/* CSB Seed Act Portal — shared custom styles */

/* Large touch targets for rural users */
.btn-lg, .form-control-lg, .form-select-lg {
    min-height: 44px;
}

/* Ensure all clickable elements meet minimum touch target */
.btn {
    min-height: 38px;
}

/* Form labels — clear and readable */
.form-label {
    font-weight: 500;
    margin-bottom: 0.3rem;
}

/* Bilingual label helper — Hindi in red like old portal */
.label-hindi {
    display: block;
    font-size: 0.85rem;
    color: red;
    font-weight: normal;
}

/* Section dividers — zari left border accent */
.form-section {
    background: #f0f4ff;
    padding: 0.75rem 1rem;
    margin: 1.5rem -1rem 1rem;
    border-left: 4px solid var(--gold, #C9A84C);
    font-weight: 600;
    font-family: 'Exo', sans-serif;
}

/* ===== Step Indicator with Connecting Lines ===== */
.step-indicator {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.step-indicator .step-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    z-index: 1;
}

.step-indicator .step {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    font-family: 'Exo', sans-serif;
    background: #e9ecef;
    color: #6c757d;
    border: 2px solid #dee2e6;
    transition: all 0.3s ease;
}

.step-indicator .step.active {
    background: var(--navy, #223a66);
    color: white;
    border-color: var(--gold, #C9A84C);
    box-shadow: 0 0 0 4px rgba(201, 168, 76, 0.25);
}

.step-indicator .step.completed {
    background: #198754;
    color: white;
    border-color: #198754;
}

.step-indicator .step-label {
    font-size: 0.72rem;
    color: #6c757d;
    text-align: center;
    max-width: 80px;
    line-height: 1.2;
    font-weight: 500;
    transition: all 0.3s ease;
}

.step-indicator .step-wrapper.active .step-label {
    color: var(--navy, #223a66);
    font-weight: 700;
}

/* Connecting lines — silk thread between step circles */
.step-indicator .step-line {
    flex: 1;
    height: 3px;
    background: #dee2e6;
    margin: 19px 0 0;
    min-width: 40px;
    max-width: 100px;
    transition: background 0.3s ease;
    border-radius: 2px;
    position: relative;
}

.step-indicator .step-line.completed {
    background: linear-gradient(90deg, var(--gold-dark, #A8893A), var(--gold-light, #D4AF37), var(--gold, #C9A84C));
}

/* Silk thread shimmer on completed step lines */
.step-indicator .step-line.completed::after {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.5) 50%, transparent 100%);
    background-size: 200% 100%;
    animation: threadShimmer 2s ease-in-out infinite;
    border-radius: 2px;
}

@keyframes threadShimmer {
    0%   { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* ===== Step Transition Animations ===== */
[x-show] {
    animation: stepFadeIn 0.3s ease-out;
}

@keyframes stepFadeIn {
    0% {
        opacity: 0;
        transform: translateX(15px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ===== File Upload Hints ===== */
.file-hint {
    font-size: 0.8rem;
    color: #0d6efd;
    margin-top: 4px;
}

.file-hint .max-file {
    color: #0d6efd;
    font-weight: 600;
}

/* ===== Declaration Section ===== */
.declaration-header {
    background: #f0f4ff;
    padding: 10px 16px;
    text-align: center;
    border-left: 4px solid var(--gold, #C9A84C);
    margin: 1.5rem 0 1rem;
}

.declaration-header h5 {
    margin: 0;
    font-family: 'Exo', sans-serif;
    font-weight: 700;
    color: var(--navy, #223a66);
}

.declaration-text {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 16px 20px;
    font-size: 0.95rem;
    line-height: 1.7;
    color: #333;
}

.declaration-text .hindi {
    color: red;
}

/* ===== Error messages — plain language ===== */
.invalid-feedback, .text-danger {
    font-size: 0.85rem;
}

/* ===== Success checkmark animation ===== */
.success-checkmark {
    animation: successPulse 0.6s ease-out;
}

@keyframes successPulse {
    0% { transform: scale(0.5); opacity: 0; }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

/* ===== Mobile responsive ===== */
@media (max-width: 768px) {
    .step-indicator .step {
        width: 32px;
        height: 32px;
        font-size: 0.75rem;
    }

    .step-indicator .step-label {
        font-size: 0.6rem;
        max-width: 55px;
    }

    .step-indicator .step-line {
        min-width: 20px;
        margin-top: 15px;
    }

    .card-body {
        padding: 1rem;
    }

    .declaration-text {
        font-size: 0.85rem;
        padding: 12px;
    }
}
