/* =========================================================
   Leviatech — Appliance Brand Static Site
   Reference: brutelle.coffee/shop (minimal editorial shop)
   Brand source: leviatech.luoguyun.com
   TODO markers in comments indicate copy needing review.

   Typography system: LEVITECH 官网字体规范与交付指令 v1.0（§4 token 命名）
   自托管 woff2 子集（§5.2），拉丁字符集，font-display: swap。
   ========================================================= */

/* ---------- @font-face（自托管，禁止第三方 CDN，规范 §5.2 / 6.1-21） ---------- */
@font-face {
  font-family: "Newsreader";
  src: url("../fonts/newsreader-vf.woff2") format("woff2-variations"),
       url("../fonts/newsreader-vf.woff2") format("woff2");
  font-weight: 500 600;          /* 变量轴 wght 已实例化为 500–600 */
  font-style: normal;
  font-display: swap;
  /* opsz 轴保留 20–40，由各层级显式通过 font-variation-settings 取值 */
}

@font-face {
  font-family: "Newsreader";
  src: url("../fonts/newsreader-italic-500.woff2") format("woff2");
  font-weight: 500;
  font-style: italic;            /* 美发线点睛：Newsreader Italic（规范 §1.5 / §2.3） */
  font-display: swap;
}

@font-face {
  font-family: "Plus Jakarta Sans";
  src: url("../fonts/plus-jakarta-sans-vf.woff2") format("woff2-variations"),
       url("../fonts/plus-jakarta-sans-vf.woff2") format("woff2");
  font-weight: 400 600;          /* 变量轴 wght 已实例化为 400–600 */
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Caveat";
  src: url("../fonts/caveat-520.woff2") format("woff2");
  font-weight: 520;              /* 点睛手写，唯一字重（规范 §2.2 AC） */
  font-style: normal;
  font-display: swap;
}

:root {
  /* Color palette: dark theme — charcoal base + gold accent */
  --bg: #101112;
  --bg-elevated: #1a1c1e;
  --bg-muted: #232629;
  --text: #e8e2da;              /* 深底正文，禁止纯白（规范 §3.5） */
  --text-bright: #f7f2ec;       /* 深底标题层（基线主标题色） */
  --text-secondary: #b3aea6;
  --text-muted: #85817a;
  --accent: #c9a45f;
  --accent-dark: #a9894c;
  --color-accent-text: #e4b872; /* 深底点睛色（规范 §3.5 / §2.3） */
  --color-hero-accent: #deac64; /* 首图点睛：基线图暖金 */
  --color-hero-eyebrow: #baafa5;/* 首图 eyebrow：基线图暖灰 */
  --color-hero-lead: #d6cdc3;   /* 首图副标题：基线图暖灰 */
  --border: #31353a;
  --shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
  --shadow-hover: 0 16px 45px rgba(0, 0, 0, 0.55);

  /* ---------- Typography tokens（规范 §4.2 / §4.4 / §4.5） ---------- */
  /* 字族：叙事衬线 / UI 无衬线 / 点睛手写 */
  --font-family-display: "Newsreader", "Source Serif 4", "PT Serif", Georgia, serif;
  --font-family-ui: "Plus Jakarta Sans", "Inter", "Manrope", system-ui, sans-serif;
  --font-family-accent: "Caveat", "Gloria Hallelujah", cursive;
  --font: var(--font-family-ui);        /* 兼容旧引用 */
  --font-display: var(--font-family-display);

  /* 字重：全站只允许这 5 档（规范 §4.3） */
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;

  /* ---------- 断点缩放系数（规范 §3.1） ----------
     桌面 1440 基准 = 1.00；各断点按表锁定系数，字号 = 基准值 × 系数，
     并取 max() 守住 §3.2 硬性下限（正文 16px、正文 13px 等）。         */
  --type-scale: 0.62;                             /* Mobile S  < 480  */

  --size-hero: max(57px, calc(92px * var(--type-scale)));          /* T1  92 → 57 */
  --size-h2: max(38px, calc(56px * var(--type-scale)));            /* T2  56 → 38 */
  --size-h3: max(26px, calc(36px * var(--type-scale)));            /* T3  36 → 26 */
  --size-card-title: max(18px, calc(22px * var(--type-scale)));    /* T4  22 → 18 */
  --size-h4: max(17px, calc(18px * var(--type-scale)));            /* T5  18 → 17 */
  --size-lead: max(18px, calc(22px * var(--type-scale)));          /* LD  22 → 18 */
  --size-body: max(16px, calc(17px * var(--type-scale)));          /* BD  17 → 16（下限锁定） */
  --size-small: max(13px, calc(14px * var(--type-scale)));         /* SM  14 → 13 */
  --size-caption: 13px;                           /* CP */
  --size-nav: 15px;                               /* NV / BT 不随视口缩放 */
  --size-btn: 15px;
  --size-label: 13px;                             /* LB / FT */
  --size-eyebrow: 12px;                           /* EY */

  /* 首图专用：与基线图字号比例一致（eyebrow 0.217× / lead 0.293× 主标题） */
  --size-hero-eyebrow: max(13px, calc(var(--size-hero) * 0.217));
  --size-hero-lead: max(18px, calc(var(--size-hero) * 0.293));

  /* 行高（深底正文 +0.05，规范 §3.5） */
  --lh-display: 1.02;
  --lh-heading: 1.08;
  --lh-heading-3: 1.18;
  --lh-body: 1.75;
  --lh-ui: 1;

  /* 字距（规范 §3.4） */
  --ls-hero: -0.020em;
  --ls-h2: -0.018em;
  --ls-h3: -0.012em;
  --ls-card: -0.010em;
  --ls-normal: 0;
  --ls-wide: 0.020em;
  --ls-nav: 0.005em;
  --ls-caps: 0.22em;

  /* Spacing */
  --section-gap: 120px;
  --container: 1280px;
  --radius: 4px;
  --radius-lg: 12px;
}

