/* Akansha Ispat, website styles
   Layout concept: a mill spec sheet. Paper body, forest-green brand bands from the logo,
   mono spec chips for grades and sizes, size rulers drawn to millimetre scale. */
:root {
  --paper: #F9F8F3;
  --surface: #FFFFFF;
  --cream: #F2EEE2;
  --ink: #142019;
  --muted: #55625A;
  --line: #DCE0D6;
  --brand: #385F44;
  --brand-deep: #223C2B;
  --accent: #2C5838;
  --on-brand: #F7F4EC;
  --on-brand-muted: #C9D6CB;
  --logo: #385F44;
  --steel-hi: #F4F6F3;
  --steel-mid: #B7C0BA;
  --steel-lo: #66736B;
  --shadow: 0 1px 2px rgba(20, 32, 25, .06), 0 8px 24px rgba(20, 32, 25, .07);

  --font-display: "Montserrat", "Segoe UI", Arial, sans-serif;
  --font-body: "Source Sans 3", "Segoe UI", Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;

  --fs-hero: clamp(2.3rem, 5.4vw, 4.25rem);
  --fs-h2: clamp(1.7rem, 3.2vw, 2.5rem);
  --fs-h3: 1.25rem;
  --fs-body: 1.0625rem;
  --fs-small: .875rem;
  --fs-label: .75rem;

  --radius: 6px;
  --wrap: 1200px;
  --header-h: 72px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0E1511; --surface: #151F18; --cream: #18241C; --ink: #E8ECE5; --muted: #A2AFA6;
    --line: #2A3A30; --brand: #2E5038; --brand-deep: #1A2E21; --accent: #92C6A1; --on-brand: #F2F0E6;
    --on-brand-muted: #B5C6B9; --logo: #F7F4EC; --steel-hi: #DDE2DE; --steel-mid: #8F9A93; --steel-lo: #4D5A52;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.35);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #0E1511; --surface: #151F18; --cream: #18241C; --ink: #E8ECE5; --muted: #A2AFA6;
  --line: #2A3A30; --brand: #2E5038; --brand-deep: #1A2E21; --accent: #92C6A1; --on-brand: #F2F0E6;
  --on-brand-muted: #B5C6B9; --logo: #F7F4EC; --steel-hi: #DDE2DE; --steel-mid: #8F9A93; --steel-lo: #4D5A52;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.35);
  color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body::before {
  content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px);
  z-index: 60; background: var(--surface);
}
img, svg { max-width: 100%; }
[hidden] { display: none !important; }
img { height: auto; display: block; }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.15;
  margin: 0;
  text-wrap: balance;
  letter-spacing: -.01em;
}
h1 { font-size: var(--fs-hero); font-weight: 700; letter-spacing: -.025em; }
h2 { font-size: var(--fs-h2); font-weight: 700; }
h3 { font-size: var(--fs-h3); font-weight: 600; line-height: 1.25; }
p { margin: 0; }
.prose p + p, .prose p + ul, .prose ul + p, .prose table + p { margin-top: 1em; }
.lead { font-size: 1.25rem; line-height: 1.5; color: var(--muted); max-width: 62ch; }
.muted { color: var(--muted); }
.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.skip {
  position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--brand); color: var(--on-brand);
  padding: 10px 14px; border-radius: var(--radius);
}
.skip:focus { left: 16px; }

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 64px);
  margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
@media (min-width: 720px) {
  .wrap { padding-left: max(32px, env(safe-area-inset-left, 0px)); padding-right: max(32px, env(safe-area-inset-right, 0px)); }
}
.section { padding-block: clamp(56px, 8vw, 96px); }
.section--tight { padding-block: clamp(40px, 6vw, 72px); }
.section--cream { background: var(--cream); }
.section--brand { background: var(--brand); color: var(--on-brand); }
.section--brand h2, .section--brand h3 { color: var(--on-brand); }
.section--brand .muted, .section--brand .lead { color: var(--on-brand-muted); }
.section--brand a:not(.btn) { color: var(--on-brand); }

.eyebrow {
  display: inline-block; font-family: var(--font-display); font-size: var(--fs-label); font-weight: 600;
  letter-spacing: 1.6px; text-transform: uppercase; color: var(--accent); line-height: 1.4;
}
.section--brand .eyebrow { color: var(--on-brand-muted); }
.section-head { display: grid; gap: 14px; margin-bottom: clamp(28px, 4vw, 48px); max-width: 760px; }
.section-head--split { max-width: none; grid-template-columns: 1fr; align-items: end; }
@media (min-width: 900px) { .section-head--split { grid-template-columns: 1.1fr .9fr; gap: 40px; } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--font-display); font-weight: 600; font-size: .95rem;
  padding: 13px 22px; border-radius: var(--radius); border: 1.5px solid transparent;
  text-decoration: none; cursor: pointer; transition: transform .18s ease, background-color .18s ease, color .18s ease, border-color .18s ease;
  line-height: 1.2; white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); text-decoration: none; }
