/* ============================================================
   Zhuomei Flooring — global stylesheet
   常州卓美材料有限公司 · Independent storefront
   ============================================================ */

:root {
  --bg: #faf8f4;
  --surface: #ffffff;
  --ink: #27231e;
  --muted: #6f675c;
  --line: #e8e1d5;
  --accent: #b9742f;
  --accent-dark: #96591f;
  --accent-soft: #f7ede1;
  --dark: #211b15;
  --dark-2: #2c241c;
  --ok: #3c7a4e;
  --danger: #b04a3a;
  --whatsapp: #25d366;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 10px 30px rgba(64, 45, 22, 0.09);
  --shadow-lg: 0 18px 50px rgba(64, 45, 22, 0.16);
  --maxw: 1200px;
  --font-sans: "Segoe UI", "Helvetica Neue", Arial, "PingFang SC",
    "Microsoft YaHei", sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; }
input, textarea, select { font-family: inherit; font-size: 1rem; }

.container { width: min(var(--maxw), calc(100% - 40px)); margin: 0 auto; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; gap: 28px;
  height: 72px;
}
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: 0.04em; }
.logo svg { flex: none; }
.logo .brand-sub { display: block; font-size: 0.62rem; font-weight: 600; letter-spacing: 0.18em; color: var(--muted); }
.logo .brand-main { font-size: 1.05rem; line-height: 1.15; color: var(--ink); }

.main-nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.main-nav a {
  padding: 8px 14px; border-radius: 999px;
  font-size: 0.95rem; font-weight: 500; color: var(--ink);
  transition: background 0.15s ease, color 0.15s ease;
}
.main-nav a:hover { background: var(--accent-soft); color: var(--accent-dark); }
.main-nav a.active { background: var(--accent-soft); color: var(--accent-dark); font-weight: 600; }

.header-actions { display: flex; align-items: center; gap: 10px; }
.cart-btn {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--surface); font-weight: 600; font-size: 0.9rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.cart-btn:hover { border-color: var(--accent); box-shadow: var(--shadow); }
.cart-count {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 20px; height: 20px; padding: 0 6px;
  background: var(--accent); color: #fff; border-radius: 999px;
  font-size: 0.72rem; font-weight: 700;
}
.cart-count[hidden] { display: none; }

.nav-toggle {
  display: none; border: 1px solid var(--line); background: var(--surface);
  border-radius: 9px; padding: 8px 10px; line-height: 0;
}

/* ---------- Hero ---------- */
.hero {
  position: relative; color: #fff;
  background: var(--dark) center/cover no-repeat;
  min-height: 560px; display: flex; align-items: center;
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, rgba(24, 17, 10, 0.82) 8%, rgba(24, 17, 10, 0.55) 46%, rgba(24, 17, 10, 0.18) 100%);
}
.hero-inner { position: relative; z-index: 1; padding: 90px 0; max-width: 640px; }
.hero .eyebrow {
  display: inline-block; padding: 6px 14px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35); font-size: 0.78rem;
  letter-spacing: 0.14em; text-transform: uppercase; margin-bottom: 22px;
}
.hero h1 { font-size: clamp(2rem, 4.4vw, 3.2rem); line-height: 1.12; font-weight: 800; margin-bottom: 18px; }
.hero p { font-size: 1.08rem; color: rgba(255, 255, 255, 0.86); max-width: 540px; margin-bottom: 30px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-stats {
  position: relative; z-index: 1; margin-top: 46px; padding-top: 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.22);
  display: flex; flex-wrap: wrap; gap: 34px;
}
.hero-stats b { display: block; font-size: 1.5rem; font-weight: 800; }
.hero-stats span { font-size: 0.82rem; color: rgba(255, 255, 255, 0.72); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 12px 24px; border-radius: 999px; font-weight: 700; font-size: 0.95rem;
  border: 1px solid transparent; transition: transform 0.12s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 8px 22px rgba(185, 116, 47, 0.32); }