/* ---------- 响应式断点（规范 §3.1 / §4.4） ----------
   断点不逐个改组件，只切换一个缩放系数 --type-scale，
   全站字号随之联动；≥1600 锁定上限，改用更多留白。      */
@media (min-width: 480px) {
  :root { --type-scale: 0.70; }   /* Mobile L 480–767  */
}
@media (min-width: 768px) {
  :root { --type-scale: 0.80; }   /* Tablet 768–1023   */
}
@media (min-width: 1024px) {
  :root { --type-scale: 0.92; }   /* Laptop 1024–1279  */
}
@media (min-width: 1280px) {
  :root { --type-scale: 1.00; }   /* Desktop ≥1280（含 XL，上限锁定） */
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-family-ui);   /* BD：Plus Jakarta Sans */
  font-size: var(--size-body);
  font-weight: var(--weight-regular);
  color: var(--text);
  background: var(--bg);
  line-height: var(--lh-body);          /* 深底 +0.05（规范 §3.5） */
  letter-spacing: var(--ls-normal);
  -webkit-font-smoothing: antialiased;  /* 深底必须显式开启 */
  -moz-osx-font-smoothing: grayscale;
  font-variant-numeric: tabular-nums;
}

/* 标题层级统一走叙事衬线（规范 §6.2-A） */
h1, h2, h3 {
  font-family: var(--font-family-display);
  color: var(--text-bright);
  letter-spacing: var(--ls-h2);
}

/* 数字、价格、规格统一等宽数字（规范 §6.1-12） */
.product-card__price,
.product-detail__price,
.spec-table td,
.cart-drawer__subtotal-value,
.cart-item__meta,
.cart-btn__count {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

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

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
}

.container {
  width: min(92%, var(--container));
  margin: 0 auto;
}

.section {
  padding: var(--section-gap) 0;
}

/* 首页「Shop by category」与上方头图（hero）之间的专属留白。
   以正文行高为基准换算：BD 17px × 1.75 ≈ 30px/行，
   桌面 5rem(80px) ≈ 2.7 行；随视口按 5vw 线性收缩，
   下限 2.25rem(36px) ≈ 1.3 行，移动端不会留下过大空隙。
   仅作用于首页该 section，不参与 --section-gap 的全局联动。 */
.section--after-hero {
  padding-top: clamp(2.25rem, 5vw, 5rem);
}

/* T2 — 章节大标题：Newsreader 56 / 500 / 1.08 / -0.018em */
.section-title {
  font-family: var(--font-family-display);
  font-size: var(--size-h2);
  font-weight: var(--weight-medium);
  line-height: var(--lh-heading);
  letter-spacing: var(--ls-h2);
  font-variation-settings: "opsz" 36;
  margin: 0 0 1rem;
}

/* LD — 引言：Plus Jakarta Sans 22 / 400 / 1.60 */
.section-subtitle {
  color: var(--text-secondary);
  font-size: var(--size-lead);
  font-weight: var(--weight-regular);
  line-height: 1.65;
  letter-spacing: -0.005em;
  max-width: 68ch;
  margin: 0 0 3rem;
}

/* =========================================================
   Header
   ========================================================= */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(16, 17, 18, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
}

.logo__img {
  height: 21px;
  width: auto;
  display: block;
}

/* Footer brand lockup */
.logo__img--brand {
  height: 21px;
  margin-bottom: 1rem;
}

/* Logo used inline inside copy, aligned to the text baseline */
.logo-inline {
  display: inline-block;
  height: 14px;
  width: auto;
  vertical-align: -0.12em;
  margin: 0 0.12em;
}

@media (max-width: 480px) {
  .logo__img,
  .logo__img--brand {
    height: 17px;
  }

  .logo-inline {
    height: 12px;
  }
}

.nav {
  display: flex;
  align-items: center;
  gap: 2.25rem;
}

