/* ============================================================
   NIRVAAN LOGIN — THEME PALETTE
   Edit these tokens to recolor the whole page in one place.
   The default theme is Nirvaan violet.
   ============================================================ */
:root {
    /* Brand accent */
    --nv-primary:       #635BFF;   /* main brand / buttons / accents  */
    --nv-primary-rgb:   99, 91, 255; /* rgb of primary (for shadows)  */
    --nv-primary-dark:  #4b45c6;   /* hover / gradient end            */
    --nv-primary-light: #7a72ff;   /* gradient start                  */
    --nv-primary-soft:  #eeedff;   /* tinted pills / hover fills      */

    /* Neutrals */
    --nv-ink:           #171a2b;   /* headings / primary text         */
    --nv-body:          #4a5064;   /* body text                       */
    --nv-muted:         #868c9c;   /* labels / secondary text         */
    --nv-border:        #e6e8f0;   /* input & card borders            */
    --nv-field-bg:      #fafbff;   /* input background                */
    --nv-surface:       #ffffff;   /* form pane background            */

    /* Hero gradient (right panel) — built from brand tokens */
    --nv-hero-a:        #7a72ff;
    --nv-hero-b:        #635BFF;
    --nv-hero-c:        #4a43c9;

    /* Shape & depth */
    --nv-radius:        14px;
    --nv-radius-lg:     18px;
    --nv-shadow-btn:    0 16px 34px -14px rgba(var(--nv-primary-rgb), .70);
    --nv-focus-ring:    0 0 0 4px rgba(var(--nv-primary-rgb), .14);
}

* { box-sizing: border-box; }
html, body { height: 100%; }

body.auth-page {
    margin: 0;
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--nv-ink);
    background: var(--nv-surface);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

/* full-viewport split shell */
.nv-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1.02fr 0.98fr;
}

/* =============== LEFT: FORM =============== */
.nv-form-pane {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 30px clamp(48px, 6vw, 104px);
    background: var(--nv-surface);
}

.nv-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* left-side brand lockup: icon mark + wordmark */
.nv-brand-lockup {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}
.nv-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--nv-primary-light), var(--nv-primary) 55%, var(--nv-primary-dark));
    color: #fff;
    font-size: 17px;
    box-shadow: 0 8px 18px -8px rgba(var(--nv-primary-rgb), .7);
}
.nv-logo { height: 26px; width: auto; }

.nv-help {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 13px;
    font-weight: 600;
    color: var(--nv-muted);
    text-decoration: none;
    transition: color .15s ease;
}
.nv-help:hover { color: var(--nv-primary); }

.nv-form-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    max-width: 404px;
    width: 100%;
    margin: 0 auto;
    padding: 24px 0;
}

.nv-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    align-self: flex-start;
    padding: 6px 13px;
    border-radius: 999px;
    background: var(--nv-primary-soft);
    color: var(--nv-primary-dark);
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .05em;
    text-transform: uppercase;
    margin-bottom: 18px;
}

.nv-title {
    font-size: clamp(28px, 2.8vw, 34px);
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.08;
    margin: 0 0 9px;
}

.nv-subtitle {
    font-size: 15px;
    line-height: 1.55;
    color: var(--nv-body);
    margin: 0 0 26px;
}

/* floating-label field */
.nv-field { position: relative; margin-bottom: 14px; }

