@font-face {
  font-family: "ChenYu Luoyan";
  src: url("../assets/fonts/chenyu-luoyan-subset.woff2") format("woff2");
  font-display: swap;
}

@font-face {
  font-family: "jf open Huninn";
  src: url("../assets/fonts/jf-openhuninn-subset.woff2") format("woff2");
  font-display: swap;
}

:root {
  --cream: #FBF4E4;
  --ink: #2A2113;
  --brand-orange: #F2A900;
  --brand-green: #3FA34D;

  --stroke-gold: #B08A3E;
  --mtn-green: #4C8C52;
  --mtn-yellow: #EFD24A;
  --mtn-front: #E2672E;

  --flavor-fresh: #E8622C;
  --flavor-rich: #2FA5A0;
  --flavor-mango: #E0A527;

  --container: min(100%, 1440px);
  --gutter: clamp(20px, 5vw, 64px);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  -moz-text-size-adjust: 100%;
}

body {
  font-family: "jf open Huninn", "Noto Sans TC", sans-serif;
  background: var(--cream);
  color: var(--ink);
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  -moz-text-size-adjust: 100%;
}

img { max-width: 100%; display: block; }

.container {
  width: var(--container);
  margin-inline: auto;
}

/* ---------- 開場動畫 ---------- */
#intro-splash {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: #1E2A1C;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

#introSvg {
  width: clamp(140px, 30vw, 220px);
  height: auto;
  overflow: visible;
}

#glowCircle {
  opacity: 0;
  transform-origin: 238.5px 266.5px;
  transform: scale(0.4);
}

.skip-hint {
  position: absolute;
  bottom: 6vh;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(251, 244, 228, 0.55);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  opacity: 0;
}

/* ---------- 左上角：漢堡選單開關 + 品牌角標 ---------- */
.topbar-left {
  position: fixed;
  top: 24px;
  left: 24px;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 14px;
}

.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  border: none;
  background: none;
  padding: 0;
  cursor: pointer;
  opacity: 0.9;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-toggle:hover { transform: scale(1.05); opacity: 1; }

.menu-toggle-bar {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--ink);
  border-radius: 1px;
}

.brand-mark {
  display: block;
  width: 48px;
  opacity: 0.9;
}

/* ---------- 側邊選單抽屜 ---------- */
.drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: rgba(42, 33, 19, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.drawer-overlay.is-open { opacity: 1; pointer-events: auto; }

.side-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 50;
  width: min(360px, 100%);
  background: var(--cream);
  border-right: 1px solid rgba(176, 138, 62, 0.35);
  box-shadow: 16px 0 40px rgba(42, 33, 19, 0.18);
  display: flex;
  flex-direction: column;
  padding: 80px 28px 32px;
  transform: translateX(-100%);
  opacity: 0;
  transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s ease;
  overflow-y: auto;
}

.side-drawer.is-open { transform: translateX(0); opacity: 1; }

@media (max-width: 600px) {
  .side-drawer { width: 100%; }
}

.drawer-close {
  position: absolute;
  top: 20px;
  right: 20px;
  border: none;
  background: none;
  font-size: 1.75rem;
  line-height: 1;
  color: var(--ink);
  cursor: pointer;
}

.drawer-ridge { margin-bottom: 2rem; }

.drawer-ridge svg { width: 100%; height: auto; overflow: visible; }

.drawer-sun { fill: var(--brand-orange); opacity: 0.85; }

.drawer-ridge-fill {
  fill: var(--mtn-green);
  fill-opacity: 0.5;
  stroke: none;
}

.drawer-ridge-line {
  fill: none;
  stroke: var(--stroke-gold);
  stroke-width: 3;
  stroke-linejoin: round;
  stroke-linecap: round;
}

.ridge-nav { position: relative; flex: 1; }

.trail-line {
  position: absolute;
  left: 7px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: rgba(176, 138, 62, 0.3);
}

.trail-fill {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 0%;
  background: var(--brand-orange);
  transition: height 0.4s ease;
}

