/* =========================================================
   欸！點餐囉 — 網站樣式
   要改配色，改下面 :root 裡的變數就好，全站會一起變。
   ========================================================= */

:root {
  /* --- 配色（沿用原站 Astra 色票） --- */
  --c-accent:        #fbe8a6;   /* 主色：奶油黃，用在強調區塊底 */
  --c-accent-deep:   #f3d97a;   /* 深黃：邊框、hover */
  --c-ink:           #2c2927;   /* 主文字：近黑 */
  --c-ink-soft:      #534a45;   /* 次文字：棕灰 */
  --c-cream:         #f2f1e5;   /* 區塊米白底 */
  --c-white:         #ffffff;
  --c-brown:         #7d5a1e;   /* 聯絡我們標題的棕色 */
  --c-green:         #669900;   /* Email 連結綠 */

  /* --- 版面 --- */
  --wrap:            1200px;
  --wrap-narrow:     780px;
  --section-y:       clamp(64px, 9vw, 120px);
  --radius:          20px;

  /* --- 字體 --- */
  --font-body: "Manrope", "PingFang TC", "Noto Sans TC", "Microsoft JhengHei",
               "Heiti TC", sans-serif;
  --font-head: "Plus Jakarta Sans", "PingFang TC", "Noto Sans TC",
               "Microsoft JhengHei", "Heiti TC", sans-serif;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.85;
  color: var(--c-ink);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  line-height: 1.4;
  margin: 0;
  font-weight: 600;
}

p  { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }

a { color: inherit; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

/* ---------- 版心 ---------- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 24px;
}
.wrap--narrow { max-width: var(--wrap-narrow); }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--c-ink);
  color: var(--c-white);
  padding: 12px 20px;
}
.skip-link:focus { left: 0; }

:focus-visible {
  outline: 3px solid var(--c-accent-deep);
  outline-offset: 3px;
}

/* ---------- 頁首 ---------- */
.site-header { position: absolute; inset: 0 0 auto; z-index: 20; }

.site-header__inner {
  display: flex;
  align-items: center;
  min-height: 88px;
}

.site-header__logo img { width: 60px; height: auto; }

/* 內頁用的實心頁首（隱私權政策） */
.site-header--solid {
  position: static;
  background: var(--c-ink);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 62vh;
  padding-block: 190px 60px;
  background-image: url("../img/hero-bg.jpg");
  background-position: 50% 50%;
  background-size: cover;
  background-repeat: no-repeat;
  color: var(--c-white);
  isolation: isolate;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--c-ink);
  opacity: .6;
  z-index: -1;
}

.hero__eyebrow {
  font-size: clamp(20px, 3vw, 28px);
  font-weight: 600;
  letter-spacing: .06em;
  margin-bottom: .4em;
}

.hero__title {
  font-size: clamp(40px, 8vw, 72px);
  letter-spacing: .02em;
  margin-bottom: .2em;
}

.hero__subtitle {
  font-size: clamp(17px, 2.4vw, 22px);
  color: var(--c-accent);
  margin-bottom: 1.8em;
}

/* ---------- 商店徽章 ---------- */
.store-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
}
.store-badges--center { justify-content: center; margin-top: 2.4em; }

.store-badges__link { display: inline-flex; }

/* Google 官方徽章圖本身帶留白，Apple 的沒有 —— 用不同高度＋負邊距對齊視覺 */
.store-badges__link--google img { height: 62px; width: auto; margin: -11px; }
.store-badges__link--apple  img { height: 40px; width: auto; }

.store-badges__link:hover { opacity: .85; }

/* ---------- 區塊 ---------- */
.section { padding-block: var(--section-y); }
.section--cream  { background: var(--c-cream); }
.section--yellow { background: var(--c-accent); }
.section--tight  { padding-block: clamp(40px, 5vw, 64px); }

