/* Central Barbershop — 共用設計系統
   顏色取自 Logo 綠與店內牆面：奶油白牆、紅腰線、鼠尾草綠下牆 */
/* 美式字體：Oswald＝老招牌窄體；Graduate＝校隊號碼字；Archivo 粗斜體只用來重現店裡牆上的紅字 */
@import url("https://fonts.googleapis.com/css2?family=Oswald:wght@500;600;700&family=Graduate&family=Archivo:ital,wght@1,800;1,900&family=Noto+Sans+TC:wght@400;500;700;900&display=swap");
/* 中文標題與大數字：未來熒黑 半窄體特粗（Glow Sans TC Condensed ExtraBold，OFL 授權，2026/10/28 使用者指定）。
   只抽出網頁用到的字，約 200KB；授權在 assets/fonts/OFL-GlowSans.txt */
@font-face {
  font-family: "Glow Sans Title";
  src: url("../fonts/glow-sans-tc-condensed-extrabold.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --green: #0f5127;   /* 取自原始 Logo */
  --green-d: #0a3a1c;
  --green-l: #e2ebe0;
  --sage: #9bb39a;
  --sage-l: #dde7da;
  --cream: #f4ecd4;
  --paper: #fbf8ef;
  --white: #ffffff;
  --ink: #1b201b;
  --ink-2: #4b544b;
  --ink-3: #636a62;   /* 在奶油紙底上仍達 WCAG AA 4.5:1 */
  --line: #e4ddca;
  --red: #c8102e;
  --red-d: #9d0b23;
  --red-l: #fbe5e8;
  --amber: #8a5a10;   /* 在 --amber-l 底上達 AA 4.5:1 */
  --amber-l: #fbf0d9;
  --blue: #2f5d8a;
  --blue-l: #e3ecf5;

  --font: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", system-ui, sans-serif;
  --display: "Oswald", "Noto Sans TC", sans-serif;      /* 標題、標籤、時間、金額 */
  --varsity: "Glow Sans Title", "Oswald", sans-serif;   /* 椅號、候位號碼、大數字（2026/10/28 由 Graduate 改未來熒黑窄體） */
  --title: "Glow Sans Title", "Noto Sans TC", sans-serif; /* 中文標題 */
  --wall: "Archivo", "Oswald", sans-serif;             /* 牆上紅色粗斜體字 */
  --r: 4px;
  --r-lg: 6px;
  --shadow: 0 1px 0 rgba(27, 32, 27, .05);
  --shadow-lg: 0 8px 28px rgba(27, 32, 27, .16);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  font-size: 15px;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.25; }
p { margin: 0; }

/* ---------- 品牌元素 ---------- */
.logo { height: 40px; width: auto; }
.tag {
  display: inline-block;
  font-family: var(--wall);
  font-style: italic;
  font-weight: 900;
  letter-spacing: .02em;
  text-transform: uppercase;
  color: var(--red);
  background: var(--white);
  padding: 2px 10px;
  border-radius: 3px;
  font-size: 13px;
  line-height: 1.5;
}
.tag.solid { background: var(--red); color: var(--white); }
.slogan {
  font-family: var(--wall);
  font-style: italic;
  font-weight: 900;
  text-transform: uppercase;
  color: var(--red);
  line-height: 1.05;
  letter-spacing: .01em;
}
.eyebrow {
  font-family: var(--display);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--green);
}
.stripe { height: 6px; background: var(--red); }
.wall {
  /* 店內牆面：上奶油、紅腰線、下鼠尾草綠 */
  background: linear-gradient(to bottom, var(--cream) 0 62%, var(--red) 62% calc(62% + 6px), var(--sage) calc(62% + 6px));
}
.num { font-family: var(--display); font-weight: 600; font-variant-numeric: tabular-nums; }

