/* 乐赛佳官网 · 极简自写样式（无框架依赖，移动优先） */
:root {
  --ink: #1f2a36;
  --muted: #5b6b7b;
  --brand: #12436b;
  --brand-dark: #0c2f4b;
  --accent: #c2410c;
  --bg: #f7f8fa;
  --line: #e3e8ee;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
figure { margin: 0; }
body {
  margin: 0;
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
}
img { max-width: 100%; display: block; }
a { color: var(--brand); }
.wrap { max-width: 1100px; margin: 0 auto; padding: 0 20px; }
.section { padding: 48px 20px; }
.section-alt { background: #fff; }
h1 { font-size: 1.7rem; line-height: 1.35; }
h2 { font-size: 1.35rem; margin: 0 0 18px; }
h3 { font-size: 1.05rem; margin: 0 0 8px; }
.section-intro { color: var(--muted); margin-top: -6px; }
.section-note { color: var(--muted); font-size: 0.92rem; }

/* 页头 / 页脚（桌面 76px 大方留白；移动端侧滑抽屉菜单） */
.site-header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.header-inner { display: flex; align-items: center; gap: 24px; height: 76px; }
.brand { font-size: 1.45rem; font-weight: 700; color: var(--brand-dark); text-decoration: none; display: flex; align-items: center; gap: 10px; }
.brand-logo { height: 46px; width: auto; }
.brand-text { letter-spacing: 5px; white-space: nowrap; }
.nav { display: flex; gap: 10px; margin-left: auto; }
.nav a { text-decoration: none; color: var(--ink); font-size: 1.02rem; padding: 9px 16px; border-radius: 8px; letter-spacing: 1px; transition: color .2s ease, background-color .2s ease; }
.nav a:hover { color: var(--brand); background: #f0f4f8; }
.nav a.active { color: var(--brand); font-weight: 600; background: #e8eff6; }
.nav-backdrop { display: none; }
.nav-toggle { display: none; }
.site-footer { background: var(--brand-dark); color: #cfd9e3; margin-top: 0; padding: 28px 0; font-size: 0.9rem; }
.site-footer p { margin: 4px 0; }
.site-footer a { color: #fff; }
.f-flex { display: flex; align-items: flex-start; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.f-qr { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 0.85rem; color: #cfd9e3; }
.f-qr img { background: #fff; border-radius: 8px; padding: 4px; }
.f-company { font-weight: 600; color: #fff; text-decoration: none; }
.f-company:hover { text-decoration: underline; }
.f-beian { color: #9fb2c4; }

/* 首页 */
.hero { background: linear-gradient(135deg, var(--brand-dark), var(--brand)); color: #fff; padding: 92px 0; }
.hero-photo { background-size: cover; background-position: center; }
.hero-eyebrow { display: inline-block; font-size: 0.88rem; letter-spacing: 1px; color: #ffd9c2; border: 1px solid rgba(255,217,194,.45); border-radius: 999px; padding: 4px 14px; margin: 0 0 16px; }
.hero h1 { font-size: 2.3rem; margin: 0 0 12px; letter-spacing: 1px; }
.hero-sub { color: #d7e2ec; font-size: 1.08rem; margin: 0 0 26px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }

/* 数字统计带 */
.stats-band { background: #fff; border-bottom: 1px solid var(--line); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 36px 20px; }
.stat { text-align: center; }
.stat-num { font-size: 2.2rem; font-weight: 700; color: var(--brand); font-variant-numeric: tabular-nums; line-height: 1.2; }
.stat-label { color: var(--muted); font-size: 0.92rem; margin-top: 4px; }

/* 滚动渐入（尊重减弱动效偏好） */
@media (prefers-reduced-motion: no-preference) {
  [data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .5s ease, transform .5s ease; }
  [data-reveal].revealed { opacity: 1; transform: none; }
}

/* 页头滚动阴影 */
.site-header.scrolled { box-shadow: 0 2px 14px rgba(18,42,66,.10); }

/* 返回顶部 */
#back-top { position: fixed; right: 18px; bottom: 74px; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: #fff; color: var(--brand); font-size: 1.15rem; cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0; line-height: 1; opacity: 0; visibility: hidden; transition: opacity .2s ease, visibility .2s ease; box-shadow: 0 4px 14px rgba(18,42,66,.16); z-index: 20; }
#back-top.show { opacity: 1; visibility: visible; }
#back-top:hover { background: var(--brand); color: #fff; }

/* 企业微信在线咨询浮钮：收起态小圆钮（低调），悬停展开橙色药丸 */
.kf-float { position: fixed; right: 18px; bottom: 18px; z-index: 21; display: flex; align-items: center; width: 46px; height: 46px; padding: 0; border-radius: 23px; border: 1px solid var(--line); background: #fff; color: var(--brand); text-decoration: none; overflow: hidden; white-space: nowrap; box-shadow: 0 4px 14px rgba(18,42,66,.16); transition: width .25s ease, background-color .2s ease, color .2s ease, border-color .2s ease; }
.kf-float svg { width: 22px; height: 22px; flex-shrink: 0; margin: 0 auto; transition: margin .25s ease; }
.kf-float span { max-width: 0; opacity: 0; overflow: hidden; transition: max-width .25s ease, opacity .2s ease, margin .25s ease; }
.kf-float:hover { width: 138px; background: var(--accent); color: #fff; border-color: var(--accent); }
.kf-float:hover svg { margin: 0 0 0 10px; }
.kf-float:hover span { max-width: 72px; opacity: 1; margin-right: 12px; }

/* 交付案例滚动带（内容渲染两份，位移 -50% 实现无缝循环；8px = gap/2 修正） */
.case-marquee { overflow: hidden; }
.case-track { display: flex; gap: 16px; width: max-content; animation: case-scroll 42s linear infinite; }
.case-marquee:hover .case-track { animation-play-state: paused; }
.case-card { width: 380px; flex-shrink: 0; }
@keyframes case-scroll { to { transform: translateX(calc(-50% - 8px)); } }
@media (prefers-reduced-motion: reduce) {
  .case-track { animation: none; overflow-x: auto; width: auto; }
}

/* 关于页二维码 */
.about-qr { display: flex; align-items: center; gap: 18px; margin-top: 20px; }
.about-qr img { width: 150px; height: 150px; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 6px; }
.about-qr p { margin: 0; color: var(--muted); font-size: 0.95rem; }

/* 关于页地图（z-index:0 建 stacking context，防 Leaflet 层叠到吸顶导航之上） */
#map { position: relative; z-index: 0; height: 340px; margin-top: 18px; border: 1px solid var(--line); border-radius: 10px; }
.map-actions { margin-top: 12px; }
.map-actions .btn-dark { background: #fff; }

.btn { display: inline-block; padding: 11px 22px; border-radius: 6px; text-decoration: none; font-size: 1rem; border: 1px solid transparent; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: #a63708; }
.btn-ghost { border-color: rgba(255,255,255,.6); color: #fff; }
.btn-ghost.btn-dark { border-color: var(--brand); color: var(--brand); }
.btn-lg { font-size: 1.15rem; padding: 14px 30px; }
.card-title { font-size: 1.02rem; margin: 10px 0 6px; font-weight: 600; }

/* 页脚品牌主张带（全站每页页脚一部分，单行大字，Noto Sans SC Black OFL 子集 3.6KB 自托管） */
@font-face {
  font-family: 'Noto Sans SC Black';
  src: url('../fonts/notosanssc-black-subset.woff2') format('woff2');
  font-weight: 900;
  font-display: swap;
}
.tagline-band { background: var(--brand-dark); padding: 54px 20px 46px; text-align: center; }
.tagline-big { margin: 0; font-family: 'Noto Sans SC Black', -apple-system, 'PingFang SC', 'Microsoft YaHei', sans-serif; font-weight: 900; line-height: 1.2; white-space: nowrap; }
.tagline-big span { font-size: clamp(1.3rem, 6.8vw, 5.2rem); color: #fff; letter-spacing: .02em; }
.tagline-big em { font-style: normal; color: #f97316; }

.btn { display: inline-block; padding: 11px 22px; border-radius: 6px; text-decoration: none; font-size: 1rem; border: 1px solid transparent; }
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.card { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 18px; }
.card p { margin: 0; color: var(--muted); }
.card h3 { color: var(--ink); }
.more-link { margin-top: 22px; }
.door-card { text-decoration: none; padding: 14px; transition: box-shadow .15s ease, transform .15s ease; }
.door-card:hover { box-shadow: 0 6px 18px rgba(18,67,107,.12); transform: translateY(-2px); }
.door-card img { width: 100%; height: 260px; object-fit: contain; background: #fff; border-radius: 6px; transition: transform .3s ease; }
.door-card:hover img { transform: scale(1.03); }
.door-card .meta { font-size: 0.85rem; }
/* 优势序号卡（描边数字，橙/蓝交替） */
.adv-card { display: flex; gap: 14px; align-items: flex-start; }
.adv-num { font-family: 'Noto Sans SC Black', -apple-system, 'PingFang SC', sans-serif; font-weight: 900; font-size: 2rem; line-height: 1.1; color: transparent; -webkit-text-stroke: 1.5px var(--accent); }
@supports not (-webkit-text-stroke: 1px #000) { .adv-num { color: var(--accent); } }
.adv-card:nth-child(even) .adv-num { -webkit-text-stroke-color: var(--brand); }
@supports not (-webkit-text-stroke: 1px #000) { .adv-card:nth-child(even) .adv-num { color: var(--brand); } }
.adv-body h3 { margin: 0 0 6px; }
.adv-body p { margin: 0; }
/* 工厂实力三入口 */
.factory-entry { text-decoration: none; overflow: hidden; padding: 0 0 14px; }
.factory-entry img { width: 100%; height: 210px; object-fit: cover; display: block; border-radius: 9px 9px 0 0; transition: transform .35s ease; }
.factory-entry:hover { box-shadow: 0 6px 18px rgba(18,67,107,.12); transform: translateY(-2px); }
.factory-entry:hover img { transform: scale(1.04); }
.factory-entry h3 { margin: 12px 14px 4px; }
.factory-entry p { margin: 0 14px; font-size: 0.9rem; }
/* 工厂图集（瀑布流） */
.gallery { columns: 3; column-gap: 16px; }
.g-group-title { margin: 60px 0 20px; }
.g-group-title:first-of-type { margin-top: 10px; }
.g-item { break-inside: avoid; margin: 0 0 16px; position: relative; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); }
.g-item img { width: 100%; display: block; transition: transform .35s ease; }
.g-item:hover img { transform: scale(1.05); }
.g-item figcaption { position: absolute; right: 0; bottom: 0; left: 0; padding: 30px 12px 9px; background: linear-gradient(transparent, rgba(8,24,40,.75)); color: #fff; font-size: 0.85rem; }

/* 详情页图片看大图浮层 */
.zoomable { cursor: zoom-in; }
.lightbox { position: fixed; inset: 0; z-index: 50; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 24px; background: rgba(12,30,48,.86); opacity: 0; visibility: hidden; transition: opacity .2s ease, visibility .2s ease; }
.lightbox.open { opacity: 1; visibility: visible; }
.lightbox img { max-width: min(1100px, 94vw); max-height: 84vh; width: auto; height: auto; background: #fff; border-radius: 8px; box-shadow: 0 12px 40px rgba(0,0,0,.4); }
.lb-cap { color: #d7e2ec; font-size: .92rem; margin: 0; text-align: center; }
.lb-close { position: absolute; top: 10px; right: 12px; width: 44px; height: 44px; border: none; border-radius: 50%; background: rgba(255,255,255,.14); color: #fff; font-size: 1.5rem; cursor: pointer; }
.lb-close:hover { background: rgba(255,255,255,.28); }

/* 主图放大镜（仅精确指针设备启用，JS 动态包一层） */
.magnify { position: relative; overflow: hidden; cursor: zoom-in; background: #fff; border: 1px solid var(--line); border-radius: 10px; }
.magnify .door-main { border: none; border-radius: 0; transition: transform .15s ease; will-change: transform; }
@media (prefers-reduced-motion: reduce) {
  .magnify .door-main { transition: none; }
}

/* 门型详情 */
.crumb { font-size: 0.88rem; color: var(--muted); }
.crumb a { text-decoration: none; }
.door-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; margin-top: 20px; margin-bottom: 32px; }
.door-main { width: 100%; max-height: 560px; object-fit: contain; background: #fff; border: 1px solid var(--line); border-radius: 10px; }
.door-media { position: relative; }
.door-media figure { margin: 18px 0 0; }
.door-media figure img { width: 100%; height: auto; border: 1px solid var(--line); border-radius: 10px; }
.door-media figcaption { font-size: 0.82rem; color: var(--muted); margin-top: 6px; }
.door-spec table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); }
.door-spec th, .door-spec td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; font-size: 0.95rem; }
.door-spec th { width: 9.5em; background: #f0f3f7; color: var(--muted); font-weight: 600; white-space: nowrap; }
.door-spec tr:last-child th, .door-spec tr:last-child td { border-bottom: none; }
.cert-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 420px)); gap: 20px; }
.cert-grid img { width: 100%; height: auto; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.cert-grid figcaption { font-size: 0.85rem; color: var(--muted); margin-top: 8px; }
.door-pager { display: flex; justify-content: space-between; gap: 12px; margin-top: 26px; flex-wrap: wrap; }
.door-pager a { text-decoration: none; }

/* 专题 */
.guide-list { display: grid; gap: 14px; }
.guide-card { text-decoration: none; }
.guide-card p { font-size: 0.92rem; }
.guide-card h2 { font-size: 1.08rem; margin-bottom: 6px; }
.guide-upcoming { border-style: dashed; color: var(--muted); }
.guide-upcoming h2 { color: var(--muted); }
.upcoming-note { color: var(--muted); margin-bottom: 14px; }
.guide-detail { max-width: 820px; }
.guide-detail h2 { margin-top: 32px; }
.guide-detail figure.g-fig { margin: 22px 0; }
.guide-detail .g-fig img { width: 100%; border: 1px solid var(--line); border-radius: 10px; }
.guide-detail .g-fig figcaption { font-size: 0.85rem; color: var(--muted); margin-top: 8px; }
.guide-detail table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; margin: 18px 0; font-size: 0.95rem; }
.guide-detail th, .guide-detail td { text-align: left; padding: 9px 14px; border-bottom: 1px solid var(--line); }
.guide-detail th { background: #f0f3f7; }
.guide-cta { margin-top: 36px; display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.guide-cta p { margin: 0; }

@media (max-width: 720px) {
  .grid-2, .grid-3, .door-grid, .cert-grid { grid-template-columns: 1fr; }
  .gallery { columns: 2; }
  .stats { grid-template-columns: repeat(2, 1fr); padding: 26px 20px; }
  .stat-num { font-size: 1.7rem; }
  .case-card { width: 300px; }
  /* 卡片图改全宽自适应高度：竖版门照片铺满卡片，消除 contain 白边 */
  .door-card img { height: auto; object-fit: fill; }
  .hero { padding: 60px 0; }
  .hero h1 { font-size: 1.55rem; }
}
/* 窄屏页头：品牌 + 汉堡按钮，右侧滑出抽屉（不全屏，遮罩点击关闭） */
@media (max-width: 640px) {
  .header-inner { height: 62px; gap: 0; padding: 0 20px; }
  .brand { font-size: 1.2rem; letter-spacing: 3px; gap: 8px; }
  .brand-logo { height: 38px; }
  .nav-toggle { display: flex; position: relative; z-index: 26; flex-direction: column; justify-content: center; align-items: center; gap: 5px; width: 44px; height: 44px; margin-left: auto; background: none; border: none; cursor: pointer; padding: 0; }
  .nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); transition: transform .25s ease, opacity .2s ease; }
  body.nav-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  body.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  body.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .nav-backdrop { display: block; position: fixed; inset: 0; z-index: 24; background: rgba(8,20,34,.55); opacity: 0; visibility: hidden; transition: opacity .3s ease, visibility .3s ease; }
  body.nav-open .nav-backdrop { opacity: 1; visibility: visible; }
  .nav { position: fixed; top: 0; right: 0; bottom: 0; z-index: 25; margin: 0; width: min(45%, 240px); flex-direction: column; align-items: flex-start; gap: 4px; padding: 84px 24px; background: var(--brand-dark); box-shadow: -8px 0 28px rgba(8,20,34,.35); transform: translateX(100%); transition: transform .3s ease; }
  body.nav-open .nav { transform: none; }
  body.nav-open .nav-toggle span { background: #fff; }
  .nav .home-link { display: block; }
  .nav a { color: #fff; font-size: 1.3rem; letter-spacing: 2px; padding: 15px 4px; width: 100%; border-radius: 0; border-bottom: 1px solid rgba(255,255,255,.1); }
  .nav a:hover { background: none; }
  .nav a:hover, .nav a.active { color: #f97316; }
  .nav a.active { background: none; }
}
