/* ============================================================
   Liaoning Dahua Energy (DHES) — Skeleton stylesheet
   Brand: red #C01818 · charcoal #2B2B2B · white
   ============================================================ */

:root {
  --red: #c01818;
  --red-dark: #9c1414;
  --ink: #2b2b2b;
  --ink-2: #4d4d4d;
  --muted: #777f86;
  --line: #e6e8ea;
  --bg: #ffffff;
  --bg-soft: #f5f6f7;
  --bg-dark: #1c1f22;
  --bg-dark-2: #14171a;
  --white: #ffffff;
  --radius: 10px;
  --radius-sm: 6px;
  --shadow: 0 6px 24px rgba(20, 23, 26, 0.08);
  --shadow-lg: 0 16px 48px rgba(20, 23, 26, 0.16);
  --maxw: 1200px;
  --header-h: 96px;
  --ease: cubic-bezier(.2,.7,.3,1);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-head: "Poppins", var(--font);
}

/* ---------- Reset ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--ink); line-height: 1.2; margin: 0 0 .5em; font-weight: 700; }
p { margin: 0 0 1em; }
ul { margin: 0; padding: 0; }

/* ---------- Layout helpers ---------- */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section { padding: 84px 0; }
.section--soft { background: var(--bg-soft); }
.section--dark { background: var(--bg-dark); color: #e7eaec; }
.section--dark h1, .section--dark h2, .section--dark h3 { color: #fff; }
.section-head { max-width: 720px; margin: 0 auto 48px; text-align: center; }
.eyebrow {
  display: inline-block; font-family: var(--font-head); font-weight: 600;
  letter-spacing: 3px; text-transform: uppercase; font-size: 13px;
  color: var(--red); margin-bottom: 12px;
}
.section-head h2 { font-size: clamp(26px, 4vw, 40px); }
.section-head p { color: var(--muted); font-size: 17px; margin: 0; }
.text-center { text-align: center; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-head); font-weight: 600; font-size: 15px;
  padding: 13px 26px; border-radius: var(--radius-sm); cursor: pointer;
  border: 2px solid transparent; transition: all .2s var(--ease);
}
.btn--primary { background: var(--red); color: #fff; }
.btn--primary:hover { background: var(--red-dark); transform: translateY(-2px); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--red); color: var(--red); }
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: var(--red); color: #fff; }
.btn--outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.4); }
.btn--outline-light:hover { background: #fff; color: var(--ink); }

/* ---------- Top utility bar ---------- */
.topbar {
  background: var(--bg-dark-2); color: #c8ced2; font-size: 13.5px;
}
.topbar .container { display: flex; align-items: center; justify-content: space-between; height: 40px; }
.topbar a { color: #c8ced2; transition: color .2s; }
.topbar a:hover { color: #fff; }
.topbar__left { display: flex; gap: 22px; align-items: center; }
.topbar__right { display: flex; gap: 18px; align-items: center; }
.topbar__item { display: inline-flex; align-items: center; gap: 6px; }
.lang-switch { display: inline-flex; gap: 8px; align-items: center; }
.lang-switch a.active { color: #fff; font-weight: 600; }

/* ---------- Header ---------- */
.header {
  position: sticky; top: 0; z-index: 50; background: #fff;
  border-bottom: 1px solid var(--line);
}
.header .container { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.brand img { height: 46px; width: auto; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav > li { position: relative; list-style: none; }
.nav > li > a {
  display: flex; align-items: center; gap: 5px; padding: 0 16px; height: var(--header-h);
  font-family: var(--font-head); font-weight: 600; font-size: 15px; color: var(--ink);
  border-bottom: 3px solid transparent; transition: color .2s;
}
.nav > li > a:hover, .nav > li.active > a { color: var(--red); border-bottom-color: var(--red); }
.nav .caret { width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg) translateY(-2px); opacity: .6; }

/* dropdown */
.dropdown {
  position: absolute; top: 100%; left: 0; min-width: 240px; background: #fff;
  box-shadow: var(--shadow); border-radius: 0 0 var(--radius) var(--radius);
  border-top: 3px solid var(--red); padding: 8px 0;
  opacity: 0; visibility: hidden; transform: translateY(8px); transition: all .2s var(--ease);
}
.nav > li:hover .dropdown { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown li { list-style: none; }
.dropdown a { display: block; padding: 10px 20px; font-size: 14.5px; color: var(--ink-2); }
.dropdown a:hover { background: var(--bg-soft); color: var(--red); }

.header__actions { display: flex; align-items: center; gap: 14px; }
.header__cta { display: inline-flex; }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px 0; transition: .3s; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 86vh; display: flex; align-items: center;
  color: #fff; overflow: hidden;
  background: linear-gradient(120deg, #14171a 0%, #20262b 55%, #2b1416 100%);
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(900px 500px at 80% 15%, rgba(192,24,24,.28), transparent 60%),
    repeating-linear-gradient(135deg, rgba(255,255,255,.03) 0 2px, transparent 2px 26px);
  pointer-events: none;
}
.hero__inner { position: relative; z-index: 2; max-width: 720px; padding: 60px 0; }
.hero h1 { color: #fff; font-size: clamp(34px, 6vw, 62px); letter-spacing: .5px; margin-bottom: 18px; }
.hero h1 .accent { color: #ff5a5a; }
.hero p { font-size: clamp(16px, 2.2vw, 20px); color: #cfd5d9; max-width: 560px; margin-bottom: 32px; }
.hero__actions { display: flex; gap: 14px; flex-wrap: wrap; }
.scroll-cue { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); z-index: 2;
  font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: #aab2b8; text-align: center; }
.scroll-cue::after { content: ""; display: block; width: 1px; height: 34px; background: linear-gradient(#aab2b8, transparent); margin: 10px auto 0; }

/* ---------- Stat strip ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.stat { text-align: center; padding: 8px; }
.stat__num { font-family: var(--font-head); font-weight: 700; font-size: clamp(30px, 4vw, 46px); color: var(--red); line-height: 1; }
.stat__label { color: var(--muted); font-size: 15px; margin-top: 8px; }

/* ---------- Product / card grids ---------- */
.grid { display: grid; gap: 26px; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: transform .25s var(--ease), box-shadow .25s var(--ease);
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.card__media {
  aspect-ratio: 4 / 3; background: var(--ph, linear-gradient(135deg, #d9dde0, #eef1f3));
  position: relative; display: flex; align-items: center; justify-content: center;
  color: #9aa3a9; font-size: 13px; letter-spacing: 1px;
}
.card__media .tag {
  position: absolute; top: 12px; left: 12px; background: var(--red); color: #fff;
  font-size: 11px; font-weight: 600; letter-spacing: .5px; padding: 4px 10px; border-radius: 100px;
}
.card__body { padding: 22px; flex: 1; display: flex; flex-direction: column; }
.card__body h3 { font-size: 18px; margin-bottom: 8px; }
.card__body p { color: var(--muted); font-size: 14.5px; margin-bottom: 16px; }
.card__link { margin-top: auto; font-family: var(--font-head); font-weight: 600; font-size: 14px; color: var(--red); display: inline-flex; align-items: center; gap: 6px; }
.card__link::after { content: "→"; transition: transform .2s; }
.card:hover .card__link::after { transform: translateX(4px); }

/* media placeholder variations */
.ph-1 { --ph: linear-gradient(135deg,#3a4750,#5d6b75); }
.ph-2 { --ph: linear-gradient(135deg,#7a2326,#b13a3a); }
.ph-3 { --ph: linear-gradient(135deg,#2f3a42,#465058); }
.ph-4 { --ph: linear-gradient(135deg,#4a3033,#7a4a4d); }
.ph-5 { --ph: linear-gradient(135deg,#36424a,#586772); }
.ph-6 { --ph: linear-gradient(135deg,#5a2326,#8a3a3d); }

/* ---------- Filter bar ---------- */
.filterbar { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 40px; }
.filterbar button {
  font-family: var(--font-head); font-weight: 600; font-size: 14px; padding: 9px 20px;
  border-radius: 100px; border: 1px solid var(--line); background: #fff; color: var(--ink-2); cursor: pointer;
  transition: all .2s;
}
.filterbar button:hover { border-color: var(--red); color: var(--red); }
.filterbar button.active { background: var(--red); border-color: var(--red); color: #fff; }

/* ---------- Split feature ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split__media { aspect-ratio: 5/4; border-radius: var(--radius); background: linear-gradient(135deg,#2f3a42,#566571); box-shadow: var(--shadow); position: relative; }
.split__media .badge { position: absolute; bottom: -22px; left: -22px; background: var(--red); color: #fff; padding: 18px 24px; border-radius: var(--radius); font-family: var(--font-head); }
.split__media .badge b { display: block; font-size: 28px; line-height: 1; }
.split h2 { font-size: clamp(24px, 3.5vw, 36px); }
.feature-list { list-style: none; margin: 22px 0 28px; }
.feature-list li { position: relative; padding: 8px 0 8px 32px; color: var(--ink-2); }
.feature-list li::before { content: "✓"; position: absolute; left: 0; top: 8px; width: 20px; height: 20px; background: rgba(192,24,24,.1); color: var(--red); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }

/* ---------- Blog ---------- */
.post-card .card__media { aspect-ratio: 16/10; }
.post-card .meta { font-size: 13px; color: var(--muted); margin-bottom: 8px; display: flex; gap: 10px; }
.post-card .meta .cat { color: var(--red); font-weight: 600; }

/* ---------- CTA band ---------- */
.cta-band { background: linear-gradient(120deg, var(--red), var(--red-dark)); color: #fff; text-align: center; }
.cta-band h2 { color: #fff; font-size: clamp(26px, 4vw, 40px); }
.cta-band p { color: #ffd9d9; max-width: 560px; margin: 0 auto 28px; }

/* ---------- Page hero (sub pages) ---------- */
.page-hero {
  background: linear-gradient(120deg, #14171a, #262d33); color: #fff; padding: 70px 0;
  position: relative; overflow: hidden;
}
.page-hero::after { content: ""; position: absolute; inset: 0; background: radial-gradient(600px 300px at 85% 20%, rgba(192,24,24,.28), transparent 60%); }
.page-hero .container { position: relative; z-index: 2; }
.page-hero h1 { color: #fff; font-size: clamp(28px, 5vw, 46px); margin-bottom: 8px; }
.breadcrumb { font-size: 14px; color: #aab2b8; }
.breadcrumb a:hover { color: #fff; }

/* ---------- Forms ---------- */
.form { display: grid; gap: 18px; }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; font-family: var(--font-head); }
.field input, .field select, .field textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  font-family: var(--font); font-size: 15px; color: var(--ink); background: #fff; transition: border-color .2s;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--red); }
.field textarea { min-height: 130px; resize: vertical; }

/* ---------- Product detail ---------- */
.pd { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: start; }
.pd__gallery .main { aspect-ratio: 4/3; border-radius: var(--radius); background: linear-gradient(135deg,#3a4750,#5d6b75); }
.pd__thumbs { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; margin-top: 12px; }
.pd__thumbs div { aspect-ratio: 1; border-radius: var(--radius-sm); background: linear-gradient(135deg,#d9dde0,#eef1f3); cursor: pointer; }
.spec-table { width: 100%; border-collapse: collapse; margin: 18px 0 26px; }
.spec-table th, .spec-table td { text-align: left; padding: 11px 14px; border: 1px solid var(--line); font-size: 14.5px; }
.spec-table th { background: var(--bg-soft); width: 40%; font-family: var(--font-head); font-weight: 600; }

/* ---------- Footer ---------- */
.footer { background: var(--bg-dark); color: #aeb6bc; padding: 64px 0 0; font-size: 14.5px; }
.footer a { color: #aeb6bc; transition: color .2s; }
.footer a:hover { color: #fff; }
.footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 48px; }
.footer__brand img { height: 40px; margin-bottom: 18px; filter: brightness(0) invert(1); opacity: .92; }
.footer h4 { color: #fff; font-size: 15px; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 18px; }
.footer ul li { list-style: none; margin-bottom: 10px; }
.footer .contact-line { display: flex; gap: 10px; margin-bottom: 12px; }
.footer .contact-line .ic { color: var(--red); flex: 0 0 auto; }
.socials { display: flex; gap: 12px; margin-top: 16px; }
.socials a { width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,.08); display: flex; align-items: center; justify-content: center; }
.socials a:hover { background: var(--red); color: #fff; }
.footer__bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 20px 0; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 13px; color: #828b91; }

/* ---------- Floating contact ---------- */
.floaters { position: fixed; right: 18px; bottom: 22px; z-index: 60; display: flex; flex-direction: column; gap: 12px; }
.floaters a, .floaters button {
  width: 52px; height: 52px; border-radius: 50%; border: 0; cursor: pointer;
  display: flex; align-items: center; justify-content: center; color: #fff;
  box-shadow: var(--shadow-lg); transition: transform .2s;
}
.floaters a:hover, .floaters button:hover { transform: scale(1.08); }
.float-wa { background: #25d366; }
.float-wc { background: #07c160; }
.float-top { background: var(--ink); }
.floaters svg { width: 26px; height: 26px; }

/* wechat popover */
.wc-pop {
  position: fixed; right: 84px; bottom: 86px; z-index: 60; background: #fff; color: var(--ink);
  border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 16px; width: 200px; text-align: center;
  display: none;
}
.wc-pop.show { display: block; }
.wc-pop .qr { width: 160px; height: 160px; margin: 0 auto 10px; background: repeating-conic-gradient(#222 0 25%, #fff 0 50%) 50%/16px 16px; border-radius: 8px; }
.wc-pop small { color: var(--muted); }

/* ---------- Cookie banner ---------- */
.cookie {
  position: fixed; left: 18px; right: 18px; bottom: 18px; z-index: 70; max-width: 560px;
  background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-lg);
  border-radius: var(--radius); padding: 18px 20px; display: none; gap: 14px; align-items: center; justify-content: space-between; flex-wrap: wrap;
}
.cookie.show { display: flex; }
.cookie p { margin: 0; font-size: 13.5px; color: var(--ink-2); flex: 1 1 280px; }
.cookie .actions { display: flex; gap: 10px; }

/* ---------- Utilities ---------- */
.hide { display: none !important; }
.mt-0 { margin-top: 0; }
.muted { color: var(--muted); }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 980px) {
  :root { --header-h: 72px; }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .split, .pd { grid-template-columns: 1fr; gap: 32px; }
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .topbar__left .hide-sm { display: none; }

  .nav-toggle { display: block; }
  .header__cta { display: none; }
  .nav {
    position: fixed; top: var(--header-h); right: 0; height: calc(100vh - var(--header-h));
    width: 290px; max-width: 84vw; background: #fff; flex-direction: column; align-items: stretch;
    padding: 12px 0; box-shadow: var(--shadow-lg); transform: translateX(100%); transition: transform .3s var(--ease);
    overflow-y: auto; gap: 0;
  }
  .nav.open { transform: translateX(0); }
  .nav > li > a { height: auto; padding: 14px 24px; border-bottom: 1px solid var(--line); }
  .nav > li > a:hover, .nav > li.active > a { border-bottom-color: var(--line); }
  .dropdown { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border-top: 0; padding: 0 0 8px; background: var(--bg-soft); display: none; }
  .nav > li.open-sub .dropdown { display: block; }
}
@media (max-width: 620px) {
  .section { padding: 56px 0; }
  .stats { grid-template-columns: repeat(2, 1fr); gap: 18px; }
  .grid--4, .grid--3, .grid--2 { grid-template-columns: 1fr; }
  .form .row { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .topbar__left { gap: 14px; }
  .topbar__item.hide-xs { display: none; }
}