.nv-field input {
    width: 100%;
    height: 56px;
    padding: 21px 46px 8px 16px;
    font-size: 15px;
    font-weight: 500;
    color: var(--nv-ink);
    background: var(--nv-field-bg);
    border: 1.5px solid var(--nv-border);
    border-radius: var(--nv-radius);
    outline: none;
    transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.nv-field input:focus {
    border-color: var(--nv-primary);
    background: #fff;
    box-shadow: var(--nv-focus-ring);
}

.nv-field > label {
    position: absolute;
    left: 16px;
    top: 19px;
    font-size: 15px;
    color: var(--nv-muted);
    pointer-events: none;
    transition: all .15s ease;
}
.nv-field input:focus + label,
.nv-field input:not(:placeholder-shown) + label {
    top: 10px;
    font-size: 11px;
    font-weight: 700;
    color: var(--nv-primary);
    letter-spacing: .04em;
    text-transform: uppercase;
}

.nv-ficon {
    position: absolute;
    right: 16px; top: 50%;
    transform: translateY(-50%);
    color: #b2b7c6;
    font-size: 15px;
}

.nv-toggle {
    position: absolute;
    right: 14px; top: 50%;
    transform: translateY(-50%);
    border: none; background: none;
    color: #b2b7c6;
    cursor: pointer;
    font-size: 15px;
    padding: 6px;
    line-height: 1;
    transition: color .15s ease;
}
.nv-toggle:hover { color: var(--nv-primary); }

.nv-btn {
    width: 100%;
    height: 52px;
    margin-top: 8px;
    border: none;
    border-radius: var(--nv-radius);
    background: linear-gradient(135deg, var(--nv-primary-light), var(--nv-primary) 55%, var(--nv-primary-dark));
    color: #fff;
    font-size: 15.5px;
    font-weight: 700;
    letter-spacing: .01em;
    cursor: pointer;
    transition: transform .06s ease, box-shadow .2s ease, filter .2s ease;
    box-shadow: var(--nv-shadow-btn);
}
.nv-btn:hover { filter: brightness(1.06); box-shadow: 0 20px 40px -14px rgba(var(--nv-primary-rgb), .82); }
.nv-btn:active { transform: translateY(1px); }

.nv-divider {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 20px 0 14px;
    color: #aab0be;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.nv-divider::before, .nv-divider::after {
    content: ""; flex: 1; height: 1px; background: var(--nv-border);
}

.nv-btn-outline {
    width: 100%;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border: 1.5px solid var(--nv-border);
    border-radius: var(--nv-radius);
    background: #fff;
    color: var(--nv-ink);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: border-color .15s ease, background .15s ease, color .15s ease;
}
.nv-btn-outline:hover {
    border-color: var(--nv-primary);
    background: var(--nv-primary-soft);
    color: var(--nv-primary-dark);
}
.nv-btn-outline i { color: var(--nv-primary); }

.nv-foot {
    font-size: 12.5px;
    color: #a3a9b8;
    text-align: center;
    padding-top: 10px;
}

/* jQuery-validation error message — small, normal-case, below the input */
label.error {
    display: block;
    margin: -8px 2px 14px;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.35;
    letter-spacing: normal;
    text-transform: none;
    color: #e5484d;
}
label.error small { font-size: inherit; }

/* =============== RIGHT: BRAND HERO =============== */
.nv-hero {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: clamp(36px, 3.4vw, 60px);
    color: #fff;
    background:
        radial-gradient(620px 420px at 85% 12%, rgba(255,255,255,.18), transparent 60%),
        radial-gradient(720px 520px at 8% 92%, rgba(0,0,0,.16), transparent 60%),
        linear-gradient(150deg, var(--nv-hero-a) 0%, var(--nv-hero-b) 42%, var(--nv-hero-c) 100%);
}

/* faint dot-grid texture */
.nv-hero::before {
    content: "";
    position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255,255,255,.15) 1.1px, transparent 1.1px);
    background-size: 26px 26px;
    opacity: .5;
    pointer-events: none;
}

.nv-hero .nv-orb {
    position: absolute;
    border-radius: 50%;
    background: rgba(255,255,255,.10);
    pointer-events: none;
    z-index: 1;
}
.nv-hero .nv-orb.o1 { width: 360px; height: 360px; top: -130px; right: -100px; }
.nv-hero .nv-orb.o2 { width: 210px; height: 210px; bottom: 110px; right: 54px; background: rgba(255,255,255,.07); }

/* content wrappers sit above the texture/orbs (exclude absolute orbs) */
.nv-hero > div { position: relative; z-index: 2; }

.nv-brand-badge {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 22px;
    font-weight: 800;
    letter-spacing: .01em;
}
.nv-brand-badge .mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px; height: 44px;
    border-radius: 13px;
    background: rgba(255,255,255,.2);
    font-size: 20px;
    backdrop-filter: blur(6px);
}

.nv-hero-head {
    font-size: clamp(34px, 3.3vw, 46px);
    font-weight: 800;
    line-height: 1.06;
    letter-spacing: -.035em;
    margin: 20px 0 14px;
}
.nv-hero-sub {
    font-size: 15.5px;
    line-height: 1.6;
    color: rgba(255,255,255,.86);
    margin: 0 0 26px;
    max-width: 450px;
}

.nv-features { display: grid; gap: 11px; max-width: 470px; }
.nv-feature {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 14px 18px;
    border-radius: var(--nv-radius-lg);
    background: rgba(255,255,255,.10);
    border: 1px solid rgba(255,255,255,.16);
    backdrop-filter: blur(10px);
}
.nv-feature .fi {
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px; height: 46px;
    border-radius: 13px;
    background: rgba(255,255,255,.18);
    font-size: 18px;
}
.nv-feature h4 { margin: 0 0 3px; font-size: 15px; font-weight: 700; }
.nv-feature p { margin: 0; font-size: 13px; color: rgba(255,255,255,.78); line-height: 1.42; }

.nv-hero-bot { display: flex; gap: 46px; }
.nv-stat .num { font-size: 27px; font-weight: 800; letter-spacing: -.02em; }
.nv-stat .lbl { font-size: 12.5px; color: rgba(255,255,255,.72); margin-top: 3px; }

/* =============== ENTRANCE ANIMATION =============== */
@keyframes nvRise {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}
.nv-anim { opacity: 0; animation: nvRise .6s cubic-bezier(.2,.7,.2,1) forwards; }
.nv-d1 { animation-delay: .05s; }
.nv-d2 { animation-delay: .14s; }
.nv-d3 { animation-delay: .23s; }
.nv-d4 { animation-delay: .32s; }
.nv-d5 { animation-delay: .40s; }

