/* Coffee Y'all — online ordering (order.coffeeyallespresso.com).
   Phone first. No web fonts (the order site's Content-Security-Policy allows
   only files from this site), no inline styles: pages switch classes and the
   hidden attribute. Tap targets are 48px or more and inputs 16px or more
   (smaller makes iPhones zoom in). */
:root {
  --dark: #1c1c1e;
  --cream: #f6f1ea;
  --gold: #bc8d4b;
  --gold-text: #8a6425;
  --ink-soft: #55504a;
  --line: #e7dfd3;
  --ok: #1e7a3c;
  --ok-bg: #e3f4e8;
  --warn: #8a5300;
  --warn-bg: #fff1d6;
  --info: #1f5f99;
  --info-bg: #e3eefa;
  --bad: #a8261b;
  --bad-bg: #fde8e6;
  --radius: 18px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
html.locked, html.locked body { overflow: hidden; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.5;
  color: var(--dark);
  background: var(--cream);
}
img { max-width: 100%; display: block; }
a { color: var(--gold-text); }
button, input { font-family: var(--font); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.top {
  background: var(--dark);
  color: #fff;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.top img { width: 42px; height: 42px; border-radius: 10px; }
.top .brand { font-weight: 800; letter-spacing: 1px; text-transform: uppercase; font-size: 15px; }
.top .brand small { display: block; font-weight: 600; letter-spacing: 3px; font-size: 10px; color: var(--gold); }

main { max-width: 560px; margin: 0 auto; padding: 28px 20px 48px; }
h1 {
  font-size: clamp(30px, 9vw, 44px);
  line-height: 1.1;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.5px;
  margin: 8px 0 14px;
}
.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold-text);
}
.card {
  background: #fff;
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: 0 4px 18px rgba(28, 28, 30, .08);
  margin: 22px 0;
}
.card p { margin: 0 0 12px; color: var(--ink-soft); }
.card p:last-child { margin-bottom: 0; }
.card.staff { border: 2px dashed var(--gold); }

.btn {
  display: inline-block;
  font-family: var(--font);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  text-decoration: none;
  padding: 15px 28px;
  border-radius: 999px;
  border: 3px solid var(--gold);
  background: var(--gold);
  color: var(--dark);
}
.btn.dark { background: var(--dark); border-color: var(--dark); color: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }

/* the full-width 56px button ("Find my stand", "Start") */
.btn-big {
  display: block;
  width: 100%;
  min-height: 56px;
  margin: 14px 0 8px;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  border: 0;
  border-radius: 999px;
  background: var(--gold);
  color: var(--dark);
  cursor: pointer;
}
.btn-plain {
  min-height: 48px;
  padding: 8px 14px;
  font-size: 16px;
  font-weight: 700;
  color: var(--gold-text);
  background: none;
  border: 0;
  cursor: pointer;
}

.foot { text-align: center; font-size: 14px; color: var(--ink-soft); padding: 8px 20px 30px; }

.lede { font-size: 19px; font-weight: 600; margin: 0 0 10px; }
.drive { color: var(--ink-soft); margin: 0 0 6px; }
.small { font-size: 15px; }
.muted { color: var(--ink-soft); }
.msg { background: var(--info-bg); color: var(--info); border-radius: 12px; padding: 12px 14px; margin: 12px 0; }
.loading { color: var(--ink-soft); }
.preview-note {
  background: var(--warn-bg);
  color: var(--warn);
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 15px;
  font-weight: 600;
  margin: 10px 0;
}

/* ---------- "Where are you?": the stand cards ---------- */
.stands { list-style: none; margin: 18px 0 0; padding: 0; }
.stands li { margin: 0 0 14px; }
.stand {
  display: block;
  width: 100%;
  text-align: left;
  min-height: 56px;
  padding: 18px;
  font-size: 17px;
  color: var(--dark);
  background: #fff;
  border: 2px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 4px 18px rgba(28, 28, 30, .06);
  cursor: pointer;
}
.stand > span { display: block; }
.stand .stand-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.stand-name { font-size: 22px; font-weight: 800; }
.stand-dist { font-weight: 800; color: var(--ink-soft); white-space: nowrap; }
.stand-dist.near { color: var(--ok); }
.stand-addr, .stand-hours { color: var(--ink-soft); font-size: 15px; }
.chip-state {
  display: inline-block !important;
  margin-top: 8px;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  background: #eee;
  color: var(--ink-soft);
}
.chip-state.open { background: var(--ok-bg); color: var(--ok); }
.chip-state.paused, .chip-state.last_orders { background: var(--warn-bg); color: var(--warn); }

/* ---------- Screen 2: a stand's menu ---------- */
.bar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-areas: "back name cart" "pill pill pill";
  align-items: center;
  gap: 4px 8px;
  margin: -28px -20px 12px;
  padding: 8px 12px;
  background: var(--cream);
  border-bottom: 1px solid var(--line);
}
.bar-back {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  min-height: 48px;
  font-size: 30px;
  font-weight: 700;
  text-decoration: none;
  color: var(--dark);
}
.bar-stand {
  flex: 1 1 auto;
  margin: 0;
  font-size: 20px;
  letter-spacing: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pill, .cart-btn {
  min-height: 48px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  border: 0;
  cursor: pointer;
}
.pill { grid-area: pill; justify-self: start; max-width: 100%; line-height: 1.2; text-align: left; }
.bar-back { grid-area: back; }
.bar-stand { grid-area: name; min-width: 0; }
.cart-btn { grid-area: cart; }
.pill.off { background: #e6e3de; color: var(--ink-soft); }
.pill.fix { background: var(--info-bg); color: var(--info); }
.pill.ok { background: var(--ok-bg); color: var(--ok); }
.pill.warn { background: var(--warn-bg); color: var(--warn); }
.cart-btn { flex: 0 0 auto; background: var(--dark); color: #fff; }

.banner {
  margin: 8px 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--info-bg);
  color: var(--info);
  font-weight: 600;
}
.banner.warn { background: var(--warn-bg); color: var(--warn); }

.chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 6px 0 10px;
  scrollbar-width: none;
}
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto;
  min-height: 48px;
  padding: 8px 16px;
  font-size: 15px;
  font-weight: 700;
  border-radius: 999px;
  border: 2px solid var(--line);
  background: #fff;
  color: var(--dark);
  cursor: pointer;
}
.search input, .filter, .note-input {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  font-size: 16px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.msec { scroll-margin-top: 130px; margin-top: 22px; }
.msec h2 { font-size: 24px; font-weight: 800; text-transform: uppercase; margin: 0 0 6px; }
.msec h3 { font-size: 19px; font-weight: 800; margin: 18px 0 6px; }
.msec.secret > h2 { color: var(--gold-text); }
.snote { color: var(--ink-soft); margin: 0 0 8px; }
.drinks { list-style: none; margin: 0; padding: 0; }
.drinks li { border-bottom: 1px solid var(--line); }
.drink {
  display: block;
  width: 100%;
  min-height: 56px;
  padding: 12px 4px;
  text-align: left;
  font-size: 17px;
  color: var(--dark);
  background: none;
  border: 0;
  cursor: pointer;
}
.drink > span { display: block; }
.d-top { display: flex !important; justify-content: space-between; gap: 12px; }
.d-name { font-weight: 700; }
.d-sizes { color: var(--ink-soft); font-size: 15px; white-space: nowrap; }
.d-desc { color: var(--ink-soft); font-size: 15px; }
.drink.soldout { opacity: .5; cursor: default; }
.d-sold { color: var(--bad); font-weight: 700; font-size: 14px; }
.none { color: var(--ink-soft); }
.pay { margin-top: 28px; font-weight: 700; text-align: center; }

/* ---------- bottom sheets: the drink sheet, the cart, help ---------- */
.sheet {
  position: fixed;
  /* the four sides, not `inset`: Safari before iOS 14.5 ignores inset, and
     the sheet would sit off the bottom of the page */
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 20;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: rgba(28, 28, 30, .55);
}
.sheet-panel {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 600px;
  height: 94vh;
  height: 94dvh;
  background: var(--cream);
  border-radius: 20px 20px 0 0;
  box-shadow: 0 -8px 30px rgba(0, 0, 0, .25);
}
.sheet.small .sheet-panel { height: auto; max-height: 90vh; }
.sheet-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 12px 8px 20px;
  border-bottom: 1px solid var(--line);
}
.sheet-head h2 { flex: 1 1 auto; margin: 0; font-size: 22px; font-weight: 800; }
.sheet-head h2:focus { outline: none; }
.x {
  min-width: 48px;
  min-height: 48px;
  font-size: 28px;
  line-height: 1;
  background: none;
  border: 0;
  color: var(--dark);
  cursor: pointer;
}
.sheet-body { flex: 1 1 auto; overflow-y: auto; padding: 14px 20px 24px; -webkit-overflow-scrolling: touch; }
.sheet.small .sheet-body h2 { font-size: 22px; margin: 4px 0 10px; }
.sheet-body h3 { font-size: 18px; margin: 16px 0 6px; }
.sheet-body ol { padding-left: 22px; }
.sheet-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: #fff;
}
.desc { color: var(--ink-soft); margin: 0 0 8px; }