.btn-primary:hover { background: var(--accent-dark); }
.btn-light { background: #fff; color: var(--dark); }
.btn-light:hover { box-shadow: var(--shadow-lg); }
.btn-outline { border-color: var(--line); background: var(--surface); color: var(--ink); }
.btn-outline:hover { border-color: var(--accent); color: var(--accent-dark); }
.btn-whatsapp { background: var(--whatsapp); color: #fff; }
.btn-whatsapp:hover { filter: brightness(0.96); }
.btn-sm { padding: 8px 16px; font-size: 0.85rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; }

/* ---------- Sections ---------- */
.section { padding: 78px 0; }
.section.tight { padding: 52px 0; }
.section-head { max-width: 720px; margin: 0 auto 46px; text-align: center; }
.section-head.left { margin: 0 0 34px; text-align: left; }
.eyebrow {
  display: inline-block; font-size: 0.78rem; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent-dark);
  margin-bottom: 12px;
}
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); font-weight: 800; line-height: 1.2; }
.section-head p { margin-top: 12px; color: var(--muted); }

/* ---------- Category cards ---------- */
.cat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.cat-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex; flex-direction: column;
}
.cat-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.cat-card .cat-img { aspect-ratio: 4 / 3; overflow: hidden; background: var(--accent-soft); }
.cat-card .cat-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.35s ease; }
.cat-card:hover .cat-img img { transform: scale(1.04); }
.cat-card .cat-body { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.cat-card h3 { font-size: 1.22rem; font-weight: 800; }
.cat-card p { color: var(--muted); font-size: 0.95rem; flex: 1; }
.cat-link { font-weight: 700; color: var(--accent-dark); font-size: 0.92rem; display: inline-flex; align-items: center; gap: 6px; }
.cat-link:hover { text-decoration: underline; }

/* ---------- Product cards ---------- */
.product-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.product-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.product-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.product-card .p-img { position: relative; aspect-ratio: 4 / 3; background: var(--accent-soft); overflow: hidden; }
.product-card .p-img img { width: 100%; height: 100%; object-fit: cover; }
.product-card .p-img .badge {
  position: absolute; top: 12px; left: 12px;
  background: var(--ok); color: #fff; font-size: 0.7rem; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase; padding: 5px 10px; border-radius: 999px;
}
.p-body { padding: 20px 22px 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.p-cat { font-size: 0.74rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.p-name { font-size: 1.06rem; font-weight: 800; line-height: 1.35; }
.p-specs { font-size: 0.85rem; color: var(--muted); }
.p-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 14px; border-top: 1px dashed var(--line); }
.p-price b { font-size: 1.22rem; color: var(--accent-dark); }
.p-price span { display: block; font-size: 0.74rem; color: var(--muted); }
.p-actions { display: flex; gap: 8px; }

/* ---------- Value props ---------- */
.props { background: var(--dark); color: #fff; }
.props-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; }
.prop { display: flex; gap: 16px; align-items: flex-start; }
.prop svg { flex: none; margin-top: 2px; }
.prop h4 { font-size: 1.02rem; font-weight: 700; margin-bottom: 6px; }
.prop p { font-size: 0.88rem; color: rgba(255, 255, 255, 0.68); }

/* ---------- Split banner (factory / CTA) ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 46px; align-items: center; }
.split-img img { border-radius: var(--radius); box-shadow: var(--shadow-lg); width: 100%; }
.split h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; line-height: 1.2; margin-bottom: 18px; }
.split p { color: var(--muted); margin-bottom: 14px; }
.check-list { margin: 18px 0 26px; display: grid; gap: 12px; }
.check-list li { display: flex; gap: 10px; align-items: flex-start; font-size: 0.97rem; }
.check-list svg { flex: none; margin-top: 3px; color: var(--ok); }

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(120deg, var(--accent-dark), var(--accent));
  color: #fff; border-radius: var(--radius); padding: 46px 52px;
  display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap;
}
.cta-band h2 { font-size: 1.7rem; font-weight: 800; }
.cta-band p { color: rgba(255, 255, 255, 0.85); margin-top: 6px; }

/* ---------- Page hero (inner pages) ---------- */
.page-hero { background: var(--dark-2); color: #fff; padding: 64px 0; }
.page-hero h1 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); font-weight: 800; }
.page-hero p { color: rgba(255, 255, 255, 0.75); max-width: 640px; margin-top: 10px; }
.breadcrumb { font-size: 0.82rem; color: rgba(255, 255, 255, 0.6); margin-bottom: 12px; }
.breadcrumb a:hover { color: #fff; text-decoration: underline; }

/* ---------- Filter chips ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 40px; }
.chip {
  padding: 9px 20px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--surface); font-weight: 600; font-size: 0.9rem; color: var(--ink);
  transition: all 0.15s ease;
}
.chip:hover { border-color: var(--accent); }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ---------- Product detail ---------- */
.pd-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: start; }
.pd-img { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.pd-img img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.pd-cat { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent-dark); margin-bottom: 10px; }
.pd-name { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; line-height: 1.2; margin-bottom: 8px; }
.pd-sku { font-size: 0.85rem; color: var(--muted); margin-bottom: 20px; }
.pd-price { display: flex; align-items: baseline; gap: 10px; margin-bottom: 18px; }
.pd-price b { font-size: 2rem; color: var(--accent-dark); }
.pd-price span { color: var(--muted); font-size: 0.9rem; }
.pd-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.tag { background: var(--accent-soft); color: var(--accent-dark); border-radius: 999px; padding: 5px 13px; font-size: 0.8rem; font-weight: 600; }
.pd-qty { display: flex; align-items: center; gap: 14px; margin: 24px 0 12px; }
.qty-box { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; background: var(--surface); }
.qty-box button { width: 40px; height: 44px; border: 0; background: transparent; font-size: 1.15rem; font-weight: 700; color: var(--ink); }
.qty-box button:hover { background: var(--accent-soft); }
.qty-box input {
  width: 74px; height: 44px; border: 0; text-align: center; font-weight: 700;
  border-left: 1px solid var(--line); border-right: 1px solid var(--line);
  -moz-appearance: textfield;
}
.qty-box input::-webkit-outer-spin-button, .qty-box input::-webkit-inner-spin-button { -webkit-appearance: none; }
.pd-note { font-size: 0.85rem; color: var(--muted); margin-bottom: 8px; }
.pd-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 20px 0 8px; }