.section__title {
  font-size: clamp(26px, 4vw, 40px);
  text-align: center;
  margin-bottom: 1.6em;
}
.section__title--spaced { margin-top: 2.4em; }

/* ---------- 痛點三連 ---------- */
.pains {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 40px 32px;
}

.pain {
  display: flex;
  flex-direction: column;
  text-align: center;
}

.pain__title {
  font-size: clamp(19px, 2.2vw, 23px);
  margin-bottom: .9em;
  min-height: 2.8em;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 插圖是去背的，不加圓角；margin-top:auto 讓三張圖共用同一條底線 */
.pain__img {
  width: 100%;
  margin-top: auto;
}

/* ---------- 產品特色 ---------- */
/* 收窄到 940px 並置中，否則在寬螢幕上文字會貼左、插圖貼右，中間空一大塊 */
.features {
  display: grid;
  gap: clamp(40px, 6vw, 72px);
  max-width: 940px;
  margin-inline: auto;
}

.feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(24px, 5vw, 56px);
}

/* 偶數項左右對調，做出交錯排版 */
.feature:nth-child(even) .feature__text { order: 2; }
.feature:nth-child(even) .feature__img  { order: 1; }

.feature__title {
  font-size: clamp(21px, 2.6vw, 28px);
  margin-bottom: .6em;
}

.feature__text p { color: var(--c-ink-soft); margin: 0; }

/* 同樣是去背插圖，不加圓角 */
.feature__img {
  width: clamp(180px, 24vw, 280px);
  height: auto;
}

@media (max-width: 720px) {
  .feature {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }
  .feature:nth-child(even) .feature__text,
  .feature:nth-child(even) .feature__img { order: initial; }
}

/* ---------- 勾選清單 ---------- */
.checklist { display: grid; gap: 14px; }

.checklist li {
  position: relative;
  padding-left: 2.2em;
  font-size: clamp(16px, 2vw, 19px);
}

.checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .48em;
  width: 1.15em;
  height: 1.15em;
  background: var(--c-ink);
  /* 原站用的 Font Awesome 打勾，改成同形狀的 mask，不必載入圖示字型 */
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'%3E%3Cpath d='M438.6 105.4C451.1 117.9 451.1 138.1 438.6 150.6L182.6 406.6C170.1 419.1 149.9 419.1 137.4 406.6L9.372 278.6C-3.124 266.1-3.124 245.9 9.372 233.4C21.87 220.9 42.13 220.9 54.63 233.4L159.1 338.7L393.4 105.4C405.9 92.88 426.1 92.88 438.6 105.4H438.6z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'%3E%3Cpath d='M438.6 105.4C451.1 117.9 451.1 138.1 438.6 150.6L182.6 406.6C170.1 419.1 149.9 419.1 137.4 406.6L9.372 278.6C-3.124 266.1-3.124 245.9 9.372 233.4C21.87 220.9 42.13 220.9 54.63 233.4L159.1 338.7L393.4 105.4C405.9 92.88 426.1 92.88 438.6 105.4H438.6z'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* ---------- 使用流程 ---------- */
.steps { counter-reset: step; display: grid; gap: 18px; }

.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 3em;
  font-size: clamp(16px, 2vw, 19px);
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: .28em;
  width: 2em;
  height: 2em;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--c-accent);
  color: var(--c-ink);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .95em;
  line-height: 1;
}

/* ---------- 輪播 ---------- */
.carousel {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
}

.carousel__track {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  padding-block: 4px;
  flex: 1;
}
.carousel__track::-webkit-scrollbar { display: none; }

/* 用 start 對齊：吸附點就是 0、249、498…，與 JS 的步進距離一致。
   若用 center，前幾張的理想吸附位置會算成負值再被夾到 0，行為不好預期。 */
.carousel__slide {
  flex: 0 0 auto;
  scroll-snap-align: start;
}

.carousel__slide img {
  width: 229px;
  height: auto;
  border-radius: 14px;
  box-shadow: 0 6px 24px rgba(44, 41, 39, .18);
}

