:root {
    color-scheme: dark;
    --vpene-bg: #060914;
    --vpene-bg-soft: #0b1020;
    --vpene-panel: rgba(15, 23, 42, 0.78);
    --vpene-panel-strong: rgba(17, 25, 48, 0.96);
    --vpene-border: rgba(148, 163, 184, 0.14);
    --vpene-border-strong: rgba(129, 140, 248, 0.32);
    --vpene-text: #f8fafc;
    --vpene-muted: #94a3b8;
    --vpene-primary: #818cf8;
    --vpene-primary-strong: #6366f1;
    --vpene-cyan: #22d3ee;
    --vpene-green: #34d399;
}

html {
    background: var(--vpene-bg);
}

body {
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
        "Segoe UI", sans-serif;
    text-rendering: optimizeLegibility;
}

::selection {
    background: rgba(99, 102, 241, 0.42);
    color: #fff;
}

.vpene-shell,
.vpene-auth-page {
    background:
        radial-gradient(circle at 82% 4%, rgba(79, 70, 229, 0.16), transparent 28rem),
        radial-gradient(circle at 12% 92%, rgba(8, 145, 178, 0.1), transparent 30rem),
        var(--vpene-bg);
}

.vpene-shell::before,
.vpene-auth-page::before {
    position: fixed;
    inset: 0;
    z-index: -1;
    background-image:
        linear-gradient(rgba(148, 163, 184, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(148, 163, 184, 0.025) 1px, transparent 1px);
    background-size: 48px 48px;
    content: "";
    mask-image: linear-gradient(to bottom, black, transparent 82%);
    pointer-events: none;
}

.vpene-mobile-header {
    background: rgba(6, 9, 20, 0.82) !important;
    border-color: var(--vpene-border) !important;
    box-shadow: 0 12px 32px rgba(2, 6, 23, 0.28);
}

.vpene-sidebar {
    overflow: hidden;
    background:
        radial-gradient(circle at 10% 0%, rgba(99, 102, 241, 0.17), transparent 18rem),
        linear-gradient(180deg, rgba(13, 19, 39, 0.99), rgba(8, 12, 27, 0.99)) !important;
    border-color: var(--vpene-border) !important;
    box-shadow: 20px 0 55px rgba(2, 6, 23, 0.34);
}

.vpene-sidebar::after {
    position: absolute;
    inset: 0 0 auto;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(129, 140, 248, 0.75), transparent);
    content: "";
}

.vpene-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
    color: var(--vpene-text);
    text-decoration: none;
}

