:root {
  --bg: #0a1f29;         /* deep navy (logo cube) */
  --surface: #103038;    /* navy-teal surface */
  --ink: #eaf6f4;        /* soft white */
  --muted: #8fb6b6;      /* muted teal-grey */
  --line: #1d3f49;       /* border */
  --brand: #23b3ac;      /* teal (logo meander) */
  --brand-2: #1a938d;    /* deeper teal */
  --gold: #23b3ac;       /* brand accent = teal */
  --gold-ink: #042028;   /* dark navy text on teal buttons */
  --gold-soft: #0e2c33;  /* dark teal tint (placeholders / image bg) */
  --accent: #f2c94c;     /* yellow accent (logo top) */
  --ok: #2fa35a;
  --warn: #e0a63a;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 10px 28px rgba(0,0,0,.45);
  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --hdr-h: 76px;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; }
body { font-family: var(--sans); background: var(--bg); color: var(--ink); line-height: 1.45; }
.muted { color: var(--muted); }
.center { text-align: center; }

/* ---------- Header ---------- */
header.topbar {
  position: sticky; top: 0; z-index: 30; height: var(--hdr-h);
  background: #06212c; color: var(--gold);
  padding: 0 18px; display: flex; align-items: center; justify-content: space-between;
  border-bottom: 2px solid var(--gold);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand .logo-img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 2px var(--gold); }
.brand-name { font-family: var(--serif); font-size: 25px; font-weight: 600; letter-spacing: .01em; line-height: 1.05; color: var(--gold); }
.brand-tag { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; opacity: .9; margin-top: 3px; color: var(--accent); }
.table-badge {
  background: rgba(35,179,172,.14); border: 1px solid rgba(35,179,172,.45); color: var(--gold);
  padding: 7px 13px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; text-align: center; max-width: 42vw;
}

