/* ==========================================================
   Doorsopen 網站共用樣式（手機優先）
   ========================================================== */

:root {
  /* 換色只要改下面 --accent 和 --deep 兩個變數，其他顏色都由它們推出來。
     2026-11-30 閔淳選定 B 葡萄霓虹（見 08_配色庫/配色規則.md「已定案」）。 */
  --accent: #5A3E9E;  /* 葡萄紫（2026-11-30 定案 B 葡萄霓虹） */
  --deep:   #22173F;
  --accent2: #C04A9A; /* 漸層第二色，只用在 Logo、小面積 */

  /* ---- 以下由公式推導（規則見 08_配色庫/配色規則.md），不用手改 ---- */
  --bg:         color-mix(in srgb, var(--accent) 4%, #F5F5F4); /* 底色：淺灰混 4% 主色 */
  --surface:    #FFFFFF;                                          /* 卡片 */
  --soft:       color-mix(in srgb, var(--accent) 12%, #FFFFFF);  /* 淺底：主色混 88% 白 */
  --stub-hi:    color-mix(in srgb, var(--accent) 38%, #FFFFFF);  /* 深色底上的亮字：主色混 62% 白 */
  --accent-ink: var(--deep);   /* 主色文字（site.js 會依對比重新計算） */
  --on-accent:  #FFFFFF;       /* 主色按鈕上的字（site.js 會依對比重新計算） */

  /* 中性色 */
  --ink:   #151716;
  --muted: #565B58;
  --line:  #E2E3E1;

  --radius: 14px;
  --gutter: 16px;
  --max: 720px;
  --font: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
}
img { max-width: 100%; display: block; }
a { color: var(--accent-ink); }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- 頁首 ---------- */
.site-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 14px 0;
}
.site-head__name { font-weight: 900; font-size: 18px; color: var(--ink); text-decoration: none; letter-spacing: .02em; }
.site-head nav a { color: var(--muted); text-decoration: none; font-size: 14px; margin-left: 14px; }
.site-head nav a:hover { color: var(--ink); }

/* ---------- 區塊標題 ---------- */
.section { margin: 28px 0; }
.section__title {
  font-size: 13px; font-weight: 700; letter-spacing: .12em;
  color: var(--muted); margin: 0 0 12px;
}
.lead { color: var(--muted); font-size: 14px; margin: 0 0 16px; }

/* ---------- 首頁：最新貼文卡 ---------- */
.posts { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 560px) { .posts { grid-template-columns: 1fr 1fr; } }

.post {
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
}
.post__cover {
  position: relative;
  aspect-ratio: 4 / 5;               /* 跟 IG 貼文 1080×1350 一樣比例 */
  background: var(--deep);
  color: var(--stub-hi);
  padding: 20px;
  display: flex; flex-direction: column; justify-content: flex-end;
}
.post__cover.has-image { padding: 0; }
.post__cover.has-image img { width: 100%; height: 100%; object-fit: cover; }
.post__kicker { font-size: 13px; font-weight: 700; letter-spacing: .08em; }
.post__title { color: #fff; font-size: 26px; line-height: 1.3; font-weight: 900; margin: 6px 0 14px; }
.post__brand { font-size: 12px; opacity: .8; }
.post__body { padding: 12px 14px 14px; }
.post__meta { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.post__meta a { color: var(--accent-ink); }
.post.is-sample { border-style: dashed; border-color: #B9BBB8; }

/* ---------- 連結列 ---------- */
.link-row { margin: 8px 0; }
.link {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  min-height: 48px; padding: 10px 14px;
  border-radius: 10px;
  background: var(--accent); color: var(--on-accent);
  text-decoration: none; font-weight: 700;
}
.link--info { background: var(--soft); color: var(--ink); }
.link--insurance { background: var(--surface); color: var(--ink); border: 1px solid var(--line); }
.link__arrow { flex: none; }
.link.is-pending {
  background: repeating-linear-gradient(135deg, #F0F0EE 0 8px, #E8E8E6 8px 16px);
  color: var(--muted); cursor: not-allowed; border: 1px dashed #B9BBB8;
}
.note { display: block; font-size: 12px; color: var(--muted); margin: 4px 2px 0; }

/* ---------- 標籤 ---------- */
.tag {
  display: inline-block; flex: none;
  font-size: 11px; font-weight: 700; line-height: 1;
  padding: 5px 7px; border-radius: 6px;
}
.tag--pending { background: #FFF; color: #5B4A00; border: 1px dashed #A08A2A; }
.tag--sample  { position: absolute; top: 12px; left: 12px; background: #FFF; color: var(--ink); }

/* ---------- 佔位區塊（還沒寫的內容） ---------- */
.todo {
  border: 2px dashed #A08A2A;
  background: #FFFBEA;
  color: #5B4A00;
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 14px;
}
.todo::before { content: "待補｜"; font-weight: 900; }

/* ---------- 場館清單、帳號 ---------- */
.venue-list, .accounts { display: grid; gap: 8px; }
.venue-item, .account {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 10px;
  padding: 12px 14px; text-decoration: none; color: var(--ink);
}
.venue-item__name, .account__label { font-weight: 700; }
.venue-item__city, .account__handle { color: var(--muted); font-size: 14px; margin-right: auto; }

/* ---------- 場館頁 ---------- */
.venue-hero {
  background: var(--deep); color: var(--stub-hi);
  border-radius: var(--radius); padding: 22px 20px; margin-top: 4px;
}
.venue-hero h1 { color: #fff; font-size: 28px; line-height: 1.3; margin: 4px 0 6px; font-weight: 900; }
.venue-hero p { margin: 0; font-size: 14px; }

.toc { display: flex; flex-wrap: wrap; gap: 6px; margin: 16px 0 0; padding: 0; list-style: none; }
.toc a {
  display: inline-block; font-size: 13px; padding: 6px 10px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line); color: var(--ink); text-decoration: none;
}

.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px; margin: 12px 0;
}
.card h2 { font-size: 20px; margin: 0 0 10px; font-weight: 900; }
.card h3 { font-size: 16px; margin: 16px 0 6px; }

.facts { margin: 0; display: grid; grid-template-columns: 7em 1fr; gap: 8px 12px; font-size: 15px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; }
.src { font-size: 12px; color: var(--muted); }
.src a { color: var(--muted); }
.flag { font-size: 11px; font-weight: 700; color: #5B4A00; border: 1px dashed #A08A2A; border-radius: 4px; padding: 1px 5px; margin-left: 4px; white-space: nowrap; }

.decide { /* 讀者正要做決定的地方：連結放這裡 */
  border-left: 3px solid var(--accent); padding-left: 12px; margin-top: 12px;
}
.decide__q { font-weight: 700; margin: 0 0 4px; }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-weight: 700; }

/* ---------- 頁尾 ---------- */
.site-foot { color: var(--muted); font-size: 13px; padding: 28px 0 40px; border-top: 1px solid var(--line); margin-top: 36px; }
.site-foot a { color: var(--muted); }