@media (prefers-reduced-motion: reduce) {
    .nv-anim { animation: none; opacity: 1; }
}

/* =============== BRAND-SIDE SWAP (from theme drawer) =============== */
.nv-shell.brand-left { grid-template-columns: 0.98fr 1.02fr; }
.nv-shell.brand-left .nv-hero { order: 1; }
.nv-shell.brand-left .nv-form-pane { order: 2; }

/* =============== THEME CUSTOMIZER — TRIGGER BUTTON =============== */
.nv-theme-btn {
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 60;
    width: 46px;
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    color: #fff;
    font-size: 18px;
    background: linear-gradient(135deg, var(--nv-primary-light), var(--nv-primary) 55%, var(--nv-primary-dark));
    box-shadow: 0 10px 24px -8px rgba(var(--nv-primary-rgb), .75);
    transition: transform .2s ease, box-shadow .2s ease;
}
.nv-theme-btn:hover { transform: rotate(45deg) scale(1.06); box-shadow: 0 14px 30px -8px rgba(var(--nv-primary-rgb), .85); }
.nv-theme-btn i { transition: transform .3s ease; }

/* =============== THEME CUSTOMIZER — OVERLAY & DRAWER =============== */
.nv-overlay {
    position: fixed;
    inset: 0;
    z-index: 70;
    background: rgba(17, 20, 34, .42);
    backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s ease, visibility .3s ease;
}
.nv-overlay.open { opacity: 1; visibility: visible; }

.nv-drawer {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 80;
    height: 100vh;
    width: min(300px, 86vw);
    display: flex;
    flex-direction: column;
    background: #ffffff;
    box-shadow: -24px 0 60px -20px rgba(17, 20, 34, .35);
    transform: translateX(100%);
    transition: transform .34s cubic-bezier(.22,.7,.24,1);
    will-change: transform;
}
.nv-drawer.open { transform: translateX(0); }

.nv-drawer-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 22px 22px 18px;
    color: #fff;
    background: linear-gradient(135deg, var(--nv-primary-light), var(--nv-primary) 55%, var(--nv-primary-dark));
}
.nv-drawer-head h3 { margin: 0; font-size: 17px; font-weight: 800; letter-spacing: -.01em; }
.nv-drawer-head p { margin: 3px 0 0; font-size: 12px; color: rgba(255,255,255,.82); }

.nv-drawer-close {
    flex: none;
    width: 32px; height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 9px;
    cursor: pointer;
    color: #fff;
    font-size: 15px;
    background: rgba(255,255,255,.18);
    transition: background .15s ease;
}
.nv-drawer-close:hover { background: rgba(255,255,255,.30); }

.nv-drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px 22px;
}

.nv-sec { margin-bottom: 26px; }
.nv-sec-title {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--nv-muted);
    margin-bottom: 12px;
}

/* color swatches */
.nv-swatches {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}
.nv-swatch {
    position: relative;
    aspect-ratio: 1 / 1;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    padding: 0;
    box-shadow: inset 0 0 0 1px rgba(0,0,0,.06);
    transition: transform .12s ease;
}
.nv-swatch:hover { transform: translateY(-2px) scale(1.05); }
.nv-swatch::after {
    content: "\f00c"; /* fa check */
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 13px;
    opacity: 0;
    transform: scale(.5);
    transition: opacity .15s ease, transform .15s ease;
}
.nv-swatch.active { box-shadow: inset 0 0 0 2px #fff, 0 0 0 2px currentColor; }
.nv-swatch.active::after { opacity: 1; transform: scale(1); }

/* segmented toggle */
.nv-seg {
    display: flex;
    gap: 6px;
    padding: 4px;
    border-radius: 12px;
    background: #f3f4fa;
}
.nv-seg button {
    flex: 1;
    border: none;
    border-radius: 9px;
    padding: 9px 6px;
    font-size: 12.5px;
    font-weight: 600;
    color: var(--nv-body);
    background: transparent;
    cursor: pointer;
    transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}
.nv-seg button.active {
    background: #fff;
    color: var(--nv-primary);
    box-shadow: 0 2px 8px -3px rgba(17,20,34,.2);
}

.nv-drawer-foot {
    padding: 16px 22px 22px;
    border-top: 1px solid var(--nv-border);
}
.nv-reset {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px;
    border: 1.5px solid var(--nv-border);
    border-radius: 11px;
    background: #fff;
    color: var(--nv-body);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.nv-reset:hover { border-color: var(--nv-primary); color: var(--nv-primary); background: var(--nv-primary-soft); }

/* =============== RESPONSIVE (split at >= 1024px) =============== */
@media (max-width: 1023.98px) {
    .nv-shell,
    .nv-shell.brand-left { grid-template-columns: 1fr; }
    .nv-hero { display: none; }
    .nv-form-pane { min-height: 100vh; }
}
