/* ==========================================================================
   Retro RollRoll — Home 2026
   首頁專用樣式。所有選擇器一律 .hm- 前綴，不覆寫 styles.css 既有元件，
   移除本檔的 <link> 即可完整還原舊版。
   色彩、字體全部沿用 styles.css 既有 token，本檔不引入任何新色相。
   ========================================================================== */

:root {
  /* 由既有 token 衍生的地色與筆觸，不新增色相 */
  --hm-ground-paper: #e3d4bc;
  --hm-ground-sumi: #232322;
  --hm-ground-indigo: #1e303d;
  --hm-on-dark: #f1e8d8;
  --hm-on-dark-soft: rgba(241, 232, 216, 0.66);
  --hm-hair: rgba(100, 76, 42, 0.24);
  --hm-hair-dark: rgba(215, 189, 124, 0.26);

  /* 節奏 */
  --hm-band-y: clamp(76px, 8.5vw, 132px);
  --hm-gap: clamp(18px, 2vw, 26px);

  /* 語意色：金＝數位開啟／朱＝人的動作／藍＝結構註記 */
  --hm-reveal: #a77f36;
  --hm-act: #a63a2b;
  --hm-note: #294253;
}

/* --------------------------------------------------------------------------
   進場顯現：僅在 JS 可用時才隱藏，避免 JS 失效造成整頁空白
   -------------------------------------------------------------------------- */
.hm-js [data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 0.7s cubic-bezier(0.22, 0.61, 0.36, 1),
    transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1);
  transition-delay: var(--d, 0ms);
}
.hm-js [data-reveal].is-in {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .hm-js [data-reveal] {
    opacity: 1;
    transform: none;
  }
}

/* --------------------------------------------------------------------------
   Band：整頁的地色節奏單位
   -------------------------------------------------------------------------- */
.hm-band {
  position: relative;
  padding: var(--hm-band-y) 0;
}
.hm-band--paper {
  background: var(--hm-ground-paper);
  border-top: 1px solid var(--hm-hair);
  border-bottom: 1px solid var(--hm-hair);
}
.hm-band--sumi {
  background: var(--hm-ground-sumi);
  color: var(--hm-on-dark);
  border-top: 3px solid var(--rr-gold);
  border-bottom: 3px solid var(--rr-gold);
  overflow: hidden;
}
.hm-band--indigo {
  background: var(--hm-ground-indigo);
  color: var(--hm-on-dark);
  overflow: hidden;
}
.hm-band--sumi .h2,
.hm-band--sumi .h3,
.hm-band--indigo .h2,
.hm-band--indigo .h3 {
  color: var(--hm-on-dark);
}
.hm-band--sumi .muted,
.hm-band--indigo .muted {
  color: var(--hm-on-dark-soft);
}

/* 琳派金雲：僅出現在深色地，且不可互動 */
.hm-band--sumi::before,
.hm-band--indigo::before {
  content: "";
  position: absolute;
  left: -10%;
  top: -22%;
  width: 46%;
  padding-top: 46%;
  border-radius: 50%;
  background: radial-gradient(
    circle at 42% 38%,
    rgba(215, 189, 124, 0.24),
    rgba(167, 127, 54, 0.08) 55%,
    transparent 72%
  );
  pointer-events: none;
}
.hm-band--sumi::after,
.hm-band--indigo::after {
  content: "";
  position: absolute;
  right: -14%;
  bottom: -26%;
  width: 52%;
  padding-top: 52%;
  border-radius: 50%;
  background: radial-gradient(
    circle at 40% 35%,
    rgba(215, 189, 124, 0.16),
    transparent 66%
  );
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   Band 內部骨架：左側縱書標記 ＋ 右側內容
   -------------------------------------------------------------------------- */
.hm-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}
/* grid/flex 子項預設 min-width:auto，會被橫向捲軸內容撐開，必須歸零 */
.hm-inner > *,
.hm-thesis__grid > *,
.hm-values > *,
.hm-demo__stage > * {
  min-width: 0;
}
@media (min-width: 1080px) {
  .hm-inner {
    grid-template-columns: 46px 1fr;
    gap: 40px;
  }
}

.hm-mark {
  display: none;
}
@media (min-width: 1080px) {
  .hm-mark {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    position: sticky;
    top: 140px;
    height: max-content;
  }
  .hm-mark__num {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 1px;
    color: var(--rr-gold);
  }
  .hm-mark__zh {
    writing-mode: vertical-rl;
    text-orientation: upright;
    font-family: var(--label-jp);
    font-size: 15px;
    letter-spacing: 0.42em;
    color: var(--rr-ink-faint);
    white-space: nowrap;
  }
  .hm-band--sumi .hm-mark__zh,
  .hm-band--indigo .hm-mark__zh {
    color: rgba(241, 232, 216, 0.5);
  }
  .hm-mark__rule {
    width: 1px;
    flex: 1;
    min-height: 60px;
    background: linear-gradient(to bottom, var(--rr-gold), transparent);
  }
}

/* --------------------------------------------------------------------------
   共用排版件
   -------------------------------------------------------------------------- */