/* NV — 导航：Plus Jakarta Sans 15 / 500 / +0.005em（不随视口缩放） */
.nav__link {
  font-family: var(--font-family-ui);
  font-size: var(--size-nav);
  font-weight: var(--weight-medium);
  letter-spacing: var(--ls-nav);
  line-height: var(--lh-ui);
  color: var(--text-secondary);
  transition: color 0.2s ease;
}

.nav__link:hover,
.nav__link[aria-current="page"] {
  color: var(--text);
}

.header__actions {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.cart-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  transition: background 0.2s ease;
}

.cart-btn:hover {
  background: var(--bg-muted);
}

.cart-btn svg {
  width: 22px;
  height: 22px;
}

.cart-btn__count {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: var(--accent);
  color: #1a1512;                /* 金底深字，避免深底纯白（规范 §6.1-17） */
  font-size: var(--size-label);  /* LB 13px：守住 §3.2 辅助文字下限 */
  font-weight: var(--weight-semibold);
  border-radius: 9px;
  display: none;
  align-items: center;
  justify-content: center;
}

.cart-btn__count.is-visible {
  display: flex;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  padding: 0.5rem;
}

.menu-toggle svg {
  width: 26px;
  height: 26px;
}

/* =========================================================
   Mobile navigation
   ========================================================= */
.mobile-nav {
  display: none;
  position: fixed;
  inset: 72px 0 0 0;
  background: var(--bg);
  z-index: 99;
  padding: 2rem;
  flex-direction: column;
  gap: 1.5rem;
}

.mobile-nav.is-open {
  display: flex;
}

.mobile-nav .nav__link {
  font-size: var(--size-h4);      /* 移动端抽屉导航：T5 层级，仍走 token */
  font-weight: var(--weight-medium);
  letter-spacing: var(--ls-nav);
}

/* =========================================================
   Buttons
   ========================================================= */
/* BT — 按钮：Plus Jakarta Sans 15 / 600 / +0.020em（不缩放，规范 §4.4） */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius);
  font-family: var(--font-family-ui);
  font-size: var(--size-btn);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--ls-wide);
  line-height: var(--lh-ui);
  border: 1px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn--primary {
  background: var(--accent);
  color: #16130c;
}

.btn--primary:hover {
  background: var(--accent-dark);
  box-shadow: var(--shadow-hover);
}

.btn--secondary {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.btn--secondary:hover {
  border-color: var(--text);
}

.btn--on-image {
  color: var(--text-bright);      /* 首图叠字用暖白，与基线图主标题同色 */
  border-color: rgba(255, 255, 255, 0.55);
}

.btn--on-image:hover {
  border-color: var(--text-bright);
}

.btn--accent {
  background: var(--accent);
  color: #1a1512;                 /* 金底深字（规范 §6.1-17） */
}

.btn--accent:hover {
  background: var(--accent-dark);
}

/* =========================================================
   Hero — fullscreen background slideshow
   ========================================================= */
.hero {
  position: relative;
  min-height: 100vh;
  display: grid;
  align-items: center;
  overflow: hidden;
  background: var(--bg);
}

.hero__slides,
.hero__slide {
  position: absolute;
  inset: 0;
}

.hero__slide {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: var(--bg-muted);
  opacity: 0;
  transform: scale(1.05);
  transition: opacity 1s ease, transform 6s ease;
}

.hero__slide-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* 方案 B：底图铺满整屏。原图为宽幅（21:9），cover 时横向可裁切量最大，
     取景贴左（object-position: left）可把两张图中部的产品主体整体推向画面右侧，
     为左侧文案区留出相对空旷的画幅。 */
  object-position: left center;
  display: block;
}

.hero__slide.is-active {
  opacity: 1;
  transform: scale(1);
}

/* 蒙版（方案 B）：底图铺满整屏后，在左侧文案区整块覆盖半透明深暖灰。
   覆盖范围与文案区一致 —— 自左缘 0% 到分栏中线（52%）恒定在 30%–40% 区间内
   （40% → 34%）做轻微渐变，中线之后再羽化收尾，避免生硬直边。
   全程不使用 100% 不透明，底图始终透出。 */
.hero__scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(15, 16, 18, 0.40) 0%,
    rgba(18, 16, 16, 0.39) 18%,
    rgba(21, 18, 16, 0.37) 34%,
    rgba(23, 20, 17, 0.34) 52%,
    rgba(25, 21, 18, 0.22) 62%,
    rgba(26, 22, 19, 0.08) 72%,
    rgba(26, 22, 19, 0) 80%
  );
  z-index: 1;
  pointer-events: none;
}

