/* =========================================================
   首頁樣式：水墨留白
   米白宣紙底、墨黑文字、朱紅印章點綴，大量留白
   ========================================================= */

/* ---- 顏色與字型（想調整顏色，改這裡就好） ---- */
:root {
  --paper: #f6f2e9;        /* 宣紙米白 */
  --paper-deep: #ede6d6;   /* 稍深的紙色（卡片底） */
  --ink: #1f1d1a;          /* 濃墨 */
  --ink-soft: #5a554d;     /* 淡墨（次要文字） */
  --ink-faint: #a49c8e;    /* 極淡墨（標籤、線條） */
  --seal: #b8282e;         /* 朱紅，和印章同色 */

  --font-brush: "LXGW WenKai TC", "Kaiti TC", "BiauKai", "DFKai-SB", "標楷體", serif;
  --font-body: "Noto Serif TC", "Songti TC", "PMingLiU", "新細明體", serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background-color: var(--paper);
  /* 很淡的紙紋（用程式畫的雜訊，不需要圖檔） */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .3 0 0 0 0 .25 0 0 0 0 .15 0 0 0 .05 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  font-family: var(--font-body);
  line-height: 1.9;
  -webkit-text-size-adjust: 100%;
  overflow-x: clip;   /* 背景墨暈超出畫面時，不讓手機左右滑動 */
}

/* 印章圖：用「正片疊底」讓紅色像吃進紙裡 */
img[src$="seal.png"] { mix-blend-mode: multiply; }

a { color: inherit; }

/* =========================================================
   頂部
   ========================================================= */
.site-head {
  max-width: 960px;
  margin: 0 auto;
  padding: calc(18px + env(safe-area-inset-top)) 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-family: var(--font-brush);
  font-size: 20px;
  letter-spacing: 0.2em;
}
.brand img { width: 30px; height: 30px; }
.site-head nav { display: flex; gap: 22px; }
.site-head nav a {
  text-decoration: none;
  color: var(--ink-soft);
  font-size: 15px;
  letter-spacing: 0.3em;
  transition: color 0.2s;
}
.site-head nav a:hover { color: var(--seal); }

/* =========================================================
   開場
   ========================================================= */
.hero {
  position: relative;
  max-width: 960px;
  margin: 0 auto;
  padding: 56px 20px 40px;
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "lead title"
    ".    seal";
  column-gap: 28px;
  align-items: start;
}

/* 背景一抹很淡的墨暈 */
.ink-wash {
  position: absolute;
  top: 10px;
  right: -40px;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle at 45% 45%, rgba(31, 29, 26, 0.09), rgba(31, 29, 26, 0.03) 45%, transparent 70%);
  filter: blur(8px);
  pointer-events: none;
}

/* 淡墨神馬：像宣紙上隱約的水印（寓意福氣）
   想更淡／更濃，改 opacity；想更大／更小，改 width */
.hero-horse {
  position: absolute;
  left: 0;
  bottom: -18px;
  width: min(560px, 82%);
  height: auto;
  opacity: 0.14;
  mix-blend-mode: multiply;
  pointer-events: none;
  user-select: none;
}
/* 文字、印章疊在神馬上面 */
.hero-title, .hero-seal, .hero-lead { position: relative; z-index: 1; }

/* 直書大標題：由右到左、由上到下 */
.hero-title {
  grid-area: title;
  position: relative;
  margin: 0;
  writing-mode: vertical-rl;
  font-family: var(--font-brush);
  font-weight: 400;
  font-size: clamp(38px, 9vw, 64px);
  line-height: 1.5;
  letter-spacing: 0.18em;
}
.hero-title span { display: block; }               /* 每一句自成一直行 */
.hero-title span:nth-child(2) { padding-top: 1.4em; } /* 第二行往下錯開，像手寫落款 */

.hero-seal {
  grid-area: seal;
  justify-self: start;
  width: 54px;
  height: 54px;
  margin-top: 10px;
  transform: rotate(-4deg);
  opacity: 0.95;
}