.hm-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--rr-ink-faint);
}
.hm-eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--rr-gold);
}
.hm-band--sumi .hm-eyebrow,
.hm-band--indigo .hm-eyebrow {
  color: rgba(241, 232, 216, 0.62);
}

.hm-title {
  font-family: var(--heading-zh);
  font-weight: 700;
  font-size: clamp(25px, 3.1vw, 43px);
  line-height: 1.42;
  letter-spacing: 0.5px;
  margin: 0 0 18px;
  max-width: 22em;
}
.hm-band--sumi .hm-title,
.hm-band--indigo .hm-title {
  color: var(--hm-on-dark);
}

.hm-lede {
  font-family: var(--body-font);
  font-size: clamp(16px, 1.35vw, 19px);
  line-height: 2.05;
  color: var(--rr-ink-soft);
  max-width: 40em;
  margin: 0 0 16px;
}
.hm-band--sumi .hm-lede,
.hm-band--indigo .hm-lede {
  color: var(--hm-on-dark-soft);
}

.hm-quote {
  margin: 34px 0 0;
  padding-left: 20px;
  border-left: 2px solid var(--rr-gold);
  font-family: var(--heading-zh);
  font-size: clamp(17px, 1.7vw, 22px);
  line-height: 1.85;
  color: var(--rr-indigo);
  max-width: 30em;
}
.hm-band--sumi .hm-quote,
.hm-band--indigo .hm-quote {
  color: var(--rr-gold-light);
}

.hm-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 30px;
}
.hm-band--sumi .hm-actions .btn-ghost,
.hm-band--indigo .hm-actions .btn-ghost {
  color: var(--hm-on-dark);
  border-color: rgba(241, 232, 216, 0.45);
}
.hm-band--sumi .hm-actions .btn-ghost:hover,
.hm-band--indigo .hm-actions .btn-ghost:hover {
  background: rgba(241, 232, 216, 0.09);
  color: var(--rr-gold-light);
  border-color: var(--rr-gold);
}

/* --------------------------------------------------------------------------
   1. HERO
   -------------------------------------------------------------------------- */
.hm-hero {
  position: relative;
  min-height: min(88vh, 780px);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: var(--rr-sumi);
  border-bottom: 3px solid var(--rr-gold);
}
.hm-hero__media,
.hm-hero__media video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hm-hero__scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      180deg,
      rgba(32, 29, 26, 0.52) 0%,
      rgba(32, 29, 26, 0.16) 34%,
      rgba(32, 29, 26, 0.58) 74%,
      rgba(32, 29, 26, 0.88) 100%
    );
  pointer-events: none;
}
.hm-hero__inner {
  position: relative;
  z-index: 2;
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
  padding: 0 0 clamp(0, 0vw, 86px);
  color: var(--hm-on-dark);
}
.hm-hero__kicker {
  font-family: var(--heading-en);
  font-size: clamp(13px, 1.2vw, 16px);
  letter-spacing: 0.42em;
  text-transform: uppercase;
  margin: 0 0 18px;
  color: var(--rr-gold-light);
}
.hm-hero__title {
    font-family: var(--heading-zh);
    font-weight: 700;
    font-size: clamp(22px, 4.6vw, 46px);
    line-height: 1.32;
    letter-spacing: 1px;
    margin: 0 0 14px;
    text-shadow: 0 2px 24px rgba(0, 0, 0, 0.45);
}
.hm-hero__title em {
  font-style: normal;
  opacity: 1;
  color: var(--rr-gold-light);
}
.hm-hero__sub {
font-family: 'Space Mono';
    font-size: clamp(15px, 1.3vw, 18px);
    line-height: 1.95;
    max-width: 32em;
    margin: 0;
    color: rgba(241, 232, 216, 0.86);
    text-shadow: 0 1px 14px rgba(0, 0, 0, 0.5);
}
.hm-hero__actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 30px;
}
.hm-hero__actions .btn-ghost {
  color: var(--hm-on-dark);
  border-color: rgba(241, 232, 216, 0.5);
  background: rgba(32, 29, 26, 0.22);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}
.hm-hero__actions .btn-ghost:hover {
  background: rgba(241, 232, 216, 0.12);
  color: var(--rr-gold-light);
  border-color: var(--rr-gold);
}
.hm-hero__meta {
  margin-top: 30px;
  padding-top: 18px;
  border-top: 1px solid rgba(241, 232, 216, 0.22);
  display: flex;
  gap: 6px 16px;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(241, 232, 216, 0.6);
}

/* --------------------------------------------------------------------------
   2. 命題（安靜、大留白）
   -------------------------------------------------------------------------- */
.hm-thesis .hm-title {
  font-size: clamp(26px, 3.6vw, 50px);
}
.hm-thesis__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  margin-top: 34px;
}
@media (min-width: 900px) {
  .hm-thesis__grid {
    grid-template-columns: 1.15fr 1fr;
    gap: 56px;
  }
}

/* --------------------------------------------------------------------------
   3. 感應演示（本頁的核心互動）
   -------------------------------------------------------------------------- */
.hm-demo__head {
  max-width: 46em;
  margin-bottom: 40px;
}