.grp { margin: 0 0 20px; }
.grp-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.grp-head h3 { margin: 0; font-size: 18px; font-weight: 800; }
.tag-req, .tag-opt, .grp-count { font-size: 13px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; }
.tag-req { color: var(--bad); }
.tag-opt, .grp-count { color: var(--ink-soft); }
.grp-count { margin-left: auto; }
.help, .size-note, .picked { font-size: 15px; color: var(--ink-soft); margin: 4px 0 8px; }
.size-note { color: var(--warn); }
.picked { color: var(--dark); font-weight: 600; }

.seg { display: flex; gap: 6px; flex-wrap: wrap; }
.seg-btn, .opt {
  min-height: 48px;
  padding: 8px 16px;
  font-size: 16px;
  font-weight: 700;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--dark);
  cursor: pointer;
}
.seg-btn { flex: 1 1 0; min-width: 64px; }
.opts { display: flex; flex-wrap: wrap; gap: 8px; }
.chips-opts .opt { border-radius: 999px; font-weight: 600; }
.opt-head { width: 100%; margin: 10px 0 0; font-size: 14px; text-transform: uppercase; letter-spacing: 1px; color: var(--gold-text); }
.seg-btn[aria-pressed="true"], .opt[aria-pressed="true"] {
  background: var(--dark);
  border-color: var(--dark);
  color: #fff;
}
.seg-btn:disabled, .opt:disabled { opacity: .45; cursor: not-allowed; }
.so { font-weight: 600; font-size: 13px; }
.filter { margin: 0 0 6px; }