/* ---------- Trading banner ---------- */
.tradebar { text-align: center; font-weight: 700; font-size: 14.5px; padding: 11px 16px; line-height: 1.35; }
.tradebar.open { background: #14251a; color: #86e2a6; border-bottom: 1px solid #276b41; }
.tradebar.open b { color: #b6f0c9; }
.tradebar.closed { background: #3a1111; color: #ffb4a0; border-bottom: 1px solid #7a2418; }
.tradebar.closed b { color: #fff; }

/* ---------- Layout ---------- */
.shell { max-width: 1200px; margin: 0 auto; padding: 22px; display: block; }

/* ---------- Category tabs ---------- */
.tabs {
  position: sticky; top: var(--hdr-h); z-index: 15; background: var(--bg);
  display: flex; gap: 6px; overflow-x: auto; padding: 12px 2px; margin-bottom: 6px;
  -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
  flex: 0 0 auto; border: 1px solid var(--line); background: var(--surface); color: var(--muted);
  padding: 9px 18px; font-family: var(--sans); font-size: 14px; font-weight: 600;
  cursor: pointer; white-space: nowrap; border-radius: 999px; transition: all .15s;
}
.tab:hover { color: var(--ink); border-color: var(--gold); }
.tab.active { color: var(--gold-ink); background: var(--gold); border-color: var(--gold); }

.section-title { font-family: var(--serif); font-weight: 600; font-size: 26px; margin: 6px 2px 16px; }
.section-title small { display: block; font-family: var(--sans); font-size: 13px; font-weight: 400; color: var(--muted); margin-top: 3px; letter-spacing: .02em; }

/* ---------- Item cards ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: 16px;
  overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow); transition: transform .15s, border-color .15s;
}
.card:hover { transform: translateY(-2px); border-color: var(--gold); }
.card .imgwrap { position: relative; width: 100%; padding-top: 74%; overflow: hidden; background: #000; }
.card .imgwrap img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.card .imgwrap .ph {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-family: var(--serif); font-size: 44px; font-weight: 600; color: var(--gold); background: var(--gold-soft);
}
.card .imgwrap.noimg img { display: none; }
.card .body { padding: 12px 13px 14px; display: flex; flex-direction: column; flex: 1; }
.card .name { font-family: var(--serif); font-weight: 600; font-size: 16.5px; line-height: 1.2; color: var(--ink); }
.card .desc { color: var(--muted); font-size: 12.5px; margin-top: 5px; flex: 1; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card .foot { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; gap: 8px; }
.card .price { font-family: var(--serif); font-weight: 600; font-size: 17px; color: var(--gold); }

button.add {
  border: none; background: var(--gold); color: var(--gold-ink); border-radius: 10px;
  padding: 9px 16px; font-family: var(--sans); font-weight: 800; cursor: pointer; font-size: 14px; transition: background .15s;
}
button.add:hover { background: var(--brand-2); }
.qty { display: flex; align-items: center; gap: 8px; }
.qty button { width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--gold); background: transparent; font-size: 18px; line-height: 1; cursor: pointer; color: var(--gold); }
.qty button:hover { background: var(--gold-soft); }
.qty .n { min-width: 14px; text-align: center; font-weight: 700; color: var(--ink); }

/* ---------- Order summary panel ---------- */
.summary { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); padding: 20px; }
.close-sheet { display: none; position: absolute; top: 12px; right: 14px; border: none; background: transparent; font-size: 20px; color: var(--muted); cursor: pointer; }
.panel-title { font-family: var(--serif); font-weight: 600; font-size: 21px; margin: 0 0 14px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.empty-cart { color: var(--muted); text-align: center; padding: 24px 8px; font-size: 14px; }
.empty-cart span { color: var(--muted); opacity: .8; }
.cart-line { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.cart-line .cl-info { flex: 1; min-width: 0; }
.cart-line .cl-name { font-weight: 600; font-size: 15px; }
.cart-line .cl-price { color: var(--muted); font-size: 13px; margin-top: 2px; }
.cart-line .cl-qty { display: flex; align-items: center; gap: 8px; }
.cart-line .cl-qty button { width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--line); background: #fff; font-size: 16px; cursor: pointer; color: var(--brand); }
.cart-line .cl-qty .n { min-width: 14px; text-align: center; font-weight: 700; font-size: 14px; }
.name-field { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 12px; font: inherit; font-size: 15px; margin-top: 14px; background: #0c2830; color: var(--ink); }
.name-field::placeholder, .note::placeholder { color: #6f9a9a; }
.name-field:focus { outline: none; border-color: var(--gold); }
.note { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 11px; font: inherit; font-size: 14px; margin-top: 10px; resize: vertical; background: #0c2830; color: var(--ink); }
.note:focus { outline: none; border-color: var(--gold); }
.sum-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 16px; font-family: var(--serif); }
.sum-total span:first-child { font-size: 15px; color: var(--muted); }
.sum-total span:last-child { font-size: 24px; font-weight: 600; color: var(--gold); }
.pay-hint { font-size: 12.5px; color: var(--muted); margin-top: 10px; text-align: center; }
.place { width: 100%; border: none; background: var(--gold); color: var(--gold-ink); padding: 15px; border-radius: 12px; font-family: var(--sans); font-size: 16px; font-weight: 800; margin-top: 12px; cursor: pointer; transition: background .15s; }
.place:hover { background: var(--brand-2); }
.place:disabled { opacity: .6; cursor: default; }
.place.paycounter { background: transparent; color: var(--gold); border: 1px solid var(--gold); margin-top: 8px; }
.place.paycounter:hover { background: var(--gold-soft); }

/* ---------- Mobile cart bar ---------- */
.cartbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 45;
  background: #06212c; color: var(--gold); padding: 14px 18px; border-top: 2px solid var(--gold);
  display: none; align-items: center; justify-content: space-between;
  box-shadow: 0 -6px 24px rgba(0,0,0,.5); transform: translateY(120%); transition: transform .2s;
}
.cartbar.show { transform: translateY(0); }
.cartbar .lbl { font-weight: 700; }
.cartbar button { border: none; background: var(--gold); color: var(--gold-ink); font-weight: 800; padding: 11px 20px; border-radius: 10px; font-family: var(--sans); }
.backdrop { position: fixed; inset: 0; background: rgba(20,14,12,.5); z-index: 48; display: none; }
.backdrop.show { display: block; }

/* ---------- Desktop: two columns ---------- */
@media (min-width: 900px) {
  .shell { display: grid; grid-template-columns: 340px 1fr; gap: 28px; align-items: start; }
  .summary { position: sticky; top: calc(var(--hdr-h) + 22px); order: 0; }
  .menu { order: 1; min-width: 0; }
  .cartbar { display: none !important; }
  .backdrop { display: none !important; }
}

/* ---------- Mobile: summary becomes a bottom sheet ---------- */
@media (max-width: 899px) {
  .shell { padding: 12px 12px 90px; }
  .summary {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; margin: 0;
    border-radius: 18px 18px 0 0; max-height: 82vh; overflow: auto;
    transform: translateY(120%); transition: transform .25s; max-width: 620px; left: 50%; translate: -50% 0;
  }
  .summary.show { transform: translateY(0); }
  .close-sheet { display: block; }
  .cartbar { display: flex; }
  .tabs { top: var(--hdr-h); }
}

/* ---------- Confirmation (big order number) ---------- */
.confirm { text-align: center; padding: 54px 20px; max-width: 480px; margin: 0 auto; }
.confirm .tick {
  width: 72px; height: 72px; margin: 0 auto 6px; border-radius: 50%;
  background: var(--ok); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 38px;
}
.confirm h2 { font-family: var(--serif); font-weight: 600; font-size: 26px; margin: 12px 0 4px; }
.confirm .ordernum {
  margin: 22px auto; background: var(--surface); border: 3px solid var(--gold); border-radius: 22px;
  padding: 22px 16px; max-width: 320px; box-shadow: var(--shadow);
}
.confirm .ordernum .lbl { font-size: 14px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.confirm .ordernum .num { font-family: var(--serif); font-weight: 600; font-size: 88px; line-height: 1; color: var(--gold); margin-top: 6px; }
.confirm .pay-callout { background: #3a1111; border: 2px solid #e0533a; border-radius: 16px; padding: 16px 18px; margin: 0 auto; max-width: 400px; }
.confirm .pay-callout .pc-title { font-family: var(--serif); font-weight: 600; font-size: 18px; color: #ffb4a0; line-height: 1.3; }
.confirm .pay-callout .pc-amt { margin-top: 8px; font-size: 15px; color: #ffd9cf; }
.confirm .pay-callout .pc-amt b { color: #fff; font-size: 18px; }
.confirm .steps { text-align: left; background: var(--gold-soft); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; margin: 18px auto 0; max-width: 400px; color: var(--ink); }
.confirm .steps li { margin: 8px 0; font-size: 14px; }