.hm-demo__stage {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: 26px;
  align-items: center;
  padding: clamp(22px, 3vw, 40px);
  border: 1px solid var(--hm-hair-dark);
  border-radius: 4px 26px 4px 26px;
  background:
    radial-gradient(
      120% 90% at 24% 50%,
      rgba(167, 127, 54, 0.12),
      transparent 62%
    ),
    rgba(241, 232, 216, 0.035);
}
@media (min-width: 860px) {
  .hm-demo__stage {
    grid-template-columns: 1fr minmax(280px, 420px);
    gap: 40px;
  }
}

/* --- 陶瓷作品：磁磚裁片造型，非拉坯圓器 --- */
.hm-piece {
  position: relative;
  justify-self: center;
  width: clamp(180px, 26vw, 260px);
  aspect-ratio: 1 / 1;
  display: grid;
  place-items: center;
}
.hm-piece__art {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.45));
  position: relative;
  z-index: 2;
}
/* 感應波紋：強度由 --t（0 遠 → 1 貼近）驅動 */
.hm-ring {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 60%;
  aspect-ratio: 1;
  margin: -30% 0 0 -30%;
  border-radius: 50%;
  border: 1px solid var(--rr-gold);
  opacity: calc(var(--t, 0) * 0.9);
  transform: scale(calc(0.6 + var(--t, 0) * 1.5));
  transition:
    opacity 0.18s linear,
    transform 0.18s linear;
  pointer-events: none;
  z-index: 1;
}
.hm-ring:nth-of-type(2) {
  transform: scale(calc(0.6 + var(--t, 0) * 2.1));
  opacity: calc(var(--t, 0) * 0.5);
}
.hm-ring:nth-of-type(3) {
  transform: scale(calc(0.6 + var(--t, 0) * 2.8));
  opacity: calc(var(--t, 0) * 0.28);
}
.hm-demo.is-open .hm-ring {
  animation: hmPulse 1.6s ease-out 1;
}
@keyframes hmPulse {
  0% {
    transform: scale(0.7);
    opacity: 0.9;
  }
  100% {
    transform: scale(3.4);
    opacity: 0;
  }
}

/* --- 軌道與手機 --- */
.hm-track {
  position: relative;
  min-height: 470px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}
.hm-track::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: repeating-linear-gradient(
    to right,
    var(--hm-hair-dark) 0 6px,
    transparent 6px 12px
  );
}
.hm-phone {
  position: relative;
  z-index: 2;
  width: min(232px, 62vw);
  aspect-ratio: 9 / 18.5;
  border-radius: 30px;
  padding: 9px;
  background: linear-gradient(160deg, #3a3735, #1b1917);
  border: 1px solid rgba(215, 189, 124, 0.34);
  box-shadow:
    0 24px 48px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  cursor: grab;
  touch-action: pan-y;
  transform: translateX(calc(var(--travel, 0px) * var(--t, 0) * -1));
  transition: transform 0.22s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.hm-phone.is-dragging {
  cursor: grabbing;
  transition: none;
}
.hm-phone:focus-visible {
  outline: 2px solid var(--rr-gold);
  outline-offset: 6px;
}
.hm-phone::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 5px;
  width: 54px;
  height: 5px;
  border-radius: 3px;
  background: rgba(241, 232, 216, 0.22);
  transform: translateX(-50%);
}

.hm-screen {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 22px;
  overflow: hidden;
  background: var(--rr-ivory);
  display: flex;
  flex-direction: column;
}

/* 待機畫面 */
.hm-screen__idle {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 22px;
  text-align: center;
  background: var(--rr-ivory);
  transition: opacity 0.4s ease;
}
.hm-demo.is-open .hm-screen__idle {
  opacity: 0;
  pointer-events: none;
}
.hm-screen__idle p {
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.4px;
  color: var(--rr-ink-faint);
  line-height: 1.9;
}
.hm-wave {
  width: 46px;
  height: 46px;
  color: var(--rr-gold);
  opacity: calc(0.35 + var(--t, 0) * 0.65);
}

/* 內容畫面 */
.hm-screen__doc {
  position: absolute;
  inset: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(12px);
  transition:
    opacity 0.55s ease 0.12s,
    transform 0.55s cubic-bezier(0.22, 0.61, 0.36, 1) 0.12s;
  display: flex;
  flex-direction: column;
}
.hm-demo.is-open .hm-screen__doc {
  opacity: 1;
  transform: none;
}
.hm-doc__bar {
  flex: 0 0 auto;
  padding: 14px 16px 10px;
  border-bottom: 1px solid var(--rr-edge);
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--rr-ink-faint);
}
.hm-doc__body {
  flex: 1 1 auto;
  overflow: auto;
  padding: 16px;
  color: var(--rr-ink);
}
.hm-doc__body h4 {
  margin: 0 0 8px;
  font-family: var(--heading-zh);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.6;
}
.hm-doc__body p {
  margin: 0 0 10px;
  font-size: 12.5px;
  line-height: 1.95;
  color: var(--rr-ink-soft);
}
.hm-doc__sign {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1px;
  color: var(--rr-ink-faint);
}
.hm-doc__photo {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 12px;
  background: rgba(32, 29, 26, 0.08);
}
.hm-doc__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hm-doc__play {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(32, 29, 26, 0.55);
  border: 1px solid var(--rr-gold-light);
  color: var(--rr-ivory);
  display: grid;
  place-items: center;
  font-size: 13px;
  padding-left: 3px;
}
.hm-doc__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 0;
  border-top: 1px dashed var(--rr-edge);
  font-size: 11.5px;
  color: var(--rr-ink-soft);
}
.hm-doc__row span:last-child {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--rr-gold);
  white-space: nowrap;
}