.carousel__nav {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: var(--c-white);
  color: var(--c-ink);
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(44, 41, 39, .2);
  transition: background .15s ease;
}
.carousel__nav:hover { background: var(--c-accent-deep); }
.carousel__nav[disabled] { opacity: .35; cursor: default; }
.carousel__nav[disabled]:hover { background: var(--c-white); }

.carousel__nav svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media (max-width: 560px) {
  .carousel__nav { display: none; }
  .carousel__track { scroll-snap-type: x proximity; }
}

/* ---------- 影片 CTA ---------- */
.yt-cta { text-align: center; }

.yt-button {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 28px;
  border-radius: 999px;
  background: var(--c-white);
  box-shadow: 0 2px 14px rgba(44, 41, 39, .15);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: clamp(17px, 2.2vw, 20px);
  text-decoration: none;
  transition: transform .15s ease, box-shadow .15s ease;
}
.yt-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(44, 41, 39, .22);
}

.yt-button__icon { width: 42px; height: 30px; flex: 0 0 auto; }

/* ---------- 結尾 CTA ---------- */
.closing {
  background: var(--c-ink);
  color: var(--c-white);
  text-align: center;
}

.closing__title {
  font-size: clamp(23px, 3.4vw, 34px);
  margin-bottom: .9em;
}

.closing__text { color: #e6e2dd; margin: 0; }

/* ---------- 頁尾 ---------- */
.site-footer {
  background: var(--c-cream);
  padding-block: clamp(48px, 6vw, 72px) 32px;
}

.contact-card {
  max-width: 420px;
  margin-inline: auto;
  padding: 28px 24px;
  background: var(--c-white);
  border-radius: var(--radius);
  box-shadow: 0 2px 16px rgba(60, 70, 40, .13);
  text-align: center;
}

.contact-card__title {
  color: var(--c-brown);
  font-size: 1.5em;
  letter-spacing: 1px;
  margin-bottom: .55em;
}

.contact-card__line { margin-bottom: 12px; }
.contact-card__line img { display: inline-block; height: 40px; width: auto; border-radius: 8px; }

.contact-card__mail {
  color: var(--c-green);
  font-weight: 700;
  text-decoration: none;
}
.contact-card__mail:hover { text-decoration: underline; }

.contact-card__note {
  font-size: .93em;
  color: #888;
  margin: 0;
}

.site-footer__bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 6px 20px;
  margin-top: 44px;
  font-size: .9em;
  color: var(--c-ink-soft);
}
.site-footer__bar p { margin: 0; }
.site-footer__bar a { color: var(--c-ink-soft); }

/* ---------- 返回頂端 ---------- */
.to-top {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 30;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--c-ink);
  color: var(--c-white);
  box-shadow: 0 2px 12px rgba(44, 41, 39, .3);
  text-decoration: none;
}
.to-top:hover { background: var(--c-ink-soft); }
.to-top svg {
  width: 20px; height: 20px;
  fill: none; stroke: currentColor;
  stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round;
}

/* ---------- 內頁（隱私權政策） ---------- */
.page {
  padding-block: clamp(48px, 6vw, 88px);
  background: var(--c-white);
}

.page__title {
  font-size: clamp(30px, 5vw, 44px);
  margin-bottom: 1.2em;
}

.page h2, .page h3 {
  font-size: clamp(20px, 2.6vw, 25px);
  margin-top: 2em;
  margin-bottom: .7em;
}

.page ul { list-style: disc; padding-left: 1.4em; margin-bottom: 1em; }
.page ul ul { list-style: circle; margin-top: .5em; }
.page li { margin-bottom: .5em; }

.page__note {
  margin-top: 2.5em;
  padding: 18px 22px;
  background: var(--c-cream);
  border-left: 5px solid var(--c-accent-deep);
  border-radius: 8px;
}
