/* ==========================================================================
   MASIH MOTOR ENGINEERING — global stylesheet
   Palette from the company logo (teal shield, red band) + workshop green.
   ========================================================================== */

:root {
  /* surfaces */
  --white: #ffffff;
  --paper: #f3f6f6;
  --paper-2: #e9eff0;
  --line: #d9e3e5;
  --line-soft: #e8eef0;

  /* ink (teal-tinted, never pure black) */
  --ink: #0b1a21;
  --ink-2: #33464e;
  --ink-3: #5f7179;
  --night-950: #031118;
  --night-900: #061a23;
  --night-800: #0b2a35;
  --night-700: #12394a;
  --night-line: rgba(122, 196, 214, 0.14);

  /* brand */
  --teal-700: #01738e;
  --teal-600: #0093ad;
  --teal-500: #1d9dba;
  --teal-300: #72cbd9;
  --teal-50: #e4f4f7;

  --red-700: #a51d24;
  --red-600: #d1262e;
  --red-50: #fcebec;

  --green-700: #157a43;
  --green-600: #1f9d55;
  --green-400: #4cc784;
  --green-50: #e5f5ec;

  /* type */
  --font-display: "Archivo", "Arial Narrow", system-ui, sans-serif;
  --font-body: "Geist", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, Consolas, monospace;

  /* shape */
  --r-xs: 6px;
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-xl: 32px;

  --shadow-sm: 0 1px 2px rgba(6, 40, 52, 0.06), 0 4px 14px rgba(6, 40, 52, 0.06);
  --shadow-md: 0 2px 6px rgba(6, 40, 52, 0.06), 0 18px 40px -12px rgba(6, 40, 52, 0.22);
  --shadow-lg: 0 30px 80px -24px rgba(3, 30, 42, 0.45);

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);

  --z-header: 40;
  --z-chat: 60;
  --z-skip: 80;

  --container: 1240px;
  --gutter: clamp(16px, 4vw, 32px);
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, p { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }
button { font: inherit; }
::selection { background: var(--teal-600); color: #fff; }
:focus-visible { outline: 2px solid var(--teal-500); outline-offset: 3px; border-radius: 4px; }

.skip-link {
  position: fixed; left: 16px; top: -60px; z-index: var(--z-skip);
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: var(--r-sm);
  transition: top .2s var(--ease-out);
}
.skip-link:focus { top: 16px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- type ---------- */
.display, h1, h2.section-title {
  font-family: var(--font-display);
  font-stretch: 78%;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 0.98;
}
h2.section-title { font-size: clamp(34px, 5vw, 58px); }
.section-title em { font-style: normal; color: var(--teal-600); }
.section-sub { margin-top: 18px; max-width: 58ch; color: var(--ink-2); font-size: 17px; }

.kicker {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 12.5px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--teal-700);
  margin-bottom: 18px;
}
.kicker::before { content: ""; width: 18px; height: 2px; background: currentColor; }
.kicker--light { color: var(--teal-300); }
.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

/* ---------- buttons ---------- */
.btn {
  --btn-bg: var(--ink); --btn-fg: #fff; --btn-bd: transparent;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 0 24px; border-radius: 999px;
  background: var(--btn-bg); color: var(--btn-fg); border: 1.5px solid var(--btn-bd);
  font-weight: 600; font-size: 15.5px; letter-spacing: -0.005em; white-space: nowrap; cursor: pointer;
  transition: transform .16s var(--ease-out), background-color .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease;
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn:active { transform: scale(0.97); }
.btn--red { --btn-bg: var(--red-600); box-shadow: 0 10px 24px -10px rgba(209, 38, 46, .7); }
.btn--teal { --btn-bg: var(--teal-700); }
.btn--green { --btn-bg: var(--green-600); }
.btn--ghost-light { --btn-bg: rgba(255,255,255,.04); --btn-fg: #fff; --btn-bd: rgba(255,255,255,.22); }
.btn--outline { --btn-bg: transparent; --btn-fg: var(--ink); --btn-bd: var(--line); }
.btn--sm { min-height: 40px; padding: 0 16px; font-size: 14px; }
.btn--block { width: 100%; }
@media (hover: hover) and (pointer: fine) {
  .btn--red:hover { --btn-bg: var(--red-700); }
  .btn--teal:hover { --btn-bg: var(--teal-600); }
  .btn--green:hover { --btn-bg: var(--green-700); }
  .btn--ghost-light:hover { --btn-bd: rgba(255,255,255,.5); --btn-bg: rgba(255,255,255,.08); }
  .btn--outline:hover { --btn-bd: var(--teal-600); --btn-fg: var(--teal-700); }
}

.link-arrow { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--teal-700); }
.link-arrow svg { width: 16px; height: 16px; transition: transform .2s var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .link-arrow:hover svg { transform: translateX(4px); } }

/* ---------- top bar + header ---------- */
.topbar { background: var(--night-950); color: #cfe3e8; font-size: 13.5px; }
.topbar__in { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 40px; }
.topbar__links { display: flex; gap: 22px; }
.topbar a { display: inline-flex; align-items: center; gap: 7px; transition: color .2s ease; }
.topbar svg { width: 15px; height: 15px; color: var(--teal-300); }
.topbar__note { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-mono); font-size: 12px; letter-spacing: .04em; text-transform: uppercase; color: var(--green-400); }
.topbar__note::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--green-400); box-shadow: 0 0 0 4px rgba(76,199,132,.18); }
@media (hover: hover) and (pointer: fine) { .topbar a:hover { color: #fff; } }

.site-header {
  position: sticky; top: 0; z-index: var(--z-header);
  background: rgba(255,255,255,.88); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .25s ease, box-shadow .25s ease;
}
.site-header.is-scrolled { border-color: var(--line-soft); box-shadow: 0 8px 30px -18px rgba(6,40,52,.35); }
.header__in { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: 76px; }

.brand { display: flex; align-items: center; gap: 12px; }
.brand__logo { height: 48px; width: auto; filter: drop-shadow(0 4px 8px rgba(1,115,142,.25)); }
.brand__word { display: flex; flex-direction: column; line-height: 1; }
.brand__word b { font-family: var(--font-display); font-stretch: 85%; font-weight: 800; font-size: 23px; letter-spacing: .02em; color: var(--red-600); }
.brand__word span { font-family: var(--font-display); font-stretch: 85%; font-weight: 600; font-size: 12.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--teal-600); margin-top: 4px; }

.nav { display: flex; align-items: center; gap: 28px; }
.nav__links { display: flex; gap: 4px; }
.nav__links a {
  position: relative; padding: 8px 14px; border-radius: 999px; font-weight: 500; color: var(--ink-2);
  transition: color .2s ease, background-color .2s ease;
}
.nav__links a.is-active { color: var(--ink); background: var(--paper); }
.nav__cta { display: flex; gap: 10px; }
@media (hover: hover) and (pointer: fine) { .nav__links a:hover { color: var(--ink); } }

.hamburger {
  display: none; width: 46px; height: 46px; border-radius: 12px; border: 1px solid var(--line);
  background: #fff; cursor: pointer; align-items: center; justify-content: center; flex-direction: column; gap: 5px;
}
.hamburger span { width: 20px; height: 2px; border-radius: 2px; background: var(--ink); transition: transform .25s var(--ease-out), opacity .2s ease; }
.hamburger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.is-open span:nth-child(2) { opacity: 0; }
.hamburger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-nav {
  display: none; border-top: 1px solid var(--line-soft); background: #fff;
  overflow: hidden; max-height: 0; transition: max-height .35s var(--ease-out);
}
.mobile-nav.is-open { max-height: 420px; }
.mobile-nav__in { padding: 14px var(--gutter) 22px; display: grid; gap: 4px; }
.mobile-nav a:not(.btn) { padding: 12px 4px; font-size: 18px; font-weight: 600; border-bottom: 1px solid var(--line-soft); }
.mobile-nav a.is-active { color: var(--teal-700); }
.mobile-nav .btn { margin-top: 12px; }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden; color: #fff; isolation: isolate;
  background:
    radial-gradient(900px 520px at 78% 38%, rgba(0,147,173,.28), transparent 62%),
    radial-gradient(600px 420px at 95% 95%, rgba(31,157,85,.16), transparent 65%),
    radial-gradient(700px 500px at 0% 0%, rgba(209,38,46,.10), transparent 60%),
    var(--night-900);
}
.hero::before {
  /* blueprint grid */
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(var(--night-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--night-line) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse at 70% 40%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at 70% 40%, #000 20%, transparent 75%);
}
.hero__in { display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, 1fr); gap: 24px; align-items: center; min-height: min(760px, calc(100dvh - 116px)); padding-block: 72px 120px; }
.hero__copy { position: relative; z-index: 2; }
.hero__badge {
  display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px 7px 8px; border-radius: 999px;
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); font-size: 13.5px; color: #d7eaee;
}
.hero__badge i { font-style: normal; font-family: var(--font-mono); font-size: 11.5px; font-weight: 500; letter-spacing: .06em; background: var(--green-600); color: #fff; padding: 3px 8px; border-radius: 999px; }
.hero h1 { margin-top: 26px; font-size: clamp(46px, 7.2vw, 96px); color: #fff; }
.hero h1 .accent { color: var(--teal-300); }
.hero h1 .underline { position: relative; white-space: nowrap; }
.hero h1 .underline::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: .04em; height: .09em; border-radius: 4px;
  background: var(--red-600); transform-origin: left; transform: scaleX(0);
  animation: underline .9s var(--ease-out) .9s forwards;
}
@keyframes underline { to { transform: scaleX(1); } }
.hero__lede { margin-top: 26px; max-width: 52ch; font-size: 18px; line-height: 1.65; color: #b9d2d8; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.hero__trust { display: flex; flex-wrap: wrap; gap: 10px 26px; margin-top: 44px; }
.hero__trust li { display: flex; align-items: center; gap: 9px; font-size: 14.5px; color: #cfe3e8; }
.hero__trust svg { width: 18px; height: 18px; color: var(--green-400); }

.hero__stage { position: relative; height: 100%; min-height: 520px; }
.engine-canvas { position: absolute; inset: -40px -4vw -40px -60px; width: auto; height: auto; }
.engine-canvas canvas { width: 100% !important; height: 100% !important; }
.engine-fallback {
  position: absolute; inset: 0; display: grid; place-items: center; opacity: .55;
}
.engine-ready .engine-fallback { display: none; }

.hud { position: absolute; z-index: 2; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: #9fcfda; pointer-events: none; }
.hud__chip {
  display: inline-flex; flex-direction: column; gap: 2px; padding: 9px 12px; border-radius: 10px;
  background: rgba(3,17,24,.55); border: 1px solid rgba(114,203,217,.22); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.hud__chip b { font-size: 17px; font-weight: 500; letter-spacing: .02em; color: #fff; font-variant-numeric: tabular-nums; }
.hud__chip--green b { color: var(--green-400); }
.hud--a { top: 8%; right: 4%; }
.hud--b { bottom: 14%; left: 2%; }
.hud--c { bottom: 6%; right: 10%; }

/* diagnostic dock overlapping hero bottom */
.diag {
  position: relative; z-index: 3; margin-top: -72px;
}
.diag__card {
  display: grid; grid-template-columns: auto 1fr auto; gap: 28px; align-items: center;
  background: #fff; border-radius: var(--r-lg); padding: 22px 22px 22px 28px; box-shadow: var(--shadow-lg);
  border: 1px solid var(--line-soft);
}
.diag__title { font-family: var(--font-display); font-stretch: 82%; font-weight: 800; font-size: 24px; line-height: 1.05; }
.diag__title small { display: block; font-family: var(--font-mono); font-size: 11.5px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--green-700); margin-bottom: 6px; }
.diag__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.diag__chips button {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: 999px; cursor: pointer;
  background: var(--paper); border: 1px solid var(--line-soft); color: var(--ink-2); font-size: 14.5px; font-weight: 500;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease, transform .16s var(--ease-out);
}
.diag__chips button:active { transform: scale(.97); }
.diag__chips svg { width: 16px; height: 16px; color: var(--teal-600); }
@media (hover: hover) and (pointer: fine) {
  .diag__chips button:hover { background: var(--teal-50); border-color: rgba(0,147,173,.35); color: var(--teal-700); }
}

/* ---------- sections ---------- */
.section { padding: clamp(80px, 10vw, 132px) 0 clamp(88px, 11vw, 144px); }
.section--paper { background: var(--paper); }
.section--tight { padding: 64px 0 72px; }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr); gap: 32px; align-items: end; margin-bottom: 56px; }
.section-head .section-sub { margin-top: 0; justify-self: end; }

/* ---------- brands ---------- */
.brands { padding: 120px 0 40px; }
.brands__head { display: flex; align-items: end; justify-content: space-between; gap: 24px; flex-wrap: wrap; margin-bottom: 28px; }
.brands__head h2 { font-family: var(--font-display); font-stretch: 80%; font-weight: 800; font-size: clamp(26px, 3.2vw, 36px); letter-spacing: -0.015em; line-height: 1.05; }
.brands__head p { color: var(--ink-3); max-width: 46ch; }

.dealer-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.dealer {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  min-height: 150px; padding: 22px 12px 18px; border-radius: var(--r-md); background: var(--paper); border: 1px solid transparent;
  transition: background-color .25s ease, border-color .25s ease, transform .3s var(--ease-out);
}
.dealer::after {
  content: "Approved"; position: absolute; top: 10px; right: 10px; font-family: var(--font-mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--green-700); background: var(--green-50); padding: 2px 7px; border-radius: 999px;
}
.dealer span:last-child { font-size: 13.5px; font-weight: 600; color: var(--ink-2); text-align: center; line-height: 1.25; }
@media (hover: hover) and (pointer: fine) { .dealer:hover { background: #fff; border-color: var(--line); transform: translateY(-3px); } }

.brand-logo {
  display: block; width: 64px; height: 64px; background-color: currentColor; color: var(--ink);
  -webkit-mask: var(--logo) center / contain no-repeat; mask: var(--logo) center / contain no-repeat;
}
.dealer .brand-logo { width: 72px; height: 58px; transition: color .25s ease; }
@media (hover: hover) and (pointer: fine) { .dealer:hover .brand-logo { color: var(--teal-700); } }

.conveyor { position: relative; margin-top: 18px; padding: 26px 0; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.conveyor__viewport { overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.conveyor__label { display: flex; justify-content: space-between; margin-bottom: 14px; font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.conveyor__track { display: flex; width: max-content; gap: 14px; animation: convey 60s linear infinite; }
.conveyor__viewport:hover .conveyor__track { animation-play-state: paused; }
.conveyor__item {
  display: flex; align-items: center; gap: 12px; padding: 12px 18px 12px 14px; border-radius: 14px; background: #fff; border: 1px solid var(--line-soft);
  box-shadow: var(--shadow-sm); white-space: nowrap; font-weight: 600; font-size: 14.5px; color: var(--ink-2);
}
.conveyor__item .brand-logo { width: 34px; height: 30px; color: var(--ink-2); }
@keyframes convey { to { transform: translateX(-50%); } }

/* ---------- why ---------- */
.why { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(40px, 7vw, 96px); align-items: start; }
.why__intro { position: sticky; top: 120px; }
.why__intro .section-sub { margin-bottom: 30px; }
.why__list { display: grid; gap: 14px; }
.why__item { display: grid; grid-template-columns: 56px 1fr; gap: 20px; padding: 26px 28px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line-soft); box-shadow: var(--shadow-sm); }
.why__item:nth-child(even) { margin-left: clamp(0px, 4vw, 48px); }
.why__icon { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; background: var(--teal-50); color: var(--teal-700); }
.why__icon--green { background: var(--green-50); color: var(--green-700); }
.why__icon--red { background: var(--red-50); color: var(--red-600); }
.why__icon svg { width: 26px; height: 26px; }
.why__item h3 { font-size: 19px; font-weight: 600; letter-spacing: -0.01em; margin-bottom: 6px; }
.why__item p { color: var(--ink-2); font-size: 15.5px; }

/* ---------- stats ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stat { padding: 34px 26px 30px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; padding-left: 0; }
.stat__num { font-family: var(--font-display); font-stretch: 75%; font-weight: 800; font-size: clamp(54px, 6.5vw, 84px); line-height: .9; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; color: var(--ink); }
.stat__num small { font-size: .42em; letter-spacing: 0; color: var(--teal-600); margin-left: 4px; }
.stat__label { margin-top: 14px; font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }

/* ---------- services bento ---------- */
.bento { display: grid; grid-template-columns: repeat(12, 1fr); gap: 14px; }
.svc {
  position: relative; display: flex; flex-direction: column; padding: 28px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line-soft);
  overflow: hidden; min-height: 250px; transition: transform .35s var(--ease-out), box-shadow .3s ease, border-color .3s ease;
}
.svc--wide { grid-column: span 7; }
.svc--mid { grid-column: span 5; }
.svc--third { grid-column: span 4; }
.svc--dark { background: var(--night-900); color: #fff; border-color: var(--night-800); }
.svc--dark p { color: #a9c7ce; }
.svc__num { font-family: var(--font-mono); font-size: 12.5px; color: var(--teal-600); letter-spacing: .06em; }
.svc--dark .svc__num { color: var(--teal-300); }
.svc h3 { margin-top: auto; padding-top: 48px; font-family: var(--font-display); font-stretch: 82%; font-weight: 800; font-size: clamp(24px, 2.4vw, 30px); letter-spacing: -0.015em; line-height: 1.05; }
.svc p { margin-top: 10px; color: var(--ink-2); font-size: 15.5px; max-width: 46ch; }
.svc__tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; }
.svc__tags span { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; padding: 4px 9px; border-radius: 6px; background: var(--paper); color: var(--ink-2); }
.svc--dark .svc__tags span { background: rgba(255,255,255,.07); color: #cfe3e8; }
.svc__art { position: absolute; top: 22px; right: 22px; width: 40%; max-width: 280px; color: var(--teal-600); opacity: .9; pointer-events: none; }
.svc--dark .svc__art { color: var(--teal-300); }
.svc--mid .svc__art { width: 30%; max-width: 150px; }
.svc--wide { min-height: 300px; }
.svc__art svg { width: 100%; height: auto; }
.svc__art .spin { transform-origin: 50% 50%; transform-box: fill-box; animation: spin 14s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (hover: hover) and (pointer: fine) {
  .svc:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--line); }
}
.svc-more { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-top: 30px; flex-wrap: wrap; }
.svc-more p { color: var(--ink-3); }

/* ---------- process ---------- */
.process { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; counter-reset: step; position: relative; }
.process::before { content: ""; position: absolute; top: 27px; left: 28px; right: 12%; height: 2px; background: linear-gradient(90deg, var(--green-600), var(--teal-600)); opacity: .35; }
.step { position: relative; padding-right: 28px; }
.step__dot { position: relative; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: #fff; border: 2px solid var(--green-600); color: var(--green-700); font-family: var(--font-mono); font-weight: 500; font-size: 15px; }
.step:last-child .step__dot { background: var(--green-600); color: #fff; }
.step h3 { margin-top: 24px; font-size: 19px; font-weight: 600; letter-spacing: -0.01em; }
.step p { margin-top: 8px; color: var(--ink-2); font-size: 15.5px; max-width: 30ch; }

/* ---------- branches ---------- */
.branches { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.branch {
  position: relative; display: grid; gap: 14px; align-content: start; padding: 28px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line-soft);
  transition: border-color .25s ease, box-shadow .25s ease;
}
.branch--hq { grid-row: span 3; display: flex; flex-direction: column; background: var(--night-900); color: #fff; border-color: var(--night-800); overflow: hidden; }
.branch--hq::after { content: ""; position: absolute; inset: auto -80px -120px auto; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(circle, rgba(31,157,85,.35), transparent 65%); }
.branch__tag { justify-self: start; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; background: var(--green-50); color: var(--green-700); }
.branch--hq .branch__tag { background: var(--green-600); color: #fff; }
.branch h3 { font-family: var(--font-display); font-stretch: 82%; font-weight: 800; font-size: 28px; letter-spacing: -0.015em; line-height: 1.05; }
.branch--hq h3 { font-size: clamp(34px, 4vw, 46px); }
.branch__row { display: flex; gap: 10px; align-items: flex-start; color: var(--ink-2); font-size: 15.5px; }
.branch--hq .branch__row { color: #bcd6dc; }
.branch__row svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 3px; color: var(--green-600); }
.branch--hq .branch__row svg { color: var(--green-400); }
.branch__row a { font-weight: 600; color: var(--ink); }
.branch--hq .branch__row a { color: #fff; }
.branch__actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 6px; position: relative; z-index: 1; }
.branch--hq .branch__map { flex: 1; position: relative; z-index: 1; border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--night-700); min-height: 220px; }
.branch__map iframe { width: 100%; height: 100%; min-height: 220px; border: 0; display: block; filter: grayscale(.2) contrast(1.05); }
@media (hover: hover) and (pointer: fine) { .branch:not(.branch--hq):hover { border-color: rgba(31,157,85,.4); box-shadow: var(--shadow-md); } }

/* single head-office card */
.branches:has(.branch--solo) { grid-template-columns: 1fr; }
.branch--solo { grid-row: auto; display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 32px; padding: clamp(26px, 4vw, 44px); align-items: stretch; }
.branch--solo .branch__info { position: relative; z-index: 1; display: grid; gap: 16px; align-content: start; }
.branch--solo h3 { font-size: clamp(36px, 4.6vw, 56px); }
.branch--solo .branch__actions { margin-top: 10px; }
.branch--solo .branch__map, .branch--solo .branch__map iframe { min-height: 340px; }
@media (max-width: 900px) { .branch--solo { grid-template-columns: 1fr; } .branch--solo .branch__map, .branch--solo .branch__map iframe { min-height: 260px; } }

/* ---------- AI CTA ---------- */
.ai-cta {
  position: relative; overflow: hidden; border-radius: var(--r-xl); color: #fff; padding: clamp(36px, 6vw, 72px);
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 40px; align-items: center;
  background: radial-gradient(600px 380px at 85% 20%, rgba(0,147,173,.45), transparent 60%), radial-gradient(500px 360px at 10% 100%, rgba(31,157,85,.28), transparent 60%), var(--night-900);
}
.ai-cta h2 { font-family: var(--font-display); font-stretch: 78%; font-weight: 800; font-size: clamp(34px, 4.6vw, 56px); letter-spacing: -0.02em; line-height: .98; }
.ai-cta p { margin-top: 18px; color: #b9d2d8; max-width: 46ch; font-size: 17px; }
.ai-cta__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.ai-cta__demo { display: grid; gap: 10px; }
.bubble { max-width: 88%; padding: 13px 16px; border-radius: 18px; font-size: 15px; line-height: 1.5; }
.bubble--user { justify-self: end; background: var(--teal-700); border-bottom-right-radius: 6px; }
.bubble--bot { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.1); border-bottom-left-radius: 6px; color: #e3eff2; }
.bubble--bot b { color: var(--green-400); font-weight: 600; }

/* ---------- page hero (inner pages) ---------- */
.page-hero { position: relative; overflow: hidden; color: #fff; padding: 84px 0 96px; isolation: isolate;
  background: radial-gradient(700px 420px at 85% 30%, rgba(0,147,173,.3), transparent 62%), radial-gradient(500px 360px at 100% 100%, rgba(31,157,85,.18), transparent 60%), var(--night-900); }
.page-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background-image: linear-gradient(var(--night-line) 1px, transparent 1px), linear-gradient(90deg, var(--night-line) 1px, transparent 1px); background-size: 56px 56px;
  mask-image: radial-gradient(ellipse at 80% 40%, #000 15%, transparent 70%); -webkit-mask-image: radial-gradient(ellipse at 80% 40%, #000 15%, transparent 70%); }
.page-hero h1 { font-size: clamp(42px, 6vw, 76px); max-width: 16ch; }
.page-hero p { margin-top: 20px; max-width: 58ch; color: #b9d2d8; font-size: 17.5px; }
.page-hero__art { position: absolute; right: -60px; top: 50%; transform: translateY(-50%); width: min(460px, 42vw); color: var(--teal-300); opacity: .22; pointer-events: none; }
.page-hero__art .spin { transform-origin: 50% 50%; transform-box: fill-box; animation: spin 30s linear infinite; }
.breadcrumb { display: flex; gap: 8px; font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .06em; text-transform: uppercase; color: #8fb6bf; margin-bottom: 22px; }
.breadcrumb a { color: #cfe3e8; }

/* ---------- services page ---------- */
.svc-cats { display: grid; gap: 18px; }
.svc-cat { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 32px; padding: 34px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line-soft); }
.svc-cat__head h2 { font-family: var(--font-display); font-stretch: 80%; font-weight: 800; font-size: clamp(28px, 3.2vw, 38px); letter-spacing: -0.015em; line-height: 1.02; margin-top: 14px; }
.svc-cat__head p { margin-top: 12px; color: var(--ink-2); }
.svc-cat__icon { width: 60px; height: 60px; border-radius: 18px; display: grid; place-items: center; background: var(--teal-50); color: var(--teal-700); }
.svc-cat__icon svg { width: 30px; height: 30px; }
.svc-items { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-content: start; }
.svc-item { display: grid; grid-template-columns: 24px 1fr; gap: 12px; padding: 16px 18px; border-radius: var(--r-md); background: var(--paper); }
.svc-item svg { width: 20px; height: 20px; margin-top: 2px; color: var(--green-600); }
.svc-item b { display: block; font-weight: 600; font-size: 15.5px; }
.svc-item span { display: block; margin-top: 3px; font-size: 14.5px; color: var(--ink-2); }

.warranty { display: grid; grid-template-columns: auto 1fr; gap: 28px; align-items: center; padding: 32px 36px; border-radius: var(--r-lg); background: var(--green-50); border: 1px solid rgba(31,157,85,.25); }
.warranty__seal { width: 108px; height: 108px; border-radius: 50%; display: grid; place-items: center; text-align: center; background: var(--green-600); color: #fff; font-family: var(--font-display); font-stretch: 80%; font-weight: 800; line-height: 1; box-shadow: 0 0 0 8px rgba(31,157,85,.15); }
.warranty__seal b { display: block; font-size: 40px; }
.warranty__seal span { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.warranty h3 { font-family: var(--font-display); font-stretch: 82%; font-weight: 800; font-size: 28px; letter-spacing: -0.01em; }
.warranty p { margin-top: 8px; color: var(--ink-2); max-width: 72ch; }

/* ---------- contact page ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 24px; align-items: start; }
.form-card { padding: clamp(26px, 4vw, 40px); border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line-soft); box-shadow: var(--shadow-md); }
.form-card h2 { font-family: var(--font-display); font-stretch: 80%; font-weight: 800; font-size: clamp(30px, 3.4vw, 40px); letter-spacing: -0.015em; line-height: 1.02; }
.form-card > p { margin-top: 10px; color: var(--ink-2); }
.form { display: grid; gap: 16px; margin-top: 28px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 7px; color: var(--ink-2); }
.field input, .field select, .field textarea {
  width: 100%; padding: 13px 15px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--paper);
  font: 16px var(--font-body); color: var(--ink); transition: border-color .2s ease, background-color .2s ease, box-shadow .2s ease;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--teal-600); background: #fff; box-shadow: 0 0 0 4px rgba(0,147,173,.12); }
.field.has-error input, .field.has-error textarea { border-color: var(--red-600); }
.field__error { display: none; margin-top: 6px; font-size: 13.5px; color: var(--red-600); }
.field.has-error .field__error { display: block; }
.form-note { font-size: 14px; color: var(--ink-3); }
.form-status { display: none; padding: 14px 16px; border-radius: 12px; font-size: 15px; }
.form-status.is-ok { display: block; background: var(--green-50); color: var(--green-700); border: 1px solid rgba(31,157,85,.3); }
.contact-aside { display: grid; gap: 14px; }
.quick { display: grid; gap: 10px; padding: 26px; border-radius: var(--r-lg); background: var(--night-900); color: #fff; }
.quick h3 { font-family: var(--font-display); font-stretch: 82%; font-weight: 800; font-size: 26px; }
.quick p { color: #b9d2d8; font-size: 15px; margin-bottom: 6px; }
.quick a.quick__line { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-radius: 14px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.09); transition: background-color .2s ease, border-color .2s ease; }
.quick a.quick__line span { display: flex; align-items: center; gap: 12px; font-weight: 600; }
.quick a.quick__line small { font-family: var(--font-mono); font-size: 12px; color: #8fb6bf; letter-spacing: .04em; }
.quick svg { width: 20px; height: 20px; color: var(--green-400); }
@media (hover: hover) and (pointer: fine) { .quick a.quick__line:hover { background: rgba(255,255,255,.09); border-color: rgba(76,199,132,.4); } }

/* ---------- footer ---------- */
.site-footer { background: var(--night-950); color: #a9c3ca; padding: 80px 0 36px; }
.footer-top { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: 40px; }
.footer-brand p { margin-top: 18px; max-width: 34ch; font-size: 15px; }
.footer-brand .brand__word span { color: var(--teal-300); }
.site-footer h4 { font-family: var(--font-mono); font-size: 12px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: #6f97a1; margin-bottom: 16px; }
.site-footer li { margin-bottom: 10px; font-size: 15px; }
.site-footer a { transition: color .2s ease; }
@media (hover: hover) and (pointer: fine) { .site-footer a:hover { color: #fff; } }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 60px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.08); font-size: 13.5px; color: #6f97a1; }
.footer-bee { display: inline-flex; align-items: center; gap: 8px; margin-top: 18px; font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--green-400); }

/* ---------- 404 ---------- */
.notfound { min-height: 70vh; display: grid; place-items: center; text-align: center; padding-block: 80px; }
.notfound h1 { font-size: clamp(54px, 9vw, 120px); }
.notfound p { margin: 18px auto 30px; max-width: 46ch; color: var(--ink-2); }

/* ---------- reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease-out), transform .8s var(--ease-out); transition-delay: calc(var(--i, 0) * 70ms); }
.js .reveal.is-visible { opacity: 1; transform: none; }
.hero .rise { opacity: 0; animation: rise .9s var(--ease-out) forwards; animation-delay: calc(var(--d, 0) * 90ms + 100ms); }
@keyframes rise { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }

/* ---------- chat widget ---------- */
.chat-launcher {
  position: fixed; right: 20px; bottom: 20px; z-index: var(--z-chat);
  display: inline-flex; align-items: center; gap: 10px; height: 58px; padding: 0 22px 0 18px; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--red-600); color: #fff; font-weight: 600; font-size: 15px; box-shadow: 0 14px 34px -12px rgba(165,29,36,.8);
  transition: transform .2s var(--ease-out), background-color .2s ease;
}
.chat-launcher svg { width: 22px; height: 22px; }
.chat-launcher:active { transform: scale(.96); }
.chat-launcher__badge { position: absolute; top: -4px; right: -4px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: var(--green-600); border: 2px solid #fff; font-size: 12px; display: grid; place-items: center; }
@media (hover: hover) and (pointer: fine) { .chat-launcher:hover { background: var(--red-700); transform: translateY(-2px); } }

.chat-panel {
  position: fixed; right: 20px; bottom: 92px; z-index: var(--z-chat);
  width: 392px; max-width: calc(100vw - 32px); height: min(600px, calc(100dvh - 120px));
  display: flex; flex-direction: column; overflow: hidden; border-radius: 22px; background: #fff; box-shadow: var(--shadow-lg); border: 1px solid var(--line-soft);
  transform-origin: bottom right; opacity: 0; transform: translateY(10px) scale(.96); visibility: hidden; pointer-events: none;
  transition: opacity .2s var(--ease-out), transform .2s var(--ease-out), visibility 0s .2s;
}
.chat-panel.is-open { opacity: 1; transform: none; visibility: visible; pointer-events: auto; transition: opacity .22s var(--ease-out), transform .22s var(--ease-out), visibility 0s; }
.chat-panel__head { display: flex; align-items: center; gap: 12px; padding: 16px 16px 14px 18px; background: var(--night-900); color: #fff; }
.chat-panel__avatar { width: 42px; height: 42px; border-radius: 12px; background: #fff; display: grid; place-items: center; overflow: hidden; flex-shrink: 0; }
.chat-panel__avatar img { width: 36px; height: auto; }
.chat-panel__title { flex: 1; line-height: 1.25; }
.chat-panel__title b { display: block; font-size: 15.5px; }
.chat-panel__title span { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--green-400); }
.chat-panel__title span::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--green-400); }
.chat-panel__close { width: 36px; height: 36px; border-radius: 10px; border: 0; background: rgba(255,255,255,.08); color: #fff; cursor: pointer; font-size: 20px; line-height: 1; }
.chat-panel__body { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; background: var(--paper); overscroll-behavior: contain; }
.chat-msg { max-width: 86%; padding: 11px 14px; border-radius: 16px; font-size: 14.5px; line-height: 1.5; white-space: pre-wrap; animation: msg .25s var(--ease-out); }
.chat-msg.bot { align-self: flex-start; background: #fff; border: 1px solid var(--line-soft); border-bottom-left-radius: 6px; }
.chat-msg.user { align-self: flex-end; background: var(--teal-700); color: #fff; border-bottom-right-radius: 6px; }
.chat-msg.error { align-self: flex-start; background: var(--red-50); color: var(--red-700); border: 1px solid rgba(209,38,46,.2); }
@keyframes msg { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.chat-typing { align-self: flex-start; display: flex; gap: 4px; padding: 14px 16px; background: #fff; border: 1px solid var(--line-soft); border-radius: 16px; }
.chat-typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--teal-500); animation: blink 1.2s infinite ease-in-out; }
.chat-typing span:nth-child(2) { animation-delay: .15s; }
.chat-typing span:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }
.chat-quick { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 14px 0; background: var(--paper); }
.chat-quick button { padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink-2); font-size: 13px; cursor: pointer; transition: border-color .2s ease, color .2s ease; }
@media (hover: hover) and (pointer: fine) { .chat-quick button:hover { border-color: var(--teal-600); color: var(--teal-700); } }
.chat-panel__foot { display: flex; gap: 8px; align-items: flex-end; padding: 12px 12px 10px; background: var(--paper); }
.chat-panel__foot textarea { flex: 1; resize: none; min-height: 46px; max-height: 110px; padding: 12px 14px; border-radius: 14px; border: 1.5px solid var(--line); background: #fff; font: 16px var(--font-body); color: var(--ink); }
.chat-panel__foot textarea:focus { outline: none; border-color: var(--teal-600); }
.chat-panel__send { width: 46px; height: 46px; border-radius: 14px; border: 0; background: var(--red-600); color: #fff; cursor: pointer; display: grid; place-items: center; flex-shrink: 0; transition: background-color .2s ease, transform .15s var(--ease-out); }
.chat-panel__send:active { transform: scale(.94); }
.chat-panel__send:disabled { opacity: .5; cursor: default; }
.chat-panel__send svg { width: 20px; height: 20px; }
.chat-disclaimer { padding: 0 16px 12px; background: var(--paper); font-size: 11.5px; color: var(--ink-3); text-align: center; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .dealer-grid { grid-template-columns: repeat(3, 1fr); }
  .svc--wide, .svc--mid { grid-column: span 12; }
  .svc--third { grid-column: span 6; }
  .footer-top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
  .nav__links, .nav__cta { display: none; }
  .hamburger { display: inline-flex; }
  .mobile-nav { display: block; }
  .topbar__links a:not(:first-child) { display: none; }
  .hero__in { grid-template-columns: 1fr; min-height: 0; padding-block: 56px 96px; gap: 0; }
  .hero__stage { min-height: 360px; margin: 8px -24px 0; }
  .engine-canvas { inset: -20px; }
  .hud--b { display: none; }
  .diag__card { grid-template-columns: 1fr; gap: 16px; padding: 22px; }
  .section-head { grid-template-columns: 1fr; }
  .section-head .section-sub { justify-self: start; }
  .why { grid-template-columns: 1fr; }
  .why__intro { position: static; }
  .why__item:nth-child(even) { margin-left: 0; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; padding-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .process { grid-template-columns: 1fr 1fr; gap: 36px 0; }
  .process::before { display: none; }
  .branches { grid-template-columns: 1fr; }
  .branch--hq { grid-row: auto; }
  .ai-cta { grid-template-columns: 1fr; }
  .svc-cat { grid-template-columns: 1fr; padding: 26px; }
  .contact-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .brand__logo { height: 40px; }
  .brand__word b { font-size: 20px; }
  .brand__word span { font-size: 11px; }
  .header__in { height: 68px; }
  .topbar__note { display: none; }
  .hero h1 { font-size: clamp(42px, 12vw, 56px); }
  .hero__lede { font-size: 16.5px; }
  .hero__actions .btn { flex: 1 1 100%; }
  .hero__stage { min-height: 300px; }
  .hud { font-size: 10px; }
  .hud__chip b { font-size: 14px; }
  .dealer-grid { grid-template-columns: repeat(2, 1fr); }
  .svc--third { grid-column: span 12; }
  .svc__art { width: 40%; }
  .process { grid-template-columns: 1fr; }
  .svc-items { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .warranty { grid-template-columns: 1fr; padding: 26px; }
  .footer-top { grid-template-columns: 1fr; gap: 30px; }
  .chat-launcher span.chat-launcher__text { display: none; }
  .chat-launcher { padding: 0 18px; }
  .chat-panel { right: 12px; left: 12px; width: auto; max-width: none; bottom: 88px; height: calc(100dvh - 110px); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal, .hero .rise { opacity: 1; transform: none; animation: none; transition: opacity .3s ease; }
  .hero h1 .underline::after { animation: none; transform: none; }
  .conveyor__track { animation-duration: 240s; }
  .svc__art .spin, .page-hero__art .spin { animation: none; }
  .chat-panel, .chat-panel.is-open { transform: none; }
}