.ridge-list {
  position: relative;
  z-index: 1;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.ridge-node {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  text-decoration: none;
  color: var(--ink);
}

.node-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--cream);
  border: 2px solid var(--stroke-gold);
  flex-shrink: 0;
  transition: 0.3s;
}

.node-icon { font-size: 1.1rem; }

.node-label {
  font-size: 0.9rem;
  letter-spacing: 0.05em;
}

.ridge-node.is-active .node-dot {
  background: var(--brand-orange);
  border-color: var(--brand-orange);
  box-shadow: 0 0 0 4px rgba(242, 169, 0, 0.2);
}

.ridge-node.is-active .node-label {
  font-weight: 700;
}

.drawer-cta {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(176, 138, 62, 0.25);
  text-align: center;
}

.drawer-line-btn { width: 100%; }

.drawer-phone {
  margin-top: 0.9rem;
  font-size: 0.8rem;
  color: #5a4f3a;
}

/* ---------- 山景固定背景 ---------- */
.mountain-scene {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.mountain-scene svg {
  width: 100%;
  height: 100%;
}

.stroke-only {
  fill: none;
  stroke: var(--stroke-gold);
  stroke-width: 3;
  stroke-linejoin: round;
}

.ridge {
  stroke-width: 2;
  opacity: 0.7;
}

.fillable {
  stroke: var(--stroke-gold);
  stroke-width: 3;
  stroke-linejoin: round;
  fill-opacity: 0;
  transition: fill-opacity 0.6s ease;
}

.fillable[data-fill="mtn-green"] { fill: var(--mtn-green); }
.fillable[data-fill="mtn-yellow"] { fill: var(--mtn-yellow); }
.fillable[data-fill="mtn-front"] { fill: var(--mtn-front); }

.sun-ring {
  fill: none;
  stroke: var(--stroke-gold);
  stroke-width: 2.5;
}

.sun-rays line {
  stroke: var(--stroke-gold);
  stroke-width: 2.5;
  stroke-linecap: round;
}

.tint {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  mix-blend-mode: multiply;
}

.tint-fresh { background: var(--flavor-fresh); }
.tint-rich { background: var(--flavor-rich); }

/* ---------- 版面 ---------- */
main { position: relative; z-index: 1; }

section {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6vh var(--gutter);
}

/* ---------- Hero ---------- */
#hero { text-align: center; }

.hero-content { width: var(--container); max-width: 720px; }

.eyebrow {
  font-size: 0.9rem;
  letter-spacing: 0.35em;
  color: var(--stroke-gold);
  margin-bottom: 1.5rem;
}

.headline {
  font-family: "ChenYu Luoyan", "Noto Sans TC", cursive;
  font-size: clamp(3.9rem, 14.5vw, 9rem);
  line-height: 1;
  color: var(--ink);
  text-shadow: 0 4px 24px rgba(255,255,255,0.6);
}

.script {
  font-family: "Sacramento", cursive;
  font-size: clamp(1.8rem, 5vw, 3rem);
  color: var(--brand-orange);
  margin-top: 0.5rem;
}

.tagline {
  margin-top: 1.5rem;
  font-size: clamp(1rem, 2vw, 1.25rem);
  letter-spacing: 0.05em;
  color: var(--ink);
}

.reveal-1, .reveal-2, .reveal-3, .reveal-4 {
  opacity: 0;
  transform: translateY(24px);
}

.scroll-hint {
  position: absolute;
  bottom: 6vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  opacity: 0;
}

.scroll-hint span {
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  color: var(--stroke-gold);
}

.scroll-hint i {
  width: 1px;
  height: 36px;
  background: var(--stroke-gold);
  position: relative;
  overflow: hidden;
}

.scroll-hint i::after {
  content: "";
  position: absolute;
  top: -100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--ink);
  animation: scrollLine 1.8s ease-in-out infinite;
}

@keyframes scrollLine {
  0% { top: -100%; }
  60% { top: 100%; }
  100% { top: 100%; }
}

.hero-bottles {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  display: flex;
  align-items: flex-end;
  z-index: 1;
  pointer-events: none;
}

