/* Stylesheets are linked individually in the layouts so each file is cache-busted. */

/* ==========================================================================
   NOVA core — tokens, reset, typography, buttons, forms, feedback
   ========================================================================== */

:root {
    --bg: #07070b;
    --bg-soft: #0b0b12;
    --bg-elevated: #101018;
    --surface: #12121b;
    --surface-2: #171722;
    --surface-3: #1e1e2b;
    --border: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.16);
    --text: #f6f6fa;
    --text-soft: #d3d3de;
    --muted: #9a9aae;
    --muted-2: #6f6f84;
    --accent: #ff3d5a;
    --accent-hover: #ff5c73;
    --accent-2: #8b5cf6;
    --accent-3: #f6d365;
    --success: #34d399;
    --warning: #fbbf24;
    --danger: #fb7185;
    --gradient: linear-gradient(120deg, #ff3d5a 0%, #c53bdb 55%, #8b5cf6 100%);
    --gradient-soft: linear-gradient(135deg, rgba(255, 61, 90, 0.16), rgba(139, 92, 246, 0.16));
    --shadow-lg: 0 30px 80px rgba(0, 0, 0, 0.55);
    --shadow-md: 0 18px 44px rgba(0, 0, 0, 0.42);
    --radius-lg: 22px;
    --radius: 15px;
    --radius-sm: 10px;
    --header-h: 76px;
    --container: 1380px;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
html:has(dialog[open]) { overflow: hidden; }

body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
    font-size: 15px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(1100px 520px at 82% -8%, rgba(139, 92, 246, 0.11), transparent 60%),
        radial-gradient(900px 480px at -8% 8%, rgba(255, 61, 90, 0.07), transparent 55%),
        var(--bg);
}