/* --- HUD 狀態列 --- */
.hm-hud {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: rgba(241, 232, 216, 0.62);
}
.hm-hud__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(241, 232, 216, 0.3);
  transition: background 0.3s ease;
}
.hm-demo.is-near .hm-hud__dot {
  background: var(--rr-gold-light);
}
.hm-demo.is-open .hm-hud__dot {
  background: var(--rr-vermilion);
}

/* --- 內容切換 --- */
.hm-switch {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 22px;
}
.hm-switch__btn {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.8px;
  padding: 10px 14px;
  min-height: 42px;
  border-radius: 3px;
  border: 1px solid rgba(241, 232, 216, 0.28);
  background: transparent;
  color: rgba(241, 232, 216, 0.75);
  cursor: pointer;
  transition:
    border-color 0.2s ease,
    color 0.2s ease,
    background 0.2s ease;
}
.hm-switch__btn:hover {
  border-color: var(--rr-gold);
  color: var(--rr-gold-light);
}
.hm-switch__btn[aria-pressed="true"] {
  background: rgba(167, 127, 54, 0.16);
  border-color: var(--rr-gold);
  color: var(--rr-gold-light);
}

.hm-demo__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 28px;
}
.hm-demo__hint {
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1px;
  color: rgba(241, 232, 216, 0.5);
}
.hm-reset {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1px;
  background: none;
  border: 0;
  border-bottom: 1px solid rgba(241, 232, 216, 0.4);
  color: rgba(241, 232, 216, 0.75);
  padding: 6px 2px;
  min-height: 40px;
  cursor: pointer;
}
.hm-reset:hover {
  color: var(--rr-gold-light);
  border-color: var(--rr-gold);
}

/* 操作說明會因裝置而異：桌機可拖曳，行動裝置為點擊 */
.hm-narrow-only {
  display: none;
}
@media (max-width: 859px) {
  .hm-wide-only {
    display: none;
  }
  .hm-narrow-only {
    display: inline;
  }
  .hm-track {
    min-height: 430px;
    justify-content: center;
  }
  .hm-phone {
    transform: none !important;
    transition: none;
    cursor: default;
  }
  .hm-track::before {
    display: none;
  }
}

/* --------------------------------------------------------------------------
   4. HOW IT WORKS — 真正的三段序列，因此才使用編號
   -------------------------------------------------------------------------- */
.hm-steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin-top: 38px;
  counter-reset: hmstep;
}
@media (min-width: 880px) {
  .hm-steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
  }
}
.hm-step {
  position: relative;
  padding: 30px 26px 30px 0;
  border-top: 1px solid var(--rr-edge);
}
@media (min-width: 880px) {
  .hm-step {
    padding: 34px 30px 10px 0;
  }
}
.hm-step__no {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--rr-gold);
  margin-bottom: 12px;
}
.hm-step__no::before {
  counter-increment: hmstep;
  content: counter(hmstep, decimal-leading-zero);
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--rr-gold);
  background: var(--hm-ground-paper);
  color: var(--rr-ink);
  font-size: 11px;
  letter-spacing: 0;
}
.hm-step__title {
  margin: 0 0 8px;
  font-family: var(--heading-zh);
  font-size: clamp(18px, 1.7vw, 22px);
  font-weight: 700;
}
.hm-step__desc {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.95;
  color: var(--rr-ink-soft);
  max-width: 26em;
}
.hm-steps__note {
  margin: 26px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--rr-edge);
  font-family: var(--mono);
    font-size: 14px;
  letter-spacing: 0.6px;
  color: var(--rr-ink-soft);
}

/* --------------------------------------------------------------------------
   5. 三個層次（非序列 → 不用編號，改用縱書標籤）
   -------------------------------------------------------------------------- */
.hm-layers {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--hm-gap);
  margin-top: 38px;
}
@media (min-width: 900px) {
  .hm-layers {
    grid-template-columns: repeat(3, 1fr);
  }
}
.hm-layer {
  position: relative;
  display: flex;
  gap: 18px;
  padding: 26px 22px;
  border: 1px solid var(--rr-edge);
  border-radius: 3px 18px 3px 18px;
  background: rgba(251, 245, 231, 0.72);
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease,
    border-color 0.22s ease;
}
.hm-layer:hover {
  transform: translateY(-4px);
  border-color: var(--rr-gold);
  box-shadow: 0 12px 26px rgba(35, 28, 22, 0.12);
}
.hm-layer__tag {
  flex: 0 0 auto;
  writing-mode: vertical-rl;
  text-orientation: upright;
  font-family: var(--label-jp);
  font-size: 13px;
  letter-spacing: 0.34em;
  color: var(--rr-ivory);
  background: var(--rr-indigo);
  padding: 12px 5px;
  border-radius: 2px;
  height: max-content;
}
.hm-layer:nth-child(2) .hm-layer__tag {
  background: var(--rr-gold);
}
.hm-layer:nth-child(3) .hm-layer__tag {
  background: var(--rr-vermilion);
}
.hm-layer__title {
  margin: 0 0 8px;
  font-family: var(--heading-zh);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.6;
}
.hm-layer__desc {
  margin: 0;
  font-size: 14px;
  line-height: 1.95;
  color: var(--rr-ink-soft);
}