/* ---------- 按鈕 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 18px;
  border-radius: var(--r);
  border: 1.5px solid var(--green);
  background: var(--green); color: var(--white);
  font-weight: 700; font-size: 15px; text-decoration: none;
  transition: background .15s, transform .1s;
}
.btn:hover { background: var(--green-d); }
.btn:active { transform: translateY(1px); }
.btn.red { background: var(--red); border-color: var(--red); }
.btn.red:hover { background: var(--red-d); }
.btn.ghost { background: transparent; color: var(--green); }
.btn.ghost:hover { background: var(--green-l); }
.btn.light { background: var(--white); border-color: var(--line); color: var(--ink); }
.btn.light:hover { background: var(--cream); }
.btn.sm { min-height: 34px; padding: 0 12px; font-size: 13px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .4; pointer-events: none; }
.line-btn { background: #06c755; border-color: #06c755; color: #0a2a14; }  /* LINE 綠底配深字，對比 6.7:1 */
.line-btn:hover { background: #05b54d; }

/* ---------- 卡片、標籤、頭像 ---------- */
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow);
}
.chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: 3px;
  font-size: 12px; font-weight: 700; line-height: 1.7;
  background: var(--green-l); color: var(--green-d);
  white-space: nowrap;
}
.chip.red { background: var(--red-l); color: var(--red-d); }
.chip.amber { background: var(--amber-l); color: var(--amber); }
.chip.blue { background: var(--blue-l); color: var(--blue); }
.chip.gray { background: #eeece6; color: var(--ink-2); }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; background: currentColor; }
.avatar {
  width: 40px; height: 40px; border-radius: 50%;
  display: inline-grid; place-items: center; flex: none;
  font-family: var(--varsity); font-weight: 400;
  color: var(--white); background: var(--green);
  font-size: 15px; overflow: hidden;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.lg { width: 64px; height: 64px; font-size: 22px; }
.muted { color: var(--ink-3); }
.small { font-size: 13px; }

/* ---------- 表單 ---------- */
.field { display: grid; gap: 6px; }
.field label { font-size: 13px; font-weight: 700; color: var(--ink-2); }
.input, .select, .textarea {
  width: 100%; min-height: 44px; padding: 10px 12px;
  border: 1.5px solid var(--line); border-radius: var(--r);
  background: var(--white);
}
.input:focus, .select:focus, .textarea:focus { border-color: var(--green); box-shadow: 0 0 0 3px var(--green-l); }

/* ---------- 表格 ---------- */
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th {
  text-align: left; font-size: 12px; font-weight: 700; color: var(--ink-3);
  padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
.table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table .r { text-align: right; }

/* ---------- 原型標示 ---------- */
.proto-bar {
  position: fixed; left: 12px; bottom: 12px; z-index: 999;
  display: flex; gap: 6px; align-items: center;
  background: var(--ink); color: var(--white);
  padding: 6px 6px 6px 12px; border-radius: 999px;
  font-size: 12px; box-shadow: var(--shadow-lg);
}
.shot .proto-bar { display: none; }
@media (max-width: 480px) {
  /* 手機上收成小膠囊，點一下才展開，避免蓋住底部按鈕 */
  .proto-bar { left: auto; right: 8px; bottom: 96px; flex-wrap: wrap; justify-content: flex-end; max-width: calc(100vw - 16px); padding: 6px 12px; opacity: .92; }
  .proto-bar a { display: none; }
  .proto-bar:hover, .proto-bar:focus-within { padding: 6px 6px 6px 12px; opacity: 1; }
  .proto-bar:hover a, .proto-bar:focus-within a { display: inline-block; }
}
.proto-bar a {
  text-decoration: none; background: rgba(255,255,255,.12);
  padding: 4px 10px; border-radius: 999px;
}
.proto-bar a:hover { background: rgba(255,255,255,.24); }

/* ---------- 手機外框：在桌機上看手機畫面 ---------- */
.device-stage {
  min-height: 100vh;
  display: flex; justify-content: center; align-items: flex-start;
  padding: 32px 16px 80px;
  background: var(--sage-l);
}
.device {
  width: 390px; max-width: 100%;
  min-height: 780px;
  background: var(--paper);
  border-radius: 36px;
  border: 10px solid var(--ink);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  position: relative;
  display: flex; flex-direction: column;
}
@media (max-width: 480px) {
  .device-stage { padding: 0; background: var(--paper); }
  .device { width: 100%; border: 0; border-radius: 0; min-height: 100vh; box-shadow: none; }
}

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; top: 20px; transform: translate(-50%, calc(-100% - 60px));
  background: var(--ink); color: var(--white);
  padding: 12px 18px; border-radius: var(--r); font-weight: 700; font-size: 14px;
  box-shadow: var(--shadow-lg); z-index: 1000; transition: transform .25s ease;
  max-width: calc(100vw - 32px);
}
.toast.show { transform: translate(-50%, 0); }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- 鍵盤焦點：Tab 鍵移動時看得到在哪 ---------- */
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