.btn:active { transform: translateY(0); }
.btn--primary { background: var(--brand); color: var(--on-brand); }
.btn--primary:hover { background: var(--brand-deep); }
.btn--ghost { border-color: var(--line); color: var(--ink); background: var(--surface); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--light { background: var(--on-brand); color: #223C2B; }
.btn--light:hover { background: #FFFFFF; }
.btn--outline-light { border-color: rgba(247, 244, 236, .5); color: var(--on-brand); }
.btn--outline-light:hover { border-color: var(--on-brand); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.arrow-link { font-family: var(--font-display); font-weight: 600; font-size: .92rem; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.arrow-link::after { content: "→"; transition: transform .2s ease; }
.arrow-link:hover::after { transform: translateX(4px); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .2s ease;
}
.site-header.is-scrolled { box-shadow: var(--shadow); }
.header-inner { display: flex; align-items: center; gap: 24px; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 8px; padding: 6px 0; text-decoration: none; color: var(--ink); flex: none; }
.brand-mark { width: 40px; height: 40px; display: block; flex: none; }
.brand-mark svg { width: 100%; height: 100%; fill: var(--logo); display: block; }
.brand-name { font-family: var(--font-display); font-weight: 600; font-size: 1.4rem; line-height: 1; letter-spacing: -.01em; color: var(--logo); }
.nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.nav a {
  font-family: var(--font-display); font-weight: 600; font-size: .9rem; color: var(--ink);
  text-decoration: none; padding: 8px 11px; border-radius: 4px; position: relative;
}
.nav a:not(.btn)::after {
  content: ""; position: absolute; left: 11px; right: 11px; bottom: 3px; height: 2px; background: var(--accent);
  transform: scaleX(0); transform-origin: left; transition: transform .22s ease;
}
.nav a:not(.btn):hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a[aria-current="page"] { color: var(--accent); }
.nav .btn { margin-left: 10px; padding: 10px 18px; }
.nav .btn--primary, .nav .btn--primary[aria-current="page"] { color: var(--on-brand); }
.nav-toggle {
  display: none; margin-left: auto; background: none; border: 1px solid var(--line); border-radius: var(--radius);
  width: 44px; height: 44px; cursor: pointer; color: var(--ink);
}
.nav-toggle span { display: block; width: 18px; height: 2px; background: currentColor; margin: 4px auto; transition: transform .2s ease, opacity .2s ease; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
@media (max-width: 1080px) {
  .nav-toggle { display: block; }
  .nav {
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--surface); border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    padding: 8px max(16px, env(safe-area-inset-right, 0px)) 18px max(16px, env(safe-area-inset-left, 0px));
    display: none;
  }
  .nav.is-open { display: flex; animation: drop .22s ease both; }
  .nav a { padding: 13px 4px; border-bottom: 1px solid var(--line); font-size: 1rem; }
  .nav a::after { display: none; }
  .nav .btn { margin: 14px 0 0; border-bottom: 0; }
}
@keyframes drop { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }

/* ---------- Breadcrumb + page hero ---------- */
.crumbs { font-size: var(--fs-small); color: var(--muted); }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: var(--steel-mid); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--accent); text-decoration: underline; }
.page-hero { padding-block: clamp(36px, 6vw, 72px) clamp(32px, 5vw, 56px); border-bottom: 1px solid var(--line); background: var(--paper); position: relative; overflow: hidden; }
.page-hero .wrap { display: grid; gap: 18px; position: relative; }
.page-hero h1 { font-size: clamp(2rem, 4.4vw, 3rem); line-height: 1.1; max-width: 20ch; }
.page-hero .lead { margin-top: 2px; }
.hex-deco { position: absolute; right: -40px; top: -30px; width: 300px; height: 300px; pointer-events: none; }
.hex-deco polygon { fill: none; stroke: var(--accent); stroke-width: .5; opacity: .45; }
@media (max-width: 720px) { .hex-deco { width: 200px; height: 200px; right: -70px; } }
.answer {
  border-left: 3px solid var(--brand); background: var(--surface); padding: 16px 20px; border-radius: 0 var(--radius) var(--radius) 0;
  max-width: 78ch; box-shadow: var(--shadow);
}
.answer strong { font-family: var(--font-display); font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); display: block; margin-bottom: 4px; }

/* ---------- Home hero ---------- */
.hero { position: relative; overflow: hidden; background: var(--paper); border-bottom: 1px solid var(--line); }
.hero-grid { display: grid; gap: 40px; align-items: center; padding-block: clamp(40px, 7vw, 96px); }
@media (min-width: 960px) { .hero-grid { grid-template-columns: 1.05fr .95fr; gap: 56px; } }
.hero h1 { line-height: 1.06; }
.hero h1 .line { display: block; }
.hero h1 .accent { color: var(--accent); }
.hero .lead { margin-top: 20px; }
.hero .btn-row { margin-top: 30px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 28px; font-size: var(--fs-small); color: var(--muted); }
.hero-meta span { display: inline-flex; align-items: center; gap: 8px; }
.hero-meta svg { width: 16px; height: 16px; color: var(--accent); }
.hero-art { position: relative; aspect-ratio: 1 / 1; max-width: 520px; width: 100%; justify-self: center; }
.hero-art svg { width: 100%; height: 100%; overflow: visible; }
.hero-tag {
  position: absolute; font-family: var(--font-mono); font-size: .72rem; letter-spacing: .06em;
  background: var(--surface); border: 1px solid var(--line); border-radius: 4px; padding: 6px 10px; box-shadow: var(--shadow);
  color: var(--ink); white-space: nowrap;
}
.hero-tag b { color: var(--accent); font-weight: 600; }
.hero-tag--a { left: 0; top: 12%; }
.hero-tag--b { right: 0; bottom: 14%; }
@media (prefers-reduced-motion: no-preference) {
  .hero h1 .line { animation: rise .8s cubic-bezier(.2,.7,.2,1) both; }
  .hero h1 .line:nth-child(2) { animation-delay: .1s; }
  .hero .lead, .hero .btn-row, .hero-meta { animation: rise .8s .22s cubic-bezier(.2,.7,.2,1) both; }
  .hero-tag { animation: fade 1s 1.1s ease both; }
  .bar-end { animation: pop .7s cubic-bezier(.2,.8,.2,1.15) both; animation-delay: calc(var(--i) * 28ms + .15s); transform-box: fill-box; transform-origin: center; }
  .shine { animation: sweep 6s 1.4s ease-in-out infinite; }
}
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: none; } }
@keyframes sweep { 0% { transform: translateX(-120%); } 45%, 100% { transform: translateX(120%); } }