.vpene-logo-mark {
    position: relative;
    display: inline-grid;
    width: 2.65rem;
    height: 2.65rem;
    flex: 0 0 auto;
    place-items: center;
    overflow: hidden;
    border: 1px solid rgba(165, 180, 252, 0.35);
    border-radius: 0.9rem;
    background: linear-gradient(145deg, #6366f1, #4338ca 55%, #0891b2);
    box-shadow: 0 12px 30px rgba(79, 70, 229, 0.3), inset 0 1px rgba(255, 255, 255, 0.25);
}

.vpene-logo-mark::after {
    position: absolute;
    top: -55%;
    left: -15%;
    width: 80%;
    height: 160%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    content: "";
    transform: rotate(25deg);
}

.vpene-logo-mark svg {
    position: relative;
    z-index: 1;
    width: 1.45rem;
    height: 1.45rem;
}

.vpene-brand-name {
    display: block;
    background: linear-gradient(100deg, #fff 5%, #c7d2fe 52%, #67e8f9);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-size: 1.2rem;
    font-weight: 750;
    letter-spacing: -0.035em;
    line-height: 1.1;
}

.vpene-brand-caption {
    display: block;
    margin-top: 0.2rem;
    color: #64748b;
    font-size: 0.675rem;
    font-weight: 650;
    letter-spacing: 0.12em;
    line-height: 1.2;
    text-transform: uppercase;
}

.vpene-nav-label {
    margin: 1.25rem 0 0.45rem;
    padding: 0 0.9rem;
    color: #64748b;
    font-size: 0.65rem;
    font-weight: 750;
    letter-spacing: 0.13em;
    text-transform: uppercase;
}

.vpene-nav-link {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 2.7rem;
    margin-bottom: 0.2rem;
    padding: 0.65rem 0.85rem;
    overflow: hidden;
    border: 1px solid transparent;
    border-radius: 0.8rem;
    color: #a8b3c7;
    font-size: 0.875rem;
    font-weight: 560;
    transition: border-color 160ms ease, background 160ms ease, color 160ms ease,
        transform 160ms ease;
}

.vpene-nav-link svg {
    width: 1.15rem;
    height: 1.15rem;
    margin-right: 0.75rem;
    color: #78869f;
    transition: color 160ms ease, transform 160ms ease;
}

.vpene-nav-link:hover {
    border-color: rgba(148, 163, 184, 0.12);
    background: rgba(148, 163, 184, 0.07);
    color: #f8fafc;
    transform: translateX(2px);
}

.vpene-nav-link:hover svg {
    color: #a5b4fc;
    transform: scale(1.05);
}

.vpene-nav-link.is-active {
    border-color: rgba(129, 140, 248, 0.19);
    background: linear-gradient(90deg, rgba(79, 70, 229, 0.24), rgba(99, 102, 241, 0.08));
    box-shadow: inset 0 1px rgba(255, 255, 255, 0.035);
    color: #e0e7ff;
}

.vpene-nav-link.is-active::before {
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    border-radius: 0 3px 3px 0;
    background: linear-gradient(#a5b4fc, #22d3ee);
    content: "";
}

.vpene-nav-link.is-active svg {
    color: #a5b4fc;
}

.vpene-user-card {
    border: 1px solid var(--vpene-border);
    border-radius: 0.95rem;
    background: rgba(148, 163, 184, 0.055);
}

.vpene-avatar {
    display: grid;
    width: 2.15rem;
    height: 2.15rem;
    flex: 0 0 auto;
    place-items: center;
    border: 1px solid rgba(165, 180, 252, 0.26);
    border-radius: 0.75rem;
    background: rgba(99, 102, 241, 0.18);
    color: #c7d2fe;
    font-size: 0.78rem;
    font-weight: 750;
}

.vpene-page-frame {
    width: 100%;
    max-width: 100rem;
    margin: 0 auto;
}

.vpene-page-heading {
    letter-spacing: -0.04em;
}

.vpene-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    border: 1px solid var(--vpene-border-strong);
    border-radius: 1.4rem;
    background:
        linear-gradient(115deg, rgba(79, 70, 229, 0.23), rgba(8, 145, 178, 0.09) 55%, rgba(15, 23, 42, 0.5)),
        rgba(15, 23, 42, 0.74);
    box-shadow: 0 25px 70px rgba(2, 6, 23, 0.25), inset 0 1px rgba(255, 255, 255, 0.05);
}

.vpene-hero::after {
    position: absolute;
    z-index: -1;
    top: -7rem;
    right: -5rem;
    width: 22rem;
    height: 22rem;
    border: 1px solid rgba(165, 180, 252, 0.18);
    border-radius: 999px;
    box-shadow: 0 0 0 3.5rem rgba(99, 102, 241, 0.035), 0 0 0 7rem rgba(34, 211, 238, 0.025);
    content: "";
}

.vpene-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border: 1px solid rgba(52, 211, 153, 0.22);
    border-radius: 999px;
    background: rgba(16, 185, 129, 0.08);
    padding: 0.38rem 0.7rem;
    color: #a7f3d0;
    font-size: 0.72rem;
    font-weight: 650;
}

.vpene-status-dot {
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 999px;
    background: var(--vpene-green);
    box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.11), 0 0 14px rgba(52, 211, 153, 0.65);
}

.vpene-stat-card,
.vpene-action-card {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--vpene-border) !important;
    background: linear-gradient(145deg, rgba(18, 27, 51, 0.88), rgba(10, 16, 32, 0.84)) !important;
    box-shadow: 0 16px 40px rgba(2, 6, 23, 0.16), inset 0 1px rgba(255, 255, 255, 0.035);
    transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.vpene-stat-card::before {
    position: absolute;
    inset: auto -2rem -4rem auto;
    width: 8rem;
    height: 8rem;
    border-radius: 999px;
    background: var(--card-glow, rgba(99, 102, 241, 0.11));
    content: "";
    filter: blur(1px);
}

.vpene-accent-indigo { --card-glow: rgba(99, 102, 241, 0.13); }
.vpene-accent-cyan { --card-glow: rgba(34, 211, 238, 0.11); }
.vpene-accent-purple { --card-glow: rgba(168, 85, 247, 0.11); }
.vpene-accent-green { --card-glow: rgba(52, 211, 153, 0.11); }
.vpene-accent-amber { --card-glow: rgba(251, 191, 36, 0.1); }
.vpene-accent-blue { --card-glow: rgba(59, 130, 246, 0.11); }

.vpene-stat-card:hover,
.vpene-action-card:hover {
    border-color: rgba(129, 140, 248, 0.34) !important;
    box-shadow: 0 22px 55px rgba(2, 6, 23, 0.26), 0 0 0 1px rgba(129, 140, 248, 0.06);
    transform: translateY(-3px);
}

