/* Metre2 Compress PDF 1.0 - "the press" (2026-10-29).
   Accent: violet #b46cff -> pink #ff6fae, chosen to sit well away from the portfolio's existing
   accents (PDF Flatten lime, the shell's teal, the many blues). Icon rail + file shelf + control
   deck with a size gauge - a different shape from PDF Flatten's three-column light table. */
@font-face { font-family: 'InterCP'; src: url('fonts/inter-var.woff2') format('woff2'); font-weight: 100 900; font-display: swap; }
:root {
  --accent: #b46cff; --accent-2: #ff6fae; --accent-ink: #1a0630; --accent-soft: rgba(180, 108, 255, .16);
  --good: #4ade9a; --good-soft: rgba(74, 222, 154, .14);
  --warn: #ffb547; --warn-soft: rgba(255, 181, 71, .14);
  --bad: #ff6b7a; --bad-soft: rgba(255, 107, 122, .14);
  --bg: #0f0a1f; --glass: rgba(28, 20, 52, .62); --glass-2: rgba(38, 28, 70, .78);
  --line: rgba(201, 170, 255, .13); --line-2: rgba(201, 170, 255, .24);
  --text: #f1ecff; --muted: #a99cc8; --dim: #7a6d9a;
  --radius: 14px;
  font-family: 'InterCP', 'Segoe UI Variable Text', 'Segoe UI', system-ui, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; color: var(--text); font-size: 13.5px; overflow: hidden; background: #0c0818; }
body::before, body::after { content: ''; position: fixed; inset: -20%; z-index: -1; pointer-events: none; }
body::before { background:
  radial-gradient(38% 34% at 22% 28%, rgba(180, 108, 255, .22), transparent 70%),
  radial-gradient(32% 30% at 78% 70%, rgba(255, 111, 174, .16), transparent 70%),
  radial-gradient(40% 40% at 60% 18%, rgba(90, 120, 255, .12), transparent 70%);
  animation: drift 38s ease-in-out infinite alternate; }
body::after { background: linear-gradient(180deg, rgba(12, 8, 24, .2), rgba(12, 8, 24, .75)); }
@keyframes drift { from { transform: translate3d(-3%, -2%, 0) scale(1); } to { transform: translate3d(3%, 2%, 0) scale(1.08); } }
@media (prefers-reduced-motion: reduce) { body::before { animation: none; } }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
[hidden] { display: none !important; }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.muted { color: var(--muted); line-height: 1.55; }
.label { font-size: 10.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--dim); margin: 18px 0 8px; display: flex; align-items: center; gap: 8px; }
.hint { color: var(--muted); font-size: 12px; margin: 8px 2px 0; line-height: 1.5; min-height: 18px; }
.pro-tag { display: inline-flex; align-items: center; font-size: 9px; font-weight: 800; letter-spacing: .08em; padding: 2px 5px; border-radius: 4px; background: linear-gradient(135deg, #ffd66b, #ffb547); color: #2a1700; vertical-align: 1px; text-transform: none; }
html[data-ks-pro="1"] .pro-tag { background: rgba(255, 201, 77, .16); color: #ffd36b; }

/* ---- layout -------------------------------------------------------------------------------- */
#app { position: fixed; inset: 0; display: grid; grid-template-columns: 76px minmax(0, 1fr); grid-template-rows: 64px minmax(0, 1fr); }
.rail { grid-row: 1 / -1; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 0; background: rgba(10, 6, 22, .6); border-right: 1px solid var(--line); backdrop-filter: blur(16px); }
.rail-brand { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; margin-bottom: 10px; color: #fff; background: linear-gradient(135deg, var(--accent-2), var(--accent) 60%, #6a3df0); box-shadow: 0 8px 24px rgba(180, 108, 255, .45); }
.rail-brand svg { width: 22px; height: 22px; }
.rail-btn { width: 62px; padding: 9px 0 7px; border: 0; border-radius: 12px; background: transparent; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 10.5px; font-weight: 600; }
.rail-btn:hover { color: var(--text); background: rgba(255, 255, 255, .05); }
.rail-btn.on { color: #fff; background: linear-gradient(135deg, rgba(255, 111, 174, .22), rgba(180, 108, 255, .28)); box-shadow: inset 0 0 0 1px rgba(201, 170, 255, .28); }
.rail-btn svg { width: 21px; height: 21px; }
.rail-gap { flex: 1; }
.topbar { display: flex; align-items: center; gap: 14px; padding: 0 20px; border-bottom: 1px solid var(--line); background: rgba(12, 8, 26, .45); backdrop-filter: blur(14px); min-width: 0; }
.title-block { display: flex; align-items: baseline; gap: 14px; min-width: 0; }
.title-block h1 { font-size: 19px; margin: 0; font-weight: 750; letter-spacing: -.01em; white-space: nowrap; }
.summary { display: flex; gap: 8px; align-items: center; min-width: 0; overflow: hidden; }
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.topbar { grid-column: 2; grid-row: 1; }
.view, .welcome { grid-column: 2; grid-row: 2; min-height: 0; min-width: 0; }
#app.empty .view, #app.empty #clear-all { display: none !important; }
#app:not(.empty) .welcome { display: none; }

/* ---- buttons, chips ----------------------------------------------------------------------- */
.cp-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 36px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--line-2); background: rgba(255, 255, 255, .04); font-weight: 600; font-size: 13px; white-space: nowrap; }
.cp-btn:hover { background: rgba(255, 255, 255, .08); }
.cp-btn.sm { height: 28px; padding: 0 10px; font-size: 12px; }
.cp-btn svg { width: 16px; height: 16px; }
.cp-btn.main { color: #fff; border: 0; background: linear-gradient(135deg, var(--accent-2), var(--accent) 55%, #7a45f5); box-shadow: 0 10px 30px rgba(180, 108, 255, .38), inset 0 1px 0 rgba(255, 255, 255, .35); }
.cp-btn.main:hover { filter: brightness(1.08); }
.cp-btn.main:disabled { filter: grayscale(.7) brightness(.6); box-shadow: none; cursor: default; }
.cp-btn.big { width: 100%; height: 52px; border-radius: 14px; font-size: 15.5px; }
.cp-icon { width: 34px; height: 34px; display: inline-grid; place-items: center; border-radius: 10px; border: 1px solid var(--line); background: transparent; color: var(--muted); padding: 0; }
.cp-icon:hover { color: var(--text); border-color: var(--line-2); }
.cp-icon.sm { width: 28px; height: 28px; }
.cp-icon:disabled { opacity: .35; cursor: default; }
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 600; padding: 3px 9px; border-radius: 999px; white-space: nowrap; background: rgba(255, 255, 255, .07); color: var(--muted); }
.chip.good { background: var(--good-soft); color: #9ff0c6; }
.chip.warn { background: var(--warn-soft); color: #ffd28c; }
.chip.bad { background: var(--bad-soft); color: #ffb0b8; }
.chip.acc { background: var(--accent-soft); color: #dcc3ff; }
.linkish { background: none; border: 0; color: #dcc3ff; padding: 0; text-decoration: underline; text-underline-offset: 2px; }

/* ---- welcome ------------------------------------------------------------------------------- */
.welcome { display: grid; place-items: center; padding: 24px; overflow: auto; }
.welcome-card { max-width: 640px; text-align: center; padding: 34px 38px; border-radius: 26px; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(18px); box-shadow: 0 30px 80px rgba(0, 0, 0, .35); }
.welcome h2 { font-size: 26px; margin: 18px 0 8px; letter-spacing: -.015em; }
.lede { color: var(--muted); font-size: 15px; line-height: 1.6; margin: 0 auto 22px; max-width: 520px; }
.welcome-actions { display: flex; gap: 10px; justify-content: center; margin-bottom: 22px; }
.points { list-style: none; padding: 0; margin: 0; text-align: left; display: grid; gap: 10px; }
.points li { padding: 11px 14px; border-radius: 12px; background: rgba(255, 255, 255, .035); border: 1px solid var(--line); color: var(--muted); line-height: 1.5; }
.points b { color: var(--text); }
.press-art { position: relative; width: 150px; height: 120px; margin: 0 auto; }
.press-art .plate { position: absolute; left: 10px; right: 10px; height: 12px; border-radius: 6px; background: linear-gradient(90deg, var(--accent-2), var(--accent)); box-shadow: 0 6px 24px rgba(180, 108, 255, .5); }
.press-art .plate.top { top: 4px; animation: press 3.2s ease-in-out infinite; }
.press-art .plate.bottom { bottom: 4px; }
.press-art .sheet { position: absolute; left: 32px; right: 32px; height: 54px; bottom: 18px; border-radius: 4px; background: #f5f1ff; box-shadow: 0 2px 0 rgba(0, 0, 0, .15); transform-origin: bottom; animation: squash 3.2s ease-in-out infinite; }
.press-art .sheet.s2 { left: 28px; right: 36px; bottom: 22px; opacity: .8; }
.press-art .sheet.s3 { left: 36px; right: 28px; bottom: 26px; opacity: .6; }
@keyframes press { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(44px); } }
@keyframes squash { 0%, 100% { transform: scaleY(1); } 50% { transform: scaleY(.25); } }

/* ---- compress view: shelf + deck ------------------------------------------------------------ */
#view-compress { display: grid; grid-template-columns: minmax(0, 1fr) 360px; }
.shelf { padding: 18px 12px 18px 20px; display: flex; flex-direction: column; gap: 12px; min-height: 0; overflow: hidden; }
.dropzone { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-radius: 14px; border: 1.5px dashed var(--line-2); color: var(--muted); cursor: pointer; flex-shrink: 0; }
.dropzone:hover { border-color: var(--accent); color: var(--text); }
.dropzone b { color: var(--text); }
.file-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; overflow-y: auto; padding: 2px 6px 18px 2px; align-content: start; min-height: 0; }
.fcard { position: relative; padding: 14px 14px 12px; border-radius: var(--radius); background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(14px); display: flex; flex-direction: column; gap: 9px; transition: transform .15s, border-color .15s; }
.fcard:hover { transform: translateY(-2px); border-color: var(--line-2); }
.fcard.sel { border-color: rgba(201, 170, 255, .55); box-shadow: 0 0 0 1px rgba(201, 170, 255, .3), 0 14px 34px rgba(180, 108, 255, .18); }
.fcard .top { display: flex; gap: 10px; align-items: flex-start; }
.fcard .ficon { width: 34px; height: 42px; border-radius: 6px; flex-shrink: 0; background: linear-gradient(160deg, #fff, #e7defc); position: relative; overflow: hidden; }
.fcard .ficon::after { content: 'PDF'; position: absolute; bottom: 4px; left: 0; right: 0; text-align: center; font-size: 8.5px; font-weight: 800; color: #8a3ddc; }
.fcard .fname { font-weight: 650; word-break: break-word; line-height: 1.3; }
.fcard .fsub { color: var(--muted); font-size: 12px; margin-top: 2px; }
.fcard .x { margin-left: auto; width: 26px; height: 26px; border: 0; border-radius: 8px; background: transparent; color: var(--dim); display: grid; place-items: center; padding: 0; flex-shrink: 0; }
.fcard .x:hover { color: var(--text); background: rgba(255, 255, 255, .07); }
.fcard .x svg { width: 14px; height: 14px; }
.bars { display: grid; gap: 5px; }
.bar { position: relative; height: 9px; border-radius: 6px; background: rgba(255, 255, 255, .06); overflow: hidden; }
.bar i { position: absolute; inset: 0 auto 0 0; border-radius: 6px; }
.bar.before i { background: rgba(169, 156, 200, .55); width: 100%; }
.bar.after i { background: linear-gradient(90deg, var(--accent-2), var(--accent)); transition: width .5s ease; }
.bar.after.working i { width: 40% !important; background: linear-gradient(90deg, transparent, var(--accent), transparent); animation: sweep 1.2s linear infinite; }
@keyframes sweep { from { transform: translateX(-100%); } to { transform: translateX(250%); } }
.barline { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); }
.barline b { color: var(--text); font-weight: 650; }
.fcard .chips { display: flex; flex-wrap: wrap; gap: 5px; }
.fcard .status { font-size: 12px; color: var(--muted); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.fcard .status .saved { color: #9ff0c6; font-weight: 700; }
.fcard .parts { font-size: 11.5px; color: var(--muted); }

.deck { margin: 14px 16px 14px 4px; border-radius: 20px; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(18px); display: flex; flex-direction: column; min-height: 0; box-shadow: 0 24px 60px rgba(0, 0, 0, .3); }
.deck-scroll { overflow-y: auto; padding: 16px 18px 10px; flex: 1; min-height: 0; }
.deck-foot { padding: 12px 18px 16px; border-top: 1px solid var(--line); }
.foot-note { color: var(--muted); font-size: 12px; margin-top: 9px; line-height: 1.5; }
.gauge-wrap { position: relative; width: 190px; height: 190px; margin: 2px auto 0; }
.gauge { width: 190px; height: 190px; transform: rotate(-90deg); }
.g-track { fill: none; stroke: rgba(255, 255, 255, .07); stroke-width: 14; }
.g-fill { fill: none; stroke: url(#gg); stroke-width: 14; stroke-linecap: round; transition: stroke-dasharray .7s ease; filter: drop-shadow(0 0 8px rgba(180, 108, 255, .55)); }
.g-target { stroke: #ffd66b; stroke-width: 3; }
.gauge-text { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.g-big { font-size: 30px; font-weight: 800; letter-spacing: -.02em; background: linear-gradient(135deg, #ffd1e8, #e4cfff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.g-small { font-size: 11.5px; color: var(--muted); max-width: 140px; line-height: 1.4; margin-top: 2px; }
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.seg button { height: 36px; border-radius: 10px; border: 1px solid var(--line); background: rgba(255, 255, 255, .03); color: var(--muted); font-weight: 600; font-size: 12.5px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.seg button.on { color: #fff; border-color: transparent; background: linear-gradient(135deg, rgba(255, 111, 174, .35), rgba(180, 108, 255, .45)); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips button { height: 30px; padding: 0 11px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255, 255, 255, .03); color: var(--muted); font-size: 12px; font-weight: 600; }
.chips button.on { color: #fff; border-color: transparent; background: linear-gradient(135deg, rgba(255, 111, 174, .35), rgba(180, 108, 255, .45)); }
.custom { margin-top: 10px; display: grid; gap: 8px; padding: 12px; border-radius: 12px; background: rgba(255, 255, 255, .03); border: 1px solid var(--line); }
.slider { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 10px; font-size: 12px; color: var(--muted); }
.slider input { grid-column: 1 / -1; accent-color: var(--accent); width: 100%; }
.slider b { color: var(--text); font-weight: 650; }
.row-toggle { display: flex; gap: 10px; align-items: flex-start; padding: 8px 2px; color: var(--muted); font-size: 12.5px; line-height: 1.45; cursor: pointer; }
.row-toggle input { accent-color: var(--accent); width: 16px; height: 16px; margin: 1px 0 0; flex-shrink: 0; }
.row-toggle b { color: var(--text); font-weight: 650; }
.group { margin-top: 12px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255, 255, 255, .02); padding: 0 12px; }
.group summary { list-style: none; cursor: pointer; padding: 11px 0; font-weight: 650; display: flex; align-items: center; gap: 8px; }
.group summary::-webkit-details-marker { display: none; }
.group summary::after { content: ''; margin-left: auto; width: 7px; height: 7px; border-right: 2px solid var(--dim); border-bottom: 2px solid var(--dim); transform: rotate(45deg); transition: transform .15s; }
.group[open] summary::after { transform: rotate(-135deg); }
.group[open] { padding-bottom: 6px; }
.save-opts { display: grid; gap: 8px; padding-bottom: 6px; }
.save-opts .radio { display: flex; gap: 8px; align-items: center; color: var(--muted); font-size: 12.5px; cursor: pointer; }
.save-opts .radio input { accent-color: var(--accent); }
.save-opts .folder { font-size: 12px; color: #dcc3ff; word-break: break-all; }
.field { display: grid; gap: 5px; font-size: 12px; color: var(--muted); }
.field input, .field select, select { height: 34px; border-radius: 9px; border: 1px solid var(--line-2); background: rgba(0, 0, 0, .25); padding: 0 10px; color: var(--text); }
.preset-row { display: flex; gap: 6px; align-items: center; margin-top: 14px; flex-wrap: wrap; }
.preset-row select { flex: 1; min-width: 0; }

/* ---- check view --------------------------------------------------------------------------- */
#view-check { overflow-y: auto; padding: 18px 22px 30px; }
.check-head { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; }
.check-head select { min-width: 280px; max-width: 100%; }
.check-body { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; }
.card { padding: 18px; border-radius: 18px; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(14px); }
.card h3 { margin: 0 0 12px; font-size: 14px; }
.card.wide { grid-column: 1 / -1; }
.stack { display: flex; height: 22px; border-radius: 8px; overflow: hidden; background: rgba(255, 255, 255, .05); }
.stack i { display: block; height: 100%; }
.legend { display: grid; gap: 8px; margin-top: 14px; }
.legend div { display: grid; grid-template-columns: 12px 1fr auto auto; gap: 10px; align-items: center; font-size: 12.5px; }
.legend span.sw { width: 12px; height: 12px; border-radius: 4px; }
.legend .v { font-weight: 650; } .legend .p { color: var(--muted); width: 44px; text-align: right; }
.bigstat { font-size: 30px; font-weight: 800; letter-spacing: -.02em; }
.kv { display: grid; grid-template-columns: 1fr auto; gap: 8px 14px; font-size: 12.5px; color: var(--muted); }
.kv b { color: var(--text); font-weight: 650; text-align: right; }
.heavy { display: grid; gap: 8px; }
.heavy div { display: grid; grid-template-columns: 64px 1fr 70px; gap: 10px; align-items: center; font-size: 12.5px; }
.heavy .hb { height: 8px; border-radius: 5px; background: rgba(255, 255, 255, .06); overflow: hidden; }
.heavy .hb i { display: block; height: 100%; background: linear-gradient(90deg, var(--accent-2), var(--accent)); }
.tips { margin: 0; padding-left: 18px; color: var(--muted); line-height: 1.6; font-size: 12.5px; }
.empty-note { color: var(--muted); padding: 30px; text-align: center; }

/* ---- compare view -------------------------------------------------------------------------- */
#view-compare { display: flex; flex-direction: column; padding: 14px 18px 18px; gap: 12px; }
.compare-bar { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.compare-bar select { min-width: 220px; max-width: 360px; }
.pager, .zoom { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12.5px; }
.compare-sizes { margin-left: auto; display: flex; gap: 8px; }
.compare-stage { position: relative; flex: 1; min-height: 0; overflow: auto; border-radius: 18px; background: rgba(0, 0, 0, .28); border: 1px solid var(--line); }
.compare-inner { position: relative; margin: 20px auto; width: max-content; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); user-select: none; }
.compare-inner canvas { display: block; background: #fff; }
.after-clip { position: absolute; inset: 0; overflow: hidden; clip-path: inset(0 0 0 50%); }
.split-line { position: absolute; top: 0; bottom: 0; left: 50%; width: 0; cursor: ew-resize; }
.split-line i { position: absolute; top: 0; bottom: 0; left: -1.5px; width: 3px; background: linear-gradient(var(--accent-2), var(--accent)); box-shadow: 0 0 12px rgba(180, 108, 255, .8); }
.split-line::before { content: ''; position: absolute; top: 50%; left: -18px; width: 36px; height: 36px; margin-top: -18px; border-radius: 50%; background: linear-gradient(135deg, var(--accent-2), var(--accent)); box-shadow: 0 6px 18px rgba(0, 0, 0, .4); }
.split-line span { position: absolute; top: 10px; font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 999px; background: rgba(12, 8, 26, .78); color: #fff; white-space: nowrap; }
.split-line span:first-child { right: 12px; } .split-line span:last-child { left: 12px; }
.compare-empty { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; color: var(--muted); gap: 12px; padding: 20px; }
.busy { position: absolute; inset: 0; display: grid; place-content: center; gap: 10px; justify-items: center; color: var(--muted); background: rgba(12, 8, 26, .4); }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .12); border-top-color: var(--accent); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- dialogs, toast, overlay --------------------------------------------------------------- */
dialog { border: 1px solid var(--line-2); border-radius: 18px; background: rgba(24, 17, 46, .97); color: var(--text); padding: 0; width: min(520px, calc(100vw - 32px)); box-shadow: 0 30px 80px rgba(0, 0, 0, .6); }
dialog::backdrop { background: rgba(6, 3, 14, .6); backdrop-filter: blur(3px); }
.dlg-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.dlg-head h2 { margin: 0; font-size: 16px; }
.dlg-body { padding: 16px 18px 18px; max-height: 70vh; overflow-y: auto; }
.dlg-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }
.toast { position: fixed; bottom: 20px; left: 50%; transform: translate(-50%, 30px); opacity: 0; transition: .25s; padding: 11px 16px; border-radius: 12px; background: rgba(30, 22, 58, .97); border: 1px solid var(--line-2); box-shadow: 0 14px 40px rgba(0, 0, 0, .5); z-index: 50; max-width: min(560px, calc(100vw - 32px)); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.drop-overlay { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; background: rgba(12, 8, 26, .7); backdrop-filter: blur(4px); }
.drop-overlay div { display: flex; flex-direction: column; align-items: center; gap: 12px; font-size: 18px; font-weight: 700; padding: 40px 60px; border-radius: 24px; border: 2px dashed var(--accent); }
.drop-overlay svg { width: 38px; height: 38px; color: var(--accent); }

/* ---- browser edition and small screens --------------------------------------------------- */
html.web .rail-brand { cursor: pointer; }
@media (max-width: 980px) {
  #view-compress { grid-template-columns: 1fr; overflow-y: auto; }
  .shelf { overflow: visible; }
  .file-grid { overflow: visible; }
  .deck { margin: 0 14px 18px; display: block; }
  .deck-scroll { overflow: visible; }
  .deck-foot { position: sticky; bottom: 0; background: rgba(24, 17, 46, .96); border-radius: 0 0 20px 20px; }
}
@media (max-width: 640px) {
  #app { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr) 62px; }
  .rail { grid-row: 3; grid-column: 1; flex-direction: row; justify-content: space-around; padding: 6px 8px; border-right: 0; border-top: 1px solid var(--line); }
  .rail-brand, .rail-gap { display: none; }
  .rail-btn { width: auto; flex: 1; }
  .topbar { grid-row: 1; grid-column: 1; flex-wrap: wrap; padding: 10px 14px; gap: 8px; }
  .title-block { width: 100%; }
  .top-actions { margin-left: 0; flex-wrap: wrap; }
  .top-actions .cp-btn span { display: none; }
  .view, .welcome { grid-row: 2; grid-column: 1; }
  .file-grid { grid-template-columns: 1fr; }
  .shelf { padding: 14px; }
  .welcome-card { padding: 24px 18px; }
  .welcome-actions { flex-direction: column; }
  .check-head select, .compare-bar select { min-width: 0; width: 100%; }
  .compare-sizes { margin-left: 0; }
}
