/* ganaa.download — glass app. One blur per surface, never on things that fade in and out by the hundred. */
:root {
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --bg: #edf1f8;
  --text: #0f172a; --text-2: #3f4b5f; --muted: #6b7789;
  --line: rgba(15, 23, 42, .08); --line-2: rgba(15, 23, 42, .15);
  --glass: rgba(255, 255, 255, .58); --glass-2: rgba(255, 255, 255, .82); --glass-brd: rgba(255, 255, 255, .75); --glass-hi: rgba(255, 255, 255, .65);
  --card: rgba(255, 255, 255, .78); --card-h: #fff;
  --hover: rgba(15, 23, 42, .05); --press: rgba(15, 23, 42, .09);
  --ind: #fff;
  --accent: #0a84ff; --accent-2: #5e5ce6; --accent-soft: rgba(10, 132, 255, .12);
  --ok: #22c55e; --ok-ink: #15803d; --bad: #ef4444; --warn: #f59e0b;
  --shadow-1: 0 1px 2px rgba(15, 23, 42, .06), 0 1px 1px rgba(15, 23, 42, .03);
  --shadow-2: 0 10px 28px -8px rgba(15, 23, 42, .16), 0 2px 6px rgba(15, 23, 42, .05);
  --shadow-3: 0 28px 70px -16px rgba(15, 23, 42, .32), 0 8px 22px -10px rgba(15, 23, 42, .14);
  --blur: blur(26px) saturate(170%);
  --out: cubic-bezier(.22, 1, .36, 1); --spring: cubic-bezier(.32, 1.16, .42, 1); --inout: cubic-bezier(.65, 0, .35, 1);
  --side-w: 264px; --rail-w: 76px;
  --blob-1: rgba(125, 211, 252, .55); --blob-2: rgba(196, 181, 253, .5); --blob-3: rgba(253, 186, 116, .42);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #080c18; --text: #e9eef7; --text-2: #b8c2d6; --muted: #8590a8;
    --line: rgba(255, 255, 255, .08); --line-2: rgba(255, 255, 255, .15);
    --glass: rgba(18, 24, 40, .56); --glass-2: rgba(24, 30, 48, .86); --glass-brd: rgba(255, 255, 255, .09); --glass-hi: rgba(255, 255, 255, .06);
    --card: rgba(30, 37, 58, .66); --card-h: rgba(40, 48, 72, .92); --hover: rgba(255, 255, 255, .06); --press: rgba(255, 255, 255, .11); --ind: rgba(255, 255, 255, .11);
    --accent: #3d9bff; --accent-2: #7b79ff; --accent-soft: rgba(61, 155, 255, .17); --ok-ink: #4ade80;
    --shadow-1: 0 1px 2px rgba(0, 0, 0, .3); --shadow-2: 0 12px 30px -10px rgba(0, 0, 0, .55); --shadow-3: 0 30px 80px -16px rgba(0, 0, 0, .7);
    --blob-1: rgba(14, 165, 233, .32); --blob-2: rgba(99, 102, 241, .34); --blob-3: rgba(249, 115, 22, .2);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #080c18; --text: #e9eef7; --text-2: #b8c2d6; --muted: #8590a8;
  --line: rgba(255, 255, 255, .08); --line-2: rgba(255, 255, 255, .15);
  --glass: rgba(18, 24, 40, .56); --glass-2: rgba(24, 30, 48, .86); --glass-brd: rgba(255, 255, 255, .09); --glass-hi: rgba(255, 255, 255, .06);
  --card: rgba(30, 37, 58, .66); --card-h: rgba(40, 48, 72, .92); --hover: rgba(255, 255, 255, .06); --press: rgba(255, 255, 255, .11); --ind: rgba(255, 255, 255, .11);
  --accent: #3d9bff; --accent-2: #7b79ff; --accent-soft: rgba(61, 155, 255, .17); --ok-ink: #4ade80;
  --shadow-1: 0 1px 2px rgba(0, 0, 0, .3); --shadow-2: 0 12px 30px -10px rgba(0, 0, 0, .55); --shadow-3: 0 30px 80px -16px rgba(0, 0, 0, .7);
  --blob-1: rgba(14, 165, 233, .32); --blob-2: rgba(99, 102, 241, .34); --blob-3: rgba(249, 115, 22, .2);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; font: 14px/1.45 var(--font); color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; overflow: hidden; -webkit-tap-highlight-color: transparent; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: inherit; }
[hidden] { display: none !important; }
* { scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
::selection { background: var(--accent-soft); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
svg.i { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; display: block; }
.muted { color: var(--muted); } .small { font-size: 12px; } .center { text-align: center; } .sp { flex: 1; }
.err { color: var(--bad); font-size: 13.5px; margin: 6px 0 0; } .ok { color: var(--ok-ink); } .bad { color: var(--bad); }
.tag { font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 6px; background: var(--accent-soft); color: var(--accent); }
.noscroll { overflow: hidden; }

/* ------------------------------------------------------------ background */
.bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; background: var(--bg); transition: background .4s; }
.bg i { position: absolute; width: 70vmax; height: 70vmax; border-radius: 50%; will-change: transform; }
.bg i:nth-child(1) { left: -22vmax; top: -26vmax; background: radial-gradient(closest-side, var(--blob-1), transparent); animation: drift1 38s ease-in-out infinite alternate; }
.bg i:nth-child(2) { right: -26vmax; top: 4vmax; background: radial-gradient(closest-side, var(--blob-2), transparent); animation: drift2 44s ease-in-out infinite alternate; }
.bg i:nth-child(3) { left: 18vmax; bottom: -40vmax; background: radial-gradient(closest-side, var(--blob-3), transparent); animation: drift3 50s ease-in-out infinite alternate; }
@keyframes drift1 { to { transform: translate(14vmax, 10vmax) scale(1.08); } }
@keyframes drift2 { to { transform: translate(-12vmax, 14vmax) scale(.94); } }
@keyframes drift3 { to { transform: translate(-10vmax, -12vmax) scale(1.1); } }

.glass { background: var(--glass); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); border: 1px solid var(--glass-brd); box-shadow: var(--shadow-2), inset 0 1px 0 var(--glass-hi); }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) { .glass { background: var(--glass-2); } }

/* ------------------------------------------------------------ controls */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 12px; border: 1px solid transparent; font: 600 14px/1 var(--font); cursor: pointer; white-space: nowrap; text-decoration: none; color: var(--text); background: transparent; user-select: none; transition: transform .16s var(--out), background .2s, box-shadow .2s, filter .2s, opacity .2s; }
.btn:active { transform: scale(.97); }
.btn svg.i { width: 18px; height: 18px; }
.btn.primary { background: var(--accent); color: #fff; box-shadow: 0 8px 20px -10px var(--accent), inset 0 1px 0 rgba(255, 255, 255, .22); }
.btn.primary:hover { filter: brightness(1.07); }
.btn.ghost { background: var(--card); border-color: var(--line); box-shadow: var(--shadow-1); }
.btn.ghost:hover { background: var(--card-h); }
.btn.sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 10px; gap: 6px; }
.btn.sm svg.i { width: 16px; height: 16px; }
.btn:disabled { opacity: .45; pointer-events: none; }
.btn.on { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
.icon-btn { width: 36px; height: 36px; display: inline-grid; place-items: center; border-radius: 10px; border: 0; background: transparent; color: var(--text-2); cursor: pointer; flex: none; position: relative; text-decoration: none; transition: background .15s, color .15s, transform .15s var(--out); }
.icon-btn:hover { background: var(--hover); color: var(--text); }
.icon-btn:active { transform: scale(.92); }
.icon-btn.sm { width: 30px; height: 30px; border-radius: 9px; }
.icon-btn.sm svg.i { width: 17px; height: 17px; }
.icon-btn.accent { background: var(--accent); color: #fff; }
.icon-btn:disabled { opacity: .4; pointer-events: none; }
.inp { width: 100%; height: 42px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--card); color: var(--text); font: 15px var(--font); outline: none; transition: border-color .15s, box-shadow .2s, background .2s; }
.inp:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); background: var(--card-h); }
textarea.inp { height: auto; padding: 10px 14px; resize: vertical; line-height: 1.45; min-height: 64px; }
.inp::placeholder { color: var(--muted); opacity: .8; }
.form { display: flex; flex-direction: column; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field > span:first-child { font-size: 13px; font-weight: 600; color: var(--text-2); }
.pw-row { display: flex; gap: 8px; align-items: center; }
.pw-row .inp { flex: 1; min-width: 0; }
.prefix-inp { display: flex; align-items: center; border: 1px solid var(--line-2); border-radius: 12px; background: var(--card); overflow: hidden; transition: box-shadow .2s, border-color .15s; }
.prefix-inp:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.prefix-inp span { padding: 0 2px 0 14px; color: var(--muted); white-space: nowrap; }
.prefix-inp .inp { border: 0; box-shadow: none; background: transparent; padding-left: 2px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border-radius: 999px; background: var(--hover); color: var(--text-2); font: 600 12.5px var(--font); white-space: nowrap; border: 0; }
.chip svg.i { width: 15px; height: 15px; }
.chip.bad { background: rgba(239, 68, 68, .12); color: var(--bad); }
.bar { display: block; height: 6px; border-radius: 99px; background: var(--line-2); overflow: hidden; flex: none; }
.bar > i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--accent), var(--accent-2)); transition: width .5s var(--out); }
.bar.big { height: 8px; margin: 16px 0 8px; }
.bar.done > i { background: var(--ok); } .bar.stopped > i { background: var(--warn); }
.ring { transform: rotate(-90deg); display: block; }
.ring circle { fill: none; stroke-width: 4; }
.ring-bg { stroke: var(--line-2); }
.ring-fg { stroke: var(--accent); stroke-linecap: round; stroke-dasharray: 100 100; stroke-dashoffset: calc(100 - var(--p, 0)); transition: stroke-dashoffset .5s var(--out), stroke .3s; }