.hero__grid {
  position: relative;
  z-index: 2;
  /* 与 .container 同宽：原 width:100% 覆盖了容器的 min(92%,1280px)，
     令首屏文案贴近视口左缘、破坏基线留白关系（规范 §2.4） */
  width: min(92%, var(--container));
  margin: 0 auto;
  display: grid;
  /* 底图铺满后，网格只用于界定文案列宽（52%，即左侧分栏）。
     第二列留空，产品由底图本身呈现，文案与蒙版共用同一条中线 */
  grid-template-columns: minmax(0, 52fr) minmax(0, 48fr);
  align-items: center;
  gap: 2rem;
}

.hero__copy {
  position: relative;
  min-width: 0;
}

/* 两套场景文案叠放在同一网格单元，仅当前场景可见（保证垂直居中等位） */
.hero__content {
  grid-area: 1 / 1;
  padding: 7rem 0;
  max-width: 720px;
  display: none;
}

.hero__content.is-active {
  display: block;
}

/* EY — 全大写标签：字距 +0.22em（规范 §3.4 唯一正例），色值取基线图 */
.hero__eyebrow {
  text-transform: uppercase;
  font-family: var(--font-family-ui);
  font-size: var(--size-hero-eyebrow);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--ls-caps);
  line-height: var(--lh-ui);
  color: var(--color-hero-eyebrow);
  margin: 0 0 2.1rem;
}

/* T1 — Hero 主标题：Newsreader 92 / 500 / 1.02 / -0.020em / opsz 40 */
.hero__title {
  font-family: var(--font-family-display);
  font-size: var(--size-hero);
  font-weight: var(--weight-medium);
  line-height: var(--lh-display);
  letter-spacing: var(--ls-hero);
  font-variation-settings: "opsz" 40;
  color: var(--text-bright);
  margin: 0 0 1.35rem;
}

/* 主标题人工断行，禁止自动折行决定断句（规范 §6.1-23） */
.hero__title-line {
  display: block;
}

/* AC — 点睛：Caveat 520，字号 = 主标题 × 1.24，暖金 */
.hero__title-accent {
  display: block;
  font-family: var(--font-family-accent);
  font-weight: 520;
  font-size: 1.24em;
  line-height: 1.05;
  letter-spacing: 0;
  color: var(--color-hero-accent);
}

/* 美发线：点睛改用 Newsreader Italic（规范 §1.5 / §6.1-9） */
.hero.is-beauty .hero__title-accent {
  font-family: var(--font-family-display);
  font-style: italic;
  font-weight: var(--weight-medium);
  font-size: 0.97em;
  font-variation-settings: "opsz" 40;
  color: var(--color-hero-accent);
}

.hero__lead {
  font-family: var(--font-family-ui);
  font-size: var(--size-hero-lead);
  font-weight: var(--weight-regular);
  line-height: 1.6;
  color: var(--color-hero-lead);
  max-width: 560px;
  margin: 0 0 2.35rem;
}

.hero__lead-accent {
  font-family: var(--font-family-accent);
  font-weight: 520;
  font-size: 1.24em;
  line-height: 1;
  color: var(--color-hero-accent);
}

.hero.is-beauty .hero__lead-accent {
  font-family: var(--font-family-display);
  font-style: italic;
  font-weight: var(--weight-medium);
  font-size: 1em;
  font-variation-settings: "opsz" 40;
}

.hero__actions {
  display: flex;
  gap: 1.75rem;
  align-items: center;
  flex-wrap: wrap;
}

/* 首屏 CTA 与基线一致：奶油白胶囊主按钮 + 下划线文字链 */
.hero__actions .btn--primary {
  background: #f7f2ec;
  color: #1a1512;
  border-radius: 999px;
  padding: 1.05rem 1.9rem;
}

.hero__actions .btn--primary:hover {
  background: #fffdf9;
  box-shadow: var(--shadow-hover);
}

.hero__actions .btn--secondary {
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  color: #e4dcd3;
  text-decoration: underline;
  text-underline-offset: 6px;
  text-decoration-thickness: 1.5px;
}

.hero__actions .btn--secondary:hover {
  color: var(--text-bright);
  transform: none;
}

/* 场景切换时文案淡入 */
.hero__content.is-switching {
  opacity: 0;
  transition: opacity 0.28s ease;
}

.hero__content {
  transition: opacity 0.28s ease;
}

.hero__nav {
  position: absolute;
  bottom: 2.5rem;
  left: 0;
  right: 0;
  z-index: 3;
  width: min(92%, var(--container));
  margin: 0 auto;
  display: flex;
  align-items: center;
  /* 分栏版式下改为与文案同侧左对齐，避免右箭头悬于产品图之上 */
  justify-content: flex-start;
  gap: 1.5rem;
}

.hero__arrow {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(0, 0, 0, 0.3);
  color: var(--text-bright);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.hero__arrow:hover {
  background: rgba(0, 0, 0, 0.55);
  border-color: var(--text-bright);
}

.hero__arrow svg {
  width: 20px;
  height: 20px;
}

.hero__dots {
  display: flex;
  gap: 0.6rem;
}

.hero__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: none;
  padding: 0;
  background: rgba(255, 255, 255, 0.4);
  transition: background 0.2s ease, transform 0.2s ease;
}