/* --------------------------------------------------------------------------
   6. 設計價值（不對稱雙欄）
   -------------------------------------------------------------------------- */
.hm-values {
  display: grid;
  grid-template-columns: 1fr;
  gap: 34px;
  margin-top: 34px;
  align-items: start;
}
@media (min-width: 960px) {
  .hm-values {
    grid-template-columns: 0.85fr 1fr;
    gap: 56px;
  }
}
.hm-values__figure {
  margin: 0;
  position: relative;
}
.hm-values__figure img {
  width: 100%;
  border-radius: 3px 30px 3px 30px;
  border: 1px solid var(--rr-edge);
  box-shadow:
    2px 2px 0 rgba(166, 58, 43, 0.16),
    -2px -2px 0 rgba(41, 66, 83, 0.12),
    0 16px 34px rgba(35, 28, 22, 0.14);
}
.hm-values__figure figcaption {
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--rr-ink-faint);
  text-transform: uppercase;
}
.hm-value {
  padding: 22px 0;
  border-top: 1px solid var(--rr-edge);
}
.hm-value:first-child {
  padding-top: 0;
  border-top: 0;
}
.hm-value__title {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 8px;
  font-family: var(--heading-zh);
  font-size: clamp(18px, 1.6vw, 21px);
  font-weight: 700;
}
.hm-value__title small {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--rr-gold);
  font-weight: 400;
}
.hm-value p {
  margin: 0;
  font-size: 14.5px;
  line-height: 2;
  color: var(--rr-ink-soft);
}

/* --------------------------------------------------------------------------
   7. 作品實證（橫向捲動）
   -------------------------------------------------------------------------- */
.hm-proof {
  display: flex;
  gap: 16px;
  margin-top: 34px;
  padding-bottom: 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}
.hm-proof__item {
  flex: 0 0 auto;
  width: clamp(200px, 26vw, 268px);
  scroll-snap-align: start;
}
.hm-proof__item img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 3px 20px 3px 20px;
  border: 1px solid var(--rr-edge);
  background: rgba(32, 29, 26, 0.05);
  transition: transform 0.3s ease;
}
.hm-proof__item:hover img {
  transform: translateY(-4px);
}
.hm-proof__cap {
  margin: 12px 0 0;
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--rr-ink);
}
.hm-proof__mat {
  margin: 4px 0 0;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.6px;
  color: var(--rr-ink-faint);
  text-transform: uppercase;
}
.hm-proof__scrollhint {
  margin: 8px 0 0;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--rr-ink-faint);
}

/* --------------------------------------------------------------------------
   8. 應用可能
   -------------------------------------------------------------------------- */
.hm-apps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin-top: 34px;
  border-top: 1px solid var(--rr-edge);
}
@media (min-width: 760px) {
  .hm-apps {
    grid-template-columns: repeat(2, 1fr);
    column-gap: 48px;
  }
}
.hm-app {
  padding: 24px 0;
  border-bottom: 1px solid var(--rr-edge);
}
.hm-app__title {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 8px;
  font-family: var(--heading-zh);
  font-size: 17px;
  font-weight: 700;
}
.hm-app__title small {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.4px;
  color: var(--rr-indigo);
  text-transform: uppercase;
  font-weight: 400;
}
.hm-app p {
  margin: 0;
  font-size: 14px;
  line-height: 1.95;
  color: var(--rr-ink-soft);
}

/* --------------------------------------------------------------------------
   9. 品牌故事
   -------------------------------------------------------------------------- */
.hm-story {
  max-width: 44em;
}
.hm-story__en {
  margin: 26px 0 0;
  font-family: var(--heading-en);
  font-style: italic;
  font-size: clamp(19px, 2vw, 27px);
  color: var(--rr-gold-light);
  letter-spacing: 0.4px;
}

/* --------------------------------------------------------------------------
   10. 最終 CTA
   -------------------------------------------------------------------------- */
.hm-final {
  text-align: left;
}
.hm-final__title {
  font-family: var(--heading-zh);
  font-weight: 700;
  font-size: clamp(26px, 3.6vw, 46px);
  line-height: 1.42;
  margin: 0 0 20px;
  max-width: 14em;
}
.hm-final__list {
  margin: 0 0 8px;
  padding: 0;
  list-style: none;
  max-width: 34em;
}
.hm-final__list li {
  padding: 12px 0 12px 26px;
  border-bottom: 1px solid var(--rr-edge);
  font-size: 15px;
  line-height: 1.85;
  color: var(--rr-ink-soft);
  position: relative;
}
.hm-final__list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 22px;
  width: 10px;
  height: 1px;
  background: var(--rr-gold);
}