.spec-table { width: 100%; border-collapse: collapse; margin-top: 26px; }
.spec-table th, .spec-table td {
  text-align: left; padding: 11px 14px; font-size: 0.93rem;
  border-bottom: 1px solid var(--line);
}
.spec-table th { width: 40%; color: var(--muted); font-weight: 600; background: #fdfbf7; }
.pd-features { margin-top: 28px; }
.pd-features h3 { font-size: 1.1rem; font-weight: 800; margin-bottom: 14px; }

/* ---------- Forms ---------- */
.form-card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 34px; box-shadow: var(--shadow);
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; font-size: 0.86rem; font-weight: 700; margin-bottom: 7px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: #fdfcf9; color: var(--ink); outline: none; transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field input:focus, .field textarea:focus, .field select:focus {
  border-color: var(--accent); box-shadow: 0 0 0 3px rgba(185, 116, 47, 0.15);
}
.field textarea { resize: vertical; min-height: 130px; }
.form-note { font-size: 0.82rem; color: var(--muted); margin-top: 14px; }

/* ---------- Contact cards ---------- */
.contact-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-bottom: 44px; }
.contact-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; display: flex; flex-direction: column; gap: 10px;
}
.contact-card svg { color: var(--accent); }
.contact-card h3 { font-size: 1.02rem; font-weight: 800; }
.contact-card p, .contact-card a { font-size: 0.93rem; color: var(--muted); }
.contact-card a:hover { color: var(--accent-dark); text-decoration: underline; }