.hero__dot:hover {
  transform: scale(1.2);
}

.hero__dot.is-active {
  background: #fff;
}

@media (max-width: 768px) {
  /* 底图铺满版式下文案居中叠加，无需额外纵向内边距 */
  .hero__content {
    padding: 0;
  }

  /* 移动端 Newsreader 由 500 提到 600，细笔画不发虚（规范 §3.6） */
  .hero__title,
  .section-title,
  .product-detail__title {
    font-weight: var(--weight-semibold);
  }

  /* 移动端点睛倍数 1.24 → 1.15（规范 §3.6） */
  .hero__title-accent {
    font-size: 1.15em;
  }

  .hero__actions {
    gap: 1.25rem;
  }
}

/* =========================================================
   Category cards
   ========================================================= */
.category-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.category-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 380px;
  padding: 2rem;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-muted);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.category-card__image {
  position: absolute;
  inset: 0;
}

.category-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.55), transparent 60%);
}

.category-card__content {
  position: relative;
  z-index: 1;
  color: var(--text-bright);
}

/* T3 — 分类卡片标题：36 / 500 / -0.012em */
.category-card__title {
  font-family: var(--font-family-display);
  font-size: var(--size-h3);
  font-weight: var(--weight-medium);
  line-height: var(--lh-heading-3);
  letter-spacing: var(--ls-h3);
  margin: 0 0 0.5rem;
}

/* SM — 分类卡片链接：14 / 500 */
.category-card__link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: var(--size-small);
  font-weight: var(--weight-medium);
  border-bottom: 1px solid rgba(255,255,255,0.4);
  padding-bottom: 0.15rem;
}

/* =========================================================
   Product grid
   ========================================================= */
.product-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.filter-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

/* BT 变体：筛选芯片走 UI 层，字重只允许 §4.3 五档中的 500 */
.filter-btn {
  padding: 0.5rem 1rem;
  border-radius: 100px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-secondary);
  font-family: var(--font-family-ui);
  font-size: var(--size-btn);
  font-weight: var(--weight-medium);
  letter-spacing: var(--ls-wide);
  line-height: var(--lh-ui);
  transition: all 0.2s ease;
}

.filter-btn:hover,
.filter-btn.is-active {
  background: var(--accent);
  color: #16130c;
  border-color: var(--accent);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem 1.5rem;
}

.product-card {
  display: flex;
  flex-direction: column;
  group: product;
}

.product-card__media {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-muted);
  margin-bottom: 1rem;
  aspect-ratio: 1 / 1;
  transition: box-shadow 0.3s ease;
}

.product-card:hover .product-card__media {
  box-shadow: var(--shadow-hover);
}

.product-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.product-card:hover .product-card__media img {
  transform: scale(1.03);
}

.product-card__badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.25rem 0.7rem;
  background: var(--bg-elevated);
  font-size: var(--size-eyebrow);   /* EY：全大写标签 12px */
  font-weight: var(--weight-semibold);
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);   /* 全大写必须正向加宽（规范 §3.4） */
}

.product-card__add {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.25s ease;
  box-shadow: var(--shadow);
}

.product-card:hover .product-card__add {
  opacity: 1;
  transform: translateY(0);
}

.product-card__add:hover {
  background: var(--accent);
  color: #1a1512;                 /* 金底深字（规范 §6.1-17） */
}

/* EY — 卡片分类标签：12 / 600 / +0.22em 全大写 */
.product-card__category {
  font-size: var(--size-eyebrow);
  font-weight: var(--weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);
  color: var(--text-muted);
  margin-bottom: 0.35rem;
}

/* T4 — 卡片标题：Plus Jakarta Sans 22 / 600 / 1.35 / -0.010em */
.product-card__title {
  font-family: var(--font-family-ui);
  font-size: var(--size-card-title);
  font-weight: var(--weight-semibold);
  line-height: 1.35;
  letter-spacing: var(--ls-card);
  margin: 0 0 0.5rem;
}

.product-card__title a:hover {
  color: var(--accent-dark);
}

/* NUM — 价格：17 / 500 / tabular-nums */
.product-card__price {
  font-size: var(--size-body);
  font-weight: var(--weight-medium);
}

/* =========================================================
   Product detail
   ========================================================= */
.product-detail {
  padding-top: 3rem;
}

.product-detail__grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 5rem;
  align-items: start;
}

.product-detail__media {
  position: sticky;
  top: 100px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-muted);
}

.product-detail__media img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.product-detail__info {
  padding-top: 1rem;
}

/* EY — 详情分类标签：12 / 600 / +0.22em 全大写（规范 §3.4） */
.product-detail__category {
  text-transform: uppercase;
  font-size: var(--size-eyebrow);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--ls-caps);
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