.hero-lead {
  grid-area: lead;
  align-self: start;          /* 文字放左上，讓出左下給神馬低頭舔膝 */
  padding-top: 0.6em;
  margin: 0;
  color: var(--ink-soft);
  font-size: 16px;
  line-height: 2.2;
}

/* =========================================================
   毛筆分隔線（兩端漸淡）
   ========================================================= */
.brush-line {
  max-width: 920px;
  height: 2px;
  margin: 24px auto;
  background: linear-gradient(90deg, transparent, var(--ink) 18%, var(--ink) 60%, transparent);
  opacity: 0.25;
  border-radius: 2px;
}

/* =========================================================
   區塊（旅途、遊戲）
   ========================================================= */
.section {
  max-width: 960px;
  margin: 0 auto;
  padding: 28px 20px 36px;
}
.section-title {
  margin: 0;
  font-family: var(--font-brush);
  font-weight: 400;
  font-size: 30px;
  letter-spacing: 0.3em;
  display: flex;
  align-items: baseline;
  gap: 14px;
}
.section-title .num {
  color: var(--seal);
  font-size: 16px;
  letter-spacing: 0;
}
.section-note {
  margin: 4px 0 24px;
  color: var(--ink-soft);
  font-size: 14px;
}

/* ---- 旅途卡片 ---- */
.trip-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}
.trip {
  position: relative;
  padding: 22px 22px 20px;
  background: rgba(237, 230, 214, 0.55);
  border-left: 3px solid var(--ink);
  text-decoration: none;
  transition: background 0.25s, transform 0.25s;
}
a.trip:hover { background: var(--paper-deep); transform: translateY(-2px); }
.trip-place {
  font-family: var(--font-brush);
  font-size: 24px;
  letter-spacing: 0.15em;
}
.trip-year {
  color: var(--ink-faint);
  font-size: 13px;
  letter-spacing: 0.1em;
}
.trip p {
  margin: 10px 0 0;
  color: var(--ink-soft);
  font-size: 15px;
}
.tag {
  position: absolute;
  top: 20px;
  right: 18px;
  padding: 0 6px;
  border: 1px solid var(--seal);
  color: var(--seal);
  font-size: 12px;
  line-height: 1.7;
  letter-spacing: 0.1em;
}