/* ---------- FAQ ---------- */
.faq-list { max-width: 860px; margin: 0 auto; display: grid; gap: 14px; }
.faq-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.faq-item summary {
  cursor: pointer; padding: 19px 22px; font-weight: 700; font-size: 1rem;
  list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 14px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-size: 1.4rem; color: var(--accent); transition: transform 0.2s ease; line-height: 1; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .faq-a { padding: 0 22px 20px; color: var(--muted); font-size: 0.95rem; }

/* ---------- Cart ---------- */
.cart-table { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.cart-row {
  display: grid; grid-template-columns: 90px 1fr 150px 130px 90px 44px;
  align-items: center; gap: 16px; padding: 18px 22px; border-bottom: 1px solid var(--line);
}
.cart-row:last-child { border-bottom: 0; }
.cart-row .c-img { border-radius: var(--radius-sm); overflow: hidden; aspect-ratio: 4 / 3; }
.cart-row .c-img img { width: 100%; height: 100%; object-fit: cover; }
.cart-row .c-name { font-weight: 700; font-size: 0.97rem; }
.cart-row .c-meta { font-size: 0.8rem; color: var(--muted); }
.cart-row .c-unit { font-size: 0.9rem; color: var(--muted); }
.cart-row .c-line { font-weight: 700; color: var(--accent-dark); }
.cart-remove { border: 0; background: transparent; color: var(--muted); font-size: 1.2rem; line-height: 1; padding: 6px; border-radius: 8px; }
.cart-remove:hover { color: var(--danger); background: #fbeae7; }
.cart-summary {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow); position: sticky; top: 96px;
}
.summary-line { display: flex; justify-content: space-between; padding: 9px 0; font-size: 0.95rem; color: var(--muted); }
.summary-line.total { border-top: 1px solid var(--line); margin-top: 10px; padding-top: 16px; font-size: 1.15rem; font-weight: 800; color: var(--ink); }
.summary-line.total b { color: var(--accent-dark); font-size: 1.3rem; }
.cart-layout { display: grid; grid-template-columns: 1fr 360px; gap: 34px; align-items: start; }
.empty-cart { text-align: center; padding: 80px 20px; }
.empty-cart svg { margin: 0 auto 20px; color: var(--line); }
.empty-cart h2 { font-weight: 800; margin-bottom: 8px; }
.empty-cart p { color: var(--muted); margin-bottom: 22px; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 30px; transform: translate(-50%, 20px);
  background: var(--dark); color: #fff; padding: 13px 22px; border-radius: 999px;
  font-size: 0.92rem; font-weight: 600; opacity: 0; pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease; z-index: 200;
  box-shadow: var(--shadow-lg); max-width: calc(100vw - 40px);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- WhatsApp float ---------- */
.wa-float {
  position: fixed; right: 22px; bottom: 22px; z-index: 150;
  width: 58px; height: 58px; border-radius: 50%;
  background: var(--whatsapp); display: flex; align-items: center; justify-content: center;
  box-shadow: 0 12px 30px rgba(37, 211, 102, 0.45);
  transition: transform 0.2s ease;
}
.wa-float:hover { transform: scale(1.08); }

/* ---------- Footer ---------- */
.site-footer { background: var(--dark); color: #fff; margin-top: 40px; }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; padding: 60px 0 46px; }
.footer-brand p { color: rgba(255, 255, 255, 0.62); font-size: 0.92rem; margin-top: 14px; max-width: 300px; }
.footer-col h4 { font-size: 0.85rem; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 18px; color: rgba(255, 255, 255, 0.85); }
.footer-col ul { display: grid; gap: 10px; }
.footer-col a { color: rgba(255, 255, 255, 0.62); font-size: 0.93rem; }
.footer-col a:hover { color: #fff; text-decoration: underline; }
.footer-col p { color: rgba(255, 255, 255, 0.62); font-size: 0.9rem; display: flex; gap: 9px; align-items: flex-start; margin-bottom: 10px; }
.footer-col p svg { flex: none; margin-top: 3px; opacity: 0.75; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 20px 0; display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  font-size: 0.82rem; color: rgba(255, 255, 255, 0.5);
}

/* ---------- Misc ---------- */
.mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; } .mt-4 { margin-top: 34px; }
.text-center { text-align: center; }
.muted { color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .cat-grid, .product-grid { grid-template-columns: repeat(2, 1fr); }
  .props-grid { grid-template-columns: repeat(2, 1fr); }
  .pd-grid { grid-template-columns: 1fr; gap: 30px; }
  .cart-layout { grid-template-columns: 1fr; }
  .cart-summary { position: static; }
  .split { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .form-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .nav-toggle { display: inline-flex; }
  .main-nav {
    display: none; position: absolute; top: 72px; left: 0; right: 0;
    background: var(--surface); border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: stretch; padding: 12px 20px 18px; gap: 2px;
    box-shadow: var(--shadow-lg);
  }
  .main-nav.open { display: flex; }
  .main-nav a { border-radius: 10px; }
  .header-inner { gap: 14px; }
  .cart-btn span.cart-label { display: none; }
  .hero { min-height: 0; }
  .hero-inner { padding: 70px 0 60px; }
  .hero-stats { gap: 20px; }
}

@media (max-width: 560px) {
  .cat-grid, .product-grid, .props-grid, .contact-grid { grid-template-columns: 1fr; }
  .cart-row { grid-template-columns: 64px 1fr auto; grid-template-areas: "img name remove" "img qty line"; row-gap: 8px; }
  .cart-row .c-img { grid-area: img; }
  .cart-row .c-main { grid-area: name; }
  .cart-row .c-qty { grid-area: qty; }
  .cart-row .c-line { grid-area: line; justify-self: end; }
  .cart-row .cart-remove { grid-area: remove; justify-self: end; }
  .cta-band { padding: 34px 26px; }
  .footer-top { grid-template-columns: 1fr; gap: 30px; }
}
