/* ── The sheet ────────────────────────────────────────────────────────────
   Shared across every forgedsolutions.ai marketing page. Three layers, the
   way a drawing is actually made: construction lines in non-photo blue (the
   blue that never reproduced when a print was copied), finished linework in
   graphite ink, and one oxide accent reserved for the things that are hot —
   live status, revision marks, an activated node. Nothing else gets colour. */
:root {
  --sheet:        #FAFAF7;
  --sheet-2:      #ECEBE5;
  --sheet-3:      #DEDCD3;
  --ink:          #090B0C;
  --ink-soft:     #262B2E;
  --dim:          #52585C;
  --rule:         #B7B4AA;
  --rule-strong:  #838075;
  --construction: #4A80A0;
  --oxide:        #B8380F;
  --oxide-ink:    #7A2A10;
  --live:         #1C5C3A;

  --f-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --f-body:    "Source Serif 4", Georgia, "Times New Roman", serif;
  --f-mono:    "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --measure: 62ch;
  --edge: clamp(14px, 3.2vw, 34px);

  /* Brushed-metal hairline texture — layered as an extra background-image
     alongside each surface's own fill, never a standalone class, since a
     second `background` declaration would just replace the first instead
     of stacking with it. Reads as faint tooling marks on light or dark. */
  --brushed-tex:
    repeating-linear-gradient(
      115deg,
      rgba(255,255,255,.07) 0px, rgba(255,255,255,.07) 1px,
      transparent 1px, transparent 3px,
      rgba(0,0,0,.05) 3px, rgba(0,0,0,.05) 4px,
      transparent 4px, transparent 7px
    );
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --sheet:        #08090A;
    --sheet-2:      #131517;
    --sheet-3:      #1B1E21;
    --ink:          #FAFBFA;
    --ink-soft:     #D8DBDC;
    --dim:          #9BA1A5;
    --rule:         #2F343A;
    --rule-strong:  #4E5560;
    --construction: #74A6C2;
    --oxide:        #FF8A4C;
    --oxide-ink:    #FF8A4C;
    --live:         #6FCC9A;
  }
}
:root[data-theme="dark"] {
  --sheet:        #08090A;
  --sheet-2:      #131517;
  --sheet-3:      #1B1E21;
  --ink:          #FAFBFA;
  --ink-soft:     #D8DBDC;
  --dim:          #9BA1A5;
  --rule:         #2F343A;
  --rule-strong:  #4E5560;
  --construction: #74A6C2;
  --oxide:        #FF8A4C;
  --oxide-ink:    #FF8A4C;
  --live:         #6FCC9A;
}

/* ── Texture & accent utilities ──────────────────────────────────────────
   Hex, brushed metal, and bloom — the "forged + space-age" layer on top of
   the drafting sheet. Pure CSS/SVG, no dependency, theme-aware via var(). */

/* A faint field of hexagon outlines behind a panel — one hex, safely
   inscribed with margin inside its own tile so there is no cross-tile
   seam to get wrong. Applied as a ::before so it never fights the
   panel's own background-image (the brushed texture, a gradient, etc). */
/* isolation: isolate scopes the pseudo-element's negative z-index to this
   box alone — without it, an absolutely-positioned ::before paints ABOVE
   static in-flow content regardless of DOM order (position:absolute
   descendants paint after static ones per the stacking spec), which would
   put this "background" texture on top of real text instead of behind it. */
.hex-field { position: relative; isolation: isolate; }
.hex-field::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: var(--construction);
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3E%3Cpath d='M24 15L19.5 22.794 10.5 22.794 6 15 10.5 7.206 19.5 7.206Z' fill='none' stroke='black' stroke-width='1'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3E%3Cpath d='M24 15L19.5 22.794 10.5 22.794 6 15 10.5 7.206 19.5 7.206Z' fill='none' stroke='black' stroke-width='1'/%3E%3C/svg%3E");
  -webkit-mask-size: 30px 30px;
  mask-size: 30px 30px;
  -webkit-mask-repeat: repeat;
  mask-repeat: repeat;
  opacity: .07;
}

/* A small solid hex marker — the one deliberate "hex like the Grizzly
   mark" nod, used as a bullet ahead of an eyebrow or a code label. */
.hex-bullet {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 7px;
  vertical-align: middle;
  background: var(--oxide);
  clip-path: polygon(25% 0%, 75% 0%, 100% 50%, 75% 100%, 25% 100%, 0% 50%);
}

/* Construction-line corner brackets — like crop marks on a technical
   drawing, or a targeting reticle. Two short line segments per corner,
   each its own background layer; no trig, no SVG. */