/* ---------- Facts strip ---------- */
.facts { background: var(--brand); color: var(--on-brand); }
.facts-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 760px) { .facts-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.fact { padding: 26px 18px; border-left: 1px solid rgba(247, 244, 236, .16); }
.fact:first-child { border-left: 0; }
@media (max-width: 759px) { .fact:nth-child(odd) { border-left: 0; } .fact { border-top: 1px solid rgba(247, 244, 236, .16); } .fact:nth-child(-n+2) { border-top: 0; } .fact:last-child { grid-column: 1 / -1; } }
.fact b { display: block; font-family: var(--font-display); font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.fact span { display: block; margin-top: 8px; font-size: .9rem; color: var(--on-brand-muted); }

/* ---------- Grids and cards ---------- */
.grid { display: grid; gap: 20px; }
.grid--2 { grid-template-columns: 1fr; }
.grid--3 { grid-template-columns: 1fr; }
.grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 720px) { .grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.grid > * { min-width: 0; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(20px, 2.4vw, 28px); display: flex; flex-direction: column; gap: 12px;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
a.card { text-decoration: none; color: inherit; }
a.card:hover { border-color: var(--accent); transform: translateY(-3px); box-shadow: var(--shadow); }
.card p { color: var(--muted); font-size: .98rem; }
.card .arrow-link { margin-top: auto; padding-top: 6px; }

/* Profile cards with drawn cross-section and ruler */
.profile-card { position: relative; overflow: hidden; }
.profile-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.profile-icon { width: 56px; height: 56px; flex: none; }
.profile-range { font-family: var(--font-mono); font-size: 1.35rem; font-weight: 500; color: var(--ink); letter-spacing: -.02em; }
.profile-range small { font-size: .78rem; color: var(--muted); margin-left: 4px; }
.ruler { margin-top: 6px; }
.ruler-track { position: relative; height: 10px; background: repeating-linear-gradient(90deg, var(--line) 0 1px, transparent 1px 10%); border-bottom: 1px solid var(--steel-mid); }
.ruler-fill { position: absolute; top: 0; bottom: -1px; left: var(--from); width: var(--span); background: var(--brand); border-radius: 2px 2px 0 0; transform-origin: left; }
@media (prefers-reduced-motion: no-preference) { .ruler-fill { animation: grow 1s .3s cubic-bezier(.2,.7,.2,1) both; } }
@keyframes grow { from { transform: scaleX(0); } to { transform: none; } }
.ruler-scale { display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: .68rem; color: var(--muted); margin-top: 4px; }

/* Grade family blocks */
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  font-family: var(--font-mono); font-size: .8rem; font-weight: 500; letter-spacing: .01em;
  padding: 4px 9px; border-radius: 3px; background: var(--paper); border: 1px solid var(--line); color: var(--ink);
  white-space: nowrap; transition: background-color .2s ease, color .2s ease, border-color .2s ease, opacity .2s ease;
}
.family { display: grid; gap: 14px; padding: 22px 0; border-top: 1px solid var(--line); }
@media (min-width: 820px) { .family { grid-template-columns: 260px 1fr; gap: 32px; align-items: start; } }
.family h3 { display: flex; align-items: baseline; gap: 10px; }
.family h3 .count { font-family: var(--font-mono); font-size: .78rem; color: var(--muted); font-weight: 500; }
.family p { color: var(--muted); font-size: .97rem; margin-top: 6px; }

/* Process steps */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; counter-reset: step; }
@media (min-width: 900px) { .steps--row { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.steps > li { counter-increment: step; position: relative; padding: 22px 18px 22px 0; border-top: 2px solid var(--line); }
.steps > li::before {
  content: counter(step, decimal-leading-zero); display: block; font-family: var(--font-mono); font-size: .78rem;
  color: var(--accent); margin-bottom: 10px; letter-spacing: .08em;
}
.steps > li::after { content: ""; position: absolute; top: -2px; left: 0; width: 34px; height: 2px; background: var(--brand); transition: width .4s ease; }
.steps > li:hover::after { width: 100%; }
.steps h3 { font-size: 1.02rem; }
.steps p { color: var(--muted); font-size: .94rem; margin-top: 6px; }
.section--brand .steps > li { border-top-color: rgba(247, 244, 236, .2); }
.section--brand .steps > li::after { background: var(--on-brand); }
.section--brand .steps > li::before { color: var(--on-brand-muted); }
.section--brand .steps p { color: var(--on-brand-muted); }
.steps--detail > li { display: grid; gap: 8px; padding: 26px 0; }
@media (min-width: 820px) { .steps--detail > li { grid-template-columns: 90px 260px 1fr; gap: 24px; align-items: start; } .steps--detail > li::before { margin: 2px 0 0; } }

/* Industry tiles */
.industry { display: flex; flex-direction: column; gap: 10px; }
.industry-icon { width: 42px; height: 42px; color: var(--accent); }
.industry .chips { margin-top: 4px; }
.industry .chip { font-size: .72rem; padding: 3px 7px; }

/* Split feature */
.split { display: grid; gap: 36px; align-items: center; }
@media (min-width: 920px) { .split { grid-template-columns: 1fr 1fr; gap: 64px; } }
.split > * { min-width: 0; }
.checks { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 28px; }
.checks li::before {
  content: ""; position: absolute; left: 3px; top: 5px; width: 6px; height: 12px;
  border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent); transform: rotate(40deg);
}
.section--brand .checks li::before { border-color: var(--on-brand); }

/* ---------- Calculator ---------- */
.calc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 3vw, 32px); box-shadow: var(--shadow); color: var(--ink); }
.calc-fields { display: grid; gap: 16px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.calc-fields .full { grid-column: 1 / -1; }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label {
  display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 8px; cursor: pointer;
  border: 1.5px solid var(--line); border-radius: var(--radius); font-family: var(--font-display); font-weight: 600; font-size: .85rem;
  transition: border-color .18s ease, background-color .18s ease, color .18s ease;
}
.seg label svg { width: 28px; height: 28px; }
.seg input:checked + label { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 9%, var(--surface)); color: var(--accent); }
.seg input:focus-visible + label { outline: 3px solid var(--accent); outline-offset: 2px; }
.field { display: grid; gap: 6px; align-content: start; }
.field label, .field .label { font-family: var(--font-display); font-weight: 600; font-size: .8rem; color: var(--ink); }
.field .hint { font-size: .8rem; color: var(--muted); }
input[type="number"], input[type="text"], input[type="email"], input[type="tel"], select, textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink); background: var(--paper);
  border: 1.5px solid var(--line); border-radius: var(--radius); padding: 11px 12px; min-height: 46px;
  transition: border-color .18s ease, background-color .18s ease;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); background: var(--surface); }
