:root {
  --bg: #f6f7fb;
  --surface: #ffffff;
  --surface-2: #f0f2f7;
  --text: #141824;
  --muted: #5d6475;
  --border: #e2e5ee;
  --accent: #1f5eff;
  --accent-ink: #ffffff;
  --accent-soft: #e6edff;
  --checker-a: #e9ebf1;
  --checker-b: #ffffff;
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 4px 16px rgba(16, 24, 40, .06);
  --radius: 14px;
  color-scheme: light;
}
/* Dark palette: follows the system unless the visitor picked Light, or forced with Dark. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1118;
    --surface: #171b24;
    --surface-2: #1f2430;
    --text: #eef0f5;
    --muted: #9aa2b4;
    --border: #2a3040;
    --accent: #5b8cff;
    --accent-ink: #0b1020;
    --accent-soft: #1e2a4a;
    --checker-a: #262b37;
    --checker-b: #1c2029;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e1118;
  --surface: #171b24;
  --surface-2: #1f2430;
  --text: #eef0f5;
  --muted: #9aa2b4;
  --border: #2a3040;
  --accent: #5b8cff;
  --accent-ink: #0b1020;
  --accent-soft: #1e2a4a;
  --checker-a: #262b37;
  --checker-b: #1c2029;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25);
  color-scheme: dark;
}

/* Theme switcher */
.theme-btn {
  flex: none; width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--border);
  background: var(--surface); color: var(--muted); display: grid; place-items: center; cursor: pointer; padding: 0;
  transition: color .15s, background .15s;
}
.theme-btn:hover { color: var(--text); background: var(--surface-2); }
.theme-btn svg { width: 18px; height: 18px; }
.theme-btn [data-icon] { display: none; }
:root:not([data-theme]) .theme-btn [data-icon="system"],
:root[data-theme="light"] .theme-btn [data-icon="light"],
:root[data-theme="dark"] .theme-btn [data-icon="dark"] { display: block; }
.header-end { display: flex; align-items: center; gap: 12px; min-width: 0; }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.55 Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { line-height: 1.2; margin: 0; }
a { color: inherit; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }

/* Header */
.site-header { background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 10; }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; text-decoration: none; }
.brand-mark { width: 28px; height: 28px; display: block; flex: none; }
.nav { display: flex; gap: 20px; }
.nav a { text-decoration: none; color: var(--muted); font-weight: 500; }
.nav a:hover { color: var(--text); }

.hero { padding: 36px 16px 20px; }
.hero h1 { font-size: clamp(26px, 4vw, 38px); letter-spacing: -.02em; }
.lede { color: var(--muted); max-width: 640px; margin: 10px 0 0; font-size: 16px; }

/* Steps */
.steps { display: flex; gap: 8px; list-style: none; padding: 0; margin: 0 0 16px; flex-wrap: wrap; }
.steps li { padding: 6px 12px; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: 13px; font-weight: 500; }
.steps li.active { background: var(--accent-soft); color: var(--accent); }
.steps li.done { color: var(--text); }

