:root {
    --primary: #343b78;
    --primary-deep: #252b5c;
    --primary-soft: #202743;
    --accent: #999bf3;
    --accent-light: #b8b9ff;
    --page-bg: #080b16;
    --surface: #111728;
    --surface-raised: #171e32;
    --text: #f2f4ff;
    --muted: #b6bfd5;
    --muted-light: #909bb5;
    --border: #303a55;
    --border-light: #252e46;
    --error: #ff929a;
    --error-bg: #32171e;
    --success: #57d6a0;
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
    color-scheme: dark;
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-synthesis: none;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    background: var(--page-bg);
}

body {
    min-width: 320px;
    min-height: 100vh;
    margin: 0;
    color: var(--text);
    background: var(--page-bg);
    -webkit-font-smoothing: antialiased;
}

button,
input {
    font: inherit;
}

button,
a,
input,
label {
    -webkit-tap-highlight-color: transparent;
}

button,
a {
    outline: none;
}

button:focus-visible,
a:focus-visible {
    box-shadow: 0 0 0 4px rgba(105, 105, 212, 0.3);
}

svg {
    display: block;
}

.auth-layout {
    display: grid;
    grid-template-columns: minmax(440px, 0.88fr) minmax(520px, 1.12fr);
    min-height: 100svh;
}

.brand-panel {
    position: relative;
    display: flex;
    min-height: 100svh;
    padding: 44px clamp(42px, 4.5vw, 76px) 34px;
    overflow: hidden;
    flex-direction: column;
    color: #ffffff;
    background: var(--primary);
    isolation: isolate;
}