.rays { position: relative; isolation: isolate; }
.rays::before, .rays::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 34px;
  height: 34px;
  pointer-events: none;
  opacity: .55;
  background:
    linear-gradient(var(--construction), var(--construction)) top left / 1px 20px no-repeat,
    linear-gradient(90deg, var(--construction), var(--construction)) top left / 20px 1px no-repeat;
}
.rays::before { top: 12px; left: 12px; }
.rays::after  { bottom: 12px; right: 12px; transform: rotate(180deg); }

/* Stacked bloom — several drop-shadows at increasing blur/opacity read as
   a genuine glow; one shadow reads as a CSS-tutorial box-shadow. */
.glow-oxide { transition: filter .2s ease; }
.glow-oxide:hover, .glow-oxide:focus-visible {
  filter:
    drop-shadow(0 0 4px color-mix(in srgb, var(--oxide) 55%, transparent))
    drop-shadow(0 0 14px color-mix(in srgb, var(--oxide) 30%, transparent));
}

/* A dark "night shop floor" scope — re-declares the same token values
   already sitting in the dark-theme blocks above, so every component
   underneath (cards, prisms, dim-rules, eyebrows) recolors for free with
   zero per-child dark classes. If the visitor's OS is already dark these
   values equal the surroundings, so nothing double-darkens. Sits in
   normal flow like any other panel — same border+background convention
   as .constellation — rather than fighting the sheet's own frame border. */
.night {
  --sheet:        #08090A;
  --sheet-2:      #131517;
  --sheet-3:      #1B1E21;
  --ink:          #FAFBFA;
  --ink-soft:     #D8DBDC;
  --dim:          #9BA1A5;
  --rule:         #2F343A;
  --rule-strong:  #4E5560;
  --construction: #74A6C2;
  --oxide:        #FF8A4C;
  --oxide-ink:    #FF8A4C;
  --live:         #6FCC9A;
  position: relative;
  background: var(--sheet);
  border: 1px solid var(--rule-strong);
  padding: clamp(34px, 5.4vw, 58px) clamp(20px, 3.6vw, 40px);
}

/* A small live readout — must show something real (local clock, a fact
   already stated elsewhere on the page), never a fabricated counter. */
.telemetry {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .08em;
  color: var(--dim);
  margin-top: 22px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--sheet);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  background-image:
    linear-gradient(var(--construction) 1px, transparent 1px),
    linear-gradient(90deg, var(--construction) 1px, transparent 1px);
  background-size: 56px 56px, 56px 56px;
  background-position: 0 0, 0 0;
}
@supports (background-blend-mode: multiply) {
  body { background-blend-mode: normal; }
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: var(--sheet);
  opacity: .955;
  pointer-events: none;
  z-index: 0;
}
.sheet { position: relative; z-index: 1; }

/* ── Sheet border + zone ticks ─────────────────────────────────────────── */
.sheet { max-width: 1180px; margin: 0 auto; padding: 0 var(--edge); }
.frame {
  border: 1px solid var(--rule-strong);
  border-top: 0;
  padding: 0 clamp(18px, 3.6vw, 44px) clamp(28px, 4vw, 44px);
}
.zones {
  display: flex;
  align-items: stretch;
  border: 1px solid var(--rule-strong);
  border-bottom: 0;
  height: 26px;
  font-family: var(--f-mono);
  font-size: 9.5px;
  letter-spacing: .18em;
  color: var(--dim);
}
.zones span { flex: 1; display: grid; place-items: center; border-right: 1px solid var(--rule); }
.zones span:last-child { border-right: 0; }

/* ── Type scale ───────────────────────────────────────────────────────── */
h1, h2, h3 { font-family: var(--f-display); text-wrap: balance; margin: 0; }
h1 { font-size: clamp(38px, 6.6vw, 76px); line-height: 1.02; letter-spacing: -.028em; font-weight: 700; }
h2 { font-size: clamp(24px, 3vw, 34px); line-height: 1.1; letter-spacing: -.018em; font-weight: 600; }
h3 { font-size: 20px; line-height: 1.2; letter-spacing: -.012em; font-weight: 600; }
p { margin: 0; max-width: var(--measure); }

.eyebrow {
  font-family: var(--f-mono);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--dim);
  margin: 0;
}

/* ── Dimension-line divider ───────────────────────────────────────────── */
.dim-rule { display: flex; align-items: center; gap: 12px; margin: clamp(46px, 6.5vw, 78px) 0 clamp(22px, 3vw, 30px); }
.dim-rule::before, .dim-rule::after { content: ""; height: 1px; background: var(--rule-strong); flex: 1; }
.dim-rule::before { flex: 0 0 10px; }
.dim-rule .tick { width: 1px; height: 9px; background: var(--rule-strong); }

