/* Galaxy Clothing — tampilan. Header hitam, kartu terang di atas krem, kuning Galaxy untuk aksi utama.
   HP: navigasi bawah. iPad mendatar & laptop (≥1000px): navigasi kiri, keranjang & detail order dua kolom. */
@font-face { font-family: 'Poppins'; src: url('fonts/poppins-500.woff') format('woff'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Poppins'; src: url('fonts/poppins-600.woff') format('woff'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'Poppins'; src: url('fonts/poppins-700.woff') format('woff'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Poppins'; src: url('fonts/poppins-800.woff') format('woff'); font-weight: 800; font-display: swap; }
@font-face { font-family: 'Plus Jakarta Sans'; src: url('fonts/jakarta-var.woff') format('woff'); font-weight: 200 800; font-display: swap; }
@font-face { font-family: 'Oswald'; src: url('fonts/oswald-var.woff') format('woff'); font-weight: 200 700; font-display: swap; }

:root {
  --bg: #FAF6E8; --card: #FFFFFF; --ink: #0B0B0B; --mut: #6B6650; --line: #E6DFC4; --soft: #F1EBD2;
  --y: #FFD400; --yink: #0B0B0B; --red: #D10A00; --redbg: #FDE3E0; --ok: #17703A; --okbg: #DCF2E2; --warn: #7A5B00; --warnbg: #FFF0B3;
  --bar: #0B0B0B; --barink: #FAF6E8; --wa: #1FAF54;
  --hd: 'Poppins', 'Arial Black', system-ui, sans-serif; --bd: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --navh: 60px; --toph: 56px; --sat: env(safe-area-inset-top, 0px); --sab: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --bg: #0B0B0B; --card: #1A1A17; --ink: #FAF6E8; --mut: #A8A28A; --line: #35332A; --soft: #26251F;
  --red: #FF6A5C; --redbg: #3C1512; --ok: #6FD58C; --okbg: #143221; --warn: #FFD95A; --warnbg: #3A3200; --bar: #000000; color-scheme: dark; } }
:root[data-theme="dark"] {
  --bg: #0B0B0B; --card: #1A1A17; --ink: #FAF6E8; --mut: #A8A28A; --line: #35332A; --soft: #26251F;
  --red: #FF6A5C; --redbg: #3C1512; --ok: #6FD58C; --okbg: #143221; --warn: #FFD95A; --warnbg: #3A3200; --bar: #000000; color-scheme: dark; }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--toph) + var(--sat) + 8px); }
html, body { margin: 0; }
body { background: var(--bg); color: var(--ink); font: 15px/1.45 var(--bd); min-height: 100vh; min-height: 100dvh; -webkit-tap-highlight-color: transparent; overscroll-behavior-y: none; }
body.lock { overflow: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }
img { max-width: 100%; }
h1, h2, h3 { font-family: var(--hd); letter-spacing: -.5px; line-height: 1.12; margin: 0; text-wrap: balance; }
h1 { font-size: 30px; font-weight: 800; text-transform: lowercase; }
h2 { font-size: 20px; font-weight: 800; }
h3, .h3 { font-size: 16px; font-weight: 700; letter-spacing: 0; font-family: var(--hd); }
p { margin: 0; }
code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .9em; background: var(--soft); padding: 1px 5px; border-radius: 5px; }
:focus-visible { outline: 3px solid var(--y); outline-offset: 2px; }

/* ----- bingkai ----- */
#top { position: sticky; top: 0; z-index: 50; background: var(--bar); color: var(--barink); padding-top: var(--sat); }
#top .in { display: flex; align-items: center; gap: 8px; min-height: var(--toph); padding: 0 max(14px, env(safe-area-inset-right, 0px)) 0 max(14px, env(safe-area-inset-left, 0px)); }
.logo { height: 32px; width: auto; display: block; }
.logo-a { display: flex; align-items: center; }
.pill { display: inline-flex; align-items: center; gap: 6px; font: 600 12px/1 var(--bd); padding: 7px 10px; border-radius: 99px; background: #2a2a26; color: #FAF6E8; white-space: nowrap; border: 0; cursor: pointer; text-decoration: none; max-width: 46vw; overflow: hidden; text-overflow: ellipsis; }
.pill b { width: 8px; height: 8px; border-radius: 50%; background: #4ade80; display: inline-block; flex: none; }
.pill.sync b { background: var(--y); animation: blink 1.2s infinite; }
.pill.off b { background: #9a968a; }
.pill.bad b { background: #ff5a4e; }
.pill.role { background: transparent; border: 1px solid #3a3a34; }
@keyframes blink { 50% { opacity: .35; } }
#banners:empty { display: none; }
.banner { display: flex; align-items: center; gap: 8px; padding: 9px max(14px, env(safe-area-inset-left, 0px)); background: var(--soft); border-bottom: 1px solid var(--line); font-size: 13.5px; font-weight: 600; }
.banner.y { background: var(--y); color: var(--yink); }
.banner.r { background: var(--redbg); color: var(--red); }
.shell { display: block; }
.wrap { width: 100%; max-width: 860px; margin: 0 auto; padding: 18px max(16px, env(safe-area-inset-right, 0px)) calc(var(--navh) + var(--sab) + 96px) max(16px, env(safe-area-inset-left, 0px)); }
body.noshell .wrap { padding-bottom: 48px; }
#nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; background: var(--bar); display: flex; padding-bottom: var(--sab); padding-left: env(safe-area-inset-left, 0px); padding-right: env(safe-area-inset-right, 0px); }
#nav:empty { display: none; }
#nav a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: #a8a28a; text-decoration: none; font: 600 11px/1 var(--bd); min-height: var(--navh); padding: 6px 2px; }
#nav a.on { color: var(--y); }
#nav .ic { width: 23px; height: 23px; }

/* ----- dasar ----- */
.stack { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.g6 { gap: 6px !important; } .g8 { gap: 8px !important; } .g10 { gap: 10px !important; }
.mt4 { margin-top: 4px; } .mt6 { margin-top: 6px; } .mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mtm6 { margin-top: -6px; }
.row { display: flex; gap: 10px; align-items: center; min-width: 0; }
.row.wrapr { flex-wrap: wrap; }
.sp { flex: 1; min-width: 0; }
.ell { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.self-start { align-self: flex-start; }
.sub { color: var(--mut); font-size: 13px; }
.mut { color: var(--mut); }
.small { font-size: 12.5px; }
.b { font-weight: 700; }
.ink { color: var(--ink); }
.right { text-align: right; }
.num { font-variant-numeric: tabular-nums; }
.big { font: 800 20px/1.15 var(--hd); letter-spacing: -.4px; }
.ok-t { color: var(--ok); } .bad-t { color: var(--red); } .warn-t { color: var(--warn); }
.mono { font-family: ui-monospace, Menlo, Consolas, monospace; white-space: pre-wrap; word-break: break-word; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 14px; min-width: 0; }
.card.flat { border: 0; background: var(--soft); }
.card.list { padding: 2px 14px; }
details.card > summary { list-style: none; cursor: pointer; }
details.card > summary::-webkit-details-marker { display: none; }
details.card > summary::after { content: '▾'; float: right; color: var(--mut); }
details[open].card > summary::after { content: '▴'; }
.bar { background: var(--ink); color: var(--bg); font: 700 12px/1 var(--bd); letter-spacing: .06em; text-transform: uppercase; padding: 10px 12px; border-radius: 8px; display: flex; justify-content: space-between; align-items: center; gap: 8px; border: 0; width: 100%; text-align: left; }
.bar .r { opacity: .72; text-transform: none; letter-spacing: 0; font-weight: 600; display: inline-flex; align-items: center; gap: 4px; }
.bar.r { background: var(--red); color: #fff; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.grid4 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 640px) { .grid4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } .g3c { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.stat .k { font-size: 12px; color: var(--mut); font-weight: 600; }
.stat .v { font: 800 20px/1.15 var(--hd); letter-spacing: -.5px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.stat.y { background: var(--y); color: var(--yink); border-color: var(--y); }
.stat.y .k { color: #3a3200; }

/* ----- tombol & input ----- */
.btn { appearance: none; -webkit-appearance: none; border: 1.5px solid var(--ink); background: var(--card); color: var(--ink); border-radius: 12px; padding: 11px 14px; font-weight: 700; font-size: 14.5px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; text-align: center; text-decoration: none; line-height: 1.2; touch-action: manipulation; }
.btn:active { transform: translateY(1px); }
.btn.y { background: var(--y); border-color: var(--y); color: var(--yink); }
.btn.k { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.btn.red { background: var(--red); border-color: var(--red); color: #fff; }
.btn.ghost { border-color: var(--line); background: transparent; }
.btn.wa { background: var(--wa); border-color: var(--wa); color: #fff; }
.btn.sm { min-height: 38px; padding: 7px 11px; font-size: 13px; border-radius: 10px; }
.btn.block { width: 100%; }
.btn.icon-only { padding: 7px; min-width: 38px; }
.btn[disabled], .btn.busy { opacity: .5; pointer-events: none; }
.btn.bad-t { color: var(--red); }
.filebtn { position: relative; overflow: hidden; }
.filebtn input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font-size: 0; }
.ic { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.ic.xs { width: 14px; height: 14px; }
.ic.spin { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
label.f { display: flex; flex-direction: column; gap: 5px; font-weight: 600; font-size: 13px; min-width: 0; }
label.f > small { font-weight: 500; }
.in-t, select.in-t, textarea.in-t { width: 100%; border: 1.5px solid var(--line); background: var(--card); border-radius: 10px; padding: 10px 12px; font-weight: 500; font-size: 16px; min-height: 46px; min-width: 0; -webkit-appearance: none; appearance: none; }
select.in-t { background-image: linear-gradient(45deg, transparent 50%, var(--mut) 50%), linear-gradient(135deg, var(--mut) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 30px; }
textarea.in-t { min-height: 84px; resize: vertical; line-height: 1.4; }
.in-t:focus { border-color: var(--ink); outline: none; }
.in-t.mini { min-height: 38px; padding: 6px 8px; width: 112px; }
input[type="date"].in-t { min-height: 46px; }
.cb { width: 22px; height: 22px; flex: none; accent-color: var(--ink); }
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips.wrapc { flex-wrap: wrap; overflow: visible; }
.chip { appearance: none; white-space: nowrap; border: 1.5px solid var(--line); background: var(--card); border-radius: 99px; padding: 8px 13px; font-weight: 600; font-size: 13.5px; cursor: pointer; min-height: 40px; touch-action: manipulation; }
.chip.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.tag { display: inline-flex; align-items: center; gap: 4px; font: 700 11px/1 var(--bd); padding: 5px 8px; border-radius: 6px; background: var(--soft); color: var(--ink); white-space: nowrap; }
.tag.ok { background: var(--okbg); color: var(--ok); } .tag.warn { background: var(--warnbg); color: var(--warn); } .tag.bad { background: var(--redbg); color: var(--red); } .tag.dark { background: var(--ink); color: var(--bg); }
.step { display: inline-flex; align-items: center; border: 1.5px solid var(--ink); border-radius: 12px; overflow: hidden; flex: none; }
.step button { width: 44px; height: 44px; border: 0; background: var(--card); font: 700 21px/1 var(--bd); cursor: pointer; touch-action: manipulation; }
.step span { min-width: 42px; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; }
.sz { display: flex; flex-wrap: wrap; gap: 8px; }
.sz button { min-width: 54px; height: 48px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--card); font-weight: 700; cursor: pointer; padding: 0 10px; touch-action: manipulation; }
.sz button.on { background: var(--y); border-color: var(--ink); color: var(--yink); }
.sz button .q { display: block; font-size: 10.5px; font-weight: 600; color: var(--mut); line-height: 1; margin-top: 2px; }
.sz button.on .q { color: #3a3200; }
.swg { display: grid; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); gap: 8px; max-height: 300px; overflow: auto; padding: 2px; -webkit-overflow-scrolling: touch; }
.sw { appearance: none; display: flex; flex-direction: column; align-items: center; gap: 5px; border: 1.5px solid var(--line); background: var(--card); border-radius: 12px; padding: 8px 4px; cursor: pointer; font: 600 11.5px/1.15 var(--bd); text-align: center; min-height: 72px; color: var(--ink); }
.sw i { width: 28px; height: 28px; border-radius: 50%; border: 1px solid rgba(128, 128, 128, .5); display: block; }
.sw small { display: block; font-size: 10px; color: var(--mut); font-weight: 500; }
.sw.on { border-color: var(--ink); box-shadow: inset 0 0 0 2px var(--y); }
.dot { display: inline-block; width: 14px; height: 14px; border-radius: 50%; border: 1px solid rgba(128, 128, 128, .5); vertical-align: -2px; flex: none; }
.szg { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.szc { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.szc b { font-size: 13px; text-align: center; }
.szc input { text-align: center; font-weight: 700; padding: 8px 4px; }
.szc small { font-size: 10.5px; color: var(--mut); text-align: center; line-height: 1.1; }
.sabrow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: start; background: var(--soft); border-radius: 12px; padding: 10px; }

/* ----- daftar ----- */
.li { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); min-width: 0; color: inherit; text-decoration: none; background: none; border-left: 0; border-right: 0; border-top: 0; width: 100%; text-align: left; font: inherit; }
.li:last-child { border-bottom: 0; }
.li .t { font-weight: 700; overflow-wrap: anywhere; }
.li .s { font-size: 12.5px; color: var(--mut); overflow-wrap: anywhere; }
.tap { cursor: pointer; }
a.li:active, button.li:active { opacity: .7; }
.dayhead { font-size: 12px; font-weight: 700; color: var(--mut); padding: 12px 0 2px; }
.meter { height: 7px; background: var(--soft); border-radius: 9px; overflow: hidden; margin-top: 7px; }
.meter i { display: block; height: 100%; background: var(--ink); border-radius: 9px; }
.meter.g i { background: var(--ok); }
.thumb { width: 58px; height: 58px; border-radius: 10px; object-fit: cover; background: #606060; flex: none; display: block; }
.thumb.c { display: flex; align-items: center; justify-content: center; border: 1px solid var(--line); background: var(--soft); }
.thumb.sm { width: 42px; height: 42px; }
.thumb.big { width: 76px; height: 76px; }
.itm { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--line); }
.itm:last-child { border-bottom: 0; }
.szchips { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 6px; }
.szchips span { font: 700 11.5px/1 var(--bd); padding: 5px 7px; border-radius: 6px; background: var(--soft); font-variant-numeric: tabular-nums; }
.szchips span.warn { background: var(--warnbg); color: var(--warn); } .szchips span.bad { background: var(--redbg); color: var(--red); }
.empty { border: 2px dashed var(--line); border-radius: 14px; padding: 22px 16px; text-align: center; color: var(--mut); display: block; }
.empty.sm { padding: 14px; }
.tw { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.t { border-collapse: collapse; width: 100%; font-size: 13.5px; }
table.t th { background: var(--ink); color: var(--bg); text-align: left; padding: 8px 10px; font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
table.t td { padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.t td.r, table.t th.r { text-align: right; font-variant-numeric: tabular-nums; }
.warnbox, .redbox, .okbox { border-radius: 10px; padding: 10px 12px; font-size: 13.5px; font-weight: 600; }
.warnbox { background: var(--warnbg); color: var(--warn); } .redbox { background: var(--redbg); color: var(--red); } .okbox { background: var(--okbg); color: var(--ok); }
.alert { display: flex; gap: 10px; align-items: center; width: 100%; text-align: left; background: var(--card); border: 1.5px solid var(--line); border-radius: 12px; padding: 11px 12px; font-weight: 600; font-size: 13.5px; cursor: pointer; color: var(--ink); }
.alert span { flex: 1; min-width: 0; }
.alert.bad { border-color: var(--red); color: var(--red); } .alert.warn { border-color: var(--warn); }
.steps { display: flex; gap: 4px; }
.steps i { flex: 1; height: 6px; border-radius: 4px; background: var(--line); }
.steps i.d { background: var(--ink); } .steps i.n { background: var(--y); outline: 1px solid var(--ink); }
.qa .btn { min-height: 52px; }

/* ----- kasir ----- */
.pgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 560px) { .pgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.prod { display: flex; flex-direction: column; gap: 6px; text-align: left; background: var(--card); border: 1.5px solid var(--line); border-radius: 14px; padding: 12px; cursor: pointer; min-width: 0; color: var(--ink); align-items: flex-start; }
.prod:active { border-color: var(--ink); }
.prod .n { font-weight: 700; overflow-wrap: anywhere; line-height: 1.25; }
.prod .p { font: 800 16px/1 var(--hd); font-variant-numeric: tabular-nums; }
.cartpanel { display: none; }
.cartbar { position: fixed; left: 0; right: 0; bottom: calc(var(--navh) + var(--sab)); z-index: 39; padding: 0 max(12px, env(safe-area-inset-left, 0px)) 10px; }
.cartbar button { width: 100%; display: flex; justify-content: space-between; align-items: center; background: var(--y); color: var(--yink); border: 2px solid var(--ink); border-radius: 14px; padding: 13px 16px; font-weight: 800; font-size: 15px; cursor: pointer; box-shadow: 0 6px 18px rgba(0, 0, 0, .25); }
.cartbar button span { display: inline-flex; align-items: center; gap: 6px; }
pre.struk { white-space: pre-wrap; margin: 0; font: 13px/1.5 ui-monospace, Menlo, Consolas, monospace; background: var(--card); padding: 12px; border-radius: 12px; border: 1px solid var(--line); overflow-x: auto; }

/* ----- order ----- */
.dhead { display: flex; align-items: center; gap: 10px; margin-bottom: 2px; }
.dhead b { font: 800 17px/1.2 var(--hd); }
.dgrid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
.dimg { width: 100%; border-radius: 10px; background: #606060; display: block; max-height: 280px; object-fit: contain; }
.dimgbtn { padding: 0; border: 0; background: none; cursor: zoom-in; display: block; width: 100%; }
.dcard { display: flex; flex-direction: column; gap: 10px; }
.inv { background: #fff; color: #0B0B0B; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.inv .c { padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; }
.inv .tot { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; }
.inv .tot.big { font: 800 18px/1.2 var(--hd); border-top: 2px solid #0B0B0B; margin-top: 4px; padding-top: 8px; }
.inv .tot.dp { background: #FFD400; padding: 8px 10px; border-radius: 8px; font-weight: 800; }
.inv .bad-t { color: #D10A00; } .inv .ok-t { color: #17703A; }
.lbimg, .fullimg { width: 100%; border-radius: 10px; border: 1px solid var(--line); display: block; background: #fff; }
.stickybar { position: sticky; bottom: calc(var(--navh) + var(--sab)); z-index: 3; padding: 10px 0; background: var(--bg); border-top: 1px solid var(--line); }
.qr { display: flex; justify-content: center; padding: 8px; }
.qr img { width: 220px; height: 220px; image-rendering: pixelated; border-radius: 8px; background: #fff; }
.menu { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.mitem { display: flex; gap: 12px; align-items: center; text-decoration: none; color: var(--ink); }
.mitem .ic { width: 24px; height: 24px; }
@media (min-width: 640px) { .menu { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ----- sheet ----- */
#sheetWrap { position: fixed; inset: 0; z-index: 70; background: rgba(0, 0, 0, .55); display: flex; align-items: flex-end; justify-content: center; }
#sheet { background: var(--bg); width: 100%; max-width: 680px; max-height: 94vh; max-height: 94dvh; border-radius: 20px 20px 0 0; display: flex; flex-direction: column; padding-bottom: var(--sab); box-shadow: 0 -10px 40px rgba(0, 0, 0, .3); }
#sheetBody { overflow: auto; padding: 14px max(16px, env(safe-area-inset-left, 0px)) 22px; display: flex; flex-direction: column; gap: 14px; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.grab { width: 44px; height: 5px; border-radius: 9px; background: var(--line); margin: 8px auto 0; flex: none; }
.shead { display: flex; align-items: flex-start; gap: 10px; position: sticky; top: -14px; background: var(--bg); padding: 4px 0 6px; z-index: 2; }
@media (min-width: 700px) {
  #sheetWrap { align-items: center; padding: 24px; }
  #sheet { border-radius: 18px; max-height: 88vh; }
  #sheet.wide { max-width: 900px; }
  .grab { display: none; }
}
#toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--navh) + var(--sab) + 80px); z-index: 90; background: var(--ink); color: var(--bg); padding: 11px 16px; border-radius: 12px; font-weight: 600; font-size: 14px; max-width: min(92vw, 520px); box-shadow: 0 8px 24px rgba(0, 0, 0, .3); text-align: center; }
#toast.err { background: var(--red); color: #fff; }
body.lock #toast { top: calc(var(--toph) + var(--sat) + 10px); bottom: auto; }

/* ----- setup ----- */
.setup { display: flex; flex-direction: column; gap: 14px; max-width: 640px; margin: 0 auto; }
.setup-logo { display: none; }
.choice { display: flex; gap: 12px; align-items: center; text-align: left; cursor: pointer; width: 100%; color: var(--ink); font: inherit; }
.choice .ic { width: 26px; height: 26px; }
.wstep.dim { opacity: .55; }
.wstep.done .stepn { background: var(--ok); color: #fff; }
.stepn { width: 26px; height: 26px; border-radius: 50%; background: var(--ink); color: var(--bg); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; flex: none; }
.steps-ol { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
pre.rules { max-height: 260px; overflow: auto; font: 11.5px/1.45 ui-monospace, Menlo, Consolas, monospace; background: var(--soft); padding: 10px; border-radius: 10px; white-space: pre; margin: 0; }
.splash { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; min-height: 50vh; }
.splash img { filter: invert(var(--inv, 1)); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .splash img { --inv: 0; } }
:root[data-theme="dark"] .splash img { --inv: 0; }

/* ----- layar lebar: iPad mendatar & laptop ----- */
@media (min-width: 1000px) {
  :root { --navh: 0px; }
  .shell { display: grid; grid-template-columns: 96px minmax(0, 1fr); }
  #nav { position: sticky; top: calc(var(--toph) + var(--sat)); height: calc(100vh - var(--toph) - var(--sat)); flex-direction: column; justify-content: flex-start; padding: 12px 0; gap: 4px; }
  #nav a { flex: none; min-height: 68px; font-size: 11.5px; }
  body.noshell .shell { display: block; }
  .wrap { max-width: 1180px; padding: 22px 28px 48px; }
  .kasir { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 20px; align-items: start; }
  .cartpanel { display: flex; flex-direction: column; gap: 12px; position: sticky; top: calc(var(--toph) + var(--sat) + 16px); max-height: calc(100vh - var(--toph) - 40px); overflow: auto; }
  .cartbar { display: none; }
  .pgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .dgrid { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: start; }
  .dgrid > .stack:last-child { position: sticky; top: calc(var(--toph) + var(--sat) + 16px); }
  .olist { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 24px; }
  .olist .li:nth-last-child(2):nth-child(odd) { border-bottom: 0; }
  .editor { max-width: 860px; }
  .stickybar { bottom: 0; }
  #toast { bottom: 28px; }
  .menu { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1400px) { .pgrid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
@media print { #top, #nav, #banners, .cartbar { display: none !important; } }