/* 详情页商品名：与站内页标题同级（T2），避免 48px 这类表外数值 */
.product-detail__title {
  font-family: var(--font-family-display);
  font-size: var(--size-h2);
  font-weight: var(--weight-medium);
  font-variation-settings: "opsz" 36;
  line-height: var(--lh-heading);
  letter-spacing: var(--ls-h2);
  margin: 0 0 1rem;
}

/* NUM — 详情价格：T3 层级，等宽数字，与卡片价格同族同字重 */
.product-detail__price {
  font-size: var(--size-h3);
  font-weight: var(--weight-medium);
  line-height: var(--lh-heading-3);
  font-variant-numeric: tabular-nums;
  margin-bottom: 1.5rem;
}

/* BD — 详情描述：17 / 400 / 1.75（深底正文 +0.05 行高） */
.product-detail__desc {
  color: var(--text-secondary);
  font-size: var(--size-body);
  line-height: var(--lh-body);
  margin-bottom: 2rem;
}

.product-detail__actions {
  display: flex;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.quantity {
  display: flex;
  align-items: center;
  border: 1px solid #4a5058;
  border-radius: var(--radius);
  overflow: hidden;
  color-scheme: dark;
}

.quantity button {
  width: 44px;
  height: 48px;
  background: transparent;
  border: none;
  font-size: var(--size-body);
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.quantity button:hover {
  background: var(--bg-muted);
  color: var(--text-bright);
}

.quantity button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.quantity button:disabled {
  color: var(--text-muted);
  cursor: not-allowed;
  opacity: 0.6;
}

.quantity input {
  width: 50px;
  height: 48px;
  border: none;
  text-align: center;
  font-size: var(--size-body);
  font-weight: var(--weight-medium);
  background: transparent;
  /* Input elements do not inherit body color — keep the number
     readable on the dark theme in every state. */
  color: var(--text);
  -webkit-text-fill-color: var(--text);
  opacity: 1;
  caret-color: var(--text);
}

.quantity input:focus {
  outline: none;
  background: var(--bg-muted);
}

.quantity input:disabled,
.quantity input[readonly] {
  color: var(--text);
  -webkit-text-fill-color: var(--text);
  opacity: 1;
}

.quantity input::placeholder {
  color: var(--text-muted);
  -webkit-text-fill-color: var(--text-muted);
}

/* Hide native number spinners — controls are the +/- buttons */
.quantity input::-webkit-outer-spin-button,
.quantity input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.quantity input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}

.spec-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1.5rem;
}

.spec-table th,
.spec-table td {
  text-align: left;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
  font-size: var(--size-small);
}

.spec-table th {
  color: var(--text-muted);
  font-weight: var(--weight-medium);
  width: 40%;
}

/* =========================================================
   Cart drawer
   ========================================================= */
.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: min(440px, 100vw);
  height: 100vh;
  background: var(--bg-elevated);
  box-shadow: -10px 0 40px rgba(0,0,0,0.1);
  z-index: 200;
  transform: translateX(110%);
  transition: transform 0.35s ease;
  display: flex;
  flex-direction: column;
}

.cart-drawer.is-open {
  transform: translateX(0);
}

.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.35);
  z-index: 199;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

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

.cart-drawer__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem;
  border-bottom: 1px solid var(--border);
}

/* T4 — 抽屉标题：22 / 500 / -0.010em */
.cart-drawer__title {
  font-size: var(--size-card-title);
  font-weight: var(--weight-medium);
  letter-spacing: var(--ls-card);
  margin: 0;
}

.cart-drawer__close {
  background: none;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-drawer__close:hover {
  background: var(--bg-muted);
}

.cart-drawer__body {
  flex: 1;
  overflow-y: auto;
  padding: 1.5rem;
}

.cart-empty {
  text-align: center;
  color: var(--text-secondary);
  padding: 4rem 1rem;
}

.cart-item {
  display: flex;
  gap: 1rem;
  padding-bottom: 1.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.cart-item__thumb {
  width: 80px;
  height: 80px;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-muted);
  flex-shrink: 0;
}

.cart-item__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-item__details {
  flex: 1;
}

/* BD — 购物车条目名：17 / 500 */
.cart-item__title {
  font-weight: var(--weight-medium);
  margin: 0 0 0.25rem;
  font-size: var(--size-body);
}

/* SM — 购物车条目规格：14 */
.cart-item__meta {
  color: var(--text-muted);
  font-size: var(--size-small);
  margin-bottom: 0.5rem;
}

.cart-item__qty {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.cart-item__qty button {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--size-small);
  color: var(--text);
}

/* LB — 移除链接：13 */
.cart-item__remove {
  color: var(--text-muted);
  font-size: var(--size-label);
  text-decoration: underline;
  background: none;
  border: none;
  padding: 0;
}

.cart-item__remove:hover {
  color: var(--text);
}

.cart-drawer__footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border);
  background: var(--bg);
}

