/* ==========================================================================
   栖光生活 AURA - 极简独立美学商城样式系统
   设计语言：轻暖浅红瓷白背景 + 纯白浮岛卡片 + 深灰文字 + 高留白去边框
   ========================================================================== */

:root {
  /* 基础色盘 */
  --bg-canvas: #FCF6F5;            /* 浅红淡瓷色背景 */
  --bg-canvas-subtle: #F8EDED;     /* 辅助极淡浅红底色 */
  --bg-card: #FFFFFF;              /* 纯白卡片 */
  --bg-card-hover: #FFFFFF;
  --bg-glass: rgba(255, 255, 255, 0.85);

  /* 文字层次 (深灰色系，拒绝生硬纯黑) */
  --text-main: #1D2129;            /* 主标题/关键数值 */
  --text-body: #4E5666;            /* 正文阅读 */
  --text-muted: #86909C;           /* 辅助说明/时间标签 */
  --text-light: #B8BFC9;           /* 极淡装饰/占位符 */

  /* 品牌点缀色 (柔和暖红与浅红衬底) */
  --accent: #CF5C56;               /* 栖光朱砂暖红 */
  --accent-hover: #B5453F;         /* 悬浮加深 */
  --accent-light: #FCEEEC;         /* 极淡粉红背景块 */
  --accent-focus: rgba(207, 92, 86, 0.15);

  /* 功能辅助色 */
  --color-success: #389E62;
  --color-warning: #D9822B;
  --color-error: #D04848;

  /* 去边框哲学：通过多层次自然光晕阴影分离空间，坚决摒弃厚重生硬边框 */
  --shadow-sm: 0 4px 16px -2px rgba(190, 110, 110, 0.04);
  --shadow-card: 0 12px 32px -8px rgba(190, 110, 110, 0.06), 0 4px 12px -2px rgba(190, 110, 110, 0.03);
  --shadow-card-hover: 0 20px 48px -10px rgba(190, 110, 110, 0.12), 0 8px 20px -4px rgba(190, 110, 110, 0.05);
  --shadow-float: 0 24px 60px -12px rgba(170, 90, 90, 0.15);

  /* 圆角韵律 */
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --radius-full: 9999px;

  /* 字体族 */
  --font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* 基础重置 */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  border: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-canvas);
  color: var(--text-body);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

/* 排版规范 */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-main);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

h1 { font-size: 2.75rem; font-weight: 600; text-wrap: balance; }
h2 { font-size: 2rem; font-weight: 600; text-wrap: balance; }
h3 { font-size: 1.35rem; font-weight: 600; }
h4 { font-size: 1.1rem; font-weight: 600; }

p {
  color: var(--text-body);
  font-size: 0.95rem;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

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

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  outline: none;
}

.tabular-nums {
  font-variant-numeric: tabular-nums;
}

/* 容器架构与高留白约束 */
.container {
  width: 100%;
  max-width: 1240px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 2rem;
  padding-right: 2rem;
}

.container-narrow {
  width: 100%;
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 2rem;
  padding-right: 2rem;
}

.section-spacing {
  padding-top: 5rem;
  padding-bottom: 5rem;
}

.section-spacing-lg {
  padding-top: 6.5rem;
  padding-bottom: 6.5rem;
}

/* 核心组件：纯白无边框卡片 (White Floating Cards) */
.white-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
  position: relative;
}

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

/* 顶部通知微栏 */
.top-announcement {
  background-color: #F8E8E7;
  color: var(--text-body);
  font-size: 0.8rem;
  text-align: center;
  padding: 0.55rem 1rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}
.top-announcement span {
  color: var(--accent);
  margin-right: 0.5rem;
  font-weight: 600;
}

/* 顶部导航栏 (Strict 3-Zone Top Bar) */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.site-header.scrolled {
  background-color: rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
  gap: 2rem;
}

/* Zone 1: 品牌字标 (单行无附属标签) */
.brand-wordmark {
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text-main);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.brand-wordmark .brand-dot {
  width: 6px;
  height: 6px;
  background-color: var(--accent);
  border-radius: 50%;
  display: inline-block;
}
.brand-wordmark .brand-en {
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--text-muted);
  letter-spacing: 0.1em;
}

/* Zone 2: 主导航链接 (文本hover微动) */
.nav-links {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  list-style: none;
}

.nav-item a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-body);
  white-space: nowrap;
  position: relative;
  padding: 0.4rem 0;
}

.nav-item a:hover,
.nav-item.active a {
  color: var(--text-main);
}

.nav-item.active a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--accent);
  border-radius: 2px;
}

/* Zone 3: 右侧操作区 (搜索入口、用户状态、购物车) */
.header-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  white-space: nowrap;
}

.search-trigger-btn {
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.88rem;
  padding: 0.5rem 0.9rem;
  border-radius: var(--radius-full);
  background-color: rgba(255, 255, 255, 0.6);
  transition: all 0.2s ease;
}