h1, h2, h3, h4, h5 {
    font-family: "Outfit", "Inter", sans-serif;
    font-weight: 700;
    line-height: 1.14;
    letter-spacing: -0.022em;
    margin: 0 0 0.5em;
    color: var(--text);
}
h1 { font-size: clamp(2rem, 4vw, 3.4rem); }
h2 { font-size: clamp(1.5rem, 2.4vw, 2.15rem); }
h3 { font-size: 1.18rem; }
p { margin: 0 0 1em; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; border-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
ul, ol { margin: 0; padding: 0; list-style: none; }
svg { flex-shrink: 0; }
::selection { background: rgba(255, 61, 90, 0.4); color: #fff; }

:focus-visible {
    outline: 2px solid rgba(255, 143, 162, 0.9);
    outline-offset: 3px;
    border-radius: 6px;
}

.skip-link {
    position: fixed;
    top: -60px;
    left: 16px;
    z-index: 300;
    padding: 10px 18px;
    border-radius: 10px;
    background: var(--accent);
    color: #fff;
    font-weight: 600;
    transition: top 0.2s ease;
}
.skip-link:focus { top: 12px; }

.sr-only {
    position: absolute !important;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: clamp(18px, 3vw, 40px);
}

.site-main { min-height: 60vh; padding-bottom: 40px; }
.muted { color: var(--muted); }
.break-all { word-break: break-all; }
.dot {
    width: 3px; height: 3px;
    border-radius: 50%;
    background: currentColor;
    opacity: 0.55;
    display: inline-block;
    vertical-align: middle;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.17em;
    text-transform: uppercase;
    color: #ff8fa2;
    margin-bottom: 8px;
}

.icon-star { color: var(--accent-3); fill: var(--accent-3); stroke: none; }

/* Buttons ----------------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 11px 22px;
    border: 1px solid transparent;
    border-radius: 12px;
    background: transparent;
    color: var(--text);
    font-weight: 600;
    font-size: 14px;
    line-height: 1;
    white-space: nowrap;
    transition: transform 0.22s var(--ease), background 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease, color 0.22s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary {
    background: var(--gradient);
    background-size: 160% 160%;
    color: #fff;
    box-shadow: 0 12px 26px rgba(255, 61, 90, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.24);
}
.btn-primary:hover {
    background-position: 80% 20%;
    box-shadow: 0 16px 34px rgba(197, 59, 219, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}
.btn-glass {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.12);
    color: var(--text);
    backdrop-filter: blur(10px);
}
.btn-glass:hover { background: rgba(255, 255, 255, 0.13); border-color: rgba(255, 255, 255, 0.24); }
.btn-ghost { color: var(--text-soft); }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.07); color: #fff; }
.btn-danger {
    background: rgba(251, 113, 133, 0.13);
    border-color: rgba(251, 113, 133, 0.34);
    color: #ffc2cb;
}
.btn-danger:hover { background: rgba(251, 113, 133, 0.22); }
.btn-sm { min-height: 36px; padding: 8px 15px; font-size: 13px; border-radius: 10px; }
.btn-lg { min-height: 52px; padding: 14px 28px; font-size: 15px; border-radius: 14px; }
.btn-block { width: 100%; }
.btn.is-disabled { opacity: 0.55; pointer-events: none; }

.icon-btn {
    display: inline-grid;
    place-items: center;
    width: 36px; height: 36px;
    padding: 0;
    border: 1px solid transparent;
    border-radius: 10px;
    background: transparent;
    color: var(--text-soft);
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.icon-btn:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.icon-btn--danger:hover { background: rgba(251, 113, 133, 0.15); color: #ffb3c0; }
.icon-btn--crown:hover { background: rgba(246, 211, 101, 0.14); color: var(--accent-3); }

.text-link {
    background: none;
    border: 0;
    padding: 0;
    color: #ff9db0;
    font-weight: 600;
    font-size: inherit;
    display: inline;
}
.text-link:hover { color: #ffc2cd; text-decoration: underline; text-underline-offset: 3px; }
.text-link--danger { color: #ff9aa8; }
.link-danger {
    display: flex; align-items: center; gap: 10px;
    width: 100%; padding: 11px 14px;
    background: none; border: 0; border-radius: 9px;
    color: #ff9aa8; font-size: 13.5px; text-align: left;
}
.link-danger:hover { background: rgba(251, 113, 133, 0.1); }

/* Forms ------------------------------------------------------------------- */
.field { display: flex; flex-direction: column; gap: 7px; }
.field > span:first-child { font-size: 12.5px; font-weight: 600; color: var(--text-soft); letter-spacing: 0.01em; }
.field-hint { font-size: 11.5px; color: var(--muted-2); line-height: 1.5; }
.form-error { font-size: 12px; color: #ffabb7; display: flex; align-items: center; gap: 5px; }

.input-wrap { position: relative; display: flex; align-items: center; }
.input-wrap > svg {
    position: absolute;
    left: 14px;
    color: var(--muted-2);
    pointer-events: none;
}
.input-wrap input {
    width: 100%;
    height: 46px;
    padding: 0 44px 0 43px;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: rgba(10, 10, 16, 0.75);
    color: var(--text);
    font-size: 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.input-wrap input::placeholder, .text-input::placeholder { color: var(--muted-2); }
.input-wrap input:focus, .text-input:focus, .select-input:focus {
    outline: none;
    border-color: rgba(255, 61, 90, 0.6);
    box-shadow: 0 0 0 4px rgba(255, 61, 90, 0.12);
    background: rgba(14, 14, 22, 0.95);
}
.input-wrap.has-error input { border-color: rgba(251, 113, 133, 0.65); }
.input-wrap.has-error > svg { color: #ff9aa8; }

.input-action {
    position: absolute;
    right: 7px;
    display: grid;
    place-items: center;
    width: 32px; height: 32px;
    border: 0; border-radius: 8px;
    background: transparent;
    color: var(--muted);
}
.input-action:hover { background: rgba(255, 255, 255, 0.07); color: #fff; }

.text-input, .select-input, textarea.text-input {
    width: 100%;
    min-height: 44px;
    padding: 10px 14px;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: rgba(10, 10, 16, 0.75);
    color: var(--text);
    font-size: 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
textarea.text-input { resize: vertical; min-height: 96px; }
.text-input.has-error { border-color: rgba(251, 113, 133, 0.65); }
.select-input {
    appearance: none;
    background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
    background-position: calc(100% - 18px) 19px, calc(100% - 13px) 19px;
    background-size: 5px 5px, 5px 5px;
    background-repeat: no-repeat;
    padding-right: 38px;
}
select option { background: #14141e; color: var(--text); }

.select-wrap { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.select-wrap > span { font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted-2); }
.select-wrap select {
    height: 40px;
    padding: 0 34px 0 12px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background-color: rgba(10, 10, 16, 0.7);
    color: var(--text-soft);
    font-size: 13px;
    appearance: none;
    background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
    background-position: calc(100% - 17px) 17px, calc(100% - 12px) 17px;
    background-size: 5px 5px, 5px 5px;
    background-repeat: no-repeat;
    min-width: 0;
    cursor: pointer;
}
.select-wrap select:focus { outline: none; border-color: rgba(255, 61, 90, 0.55); }

.checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 13px;
    color: var(--text-soft);
    cursor: pointer;
    line-height: 1.5;
}
.checkbox input[type="checkbox"] {
    appearance: none;
    width: 18px; height: 18px;
    margin: 2px 0 0;
    flex: 0 0 auto;
    border: 1px solid var(--border-strong);
    border-radius: 5px;
    background: rgba(10, 10, 16, 0.8);
    display: grid;
    place-items: center;
    transition: background 0.15s ease, border-color 0.15s ease;
}
.checkbox input[type="checkbox"]::after {
    content: "";
    width: 9px; height: 5px;
    border-left: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(-45deg) scale(0);
    transition: transform 0.15s ease;
    margin-top: -2px;
}
.checkbox input[type="checkbox"]:checked { background: var(--accent); border-color: var(--accent); }
.checkbox input[type="checkbox"]:checked::after { transform: rotate(-45deg) scale(1); }
.checkbox.has-error { color: #ffabb7; }

.form-stack { display: flex; flex-direction: column; gap: 17px; }
.form-grid { display: grid; gap: 16px; }
.form-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-row-between { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }

.strength-meter { display: flex; gap: 5px; margin-top: 2px; }
.strength-meter span { height: 3px; flex: 1; border-radius: 99px; background: rgba(255, 255, 255, 0.09); transition: background 0.25s ease; }
.strength-meter[data-score="1"] span:nth-child(-n+1) { background: #fb7185; }
.strength-meter[data-score="2"] span:nth-child(-n+2) { background: #fbbf24; }
.strength-meter[data-score="3"] span:nth-child(-n+3) { background: #34d399; }
.strength-meter[data-score="4"] span { background: #34d399; }

.file-drop {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 26px 18px;
    border: 1.5px dashed var(--border-strong);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
    color: var(--muted);
    text-align: center;
    transition: border-color 0.2s ease, background 0.2s ease;
    cursor: pointer;
}
.file-drop strong { font-size: 13px; color: var(--text-soft); font-weight: 600; }
.file-drop small { font-size: 11.5px; color: var(--muted-2); }
.file-drop input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.file-drop:hover, .file-drop.is-drag { border-color: rgba(255, 61, 90, 0.55); background: rgba(255, 61, 90, 0.05); }

.copy-row { display: flex; gap: 8px; }
.copy-row .text-input { font-size: 12px; }
.inline-form { display: inline-flex; margin: 0; }
.inline-form--inline { display: inline; }
.inline-form--inline .text-link { padding-left: 4px; }

/* Badges ------------------------------------------------------------------ */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    border-radius: 99px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.04em;
    line-height: 1.7;
    border: 1px solid transparent;
    white-space: nowrap;
}
.badge--muted { background: rgba(255, 255, 255, 0.06); border-color: var(--border); color: var(--muted); }
.badge--success { background: rgba(52, 211, 153, 0.12); border-color: rgba(52, 211, 153, 0.28); color: #6ee7b7; }
.badge--danger { background: rgba(251, 113, 133, 0.12); border-color: rgba(251, 113, 133, 0.3); color: #fda4af; }
.badge--info { background: rgba(96, 165, 250, 0.12); border-color: rgba(96, 165, 250, 0.28); color: #93c5fd; }
.badge--warning { background: rgba(251, 191, 36, 0.12); border-color: rgba(251, 191, 36, 0.3); color: #fcd34d; }
.badge--premium {
    background: linear-gradient(120deg, rgba(255, 61, 90, 0.2), rgba(139, 92, 246, 0.2));
    border-color: rgba(246, 211, 101, 0.38);
    color: #fde68a;
}
.plan-badge { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; padding: 2px 8px; border-radius: 99px; }
.plan-badge--premium { color: #fde68a; background: rgba(246, 211, 101, 0.12); }
.plan-badge--free { color: var(--muted); background: rgba(255, 255, 255, 0.06); }

/* Panels, notices, toasts ------------------------------------------------- */
.panel {
    background: linear-gradient(180deg, rgba(22, 22, 32, 0.86), rgba(14, 14, 21, 0.86));
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px;
    margin-bottom: 18px;
}
.panel--flush { padding: 0; overflow: hidden; }
.panel__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 16px; }
.panel__head--pad { padding: 20px 22px 0; }
.panel__head .eyebrow { margin-bottom: 4px; }
.panel__head h3 { margin: 0; font-size: 1.05rem; }
.panel__head h2 { margin: 0; }
.panel__subhead { margin: 18px 0 10px; padding-top: 14px; border-top: 1px solid var(--border); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); }
.panel-note { display: flex; align-items: flex-start; gap: 7px; margin: 12px 0 0; font-size: 12px; line-height: 1.6; color: var(--muted-2); }
.panel-note code { color: #d8b4fe; }
.panel-lead { color: var(--muted); font-size: 13.5px; }
.panel-empty { padding: 22px 0; margin: 0; color: var(--muted-2); font-size: 13.5px; text-align: center; }

.notice {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 17px;
    margin-bottom: 18px;
    border: 1px solid var(--border);
    border-radius: 12px;
    font-size: 13.5px;
    line-height: 1.6;
    color: var(--text-soft);
    background: rgba(255, 255, 255, 0.03);
}
.notice > svg { margin-top: 1px; flex-shrink: 0; }
.notice strong { color: var(--text); }
.notice--success { border-color: rgba(52, 211, 153, 0.25); background: rgba(52, 211, 153, 0.07); }
.notice--success > svg { color: #6ee7b7; }
.notice--warning { border-color: rgba(251, 191, 36, 0.28); background: rgba(251, 191, 36, 0.07); }
.notice--warning > svg { color: #fcd34d; }
.notice--error { border-color: rgba(251, 113, 133, 0.3); background: rgba(251, 113, 133, 0.08); }
.notice--error > svg { color: #fda4af; }
.notice--info { border-color: rgba(96, 165, 250, 0.24); background: rgba(96, 165, 250, 0.06); }
.notice--info > svg { color: #93c5fd; }
.notice__meta { display: block; margin-top: 5px; font-size: 11.5px; color: var(--muted); }

.toast-stack {
    position: fixed;
    right: 20px;
    bottom: 22px;
    z-index: 260;
    display: flex;
    flex-direction: column;
    gap: 9px;
    width: min(370px, calc(100vw - 32px));
    pointer-events: none;
}
.toast {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 12px;
    background: rgba(20, 20, 30, 0.96);
    border: 1px solid var(--border-strong);
    box-shadow: var(--shadow-md);
    font-size: 13px;
    color: var(--text-soft);
    backdrop-filter: blur(16px);
    pointer-events: auto;
    animation: toastIn 0.4s var(--ease);
}
.toast.is-leaving { animation: toastOut 0.3s ease forwards; }
.toast__icon { color: var(--muted); margin-top: 1px; }
.toast--success .toast__icon { color: #6ee7b7; }
.toast--error .toast__icon { color: #fda4af; }
.toast--info .toast__icon { color: #93c5fd; }
.toast__text { flex: 1; }
.toast__close { background: none; border: 0; color: var(--muted-2); padding: 0; display: grid; place-items: center; }
.toast__close:hover { color: #fff; }
@keyframes toastIn { from { opacity: 0; transform: translateY(14px) scale(0.98); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(8px); } }

/* Shared page heads ------------------------------------------------------- */
.page-head { padding: 46px 0 26px; border-bottom: 1px solid var(--border); background: linear-gradient(180deg, rgba(139, 92, 246, 0.06), transparent); }
.page-head__inner { display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; flex-wrap: wrap; }
.page-head h1 { margin: 0 0 6px; font-size: clamp(2rem, 3.4vw, 2.9rem); }
.page-head__meta { margin: 0; color: var(--muted); font-size: 13.5px; }

.view-switch { display: inline-flex; gap: 4px; padding: 4px; border: 1px solid var(--border); border-radius: 11px; background: rgba(10, 10, 16, 0.6); }
.view-switch a { display: inline-flex; align-items: center; gap: 6px; padding: 7px 13px; border-radius: 8px; font-size: 12.5px; font-weight: 600; color: var(--muted); transition: 0.2s ease; }
.view-switch a:hover { color: #fff; }
.view-switch a.is-active { background: rgba(255, 255, 255, 0.09); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05); }

.pagination { display: flex; justify-content: center; align-items: center; gap: 6px; margin: 34px 0 10px; flex-wrap: wrap; }
.page-link {
    display: inline-grid; place-items: center;
    min-width: 36px; height: 36px;
    padding: 0 10px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--muted);
    font-size: 13px; font-weight: 600;
    transition: 0.2s ease;
}
.page-link:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.page-link.is-active { background: var(--gradient); color: #fff; border-color: transparent; }
.page-link.is-disabled { opacity: 0.35; pointer-events: none; }
.page-ellipsis { color: var(--muted-2); padding: 0 3px; }

.empty-state {
    display: flex; flex-direction: column; align-items: center;
    gap: 8px; padding: 64px 24px; text-align: center;
    border: 1px dashed var(--border-strong);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.02);
    margin: 26px 0;
}
.empty-state > svg { color: var(--muted-2); margin-bottom: 6px; }
.empty-state h2 { margin: 0; font-size: 1.4rem; }
.empty-state p { color: var(--muted); max-width: 440px; margin: 0 0 10px; font-size: 13.5px; }

.table-wrap { width: 100%; overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table th {
    text-align: left;
    padding: 11px 14px;
    font-size: 10.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--muted-2);
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}
.data-table td { padding: 12px 14px; border-bottom: 1px solid rgba(255, 255, 255, 0.05); color: var(--text-soft); vertical-align: middle; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: rgba(255, 255, 255, 0.02); }
.table-empty { text-align: center; color: var(--muted-2); padding: 36px 16px !important; }
.cell-sub { display: block; font-size: 12px; color: var(--muted); }

/* Motion accents ---------------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.55s ease, transform 0.55s var(--ease); }
.reveal.is-revealed { opacity: 1; transform: none; }
.rail__arrow:disabled { opacity: 0.3; cursor: default; }
.switch-row.is-disabled { opacity: 0.45; }
.panel.is-highlighted { border-color: rgba(255, 61, 90, 0.45); box-shadow: 0 0 0 4px rgba(255, 61, 90, 0.08); }
.btn.is-busy { opacity: 0.6; pointer-events: none; }
@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; }
}
