/* Fame Advisory — full-page auth (login, forgot, reset) */

:root {
    --portal-navy: #152a44;
    --portal-blue: #1e3d5c;
    --portal-accent: #3672a0;
    --portal-accent-hover: #2d5f8f;
    --portal-gold: #fecc00;
    --portal-text: #181c32;
    --portal-text-muted: #6b7280;
    --portal-border: #e4e6ef;
}

html,
body.app-blank {
    height: 100%;
    margin: 0;
    -webkit-font-smoothing: antialiased;
}

body.app-blank {
    overflow-x: hidden;
    overflow-y: auto;
}

/* —— Full-page background —— */
.portal-auth-root {
    position: relative;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
}

.portal-auth-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    background-image: var(--portal-auth-bg);
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    transform: scale(1.02);
}

.portal-auth-overlay {
    position: fixed;
    inset: 0;
    z-index: 1;
    background: linear-gradient(
        135deg,
        rgba(21, 42, 68, 0.82) 0%,
        rgba(30, 61, 92, 0.72) 45%,
        rgba(54, 114, 160, 0.65) 100%
    );
    pointer-events: none;
}

.portal-auth-overlay::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.14) 0%,
        transparent 40%,
        rgba(21, 42, 68, 0.2) 100%
    );
}

.portal-auth-page {
    position: relative;
    z-index: 2;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 1.5rem 1.25rem 2rem;
}

@media (min-width: 992px) {
    .portal-auth-page {
        padding: 2.5rem 3rem;
    }
}

.portal-auth-layout {
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    display: grid;
    gap: 2rem;
    align-items: center;
}

@media (min-width: 992px) {
    .portal-auth-layout {
        grid-template-columns: 1fr minmax(380px, 440px);
        gap: 3.5rem;
    }
}

/* —— Hero (left on desktop) —— */
.portal-auth-hero {
    color: #fff;
    text-align: center;
}

@media (min-width: 992px) {
    .portal-auth-hero {
        text-align: left;
        padding-right: 1rem;
    }
}

.portal-auth-hero-logo {
    display: block;
    height: 56px;
    width: auto;
    margin: 0 auto 1.5rem;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.15));
}

.portal-auth-hero-badge {
    display: inline-block;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--portal-gold);
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.18);
    padding: 0.4rem 0.85rem;
    border-radius: 2rem;
    margin-bottom: 1.25rem;
    backdrop-filter: blur(6px);
}

.portal-auth-hero-title {
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.25;
    margin: 0 0 1rem;
    color: #ffffff;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
}

.portal-auth-hero-text {
    font-size: 1rem;
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.88);
    margin: 0 0 1.75rem;
    max-width: 480px;
}

@media (min-width: 992px) {
    .portal-auth-hero-text {
        margin-left: 0;
        margin-right: 0;
    }
}

@media (max-width: 991.98px) {
    .portal-auth-hero-features {
        display: none;
    }

    .portal-auth-hero-title {
        font-size: 1.35rem;
    }

    .portal-auth-hero-text {
        font-size: 0.9375rem;
        margin-bottom: 0;
    }
}

.portal-auth-hero-features {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.portal-auth-hero-features li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 0.625rem;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.45;
    color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
}

.portal-auth-hero-check {
    flex-shrink: 0;
    width: 1.25rem;
    height: 1.25rem;
    margin-top: 0.1rem;
    border-radius: 0.35rem;
    background: var(--portal-gold);
    color: var(--portal-navy);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    font-weight: 800;
}

/* —— Login card —— */
.portal-auth-card {
    background: #fff;
    border-radius: 1rem;
    box-shadow:
        0 4px 6px rgba(21, 42, 68, 0.04),
        0 24px 48px rgba(21, 42, 68, 0.18),
        0 0 0 1px rgba(255, 255, 255, 0.06);
    overflow: hidden;
    width: 100%;
    max-width: 440px;
    margin: 0 auto;
}

@media (min-width: 992px) {
    .portal-auth-card {
        margin: 0;
        max-width: none;
    }
}

.portal-auth-card-header {
    padding: 2rem 2rem 0;
    text-align: center;
    border-bottom: none;
}

.portal-auth-card-logo {
    display: inline-block;
    line-height: 0;
}

.portal-auth-card-logo img {
    height: 52px;
    width: auto;
    display: block;
    margin: 0 auto;
}

.portal-auth-card-body {
    padding: 1.75rem 2rem 1.5rem;
}

.portal-auth-card-footer {
    padding: 1rem 2rem 1.5rem;
    text-align: center;
    font-size: 0.8125rem;
    color: #9ca3af;
    border-top: 1px solid var(--portal-border);
    background: #fafbfc;
}

.portal-auth-page-footer {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.8125rem;
}

.portal-auth-page-footer a {
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    font-weight: 600;
}

.portal-auth-page-footer a:hover {
    color: #fff;
}

/* —— Form —— */
.portal-auth-form {
    width: 100%;
}

