/* KSHIMMY.xyz — same palette, type and components as the previous site, trimmed to what the fresh site uses. */

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

:root{
    --mono:'JetBrains Mono', ui-monospace,'SFMono-Regular',Menlo,monospace;
    --sans:'Hanken Grotesk',-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;
    --display:var(--mono);
    --radius:0px; --radius-sm:2px;

    /* Same grays as the in-game menu: body 17, tabs 12, borders 10 / 48 */
    --bg:#0c0c0c; --bg-soft:#161616; --panel:#111111; --panel-2:#1a1a1a;
    --hover:#222222; --line:#2a2a2a; --line-2:#3a3a3a; --edge:#0a0a0a;
    --ink:#e8e8e8; --ink-2:#aaaaaa; --ink-3:#6e6e6e; --ink-4:#484848;
    /* The menu's default accent (212,160,23) and its cyan-magenta-lime bar */
    --iris:#d4a017; --iris-2:#ecbb3a; --iris-weak:rgba(212,160,23,.12); --iris-line:rgba(212,160,23,.4);
    --rainbow:linear-gradient(90deg,#37b1da,#c954c0,#cce336);

    --ok:#37c793; --ok-weak:rgba(55,199,147,.13);
    --danger:#f0687a; --danger-weak:rgba(240,104,122,.13);
    --warn:#e6b24e; --warn-weak:rgba(230,178,78,.12);
    --r-admin:#37c793; --r-member:#8b8cf2;
}

[hidden]{ display:none !important; }
html{ -webkit-text-size-adjust:100%; }
body{
    background:var(--bg); color:var(--ink);
    font-family:var(--sans); font-size:14.5px; line-height:1.6; letter-spacing:-0.005em;
    min-height:100vh; display:flex; flex-direction:column;
    -webkit-font-smoothing:antialiased; text-rendering:optimizeLegibility;
}
/* Dotted backdrop with a soft glow at the top */
body::before{
    content:''; position:fixed; inset:0; z-index:0; pointer-events:none;
    background-image:
        radial-gradient(circle at 1px 1px, rgba(255,255,255,.026) 1px, transparent 0),
        radial-gradient(ellipse 90% 55% at 50% -8%, color-mix(in srgb, var(--iris) 8%, transparent), transparent 60%);
    background-size:22px 22px, 100% 100%;
    -webkit-mask-image:linear-gradient(to bottom,#000,rgba(0,0,0,.35) 60%,transparent);
    mask-image:linear-gradient(to bottom,#000,rgba(0,0,0,.35) 60%,transparent);
}

h1{ font-family:var(--display); font-weight:600; letter-spacing:-0.025em; line-height:1.15; font-size:26px; }
h2{ font-family:var(--display); font-size:1.02rem; font-weight:600; }
p{ color:var(--ink-2); margin-bottom:.55rem; }
a{ color:var(--iris-2); text-decoration:none; transition:color .15s; }
a:hover{ color:var(--ink); }
.mono{ font-family:var(--mono); }
.dim{ color:var(--ink-3); }
.tnum{ font-variant-numeric:tabular-nums; }

/* ── Forms ─────────────────────────────────────────────────────────────── */
label{ display:block; font-size:.82rem; font-weight:500; margin-bottom:6px; color:var(--ink-2); }
input[type=text],input[type=password],input[type=email],input[type=number],input[type=file],textarea,select{
    width:100%; padding:9px 12px; margin-bottom:.85rem;
    background:var(--bg-soft); border:1px solid var(--line-2); border-radius:var(--radius-sm);
    color:var(--ink); font-family:var(--sans); font-size:.92rem; line-height:1.5; outline:none;
    transition:border-color .15s, box-shadow .15s;
}
input::placeholder,textarea::placeholder{ color:var(--ink-4); }
input:focus,textarea:focus,select:focus{ border-color:var(--iris-line); box-shadow:0 0 0 3px var(--iris-weak); background:var(--bg); }
select option{ background:var(--panel-2); }
textarea{ resize:vertical; min-height:90px; }
.hint{ font-size:12.5px; color:var(--ink-3); margin:-6px 0 14px; }
.check{ display:flex; align-items:center; gap:9px; font-size:13.5px; color:var(--ink-2); cursor:pointer; }
.check input{ width:auto; margin:0; accent-color:var(--iris); }

.btn,button{
    display:inline-flex; align-items:center; justify-content:center; gap:8px; height:36px; padding:0 15px;
    border-radius:9px; border:1px solid transparent; cursor:pointer; white-space:nowrap;
    font-family:var(--sans); font-size:13.5px; font-weight:600; transition:.14s;
    background:var(--iris); color:#fff;
}
.btn:hover,button:hover{ background:var(--iris-2); color:#fff; }
.btn-ghost{ background:var(--panel); color:var(--ink); border-color:var(--line-2); }
.btn-ghost:hover{ background:var(--panel-2); color:var(--ink); }
.btn-danger{ background:var(--danger-weak); color:var(--danger); border-color:rgba(240,104,122,.25); }
.btn-danger:hover{ background:rgba(240,104,122,.2); color:var(--danger); }
.btn-ok{ background:var(--ok-weak); color:var(--ok); border-color:rgba(55,199,147,.25); }
.btn-ok:hover{ background:rgba(55,199,147,.2); color:var(--ok); }
.btn-sm{ height:30px; padding:0 11px; font-size:12.5px; border-radius:8px; }
.btn-lg{ height:42px; padding:0 20px; font-size:14.5px; }
.btn-block{ width:100%; }

/* ── Layout ────────────────────────────────────────────────────────────── */
.page{ position:relative; z-index:1; flex:1; }
.container{ max-width:1120px; margin:0 auto; padding:30px 22px 8px; }
.flash-wrap{ padding-top:16px; padding-bottom:0; }
.pagehead{ display:flex; align-items:flex-end; justify-content:space-between; gap:20px; margin-bottom:22px; flex-wrap:wrap; }
.eyebrow{ font-family:var(--mono); font-size:11px; font-weight:500; letter-spacing:.16em; text-transform:uppercase; color:var(--ink-3); margin-bottom:9px; }
.sub{ color:var(--ink-2); margin-top:6px; max-width:60ch; }
.grid-2{ display:grid; grid-template-columns:1fr 1fr; gap:16px; align-items:start; }
.grid-main{ display:grid; grid-template-columns:1fr 312px; gap:16px; align-items:start; }
.stack{ display:flex; flex-direction:column; gap:16px; }
@media (max-width:860px){ .grid-2,.grid-main{ grid-template-columns:1fr; } }

.panel{ background:var(--panel); border:1px solid var(--line); border-radius:var(--radius); }
.panel-head{ display:flex; align-items:center; justify-content:space-between; gap:12px; padding:13px 16px; border-bottom:1px solid var(--line); }
.panel-title{ font-family:var(--mono); font-size:11.5px; font-weight:600; letter-spacing:.12em; text-transform:uppercase; color:var(--ink-2); }
.panel-pad{ padding:16px; }

.alert{ display:flex; gap:9px; padding:11px 14px; border-radius:10px; font-size:13.5px; margin-bottom:16px; border:1px solid; }
.alert-err{ background:var(--danger-weak); color:var(--danger); border-color:rgba(240,104,122,.28); }
.alert-ok{ background:var(--ok-weak); color:var(--ok); border-color:rgba(55,199,147,.25); }

.badge{ display:inline-flex; align-items:center; padding:2px 8px; border-radius:5px; border:1px solid;
    font-family:var(--mono); font-size:.68rem; font-weight:600; letter-spacing:.08em; text-transform:uppercase; vertical-align:middle; }
.badge-admin{ color:var(--r-admin); background:var(--ok-weak); border-color:rgba(55,199,147,.25); }
.badge-member{ color:var(--r-member); background:var(--iris-weak); border-color:var(--iris-line); }
.badge-banned{ color:var(--danger); background:var(--danger-weak); border-color:rgba(240,104,122,.3); }
.badge-ok{ color:var(--ok); background:var(--ok-weak); border-color:rgba(55,199,147,.25); }
.badge-warn{ color:var(--warn); background:var(--warn-weak); border-color:rgba(230,178,78,.24); }
.badge-dim{ color:var(--ink-3); background:var(--panel-2); border-color:var(--line-2); }

/* ── Navigation ────────────────────────────────────────────────────────── */
.site-nav{ position:sticky; top:0; z-index:100; background:color-mix(in srgb, var(--bg) 82%, transparent);
    backdrop-filter:blur(18px) saturate(140%); -webkit-backdrop-filter:blur(18px) saturate(140%); border-bottom:1px solid var(--line); }
.nav-inner{ max-width:1120px; margin:0 auto; padding:0 22px; height:58px; display:flex; align-items:center; gap:22px; }
.nav-brand{ display:flex; align-items:center; gap:10px; }
.nav-logo{ width:32px; height:32px; border-radius:9px; overflow:hidden; display:block; }
.nav-logo img{ width:100%; height:100%; object-fit:contain; display:block; }
.nav-word{ font-family:var(--display); font-weight:600; font-size:16px; letter-spacing:-0.02em; color:var(--ink); }
.tld{ font-family:var(--mono); font-weight:500; font-size:12.5px; color:var(--ink-3); letter-spacing:0; }
.nav-left,.nav-right{ display:flex; align-items:center; gap:2px; }
.nav-right{ margin-left:auto; }
.nav-link{ padding:7px 12px; border-radius:8px; color:var(--ink-2); font-size:13.5px; font-weight:500; white-space:nowrap; }
.nav-link:hover,.nav-link.active{ color:var(--ink); background:var(--panel-2); }
.nav-link-admin{ color:var(--r-admin); }
.nav-link-admin:hover,.nav-link-admin.active{ background:rgba(55,199,147,.1); color:var(--r-admin); }
.nav-link-logout{ color:var(--danger); }
.nav-link-logout:hover{ background:var(--danger-weak); color:var(--danger); }
.nav-me{ margin-left:6px; display:block; }
@media (max-width:640px){ .nav-inner{ gap:10px; padding:0 14px; } .nav-word{ display:none; } .nav-link{ padding:7px 8px; } }

.site-foot{ position:relative; z-index:1; border-top:1px solid var(--line); margin-top:40px; }
.foot-in{ max-width:1120px; margin:0 auto; padding:18px 22px; display:flex; justify-content:space-between; font-size:13px;
    font-family:var(--display); font-weight:600; color:var(--ink-2); }
.foot-dim{ font-family:var(--mono); font-weight:400; font-size:11.5px; color:var(--ink-3); }

/* ── Avatars and names ─────────────────────────────────────────────────── */
.av{ display:inline-grid; place-items:center; border-radius:50%; overflow:hidden; flex:none;
    background:var(--panel-2); border:1px solid var(--line-2); color:var(--r-member);
    font-family:var(--mono); font-weight:600; }
.av img{ width:100%; height:100%; object-fit:cover; display:block; }
.av-admin{ color:var(--r-admin); border-color:rgba(55,199,147,.4); }
.uname{ font-weight:600; color:var(--r-member); }
.uname-admin{ color:var(--r-admin); }
.uname-banned{ text-decoration:line-through; color:var(--ink-3); }
.dot{ display:inline-block; width:8px; height:8px; border-radius:50%; background:var(--ink-4); }
.dot-on{ background:var(--ok); box-shadow:0 0 0 3px var(--ok-weak); }

/* ── Sign-in card ──────────────────────────────────────────────────────── */
.auth{ max-width:420px; margin:56px auto 0; padding:28px; background:var(--panel); border:1px solid var(--line); border-radius:16px; }
.auth h1{ font-size:23px; margin-bottom:6px; }
.auth > p{ font-size:13.5px; margin-bottom:22px; }
.auth-foot{ margin-top:18px; padding-top:16px; border-top:1px solid var(--line); font-size:13px; color:var(--ink-3); text-align:center; }
@media (max-width:480px){ .auth{ margin:24px 14px 0; padding:22px; } }

/* ── Tables ────────────────────────────────────────────────────────────── */
.table-wrap{ overflow-x:auto; }
table{ width:100%; border-collapse:collapse; font-size:13.5px; }
th{ text-align:left; padding:10px 16px; font-family:var(--mono); font-size:11px; font-weight:600; letter-spacing:.1em; text-transform:uppercase;
    color:var(--ink-3); border-bottom:1px solid var(--line); white-space:nowrap; }
td{ padding:10px 16px; border-bottom:1px solid var(--line); vertical-align:middle; }
tr:last-child td{ border-bottom:none; }
tbody tr:hover{ background:var(--bg-soft); }
.cell-user{ display:flex; align-items:center; gap:10px; }
.row-actions{ display:flex; gap:6px; flex-wrap:wrap; }
.row-actions form{ display:inline; }
.empty{ padding:28px 16px; text-align:center; color:var(--ink-3); }

/* ── Profile ───────────────────────────────────────────────────────────── */
.profile-top{ display:flex; align-items:center; gap:18px; padding:22px; }
.profile-name{ font-family:var(--display); font-size:24px; font-weight:600; letter-spacing:-0.02em; display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.uid{ font-family:var(--mono); font-size:12px; color:var(--ink-3); border:1px solid var(--line-2); border-radius:6px; padding:1px 7px; }
.facts{ display:grid; grid-template-columns:auto 1fr; gap:9px 18px; font-size:13.5px; }
.facts dt{ color:var(--ink-3); }
.facts dd{ color:var(--ink); }
.bio{ white-space:pre-wrap; word-break:break-word; color:var(--ink); }

/* ── Stat tiles and tabs ───────────────────────────────────────────────── */
.stats{ display:grid; grid-template-columns:repeat(auto-fit,minmax(150px,1fr)); gap:12px; margin-bottom:16px; }
.stat{ background:var(--panel); border:1px solid var(--line); border-radius:var(--radius); padding:14px 16px; }
.stat b{ display:block; font-family:var(--display); font-size:24px; font-weight:600; }
.stat span{ font-family:var(--mono); font-size:11px; letter-spacing:.1em; text-transform:uppercase; color:var(--ink-3); }
.tabs{ display:flex; gap:4px; margin-bottom:16px; border-bottom:1px solid var(--line); }
.tab{ padding:9px 14px; font-size:13.5px; font-weight:600; color:var(--ink-2); border-bottom:2px solid transparent; margin-bottom:-1px; }
.tab:hover{ color:var(--ink); }
.tab.active{ color:var(--iris-2); border-bottom-color:var(--iris); }
.inline-form{ display:flex; gap:8px; align-items:flex-end; flex-wrap:wrap; }
.inline-form > div{ flex:1; min-width:120px; }
.inline-form input,.inline-form select{ margin-bottom:0; }
.code{ font-family:var(--mono); font-size:13px; letter-spacing:.04em; color:var(--ink); background:var(--bg-soft); border:1px solid var(--line-2);
    border-radius:6px; padding:2px 8px; user-select:all; }

/* ── Forum ─────────────────────────────────────────────────────────────── */
.alert-warn{ background:var(--warn-weak); color:var(--warn); border-color:rgba(230,178,78,.28); }
.crumbs{ font-size:13px; color:var(--ink-3); margin-bottom:14px; }
.crumbs span{ margin:0 4px; color:var(--ink-4); }
.sec-title{ font-family:var(--display); font-weight:600; font-size:15px; color:var(--ink); }
.sec-title:hover{ color:var(--iris-2); }
.trow{ display:flex; align-items:center; gap:13px; padding:12px 16px; border-bottom:1px solid var(--line); color:inherit; }
.trow:last-child{ border-bottom:none; }
.trow:hover{ background:var(--bg-soft); color:inherit; }
.trow-title{ display:flex; align-items:center; gap:8px; font-weight:600; color:var(--ink); min-width:0; }
.trow-title > span:not(.badge){ overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.post{ display:flex; border-top:1px solid var(--line); }
.post:first-child{ border-top:none; }
.post-side{ width:150px; flex:none; padding:16px 12px; border-right:1px solid var(--line); background:var(--bg-soft);
    display:flex; flex-direction:column; align-items:center; gap:6px; text-align:center; }
.post:first-child .post-side{ border-top-left-radius:var(--radius); }
.post-main{ flex:1; min-width:0; padding:14px 18px 18px; }
.post-meta{ display:flex; justify-content:space-between; align-items:center; gap:10px; font-size:12px; color:var(--ink-3);
    padding-bottom:10px; margin-bottom:12px; border-bottom:1px solid var(--line); }
.post-body{ color:var(--ink); word-break:break-word; line-height:1.65; }
.post-body a{ text-decoration:underline; }
.bb-quote{ margin:8px 0; padding:9px 13px; border-left:3px solid var(--iris-line); background:var(--bg-soft); border-radius:0 8px 8px 0; color:var(--ink-2); }
.bb-quote cite{ display:block; font-style:normal; font-size:12px; font-weight:600; color:var(--iris-2); margin-bottom:4px; }
.bb-code{ margin:8px 0; padding:11px 13px; background:var(--bg-soft); border:1px solid var(--line-2); border-radius:8px;
    font-family:var(--mono); font-size:12.5px; white-space:pre-wrap; word-break:break-word; overflow-x:auto; }
.bb-bar{ display:flex; gap:5px; flex-wrap:wrap; margin-bottom:6px; }
@media (max-width:640px){
    .post{ flex-direction:column; }
    .post-side{ width:auto; flex-direction:row; justify-content:flex-start; border-right:none; border-bottom:1px solid var(--line); padding:10px 14px; }
}

/* ── Chat (compact: one line per message) ──────────────────────────────── */
.chat-page{ max-width:820px; }
.chat .panel-head{ padding:9px 14px; }
.chat-scroll{ overflow-y:auto; padding:8px 14px; display:flex; flex-direction:column; gap:4px; }
.chat-scroll::-webkit-scrollbar{ width:8px; }
.chat-scroll::-webkit-scrollbar-thumb{ background:var(--line-2); border-radius:8px; }
.msg{ display:flex; gap:8px; align-items:flex-start; font-size:13.5px; line-height:1.5; }
.msg .av{ margin-top:1px; }
.msg-b{ min-width:0; flex:1; word-break:break-word; }
.msg-b .uname{ margin-right:6px; }
.msg-t{ font-family:var(--mono); font-size:10.5px; color:var(--ink-4); margin-right:7px; }
.msg-txt{ color:var(--ink); }
.msg-x{ font-size:11px; color:var(--ink-4); margin-left:8px; visibility:hidden; }
.msg:hover .msg-x{ visibility:visible; }
.msg-x:hover{ color:var(--danger); }
.chat-input{ display:flex; align-items:center; gap:8px; padding:8px 14px; border-top:1px solid var(--line); }
.chat-input input{ margin:0; flex:1; padding:6px 10px; }
.chat-error{ color:var(--danger); font-size:12.5px; padding:0 14px 10px; }
/* ── Role permissions ──────────────────────────────────────────────────── */
.perm-grid{ display:grid; grid-template-columns:repeat(auto-fit,minmax(300px,1fr)); gap:8px 18px; }
.perm-grid .check{ align-items:flex-start; margin:0; }
.perm-grid .check input{ margin-top:4px; }

/* ── Profile banner ────────────────────────────────────────────────────── */
.pcard{ overflow:hidden; }
.pbanner{ position:relative; width:100%; aspect-ratio:15 / 4; max-height:280px; background:var(--bg-soft); border-bottom:2px solid var(--rc, var(--line)); }
.pbanner img{ width:100%; height:100%; object-fit:cover; display:block; }
.pbanner::after{ content:''; position:absolute; left:0; right:0; bottom:0; height:38%; background:linear-gradient(to bottom, transparent, var(--panel)); }
.profile-top.has-banner{ position:relative; margin-top:-34px; }
.profile-top.has-banner .av{ box-shadow:0 0 0 4px var(--panel); }
/* -- Administration: one user ------------------------------------------------ */
.manage-head{ display:flex; align-items:center; gap:14px; }

/* -- Edit profile -------------------------------------------------------------- */
.ep{ display:grid; grid-template-columns:200px 1fr; gap:20px; align-items:start; }
.ep-nav{ position:sticky; top:16px; display:flex; flex-direction:column; gap:2px; }
.ep-nav a{ display:block; padding:9px 12px; border-radius:8px; color:var(--ink-2); font-weight:600; font-size:13.5px; border:1px solid transparent; }
.ep-nav a:hover{ color:var(--ink); background:var(--panel); }
.ep-nav a.active{ color:var(--ink); background:var(--panel); border-color:var(--line-2); box-shadow:inset 2px 0 0 var(--iris); }
.ep-pane{ display:none; }
.ep-pane.active{ display:block; }
.ep-row{ display:grid; grid-template-columns:190px 1fr; gap:18px; padding:18px 16px; border-top:1px solid var(--line); }
.ep-row:first-of-type{ border-top:0; }
.ep-row h3{ font-size:13.5px; font-weight:600; color:var(--ink); margin-bottom:3px; }
.ep-row .ep-help{ font-size:12.5px; color:var(--ink-3); line-height:1.45; }
.ep-row input,.ep-row textarea{ margin-bottom:0; }
.ep-actions{ display:flex; gap:8px; flex-wrap:wrap; margin-top:10px; }
.ep-pending{ display:inline-flex; align-items:center; height:30px; font-size:12.5px; color:var(--warn); }

/* Live preview of the profile header */
.ep-preview{ border-bottom:1px solid var(--line); border-radius:var(--radius) var(--radius) 0 0; overflow:hidden; }
.ep-banner{ aspect-ratio:15/4; background:linear-gradient(120deg, var(--panel-2), var(--bg-soft)); display:grid; place-items:center; color:var(--ink-4); font-size:12.5px; }
.ep-banner img{ width:100%; height:100%; object-fit:cover; display:block; }
.ep-ident{ display:flex; align-items:flex-end; gap:14px; padding:0 16px 14px; margin-top:-34px; position:relative; }
.ep-ident .ep-av{ width:84px; height:84px; border-radius:50%; overflow:hidden; border:3px solid var(--panel); background:var(--panel-2); display:grid; place-items:center; font-size:30px; font-weight:700; flex:none; }
.ep-ident .ep-av img{ width:100%; height:100%; object-fit:cover; display:block; }
.ep-ident .ep-name{ font-family:var(--display); font-size:20px; font-weight:600; padding-bottom:6px; }

/* Sticky bar with the one Save button */
.ep-save{ position:sticky; bottom:14px; z-index:5; margin-top:16px; display:flex; align-items:center; justify-content:space-between; gap:12px;
    padding:10px 12px 10px 16px; background:var(--panel-2); border:1px solid var(--line-2); border-radius:var(--radius); box-shadow:0 10px 30px rgba(0,0,0,.45); }
.ep-save span{ font-size:13px; color:var(--ink-2); }
.ep-save.dirty{ border-color:var(--iris-line); }
.ep-save.dirty span{ color:var(--ink); }

/* Crop dialog */
.crop-back{ position:fixed; inset:0; z-index:50; background:rgba(5,6,9,.78); display:grid; place-items:center; padding:16px; }
.crop-box{ width:min(680px,100%); background:var(--panel); border:1px solid var(--line-2); border-radius:var(--radius); overflow:hidden; }
.crop-stage{ position:relative; background:#07080b; overflow:hidden; cursor:grab; touch-action:none; user-select:none; }
.crop-stage.dragging{ cursor:grabbing; }
.crop-stage canvas{ display:block; width:100%; height:100%; }
.crop-frame{ position:absolute; pointer-events:none; box-shadow:0 0 0 9999px rgba(5,6,9,.66); outline:2px solid rgba(255,255,255,.85); }
.crop-frame.round{ border-radius:50%; }
.crop-bar{ display:flex; align-items:center; gap:12px; padding:12px 16px; border-top:1px solid var(--line); }
.crop-bar input[type=range]{ flex:1; margin:0; padding:0; height:auto; accent-color:var(--iris); background:none; border:0; }
.crop-bar .crop-z{ width:30px; height:30px; padding:0; font-size:17px; line-height:1; }
.crop-foot{ display:flex; justify-content:space-between; align-items:center; gap:8px; padding:12px 16px; border-top:1px solid var(--line); }

@media (max-width:760px){
    .ep{ grid-template-columns:1fr; }
    .ep-nav{ position:static; flex-direction:row; flex-wrap:wrap; }
    .ep-row{ grid-template-columns:1fr; gap:10px; }
}
/* ══════════════════════════════════════════════════════════════════════════
   Menu look: the website wears the same frame as the in-game menu — flat dark
   panels with a double border, square corners, the colour bar on top.
   ══════════════════════════════════════════════════════════════════════════ */
body::before{ display:none; }
::selection{ background:var(--iris); color:#111; }
*{ scrollbar-color:var(--line-2) var(--bg); }

.rainbow{ position:sticky; top:0; z-index:101; height:3px; background:var(--rainbow); box-shadow:0 1px 0 var(--edge); }
.site-nav{ top:3px; background:#0c0c0c; backdrop-filter:none; -webkit-backdrop-filter:none; border-bottom:1px solid var(--line); box-shadow:0 1px 0 var(--edge); }
.nav-inner{ height:50px; }
.nav-logo{ width:34px; height:34px; border-radius:0; overflow:visible; }
.nav-word{ font-size:14px; letter-spacing:.06em; color:var(--iris); }
.nav-link{ border-radius:0; height:50px; display:flex; align-items:center; padding:0 12px; font-size:13px; }
.nav-link:hover{ background:rgba(255,255,255,.04); }
.nav-link.active{ color:var(--iris-2); background:var(--iris-weak); box-shadow:inset 0 -2px 0 var(--iris); }
.nav-link-admin.active{ box-shadow:inset 0 -2px 0 var(--r-admin); }

h1{ font-size:20px; letter-spacing:.04em; text-transform:uppercase; color:var(--iris); }
h1 .uid{ text-transform:none; }
.pagehead{ position:relative; align-items:center; padding-bottom:12px; border-bottom:1px solid var(--line); }
.pagehead::after{ content:''; position:absolute; left:0; bottom:-1px; width:110px; height:1px; background:var(--iris); }
.eyebrow{ margin-bottom:5px; }

/* Double border: light inner line, near-black outer line, soft shadow */
.panel,.stat,.auth,.crop-box,.ep-save{ border:1px solid var(--line-2); box-shadow:0 0 0 1px var(--edge), 0 6px 18px rgba(0,0,0,.45); border-radius:0; }
.panel-head{ background:#0c0c0c; padding:10px 14px; }
.panel-title{ color:var(--ink-2); }
.panel-title::before{ content:''; display:inline-block; width:3px; height:9px; margin-right:8px; background:var(--iris); vertical-align:-1px; }
.auth{ position:relative; }
.auth::before,.pcard::before{ content:''; display:block; height:3px; background:var(--rainbow); }
.auth::before{ position:absolute; left:0; right:0; top:0; }
.auth h1{ font-size:19px; }
.stat b{ color:var(--iris-2); }

.btn,button{ border-radius:2px; height:34px; background:linear-gradient(#d9a620,#b3860f); color:#141414; border:1px solid var(--edge); box-shadow:inset 0 1px 0 rgba(255,255,255,.22); }
.btn:hover,button:hover{ background:linear-gradient(#ecbb3a,#c4951a); color:#141414; }
button:disabled{ opacity:.45; cursor:default; }
.btn-ghost{ background:var(--panel-2); color:var(--ink); border-color:var(--line-2); box-shadow:0 0 0 1px var(--edge); }
.btn-ghost:hover{ background:var(--hover); color:var(--iris-2); }
.btn-danger,.btn-ok{ box-shadow:0 0 0 1px var(--edge); }
.btn-danger{ background:var(--danger-weak); color:var(--danger); border-color:rgba(240,104,122,.3); }
.btn-danger:hover{ background:rgba(240,104,122,.22); color:var(--danger); }
.btn-ok{ background:var(--ok-weak); color:var(--ok); border-color:rgba(55,199,147,.3); }
.btn-ok:hover{ background:rgba(55,199,147,.22); color:var(--ok); }
.btn-sm{ height:28px; border-radius:2px; }
.btn-lg{ height:40px; }

input[type=text],input[type=password],input[type=email],input[type=number],input[type=file],textarea,select{ box-shadow:0 0 0 1px var(--edge); }
input:focus,textarea:focus,select:focus{ border-color:var(--iris); box-shadow:0 0 0 1px var(--edge); background:var(--bg-soft); }
.alert,.badge,.uid,.code,.bb-code,.bb-quote{ border-radius:2px; }
.badge-member{ color:var(--r-member); background:rgba(139,140,242,.12); border-color:rgba(139,140,242,.3); }
.badge-ingame{ color:var(--ok); background:var(--ok-weak); border-color:rgba(55,199,147,.35); }
.badge-ingame::before{ content:''; width:6px; height:6px; margin-right:6px; background:var(--ok); border-radius:50%; animation:ingame 1.6s ease-in-out infinite; }
@keyframes ingame{ 50%{ opacity:.25; } }

/* Square avatars with a role-coloured edge, like the account card in the menu */
.av,.ep-ident .ep-av{ border-radius:2px; }
.crop-frame.round{ border-radius:0; }
.tab{ font-family:var(--mono); font-size:12px; letter-spacing:.06em; text-transform:uppercase; }
.ep-nav a{ border-radius:0; }
.ep-nav a.active{ background:var(--iris-weak); border-color:transparent; color:var(--iris-2); }
tbody tr:hover{ background:rgba(255,255,255,.025); }
th{ background:#0c0c0c; }
.post-side{ background:#0e0e0e; }
.chat-scroll::-webkit-scrollbar-thumb{ border-radius:0; }

/* -- Files ------------------------------------------------------------------- */
.frow{ display:flex; align-items:center; gap:14px; padding:12px 16px; border-bottom:1px solid var(--line); }
.frow:last-child{ border-bottom:none; }
.frow-main{ flex:1; min-width:0; }
.frow-title{ font-weight:600; color:var(--ink); word-break:break-word; }
.frow-desc{ font-size:13px; color:var(--ink-2); word-break:break-word; }
.frow-meta{ font-size:12px; color:var(--ink-3); margin-top:2px; }

/* -- Footer: who is online --------------------------------------------------- */
.site-foot{ background:#0c0c0c; box-shadow:0 -1px 0 var(--edge); }
.foot-online{ max-width:1120px; margin:0 auto; padding:12px 22px; display:flex; gap:12px; align-items:baseline; font-size:13px; border-bottom:1px solid var(--line); }
.foot-online-label{ flex:none; font-family:var(--mono); font-size:11.5px; letter-spacing:.1em; text-transform:uppercase; color:var(--ink-2); }
.foot-online-label .dot{ margin-right:6px; }
.foot-online-names{ line-height:1.7; }
.foot-online-names .sep{ color:var(--ink-4); }
.foot-online-names .uname:hover{ text-decoration:underline; }
.foot-in{ padding:12px 22px; font-size:12px; }
/* ══════════════════════════════════════════════════════════════════════════
   Second pass: tighter type, calmer panels, administration layout, forum extras
   ══════════════════════════════════════════════════════════════════════════ */
body{ font-size:14px; }
.container{ max-width:1160px; padding-top:26px; }
.nav-inner,.foot-in,.foot-online{ max-width:1160px; }
.panel,.stat,.auth,.crop-box,.ep-save{ box-shadow:0 0 0 1px var(--edge); }
.panel-head{ min-height:38px; padding:8px 14px; }
.panel-title{ font-size:11px; }
.pagehead{ margin-bottom:18px; }
.sub{ margin-top:4px; font-size:13px; }
td{ padding:9px 14px; }
th{ padding:8px 14px; font-size:10.5px; }
.empty{ padding:22px 16px; font-size:13px; }
a.uname:hover{ text-decoration:underline; }

/* Site-wide notice set under Administration → Settings */
.notice{ background:var(--iris-weak); border-bottom:1px solid var(--iris-line); }
.notice-in{ max-width:1160px; margin:0 auto; padding:8px 22px; font-size:13px; color:var(--iris-2); }

/* Stat tiles: small label, big number, accent edge */
.stats{ grid-template-columns:repeat(auto-fit,minmax(140px,1fr)); gap:10px; }
.stat{ display:flex; flex-direction:column-reverse; gap:2px; padding:12px 14px; border-left:2px solid var(--iris); }
.stat b{ font-size:22px; line-height:1.1; color:var(--ink); }
.stat span{ font-size:10.5px; }

/* -- Administration ---------------------------------------------------------- */
.adm{ max-width:1320px; display:grid; grid-template-columns:190px minmax(0,1fr); gap:22px; align-items:start; }
.adm-nav{ position:sticky; top:72px; background:var(--panel); border:1px solid var(--line-2); box-shadow:0 0 0 1px var(--edge); padding:6px 0 8px; }
.adm-group{ padding:12px 14px 5px; font-family:var(--mono); font-size:10px; letter-spacing:.14em; text-transform:uppercase; color:var(--ink-3); }
.adm-link{ display:flex; align-items:center; justify-content:space-between; padding:7px 14px; font-size:13px; font-weight:500; color:var(--ink-2); border-left:2px solid transparent; }
.adm-link:hover{ color:var(--ink); background:rgba(255,255,255,.03); }
.adm-link.active{ color:var(--iris-2); background:var(--iris-weak); border-left-color:var(--iris); }
.adm-count{ font-family:var(--mono); font-size:10.5px; padding:0 6px; border:1px solid rgba(55,199,147,.35); color:var(--ok); background:var(--ok-weak); }
.adm-count.warn{ border-color:rgba(230,178,78,.4); color:var(--warn); background:var(--warn-weak); }
.adm-head{ display:flex; align-items:center; justify-content:space-between; margin-bottom:16px; padding-bottom:10px; border-bottom:1px solid var(--line); position:relative; }
.adm-head::after{ content:''; position:absolute; left:0; bottom:-1px; width:80px; height:1px; background:var(--iris); }
.adm-head h1{ font-size:17px; }
.adm-save{ margin-top:16px; display:flex; justify-content:flex-end; }
.adm-main .grid-2{ gap:14px; }
.adm-main .stack{ gap:14px; }
@media (max-width:900px){
    .adm{ grid-template-columns:1fr; }
    .adm-nav{ position:static; display:flex; flex-wrap:wrap; padding:4px; }
    .adm-group{ display:none; }
    .adm-link{ border-left:0; border-bottom:2px solid transparent; }
    .adm-link.active{ border-bottom-color:var(--iris); }
}

/* On/off switches, drawn like the pills in the menu */
.switches{ display:grid; gap:9px; margin:4px 0 16px; }
.switch{ display:flex; align-items:center; gap:10px; margin:0; font-size:13.5px; color:var(--ink); cursor:pointer; }
.switch input{ appearance:none; -webkit-appearance:none; flex:none; width:30px; height:14px; margin:0; padding:0; background:#1a1a1a; border:1px solid var(--line-2); box-shadow:0 0 0 1px var(--edge); position:relative; cursor:pointer; }
.switch input::after{ content:''; position:absolute; top:1px; left:1px; width:12px; height:10px; background:var(--ink-3); transition:left .12s, background .12s; }
.switch input:checked{ border-color:var(--iris-line); }
.switch input:checked::after{ left:15px; background:var(--iris); }

/* -- Forum: composer and post extras ----------------------------------------- */
.bb-bar{ gap:4px; align-items:center; padding:6px; margin-bottom:0; background:#0c0c0c; border:1px solid var(--line-2); border-bottom:0; box-shadow:0 0 0 1px var(--edge); }
.bb-bar + textarea{ border-top-color:var(--line); }
.bb-bar button{ height:26px; padding:0 9px; font-size:12px; box-shadow:none; }
.bb-gap{ width:1px; height:18px; background:var(--line-2); margin:0 4px; }
.bb-bar .bb-size{ width:auto; height:26px; margin:0; padding:0 6px; font-size:12px; box-shadow:none; }
.bb-bar .bb-color{ width:30px; height:26px; margin:0; padding:1px; background:var(--panel-2); border:1px solid var(--line-2); cursor:pointer; }
.bb-h{ font-family:var(--mono); font-size:16px; font-weight:600; color:var(--iris-2); margin:6px 0 2px; padding-bottom:4px; border-bottom:1px solid var(--line); }
.bb-center{ text-align:center; }
.bb-hr{ border:0; border-top:1px solid var(--line-2); margin:10px 0; }
.bb-list{ margin:6px 0 6px 22px; }
.bb-icode{ font-family:var(--mono); font-size:12.5px; padding:1px 5px; background:var(--bg-soft); border:1px solid var(--line-2); }
.bb-img{ display:block; max-width:100%; max-height:520px; margin:8px 0; border:1px solid var(--line-2); }
.bb-spoiler{ margin:8px 0; border:1px solid var(--line-2); background:var(--bg-soft); }
.bb-spoiler summary{ padding:6px 10px; cursor:pointer; font-family:var(--mono); font-size:11.5px; letter-spacing:.08em; text-transform:uppercase; color:var(--ink-2); }
.bb-spoiler > div{ padding:8px 12px; border-top:1px solid var(--line); }
.attach-list{ display:flex; flex-wrap:wrap; gap:8px; margin-top:14px; padding-top:12px; border-top:1px solid var(--line); }
.attach{ display:flex; flex-direction:column; padding:7px 12px; background:var(--panel-2); border:1px solid var(--line-2); border-left:2px solid var(--iris); min-width:180px; }
.attach:hover{ background:var(--hover); }
.attach-name{ font-size:13px; font-weight:600; color:var(--ink); word-break:break-all; }
.attach-meta{ font-size:11.5px; color:var(--ink-3); }
.attach-wait{ border-left-color:var(--warn); }
.attach-wait .attach-meta{ color:var(--warn); }
.post-side{ width:140px; }
.post-meta .row-actions .btn,.post-meta .row-actions button{ height:24px; padding:0 9px; font-size:11.5px; }
/* -- Profile: lifetime macro stats ------------------------------------------- */
.pstats{ display:grid; grid-template-columns:repeat(3,1fr); }
.pstat{ display:flex; flex-direction:column; gap:1px; padding:13px 16px; border-right:1px solid var(--line); border-bottom:1px solid var(--line); }
.pstat:nth-child(3n){ border-right:0; }
.pstat:nth-last-child(-n+3){ border-bottom:0; }
.pstat b{ font-family:var(--mono); font-size:19px; font-weight:600; color:var(--ink); line-height:1.2; }
.pstat span{ font-family:var(--mono); font-size:10.5px; letter-spacing:.1em; text-transform:uppercase; color:var(--ink-3); }
@media (max-width:560px){ .pstats{ grid-template-columns:repeat(2,1fr); } .pstat:nth-child(3n){ border-right:1px solid var(--line); } .pstat:nth-child(2n){ border-right:0; } .pstat:nth-last-child(-n+3){ border-bottom:1px solid var(--line); } .pstat:nth-last-child(-n+2){ border-bottom:0; } }.pbreak{ display:grid; grid-template-columns:3fr 2fr; border-top:1px solid var(--line); }
.pbreak table + table{ border-left:1px solid var(--line); }
.pbreak table{ align-self:start; }
.pbreak td,.pbreak th{ padding:7px 16px; }
.pbreak td:not(:first-child),.pbreak th:not(:first-child){ text-align:right; }
.pbreak table:only-child{ grid-column:1 / -1; }
@media (max-width:560px){ .pbreak{ grid-template-columns:1fr; } .pbreak table + table{ border-left:0; border-top:1px solid var(--line); } }
/* ══════════════════════════════════════════════════════════════════════════
   Third pass: account menu, notifications, private messages, mentions
   ══════════════════════════════════════════════════════════════════════════ */
.nav-right{ gap:4px; }
.nav-icon{ position:relative; display:grid; place-items:center; width:36px; height:50px; color:var(--ink-2); }
.nav-icon:hover{ color:var(--ink); background:rgba(255,255,255,.04); }
.nav-icon.active{ color:var(--iris-2); box-shadow:inset 0 -2px 0 var(--iris); }
.nav-badge{ position:absolute; top:9px; right:2px; min-width:15px; height:15px; padding:0 4px; display:grid; place-items:center;
    font-family:var(--mono); font-size:10px; font-weight:600; line-height:1; color:#141414; background:var(--iris); box-shadow:0 0 0 1px var(--edge); }
.nav-menu{ position:relative; margin-left:6px; }
.nav-menu summary{ list-style:none; cursor:pointer; display:block; }
.nav-menu summary::-webkit-details-marker{ display:none; }
.nav-menu[open] summary .av{ box-shadow:0 0 0 1px var(--iris); }
.nav-drop{ position:absolute; right:0; top:calc(100% + 10px); min-width:190px; z-index:120; background:var(--panel);
    border:1px solid var(--line-2); box-shadow:0 0 0 1px var(--edge), 0 12px 28px rgba(0,0,0,.6); }
.nav-drop-name{ display:flex; align-items:baseline; justify-content:space-between; gap:10px; padding:10px 14px; border-bottom:1px solid var(--line); font-size:13.5px; }
.nav-drop-name .mono{ font-size:11px; }
.nav-drop a{ display:block; padding:8px 14px; font-size:13.5px; color:var(--ink-2); }
.nav-drop a:hover{ color:var(--ink); background:rgba(255,255,255,.04); }
.nav-drop a.danger{ color:var(--danger); border-top:1px solid var(--line); }
.nav-drop a.danger:hover{ background:var(--danger-weak); }
@media (max-width:760px){ .nav-left{ overflow-x:auto; scrollbar-width:none; } .nav-left::-webkit-scrollbar{ display:none; } }

/* -- Notifications ----------------------------------------------------------- */
.nrow{ display:flex; align-items:center; gap:12px; padding:11px 16px; border-bottom:1px solid var(--line); border-left:2px solid transparent; }
.nrow:last-child{ border-bottom:none; }
.nrow.unread{ border-left-color:var(--iris); background:var(--iris-weak); }
.nrow-main{ flex:1; min-width:0; }
.nrow-text{ color:var(--ink); font-size:13.5px; word-break:break-word; }
a.nrow-text:hover{ color:var(--iris-2); }
.nrow-meta{ font-family:var(--mono); font-size:10.5px; letter-spacing:.08em; text-transform:uppercase; color:var(--ink-3); margin-top:2px; }

/* -- Private messages -------------------------------------------------------- */
.pm{ display:grid; grid-template-columns:300px minmax(0,1fr); gap:14px; align-items:stretch; }
.pm-list{ align-self:start; max-height:620px; overflow-y:auto; }
.pm-item{ display:flex; align-items:center; gap:10px; padding:10px 14px; border-bottom:1px solid var(--line); border-left:2px solid transparent; color:inherit; }
.pm-item:last-child{ border-bottom:none; }
.pm-item:hover{ background:rgba(255,255,255,.03); color:inherit; }
.pm-item.active{ border-left-color:var(--iris); background:var(--iris-weak); }
.pm-item-main{ flex:1; min-width:0; }
.pm-snip{ font-size:12.5px; color:var(--ink-3); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.pm-thread{ display:flex; flex-direction:column; min-height:420px; }
.pm-scroll{ flex:1; height:460px; overflow-y:auto; padding:14px 16px; display:flex; flex-direction:column; gap:10px; }
.pm-msg{ display:flex; flex-direction:column; align-items:flex-start; max-width:78%; }
.pm-msg.mine{ align-self:flex-end; align-items:flex-end; }
.pm-bubble{ padding:7px 11px; background:var(--panel-2); border:1px solid var(--line-2); font-size:13.5px; line-height:1.5; word-break:break-word; color:var(--ink); }
.pm-msg.mine .pm-bubble{ background:var(--iris-weak); border-color:var(--iris-line); }
.pm-time{ font-family:var(--mono); font-size:10px; color:var(--ink-4); margin-top:3px; }
.pm-send{ display:flex; gap:8px; align-items:flex-end; padding:10px 12px; border-top:1px solid var(--line); }
.pm-send textarea{ margin:0; min-height:0; resize:none; }
@media (max-width:760px){ .pm{ grid-template-columns:1fr; } .pm-scroll{ height:380px; } }

/* -- Small things ------------------------------------------------------------ */
.mention{ font-weight:600; }
.mention:hover{ text-decoration:underline; }
.msg-me{ background:var(--iris-weak); box-shadow:-3px 0 0 var(--iris); }
.codes{ display:grid; grid-template-columns:repeat(2,1fr); gap:6px; margin-bottom:14px; }
.codes .code{ text-align:center; padding:5px 8px; }

/* ══════════════════════════════════════════════════════════════════════════
   Fourth pass. The site is drawn the way the in-game menu is: its caption face,
   its frames, its HUD boxes. Less padding, so a page fits on a screen.
   Movement uses one easing everywhere and all of it stops under "reduce motion"
   (the .fx class is only set when motion is welcome).
   ══════════════════════════════════════════════════════════════════════════ */
@font-face{ font-family:'Ebyon'; src:url('/assets/fonts/ebyon.otf') format('opentype'); font-display:swap; }
:root{
    --brand:'Ebyon','JetBrains Mono',ui-monospace,monospace;
    --ease:cubic-bezier(.22,.8,.24,1);
}

/* The menu's dotted backdrop */
body{ line-height:1.5; background:#0d0d0d radial-gradient(rgba(255,255,255,.03) 1px, transparent 1.3px) 0 0 / 5px 5px; }
::selection{ background:var(--iris); color:#111; }
*{ scrollbar-width:thin; scrollbar-color:#333 #0c0c0c; }
::-webkit-scrollbar{ width:10px; height:10px; }
::-webkit-scrollbar-track{ background:#0c0c0c; }
::-webkit-scrollbar-thumb{ background:#2e2e2e; border:2px solid #0c0c0c; }
::-webkit-scrollbar-thumb:hover{ background:#444; }

/* ── Tighter everywhere ────────────────────────────────────────────────────── */
.container{ max-width:1240px; padding:16px 20px 4px; }
.nav-inner,.foot-in,.foot-online,.notice-in{ max-width:1240px; }
.nav-inner{ height:44px; padding:0 20px; gap:18px; }
.nav-link,.nav-icon{ height:44px; }
.nav-badge{ top:7px; }
.pagehead{ margin-bottom:12px; padding-bottom:9px; }
.panel-head{ min-height:32px; padding:5px 12px; }
.panel-pad{ padding:12px; }
.panel-foot{ padding:10px 12px; border-top:1px solid var(--line); }
.stack,.adm-main .stack{ gap:12px; }
.grid-2,.grid-main,.adm-main .grid-2{ gap:12px; }
td{ padding:7px 12px; }
th{ padding:6px 12px; }
.empty{ padding:16px 12px; }
.stats{ gap:8px; margin-bottom:12px; }
.stat{ padding:8px 12px; }
.stat b{ font-size:19px; }
.site-foot{ margin-top:20px; }
.foot-online{ padding:7px 20px; }
.foot-in{ padding:7px 20px; }
.adm{ gap:16px; }
.adm-nav{ top:60px; }
.adm-link{ padding:5px 14px; }
.adm-group{ padding:9px 14px 3px; }
.adm-head{ margin-bottom:12px; padding-bottom:8px; }
.head-side{ display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.head-side .mono{ font-size:12px; color:var(--ink-2); }

/* ── Type: the menu's caption face, white with the accent set off behind it ── */
h1,.nav-word,.hud-title{ font-family:var(--brand); font-weight:400; text-transform:uppercase; }
h1{ font-size:22px; line-height:1.1; letter-spacing:.02em; color:#f4f4f4; text-shadow:-1px 1px 0 var(--iris), -2px 2px 0 #000; }
h1 .uid,h1 .badge{ text-shadow:none; vertical-align:3px; margin-left:6px; }
.auth h1{ font-size:22px; margin-bottom:14px; }
.adm-head h1{ font-size:18px; }
.nav-word{ font-size:17px; letter-spacing:.02em; color:#f4f4f4; }
.tld{ font-family:var(--brand); font-size:17px; color:var(--iris); }
.pagehead::after{ width:64px; }
.panel-title{ font-size:11px; letter-spacing:.1em; }

/* ── Things answer the pointer by moving a little, not by glowing ─────────── */
a,.nav-link,.nav-icon,.adm-link,.frow,.pm-item,.nrow,tbody tr{ transition:color .15s, background .15s; }
.panel,.stat{ transition:border-color .2s; }
.panel:hover,.stat:hover{ border-color:#474747; }
.btn,button{ transition:transform .12s var(--ease), filter .15s, background .15s, color .15s, border-color .15s; }
.btn:hover,button:hover{ filter:brightness(1.07); }
.btn:active,button:active{ transform:translateY(1px); }
input[type=text],input[type=password],input[type=email],input[type=number],textarea,select{ transition:border-color .15s, background .15s; }
.av{ transition:transform .2s var(--ease); }
a:hover > .av,.cell-user:hover .av{ transform:scale(1.06); }
.switch input,.switch input::after{ transition:.16s var(--ease); }
.dot-on{ animation:ingame 2s ease-in-out infinite; }

/* Navigation: the marker under a link grows from its middle */
.nav-link{ position:relative; }
.nav-link::after{ content:''; position:absolute; left:12px; right:12px; bottom:0; height:2px; background:var(--iris); transform:scaleX(0); transition:transform .28s var(--ease); }
.nav-link:hover::after{ transform:scaleX(1); }
.nav-link.active::after{ display:none; }
.nav-link-admin::after{ background:var(--r-admin); }
.nav-logo{ transition:transform .3s var(--ease); }
.nav-brand:hover .nav-logo{ transform:scale(1.08); }
.nav-drop{ animation:drop-in .18s var(--ease) both; transform-origin:top right; }
@keyframes drop-in{ from{ opacity:0; transform:translateY(-5px); } }
.ep-pane.active{ animation:fade .22s ease both; }
@keyframes fade{ from{ opacity:0; } }

/* Buy premium glows; Extend premium, for someone who already has it, sits quietly and shows the time left */
.nav-premium{ display:inline-flex; align-items:center; gap:8px; height:28px; padding:0 12px; margin-right:6px; font-size:12.5px; font-weight:700; white-space:nowrap;
    color:#141414; background:linear-gradient(#ecbb3a,#c4951a); border:1px solid var(--edge); box-shadow:inset 0 1px 0 rgba(255,255,255,.25), 0 0 10px rgba(236,187,58,.45); transition:filter .15s, background .15s, border-color .15s; }
.nav-premium:hover,.nav-premium.active{ color:#141414; filter:brightness(1.1); }
.fx .nav-premium:not(.nav-premium-on){ animation:premium-pulse 2.4s ease-in-out infinite; }
@keyframes premium-pulse{
    0%,100%{ box-shadow:inset 0 1px 0 rgba(255,255,255,.25), 0 0 4px rgba(236,187,58,.35); }
    50%{ box-shadow:inset 0 1px 0 rgba(255,255,255,.25), 0 0 16px rgba(236,187,58,.9); }
}
.nav-premium-on{ background:none; color:var(--iris-2); border-color:var(--iris-line); box-shadow:none; }
.nav-premium-on:hover,.nav-premium-on.active{ color:var(--iris-2); background:var(--iris-weak); filter:none; }
.nav-premium-left{ font-family:var(--mono); font-size:11px; font-weight:600; padding:0 5px; line-height:16px; color:#141414; background:var(--iris); }

/* ── Pages arrive: the old one fades, the new one settles in from just below ── */
@view-transition{ navigation:auto; }
.rainbow{ view-transition-name:bar; }
.site-nav{ view-transition-name:nav; }
::view-transition-old(root){ animation:vt-out .12s ease both; }
::view-transition-new(root){ animation:fade .2s ease both; }
@keyframes vt-out{ to{ opacity:0; } }
@keyframes rise{ from{ opacity:0; transform:translateY(10px); } }
.fx .container > *,.fx .landing > .auth{ animation:rise .42s var(--ease) backwards; }
.fx .container > :nth-child(2){ animation-delay:.05s; }
.fx .container > :nth-child(3){ animation-delay:.1s; }
.fx .container > :nth-child(n+4){ animation-delay:.14s; }
.fx :is(.home,.grid-main,.grid-2,.prem,.show-grid,.stats) > *{ animation:rise .5s var(--ease) backwards; animation-delay:.08s; }
.fx :is(.home,.grid-main,.grid-2,.prem,.show-grid,.stats) > :nth-child(2){ animation-delay:.14s; }
.fx :is(.home,.grid-main,.grid-2,.prem,.show-grid,.stats) > :nth-child(3){ animation-delay:.2s; }
.fx :is(.home,.grid-main,.grid-2,.prem,.show-grid,.stats) > :nth-child(n+4){ animation-delay:.26s; }
.fx .flash-wrap .alert{ animation:rise .35s var(--ease) backwards; transition:opacity .4s, transform .4s var(--ease); }
.fx .flash-wrap .alert.leaving{ opacity:0; transform:translateY(-6px); }

/* ── Home ──────────────────────────────────────────────────────────────────── */
.home{ display:grid; grid-template-columns:minmax(0,1.45fr) minmax(0,1fr) minmax(0,1fr); gap:12px; align-items:start; }
.ulist .cell-user{ padding:6px 12px; border-bottom:1px solid var(--line); }
.ulist .cell-user:last-child{ border-bottom:0; }
.ulist .cell-user:hover{ background:rgba(255,255,255,.025); }
.steps{ display:flex; flex-wrap:wrap; gap:6px 18px; list-style:none; counter-reset:step; font-size:12.5px; color:var(--ink-2); }
.steps li{ counter-increment:step; display:flex; align-items:center; gap:7px; }
.steps li::before{ content:counter(step); display:grid; place-items:center; width:16px; height:16px; font-family:var(--mono); font-size:10.5px; font-weight:600; color:#141414; background:var(--iris); }
.invite-row{ display:flex; align-items:center; justify-content:space-between; gap:10px; padding:6px 12px; border-bottom:1px solid var(--line); }
.invite-row:last-child{ border-bottom:0; }
@media (max-width:1040px){ .home{ grid-template-columns:1fr 1fr; } .home > :first-child{ grid-column:1 / -1; } }
@media (max-width:640px){ .home{ grid-template-columns:1fr; } }

/* ── Premium ───────────────────────────────────────────────────────────────── */
.prem{ display:grid; grid-template-columns:minmax(0,1fr) 440px; gap:28px; align-items:start; }
.buy{ display:grid; grid-template-columns:repeat(3,1fr); gap:8px; }
.buy-opt{ display:grid; justify-content:stretch; justify-items:start; align-content:start; align-items:start; gap:1px; height:auto; padding:11px 13px 12px; margin:0; text-align:left; white-space:normal;
    background:#151515; border:1px solid var(--line-2); box-shadow:0 0 0 1px var(--edge); color:var(--ink); cursor:pointer; transition:transform .2s var(--ease), border-color .18s, background .18s; }
.buy-opt:hover{ background:#1a1a1a; border-color:var(--iris); color:var(--ink); transform:translateY(-2px); filter:none; }
.buy-opt:active{ transform:none; }
.buy-name{ font-family:var(--mono); font-size:11px; letter-spacing:.08em; text-transform:uppercase; color:var(--ink-3); }
.buy-price{ font-family:var(--mono); font-size:22px; font-weight:600; line-height:1.25; color:var(--iris-2); }
.buy-price small{ font-size:11px; font-weight:400; color:var(--ink-3); }
.buy-note{ font-family:var(--mono); font-size:11px; font-weight:400; color:var(--ink-3); }
.buy-until{ font-family:var(--mono); font-size:11px; font-weight:500; color:var(--ok); }
.gifting .buy-until{ visibility:hidden; }
.buy-extra{ margin-top:12px; }
.buy-extra input{ margin-bottom:0; }
.terms{ line-height:1.65; font-size:14px; color:var(--ink-2); }
@media (max-width:980px){ .prem{ grid-template-columns:1fr; } }
@media (max-width:560px){ .buy{ grid-template-columns:1fr; } }

/* ── Sign in and register: the card beside the floating HUD ────────────────── */
.landing{ max-width:960px; margin:0 auto; padding:44px 20px 0; display:grid; grid-template-columns:400px minmax(0,1fr); gap:56px; align-items:center; }
.landing .auth{ margin:0; max-width:none; }
.auth{ border-radius:0; padding:24px; margin-top:44px; }
.auth > p{ margin-bottom:16px; }
@media (max-width:920px){ .landing{ grid-template-columns:minmax(0,420px); justify-content:center; gap:24px; padding-top:24px; } }

/* ── HUD boxes: the frame the mod draws its overlay in ─────────────────────── */
.hud{ position:relative; padding:3px; background:#131417; border-radius:7px; box-shadow:0 16px 36px rgba(0,0,0,.55);
    font-size:12.5px; font-weight:600; line-height:1; letter-spacing:.01em; color:#d8d8d8; }
.hud-title{ padding:9px 8px 4px; font-size:13.5px; letter-spacing:.03em; color:var(--iris-2); }
.hud-rows{ display:grid; gap:6px; padding:7px 8px; }
.hud-rows + .hud-rows{ border-top:1px solid rgba(255,255,255,.1); }
.hud-row{ display:flex; justify-content:space-between; gap:14px; white-space:nowrap; }
.hud-row span{ color:#a8a8a8; }
.hud-row b{ font-weight:600; color:#fff; font-variant-numeric:tabular-nums; }
.hud-row b span{ color:inherit; }
.hud .acc{ color:var(--iris-2); }
.hud .ok{ color:#4ab868; }
.hud-bar{ height:4px; border-radius:2px; background:rgba(255,255,255,.12); overflow:hidden; }
.hud-bar i{ display:block; height:100%; width:42%; border-radius:2px; background:var(--iris); }
.fx .hud-bar i{ animation:hud-fill 5s linear infinite; }
@keyframes hud-fill{ from{ width:3%; } to{ width:100%; } }
.hud-mark{ display:inline-flex; align-items:center; gap:0; padding:3px; white-space:nowrap; }
.hud-mark > *{ padding:7px 0 7px; }
.hud-mark > :first-child{ padding-left:7px; }
.hud-mark > :last-child{ padding-right:7px; }
.hud-mark b{ color:#fff; font-weight:700; }
.hud-mark i{ width:1px; height:9px; margin:0 7px; padding:0 !important; font-size:0; background:rgba(255,255,255,.22); }

/* The hunter's route: waypoints, the target, and the player walking it */
.hud-map{ position:relative; width:218px; height:66px; margin:4px auto 2px; background:#0d0e10; border-radius:5px; overflow:hidden; }
.hud-map svg{ display:block; }
.hud-me{ position:absolute; left:0; top:0; width:7px; height:7px; margin:-3.5px 0 0 -3.5px; background:#fff; border-radius:50%; box-shadow:0 0 0 1px #000;
    offset-path:path('M16 52 L62 52 L88 32 L140 32 L166 16 L198 16'); offset-rotate:0deg; offset-distance:38%; }
.fx .hud-me{ animation:hud-walk 6s cubic-bezier(.4,0,.5,1) infinite; }
@keyframes hud-walk{ 0%{ offset-distance:0%; } 78%,92%{ offset-distance:97%; } 100%{ offset-distance:97%; opacity:0; } }
.hud-tgt{ transform-box:fill-box; transform-origin:center; }
.fx .hud-tgt{ animation:hud-hit 6s linear infinite; }
@keyframes hud-hit{ 0%,77%{ opacity:1; transform:none; } 80%,84%,88%{ opacity:.25; transform:scale(1.5); } 82%,86%{ opacity:1; transform:none; } 92%,100%{ opacity:0; } }

/* The bobber: it rides the water, then goes under when something bites */
.hud-water{ position:relative; width:218px; height:58px; margin:4px auto 2px; background:linear-gradient(#0d0e10 0 56%, #10202b 56%); border-radius:5px; overflow:hidden; }
.hud-wave{ position:absolute; left:0; top:28px; width:436px; height:8px; }
.fx .hud-wave{ animation:hud-wave 4s linear infinite; }
@keyframes hud-wave{ to{ transform:translateX(-218px); } }
.hud-line{ position:absolute; left:134px; top:0; width:1px; height:27px; background:#8f8f8f; transform-origin:top; }
.hud-bob{ position:absolute; left:130px; top:24px; width:9px; height:10px; background:linear-gradient(#e03030 0 50%, #f2f2f2 50%); box-shadow:0 0 0 1px #000; }
.fx .hud-bob{ animation:hud-bob 5s ease-in-out infinite; }
.fx .hud-line{ animation:hud-pull 5s ease-in-out infinite; }
@keyframes hud-bob{ 0%,20%,40%,60%,76%,100%{ transform:translateY(0); } 10%,30%,50%,70%{ transform:translateY(2px); } 82%,90%{ transform:translateY(9px); } }
@keyframes hud-pull{ 0%,20%,40%,60%,76%,100%{ transform:scaleY(1); } 10%,30%,50%,70%{ transform:scaleY(1.07); } 82%,90%{ transform:scaleY(1.33); } }
.hud-bite{ position:absolute; left:120px; top:6px; font-size:12px; font-weight:700; color:#ffdd44; text-shadow:1px 1px 0 #000; opacity:0; }
.fx .hud-bite{ animation:hud-bite 5s steps(1) infinite; }
@keyframes hud-bite{ 0%,79%{ opacity:0; } 80%,92%{ opacity:1; } 93%,100%{ opacity:0; } }

/* ── Floating: each piece drifts at its own pace and leans away from the pointer ── */
.float-stage{ position:relative; width:100%; height:410px; max-width:440px; margin:0 auto; }
.fw{ position:absolute; left:var(--x,0); top:var(--y,0); z-index:var(--z,1);
    transform:translate3d(calc(var(--px,0) * var(--d,1) * 1px), calc(var(--py,0) * var(--d,1) * 1px), 0) rotate(var(--r,0deg)); transition:transform .6s var(--ease); will-change:transform; }
.fx .fw{ animation:fade .7s ease backwards; animation-delay:calc(var(--n,0) * .11s + .12s); }
.fx .fw-in,.fx .shot-in{ animation:bob var(--dur,7s) ease-in-out var(--delay,0s) infinite alternate; }
@keyframes bob{ from{ transform:translateY(-5px); } to{ transform:translateY(6px); } }
.fw .hud{ width:var(--w,auto); }
@media (max-width:920px){
    .float-stage{ height:auto; max-width:none; display:flex; flex-wrap:wrap; gap:12px; justify-content:center; }
    .fw{ position:static; transform:none; }
    .fw-mark{ flex-basis:100%; text-align:center; }
    .fx .fw-in{ animation:none; }
}

/* ── Showcase ──────────────────────────────────────────────────────────────── */
.shots{ position:relative; max-width:920px; margin:6px auto 24px; aspect-ratio:920 / 360; }
.shot{ position:absolute; left:var(--x); top:var(--y); width:var(--w); z-index:var(--z,1); margin:0;
    transform:translate3d(calc(var(--px,0) * var(--d,1) * 1px), calc(var(--py,0) * var(--d,1) * 1px), 0) rotate(var(--r,0deg)); transition:transform .6s var(--ease); }
.fx .shot{ animation:fade .7s ease backwards; animation-delay:calc(var(--n,0) * .12s + .1s); }
.shot-in{ display:block; cursor:zoom-in; }
.shot-frame{ display:block; padding:3px; background:#131417; border-radius:8px; box-shadow:0 20px 46px rgba(0,0,0,.6); transition:transform .4s var(--ease); }
.shot-frame img{ display:block; width:100%; aspect-ratio:16 / 9; object-fit:cover; border-radius:6px; }
.shot-frame span{ display:block; padding:6px 6px 4px; font-size:12px; font-weight:600; color:#d8d8d8; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.shot:hover{ z-index:9; }
.shot:hover .shot-frame{ transform:rotate(calc(var(--r,0deg) * -1)) scale(1.05); }
.show-grid{ display:grid; grid-template-columns:repeat(auto-fill,minmax(300px,1fr)); gap:12px; }
.show-item{ margin:0; background:var(--panel); border:1px solid var(--line-2); box-shadow:0 0 0 1px var(--edge); overflow:hidden; transition:transform .25s var(--ease), border-color .2s; }
.show-item:hover{ transform:translateY(-3px); border-color:#5a5a5a; }
.show-media{ display:block; position:relative; aspect-ratio:16/9; background:#070707; overflow:hidden; }
.show-media img,.show-media video,.show-media iframe{ position:absolute; inset:0; width:100%; height:100%; border:0; display:block; object-fit:cover; }
.show-media video{ object-fit:contain; }
.show-image .show-media img{ transition:transform .5s var(--ease); cursor:zoom-in; }
.show-image:hover .show-media img{ transform:scale(1.04); }
.show-item figcaption{ padding:7px 12px; font-size:12.5px; font-weight:600; color:var(--ink-2); border-top:1px solid var(--line); }
.zoom{ position:fixed; inset:0; z-index:300; display:flex; align-items:center; justify-content:center; padding:28px; background:rgba(0,0,0,.9); cursor:zoom-out; animation:fade .18s ease both; }
.zoom img{ max-width:100%; max-height:100%; border:1px solid #000; box-shadow:0 0 0 1px #3c3c3c, 0 30px 80px rgba(0,0,0,.8); animation:zoom-pic .28s var(--ease) both; }
@keyframes zoom-pic{ from{ transform:scale(.97); opacity:0; } }
@media (max-width:760px){
    .shots{ aspect-ratio:auto; display:grid; gap:10px; }
    .shot{ position:static; width:auto; transform:none; }
    .fx .shot-in{ animation:none; }
    .show-grid{ grid-template-columns:1fr; }
}

@media (prefers-reduced-motion:reduce){
    *,*::before,*::after{ animation:none !important; transition:none !important; }
    ::view-transition-group(*),::view-transition-old(*),::view-transition-new(*){ animation:none !important; }
}

/* Administration → Showcase: the picture that was just pasted */
.paste-preview{ display:block; max-width:320px; max-height:180px; margin:0 0 12px; border:1px solid #000; box-shadow:0 0 0 1px #3c3c3c; }

/* Showcase: sections on the page, and the editable lists under Administration */
.show-nav{ display:flex; flex-wrap:wrap; gap:6px; margin:0 0 4px; }
.show-nav a{ display:inline-flex; align-items:center; gap:7px; height:26px; padding:0 10px; font-size:12.5px; font-weight:600; color:var(--ink-2); background:var(--panel); border:1px solid var(--line-2); transition:color .15s, border-color .15s; }
.show-nav a:hover{ color:var(--iris-2); border-color:var(--iris-line); }
.show-nav a span{ font-family:var(--mono); font-size:11px; color:var(--ink-3); }
.show-section{ scroll-margin-top:64px; }
.show-head{ margin:18px 0 8px; font-family:var(--brand); font-weight:400; font-size:16px; letter-spacing:.03em; text-transform:uppercase; color:#f4f4f4; text-shadow:-1px 1px 0 var(--iris); }
.edit-table td{ padding:5px 12px; }
.edit-table input[type=text],.edit-table input[type=number],.edit-table select{ margin:0; padding:5px 8px; }
.edit-table .check{ justify-content:center; }