/* site-06-dashboard-login.css: Dashboard and login (19-20).
   Part of the old site.css, split by sections (same order: _Styles.cshtml links them one after the other,
   so the cascade is exactly the same). */

/* =====================================================================
   19. DASHBOARD
   ===================================================================== */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 18px;
}

/* The link must not show the global animated underline */
.dashboard-link,
.dashboard-link:hover {
    display: block;
    height: 100%;
    background-image: none;
    text-decoration: none;
}

.dashboard-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    height: 100%;
    padding: 22px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    text-align: left;
    cursor: pointer;
    transition: var(--transition);
}

    .dashboard-card:hover {
        border-color: rgba(96, 165, 250, 0.45);
        box-shadow: 0 10px 26px -12px rgba(37, 99, 235, 0.55);
        transform: translateY(-3px);
    }

.dashboard-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    margin: 0;
    border-radius: 12px;
    background: linear-gradient(145deg, rgba(59, 130, 246, 0.22), rgba(6, 182, 212, 0.10));
    border: 1px solid rgba(96, 165, 250, 0.26);
    color: #93c5fd;
    font-size: 1.2rem;
    transition: var(--transition);
}

.dashboard-card:hover .dashboard-icon {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    border-color: #2563eb;
    color: #fff;
}

.dashboard-card h5 {
    margin: 0;
    color: var(--text);
    font-size: 0.98rem;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.dashboard-card p {
    margin: 0;
    max-width: none;
    color: var(--text-soft);
    font-size: 0.83rem;
    line-height: 1.5;
}

/* Footer line of the card */
.dashboard-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid var(--border);
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 600;
}

    .dashboard-cta i {
        transition: var(--transition);
    }

.dashboard-card:hover .dashboard-cta {
    color: #60a5fa;
}

    .dashboard-card:hover .dashboard-cta i {
        transform: translateX(3px);
    }


/* =====================================================================
   20. LOGIN
   ===================================================================== */
.auth-page {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 100vh;
    padding: 32px 20px;
    overflow: hidden;
    background: #050914 url("/images/login-fondo.jpg") center / cover no-repeat;
}

/* --- Full-screen background video --- */
.auth-bg-video {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(0.85) contrast(1.05);
    pointer-events: none;
}

/* Dark filter over the video so the card stands out */
.auth-bg-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: radial-gradient(ellipse 60% 70% at 50% 50%, rgba(5, 9, 20, 0.55) 0%, rgba(5, 9, 20, 0.78) 100%), linear-gradient(180deg, rgba(5, 9, 20, 0.35) 0%, rgba(5, 9, 20, 0.6) 100%);
    pointer-events: none;
}

/* --- Login card --- */

/* Logo on top of the card */
.auth-logo {
    display: flex;
    justify-content: center;
    padding: 32px 38px 0;
}

    .auth-logo img {
        width: 96px;
        height: 96px;
        object-fit: contain;
        filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.55));
    }

/* --- Form --- */
.auth-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 22px 38px 34px;
}


.auth-panel-head h1 {
    margin: 0;
    color: #fff;
    font-size: 1.55rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.auth-panel-head p {
    margin: 0;
    color: var(--muted);
    font-size: 0.86rem;
}

/* General errors */
.auth-alert {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    padding: 12px 14px;
    background: rgba(244, 80, 107, 0.1);
    border: 1px solid rgba(244, 80, 107, 0.28);
    border-radius: var(--radius);
    color: #fda4af;
    font-size: 0.83rem;
    line-height: 1.45;
}

    .auth-alert > i {
        margin-top: 1px;
        flex-shrink: 0;
        color: var(--danger);
        font-size: 1rem;
    }

.auth-alert-line {
    display: block;
}

/* Fields */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
    margin: 0;
}

.auth-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin: 0;
}

    .auth-field label {
        margin: 0;
        color: var(--text-soft);
        font-size: 0.74rem;
        font-weight: 700;
        letter-spacing: 0.08em;
        text-transform: uppercase;
    }

.auth-input {
    position: relative;
    display: block;
    width: 100%;
}

.auth-input-icon {
    position: absolute;
    top: 50%;
    left: 15px;
    transform: translateY(-50%);
    color: var(--muted);
    font-size: 0.98rem;
    pointer-events: none;
    transition: var(--transition);
}

.auth-form .auth-input .cool-input {
    width: 100%;
    height: 48px;
    padding: 0 46px 0 44px;
    background: rgba(3, 7, 18, 0.65);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: #fff;
    font-size: 0.92rem;
}

    .auth-form .auth-input .cool-input::placeholder {
        color: var(--input-placeholder);
    }

    .auth-form .auth-input .cool-input:hover {
        border-color: var(--border-light);
    }

    .auth-form .auth-input .cool-input:focus {
        background: rgba(17, 26, 46, 0.9);
        border-color: #3b82f6;
        box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
        outline: none;
    }