/* --------------------------------------------------------------------------
   FAQ 微調（沿用 styles.css 的 .faq，只補間距）
   -------------------------------------------------------------------------- */
.hm-faq {
  margin-top: 30px;
}

/* --------------------------------------------------------------------------
   共用：小字附註
   -------------------------------------------------------------------------- */
.hm-fineprint {
margin: 22px 0 0;
    font-size: 16px;
    line-height: 1.9;
    color: #655744;
    font-family: 'Space Mono';
}
.hm-band--sumi .hm-fineprint,
.hm-band--indigo .hm-fineprint {
  color: rgba(241, 232, 216, 0.5);
}

@media (prefers-reduced-motion: reduce) {
  .hm-phone,
  .hm-ring,
  .hm-screen__doc,
  .hm-proof__item img,
  .hm-layer {
    transition: none !important;
    animation: none !important;
  }
}

/* ==========================================================================
   共用頁面元件（custom / request / cases / online-shop）
   延續首頁的地色節奏、直排索引與 hm- 命名，不覆寫 styles.css。
   ========================================================================== */

/* --------------------------------------------------------------------------
   內頁頁首：比首頁矮，但同樣以墨地開場，維持全站一致的進入節奏
   -------------------------------------------------------------------------- */
.hm-page-hero {
  position: relative;
  padding: clamp(132px, 15vw, 190px) 0 clamp(48px, 6vw, 76px);
  background: var(--hm-ground-sumi);
  color: var(--hm-on-dark);
  border-bottom: 3px solid var(--rr-gold);
  overflow: hidden;
}
.hm-page-hero::before {
  content: "";
  position: absolute;
  right: -8%;
  top: -30%;
  width: 42%;
  padding-top: 42%;
  border-radius: 50%;
  background: radial-gradient(
    circle at 42% 38%,
    rgba(215, 189, 124, 0.26),
    rgba(167, 127, 54, 0.08) 55%,
    transparent 72%
  );
  pointer-events: none;
}
.hm-page-hero__inner {
  position: relative;
  z-index: 1;
}
.hm-page-hero .hm-eyebrow {
  color: rgba(241, 232, 216, 0.62);
}
.hm-page-hero__title {
  font-family: var(--heading-zh);
  font-weight: 700;
  font-size: clamp(22px, 3.9vw, 34px);
  line-height: 1.38;
  letter-spacing: 0.6px;
  margin: 0 0 18px;
  /* max-width: 18em; */
  color: var(--hm-on-dark);
}
.hm-page-hero__lede {
  font-size: clamp(15px, 1.3vw, 18px);
  line-height: 2;
  color: rgba(241, 232, 216, 0.78);
  max-width: 38em;
  margin: 0 0 10px;
}
.hm-page-hero__meta {
  margin: 26px 0 0;
  padding-top: 16px;
  border-top: 1px solid rgba(241, 232, 216, 0.22);
  display: flex;
  gap: 10px 30px;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: rgba(241, 232, 216, 0.6);
}
.hm-page-hero .hm-actions {
  margin-top: 26px;
}
.hm-page-hero .btn-ghost {
  color: var(--hm-on-dark);
  border-color: rgba(241, 232, 216, 0.5);
}
.hm-page-hero .btn-ghost:hover {
  background: rgba(241, 232, 216, 0.1);
  color: var(--rr-gold-light);
  border-color: var(--rr-gold);
}

/* --------------------------------------------------------------------------
   客製方案
   -------------------------------------------------------------------------- */
.hm-groupline {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
  margin: 0 0 6px;
}
.hm-groupline h3 {
  margin: 0;
  font-family: var(--heading-zh);
  font-size: clamp(19px, 1.9vw, 24px);
  font-weight: 700;
}
.hm-groupline span {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--rr-gold);
}

.hm-plans {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--hm-gap);
  margin-top: 26px;
}
@media (min-width: 900px) {
  .hm-plans {
    grid-template-columns: repeat(3, 1fr);
  }
}