.count-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; }
.count-name { font-weight: 700; }
.stepper, .qty { display: flex; align-items: center; gap: 4px; }
.step {
  min-width: 48px;
  min-height: 48px;
  font-size: 24px;
  font-weight: 700;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--dark);
  cursor: pointer;
}
.step:disabled { opacity: .4; cursor: not-allowed; }
.count-n, .qty-n { min-width: 32px; text-align: center; font-size: 20px; font-weight: 800; }
.note-label { display: block; font-weight: 800; margin-bottom: 6px; }
.note-left { display: block; text-align: right; font-size: 13px; color: var(--ink-soft); }

.btn-add {
  flex: 1 1 auto;
  min-height: 56px;
  padding: 10px 16px;
  font-size: 17px;
  font-weight: 800;
  border: 0;
  border-radius: 999px;
  background: var(--gold);
  color: var(--dark);
  cursor: pointer;
}
.btn-add.blocked { background: #e6e3de; color: var(--ink-soft); }

/* the cart */
.cart-lines { list-style: none; margin: 0; padding: 0; }
.cart-line { padding: 12px 0; border-bottom: 1px solid var(--line); }
.cart-line p { margin: 0 0 4px; }
.cl-text { font-weight: 700; }
.cl-note { color: var(--ink-soft); font-style: italic; }
.cl-flag { color: var(--bad); background: var(--bad-bg); border-radius: 10px; padding: 8px 12px; font-weight: 600; }
.cl-actions { display: flex; gap: 8px; }
.cart-empty { color: var(--ink-soft); }
.cart-sum { font-size: 18px; font-weight: 700; margin: 16px 0 6px; }
.cart-note { color: var(--ink-soft); }
.card.preview { border: 2px dashed var(--gold); }

/* ---------- the walk test ---------- */
.walk { list-style: none; margin: 0; padding: 0; }
.walk .card h2 { margin: 0 0 6px; font-size: 22px; }
.walk-verdict { font-size: 40px; font-weight: 900; margin: 0 0 4px !important; }
.walk-verdict.in { color: var(--ok) !important; }
.walk-verdict.far { color: var(--bad) !important; }
.walk-verdict.vague { color: var(--warn) !important; }

/* ---------- the self-test ---------- */
.st-summary { font-size: 22px; font-weight: 800; padding: 14px 16px; border-radius: 12px; background: #eee; }
.st-summary.pass { background: var(--ok-bg); color: var(--ok); }
.st-summary.fail { background: var(--bad-bg); color: var(--bad); }
.st-results { padding-left: 22px; font-size: 14px; }
.st-results li { margin: 2px 0; word-break: break-word; }
.st-results li.fail { color: var(--bad); font-weight: 700; }
.st-results li.pass { color: var(--ink-soft); }
.st-detail { font-weight: 400; }

@media (min-width: 600px) {
  .sheet { align-items: center; }
  .sheet-panel { height: 88vh; border-radius: 20px; }
}