.search-trigger-btn:hover {
  color: var(--text-main);
  background-color: #FFFFFF;
  box-shadow: var(--shadow-sm);
}

.user-status-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-body);
  padding: 0.4rem 0.6rem;
  border-radius: var(--radius-sm);
  transition: color 0.2s ease;
}
.user-status-btn:hover {
  color: var(--text-main);
}

.cart-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: #FFFFFF;
  color: var(--text-main);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.55rem 1.1rem;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
  cursor: pointer;
}

.cart-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px -2px rgba(190, 110, 110, 0.1);
}

.cart-badge {
  background-color: var(--accent);
  color: #FFFFFF;
  font-size: 0.72rem;
  font-weight: 600;
  height: 20px;
  min-width: 20px;
  padding: 0 6px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* 按钮体系 (优雅极简、触控友好) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 500;
  font-size: 0.92rem;
  padding: 0.75rem 1.6rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
  user-select: none;
}

.btn-primary {
  background-color: var(--accent);
  color: #FFFFFF;
  box-shadow: 0 4px 16px -2px rgba(207, 92, 86, 0.25);
}
.btn-primary:hover {
  background-color: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px -4px rgba(207, 92, 86, 0.35);
}

.btn-secondary {
  background-color: #FFFFFF;
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
}
.btn-secondary:hover {
  background-color: #FFFFFF;
  transform: translateY(-1px);
  box-shadow: var(--shadow-card);
}

.btn-outline {
  background-color: transparent;
  color: var(--text-body);
  background-color: rgba(255, 255, 255, 0.5);
}
.btn-outline:hover {
  background-color: #FFFFFF;
  color: var(--text-main);
}

.btn-sm {
  padding: 0.45rem 1rem;
  font-size: 0.85rem;
}

.btn-lg {
  padding: 0.9rem 2.2rem;
  font-size: 1rem;
}

.btn-block {
  width: 100%;
}

/* 零胶囊规范：纯净文字元数据 (Zero-Pill Metadata) */
.meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: var(--text-muted);
}
.meta-sep {
  opacity: 0.6;
}

/* 分段选项卡/筛选控制器 (Segmented Tab Controls) */
.filter-tabs {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(255, 255, 255, 0.7);
  padding: 0.35rem;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-sm);
  overflow-x: auto;
  max-width: 100%;
}

.filter-tab {
  padding: 0.5rem 1.25rem;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-body);
  border-radius: var(--radius-full);
  cursor: pointer;
  background: transparent;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.filter-tab:hover {
  color: var(--text-main);
}

.filter-tab.active {
  background-color: #FFFFFF;
  color: var(--accent);
  box-shadow: 0 4px 12px -2px rgba(190, 110, 110, 0.1);
  font-weight: 600;
}

/* 商品卡片架构 (Leading with Imagery, Clean Hierarchy) */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 2rem;
}

.product-card {
  display: flex;
  flex-direction: column;
  background-color: #FFFFFF;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.product-card-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  background-color: #F6EEEE;
  overflow: hidden;
}

.product-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.product-quick-add {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: #FFFFFF;
  color: var(--text-main);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.2s ease;
  cursor: pointer;
}

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

.product-quick-add:hover {
  background-color: var(--accent);
  color: #FFFFFF;
}

.product-card-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-card-category {
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

.product-card-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.4;
  margin-bottom: 0.5rem;
  text-wrap: balance;
}

.product-card-price-row {
  margin-top: auto;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding-top: 0.75rem;
}

.price-main {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: -0.01em;
}
.price-symbol {
  font-size: 0.85rem;
  margin-right: 2px;
}
.price-original {
  font-size: 0.82rem;
  color: var(--text-light);
  text-decoration: line-through;
  margin-left: 0.4rem;
}

/* 输入框规范 */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 0.5rem;
}

.form-control {
  width: 100%;
  padding: 0.85rem 1.15rem;
  font-size: 0.95rem;
  background-color: #F8EDED;
  color: var(--text-main);
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
}

.form-control:focus {
  background-color: #FFFFFF;
  box-shadow: 0 0 0 3px var(--accent-focus), var(--shadow-sm);
}

.form-control::placeholder {
  color: var(--text-muted);
}

/* 数量步进器 (Quantity Stepper) */
.quantity-stepper {
  display: inline-flex;
  align-items: center;
  background-color: #F8EDED;
  border-radius: var(--radius-full);
  padding: 0.25rem;
}

.quantity-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: transparent;
  color: var(--text-main);
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.quantity-btn:hover {
  background-color: #FFFFFF;
  box-shadow: var(--shadow-sm);
}

.quantity-input {
  width: 44px;
  text-align: center;
  font-weight: 600;
  font-size: 0.95rem;
  background: transparent;
  color: var(--text-main);
}

