/* 小波狗說故事 官網（2026-10-30）。顏色照 App 白天的 :root（web/ui/app.css），睡前那一段用 App 晚上的深藍。
   不用漸層、不加光暈；陰影只用中性的淡陰影。字型是 App 用的粉圓，只留這幾頁用到的字（scripts/site_font.py 產生）。
   標題（data-zy）用注音粉圓，跟 App 一樣每個字右邊帶注音。動畫在 site.js；使用者設定減少動態效果時全部關掉。 */
@font-face { font-family: 'Huninn'; src: url('fonts/huninn-site.woff2') format('woff2'); font-display: swap; }
@font-face { font-family: 'Zhuyin'; src: url('fonts/zhuyin-site.woff2') format('woff2'); font-display: block; }

:root {
  --bg: #f4ead8; --paper: #fff8ea; --paper-2: #f6ead4;
  --ink: #4a3424; --soft: #7a5c44; --faint: #a58b70;
  --edge: #dccaa9; --sun: #ffd27a; --leaf: #a7d690; --sky: #bfe3f5; --berry: #f6b5ad; --berry-ink: #5a231d;
  --dusk: #f1b97f; --night: #2b2d48; --night-paper: #36395c; --night-ink: #f6ecd9; --night-soft: #d2c6b3; --moon: #f6e7b8;
  --bezel: #3b2c20; --straw: #e6bd55; --straw-2: #c9962f;
  --shadow: 0 8px 18px rgba(60, 40, 20, .12);
  --font: 'Huninn', 'PingFang TC', 'Noto Sans TC', 'Microsoft JhengHei', system-ui, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; color: var(--ink); font: 18px/1.75 var(--font);
  background: var(--bg) url('img/paper.webp') 0 0 / 512px 512px;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
a:focus-visible, summary:focus-visible, button:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 8px; }
h1, h2, h3 { font-weight: 400; margin: 0; letter-spacing: .02em; }
[data-zy] { font-family: 'Zhuyin', var(--font); letter-spacing: 0; }
h1 { font-size: clamp(30px, 3.5vw, 44px); line-height: 1.3; } /* 注音字一個字約 1.5 個字寬：「每個字都有注音」7 個字要排在一行 */
h2 { font-size: clamp(27px, 3.6vw, 40px); line-height: 1.35; }
h3 { font-size: 22px; line-height: 1.4; }
p { margin: 0 0 12px; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 780px; }
.center { text-align: center; }
.nw { white-space: nowrap; }
.small { font-size: 16px; color: var(--soft); }
section { padding: 88px 0; }

/* 捲到才出現（site.js 加 .in）。沒有 JS 時照常顯示。 */
.js [data-reveal] {
  opacity: 0; transform: translateY(30px) rotate(var(--rot, 0deg));
  transition: opacity .7s ease, transform .9s cubic-bezier(.2, .9, .3, 1.15);
  transition-delay: calc(var(--i, 0) * 110ms);
}
.js [data-reveal].in { opacity: 1; transform: none; }
/* 螢光筆重點（10/30 使用者要：每個特色區塊一眼看到重點）：黃色色帶畫在字的下半截，捲到才從左往右畫上去，跨行時一行接一行 */
.mk-hl {
  --mk: #ffe08a; --mk-a: 55%; --mk-b: 92%; color: var(--ink); padding: 0 2px;
  background: linear-gradient(transparent var(--mk-a), var(--mk) var(--mk-a), var(--mk) var(--mk-b), transparent var(--mk-b)) no-repeat 0 0 / 100% 100%;
}
.js .mk-hl { background-size: 0 100%; transition: background-size .9s cubic-bezier(.4, .1, .3, 1) .2s; }
.js .mk-hl.mk-on { background-size: 100% 100%; }
/* 睡前那段背景會從白天變成深藍：色帶蓋在淺色字上會變灰，改成字底下一道暖黃色的線，字跟著變亮 */
.night .mk-hl { --mk: rgba(255, 210, 122, .85); --mk-a: 78%; --mk-b: 94%; color: inherit; }
@supports (color: color-mix(in srgb, red 50%, blue)) {
  .night .mk-hl { color: color-mix(in srgb, var(--night-ink) calc(var(--p2, 1) * 100%), var(--ink)); }
}

/* 上方列 */
.top { padding: 14px 0; position: relative; z-index: 2; }
.top-in { display: flex; align-items: center; gap: 24px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-size: 21px; white-space: nowrap; }
.brand img { border-radius: 11px; }
.nav { display: flex; gap: 22px; margin-left: auto; font-size: 17px; }
.nav a, .lang { text-decoration: none; color: var(--soft); }
.nav a:hover, .lang:hover { color: var(--ink); }
.lang { font-size: 16px; border: 1.5px solid var(--edge); border-radius: 999px; padding: 4px 14px; background: var(--paper); }

/* 主畫面 */
.hero { position: relative; padding: 20px 0 150px; overflow: hidden; }
.hero-in { position: relative; display: grid; grid-template-columns: 1.04fr 1fr; gap: 40px; align-items: center; }
/* 主標題：「童話動畫」是深色小標籤；「每個字／都有注音」一個字一塊字卡（App 的四個顏色、白邊像貼紙、歪歪的），
   「注音」兩塊黃色、大一點。字卡要 site.js 把字拆開才有，沒有 JS 就是一般的大字。 */
.hero h1 { font-size: clamp(40px, 4.4vw, 58px); line-height: 1.2; }
.hero h1 .h1-a {
  display: inline-block; font-size: .52em; color: var(--paper); background: var(--ink);
  padding: .16em .6em .12em .55em; margin: 0 0 .5em .1em; border-radius: .7em; rotate: -3deg;
}
.hero h1 .h1-b { display: inline-block; line-height: 1.45; }
.hero h1 em { font-style: normal; }
.hero h1 .h1-b .ch {
  background: var(--t, var(--sky)); rotate: var(--r, 0deg);
  padding: .02em .06em 0 .1em; margin: 0 .06em .1em 0;
  border: .05em solid #fffdf5; border-radius: .2em .26em .18em .24em;
  box-shadow: 0 .07em 0 rgba(74, 52, 36, .2);
}
.h1-b > .ch:nth-child(1) { --t: var(--sky); --r: -5deg; }
.h1-b > .ch:nth-child(2) { --t: var(--berry); --r: 3deg; }
.h1-b > .ch:nth-child(3) { --t: var(--leaf); --r: -2deg; }
.h1-b > .ch:nth-child(5) { --t: var(--berry); --r: 4deg; }
.h1-b > .ch:nth-child(6) { --t: var(--leaf); --r: -3deg; }
.h1-b em .ch { --t: var(--sun); --r: 3deg; font-size: 1.1em; }
.h1-b em .ch + .ch { --r: -4deg; }
@media (hover: hover) {
  .hero h1 .h1-b .ch { transition: translate .25s cubic-bezier(.3, 1.6, .5, 1); }
  .hero h1 .h1-b .ch:hover { translate: 0 -.12em; }
}
.kicker { color: var(--soft); font-size: 16px; margin-bottom: 10px; }
.lead { font-size: 20px; color: var(--soft); margin: 20px 0 28px; max-width: 30em; }
.js .hero h1:not(.chars) { visibility: hidden; } /* 拆成一個一個字之前先不顯示，免得閃一下 */
.hero h1 .ch { display: inline-block; animation: pop .75s cubic-bezier(.3, 1.6, .5, 1) both; animation-delay: calc(var(--i) * 55ms + .1s); }
.hero h1.h1-wave .ch { animation: hop .7s ease both; animation-delay: calc(var(--i) * 60ms); }
@keyframes pop { from { opacity: 0; transform: translateY(.5em) scale(.4) rotate(-14deg); } }
@keyframes hop { 40% { transform: translateY(-.2em) rotate(-5deg); } }
.hero-text > :not(h1) { animation: rise .8s ease both .7s; }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }

.stores { display: flex; flex-wrap: wrap; gap: 12px; }
.store {
  display: flex; align-items: center; gap: 10px; min-width: 180px; padding: 10px 20px 10px 16px;
  background: var(--ink); color: var(--paper); border-radius: 16px; text-decoration: none; line-height: 1.2; font-size: 20px;
  transition: transform .2s ease;
}
.store:hover { transform: translateY(-3px); }
.store svg { width: 28px; height: 28px; fill: currentColor; flex: none; }
.store span { display: flex; flex-direction: column; white-space: nowrap; }
.store small { font-size: 13px; opacity: .85; }
[data-launch="soon"] .store { pointer-events: none; }
.note { margin-top: 16px; font-size: 16px; color: var(--soft); }

.hero-stage {
  position: relative; animation: stage-in 1s cubic-bezier(.2, .9, .3, 1.1) both .2s;
  transform: perspective(1400px) rotateY(calc(var(--mx, 0) * -7deg)) rotateX(calc(var(--my, 0) * 6deg));
  transition: transform .4s ease-out;
}
@keyframes stage-in { from { opacity: 0; translate: 0 40px; scale: .92; } }
.tablet { position: relative; background: var(--bezel); padding: 12px; border-radius: 30px; box-shadow: var(--shadow); }
.tablet video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; border-radius: 19px; background: #d9ccb2; object-fit: cover; }
.hero .tablet { rotate: -1.5deg; animation: bob 6s ease-in-out infinite; }
@keyframes bob { 50% { translate: 0 -8px; } }
.now {
  position: absolute; left: 50%; bottom: -22px; translate: -50% 0; margin: 0;
  display: flex; align-items: center; gap: 8px; white-space: nowrap;
  background: var(--paper); border: 1.5px solid var(--edge); border-radius: 999px; padding: 5px 18px 5px 7px; font-size: 17px; box-shadow: var(--shadow);
}
.now img { width: 30px; }
.now span { display: inline-block; }
.now .flip { animation: flip .5s ease; }
@keyframes flip { from { opacity: 0; transform: translateY(10px); } }
.hero-bobo { position: absolute; width: 27%; left: -11%; bottom: -16%; transform-origin: 50% 92%; animation: wave 3.4s ease-in-out infinite; }
@keyframes wave { 0%, 100% { rotate: -5deg; } 50% { rotate: 6deg; } }