.hm-plan {
  display: flex;
  flex-direction: column;
  padding: 26px 24px;
  border: 1px solid var(--rr-edge);
  border-radius: 3px 22px 3px 22px;
  background: rgba(251, 245, 231, 0.74);
  box-shadow: var(--shadow);
  transition:
    transform 0.22s ease,
    border-color 0.22s ease,
    box-shadow 0.22s ease;
}
.hm-plan:hover {
  transform: translateY(-4px);
  border-color: var(--rr-gold);
  box-shadow: 0 14px 30px rgba(35, 28, 22, 0.14);
}
.hm-band--paper .hm-plan {
  background: rgba(251, 245, 231, 0.86);
}
.hm-plan__code {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--rr-gold);
  font-family: var(--mono);
  font-size: 13px;
  color: var(--rr-ink);
  background: rgba(167, 127, 54, 0.1);
  margin-bottom: 14px;
}
.hm-plan__title {
  margin: 0 0 4px;
  font-family: var(--heading-zh);
  font-size: clamp(18px, 1.7vw, 21px);
  font-weight: 700;
  line-height: 1.55;
}
.hm-plan__en {
  margin: 0 0 12px;
  font-family: var(--heading-en);
  font-style: italic;
  font-size: 14px;
  letter-spacing: 0.3px;
  color: var(--rr-ink-faint);
}
.hm-plan__desc {
  margin: 0 0 14px;
  font-size: 14.5px;
  line-height: 1.95;
  color: var(--rr-ink-soft);
}
.hm-plan__list {
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}
.hm-plan__list li {
  position: relative;
  padding: 7px 0 7px 20px;
  font-size: 13.5px;
  line-height: 1.85;
  color: var(--rr-ink-soft);
  border-top: 1px dashed var(--rr-edge);
}
.hm-plan__list li:first-child {
  border-top: 0;
}
.hm-plan__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 17px;
  width: 10px;
  height: 1px;
  background: var(--rr-gold);
}
.hm-plan__for {
  margin: 0 0 18px;
  padding: 10px 12px;
  border-left: 2px solid var(--rr-indigo);
  background: rgba(41, 66, 83, 0.05);
  font-size: 13px;
  line-height: 1.8;
  color: var(--rr-indigo);
}
.hm-plan__foot {
  margin-top: auto;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.hm-plan__foot .btn,
.hm-plan__foot .btn-ghost {
  font-size: 0.94rem;
  padding: 11px 16px;
}

/* --------------------------------------------------------------------------
   表單（request）
   -------------------------------------------------------------------------- */
.hm-formwrap {
  display: grid;
  grid-template-columns: 1fr;
  gap: 26px;
  align-items: start;
  margin-top: 34px;
}
@media (min-width: 960px) {
  .hm-formwrap {
    grid-template-columns: 1.35fr 0.65fr;
    gap: 44px;
  }
}
.hm-formwrap > * {
  min-width: 0;
}

.hm-form {
  margin: 0;
}
.hm-step-block {
  border: 0;
  margin: 0 0 34px;
  padding: 0;
}
.hm-step-block__head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  width: 100%;
  box-sizing: border-box;
  float: left; /* 讓 legend 取得完整寬度，之後由 ::after 清除 */
  margin: 0 0 18px;
  padding: 0 0 12px;
  border-bottom: 1px solid var(--rr-edge);
}
.hm-step-block__head + * {
  clear: both;
}
.hm-step-block__no {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--rr-ivory);
  background: var(--rr-indigo);
  border-radius: 2px;
  padding: 4px 8px;
}
.hm-step-block__title {
  font-family: var(--heading-zh);
  font-size: clamp(17px, 1.6vw, 20px);
  font-weight: 700;
}
.hm-step-block__note {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.6px;
  color: var(--rr-ink-faint);
  margin-left: auto;
}

/* 沿用 styles.css 的 .field / .form-row，只補間距與必填標示 */
.hm-form .form-row {
  gap: 18px;
}
.hm-form .field {
  margin-bottom: 20px;
}
.hm-form .field label {
  font-family: var(--heading-zh);
  color: var(--rr-ink);
  font-size: 14.5px;
  font-weight: 600;
}
.hm-req {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.8px;
  color: var(--rr-vermilion);
  margin-left: 6px;
}
.hm-opt {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.8px;
  color: var(--rr-ink-faint);
  margin-left: 6px;
}
.hm-form .form-actions {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--rr-edge);
}

.hm-aside {
  position: static;
}
@media (min-width: 960px) {
  .hm-aside {
    position: sticky;
    top: 140px;
  }
}
.hm-aside__card {
  padding: 24px 22px;
  border-radius: 3px 22px 3px 22px;
  background: var(--hm-ground-indigo);
  color: var(--rr-gold-pale);
  border: 1px solid var(--rr-indigo);
}
.hm-aside__card h2 {
  margin: 0 0 14px;
  font-family: var(--heading-zh);
  font-size: 17px;
  font-weight: 700;
  color: var(--rr-gold-light);
}
.hm-aside__list {
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}
.hm-aside__list li {
  padding: 10px 0;
  border-top: 1px dashed rgba(215, 189, 124, 0.3);
  font-size: 13.5px;
  line-height: 1.85;
  color: rgba(231, 215, 164, 0.85);
}
.hm-aside__list li:first-child {
  border-top: 0;
}
.hm-aside__card .btn-ghost {
  border-color: var(--rr-gold-light);
  color: var(--rr-gold-pale);
  width: 100%;
}
.hm-aside__card .btn-ghost:hover {
  background: rgba(215, 189, 124, 0.12);
  color: var(--rr-ivory);
}

/* --------------------------------------------------------------------------
   篩選列（cases / online-shop）
   -------------------------------------------------------------------------- */
.hm-filter {
  margin-top: 30px;
  padding: 18px 0;
  border-top: 1px solid var(--rr-edge);
  border-bottom: 1px solid var(--rr-edge);
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
}
.hm-filter__label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--rr-ink-faint);
  margin: 0;
  flex: 0 0 100%;
}
.hm-filter .chips {
  gap: 8px;
}
.hm-filter .chip {
  font-family: var(--label-jp);
  text-transform: none;
  letter-spacing: 0.08em;
  font-size: 13px;
  border-radius: 2px;
}
.hm-filter [data-case-search] {
  font-family: var(--body-font);
}

