:root { --brand: #0f766e; --bg: #eef1f0; --card: #fff; --text: #1d2526; --muted: #66706f; --line: #dde3e1; --ok: #15803d; --no: #b45309; }
@media (prefers-color-scheme: dark) { :root { --bg: #121819; --card: #1b2324; --text: #e6ecea; --muted: #9aa5a3; --line: #2b3536; } }
* { box-sizing: border-box; }
body { margin: 0; font: 15px/1.4 -apple-system, system-ui, "Segoe UI", Roboto, sans-serif; background: var(--bg); color: var(--text); }
.top { position: sticky; top: 0; z-index: 2; display: flex; gap: 10px; align-items: center; padding: 10px 16px; padding-top: max(10px, env(safe-area-inset-top)); background: var(--card); border-bottom: 1px solid var(--line); }
.logo { width: 36px; height: 36px; border-radius: 9px; background: var(--brand); padding: 6px; }
h1 { font-size: 17px; margin: 0; }
small { color: var(--muted); font-size: 12px; }
main { max-width: 640px; margin: 0 auto; padding: 12px 16px 40px; }
.search input { width: 100%; padding: 11px 12px; font-size: 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); color: var(--text); }
.chips { display: flex; gap: 6px; overflow-x: auto; padding: 10px 0 4px; scrollbar-width: none; }
.chips button { flex: none; border: 1px solid var(--line); background: var(--card); color: var(--text); border-radius: 99px; padding: 6px 12px; font-size: 14px; }
.chips button.on { background: var(--brand); color: #fff; border-color: var(--brand); }
.info { color: var(--muted); font-size: 13px; margin: 6px 0; }
.grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.item { background: var(--card); border-radius: 12px; overflow: hidden; display: flex; flex-direction: column; border: 1px solid var(--line); }
.ph { position: relative; overflow: hidden; aspect-ratio: 4 / 3; background: #e4e9e7; display: grid; place-items: center; color: #8a9593; font-size: 28px; font-weight: 700; }
.ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.body { padding: 8px 10px 10px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.nm { font-weight: 600; font-size: 14px; }
.pr { font-weight: 700; font-size: 16px; }
.st { font-size: 12px; font-weight: 600; }
.st.ok { color: var(--ok); } .st.no { color: var(--no); }
.wa { margin-top: auto; display: block; text-align: center; text-decoration: none; background: var(--brand); color: #fff; border-radius: 9px; padding: 8px; font-weight: 600; font-size: 14px; }
.wa.off { background: transparent; color: var(--brand); border: 1px solid var(--brand); }
.note { color: var(--muted); font-size: 12px; text-align: center; margin-top: 16px; }
.empty { grid-column: 1 / -1; text-align: center; color: var(--muted); padding: 30px 0; }
main { padding-bottom: 90px; }
button.wa { border: 0; width: 100%; font: inherit; font-weight: 600; cursor: pointer; }
.qty { margin-top: auto; display: flex; align-items: center; justify-content: space-between; border: 1px solid var(--brand); border-radius: 9px; overflow: hidden; }
.qty button { border: 0; background: var(--brand); color: #fff; width: 40px; height: 36px; font-size: 20px; font-weight: 700; }
.qty b { font-size: 16px; }
.bar { position: fixed; left: 12px; right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); max-width: 616px; margin: 0 auto; z-index: 3; display: flex; justify-content: space-between; align-items: center;
  border: 0; border-radius: 12px; padding: 14px 16px; background: var(--brand); color: #fff; font: inherit; font-size: 15px; box-shadow: 0 6px 20px rgba(0,0,0,.2); }
.bar[hidden], .sheet[hidden] { display: none; }
.bar .go { font-weight: 700; }
.sheet { position: fixed; inset: 0; z-index: 5; background: rgba(0,0,0,.45); display: flex; align-items: flex-end; justify-content: center; }
.sheet-in { background: var(--card); width: 100%; max-width: 640px; max-height: 88vh; overflow-y: auto; border-radius: 16px 16px 0 0; padding: 16px 16px max(16px, env(safe-area-inset-bottom)); }
.sheet-in h2 { margin: 0 0 8px; font-size: 18px; }
.olist { list-style: none; margin: 0; padding: 0; }
.olist li { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.olist small { display: block; color: var(--muted); }
.otot { display: flex; justify-content: space-between; padding: 10px 0; font-size: 16px; }
.sheet-in label { display: block; font-size: 13px; color: var(--muted); margin: 8px 0 4px; }
.sheet-in input, .sheet-in textarea { width: 100%; padding: 10px 11px; font: inherit; font-size: 16px; border: 1px solid var(--line); border-radius: 9px; background: var(--card); color: var(--text); }
.sheet-in .err { border-color: #dc2626; }
.seg { display: flex; gap: 6px; margin: 12px 0 4px; }
.seg button { flex: 1; padding: 10px; border: 1px solid var(--line); border-radius: 9px; background: var(--card); color: var(--text); font: inherit; font-weight: 600; }
.seg button.on { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 12%, var(--card)); color: var(--brand); }
.wa.big { margin-top: 14px; padding: 13px; font-size: 16px; }
.link { display: block; margin: 10px auto 0; border: 0; background: none; color: var(--muted); font: inherit; text-decoration: underline; }
.empty a { color: var(--brand); }
.closed { text-align: center; padding: 40px 8px; }
.closed h2 { font-size: 20px; margin: 0 0 8px; }
.closed p { color: var(--muted); margin: 0 0 18px; }
.closed .wa { display: block; max-width: 320px; margin: 0 auto; }
