/* ============================================================
   FotoDigital Photobook - Smart Features Styles
   ============================================================ */

/* ── Autofill Progress Bar ─────────────────────────────────── */

.mc-autofill-progress {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100000;
    background: rgba(38, 50, 56, 0.95);
    padding: 14px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    transform: translateY(-100%);
    transition: transform 0.3s ease;
}

.mc-autofill-progress.visible {
    transform: translateY(0);
}

.mc-autofill-progress-label {
    color: #fff;
    font-family: var(--mc-font, 'Inter', sans-serif);
    font-size: 13px;
    white-space: nowrap;
    min-width: 180px;
}

.mc-autofill-progress-track {
    flex: 1;
    height: 6px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 3px;
    overflow: hidden;
}

.mc-autofill-progress-fill {
    height: 100%;
    background: var(--mc-primary, #2196F3);
    border-radius: 3px;
    width: 0;
    transition: width 0.3s ease;
}

/* ── Quality Badge (DPI indicator on canvas) ───────────────── */

.mc-quality-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: var(--mc-font, 'Inter', sans-serif);
    font-size: 10px;
    font-weight: 700;
    color: #fff;
    line-height: 1.4;
    pointer-events: none;
    z-index: 10;
    white-space: nowrap;
}

.mc-quality-badge.mc-quality-good {
    background: #4CAF50;
}

.mc-quality-badge.mc-quality-ok {
    background: #FFC107;
    color: #333;
}

.mc-quality-badge.mc-quality-poor {
    background: #FF9800;
}

.mc-quality-badge.mc-quality-bad {
    background: #f44336;
}

/* Badge overlay inside image grid panel */
.mc-image-item .mc-quality-badge {
    position: absolute;
    top: 2px;
    right: 2px;
    font-size: 9px;
    padding: 1px 4px;
}

/* ── Validation Modal ──────────────────────────────────────── */

.mc-validation-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 100001;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mc-validation-modal-overlay.visible {
    opacity: 1;
}

.mc-validation-modal {
    background: #fff;
    border-radius: 12px;
    width: 520px;
    max-width: 90vw;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.mc-validation-modal-overlay.visible .mc-validation-modal {
    transform: scale(1);
}

.mc-vm-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 24px 12px;
    border-bottom: 1px solid var(--mc-border, #e0e0e0);
}

.mc-vm-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--mc-text, #263238);
    font-family: var(--mc-font, 'Inter', sans-serif);
}

.mc-vm-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--mc-text-light, #78909C);
    padding: 0 4px;
    line-height: 1;
    transition: color 0.2s;
}