input.mono-input { font-family: var(--font-mono); }
textarea { min-height: 110px; resize: vertical; }
.calc-out { margin-top: 22px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.calc-out div { padding: 14px 16px; border-left: 1px solid var(--line); background: var(--paper); }
.calc-out div:first-child { border-left: 0; }
.calc-out span { display: block; font-size: .74rem; font-family: var(--font-display); font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.calc-out b { display: block; margin-top: 4px; font-family: var(--font-mono); font-size: clamp(1.05rem, 2.4vw, 1.5rem); font-weight: 500; font-variant-numeric: tabular-nums; color: var(--ink); overflow-wrap: anywhere; }
.calc-out .is-key { background: color-mix(in srgb, var(--brand) 10%, var(--surface)); }
.calc-out .is-key b { color: var(--accent); }
.calc-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; font-size: .85rem; color: var(--muted); }
.calc-formula { font-family: var(--font-mono); font-size: .8rem; }
@media (max-width: 520px) { .calc-out { grid-template-columns: 1fr; } .calc-out div { border-left: 0; border-top: 1px solid var(--line); } .calc-out div:first-child { border-top: 0; } }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { font-family: var(--font-display); font-size: .76rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: var(--paper); font-weight: 600; white-space: nowrap; }
tbody tr:last-child td, tbody tr:last-child th { border-bottom: 0; }
tbody tr { transition: background-color .15s ease; }
tbody tr:hover { background: color-mix(in srgb, var(--brand) 5%, var(--surface)); }
td.num, th.num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
td .chip { font-size: .76rem; }
.table-note { font-size: .82rem; color: var(--muted); margin-top: 10px; }

/* Grade selector */
.filter-bar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.filter-bar button {
  font: 600 .85rem var(--font-display); padding: 9px 14px; border-radius: var(--radius); cursor: pointer;
  background: var(--surface); color: var(--ink); border: 1.5px solid var(--line); transition: all .18s ease;
}
.filter-bar button:hover { border-color: var(--accent); }
.filter-bar button[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.grade-explorer.is-filtering .chip[data-uses] { opacity: .35; }
.grade-explorer.is-filtering .chip.is-match { opacity: 1; background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.filter-status { font-size: .9rem; color: var(--muted); min-height: 1.6em; }

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 20px 40px 20px 0; position: relative;
  font-family: var(--font-display); font-weight: 600; font-size: 1.02rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  font-family: var(--font-mono); font-size: 1.3rem; color: var(--accent); transition: transform .2s ease;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq .faq-body { padding: 0 0 22px; color: var(--muted); max-width: 75ch; }

/* ---------- Region schematic ---------- */
.region-map { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; }
.region-map svg { width: 100%; height: auto; display: block; }
.region-map .city-label { font-family: var(--font-display); font-size: 19px; font-weight: 600; fill: var(--ink); }
.region-map .city-sub { font-family: var(--font-mono); font-size: 14px; fill: var(--muted); }
.region-map text { paint-order: stroke; stroke: var(--surface); stroke-width: 6px; stroke-linejoin: round; }
.region-map .route { stroke: var(--accent); stroke-width: 1.6; fill: none; stroke-dasharray: 4 5; }
.region-map .dot { fill: var(--surface); stroke: var(--accent); stroke-width: 2.5; }
.region-map .hub { fill: var(--accent); }
.region-map .port { fill: var(--accent); }
@media (prefers-reduced-motion: no-preference) { .region-map .route { animation: dash 30s linear infinite; } }
@keyframes dash { to { stroke-dashoffset: -400; } }

/* ---------- Timeline ---------- */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
@media (min-width: 860px) { .timeline { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.timeline li { padding: 22px 20px 22px 0; border-top: 2px solid var(--line); position: relative; }
.timeline li::before { content: ""; position: absolute; top: -7px; left: 0; width: 12px; height: 12px; background: var(--brand); border-radius: 2px; }
.timeline .year { font-family: var(--font-mono); font-size: 1.6rem; font-weight: 500; color: var(--accent); }
.timeline p { color: var(--muted); margin-top: 6px; font-size: .97rem; }

/* People */
.person { display: grid; grid-template-columns: 64px 1fr; gap: 18px; align-items: start; }
.avatar { width: 64px; height: 64px; display: grid; place-items: center; background: var(--brand); color: var(--on-brand); font-family: var(--font-display); font-weight: 700; font-size: 1.2rem; border-radius: var(--radius); }

/* Photo slot (to be replaced by real factory photography) */
.photo-slot {
  aspect-ratio: 4 / 3; border-radius: var(--radius); position: relative; overflow: hidden; display: flex; align-items: flex-end;
  background:
    radial-gradient(circle at 30% 30%, rgba(255,255,255,.18), transparent 40%),
    linear-gradient(135deg, var(--brand), var(--brand-deep));
  color: var(--on-brand); padding: 16px; max-width: 100%;
}
.photo-slot svg { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .22; }
.photo-slot span { position: relative; font-family: var(--font-mono); font-size: .75rem; letter-spacing: .06em; background: rgba(0,0,0,.25); padding: 5px 9px; border-radius: 3px; }

/* ---------- Blog ---------- */
.post-card { padding: 0; overflow: hidden; }
.post-card .cover { aspect-ratio: 16 / 8; background: var(--brand); position: relative; overflow: hidden; }
.post-card .cover svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.post-card .body { padding: 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.post-meta { font-family: var(--font-mono); font-size: .74rem; color: var(--muted); letter-spacing: .04em; display: flex; flex-wrap: wrap; gap: 6px 14px; }
.post-card h3 { font-size: 1.12rem; line-height: 1.3; }
.article { max-width: 760px; }
.article h2 { font-size: clamp(1.4rem, 2.4vw, 1.75rem); margin-top: 1.8em; margin-bottom: .55em; }
.article h3 { margin-top: 1.4em; margin-bottom: .4em; }
.article p, .article li { color: var(--ink); max-width: 70ch; }
.article ul, .article ol { padding-left: 1.2em; }
.article li + li { margin-top: .4em; }
.article .table-wrap { margin: 1.2em 0; }
.article-layout { display: grid; gap: 40px; }
@media (min-width: 1040px) { .article-layout { grid-template-columns: minmax(0, 1fr) 300px; gap: 64px; } }
.article-layout > * { min-width: 0; }
.aside-card { position: sticky; top: calc(var(--header-h) + 24px); display: grid; gap: 16px; }
.formula { font-family: var(--font-mono); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; font-size: .95rem; overflow-x: auto; white-space: nowrap; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; gap: 32px; }
@media (min-width: 980px) { .contact-grid { grid-template-columns: 1.15fr .85fr; gap: 48px; } }
.contact-grid > * { min-width: 0; }
.form-grid { display: grid; gap: 16px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 560px) { .form-grid, .calc-fields { grid-template-columns: 1fr; } }
.field .req { color: var(--accent); }
.field-error { font-size: .8rem; color: #B3261E; display: none; }
.is-invalid + .field-error { display: block; }
.is-invalid { border-color: #B3261E !important; }
.rfq-ready { margin-top: 20px; border: 1.5px solid var(--brand); border-radius: var(--radius); padding: 20px; background: color-mix(in srgb, var(--brand) 6%, var(--surface)); display: grid; gap: 12px; }
.rfq-ready pre { margin: 0; white-space: pre-wrap; font-family: var(--font-mono); font-size: .82rem; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; max-height: 220px; overflow: auto; }
.info-block { display: grid; gap: 4px; padding: 18px 0; border-top: 1px solid var(--line); }
.info-block:first-child { border-top: 0; padding-top: 0; }
.info-block h3 { font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.info-block p, .info-block a { font-size: 1.02rem; }
.copyable { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.copy-btn { font: 600 .72rem var(--font-display); letter-spacing: .06em; text-transform: uppercase; padding: 4px 8px; border-radius: 3px; border: 1px solid var(--line); background: var(--paper); color: var(--muted); cursor: pointer; }
.copy-btn:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- CTA band ---------- */
.cta-band { position: relative; overflow: hidden; }
.cta-band .wrap { display: grid; gap: 24px; align-items: center; position: relative; }
@media (min-width: 900px) { .cta-band .wrap { grid-template-columns: 1.3fr auto; gap: 48px; } }
.cta-phone { color: var(--on-brand); font-size: 1rem; letter-spacing: .02em; }

/* ---------- Footer ---------- */
.site-footer { background: var(--brand-deep); color: var(--on-brand-muted); padding-block: 56px 28px; font-size: .95rem; }
.site-footer a { color: var(--on-brand); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid { display: grid; gap: 32px; grid-template-columns: 1fr; }
@media (min-width: 720px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } }
@media (min-width: 1040px) { .footer-grid { grid-template-columns: 1.6fr 1fr 1fr 1.3fr; } }
.footer-grid h2 { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--on-brand); font-weight: 600; margin-bottom: 14px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-logo { display: inline-block; padding: 8px 0; }
.footer-logo img { width: 176px; height: auto; }
.site-footer .tagline { font-family: var(--font-display); font-weight: 600; color: var(--on-brand); font-size: 1.05rem; }
.site-footer .brand { color: var(--on-brand); }
.site-footer .brand-mark { background: var(--on-brand); }
.site-footer .brand-mark svg { fill: #385F44; }
.site-footer .brand-name small { color: var(--on-brand-muted); }
.footer-bottom { margin-top: 44px; padding-top: 22px; border-top: 1px solid rgba(247, 244, 236, .14); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: .85rem; }

/* ---------- Floating + mobile actions ---------- */
.wa-float {
  position: fixed; right: calc(20px + env(safe-area-inset-right, 0px)); bottom: calc(20px + env(safe-area-inset-bottom, 0px)); z-index: 40;
  width: 56px; height: 56px; border-radius: var(--radius); background: var(--brand); color: var(--on-brand); border: 1px solid rgba(247, 244, 236, .25); display: grid; place-items: center;
  box-shadow: 0 8px 24px rgba(0,0,0,.22); transition: transform .2s ease;
}
.wa-float:hover { transform: scale(1.07); }
.wa-float svg { width: 28px; height: 28px; }
.mobile-bar { display: none; }
@media (max-width: 760px) {
  .wa-float { display: none; }
  .mobile-bar {
    display: grid; grid-template-columns: repeat(3, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 45;
    background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(0,0,0,.08);
    padding: 8px max(10px, env(safe-area-inset-right, 0px)) calc(8px + env(safe-area-inset-bottom, 0px)) max(10px, env(safe-area-inset-left, 0px));
    gap: 8px;
  }
  .mobile-bar a { display: flex; flex-direction: column; align-items: center; gap: 2px; font: 600 .74rem var(--font-display); color: var(--ink); text-decoration: none; padding: 6px; border-radius: var(--radius); }
  .mobile-bar a svg { width: 20px; height: 20px; color: var(--accent); }
  .mobile-bar a.is-primary { background: var(--brand); color: var(--on-brand); }
  .mobile-bar a.is-primary svg { color: var(--on-brand); }
  body { padding-bottom: calc(70px + env(safe-area-inset-bottom, 0px)); }
}

/* ---------- Scroll reveal (content stays readable at rest) ---------- */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .reveal { animation: reveal linear both; animation-timeline: view(); animation-range: entry 5% entry 85%; }
  }
}
@keyframes reveal { from { opacity: .55; transform: translateY(24px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}


/* ---------- Photography (from company brochure) ---------- */
.hero-photo { position: relative; aspect-ratio: 1 / 1; max-width: 540px; width: 100%; justify-self: center; }
.hero-photo .hex-outline { position: absolute; inset: -4%; width: 108%; height: 108%; overflow: visible; }
.hero-photo .hex-outline polygon { fill: none; stroke: var(--accent); opacity: .5; stroke-width: .4; stroke-dasharray: 1.2 2; vector-effect: non-scaling-stroke; }
.hero-photo .hexframe {
  position: absolute; inset: 0; overflow: hidden; background: var(--brand-deep);
  clip-path: polygon(25% 6.7%, 75% 6.7%, 100% 50%, 75% 93.3%, 25% 93.3%, 0 50%);
}
.hero-photo .hexframe img { width: 100%; height: 100%; object-fit: cover; }
.hero-photo .hexframe::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, transparent 38%, rgba(255,255,255,.32) 50%, transparent 62%);
  transform: translateX(-120%);
}
@media (prefers-reduced-motion: no-preference) {
  .hero-photo .hexframe { animation: heroIn 1s .1s cubic-bezier(.2,.8,.2,1) both; }
  .hero-photo .hexframe img { animation: slowZoom 18s ease-out both; }
  .hero-photo .hexframe::after { animation: sweep 7s 1.3s ease-in-out infinite; }
}
@keyframes heroIn { from { opacity: 0; transform: scale(.9) rotate(-4deg); } to { opacity: 1; transform: none; } }
@keyframes slowZoom { from { transform: scale(1.12); } to { transform: scale(1); } }

.profile-photo {
  aspect-ratio: 2 / 1; display: grid; place-items: center; border-radius: var(--radius); overflow: hidden;
  background: radial-gradient(ellipse at 50% 65%, #FFFFFF 0%, #EEF0EC 70%, #E3E7E1 100%);
}
.profile-photo img { width: 86%; height: 86%; object-fit: contain; transition: transform .45s cubic-bezier(.2,.7,.2,1); }
a.card:hover .profile-photo img { transform: scale(1.05) translateY(-3px); }
.profile-photo--lg { aspect-ratio: 16 / 9; border: 1px solid var(--line); }
.profile-card .profile-top h3 { font-size: 1.15rem; }

.photo { margin: 0; border-radius: var(--radius); overflow: hidden; position: relative; background: var(--brand-deep); max-width: 100%; }
.photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s cubic-bezier(.2,.7,.2,1); }
.photo:hover img { transform: scale(1.04); }
.photo figcaption {
  position: absolute; left: 12px; bottom: 12px; right: 12px; width: fit-content; max-width: calc(100% - 24px);
  font-family: var(--font-mono); font-size: .74rem; letter-spacing: .04em; color: #F7F4EC;
  background: rgba(20, 32, 25, .78); padding: 5px 9px; border-radius: 3px;
}
.photo--wide { aspect-ratio: 3 / 2; }
.photo--tall { aspect-ratio: 4 / 5; }
.photo--square { aspect-ratio: 1 / 1; }

.mills { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.mills li {
  flex: 1 1 150px; max-width: 230px; height: 112px; display: grid; place-items: center; padding: 16px 18px;
  background: #FFFFFF; border: 1px solid var(--line); border-radius: var(--radius); transition: transform .2s ease, box-shadow .2s ease;
}
.mills li:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.mills img { max-height: 80px; max-width: 100%; width: auto; object-fit: contain; }

.apps { display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 720px) { .apps { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .apps { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.app {
  display: flex; align-items: center; gap: 12px; padding: 16px 18px; min-width: 0;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  font-family: var(--font-display); font-weight: 600; font-size: .95rem; color: var(--ink); text-decoration: none;
  transition: border-color .2s ease, transform .2s ease, background-color .2s ease;
}
.app svg { width: 28px; height: 28px; flex: none; color: var(--accent); transition: transform .3s ease; }
.app:hover { border-color: var(--accent); transform: translateY(-2px); }
.app:hover svg { transform: rotate(-8deg) scale(1.1); }

.gallery { display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 900px) { .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.gallery .photo { background: #050505; }

.cert { display: grid; gap: 32px; align-items: start; }
@media (min-width: 900px) { .cert { grid-template-columns: 340px minmax(0, 1fr); gap: 56px; } }
.cert > * { min-width: 0; }
.cert-img { display: block; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); max-width: 360px; transition: transform .25s ease; }
.cert-img:hover { transform: translateY(-3px) rotate(-.5deg); }
.cert th[scope="row"] { width: 34%; font-family: var(--font-display); font-size: .85rem; color: var(--muted); font-weight: 600; }

/* ---------- Technical drawings (brand signature: steel tones, green highlights, mono dimensions) ---------- */
.drawing { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.drawing--lg { max-width: 640px; }
.td { width: 100%; height: auto; display: block; }
.td-grid { stroke: var(--line); stroke-width: .6; }
.td-edge { stroke: var(--accent); stroke-width: 1.6; transition: stroke-width .3s ease; }
.td-centre { stroke: var(--steel-lo); stroke-width: .8; stroke-dasharray: 10 3 2 3; fill: none; }
.td-ext { stroke: var(--muted); stroke-width: .8; fill: none; }
.td-dim { stroke: var(--ink); stroke-width: 1; fill: none; }
.td-arrow { fill: var(--ink); }
.td-face { stroke: #66736B; stroke-width: 1; fill: none; opacity: .7; }
.td-removed { fill: none; stroke: var(--accent); stroke-width: 1.2; stroke-dasharray: 4 3; }
.td-text { font-family: var(--font-mono); font-size: 13px; font-weight: 500; fill: var(--ink); }
.td-text--muted { fill: var(--muted); }
a.card:hover .td-edge { stroke-width: 2.4; }
.statement { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.25rem, 2.2vw, 1.6rem); line-height: 1.4; color: var(--on-brand); max-width: 34ch; }

/* OEM supply chain name tiles (text only, no third-party logos) */
.section--rule { border-top: 1px solid var(--line); }
.oems { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px; }
.oems li {
  flex: 1 1 150px; min-height: 84px; display: flex; flex-direction: column; justify-content: center; gap: 2px;
  padding: 14px 18px; background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--brand);
  border-radius: var(--radius); transition: transform .2s ease, border-color .2s ease;
}
.oems li:hover { transform: translateY(-2px); border-color: var(--accent); }
.oem-name { font-family: var(--font-display); font-weight: 600; font-size: 1rem; line-height: 1.25; color: var(--ink); }
.oem-sub { font-family: var(--font-mono); font-size: .75rem; color: var(--muted); }

/* Utilities */
.stack-sm > * + * { margin-top: 10px; }
.stack > * + * { margin-top: 18px; }
.mt-l { margin-top: 36px; }
.center { text-align: center; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
