/* ============================================================
   XONWARE REDESIGN v1.0 — 2026-10-16
   Product-led light design system (per approved sample).
   Loads AFTER legacy sheets; restyles header/footer and powers
   the rebuilt homepage (xh-* components). Other pages untouched
   except header/footer chrome.
   ============================================================ */

:root {
  --x-ink: #0E1C30;
  --x-body: #46556C;
  --x-faint: #7A8AA3;
  --x-paper: #FFFFFF;
  --x-mist: #F3F6FA;
  --x-line: #E3EAF3;
  --x-blue: #2456E6;
  --x-blue-deep: #1B41B8;
  --x-navy: #0D2B55;
  --x-navy-2: #0A2244;
  --x-green: #9BDB3C;
  --x-green-ink: #5B8A1E;
  --x-radius: 14px;
  --x-radius-sm: 10px;
  --x-shadow: 0 1px 2px rgba(14,28,48,.05), 0 12px 32px -12px rgba(14,28,48,.12);
  --x-font: "Geist", Inter, ui-sans-serif, system-ui, sans-serif;
  --x-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* ---------- Base chrome (safe on prod, needed for preview) ---------- */
body { margin: 0; font-family: var(--x-font); }
img { max-width: 100%; height: auto; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.site-footer .footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 48px; padding: 72px 0 48px; }
.site-footer .footer__col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.site-footer .footer__bottom { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 22px 0; font-size: 13px; flex-wrap: wrap; }
.site-footer .footer__social { display: flex; gap: 16px; }
.site-footer { --leaf-400: var(--x-green); }
@media (max-width: 980px) { .site-footer .footer__grid { grid-template-columns: 1fr 1fr; gap: 32px; padding: 48px 0 32px; } }

/* ---------- Header / nav (shared chrome) ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255,255,255,.92);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--x-line);
  box-shadow: none;
}
.site-header .site-header__inner { display: flex; align-items: center; gap: 28px; min-height: 68px; }
.site-header .brand__logo { height: 34px; width: auto; }
.site-header .nav__item {
  font-family: var(--x-font); font-size: 14px; font-weight: 500;
  color: var(--x-body); text-decoration: none; padding: 8px 2px;
  border-bottom: 2px solid transparent; transition: color .15s ease;
}
.site-header .nav__item:hover { color: var(--x-ink); }
.site-header .nav__item.is-current, .site-header .nav__item.active { color: var(--x-ink); border-bottom-color: var(--x-blue); }
.site-header .nav__contact { color: var(--x-faint); }
.site-header .btn.nav__cta,
.btn--primary {
  background: var(--x-blue); color: #fff; border: 0;
  border-radius: 999px; font-weight: 600;
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 18px; font-size: 13.5px; text-decoration: none;
}
.site-header .btn.nav__cta:hover, .btn--primary:hover { background: var(--x-blue-deep); color: #fff; }

/* ---------- Footer (shared chrome) ---------- */
.site-footer { background: var(--x-navy-2); color: rgba(255,255,255,.78); }
.site-footer .footer__brand-name { color: #fff; font-weight: 700; letter-spacing: -.01em; font-size: 20px; text-decoration: none; }
.site-footer h6 { color: rgba(255,255,255,.95); font-size: 13px; font-weight: 600; margin-bottom: 14px; }
.site-footer .footer__col a { color: rgba(255,255,255,.62); font-size: 13.5px; text-decoration: none; }
.site-footer .footer__col a:hover { color: var(--x-green); }
.site-footer .btn--leaf { background: var(--x-green); color: var(--x-navy-2); border-radius: 999px; font-weight: 600; border: 0; }
.site-footer .btn--leaf:hover { filter: brightness(1.06); }
.site-footer .footer__bottom { border-top: 1px solid rgba(255,255,255,.12); }
.site-footer .footer__social a { color: rgba(255,255,255,.55); }
.site-footer .footer__social a:hover { color: var(--x-green); }

/* ============================================================
   HOMEPAGE COMPONENTS (xh-*) — used only by pages/home.php
   ============================================================ */

html[data-page="home"] body { background: var(--x-paper); color: var(--x-ink); font-family: var(--x-font); }

.xh-wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* Section scaffolding: numbered rail eyebrow (content is a numbered tour). */
.xh-sec { padding: 96px 0; }
.xh-sec--mist { background: var(--x-mist); }
.xh-sec--navy { background: var(--x-navy); color: #fff; }
.xh-sechead { display: grid; grid-template-columns: 120px 1fr auto; gap: 24px; align-items: start; margin-bottom: 56px; }
.xh-kicker { font-family: var(--x-mono); font-size: 12px; color: var(--x-faint); line-height: 1.5; padding-top: 10px; }
.xh-sec--navy .xh-kicker { color: rgba(255,255,255,.55); }
.xh-h2 { font-size: clamp(28px, 3.4vw, 40px); font-weight: 650; letter-spacing: -.02em; line-height: 1.12; margin: 0; }
.xh-sechead__aside { max-width: 320px; color: var(--x-body); font-size: 15px; line-height: 1.55; padding-top: 8px; }
.xh-sec--navy .xh-sechead__aside { color: rgba(255,255,255,.7); }

.xh-btn {
  display: inline-flex; align-items: center; gap: 8px;
  border-radius: 999px; padding: 12px 22px; font-size: 15px; font-weight: 600;
  text-decoration: none; transition: background .15s ease, border-color .15s ease;
}
.xh-btn--blue { background: var(--x-blue); color: #fff; }
.xh-btn--blue:hover { background: var(--x-blue-deep); }
.xh-btn--line { border: 1px solid var(--x-line); color: var(--x-ink); background: #fff; }
.xh-btn--line:hover { border-color: var(--x-faint); }
.xh-btn--green { background: var(--x-green); color: var(--x-navy-2); }
.xh-btn--green:hover { filter: brightness(1.06); }

.xh-link { color: var(--x-blue); font-weight: 600; font-size: 14.5px; text-decoration: none; }
.xh-link:hover { text-decoration: underline; }

/* ---------- Hero ---------- */
.xh-hero { background: linear-gradient(180deg, #FAFCFE 0%, #EEF3F9 100%); border-bottom: 1px solid var(--x-line); overflow: hidden; }
.xh-hero__grid { display: grid; grid-template-columns: minmax(0, 520px) 1fr; gap: 48px; align-items: center; padding: 84px 0 92px; }
.xh-hero__meta { font-family: var(--x-mono); font-size: 12px; letter-spacing: .08em; color: var(--x-faint); margin-bottom: 20px; }
.xh-h1 { font-size: clamp(38px, 5vw, 58px); font-weight: 680; letter-spacing: -.028em; line-height: 1.05; margin: 0 0 22px; }
.xh-hero__lede { font-size: 17.5px; line-height: 1.6; color: var(--x-body); max-width: 46ch; margin: 0 0 32px; }
.xh-hero__actions { display: flex; gap: 14px; flex-wrap: wrap; }

.xh-hero__visual { position: relative; min-height: 420px; }
/* Photo sits above the SVG fallback; if the photo 404s the SVG shows through */
.xh-net { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
.xh-hero__img {
  position: absolute; inset: 0; z-index: 1; border-radius: var(--x-radius);
  background-size: cover; background-position: center;
}
.xh-livecard { z-index: 2; }
.xh-livecard {
  position: absolute; right: 8px; top: 34px; width: 230px;
  background: #fff; border: 1px solid var(--x-line); border-radius: var(--x-radius);
  box-shadow: var(--x-shadow); padding: 16px 18px; font-size: 13px;
}
.xh-livecard__head { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--x-ink); margin-bottom: 12px; }
.xh-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--x-green); box-shadow: 0 0 0 3px rgba(155,219,60,.25); }
.xh-livecard__row { display: flex; justify-content: space-between; color: var(--x-body); padding: 5px 0; border-top: 1px dashed var(--x-line); }
.xh-livecard__row strong { color: var(--x-ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.xh-bars { display: flex; align-items: flex-end; gap: 4px; height: 36px; margin-top: 12px; }
.xh-bars span { flex: 1; background: var(--x-blue); opacity: .85; border-radius: 2px 2px 0 0; }
.xh-bars span:nth-child(2n) { background: var(--x-green); }

/* proof strip under hero */
.xh-proof { border-bottom: 1px solid var(--x-line); background: #fff; }
.xh-proof__inner { display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 14px 0; font-size: 13px; color: var(--x-faint); flex-wrap: wrap; }
.xh-proof__tags { display: flex; gap: 22px; font-family: var(--x-mono); font-size: 11.5px; letter-spacing: .1em; }

/* ---------- Impact band ---------- */
.xh-impact { display: grid; grid-template-columns: auto 1fr; gap: 64px; align-items: center; }
.xh-stat { display: flex; align-items: baseline; gap: 14px; }
.xh-stat__num { font-size: clamp(54px, 6vw, 84px); font-weight: 700; letter-spacing: -.03em; color: var(--x-ink); font-variant-numeric: tabular-nums; }
.xh-stat__lbl { font-size: 17px; color: var(--x-body); }
.xh-impact__cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.xh-impact__col { border-left: 1px solid var(--x-line); padding-left: 24px; }
.xh-impact__col h3 { font-size: 16px; font-weight: 600; margin: 0 0 6px; color: var(--x-ink); }
.xh-impact__col p { font-size: 14px; color: var(--x-body); line-height: 1.55; margin: 0; }

/* ---------- Product cards ---------- */
.xh-products { display: grid; grid-template-columns: 1.2fr 1fr; gap: 24px; }
.xh-products__right { display: grid; grid-template-rows: auto 1fr; gap: 24px; }
.xh-products__pair { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.xh-pcard {
  position: relative; display: flex; flex-direction: column; gap: 14px;
  background: #fff; border: 1px solid var(--x-line); border-radius: var(--x-radius);
  box-shadow: var(--x-shadow); padding: 26px; text-decoration: none; color: inherit;
  transition: transform .18s ease, box-shadow .18s ease;
}
.xh-pcard:hover { transform: translateY(-3px); box-shadow: 0 2px 4px rgba(14,28,48,.06), 0 20px 44px -14px rgba(14,28,48,.18); }
.xh-pcard__top { display: flex; justify-content: space-between; align-items: flex-start; }
.xh-pcard h3 { font-size: 20px; font-weight: 650; margin: 0; color: var(--x-ink); }
.xh-pcard__tag { font-size: 13.5px; color: var(--x-faint); margin-top: 3px; }
.xh-pcard__go { color: var(--x-blue); flex-shrink: 0; }
.xh-pcard p { font-size: 14.5px; line-height: 1.55; color: var(--x-body); margin: 0; }

/* mini product-UI mockups inside cards */
.xh-ui { border: 1px solid var(--x-line); border-radius: var(--x-radius-sm); overflow: hidden; background: var(--x-mist); font-size: 11.5px; margin-top: auto; }
.xh-products > .xh-pcard .xh-ui { flex: 1; display: flex; flex-direction: column; }
.xh-products > .xh-pcard .xh-ui__body { flex: 1; min-height: 240px; }
.xh-products > .xh-pcard .xh-ui__side span { padding: 8px 14px; }
.xh-products > .xh-pcard .xh-ui__main { padding: 16px 18px; font-size: 12.5px; }
.xh-ui__bar { display: flex; align-items: center; gap: 6px; background: var(--x-navy); color: #fff; padding: 7px 10px; font-weight: 600; font-size: 11px; }
.xh-ui__bar i { width: 7px; height: 7px; border-radius: 50%; background: var(--x-green); }
.xh-ui__body { display: grid; grid-template-columns: 86px 1fr; min-height: 150px; }
.xh-ui__side { background: var(--x-navy-2); color: rgba(255,255,255,.72); padding: 10px 0; display: flex; flex-direction: column; }
.xh-ui__side b { color: #fff; font-weight: 500; }
.xh-ui__side span { padding: 5px 12px; }
.xh-ui__side span.is-on { background: rgba(155,219,60,.16); color: #fff; border-left: 2px solid var(--x-green); }
.xh-ui__main { background: #fff; padding: 12px 14px; color: var(--x-body); }
.xh-ui__title { display: flex; justify-content: space-between; align-items: center; color: var(--x-ink); font-weight: 600; font-size: 12.5px; margin-bottom: 8px; }
.xh-pill { background: rgba(155,219,60,.2); color: var(--x-green-ink); border-radius: 999px; padding: 2px 8px; font-size: 10.5px; font-weight: 600; }
.xh-ui__kv { display: flex; justify-content: space-between; padding: 4px 0; border-top: 1px dashed var(--x-line); }
.xh-ui__kv strong { color: var(--x-ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.xh-ui__duo { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 10px 0; }
.xh-ui__panel { border: 1px solid var(--x-line); border-radius: 8px; padding: 9px 11px; background: var(--x-mist); }
.xh-ui__panel span { display: block; font-size: 10.5px; color: var(--x-faint); margin-bottom: 4px; }
.xh-ui__panel strong { font-size: 16px; color: var(--x-ink); font-variant-numeric: tabular-nums; }
.xh-bars--sm { height: 26px; margin-top: 2px; }
.xh-ui__svc { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-top: 1px dashed var(--x-line); color: var(--x-ink); font-weight: 500; }
.xh-ui__svc i { width: 7px; height: 7px; border-radius: 50%; background: var(--x-green); }
.xh-ui__svc em { margin-left: auto; font-style: normal; font-size: 10.5px; }
.xh-meter { height: 7px; border-radius: 999px; background: var(--x-line); overflow: hidden; margin: 6px 0 2px; }
.xh-meter i { display: block; height: 100%; background: linear-gradient(90deg, var(--x-blue), var(--x-green)); }
.xh-table { width: 100%; border-collapse: collapse; background: #fff; }
.xh-table th { text-align: left; font-weight: 600; color: var(--x-faint); font-size: 10.5px; padding: 6px 10px; border-bottom: 1px solid var(--x-line); }
.xh-table td { padding: 6px 10px; border-bottom: 1px solid var(--x-mist); color: var(--x-body); white-space: nowrap; }
.xh-ok { color: var(--x-green-ink); font-weight: 600; }

/* ---------- Lifecycle (navy band) ---------- */
.xh-life { display: grid; grid-template-columns: 1fr minmax(0, 520px); gap: 56px; align-items: center; }
.xh-life .xh-h2 { color: #fff; }
.xh-life__copy p { color: rgba(255,255,255,.72); font-size: 16px; line-height: 1.6; max-width: 44ch; }
.xh-life__shot { background: #fff; border-radius: var(--x-radius); box-shadow: 0 24px 60px -20px rgba(0,0,0,.45); overflow: hidden; color: var(--x-ink); }
.xh-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-top: 64px; position: relative; }
.xh-steps::before { content: ""; position: absolute; top: 5px; left: 2%; right: 2%; height: 2px; background: rgba(255,255,255,.18); }
.xh-step { position: relative; padding: 24px 18px 0 0; }
.xh-step::before { content: ""; position: absolute; top: 0; left: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--x-green); box-shadow: 0 0 0 4px rgba(155,219,60,.2); }
.xh-step__n { font-family: var(--x-mono); font-size: 11px; color: rgba(255,255,255,.5); }
.xh-step h4 { color: #fff; font-size: 16.5px; margin: 6px 0 6px; font-weight: 600; }
.xh-step p { color: rgba(255,255,255,.65); font-size: 13.5px; line-height: 1.5; margin: 0; }

/* ---------- Industries ---------- */
.xh-inds { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.xh-ind { display: block; text-decoration: none; color: inherit; background: #fff; border: 1px solid var(--x-line); border-radius: var(--x-radius); overflow: hidden; box-shadow: var(--x-shadow); transition: transform .18s ease; }
.xh-ind:hover { transform: translateY(-3px); }
.xh-ind__img { aspect-ratio: 16/8; background-color: var(--x-navy); background-image: linear-gradient(135deg, rgba(13,43,85,.25), rgba(36,86,230,.2)); background-size: cover; background-position: center; }
.xh-ind__body { padding: 20px 24px 24px; }
.xh-ind h3 { margin: 0 0 4px; font-size: 18px; font-weight: 650; color: var(--x-ink); }
.xh-ind p { margin: 0 0 10px; font-size: 14.5px; color: var(--x-body); }

/* ---------- Resource intelligence ---------- */
.xh-res { display: grid; grid-template-columns: minmax(0, 440px) 1fr; gap: 56px; align-items: center; }
.xh-res__copy p { color: var(--x-body); font-size: 16px; line-height: 1.6; }
.xh-ipgrid__panel { position: relative; background: #fff; border: 1px solid var(--x-line); border-radius: var(--x-radius); box-shadow: var(--x-shadow); padding: 22px; }
.xh-ipgrid__tabs { display: flex; gap: 16px; font-size: 13px; color: var(--x-faint); margin-bottom: 14px; font-family: var(--x-mono); }
.xh-ipgrid__tabs .is-on { color: var(--x-ink); font-weight: 600; border-bottom: 2px solid var(--x-blue); }
.xh-ipgrid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 5px; }
.xh-ipgrid i { aspect-ratio: 1; border-radius: 3px; background: var(--x-mist); }
.xh-ipgrid i.l1 { background: #D6E4FB; } .xh-ipgrid i.l2 { background: #A9C6F5; }
.xh-ipgrid i.l3 { background: #6E9BEC; } .xh-ipgrid i.l4 { background: var(--x-blue); }
.xh-ipgrid i.hot { background: var(--x-green); outline: 2px solid var(--x-green-ink); }
.xh-ipcard { position: absolute; right: -14px; top: 40px; width: 200px; background: #fff; border: 1px solid var(--x-line); border-radius: var(--x-radius-sm); box-shadow: var(--x-shadow); padding: 13px 15px; font-size: 12px; }
.xh-ipcard b { display: block; font-family: var(--x-mono); font-size: 12.5px; color: var(--x-ink); margin-bottom: 6px; }
.xh-ipcard div { display: flex; justify-content: space-between; color: var(--x-body); padding: 3px 0; }

/* ---------- Integrations strip ---------- */
.xh-int { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding: 26px 0; border-top: 1px solid var(--x-line); border-bottom: 1px solid var(--x-line); }
.xh-int__lead { font-size: 16.5px; font-weight: 600; color: var(--x-ink); }
.xh-int__items { display: flex; gap: 28px; flex-wrap: wrap; font-family: var(--x-mono); font-size: 12.5px; color: var(--x-faint); }

/* ---------- Resources ---------- */
.xh-arts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.xh-art { display: block; text-decoration: none; color: inherit; background: #fff; border: 1px solid var(--x-line); border-radius: var(--x-radius); overflow: hidden; box-shadow: var(--x-shadow); transition: transform .18s ease; }
.xh-art:hover { transform: translateY(-3px); }
.xh-art__img { aspect-ratio: 16/9; background: linear-gradient(120deg, #DCE7F5, #BFD3EE); background-size: cover; background-position: center; }
.xh-art__body { padding: 18px 20px 22px; }
.xh-art__kind { font-family: var(--x-mono); font-size: 11px; color: var(--x-faint); letter-spacing: .06em; }
.xh-art h3 { font-size: 15.5px; font-weight: 600; color: var(--x-ink); line-height: 1.4; margin: 8px 0 0; }

/* ---------- CTA band ---------- */
.xh-cta { text-align: center; padding: 100px 0; }
.xh-cta h2 { font-size: clamp(34px, 4.6vw, 54px); font-weight: 700; letter-spacing: -.025em; color: #fff; margin: 0 0 14px; }
.xh-cta p { color: rgba(255,255,255,.7); font-size: 17px; margin: 0 0 32px; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .xh-sec { padding: 64px 0; }
  .xh-sechead { grid-template-columns: 1fr; gap: 10px; margin-bottom: 36px; }
  .xh-sechead__aside { max-width: none; }
  .xh-hero__grid { grid-template-columns: 1fr; padding: 56px 0 64px; }
  .xh-hero__visual { min-height: 300px; }
  .xh-impact { grid-template-columns: 1fr; gap: 36px; }
  .xh-impact__cols { grid-template-columns: 1fr; gap: 20px; }
  .xh-products, .xh-products__pair { grid-template-columns: 1fr; }
  .xh-life { grid-template-columns: 1fr; }
  .xh-steps { grid-template-columns: 1fr 1fr; gap: 24px 16px; }
  .xh-steps::before { display: none; }
  .xh-inds, .xh-arts { grid-template-columns: 1fr; }
  .xh-res { grid-template-columns: 1fr; }
  .xh-ipcard { position: static; width: auto; margin-top: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  .xh-pcard, .xh-ind, .xh-art { transition: none; }
}