.auth-input:focus-within .auth-input-icon {
    color: #60a5fa;
}

/* Show / hide password */
.auth-input-toggle {
    position: absolute;
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: var(--muted);
    font-size: 0.95rem;
    cursor: pointer;
    transition: var(--transition);
}

    .auth-input-toggle:hover {
        background: rgba(255, 255, 255, 0.06);
        color: #93c5fd;
    }

.auth-field-error {
    color: var(--danger);
    font-size: 0.78rem;
}

    .auth-field-error:empty {
        display: none;
    }

.auth-capslock {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--warning);
    font-size: 0.75rem;
}

    /* The display above would override the hidden attribute */
    .auth-capslock[hidden] {
        display: none;
    }

/* Submit */
.btn-auth-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    height: 48px;
    margin-top: 4px;
    padding: 0 16px;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    border: 1px solid rgba(147, 197, 253, 0.28);
    border-radius: var(--radius);
    color: #fff;
    font-size: 0.92rem;
    font-weight: 650;
    letter-spacing: 0.01em;
    cursor: pointer;
    box-shadow: 0 10px 24px -10px rgba(37, 99, 235, 0.85);
    transition: var(--transition);
}

    .btn-auth-submit i {
        font-size: 1.25rem;
        transition: var(--transition);
    }

    .btn-auth-submit:hover {
        background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
        transform: translateY(-1px);
        box-shadow: 0 14px 28px -10px rgba(37, 99, 235, 0.95);
    }

        .btn-auth-submit:hover i {
            transform: translateX(3px);
        }

    .btn-auth-submit:active {
        transform: translateY(0);
    }

/* Panel footer */
.auth-panel-foot {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    color: var(--muted);
    font-size: 0.76rem;
}

    .auth-panel-foot > span {
        display: flex;
        align-items: center;
        gap: 7px;
    }

    .auth-panel-foot i {
        color: var(--success);
    }

.auth-help {
    color: #475569;
}

/* --- Login card (frosted glass that takes the colors of the background) --- */
.auth-card {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 480px;
    background: linear-gradient(160deg, rgba(30, 52, 92, 0.42) 0%, rgba(8, 15, 32, 0.62) 100%);
    backdrop-filter: blur(22px) saturate(160%);
    -webkit-backdrop-filter: blur(22px) saturate(160%);
    border: 1px solid rgba(148, 187, 233, 0.18);
    border-radius: var(--radius-xl);
    box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.07);
    overflow: hidden;
}

    /* Soft light reflection on the top edge of the glass */
    .auth-card::before {
        content: "";
        position: absolute;
        top: 0;
        left: 12%;
        right: 12%;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(191, 219, 254, 0.55), transparent);
        pointer-events: none;
    }

/* Centered title and subtitle */
.auth-panel-head {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-align: center;
}

/* Inputs: translucent so they blend with the glass */
.auth-form .auth-input .cool-input {
    background: rgba(4, 10, 24, 0.45);
    border: 1px solid rgba(148, 187, 233, 0.16);
}

    .auth-form .auth-input .cool-input:hover {
        border-color: rgba(148, 187, 233, 0.3);
    }

    .auth-form .auth-input .cool-input:focus {
        background: rgba(8, 18, 40, 0.65);
        border-color: #60a5fa;
        box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.18);
    }

/* Centered footer with a softer divider */
.auth-panel-foot {
    align-items: center;
    text-align: center;
    border-top-color: rgba(148, 187, 233, 0.12);
}

.auth-help {
    color: #64748b;
}

/* ---------------------------------------------------------------------
   Login code (second step, Pages/Account/VerifyCode)
   --------------------------------------------------------------------- */
.auth-code-input {
    font-size: 1.6rem;
    letter-spacing: 0.5em;
    text-align: center;
    font-variant-numeric: tabular-nums;
}

.auth-alternatives {
    margin-top: 0.9rem;
    display: grid;
    gap: 0.6rem;
    text-align: center;
    font-size: 0.9rem;
}

.auth-alternatives .btn-link {
    font-size: 0.9rem;
    color: inherit;
    opacity: 0.85;
}

.auth-recovery summary {
    cursor: pointer;
    opacity: 0.85;
}

.auth-recovery-form {
    display: flex;
    gap: 0.5rem;
    margin: 0.6rem 0 0.3rem;
}

.auth-recovery-form input {
    text-transform: uppercase;
    letter-spacing: 0.1em;
}