/* ---- 遊戲清單 ---- */
.game-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 4px 28px;
}
.game {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 4px;
  border-bottom: 1px solid rgba(31, 29, 26, 0.12);
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}
/* 遊戲記號：小方框裡一個字，呼應印章 */
.game-mark {
  flex: none;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1.5px solid var(--ink);
  font-family: var(--font-brush);
  font-size: 24px;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.game:hover .game-mark,
.game:active .game-mark {
  background: var(--seal);
  border-color: var(--seal);
  color: var(--paper);
}
.game-text { display: flex; flex-direction: column; line-height: 1.5; }
.game-text strong { font-weight: 600; font-size: 17px; letter-spacing: 0.08em; }
.game-text small { color: var(--ink-soft); font-size: 13px; }

/* ---- 首頁：三個板塊入口 ---- */
.door-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}
.door {
  position: relative;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 26px 22px;
  background: rgba(237, 230, 214, 0.55);
  border-left: 3px solid var(--ink);
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.25s, transform 0.25s;
}
.door:hover, .door:active { background: var(--paper-deep); transform: translateY(-2px); }
.door-num {
  position: absolute;
  top: 10px;
  right: 14px;
  color: var(--seal);
  font-family: var(--font-brush);
  font-size: 14px;
}
.door-mark {
  flex: none;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 1.5px solid var(--ink);
  font-family: var(--font-brush);
  font-size: 32px;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.door:hover .door-mark,
.door:active .door-mark {
  background: var(--seal);
  border-color: var(--seal);
  color: var(--paper);
}
.door-text { display: flex; flex-direction: column; line-height: 1.6; }
.door-text strong {
  font-family: var(--font-brush);
  font-weight: 400;
  font-size: 26px;
  letter-spacing: 0.3em;
}
.door-text small { color: var(--ink-soft); font-size: 13px; }

/* =========================================================
   板塊頁（旅途／健康／興趣）
   ========================================================= */
.site-head nav a.on { color: var(--seal); }   /* 目前所在板塊 */

.page-head {
  max-width: 960px;
  margin: 0 auto;
  padding: 48px 20px 8px;
}
.page-head .section-title { font-size: 40px; }
.page-head p {
  margin: 6px 0 0;
  color: var(--ink-soft);
  font-size: 15px;
}
.section-sub {
  margin: 0;
  font-family: var(--font-brush);
  font-weight: 400;
  font-size: 22px;
  letter-spacing: 0.25em;
}
.group { margin-bottom: 36px; }
.group:last-child { margin-bottom: 0; }

/* 還沒做好的項目：灰一點，不能點 */
.game.soon { cursor: default; }
.game.soon .game-mark { border-color: var(--ink-faint); color: var(--ink-faint); }
.game.soon:hover .game-mark { background: none; color: var(--ink-faint); border-color: var(--ink-faint); }
.game .tag { position: static; margin-left: auto; flex: none; }

/* =========================================================
   自述頁（about/）：窄欄、段首空兩格，像一頁手稿
   ========================================================= */
.essay {
  max-width: 680px;
  margin: 0 auto;
  padding: 48px 20px 24px;
}
.essay-kicker {
  margin: 0;
  color: var(--seal);
  font-family: var(--font-brush);
  font-size: 15px;
  letter-spacing: 0.4em;
}
.essay-title {
  margin: 4px 0 32px;
  font-family: var(--font-brush);
  font-weight: 400;
  font-size: 42px;
  letter-spacing: 0.3em;
}
.essay p {
  margin: 0 0 1.1em;
  font-size: 17px;
  line-height: 2.1;
  text-indent: 2em;          /* 中文段首空兩格 */
  text-align: justify;
}
.essay .essay-kicker { text-indent: 0; }
.essay .essay-motto {
  margin: 2em 0;
  text-indent: 0;
  text-align: center;
  font-family: var(--font-brush);
  font-size: 21px;
  letter-spacing: 0.12em;
}
.essay-num {
  margin: 1.6em 0 0.4em;
  color: var(--seal);
  font-family: var(--font-brush);
  font-weight: 400;
  font-size: 20px;
}
.essay-sign {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  margin-top: 2em;
  font-family: var(--font-brush);
  font-size: 20px;
  letter-spacing: 0.2em;
}
.essay-sign img { width: 40px; height: 40px; transform: rotate(-4deg); }

/* 首頁開場短文下的「讀自述」連結 */
.hero-lead a {
  color: var(--seal);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

/* 小字說明（例如健康免責聲明） */
.fine-print {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
  color: var(--ink-faint);
  font-size: 12px;
  line-height: 1.8;
}

/* =========================================================
   頁尾
   ========================================================= */
.site-foot {
  padding: 40px 20px calc(48px + env(safe-area-inset-bottom));
  text-align: center;
  color: var(--ink-faint);
  font-size: 13px;
  letter-spacing: 0.15em;
}
.site-foot img { width: 36px; height: 36px; opacity: 0.85; }
.site-foot p { margin: 6px 0 0; }

/* =========================================================
   手機（窄螢幕）微調
   ========================================================= */
@media (max-width: 560px) {
  .hero {
    padding-top: 40px;
    column-gap: 18px;
  }
  .hero-lead { font-size: 14px; line-height: 2.1; }
  .ink-wash { width: 240px; height: 240px; right: -60px; }
  .section-title { font-size: 26px; }
  .page-head .section-title { font-size: 32px; }
  .hero-horse { width: 96%; left: 2%; bottom: -6px; opacity: 0.2; }
  .essay { padding-top: 36px; }
  .essay-title { font-size: 34px; }
  .essay p { font-size: 16px; }
  .essay .essay-motto { font-size: 17px; letter-spacing: 0.04em; }
}
