/* 方睿小吃 — 設計系統
   色票取自店內菜單：深咖啡標題、酒紅價格、米白底
   字階 13 / 15 / 17 / 22 / 30；間距 4 / 8 / 16 / 24 / 40 */
:root {
  --rice: #fbf7f0;
  --paper: #ffffff;
  --ink: #2b1b12;
  --muted: #6b5a4e;
  --line: #e6dccd;
  --red: #a31f37;
  --red-soft: #f6e4e6;
  --ok: #2f6b45;
  --ok-soft: #e5f1e8;
  --radius: 10px;
  --serif: "Noto Serif TC", "Songti TC", serif;
  --sans: "Noto Sans TC", "PingFang TC", "Heiti TC", sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--rice);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.7;
}
a { color: inherit; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.3; margin: 0; text-wrap: balance; }

/* 版頭與導覽 */
.top {
  background: var(--ink);
  color: var(--rice);
  position: sticky; top: 0; z-index: 10;
}
.top-inner {
  max-width: 720px; margin: 0 auto; padding: 0 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  min-height: 56px;
}
.brand { font-family: var(--serif); font-weight: 700; font-size: 19px; text-decoration: none; letter-spacing: .08em; }
.nav { display: flex; gap: 4px; }
.nav a {
  text-decoration: none; font-size: 15px; padding: 10px 12px; border-radius: 8px;
  min-height: 44px; display: inline-flex; align-items: center;
}
.nav a[aria-current="page"] { background: rgba(251, 247, 240, .16); }

main { max-width: 720px; margin: 0 auto; padding: 24px 16px 56px; }
section + section { margin-top: 40px; }
.section-title { font-size: 22px; margin-bottom: 16px; }

/* 首頁主視覺 */
.hero { padding: 24px 0 8px; }
.hero .kind { color: var(--red); font-weight: 700; font-size: 15px; letter-spacing: .12em; }
.hero h1 { font-size: 34px; margin: 4px 0 8px; letter-spacing: .06em; }
.hero p { font-size: 17px; color: var(--muted); margin: 0 0 24px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 24px; border-radius: 999px;
  font: 700 16px/1 var(--sans); text-decoration: none; cursor: pointer;
  border: 2px solid var(--red); background: var(--red); color: #fff;
}
.btn.ghost { background: transparent; color: var(--red); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn:focus-visible, .chip:focus-visible, input:focus-visible, select:focus-visible, .nav a:focus-visible {
  outline: 3px solid #e0a43a; outline-offset: 2px;
}

/* 資訊卡 */
.info { display: grid; gap: 8px; }
.info-row {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px; display: grid; grid-template-columns: 72px 1fr; gap: 8px; align-items: start;
}
.info-row dt { color: var(--muted); font-size: 13px; padding-top: 2px; }
.info-row dd { margin: 0; font-size: 17px; }
.info-row dd a { color: var(--red); font-weight: 700; }
.note { color: var(--muted); font-size: 13px; margin: 4px 0 0; }
.note.lead { margin: -8px 0 16px; }

.signature { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.sig-item {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px; display: flex; justify-content: space-between; align-items: baseline; gap: 8px;
}
.sig-item b { font-size: 17px; }
.placeholder {
  border: 2px dashed var(--line); border-radius: var(--radius); padding: 16px;
  color: var(--muted); background: var(--paper);
}

/* 菜單 */
.menu-group { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 16px 16px; }
.menu-group + .menu-group { margin-top: 24px; }
.menu-group h2 { font-size: 22px; padding: 12px 0 4px; }
.menu-group .rule { color: var(--muted); font-size: 13px; margin: 0 0 8px; }
.menu-head, .menu-item {
  display: grid; grid-template-columns: 1fr 64px 64px; gap: 8px; align-items: baseline;
}
.menu-group.single .menu-head, .menu-group.single .menu-item { grid-template-columns: 1fr 72px; }
.menu-head { font-size: 13px; color: var(--muted); border-bottom: 1px solid var(--line); padding: 4px 0; }
.menu-head span:not(:first-child) { text-align: right; }
.menu-item { padding: 12px 0; border-bottom: 1px dashed var(--line); }
.menu-item:last-child { border-bottom: 0; }
.menu-item .name { font-size: 17px; font-weight: 700; }
.menu-item .tags { display: inline-flex; gap: 4px; margin-left: 4px; vertical-align: 2px; }
.tag { font-size: 12px; font-weight: 500; border: 1px solid var(--line); border-radius: 999px; padding: 0 8px; color: var(--muted); }
.price { font-family: var(--serif); color: var(--red); font-weight: 700; font-size: 17px; text-align: right; white-space: nowrap; }
.legend { color: var(--muted); font-size: 13px; margin-top: 16px; }

/* 預約 */
.step { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.step + .step { margin-top: 16px; }
.step h2 { font-size: 17px; font-family: var(--sans); margin-bottom: 12px; }
.chips { display: grid; gap: 8px; }
.chips.dates { grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); }
.chips.times { grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); }
.chip {
  min-height: 48px; border: 1px solid var(--line); border-radius: 8px; background: var(--rice);
  font: 500 15px/1.25 var(--sans); color: var(--ink); cursor: pointer; padding: 6px 4px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.chip small { font-size: 12px; color: var(--muted); }
.chip[aria-pressed="true"] { background: var(--red); border-color: var(--red); color: #fff; }
.chip[aria-pressed="true"] small { color: #fff; }
.chip:disabled { background: #f1ede6; color: #b3a89d; cursor: not-allowed; text-decoration: line-through; }
.chip:disabled small { color: #b3a89d; }

.field { display: grid; gap: 4px; }
.field + .field { margin-top: 16px; }
.field label { font-size: 15px; font-weight: 700; }
.field input, .field select {
  min-height: 48px; border: 1px solid var(--line); border-radius: 8px; padding: 0 12px;
  font: 400 16px var(--sans); color: var(--ink); background: var(--paper); width: 100%;
}
.field .hint { font-size: 13px; color: var(--muted); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.summary { font-size: 15px; color: var(--muted); margin: 16px 0 8px; min-height: 1.7em; }
.msg { border-radius: var(--radius); padding: 16px; margin-top: 16px; }
.msg.err { background: var(--red-soft); color: var(--red); }
.msg.ok { background: var(--ok-soft); color: var(--ok); }
.msg.ok h2 { font-size: 22px; margin-bottom: 8px; }
.banner { background: #fff4d6; color: #6b4e00; border-radius: var(--radius); padding: 12px 16px; font-size: 13px; margin-bottom: 16px; }
.loading { color: var(--muted); font-size: 15px; }

footer { text-align: center; color: var(--muted); font-size: 13px; padding: 24px 16px 40px; border-top: 1px solid var(--line); }

@media (min-width: 640px) {
  .hero h1 { font-size: 42px; }
}
