/* ==========================================================================
   SubMela design system — plain CSS, no build step (cPanel friendly).
   Fonts → tokens → base → header/footer → components → homepage → responsive.
   Status is never colour-only: every badge/notice carries text or an icon.
   Fonts are self-hosted (SIL OFL, see /fonts/LICENSE.txt), so the CSP stays 'self'.
   ========================================================================== */

/* ---------- Fonts ---------- */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/inter-400.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/inter-500.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/inter-600.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 200 800; font-display: swap; src: url("../fonts/manrope-var.woff2") format("woff2-variations"), url("../fonts/manrope-var.woff2") format("woff2"); }

/* ---------- Tokens ---------- */
:root {
    --font: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
    --display: "Manrope", "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
    --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;

    --bg: #f6f7fc;
    --bg-2: #eef0f8;
    --surface: #ffffff;
    --surface-2: #f9fafe;
    --ink: #0e1330;
    --ink-2: #383e5e;
    --muted: #636a8a;
    --line: #e6e8f2;
    --line-2: #d3d7e7;
    --lav: #f6f5ff;
    --lav-2: #ecebff;

    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --primary-ink: #ffffff;
    --primary-soft: #efefff;
    --primary-soft-ink: #3730a3;
    --grad: linear-gradient(135deg, #5b5cf6 0%, #5b3cf0 52%, #8b3dff 100%);
    --grad-hover: linear-gradient(135deg, #4f50ea 0%, #4f30e2 52%, #7d2ff2 100%);

    --ok: #157347;      --ok-soft: #e4f6ec;
    --wait: #8a5a00;    --wait-soft: #fff4dc;
    --bad: #b42318;     --bad-soft: #fdeaea;
    --info: #1c5f9e;    --info-soft: #e6f1fb;

    --r-sm: 8px; --r: 12px; --r-lg: 16px; --r-xl: 22px; --r-pill: 999px;
    --shadow-xs: 0 1px 2px rgba(16, 19, 48, .05);
    --shadow-sm: 0 1px 2px rgba(16, 19, 48, .04), 0 2px 8px -2px rgba(16, 19, 48, .06);
    --shadow: 0 10px 30px -12px rgba(28, 25, 85, .18), 0 2px 6px -1px rgba(16, 19, 48, .05);
    --shadow-lg: 0 28px 60px -24px rgba(60, 48, 200, .32), 0 10px 24px -14px rgba(16, 19, 48, .12);
    --shadow-primary: 0 8px 20px -8px rgba(79, 70, 229, .6);
    --focus: 0 0 0 3px rgba(99, 102, 241, .35);

    --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px; --s-6: 32px; --s-7: 48px; --s-8: 64px;
    --wrap: 1320px;
    --gutter: 24px;
    --header-h: 72px;
    --control: 44px;
}
@media (prefers-color-scheme: dark) {
    :root {
        --bg: #0b0d1c; --bg-2: #161a33; --surface: #12152b; --surface-2: #181c36;
        --ink: #eef0fb; --ink-2: #c8cce5; --muted: #959cbe; --line: #252a49; --line-2: #353b62;
        --lav: #0f1229; --lav-2: #1a1e3d;
        --primary: #8b85ff; --primary-hover: #a5a0ff; --primary-ink: #0b0d1c; --primary-soft: #23264b; --primary-soft-ink: #cfccff;
        --ok: #5fd39a; --ok-soft: #12301f; --wait: #f5c35a; --wait-soft: #332810; --bad: #ff8a80; --bad-soft: #3b1715; --info: #7cc0ff; --info-soft: #152840;
        --shadow-xs: 0 1px 2px rgba(0, 0, 0, .4); --shadow-sm: 0 1px 3px rgba(0, 0, 0, .45);
        --shadow: 0 10px 30px -12px rgba(0, 0, 0, .6); --shadow-lg: 0 28px 60px -24px rgba(0, 0, 0, .75);
    }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.55; color: var(--ink); background: var(--bg); min-height: 100vh; display: flex; flex-direction: column; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
body.is-home { background: var(--surface); }
main { flex: 1; }
a { color: var(--primary); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--primary-hover); }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: var(--r-sm); }
img, svg { max-width: 100%; display: inline-block; vertical-align: middle; }
h1, h2, h3, h4 { font-family: var(--display); line-height: 1.2; margin: 0 0 var(--s-3); font-weight: 800; letter-spacing: -0.02em; }
h3, h4 { font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: clamp(1.55rem, 1.2rem + 1.2vw, 2.1rem); }
h2 { font-size: 1.3rem; }
h3 { font-size: 1.05rem; }
b, strong { font-weight: 600; }
p { margin: 0 0 var(--s-3); }
p:last-child { margin-bottom: 0; }
ul, ol { margin: 0 0 var(--s-3); padding-left: 1.2em; }
code { font-family: var(--mono); font-size: .9em; background: var(--bg-2); padding: 1px 5px; border-radius: 4px; }
hr { border: 0; border-top: 1px solid var(--line); margin: var(--s-5) 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); width: 100%; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 50; background: var(--surface); padding: var(--s-2) var(--s-3); border-radius: var(--r-sm); box-shadow: var(--shadow); }
.skip:focus { left: var(--s-4); }
.icon { width: 1.25em; height: 1.25em; stroke: currentColor; stroke-width: 1.8; fill: none; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }
.tiny { font-size: .8rem; }
.strong { font-weight: 600; }
.inline { display: inline; }
.nowrap { white-space: nowrap; }
.mono { font-family: var(--mono); font-size: .9em; overflow-wrap: anywhere; }
.row { display: flex; gap: var(--s-3); align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.stack { display: flex; flex-direction: column; gap: var(--s-3); }
.mt-0 { margin-top: 0 !important; } .mt-4 { margin-top: var(--s-4); } .mt-5 { margin-top: var(--s-5); } .mt-6 { margin-top: var(--s-6); }
.mb-0 { margin-bottom: 0 !important; } .mb-4 { margin-bottom: var(--s-4); } .mb-5 { margin-bottom: var(--s-5); }
.text-right { text-align: right; }
.text-ok { color: var(--ok) !important; } .text-bad { color: var(--bad) !important; } .ink-2 { color: var(--ink-2); }
.row.top { align-items: flex-start; } .grow { flex: 1; min-width: 0; }
.title-mono { font-size: 1.3rem; } .w-narrow { max-width: 110px; }
.code-input { font-size: 1.4rem; letter-spacing: .3em; text-align: center; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Brand ---------- */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); flex: none; }
.brand:hover { color: var(--ink); }
.brand-mark { flex: none; filter: drop-shadow(0 6px 10px rgba(91, 60, 240, .28)); transition: transform .25s ease; }
.brand:hover .brand-mark { transform: rotate(-6deg) scale(1.04); }
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-word { font-family: var(--display); font-weight: 800; font-size: 1.42rem; letter-spacing: -0.04em; color: var(--ink); white-space: nowrap; }
.brand-accent { background: linear-gradient(95deg, #4f46e5 0%, #6d3df2 55%, #9333ea 100%); -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: 1px; }
.brand small { font-family: var(--font); font-weight: 600; font-size: .7rem; color: var(--muted); letter-spacing: .06em; text-transform: uppercase; margin-left: 4px; vertical-align: middle; }
.brand-tag { font-size: .74rem; color: var(--muted); font-weight: 500; margin-top: 6px; letter-spacing: 0; white-space: nowrap; }
@media (prefers-color-scheme: dark) { .brand-accent { background-image: linear-gradient(95deg, #a5b4fc, #c4b5fd); } }

/* ---------- Public header ---------- */
.site-header { position: sticky; top: 0; z-index: 30; background: color-mix(in srgb, var(--surface) 88%, transparent); -webkit-backdrop-filter: saturate(1.6) blur(14px); backdrop-filter: saturate(1.6) blur(14px); border-bottom: 1px solid var(--line); }
.header-row { display: flex; align-items: center; gap: 20px; min-height: var(--header-h); position: relative; }
.header-search { flex: 1; max-width: 520px; margin: 0 auto; }
.header-search form { display: flex; align-items: center; gap: var(--s-2); background: var(--bg-2); border: 1px solid transparent; border-radius: var(--r-pill); padding: 0 var(--s-2) 0 var(--s-4); min-height: 44px; transition: border-color .15s, background .15s, box-shadow .15s; }
.header-search form:focus-within { border-color: var(--primary); background: var(--surface); box-shadow: 0 0 0 4px rgba(99, 102, 241, .12); }
.header-search input { flex: 1; border: 0; background: transparent; min-height: 42px; padding: 0; font: inherit; color: var(--ink); min-width: 0; }
.header-search input:focus { outline: none; box-shadow: none; }
.header-search button { border: 0; background: transparent; color: var(--muted); min-width: 36px; min-height: 36px; display: inline-grid; place-items: center; border-radius: var(--r-pill); cursor: pointer; }
.header-search button:hover { color: var(--ink); background: var(--surface-2); }
.top-nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav-link { display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 14px; border-radius: 11px; color: var(--ink-2); font-weight: 600; font-size: .95rem; text-decoration: none; white-space: nowrap; cursor: pointer; transition: background .15s, color .15s; }
.nav-link .icon { color: var(--muted); transition: color .15s; }
.nav-link:hover, .dropdown[open] > summary.nav-link { background: var(--primary-soft); color: var(--primary-soft-ink); }
.nav-link:hover .icon, .dropdown[open] > summary.nav-link .icon { color: var(--primary); }
.nav-link[aria-current="page"] { color: var(--primary); background: var(--primary-soft); }
.nav-link[aria-current="page"] .icon { color: var(--primary); }
.caret { width: 16px; height: 16px; transition: transform .2s; }
.dropdown[open] .caret { transform: rotate(180deg); }
.nav-sep { width: 1px; height: 26px; background: var(--line); margin: 0 8px; }
.top-nav .button { margin-left: 4px; }
.nav-balance { background: var(--primary-soft); color: var(--primary-soft-ink); border-radius: var(--r-pill); padding: 2px 9px; font-size: .78rem; font-weight: 600; }
.header-row > .header-cta { display: none; }
.menu-toggle { display: none; border: 1px solid var(--line); background: var(--surface); border-radius: 12px; width: 44px; height: 44px; place-items: center; cursor: pointer; color: var(--ink); box-shadow: var(--shadow-xs); }
.menu-toggle:hover { border-color: var(--line-2); }
.dropdown, .user-menu { position: relative; }
.dropdown > summary { list-style: none; }
.dropdown > summary::-webkit-details-marker { display: none; }
.dropdown .menu { position: absolute; left: 0; top: calc(100% + 10px); background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lg); min-width: 240px; padding: 8px; z-index: 40; animation: menu-in .16s ease-out; }
@keyframes menu-in { from { opacity: 0; transform: translateY(-6px); } }
.mega .menu { left: auto; right: 0; width: min(580px, calc(100vw - 32px)); padding: 14px; }
.menu-title { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 600; margin: 2px 8px 10px; }
.mega-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.mega-grid a { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 14px; text-decoration: none; color: var(--ink); transition: background .15s; }
.mega-grid a:hover, .mega-grid a[aria-current="page"] { background: var(--lav); color: var(--ink); }
.mega-icon { width: 40px; height: 40px; border-radius: 12px; display: inline-grid; place-items: center; flex: none; color: #fff; }
.mega-text { display: flex; flex-direction: column; min-width: 0; gap: 1px; }
.mega-name { font-weight: 600; font-size: .95rem; }
.mega-desc { font-size: .82rem; color: var(--muted); }
.mega-all { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 10px; padding: 12px; border-top: 1px solid var(--line); font-weight: 600; font-size: .92rem; text-decoration: none; color: var(--primary); }
.mega-all:hover { gap: 10px; }
.user-menu > summary { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 12px 0 5px; border-radius: var(--r-pill); border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: .92rem; cursor: pointer; color: var(--ink); box-shadow: var(--shadow-xs); }
.user-menu > summary:hover { border-color: var(--line-2); }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--grad); color: #fff; display: inline-grid; place-items: center; font-family: var(--display); font-size: .85rem; font-weight: 800; }
.user-menu .menu { right: 0; left: auto; min-width: 236px; }
.user-menu .menu a, .user-menu .menu .link-button { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 10px 12px; border-radius: 10px; color: var(--ink); text-decoration: none; background: none; border: 0; font: inherit; font-size: .95rem; cursor: pointer; }
.user-menu .menu a .icon, .user-menu .menu .link-button .icon { color: var(--muted); }
.user-menu .menu a:hover, .user-menu .menu .link-button:hover { background: var(--lav); }
.user-menu .menu hr { margin: 6px 0; }
.dev-banner { margin: 0; padding: 8px 16px; text-align: center; background: var(--wait-soft); color: var(--wait); font-size: .9rem; font-weight: 500; }
.page { padding: var(--s-5) var(--gutter) var(--s-7); }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s-4); flex-wrap: wrap; margin-bottom: var(--s-5); }
.page-head h1 { margin: 0; }
.page-head .lead { color: var(--muted); margin: 4px 0 0; }
.breadcrumb { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: .9rem; text-decoration: none; margin-bottom: var(--s-3); }
.breadcrumb:hover { color: var(--ink); }

/* ---------- Footer ---------- */
.site-footer { margin-top: auto; border-top: 1px solid var(--line); background: linear-gradient(180deg, var(--surface-2), var(--lav)); color: var(--muted); font-size: .93rem; padding: 56px 0 28px; }
.footer-grid { display: grid; gap: 40px; grid-template-columns: 1.5fr 1fr 1fr 1.25fr; }
.footer-brand > p { margin-top: 18px; max-width: 360px; line-height: 1.65; }
.footer-pay { display: inline-flex !important; align-items: center; gap: 8px; padding: 8px 14px; border-radius: var(--r-pill); background: var(--surface); border: 1px solid var(--line); color: var(--ink-2); font-size: .84rem; font-weight: 500; box-shadow: var(--shadow-xs); }
.footer-pay .icon { color: var(--ok); }
.site-footer h4 { font-size: .98rem; color: var(--ink); margin: 6px 0 16px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 11px; }
.site-footer a { color: var(--ink-2); text-decoration: none; transition: color .15s; }
.site-footer a:hover { color: var(--primary); }
.footer-contact li { display: flex; gap: 12px; align-items: flex-start; }
.fc-icon { width: 32px; height: 32px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); color: var(--primary); display: inline-grid; place-items: center; flex: none; }
.footer-contact li > span:last-child { padding-top: 5px; overflow-wrap: anywhere; min-width: 0; }
.footer-bottom { border-top: 1px solid var(--line); margin-top: 44px; padding-top: 22px; display: flex; justify-content: space-between; gap: var(--s-3); flex-wrap: wrap; font-size: .88rem; }

/* ---------- Buttons ---------- */
.button, button.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: var(--control); padding: 0 20px; border-radius: 12px; background: var(--grad); color: #fff; border: 1px solid transparent; font: inherit; font-weight: 600; font-size: .95rem; text-decoration: none; cursor: pointer; transition: transform .15s ease, box-shadow .2s ease, background .2s, border-color .15s, color .15s; white-space: nowrap; box-shadow: var(--shadow-primary), inset 0 1px 0 rgba(255, 255, 255, .18); }
.button:hover { background: var(--grad-hover); color: #fff; transform: translateY(-1px); box-shadow: 0 12px 24px -10px rgba(79, 70, 229, .72), inset 0 1px 0 rgba(255, 255, 255, .18); }
.button:active { transform: translateY(0); }
.button.secondary { background: var(--surface); color: var(--ink); border-color: var(--line-2); box-shadow: var(--shadow-xs); }
.button.secondary:hover { background: var(--surface); color: var(--primary); border-color: color-mix(in srgb, var(--primary) 45%, var(--line-2)); box-shadow: var(--shadow-sm); }
.button.soft { background: var(--primary-soft); color: var(--primary-soft-ink); box-shadow: none; }
.button.soft:hover { background: var(--primary); color: #fff; }
.button.danger { background: var(--bad); color: #fff; box-shadow: none; }
.button.danger:hover { background: var(--bad); filter: brightness(1.08); }
.button.ghost { background: transparent; color: var(--primary); box-shadow: none; }
.button.ghost:hover { background: var(--primary-soft); color: var(--primary-soft-ink); }
.button.small { min-height: 38px; padding: 0 14px; font-size: .9rem; border-radius: 10px; }
.button.lg { min-height: 52px; padding: 0 26px; font-size: 1rem; border-radius: 14px; }
.button.block { width: 100%; }
.button[disabled], .button[aria-disabled="true"] { opacity: .55; cursor: not-allowed; pointer-events: none; }
.button.is-busy::before { content: ""; width: 14px; height: 14px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.link-button { background: none; border: 0; color: var(--primary); font: inherit; cursor: pointer; padding: 0; min-height: 0; text-decoration: underline; text-underline-offset: 2px; }
.actions { display: flex; gap: var(--s-2); flex-wrap: wrap; align-items: center; }
.arrow-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; text-decoration: none; transition: gap .15s; white-space: nowrap; }
.arrow-link:hover { gap: 10px; }

/* ---------- Forms ---------- */
input, select, textarea { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line-2); border-radius: 10px; min-height: var(--control); padding: 10px 12px; width: 100%; transition: border-color .15s, box-shadow .15s; }
textarea { min-height: 96px; resize: vertical; }
select { 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) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: var(--focus); }
input[type="checkbox"], input[type="radio"] { width: 18px; height: 18px; min-height: 0; padding: 0; margin: 0; accent-color: var(--primary); vertical-align: middle; }
input[aria-invalid="true"], .has-error input, .has-error select, .has-error textarea { border-color: var(--bad); }
label { display: block; font-weight: 600; font-size: .95rem; margin-bottom: 6px; }
.field { margin-bottom: var(--s-4); }
.field .help { margin: 6px 0 0; font-size: .85rem; color: var(--muted); }
.field .error { margin: 6px 0 0; font-size: .85rem; color: var(--bad); font-weight: 500; }
.field .error[hidden] { display: none; }
.check { display: flex; align-items: flex-start; gap: 10px; margin: var(--s-3) 0; }
.check label { display: inline; font-weight: 400; margin: 0; }
.check input { margin-top: 3px; flex: none; }
.password-wrap { position: relative; }
.password-wrap input { padding-right: 46px; }
.password-toggle { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 34px; height: 34px; border: 0; background: transparent; color: var(--muted); border-radius: var(--r-sm); display: inline-grid; place-items: center; cursor: pointer; }
.password-toggle:hover { background: var(--bg-2); color: var(--ink); }
.password-toggle .icon:last-child { display: none; }
.password-toggle[aria-pressed="true"] .icon:first-child { display: none; }
.password-toggle[aria-pressed="true"] .icon:last-child { display: inline-block; }
.input-group { display: flex; gap: var(--s-2); }
.input-group > * { flex: 1; }
.input-group > .button { flex: none; }
.form-row { display: grid; gap: var(--s-3); grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
fieldset { border: 1px solid var(--line); border-radius: var(--r); margin: 0 0 var(--s-4); padding: var(--s-3) var(--s-4); }
legend { font-weight: 600; padding: 0 6px; }
.form-actions { display: flex; gap: var(--s-2); align-items: center; flex-wrap: wrap; margin-top: var(--s-4); }

/* ---------- Surfaces ---------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--s-5); box-shadow: var(--shadow-sm); }
.panel + .panel { margin-top: var(--s-4); }
.panel h2:first-child, .panel h3:first-child { margin-top: 0; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); flex-wrap: wrap; margin-bottom: var(--s-4); }
.panel-head h2, .panel-head h3 { margin: 0; }
.narrow { max-width: 480px; }
.wide { max-width: 720px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--s-4); box-shadow: var(--shadow-sm); }
.section { margin: var(--s-6) 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--s-3); flex-wrap: wrap; margin-bottom: var(--s-4); }
.section-head h2 { margin: 0; }
.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); }
.grid-2 { display: grid; gap: var(--s-4); grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.split { display: grid; gap: var(--s-5); grid-template-columns: minmax(0, 1fr) 360px; align-items: start; }
.sticky { position: sticky; top: 84px; }

/* ---------- Notices & badges ---------- */
.notice { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--r); margin: 0 0 var(--s-4); border: 1px solid transparent; font-size: .95rem; }
.notice .icon { margin-top: 2px; }
.notice p { margin: 0; }
.notice.success { background: var(--ok-soft); color: var(--ok); border-color: color-mix(in srgb, var(--ok) 25%, transparent); }
.notice.error { background: var(--bad-soft); color: var(--bad); border-color: color-mix(in srgb, var(--bad) 25%, transparent); }
.notice.pending, .notice.warning { background: var(--wait-soft); color: var(--wait); border-color: color-mix(in srgb, var(--wait) 25%, transparent); }
.notice.info { background: var(--info-soft); color: var(--info); border-color: color-mix(in srgb, var(--info) 25%, transparent); }
.notice a { color: inherit; font-weight: 600; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--r-pill); font-size: .8rem; font-weight: 600; line-height: 1.4; white-space: nowrap; border: 1px solid transparent; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .9; }
.badge.tone-ok { background: var(--ok-soft); color: var(--ok); }
.badge.tone-wait { background: var(--wait-soft); color: var(--wait); }
.badge.tone-bad { background: var(--bad-soft); color: var(--bad); }
.badge.tone-info { background: var(--info-soft); color: var(--info); }
.badge.tone-muted { background: var(--bg-2); color: var(--muted); }
.badge.plain::before { display: none; }

/* ---------- Chips, tabs, pagination ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 var(--s-4); padding: 0; list-style: none; }
.chips a, .chips button { display: inline-flex; min-height: 36px; align-items: center; gap: 6px; padding: 0 14px; border-radius: var(--r-pill); background: var(--surface); border: 1px solid var(--line-2); color: var(--ink-2); text-decoration: none; font: inherit; font-size: .9rem; font-weight: 500; cursor: pointer; }
.chips a:hover, .chips button:hover { border-color: var(--primary); color: var(--primary); }
.chips a[aria-current="page"], .chips .is-active { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: var(--s-4); overflow-x: auto; }
.tabs a { padding: 10px 14px; text-decoration: none; color: var(--muted); font-weight: 500; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs a:hover { color: var(--ink); }
.tabs a[aria-current="page"] { color: var(--primary); border-color: var(--primary); }
.tabs .count { background: var(--bg-2); color: var(--ink-2); border-radius: var(--r-pill); padding: 0 8px; font-size: .78rem; margin-left: 6px; }
.pagination { display: flex; gap: var(--s-3); list-style: none; padding: 0; margin: var(--s-4) 0; align-items: center; justify-content: space-between; }
.pagination a { text-decoration: none; font-weight: 500; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 600; background: var(--surface-2); white-space: nowrap; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--surface-2); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
td .sub, th .sub { display: block; color: var(--muted); font-size: .85rem; margin-top: 2px; font-weight: 500; text-transform: none; letter-spacing: 0; }
.table-tools { display: flex; gap: var(--s-2); align-items: center; flex-wrap: wrap; margin-bottom: var(--s-3); }
.table-tools form { display: flex; gap: var(--s-2); flex: 1; min-width: 240px; max-width: 460px; }
.table-tools input, .table-tools select { min-height: 40px; }
.table-foot { display: flex; justify-content: space-between; align-items: center; gap: var(--s-3); flex-wrap: wrap; padding: var(--s-3) 0; color: var(--muted); font-size: .9rem; }
.table-foot .pagination { margin: 0; }

/* ---------- Definition lists, stats ---------- */
dl.summary { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 10px 20px; margin: 0; }
dl.summary dt { color: var(--muted); font-size: .92rem; }
dl.summary dd { margin: 0; overflow-wrap: anywhere; }
.stats { display: grid; gap: var(--s-3); grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--s-4); display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.stat .label { color: var(--muted); font-size: .85rem; display: flex; align-items: center; gap: 6px; }
.stat .value { font-size: 1.6rem; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stat .value.small { font-size: 1.15rem; }
.stat .hint { color: var(--muted); font-size: .82rem; }
.stat.is-alert { border-color: color-mix(in srgb, var(--bad) 40%, var(--line)); }
.stat.is-alert .value { color: var(--bad); }
.stat a, a.stat { text-decoration: none; color: inherit; }
a.stat:hover { border-color: var(--primary); }
.kv { display: flex; justify-content: space-between; gap: var(--s-3); padding: 10px 0; border-bottom: 1px solid var(--line); }
.kv:last-child { border-bottom: 0; }
.kv .k { color: var(--muted); }
.kv .v { text-align: right; font-weight: 500; overflow-wrap: anywhere; }
.total { font-family: var(--display); font-size: 1.5rem; font-weight: 800; letter-spacing: -0.03em; }
.stat .value { font-family: var(--display); font-weight: 800; }

/* ---------- Brand letter marks & tints ---------- */
.logo { flex: none; width: 46px; height: 46px; border-radius: 13px; display: inline-grid; place-items: center; font-family: var(--display); font-weight: 800; font-size: 1.02rem; color: #fff; letter-spacing: -0.03em; text-shadow: 0 1px 1px rgba(0, 0, 0, .15); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), inset 0 -10px 18px -10px rgba(0, 0, 0, .22), 0 6px 14px -8px rgba(30, 27, 75, .45); }
.logo.lg { width: 64px; height: 64px; font-size: 1.45rem; border-radius: 18px; }
.logo.h0 { background: linear-gradient(140deg, #6366f1, #4338ca); }
.logo.h1 { background: linear-gradient(140deg, #06b6d4, #0e7490); }
.logo.h2 { background: linear-gradient(140deg, #ec4899, #be185d); }
.logo.h3 { background: linear-gradient(140deg, #f59e0b, #c2410c); }
.logo.h4 { background: linear-gradient(140deg, #22c55e, #15803d); }
.logo.h5 { background: linear-gradient(140deg, #a855f7, #6d28d9); }
.logo.h6 { background: linear-gradient(140deg, #fb923c, #ea580c); }
.logo.h7 { background: linear-gradient(140deg, #3b82f6, #1d4ed8); }
.tint-0, .tint-1, .tint-2, .tint-3, .tint-4, .tint-5 { color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 8px 16px -8px rgba(67, 56, 202, .55); }
.tint-0 { background: linear-gradient(135deg, #6366f1, #8b5cf6); }
.tint-1 { background: linear-gradient(135deg, #0ea5e9, #6366f1); }
.tint-2 { background: linear-gradient(135deg, #a855f7, #ec4899); }
.tint-3 { background: linear-gradient(135deg, #10b981, #0ea5e9); }
.tint-4 { background: linear-gradient(135deg, #f43f5e, #f97316); }
.tint-5 { background: linear-gradient(135deg, #14b8a6, #6366f1); }

/* ---------- Product cards ---------- */
.product-card { position: relative; display: flex; flex-direction: column; gap: 14px; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow-sm); transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease; min-width: 0; isolation: isolate; }
.product-card::before { content: ""; position: absolute; left: 22px; right: 22px; top: -1px; height: 3px; border-radius: 0 0 4px 4px; background: var(--grad); opacity: 0; transition: opacity .22s ease; }
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--primary) 30%, var(--line)); }
.product-card:hover::before { opacity: 1; }
.product-card:hover .logo { transform: scale(1.05) rotate(-3deg); }
.product-card .logo { transition: transform .25s ease; }
.pc-head { display: flex; gap: 14px; align-items: center; }
.pc-titles { min-width: 0; }
.pc-cat { font-size: .7rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--primary); margin: 0 0 4px; }
.product-card h3 { margin: 0; font-size: 1.14rem; line-height: 1.25; }
.product-card h3 a { color: inherit; text-decoration: none; }
.product-card h3 a::after { content: ""; position: absolute; inset: 0; border-radius: 20px; z-index: 0; }
.pc-variant { margin: 0; color: var(--ink-2); font-weight: 500; font-size: .95rem; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.9em; }
.pc-meta { list-style: none; margin: 0; padding: 14px 0 0; border-top: 1px dashed var(--line-2); display: grid; grid-template-columns: 1fr 1fr; gap: 9px 14px; }
.pc-meta li { display: flex; align-items: flex-start; gap: 7px; font-size: .84rem; line-height: 1.35; color: var(--muted); min-width: 0; }
.pc-meta li span { min-width: 0; overflow-wrap: anywhere; }
.pc-meta .icon { color: var(--primary); width: 16px; height: 16px; margin-top: 1px; }
.pc-foot { margin-top: auto; display: flex; align-items: flex-end; justify-content: space-between; gap: var(--s-3); padding-top: 16px; border-top: 1px solid var(--line); }
.product-card .price, .rec .price { margin: 0; font-family: var(--display); font-weight: 800; font-size: 1.65rem; letter-spacing: -0.035em; line-height: 1; color: var(--ink); }
.price-label { display: block; font-family: var(--font); font-size: .68rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; margin-bottom: 7px; }
.product-card .price small, .rec .price small { font-family: var(--font); font-size: .76rem; font-weight: 600; color: var(--muted); margin-left: 5px; letter-spacing: 0; }
.pc-buy, .pc-notify, .pc-state { position: relative; z-index: 1; }
.pc-buy { min-height: 44px; padding: 0 18px; }
.pc-buy .icon { transition: transform .2s; }
.product-card:hover .pc-buy .icon { transform: translateX(3px); }
.product-card .state { font-size: .8rem; color: var(--muted); margin: 6px 0 0; }
.product-card.is-unavailable { background: var(--surface-2); }
.product-card.is-unavailable .logo { filter: saturate(.55); }
.product-card.is-unavailable:hover { transform: translateY(-2px); }

/* ---------- Empty / timeline / misc ---------- */
.empty { text-align: center; padding: var(--s-7) var(--s-4); background: var(--surface); border: 1px dashed var(--line-2); border-radius: var(--r-lg); color: var(--muted); }
.empty .icon { color: var(--muted); margin-bottom: var(--s-3); stroke-width: 1.4; }
.empty-title { font-weight: 600; color: var(--ink); margin-bottom: 4px; }
.empty-body { max-width: 440px; margin: 0 auto; }
.empty-body .button { margin-top: var(--s-3); }
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline li { position: relative; padding: 0 0 var(--s-4) 28px; }
.timeline li::before { content: ""; position: absolute; left: 6px; top: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); }
.timeline li::after { content: ""; position: absolute; left: 10px; top: 18px; bottom: 0; width: 2px; background: var(--line); }
.timeline li:last-child::after { display: none; }
.timeline li.done::before { background: var(--ok); }
.timeline li.now::before { background: var(--primary); box-shadow: 0 0 0 4px var(--primary-soft); }
.timeline li.bad::before { background: var(--bad); }
.timeline .t { font-weight: 600; }
.timeline .d { color: var(--muted); font-size: .9rem; }
.secret { font-family: var(--mono); background: var(--bg-2); border: 1px dashed var(--line-2); padding: 12px; border-radius: var(--r-sm); white-space: pre-wrap; overflow-wrap: anywhere; user-select: all; }
.masked { font-family: var(--mono); letter-spacing: .2em; color: var(--muted); background: var(--bg-2); padding: 10px 12px; border-radius: var(--r-sm); display: inline-flex; align-items: center; gap: 10px; letter-spacing: normal; }
.countdown { font-variant-numeric: tabular-nums; font-weight: 600; }
.countdown.is-low { color: var(--bad); }
.steps { display: grid; gap: var(--s-3); grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); counter-reset: step; margin: var(--s-4) 0; padding: 0; list-style: none; }
.steps li { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: var(--s-4); counter-increment: step; }
.steps li::before { content: counter(step); display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--primary-soft); color: var(--primary-soft-ink); font-weight: 700; font-size: .85rem; margin-bottom: 8px; }
.steps .t { font-weight: 600; display: block; }
.steps .d { color: var(--muted); font-size: .9rem; }
.info-list { display: grid; gap: var(--s-3); margin: 0; padding: 0; list-style: none; }
.info-list li { display: flex; gap: 12px; align-items: flex-start; }
.info-list .icon { color: var(--primary); margin-top: 2px; }
.info-list .t { font-weight: 600; display: block; }
.info-list .d { color: var(--ink-2); font-size: .95rem; }

/* ---------- Auth ---------- */
.auth-page { min-height: calc(100vh - 64px); display: grid; place-items: center; padding: var(--s-6) var(--s-4); }
.auth-card { width: 100%; max-width: 440px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow); padding: var(--s-6); }
.auth-card h1 { font-size: 1.5rem; margin-bottom: var(--s-2); }
.auth-card .lead { color: var(--muted); margin-bottom: var(--s-5); }
.auth-switch { text-align: center; margin-top: var(--s-5); color: var(--muted); }
.auth-switch a { font-weight: 600; }
.auth-card .button.block { margin-top: var(--s-2); }

/* ---------- Account shell ---------- */
.account-shell { display: grid; gap: var(--s-5); grid-template-columns: 240px minmax(0, 1fr); align-items: start; }
.account-shell > * { min-width: 0; }
.split > * { min-width: 0; }
.grid-2 > *, .grid > * { min-width: 0; }
.side-nav { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--s-2); position: sticky; top: 84px; }
.side-nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--r-sm); color: var(--ink-2); text-decoration: none; font-weight: 500; }
.side-nav a:hover { background: var(--bg-2); color: var(--ink); }
.side-nav a[aria-current="page"] { background: var(--primary-soft); color: var(--primary-soft-ink); }
.side-nav .icon { color: inherit; }
.side-nav .group { font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 12px 12px 4px; }
.bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; display: none; background: var(--surface); border-top: 1px solid var(--line); z-index: 30; padding-bottom: env(safe-area-inset-bottom); }
.bottom-nav a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 4px; min-height: 56px; text-decoration: none; color: var(--muted); font-size: .72rem; font-weight: 500; }
.bottom-nav a[aria-current="page"] { color: var(--primary); }

/* ---------- Admin shell ---------- */
.admin { background: var(--bg); }
.admin-shell { display: grid; grid-template-columns: 248px minmax(0, 1fr); min-height: 100vh; }
.admin-shell > * { min-width: 0; }
.admin-side { background: var(--surface); border-right: 1px solid var(--line); padding: var(--s-4) var(--s-3); position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; gap: var(--s-2); }
.admin-side .brand { padding: 4px 8px 12px; }
.admin-side nav a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: var(--r-sm); color: var(--ink-2); text-decoration: none; font-weight: 500; font-size: .95rem; }
.admin-side nav a:hover { background: var(--bg-2); color: var(--ink); }
.admin-side nav a[aria-current="page"] { background: var(--primary-soft); color: var(--primary-soft-ink); }
.admin-side .group { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 12px 12px 4px; }
.admin-side .count { margin-left: auto; background: var(--bad-soft); color: var(--bad); border-radius: var(--r-pill); padding: 0 8px; font-size: .75rem; font-weight: 700; }
.admin-side .foot { margin-top: auto; padding: var(--s-3) 8px 0; border-top: 1px solid var(--line); font-size: .85rem; color: var(--muted); }
.admin-main { padding: var(--s-5) var(--s-6) var(--s-8); min-width: 0; }
.admin-top { display: none; align-items: center; gap: var(--s-3); padding: 10px var(--s-4); background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.admin-main .page-head { margin-bottom: var(--s-4); }
.admin .panel { padding: var(--s-4) var(--s-5); }
.admin dl.summary { gap: 8px 20px; }
.admin h2 { font-size: 1.1rem; margin-top: var(--s-5); }
.admin .table-wrap table { font-size: .93rem; }
.admin th, .admin td { padding: 10px 12px; }
.env-note { font-size: .85rem; color: var(--muted); }
.switches { display: flex; gap: var(--s-4); flex-wrap: wrap; align-items: center; }
.toggle { display: inline-flex; align-items: center; gap: 8px; font-weight: 500; }


/* ---------- Catalog nav (results page) ---------- */
.cat-nav { display: grid; gap: var(--s-3); grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); margin: var(--s-5) 0; }
.cat-nav a { display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .95rem; box-shadow: var(--shadow-xs); transition: border-color .15s, color .15s, box-shadow .15s; }
.cat-nav a:hover { border-color: color-mix(in srgb, var(--primary) 45%, var(--line)); color: var(--primary); box-shadow: var(--shadow-sm); }
.cat-nav a[aria-current="page"] { border-color: var(--primary); background: var(--primary-soft); color: var(--primary-soft-ink); }
.cat-nav .icon { color: var(--primary); }

/* ---------- SubMela AI (assistant) ---------- */
.ai { position: relative; border-radius: 26px; border: 1px solid transparent; background: linear-gradient(var(--surface), var(--surface)) padding-box, linear-gradient(135deg, rgba(99, 102, 241, .6), rgba(168, 85, 247, .38) 38%, var(--line) 72%) border-box; box-shadow: 0 34px 80px -34px rgba(67, 56, 202, .42), 0 10px 26px -14px rgba(16, 19, 48, .12); overflow: hidden; }
.ai-head { display: flex; align-items: center; gap: 14px; padding: 18px 24px; border-bottom: 1px solid var(--line); background: linear-gradient(90deg, rgba(99, 102, 241, .08), rgba(168, 85, 247, .05) 45%, transparent 80%); }
.ai-avatar { position: relative; width: 48px; height: 48px; border-radius: 15px; background: var(--grad); color: #fff; display: grid; place-items: center; flex: none; box-shadow: 0 10px 22px -8px rgba(91, 60, 240, .7), inset 0 1px 0 rgba(255, 255, 255, .25); }
.ai-avatar::after { content: ""; position: absolute; inset: -5px; border-radius: 19px; border: 2px solid rgba(124, 58, 237, .4); animation: ring 2.8s ease-out infinite; }
@keyframes ring { 0% { opacity: .9; transform: scale(.9); } 100% { opacity: 0; transform: scale(1.22); } }
.ai-heading { min-width: 0; }
.ai-heading h2 { font-size: 1.22rem; margin: 0; letter-spacing: -0.02em; }
.ai-heading p { margin: 2px 0 0; font-size: .88rem; color: var(--muted); }
.ai-live { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: var(--r-pill); background: var(--ok-soft); color: var(--ok); font-size: .8rem; font-weight: 600; white-space: nowrap; }
.ai-live i { width: 8px; height: 8px; border-radius: 50%; background: currentColor; animation: live 2s infinite; }
@keyframes live { 0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, .5); } 70% { box-shadow: 0 0 0 7px rgba(34, 197, 94, 0); } 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); } }
.ai-reset { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); border-radius: 10px; font: inherit; font-size: .85rem; font-weight: 600; cursor: pointer; }
.ai-reset:hover { color: var(--primary); border-color: var(--primary); }
.chat-log { position: relative; display: flex; flex-direction: column; gap: 18px; padding: 22px 24px 6px; max-height: clamp(320px, calc(100vh - 360px), 620px); overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; overscroll-behavior: contain; }
.msg { display: flex; gap: 12px; align-items: flex-start; min-width: 0; animation: msg-in .3s ease-out both; scroll-margin-top: calc(var(--header-h) + 16px); }
@keyframes msg-in { from { opacity: 0; transform: translateY(8px); } }
.msg-avatar { width: 34px; height: 34px; border-radius: 11px; background: var(--grad); color: #fff; display: grid; place-items: center; flex: none; box-shadow: 0 6px 14px -6px rgba(91, 60, 240, .65); }
.msg-body { min-width: 0; flex: 1; }
.msg-who { font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--primary); margin: 2px 0 6px; }
.msg-text { margin: 0; display: inline-block; max-width: 780px; padding: 12px 16px; background: var(--lav); border: 1px solid var(--lav-2); border-radius: 4px 18px 18px 18px; color: var(--ink); line-height: 1.55; overflow-wrap: anywhere; }
.msg.user { justify-content: flex-end; }
.msg.user .msg-body { flex: 0 1 auto; max-width: min(80%, 620px); }
.msg.user .msg-text { background: var(--grad); color: #fff; border-color: transparent; border-radius: 18px 4px 18px 18px; box-shadow: var(--shadow-primary); }
.thinking { display: inline-flex; align-items: center; gap: 10px; padding: 12px 16px; background: var(--lav); border: 1px solid var(--lav-2); border-radius: 4px 18px 18px 18px; color: var(--muted); font-size: .9rem; }
.dots { display: inline-flex; gap: 4px; }
.dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--primary); animation: blink 1.2s infinite; }
.dots i:nth-child(2) { animation-delay: .18s; } .dots i:nth-child(3) { animation-delay: .36s; }
@keyframes blink { 0%, 80%, 100% { opacity: .25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
.skeletons { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.skeleton { height: 190px; border-radius: 18px; border: 1px solid var(--line); background: linear-gradient(100deg, var(--surface-2) 30%, var(--lav-2) 50%, var(--surface-2) 70%); background-size: 300% 100%; animation: shimmer 1.4s ease-in-out infinite; }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }
.recs-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 16px 0 10px; font-size: .85rem; color: var(--muted); font-weight: 500; }
.recs-head strong { color: var(--ink); }
.recs-all { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; text-decoration: none; }
.recs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.rec { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-xs); min-width: 0; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; animation: msg-in .35s ease-out both; }
.rec:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--primary) 35%, var(--line)); box-shadow: var(--shadow); }
.rec-top { display: flex; gap: 12px; align-items: center; }
.rec-top .logo { width: 40px; height: 40px; border-radius: 12px; font-size: .9rem; }
.rec-titles { min-width: 0; flex: 1; }
.rec-cat { margin: 0 0 2px; font-size: .66rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--primary); }
.rec h4 { margin: 0; font-size: 1rem; line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rec h4 a { color: inherit; text-decoration: none; }
.rec h4 a:hover { color: var(--primary); }
.rec .badge { align-self: flex-start; }
.rec-variant { margin: 0; font-size: .88rem; color: var(--ink-2); font-weight: 500; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.9em; }
.rec-meta { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: .8rem; color: var(--muted); }
.rec-meta li { display: inline-flex; align-items: center; gap: 5px; }
.rec-meta .icon { width: 14px; height: 14px; color: var(--primary); }
.rec-price { margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line); }
.rec .price { font-size: 1.35rem; }
.rec-state { margin: 0; font-size: .84rem; color: var(--muted); }
.rec-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.rec-actions .button { min-height: 38px; padding: 0 10px; font-size: .86rem; border-radius: 10px; }
.rec-actions .button:only-child { grid-column: 1 / -1; }
.rec.is-unavailable { background: var(--surface-2); }
.recs-more { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; min-height: 38px; padding: 0 14px; border: 1px dashed var(--line-2); border-radius: 10px; background: transparent; color: var(--primary); font: inherit; font-size: .88rem; font-weight: 600; cursor: pointer; }
.recs-more:hover { border-style: solid; border-color: var(--primary); background: var(--primary-soft); }
.msg-links { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.msg-follow { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 14px; }
.msg-follow .label { font-size: .78rem; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .08em; margin-right: 2px; }
.follow-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 13px; border-radius: var(--r-pill); border: 1px solid var(--line-2); background: var(--surface); color: var(--ink-2); font: inherit; font-size: .85rem; font-weight: 500; cursor: pointer; transition: border-color .15s, color .15s, background .15s; }
.follow-chip:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.ai-form { display: flex; align-items: center; gap: 10px; margin: 14px 24px 0; padding: 7px 7px 7px 16px; border: 1.5px solid var(--line-2); border-radius: 18px; background: var(--surface); box-shadow: var(--shadow-xs); transition: border-color .15s, box-shadow .15s; }
.ai-form:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(99, 102, 241, .14); }
.ai-input-icon { display: inline-grid; color: var(--primary); }
.ai-form input { flex: 1; min-width: 0; border: 0; background: transparent; min-height: 50px; padding: 0 4px; font-size: 1.04rem; box-shadow: none; border-radius: 0; }
.ai-form input:focus { box-shadow: none; outline: none; }
.ai-form input::-webkit-search-cancel-button { display: none; }
.ai-send { display: inline-flex; align-items: center; gap: 8px; min-height: 50px; padding: 0 24px; border: 0; border-radius: 13px; background: var(--grad); color: #fff; font: inherit; font-weight: 600; cursor: pointer; flex: none; box-shadow: var(--shadow-primary), inset 0 1px 0 rgba(255, 255, 255, .2); transition: transform .15s, box-shadow .2s, background .2s; }
.ai-send:hover { background: var(--grad-hover); transform: translateY(-1px); box-shadow: 0 12px 24px -10px rgba(79, 70, 229, .8); }
.ai-send[disabled] { opacity: .65; cursor: progress; transform: none; }
.ai-prompts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 14px 24px 0; }
.ai-prompts .label { font-size: .78rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; margin-right: 2px; }
.chip { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 14px 0 5px; border-radius: var(--r-pill); background: var(--surface); border: 1px solid var(--line); color: var(--ink-2); text-decoration: none; font-size: .88rem; font-weight: 500; white-space: nowrap; box-shadow: var(--shadow-xs); transition: border-color .15s, color .15s, background .15s, transform .15s; }
.chip:hover { border-color: color-mix(in srgb, var(--primary) 50%, var(--line)); color: var(--primary); background: var(--primary-soft); transform: translateY(-1px); }
.chip-mark { width: 26px; height: 26px; font-size: .64rem; border-radius: var(--r-pill); box-shadow: none; }
.chip-intent { padding-left: 12px; background: var(--primary-soft); border-color: transparent; color: var(--primary-soft-ink); font-weight: 600; }
.chip-intent .icon { color: var(--primary); }
.ai-note { display: flex; align-items: center; gap: 8px; margin: 0; padding: 14px 24px 18px; font-size: .82rem; color: var(--muted); }
.ai-note .icon { color: var(--ok); }
.ai-compact { margin: 0 0 var(--s-5); box-shadow: var(--shadow); }
.ai-compact .is-welcome { display: none; }
.ai-compact .chat-log { padding-top: 0; padding-bottom: 0; }
.ai-compact .chat-log.has-messages { padding: 22px 24px 6px; }

/* ---------- Homepage ---------- */
.is-home .page-full { padding-bottom: 0; }
.hero { position: relative; overflow: hidden; background: radial-gradient(1000px 540px at 85% -5%, rgba(139, 92, 246, .17), transparent 62%), radial-gradient(760px 460px at -5% 105%, rgba(79, 70, 229, .11), transparent 60%), linear-gradient(180deg, #fcfcff 0%, #f3f2ff 100%); border-bottom: 1px solid var(--line); padding-bottom: 76px; }
.hero::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(79, 70, 229, .16) 1px, transparent 1.2px); background-size: 22px 22px; -webkit-mask-image: radial-gradient(ellipse 60% 70% at 75% 45%, #000 15%, transparent 72%); mask-image: radial-gradient(ellipse 60% 70% at 75% 45%, #000 15%, transparent 72%); pointer-events: none; }
.hero-glow { position: absolute; width: 520px; height: 520px; right: 6%; top: -120px; border-radius: 50%; background: radial-gradient(circle, rgba(167, 139, 250, .28), transparent 65%); filter: blur(10px); pointer-events: none; }
.hero-grid { position: relative; display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(0, .82fr); gap: 40px; align-items: center; padding-top: 60px; padding-bottom: 28px; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; padding: 6px 16px 6px 6px; border-radius: var(--r-pill); background: color-mix(in srgb, var(--surface) 85%, transparent); border: 1px solid color-mix(in srgb, var(--primary) 22%, var(--line)); color: var(--primary-soft-ink); font-weight: 600; font-size: .86rem; box-shadow: 0 6px 16px -10px rgba(79, 70, 229, .45); margin: 0; }
.eyebrow-icon { width: 26px; height: 26px; border-radius: 50%; background: var(--grad); color: #fff; display: inline-grid; place-items: center; }
.hero-copy { container-type: inline-size; }
.hero-copy h1 { font-size: clamp(2rem, .9rem + 2.6vw, 3.1rem); font-size: clamp(2rem, 6.85cqi, 3.15rem); line-height: 1.08; letter-spacing: -0.045em; margin: 22px 0 18px; color: var(--ink); }
.hero-copy h1 .hl { display: block; text-wrap: balance; }
.hero-copy .accent { position: relative; white-space: nowrap; background: linear-gradient(95deg, #4f46e5 0%, #6d3df2 50%, #9333ea 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-copy .accent::after { content: ""; position: absolute; left: 2%; right: 2%; bottom: -.04em; height: .13em; border-radius: 99px; background: linear-gradient(90deg, rgba(79, 70, 229, .45), rgba(147, 51, 234, .45)); }
.hero-copy .lead { font-size: 1.1rem; line-height: 1.65; color: var(--ink-2); max-width: 580px; margin-bottom: 24px; }
.hero-points { display: flex; flex-wrap: wrap; gap: 12px 26px; margin: 0; padding: 0; list-style: none; color: var(--ink); font-weight: 500; font-size: .95rem; }
.hero-points li { display: inline-flex; align-items: center; gap: 9px; }
.tick { width: 22px; height: 22px; border-radius: 50%; background: var(--ok-soft); color: var(--ok); display: inline-grid; place-items: center; }
.tick .icon { stroke-width: 2.6; }
.hero-visual { position: relative; width: 100%; max-width: 540px; aspect-ratio: 540 / 450; margin-left: auto; }
.hv-rings { position: absolute; inset: 0; pointer-events: none; }
.hv-rings::before { content: ""; position: absolute; left: 50%; top: 50%; width: 46%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; background: radial-gradient(circle, rgba(124, 58, 237, .30), rgba(99, 102, 241, .10) 55%, transparent 72%); animation: pulse 5s ease-in-out infinite; }
.hv-rings i { position: absolute; left: 50%; top: 50%; aspect-ratio: 1; border-radius: 50%; border: 1px solid rgba(99, 102, 241, .2); transform: translate(-50%, -50%); }
.hv-rings i:nth-child(1) { width: 38%; }
.hv-rings i:nth-child(2) { width: 62%; border-color: rgba(99, 102, 241, .14); }
.hv-rings i:nth-child(3) { width: 88%; border-style: dashed; border-color: rgba(99, 102, 241, .14); }
@keyframes pulse { 0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: .9; } 50% { transform: translate(-50%, -50%) scale(1.08); opacity: 1; } }
.hv-lines { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.hv-lines path { fill: none; stroke: rgba(99, 102, 241, .42); stroke-width: 1.4; stroke-dasharray: 3 5; vector-effect: non-scaling-stroke; animation: dash 14s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -160; } }
.hv-core { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 26%; aspect-ratio: 1; border-radius: 30%; background: var(--surface); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; box-shadow: 0 30px 60px -22px rgba(79, 70, 229, .6), 0 0 0 10px rgba(255, 255, 255, .6), 0 0 0 11px rgba(99, 102, 241, .14); z-index: 1; }
.hv-core .brand-mark { width: 46%; height: auto; }
.hv-core-label { font-family: var(--display); font-weight: 800; font-size: .8rem; letter-spacing: -0.01em; color: var(--ink); white-space: nowrap; }
.hv-tile { position: absolute; z-index: 2; display: flex; align-items: center; gap: 12px; width: 37%; padding: 11px 14px 11px 11px; background: color-mix(in srgb, var(--surface) 90%, transparent); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border: 1px solid color-mix(in srgb, var(--primary) 12%, var(--line)); border-radius: 18px; box-shadow: 0 20px 40px -20px rgba(40, 35, 120, .38), 0 2px 6px rgba(16, 19, 48, .05); animation: float 8s ease-in-out infinite; }
.hv-tile { width: 40%; }
.hv-icon { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex: none; }
.hv-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; gap: 2px; }
.hv-text b { font-family: var(--display); font-weight: 700; font-size: .92rem; line-height: 1.25; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.hv-text small { font-size: .8rem; color: var(--primary); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hv-tile:not(.is-priced) .hv-text small { color: var(--muted); font-weight: 500; }
.hv-t0 { left: 0; top: 7%; }
.hv-t1 { right: 0; top: 1%; animation-delay: -2s; }
.hv-t2 { left: -3%; top: 41%; animation-delay: -4s; }
.hv-t3 { right: -3%; top: 39%; animation-delay: -1s; }
.hv-t4 { left: 2%; bottom: 5%; animation-delay: -3s; }
.hv-t5 { right: 2%; bottom: 1%; animation-delay: -5s; }
@keyframes float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -9px; } }
.ai-wrap { position: relative; z-index: 3; margin-top: -60px; }
.band { padding: 76px 0; }
.ai-wrap + .band { padding-top: 64px; }
.band-soft { background: linear-gradient(180deg, var(--lav) 0%, color-mix(in srgb, var(--lav) 35%, var(--surface)) 100%); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.band-tight { padding: 0 0 84px; }
.band-soft + .band-tight { padding-top: 0; }
.band-soft + .band-tight .trust { margin-top: -36px; position: relative; }
.band .section-head { align-items: flex-end; margin-bottom: 28px; gap: 16px; }
.band .section-head h2 { font-size: clamp(1.6rem, 1.15rem + 1.2vw, 2.2rem); letter-spacing: -0.035em; margin: 0; }
.band .section-head .muted { margin-top: 8px; font-size: 1rem; }
.section-head.center { justify-content: center; text-align: center; }
.kicker { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 8px; font-size: .76rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--primary); }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, .18); }
.cat-cards { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
.cat-card { position: relative; display: flex; flex-direction: column; gap: 6px; padding: 22px 20px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; text-decoration: none; color: var(--ink); box-shadow: var(--shadow-xs); transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease; min-width: 0; overflow: hidden; isolation: isolate; }
.cat-card::after { content: ""; position: absolute; z-index: -1; right: -46px; top: -46px; width: 130px; height: 130px; border-radius: 50%; background: radial-gradient(circle, rgba(99, 102, 241, .12), transparent 70%); transition: transform .35s ease; }
.cat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--primary) 30%, var(--line)); color: var(--ink); }
.cat-card:hover::after { transform: scale(1.5); }
.cat-icon { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; margin-bottom: 10px; transition: transform .25s ease; }
.cat-card:hover .cat-icon { transform: scale(1.06) rotate(-4deg); }
.cat-name { font-family: var(--display); font-weight: 800; font-size: 1.04rem; letter-spacing: -0.015em; line-height: 1.25; }
.cat-desc { color: var(--muted); font-size: .86rem; line-height: 1.45; }
.cat-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: auto; padding-top: 16px; font-size: .82rem; font-weight: 600; color: var(--primary); }
.cat-foot .icon { transition: transform .2s; }
.cat-card:hover .cat-foot .icon { transform: translateX(3px); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.more-row { display: flex; justify-content: center; margin-top: 32px; }
.soon { position: relative; background: radial-gradient(500px 240px at 0% 0%, rgba(139, 92, 246, .14), transparent 70%), linear-gradient(135deg, #f7f5ff 0%, #f0f2ff 55%, #fbf5ff 100%); border: 1px solid color-mix(in srgb, var(--primary) 16%, var(--line)); border-radius: 26px; padding: 28px; }
.soon-head { display: flex; align-items: center; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.soon-bell { width: 54px; height: 54px; border-radius: 17px; background: var(--surface); color: var(--primary); display: grid; place-items: center; box-shadow: var(--shadow-sm); flex: none; }
.soon-head h2 { font-size: 1.5rem; margin: 0 0 4px; letter-spacing: -0.03em; }
.row-nav { display: flex; gap: 8px; }
.row-nav button { width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow-xs); transition: color .15s, border-color .15s; }
.row-nav button:hover:not([disabled]) { color: var(--primary); border-color: var(--primary); }
.row-nav button[disabled] { opacity: .4; cursor: default; }
.soon-row { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * 14px) / 4); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; padding: 2px 2px 8px; margin: -2px -2px 0; scrollbar-width: none; }
.soon-row::-webkit-scrollbar { display: none; }
.mini-card { scroll-snap-align: start; display: flex; flex-direction: column; gap: 6px; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; min-width: 0; box-shadow: var(--shadow-xs); transition: box-shadow .2s ease, transform .2s ease, border-color .2s; }
.mini-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: color-mix(in srgb, var(--primary) 25%, var(--line)); }
.mc-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.mc-top .logo { width: 40px; height: 40px; border-radius: 12px; font-size: .9rem; filter: saturate(.6); }
.mc-name { margin: 0; font-family: var(--display); font-weight: 700; font-size: 1rem; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc-variant { margin: 0 0 6px; font-size: .85rem; color: var(--muted); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.9em; }
.mini-card .notify { margin-top: auto; width: 100%; background: var(--surface); color: var(--primary); border: 1px solid color-mix(in srgb, var(--primary) 35%, var(--line)); box-shadow: none; }
.mini-card .notify:hover { background: var(--grad); color: #fff; border-color: transparent; }
.soon-foot { margin-top: 14px; }
.how { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.how li { position: relative; text-align: center; padding: 30px 22px 26px; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-xs); transition: box-shadow .2s, transform .2s; }
.how li:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.how li:not(:last-child)::after { content: ""; position: absolute; top: 62px; right: -25px; width: 26px; height: 2px; background: repeating-linear-gradient(90deg, rgba(99, 102, 241, .45) 0 5px, transparent 5px 9px); }
.how-icon { position: relative; width: 66px; height: 66px; margin: 0 auto 18px; border-radius: 20px; background: linear-gradient(135deg, var(--primary-soft), var(--lav-2)); color: var(--primary); display: grid; place-items: center; border: 1px solid color-mix(in srgb, var(--primary) 14%, transparent); }
.how-icon b { position: absolute; top: -9px; right: -9px; width: 28px; height: 28px; border-radius: 50%; background: var(--grad); color: #fff; font-family: var(--display); font-weight: 800; font-size: .8rem; display: grid; place-items: center; box-shadow: 0 0 0 4px var(--surface); }
.how h3 { font-size: 1.08rem; margin: 0 0 6px; }
.how p { margin: 0; color: var(--muted); font-size: .92rem; line-height: 1.55; }
.trust { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 30px 24px; border-radius: 26px; background: radial-gradient(520px 220px at 8% 0%, rgba(139, 92, 246, .5), transparent 70%), radial-gradient(420px 200px at 100% 100%, rgba(59, 130, 246, .28), transparent 70%), linear-gradient(135deg, #1e1b4b 0%, #312e81 55%, #4c1d95 100%); color: #e0e7ff; box-shadow: 0 34px 70px -34px rgba(49, 46, 129, .7); overflow: hidden; }
.trust > div { display: flex; gap: 14px; align-items: flex-start; padding: 6px 16px; min-width: 0; }
.trust > div + div { border-left: 1px solid rgba(255, 255, 255, .12); }
.trust-icon { width: 46px; height: 46px; border-radius: 14px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .16); color: #fff; display: grid; place-items: center; flex: none; }
.trust .t { display: block; font-family: var(--display); font-weight: 700; color: #fff; font-size: 1rem; margin-bottom: 4px; }
.trust .d { display: block; color: #c7d2fe; font-size: .88rem; line-height: 1.5; }
.buy-panel { scroll-margin-top: calc(var(--header-h) + 20px); }
@media (prefers-color-scheme: dark) {
    .hero { background: radial-gradient(1000px 540px at 85% -5%, rgba(139, 92, 246, .22), transparent 62%), radial-gradient(760px 460px at -5% 105%, rgba(79, 70, 229, .18), transparent 60%), var(--bg); }
    .hv-core { box-shadow: 0 30px 60px -22px rgba(0, 0, 0, .8), 0 0 0 10px rgba(255, 255, 255, .04), 0 0 0 11px rgba(139, 133, 255, .2); }
    .soon { background: radial-gradient(500px 240px at 0% 0%, rgba(139, 92, 246, .16), transparent 70%), var(--surface-2); }
    .hero-copy .accent { background-image: linear-gradient(95deg, #a5b4fc, #c4b5fd); }
}

/* ---------- Responsive ---------- */
@media (max-width: 1200px) {
    .hero-grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 28px; }
    .hv-tile { width: 42%; }
    .hv-text b { font-size: .86rem; }
}
@media (min-width: 901px) and (max-width: 1200px) {
    .header-row { gap: 14px; }
    .top-nav .nav-link { padding: 0 10px; }
    .top-nav .nav-link > .icon:first-child { display: none; }
    .user-menu > summary .nowrap { display: none; }
    .user-menu > summary { padding-right: 8px; }
    .nav-sep { margin: 0 4px; }
}
@media (max-width: 1100px) {
    .cat-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .how { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .how li::after { display: none; }
    .trust { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 20px; }
    .trust > div:nth-child(3) { border-left: 0; }
    .soon-row { grid-auto-columns: calc((100% - 2 * 14px) / 3.2); }
    .recs, .skeletons { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
    .footer-grid > :last-child { grid-column: 1 / -1; }
    .footer-contact { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 1000px) {
    .split { grid-template-columns: 1fr; }
    .sticky { position: static; }
    .admin-shell { grid-template-columns: 1fr; }
    .admin-side { position: fixed; inset: 0 auto 0 0; width: 280px; transform: translateX(-100%); transition: transform .2s; z-index: 40; box-shadow: var(--shadow); }
    .admin-side.is-open { transform: none; }
    .admin-top { display: flex; }
    .admin-main { padding: var(--s-4); }
}
@media (max-width: 1080px) {
    .hero { padding-bottom: 64px; }
    .hero-grid { grid-template-columns: 1fr; gap: 28px; padding-top: 44px; padding-bottom: 20px; }
    .hero-visual { max-width: none; aspect-ratio: auto; margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
    .hv-rings, .hv-lines, .hv-core { display: none; }
    .hv-tile { position: static; width: auto; animation: none; }
}
@media (max-width: 900px) {
    .header-row > .brand { margin-right: auto; }
    .header-search { display: none; }
    .header-search.is-open { display: block; position: absolute; left: 0; right: 0; top: 100%; padding: var(--s-3) var(--gutter); background: var(--surface); border-bottom: 1px solid var(--line); max-width: none; box-shadow: var(--shadow); }
    .menu-toggle { display: inline-grid; }
    .header-row > .header-cta { display: inline-flex; }
    .top-nav { display: none; }
    .top-nav.is-open { display: flex; flex-direction: column; align-items: stretch; position: absolute; left: 0; right: 0; top: 100%; margin: 0; background: var(--surface); border-bottom: 1px solid var(--line); padding: 10px var(--gutter) 18px; gap: 2px; box-shadow: var(--shadow-lg); max-height: calc(100vh - var(--header-h)); overflow-y: auto; animation: menu-in .16s ease-out; }
    .top-nav.is-open .nav-link { min-height: 50px; padding: 0 12px; font-size: 1rem; }
    .top-nav.is-open .dropdown { width: 100%; }
    .top-nav.is-open .dropdown > summary { width: 100%; }
    .top-nav.is-open .dropdown .caret { margin-left: auto; }
    .top-nav.is-open .dropdown .menu { position: static; width: auto; min-width: 0; border: 0; box-shadow: none; padding: 2px 0 8px; background: transparent; animation: none; }
    .top-nav.is-open .menu-title { display: none; }
    .top-nav.is-open .mega-grid { grid-template-columns: 1fr; }
    .top-nav.is-open .mega-grid a { padding: 8px 12px; }
    .top-nav.is-open .mega-icon { width: 34px; height: 34px; border-radius: 10px; }
    .top-nav.is-open .mega-all { justify-content: flex-start; padding: 10px 12px; margin-top: 4px; }
    .top-nav.is-open .nav-sep { width: auto; height: 1px; margin: 8px 0; }
    .top-nav.is-open .button { width: 100%; min-height: 48px; margin: 4px 0 0; font-size: 1rem; }
    .top-nav.is-open .user-menu > summary { width: 100%; border-radius: 14px; min-height: 52px; }
    .top-nav.is-open .user-menu .caret { margin-left: auto; }
    .top-nav.is-open .user-menu .menu { padding: 4px 0 0; }
}
@media (max-width: 760px) {
    :root { --gutter: 16px; --header-h: 64px; }
    .search-toggle { display: inline-grid; }
    .bottom-nav { display: flex; }
    .site-footer { padding-bottom: 28px; }
    body:has(.bottom-nav) .site-footer { padding-bottom: 92px; }
    .account-shell { grid-template-columns: 1fr; }
    .side-nav { display: flex; overflow-x: auto; position: static; padding: 6px; gap: 2px; }
    .side-nav .group { display: none; }
    .side-nav a { white-space: nowrap; padding: 8px 12px; }
    .page { padding-top: var(--s-4); }
    .page-head .button { width: 100%; }
    .stats { grid-template-columns: 1fr 1fr; }
    .panel { padding: var(--s-4); }
    .auth-card { padding: var(--s-5); }
    th, td { padding: 10px; }
    .stat .value { font-size: 1.35rem; }
    dl.summary { grid-template-columns: 1fr; gap: 2px 0; }
    dl.summary dt { margin-top: 10px; }
    dl.summary dt:first-child { margin-top: 0; }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px 24px; }
    .footer-grid > :first-child, .footer-grid > :last-child { grid-column: 1 / -1; }
    .footer-contact { grid-template-columns: 1fr; }
}
@media (min-width: 901px) { .search-toggle { display: none; } }
@media (max-width: 680px) {
    .hero { padding-bottom: 52px; }
    .hero-grid { padding-top: 30px; gap: 22px; }
    .hero-copy h1 { font-size: clamp(1.75rem, 8.3cqi, 2.4rem); margin: 18px 0 14px; letter-spacing: -0.04em; }
    .hero-copy .lead { font-size: 1rem; margin-bottom: 18px; }
    .hero-points { gap: 10px 18px; font-size: .9rem; }
    .hero-visual { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
    .hv-tile { padding: 10px; gap: 10px; border-radius: 16px; }
    .hv-icon { width: 36px; height: 36px; border-radius: 11px; }
    .hv-t4, .hv-t5 { display: none; }
    .ai-wrap { margin-top: -38px; padding: 0 12px; }
    .ai { border-radius: 22px; }
    .ai-head { padding: 14px 16px; gap: 12px; flex-wrap: wrap; }
    .ai-avatar { width: 42px; height: 42px; border-radius: 13px; }
    .ai-heading h2 { font-size: 1.08rem; }
    .ai-heading p { font-size: .82rem; }
    .ai-live { order: 3; margin-left: 0; font-size: .74rem; padding: 4px 10px; }
    .ai-head .ai-reset { margin-left: auto; }
    .chat-log { padding: 16px 16px 4px; max-height: none; overflow: visible; gap: 14px; }
    .msg-avatar { width: 30px; height: 30px; border-radius: 10px; }
    .msg { gap: 10px; }
    .msg.user .msg-body { max-width: 88%; }
    .msg-text { padding: 10px 14px; font-size: .95rem; }
    .recs, .skeletons { grid-template-columns: 1fr; }
    .skeleton:nth-child(n+2) { display: none; }
    .msg-body > .recs, .msg-body > .recs-head, .msg-body > .recs-more, .msg-body > .msg-follow, .msg-body > .msg-links, .msg-body > .skeletons { margin-left: -40px; }
    .rec-variant { min-height: 0; }
    .ai-form { margin: 12px 16px 0; padding: 5px 5px 5px 12px; border-radius: 16px; }
    .ai-form input { min-height: 46px; font-size: 1rem; }
    .ai-send { min-height: 46px; padding: 0 16px; border-radius: 12px; }
    .ai-send span { display: none; }
    .ai-prompts { flex-wrap: nowrap; overflow-x: auto; padding: 12px 16px 2px; scrollbar-width: none; -webkit-mask-image: linear-gradient(90deg, #000 88%, transparent); mask-image: linear-gradient(90deg, #000 88%, transparent); }
    .ai-prompts::-webkit-scrollbar { display: none; }
    .ai-prompts .label { flex: none; }
    .chip { flex: none; }
    .ai-note { padding: 12px 16px 16px; align-items: flex-start; }
    .ai-compact .chat-log.has-messages { padding: 16px 16px 4px; }
    .band { padding: 52px 0; }
    .ai-wrap + .band { padding-top: 44px; }
    .band-tight { padding: 0 0 56px; }
    .band .section-head { margin-bottom: 20px; }
    .band .section-head .arrow-link { font-size: .92rem; }
    .cat-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .cat-card { padding: 16px 14px 14px; border-radius: 18px; }
    .cat-icon { width: 44px; height: 44px; border-radius: 13px; margin-bottom: 6px; }
    .cat-name { font-size: .96rem; }
    .cat-desc { font-size: .8rem; }
    .cat-foot { padding-top: 10px; font-size: .78rem; }
    .grid-3 { grid-template-columns: 1fr; gap: 14px; }
    .product-card { padding: 18px; border-radius: 18px; }
    .pc-variant { min-height: 0; }
    .more-row .button { width: 100%; }
    .soon { padding: 20px 16px; border-radius: 22px; margin: 0 -4px; }
    .soon-head { gap: 12px; margin-bottom: 16px; align-items: flex-start; }
    .soon-bell { width: 46px; height: 46px; border-radius: 14px; }
    .soon-head h2 { font-size: 1.25rem; }
    .soon-head .arrow-link, .row-nav { display: none; }
    .soon-row { grid-auto-columns: 72%; gap: 12px; }
    .how { grid-template-columns: 1fr; gap: 12px; }
    .how li { text-align: left; display: grid; grid-template-columns: 58px minmax(0, 1fr); column-gap: 16px; padding: 18px; align-items: start; }
    .how-icon { grid-row: 1 / span 2; width: 54px; height: 54px; margin: 0; border-radius: 16px; }
    .how-icon b { width: 24px; height: 24px; font-size: .72rem; top: -7px; right: -7px; }
    .how h3 { margin: 2px 0 4px; font-size: 1rem; }
    .band-soft + .band-tight .trust { margin-top: -24px; }
    .trust { grid-template-columns: 1fr; padding: 18px; gap: 0; border-radius: 22px; }
    .trust > div { padding: 14px 4px; }
    .trust > div + div { border-left: 0; border-top: 1px solid rgba(255, 255, 255, .12); }
    .trust-icon { width: 42px; height: 42px; }
}
@media (max-width: 380px) {
    .brand-word { font-size: 1.2rem; }
    .brand .brand-mark { width: 30px; height: 30px; }
    .header-row { gap: 10px; }
    .header-row > .header-cta { padding: 0 12px; }
    .eyebrow { font-size: .78rem; padding-right: 12px; gap: 8px; }
    .eyebrow-icon { width: 22px; height: 22px; }
    .hero-points { flex-direction: column; gap: 8px; }
    .hv-text b { font-size: .82rem; }
    .hv-text small { font-size: .74rem; }
    .cat-desc { display: none; }
    .stats { grid-template-columns: 1fr; }
}
/* ---------- Search-first assistant layout (D-026) ---------- */
.ai-form { margin: 18px 24px 20px; }
.chat-log { padding: 20px 24px 8px; border-top: 0; max-height: clamp(360px, calc(100vh - 300px), 640px); }
.chat-log:not(:empty) + .ai-form { margin-top: 10px; }
.chat-log:empty { display: none; }
.ai-compact .chat-log { padding: 20px 24px 8px; }
.msg-body > .msg-text + .results { margin-top: 12px; }
.results { margin-top: 2px; }
.results-head { display: flex; align-items: baseline; justify-content: space-between; gap: 6px 14px; flex-wrap: wrap; margin: 0 0 10px; }
.results-head h2, .results-head h3 { font-size: 1.08rem; margin: 0; letter-spacing: -0.02em; }
.results-head h2 .muted, .results-head h3 .muted { font-family: var(--font); font-weight: 500; font-size: .92rem; }
.results-list { margin-top: 0; }
.rows { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; box-shadow: var(--shadow-xs); }
.rrow { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 14px; padding: 10px 12px 10px 14px; min-height: 62px; transition: background .15s; }
.rrow + .rrow { border-top: 1px solid var(--line); }
.rrow:hover { background: var(--surface-2); }
.rrow > .logo { width: 38px; height: 38px; border-radius: 11px; font-size: .8rem; }
.rrow-main { display: flex; flex-direction: column; min-width: 0; gap: 1px; }
.rrow-cat { font-size: .66rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rrow-name { font-family: var(--display); font-weight: 700; font-size: 1rem; line-height: 1.3; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rrow-price { text-align: right; white-space: nowrap; }
.rrow-price .price { font-family: var(--display); font-weight: 800; font-size: 1.05rem; letter-spacing: -0.02em; color: var(--ink); font-variant-numeric: tabular-nums; }
.rrow-action { min-width: 116px; }
.rrow.is-unavailable > .logo { filter: saturate(.5); }
.rrow.is-unavailable .rrow-action { background: var(--surface); color: var(--ink); border-color: var(--line-2); box-shadow: var(--shadow-xs); }
.rrow.is-unavailable .rrow-action:hover { color: var(--primary); border-color: var(--primary); }
.rows-more { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; min-height: 36px; padding: 0 12px; border: 1px dashed var(--line-2); border-radius: 10px; background: transparent; color: var(--primary); font: inherit; font-size: .86rem; font-weight: 600; cursor: pointer; }
.rows-more:hover { border-style: solid; border-color: var(--primary); background: var(--primary-soft); }
.row-skeleton { height: 62px; background: linear-gradient(100deg, var(--surface-2) 30%, var(--lav-2) 50%, var(--surface-2) 70%); background-size: 300% 100%; animation: shimmer 1.4s ease-in-out infinite; }
.row-skeleton + .row-skeleton { border-top: 1px solid var(--line); }

/* ---------- Quick-view popup ---------- */
html { scrollbar-gutter: stable; }
html.qv-open { overflow: hidden; }
.qv { padding: 0; border: 0; background: transparent; color: var(--ink); width: min(660px, calc(100vw - 32px)); max-width: none; max-height: min(88vh, 860px); margin: auto; overflow: visible; }
.qv::backdrop { background: rgba(14, 19, 48, .55); }
.qv[open] { animation: qv-in .18s ease-out; }
.qv[open]::backdrop { animation: qv-fade .18s ease-out; }
@keyframes qv-in { from { opacity: 0; transform: translateY(10px) scale(.985); } }
@keyframes qv-fade { from { opacity: 0; } }
.qv-panel { display: flex; flex-direction: column; max-height: min(88vh, 860px); background: var(--surface); border: 1px solid var(--line); border-radius: 22px; box-shadow: 0 40px 90px -30px rgba(14, 19, 48, .6); overflow: hidden; }
.qv-head { display: flex; align-items: center; gap: 14px; padding: 16px 18px 16px 20px; border-bottom: 1px solid var(--line); flex: none; }
.qv-logo { width: 46px; height: 46px; }
.qv-titles { min-width: 0; flex: 1; }
.qv-cat { margin: 0 0 2px; font-size: .68rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--primary); }
.qv-head h2 { margin: 0; font-size: 1.2rem; line-height: 1.25; }
.qv-close { width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); display: grid; place-items: center; cursor: pointer; flex: none; }
.qv-close:hover { color: var(--ink); border-color: var(--line-2); background: var(--surface-2); }
.qv-body { flex: 1 1 auto; overflow-y: auto; overscroll-behavior: contain; padding: 18px 20px 22px; min-height: 140px; }
.qv-foot { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 14px 20px; border-top: 1px solid var(--line); background: var(--surface-2); }
.qv-foot:empty { display: none; }
.qv-price { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.qv-price .label { font-size: .68rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.qv-price .value { font-family: var(--display); font-weight: 800; font-size: 1.6rem; letter-spacing: -0.03em; line-height: 1.1; }
.qv-price .value small { font-family: var(--font); font-size: .78rem; font-weight: 600; color: var(--muted); margin-left: 4px; letter-spacing: 0; }
.qv-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; margin-left: auto; }
.qv-actions .button { min-height: 48px; padding: 0 24px; font-size: 1rem; }
.qv-actions .qty { display: flex; align-items: center; gap: 6px; font-size: .85rem; color: var(--muted); font-weight: 500; }
.qv-actions .qty select { width: auto; min-height: 42px; padding: 6px 30px 6px 10px; }
.qv-hint { width: 100%; margin: 0; font-size: .82rem; color: var(--muted); text-align: right; }
.qv-section { margin: 0 0 18px; }
.qv-section:last-child { margin-bottom: 0; }
.qv-section-title { margin: 0 0 10px; font-family: var(--font); font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.qv-desc { margin: 0; color: var(--ink-2); line-height: 1.6; }
.qv-options { display: grid; gap: 8px; }
.qv-option { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border: 1.5px solid var(--line); border-radius: 14px; cursor: pointer; margin: 0; font-weight: 400; transition: border-color .15s, background .15s; }
.qv-option:hover { border-color: var(--line-2); }
.qv-option input { flex: none; }
.qv-option:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.qv-option .o-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.qv-option .o-name { font-weight: 600; font-size: .95rem; color: var(--ink); }
.qv-option .o-sub { font-size: .8rem; color: var(--muted); }
.qv-option .o-price { font-family: var(--display); font-weight: 800; white-space: nowrap; }
.qv-facts { margin: 0; display: grid; gap: 12px; }
.qv-fact { display: grid; grid-template-columns: 22px minmax(0, 1fr); column-gap: 10px; }
.qv-fact .icon { color: var(--primary); width: 18px; height: 18px; margin-top: 2px; grid-row: 1 / span 2; }
.qv-fact dt { font-weight: 600; font-size: .9rem; color: var(--ink); }
.qv-fact dd { margin: 1px 0 0; font-size: .9rem; color: var(--ink-2); line-height: 1.5; overflow-wrap: anywhere; }
.qv-fact dd a { font-weight: 600; }
.qv-field { margin: 0; }
.qv-field label { font-size: .9rem; }
.qv-field .help { margin: 6px 0 0; font-size: .82rem; color: var(--muted); }
.qv-consent { display: flex; align-items: flex-start; gap: 10px; margin: 0; font-weight: 400; font-size: .9rem; color: var(--ink-2); }
.qv-consent input { margin-top: 3px; flex: none; }
.qv-notice { margin: 0 0 16px; }
.qv-skel { display: grid; gap: 12px; }
.qv-skel i { display: block; height: 14px; border-radius: 7px; background: linear-gradient(100deg, var(--surface-2) 30%, var(--lav-2) 50%, var(--surface-2) 70%); background-size: 300% 100%; animation: shimmer 1.4s ease-in-out infinite; }
.qv-skel i:nth-child(1) { width: 70%; } .qv-skel i:nth-child(2) { width: 92%; } .qv-skel i:nth-child(3) { width: 84%; height: 56px; border-radius: 14px; } .qv-skel i:nth-child(4) { width: 60%; }
@media (prefers-color-scheme: dark) { .qv::backdrop { background: rgba(0, 0, 0, .6); } }
@media (max-width: 680px) {
    .ai-form { margin: 14px 16px 16px; }
    .chat-log { padding: 16px 16px 6px; max-height: 60vh; max-height: 60dvh; overflow-y: auto; }
    .ai-compact .chat-log { padding: 16px 16px 6px; }
    .ai-form { margin-bottom: calc(14px + env(safe-area-inset-bottom)); }
    .msg-body > .results { margin-left: -40px; }
    .rrow { grid-template-columns: 36px minmax(0, 1fr) auto; grid-template-areas: "logo main action" "logo price action"; column-gap: 12px; row-gap: 1px; padding: 10px 10px 10px 12px; }
    .rrow > .logo { grid-area: logo; width: 36px; height: 36px; }
    .rrow-main { grid-area: main; }
    .rrow-price { grid-area: price; text-align: left; }
    .rrow-price .price { font-size: .98rem; }
    .rrow-action { grid-area: action; min-width: 0; padding: 0 12px; }
    .results-head h2, .results-head h3 { font-size: 1rem; }
    .qv { width: 100%; max-height: 94vh; max-height: 94dvh; margin: auto 0 0; }
    .qv-panel { max-height: 94vh; max-height: 94dvh; border-radius: 22px 22px 0 0; border-bottom: 0; }
    .qv[open] { animation: qv-up .22s ease-out; }
    @keyframes qv-up { from { transform: translateY(48px); opacity: .5; } }
    .qv-head { padding: 14px 14px 14px 16px; }
    .qv-head h2 { font-size: 1.08rem; }
    .qv-body { padding: 16px; }
    .qv-foot { padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); }
    .qv-price .value { font-size: 1.35rem; }
    .qv-actions .button { padding: 0 18px; }
}
@media (max-width: 380px) {
    .rrow-action { padding: 0 10px; font-size: .84rem; }
    .qv-actions { width: 100%; }
    .qv-actions .button { flex: 1; }
}

/* ---------- Checkout: how to pay (D-027) ---------- */
.pay-methods { border: 0; margin: 0; padding: 0; display: grid; gap: 10px; }
.pay-methods legend { padding: 0; margin-bottom: 10px; font-family: var(--display); font-weight: 700; font-size: 1rem; }
.pay-option { display: flex; align-items: center; gap: 12px; margin: 0; padding: 14px; border: 1.5px solid var(--line); border-radius: 14px; cursor: pointer; font-weight: 400; transition: border-color .15s, background .15s; }
.pay-option:hover { border-color: var(--line-2); }
.pay-option:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.pay-option input { flex: none; }
.pay-option > .icon { color: var(--primary); }
.pay-option.is-disabled { cursor: not-allowed; opacity: .65; background: var(--surface-2); }
.po-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.po-title { font-weight: 600; color: var(--ink); }
.po-sub { font-size: .84rem; color: var(--muted); line-height: 1.45; }

/* ---------- Checkout: agree to the terms (D-028) ---------- */
.agree { margin-top: 14px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--surface-2); transition: border-color .15s, background .15s; }
.agree .check { margin: 0; align-items: center; }
.agree .check input { margin-top: 0; }
.agree label { font-size: .92rem; line-height: 1.45; color: var(--ink); cursor: pointer; }
.agree:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.agree.has-error:not(:has(input:checked)) { border-color: var(--bad); background: var(--bad-soft); }
.agree-error { margin: 8px 0 0; font-size: .85rem; font-weight: 500; color: var(--bad); }
.agree:has(input:checked) .agree-error { display: none; }
form:has(.agree input:not(:checked)) button[type="submit"] { opacity: .55; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } html { scroll-behavior: auto; } }
@media print { .site-header, .site-footer, .bottom-nav, .admin-side, .admin-top, .button, .menu-toggle { display: none !important; } body { background: #fff; } .panel, .card, .table-wrap { box-shadow: none; } }

/* ---------- Sign-in security (D-037): recovery codes, shown once ---------- */
.recovery-codes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 24px; margin: var(--s-4) 0; padding: 14px 18px 14px 40px; font-family: var(--mono); font-size: 1.05rem; letter-spacing: .04em; background: var(--bg-2); border: 1px dashed var(--line-2); border-radius: var(--r-sm); user-select: all; }
.recovery-codes li { padding-left: 4px; }
@media (max-width: 420px) { .recovery-codes { grid-template-columns: 1fr; } }