.portal-auth-eyebrow {
    display: inline-block;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--portal-accent);
    margin-bottom: 0.65rem;
}

.portal-auth-card-title {
    font-size: 1.625rem;
    font-weight: 700;
    color: var(--portal-text);
    letter-spacing: -0.02em;
    line-height: 1.25;
    margin: 0 0 0.5rem;
}

.portal-auth-card-subtitle {
    color: var(--portal-text-muted);
    font-size: 0.9375rem;
    line-height: 1.55;
    margin: 0 0 1.75rem;
}

.portal-auth-form .form-label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.45rem;
}

.portal-auth-form .form-control {
    background: #fff;
    border: 1px solid var(--portal-border);
    padding: 0.75rem 1rem;
    font-size: 0.9375rem;
    border-radius: 0.5rem;
    min-height: 46px;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.portal-auth-form .form-control::placeholder {
    color: #9ca3af;
}

.portal-auth-form .form-control:focus {
    border-color: var(--portal-accent);
    box-shadow: 0 0 0 3px rgba(54, 114, 160, 0.12);
}

.portal-auth-form .btn-primary {
    background: var(--portal-accent);
    border: none;
    padding: 0.8rem 1.25rem;
    font-weight: 600;
    font-size: 0.9375rem;
    min-height: 48px;
    border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(54, 114, 160, 0.25);
    transition: background 0.15s ease, transform 0.1s ease, box-shadow 0.15s ease;
}

.portal-auth-form .btn-primary:hover {
    background: var(--portal-accent-hover);
    box-shadow: 0 4px 12px rgba(54, 114, 160, 0.35);
}

.portal-auth-form .btn-primary:active {
    transform: translateY(1px);
}

.portal-auth-form .btn-light {
    border: 1px solid var(--portal-border);
    font-weight: 600;
    min-height: 46px;
    border-radius: 0.5rem;
}

.portal-auth-form .link-primary {
    color: var(--portal-accent);
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
}

.portal-auth-form .link-primary:hover {
    color: var(--portal-navy);
    text-decoration: underline;
}

.portal-auth-form .alert {
    border-radius: 0.5rem;
    font-size: 0.875rem;
}

.portal-auth-copyright {
    color: var(--portal-text-muted);
    font-size: 0.85rem;
}

[data-portal-password-wrapper] .form-control.pe-12 {
    padding-right: 3rem !important;
}

[data-portal-password-wrapper] .position-relative {
    position: relative;
}

[data-portal-password-toggle="true"] {
    z-index: 5;
    pointer-events: auto;
    cursor: pointer;
}

.portal-password-policy {
    background: #f8fafc;
    border: 1px solid var(--portal-border, #e2e8f0);
    border-radius: 0.75rem;
    padding: 1rem 1.05rem 0.95rem;
}

.portal-password-strength-label {
    color: #64748b;
}

.portal-password-strength.is-weak .portal-password-strength-label { color: #dc2626; }
.portal-password-strength.is-fair .portal-password-strength-label { color: #d97706; }
.portal-password-strength.is-good .portal-password-strength-label { color: #2563eb; }
.portal-password-strength.is-strong .portal-password-strength-label { color: #16a34a; }

.portal-password-strength-track {
    height: 6px;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
}

.portal-password-strength-fill {
    display: block;
    height: 100%;
    width: 0;
    border-radius: 999px;
    background: #cbd5e1;
    transition: width 0.2s ease, background 0.2s ease;
}

.portal-password-strength.is-weak .portal-password-strength-fill { background: #dc2626; }
.portal-password-strength.is-fair .portal-password-strength-fill { background: #d97706; }
.portal-password-strength.is-good .portal-password-strength-fill { background: #2563eb; }
.portal-password-strength.is-strong .portal-password-strength-fill { background: #16a34a; }

.portal-password-rule {
    color: #64748b;
}

.portal-password-rule-icon {
    display: inline-flex;
    width: 0.9rem;
    height: 0.9rem;
    border: 1.5px solid #cbd5e1;
    border-radius: 999px;
    flex-shrink: 0;
    position: relative;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.portal-password-rule.is-met {
    color: #15803d;
    font-weight: 600;
}

.portal-password-rule.is-met .portal-password-rule-icon {
    background: #16a34a;
    border-color: #16a34a;
}

.portal-password-rule.is-met .portal-password-rule-icon::after {
    content: '';
    position: absolute;
    left: 0.22rem;
    top: 0.05rem;
    width: 0.28rem;
    height: 0.48rem;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.portal-password-rule.is-unmet .portal-password-rule-icon {
    border-color: #f59e0b;
}

.portal-password-reuse {
    font-size: 0.75rem;
    line-height: 1.45;
    color: #64748b;
    margin: 0;
}

.portal-password-match.is-match {
    color: #15803d;
    font-weight: 600;
}

.portal-password-match.is-mismatch {
    color: #dc2626;
    font-weight: 600;
}

.portal-auth-form .btn-primary:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    box-shadow: none;
}