.vpene-stat-label {
    color: #94a3b8;
    font-size: 0.75rem;
    font-weight: 650;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.vpene-stat-value {
    margin-top: 0.45rem;
    color: #f8fafc;
    font-size: clamp(1.9rem, 3vw, 2.5rem);
    font-weight: 750;
    letter-spacing: -0.055em;
    line-height: 1;
}

.vpene-card-icon {
    display: grid;
    width: 2.8rem;
    height: 2.8rem;
    flex: 0 0 auto;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 0.9rem;
    background: rgba(99, 102, 241, 0.14);
}

.vpene-action-arrow {
    transition: transform 180ms ease;
}

.vpene-action-card:hover .vpene-action-arrow {
    transform: translateX(4px);
}

.vpene-primary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    border: 1px solid rgba(165, 180, 252, 0.32);
    border-radius: 0.8rem;
    background: linear-gradient(135deg, #6366f1, #4f46e5 55%, #4338ca);
    box-shadow: 0 12px 28px rgba(79, 70, 229, 0.24), inset 0 1px rgba(255, 255, 255, 0.18);
    color: #fff;
    font-weight: 650;
    transition: filter 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.vpene-primary-button:hover {
    box-shadow: 0 16px 36px rgba(79, 70, 229, 0.36), inset 0 1px rgba(255, 255, 255, 0.2);
    filter: brightness(1.08);
    transform: translateY(-1px);
}

.vpene-auth-page {
    position: relative;
    isolation: isolate;
    min-height: 100vh;
    overflow-x: hidden;
}

.vpene-auth-shell {
    display: grid;
    width: min(72rem, calc(100% - 2rem));
    min-height: min(44rem, calc(100vh - 3rem));
    margin: 1.5rem auto;
    overflow: hidden;
    border: 1px solid var(--vpene-border);
    border-radius: 1.75rem;
    background: rgba(9, 14, 29, 0.76);
    box-shadow: 0 35px 100px rgba(2, 6, 23, 0.55), inset 0 1px rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(22px);
}

.vpene-auth-visual {
    position: relative;
    display: none;
    isolation: isolate;
    overflow: hidden;
    padding: clamp(2.5rem, 6vw, 5rem);
    background:
        radial-gradient(circle at 78% 24%, rgba(34, 211, 238, 0.16), transparent 18rem),
        linear-gradient(145deg, rgba(79, 70, 229, 0.24), rgba(9, 14, 29, 0.35));
}

.vpene-auth-visual::after {
    position: absolute;
    z-index: -1;
    right: -10rem;
    bottom: -11rem;
    width: 31rem;
    height: 31rem;
    border: 1px solid rgba(165, 180, 252, 0.18);
    border-radius: 50%;
    box-shadow: 0 0 0 5rem rgba(99, 102, 241, 0.045), 0 0 0 10rem rgba(34, 211, 238, 0.025);
    content: "";
}

.vpene-auth-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(1.5rem, 5vw, 4rem);
}

.vpene-auth-form {
    width: 100%;
    max-width: 24rem;
}

.vpene-auth-compact-brand {
    display: inline-flex;
    margin-bottom: 2.5rem;
}

.vpene-auth-input {
    width: 100%;
    border: 1px solid rgba(148, 163, 184, 0.18) !important;
    border-radius: 0.85rem !important;
    background: rgba(15, 23, 42, 0.82) !important;
    padding: 0.8rem 0.95rem !important;
    color: #fff !important;
    box-shadow: inset 0 1px 2px rgba(2, 6, 23, 0.22);
    transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.vpene-auth-input:hover {
    border-color: rgba(148, 163, 184, 0.32) !important;
}

.vpene-auth-input:focus {
    border-color: rgba(129, 140, 248, 0.82) !important;
    background: rgba(20, 29, 54, 0.95) !important;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.13) !important;
    outline: none;
}

.vpene-auth-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.48);
    padding: 0.5rem 0.75rem;
    color: #cbd5e1;
    font-size: 0.75rem;
    font-weight: 600;
}

.vpene-auth-chip::before {
    width: 0.4rem;
    height: 0.4rem;
    border-radius: 50%;
    background: var(--vpene-cyan);
    box-shadow: 0 0 10px rgba(34, 211, 238, 0.6);
    content: "";
}

@media (min-width: 900px) {
    .vpene-auth-shell {
        grid-template-columns: minmax(0, 1.08fr) minmax(25rem, 0.92fr);
    }

    .vpene-auth-visual {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
    }

    .vpene-auth-compact-brand {
        display: none;
    }
}

@media (max-width: 639px) {
    .vpene-auth-shell {
        width: min(100% - 1rem, 32rem);
        min-height: calc(100vh - 1rem);
        margin: 0.5rem auto;
        border-radius: 1.25rem;
    }

    .vpene-auth-panel {
        align-items: flex-start;
        padding: 2rem 1.25rem;
    }

    .vpene-hero::after {
        right: -12rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .vpene-nav-link,
    .vpene-nav-link svg,
    .vpene-stat-card,
    .vpene-action-card,
    .vpene-action-arrow,
    .vpene-primary-button {
        transition: none;
    }
}
