/* ===== H5 展示页 · 基础与区块样式（弹层/表单等见 h5-ui.css）===== */
:root {
  --ink: #1d2127; --ink-2: #3b414b; --muted: #8b9099; --line: #ebe6de; --bg: #f6f4f0; --card: #fff;
  --gold: #bf9656; --gold-l: #e5c99a; --gold-d: #9c7540; --gold-bg: #f8f1e6;
  --gold-grad: linear-gradient(135deg, #e0bf86 0%, #bb8f4f 100%);
  --price: #c4472d; --r: 16px; --shadow: 0 6px 24px rgba(29, 33, 39, .06);
  --num: "DIN Alternate", "Bahnschrift", "Helvetica Neue", Arial, sans-serif;
  --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { font: 14px/1.6 -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif; color: var(--ink); background: #e9e5de; }
body.lock { overflow: hidden; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
.app { max-width: 480px; margin: 0 auto; min-height: 100vh; background: var(--bg); padding-bottom: calc(84px + var(--safe-b)); position: relative; overflow-x: clip; }
@media (min-width: 520px) { .app { box-shadow: 0 0 60px rgba(0, 0, 0, .08); } }

/* 加载 / 错误 */
.loading { min-height: 100vh; display: grid; place-items: center; }
.spinner { width: 32px; height: 32px; border-radius: 50%; border: 3px solid #e5dccd; border-top-color: var(--gold); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.error { min-height: 80vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; color: var(--muted); padding: 24px; text-align: center; }

/* 顶部栏 */
.topbar { position: sticky; top: 0; z-index: 20; height: 56px; display: flex; align-items: center; justify-content: space-between; padding: 0 16px; background: rgba(246, 244, 240, .88); backdrop-filter: saturate(180%) blur(14px); -webkit-backdrop-filter: saturate(180%) blur(14px); }
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.logo { flex: none; width: 34px; height: 34px; border-radius: 10px; background: var(--ink); color: var(--gold-l); display: grid; place-items: center; font-weight: 700; font-size: 17px; overflow: hidden; }
.logo img { width: 100%; height: 100%; object-fit: cover; }
.brand b { display: block; font-size: 16px; letter-spacing: .5px; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand small { display: block; font-size: 9px; color: var(--muted); letter-spacing: 1.2px; line-height: 1.3; white-space: nowrap; }
.icon-btn { flex: none; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--ink); color: var(--gold-l); border: 0; }
.icon-btn svg { width: 18px; height: 18px; }

/* 公告 */
.notice { margin: 2px 12px 0; height: 34px; display: flex; align-items: center; gap: 8px; padding: 0 12px; border-radius: 10px; background: #fff6e8; color: #8a6332; font-size: 12.5px; }
.notice svg { width: 15px; height: 15px; flex: none; }
.marquee { flex: 1; overflow: hidden; white-space: nowrap; -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.marquee span { display: inline-block; padding-left: 100%; animation: marquee 16s linear infinite; }
@keyframes marquee { to { transform: translateX(-100%); } }

/* 轮播 */
.hero { position: relative; margin: 12px 12px 0; border-radius: 18px; overflow: hidden; box-shadow: 0 10px 30px rgba(29, 33, 39, .18); background: #2a2d33; }
.h-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.h-track::-webkit-scrollbar { display: none; }
.h-slide { position: relative; flex: 0 0 100%; scroll-snap-align: start; aspect-ratio: 750 / 440; cursor: pointer; }
.h-slide img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.h-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(15, 17, 21, .72) 0%, rgba(15, 17, 21, .28) 58%, transparent); }
.h-slide.plain::after { display: none; }
.h-text { position: absolute; z-index: 1; left: 20px; top: 50%; transform: translateY(-50%); color: #fff; max-width: 68%; }
.h-text h2 { font-size: 22px; line-height: 1.3; font-weight: 700; letter-spacing: 1px; text-shadow: 0 2px 12px rgba(0, 0, 0, .25); }
.h-text p { font-size: 12px; opacity: .88; margin-top: 6px; }
.h-btn { display: inline-flex; align-items: center; gap: 4px; margin-top: 14px; padding: 6px 14px; border-radius: 99px; background: var(--gold-grad); color: #fff; font-size: 12px; font-weight: 600; }
.h-btn svg { width: 14px; height: 14px; }
.h-dots { position: absolute; bottom: 12px; left: 20px; display: flex; gap: 6px; z-index: 2; }
.h-dots i { width: 6px; height: 6px; border-radius: 3px; background: rgba(255, 255, 255, .45); transition: width .3s, background .3s; }
.h-dots i.on { width: 18px; background: var(--gold-l); }

/* 数据亮点 */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); margin: 14px 12px 0; padding: 16px 4px; background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); text-align: center; }
.stats div + div { border-left: 1px solid var(--line); }
.stats b { display: block; font: 700 20px/1.2 var(--num); color: var(--gold-d); }
.stats span { font-size: 11px; color: var(--muted); }

/* 分类入口 */
.quick { display: grid; grid-template-columns: repeat(5, 1fr); row-gap: 14px; margin: 14px 12px 0; padding: 16px 4px 14px; background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); }
.q-item { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12px; color: var(--ink-2); background: none; border: 0; min-width: 0; }
.q-item span { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.q-img { width: 50px; height: 50px; border-radius: 50%; overflow: hidden; background: #f1ede6; box-shadow: 0 0 0 1px var(--line), 0 4px 10px rgba(0, 0, 0, .06); }
.q-img img { width: 100%; height: 100%; object-fit: cover; }

/* 区块通用 */
.sec { margin-top: 30px; padding: 0 12px; scroll-margin-top: 64px; }
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; margin: 0 4px 14px; }
.sec-head em { display: block; font: 600 10px/1 var(--num); letter-spacing: 3px; color: var(--gold); font-style: normal; margin-bottom: 6px; }
.sec-head h3 { font-size: 19px; font-weight: 700; letter-spacing: .5px; line-height: 1.2; }
.sec-head .more { font-size: 12px; color: var(--muted); background: none; border: 0; display: inline-flex; align-items: center; }
.sec-head .more svg { width: 14px; height: 14px; }

/* 品牌优势（深色带） */
.adv { margin-top: 30px; padding: 28px 16px; background: var(--ink) radial-gradient(circle at 100% 0, rgba(191, 150, 86, .25), transparent 55%); color: #fff; }
.adv .sec-head { margin-left: 0; margin-right: 0; }
.adv .sec-head h3 { color: #fff; }
.adv-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.adv-item { padding: 16px 14px; border-radius: 14px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .08); }
.adv-item svg { width: 26px; height: 26px; color: var(--gold-l); }
.adv-item h4 { font-size: 15px; margin: 10px 0 4px; }
.adv-item p { font-size: 12px; color: rgba(255, 255, 255, .62); line-height: 1.6; }

/* 分类 Tab（吸顶） */
.tabs { position: sticky; top: 56px; z-index: 10; display: flex; gap: 8px; overflow-x: auto; margin: 0 -12px 6px; padding: 8px 16px 10px; background: var(--bg); scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; height: 32px; padding: 0 16px; border-radius: 16px; border: 0; background: #fff; color: var(--ink-2); font-size: 13px; box-shadow: inset 0 0 0 1px var(--line); transition: background .2s, color .2s; }
.tabs button.on { background: var(--ink); color: var(--gold-l); box-shadow: none; font-weight: 600; }

/* 产品卡片 */
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pcard { background: var(--card); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; cursor: pointer; }
.pcard:active { transform: scale(.98); }
.pimg { position: relative; aspect-ratio: 4 / 3; background: #eef0f2; }
.pimg img { width: 100%; height: 100%; object-fit: cover; }
.badge { position: absolute; left: 8px; top: 8px; padding: 1px 8px; border-radius: 6px; font-size: 11px; color: #fff; background: linear-gradient(135deg, #ec7352, #cf452c); font-weight: 600; }
.pbody { padding: 10px 10px 12px; display: flex; flex-direction: column; flex: 1; }
.pbody h4 { font-size: 14px; line-height: 1.4; font-weight: 600; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pbody .sub { font-size: 11px; color: var(--muted); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.tags i { font-style: normal; font-size: 10px; line-height: 18px; padding: 0 6px; border-radius: 4px; color: var(--gold-d); background: var(--gold-bg); }
.price { margin-top: auto; padding-top: 8px; display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 2px; color: var(--price); }
.price b { font: 700 19px/1 var(--num); }
.price small { font-size: 12px; font-weight: 700; }
.price span { font-size: 11px; color: var(--muted); }
.price del { font-size: 11px; color: #b5b9bf; margin-left: 4px; }
.price.ask b, .d-price.ask b { font-family: inherit; font-size: 15px; font-weight: 600; }
.empty { grid-column: 1 / -1; padding: 40px 0; text-align: center; color: var(--muted); font-size: 13px; }

/* 服务流程 */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.step { position: relative; padding: 14px 12px 12px; background: var(--card); border-radius: 14px; box-shadow: var(--shadow); overflow: hidden; }
.step b { font: 700 22px/1 var(--num); color: var(--gold-l); }
.step p { font-size: 13px; margin-top: 8px; font-weight: 600; line-height: 1.4; }
.step::after { content: ""; position: absolute; right: -14px; bottom: -14px; width: 44px; height: 44px; border-radius: 50%; background: var(--gold-bg); }

/* 装修案例 */
.cases { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 -12px; padding: 2px 16px 12px; scrollbar-width: none; }
.cases::-webkit-scrollbar { display: none; }
.case { flex: 0 0 78%; scroll-snap-align: center; background: var(--card); border-radius: 16px; overflow: hidden; box-shadow: var(--shadow); cursor: pointer; }
.case-img { position: relative; aspect-ratio: 16 / 10; background: #2a2d33; }
.case-img img { width: 100%; height: 100%; object-fit: cover; }
.case-img span { position: absolute; left: 10px; bottom: 10px; padding: 2px 8px; border-radius: 6px; background: rgba(0, 0, 0, .5); color: #fff; font-size: 11px; backdrop-filter: blur(4px); }
.case-body { padding: 12px 14px 14px; }
.case-body h4 { font-size: 15px; line-height: 1.4; }
.meta { font-size: 12px; color: var(--muted); margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* 关于我们 / 联系方式 */
.about-text { font-size: 13.5px; color: var(--ink-2); line-height: 1.85; white-space: pre-line; max-height: 5.55em; overflow: hidden; position: relative; }
.about-text.open { max-height: none; }
.expand { margin-top: 6px; font-size: 12px; color: var(--gold-d); background: none; border: 0; }
.contact { margin-top: 12px; border-top: 1px dashed var(--line); }
.c-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid #f3f0eb; }
.c-row:last-child { border-bottom: 0; padding-bottom: 0; }
.c-row > svg { width: 18px; height: 18px; color: var(--gold); flex: none; }
.c-row div { flex: 1; min-width: 0; }
.c-row small { display: block; font-size: 11px; color: var(--muted); line-height: 1.4; }
.c-row b { font-weight: 500; font-size: 14px; word-break: break-all; }
.c-act { flex: none; font-size: 12px; color: var(--gold-d); padding: 4px 12px; border-radius: 14px; background: var(--gold-bg); border: 0; }

/* 页脚 */
.footer { text-align: center; padding: 28px 16px 8px; font-size: 11px; color: #a7abb2; line-height: 1.9; }

/* 滚动出现动画 */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .marquee span { animation: none; padding-left: 0; }
}