.bottle-silhouette {
  aspect-ratio: 700 / 2818;
  background-color: var(--stroke-gold);
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: bottom center;
  mask-position: bottom center;
  opacity: 0.55;
}

.bottle-silhouette.fresh {
  height: 38vh;
  -webkit-mask-image: url("../assets/img/bottle-fresh.webp");
  mask-image: url("../assets/img/bottle-fresh.webp");
  margin-left: -18px;
  z-index: 2;
}

.bottle-silhouette.rich {
  height: 33vh;
  -webkit-mask-image: url("../assets/img/bottle-rich.webp");
  mask-image: url("../assets/img/bottle-rich.webp");
  margin-right: -18px;
  opacity: 0.4;
  z-index: 1;
}

/* ---------- 品牌故事 ---------- */
#story { text-align: center; gap: 6vh; }

.story-intro { width: var(--container); max-width: 880px; }

.story-intro h2 {
  font-family: "ChenYu Luoyan", "Noto Sans TC", cursive;
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: 1.25rem;
}

.story-intro p {
  line-height: 1.9;
  color: var(--ink);
}

.story-photo {
  position: relative;
  width: var(--container);
  max-width: 1160px;
  height: clamp(320px, 38vw, 480px);
  overflow: hidden;
  border-radius: 24px;
  opacity: 0;
  transform: translateY(32px);
}

.story-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.story-photo figcaption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 1.5rem;
  color: var(--cream);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6), 0 0 10px rgba(0, 0, 0, 0.35);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  z-index: 1;
}

.story-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(220px, 1fr));
  gap: 24px;
  width: var(--container);
  max-width: 1300px;
}

.story-card {
  background: rgba(251, 244, 228, 0.85);
  border: 1px solid rgba(176, 138, 62, 0.35);
  border-radius: 8px;
  padding: 2.5rem 1.75rem;
  backdrop-filter: blur(6px);
  opacity: 0;
  transform: translateY(32px);
}

.story-icon {
  font-size: 2.25rem;
  display: block;
  margin-bottom: 1rem;
}

.story-card h3 {
  font-size: 1.15rem;
  letter-spacing: 0.05em;
  margin-bottom: 0.75rem;
  color: var(--ink);
}

.story-card p {
  font-size: 0.9rem;
  line-height: 1.7;
  color: #5a4f3a;
}

/* ---------- 工藝流程 ---------- */
#craft { text-align: center; gap: 5vh; }

.craft-intro h2 {
  font-family: "ChenYu Luoyan", "Noto Sans TC", cursive;
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: 1.25rem;
}

.craft-intro p { line-height: 1.9; }

.craft-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
  max-width: 1100px;
}

.craft-step {
  flex: 1;
  background: rgba(251, 244, 228, 0.85);
  border: 1px solid rgba(176, 138, 62, 0.35);
  border-radius: 8px;
  padding: 2.5rem 1.75rem;
  backdrop-filter: blur(6px);
  opacity: 0;
  transform: translateY(32px);
}

.step-no {
  display: inline-block;
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  color: var(--stroke-gold);
  margin-bottom: 0.75rem;
}

.craft-step h3 { font-size: 1.4rem; margin-bottom: 0.75rem; }

