/* ==========================================================================
   Authentication Theme — VayuOS
   Dark Only · CSP-Safe · CLS-Stable · Shared by Login & Signup
   ========================================================================== */

/* --------------------------------------------------------------------------
   AUTH ROOT CONTRACT
   -------------------------------------------------------------------------- */
body.auth-page {
    background-color: #050505;
    /* background-image removed to allow .hero-bg to show */
    color: var(--text-main);
    min-height: 100svh;
    overflow-x: hidden;
    font-family: var(--font-family);
}

/* --------------------------------------------------------------------------
   AUTH LAYOUT
   -------------------------------------------------------------------------- */
.login-container {
    min-height: 100svh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 20px;
}

.login-card {
    width: 100%;
    max-width: 600px;
    /* increased height naturally via width */
    padding: 48px 40px 56px;

    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(48px);
    -webkit-backdrop-filter: blur(48px);

    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);

    box-shadow:
        0 30px 80px rgba(0, 0, 0, 0.65),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);

    display: flex;
    flex-direction: column;
    gap: 36px;
}

/* --------------------------------------------------------------------------
   HEADER
   -------------------------------------------------------------------------- */
.signup-header {
    text-align: center;
}

.signup-logo {
    width: 75%;
    max-width: 270px;
    height: auto;
    margin: 0 auto 16px;
}

.signup-title {
    font-size: 1.6rem;
    font-weight: var(--font-semibold);
    margin-bottom: 8px;
}

.signup-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   STEP SECTIONS
   -------------------------------------------------------------------------- */
.step-section {
    border-left: 2px solid rgba(255, 102, 0, 0.25);
    /* saffron idle */
    padding-left: 24px;
    padding-bottom: 4px;

    display: flex;
    flex-direction: column;
    gap: 16px;

    opacity: 0.45;
    pointer-events: none;

    transition:
        opacity 0.25s ease,
        border-color 0.25s ease;
}

/* Active step */
.step-section.active {
    opacity: 1;
    pointer-events: auto;
    border-left-color: #ff6600;
}

/* Completed step (KEEP saffron, not green) */
.step-section.completed {
    opacity: 1;
    border-left-color: #ff6600;
}

/* Clear vertical separation between steps */
.step-section+.step-section {
    margin-top: 28px;
}

/* --------------------------------------------------------------------------
   STEP HEADER
   -------------------------------------------------------------------------- */
.step-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    font-size: 1.05rem;
    font-weight: var(--font-medium);
}

.step-badge {
    font-size: 0.7rem;
    padding: 3px 10px;
    border-radius: 999px;

    background: rgba(255, 255, 255, 0.08);
    color: var(--text-muted);
}

.step-section.completed .step-badge {
    background: rgba(34, 197, 94, 0.15);
    color: var(--success);
}

/* --------------------------------------------------------------------------
   FORMS
   -------------------------------------------------------------------------- */
.form-row {
    display: flex;
    gap: 12px;
    align-items: center;
}

.form-input {
    flex: 1;
    height: 40px;
    padding: 0 16px;
    box-sizing: border-box;

    font-size: 1rem;
    line-height: 38px;
    /* 40px - 2px border */
    color: var(--text-main);

    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);

    transition:
        border-color var(--transition-fast),
        background var(--transition-fast),
        box-shadow var(--transition-fast);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 0 4px rgba(255, 102, 0, 0.25);
}

/* --------------------------------------------------------------------------
   BUTTON SYSTEM (UNIFIED WIDTH)
   -------------------------------------------------------------------------- */
.btn-login {
    height: 40px;
    padding: 0 22px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    font-size: 0.95rem;
    font-weight: var(--font-semibold);

    border-radius: var(--radius-full);
    color: #ffffff;

    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);

    border: 1px solid rgba(255, 255, 255, 0.25);

    box-shadow:
        0 4px 20px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);

    cursor: pointer;
    user-select: none;

    transition:
        background var(--transition-fast),
        transform var(--transition-fast),
        box-shadow var(--transition-fast);
}

/* Fixed-width buttons for side-by-side layout */
.btn-fixed {
    min-width: 120px;
}

/* Full-width buttons */
.btn-full {
    width: 100%;
    margin-top: 12px;
}

.btn-login:hover:not(:disabled) {
    background: rgba(255, 102, 0, 0.25);
    border-color: var(--primary);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 8px 24px var(--primary-glow);
    /* transform: translateY(-1px); REMOVED */
}


.btn-login:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    box-shadow: none;
}

.glass-processing {
    background: rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    color: #ffffff !important;
    cursor: wait !important;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.1) !important;
}

/* --------------------------------------------------------------------------
   AADHAAR SECTION
   -------------------------------------------------------------------------- */
.aadhaar-box {
    display: flex;
    flex-direction: column;
    gap: 12px;

    padding: 20px;
    border: 1px dashed rgba(255, 255, 255, 0.25);
    border-radius: var(--radius-md);
}

.aadhaar-box .form-input {
    flex: none;
    width: 100%;
}

.aadhaar-info {
    font-size: 0.8rem;
    line-height: 1.5;
    color: var(--text-muted);
}

.aadhaar-info a {
    color: var(--primary);
    text-decoration: underline;
}

/* Terminal */
#ocr-terminal {
    display: none;
    margin-top: 12px;
    padding: 12px;

    background: #000;
    color: #00ff88;
    font-family: ui-monospace, SFMono-Regular, monospace;
    font-size: 11px;

    border-radius: 6px;
    max-height: 160px;
    overflow-y: auto;
}

/* --------------------------------------------------------------------------
   CONSENT
   -------------------------------------------------------------------------- */
.consent-row {
    display: flex;
    gap: 10px;
    align-items: center;

    font-size: 0.9rem;
    color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   FOOTER
   -------------------------------------------------------------------------- */
.signup-footer {
    margin-top: 24px;
    text-align: center;
}

.auth-link {
    font-size: 0.9rem;
    color: var(--primary);
    text-decoration: none;
}

.auth-link:hover {
    text-decoration: underline;
}

/* --------------------------------------------------------------------------
   MOBILE
   -------------------------------------------------------------------------- */
@media (max-width: 520px) {
    .login-card {
        padding: 36px 24px 44px;
    }

    .form-row {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-fixed {
        width: 100%;
    }
}

/* --------------------------------------------------------------------------
   REDUCED MOTION
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
        transform: none !important;
    }
}

/* --------------------------------------------------------------------------
   REVIEW CARD
   -------------------------------------------------------------------------- */
#aadhaar-review-card {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.review-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 20px;
}

.review-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.review-item.full-width {
    grid-column: 1 / -1;
}

.review-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.review-value {
    font-size: 0.95rem;
    color: #fff;
    font-weight: 500;
}

/* Verification Actions */
.verification-actions {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 12px;
}

.verify-prompt {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 12px;
    text-align: center;
}

.radio-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
}

.radio-option:hover {
    background: rgba(255, 255, 255, 0.06);
}

.radio-option input[type="radio"] {
    accent-color: #ff6600;
}

.success-ring input:checked+.radio-label {
    color: #22c55e;
}

.error-ring input:checked+.radio-label {
    color: #ef4444;
}