/* 全局Toast提示系统 */
.toast-container {
  position: fixed;
  top: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  pointer-events: none;
}

.toast-msg {
  pointer-events: auto;
  background-color: #FFFFFF;
  color: var(--text-main);
  padding: 0.85rem 1.5rem;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-float);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.92rem;
  font-weight: 500;
  animation: toastIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.toast-msg.toast-success i, .toast-msg.toast-success .toast-icon {
  color: var(--color-success);
}
.toast-msg.toast-error i, .toast-msg.toast-error .toast-icon {
  color: var(--color-error);
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(-16px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* 底部极简版式 */
.site-footer {
  margin-top: auto;
  background-color: #F8EDED;
  padding: 4.5rem 0 2.5rem 0;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3.5rem;
}

.footer-brand p {
  margin-top: 1rem;
  max-width: 340px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.footer-col h5 {
  font-size: 0.9rem;
  color: var(--text-main);
  margin-bottom: 1.25rem;
  letter-spacing: 0.02em;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-col a {
  font-size: 0.88rem;
  color: var(--text-muted);
}
.footer-col a:hover {
  color: var(--text-main);
}

.footer-bottom {
  padding-top: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* 响应式断点适配 */
@media (max-width: 992px) {
  .nav-links {
    display: none;
  }
  .footer-top {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.6rem; }
  .header-inner { height: 64px; }
  .footer-top { grid-template-columns: 1fr; gap: 2rem; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
  .container { padding-left: 1.25rem; padding-right: 1.25rem; }
}

/* Keep original fixed desktop design with real, potentially long product content. */
[hidden]{display:none!important}
.pdp-split>*,.gallery-column,.purchase-module{min-width:0;max-width:100%}
.thumb-row{max-width:100%;overflow-x:auto;padding-bottom:4px}
.thumb-item{flex:0 0 80px}
.breadcrumbs{flex-wrap:wrap;overflow-wrap:anywhere}
#detail-rich-content{overflow-wrap:anywhere}
#detail-rich-content *{max-width:100%;box-sizing:border-box}
#detail-rich-content img{height:auto;display:block}
#detail-rich-content table{table-layout:fixed;width:100%}
.header-inner .brand-wordmark{max-width:340px;overflow-wrap:anywhere}
body>main{flex:1}

.image-empty{display:grid;place-items:center;color:var(--text-muted)}
.image-empty::after{content:'暂无商品图片'}

.cart-item-row .quantity-stepper{display:inline-flex;align-items:center;justify-content:center;gap:6px;white-space:nowrap}
#shippingProgressBar{width:0}
.checkout-row>strong:last-child{white-space:nowrap;flex-shrink:0;padding-left:12px}
#aura-pager,#store-pager{display:flex;align-items:center;flex-wrap:wrap;gap:8px;padding-top:20px}
#aura-pager button,#store-pager button{border-radius:var(--radius-full);background:var(--bg-card);color:var(--text-body);padding:8px 12px;cursor:pointer}
#aura-pager button:disabled,#store-pager button:disabled{opacity:.45;cursor:default}

/* 组合站的其他业务入口沿用商城导航；窄屏仍保留此入口。 */
@media (max-width: 1200px) {
  .header-inner:has([data-composition-entry]) { gap: 1rem; }
  .nav-links:has([data-composition-entry]) { gap: 1rem; }
}
@media (max-width: 992px) {
  .header-inner:has([data-composition-entry]) { height: auto; min-height: 64px; flex-wrap: wrap; gap: .5rem 1rem; padding-top: .5rem; padding-bottom: .5rem; }
  .nav-links:has([data-composition-entry]) { display: flex; flex-basis: 100%; order: 3; justify-content: flex-end; }
  .nav-links:has([data-composition-entry]) > .nav-item:not([data-composition-entry]) { display: none; }
}

/* 商品列表：控制长商品名称的行数，保持卡片价格和操作对齐。 */
body[data-page="products"] .catalog-title {
  font-size: clamp(1.65rem, 2.5vw, 1.9rem);
  margin-bottom: .75rem;
}
#productCatalogGrid {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr));
}
#productCatalogGrid .product-card-body {
  padding: 1.15rem 1.25rem 1.25rem;
}
#productCatalogGrid .product-card-category {
  letter-spacing: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#productCatalogGrid .product-card-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
  overflow-wrap: anywhere;
  text-wrap: initial;
  font-size: .9rem;
  font-weight: 500;
  line-height: 1.55;
  min-height: 4.65em;
  margin-bottom: .4rem;
}
#productCatalogGrid .product-card-body > p {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  overflow-wrap: anywhere;
  font-size: .82rem;
  line-height: 1.5;
}
#productCatalogGrid .product-card-price-row {
  gap: .5rem;
  flex-wrap: wrap;
  padding-top: .9rem;
}
#productCatalogGrid .price-main { font-size: 1.1rem; }