/* NUM — 小计：17 / 600 / 等宽数字 */
.cart-drawer__subtotal {
  display: flex;
  justify-content: space-between;
  font-size: var(--size-body);
  font-weight: var(--weight-semibold);
  font-variant-numeric: tabular-nums;
  margin-bottom: 1rem;
}

/* SM — 抽屉脚注：14 */
.cart-drawer__note {
  font-size: var(--size-small);
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.cart-drawer__checkout {
  width: 100%;
}

/* =========================================================
   Toast notification
   ========================================================= */
.toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(120%);
  background: var(--accent);
  color: #16130c;
  padding: 0.85rem 1.5rem;
  border-radius: 100px;
  font-size: var(--size-small);
  z-index: 300;
  opacity: 0;
  transition: all 0.35s ease;
  box-shadow: var(--shadow-hover);
}

.toast.is-visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* =========================================================
   About / content blocks
   ========================================================= */
.split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}

.split-grid__image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-muted);
}

.split-grid__image img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}

.about-intro {
  max-width: 860px;
  margin: 0 auto;
  text-align: left;
}

.value-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 3rem;
}

/* T5 — 价值卡片标题：18 / 600 / -0.010em */
.value-card__title {
  font-size: var(--size-h4);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--ls-card);
  line-height: var(--lh-heading-3);
  margin: 0 0 0.5rem;
}

/* BD — 价值卡片正文：17 / 400 / 1.75 */
.value-card__text {
  color: var(--text-secondary);
  font-size: var(--size-body);
  line-height: var(--lh-body);
}

/* =========================================================
   Contact
   ========================================================= */
.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 4rem;
  align-items: start;
}

.form-group {
  margin-bottom: 1.5rem;
}

/* SM — 表单标签：14 / 500 */
.form-label {
  display: block;
  font-size: var(--size-small);
  font-weight: var(--weight-medium);
  margin-bottom: 0.5rem;
}

.form-input,
.form-textarea {
  width: 100%;
  padding: 0.9rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-elevated);
  font-size: var(--size-body);   /* BD：输入文字不小于正文，避免 iOS 聚焦缩放 */
  transition: border-color 0.2s ease;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.form-textarea {
  min-height: 140px;
  resize: vertical;
}

.contact-info__card {
  padding: 2rem;
  background: var(--bg-elevated);
  border-radius: var(--radius-lg);
  margin-bottom: 1.5rem;
}

/* EY — 联系信息标签：12 / 600 / +0.22em 全大写 */
.contact-info__label {
  font-size: var(--size-eyebrow);
  font-weight: var(--weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

/* BD — 联系信息值：17 / 500 */
.contact-info__value {
  font-size: var(--size-body);
  font-weight: var(--weight-medium);
}

.social-links {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.social-links a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.social-links a:hover {
  background: var(--accent);
  color: #1a1512;                 /* 金底深字（规范 §6.1-17） */
}

/* =========================================================
   Footer
   ========================================================= */
.footer {
  background: #0a0b0c;
  color: var(--text-secondary);   /* 深底禁止纯白（规范 §3.5） */
  padding: 5rem 0 2rem;
  border-top: 1px solid var(--border);
}

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

.footer__brand {
  color: var(--text-bright);
  font-size: var(--size-card-title);
  font-weight: var(--weight-semibold);
  margin-bottom: 1rem;
}

/* SM — 页脚简介：14 / 1.75 */
.footer__desc {
  max-width: 320px;
  line-height: var(--lh-body);
  font-size: var(--size-small);
}

/* EY — 页脚栏目标题：12 / 600 / +0.22em 全大写 */
.footer__title {
  color: var(--text-bright);
  font-size: var(--size-eyebrow);
  font-weight: var(--weight-semibold);
  margin: 0 0 1.25rem;
  text-transform: uppercase;
  letter-spacing: var(--ls-caps);
}

.footer__links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer__links a {
  font-size: var(--size-small);   /* SM：页脚链接 14 */
  transition: color 0.2s ease;
}

.footer__links a:hover {
  color: var(--text-bright);
}

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.12);
  font-size: var(--size-small);
}

.newsletter {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
}

.newsletter input {
  flex: 1;
  min-width: 0;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.08);
  color: var(--text);
  font-size: var(--size-small);
}

.newsletter input::placeholder {
  color: rgba(255,255,255,0.4);
}

