/* ==========================================================================
   Website refactoring design system
   B2B engineering style: strong typography, calm palette, dense but readable.
   Overrides come from /assets/css/tokens.css which the builder writes from
   content/site.json -> tokens.
   ========================================================================== */

@import url("tokens.css");

:root {
  --ink: #16202b;
  --ink-soft: #3d4a58;
  --line: #e2e7ec;
  --bg: #ffffff;
  --bg-soft: #f5f7f9;
  --accent: #0f6ab4;
  --accent-dark: #0b4f87;
  --accent-ink: #ffffff;
  --radius: 10px;
  --maxw: 1200px;
  --shadow: 0 1px 2px rgba(16, 32, 48, .06), 0 8px 24px rgba(16, 32, 48, .06);
  --font: "Segoe UI", "Microsoft YaHei", -apple-system, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 { color: var(--ink); line-height: 1.25; margin: 0 0 .6em; font-weight: 700; }
h1 { font-size: clamp(28px, 3.4vw, 44px); }
h2 { font-size: clamp(22px, 2.4vw, 30px); margin-top: 1.6em; }
h3 { font-size: clamp(17px, 1.6vw, 20px); margin-top: 1.2em; }
p { margin: 0 0 1em; }
.lead { font-size: 17.5px; color: var(--ink-soft); max-width: 68ch; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; background: #fff; padding: 8px 14px; z-index: 60; }

/* buttons ---------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 0 22px; border: 1px solid var(--accent);
  border-radius: var(--radius); background: var(--accent); color: var(--accent-ink);
  font-weight: 600; font-size: 15.5px; cursor: pointer; transition: .18s ease;
}
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); text-decoration: none; transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--ink); border-color: rgba(22, 32, 43, .28); }
.btn-ghost:hover { background: rgba(255, 255, 255, .12); color: var(--ink); }
.hero .btn-ghost, .cta .btn-ghost { color: #fff; border-color: rgba(255, 255, 255, .6); }
.hero .btn-ghost:hover, .cta .btn-ghost:hover { background: rgba(255, 255, 255, .16); color: #fff; }

/* header ----------------------------------------------------------------- */
.topbar { background: var(--ink); color: #cbd5df; font-size: 13.5px; }
.topbar .wrap { display: flex; gap: 18px; justify-content: flex-end; min-height: 38px; align-items: center; flex-wrap: wrap; }
.topbar a { color: #e6edf4; display: inline-flex; align-items: center; min-height: 26px; }

.site-header { position: sticky; top: 0; z-index: 40; background: rgba(255, 255, 255, .96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; gap: 18px; min-height: 74px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); font-weight: 700; }
.brand img { height: 42px; width: auto; }
.brand span { font-size: 13.5px; color: var(--ink-soft); font-weight: 500; max-width: 220px; }
.main-nav { margin-left: auto; }
.nav-list { list-style: none; display: flex; gap: 4px; margin: 0; padding: 0; }
.nav-list > li { position: relative; }
.nav-list > li > a { display: block; padding: 12px 13px; color: var(--ink); font-weight: 600; font-size: 15px; border-radius: 8px; }
.nav-list > li > a:hover { background: var(--bg-soft); text-decoration: none; }
.nav-list > li.is-active > a { color: var(--accent); }
.sub { list-style: none; margin: 0; padding: 8px; position: absolute; left: 0; top: 100%; min-width: 240px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
  display: none; z-index: 50; }
.nav-list > li.has-sub:hover > .sub, .nav-list > li.has-sub:focus-within > .sub { display: block; }
.sub a { display: block; padding: 9px 12px; border-radius: 8px; color: var(--ink); font-size: 14.5px; }
.sub a:hover { background: var(--bg-soft); text-decoration: none; }
.sub-toggle { display: none; }
.nav-toggle { display: none; margin-left: auto; background: none; border: 1px solid var(--line); border-radius: 8px;
  width: 44px; height: 44px; font-size: 20px; cursor: pointer; }
.btn-quote { margin-left: 8px; }

/* inline search: only an icon until focused, then it covers the header row */
.site-search { margin-left: 6px; position: relative; }
.site-search input {
  width: 42px; height: 42px; padding: 0 0 0 38px; border: 1px solid var(--line); border-radius: 8px;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233d4a58' stroke-width='2'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-3.5-3.5'/%3E%3C/svg%3E") no-repeat 11px center / 18px 18px;
  font-size: 15px; color: var(--ink); cursor: pointer; transition: width .2s ease;
}
.site-search input:focus { width: 260px; cursor: text; outline: 2px solid rgba(15, 106, 180, .25); }
.search-results {
  position: absolute; right: 0; top: calc(100% + 8px); width: 320px; max-height: 60vh; overflow-y: auto;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 8px;
}
.search-results a { display: block; padding: 9px 12px; border-radius: 8px; color: var(--ink); font-size: 14.5px; }
.search-results a:hover { background: var(--bg-soft); text-decoration: none; }
.search-empty { padding: 8px 12px; margin: 0; color: var(--ink-soft); font-size: 14px; }

.scroll-progress { position: fixed; left: 0; top: 0; height: 3px; width: 0; background: var(--accent); z-index: 70; }

/* hero ------------------------------------------------------------------- */
.hero { position: relative; color: #fff; background: #16202b; }
.hero-inner { padding: 92px 22px 84px; max-width: var(--maxw); }
.hero h1 { color: #fff; max-width: 22ch; }
.hero .lead { color: rgba(255, 255, 255, .9); }
.hero h1, .hero .lead { text-shadow: 0 1px 12px rgba(0, 0, 0, .45); }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: 12.5px; font-weight: 700; color: #8fc4ef; margin-bottom: 12px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }
.hero-facts { list-style: none; display: flex; flex-wrap: wrap; gap: 30px; margin: 30px 0 0; padding: 22px 0 0; border-top: 1px solid rgba(255, 255, 255, .22); }
.hero-facts strong { display: block; font-size: 26px; line-height: 1.1; }
.hero-facts span { font-size: 13.5px; color: rgba(255, 255, 255, .78); }

.page-head { background: var(--bg-soft); border-bottom: 1px solid var(--line); }
.page-head h1 { color: var(--ink); }
.page-head .wrap { padding: 54px 22px 42px; }

/* sections and blocks ---------------------------------------------------- */
.section { padding: 54px 0; border-bottom: 1px solid var(--line); }
.section:nth-of-type(even) { background: var(--bg-soft); }
.content { max-width: 900px; }
.content h2, .section h2 { margin-top: 0; }

ul.blocks, ol.blocks { padding-left: 22px; margin: 0 0 1.2em; }
ul.blocks li, ol.blocks li { margin-bottom: 7px; }

ul.checklist { list-style: none; padding: 0; margin: 0 0 1.2em; }
ul.checklist li { position: relative; padding-left: 30px; margin-bottom: 10px; }
ul.checklist .tick { position: absolute; left: 0; top: 6px; width: 16px; height: 16px; border-radius: 4px;
  background: var(--accent); }
ul.checklist .tick::after { content: ""; position: absolute; left: 5px; top: 2px; width: 5px; height: 9px;
  border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }

.table-wrap { overflow-x: auto; margin: 0 0 1.4em; }
table { width: 100%; border-collapse: collapse; font-size: 15px; background: #fff; }
table caption { caption-side: top; text-align: left; font-weight: 700; padding: 0 0 10px; color: var(--ink); }
th, td { border: 1px solid var(--line); padding: 11px 14px; text-align: left; vertical-align: middle; }
thead th { background: var(--ink); color: #fff; font-weight: 600; }
tbody tr:nth-child(even) { background: #fafbfc; }
table.specs th[scope="row"] { width: 34%; background: var(--bg-soft); font-weight: 600; }

.grid { display: grid; gap: 22px; }
.grid.cards { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.card { display: block; color: inherit; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; background: #fff; transition: .18s ease; }
.card:hover { text-decoration: none; transform: translateY(-3px); box-shadow: var(--shadow); }
.card img { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; }
.card-body { padding: 18px 20px 22px; }
.card h3 { margin: 0 0 8px; }
.card p { color: var(--ink-soft); font-size: 15px; margin-bottom: 10px; }
.card-meta { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.card-meta li { font-size: 12.5px; background: var(--bg-soft); border: 1px solid var(--line);
  border-radius: 999px; padding: 4px 10px; color: var(--ink-soft); }

ol.steps { list-style: none; counter-reset: step; padding: 0; margin: 0 0 1.4em; }
ol.steps li { counter-increment: step; position: relative; padding: 0 0 22px 62px; }
ol.steps li::before { content: counter(step, decimal-leading-zero); position: absolute; left: 0; top: 0;
  width: 42px; height: 42px; border-radius: 50%; background: var(--accent); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px; }
ol.steps li::after { content: ""; position: absolute; left: 20px; top: 46px; bottom: 4px; width: 2px; background: var(--line); }
ol.steps li:last-child::after { display: none; }
ol.steps h3 { margin: 6px 0 4px; }

.faq details { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; margin-bottom: 10px; }
.faq summary { cursor: pointer; padding: 15px 18px; font-weight: 600; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; float: right; color: var(--accent); font-weight: 700; }
.faq details[open] summary::after { content: "−"; }
.faq-a { padding: 0 18px 16px; color: var(--ink-soft); }

.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.gallery figure, figure.wide { margin: 0 0 1.2em; }
.gallery img { border-radius: var(--radius); aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
figcaption { font-size: 13.5px; color: var(--ink-soft); padding-top: 8px; }

.cta { display: flex; align-items: center; gap: 26px; flex-wrap: wrap; justify-content: space-between;
  background: var(--ink); color: #fff; border-radius: var(--radius); padding: 34px 36px; margin: 0 0 1.4em; }
.cta h2 { color: #fff; margin: 0 0 6px; }
.cta p { color: rgba(255, 255, 255, .82); margin: 0; }

blockquote { margin: 0 0 1.4em; padding: 18px 22px; border-left: 4px solid var(--accent); background: var(--bg-soft); }
blockquote cite { display: block; font-size: 13.5px; color: var(--ink-soft); font-style: normal; }
.note { background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; font-size: 15px; }

/* footer ----------------------------------------------------------------- */
.site-footer { background: #0f1720; color: #b9c5d1; padding: 58px 0 0; font-size: 15px; }
.foot-grid { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); gap: 34px; }
.site-footer h3 { color: #fff; font-size: 16px; margin-bottom: 12px; }
.site-footer a { color: #b9c5d1; }
.site-footer a:hover { color: #fff; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.foot-contact { font-size: 14px; line-height: 1.6; color: #93a2b1; }
.foot-base { display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap;
  border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 42px; padding: 20px 22px 26px; font-size: 13.5px; color: #8593a2; }

.wa-float { position: fixed; right: 20px; bottom: 26px; z-index: 45; background: #25d366; color: #08301a;
  font-weight: 700; padding: 12px 18px; border-radius: 999px; box-shadow: var(--shadow); }
.wa-float:hover { text-decoration: none; filter: brightness(1.05); }
.mobile-bar { display: none; }

/* responsive ------------------------------------------------------------- */
@media (max-width: 1080px) {
  .brand span { display: none; }
  .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .wrap { padding: 0 16px; }
  .header-inner { gap: 10px; }
  .nav-toggle { display: block; }
  .main-nav { position: fixed; inset: 0 auto 0 0; width: min(84vw, 340px); background: #fff;
    display: none; z-index: 60; padding: 74px 20px 30px; overflow-y: auto;
    box-shadow: 12px 0 40px rgba(16, 32, 48, .18); }
  .main-nav.is-open { display: block; }
  .site-footer li { margin-bottom: 4px; }
  .site-footer li a { display: inline-flex; align-items: center; min-height: 26px; }
  .foot-base span { display: inline-flex; align-items: center; min-height: 26px; }
  .nav-list { flex-direction: column; gap: 2px; }
  .nav-list > li > a { padding: 13px 6px; border-bottom: 1px solid var(--line); }
  .sub { position: static; display: none; border: none; box-shadow: none; padding: 4px 0 8px 14px; }
  .nav-list > li.has-sub.is-open > .sub { display: block; }
  .sub-toggle { display: block; position: absolute; right: 0; top: 6px; width: 40px; height: 40px;
    background: none; border: none; font-size: 18px; color: var(--accent); cursor: pointer; }
  .btn-quote { display: none; }
  .site-search { margin: 0 8px 0 auto; }
  .site-search input { width: 40px; }
  .site-search input:focus { width: 200px; }
  .hero-inner { padding: 66px 22px 60px; }
  .hero-facts { gap: 20px; }
  .hero-facts strong { font-size: 22px; }
  .section { padding: 42px 0; }
  .foot-grid { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .foot-grid > * { min-width: 0; }
  .topbar { font-size: 12.5px; }
  .topbar .wrap { gap: 12px; justify-content: center; min-height: 34px; }
  .foot-base { padding: 18px 16px 24px; }
  .wa-float { bottom: 78px; }
  .mobile-bar { display: grid; grid-template-columns: repeat(3, 1fr); position: fixed; left: 0; right: 0; bottom: 0;
    z-index: 46; background: #fff; border-top: 1px solid var(--line); }
  .mobile-bar a { display: flex; align-items: center; justify-content: center; min-height: 58px;
    font-weight: 600; color: var(--ink); border-right: 1px solid var(--line); font-size: 15px; }
  .mobile-bar a:last-child { border-right: none; }
  .mobile-bar a.strong { background: var(--accent); color: var(--accent-ink); }
  body { padding-bottom: 58px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}
