@charset "UTF-8";
/* ============================================================
   捲動故事頁「一杯茶的來歷」（tea_story.php）
   色票、按鈕（.btn_sand／.btn_line）與 .eyebrow 沿用 style.css，這裡只寫本頁的版型。

   和首頁（home_story.css）最大的不同：這一頁捲的是**視窗本身**，不是某個容器。
   首頁沒有頁尾、整頁是一個滿版相框才需要容器捲動；這一頁有頁尾、有錨點導覽，
   用視窗捲動才能讓 #錨點、鍵盤 Home/End 與瀏覽器的回到上次位置都照常運作。

   動畫的啟用條件寫死在兩個地方，兩邊必須一致：
     CSS：@media (min-width: 901px) and (prefers-reduced-motion: no-preference)
     JS ：js/page/tea_story.js 的 canAnimate()
   ≤900px 或使用者關閉動態效果時，所有釘住、橫捲、疊層一律不啟用，
   版面退成單純的直向堆疊——那些情況下一個畫面塞不下一區，硬做只會把內容裁掉。
   ============================================================ */

/* ===== 頁首：開場是滿版圖，讓頁首浮在圖上 =====
   捲離開場後由 JS 掛上 .is_scrolled，頁首變回實色（維持選單可讀）。
   改成 fixed 不是為了好看：原本的 sticky 會先佔掉 76px 的版面高度，
   開場就被往下推、底部的「向下捲動」會掉到畫面外。 */
.tea_story_page .site_header {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	background: linear-gradient(to bottom, rgba(21, 21, 19, .86) 0%, rgba(21, 21, 19, .42) 55%, rgba(21, 21, 19, 0) 100%);
	border-bottom: 0;
	-webkit-backdrop-filter: none;
	backdrop-filter: none;
	transition: background .3s;
}
.tea_story_page.is_scrolled .site_header {
	background: rgba(21, 21, 19, .96);
	border-bottom: 1px solid var(--line);
	-webkit-backdrop-filter: saturate(140%) blur(8px);
	backdrop-filter: saturate(140%) blur(8px);
}

/* 頁首是 sticky，錨點捲過去時要讓出它的高度，標題才不會被壓在選單底下 */
.tea_story_page {
	scroll-padding-top: 76px;
}

/* ===== 共用 ===== */
.ts_sec {
	position: relative;
	overflow: hidden;
}
.ts_title {
	font-family: var(--serif);
	font-size: clamp(26px, 4vw, 44px);
	font-weight: 600;
	line-height: 1.3;
	margin: 0 0 18px;
}
.ts_lead {
	max-width: 46em;
	font-size: clamp(15px, 1.2vw, 17px);
	line-height: 2;
	color: var(--muted);
	margin: 0 0 14px;
}
.ts_btns { margin: 26px 0 0; }

/* 進場：預設就是最終樣子，有動畫能力時才在 JS 啟用前壓成未進場
   （JS 沒載到、或擋在條件外時，內容一樣看得見） */
[data-reveal] { opacity: 1; }
.ts_ready [data-reveal] {
	opacity: 0;
	transform: translateY(26px);
	transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .3, 1);
}
.ts_ready [data-reveal].is_in {
	opacity: 1;
	transform: none;
}

/* ===== 右側區塊導覽 ===== */
.ts_dots {
	position: fixed;
	top: 50%;
	right: 18px;
	z-index: 90;
	transform: translateY(-50%);
	display: none;
}
.ts_dots ul { list-style: none; margin: 0; padding: 0; }
.ts_dots li + li { margin-top: 14px; }
.ts_dots a {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 8px;
	color: var(--muted);
	text-decoration: none;
	font-size: 12px;
	letter-spacing: .1em;
}
.ts_dot_mark {
	flex: none;
	width: 9px;
	height: 9px;
	border: 1px solid var(--line-2);
	border-radius: 50%;
	background: transparent;
	transition: background .25s, border-color .25s, transform .25s;
}
.ts_dot_ta {
	opacity: 0;
	transform: translateX(6px);
	transition: opacity .25s, transform .25s;
	white-space: nowrap;
}
.ts_dots a:hover .ts_dot_ta,
.ts_dots a:focus-visible .ts_dot_ta { opacity: 1; transform: none; }
.ts_dots a:hover .ts_dot_mark { border-color: var(--gold); }
.ts_dots a.is_on { color: var(--gold-2); }
.ts_dots a.is_on .ts_dot_mark {
	background: var(--gold);
	border-color: var(--gold);
	transform: scale(1.25);
}