/* ── Wordmark header (every page) ────────────────────────────────────────*/
.wordmark { display: flex; align-items: baseline; gap: 12px; margin-bottom: clamp(34px, 6vw, 62px); flex-wrap: wrap; }
.wordmark b { font-family: var(--f-display); font-weight: 700; font-size: 15px; letter-spacing: .02em; }
.wordmark .llc { font-family: var(--f-mono); font-size: 10px; letter-spacing: .2em; color: var(--dim); text-transform: uppercase; }
.wordmark .back-link,
.wordmark .ops-link {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--dim);
  text-decoration: none;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 1px;
  transition: color .15s, border-color .15s;
}
.wordmark .ops-link { margin-left: auto; }
.wordmark .back-link:hover, .wordmark .ops-link:hover { color: var(--oxide); border-color: var(--oxide); }

.lede { font-size: clamp(18px, 2.1vw, 21px); color: var(--ink-soft); margin-top: 22px; max-width: 58ch; }
.hero-note { font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .06em; color: var(--dim); margin-top: 26px; max-width: 46ch; line-height: 1.7; }
.hero-note strong { color: var(--oxide-ink); font-weight: 500; }

a { color: var(--oxide-ink); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:focus-visible { outline: 2px solid var(--oxide); outline-offset: 3px; }

.status { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status.is-live { color: var(--live); }
.status.is-build { color: var(--oxide-ink); }

.traits { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 4px; list-style: none; margin-left: 0; padding-left: 0; }
.traits li { font-family: var(--f-mono); font-size: 10px; letter-spacing: .1em; color: var(--dim); border: 1px solid var(--rule-strong); padding: 3px 8px; }

/* ── Build spec (index) ──────────────────────────────────────────────── */
.spec { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: clamp(20px, 3vw, 38px); }
.spec div { display: flex; flex-direction: column; gap: 8px; }
.spec dt { font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--dim); }
.spec dd { margin: 0; font-size: 15.5px; color: var(--ink-soft); line-height: 1.55; }

/* ── Title block (every page) ────────────────────────────────────────── */
.title-block { margin-top: clamp(46px, 6.5vw, 78px); border: 1px solid var(--rule-strong); display: grid; grid-template-columns: 2fr 1fr 1fr; }
.title-block > div { border-right: 1px solid var(--rule); padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.title-block > div:last-child { border-right: 0; }
.tb-label { font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .2em; text-transform: uppercase; color: var(--dim); }
.tb-value { font-family: var(--f-display); font-size: 15px; font-weight: 600; letter-spacing: -.005em; overflow-wrap: anywhere; }
.tb-value.mono { font-family: var(--f-mono); font-weight: 400; font-size: 13px; letter-spacing: .04em; }

@media (max-width: 620px) {
  .title-block { grid-template-columns: 1fr 1fr; }
  .title-block > div:nth-child(1) { grid-column: 1 / -1; border-bottom: 1px solid var(--rule); }
  .zones span:nth-child(n+7) { display: none; }
}

/* ── Logo mark — the product's own reference render, shown flat, whole,
   and undistorted (background-size: contain; the source photo's own
   backdrop was pre-processed out via alpha keying, not cropped or
   covered). Static, not rotating: these are photographic 3D renders, not
   vector shapes — a flat image has no back face, so spinning one just
   looks like a paper cutout flipping edge-on rather than a solid object
   turning. Lights up on hover/focus/active instead, via a stacked
   drop-shadow bloom that (correctly, since drop-shadow respects alpha)
   traces the mark's actual silhouette rather than its bounding box. */
.logo-mark {
  --mark-size: 60px;
  display: block;
  width: var(--mark-size);
  height: var(--mark-size);
  background-image: var(--logo-img);
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  filter: drop-shadow(0 0 0 transparent);
  transition: filter .25s ease;
}
.node.is-hover .logo-mark,
.node.is-active .logo-mark,
.showcase-item:hover .logo-mark,
.showcase-item:focus-visible .logo-mark,
.logo-mark:hover {
  filter:
    drop-shadow(0 0 5px color-mix(in srgb, var(--oxide) 65%, transparent))
    drop-shadow(0 0 16px color-mix(in srgb, var(--oxide) 40%, transparent))
    brightness(1.12);
}
@media (prefers-reduced-motion: reduce) {
  .logo-mark { transition: none; }
}

/* ── Product page hero — shared by every anvil/forgedworks/forg3d/forge.html
   so the pattern lives in one place, not copy-pasted four times. Class is
   named -prism-stage from when it held the rotating housing; still just
   "the stage the logo mark sits on," so kept rather than churned. */
.product-hero { padding: clamp(40px, 6vw, 70px) 0 0; }
.product-hero-grid { display: flex; gap: clamp(28px, 5vw, 56px); align-items: center; flex-wrap: wrap; margin-top: clamp(24px, 4vw, 40px); }
.product-prism-stage { flex: 0 0 auto; display: grid; place-items: center; width: clamp(140px, 20vw, 220px); height: clamp(140px, 20vw, 220px); overflow: hidden; }
.product-prism-stage .logo-mark { --mark-size: min(76%, 168px); }
.product-hero-text { flex: 1 1 360px; min-width: 280px; }
.product-hero-text .eyebrow { margin-bottom: 10px; }
.product-hero-text .lede { margin-top: 16px; }

.why-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: clamp(16px, 2.4vw, 24px); margin-top: 20px; }
.why-card { border: 1px solid var(--rule); background-color: var(--sheet-2); background-image: var(--brushed-tex); padding: clamp(18px, 2.4vw, 24px); }
.why-card h3 { font-size: 16px; margin-bottom: 8px; }
.why-card p { color: var(--ink-soft); font-size: 15px; max-width: none; }

.feature-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1px; background: var(--rule); border: 1px solid var(--rule); margin-top: 20px; }
.feature-list > div { background-color: var(--sheet-2); background-image: var(--brushed-tex); padding: clamp(16px, 2.2vw, 22px); }
.feature-list dt { font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--oxide-ink); margin-bottom: 6px; }
.feature-list dd { margin: 0; color: var(--ink-soft); font-size: 14.5px; line-height: 1.5; }

