/* Honiee 官網：手機優先、跟系統深淺色 */
:root {
  --brand: #E0583A;          /* 暫定品牌色，設計師定稿後改這裡 */
  --brand-ink: #B8411F;      /* 淺色底上的連結色（對比夠） */
  --bg: #FFFBF8;
  --surface: #FFFFFF;
  --text: #2A211E;
  --muted: #6E625D;
  --line: #EDE3DE;
  --tbc-bg: #FFF1C2;
  --tbc-text: #6B4E00;
  --radius: 14px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --brand: #F07455;
    --brand-ink: #FF9A80;
    --bg: #171312;
    --surface: #211B19;
    --text: #F3ECE9;
    --muted: #B3A7A2;
    --line: #362D2A;
    --tbc-bg: #4A3A0C;
    --tbc-text: #FFE08A;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  overflow-wrap: anywhere;
}
:lang(en) body, body:lang(en) { line-height: 1.65; }

a { color: var(--brand-ink); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

.wrap { max-width: 720px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 600px) { .wrap { padding: 0 24px; } }

/* 頁首 */
.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 60px; }
.logo { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 20px; color: var(--text); text-decoration: none; letter-spacing: .2px; }
.logo-dot { width: 28px; height: 28px; border-radius: 9px; background: var(--brand); display: inline-block; flex: none; }
.lang { font-size: 14px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; color: var(--text); white-space: nowrap; }
.lang:hover { border-color: var(--brand); }

/* 主文 */
main.wrap { padding-top: 32px; padding-bottom: 48px; }
h1 { font-size: 28px; line-height: 1.3; margin: 0 0 8px; }
h2 { font-size: 20px; line-height: 1.4; margin: 0 0 12px; }
h3 { font-size: 17px; margin: 20px 0 8px; }
p { margin: 0 0 12px; }
ul, ol { margin: 0 0 12px; padding-left: 1.4em; }
li { margin-bottom: 6px; }
li:last-child { margin-bottom: 0; }
.meta { color: var(--muted); font-size: 14px; margin-bottom: 0; }
.lead { font-size: 17px; color: var(--muted); }

section { padding: 28px 0; border-top: 1px solid var(--line); }
section:first-of-type { border-top: 0; }
.page-head { padding-bottom: 20px; }

/* 草稿提示 */
.draft-note {
  margin: 20px 0 8px; padding: 12px 14px; border-radius: var(--radius);
  background: var(--tbc-bg); color: var(--tbc-text); font-size: 14px; line-height: 1.6;
}
/* 待確認標記 */
.tbc {
  background: var(--tbc-bg); color: var(--tbc-text);
  padding: 1px 4px; border-radius: 4px; font-size: .92em; font-weight: 600;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}

/* 表格（資料清單） */
.table-scroll { overflow-x: auto; margin: 0 0 12px; border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 520px; }
th, td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
tr:last-child td { border-bottom: 0; }
th { background: var(--surface); font-weight: 700; white-space: nowrap; }

/* 卡片 */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin: 0 0 12px; }
.card > :last-child { margin-bottom: 0; }

/* 首頁 */
.hero { text-align: center; padding: 40px 0 12px; }
.hero .logo-big { width: 72px; height: 72px; border-radius: 20px; background: var(--brand); margin: 0 auto 20px; }
.hero h1 { font-size: 34px; margin-bottom: 8px; }
.hero .lead { max-width: 30em; margin: 0 auto 24px; }
.badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 0 0 8px; }
.badge { display: inline-block; padding: 10px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); font-size: 14px; font-weight: 600; }
.features { list-style: none; padding: 0; display: grid; gap: 12px; }
.features li { margin: 0; }
.features b { display: block; margin-bottom: 2px; }
.links { list-style: none; padding: 0; margin: 0; }
.links li { margin: 0; border-bottom: 1px solid var(--line); }
.links li:last-child { border-bottom: 0; }
.links a { display: block; padding: 12px 2px; text-decoration: none; color: var(--text); }
.links a::after { content: "›"; float: right; color: var(--muted); }

/* FAQ */
details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); margin: 0 0 10px; }
summary { cursor: pointer; padding: 14px 44px 14px 16px; font-weight: 600; list-style: none; position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 16px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 20px; font-weight: 400; }
details[open] summary::after { content: "−"; }
details[open] summary { border-bottom: 1px solid var(--line); }
details > div { padding: 12px 16px 14px; }
details > div > :last-child { margin-bottom: 0; }

.btn { display: inline-block; background: var(--brand); color: #fff; text-decoration: none; font-weight: 700; padding: 12px 20px; border-radius: 12px; }
.btn:hover { filter: brightness(1.05); }
pre.template { white-space: pre-wrap; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; font-size: 14px; line-height: 1.6; font-family: inherit; margin: 0 0 12px; }

/* 頁尾 */
.site-footer { border-top: 1px solid var(--line); padding: 24px 0 40px; color: var(--muted); font-size: 14px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 10px; }
.site-footer a { color: var(--muted); }
.site-footer p { margin: 0; }

/* 手機上表格改成一列一張卡，不用左右滑 */
@media (max-width: 560px) {
  .table-scroll { overflow: visible; border: 0; border-radius: 0; }
  .table-scroll table { min-width: 0; }
  .table-scroll thead { display: none; }
  .table-scroll table, .table-scroll tbody, .table-scroll tr, .table-scroll td { display: block; width: 100%; }
  .table-scroll tr { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 6px 14px; margin-bottom: 10px; }
  .table-scroll td { border-bottom: 1px solid var(--line); padding: 8px 0; display: flex; gap: 12px; }
  .table-scroll tr td:last-child { border-bottom: 0; }
  .table-scroll td::before { content: attr(data-label); flex: 0 0 6.5em; color: var(--muted); font-size: 14px; font-weight: 400; }
  .table-scroll td:first-child { font-weight: 700; }
}