/* ===== ① 開場 ===== */
.ts_hero {
	position: relative;
	min-height: 100vh;
	min-height: 100dvh;
	display: flex;
	align-items: center;
	padding: 120px 24px 90px;
}
.ts_hero_media {
	position: absolute;
	inset: 0;
	z-index: 0;
	/* 視差時圖要能往上走一段又不露出底邊，所以先放大一點 */
	will-change: transform;
}
.ts_hero_media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.ts_hero_shade {
	position: absolute;
	inset: 0;
	background: linear-gradient(to bottom, rgba(21, 21, 19, .62) 0%, rgba(21, 21, 19, .34) 45%, rgba(21, 21, 19, .86) 100%);
}
.ts_hero_text {
	position: relative;
	z-index: 1;
	width: 100%;
	max-width: var(--wrap);
	margin: 0 auto;
}
.ts_hero_title {
	font-family: var(--serif);
	font-size: clamp(34px, 7vw, 76px);
	font-weight: 600;
	line-height: 1.22;
	letter-spacing: .04em;
	margin: 0 0 18px;
	text-shadow: 0 2px 24px rgba(0, 0, 0, .45);
}
.ts_hero_sub {
	font-size: clamp(15px, 1.6vw, 19px);
	line-height: 1.9;
	color: var(--sand-2);
	margin: 0 0 30px;
}
.ts_hero_btns {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}
.ts_hint {
	position: absolute;
	left: 50%;
	bottom: 26px;
	z-index: 1;
	transform: translateX(-50%);
	margin: 0;
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 12px;
	letter-spacing: .2em;
	color: var(--sand);
}
.ts_hint i { animation: ts_hint_move 1.8s ease-in-out infinite; }
@keyframes ts_hint_move {
	0%, 100% { transform: translateY(0); }
	50%      { transform: translateY(5px); }
}

/* ===== ② 產地：海拔尺 ===== */
.ts_alt {
	position: relative;
	padding: 110px 0;
	background: var(--bg-2);
}
.ts_alt_bg { position: absolute; inset: 0; z-index: 0; }
.ts_alt_bg img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	opacity: .32;
}
.ts_alt_shade {
	position: absolute;
	inset: 0;
	background: linear-gradient(to right, rgba(49, 49, 46, .96) 0%, rgba(49, 49, 46, .72) 55%, rgba(49, 49, 46, .3) 100%);
}
.ts_alt_inner {
	position: relative;
	z-index: 1;
	display: flex;
	align-items: stretch;
	gap: clamp(24px, 5vw, 70px);
}
.ts_num {
	font-family: var(--display);
	font-size: clamp(48px, 9vw, 104px);
	line-height: 1;
	color: var(--gold-2);
	margin: 0 0 18px;
	font-variant-numeric: tabular-nums;
}
.ts_num_unit {
	font-family: var(--sans);
	font-size: .26em;
	letter-spacing: .1em;
	margin-left: .3em;
	color: var(--muted);
}

/* 海拔尺：固定的刻度＋跟著捲動長高的填色 */
.ts_ruler {
	position: relative;
	flex: none;
	width: 64px;
	min-height: 330px;
	border-left: 1px solid var(--line-2);
	display: none;
}
.ts_ruler_fill {
	position: absolute;
	left: -2px;
	bottom: 0;
	width: 3px;
	height: 0;
	background: linear-gradient(to top, var(--gold), var(--gold-2));
}
.ts_ruler_tick {
	position: absolute;
	left: 0;
	top: var(--at);
	width: 100%;
	height: 1px;
	background: var(--line-2);
}
.ts_ruler_tick i {
	position: absolute;
	left: 10px;
	top: -8px;
	font-style: normal;
	font-size: 11px;
	letter-spacing: .1em;
	color: var(--subtle);
	white-space: nowrap;
}

/* ===== ③ 工序 ===== */
.ts_craft {
	padding: 100px 0;
	background: var(--bg);
}
.ts_craft_head { margin-bottom: 44px; }
.ts_craft_scroll { position: relative; }
.ts_craft_track {
	display: grid;
	gap: 18px;
	max-width: var(--wrap);
	margin: 0 auto;
	padding: 0 24px;
}
.ts_step {
	position: relative;
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--r-lg);
	padding: 26px 24px 28px;
}
.ts_step_img {
	margin: -26px -24px 20px;
	border-radius: var(--r-lg) var(--r-lg) 0 0;
	overflow: hidden;
	aspect-ratio: 16 / 9;
}
.ts_step_img img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.ts_step_no {
	font-family: var(--display);
	font-size: 34px;
	line-height: 1;
	color: var(--gold);
	margin: 0 0 14px;
	padding-bottom: 14px;
	border-bottom: 1px solid var(--line);
}
.ts_step_ta {
	font-family: var(--serif);
	font-size: 22px;
	font-weight: 600;
	margin: 0 0 10px;
}
.ts_step_txt {
	font-size: 15px;
	line-height: 1.95;
	color: var(--muted);
	margin: 0;
}