.mc-vm-close:hover {
    color: var(--mc-danger, #f44336);
}

.mc-vm-status {
    padding: 8px 24px;
    font-size: 14px;
    font-weight: 500;
    font-family: var(--mc-font, 'Inter', sans-serif);
}

.mc-vm-status-ok {
    color: #4CAF50;
}

.mc-vm-status-warn {
    color: #FF9800;
}

.mc-vm-summary {
    padding: 0 24px 12px;
    font-size: 12px;
    color: var(--mc-text-light, #78909C);
    font-family: var(--mc-font, 'Inter', sans-serif);
}

.mc-vm-body {
    flex: 1;
    overflow-y: auto;
    padding: 8px 24px 16px;
}

.mc-vm-footer {
    padding: 14px 24px;
    border-top: 1px solid var(--mc-border, #e0e0e0);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

/* ── Validation OK state ───────────────────────────────────── */

.mc-validation-ok {
    text-align: center;
    padding: 32px 16px;
}

.mc-validation-ok svg {
    display: block;
    margin: 0 auto 12px;
}

.mc-validation-ok p {
    margin: 0;
    font-size: 15px;
    color: var(--mc-text, #263238);
    font-family: var(--mc-font, 'Inter', sans-serif);
}

/* ── Validation Item (single warning row) ──────────────────── */

.mc-validation-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--mc-radius, 6px);
    margin-bottom: 6px;
    font-family: var(--mc-font, 'Inter', sans-serif);
    font-size: 13px;
    transition: background 0.15s;
}

.mc-validation-item:hover {
    background: rgba(0, 0, 0, 0.03);
}

.mc-validation-item.mc-vi-error {
    border-left: 3px solid #f44336;
    background: rgba(244, 67, 54, 0.04);
}

.mc-validation-item.mc-vi-warning {
    border-left: 3px solid #FF9800;
    background: rgba(255, 152, 0, 0.04);
}

.mc-validation-item.mc-vi-info {
    border-left: 3px solid #2196F3;
    background: rgba(33, 150, 243, 0.04);
}

.mc-vi-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mc-vi-error .mc-vi-icon {
    color: #f44336;
}

.mc-vi-warning .mc-vi-icon {
    color: #FF9800;
}

.mc-vi-info .mc-vi-icon {
    color: #2196F3;
}

.mc-vi-message {
    flex: 1;
    color: var(--mc-text, #263238);
    line-height: 1.4;
}

.mc-vi-goto {
    flex-shrink: 0;
    background: none;
    border: 1px solid var(--mc-border, #e0e0e0);
    border-radius: 4px;
    padding: 4px 10px;
    font-size: 14px;
    cursor: pointer;
    color: var(--mc-primary, #2196F3);
    transition: all 0.15s;
}

.mc-vi-goto:hover {
    background: var(--mc-primary, #2196F3);
    color: #fff;
    border-color: var(--mc-primary, #2196F3);
}

/* ── Validation Modal Buttons ──────────────────────────────── */

.mc-vm-btn {
    padding: 10px 20px;
    border: none;
    border-radius: var(--mc-radius, 6px);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--mc-font, 'Inter', sans-serif);
    transition: all 0.2s;
}

.mc-vm-btn-ok {
    background: var(--mc-success, #4CAF50);
    color: #fff;
}

.mc-vm-btn-ok:hover {
    background: #43A047;
}

.mc-vm-btn-fix {
    background: var(--mc-primary, #2196F3);
    color: #fff;
}

.mc-vm-btn-fix:hover {
    background: var(--mc-primary-dark, #1976D2);
}

.mc-vm-btn-ignore {
    background: transparent;
    color: var(--mc-text-light, #78909C);
    border: 1px solid var(--mc-border, #e0e0e0);
}

.mc-vm-btn-ignore:hover {
    background: #f5f5f5;
    color: var(--mc-text, #263238);
}

/* ── Autofill Button (large CTA) ──────────────────────────── */

.mc-autofill-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 16px;
    background: linear-gradient(135deg, var(--mc-primary, #2196F3), var(--mc-primary-dark, #1976D2));
    color: #fff;
    border: none;
    border-radius: var(--mc-radius, 6px);
    font-family: var(--mc-font, 'Inter', sans-serif);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(33, 150, 243, 0.3);
}

.mc-autofill-btn:hover {
    background: linear-gradient(135deg, #1E88E5, #1565C0);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.4);
    transform: translateY(-1px);
}

.mc-autofill-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(33, 150, 243, 0.3);
}

.mc-autofill-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.mc-autofill-btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* Shuffle button variant */
.mc-autofill-btn.mc-shuffle-btn {
    background: linear-gradient(135deg, #FF9800, #F57C00);
    box-shadow: 0 2px 8px rgba(255, 152, 0, 0.3);
}

.mc-autofill-btn.mc-shuffle-btn:hover {
    background: linear-gradient(135deg, #FB8C00, #EF6C00);
    box-shadow: 0 4px 12px rgba(255, 152, 0, 0.4);
}

/* Validate button variant */
.mc-autofill-btn.mc-validate-btn {
    background: linear-gradient(135deg, #4CAF50, #388E3C);
    box-shadow: 0 2px 8px rgba(76, 175, 80, 0.3);
}

.mc-autofill-btn.mc-validate-btn:hover {
    background: linear-gradient(135deg, #43A047, #2E7D32);
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.4);
}