.prose p + p { margin-top: 14px; }
.prose p { color: var(--ink-soft); font-size: 16.5px; line-height: 1.65; }

/* ── Showcase — the "flip through" body, one substantial section per
   product, vertical scroll-snap (proximity, not mandatory — never a
   forced/jarring snap). Lives inside a .night panel. ─────────────────── */
.showcase { display: flex; flex-direction: column; gap: clamp(26px, 4vw, 40px); margin-top: 22px; scroll-snap-type: y proximity; }
.showcase-item {
  display: flex;
  gap: clamp(24px, 4vw, 48px);
  align-items: center;
  flex-wrap: wrap;
  padding: clamp(20px, 3vw, 32px);
  border: 1px solid var(--rule);
  background-color: var(--sheet-2);
  background-image: var(--brushed-tex);
  scroll-snap-align: start;
  text-decoration: none;
  color: inherit;
}
.showcase-item .product-prism-stage { flex: 0 0 auto; width: clamp(130px, 15vw, 170px); height: clamp(130px, 15vw, 170px); overflow: hidden; }
.showcase-item .logo-mark { --mark-size: 110px; }
.showcase-text { flex: 1 1 320px; min-width: 260px; }
.showcase-code { font-family: var(--f-mono); font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--dim); display: flex; align-items: center; }
/* Explicit color, not inherited: .showcase-item sets color:inherit (so an
   unstyled child would fall back to whatever color the DOM inherited from
   OUTSIDE the .night scope, frozen at body — redeclaring the --ink custom
   property on .night doesn't retroactively update a `color` that was
   already resolved higher up the tree). Every other text node in this
   card (p, .showcase-code, .showcase-link) already sets its own color
   explicitly for the same reason; this was the one that got missed. */
.showcase-item h3 { font-size: clamp(20px, 2.4vw, 26px); margin-top: 8px; color: var(--ink); }
.showcase-item p { color: var(--ink-soft); font-size: 15.5px; margin-top: 10px; max-width: 54ch; }
.showcase-link {
  display: inline-block;
  margin-top: 14px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--oxide);
  border-bottom: 1px solid var(--oxide);
  padding-bottom: 2px;
}
.showcase-item:hover .showcase-link,
.showcase-item:focus-visible .showcase-link {
  filter: drop-shadow(0 0 4px color-mix(in srgb, var(--oxide) 55%, transparent)) drop-shadow(0 0 14px color-mix(in srgb, var(--oxide) 30%, transparent));
}
.showcase-item:focus-visible { outline: 2px solid var(--oxide); outline-offset: 4px; }

/* ── Solutions — provocation cards, not a feature matrix. ────────────── */
.solutions-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: clamp(16px, 2.4vw, 22px); margin-top: 20px; }
.solutions-card { border: 1px solid var(--rule); background-color: var(--sheet-2); background-image: var(--brushed-tex); padding: clamp(18px, 2.4vw, 24px); transition: border-color .2s ease; }
.solutions-card:hover { border-color: var(--oxide); }
.solutions-card .sol-q { display: block; font-family: var(--f-display); font-weight: 600; font-size: 16.5px; line-height: 1.35; color: var(--ink); }
.solutions-card p { margin-top: 10px; color: var(--dim); font-size: 13px; font-family: var(--f-mono); letter-spacing: .015em; line-height: 1.55; max-width: none; }

@media (max-width: 640px) {
  .showcase-item { flex-direction: column; align-items: flex-start; text-align: left; }
}