/* ===== ④ 茶色軸 ===== */
.ts_color { background: var(--bg); }
/* 預設（手機、關閉動態效果）：整區維持站內底色，五款茶各自是一張自己顏色的卡片。
   桌機版才改成「整區換色、一次一款」，見下方的 @media。 */
.ts_color_stage {
	background: var(--bg);
	padding: 90px 0;
}
.ts_color_inner { position: relative; }
.ts_color_head { margin-bottom: 36px; }
.ts_color_head .eyebrow { color: currentColor; opacity: .7; }
.ts_color_panels { position: relative; }

.ts_tea {
	display: grid;
	gap: 26px;
	align-items: center;
	padding: 30px 24px 34px;
	background: var(--tea, var(--card));
	color: var(--tea-on, var(--text));
	border-radius: var(--r-lg);
}
.ts_tea + .ts_tea { margin-top: 14px; }
.ts_tea_mark {
	width: clamp(130px, 30vw, 230px);
	aspect-ratio: 1;
	border-radius: 50%;
	overflow: hidden;
	background: rgba(255, 255, 255, .12);
	box-shadow: 0 18px 44px rgba(0, 0, 0, .22);
}
.ts_tea_mark img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.ts_tea_no {
	font-family: var(--display);
	font-size: 15px;
	letter-spacing: .22em;
	opacity: .72;
	margin: 0 0 10px;
}
.ts_tea_ta {
	font-family: var(--serif);
	font-size: clamp(28px, 4.6vw, 52px);
	font-weight: 600;
	line-height: 1.25;
	margin: 0 0 14px;
}
.ts_tea_txt {
	max-width: 30em;
	font-size: clamp(15px, 1.2vw, 17px);
	line-height: 2;
	opacity: .88;
	margin: 0 0 24px;
}
.ts_tea_btn { margin: 0; }
/* 按鈕用「這款茶的字色」當底、茶色當字：深色茶（烏龍、紅茶）是淺鈕，
   淺色茶（東方美人）自動翻成深鈕，不會淺底淺字 */
.ts_tea_btn .btn_sand {
	background: var(--tea-on, var(--sand));
	border-color: var(--tea-on, var(--sand));
	color: var(--tea, var(--ink-text));
}
.ts_tea_btn .btn_sand:hover {
	opacity: .86;
	background: var(--tea-on, var(--sand));
	border-color: var(--tea-on, var(--sand));
}

/* 色軸進度列：跳頁的行為要有釘住的色軸才成立（JS 只在桌機綁 click），
   所以沒啟用動畫時整條不顯示——按了沒反應的按鈕比沒有按鈕糟。 */
.ts_color_bar {
	display: none;
	list-style: none;
	flex-wrap: wrap;
	gap: 8px 18px;
	margin: 34px 0 0;
	padding: 0;
}
.ts_color_bar button {
	display: flex;
	align-items: center;
	gap: 8px;
	background: none;
	border: 0;
	padding: 4px 0;
	font-size: 13px;
	letter-spacing: .08em;
	color: inherit;
	opacity: .55;
	cursor: pointer;
	transition: opacity .25s;
}
.ts_color_bar button span {
	display: block;
	width: 26px;
	height: 2px;
	background: currentColor;
	opacity: .5;
	transition: width .3s, opacity .3s;
}
.ts_color_bar button:hover { opacity: .9; }
.ts_color_bar li.is_on button { opacity: 1; }
.ts_color_bar li.is_on button span { width: 46px; opacity: 1; }

/* ===== ⑤ 檢驗 ===== */
.ts_trust {
	padding: 100px 0;
	background: var(--bg-2);
}
.ts_trust_head { margin-bottom: 46px; }
.ts_facts {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 18px;
	margin-bottom: 44px;
}
.ts_fact {
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--r-lg);
	padding: 30px 26px;
	text-align: center;
}
.ts_fact_no {
	font-family: var(--display);
	font-size: clamp(38px, 5vw, 58px);
	line-height: 1;
	color: var(--gold-2);
	margin: 0 0 10px;
	font-variant-numeric: tabular-nums;
}
.ts_fact_no small {
	font-family: var(--sans);
	font-size: .3em;
	letter-spacing: .08em;
	color: var(--muted);
	margin-left: .2em;
}
.ts_fact_ta {
	font-size: 14px;
	letter-spacing: .06em;
	color: var(--muted);
	margin: 0;
}