.newsletter button {
  padding: 0 1.25rem;
  background: var(--accent);
  color: #1a1512;                 /* 金底深字（规范 §6.1-17） */
  border: none;
  border-radius: var(--radius);
  font-size: var(--size-btn);
  font-weight: var(--weight-medium);
}

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 1024px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .hero__grid,
  .split-grid,
  .product-detail__grid,
  .contact-grid {
    gap: 3rem;
  }

  /* 头图：底图铺满版式在窄屏回落为文案居中叠加（不再左右分栏） */
  .hero__grid {
    grid-template-columns: 1fr;
  }

  /* 窄屏画幅变窄，取景贴左会只剩空台面；改为把产品主体组居中进画面 */
  .hero__slide-img {
    object-position: 38% center;
  }

  .hero__copy {
    text-align: center;
  }

  .hero__content {
    max-width: 640px;
    margin: 0 auto;
    padding: 2rem 0;
  }

  .hero__lead {
    margin-left: auto;
    margin-right: auto;
  }

  .hero__actions {
    justify-content: center;
  }

  /* 文案居中后蒙版改为上下均匀的半透明覆盖（38%–40%），
     保证居中文字在亮底图上依旧可读；同样不使用 100% 不透明 */
  .hero__scrim {
    background: linear-gradient(
      to bottom,
      rgba(15, 16, 18, 0.34) 0%,
      rgba(18, 16, 16, 0.40) 26%,
      rgba(20, 18, 16, 0.40) 70%,
      rgba(15, 16, 18, 0.36) 100%
    );
  }
}

@media (max-width: 768px) {
  :root {
    --section-gap: 80px;
  }

  .nav {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .hero__grid,
  .split-grid,
  .product-detail__grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  /* 堆叠版式：文案居中，纵向留白收紧 */
  .hero__content {
    max-width: 640px;
    margin: 0 auto;
    padding: 0;
  }

  .category-grid,
  .value-list {
    grid-template-columns: 1fr;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
  }

  .product-card__add {
    opacity: 1;
    transform: none;
  }

  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer__bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .product-grid {
    grid-template-columns: 1fr;
  }

  .footer__grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   Home category columns (kitchen / beauty)
   ========================================================= */
.category-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

/* T4 — 首页分类列标题：22 / 500 / -0.010em */
.category-column__title {
  font-size: var(--size-card-title);
  font-weight: var(--weight-medium);
  letter-spacing: var(--ls-card);
  margin: 0 0 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

/* Two-up card list inside each column; reuses .product-card internals */
.product-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem 1.5rem;
}

@media (max-width: 1024px) {
  .category-columns {
    gap: 2.5rem;
  }
}

@media (max-width: 768px) {
  .category-columns {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .product-list {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   Product visual treatments (comparison variants)
   Applied only when a parent carries .pv-float / .pv-vignette / .pv-glow
   ========================================================= */

/* --- Variant A: 去背悬浮 + 柔和落地投影 (Dreame/Dyson style) --- */
.pv-float .product-card__media {
  background: radial-gradient(120% 100% at 50% 40%, #262a2e 0%, #1a1d20 55%, #121315 100%);
}

.pv-float .product-card__media img {
  object-fit: contain;
  padding: 6% 8% 10%;
  filter: drop-shadow(0 26px 30px rgba(0, 0, 0, 0.6)) drop-shadow(0 3px 6px rgba(0, 0, 0, 0.4)) contrast(1.03);
}

.pv-float .product-card__media::after {
  content: "";
  position: absolute;
  left: 22%;
  right: 22%;
  bottom: 7%;
  height: 7%;
  background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0) 70%);
  filter: blur(5px);
  pointer-events: none;
}

.pv-float .product-card:hover .product-card__media img {
  transform: translateY(-4px);
}

/* --- Variant B: 渐变遮罩衬托 (soft vignette fade into the card) --- */
.pv-vignette .product-card__media {
  background: radial-gradient(115% 95% at 50% 42%, #2b2f33 0%, #1b1e21 58%, #121315 100%);
}

.pv-vignette .product-card__media img {
  -webkit-mask-image: radial-gradient(closest-side, #000 56%, rgba(0, 0, 0, 0.55) 80%, transparent 100%);
  mask-image: radial-gradient(closest-side, #000 56%, rgba(0, 0, 0, 0.55) 80%, transparent 100%);
  filter: contrast(1.05) saturate(1.03);
}

.pv-vignette .product-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.35), transparent 55%);
  pointer-events: none;
}

/* --- Variant C: 边缘光晕 / 背光高光分离 --- */
.pv-glow .product-card__media {
  background: #101113;
}

.pv-glow .product-card__media::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 74%;
  aspect-ratio: 1 / 1;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0.05) 45%, rgba(255, 255, 255, 0) 72%);
  filter: blur(12px);
  pointer-events: none;
}

.pv-glow .product-card__media img {
  object-fit: contain;
  padding: 7% 9% 9%;
  filter: brightness(1.06) contrast(1.09) drop-shadow(0 0 22px rgba(255, 255, 255, 0.22));
}

.pv-glow .product-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent 40%);
  pointer-events: none;
}

/* Shared: keep add-to-cart button and badge above treatment layers */
.pv-float .product-card__badge,
.pv-vignette .product-card__badge,
.pv-glow .product-card__badge,
.pv-float .product-card__add,
.pv-vignette .product-card__add,
.pv-glow .product-card__add {
  z-index: 2;
}