.brand-panel::before {
    position: absolute;
    inset: 0;
    z-index: -2;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
    background-size: 52px 52px;
    content: "";
    mask-image: linear-gradient(to bottom, #000 0%, transparent 82%);
}

.brand-panel__glow {
    position: absolute;
    z-index: -1;
    width: 460px;
    height: 460px;
    border-radius: 50%;
    background: rgba(121, 121, 224, 0.2);
    filter: blur(90px);
    pointer-events: none;
}

.brand-panel__glow--one {
    top: -260px;
    right: -210px;
}

.brand-panel__glow--two {
    bottom: -320px;
    left: -220px;
    background: rgba(123, 176, 255, 0.12);
}

.brand {
    display: inline-flex;
    width: fit-content;
    align-items: center;
    gap: 12px;
    color: var(--primary);
    text-decoration: none;
}

.brand--light {
    color: #ffffff;
}

.brand__mark {
    display: grid;
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 13px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.brand:not(.brand--light) .brand__mark {
    border-color: rgba(39, 39, 87, 0.08);
    color: #ffffff;
    background: var(--primary);
    box-shadow: 0 8px 20px rgba(39, 39, 87, 0.18);
}

.brand__mark svg {
    width: 25px;
    height: 25px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.75;
}

.brand__text {
    display: flex;
    flex-direction: column;
    line-height: 1;
}

.brand__text strong {
    font-size: 17px;
    font-weight: 760;
    letter-spacing: 0.055em;
}

.brand__text small {
    margin-top: 6px;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.28em;
    opacity: 0.66;
}

.brand-panel__content {
    width: min(100%, 620px);
    margin: 16px 0 auto;
    padding: 0 0 32px;
}

.eyebrow {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 11px;
    font-weight: 750;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.eyebrow--light {
    color: rgba(255, 255, 255, 0.65);
}

.eyebrow__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #9d9df0;
    box-shadow: 0 0 0 5px rgba(157, 157, 240, 0.12);
}

.brand-panel h1 {
    max-width: 590px;
    margin: 24px 0 18px;
    font-size: clamp(38px, 3.6vw, 61px);
    font-weight: 720;
    letter-spacing: -0.045em;
    line-height: 1.08;
}

.brand-panel__content > p {
    max-width: 530px;
    margin: 0;
    color: rgba(255, 255, 255, 0.65);
    font-size: clamp(15px, 1.05vw, 17px);
    line-height: 1.7;
}

.product-benefits {
    display: grid;
    width: min(100%, 560px);
    margin-top: 28px;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.product-benefit {
    display: flex;
    min-width: 0;
    padding: 13px 12px;
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 13px;
    background: rgba(255, 255, 255, 0.055);
}

.product-benefit__icon {
    display: grid;
    width: 27px;
    height: 27px;
    margin-bottom: 3px;
    place-items: center;
    border-radius: 8px;
    color: #c6c6ff;
    background: rgba(255, 255, 255, 0.09);
}

.product-benefit__icon svg {
    width: 15px;
    height: 15px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.75;
}

.product-benefit strong {
    color: rgba(255, 255, 255, 0.9);
    font-size: 11px;
    font-weight: 700;
}

.product-benefit > span:last-child {
    overflow: hidden;
    max-width: 100%;
    color: rgba(255, 255, 255, 0.43);
    font-size: 9px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.analytics-showcase {
    position: relative;
    width: min(100%, 560px);
    height: clamp(285px, 34vh, 350px);
    margin: clamp(26px, 3.4vh, 38px) 0 0;
    border: 1px solid rgba(158, 158, 242, 0.22);
    border-radius: 23px;
    background: #101036;
    box-shadow:
        0 28px 65px rgba(6, 6, 29, 0.35),
        0 0 0 1px rgba(255, 255, 255, 0.025) inset,
        0 0 50px rgba(105, 105, 212, 0.12);
    isolation: isolate;
}

.analytics-showcase::before {
    position: absolute;
    top: 12%;
    right: -8%;
    z-index: -1;
    width: 55%;
    height: 76%;
    border-radius: 50%;
    background: rgba(112, 112, 221, 0.22);
    content: "";
    filter: blur(55px);
}

.analytics-showcase > picture {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    border-radius: inherit;
}

.analytics-showcase > picture img {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    object-fit: cover;
    object-position: center 48%;
}

.analytics-showcase__shade {
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: inherit;
    background:
        linear-gradient(180deg, rgba(7, 7, 30, 0.08) 35%, rgba(7, 7, 30, 0.76) 100%),
        linear-gradient(90deg, rgba(7, 7, 30, 0.16), transparent 42%);
    pointer-events: none;
}

.floating-stat {
    position: absolute;
    z-index: 3;
    display: flex;
    min-height: 50px;
    padding: 9px 10px;
    align-items: center;
    gap: 9px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 13px;
    color: #ffffff;
    background: rgba(15, 15, 54, 0.78);
    box-shadow: 0 13px 30px rgba(3, 3, 23, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.07);
    backdrop-filter: blur(16px);
}

.floating-stat--revenue {
    top: 15px;
    left: 15px;
    animation: float-card 5.4s ease-in-out infinite;
}

.floating-stat--orders {
    right: 15px;
    bottom: 53px;
    animation: float-card 6.2s ease-in-out -2.1s infinite;
}

.floating-stat__icon {
    display: grid;
    width: 31px;
    height: 31px;
    flex: 0 0 31px;
    place-items: center;
    border-radius: 9px;
    color: #d0d0ff;
    background: rgba(112, 112, 221, 0.24);
}

.floating-stat__icon--green {
    color: #a6e7c8;
    background: rgba(31, 162, 103, 0.18);
}

.floating-stat__icon svg {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.75;
}

.floating-stat__copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.floating-stat__copy small {
    color: rgba(255, 255, 255, 0.5);
    font-size: 8px;
}

.floating-stat__copy strong {
    font-size: 12px;
    font-weight: 720;
    letter-spacing: -0.015em;
    white-space: nowrap;
}

.floating-stat em {
    margin-left: 4px;
    padding: 5px 7px;
    border-radius: 999px;
    color: #a6e7c8;
    background: rgba(31, 162, 103, 0.16);
    font-size: 8px;
    font-style: normal;
    font-weight: 750;
    white-space: nowrap;
}

.showcase-caption {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 4;
    display: flex;
    min-height: 43px;
    padding: 0 15px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 0 0 23px 23px;
    color: rgba(255, 255, 255, 0.46);
    background: rgba(7, 7, 30, 0.72);
    font-size: 8px;
    backdrop-filter: blur(12px);
}

.showcase-caption span:first-child {
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-dot {
    display: block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #71d7a7;
    box-shadow: 0 0 0 4px rgba(113, 215, 167, 0.11);
}

@keyframes float-card {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.brand-panel__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: rgba(255, 255, 255, 0.36);
    font-size: 10px;
    letter-spacing: 0.02em;
}

.security-label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.5);
}

.security-label svg {
    width: 15px;
    height: 15px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.login-panel {
    position: relative;
    display: grid;
    min-height: 100svh;
    padding: clamp(34px, 5vw, 80px);
    place-items: center;
    background:
        radial-gradient(circle at 87% 9%, rgba(105, 105, 212, 0.07), transparent 24%),
        var(--page-bg);
}

.login-decoration {
    position: absolute;
    z-index: 0;
    display: grid;
    width: 56px;
    height: 56px;
    place-items: center;
    border: 1px solid rgba(39, 39, 87, 0.07);
    border-radius: 17px;
    color: var(--accent);
    background: rgba(255, 255, 255, 0.75);
    box-shadow: 0 18px 45px rgba(39, 39, 87, 0.12), inset 0 1px 0 #ffffff;
    backdrop-filter: blur(14px);
}

.login-decoration svg {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.65;
}

.login-decoration--chart {
    top: 13%;
    right: 7%;
    transform: rotate(7deg);
    animation: decoration-float 6s ease-in-out infinite;
}

.login-decoration--trend {
    bottom: 12%;
    left: 7%;
    color: #4f4fab;
    transform: rotate(-8deg);
    animation: decoration-float 7s ease-in-out -2.5s infinite;
}

.login-decoration--spark {
    top: 9%;
    left: 9%;
    width: 35px;
    height: 35px;
    border: 0;
    color: #8c8ce2;
    background: transparent;
    box-shadow: none;
    animation: sparkle-pulse 4.5s ease-in-out infinite;
}

.login-decoration--spark svg {
    width: 27px;
    height: 27px;
}

@keyframes decoration-float {
    0%, 100% { translate: 0 0; }
    50% { translate: 0 -9px; }
}

@keyframes sparkle-pulse {
    0%, 100% { opacity: 0.35; transform: scale(0.9) rotate(0deg); }
    50% { opacity: 0.8; transform: scale(1.08) rotate(8deg); }
}

.login-card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 455px;
    padding: clamp(30px, 3.3vw, 46px);
    border: 1px solid rgba(39, 39, 87, 0.07);
    border-radius: 22px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.login-card__heading {
    margin-bottom: 21px;
}

.login-card__topline {
    display: flex;
    margin-bottom: 15px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.login-card__kicker {
    display: block;
    margin: 0;
    color: var(--accent);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.17em;
}

.availability-status {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--success);
    font-size: 9px;
    font-weight: 700;
    white-space: nowrap;
}

.availability-status i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #20a66a;
    box-shadow: 0 0 0 4px rgba(32, 166, 106, 0.1);
}

.login-card h2 {
    margin: 0;
    color: var(--text);
    font-size: clamp(27px, 2.15vw, 32px);
    font-weight: 730;
    letter-spacing: -0.035em;
    line-height: 1.18;
}

.login-card__heading p {
    margin: 11px 0 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.55;
}

.product-callout {
    display: flex;
    margin-bottom: 25px;
    padding: 13px 14px;
    align-items: center;
    gap: 12px;
    border: 1px solid rgba(105, 105, 212, 0.1);
    border-radius: 12px;
    background: #f7f7fc;
}

.product-callout__icon {
    display: grid;
    width: 37px;
    height: 37px;
    flex: 0 0 37px;
    place-items: center;
    border-radius: 10px;
    color: #ffffff;
    background:
        linear-gradient(rgba(22, 22, 70, 0.48), rgba(22, 22, 70, 0.68)),
        url("../images/analytics-hero.webp") center / cover;
    box-shadow: 0 7px 16px rgba(39, 39, 87, 0.16);
}

.product-callout__icon svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.product-callout > span:last-child {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 4px;
}

.product-callout strong {
    color: var(--text);
    font-size: 11px;
    font-weight: 720;
}

.product-callout small {
    color: var(--muted);
    font-size: 9px;
    line-height: 1.45;
}

.alert {
    display: flex;
    margin: -7px 0 24px;
    padding: 13px 14px;
    align-items: flex-start;
    gap: 10px;
    border: 1px solid rgba(180, 35, 24, 0.12);
    border-radius: 11px;
    font-size: 13px;
    line-height: 1.45;
}

.alert--error {
    color: var(--error);
    background: var(--error-bg);
}

.alert__icon {
    flex: 0 0 auto;
}

.alert__icon svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-width: 1.8;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 21px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label,
.label-row label {
    color: #303040;
    font-size: 13px;
    font-weight: 680;
}

.label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.help-text {
    color: var(--muted-light);
    font-size: 10px;
}

.input-shell {
    position: relative;
    display: flex;
    height: 53px;
    align-items: center;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: #fbfbfd;
    transition: border-color 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
}

.input-shell:focus-within {
    border-color: var(--accent);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(105, 105, 212, 0.13);
}

.input-shell--error {
    border-color: rgba(180, 35, 24, 0.55);
    background: #fffdfd;
}

.input-shell__icon {
    width: 19px;
    height: 19px;
    margin-left: 16px;
    flex: 0 0 19px;
    fill: none;
    stroke: #9999aa;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
    pointer-events: none;
    transition: stroke 160ms ease;
}

.input-shell:focus-within .input-shell__icon {
    stroke: var(--accent);
}

.input-shell input {
    width: 100%;
    height: 100%;
    min-width: 0;
    padding: 0 15px 0 12px;
    border: 0;
    outline: 0;
    color: var(--text);
    background: transparent;
    font-size: 14px;
}

.input-shell input::placeholder {
    color: #a0a0af;
    opacity: 1;
}

.input-shell input:-webkit-autofill,
.input-shell input:-webkit-autofill:hover,
.input-shell input:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px #ffffff inset;
    -webkit-text-fill-color: var(--text);
}

.password-toggle {
    display: grid;
    width: 48px;
    height: 48px;
    margin-right: 2px;
    flex: 0 0 48px;
    padding: 0;
    place-items: center;
    border: 0;
    border-radius: 9px;
    color: #858597;
    background: transparent;
    cursor: pointer;
    transition: color 160ms ease, background-color 160ms ease;
}

.password-toggle:hover {
    color: var(--primary);
    background: var(--primary-soft);
}

.password-toggle svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.password-toggle .eye-closed,
.password-toggle.is-visible .eye-open {
    display: none;
}

.password-toggle.is-visible .eye-closed {
    display: block;
}

.field-error,
.caps-lock-message {
    min-height: 0;
    margin: -1px 0 0;
    color: var(--error);
    font-size: 11px;
    line-height: 1.4;
}

.caps-lock-message:empty {
    display: none;
}

.checkbox-row {
    display: flex;
    width: fit-content;
    min-height: 24px;
    margin-top: -2px;
    align-items: center;
    gap: 10px;
    color: var(--muted);
    font-size: 12px;
    cursor: pointer;
    user-select: none;
}

.checkbox-row input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
}

.checkbox-row__box {
    display: grid;
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    place-items: center;
    border: 1px solid #cfcfdd;
    border-radius: 5px;
    color: #ffffff;
    background: #ffffff;
    transition: border-color 150ms ease, background-color 150ms ease, box-shadow 150ms ease;
}

.checkbox-row__box svg {
    width: 13px;
    height: 13px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2.2;
    transform: scale(0);
    transition: transform 140ms ease;
}

.checkbox-row input:checked + .checkbox-row__box {
    border-color: var(--primary);
    background: var(--primary);
}

.checkbox-row input:checked + .checkbox-row__box svg {
    transform: scale(1);
}

.checkbox-row input:focus-visible + .checkbox-row__box {
    box-shadow: 0 0 0 4px rgba(105, 105, 212, 0.22);
}

.submit-button {
    position: relative;
    display: flex;
    width: 100%;
    height: 54px;
    margin-top: 3px;
    padding: 0 20px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 11px;
    color: #ffffff;
    background: var(--primary);
    box-shadow: 0 11px 24px rgba(39, 39, 87, 0.22);
    cursor: pointer;
    font-size: 14px;
    font-weight: 680;
    transition: transform 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.submit-button:hover {
    background: var(--primary-deep);
    box-shadow: 0 14px 28px rgba(39, 39, 87, 0.28);
    transform: translateY(-1px);
}

.submit-button:active {
    box-shadow: 0 7px 16px rgba(39, 39, 87, 0.21);
    transform: translateY(0);
}

.submit-button:disabled {
    cursor: wait;
    opacity: 0.88;
    transform: none;
}

.submit-button__arrow {
    position: absolute;
    right: 18px;
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
    transition: transform 160ms ease;
}

.submit-button:hover .submit-button__arrow {
    transform: translateX(2px);
}

.submit-button__loading {
    display: none;
    align-items: center;
    gap: 9px;
}

.submit-button.is-loading .submit-button__label,
.submit-button.is-loading .submit-button__arrow {
    display: none;
}

.submit-button.is-loading .submit-button__loading {
    display: flex;
}

.spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 650ms linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.login-card__footer {
    margin-top: 29px;
    padding-top: 23px;
    border-top: 1px solid var(--border-light);
    text-align: center;
}

.login-card__footer p {
    margin: 0;
    color: var(--muted-light);
    font-size: 11px;
}

.login-card__footer p span {
    color: var(--primary);
    font-weight: 650;
}

.secure-connection {
    display: flex;
    margin-top: 15px;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: #a0a0ae;
    font-size: 9px;
    font-weight: 650;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.secure-connection svg {
    width: 12px;
    height: 12px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.mobile-brand {
    display: none;
    width: 100%;
    max-width: 455px;
}

/* Role-aware dashboard and administrator preview mode. */
.dashboard-page {
    min-height: 100svh;
    background:
        radial-gradient(circle at 86% 7%, rgba(105, 105, 212, 0.09), transparent 24%),
        linear-gradient(180deg, #f7f7fb 0%, #f3f4f8 100%);
}

.dashboard-header {
    position: sticky;
    top: 0;
    z-index: 20;
    display: grid;
    min-height: 82px;
    padding: 14px clamp(22px, 4vw, 64px);
    align-items: center;
    grid-template-columns: 1fr auto 1fr;
    color: #ffffff;
    background: rgba(39, 39, 87, 0.98);
    box-shadow: 0 10px 35px rgba(39, 39, 87, 0.16);
    backdrop-filter: blur(16px);
}

.dashboard-header__context {
    display: flex;
    padding: 9px 13px;
    align-items: center;
    gap: 7px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.06);
}

.header-context-label {
    color: rgba(255, 255, 255, 0.48);
    font-size: 9px;
}

.dashboard-header__context strong {
    font-size: 10px;
    font-weight: 720;
}

.header-preview-chip {
    padding: 4px 6px;
    border-radius: 999px;
    color: #d7d7ff;
    background: rgba(139, 139, 235, 0.2);
    font-size: 7px;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.dashboard-header__user {
    display: flex;
    align-items: center;
    justify-self: end;
    gap: 11px;
}

.user-avatar {
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.12);
    font-size: 14px;
    font-weight: 750;
}

.user-details {
    display: flex;
    min-width: 120px;
    margin-right: 6px;
    flex-direction: column;
    gap: 4px;
}

.user-details strong {
    font-size: 12px;
}

.user-details small {
    color: rgba(255, 255, 255, 0.55);
    font-size: 9px;
}

.logout-button {
    min-height: 40px;
    padding: 0 15px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 9px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
    cursor: pointer;
    font-size: 11px;
    font-weight: 650;
    transition: background-color 150ms ease, transform 150ms ease;
}

.logout-button:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

.dashboard-workspace {
    width: min(calc(100% - 40px), 1320px);
    margin: 0 auto;
    padding: 30px 0 60px;
}

.preview-banner {
    display: flex;
    margin-bottom: 18px;
    padding: 13px 15px;
    align-items: center;
    gap: 12px;
    border: 1px solid rgba(105, 105, 212, 0.18);
    border-radius: 13px;
    color: #34346d;
    background: #eeeeff;
    box-shadow: 0 8px 24px rgba(39, 39, 87, 0.06);
}

.preview-banner__icon {
    display: grid;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    place-items: center;
    border-radius: 10px;
    color: #ffffff;
    background: var(--accent);
}

.preview-banner__icon svg,
.workspace-navigation svg,
.dashboard-metric svg,
.activity-item svg {
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.preview-banner__icon svg {
    width: 19px;
    height: 19px;
}

.preview-banner__copy {
    display: flex;
    min-width: 0;
    flex: 1;
    flex-direction: column;
    gap: 3px;
}

.preview-banner__copy strong {
    font-size: 12px;
}

.preview-banner__copy small {
    color: #65658c;
    font-size: 10px;
    line-height: 1.4;
}

.preview-banner form {
    margin-left: auto;
}

.preview-banner button {
    min-height: 36px;
    padding: 0 12px;
    border: 1px solid rgba(105, 105, 212, 0.2);
    border-radius: 8px;
    color: var(--primary);
    background: #ffffff;
    cursor: pointer;
    font-size: 9px;
    font-weight: 700;
}

.dashboard-intro {
    display: grid;
    padding: clamp(24px, 3.3vw, 38px);
    align-items: center;
    grid-template-columns: minmax(0, 0.82fr) minmax(520px, 1.18fr);
    gap: clamp(28px, 4vw, 62px);
    border: 1px solid rgba(39, 39, 87, 0.07);
    border-radius: 20px;
    background:
        radial-gradient(circle at 0% 100%, rgba(105, 105, 212, 0.08), transparent 34%),
        #ffffff;
    box-shadow: 0 18px 52px rgba(39, 39, 87, 0.08);
}

.dashboard-kicker {
    display: block;
    margin-bottom: 10px;
    color: var(--accent);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.17em;
}

.dashboard-intro h1 {
    margin: 0;
    color: var(--text);
    font-size: clamp(30px, 3vw, 43px);
    font-weight: 740;
    letter-spacing: -0.045em;
    line-height: 1.08;
}

.dashboard-intro__copy > p {
    max-width: 520px;
    margin: 13px 0 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.6;
}

.activity-live i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #27aa70;
    box-shadow: 0 0 0 4px rgba(39, 170, 112, 0.1);
}

.role-switcher {
    min-width: 0;
    padding: 15px;
    border: 1px solid var(--border-light);
    border-radius: 15px;
    background: #f8f8fb;
}

.role-switcher__label {
    display: block;
    margin: 0 0 10px 2px;
    color: #747487;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.role-switcher__options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.role-option {
    position: relative;
    display: flex;
    min-width: 0;
    min-height: 64px;
    padding: 9px 9px;
    align-items: center;
    gap: 8px;
    border: 1px solid #e4e4ed;
    border-radius: 11px;
    color: var(--text);
    background: #ffffff;
    cursor: pointer;
    text-align: left;
    transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.role-option:hover {
    border-color: rgba(105, 105, 212, 0.38);
    box-shadow: 0 9px 20px rgba(39, 39, 87, 0.08);
    transform: translateY(-1px);
}

.role-option--active {
    border-color: var(--accent);
    background: #f2f2ff;
    box-shadow: 0 0 0 3px rgba(105, 105, 212, 0.09);
}

.role-option__avatar {
    display: grid;
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    place-items: center;
    border-radius: 9px;
    color: #ffffff;
    background: var(--primary);
    font-size: 11px;
    font-weight: 750;
}

.role-option--active .role-option__avatar {
    background: var(--accent);
}

.role-option__copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 4px;
}

.role-option__copy strong {
    overflow: hidden;
    font-size: 9px;
    font-weight: 720;
    text-overflow: ellipsis;
}

.role-option__copy small {
    overflow: hidden;
    color: var(--muted-light);
    font-size: 7px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.role-option__check {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 14px;
    height: 14px;
    fill: none;
    stroke: var(--accent);
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2.2;
}

.workspace-navigation {
    display: flex;
    margin: 22px 0;
    padding: 7px;
    overflow-x: auto;
    align-items: center;
    gap: 5px;
    border: 1px solid rgba(39, 39, 87, 0.07);
    border-radius: 13px;
    background: #ffffff;
    box-shadow: 0 8px 25px rgba(39, 39, 87, 0.05);
    scrollbar-width: none;
}

.workspace-navigation::-webkit-scrollbar {
    display: none;
}

.workspace-navigation__item {
    display: flex;
    min-height: 39px;
    padding: 0 13px;
    align-items: center;
    gap: 8px;
    border-radius: 9px;
    color: #77778a;
    font-size: 10px;
    font-weight: 650;
    white-space: nowrap;
}

.workspace-navigation__item svg {
    width: 16px;
    height: 16px;
}

.workspace-navigation__item--active {
    color: #ffffff;
    background: var(--primary);
    box-shadow: 0 8px 18px rgba(39, 39, 87, 0.18);
}

.dashboard-metrics {
    display: grid;
    margin-bottom: 22px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 13px;
}

.dashboard-metric {
    min-width: 0;
    padding: 17px;
    border: 1px solid rgba(39, 39, 87, 0.07);
    border-radius: 15px;
    background: #ffffff;
    box-shadow: 0 10px 30px rgba(39, 39, 87, 0.055);
}

.dashboard-metric__topline {
    display: flex;
    margin-bottom: 17px;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.dashboard-metric__icon {
    display: grid;
    width: 35px;
    height: 35px;
    flex: 0 0 35px;
    place-items: center;
    border-radius: 10px;
    color: var(--accent);
    background: var(--primary-soft);
}

.dashboard-metric__icon svg {
    width: 18px;
    height: 18px;
}

.dashboard-metric__icon--positive {
    color: #168254;
    background: #ecf8f2;
}

.dashboard-metric__change {
    overflow: hidden;
    padding: 5px 7px;
    border-radius: 999px;
    color: #767689;
    background: #f4f4f7;
    font-size: 8px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-metric__change--positive {
    color: var(--success);
    background: #ecfdf3;
}

.dashboard-metric__label {
    display: block;
    margin-bottom: 7px;
    color: var(--muted);
    font-size: 10px;
}

.dashboard-metric > strong {
    display: block;
    overflow: hidden;
    color: var(--text);
    font-size: clamp(20px, 2vw, 27px);
    font-weight: 740;
    letter-spacing: -0.035em;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-panels {
    display: grid;
    align-items: stretch;
    grid-template-columns: minmax(0, 1.65fr) minmax(300px, 0.85fr);
    gap: 14px;
}

.dashboard-panel {
    min-width: 0;
    padding: 20px;
    border: 1px solid rgba(39, 39, 87, 0.07);
    border-radius: 17px;
    background: #ffffff;
    box-shadow: 0 12px 34px rgba(39, 39, 87, 0.055);
}

.performance-panel {
    grid-row: span 2;
}

.dashboard-panel__heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.dashboard-panel__heading > div {
    min-width: 0;
}

.dashboard-panel__heading span:first-child {
    display: block;
    margin-bottom: 7px;
    color: var(--accent);
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 0.14em;
}

.dashboard-panel__heading h2 {
    margin: 0;
    color: var(--text);
    font-size: 16px;
    letter-spacing: -0.025em;
}

.dashboard-panel__menu {
    color: #a5a5b2;
    font-size: 16px;
    letter-spacing: 0.12em;
}

.performance-summary {
    display: flex;
    margin-top: 23px;
    align-items: baseline;
    gap: 12px;
}

.performance-summary strong {
    color: var(--text);
    font-size: clamp(25px, 2.7vw, 36px);
    letter-spacing: -0.045em;
}

.performance-summary span {
    color: var(--success);
    font-size: 9px;
    font-weight: 700;
}

.performance-chart {
    position: relative;
    height: 255px;
    margin-top: 20px;
    overflow: hidden;
}

.performance-chart__grid {
    position: absolute;
    inset: 0 0 25px;
    background-image: linear-gradient(#ededf4 1px, transparent 1px);
    background-size: 100% 25%;
}

.performance-chart > svg {
    position: relative;
    width: 100%;
    height: calc(100% - 25px);
    overflow: visible;
}

.performance-chart__area {
    fill: url(#dashboard-area);
}

.performance-chart__line {
    fill: none;
    stroke: var(--accent);
    stroke-linecap: round;
    stroke-width: 3;
    vector-effect: non-scaling-stroke;
}

.performance-chart__labels {
    display: flex;
    height: 25px;
    align-items: flex-end;
    justify-content: space-between;
    color: #a0a0ae;
    font-size: 8px;
}

.capability-list {
    display: flex;
    margin-top: 17px;
    flex-direction: column;
    gap: 9px;
}

.capability-item {
    display: flex;
    min-height: 42px;
    padding: 8px 9px;
    align-items: center;
    gap: 9px;
    border-radius: 9px;
    color: #555569;
    background: #f8f8fa;
    font-size: 9px;
    line-height: 1.35;
}

.capability-item__status {
    display: grid;
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    place-items: center;
    border-radius: 7px;
}

.capability-item__status svg {
    width: 14px;
    height: 14px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2.2;
}

.capability-item--allowed .capability-item__status {
    color: var(--success);
    background: #eaf8f1;
}

.capability-item--blocked {
    color: #9292a0;
}

.capability-item--blocked .capability-item__status {
    color: #a5a5b0;
    background: #ededf1;
}

.activity-live {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--success);
    font-size: 8px;
    font-weight: 700;
}

.activity-list {
    display: flex;
    margin-top: 16px;
    flex-direction: column;
    gap: 10px;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 9px;
}

.activity-item__icon {
    display: grid;
    width: 31px;
    height: 31px;
    flex: 0 0 31px;
    place-items: center;
    border-radius: 9px;
    color: var(--accent);
    background: var(--primary-soft);
}

.activity-item__icon svg {
    width: 15px;
    height: 15px;
}

.activity-item__copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.activity-item__copy strong {
    overflow: hidden;
    color: #3e3e50;
    font-size: 9px;
    font-weight: 680;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.activity-item__copy small {
    color: #9696a5;
    font-size: 8px;
}

@media (max-width: 1100px) {
    .dashboard-intro {
        grid-template-columns: 1fr;
    }

    .dashboard-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .dashboard-header {
        grid-template-columns: 1fr auto;
    }

    .dashboard-header__context {
        display: none;
    }

    .dashboard-panels {
        grid-template-columns: 1fr;
    }

    .performance-panel {
        grid-row: auto;
    }
}

@media (max-width: 680px) {
    .dashboard-workspace {
        width: min(calc(100% - 28px), 1320px);
        padding-top: 18px;
    }

    .preview-banner {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .preview-banner form {
        width: 100%;
        margin-left: 48px;
    }

    .preview-banner button {
        width: 100%;
    }

    .dashboard-intro {
        padding: 22px 18px;
        gap: 24px;
    }

    .role-switcher__options {
        grid-template-columns: 1fr;
    }

    .role-option {
        min-height: 56px;
    }

    .dashboard-metrics {
        gap: 10px;
    }

    .dashboard-metric {
        padding: 14px;
    }

    .dashboard-metric__change {
        max-width: 82px;
    }

    .dashboard-panel {
        padding: 17px;
    }

    .performance-chart {
        height: 210px;
    }
}

@media (max-width: 430px) {
    .dashboard-metrics {
        grid-template-columns: 1fr;
    }

    .performance-summary {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }
}

@media (max-width: 1080px) {
    .auth-layout {
        grid-template-columns: minmax(410px, 0.84fr) minmax(480px, 1.16fr);
    }

    .brand-panel {
        padding-right: 40px;
        padding-left: 40px;
    }

    .brand-panel h1 {
        font-size: 43px;
    }
}

@media (max-height: 820px) and (min-width: 861px) {
    .brand-panel,
    .login-panel {
        min-height: 820px;
    }

    .analytics-showcase {
        height: 250px;
        margin-top: 22px;
    }

    .brand-panel__content {
        margin-top: 16px;
        padding-top: 0;
        padding-bottom: 24px;
    }

    .product-benefits {
        margin-top: 20px;
    }

    .product-benefit {
        padding-top: 10px;
        padding-bottom: 10px;
    }

    .product-benefit > span:last-child {
        display: none;
    }
}

@media (max-width: 860px) {
    .auth-layout {
        display: block;
        min-height: 100svh;
    }

    .brand-panel {
        display: none;
    }

    .login-panel {
        display: flex;
        min-height: 100svh;
        padding: 28px 24px 36px;
        align-items: center;
        flex-direction: column;
        justify-content: center;
        background:
            radial-gradient(circle at 85% 0%, rgba(105, 105, 212, 0.1), transparent 34%),
            var(--page-bg);
    }

    .mobile-brand {
        display: block;
        position: relative;
        z-index: 1;
        width: min(455px, calc(100vw - 48px));
        min-width: 0;
        margin-bottom: 28px;
    }

    .login-decoration {
        display: none;
    }

    .login-card {
        width: min(455px, calc(100vw - 48px));
        min-width: 0;
        padding: 38px;
    }
}

@media (max-width: 560px) {
    .login-panel {
        padding: 24px 18px 28px;
        justify-content: flex-start;
    }

    .mobile-brand {
        width: min(455px, calc(100vw - 36px));
        margin: 4px 0 23px;
    }

    .brand__mark {
        width: 42px;
        height: 42px;
        flex-basis: 42px;
        border-radius: 12px;
    }

    .login-card {
        width: min(455px, calc(100vw - 36px));
        padding: 31px 23px 27px;
        border-radius: 18px;
        box-shadow: 0 18px 48px rgba(39, 39, 87, 0.1);
    }

    .login-card__heading {
        margin-bottom: 26px;
    }

    .login-card__topline {
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
    }

    .login-card h2 {
        font-size: 27px;
    }

    .availability-status {
        font-size: 8px;
    }

    .product-callout small,
    .login-card__heading p {
        overflow-wrap: anywhere;
    }

    .help-text {
        display: none;
    }

    .dashboard-header {
        padding: 14px 18px;
    }

    .dashboard-header .brand__text,
    .user-details {
        display: none;
    }

    .dashboard-header__user {
        gap: 8px;
    }

    .logout-button {
        padding: 0 11px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* -------------------------------------------------------------------------- */
/* Global midnight theme                                                       */
/* -------------------------------------------------------------------------- */

.auth-page {
    color: var(--text);
    background: var(--page-bg);
}

.auth-page .brand-panel {
    border-right: 1px solid rgba(153, 155, 243, 0.13);
    background:
        radial-gradient(circle at 88% 7%, rgba(86, 91, 190, 0.24), transparent 27rem),
        linear-gradient(145deg, #070a15 0%, #0c1124 58%, #111633 100%);
}

.auth-page .brand-panel__glow--one {
    background: rgba(107, 109, 224, 0.18);
}

.auth-page .brand-panel__glow--two {
    background: rgba(64, 125, 208, 0.1);
}

.auth-page .login-panel {
    background:
        radial-gradient(circle at 86% 8%, rgba(105, 108, 219, 0.12), transparent 25rem),
        radial-gradient(circle at 10% 88%, rgba(42, 87, 151, 0.08), transparent 22rem),
        var(--page-bg);
}

.auth-page .login-decoration {
    border-color: rgba(154, 157, 228, 0.18);
    color: var(--accent-light);
    background: rgba(18, 24, 43, 0.78);
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.auth-page .login-decoration--trend {
    color: #8caeff;
}

.auth-page .login-card {
    border-color: rgba(154, 157, 228, 0.16);
    background:
        linear-gradient(145deg, rgba(22, 29, 49, 0.97), rgba(15, 21, 37, 0.99));
    box-shadow: 0 28px 78px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.035);
}

.auth-page .login-card__kicker,
.auth-page .login-card__footer p span {
    color: var(--accent-light);
}

.auth-page .availability-status {
    color: var(--success);
}

.auth-page .product-callout {
    border-color: rgba(153, 155, 243, 0.18);
    background: #171e32;
}

.auth-page .alert--error {
    border-color: rgba(255, 141, 150, 0.28);
    color: #ffb0b6;
    background: var(--error-bg);
}

.auth-page .form-group label,
.auth-page .label-row label {
    color: var(--text);
}

.auth-page .input-shell {
    border-color: var(--border);
    background: #0c1221;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.22);
}

.auth-page .input-shell:hover {
    border-color: #465373;
}

.auth-page .input-shell:focus-within {
    border-color: var(--accent);
    background: #10182a;
    box-shadow: 0 0 0 4px rgba(153, 155, 243, 0.16);
}

.auth-page .input-shell--error {
    border-color: rgba(255, 141, 150, 0.62);
    background: #211219;
}

.auth-page .input-shell__icon {
    stroke: #7f8ba8;
}

.auth-page .input-shell input::placeholder {
    color: #77829d;
}

.auth-page .input-shell input:-webkit-autofill,
.auth-page .input-shell input:-webkit-autofill:hover,
.auth-page .input-shell input:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px #10182a inset;
    -webkit-text-fill-color: var(--text);
    caret-color: var(--text);
}

.auth-page .password-toggle {
    color: #98a2ba;
}

.auth-page .password-toggle:hover {
    color: var(--accent-light);
    background: var(--primary-soft);
}

.auth-page .checkbox-row__box {
    border-color: #46516d;
    color: #fff;
    background: #0c1221;
}

.auth-page .checkbox-row input:checked + .checkbox-row__box {
    border-color: var(--accent);
    background: #555aa9;
}

.auth-page .submit-button {
    border: 1px solid rgba(179, 181, 255, 0.18);
    background: linear-gradient(135deg, #3b4285, #30366f);
    box-shadow: 0 13px 30px rgba(0, 0, 0, 0.35);
}

.auth-page .submit-button:hover {
    background: linear-gradient(135deg, #484f99, #393f80);
    box-shadow: 0 16px 34px rgba(0, 0, 0, 0.42);
}

.auth-page .login-card__footer {
    border-top-color: var(--border-light);
}

.auth-page .secure-connection {
    color: var(--muted-light);
}

.auth-page .mobile-brand .brand {
    color: var(--text);
}

.auth-page .mobile-brand .brand__mark {
    border-color: rgba(153, 155, 243, 0.22);
    background: #252c5e;
    box-shadow: 0 9px 24px rgba(0, 0, 0, 0.32);
}

@media (max-width: 860px) {
    .auth-page .login-panel {
        background:
            radial-gradient(circle at 86% 0%, rgba(105, 108, 219, 0.15), transparent 24rem),
            var(--page-bg);
    }
}