/* 天空的雲和小星星（扁平色塊，不發光） */
.sky { position: absolute; inset: 0; pointer-events: none; }
.cloud { position: absolute; width: 132px; height: 40px; background: #fffdf5; border-radius: 999px; animation: drift 16s ease-in-out infinite alternate; }
.cloud::before, .cloud::after { content: ''; position: absolute; background: #fffdf5; border-radius: 50%; }
.cloud::before { width: 56px; height: 56px; left: 22px; top: -26px; }
.cloud::after { width: 42px; height: 42px; left: 66px; top: -18px; }
.c1 { left: 3%; top: 64%; scale: .8; }
.c2 { right: 4%; top: 7%; animation-duration: 21s; }
.c3 { left: 40%; top: 4%; scale: .6; animation-duration: 18s; animation-delay: -6s; }
@keyframes drift { from { transform: translateX(calc(-24px + var(--mx, 0) * 30px)); } to { transform: translateX(calc(36px + var(--mx, 0) * 30px)); } }
.spark {
  position: absolute; width: 22px; height: 22px; background: var(--sun);
  clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%);
  animation: twinkle 2.8s ease-in-out infinite;
}
.s1 { left: 47%; top: 16%; }
.s2 { right: 3%; top: 48%; width: 16px; height: 16px; animation-delay: -.9s; }
.s3 { left: 52%; bottom: 10%; width: 28px; height: 28px; animation-delay: -1.7s; background: var(--berry); }
.s4 { right: 38%; top: 6%; width: 14px; height: 14px; animation-delay: -2.2s; background: var(--sky); }
.s5 { left: 1.5%; top: 30%; width: 18px; height: 18px; animation-delay: -1.2s; background: var(--leaf); }
@keyframes twinkle { 50% { transform: scale(.45) rotate(45deg); } }

/* 試玩：大野狼吹稻草屋 */
.try { padding-top: 40px; overflow-x: clip; }
.sub { color: var(--soft); margin-top: 10px; }
.stage { position: relative; max-width: 1020px; margin: 30px auto 0; display: grid; grid-template-columns: 1fr 190px; gap: 30px; align-items: center; }
.done {
  position: absolute; inset: 12px; border-radius: 19px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
  background: rgba(43, 45, 72, .5); opacity: 0; pointer-events: none; transition: opacity .5s ease;
}
.done p { margin: 0; color: var(--paper); font-size: clamp(32px, 5.4vw, 58px); }
.stage[data-state="done"] .done { opacity: 1; pointer-events: auto; }
.stage[data-state="done"] .done p { animation: pop .8s cubic-bezier(.3, 1.6, .5, 1) both; }
.again { border: 0; background: var(--paper); color: var(--ink); border-radius: 999px; padding: 10px 28px; font-size: 20px; cursor: pointer; }
.bits { position: absolute; left: 63%; top: 50%; width: 0; height: 0; pointer-events: none; z-index: 3; }
.bit {
  position: absolute; width: 9px; height: 34px; margin: -17px 0 0 -4px; background: var(--straw); border-radius: 5px;
  scale: var(--s); animation: fly 1.7s cubic-bezier(.2, .65, .35, 1) var(--d) both;
}
.bit.b2 { background: var(--straw-2); width: 6px; height: 22px; }
@keyframes fly {
  0% { transform: translate(0, 0) rotate(0); opacity: 1; }
  55% { transform: translate(calc(var(--dx) * .78), var(--dy)) rotate(calc(var(--r) * .6)); opacity: 1; }
  100% { transform: translate(var(--dx), calc(var(--dy) + 190px)) rotate(var(--r)); opacity: 0; }
}
.ctrl { display: flex; flex-direction: column; align-items: center; gap: 30px; }
.blow {
  position: relative; width: 132px; height: 132px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--ink); color: var(--paper); font-size: 18px; line-height: 1.2;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none;
  animation: breathe 2.4s ease-in-out infinite; transition: transform .2s ease, background-color .2s ease, opacity .3s ease;
}
.blow b { font-weight: 400; }
.wind { width: 44px; height: 44px; fill: none; stroke: currentColor; stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.ring { position: absolute; inset: -11px; width: calc(100% + 22px); height: calc(100% + 22px); transform: rotate(-90deg); pointer-events: none; }
.ring circle { fill: none; stroke-width: 6; }
.ring .track { stroke: var(--edge); }
.ring .prog { stroke: #6fa95e; stroke-linecap: round; transition: stroke-dashoffset .15s linear; }
@keyframes breathe { 50% { transform: scale(1.06); } }
.stage[data-state="blowing"] .blow { animation: none; transform: scale(1.1); background: #5d4331; }
.stage[data-state="blowing"] .wind { animation: puff .5s ease-in-out infinite alternate; }
@keyframes puff { to { transform: translateX(5px); } }
.stage[data-state="gone"] .blow, .stage[data-state="done"] .blow { animation: none; opacity: .45; }
.side { display: flex; flex-direction: column; gap: 10px; align-items: stretch; }
.mic, .sound {
  display: flex; align-items: center; gap: 8px; font-size: 16px; cursor: pointer;
  background: var(--paper); border: 1.5px solid var(--edge); border-radius: 999px; padding: 5px 16px 5px 7px;
}
.mic[hidden] { display: none; }
.mic img, .sound img { width: 28px; }
.mic[aria-pressed="true"] { background: var(--sun); }
.sound[aria-pressed="true"] .off, .sound[aria-pressed="false"] .on { display: none; }
.sound[aria-pressed="false"] img { opacity: .4; }
.try-note { max-width: 40em; margin: 30px auto 0; }

/* 左右兩欄（圖＋文） */
.split { display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: center; }
.split.rev > :first-child { order: 2; }
.split-text h2 { margin-bottom: 18px; }
.split-text p { color: var(--soft); }
.screen { margin: 0; background: var(--bezel); padding: 10px; border-radius: 26px; box-shadow: var(--shadow); }
.screen img { border-radius: 17px; }
.art.float img { animation: float 7s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-12px) rotate(.6deg); } }

/* 注音：動畫畫面＋底下一條放大的字幕（同一句用注音粉圓排），尾巴指著畫面裡框起來的字幕；捲到時從字幕那裡長出來 */
.zy-box { margin: 0; }
.zy-shot { position: relative; }
.zy-mark { position: absolute; left: 20.6%; right: 20.4%; top: 83%; bottom: 1.8%; border: 3px solid var(--sun); border-radius: 10px; }
.zy-big {
  position: relative; z-index: 1; margin: -12px 3% 0; padding: 10px 14px 12px; text-align: center; white-space: nowrap;
  font-size: clamp(24px, 2.9vw, 38px); line-height: 1.4;
  background: var(--paper); border: 1.5px solid var(--edge); border-radius: 22px; box-shadow: var(--shadow);
}
.zy-big::before {
  content: ''; position: absolute; left: 50%; top: -11px; width: 20px; height: 20px; translate: -50% 0; rotate: 45deg;
  background: var(--paper); border-left: 1.5px solid var(--edge); border-top: 1.5px solid var(--edge); border-radius: 4px 0 0 0;
}
.js .zy-box .zy-big { opacity: 0; transform: translateY(-30%) scale(.45); transition: opacity .3s ease .45s, transform .7s cubic-bezier(.3, 1.4, .5, 1) .45s; }
.js .zy-box.in .zy-big { opacity: 1; transform: none; }

/* 看、聽、一起玩 */
.ways { padding-top: 40px; }
.cards { display: grid; gap: 20px; margin-top: 36px; }
.three { grid-template-columns: repeat(3, 1fr); }
.two { grid-template-columns: repeat(2, 1fr); max-width: 900px; margin-left: auto; margin-right: auto; }
.card, .mini, .plan, .faq details {
  background: var(--paper); border: 1.5px solid var(--edge); border-radius: 24px; box-shadow: var(--shadow);
}
.card { padding: 22px 24px 18px; text-align: center; }
.card:nth-child(1) { --rot: -4deg; }
.card:nth-child(3) { --rot: 4deg; }
.card img { height: 150px; width: auto; margin: 0 auto 10px; animation: float 5s ease-in-out infinite; animation-delay: calc(var(--i, 0) * -1.6s); }
.card:hover img { animation: wiggle .7s ease; }
@keyframes wiggle { 25% { transform: rotate(-8deg) scale(1.06); } 60% { transform: rotate(6deg) scale(1.06); } }
.card h3 { margin-bottom: 6px; }
.card p { color: var(--soft); font-size: 17px; }

.feature { padding: 64px 0; }
.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.ticks li { display: flex; gap: 14px; align-items: flex-start; color: var(--soft); }
.ticks img { width: 48px; flex: none; transition: transform .3s ease; }
.ticks li:hover img { transform: rotate(-10deg) scale(1.12); }
.ticks b { display: block; font-weight: 400; color: var(--ink); font-size: 20px; }

/* 睡前：捲進來時天色從白天換成晚上（site.js 設 --p：0＝白天、1＝晚上） */
.night { --p: 1; position: relative; overflow: hidden; background: var(--night) url('img/paper.webp') 0 0 / 512px 512px; color: var(--night-ink); }
.night .split-text p { color: var(--night-soft); }
@supports (color: color-mix(in srgb, red 50%, blue)) {
  /* 先變成黃昏的橘色（--p1），再變成夜晚的深藍（--p2） */
  .night { background-color: color-mix(in srgb, var(--night) calc(var(--p2, 1) * 100%), color-mix(in srgb, var(--dusk) calc(var(--p1, 1) * 100%), var(--bg))); color: color-mix(in srgb, var(--night-ink) calc(var(--p2, 1) * 100%), var(--ink)); }
  .night .split-text p { color: color-mix(in srgb, var(--night-soft) calc(var(--p2, 1) * 100%), var(--soft)); }
}
.night .wrap { position: relative; }
.night .art img { border-radius: 24px; }
.night-sky { position: absolute; inset: 0; pointer-events: none; }
.sun { position: absolute; right: 12%; top: 44px; width: 86px; height: 86px; border-radius: 50%; background: var(--sun); transform: translateY(calc(var(--p) * 260px)); opacity: calc(1 - var(--p) * 1.6); }
.moon {
  position: absolute; right: 12%; top: 30px; width: 70px; height: 70px; border-radius: 50%; box-shadow: 16px 8px 0 0 var(--moon);
  transform: translateY(calc((1 - var(--p)) * 140px)) rotate(-18deg); opacity: calc(var(--p) * 1.6 - .6);
}
.star {
  position: absolute; left: var(--x); top: var(--y); width: 14px; height: 14px; background: var(--moon);
  clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%);
  opacity: calc(var(--p) * 2 - 1); animation: twinkle 3.2s ease-in-out infinite; animation-delay: var(--d);
}
.clock {
  display: inline-flex; align-items: center; gap: 8px; font-size: 22px; line-height: 1; padding: 6px 16px 6px 6px; margin-bottom: 16px;
  border-radius: 999px; background: var(--night-paper); color: var(--night-ink) !important;
  opacity: 0; transform: translateY(12px) scale(.9); transition: opacity .5s ease, transform .6s cubic-bezier(.3, 1.6, .5, 1);
}
.clock img { width: 30px; }
.night.dark .clock { opacity: 1; transform: none; }