/* --------------------------------------------------------------------------
   作品／商品格線
   注意：main.js 以 display 控制篩選，故使用 grid 而非 column-count，
   隱藏項目才不會在版面留下空洞。
   -------------------------------------------------------------------------- */
.hm-gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
  margin-top: 32px;
}
@media (min-width: 620px) {
  .hm-gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1000px) {
  .hm-gallery {
    grid-template-columns: repeat(3, 1fr);
  }
}

.hm-gallery .case {
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--rr-edge);
  border-radius: 3px 22px 3px 22px;
  background: rgba(251, 245, 231, 0.8);
  box-shadow: var(--shadow);
  transition:
    transform 0.22s ease,
    border-color 0.22s ease,
    box-shadow 0.22s ease;
}
.hm-gallery .case:hover {
  transform: translateY(-4px);
  border-color: var(--rr-gold);
  box-shadow: 0 14px 30px rgba(35, 28, 22, 0.14);
}
.hm-gallery .case-media {
  position: relative;
  margin: 0;
  background: rgba(32, 29, 26, 0.05);
}
.hm-gallery .case-media img,
.hm-gallery .case-media video {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  display: block;
  border-bottom: 1px solid var(--rr-edge);
  transition: transform 0.4s ease;
}
.hm-gallery .case:hover .case-media img {
  transform: scale(1.03);
}
.hm-gallery .case-info {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  padding: 20px;
}
.hm-case__tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  margin: 0 0 10px;
  padding: 5px 10px;
  border-radius: 2px;
  border: 1px solid var(--rr-indigo);
  background: rgba(41, 66, 83, 0.06);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--rr-indigo);
}
.hm-case__title {
  margin: 0 0 10px;
  font-family: var(--heading-zh);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.6;
}
.hm-case__desc {
  margin: 0 0 12px;
  font-size: 13.5px;
  line-height: 1.9;
  color: var(--rr-ink-soft);
}
.hm-case__mat {
  margin: auto 0 0;
  padding-top: 12px;
  border-top: 1px dashed var(--rr-edge);
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.5px;
  color: var(--rr-ink-faint);
  text-transform: uppercase;
}
.hm-case__link {
  display: inline-block;
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.8px;
  color: var(--rr-vermilion);
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
}
.hm-case__link.is-disabled {
  color: var(--rr-ink-faint);
  border-color: var(--rr-edge);
}

.hm-empty {
  margin: 34px 0 0;
  padding: 26px;
  border: 1px dashed var(--rr-edge);
  border-radius: 3px;
  text-align: center;
  font-size: 14px;
  color: var(--rr-ink-soft);
}

/* --------------------------------------------------------------------------
   結語 CTA 條（內頁共用）
   -------------------------------------------------------------------------- */
.hm-endcta {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  align-items: center;
  padding: clamp(24px, 3vw, 38px);
  border: 1px solid var(--hm-hair-dark);
  border-radius: 4px 26px 4px 26px;
  background: rgba(241, 232, 216, 0.04);
}
@media (min-width: 860px) {
  .hm-endcta {
    grid-template-columns: 1fr auto;
    gap: 40px;
  }
}
.hm-endcta h2 {
  margin: 0 0 10px;
  font-family: var(--heading-zh);
  font-size: clamp(20px, 2.2vw, 28px);
  font-weight: 700;
  color: var(--hm-on-dark);
}
.hm-endcta p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.95;
  color: var(--hm-on-dark-soft);
  max-width: 34em;
}
.hm-endcta .hm-actions {
  margin-top: 0;
}


/* --------------------------------------------------------------------------
   商店頁（online-shop）：沿用既有商品卡標記，只統一視覺語彙
   -------------------------------------------------------------------------- */
.hm-band--tight {
  padding: clamp(0px, 1.4vw, 46px) 0;
}



.hm-gallery .pill {
  margin: 0 0 10px;
  padding: 5px 10px;
  border-radius: 2px;
  border-color: var(--rr-indigo);
  background: rgba(41, 66, 83, 0.06);
  color: var(--rr-indigo);
  font-size: 10px;
  letter-spacing: 1.2px;
}
.hm-gallery .contentpro h3 {
  margin: 0 0 8px;
  font-family: var(--heading-zh);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
}
.hm-gallery .contentpro p.sp {
  margin: 0 0 6px;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 400;
  letter-spacing: 0.4px;
  color: var(--rr-ink-faint);
}
.hm-gallery .contentpro .key {
  margin: 0 0 12px;
  font-weight: 400;
  font-size: 12.5px;
  line-height: 1.8;
  color: var(--rr-ink-soft);
}
.hm-gallery .contentpro .price {
  margin: 0;
  padding: 10px 0 0;
  border: 0;
  border-top: 1px dashed var(--rr-edge);
  border-radius: 0;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--rr-ink);
  white-space: normal;
}
.hm-gallery .contentpro .price:last-child {
  padding-bottom: 0;
}
.hm-gallery .contentpro .price a {
  color: var(--rr-vermilion);
}
.hm-gallery .contentpro .price a:hover {
  color: var(--rr-vermilion-deep);
}
.hm-gallery .contentpro .num {
  letter-spacing: 0.4px;
}