.craft-step p { font-size: 0.9rem; line-height: 1.7; color: #5a4f3a; }

.craft-connector {
  width: 60px;
  height: 1px;
  background: var(--stroke-gold);
  flex-shrink: 0;
}

.craft-note {
  max-width: 720px;
  font-style: italic;
  color: #5a4f3a;
  line-height: 1.8;
}

/* ---------- 雙品項 ---------- */
#flavors { text-align: center; gap: 5vh; }

.flavors-intro h2 {
  font-family: "ChenYu Luoyan", "Noto Sans TC", cursive;
  font-size: clamp(2rem, 5vw, 3rem);
}

.flavor-cards {
  display: flex;
  flex-direction: column;
  gap: 64px;
  width: var(--container);
  max-width: 1320px;
  text-align: left;
}

.flavor-card {
  opacity: 0;
  transform: translateY(32px);
}

.flavor-stage {
  position: relative;
  display: grid;
  grid-template-columns: 140px auto 1fr;
  align-items: center;
  column-gap: 28px;
}

.flavor-rich .flavor-stage { direction: rtl; }
.flavor-rich .flavor-title,
.flavor-rich .flavor-bottle-wrap,
.flavor-rich .flavor-panel { direction: ltr; }

.flavor-title {
  grid-column: 1;
  align-self: stretch;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 16px;
}

.flavor-title-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.flavor-title-text {
  position: relative;
  z-index: 1;
  writing-mode: vertical-rl;
  text-orientation: upright;
  font-family: "ChenYu Luoyan", "Noto Sans TC", cursive;
  font-size: 2.9rem;
  letter-spacing: 0.2em;
  color: var(--flavor-fresh);
}

.flavor-rich .flavor-title-text { color: var(--flavor-rich); }
.flavor-mango .flavor-title-text { color: var(--flavor-mango); }

.flavor-bottle-wrap {
  position: relative;
  grid-column: 2;
  justify-self: center;
  margin-inline-end: -40px;
  z-index: 2;
}

.flavor-bottle-wrap::before {
  content: "";
  position: absolute;
  inset: -20%;
  background: radial-gradient(circle, var(--flavor-fresh) 0%, transparent 70%);
  opacity: 0.3;
  z-index: 0;
}

.flavor-rich .flavor-bottle-wrap::before {
  background: radial-gradient(circle, var(--flavor-rich) 0%, transparent 70%);
}

.flavor-mango .flavor-bottle-wrap::before {
  background: radial-gradient(circle, var(--flavor-mango) 0%, transparent 70%);
}

.flavor-bottle {
  position: relative;
  z-index: 1;
  max-height: 560px;
  width: auto;
  filter: drop-shadow(0 18px 22px rgba(42, 33, 19, 0.25));
}

.flavor-panel {
  grid-column: 3;
  z-index: 1;
  min-width: 0;
  background: rgba(251, 244, 228, 0.95);
  border: 1px solid rgba(176, 138, 62, 0.35);
  border-top: 4px solid var(--flavor-fresh);
  border-radius: 20px;
  padding: 2.75rem 2.75rem 2.75rem 5.5rem;
  margin-inline-start: -40px;
  backdrop-filter: blur(6px);
}

.flavor-rich .flavor-panel { border-top-color: var(--flavor-rich); }
.flavor-mango .flavor-panel { border-top-color: var(--flavor-mango); }

.flavor-quote {
  font-family: "ChenYu Luoyan", "Noto Sans TC", cursive;
  font-size: 1.7rem;
  font-style: normal;
  line-height: 1.5;
  color: var(--flavor-fresh);
  margin-bottom: 1rem;
}

.flavor-rich .flavor-quote { color: var(--flavor-rich); }
.flavor-mango .flavor-quote { color: var(--flavor-mango); }

.flavor-card h3 {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.5;
  color: #5a4f3a;
  margin-bottom: 0.75rem;
}

.flavor-desc {
  font-size: 0.9rem;
  line-height: 1.8;
  color: #5a4f3a;
  margin-bottom: 1.5rem;
}

.flavor-notes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.flavor-notes div {
  background: #fff;
  border: 1px solid rgba(176, 138, 62, 0.25);
  border-radius: 12px;
  padding: 1rem;
}

.flavor-notes dt {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  color: #fff;
  background: var(--flavor-fresh);
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  margin-bottom: 0.5rem;
}

.flavor-rich .flavor-notes dt { background: var(--flavor-rich); }
.flavor-mango .flavor-notes dt { background: var(--flavor-mango); }

.flavor-notes dd { font-size: 0.8rem; color: #5a4f3a; line-height: 1.6; }

.flavor-bottom-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(176, 138, 62, 0.2);
}

.spec-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.spec-chips span {
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: var(--stroke-gold);
}

.spec-chips span:not(:last-child)::after {
  content: "\30FB";
  margin-left: 0.4rem;
}

.flavor-cta {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  background: var(--ink);
  color: var(--cream);
  text-decoration: none;
  border-radius: 999px;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  transition: background 0.3s ease;
}

.flavor-fresh .flavor-cta:hover { background: var(--flavor-fresh); }
.flavor-rich .flavor-cta:hover { background: var(--flavor-rich); }
.flavor-mango .flavor-cta:hover { background: var(--flavor-mango); }

@media (max-width: 900px) {
  .story-cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .flavor-bottle { max-height: 420px; }
  .flavor-panel { padding: 2.25rem 2.25rem 2.25rem 4rem; }
}

@media (max-width: 700px) {
  .flavor-stage {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }
  .flavor-rich .flavor-stage { direction: ltr; }
  .flavor-title { display: none; }
  .flavor-bottle-wrap { grid-column: 1; justify-self: center; margin-inline-end: 0; }
  .flavor-panel { grid-column: 1; margin-inline-start: 0; padding: 2rem; text-align: left; }
  .flavor-quote { text-align: left; }
  .flavor-notes { grid-template-columns: 1fr; }
  .flavor-bottom-row { justify-content: flex-start; }
  .spec-chips { justify-content: flex-start; }
}

@media (max-width: 600px) {
  .story-cards {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .story-card { padding: 2rem 1.5rem; }
  .topbar-left { top: 16px; left: 16px; gap: 10px; }
  .brand-mark { width: 36px; }
  .menu-toggle { width: 34px; height: 34px; }
  .menu-toggle-bar { width: 22px; }
  section { padding: 5vh 0; }

  .craft-steps { flex-direction: column; gap: 1.5rem; }
  .craft-connector { width: 1px; height: 40px; }
  .flavor-bottle { max-height: 320px; }
  .flavor-panel { padding: 1.75rem; }

  .hero-bottles { transform: translateX(-50%) scale(0.8); }
}

/* ---------- 聯絡我們 ---------- */
#contact { gap: 4vh; text-align: center; }

.contact-intro { width: var(--container); max-width: 640px; }

.contact-intro h2 {
  font-family: "ChenYu Luoyan", "Noto Sans TC", cursive;
  font-size: clamp(2rem, 5vw, 3rem);
  margin: 1rem 0;
}

.contact-intro p { line-height: 1.9; }

.contact-card {
  display: flex;
  align-items: flex-start;
  gap: 3rem;
  width: var(--container);
  max-width: 1020px;
  background: rgba(251, 244, 228, 0.9);
  border: 1px solid rgba(176, 138, 62, 0.35);
  border-radius: 12px;
  padding: 2.5rem;
  text-align: left;
  opacity: 0;
  transform: translateY(32px);
}

.contact-qr {
  flex-shrink: 0;
  width: 190px;
  text-align: center;
}

.qr-image {
  width: 180px;
  height: 180px;
  margin: 0 auto 1rem;
  border: 4px solid var(--ink);
  border-radius: 8px;
  background: #fff;
  object-fit: contain;
  padding: 8px;
}

.contact-line-btn { width: 100%; }

.contact-info { flex: 1; min-width: 0; }

.contact-info h3 {
  font-size: 1.1rem;
  letter-spacing: 0.05em;
  margin-bottom: 1.25rem;
}

.info-list div {
  display: flex;
  gap: 1rem;
  padding: 0.6rem 0;
  border-top: 1px solid rgba(176, 138, 62, 0.2);
  font-size: 0.85rem;
}

.info-list dt {
  flex-shrink: 0;
  width: 7em;
  color: var(--stroke-gold);
  font-weight: 700;
}

.info-list dd { color: #5a4f3a; line-height: 1.6; }

@media (max-width: 700px) {
  .contact-card { flex-direction: column; align-items: center; text-align: center; }
  .info-list div { flex-direction: column; gap: 0.15rem; text-align: center; }
  .info-list dt { width: auto; }
}

.legal-bar {
  margin-top: 1rem;
  width: 100%;
  background: var(--ink);
  color: var(--cream);
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.5rem 2.5rem;
  padding: 1.25rem;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
}

@media (max-width: 380px) {
  .headline { font-size: 3.35rem; }
  .eyebrow { letter-spacing: 0.25em; }
}