/* Cards & layout */
.grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 16px; }
.side { display: grid; gap: 16px; align-content: start; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); min-width: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2 { font-size: 16px; }
.head-actions { display: flex; align-items: center; gap: 12px; }
.sheet-card { margin-top: 16px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 16px; border-radius: 10px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text); font: inherit; font-weight: 600;
  cursor: pointer; transition: background .15s, border-color .15s, opacity .15s;
}
.btn:hover:not(:disabled) { background: var(--surface-2); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover:not(:disabled) { filter: brightness(1.08); background: var(--accent); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn.ghost:hover:not(:disabled) { color: var(--text); }
.btn.sm { padding: 6px 12px; font-size: 13px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn:focus-visible, select:focus-visible, input:focus-visible, .dropzone:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; }

/* Dropzone */
.dropzone {
  border: 2px dashed var(--border); border-radius: 12px; padding: 48px 16px;
  display: grid; justify-items: center; text-align: center; gap: 6px; color: var(--muted);
  transition: border-color .15s, background .15s;
}
.dropzone.over { border-color: var(--accent); background: var(--accent-soft); }
.dz-title { font-weight: 600; color: var(--text); margin: 6px 0 0; font-size: 16px; }
.dropzone p { margin: 0; }
.dz-buttons { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; justify-content: center; }

/* Editor */
.frame-wrap {
  display: flex; justify-content: center; align-items: center;
  background-color: var(--checker-b);
  background-image: linear-gradient(45deg, var(--checker-a) 25%, transparent 25%, transparent 75%, var(--checker-a) 75%), linear-gradient(45deg, var(--checker-a) 25%, transparent 25%, transparent 75%, var(--checker-a) 75%);
  background-size: 16px 16px; background-position: 0 0, 8px 8px;
  border-radius: 12px; padding: 20px; min-height: 280px;
}
.frame-wrap { position: relative; }
.auto-status {
  position: absolute; left: 50%; bottom: 12px; transform: translateX(-50%);
  background: rgba(15, 20, 35, .82); color: #fff; font-size: 13px; font-weight: 500;
  padding: 7px 14px; border-radius: 999px; white-space: nowrap; display: flex; align-items: center; gap: 8px;
}
.auto-status::before {
  content: ""; width: 12px; height: 12px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.35); border-top-color: #fff; animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.auto-row { display: flex; align-items: center; justify-content: center; gap: 14px; flex-wrap: wrap; margin: -4px 0 14px; }
.auto-row .check { margin: 0; }
.auto-check { margin-top: 14px; color: var(--text); }
#editorCanvas { display: block; touch-action: none; cursor: grab; box-shadow: 0 2px 12px rgba(0,0,0,.18); }
#editorCanvas.dragging { cursor: grabbing; }
.hint { color: var(--muted); font-size: 13px; margin: 10px 0 14px; text-align: center; }
.controls { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 20px; }
.controls .btn-row { grid-column: 1 / -1; }
.slider label { display: flex; justify-content: space-between; font-size: 13px; font-weight: 500; margin-bottom: 4px; }
.slider output { color: var(--muted); font-variant-numeric: tabular-nums; }
input[type="range"] { width: 100%; accent-color: var(--accent); }

/* Fields */
.field { display: grid; gap: 5px; margin-bottom: 12px; font-size: 13px; font-weight: 500; }
select, input[type="number"] {
  font: inherit; font-size: 14px; padding: 9px 10px; border-radius: 10px;
  border: 1px solid var(--border); background: var(--surface); color: var(--text); width: 100%;
}
.custom-size { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.check { display: flex; align-items: center; gap: 8px; font-size: 14px; margin-bottom: 8px; cursor: pointer; }
.check input { accent-color: var(--accent); width: 16px; height: 16px; }
.head-actions .check { margin: 0; font-size: 13px; }

/* Swatches */
.swatches { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; align-items: center; }
.swatch {
  width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--border);
  cursor: pointer; padding: 0; position: relative;
}
.swatch[aria-checked="true"] { outline: 2px solid var(--accent); outline-offset: 2px; }
.swatch-custom { overflow: hidden; background: conic-gradient(red, yellow, lime, aqua, blue, magenta, red); }
.swatch-custom input { opacity: 0; position: absolute; inset: 0; width: 100%; height: 100%; cursor: pointer; }
.bg-options { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 10px 8px; margin-bottom: 14px; }
.bg-opt {
  display: grid; justify-items: center; gap: 4px; padding: 0; border: none; background: none;
  color: var(--muted); font: inherit; font-size: 11px; cursor: pointer; position: relative;
}
.bg-thumb {
  width: 54px; height: 54px; border-radius: 10px; border: 1px solid var(--border);
  display: grid; place-items: center; overflow: hidden;
}
.bg-thumb canvas { display: none; }
.bg-opt.has-photo .bg-thumb { height: auto; min-height: 54px; }
.bg-opt.has-photo .bg-thumb canvas { display: block; }
.bg-opt[aria-checked="true"] .bg-thumb { outline: 2px solid var(--accent); outline-offset: 2px; }
.bg-opt[aria-checked="true"] .bg-name { color: var(--accent); font-weight: 600; }
.bg-opt-custom .bg-thumb { background: conic-gradient(red, yellow, lime, aqua, blue, magenta, red); }
.bg-opt-custom input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.bg-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.progress { margin: 8px 0; }
.bar { height: 6px; background: var(--surface-2); border-radius: 99px; overflow: hidden; }
.bar span { display: block; height: 100%; width: 0; background: var(--accent); transition: width .2s; }
.progress p { margin: 6px 0 0; }

/* Sheet */
.sheet-grid { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 24px; }
.shrink-note { margin: -4px 0 12px; color: #b26a00; }
.out-buttons { display: grid; gap: 8px; margin: 14px 0 10px; }
.sheet-preview { background: var(--surface-2); border-radius: 12px; padding: 20px; display: flex; justify-content: center; align-items: center; min-height: 320px; }
#sheetCanvas { max-width: 100%; height: auto; background: #fff; box-shadow: 0 2px 14px rgba(0,0,0,.15); }

/* Background remover */
.checker {
  background-color: var(--checker-b);
  background-image: linear-gradient(45deg, var(--checker-a) 25%, transparent 25%, transparent 75%, var(--checker-a) 75%), linear-gradient(45deg, var(--checker-a) 25%, transparent 25%, transparent 75%, var(--checker-a) 75%);
  background-size: 16px 16px; background-position: 0 0, 8px 8px;
}
.br-canvas-wrap { position: relative; display: flex; justify-content: center; align-items: center; min-height: 260px; border-radius: 12px; overflow: hidden; margin-bottom: 14px; }
#brCanvas { display: block; }
.br-badge { position: absolute; top: 10px; left: 10px; background: rgba(15,20,35,.8); color: #fff; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; }
#brCompare { touch-action: none; user-select: none; }
.bg-opt-transparent .bg-thumb {
  background-color: #fff;
  background-image: linear-gradient(45deg, #d9dce3 25%, transparent 25%, transparent 75%, #d9dce3 75%), linear-gradient(45deg, #d9dce3 25%, transparent 25%, transparent 75%, #d9dce3 75%);
  background-size: 10px 10px; background-position: 0 0, 5px 5px;
}

/* Page tabs */
.tabs-nav a { padding: 6px 12px; border-radius: 999px; white-space: nowrap; }
.brand { white-space: nowrap; }
.tabs-nav a[aria-current="page"] { background: var(--accent-soft); color: var(--accent); }

/* ID card page */
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.quad-wrap {
  display: flex; justify-content: center; align-items: center; min-height: 220px;
  background: var(--surface-2); border-radius: 12px; overflow: hidden;
}
.quad-canvas { display: block; touch-action: none; }
.side-card .btn-row { justify-content: center; }
.enhance-card { margin-top: 16px; }
.enhance-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 24px; align-items: end; }
.enhance-grid .check { margin: 4px 0; }

/* Photo sheet tiles */
.card-head h2 .muted { font-weight: 500; margin-left: 6px; }
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.tile {
  position: relative; aspect-ratio: var(--cell-ratio, 3 / 4); border-radius: 12px; overflow: hidden;
  background: var(--surface-2); border: 2px dashed var(--border); display: flex; align-items: center; justify-content: center;
  transition: border-color .15s, opacity .15s;
}
.tile.filled { border-style: solid; }
.tile-canvas { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; }
.tile-canvas.pannable { cursor: grab; }
.tile-canvas.panning { cursor: grabbing; }
.tile-num { cursor: grab; user-select: none; white-space: nowrap; }
.fit-btn {
  height: 30px; padding: 0 10px; border-radius: 8px; border: none; font: inherit; font-size: 12px; font-weight: 700;
  background: rgba(255,255,255,.92); color: #141824; cursor: pointer;
}
.fit-btn[aria-pressed="true"] { background: var(--accent); color: #fff; }
.tile.over { border-color: var(--accent); }
.tile.dragging { opacity: .4; }
.tile canvas { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.tile-empty { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 4px; cursor: pointer; color: var(--muted); font-size: 13px; font-weight: 500; }
.tile-empty:hover { color: var(--accent); }
.tile-empty .plus { font-size: 30px; line-height: 1; font-weight: 300; }
.tile-bar {
  position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 4px; padding: 6px;
  background: linear-gradient(transparent, rgba(0,0,0,.6));
}
.tile-num { color: #fff; font-weight: 700; font-size: 13px; margin-right: auto; padding-left: 4px; }
.icon-btn {
  width: 30px; height: 30px; border-radius: 8px; border: none; display: grid; place-items: center;
  background: rgba(255,255,255,.92); color: #141824; font-size: 15px; cursor: pointer; padding: 0;
}
.icon-btn:hover { background: #fff; }

/* Homepage tool overview */
.features { margin: 4px auto 22px; }
.features-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.feature-card {
  display: flex; gap: 12px; align-items: flex-start; padding: 14px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
  text-decoration: none; color: var(--text); transition: transform .15s, border-color .15s, box-shadow .15s;
}
.feature-card:hover { transform: translateY(-2px); border-color: var(--accent); }
.feature-card.is-here { border-color: var(--accent); background: linear-gradient(180deg, var(--accent-soft), var(--surface) 70%); }
.feature-icon {
  flex: none; width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, #2F6BFF, #7A3DF0);
}
.feature-icon svg { width: 22px; height: 22px; }
.feature-body { display: grid; gap: 3px; min-width: 0; }
.feature-title { font-weight: 700; font-size: 15px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.feature-here { font-size: 11px; font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 2px 8px; border-radius: 999px; }
.feature-line { font-size: 13px; color: var(--muted); }
.feature-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.feature-chips span { font-size: 11px; font-weight: 600; color: var(--text); background: var(--surface-2); border-radius: 999px; padding: 2px 8px; }
.trust-row { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 18px; justify-content: center; padding: 0; margin: 14px 0 0; font-size: 13px; color: var(--muted); }
.trust-row li::before { content: "✓"; color: #1f9d55; font-weight: 700; margin-right: 6px; }
@media (max-width: 900px) { .features-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) {
  .features-grid { gap: 8px; }
  .feature-card { flex-direction: column; gap: 8px; padding: 12px; }
  .feature-icon { width: 34px; height: 34px; border-radius: 9px; }
  .feature-icon svg { width: 19px; height: 19px; }
  .feature-title { font-size: 14px; }
  .feature-line { font-size: 12px; }
  .feature-chips { display: none; }
  .trust-row { font-size: 12px; justify-content: flex-start; }
}

/* Local print partner */
.partner { margin-top: 24px; margin-bottom: 8px; }
.prose .partner { padding: 0; margin-top: 32px; }
.partner-card {
  display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap;
  background: var(--surface); border: 1px solid var(--border); border-left: 4px solid #f5a000;
  border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow);
}
.partner-text { display: grid; gap: 3px; min-width: 0; }
.partner-kicker { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #c47f00; }
.partner-text strong { font-size: 16px; }
.partner-text span:last-child { color: var(--muted); font-size: 14px; }
.partner-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.partner-actions .btn { text-decoration: none; }
.footer-sub { margin-top: 16px; }

/* Multi-page preview */
.ps-preview { flex-direction: column; gap: 14px; }
.pager { display: flex; align-items: center; gap: 12px; }
.tile-page { position: absolute; top: 6px; left: 6px; background: rgba(15,20,35,.75); color: #fff; font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 999px; pointer-events: none; }
.tile-add { border-style: dashed; }

/* Info */
.info { padding: 48px 16px 8px; }
.info h2 { font-size: 22px; margin-bottom: 18px; }
.how-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.how-grid > div { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; }
.how-grid h3 { font-size: 15px; margin: 10px 0 6px; }
.how-grid p { margin: 0; color: var(--muted); font-size: 14px; }
.num { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: 13px; }
details { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; margin-bottom: 10px; }
summary { font-weight: 600; cursor: pointer; }
details p { color: var(--muted); margin: 10px 0 0; }

.site-footer { padding: 48px 0 32px; color: var(--muted); font-size: 13px; border-top: 1px solid var(--border); margin-top: 48px; }
.footer-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.footer-grid a { display: block; color: var(--muted); text-decoration: none; padding: 3px 0; }
.footer-grid a:hover { color: var(--text); text-decoration: underline; }
.footer-title { color: var(--text); font-weight: 600; margin: 0 0 8px; }
.footer-note { margin-top: 28px; text-align: center; }

/* Guide & info pages */
.prose { max-width: 800px; padding-top: 28px; }
.prose h1 { font-size: clamp(26px, 4vw, 36px); letter-spacing: -.02em; margin: 6px 0 14px; }
.prose h2 { font-size: 20px; margin: 34px 0 12px; }
.prose p, .prose li { line-height: 1.7; }
.prose ol, .prose ul { padding-left: 22px; }
.prose li { margin-bottom: 6px; }
.prose a:not(.btn) { color: var(--accent); }
.prose .lede { font-size: 17px; }
.crumbs { font-size: 13px; color: var(--muted); }
.crumbs a { color: var(--muted) !important; text-decoration: none; }
.cta-row { display: flex; gap: 10px; flex-wrap: wrap; margin: 20px 0; }
.cta-row .btn { text-decoration: none; }
.spec { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; font-size: 14px; }
.spec th, .spec td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
.spec tr:last-child th, .spec tr:last-child td { border-bottom: none; }
.spec th { width: 36%; color: var(--muted); font-weight: 500; }
.spec.sizes th { width: auto; background: var(--surface-2); color: var(--text); font-weight: 600; }
.table-scroll { overflow-x: auto; border-radius: 12px; }
.table-scroll .spec { min-width: 560px; }
.note { font-size: 14px; color: var(--muted); background: var(--surface-2); border-radius: 10px; padding: 10px 14px; margin-top: 14px; }
.ad-slot { margin: 28px auto; min-height: 90px; }
.prose .ad-slot { padding: 0; }

/* Camera */
.camera-dialog { border: none; border-radius: var(--radius); padding: 0; background: var(--surface); color: var(--text); max-width: min(640px, 94vw); }
.camera-dialog::backdrop { background: rgba(0,0,0,.6); }
.cam-body { padding: 16px; display: grid; gap: 10px; }
.cam-body video { width: 100%; border-radius: 10px; background: #000; transform: scaleX(-1); }
.cam-body .btn-row { justify-content: flex-end; }

/* Toast */
.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px);
  background: var(--text); color: var(--bg); padding: 10px 16px; border-radius: 10px;
  font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; max-width: calc(100vw - 32px);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* Print */
#printArea { display: none; }
@media print {
  body > *:not(#printArea) { display: none !important; }
  #printArea { display: block !important; }
  #printArea img { display: block; break-after: page; }
  #printArea img:last-child { break-after: auto; }
}

/* Responsive */
@media (max-width: 900px) {
  .grid, .grid-2, .enhance-grid, .sheet-grid { grid-template-columns: minmax(0, 1fr); }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .how-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .nav:not(.tabs-nav) { display: none; }
  .tabs-nav { gap: 0; overflow-x: auto; scrollbar-width: none; min-width: 0; }
  .tabs-nav::-webkit-scrollbar { display: none; }
  .header-inner { gap: 10px; }
  .tabs-nav a { padding: 6px 8px; font-size: 13px; }
  .brand-text { display: none; }
  .nav-long { display: none; }
  .header-end { gap: 6px; }
  .tabs-nav a { padding: 6px 6px; font-size: 12.5px; }
  .theme-btn { width: 32px; height: 32px; border-radius: 9px; }
  .theme-btn svg { width: 16px; height: 16px; }
  .controls { grid-template-columns: 1fr; }
  .how-grid { grid-template-columns: 1fr; }
  .frame-wrap { padding: 12px; }
  .card { padding: 14px; }
}