/* ===== ⑥ 行動 ===== */
.ts_cta {
	position: relative;
	padding: 120px 0;
}
.ts_cta_bg { position: absolute; inset: 0; z-index: 0; }
.ts_cta_bg img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.ts_cta_shade {
	position: absolute;
	inset: 0;
	background: linear-gradient(to right, rgba(21, 21, 19, .92) 0%, rgba(21, 21, 19, .66) 60%, rgba(21, 21, 19, .34) 100%);
}
.ts_cta_inner { position: relative; z-index: 1; }
.ts_cta_btns {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-top: 28px;
}

/* ============================================================
   手機與小平板（≤900px）：全部退成直向堆疊
   ============================================================ */
@media (max-width: 900px) {
	.ts_hero { padding: 100px 20px 80px; min-height: 92vh; }
	.ts_alt, .ts_craft, .ts_trust { padding: 70px 0; }
	.ts_cta { padding: 80px 0; }
	.ts_alt_shade {
		background: linear-gradient(to bottom, rgba(49, 49, 46, .9) 0%, rgba(49, 49, 46, .84) 100%);
	}
	.ts_color_stage { padding: 64px 0; }
	.ts_tea { padding: 24px 20px 28px; }
	.ts_tea_mark { width: 118px; }
	.ts_cta_shade {
		background: linear-gradient(to bottom, rgba(21, 21, 19, .88) 0%, rgba(21, 21, 19, .82) 100%);
	}
	/* 手機的 CTA 按鈕排成整列，拇指好按 */
	.ts_cta_btns .btn_sand,
	.ts_cta_btns .btn_line { flex: 1 1 100%; }
}

/* ============================================================
   桌機且使用者沒有關閉動態效果：才啟用釘住、橫捲與疊層
   （條件要與 js/page/tea_story.js 的 canAnimate() 一致）
   ============================================================ */
@media (min-width: 901px) and (prefers-reduced-motion: no-preference) {

	/* ② 海拔尺：這時才出現，沒有捲動驅動就不需要這根尺 */
	.ts_ruler { display: block; }
	.ts_alt { padding: 130px 0; }
	.ts_alt_text { flex: 1; align-self: center; }

	/* ③ 工序：釘住的橫向軌道 */
	.ts_craft { padding: 0 0 110px; }
	.ts_craft_head { padding-top: 110px; }
	.ts_craft_scroll {
		height: 100vh;
		height: 100dvh;
		display: flex;
		align-items: center;
		overflow: hidden;
	}
	.ts_craft_track {
		flex: 0 0 auto;
		display: flex;
		gap: 28px;
		max-width: none;
		padding: 0 max(24px, calc((100vw - var(--wrap)) / 2 + 24px));
		will-change: transform;
	}
	.ts_step {
		flex: 0 0 auto;
		width: 330px;
		/* 卡片等高才像一條軌道；高度配合最長的那一張（有照片的第一步） */
		min-height: 340px;
	}
	.ts_step_pic { width: 460px; }

	/* ④ 茶色軸：整區釘住，五頁疊在同一個位置互相淡入淡出。
	      底色不再是卡片各自的顏色，改成整區一起換（--stage／--stage-on 由 JS 寫入）。 */
	.ts_color_stage {
		height: 100vh;
		height: 100dvh;
		display: flex;
		align-items: center;
		padding: 0;
		background: var(--stage, var(--olive));
		color: var(--stage-on, var(--paper));
		transition: background-color .2s linear;
	}
	.ts_tea_btn .btn_sand,
	.ts_tea_btn .btn_sand:hover {
		background: var(--stage-on, var(--sand));
		border-color: var(--stage-on, var(--sand));
		color: var(--stage, var(--ink-text));
	}
	.ts_color_panels {
		/* 疊起來之後高度塌掉，給一個固定高度撐住版面 */
		min-height: 46vh;
	}
	.ts_tea {
		position: absolute;
		inset: 0;
		grid-template-columns: auto 1fr;
		gap: clamp(30px, 5vw, 76px);
		padding: 0;
		background: transparent;
		color: inherit;
		border-radius: 0;
		opacity: 0;
		visibility: hidden;
		transform: translateY(18px);
		transition: opacity .45s ease, transform .55s cubic-bezier(.2, .7, .3, 1), visibility .45s;
	}
	.ts_tea + .ts_tea { margin-top: 0; }
	.ts_tea.is_on {
		opacity: 1;
		visibility: visible;
		transform: none;
	}

	/* 區塊導覽只在桌機出現（手機上它會壓到內容） */
	.ts_dots { display: block; }
	.ts_color_bar { display: flex; }
}

/* 使用者關閉動態效果：連純 CSS 的提示動畫也停掉 */
@media (prefers-reduced-motion: reduce) {
	.ts_hint i { animation: none; }
	.ts_ready [data-reveal] {
		opacity: 1;
		transform: none;
		transition: none;
	}
	.tea_story_page { scroll-behavior: auto; }
}