/* 書櫃 */
.books { list-style: none; padding: 0; margin: 36px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px 20px; }
.books li:nth-child(odd) { --rot: -3deg; }
.books li:nth-child(even) { --rot: 3deg; }
.books img { border-radius: 14px; box-shadow: var(--shadow); aspect-ratio: 16 / 9; object-fit: cover; width: 100%; transition: transform .35s cubic-bezier(.3, 1.5, .5, 1); }
.books li:hover img { transform: translateY(-8px) rotate(-1.5deg) scale(1.04); }
.books span { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 10px; font-size: 18px; line-height: 1.4; }
.books i { font-style: normal; font-size: 13px; line-height: 1; padding: 4px 8px; border-radius: 999px; background: var(--sky); color: #1d4058; }
.books i.free { background: var(--sun); color: var(--ink); }
/* 書櫃最後一格（10/30 使用者要求）：整排虛線框「每週持續更新新故事」，像書櫃還有空位。12 本在 4／3／2 欄都剛好排滿，這格自己一排 */
.books .books-more { --rot: 0deg; grid-column: 1 / -1; display: flex; align-items: center; justify-content: center; gap: 12px; padding: 14px 20px; border: 2.5px dashed #cfb48a; border-radius: 18px; font-size: 20px; line-height: 1.4; }
.books .books-more img { width: 40px; height: 40px; aspect-ratio: auto; border-radius: 0; box-shadow: none; transform: none; }

/* 給爸爸媽媽 */
.parents { background: var(--paper-2); }
.grid6 { grid-template-columns: repeat(3, 1fr); }
.mini { display: flex; gap: 16px; padding: 20px 22px; align-items: flex-start; }
.mini img { width: 54px; flex: none; transition: transform .3s ease; }
.mini:hover img { transform: rotate(-10deg) scale(1.1); }
.mini h3 { font-size: 20px; margin-bottom: 4px; }
.mini p { color: var(--soft); font-size: 16px; margin: 0; }

/* 會員：左邊免費（兩本免費的封面＋一格每 3 秒換一本「本週免費」），右邊是一張故事屋的票（票根＋全部故事的小封面）。
   票的兩個缺口用 mask 挖（看得到後面的紙紋），影子放在外面那層（mask 會把自己的影子也切掉） */
.plan-row { display: grid; grid-template-columns: 1fr 1.3fr; gap: 28px; margin-top: 40px; align-items: stretch; }
.plan { padding: 24px 26px 22px; }
.plan h3 { margin-bottom: 10px; }
.plan ul { padding: 0; margin: 0; list-style: none; display: grid; gap: 8px; }
.plan li { padding-left: 28px; position: relative; color: var(--soft); font-size: 17px; line-height: 1.6; }
.plan li::before { content: ''; position: absolute; left: 2px; top: .45em; width: 14px; height: 8px; border-left: 3px solid #6fa95e; border-bottom: 3px solid #6fa95e; transform: rotate(-45deg); }
.pf-books { display: flex; justify-content: center; align-items: center; margin: 6px 0 22px; }
.pf-books > img, .pf-week { width: 34%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 10px; border: 3px solid #fffdf5; box-shadow: var(--shadow); }
.pf-books > img:first-child { rotate: -7deg; }
.pf-books > img:nth-child(2) { rotate: 2deg; margin: 0 -5%; position: relative; z-index: 1; }
.pf-week { position: relative; rotate: 7deg; background: var(--paper-2); }
.pf-week img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 7px; opacity: 0; animation: pfw 12s infinite; }
.pf-week img:nth-child(2) { animation-delay: 3s; } .pf-week img:nth-child(3) { animation-delay: 6s; } .pf-week img:nth-child(4) { animation-delay: 9s; }
@keyframes pfw { 0%, 23% { opacity: 1; } 27%, 100% { opacity: 0; } }
.pf-week b { position: absolute; left: 50%; top: -14px; translate: -50% 0; white-space: nowrap; font-weight: 400; font-size: 13px; line-height: 1; padding: 5px 9px; border-radius: 999px; background: var(--sun); }
.pass-wrap { filter: drop-shadow(0 8px 14px rgba(60, 40, 20, .13)); }
.plan-pass {
  --cut: 31%; height: 100%; padding: 0; display: grid; grid-template-columns: var(--cut) 1fr; box-shadow: none;
  background: #fff3cf; border-color: #f0d79a;
  -webkit-mask: radial-gradient(circle 14px at var(--cut) 0, #0000 96%, #000) top / 100% 51% no-repeat, radial-gradient(circle 14px at var(--cut) 100%, #0000 96%, #000) bottom / 100% 51% no-repeat;
  mask: radial-gradient(circle 14px at var(--cut) 0, #0000 96%, #000) top / 100% 51% no-repeat, radial-gradient(circle 14px at var(--cut) 100%, #0000 96%, #000) bottom / 100% 51% no-repeat;
}
.pass-stub { display: grid; justify-items: center; align-content: center; gap: 4px; padding: 20px 12px; border-right: 2.5px dashed #e3c27c; text-align: center; }
.pass-stub img { height: 112px; width: auto; }
.pass-stub h3 { margin: 4px 0 0; font-size: 26px; }
.pass-stub span { font-size: 14px; padding: 3px 12px; border-radius: 999px; background: var(--ink); color: var(--paper); }
.pass-body { padding: 22px 24px 20px; display: grid; gap: 14px; align-content: start; }
.pass-covers { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
/* 封面最後一格「每週持續更新」（10/30 使用者要求）：虛線空格像下一本的位置；桌機 7 欄佔 2 格，平板、手機 5 欄佔 3 格，剛好排滿 */
.pass-more { grid-column: span 2; display: grid; place-items: center; border: 2px dashed #e3c27c; border-radius: 6px; background: #fffdf5; font-size: 13px; line-height: 1.2; white-space: nowrap; }
.pass-covers img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 6px; border: 2px solid #fffdf5; }
.pass-covers img:nth-child(odd) { rotate: -2deg; } .pass-covers img:nth-child(even) { rotate: 2deg; }
.pass-note { margin: 0; font-size: 14px; color: var(--soft); }
/* 常見問題 */
.faq h2 { margin-bottom: 32px; }
.faq details { margin-bottom: 12px; padding: 0 22px; box-shadow: none; }
.faq summary { cursor: pointer; list-style: none; padding: 18px 32px 18px 0; position: relative; font-size: 19px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; position: absolute; right: 0; top: 50%; transform: translateY(-50%); font-size: 26px; color: var(--faint); transition: transform .25s ease; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { color: var(--soft); padding-bottom: 18px; margin: 0; }

/* 最後的下載 */
.cta { padding: 40px 0 72px; }
.cta .stores { margin-top: 22px; }

/* 聯絡 */
.contact { padding-top: 24px; }
.contact-in { display: flex; gap: 28px; align-items: center; justify-content: center; }
.contact-in img { width: 130px; flex: none; }
.contact h2 { font-size: 28px; margin-bottom: 6px; }
.contact p { margin: 0 0 6px; font-size: 20px; }
.contact .small { font-size: 16px; color: var(--soft); }
.contact .contact-sub { font-size: 18px; color: var(--soft); }

.foot { padding: 28px 0 40px; border-top: 1.5px solid var(--edge); color: var(--soft); font-size: 15px; }
.foot-in { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }
.foot p { margin: 0; }
.foot nav { display: flex; flex-wrap: wrap; gap: 6px 20px; }

/* 背景的故事貼紙（App 故事島的圖）：捲動時各自用不同速度移動，看起來有前有後。
   --d：正的比較遠、跟著捲得慢；負的比較近、捲得快。--ty 是上下移多少 px（site.js 算，不會移出段落），--k 是幅度（手機小一點，site.js 讀），--mx 是滑鼠（只有最上面那段） */
.deco { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.pl {
  position: absolute; display: block;
  translate: calc(var(--mx, 0) * var(--d) * -70px) calc(var(--ty, 0) * 1px);
  animation: float 7s ease-in-out infinite; animation-delay: calc(var(--d) * -20s);
}
.pl img { display: block; width: 100%; height: auto; }
.d-castle { right: -1.5%; top: 3%; width: 116px; }
.d-gull { left: 34%; top: 2%; width: 66px; animation: glide 30s linear infinite; }
@keyframes glide { from { transform: translateX(-46vw) translateY(0); } 50% { transform: translateX(10vw) translateY(-14px); } to { transform: translateX(66vw) translateY(0); } }
.d-wolf { left: 1%; bottom: 14px; width: 78px; animation: sneak 2.6s ease-in-out infinite; }
@keyframes sneak { 0%, 100% { transform: translateX(0) rotate(-3deg); } 50% { transform: translateX(14px) translateY(-6px) rotate(3deg); } }
.d-straw { left: 8%; bottom: 6px; width: 142px; }
.d-mush { left: 37%; bottom: 16px; width: 64px; }
.d-whale { right: 12%; bottom: 10px; width: 120px; }
.d-bean { right: -1%; bottom: 0; width: 112px; }
.d-cy { left: 4%; top: 30px; width: 112px; rotate: -24deg; }
.d-cb { right: 4%; top: 120px; width: 96px; rotate: 28deg; }
.d-cp { left: 11%; top: 210px; width: 76px; rotate: 12deg; }
.d-light { left: -1%; bottom: 6%; width: 124px; }
.d-boat { right: -.5%; top: 8%; width: 118px; }
.d-bean2 { right: -1%; top: 7%; width: 112px; }
.d-tree { left: -1%; bottom: 14%; width: 116px; }
.d-pig { left: 2.5%; top: 9%; width: 62px; }
.d-ncot { left: -1.5%; bottom: -6px; width: 150px; }
.d-nstraw { right: -1%; bottom: -6px; width: 128px; }
.pl .lit { position: absolute; inset: 0; opacity: var(--p2, 1); }
.ways, .shelf { position: relative; }
.ways > .wrap, .shelf > .wrap, .make > .wrap { position: relative; }

/* 特色：孩子塗的、說的都能放進故事（著色本那段捲動帶著走） */
.make { position: relative; padding-bottom: 56px; }
.make-head { text-align: center; max-width: 780px; }
.tag { display: inline-block; margin: 0 0 14px; padding: 2px 16px; border-radius: 999px; background: var(--berry); color: var(--berry-ink); font-size: 16px; }
.make-head h2 { font-size: clamp(30px, 4.4vw, 50px); }
.paint { position: relative; height: 330vh; }
.paint-pin { position: sticky; top: 0; height: 100vh; height: 100svh; display: flex; align-items: center; }
.paint-in { display: grid; grid-template-columns: 290px 1fr; gap: 40px; align-items: center; width: 100%; }
/* 捲動提示（電腦、手機都有，10/30 使用者要求）：釘住的畫面底下一顆深色膠囊，四個點是第幾步，後面寫下一步是什麼。
   觸控裝置畫手指往上滑、寫「往上滑」；有滑鼠的畫滑鼠滾輪、寫「往下捲」（site.js 用 hover／pointer 判斷，加 ph-fine）。
   停著不動 2.5 秒膠囊跳兩下（ph-poke）；演完收起來 */
.paint-hint {
  position: absolute; left: 50%; bottom: calc(26px + env(safe-area-inset-bottom)); translate: -50% 0; margin: 0; z-index: 3;
  display: flex; align-items: center; gap: 10px; white-space: nowrap; padding: 7px 18px 7px 14px;
  background: var(--ink); color: var(--paper); border-radius: 999px; box-shadow: var(--shadow);
  font-size: 16px; line-height: 1.4; transition: opacity .4s, translate .4s;
}
.paint.end .paint-hint { opacity: 0; translate: -50% 12px; }
.paint-hint.ph-poke { animation: ph-hop 1s ease-in-out 2; }
.ph-dots { display: flex; gap: 4px; }
.ph-dots i { width: 7px; height: 7px; border-radius: 50%; background: rgba(255, 248, 234, .3); transition: background-color .3s; }
.ph-dots i.on { background: var(--sun); }
.ph-ic { display: grid; place-items: center; width: 22px; height: 26px; }
.ph-hand { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; animation: ph-swipe 1.6s ease-in-out infinite; }
.ph-mouse { display: none; position: relative; width: 16px; height: 24px; border: 2px solid currentColor; border-radius: 9px; box-sizing: border-box; }
.ph-mouse::after { content: ''; position: absolute; left: 50%; top: 4px; width: 3px; height: 5px; margin-left: -1.5px; border-radius: 2px; background: currentColor; animation: ph-wheel 1.6s ease-in-out infinite; }
.ph-fine .ph-hand { display: none; }
.ph-fine .ph-mouse { display: block; }
@keyframes ph-swipe { 0% { transform: translateY(6px); opacity: 0; } 25% { opacity: 1; } 75% { transform: translateY(-5px); opacity: 1; } 100% { transform: translateY(-7px); opacity: 0; } }
@keyframes ph-wheel { 0% { transform: none; opacity: 1; } 65% { transform: translateY(8px); opacity: 0; } 100% { transform: none; opacity: 0; } }
@keyframes ph-hop { 0%, 100% { transform: none; } 30% { transform: translateY(-9px); } 55% { transform: none; } 75% { transform: translateY(-3px); } }
.paint-title { display: flex; align-items: center; gap: 10px; font-size: 26px; margin: 0 0 14px; }
.paint-title img, .more-text h3 img { width: 44px; }
/* 步驟編號寫在 data-n：手機只顯示現在這一步（其他 display: none），CSS 計數器不算沒顯示的，會每一步都是 1 */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.steps li {
  position: relative; padding: 10px 14px 10px 58px; border-radius: 18px; border: 1.5px solid transparent;
  opacity: .42; transition: opacity .35s, background-color .35s, border-color .35s, transform .35s;
}
.steps li::before {
  content: attr(data-n); position: absolute; left: 12px; top: 12px; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; background: var(--edge); font-size: 17px; line-height: 1; transition: background-color .35s;
}
.steps li.on { opacity: 1; background: var(--paper); border-color: var(--edge); box-shadow: var(--shadow); transform: translateX(8px); }
.steps li.on::before { background: var(--straw); }
.steps li.past { opacity: .7; }
.steps li.past::before { background: var(--leaf); }
/* 電腦、平板的步驟可以點（site.js 加 role=button），點了捲到那一步 */
.steps li[role="button"] { cursor: pointer; }
.steps li[role="button"]:focus-visible { outline: 3px solid var(--sun); outline-offset: 2px; }
@media (hover: hover) { .steps li[role="button"]:not(.on):hover { opacity: .85; background: var(--paper); border-color: var(--edge); } }
.steps b { display: block; font-size: 21px; font-weight: 400; }
.steps span { display: block; color: var(--soft); font-size: 16px; line-height: 1.6; }
.paint-stage { position: relative; aspect-ratio: 16 / 10; background: #fbefd9; border: 1.5px solid var(--edge); border-radius: 28px; overflow: hidden; box-shadow: var(--shadow); }
.paint-stage > * { position: absolute; }
.paint-stage img { display: block; height: auto; }
.paint-stage div > img { width: 100%; }
.p-bun { left: 3%; top: 3%; width: 31%; }
.p-d1 { left: 39%; top: 9%; width: 13%; rotate: -5deg; }
.p-d2 { left: 4%; top: 30%; width: 10%; rotate: 4deg; }
.p-desk { left: 0; right: 0; bottom: 0; height: 17%; background: #e7c999; border-top: 4px solid #d2ab6c; }
.p-prn { left: 3%; bottom: 12%; width: 30%; transform-origin: 50% 100%; }
.p-ppr { left: 38%; bottom: 14%; width: 18%; aspect-ratio: 1 / 1.414; background: #fffdf7; border-radius: 4px; box-shadow: 0 4px 10px rgba(60, 40, 20, .15); opacity: 0; z-index: 1; }
.p-pig { position: absolute; left: 13%; top: 6%; width: 74%; aspect-ratio: 334 / 560; }
.p-pig img { position: absolute; inset: 0; }
.p-cup { left: 58.5%; bottom: 13%; width: 7%; }
.p-cr { left: 0; top: 0; width: 12% !important; opacity: 0; transform-origin: 0 50%; z-index: 3; }
.p-tab { right: 3%; top: 6%; width: 36%; }
.p-scr { position: absolute; left: 9.78%; top: 13.18%; width: 80.56%; height: 74.28%; background: var(--sky); overflow: hidden; }
.s-sun { position: absolute; right: 9%; top: 10%; width: 15%; aspect-ratio: 1; border-radius: 50%; background: var(--sun); }
.s-hill { position: absolute; left: -20%; right: -20%; bottom: -42%; height: 72%; border-radius: 50%; background: var(--leaf); }
.paint-stage .s-straw { position: absolute; left: 8%; bottom: 10%; width: 42%; }
.p-fr { position: relative; }
.p-phone { left: 0; top: 0; width: 20%; opacity: 0; z-index: 4; }
.p-flash { position: absolute; left: 12.91%; top: 10.58%; width: 73.57%; height: 70.77%; background: #fff; opacity: 0; border-radius: 6px; z-index: 1; }
.p-jump { left: 0; top: 0; width: 10%; opacity: 0; z-index: 5; transform-origin: 0 0; }
.p-jump img { transform-origin: 50% 100%; }
.p-jump.landed img { animation: hop2 1s ease-in-out infinite; }
@keyframes hop2 { 0%, 100% { transform: none; } 15% { transform: scaleY(.9); } 45% { transform: translateY(-16%); } 70% { transform: none; } }

.make-more { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.wear, .rec { display: grid; gap: 14px; align-content: start; padding: 20px; background: var(--paper); border: 1.5px solid var(--edge); border-radius: 28px; box-shadow: var(--shadow); }
.wear-stage, .rec-stage { position: relative; height: 270px; border-radius: 20px; background: #fbefd9; overflow: hidden; display: grid; place-items: center; }
.wear-pig { height: 100%; width: auto; }
/* 衣帽間的舞台是故事裡（天空、草地、稻草屋）：換好的衣服直接穿著在故事裡演，一直輕輕跳 */
.wear-stage { background: var(--sky); }
.wear-stage .s-sun { right: 7%; top: 9%; width: 12%; }
.wear-stage .s-hill { bottom: -46%; height: 68%; }
.wear-straw { position: absolute; left: 5%; bottom: 12%; width: 38%; max-width: 190px; }
.wear-tag {
  position: absolute; left: 12px; top: 12px; z-index: 1; display: flex; align-items: center; gap: 6px; padding: 3px 12px 3px 5px;
  border-radius: 999px; background: var(--paper); border: 1.5px solid var(--edge); font-size: 15px; line-height: 1.4;
}
.wear-tag img { width: 24px; height: 24px; }
.wear-act { position: absolute; right: 14%; bottom: 6%; height: 84%; transform-origin: 50% 100%; animation: act 1.8s ease-in-out infinite; }
@keyframes act { 0%, 100% { transform: none; } 25% { transform: translateY(-5%) rotate(-3deg); } 50% { transform: scaleY(.96); } 75% { transform: translateY(-3%) rotate(3deg); } }
.wear-pig.spin { animation: spin .5s ease; }
@keyframes spin { 40% { transform: scaleX(0) translateY(-5%); } }
/* 六顆排一列，放不下就一起縮小（窄手機、平板原本會排成 5＋1） */
.wear-picks { display: flex; gap: 8px; justify-content: center; }
.wear-picks button {
  flex: 1 1 0; min-width: 0; max-width: 54px; aspect-ratio: 4 / 5; padding: 5px 0 0; overflow: hidden; border-radius: 14px; border: 2px solid var(--edge); background: #fff;
  cursor: pointer; transition: transform .2s, border-color .2s, background-color .2s;
}
/* 圖是全身（300×481），按鈕只露出頭：圖放大到按鈕寬的 1.36 倍、置中，跟著按鈕一起縮放。
   全站的 img max-width:100% 會把圖擠窄（10/30 使用者說小豬被左右壓扁），這裡要拿掉 */
.wear-picks button img { width: 136%; max-width: none; height: auto; margin-left: -18%; }
.wear-picks button:hover { transform: translateY(-3px); }
.wear-picks [aria-pressed="true"] { border-color: var(--straw-2); background: #fff3cf; transform: translateY(-3px); }
.more-text h3 { display: flex; align-items: center; gap: 10px; margin: 0 0 4px; font-size: 22px; }
.more-text p { margin: 0; color: var(--soft); }
.rec-stage { place-items: end center; }
.rec-bobo { height: 196px; width: auto; margin-bottom: -4px; }
.say {
  position: absolute; left: 14px; right: 14px; top: 14px; margin: 0; padding: 8px 14px; font-size: 17px; line-height: 1.5;
  background: #fff; border: 1.5px solid var(--edge); border-radius: 18px; opacity: 0; transform: translateY(8px) scale(.96); transition: opacity .45s, transform .45s;
}
.say.on { opacity: 1; transform: none; }
.say b { display: inline-block; margin-right: 8px; padding: 0 10px; border-radius: 999px; background: var(--berry); color: var(--berry-ink); font-size: 14px; font-weight: 400; }
.say + .say b { background: var(--sky); color: var(--ink); }
.rec-ui {
  position: absolute; right: 12px; bottom: 12px; display: flex; align-items: center; gap: 8px; padding: 5px 12px;
  background: #fff; border: 1.5px solid var(--edge); border-radius: 999px; font-size: 15px; font-variant-numeric: tabular-nums;
}
.rec-dot { width: 10px; height: 10px; border-radius: 50%; background: #e0574a; animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: .2; } }
.rec-wave { display: flex; gap: 3px; align-items: center; height: 22px; }
.rec-wave i { width: 3px; height: 100%; border-radius: 2px; background: var(--soft); animation: lvl .9s ease-in-out infinite; animation-delay: calc(var(--n) * -.13s); }
@keyframes lvl { 0%, 100% { transform: scaleY(.25); } 50% { transform: scaleY(1); } }
/* 拼拼圖：碎片從旁邊一片一片飛進拼圖板（3×2，真的拼圖形狀，scripts 外產生的 SVG），拼好了小波狗比讚、整張圖收進「我的拼圖」。一輪一輪由 site.js 控制 */
.pz { display: grid; grid-template-columns: 1.1fr 1fr; gap: 28px; align-items: center; margin-top: 24px; padding: 20px; background: var(--paper); border: 1.5px solid var(--edge); border-radius: 28px; box-shadow: var(--shadow); }
.pz-stage { position: relative; padding: 38px 8px 4px; border-radius: 20px; background: #fbefd9; overflow: hidden; }
.pz-board { display: block; width: 100%; height: auto; overflow: visible; transform-origin: 90% 0; transition: transform .7s cubic-bezier(.5, 0, .3, 1), opacity .6s ease .1s; }
.pz-ghost { opacity: .2; }
.pz-slots { fill: none; stroke: #b9a582; stroke-width: 2; stroke-dasharray: 7 6; transition: opacity .4s; }
.pz-p { transform-box: fill-box; transform-origin: center; transform: translate(var(--x), var(--y)) rotate(var(--r)) scale(.7); }
.pz-p path { fill: none; stroke: #fff; stroke-width: 3; transition: opacity .4s; }
.pz.pz-go .pz-p { animation: pzin .65s cubic-bezier(.3, 1.2, .5, 1) both; animation-delay: calc(var(--i) * .5s + .2s); }
@keyframes pzin { from { transform: translate(var(--x), var(--y)) rotate(var(--r)) scale(.7); } 75% { transform: scale(1.06); } to { transform: none; } }
.pz.pz-done .pz-p { transform: none; }
.pz.pz-done .pz-slots, .pz.pz-done .pz-p path { opacity: 0; }
.pz-star { position: absolute; left: 62%; top: 16%; width: 12%; opacity: 0; transform: scale(.3) rotate(-30deg); transition: opacity .3s, transform .5s cubic-bezier(.3, 1.6, .5, 1); }
.pz.pz-done .pz-star { opacity: 1; transform: none; }
.pz-bobo { position: absolute; right: 1%; bottom: -3%; width: 25%; transform: translateY(105%); transition: transform .5s cubic-bezier(.3, 1.4, .5, 1); }
.pz.pz-done .pz-bobo { transform: none; }
.pz-say { position: absolute; right: 23%; bottom: 30%; margin: 0; padding: 2px 14px; background: #fff; border: 1.5px solid var(--edge); border-radius: 16px; font-size: 18px; opacity: 0; transform: translateY(8px) scale(.9); transition: opacity .35s .25s, transform .35s .25s; }
.pz.pz-done .pz-say { opacity: 1; transform: none; }
.pz.pz-away .pz-board { transform: scale(.1); opacity: 0; }
.pz.pz-away .pz-star, .pz.pz-away .pz-say { opacity: 0; transition-delay: 0s; }
.pz-album { position: absolute; right: 10px; top: 8px; display: flex; align-items: center; gap: 6px; padding: 1px 6px 1px 4px; background: var(--paper); border: 1.5px solid var(--edge); border-radius: 999px; font-size: 15px; line-height: 1.6; }
.pz-album img { width: 26px; }
.pz-album b { font-weight: 400; min-width: 1.6em; padding: 0 5px; border-radius: 999px; background: var(--sun); text-align: center; }
.pz-album.bump { animation: bump .5s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes bump { 40% { transform: scale(1.2); } }
.pz-list { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 10px; }
.pz-list li { display: flex; align-items: center; gap: 12px; color: var(--soft); line-height: 1.5; }
.pz-list li > img { width: 40px; flex: none; }
.pz-lv { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; width: 40px; flex: none; }
.pz-lv i { display: grid; place-items: center; height: 19px; border-radius: 6px; font-size: 11px; font-style: normal; line-height: 1; color: var(--ink); }
.l4 { background: var(--leaf); } .l6 { background: var(--sky); } .l9 { background: var(--sun); } .l12 { background: var(--berry); }

/* 平板 */
@media (max-width: 960px) {
  .pass-covers { grid-template-columns: repeat(5, 1fr); }
  .pass-more { grid-column: span 3; font-size: 14px; }
  .books { grid-template-columns: repeat(3, 1fr); }
  .d-tree { display: none; } /* 平板兩邊沒空位，書櫃左下的樹會蓋到最後一排的書名 */
  .grid6 { grid-template-columns: repeat(2, 1fr); }
  .hero-in { gap: 36px; }
  .paint-in { grid-template-columns: 240px 1fr; gap: 28px; }
}
/* 手機 */
@media (max-width: 760px) {
  body { font-size: 17px; }
  h1 { font-size: clamp(26px, 8.2vw, 40px); }
  .hero h1 { font-size: clamp(36px, 11.8vw, 50px); }
  section { padding: 60px 0; }
  .nav { display: none; }
  .top-in { gap: 12px; } /* 320 寬時「小波狗說故事」才不會斷成兩行 */
  .lang { margin-left: auto; }
  .hero { padding: 8px 0 56px; }
  .hero-in, .split { grid-template-columns: 1fr; gap: 28px; }
  .hero-stage { order: -1; margin: 10px 6px 26px; }
  .hero-bobo { width: 25%; left: -5%; bottom: -20%; }
  .tablet { padding: 8px; border-radius: 22px; }
  .tablet video { border-radius: 15px; }
  .done { inset: 8px; border-radius: 15px; }
  .now { font-size: 15px; bottom: -20px; }
  .now img { width: 26px; }
  .split.rev > :first-child { order: 0; }
  .lead { font-size: 18px; }
  .store { min-width: 0; flex: 1 1 150px; font-size: 17px; gap: 8px; padding: 10px 12px; }
  .store svg { width: 24px; height: 24px; }
  .try { padding-top: 24px; }
  .blow { width: 118px; height: 118px; font-size: 17px; }
  .stage { grid-template-columns: 1fr; gap: 26px; }
  .ctrl { flex-direction: row; justify-content: center; gap: 22px; }
  .zy-big { margin: -10px 0 0; padding: 8px 8px 10px; font-size: min(7.2vw, 34px); border-radius: 18px; }
  .plan-row { grid-template-columns: 1fr; gap: 22px; }
  .plan-pass { --cut: 150px; grid-template-columns: 1fr; grid-template-rows: var(--cut) auto;
    -webkit-mask: radial-gradient(circle 14px at 0 var(--cut), #0000 96%, #000) left / 51% 100% no-repeat, radial-gradient(circle 14px at 100% var(--cut), #0000 96%, #000) right / 51% 100% no-repeat;
    mask: radial-gradient(circle 14px at 0 var(--cut), #0000 96%, #000) left / 51% 100% no-repeat, radial-gradient(circle 14px at 100% var(--cut), #0000 96%, #000) right / 51% 100% no-repeat; }
  .pass-stub { grid-template-columns: auto auto; justify-content: center; column-gap: 16px; border-right: 0; border-bottom: 2.5px dashed #e3c27c; padding: 12px; }
  .pass-stub img { height: 110px; grid-row: span 2; }
  .pass-stub h3 { align-self: end; }
  .pass-stub span { align-self: start; justify-self: start; }
  .pass-body { padding: 18px 18px 18px; }
  .three, .two, .grid6 { grid-template-columns: 1fr; }
  .card { display: grid; grid-template-columns: 96px 1fr; gap: 4px 16px; text-align: left; align-items: center; padding: 18px; }
  .card img { height: 100px; grid-row: span 2; margin: 0; }
  .card p { margin: 0; }
  .card:nth-child(n) { --rot: 0deg; }
  .books { grid-template-columns: repeat(2, 1fr); gap: 20px 14px; }
  .books span { font-size: 16px; }
  .books .books-more { font-size: 17px; padding: 12px 14px; gap: 10px; }
  .books .books-more img { width: 34px; height: 34px; }
  .sun, .moon { right: 6%; scale: .75; }
  .contact-in { flex-direction: column; text-align: center; }
  .contact-in img { width: 110px; }
  .hero { padding-bottom: 96px; }
  /* 手機：貼紙少一點、小一點，移動幅度小一點，不壓到字。主畫面只留三張、分開放：海鷗在「iPhone・iPad・Android」右邊，
     大野狼從左下角探頭、稻草屋在右下角；雲、香菇、鯨魚和大部分星星不放（10/30 晚上：五張排成一排太亂） */
  .pl { --k: .55; }
  .d-castle, .d-bean, .d-mush, .d-whale, .d-cp, .d-light, .d-tree, .d-pig, .cloud, .s1, .s2, .s4, .s5 { display: none; }
  .d-gull { width: 42px; left: auto; right: 6%; top: calc(56.25vw + 50px); animation: float 6s ease-in-out infinite; }
  .d-gull img { transform: scaleX(-1); }
  .d-wolf { width: 56px; left: 1%; bottom: 10px; }
  .d-straw { width: 96px; left: auto; right: -4%; bottom: 0; } /* 再高會碰到上面那行「不用登入」 */
  .s3 { left: 44%; bottom: 46px; width: 16px; height: 16px; }
  .d-cy { width: 58px; top: 2px; left: 3%; }
  .d-cb { width: 52px; top: 8px; right: 3%; }
  .d-boat { width: 56px; top: 4px; right: 1%; }
  .d-bean2 { width: 52px; top: -10px; right: 1%; }
  .d-ncot { width: 92px; }
  .d-nstraw { width: 80px; }
  .paint { height: 300vh; }
  .paint-in { grid-template-columns: 1fr; gap: 14px; }
  .paint-title { font-size: 22px; margin-bottom: 8px; }
  .paint-title img { width: 36px; }
  .steps li:not(.on) { display: none; }
  .steps li.on { transform: none; }
  .make-more { grid-template-columns: 1fr; }
  .pz { grid-template-columns: 1fr; gap: 16px; }
  .paint-hint { bottom: calc(18px + env(safe-area-inset-bottom)); gap: 8px; padding: 6px 15px 6px 12px; font-size: 15px; }
  .pz-say { font-size: 15px; }
  .wear-stage, .rec-stage { height: 240px; }
  .rec-bobo { height: 170px; }
  .wear-picks { gap: 6px; }
  .wear-picks button { max-width: 42px; border-radius: 12px; }
  .make-also { font-size: 16px; text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .pl { translate: none; }
  .paint { height: auto; }
  .paint-pin { position: static; height: auto; padding: 24px 0; }
  .paint-hint { display: none; }
  .steps li { opacity: 1; }
}