/* avatars and file tiles */
.ava { --s: 32px; width: var(--s); height: var(--s); border-radius: 30%; display: inline-grid; place-items: center; flex: none; overflow: hidden; background: linear-gradient(140deg, hsl(var(--h) 88% 64%), hsl(calc(var(--h) + 38) 78% 50%)); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3); }
.ava b { font-size: calc(var(--s) * .38); font-weight: 700; letter-spacing: -.02em; }
.ava img { width: 100%; height: 100%; object-fit: contain; background: #fff; padding: 8%; }
.ava.xs { --s: 22px; border-radius: 7px; } .ava.sm { --s: 30px; } .ava.md { --s: 38px; } .ava.lg { --s: 46px; } .ava.xl { --s: 58px; }
.ava.me { background: linear-gradient(140deg, #38bdf8, #6366f1); }
.tile { --t: 40px; width: var(--t); height: var(--t); border-radius: calc(var(--t) * .28); display: inline-grid; place-items: center; flex: none; position: relative; background: linear-gradient(145deg, hsl(var(--h) 88% 67%), hsl(calc(var(--h) + 24) 76% 52%)); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .32), 0 3px 8px -3px hsla(var(--h), 70%, 40%, .55); }
.tile svg.i { width: 54%; height: 54%; stroke-width: 1.9; }
.tile em { position: absolute; bottom: -4px; right: -6px; font: 800 8.5px/1 var(--font); font-style: normal; text-transform: uppercase; background: var(--card-h); color: hsl(var(--h) 55% 40%); padding: 2px 4px; border-radius: 5px; box-shadow: var(--shadow-1); letter-spacing: .02em; }
.tile.sm { --t: 28px; } .tile.sm em { display: none; }
.tile.lg { --t: 66px; } .tile.lg em { font-size: 10px; padding: 3px 5px; }
.tile.xl { --t: 92px; } .tile.xl em { font-size: 12px; padding: 3px 6px; bottom: -5px; right: -8px; }
.tile.k-dir { background: linear-gradient(150deg, hsl(var(--h) 90% 70%), hsl(var(--h) 72% 52%)); }
.mark { width: 34px; height: 34px; display: block; flex: none; filter: drop-shadow(0 6px 12px rgba(56, 120, 241, .35)); }

/* ------------------------------------------------------------ sliding pills */
.pills { position: relative; max-width: 100%; }
.pills.tabs, .pills.scrollx { overflow-x: auto; scrollbar-width: none; }
.pills.tabs::-webkit-scrollbar, .pills.scrollx::-webkit-scrollbar { display: none; }
.pills-track { position: relative; display: inline-flex; gap: 2px; padding: 4px; border-radius: 999px; background: var(--hover); vertical-align: top; }
.pill-ind { position: absolute; inset: 0; background: var(--ind); pointer-events: none; opacity: 0; }
:root:not([data-theme="dark"]) .pill-ind { background: #fff; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .pill-ind { background: var(--ind); } }
.pill-b { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 14px; border: 0; background: none; border-radius: 999px; color: var(--muted); font: 600 13.5px var(--font); cursor: pointer; white-space: nowrap; transition: color .25s; }
.pill-b:hover { color: var(--text-2); }
.pill-b.on { color: var(--text); }
.pill-b svg.i { width: 17px; height: 17px; }
.pill-b .dot { width: 8px; height: 8px; border-radius: 50%; background: hsl(var(--h) 75% 55%); flex: none; }
.pill-b .cnt { font-style: normal; font-size: 11px; color: var(--muted); background: var(--hover); padding: 1px 6px; border-radius: 99px; }
.pill-b.drop-target { color: var(--accent); box-shadow: inset 0 0 0 2px var(--accent); }
.pills.icons .pill-b { padding: 0 10px; }
.pills.tabs .pills-track { background: transparent; padding: 0; gap: 4px; }
.pills.tabs .pill-ind { background: var(--card-h); }
.pills.tabs .pill-b { height: 36px; padding: 0 14px; font-size: 14px; }

/* ------------------------------------------------------------ frame */
.shell { display: flex; height: 100vh; height: 100dvh; }
.side { width: var(--side-w); flex: none; margin: 12px 0 12px 12px; border-radius: 24px; display: flex; flex-direction: column; padding: 14px 10px 10px; overflow: hidden; transition: width .5s var(--spring); z-index: 10; }
.rail .side { width: var(--rail-w); }
.side-head { display: flex; align-items: center; gap: 8px; padding: 0 2px 0 6px; min-height: 40px; }
.rail .side-head { flex-direction: column; padding: 0; gap: 10px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); flex: 1; min-width: 0; }
.rail .brand { flex: none; }
.rail .brand .lbl { display: none; }
.brand-tt { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.brand-tt b { font-size: 15px; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-tt small { font-size: 12px; color: var(--muted); white-space: nowrap; }
.nav { position: relative; flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; margin: 14px -4px 0; padding: 0 4px; }
.nav-ind { position: absolute; left: 4px; right: 4px; top: 0; bottom: 0; background: var(--ind); opacity: 0; pointer-events: none; box-shadow: none; }
:root:not([data-theme="dark"]) .nav-ind { background: rgba(255, 255, 255, .92); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .nav-ind { background: var(--ind); } }
.nav-i { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; height: 40px; padding: 0 10px 0 11px; border-radius: 12px; color: var(--text-2); text-decoration: none; font-weight: 500; white-space: nowrap; transition: color .2s, background .2s; }
.nav-i:hover:not(.on) { background: var(--hover); }
.nav-i.on { color: var(--text); font-weight: 650; }
.nav-i.sub { height: 36px; font-size: 13.5px; }
.nav-ico { width: 24px; height: 24px; display: grid; place-items: center; flex: none; }
.nav-i.on .nav-ico { color: var(--accent); }
.nav-ava { margin: 0 1px; }
.nav-chev { margin-left: auto; width: 26px; height: 26px; border: 0; background: none; border-radius: 8px; display: grid; place-items: center; color: var(--muted); cursor: pointer; flex: none; transition: background .15s, color .15s; }
.nav-chev:hover { background: var(--press); color: var(--text); }
.nav-chev svg.i { width: 16px; height: 16px; transition: transform .38s var(--spring); }
.nav-i.has-tree { padding-right: 6px; }
.has-tree.tree-open .nav-chev svg.i { transform: rotate(90deg); }
.has-tree.child-on:not(.on) { color: var(--text); }
.nav-tree { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .42s var(--out); }
.nav-tree.open { grid-template-rows: 1fr; }
.nav-tree-in { overflow: hidden; min-height: 0; padding-left: 14px; position: relative; }
.nav-tree-in::before { content: ""; position: absolute; left: 23px; top: 6px; bottom: 6px; width: 1px; background: var(--line-2); }
.nav-tree .nav-i { opacity: 0; transform: translateY(-6px); transition: opacity .18s, transform .3s var(--out), background .2s, color .2s; }
.nav-tree.open .nav-i { opacity: 1; transform: none; transition-delay: calc(min(var(--j, 0), 14) * 22ms); }
.rail .nav-tree, .rail .nav-chev { display: none; }
.dot-ico i { width: 9px; height: 9px; border-radius: 50%; background: hsl(var(--h) 75% 55%); box-shadow: 0 0 0 3px hsla(var(--h), 75%, 55%, .18); }
.lbl { transition: opacity .3s calc(140ms + var(--i, 0) * 22ms), transform .46s var(--spring) calc(140ms + var(--i, 0) * 22ms); }
.rail .side .lbl { opacity: 0; transform: translateX(-10px); transition: opacity .11s, transform .11s; pointer-events: none; }
.nav-i .lbl { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.nbadge { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--bad); color: #fff; font: 700 11px/20px var(--font); font-style: normal; text-align: center; box-shadow: 0 4px 10px -4px var(--bad); animation: pop .4s var(--spring); }
.rail .nbadge { position: absolute; top: 4px; left: 30px; min-width: 16px; height: 16px; line-height: 16px; padding: 0 4px; font-size: 10px; }
.nav-sec { margin: 18px 12px 6px; font: 700 11px/1 var(--font); text-transform: uppercase; letter-spacing: .07em; color: var(--muted); height: 12px; }
.rail .nav-sec { margin: 14px 18px 8px; border-top: 1px solid var(--line); height: 1px; }
.side-foot { border-top: 1px solid var(--line); padding-top: 10px; margin-top: 8px; display: flex; flex-direction: column; gap: 2px; }
.side-scrim { display: none; }
.main { flex: 1; min-width: 0; overflow-y: auto; overflow-x: hidden; position: relative; }
.page-host { min-height: 100%; }
.page-host.entering { animation: page-in .26s var(--out) both; }
.page-host.leaving { position: absolute; inset: 0; pointer-events: none; animation: page-out .16s ease forwards; }
@keyframes page-in { from { opacity: 0; transform: translateY(10px); } }
@keyframes page-out { to { opacity: 0; transform: scale(.99); } }
.page { max-width: 1240px; margin: 0 auto; padding: 26px 30px 120px; }
.page-head { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.ph-tt { flex: 1; min-width: 0; }
.page-head h1 { margin: 0; font-size: 28px; line-height: 1.15; letter-spacing: -.025em; }
.page-head p { margin: 4px 0 0; }
.ph-acts { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.page-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.mburger { display: none; }

/* theme switch */
.tswitch { position: relative; width: 64px; height: 32px; border-radius: 99px; border: 1px solid var(--line); background: var(--hover); cursor: pointer; display: flex; align-items: center; justify-content: space-between; padding: 0 8px; color: var(--muted); margin: 2px 6px 6px; flex: none; transition: width .4s var(--spring); }
.ts-k { position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: var(--card-h); box-shadow: var(--shadow-1); transition: transform .45s var(--spring), opacity .2s; }
:root:not([data-theme="dark"]) .ts-k { background: #fff; }
.tswitch.dark .ts-k { transform: translateX(32px); }
.tswitch svg.i { width: 15px; height: 15px; position: relative; z-index: 1; transition: color .3s; }
.tswitch:not(.dark) .ts-sun, .tswitch.dark .ts-moon { color: var(--text); }
.rail .tswitch { width: 44px; padding: 0; justify-content: center; margin: 2px auto 6px; }
.rail .tswitch .ts-k { opacity: 0; }
.rail .tswitch:not(.dark) .ts-moon, .rail .tswitch.dark .ts-sun { display: none; }
::view-transition-old(root), ::view-transition-new(root) { animation: none; mix-blend-mode: normal; }

/* ------------------------------------------------------------ workspace */
.ws { display: flex; flex-direction: column; height: 100vh; height: 100dvh; position: relative; overflow: hidden; }
.ws-head { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px; padding: 22px 30px 12px; }
.ws-id { display: flex; align-items: center; gap: 14px; min-width: 0; flex: 1 1 240px; }
.ws-tt { min-width: 0; }
.ws-tt h1 { margin: 0; font-size: 26px; letter-spacing: -.025em; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ws-tt p { margin: 3px 0 0; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ws-acts { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.search { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 8px 0 12px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); width: 210px; color: var(--muted); transition: width .35s var(--out), box-shadow .2s, border-color .2s; }
.search:focus-within { width: 270px; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.search svg.i { width: 17px; height: 17px; }
.search input { border: 0; background: none; outline: none; flex: 1; min-width: 0; font: 14px var(--font); color: var(--text); }
.search input::-webkit-search-cancel-button { display: none; }
.search kbd { font: 600 11px var(--font); color: var(--muted); border: 1px solid var(--line-2); border-radius: 6px; padding: 1px 6px; }
.search:focus-within kbd { display: none; }
.ws-tabs { display: flex; align-items: center; gap: 6px; padding: 2px 30px 0; border-bottom: 1px solid var(--line); }
.ws-tabs .pills { flex: 0 1 auto; padding: 4px 0 10px; }
.ws-tabs .b-alltabs { margin-bottom: 6px; }
.pills.tabs.fr { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 56px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 56px), transparent); }
.pills.tabs.fl { -webkit-mask-image: linear-gradient(90deg, transparent, #000 56px); mask-image: linear-gradient(90deg, transparent, #000 56px); }
.pills.tabs.fl.fr { -webkit-mask-image: linear-gradient(90deg, transparent, #000 56px, #000 calc(100% - 56px), transparent); mask-image: linear-gradient(90deg, transparent, #000 56px, #000 calc(100% - 56px), transparent); }
.ws-tabs .b-newtab { margin-bottom: 6px; }
.ws-bar { display: flex; align-items: center; gap: 10px; padding: 12px 30px 8px; min-height: 54px; }
.ws-count { font-size: 12.5px; white-space: nowrap; }
.crumbs { display: flex; align-items: center; gap: 2px; min-width: 0; overflow: hidden; font-weight: 600; font-size: 15px; }
.crumbs button { border: 0; background: none; color: var(--muted); font: inherit; padding: 5px 8px; border-radius: 8px; cursor: pointer; white-space: nowrap; }
.crumbs button:hover { background: var(--hover); color: var(--text); }
.crumbs button.drop-target { box-shadow: inset 0 0 0 2px var(--accent); color: var(--accent); }
.crumbs b { padding: 5px 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crumbs .back { margin-right: 4px; color: var(--text-2); }
.crumbs .sep { width: 14px; height: 14px; color: var(--muted); opacity: .6; }
.ws-body { flex: 1; min-height: 0; overflow: auto; padding: 4px 30px 130px; position: relative; outline: none; transition: background .2s, box-shadow .2s; }
.ws-body.drop-over { background: var(--accent-soft); box-shadow: inset 0 0 0 2px var(--accent); border-radius: 18px; }
.ws-body.drop-over::after { content: "Энд тавиад хуулна"; position: sticky; display: block; width: max-content; margin: 0 auto; bottom: 30px; padding: 10px 18px; border-radius: 14px; background: var(--accent); color: #fff; font-weight: 700; box-shadow: var(--shadow-3); pointer-events: none; }
.ws-body.boxing { user-select: none; }
.ws-body.quiet .rise { animation: none; }
.in-fwd { animation: in-fwd .38s var(--out); }
.in-back { animation: in-back .38s var(--out); }
@keyframes in-fwd { from { opacity: 0; transform: translateX(28px); } }
@keyframes in-back { from { opacity: 0; transform: translateX(-28px); } }

/* gallery */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(178px, 1fr)); gap: 14px; }
.fcard { border-radius: 16px; padding: 8px; position: relative; user-select: none; -webkit-user-select: none; outline: none; content-visibility: auto; contain-intrinsic-size: auto 232px; transition: background .15s, box-shadow .15s; }
.fcard:hover { background: var(--hover); }
.fcard.sel { background: var(--accent-soft); box-shadow: inset 0 0 0 2px var(--accent); }
.fcard.dragging { opacity: .4; }
.fthumb { aspect-ratio: 4 / 3; border-radius: 12px; background: var(--card); border: 1px solid var(--line); display: grid; place-items: center; overflow: hidden; position: relative; box-shadow: var(--shadow-1); transition: box-shadow .2s, transform .25s var(--out); }
.fthumb.has img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fcard:hover .fthumb { box-shadow: var(--shadow-2); transform: translateY(-2px); }
.fcard.drop-target .fthumb { box-shadow: 0 0 0 2px var(--accent), var(--shadow-2); }
.fmeta { padding: 8px 4px 2px; min-width: 0; }
.fname { font-weight: 600; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fsub { font-size: 12px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gsec { font-size: 12.5px; font-weight: 650; color: var(--muted); margin: 4px 4px 10px; }
.grid + .gsec { margin-top: 24px; }
.grid.gdirs { gap: 10px; }
.fdir { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 10px 10px 10px 12px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-1); contain-intrinsic-size: auto 52px; transition: background .15s, box-shadow .15s, transform .2s var(--out); }
.fdir:hover { background: var(--card-h); box-shadow: var(--shadow-2); transform: translateY(-1px); }
.fdir .fmeta { padding: 0; flex: 1; }
.fdir .chk { position: static; flex: none; border-color: var(--line-2); background: transparent; box-shadow: none; }
.fdir.sel { background: var(--accent-soft); box-shadow: inset 0 0 0 2px var(--accent); }
.fdir.drop-target { box-shadow: 0 0 0 2px var(--accent), var(--shadow-2); }
.chk { position: absolute; top: 8px; left: 8px; width: 22px; height: 22px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .95); background: rgba(15, 23, 42, .28); display: grid; place-items: center; opacity: 0; transform: scale(.8); color: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .2); transition: opacity .15s, transform .25s var(--spring), background .15s, border-color .15s; z-index: 2; }
.chk svg.i { width: 13px; height: 13px; stroke-width: 3.2; opacity: 0; transition: opacity .15s; }
.fcard:hover .chk, .selecting .chk { opacity: 1; transform: none; }
.sel .chk { background: var(--accent); border-color: var(--accent); opacity: 1; transform: none; }
.sel .chk svg.i { opacity: 1; }
.fbadge { position: absolute; bottom: 8px; right: 8px; display: inline-flex; gap: 4px; align-items: center; background: rgba(15, 23, 42, .62); color: #fff; font: 700 11px var(--font); padding: 3px 7px; border-radius: 99px; }
.fbadge svg.i { width: 13px; height: 13px; }
.play { position: absolute; inset: 0; margin: auto; width: 42px; height: 42px; border-radius: 50%; background: rgba(15, 23, 42, .45); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); display: grid; place-items: center; color: #fff; pointer-events: none; }
.play svg.i { width: 18px; height: 18px; margin-left: 2px; }

/* list */
.flist { display: flex; flex-direction: column; }
.lhead, .lrow { display: grid; grid-template-columns: 26px minmax(0, 1fr) 96px 96px 140px; align-items: center; gap: 12px; padding: 0 12px; }
.lhead { height: 34px; font-size: 12px; font-weight: 600; color: var(--muted); border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.lrow { height: 48px; border-radius: 10px; user-select: none; -webkit-user-select: none; outline: none; content-visibility: auto; contain-intrinsic-size: auto 48px; font-size: 13.5px; transition: background .12s; }
.lrow:hover { background: var(--hover); }
.lrow.sel { background: var(--accent-soft); }
.lrow.dragging { opacity: .4; }
.lrow.drop-target { box-shadow: inset 0 0 0 2px var(--accent); }
.lrow .chk { position: static; border-color: var(--line-2); background: transparent; box-shadow: none; }
.lrow:hover .chk, .selecting .lrow .chk { opacity: 1; transform: none; }
.lrow.sel .chk { background: var(--accent); border-color: var(--accent); }
.lname { display: flex; align-items: center; gap: 10px; min-width: 0; }
.lsort { display: inline-flex; align-items: center; gap: 4px; justify-self: start; height: 26px; margin: 0 -7px; padding: 0 7px; border: 0; border-radius: 7px; background: none; color: inherit; font: inherit; cursor: pointer; white-space: nowrap; transition: background .15s, color .15s; }
.lsort.r { justify-self: end; }
.lsort:hover { background: var(--hover); color: var(--text); }
.lsort.on { color: var(--text); }
.lsort svg.i { width: 13px; height: 13px; stroke-width: 2.4; }
.b-sort .sort-dir { display: inline-flex; margin-left: -2px; }
.b-sort .sort-dir svg.i { width: 13px; height: 13px; stroke-width: 2.4; }
.lname span:not(.kc) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 550; }
.kc { display: inline-flex; align-items: center; gap: 3px; color: var(--accent); font-weight: 600; font-size: 12px; }
.kc svg.i { width: 14px; height: 14px; }
.lname .kc { flex: none; }
.lthumb { width: 28px; height: 28px; border-radius: 7px; object-fit: cover; flex: none; }
.r { text-align: right; }

.marquee { position: absolute; border: 1px solid var(--accent); background: rgba(10, 132, 255, .12); border-radius: 4px; pointer-events: none; z-index: 5; }
.drag-count { position: fixed; top: -100px; left: 0; padding: 8px 14px; border-radius: 12px; background: var(--accent); color: #fff; font: 700 13px var(--font); }

/* selection bar */
.selbar { position: absolute; left: 50%; bottom: 22px; transform: translate(-50%, 160%); display: flex; align-items: center; gap: 6px; padding: 6px 6px 6px 16px; border-radius: 18px; background: var(--glass-2); opacity: 0; pointer-events: none; transition: transform .5s var(--spring), opacity .2s; z-index: 20; max-width: calc(100% - 24px); }
.selbar.on { transform: translate(-50%, 0); opacity: 1; pointer-events: auto; }
.sel-n { font-size: 13.5px; white-space: nowrap; margin-right: 6px; color: var(--text-2); }
.sel-n b { font-size: 15px; color: var(--text); }
.sel-acts { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.sel-acts button { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 12px; border: 0; background: none; color: var(--text); border-radius: 12px; font: 600 13px var(--font); cursor: pointer; white-space: nowrap; transition: background .15s; }
.sel-acts button:hover { background: var(--hover); }
.sel-acts button svg.i { width: 18px; height: 18px; }
.sel-acts .danger { color: var(--bad); }

/* empty states and skeletons */
.empty { display: grid; justify-items: center; text-align: center; gap: 6px; padding: 60px 20px; }
.empty.big { padding: 80px 20px; }
.empty-ico { width: 74px; height: 74px; border-radius: 24px; display: grid; place-items: center; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-2); color: var(--accent); margin-bottom: 8px; animation: float 5s ease-in-out infinite; }
.empty-ico.bad { color: var(--bad); }
.empty-ico svg.i { width: 32px; height: 32px; }
.empty h2, .empty h3 { margin: 4px 0 0; font-size: 19px; letter-spacing: -.01em; }
.empty p { margin: 0; max-width: 420px; }
.empty-acts { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; justify-content: center; }
.empty-s { padding: 18px 6px; text-align: center; margin: 0; font-size: 13.5px; }
.sk { border-radius: 14px; background: linear-gradient(90deg, var(--hover) 25%, var(--press) 50%, var(--hover) 75%); background-size: 200% 100%; animation: shimmer 1.3s infinite linear; height: 58px; margin-bottom: 8px; }
.sk.tall { height: 96px; }
.grid.skel .sk { height: 196px; margin: 0; }
.flist.skel .sk { height: 44px; margin-bottom: 6px; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ------------------------------------------------------------ sheets, menus, toasts */
.scrim { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(8, 12, 24, .34); animation: fade .22s ease both; }
.scrim.out { animation: fade-out .19s ease forwards; }
.sheet { width: min(560px, 100%); max-height: calc(100dvh - 40px); display: flex; flex-direction: column; border-radius: 26px; outline: none; overflow: hidden; animation: sheet-in .46s var(--spring) both; }
.sheet.glass { background: var(--glass-2); }
.scrim.out .sheet { animation: sheet-out .19s ease forwards; }
.sheet.narrow { width: min(450px, 100%); }
.sheet.wide { width: min(860px, 100%); }
.sheet-head { display: flex; align-items: center; gap: 10px; padding: 18px 16px 4px 22px; }
.sheet-title { flex: 1; min-width: 0; font-size: 18px; font-weight: 700; letter-spacing: -.015em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sheet-body { padding: 10px 22px 16px; overflow-x: hidden; overflow-y: auto; }
.sheet-body .msg { margin: 0; color: var(--text-2); line-height: 1.55; white-space: pre-line; }
.sheet-foot { display: flex; justify-content: flex-end; align-items: center; gap: 8px; padding: 10px 18px 18px; flex-wrap: wrap; }
@keyframes sheet-in { from { opacity: 0; transform: translateY(16px) scale(.95); } }
@keyframes sheet-out { to { opacity: 0; transform: translateY(8px) scale(.98); } }
@keyframes fade { from { opacity: 0; } }
@keyframes fade-out { to { opacity: 0; } }
.menu { position: fixed; z-index: 200; min-width: 210px; max-width: 320px; max-height: calc(100dvh - 16px); overflow-y: auto; overscroll-behavior: contain; padding: 6px; border-radius: 15px; background: var(--glass-2); animation: menu-in .22s var(--out) both; }
.menu.out { animation: menu-out .13s ease forwards; }
@keyframes menu-in { from { opacity: 0; transform: scale(.94) translateY(-4px); } }
@keyframes menu-out { to { opacity: 0; transform: scale(.97); } }
.menu-i { display: flex; align-items: center; gap: 10px; width: 100%; height: 36px; padding: 0 10px; border: 0; background: none; border-radius: 10px; color: var(--text); font: 500 14px var(--font); cursor: pointer; text-align: left; white-space: nowrap; animation: rise .3s var(--out) both; animation-delay: calc(var(--d, 0) * 14ms); }
.menu-i:hover, .menu-i:focus-visible { background: var(--accent); color: #fff; outline: none; }
.menu-i svg.i, .menu-i i.i { width: 18px; height: 18px; display: block; flex: none; }
.menu-i span { flex: 1; overflow: hidden; text-overflow: ellipsis; }
.menu-i kbd { font: 500 11.5px var(--font); color: var(--muted); }
.menu-i:hover kbd, .menu-i:focus-visible kbd { color: rgba(255, 255, 255, .8); }
.menu-i.danger { color: var(--bad); }
.menu-i.danger:hover, .menu-i.danger:focus-visible { background: var(--bad); color: #fff; }
.menu-i:disabled { opacity: .4; pointer-events: none; }
.menu-sep { height: 1px; background: var(--line); margin: 5px 8px; }
.menu-head { padding: 6px 10px 4px; font-size: 12px; font-weight: 700; color: var(--muted); }
.toasts { position: fixed; left: 50%; top: 16px; transform: translateX(-50%); z-index: 300; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; width: max-content; max-width: calc(100vw - 32px); }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 10px; padding: 10px 16px 10px 12px; border-radius: 16px; font-weight: 550; font-size: 14px; background: var(--glass-2); animation: toast-in .5s var(--spring) both; max-width: 100%; cursor: default; }
.toast span { overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.toast svg.i { color: var(--ok); width: 20px; height: 20px; }
.toast.err svg.i { color: var(--bad); }
.toast.link svg.i { color: var(--accent); }
.toast.out { animation: toast-out .26s ease forwards; }
@keyframes toast-in { from { opacity: 0; transform: translateY(-18px) scale(.95); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(-10px) scale(.97); } }

/* ------------------------------------------------------------ upload tray */
.tray { position: fixed; right: 20px; bottom: 20px; z-index: 90; width: 370px; max-width: calc(100vw - 24px); border-radius: 22px; overflow: hidden; background: var(--glass-2); animation: tray-in .5s var(--spring) both; transition: transform .45s var(--spring), opacity .25s; }
.tray.gone { transform: translateY(150%); opacity: 0; pointer-events: none; }
@keyframes tray-in { from { transform: translateY(120%); opacity: 0; } }
.tray-head { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; border: 0; background: none; color: var(--text); cursor: pointer; text-align: left; font: inherit; }
.tray-ring { width: 42px; height: 42px; flex: none; }
.tray-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.tray-txt b { font-size: 14px; }
.tray-txt small { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tray-chev { color: var(--muted); transition: transform .35s var(--out); }
.tray.open .tray-chev { transform: rotate(180deg); }
.tray-body { max-height: 0; overflow: hidden; transition: max-height .45s var(--out); }
.tray.open .tray-body { max-height: 440px; }
.tray-list { max-height: 340px; overflow: auto; padding: 0 8px; border-top: 1px solid var(--line); }
.trow { display: flex; align-items: center; gap: 10px; padding: 8px 4px; border-bottom: 1px solid var(--line); }
.trow:last-child { border-bottom: 0; }
.trow-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.trow-main b { font-size: 13px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trow-main small { font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trow-main .bar { height: 4px; }
.trow > span { font-size: 12px; font-weight: 700; flex: none; font-variant-numeric: tabular-nums; }
.trow > span svg.i { width: 18px; height: 18px; }
.trow .ok { color: var(--ok); } .trow .bad { color: var(--bad); }
.tray-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 10px 12px; }
.tray[data-state="done"] .ring-fg { stroke: var(--ok); }
.tray[data-state="err"] .ring-fg { stroke: var(--bad); }
.tray[data-state="wait"] .ring-fg { stroke: var(--warn); }

/* ------------------------------------------------------------ viewer */
.lb { position: fixed; inset: 0; z-index: 150; display: flex; flex-direction: column; outline: none; color: #fff; }
.lb-bg { position: absolute; inset: 0; background: rgba(5, 7, 13, .93); -webkit-backdrop-filter: blur(22px) saturate(140%); backdrop-filter: blur(22px) saturate(140%); animation: fade .32s ease both; }
.lb.out .lb-bg { animation: fade-out .26s ease forwards; }
.lb.out .lb-top, .lb.out .lb-side, .lb.out .lb-nav, .lb.out .lb-media, .lb.out .lb-file { opacity: 0; transition: opacity .15s; }
.lb-top { position: relative; z-index: 2; display: flex; align-items: center; gap: 10px; padding: 12px 14px; animation: drop-in .45s var(--out) both; }
@keyframes drop-in { from { opacity: 0; transform: translateY(-10px); } }
.lb-top .icon-btn { color: rgba(255, 255, 255, .85); }
.lb-top .icon-btn:hover { background: rgba(255, 255, 255, .13); color: #fff; }
.lb-title { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.lb-title b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; }
.lb-title small { color: rgba(255, 255, 255, .6); font-size: 12px; }
.lb-acts { display: flex; gap: 4px; }
.lb-cn { position: absolute; top: 1px; right: -1px; font: 800 10px/14px var(--font); font-style: normal; background: var(--accent); color: #fff; border-radius: 99px; padding: 0 5px; }
.lb-cn:empty { display: none; }
.lb-main { position: relative; z-index: 1; flex: 1; min-height: 0; display: flex; }
.lb-stage { flex: 1; min-width: 0; position: relative; overflow: hidden; }
.lb-pane { position: absolute; inset: 0; display: grid; place-items: center; padding: 24px; }
.lb-img { display: block; border-radius: 6px; box-shadow: 0 30px 90px -20px rgba(0, 0, 0, .7); user-select: none; -webkit-user-select: none; -webkit-user-drag: none; background: rgba(255, 255, 255, .04); transition: width .25s var(--out), height .25s var(--out); }
.lb-pane.loading::after { content: ""; position: absolute; width: 34px; height: 34px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .2); border-top-color: #fff; animation: spin .8s linear infinite; }
.lb-media { max-width: 100%; max-height: 100%; border-radius: 12px; box-shadow: 0 30px 90px -20px rgba(0, 0, 0, .7); outline: none; background: #000; animation: fade .3s ease both; }
audio.lb-media { width: min(520px, 92%); background: none; box-shadow: none; }
.lb-pane:has(audio) { grid-template-rows: auto auto; align-content: center; gap: 22px; }
.lb-audio .tile { animation: float 4s ease-in-out infinite; }
.lb-file { display: grid; justify-items: center; gap: 12px; text-align: center; max-width: 420px; animation: sheet-in .45s var(--spring) both; }
.lb-file b { font-size: 17px; word-break: break-word; }
.lb-file p { margin: 0; color: rgba(255, 255, 255, .65); }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; width: 48px; height: 48px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .12); color: #fff; display: grid; place-items: center; cursor: pointer; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); transition: background .2s, transform .25s var(--spring), right .4s var(--spring); }
.lb-nav:hover { background: rgba(255, 255, 255, .22); transform: translateY(-50%) scale(1.07); }
.lb-nav.prev { left: 16px; } .lb-nav.next { right: 16px; }
.lb.side-open .lb-nav.next { right: 368px; }
.lb-side { width: 0; overflow: hidden; margin: 0 12px 12px 0; border-radius: 22px; color: var(--text); display: flex; flex-direction: column; background: var(--glass-2); opacity: 0; border-width: 0; transition: width .45s var(--spring), opacity .25s, border-width .2s; }
.lb.side-open .lb-side { width: 340px; opacity: 1; border-width: 1px; }
.lb-side > * { min-width: 316px; }
.cm-head { display: flex; align-items: center; gap: 8px; padding: 14px 16px 6px; }
.cm-n { font-weight: 700; }
.cm-list { flex: 1; min-height: 0; overflow: auto; padding: 6px 12px 10px; display: flex; flex-direction: column; gap: 10px; }
.cm { max-width: 90%; align-self: flex-start; animation: rise .35s var(--out) both; }
.cm.me { align-self: flex-end; }
.cm-meta { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--muted); margin: 0 6px 3px; }
.cm.me .cm-meta { justify-content: flex-end; }
.cm-txt { padding: 9px 13px; border-radius: 18px 18px 18px 6px; background: var(--card-h); border: 1px solid var(--line); white-space: pre-wrap; word-break: break-word; font-size: 14px; line-height: 1.45; }
.cm.me .cm-txt { background: var(--accent); color: #fff; border-color: transparent; border-radius: 18px 18px 6px 18px; }
.tc { border: 0; background: rgba(10, 132, 255, .16); color: inherit; font: 700 12px var(--font); padding: 1px 6px; border-radius: 6px; cursor: pointer; }
.cm.me .tc { background: rgba(255, 255, 255, .25); }
.cm-del { border: 0; background: none; color: var(--muted); cursor: pointer; padding: 0; display: grid; opacity: 0; transition: opacity .15s; }
.cm-del svg.i { width: 14px; height: 14px; }
.cm:hover .cm-del { opacity: 1; }
.cm-empty { display: grid; justify-items: center; gap: 8px; text-align: center; padding: 40px 16px; color: var(--muted); margin: auto 0; }
.cm-empty svg.i { width: 32px; height: 32px; opacity: .5; }
.cm-empty p { margin: 0; }
.cm-form { display: flex; align-items: flex-end; gap: 6px; padding: 10px; border-top: 1px solid var(--line); }
.cm-form textarea { flex: 1; min-width: 0; resize: none; border: 1px solid var(--line-2); border-radius: 18px; padding: 8px 14px; font: 14px/1.4 var(--font); background: var(--card); color: var(--text); outline: none; max-height: 140px; transition: border-color .15s, box-shadow .2s; }
.cm-form textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.cm-form .icon-btn { border-radius: 50%; }

/* ------------------------------------------------------------ animated buttons */
/* Send: one transform per moving part, nothing reflows. */
.sendbtn { --bh: 52px; position: relative; height: var(--bh); min-width: 190px; padding: 0 28px 0 calc(var(--bh) + 14px); border: 0; border-radius: 999px; background: #111827; color: #fff; font: 700 15px var(--font); letter-spacing: .01em; cursor: pointer; overflow: hidden; isolation: isolate; box-shadow: 0 12px 26px -12px rgba(17, 24, 39, .7); transition: transform .16s var(--out); }
:root[data-theme="dark"] .sendbtn { background: #233046; box-shadow: 0 12px 26px -12px rgba(0, 0, 0, .8), inset 0 0 0 1px rgba(255, 255, 255, .08); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .sendbtn { background: #233046; box-shadow: 0 12px 26px -12px rgba(0, 0, 0, .8), inset 0 0 0 1px rgba(255, 255, 255, .08); } }
.sendbtn:active { transform: scale(.97); }
.sb-wake { position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(90deg, #16a34a, #22c55e); transform: translate3d(calc(-100% + var(--bh)), 0, 0); transition: transform .717s cubic-bezier(.30, .10, .00, .90); z-index: -1; }
.sb-plane { position: absolute; left: 0; top: 0; width: var(--bh); height: var(--bh); display: grid; place-items: center; color: #fff; }
.sb-plane svg.i { width: 22px; height: 22px; stroke-width: 2; }
.sb-dash { position: absolute; right: 62%; top: 50%; height: 2px; width: 0; border-radius: 2px; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .85)); }
.sb-word { position: relative; display: inline-block; transition: opacity .17s, transform .17s; }
.sb-sent { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; pointer-events: none; }
.sb-sent span { display: inline-block; opacity: 0; transform: translateY(10px); }
.sendbtn:not([data-state="idle"]) { pointer-events: none; }
.sendbtn[data-state="fly"] .sb-word, .sendbtn[data-state="sent"] .sb-word { opacity: 0; transform: translateX(16px); }
.sendbtn[data-state="fly"] .sb-wake, .sendbtn[data-state="sent"] .sb-wake { transform: none; }
.sendbtn[data-state="fly"] .sb-plane { animation: sb-fly .533s cubic-bezier(.698, .187, .322, .847) .2s forwards; }
.sendbtn[data-state="fly"] .sb-dash { animation: sb-dash .52s ease-out .24s forwards; }
.sendbtn[data-state="sent"] .sb-plane { opacity: 0; }
.sendbtn[data-state="sent"] .sb-sent span { animation: sb-land .34s var(--spring) forwards; animation-delay: calc(var(--i) * 30ms); }
@keyframes sb-fly { 0% { transform: none; } 28% { transform: translateX(-6px) rotate(-8deg); } 100% { transform: translateX(calc(var(--w, 220px) - var(--bh) / 2)) scale(1.18); opacity: 0; } }
@keyframes sb-dash { 50% { width: 64px; } to { width: 0; } }
@keyframes sb-land { to { opacity: 1; transform: none; } }

/* Delete: the bin eats the label, the pill closes to a disc, a ring is drawn while the server works. */
.eatbtn { --bh: 40px; position: relative; height: var(--bh); min-width: 116px; padding: 0 18px 0 calc(var(--bh) + 2px); border: 0; background: none; color: #fff; font: 700 14px var(--font); cursor: pointer; isolation: isolate; display: inline-flex; align-items: center; transition: transform .16s var(--out); }
.eatbtn:active { transform: scale(.97); }
.eb-face { position: absolute; inset: 0; border-radius: 999px; background: linear-gradient(180deg, #f2545b, #d92d36); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25); z-index: -1; clip-path: inset(0 0 0 0 round 999px); transition: clip-path .44s cubic-bezier(.65, 0, .35, 1); }
.eb-bin { position: absolute; left: 0; top: 0; width: var(--bh); height: var(--bh); display: grid; place-items: center; }
.eb-bin svg { width: 20px; height: 20px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; overflow: visible; }
.eb-lid { transform-origin: 19px 7px; transition: transform .28s var(--spring); }
.eb-label { display: inline-flex; white-space: pre; }
.eb-label span { display: inline-block; }
.eb-ring { position: absolute; left: -4px; top: -4px; width: calc(var(--bh) + 8px); height: calc(var(--bh) + 8px); opacity: 0; pointer-events: none; }
.eb-ring circle { fill: none; stroke: #ef4444; stroke-width: 2.6; stroke-linecap: round; stroke-dasharray: 0 140; transform-origin: center; transform: rotate(-90deg); }
.eatbtn[data-state="eat"], .eatbtn[data-state="done"] { pointer-events: none; }
.eatbtn[data-state="eat"] .eb-lid { transform: rotate(-30deg) translate(-1px, -2px); }
.eatbtn[data-state="eat"] .eb-label span { animation: eb-fly .5s cubic-bezier(.5, 0, .75, 0) forwards; animation-delay: calc(var(--i) * 38ms); }
.eatbtn[data-state="eat"] .eb-face, .eatbtn[data-state="done"] .eb-face { clip-path: inset(0 calc(100% - var(--bh)) 0 0 round 999px); transition-delay: calc(var(--n) * 38ms + 160ms); }
.eatbtn[data-state="eat"] .eb-ring { opacity: 1; transition: opacity .2s calc(var(--n) * 38ms + 420ms); }
.eatbtn[data-state="eat"] .eb-ring circle { animation: eb-draw 1.1s ease-in-out calc(var(--n) * 38ms + 420ms) infinite alternate, spin 1.4s linear infinite; }
.eatbtn[data-state="done"] .eb-label span { opacity: 0; }
.eatbtn[data-state="done"] .eb-ring { opacity: 1; }
.eatbtn[data-state="done"] .eb-ring circle { stroke-dasharray: 140 140; transition: stroke-dasharray .3s ease-out; }
.eatbtn[data-state="done"] .eb-lid { transform: none; }
@keyframes eb-fly { 0% { transform: none; } 45% { transform: translate(calc(var(--dx) * .45), -16px) rotate(-30deg); } 100% { transform: translate(var(--dx), 2px) scale(.2) rotate(-60deg); opacity: 0; } }
@keyframes eb-draw { from { stroke-dasharray: 10 140; } to { stroke-dasharray: 96 140; } }

/* ------------------------------------------------------------ send page */
.send-grid { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 20px; align-items: start; }
.send-card { border-radius: 28px; padding: 22px; display: flex; flex-direction: column; gap: 18px; transition: box-shadow .25s; }
.send-card.over { box-shadow: 0 0 0 3px var(--accent), var(--shadow-3); }
.drop { border: 2px dashed var(--line-2); border-radius: 22px; display: grid; justify-items: center; gap: 8px; padding: 42px 20px; text-align: center; cursor: pointer; outline: none; transition: border-color .2s, background .2s, padding .45s var(--out); }
.drop:hover, .drop:focus-visible, .drop.over, .send-card.over .drop { border-color: var(--accent); background: var(--accent-soft); }
.drop b { font-size: 16px; }
.drop-ico { width: 66px; height: 66px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: #fff; box-shadow: 0 14px 30px -12px var(--accent); transition: transform .45s var(--spring); margin-bottom: 4px; }
.drop:hover .drop-ico { transform: scale(1.08) rotate(90deg); }
.drop-ico svg.i { width: 28px; height: 28px; stroke-width: 2.2; }
.drop-btns { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 4px; }
.drop.mini { grid-template-columns: auto 1fr auto; justify-items: start; align-items: center; padding: 12px 14px; text-align: left; column-gap: 14px; }
.drop.mini .drop-ico { width: 40px; height: 40px; margin: 0; box-shadow: none; }
.drop.mini .drop-ico svg.i { width: 20px; height: 20px; }
.drop.mini > .muted { display: none; }
.drop.mini b { font-size: 14px; }
.drop.mini .drop-btns { margin: 0; }
.staged { border: 1px solid var(--line); border-radius: 18px; background: var(--card); overflow: hidden; animation: rise .4s var(--out) both; }
.staged-head { display: flex; align-items: center; gap: 8px; padding: 10px 10px 10px 16px; border-bottom: 1px solid var(--line); }
.staged-list { max-height: 250px; overflow: auto; padding: 6px; }
.srow { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 12px; }
.srow:hover { background: var(--hover); }
.srow-main, .row-main, .lnk-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.srow-main b, .row-main b, .lnk-main b { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.srow-main small, .row-main small, .lnk-main small { font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.send-opts, .link-opts { display: flex; flex-direction: column; gap: 14px; }
.dest-row { display: flex; gap: 8px; flex-wrap: wrap; }
.picker { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--card); color: var(--text); font: 500 14px var(--font); cursor: pointer; max-width: 100%; transition: border-color .15s, background .15s; }
.picker:hover { border-color: var(--accent); }
.picker span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.picker > svg.i:last-child { width: 16px; height: 16px; color: var(--muted); }
.picker:disabled { opacity: .5; pointer-events: none; }
.send-foot { display: flex; justify-content: flex-end; gap: 10px; align-items: center; flex-wrap: wrap; }
.send-card.sending { align-items: center; text-align: center; padding: 44px 22px 28px; gap: 10px; }
.sending-hero { position: relative; width: 170px; height: 170px; margin-bottom: 6px; }
.big-ring { width: 100%; height: 100%; }
.big-ring circle { stroke-width: 3.2; }
.sh-pct { position: absolute; inset: 0; display: grid; place-items: center; font-size: 36px; font-weight: 750; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.sh-title { margin: 6px 0 0; font-size: 20px; letter-spacing: -.015em; word-break: break-word; }
.sh-sub { margin: 0; font-variant-numeric: tabular-nums; }
.sh-where { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; }
.sh-where svg.i { width: 16px; height: 16px; }
.send-card.sending .send-foot { justify-content: center; margin-top: 10px; }
.send-card.done { padding: 30px 22px 22px; }
.send-card.done .send-foot { justify-content: center; }
.send-side { display: flex; flex-direction: column; gap: 16px; }
.side-card { border-radius: 22px; padding: 16px; }
.sc-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.sc-head a { display: inline-flex; align-items: center; gap: 2px; text-decoration: none; font-size: 13px; font-weight: 600; }
.sc-head a svg.i { width: 15px; height: 15px; }
@media (max-width: 1180px) { .send-grid { grid-template-columns: minmax(0, 1fr); } .send-side { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
@media (max-width: 1180px) and (max-width: 640px) { .send-side { grid-template-columns: 1fr; } }
.tips ol { margin: 8px 0 0; padding-left: 20px; color: var(--text-2); line-height: 1.85; font-size: 13.5px; }

/* the finished link */
.link-done { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: center; gap: 6px; padding: 6px 0 4px; }
.link-done > * { max-width: 100%; }
.ld-badge { width: 74px; height: 74px; border-radius: 50%; background: var(--ok); color: #fff; display: grid; place-items: center; box-shadow: 0 16px 36px -14px var(--ok); animation: pop .65s var(--spring) both; }
.ld-badge svg.i { width: 36px; height: 36px; stroke-width: 2.6; stroke-dasharray: 30; stroke-dashoffset: 30; animation: draw .5s .25s var(--out) forwards; }
.link-done h3 { margin: 8px 0 0; font-size: 22px; letter-spacing: -.02em; }
.ld-sub { margin: 0; }
.link-box { display: flex; align-items: center; gap: 8px; width: 100%; max-width: 540px; padding: 6px 6px 6px 16px; border-radius: 16px; border: 1px solid var(--line-2); background: var(--card); margin-top: 12px; animation: rise .5s .15s var(--out) both; }
.lb-url { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 600 14.5px var(--mono); text-align: left; cursor: pointer; }
.lb-copy { transition: background .3s, transform .16s var(--out); }
.lb-copy.copied { background: var(--ok); box-shadow: 0 8px 20px -10px var(--ok); }
.ld-meta { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 8px; }
.share-what { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 16px; background: var(--hover); margin-bottom: 16px; }
.share-what > div { display: flex; flex-direction: column; min-width: 0; }
.share-what b, .share-what small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pills.seg { align-self: flex-start; overflow-x: auto; scrollbar-width: none; }
.pills.seg::-webkit-scrollbar { display: none; }

/* links */
.lnk-list, .recent-links { display: flex; flex-direction: column; gap: 8px; }
.lnk { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-1); transition: transform .25s var(--out), opacity .2s, box-shadow .2s; }
.lnk:hover { box-shadow: var(--shadow-2); }
.recent-links .lnk { padding: 8px 6px 8px 8px; background: transparent; border: 0; box-shadow: none; border-radius: 12px; }
.recent-links .lnk:hover { background: var(--hover); }
.lnk.gone { opacity: .62; }
.lnk.leaving { opacity: 0; transform: translateX(24px); }
.lnk-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.lnk-acts { display: flex; gap: 2px; }
.l-copy.ok { color: var(--ok); }

/* clients */
.cgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(286px, 1fr)); gap: 16px; }
.ccard { border-radius: 24px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-1); padding: 16px; display: flex; flex-direction: column; gap: 14px; position: relative; overflow: hidden; transition: transform .3s var(--out), box-shadow .3s; }
.ccard::before { content: ""; position: absolute; inset: 0; background: linear-gradient(165deg, hsla(var(--h), 85%, 62%, .26), hsla(calc(var(--h) + 40), 85%, 60%, .06) 45%, transparent 70%); pointer-events: none; }
.ccard:hover { transform: translateY(-3px); box-shadow: var(--shadow-3); }
.cc-open { all: unset; cursor: pointer; display: flex; flex-direction: column; gap: 14px; position: relative; border-radius: 14px; }
.cc-open:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.cc-top { display: flex; align-items: center; gap: 12px; min-width: 0; }
.cc-tt { display: flex; flex-direction: column; min-width: 0; }
.cc-tt b { font-size: 16.5px; letter-spacing: -.01em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cc-tt small { font-size: 12.5px; }
.cc-stats { display: flex; gap: 14px; font-size: 13px; color: var(--text-2); flex-wrap: wrap; }
.cc-pw { display: flex; align-items: center; gap: 6px; padding: 5px 5px 5px 12px; border-radius: 12px; background: var(--hover); font-size: 12.5px; }
.cc-pw code { flex: 1; font: 600 13px var(--mono); letter-spacing: .03em; }
.cc-codes { display: flex; align-items: center; gap: 8px; margin-top: -6px; padding: 6px 10px 6px 12px; border: 0; border-radius: 12px; background: transparent; color: var(--text-2); font: 600 12.5px var(--font); cursor: pointer; text-align: left; }
.cc-codes span { flex: 1; }
.cc-codes svg.i { width: 15px; height: 15px; color: var(--muted); }
.cc-codes:hover { background: var(--hover); color: var(--text); }
.codes { display: flex; flex-direction: column; gap: 6px; margin-top: 4px; }
.codes-empty, .adm-empty { margin: 2px 0; }
.code-row { display: flex; align-items: center; gap: 4px; padding: 6px 6px 6px 12px; border-radius: 12px; background: var(--hover); min-width: 0; }
.cr-tt { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.cr-tt b, .cr-tt small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cr-tt b { font-size: 13.5px; }
.cr-tt small { font-size: 11.5px; }
.code-row code { font: 600 12.5px var(--mono); letter-spacing: .03em; margin: 0 4px; white-space: nowrap; }
.code-row .k-del.armed, .adm-row .a-del.armed { color: var(--bad); background: rgba(239, 68, 68, .12); }
.code-add { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; padding-top: 10px; border-top: 1px dashed var(--line-2); }
.adm-list { display: flex; flex-direction: column; gap: 4px; }
.adm-row { display: flex; align-items: center; gap: 10px; padding: 8px 6px 8px 8px; border-radius: 14px; }
.adm-row:hover { background: var(--hover); }
.adm-tt { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.adm-tt b { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adm-tt small { font-size: 12px; }
.adm-link { display: inline-flex; align-items: center; gap: 5px; align-self: flex-start; max-width: 100%; margin-top: 3px; padding: 2px 8px 2px 6px; border: 0; border-radius: 8px; background: var(--accent-soft); color: var(--accent); font: 600 12px var(--mono); cursor: pointer; }
.adm-link span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adm-link svg.i { width: 13px; height: 13px; flex: none; }
.adm-link:hover { filter: brightness(1.1); }
.adm-list .sk { height: 44px; border-radius: 14px; }
.cg-sec { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; margin: 10px 2px -4px; font-size: 14px; }
.cg-sec:first-child { margin-top: 0; }
.cg-sec svg.i { width: 18px; height: 18px; color: var(--muted); }
.cg-sec small { font-size: 12.5px; }
.cc-acts { display: flex; gap: 8px; }
.cc-acts .btn { flex: 1; }
.ccard.add { align-items: center; justify-content: center; text-align: center; border: 2px dashed var(--line-2); background: transparent; box-shadow: none; cursor: pointer; min-height: 230px; color: var(--text); font: inherit; gap: 6px; }
.ccard.add::before { display: none; }
.ccard.add:hover { border-color: var(--accent); background: var(--accent-soft); }
.add-ico { width: 54px; height: 54px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; margin-bottom: 6px; transition: transform .4s var(--spring); }
.ccard.add:hover .add-ico { transform: rotate(90deg) scale(1.06); }
.logo-row { display: flex; gap: 16px; align-items: center; }
.logo-box .ava { --s: 74px; border-radius: 22px; }
.logo-btns { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.danger-zone { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 16px; border: 1px solid rgba(239, 68, 68, .25); background: rgba(239, 68, 68, .06); }
.danger-zone > div { flex: 1; display: flex; flex-direction: column; gap: 2px; }

/* notifications */
.act-list { display: flex; flex-direction: column; gap: 6px; }
.act { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 12px 14px; border-radius: 18px; border: 1px solid var(--line); background: var(--card); color: var(--text); font: inherit; cursor: pointer; transition: box-shadow .2s, transform .25s var(--out); }
.act:hover { box-shadow: var(--shadow-2); transform: translateY(-1px); }
.act.unread { box-shadow: inset 3px 0 0 var(--accent); }
.act-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.act-l1 { display: flex; align-items: center; gap: 8px; min-width: 0; }
.act-l1 .who { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.act-chip { flex: none; font-size: 11.5px; font-weight: 700; padding: 2px 9px; border-radius: 99px; background: var(--hover); color: var(--text-2); display: inline-flex; align-items: center; }
.act.ok .act-chip { background: rgba(34, 197, 94, .14); color: var(--ok-ink); }
.act.live .act-chip { background: var(--accent-soft); color: var(--accent); }
.act.live .act-chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; margin-right: 5px; animation: pulse 1.2s ease-in-out infinite; }
.act.bad .act-chip { background: rgba(245, 158, 11, .16); color: #b45309; }
.act.up .act-chip { background: rgba(139, 92, 246, .14); color: #7c3aed; }
.act.cm .act-chip { background: rgba(236, 72, 153, .13); color: #db2777; }
.act-l2 { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.act-l3 { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text-2); min-width: 0; }
.act-l3:empty { display: none; }
.act-l3 .bar { width: 150px; }
.act-l3 small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.act-time { font-size: 12px; white-space: nowrap; flex: none; }
.who-sum { margin: 0 0 4px; }
.who-client { display: flex; align-items: center; gap: 10px; margin: 18px 0 6px; font-size: 15px; }
.who-row { display: grid; grid-template-columns: 200px minmax(0, 1fr) 230px 130px; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 12px; width: 100%; border: 0; background: none; text-align: left; font: inherit; color: var(--text); }
.who-row.click { cursor: pointer; }
.who-row.click:hover { background: var(--hover); }
.who-f { display: flex; align-items: center; gap: 6px; font-weight: 600; min-width: 0; }
.who-f svg.i { width: 17px; height: 17px; color: var(--muted); }
.who-p, .who-pr { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.g-who { display: flex; align-items: center; gap: 12px; }
.g-tt { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.g-btns { display: flex; gap: 6px; flex-wrap: wrap; }
.g-stats { display: grid; grid-template-columns: 1fr 1fr 1.4fr; gap: 10px; margin: 14px 0 6px; }
.g-stats > div { padding: 10px 12px; border-radius: 14px; background: var(--hover); display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.g-stats b { font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; }
.g-status { margin: 6px 0; font-weight: 600; }
.g-status.ok { color: var(--ok-ink); } .g-status.live { color: var(--accent); } .g-status.bad { color: #b45309; }
.g-tabs { margin: 12px 0 8px; }
.g-list { max-height: 46dvh; overflow: auto; }
.g-row { display: grid; grid-template-columns: 28px minmax(0, 1fr) 80px 110px 150px; gap: 10px; align-items: center; padding: 6px 8px; border-radius: 10px; font-size: 13px; }
.g-row:hover { background: var(--hover); }
.g-row svg.i { width: 16px; height: 16px; }
.g-n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* settings */
.set-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; align-items: start; }
.set-card { border-radius: 24px; padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.set-card h3 { margin: 4px 0 0; font-size: 17px; }
.set-card p { margin: 0; }
.set-card .btn { align-self: flex-start; }
.set-ico { width: 46px; height: 46px; border-radius: 15px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; }
.gm-text { padding: 12px 14px; border-radius: 14px; background: var(--hover); font-weight: 600; white-space: pre-wrap; }
.about { display: flex; flex-direction: column; }
.about div { display: flex; justify-content: space-between; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.about div:last-child { border-bottom: 0; }

/* dialogs bits */
.rows .row { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.mv-path { margin-top: 2px; }
.mv-list { max-height: 300px; overflow: auto; margin-top: 8px; display: flex; flex-direction: column; gap: 2px; transition: opacity .2s; }
.mv-list.loading { opacity: .5; }
.mv-row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border: 0; background: none; border-radius: 12px; color: var(--text); font: 500 14px var(--font); cursor: pointer; text-align: left; }
.mv-row span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mv-row:hover { background: var(--hover); }
.mv-row > svg.i { color: var(--muted); width: 16px; height: 16px; }
.help { display: flex; flex-direction: column; gap: 16px; }
.help-i { display: flex; gap: 12px; }
.help-i > svg.i { width: 22px; height: 22px; color: var(--accent); margin-top: 1px; }
.help-i p { margin: 2px 0 0; }
.help-call { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 14px; background: var(--accent-soft); color: var(--accent); }
.help-call a { color: inherit; }
.dl-sheet .sheet-body { text-align: center; }
.dl-hero { position: relative; width: 98px; height: 98px; margin: 4px auto 12px; }
.dl-ring { width: 100%; height: 100%; }
.dl-hero .dl-ico { position: absolute; inset: 0; margin: auto; width: 34px; height: 34px; color: var(--accent); }
.dl-sheet.busy .dl-hero .dl-ico { animation: bob 1s ease-in-out infinite; }
.dl-name { font-weight: 700; font-size: 17px; word-break: break-word; }
.dl-msg { margin-top: 2px; }
.dl-now { font-size: 12.5px; margin-top: 10px; min-height: 18px; word-break: break-word; line-height: 1.5; }
.dl-sheet .sheet-foot { justify-content: center; }

/* games */
.game-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.gcard { display: flex; flex-direction: column; gap: 14px; padding: 14px; border-radius: 24px; border: 1px solid var(--line); background: var(--card); text-align: left; font: inherit; color: var(--text); cursor: pointer; box-shadow: var(--shadow-1); transition: transform .3s var(--out), box-shadow .3s; }
.gcard:hover { transform: translateY(-4px); box-shadow: var(--shadow-3); }
.g-art { height: 136px; border-radius: 18px; display: grid; place-items: center; background: radial-gradient(circle at 28% 18%, hsla(var(--h), 95%, 78%, .9), transparent 58%), linear-gradient(135deg, hsl(var(--h) 80% 56%), hsl(calc(var(--h) + 50) 72% 44%)); color: #fff; overflow: hidden; }
.g-art svg { width: 66px; height: 66px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .28)); transition: transform .5s var(--spring); }
.gcard:hover .g-art svg { transform: scale(1.12) rotate(-6deg); }
.g-tt { display: flex; flex-direction: column; padding: 0 4px; }
.g-tt b { font-size: 16px; }
.g-play { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: 13px; color: var(--accent); padding: 0 4px 4px; }
.g-play svg.i { width: 14px; height: 14px; }
.sheet.game-sheet { width: auto; max-width: calc(100vw - 24px); }
.game-sheet .sheet-body { padding: 6px 12px 14px; }
.score-sheet .sheet-foot .sp { flex: 1; }
.sc-hero { width: 74px; height: 74px; margin: 0 auto 8px; border-radius: 24px; display: grid; place-items: center; background: var(--hover); color: var(--muted); }
.sc-hero.won { background: linear-gradient(135deg, #fcd34d, #f59e0b); color: #fff; box-shadow: 0 16px 34px -14px #f59e0b; animation: pop .7s var(--spring) both; }
.sc-hero svg.i { width: 36px; height: 36px; }
.sc-msg { text-align: center; font-size: 17px; font-weight: 700; margin: 4px 0; white-space: pre-wrap; }
.sc-you { text-align: center; color: var(--text-2); margin: 0 0 12px; }
.sc-entry { margin-bottom: 12px; }
.sc-rank { text-align: center; font-weight: 700; color: var(--ok-ink); display: flex; gap: 6px; justify-content: center; align-items: center; margin: 0 0 12px; }
.sc-board { border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.sc-bh { padding: 10px 14px; background: var(--hover); font-size: 13px; }
.sc-list { max-height: 260px; overflow: auto; }
.sc-list .sk { margin: 10px; }
.sc-row { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto 74px; gap: 8px; align-items: center; padding: 8px 14px; border-top: 1px solid var(--line); font-size: 13.5px; }
.sc-row b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-row .n { font-weight: 800; color: var(--muted); }
.sc-row .v { font-weight: 700; font-variant-numeric: tabular-nums; }
.sc-row small { text-align: right; }
.sc-row.me { background: var(--accent-soft); }
.sc-row.top1 .n { color: #f59e0b; } .sc-row.top2 .n { color: #94a3b8; } .sc-row.top3 .n { color: #c2410c; }

/* the games keep their own classic look inside the glass sheet */
.game-host { --face: #c0c0c0; --hi: #fff; --light: #dfdfdf; --shadow: #808080; --dark: #0a0a0a; --navy: #000080;
  --raised: inset -1px -1px var(--dark), inset 1px 1px var(--hi), inset -2px -2px var(--shadow), inset 2px 2px var(--light);
  --pressed: inset -1px -1px var(--hi), inset 1px 1px var(--dark), inset -2px -2px var(--light), inset 2px 2px var(--shadow);
  --sunken: inset -1px -1px var(--hi), inset 1px 1px var(--shadow), inset -2px -2px var(--light), inset 2px 2px var(--dark);
  display: flex; flex-direction: column; overflow: hidden; border-radius: 16px; background: #e7ebf2; color: #111; font: 13px/1.35 var(--font); max-width: 100%; }
.game-host .game-menu { display: flex; flex-wrap: wrap; gap: 4px; padding: 6px; flex: none; }
.game-host .game-menu button { border: 0; background: rgba(0, 0, 0, .06); border-radius: 9px; padding: 6px 11px; font: 600 12.5px var(--font); color: inherit; cursor: pointer; }
.game-host .game-menu button:hover { background: var(--accent); color: #fff; }
.game-host .game-menu u { text-decoration: none; }
.game-host .statusbar { display: flex; justify-content: space-between; gap: 8px; padding: 6px 12px; font-size: 12px; color: #555; flex: none; }
.game-host .sol { position: relative; flex: 1; min-height: 0; background: radial-gradient(circle at 50% 30%, #1f9d55, #0b6b35); overflow: hidden; touch-action: none; user-select: none; }
.game-host .sol .slot { position: absolute; border: 1px solid rgba(255, 255, 255, .35); border-radius: 6px; }
.game-host .sol .slot.f::after { content: ""; position: absolute; inset: 22%; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .35); }
.game-host .card { position: absolute; left: 0; top: 0; border-radius: 6px; transition: transform .16s var(--out); will-change: transform; cursor: default; }
.game-host .card.drag { transition: none; cursor: grabbing; }
.game-host .card .face, .game-host .card .back { position: absolute; inset: 0; border-radius: 6px; border: 1px solid rgba(0, 0, 0, .35); box-shadow: 0 2px 4px rgba(0, 0, 0, .25); }
.game-host .card .face { background: #fff; color: #111; font-weight: bold; display: none; }
.game-host .card.up .face { display: block; }
.game-host .card.up .back { display: none; }
.game-host .card .face.red { color: #d00000; }
.game-host .card .tl, .game-host .card .br { position: absolute; line-height: .95; text-align: center; font-family: Georgia, "Times New Roman", serif; }
.game-host .card .tl { left: 3px; top: 3px; } .game-host .card .br { right: 3px; bottom: 3px; transform: rotate(180deg); }
.game-host .card .mid { position: absolute; left: 50%; top: 52%; transform: translate(-50%, -50%); font-family: Georgia, serif; }
.game-host .card .back { background: #fff; padding: 3px; }
.game-host .card .back::before { content: ""; position: absolute; inset: 3px; border-radius: 4px; background: repeating-linear-gradient(45deg, #2563eb 0 3px, #3b82f6 3px 6px); box-shadow: inset 0 0 0 2px #fff; }
.game-host .card.shake { animation: g-shake .25s; }
@keyframes g-shake { 25% { margin-left: -4px; } 75% { margin-left: 4px; } }
.game-host .mines { padding: 10px; display: flex; flex-direction: column; gap: 8px; align-items: center; overflow: auto; flex: 1; min-height: 0; background: var(--face); }
.game-host .mines .top { display: flex; align-items: center; justify-content: space-between; padding: 4px 6px; box-shadow: inset 2px 2px var(--shadow), inset -2px -2px var(--hi); align-self: stretch; }
.game-host .lcd { background: #000; color: #f00; font: bold 22px/1 "Courier New", monospace; padding: 2px 3px; letter-spacing: 1px; min-width: 50px; text-align: right; box-shadow: inset 1px 1px var(--shadow), inset -1px -1px var(--hi); }
.game-host .face-btn { width: 30px; height: 30px; padding: 0; display: grid; place-items: center; background: var(--face); border: 0; box-shadow: var(--raised); cursor: pointer; }
.game-host .face-btn:active { box-shadow: var(--pressed); }
.game-host .mfield { display: grid; box-shadow: inset 3px 3px var(--shadow), inset -3px -3px var(--hi); padding: 3px; touch-action: manipulation; }
.game-host .mcell { width: var(--cs); height: var(--cs); border: 0; padding: 0; background: var(--face); box-shadow: inset -2px -2px var(--shadow), inset 2px 2px var(--hi); font: bold calc(var(--cs) * .62)/1 Tahoma, Verdana, sans-serif; display: grid; place-items: center; cursor: default; user-select: none; color: #000; }
.game-host .mcell.open { box-shadow: none; border-right: 1px solid var(--shadow); border-bottom: 1px solid var(--shadow); }
.game-host .mcell.boom { background: #f00; }
.game-host .mcell .n1 { color: #0000ff; } .game-host .mcell .n2 { color: #008000; } .game-host .mcell .n3 { color: #ff0000; } .game-host .mcell .n4 { color: #000080; }
.game-host .mcell .n5 { color: #800000; } .game-host .mcell .n6 { color: #008080; } .game-host .mcell .n7 { color: #000; } .game-host .mcell .n8 { color: #808080; }
.game-host .arcade { flex: 1; min-height: 0; background: #000; display: grid; place-items: center; position: relative; overflow: hidden; touch-action: none; }
.game-host .arcade canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; image-rendering: pixelated; display: block; }
.game-host .arcade .pad { position: absolute; bottom: 10px; display: flex; gap: 10px; }
.game-host .arcade .pad.l { left: 10px; } .game-host .arcade .pad.r { right: 10px; }
.game-host .arcade .pad button { width: 62px; height: 62px; font-size: 22px; border-radius: 18px; background: rgba(255, 255, 255, .22); color: #fff; border: 1px solid rgba(255, 255, 255, .3); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); touch-action: none; user-select: none; }
.game-host .arcade .pad button:active { background: rgba(255, 255, 255, .4); }
@media (hover: hover) and (pointer: fine) { .game-host .arcade .pad { display: none; } }

/* ------------------------------------------------------------ share link page */
.lk { height: 100vh; height: 100dvh; overflow: auto; display: flex; flex-direction: column; }
.lk-top { display: flex; align-items: center; padding: 16px 20px; }
.lk-brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-weight: 750; font-size: 16px; letter-spacing: -.01em; }
.lk-brand .mark { width: 32px; height: 32px; }
.lk-tag { margin-left: 2px; padding-left: 12px; border-left: 1px solid var(--line-2); color: var(--muted); font-weight: 500; font-size: 13.5px; letter-spacing: 0; white-space: nowrap; }
@media (max-width: 560px) { .lk-tag { display: none; } }
/* the admin's overview */
.ov-top { display: grid; grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.ov-top > .sk { height: 120px; border-radius: 22px; }
.ov-card { border-radius: 22px; padding: 18px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ov-card b { font-size: 26px; letter-spacing: -.02em; }
.ov-card small { font-size: 12.5px; }
.ov-ico { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); margin-bottom: 6px; }
.ov-ico svg.i { width: 18px; height: 18px; }
.ov-bar { display: block; height: 8px; border-radius: 99px; background: var(--hover); overflow: hidden; margin: 8px 0 4px; }
.ov-bar > i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #38bdf8, #6366f1); }
.ov-list { display: flex; flex-direction: column; gap: 6px; }
.ov-list > .sk { height: 62px; border-radius: 16px; }
.ov-head, .ov-row { display: grid; grid-template-columns: minmax(0, 2.2fr) repeat(5, minmax(0, 1fr)); gap: 12px; align-items: center; padding: 0 16px; }
.ov-head { font-size: 12px; font-weight: 600; color: var(--muted); padding-bottom: 4px; }
.ov-row { min-height: 62px; border-radius: 16px; border: 1px solid var(--line); background: var(--card); color: var(--text); font: inherit; text-align: left; cursor: pointer; transition: background .15s, box-shadow .15s; }
.ov-row:hover { background: var(--card-h); box-shadow: var(--shadow-2); }
.ov-who { display: flex; align-items: center; gap: 10px; min-width: 0; }
.ov-nm { display: flex; flex-direction: column; min-width: 0; }
.ov-who b, .ov-who small, .ov-c b, .ov-c small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ov-who small { font-size: 12px; }
.ov-c { display: flex; flex-direction: column; min-width: 0; font-size: 13.5px; }
.ov-c small { font-size: 11.5px; }
.ov-sec { font-size: 15px; margin: 18px 4px 10px; letter-spacing: -.01em; }
.ov-usage { display: flex; flex-direction: column; gap: 6px; margin-bottom: 8px; }
.ov-urow { cursor: default; }
/* sections fold by their heading */
.ov-sec.fold { display: flex; align-items: center; gap: 6px; cursor: pointer; user-select: none; -webkit-user-select: none; width: fit-content; border-radius: 8px; }
.ov-sec.fold:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.fold-ico { width: 16px; height: 16px; color: var(--muted); transition: transform .2s var(--out); }
.folded .fold-ico { transform: rotate(-90deg); }
.fold-n { font-size: 12.5px; font-weight: 600; margin-left: 2px; }
.folded > :not(.ov-sec):not(.ov-keep) { display: none !important; }
.ov-pub:not(.all) .ov-more { display: none; }
.ov-places { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 0 2px 10px; font-size: 12.5px; }
.ov-places .chip { height: 26px; font-size: 12px; }
.ov-all { align-self: center; margin-top: 6px; }
/* the site's use: filters, measures, the chart */
.ov-filters { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.ov-note { font-size: 12px; }
.ov-mets { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; margin-bottom: 10px; }
.ov-met { display: flex; flex-direction: column; gap: 2px; padding: 12px 12px 10px; border-radius: 16px; border: 1px solid var(--line); background: var(--card); color: var(--text); font: inherit; text-align: left; cursor: pointer; min-width: 0; transition: background .15s, box-shadow .15s; }
.ov-met:hover { background: var(--card-h); }
.ov-met.on { box-shadow: inset 0 0 0 2px var(--accent); background: var(--accent-soft); }
.ov-met span { font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ov-met b { font-size: 22px; letter-spacing: -.02em; }
.ov-met small { font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ov-chart { border-radius: 22px; padding: 16px 16px 8px; position: relative; }
.ov-ch-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 4px; flex-wrap: wrap; }
.ov-ch-head b { font-size: 14px; }
.ov-ch-head small { font-size: 12px; }
.ov-plot { position: relative; width: 100%; overflow: hidden; }
.lc { display: block; max-width: 100%; height: auto; }
.lc .g { stroke: var(--line); stroke-width: 1; }
.lc .yl { fill: var(--muted); font: 500 11px var(--font); text-anchor: end; }
.lc .xl { fill: var(--muted); font: 500 11px var(--font); text-anchor: middle; }
.lc .ln { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.lc .cx { stroke: var(--line-2); stroke-width: 1; stroke-dasharray: 3 3; }
.lc .dot { fill: var(--accent); stroke: var(--card); stroke-width: 2; }
.lc .hit { fill: transparent; cursor: crosshair; }
.ov-tip { position: absolute; transform: translateX(-50%); pointer-events: none; display: flex; flex-direction: column; padding: 6px 10px; border-radius: 10px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow-2); font-size: 12.5px; white-space: nowrap; z-index: 2; }
.ov-tip small { font-size: 11px; }
@media (max-width: 1100px) { .ov-mets { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 560px) { .ov-mets { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.ov-pubtop { margin-bottom: 10px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.ov-prow:disabled { cursor: default; opacity: .62; }
.ov-prow:disabled:hover { box-shadow: none; background: var(--card); }
.ov-urow:hover { box-shadow: none; background: var(--card); }
.ov-bar.sm { height: 5px; margin: 5px 0 3px; max-width: 160px; }
/* The storage card: a ring around the limit, the elephant faint behind it. */
.ov-card.ov-space { --rg-a: #0284c7; --rg-b: #4f46e5; --rg-c: #7c3aed; position: relative; overflow: hidden; isolation: isolate; flex-direction: row; align-items: center; gap: 26px; padding: 20px 24px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .ov-card.ov-space { --rg-a: #7dd3fc; --rg-b: #818cf8; --rg-c: #c4b5fd; } }
:root[data-theme="dark"] .ov-card.ov-space { --rg-a: #7dd3fc; --rg-b: #818cf8; --rg-c: #c4b5fd; }
.ov-wm { position: absolute; right: -38px; bottom: -46px; width: 172px; opacity: .07; pointer-events: none; z-index: -1; }
.ov-wm img { display: block; width: 100%; height: auto; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .ov-wm { opacity: .075; } :root:not([data-theme="light"]) .ov-wm img { filter: grayscale(1) brightness(2.2); } }
:root[data-theme="dark"] .ov-wm { opacity: .075; }
:root[data-theme="dark"] .ov-wm img { filter: grayscale(1) brightness(2.2); }
.ov-ring { position: relative; width: 148px; height: 148px; flex: none; }
.ov-ring svg { display: block; width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.ov-ring circle { fill: none; stroke-width: 8; }
.ov-ring .trk { stroke: var(--hover); }
.ov-ring .arc { stroke: url(#ov-rg); stroke-linecap: round; filter: drop-shadow(0 0 4px rgba(99, 102, 241, .75)); transition: stroke-dasharray 1.4s var(--out); }
.ov-ring-in { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.ov-ring-in > span { font-size: 12px; margin-top: 5px; }
.ov-card .ov-cap { font-size: 38px; font-weight: 800; letter-spacing: -.045em; line-height: 1; background: linear-gradient(120deg, var(--rg-a), var(--rg-b) 55%, var(--rg-c)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ov-card .ov-cap small { font-size: .5em; letter-spacing: 0; margin-left: 3px; }
.ov-rl { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.ov-rl li { display: flex; flex-direction: column; min-width: 0; }
.ov-rl span { font-size: 12px; }
.ov-card .ov-rl b { font-size: 19px; letter-spacing: -.01em; font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 560px) { .ov-card.ov-space { gap: 18px; padding: 18px; } .ov-ring { width: 124px; height: 124px; } .ov-card .ov-cap { font-size: 31px; } .ov-card .ov-rl b { font-size: 17px; } }
@media (prefers-reduced-motion: reduce) { .ov-ring .arc { transition: none; } }
/* Near or at an admin's storage limit. */
.ov-space.warn .arc { stroke: #f59e0b; filter: drop-shadow(0 0 4px rgba(245, 158, 11, .7)); }
.ov-space.full .arc { stroke: #ef4444; filter: drop-shadow(0 0 4px rgba(239, 68, 68, .7)); }
.ov-space.warn .p { color: #d97706; } .ov-space.full .p { color: #ef4444; }
.ov-qmsg b { font-size: 13px !important; color: #d97706; } .ov-space.full .ov-qmsg b { color: #ef4444; }
.ov-bar.warn > i { background: #f59e0b; } .ov-bar.full > i { background: #ef4444; }
/* The storage limit field of an admin. */
.quota-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.quota-inp { position: relative; display: inline-flex; align-items: center; }
.quota-inp .inp { width: 108px; padding-right: 40px; font-variant-numeric: tabular-nums; }
.quota-inp span { position: absolute; right: 12px; color: var(--muted); font-weight: 600; font-size: 13px; pointer-events: none; }
.quota-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.q-chip { height: 30px; padding: 0 11px; border-radius: 99px; border: 1px solid var(--line-2); background: var(--card); color: var(--text-2); font: 600 12.5px var(--font); cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.q-chip:hover { background: var(--hover); }
.q-chip.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.dlb { display: inline-flex; align-items: center; gap: 3px; margin-left: 6px; color: var(--muted); font-size: 12px; font-weight: 600; flex: none; }
.dlb svg.i { width: 13px; height: 13px; }
@media (max-width: 900px) {
  .ov-top { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ov-space { grid-column: 1 / -1; }
  .ov-head { display: none; }
  .ov-row { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 14px; row-gap: 10px; }
  .ov-who { grid-column: 1 / -1; }
  .ov-c::before { content: attr(data-label); font-size: 11px; color: var(--muted); font-weight: 600; }
}
.lk-top .tswitch { margin: 0; }
.lk-main { flex: 1; display: grid; place-items: start center; padding: 3vh 16px 30px; }
.lk-card { width: min(720px, 100%); border-radius: 30px; padding: 28px; animation: sheet-in .65s var(--spring) both; }
.lk-card.reveal { animation: flip-in .7s var(--spring) both; transform-origin: 50% 0; }
@keyframes flip-in { from { opacity: 0; transform: perspective(1000px) rotateX(-14deg) translateY(14px); } }
.lk-head { display: flex; gap: 22px; align-items: center; }
.lk-stack { flex: none; }
.lk-tt { min-width: 0; flex: 1; }
.lk-tt h1 { margin: 0; font-size: 27px; letter-spacing: -.025em; line-height: 1.2; word-break: break-word; }
.lk-msg { margin: 8px 0 0; color: var(--text-2); white-space: pre-wrap; line-height: 1.55; }
.lk-meta { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.stack3 { position: relative; display: inline-block; }
.stack3 i { position: absolute; inset: 0; border-radius: 26px; background: var(--card-h); border: 1px solid var(--line); box-shadow: var(--shadow-1); }
.stack3 i:nth-child(1) { transform: rotate(-9deg) translate(-7px, 4px); }
.stack3 i:nth-child(2) { transform: rotate(7deg) translate(7px, 2px); }
.stack3 .tile { position: relative; }
.lk-cta { margin: 24px 0 16px; }
.dlbtn { position: relative; width: 100%; display: flex; align-items: center; gap: 14px; padding: 14px 18px; border: 0; border-radius: 20px; background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #fff; cursor: pointer; overflow: hidden; text-align: left; font: inherit; box-shadow: 0 18px 38px -16px var(--accent); isolation: isolate; transition: transform .16s var(--out), filter .2s, background .3s; }
.dlbtn:hover { filter: brightness(1.06); }
.dlbtn:active { transform: scale(.985); }
.dl-fill { position: absolute; inset: 0 auto 0 0; width: var(--p, 0%); background: rgba(255, 255, 255, .2); z-index: -1; transition: width .5s var(--out); }
.dlbtn .dl-ico { width: 46px; height: 46px; border-radius: 15px; background: rgba(255, 255, 255, .2); display: grid; place-items: center; flex: none; }
.dlbtn .dl-ico svg.i { width: 24px; height: 24px; stroke-width: 2.2; }
.dl-txt { display: flex; flex-direction: column; min-width: 0; }
.dl-txt b { font-size: 17px; }
.dl-txt small { opacity: .88; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dlbtn.busy .dl-ico svg.i { animation: bob 1s ease-in-out infinite; }
.dlbtn.ok { background: linear-gradient(135deg, #16a34a, #22c55e); box-shadow: 0 18px 38px -16px #22c55e; }
.dlbtn.ok .dl-ico svg.i { stroke-dasharray: 30; animation: draw .45s var(--out) both; }
.lk-files { display: flex; flex-direction: column; border-top: 1px solid var(--line); padding-top: 8px; }
.lk-row { display: flex; align-items: center; gap: 10px; padding: 7px 6px 7px calc(8px + var(--depth, 0) * 22px); border-radius: 12px; }
.lk-row:hover { background: var(--hover); }
.lk-th { width: 36px; height: 36px; border-radius: 10px; object-fit: cover; flex: none; }
.lk-n { flex: 1; min-width: 0; border: 0; background: none; text-align: left; font: 500 14px var(--font); color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0; cursor: pointer; }
.lk-n:disabled { cursor: default; color: var(--text); }
.lk-n:not(:disabled):hover { color: var(--accent); }
.lk-s { font-size: 12.5px; white-space: nowrap; }
.lk-dir summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 7px 6px 7px calc(8px + var(--depth, 0) * 22px); border-radius: 12px; cursor: pointer; user-select: none; }
.lk-dir summary::-webkit-details-marker { display: none; }
.lk-dir summary:hover { background: var(--hover); }
.lk-dir summary b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.lk-dir .chev { width: 16px; height: 16px; color: var(--muted); transition: transform .3s var(--out); }
.lk-dir[open] > summary .chev { transform: rotate(90deg); }
.lk-dir[open] > .lk-dir-body { animation: rise .35s var(--out); }
.lk-foot { text-align: center; padding: 18px; font-size: 13px; }
.lk-foot a { color: var(--accent); font-weight: 600; text-decoration: none; }
.foot-safe { display: inline-flex; align-items: center; gap: 6px; margin-right: 10px; color: var(--accent); font-weight: 600; }
.foot-safe svg.i { width: 15px; height: 15px; }
.foot-co { display: block; margin-top: 6px; font-size: 12px; opacity: .8; }
.lk-foot .foot-co a { font-weight: 500; }
/* share link: a short card first (preview, expiry, safety, Open / Download), and what the site is for beside it */
.lk-main.split { grid-template-columns: minmax(0, 400px) minmax(0, 560px); justify-content: center; justify-items: stretch; align-items: start; column-gap: 28px; row-gap: 18px; }
.lk-card.lk-ready { width: 100%; display: grid; justify-items: center; text-align: center; gap: 8px; padding: 20px 20px 22px; }
.lr-prev { position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); background: var(--hover); display: grid; place-items: center; cursor: pointer; padding: 0; }
.lr-prev img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lr-art { display: grid; place-items: center; }
.lr-chip { position: absolute; display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 12px; background: rgba(255, 255, 255, .94); color: #0b1220; font: 600 14px var(--font); box-shadow: 0 6px 20px rgba(0, 0, 0, .18); transition: transform .25s var(--spring); }
.lr-chip svg.i { width: 17px; height: 17px; }
.lr-prev:hover .lr-chip, .lr-prev:focus-visible .lr-chip { transform: scale(1.06); }
.lk-ready h2 { margin: 12px 0 0; font-size: 22px; letter-spacing: -.02em; }
.lr-name { margin: 0; font-weight: 600; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lk-ready .lk-meta { justify-content: center; }
.lr-exp { margin: 0; font-size: 13px; }
.lr-safe { display: flex; gap: 10px; align-items: center; text-align: left; width: 100%; padding: 10px 12px; margin-top: 6px; border-radius: 14px; background: var(--accent-soft); color: var(--accent); }
.lr-safe > svg.i { width: 22px; height: 22px; flex: none; }
.lr-safe div { display: flex; flex-direction: column; gap: 1px; }
.lr-safe b { font-size: 13px; } .lr-safe small { font-size: 12px; opacity: .85; }
.lr-warn { display: flex; gap: 8px; align-items: center; text-align: left; width: 100%; padding: 9px 12px; border-radius: 14px; background: rgba(245, 158, 11, .14); color: #b45309; font-size: 12.5px; font-weight: 600; }
:root[data-theme="dark"] .lr-warn { color: #fbbf24; }
.lr-warn svg.i { width: 18px; height: 18px; flex: none; }
.lr-acts { display: grid; gap: 8px; width: 100%; margin-top: 8px; }
.lr-acts .btn { width: 100%; height: 46px; font-size: 15px; border-radius: 14px; }
.lr-acts .btn.ghost { border-color: var(--line-2); }
.lk-promo { position: relative; overflow: hidden; min-height: 440px; border-radius: 30px; padding: 30px; display: flex; flex-direction: column; justify-content: flex-end; color: #fff;
  background: radial-gradient(120% 80% at 100% 0%, rgba(255, 255, 255, .22), transparent 55%), linear-gradient(145deg, #0ea5e9, #6366f1 55%, #a855f7); box-shadow: var(--shadow-2); animation: sheet-in .7s .08s var(--spring) both; }
.lp-big { position: absolute; top: 24px; left: 28px; font: 800 clamp(64px, 8vw, 116px)/.9 var(--font); letter-spacing: -.05em; text-shadow: 0 10px 40px rgba(30, 27, 75, .25); }
.lp-tiles { position: absolute; right: 26px; top: 46%; display: flex; gap: 12px; transform: translateY(-50%) rotate(-8deg); }
.lp-tiles > * { box-shadow: 0 14px 34px rgba(30, 27, 75, .35); border-radius: 18px; }
.lp-tiles > :nth-child(2) { transform: translateY(-22px) rotate(6deg); }
.lp-tiles > :nth-child(3) { transform: translateY(10px) rotate(-4deg); }
.lp-txt { position: relative; }
.lp-txt h2 { margin: 0 0 6px; font-size: 26px; letter-spacing: -.02em; }
.lp-txt p { margin: 0 0 16px; color: rgba(255, 255, 255, .88); }
.lp-go { background: #fff; color: #312e81; height: 44px; padding: 0 18px; border-radius: 14px; }
.lp-go:hover { filter: brightness(.96); }
.safe-card b { display: inline-flex; align-items: center; gap: 6px; }
.safe-card b svg.i { width: 17px; height: 17px; color: var(--accent); }
.safe-card p { margin: 6px 0 0; font-size: 13px; }
.safe-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; font-size: 13.5px; color: var(--text-2); }
.safe-list b { color: var(--text); }
@media (max-width: 899px) {
  .lk-main.split { grid-template-columns: minmax(0, 1fr); }
  .lk-promo { min-height: 0; padding: 22px; justify-content: flex-start; }
  .lp-big { position: static; font-size: 56px; margin: 4px 0 22px; }
  .lp-tiles { top: 22px; right: 14px; transform: rotate(-8deg) scale(.5); transform-origin: top right; }
}
.lk-card.gate { width: min(440px, 100%); text-align: center; display: grid; justify-items: center; gap: 6px; padding: 34px 28px; }
.gate-ico { width: 78px; height: 78px; border-radius: 26px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; margin-bottom: 8px; transition: background .3s, color .3s; }
.gate-ico svg.i { width: 34px; height: 34px; }
.gate h2 { margin: 2px 0 0; font-size: 22px; letter-spacing: -.02em; }
.gate p { margin: 0; }
.gate-form { width: 100%; margin-top: 14px; }
.gate.unlocked .gate-ico { background: var(--ok); color: #fff; animation: unlock .42s var(--spring) both; }
.gate.unlocked { animation: gate-out .42s var(--inout) forwards; }
@keyframes unlock { 50% { transform: scale(1.12) rotate(-8deg); } }
@keyframes gate-out { to { opacity: 0; transform: perspective(1000px) rotateX(10deg) translateY(-6px); } }

/* ------------------------------------------------------------ language button */
.langbtn { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--line); background: var(--hover); color: var(--text-2); font: 600 13px var(--font); cursor: pointer; transition: background .15s, color .15s; flex: none; }
.langbtn:hover { background: var(--press); color: var(--text); }
.langbtn svg.i { width: 17px; height: 17px; }
.lk-top .langbtn { margin-right: 8px; }
.side-lang { margin: 2px 6px 4px; justify-content: flex-start; }
.rail .side-lang { width: 44px; padding: 0; justify-content: center; margin: 2px auto 4px; }
.rail .side-lang .lbl { display: none; }
@media (max-width: 900px) { .rail .side-lang { width: auto; padding: 0 12px; justify-content: flex-start; margin: 2px 6px 4px; } .rail .side-lang .lbl { display: inline; } }

/* ------------------------------------------------------------ front page */
.home .lk-main { padding-top: 2vh; }
.home-card { width: min(600px, 100%); display: flex; flex-direction: column; gap: 18px; transition: box-shadow .25s; }
.home-card.over { box-shadow: 0 0 0 3px var(--accent), var(--shadow-3); }
.home-tabs { display: flex; justify-content: center; }
.home-send { display: flex; flex-direction: column; gap: 14px; }
.home-lim { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.home-lim svg.i { width: 17px; height: 17px; }
.staged .bar.cap { height: 4px; margin: 0 12px 12px; }
.home-login { display: grid; justify-items: center; text-align: center; gap: 6px; padding: 10px 0 4px; }
.home-login h2 { margin: 2px 0 0; font-size: 22px; letter-spacing: -.02em; }
.home-login p { margin: 0; }
.home-login .user-inp { width: 100%; max-width: 420px; margin-top: 12px; }
.home-login .pw-row { width: 100%; max-width: 420px; margin-top: 4px; }
.home-login .small { margin-top: 10px; }
.home-login a { color: var(--accent); font-weight: 600; text-decoration: none; }
.gate-ico.ok { background: var(--ok); color: #fff; animation: unlock .42s var(--spring) both; }
.home-sending { display: grid; justify-items: center; text-align: center; gap: 8px; padding: 18px 0 6px; }
.home-sending .send-foot { justify-content: center; margin-top: 8px; }
.ld-kind { display: flex; justify-content: center; margin-top: 10px; }
.center-foot { justify-content: center; margin-top: 12px; }
@media (max-width: 760px) { .home-card { padding: 18px 14px; } .home-tabs .pill-b { padding: 0 10px; } }

/* ------------------------------------------------------------ first-visit tour */
.tour { position: fixed; inset: 0; z-index: 160; animation: fade .3s ease both; }
.tour.out { animation: fade-out .25s ease forwards; }
.tour-hole { position: fixed; border-radius: 14px; box-shadow: 0 0 0 200vmax rgba(5, 8, 16, .58); pointer-events: none; transition: left .5s var(--spring), top .5s var(--spring), width .5s var(--spring), height .5s var(--spring), border-radius .3s; }
.tour-hole::after { content: ""; position: absolute; inset: -4px; border-radius: inherit; border: 2px solid var(--accent); animation: tour-pulse 1.6s ease-out infinite; }
.tour-hole.none::after { display: none; }
@keyframes tour-pulse { 0% { opacity: .9; transform: scale(1); } 100% { opacity: 0; transform: scale(1.12); } }
.tour-card { position: fixed; border-radius: 20px; padding: 16px 16px 14px; background: var(--glass-2); transition: left .5s var(--spring), top .5s var(--spring); animation: sheet-in .45s var(--spring) both; }
.tour-card.swap h3, .tour-card.swap p { animation: rise .35s var(--out) both; }
.tour-card::before { content: ""; position: absolute; left: calc(var(--ax, 50%) - 8px); width: 16px; height: 16px; background: inherit; border: inherit; transform: rotate(45deg); }
.tour-card[data-side="below"]::before { top: -9px; border-right: 0; border-bottom: 0; }
.tour-card[data-side="above"]::before { bottom: -9px; border-left: 0; border-top: 0; }
.tour-card[data-side="center"]::before { display: none; }
.tour-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 4px; }
.tour-n { font-size: 12px; font-weight: 700; }
.tour-skip { border: 0; background: none; color: var(--muted); font: 600 13px var(--font); cursor: pointer; padding: 4px 6px; border-radius: 8px; }
.tour-skip:hover { background: var(--hover); color: var(--text); }
.tour-card h3 { margin: 2px 0 6px; font-size: 17px; letter-spacing: -.01em; }
.tour-card p { margin: 0; color: var(--text-2); line-height: 1.5; font-size: 14px; }
.tour-dots { display: flex; gap: 5px; margin: 14px 0 12px; }
.tour-dots i { width: 6px; height: 6px; border-radius: 99px; background: var(--line-2); transition: width .35s var(--spring), background .25s; }
.tour-dots i.on { width: 18px; background: var(--accent); }
.tour-btns { display: flex; justify-content: flex-end; gap: 8px; }
.help-tour { align-self: flex-start; }

/* ------------------------------------------------------------ shared motion */
.rise { animation: rise .55s var(--out) both; animation-delay: calc(min(var(--d, 0), 18) * 26ms); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes pop { from { opacity: 0; transform: scale(.5); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes bob { 50% { transform: translateY(3px); } }
@keyframes float { 50% { transform: translateY(-5px); } }
@keyframes pulse { 50% { opacity: .35; } }

/* ------------------------------------------------------------ small screens */
@media (max-width: 900px) {
  .side { position: fixed; z-index: 120; left: 0; top: 0; bottom: 0; margin: 8px; width: min(300px, 84vw) !important; transform: translateX(calc(-100% - 16px)); transition: transform .45s var(--spring); }
  .side.glass { background: var(--glass-2); }
  .drawer .side { transform: none; }
  .side-scrim { display: block; position: fixed; inset: 0; z-index: 110; background: rgba(8, 12, 24, .35); opacity: 0; pointer-events: none; transition: opacity .3s; }
  .drawer .side-scrim { opacity: 1; pointer-events: auto; }
  .rail .side .lbl { opacity: 1; transform: none; pointer-events: auto; }
  .rail .side-head { flex-direction: row; }
  .rail .nav-sec { margin: 18px 12px 6px; border: 0; height: 12px; }
  .rail .tswitch { width: 64px; padding: 0 8px; justify-content: space-between; margin: 2px 6px 6px; }
  .rail .tswitch .ts-k { opacity: 1; }
  .rail .tswitch .ts-moon, .rail .tswitch .ts-sun { display: block; }
  .rail .nbadge { position: static; }
  .fold { display: none; }
  .rail .nav-tree { display: grid; }
  .rail .nav-chev { display: grid; }
  .mburger { display: inline-grid; }
  .send-grid { grid-template-columns: 1fr; }
  .who-row { grid-template-columns: 1fr; gap: 4px; }
}
@media (max-width: 760px) {
  .page { padding: 14px 14px 120px; }
  .page-head { margin-bottom: 16px; gap: 10px; }
  .page-head h1 { font-size: 23px; }
  .ph-acts .btn span { display: none; }
  .ph-acts .btn { padding: 0 11px; }
  .ws-head { padding: 12px 14px 8px; flex-wrap: wrap; gap: 10px; }
  .ws-id { gap: 10px; }
  .ws-tt h1 { font-size: 20px; }
  .ws-ava.lg { --s: 38px; }
  .ws-acts { width: 100%; }
  .search { flex: 1; width: auto; }
  .search:focus-within { width: auto; }
  .search kbd { display: none; }
  .ws-acts .btn span { display: none; }
  .ws-acts .btn { padding: 0 11px; }
  .ws-tabs { padding: 0 14px; }
  .ws-bar { padding: 10px 14px 6px; }
  .ws-body { padding: 4px 12px 140px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
  .fcard { padding: 5px; }
  .lhead, .lrow { grid-template-columns: 22px minmax(0, 1fr) 72px; }
  .lhead > :nth-child(n+4), .lrow > div:nth-child(n+4) { display: none; }
  .b-sort span { display: none; }
  .ws-count { display: none; }
  .selbar { bottom: 12px; padding-left: 12px; }
  .sel-acts button span { display: none; }
  .sel-n { font-size: 12.5px; }
  .tray { right: 12px; left: 12px; bottom: 12px; width: auto; }
  .lb-main { flex-direction: column; }
  .lb-side { width: auto !important; height: 0; margin: 0 8px 8px; transition: height .45s var(--spring), opacity .25s; }
  .lb.side-open .lb-side { height: 50dvh; }
  .lb-side > * { min-width: 0; }
  .lb-nav { display: none; }
  .lb-pane { padding: 8px; }
  .lk-card { padding: 20px 18px; border-radius: 26px; }
  .lk-head { flex-direction: column; text-align: center; gap: 16px; }
  .lk-meta { justify-content: center; }
  .lk-tt h1 { font-size: 22px; }
  .send-card { padding: 16px; border-radius: 24px; }
  .drop { padding: 30px 14px; }
  .drop.mini { grid-template-columns: auto 1fr; }
  .drop.mini .drop-btns { grid-column: 1 / -1; }
  .sendbtn { width: 100%; }
  .send-foot { justify-content: stretch; }
  .lnk { flex-wrap: wrap; }
  .lnk-meta { width: 100%; justify-content: flex-start; order: 3; padding-left: 40px; }
  .act-l3 .bar { width: 90px; }
  .g-stats { grid-template-columns: 1fr; }
  .g-row { grid-template-columns: 28px minmax(0, 1fr) 70px; }
  .g-row > span:nth-child(n+4) { display: none; }
  .scrim { place-items: end center; padding: 0; }
  .sheet { width: 100% !important; max-width: 100% !important; border-radius: 26px 26px 0 0; max-height: 92dvh; animation-name: sheet-up; padding-bottom: env(safe-area-inset-bottom); }
  .scrim.out .sheet { animation: sheet-down .22s ease forwards; }
  @keyframes sheet-up { from { transform: translateY(100%); } }
  @keyframes sheet-down { to { transform: translateY(100%); } }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; animation-delay: 0s !important; transition-duration: .01ms !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
  .bg i { animation: none; }
}
