/* ════════════════════════════════════════════════════════════════
   AZMX AI — sacred-geometry ornament layer
   Shared across every page. Loaded after site2.css.

   Provides:
   1. Sigil-row dividers between sections
   2. Ornament glyphs prepended to .eyebrow / .page-eyebrow / .kicker
   3. Corner ornaments on .alt / .final / .editorial-section
   4. Hero mandala backdrop (landing only — injected via inline SVG)
   5. Footer sigil row + rotating brand-mark accent
   6. Floating particle accents on hero

   All animations honor prefers-reduced-motion.
   ════════════════════════════════════════════════════════════════ */

/* ── Shared stroke / fill tokens ───────────────────────────────── */
.sg-stroke       { stroke: #1a1410; fill: none; stroke-width: .9; stroke-linecap: round; stroke-linejoin: round; }
.sg-stroke-2     { stroke: #1a1410; fill: none; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.sg-stroke-amber { stroke: #d97757; fill: none; stroke-width: 1; }
.sg-stroke-dotted{ stroke: #1a1410; fill: none; stroke-width: .8; stroke-dasharray: 2 4; }
.sg-dot          { fill: #1a1410; }
.sg-dot-amber    { fill: #d97757; }

/* ── Universal animation keyframes ─────────────────────────────── */
.sg-draw        { stroke-dasharray: 1600; stroke-dashoffset: 1600; animation: sg-draw 4s cubic-bezier(.22,.61,.36,1) forwards; }
.sg-draw-2      { animation-delay: .25s; }
.sg-draw-3      { animation-delay: .5s; }
.sg-draw-4      { animation-delay: .75s; }
.sg-draw-5      { animation-delay: 1s; }
.sg-draw-6      { animation-delay: 1.25s; }
.sg-spin-slow   { transform-origin: 50% 50%; animation: sg-spin 180s linear infinite; }
.sg-spin-med    { transform-origin: 50% 50%; animation: sg-spin 100s linear infinite reverse; }
.sg-spin-fast   { transform-origin: 50% 50%; animation: sg-spin 60s linear infinite; }
.sg-pulse       { animation: sg-pulse 5s cubic-bezier(.4,0,.6,1) infinite; transform-origin: 50% 50%; }
.sg-breathe     { animation: sg-breathe 9s cubic-bezier(.4,0,.6,1) infinite; transform-origin: 50% 50%; }

@keyframes sg-draw    { to { stroke-dashoffset: 0; } }
@keyframes sg-spin    { to { transform: rotate(360deg); } }
@keyframes sg-pulse   { 0%, 100% { opacity: .55; transform: scale(1); } 50% { opacity: 1; transform: scale(1.08); } }
@keyframes sg-breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.025); } }

/* ── Mandala backdrop — for any page that opts in via .hero ───── */
.sg-mandala {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: clamp(680px, 80vw, 1080px);
  height: clamp(680px, 80vw, 1080px);
  pointer-events: none;
  z-index: 0;
  opacity: .085;
  mix-blend-mode: multiply;
}
.sg-mandala svg { width: 100%; height: 100%; overflow: visible; }

/* Hero containers — make them stacking contexts so mandala sits behind */
.hero, .geom-hero, .page-hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.hero > .wrap,
.geom-hero > *:not(.sg-mandala):not(.sg-floaters),
.page-hero > *:not(.sg-mandala):not(.sg-floaters) {
  position: relative;
  z-index: 1;
}

/* Floating particles — depth + life over the hero */
.sg-floaters { position: absolute; inset: 0; pointer-events: none; z-index: 0; opacity: .35; }
.sg-floaters .f {
  position: absolute; width: 4px; height: 4px; border-radius: 50%;
  background: #d97757;
  animation: sg-float 14s ease-in-out infinite;
}
.sg-floaters .f:nth-child(1){ top:18%; left: 8%;  animation-delay: -2s; }
.sg-floaters .f:nth-child(2){ top:28%; right:12%; animation-delay: -5s;  background:#1a1410; opacity:.3; }
.sg-floaters .f:nth-child(3){ bottom:22%; left:14%; animation-delay: -8s; }
.sg-floaters .f:nth-child(4){ bottom:16%; right: 8%; animation-delay: -11s; background:#1a1410; opacity:.3; }
.sg-floaters .f:nth-child(5){ top:50%; left:4%; animation-delay: -3.5s; width:3px; height:3px; }
.sg-floaters .f:nth-child(6){ top:60%; right:5%; animation-delay: -6.5s; width:3px; height:3px; }
@keyframes sg-float {
  0%, 100% { transform: translate(0, 0) scale(1);     opacity: .35; }
  25%      { transform: translate(12px, -18px) scale(1.2); opacity: .8;  }
  50%      { transform: translate(-8px, -24px) scale(.8);  opacity: .5;  }
  75%      { transform: translate(6px,  10px) scale(1.1); opacity: .7;  }
}

/* ── Sigil-row divider ─────────────────────────────────────────── */
.sigil-row {
  display: flex; align-items: center; justify-content: center;
  gap: 22px; padding: 36px 0 30px;
  opacity: 0; transform: translateY(8px);
  transition: opacity .6s ease, transform .6s ease;
}
.sigil-row.in { opacity: 1; transform: none; }
.sigil-row .line {
  flex: 1; max-width: 220px; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0,0,0,.18), transparent);
}
.sigil-row .glyph {
  width: 22px; height: 22px; opacity: .42;
  transition: opacity .4s ease, transform .4s ease;
  cursor: default;
}
.sigil-row .glyph:hover { opacity: .85; transform: rotate(45deg); }
.sigil-row .glyph svg { width: 100%; height: 100%; }
.sigil-row .glyph .sg-stroke,
.sigil-row .glyph .sg-stroke-2 { stroke: #3a3540; stroke-width: 1; }
.sigil-row .glyph .sg-dot { fill: #3a3540; }

/* Special variants */
.sigil-row.dense { gap: 14px; }
.sigil-row.dense .glyph { width: 16px; height: 16px; }
.sigil-row.amber .glyph .sg-stroke,
.sigil-row.amber .glyph .sg-stroke-2 { stroke: #d97757; }
.sigil-row.amber .glyph .sg-dot { fill: #d97757; }

/* ── Eyebrow ornament — universal selector across page types ──── */
.eyebrow .sg-orn,
.page-eyebrow .sg-orn,
.kicker .sg-orn,
.bay .sg-orn,
.ix .sg-orn {
  display: inline-block; vertical-align: middle;
  width: 14px; height: 14px; margin-right: 8px;
  opacity: .55;
}
.eyebrow .sg-orn svg,
.page-eyebrow .sg-orn svg,
.kicker .sg-orn svg,
.bay .sg-orn svg,
.ix .sg-orn svg { width: 100%; height: 100%; }
.eyebrow .sg-orn .sg-stroke,
.page-eyebrow .sg-orn .sg-stroke,
.kicker .sg-orn .sg-stroke,
.bay .sg-orn .sg-stroke,
.ix .sg-orn .sg-stroke { stroke: currentColor; stroke-width: 1.2; fill: none; }
.eyebrow .sg-orn .sg-dot,
.page-eyebrow .sg-orn .sg-dot,
.kicker .sg-orn .sg-dot,
.bay .sg-orn .sg-dot,
.ix .sg-orn .sg-dot { fill: currentColor; }

/* ── Corner ornaments — on .alt / .final / .editorial-section ── */
.alt, .final, .editorial-section, .ed-cta { position: relative; }
.sg-corner {
  position: absolute;
  width: 56px; height: 56px;
  pointer-events: none;
  opacity: .14;
  z-index: 0;
}
.sg-corner svg { width: 100%; height: 100%; }
.sg-corner.tl { top: 18px; left:  18px; }
.sg-corner.tr { top: 18px; right: 18px; transform: scaleX(-1); }
.sg-corner.bl { bottom: 18px; left:  18px; transform: scaleY(-1); }
.sg-corner.br { bottom: 18px; right: 18px; transform: scale(-1, -1); }
.sg-corner .sg-stroke { stroke: #3a3540; stroke-width: 1.2; }
.sg-corner .sg-dot { fill: #3a3540; }
@media (max-width: 720px) { .sg-corner { display: none; } }

/* ── Footer sigil row + brand mark ─────────────────────────────── */
.footer-sigil {
  margin: 0;
  padding: 28px 0 22px;
  border-bottom: 1px solid rgba(0,0,0,.06);
}
.footer-sigil .glyph { opacity: .35; }
.footer-sigil .glyph:hover { opacity: .7; }
.footer-sigil .line {
  background: linear-gradient(90deg, transparent, rgba(0,0,0,.1), transparent);
}

/* Tiny breathing mandala next to the footer brand */
footer.site .sg-brand-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px;
  margin-left: 10px;
  vertical-align: middle;
  opacity: .55;
}
footer.site .sg-brand-mark svg { width: 100%; height: 100%; }
footer.site .sg-brand-mark .sg-stroke { stroke: currentColor; stroke-width: 1; }
footer.site .sg-brand-mark .sg-dot { fill: currentColor; }

/* Tiny ornaments on footer column headers */
footer.site h4 .sg-orn,
footer.site .bcol h4 .sg-orn {
  display: inline-block; vertical-align: middle;
  width: 12px; height: 12px; margin-right: 6px;
  opacity: .5;
}
footer.site h4 .sg-orn svg { width: 100%; height: 100%; }
footer.site h4 .sg-orn .sg-stroke { stroke: currentColor; stroke-width: 1.2; fill: none; }
footer.site h4 .sg-orn .sg-dot { fill: currentColor; }

/* ════════════════════════════════════════════════════════════════
   PER-LINK FOOTER GLYPHS
   Every footer link gets its own sacred-geometry mini-glyph (14px)
   prepended by sacred.js. The glyph rotates / pulses / flips /
   draws-in on hover, with a different effect per link position so
   no two adjacent links animate the same way.
   ════════════════════════════════════════════════════════════════ */
footer.site li { display: flex; align-items: center; gap: 9px; line-height: 1.4; }
footer.site .fg {
  display: inline-flex; align-items: center; justify-content: center;
  width: 15px; height: 15px;
  color: var(--ink-3);
  opacity: .55;
  flex-shrink: 0;
  transition: color .22s ease, opacity .22s ease, transform .35s cubic-bezier(.22,.61,.36,1);
}
footer.site .fg svg { width: 100%; height: 100%; overflow: visible; }
footer.site .fg svg path,
footer.site .fg svg circle,
footer.site .fg svg rect,
footer.site .fg svg polygon,
footer.site .fg svg line,
footer.site .fg svg ellipse {
  stroke: currentColor; fill: none; stroke-width: 1.2;
  stroke-linecap: round; stroke-linejoin: round;
}
footer.site .fg svg .dot { fill: currentColor; stroke: none; }
footer.site li:hover .fg { color: #d97757; opacity: 1; }
footer.site li a:hover { color: #d97757; }

/* Per-position animation rotation — 6 distinct hover effects
   cycled across every 6 links so adjacent items feel varied. */
footer.site li:nth-child(6n+1):hover .fg { transform: rotate(180deg); }
footer.site li:nth-child(6n+2):hover .fg { transform: scale(1.35); }
footer.site li:nth-child(6n+3):hover .fg { transform: rotate(-90deg) scale(1.2); }
footer.site li:nth-child(6n+4):hover .fg { transform: scaleX(-1) rotate(45deg); }
footer.site li:nth-child(6n+5):hover .fg { transform: rotate(360deg); transition-duration: .65s; }
footer.site li:nth-child(6n):hover .fg   { transform: translateY(-2px) scale(1.15); }

/* Stroke draw-in on viewport entry — animated by sacred.js adding
   .fg-in once the footer scrolls into view, with a staggered delay
   so the row "ticks in" like a constellation. */
footer.site .fg svg [data-draw] {
  stroke-dasharray: 60;
  stroke-dashoffset: 60;
  transition: stroke-dashoffset 1.4s cubic-bezier(.22,.61,.36,1);
}
footer.site.fg-in .fg svg [data-draw] { stroke-dashoffset: 0; }
footer.site.fg-in .fg:nth-child(2n) svg [data-draw] { transition-delay: 60ms; }
footer.site.fg-in .fg:nth-child(3n) svg [data-draw] { transition-delay: 120ms; }
footer.site.fg-in .fg:nth-child(4n) svg [data-draw] { transition-delay: 180ms; }
footer.site.fg-in .fg:nth-child(5n) svg [data-draw] { transition-delay: 240ms; }

/* External-link arrow remains visible even with the glyph prepended */
footer.site li a { display: inline-flex; align-items: center; gap: 4px; }

@media (prefers-reduced-motion: reduce) {
  footer.site .fg { transition: none; }
  footer.site li:hover .fg { transform: none; }
  footer.site .fg svg [data-draw] { stroke-dashoffset: 0 !important; transition: none; }
}

/* ════════════════════════════════════════════════════════════════
   MOTION VOCABULARY (universal)
   Hover lift on cards, scroll-triggered fade-up, and a starting
   point for count-up numbers in the ticker.
   ════════════════════════════════════════════════════════════════ */

/* Card hover lift — applies to every kind of card we have */
.case-grid .case,
.cards .c,
.bento .tile,
.case-grid > a.case,
.cards > a.c,
main .step,
main .board .col,
main .flow3 .step,
.editorial-section .num-list li {
  transition: transform .28s cubic-bezier(.22,.61,.36,1),
              border-color .28s cubic-bezier(.22,.61,.36,1),
              box-shadow .28s cubic-bezier(.22,.61,.36,1);
}
.case-grid .case:hover,
.cards .c:hover,
.bento .tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px -24px rgba(26,20,16,.18);
}
.case-grid > a.case:hover,
.cards > a.c:hover {
  border-color: #d97757 !important;
}

/* Scroll-reveal — entries fade up + un-blur. The .in class is
   added by sacred.js when the element enters the viewport. */
.sg-reveal {
  opacity: 0;
  transform: translateY(14px);
  filter: blur(4px);
  transition: opacity .65s cubic-bezier(.22,.61,.36,1),
              transform .65s cubic-bezier(.22,.61,.36,1),
              filter .65s cubic-bezier(.22,.61,.36,1);
}
.sg-reveal.in {
  opacity: 1; transform: none; filter: none;
}
.sg-reveal.in.delay-1 { transition-delay: 60ms; }
.sg-reveal.in.delay-2 { transition-delay: 120ms; }
.sg-reveal.in.delay-3 { transition-delay: 180ms; }
.sg-reveal.in.delay-4 { transition-delay: 240ms; }
.sg-reveal.in.delay-5 { transition-delay: 300ms; }

/* Count-up tickers — sacred.js animates strong→target via
   data-target. Tabular-nums prevents width jitter during count. */
.ticker .t-item strong,
main .stats .s strong,
main .price {
  font-variant-numeric: tabular-nums;
}

/* ── Secondary accent — deep teal for regulated/enterprise pills */
:root { --azmx-teal: #2a6b6b; }
.pill.teal,
.case-grid .case.teal .tag,
.tag.teal,
.industry-strip .col.teal span {
  color: var(--azmx-teal);
  border-color: rgba(42,107,107,.25);
}
.bay.teal { color: var(--azmx-teal); }

/* ════════════════════════════════════════════════════════════════
   PRICING COMPARISON MATRIX — every feature × every tier
   - Sticky tier header inside the matrix
   - Filter chips at top
   - Each ✓ is an SVG checkmark that stroke-draws when scrolled in
   - Row hover tints the row
   - Pro column gets a soft amber accent (most popular)
   - Enterprise column gets a teal accent (regulated/gov)
   ════════════════════════════════════════════════════════════════ */
.pm-wrap {
  max-width: 1180px;
  width: calc(100% - 56px);
  margin: 24px auto 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--bg-soft);
  overflow: hidden;
  position: relative;
  box-sizing: border-box;
}
.pm-chips {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  padding: 16px 22px; border-bottom: 1px solid var(--line);
  background: rgba(251,250,247,.94);
  position: sticky; top: 66px; z-index: 4;
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
}
.pm-chips button {
  font: inherit; font-size: 12.5px; padding: 7px 14px;
  border-radius: 999px; border: 1px solid var(--line);
  background: var(--bg-soft); color: var(--ink-2);
  cursor: pointer; transition: all .18s ease;
}
.pm-chips button:hover { border-color: var(--ink-3); color: var(--ink); }
.pm-chips button.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.pm-chips .pm-count { margin-left: auto; font-family: var(--mono); font-size: 12px; color: var(--ink-3); align-self: center; }

.pm-scroll { overflow-x: auto; }
.pm-table {
  width: 100%;
  min-width: 880px;
  border-collapse: collapse;
  font-size: 13.5px;
  table-layout: fixed; /* every column locks to its colgroup width */
}
/* Explicit column widths via :nth-child so every row aligns */
.pm-table col,
.pm-table th:nth-child(1), .pm-table td:nth-child(1) { width: 44%; }
.pm-table th:nth-child(2), .pm-table td:nth-child(2),
.pm-table th:nth-child(3), .pm-table td:nth-child(3),
.pm-table th:nth-child(4), .pm-table td:nth-child(4),
.pm-table th:nth-child(5), .pm-table td:nth-child(5) { width: 14%; }

.pm-table thead {
  position: sticky;
  top: 0; /* sticky inside the .pm-scroll container — not document */
  z-index: 3;
  background: var(--surface);
}
.pm-table th {
  padding: 18px 12px;
  text-align: center;
  vertical-align: middle;
  font-family: var(--mono); font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--ink-3); font-weight: 500;
  border-bottom: 1.5px solid var(--line);
  background: var(--surface);
}
.pm-table th:first-child {
  text-align: left;
  padding: 18px 18px 18px 22px;
  font-size: 11px;
}
.pm-table th .tier-name {
  display: block;
  font-size: 14px;
  color: var(--ink);
  font-weight: 600;
  letter-spacing: -.01em;
  margin: 0 0 3px;
  text-transform: none;
  font-family: inherit;
}
.pm-table th .tier-price {
  display: block;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: .04em;
  text-transform: none;
}
.pm-table th.col-pro { background: linear-gradient(180deg, rgba(217,119,87,.10), rgba(217,119,87,.04)); }
.pm-table th.col-pro .tier-name { color: #d97757; }
.pm-table th.col-ent { background: linear-gradient(180deg, rgba(42,107,107,.10), rgba(42,107,107,.04)); }
.pm-table th.col-ent .tier-name { color: #2a6b6b; }

.pm-table .group td {
  padding: 16px 22px;
  font-family: var(--mono); font-size: 10.5px;
  letter-spacing: .16em; text-transform: uppercase; color: var(--ink-3);
  background: linear-gradient(180deg, var(--surface) 0%, rgba(217,119,87,.04) 100%);
  border-bottom: 1px solid var(--line);
  border-top: 1.5px solid var(--line);
  font-weight: 600;
  text-align: left;
}
.pm-table .group td::before {
  content: "■"; margin-right: 10px; color: #d97757; font-size: 9px;
}

.pm-table tbody tr.row { transition: background .14s ease; }
.pm-table tbody tr.row:hover { background: rgba(217,119,87,.04); }
.pm-table tbody tr.row td {
  padding: 12px 12px;
  text-align: center;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  font-size: 13px;
  line-height: 1.35;
}
.pm-table tbody tr.row td:first-child {
  text-align: left;
  padding: 12px 18px 12px 22px;
  color: var(--ink);
  font-size: 13.5px;
}
.pm-table tbody tr.row td:first-child code { font-size: 12px; }
.pm-table tbody tr.row td.col-pro { background: rgba(217,119,87,.025); }
.pm-table tbody tr.row td.col-ent { background: rgba(42,107,107,.025); }
.pm-table tbody tr.row:hover td.col-pro { background: rgba(217,119,87,.08); }
.pm-table tbody tr.row:hover td.col-ent { background: rgba(42,107,107,.08); }

.pm-table .cell-yes svg,
.pm-table .cell-no svg,
.pm-table .cell-roadmap svg,
.pm-table .cell-na svg { width: 18px; height: 18px; display: inline-block; vertical-align: middle; }
.pm-table .cell-yes path {
  fill: none; stroke: #2e7d3a; stroke-width: 2.2;
  stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 28; stroke-dashoffset: 28;
  transition: stroke-dashoffset .65s cubic-bezier(.22,.61,.36,1);
}
.pm-table.pm-in .cell-yes path { stroke-dashoffset: 0; }
.pm-table.pm-in tr.row .cell-yes path { transition-delay: var(--pmd, 0ms); }
.pm-table .cell-no { color: var(--ink-4); font-family: var(--mono); font-size: 14px; }
.pm-table .cell-na { color: var(--ink-4); font-family: var(--mono); font-size: 11px; letter-spacing: .04em; }
.pm-table .cell-roadmap {
  color: #b58a52; font-family: var(--mono); font-size: 11px; letter-spacing: .04em;
  display: inline-flex; align-items: center; gap: 4px;
}
.pm-table .cell-roadmap::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: #d9a155; box-shadow: 0 0 0 3px rgba(217,161,85,.18);
  animation: sg-pulse 3.5s ease-in-out infinite;
}

.pm-table tbody tr.hide { display: none; }

/* Legend below the matrix */
.pm-legend {
  display: flex; gap: 22px; flex-wrap: wrap;
  padding: 16px 24px; font-size: 11.5px; color: var(--ink-3);
  background: var(--surface); border-top: 1px solid var(--line);
}
.pm-legend span { display: inline-flex; align-items: center; gap: 8px; }
.pm-legend .lg-yes::before { content: ""; width: 14px; height: 14px; display: inline-block; background: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18'%3E%3Cpath d='M3 9.5 L7.5 14 L15 5' fill='none' stroke='%232e7d3a' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat; }
.pm-legend .lg-no::before { content: "—"; color: var(--ink-4); }
.pm-legend .lg-rm::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #d9a155; box-shadow: 0 0 0 3px rgba(217,161,85,.18); }

/* ════════════════════════════════════════════════════════════════
   COMPACT PRIMITIVES — icon-grid, brief sections, number stack
   Built so each page's content can mirror its sacred-geometry
   symbol (Vesica = 2 cells, Trinity = 3, Platonic = 5, Fruit = 6).
   ════════════════════════════════════════════════════════════════ */

/* Brief section — kicker + h2 only, no lede. Used as a hat over an
   iconGrid or numberStack. */
.editorial-section.brief { padding: 56px 0 32px; }
.editorial-section.brief h2 { margin-bottom: 8px; max-width: 28ch; }

/* iconGrid — sacred-glyph + h3 + 1-line. Hover lifts the tile, the
   glyph rotates 60°. */
.icon-grid {
  display: grid;
  gap: 18px;
  margin: 28px 0 0;
}
.icon-grid.two   { grid-template-columns: repeat(2, 1fr); }
.icon-grid.three { grid-template-columns: repeat(3, 1fr); }
.icon-grid.four  { grid-template-columns: repeat(4, 1fr); }
.icon-grid.five  { grid-template-columns: repeat(5, 1fr); }
@media (max-width: 960px) {
  .icon-grid.four, .icon-grid.five { grid-template-columns: repeat(2, 1fr); }
  .icon-grid.three { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .icon-grid.two, .icon-grid.three, .icon-grid.four, .icon-grid.five {
    grid-template-columns: 1fr;
  }
}

.icon-grid .ig {
  padding: 26px 24px 22px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--bg-soft);
  display: flex; flex-direction: column; gap: 10px;
  position: relative;
  transition: transform .28s cubic-bezier(.22,.61,.36,1),
              border-color .28s, box-shadow .28s;
}
.icon-grid .ig:hover {
  transform: translateY(-3px);
  border-color: #d97757;
  box-shadow: 0 18px 38px -28px rgba(217,119,87,.32);
}
.icon-grid .ig-glyph {
  width: 28px; height: 28px;
  color: var(--ink-2);
  opacity: .72;
  display: inline-flex; align-items: center; justify-content: center;
  transition: color .25s ease, transform .55s cubic-bezier(.22,.61,.36,1), opacity .25s ease;
}
.icon-grid .ig:hover .ig-glyph {
  color: #d97757;
  opacity: 1;
  transform: rotate(60deg);
}
.icon-grid .ig-glyph svg { width: 100%; height: 100%; overflow: visible; }
.icon-grid .ig-glyph svg path,
.icon-grid .ig-glyph svg circle,
.icon-grid .ig-glyph svg rect,
.icon-grid .ig-glyph svg polygon,
.icon-grid .ig-glyph svg line {
  stroke: currentColor; fill: none; stroke-width: 1.3;
  stroke-linecap: round; stroke-linejoin: round;
}
.icon-grid .ig-glyph svg .dot { fill: currentColor; stroke: none; }

.icon-grid .ig h3 {
  font-size: 16px;
  letter-spacing: -.015em;
  margin: 0;
  font-weight: 600;
  line-height: 1.3;
}
.icon-grid .ig p {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink-2);
  margin: 0;
  /* Limit each card's text to a short sentence */
  max-width: 38ch;
}

/* numberStack — big bold numbers, terse caption. Wraps to .wrap width. */
.number-stack {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 32px;
  max-width: 1180px;
  width: 100%;
  margin: 40px auto 24px;
  padding: 28px 28px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  box-sizing: border-box;
}
@media (max-width: 720px) {
  .number-stack { padding: 22px 20px; gap: 22px; }
}
.number-stack .ns strong {
  display: block;
  font-family: var(--mono);
  font-size: clamp(32px, 4.5vw, 48px);
  letter-spacing: -.03em;
  color: var(--ink);
  font-weight: 500;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  margin: 0 0 6px;
}
.number-stack .ns span {
  font-size: 13px;
  color: var(--ink-3);
}

/* ════════════════════════════════════════════════════════════════
   SUB-NAV containment + horizontal scroll on narrow widths
   The solutions pages have a `.sub-nav` pill row that was rendering
   edge-to-edge because it lived outside any `.wrap` container.
   Constraining it here matches the rest of the page width.
   ════════════════════════════════════════════════════════════════ */
.sub-nav {
  max-width: 1180px;
  margin: 0 auto 36px;
  padding: 24px 28px 4px;
  /* fall back to flex; the inline-style version had no width cap. */
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  border-top: 1px solid rgba(0,0,0,.06);
  position: relative;
  z-index: 1;
}
.sub-nav a {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 13.5px;
  color: var(--ink-2);
  text-decoration: none;
  background: var(--bg-soft);
  white-space: nowrap;
  transition: background .18s ease, color .18s ease, border-color .18s ease, transform .18s ease;
}
.sub-nav a:hover { color: var(--ink); border-color: var(--ink-3); transform: translateY(-1px); }
.sub-nav a.active,
.sub-nav a[aria-current="page"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }

@media (max-width: 720px) {
  .sub-nav {
    padding: 18px 20px 4px;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    /* edge fade so users see the row is scrollable */
    mask-image: linear-gradient(to right, transparent 0, #000 16px, #000 calc(100% - 16px), transparent 100%);
  }
  .sub-nav::-webkit-scrollbar { display: none; }
}

/* Sticky-header offset for in-page anchors. Without this, jumping to
   #foo lands the section UNDER the 66px sticky header. */
html { scroll-padding-top: 84px; }
:target { scroll-margin-top: 84px; }

/* ════════════════════════════════════════════════════════════════
   ITEM #3 — SERIF ITALIC IN HEADLINES
   Georgia italic for <em> inside h1/h2 — instant editorial weight.
   Pages with <em> in headlines get this for free.
   ════════════════════════════════════════════════════════════════ */
main h1 em,
main h2 em,
.page-h1 em,
.editorial-section h2 em,
.ed-cta h2 em,
.home-hero h1 em,
.hero h1 em {
  font-family: Georgia, "Iowan Old Style", "Times New Roman", serif !important;
  font-style: italic !important;
  font-weight: 400 !important;
  letter-spacing: -.01em !important;
  color: var(--ink-2);
}

/* ════════════════════════════════════════════════════════════════
   ITEM #4 — CURSOR-TAIL ACCENT ON CTA HOVER
   Amber radial follows the mouse over .btn.solid + .btn.ghost.
   --x and --y are updated by sacred.js on mousemove.
   ════════════════════════════════════════════════════════════════ */
.btn.solid,
.btn.ghost,
.case-grid .case,
.cards > a.c {
  position: relative;
  overflow: hidden;
}
.btn.solid::before,
.btn.ghost::before,
.case-grid .case::before,
.cards > a.c::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: radial-gradient(circle 90px at var(--cx, 50%) var(--cy, 50%), rgba(217,119,87,.42), transparent 65%);
  opacity: 0;
  transition: opacity .35s cubic-bezier(.22,.61,.36,1);
  pointer-events: none;
  z-index: 0;
  mix-blend-mode: screen;
}
.btn.solid:hover::before,
.btn.ghost:hover::before,
.case-grid .case:hover::before,
.cards > a.c:hover::before { opacity: 1; }
.btn.solid > *,
.btn.ghost > *,
.case-grid .case > *,
.cards > a.c > * { position: relative; z-index: 1; }
.btn.solid:hover,
.btn.ghost:hover,
.case-grid .case:hover {
  box-shadow: 0 8px 32px -16px rgba(217,119,87,.28);
}

/* ════════════════════════════════════════════════════════════════
   ITEM #5 — PAGE-TRANSITION FADE
   200ms fade on body. sacred.js fades on internal nav.
   ════════════════════════════════════════════════════════════════ */
body {
  opacity: 1;
  transition: opacity 220ms cubic-bezier(.4,0,.2,1);
}
body.sg-leaving {
  opacity: 0;
  filter: blur(3px);
  transition: opacity 180ms ease-in, filter 180ms ease-in;
}
@keyframes sg-page-in {
  from { opacity: 0; filter: blur(3px); }
  to { opacity: 1; filter: none; }
}
html.sg-page-in body {
  animation: sg-page-in 360ms cubic-bezier(.22,.61,.36,1) both;
}

/* ════════════════════════════════════════════════════════════════
   ITEM #6 — PAPER GRAIN TEXTURE
   4% SVG noise overlay on body, fixed, behind content but above bg.
   ════════════════════════════════════════════════════════════════ */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9998;
  opacity: .045;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.92' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.10 0 0 0 0 0.08 0 0 0 0 0.06 0 0 0 1 0'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 220px 220px;
}

/* ════════════════════════════════════════════════════════════════
   ITEM #1 / #2 — INLINE PRODUCT MOCKUPS + BYOK SLIDER
   Used inline by the generator entries for /agent, /security, /pricing.
   ════════════════════════════════════════════════════════════════ */

/* Agent panel mini-mockup (used on /agent) */
.agent-mockup {
  margin: 28px 0 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  background: var(--bg-soft);
  font-family: var(--mono);
  font-size: 13px;
  box-shadow: 0 18px 48px -28px rgba(26,20,16,.18);
}
.agent-mockup .am-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 16px; background: var(--surface); border-bottom: 1px solid var(--line);
}
.agent-mockup .am-bar i {
  width: 11px; height: 11px; border-radius: 50%; background: var(--line-2); display: block;
}
.agent-mockup .am-bar i:nth-child(1){background:#e07c5b}
.agent-mockup .am-bar i:nth-child(2){background:#d9bd6a}
.agent-mockup .am-bar i:nth-child(3){background:#6fa67a}
.agent-mockup .am-bar span { margin-left: 8px; color: var(--ink-3); font-size: 11.5px; letter-spacing: .04em; }
.agent-mockup .am-body { padding: 18px 22px; line-height: 1.7; }
.agent-mockup .am-prompt { color: var(--ink); padding: 8px 0 12px; border-bottom: 1px dashed var(--line); }
.agent-mockup .am-prompt::before { content: "you · "; color: var(--ink-3); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; margin-right: 6px; }
.agent-mockup .am-line { color: var(--ink-2); padding: 6px 0; }
.agent-mockup .am-line::before { content: "azmx · "; color: #d97757; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; margin-right: 6px; }
.agent-mockup .am-approve {
  margin: 14px 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
}
.agent-mockup .am-approve strong { display: block; color: var(--ink); font-size: 12px; letter-spacing: .04em; margin: 0 0 8px; font-weight: 500; }
.agent-mockup .am-approve .am-diff { background: #f1f7f1; color: #2e5e34; padding: 6px 10px; border-radius: 6px; font-size: 12.5px; margin: 0 0 10px; }
.agent-mockup .am-approve .am-actions { display: flex; gap: 8px; }
.agent-mockup .am-approve .am-actions b { padding: 6px 12px; border-radius: 6px; font-weight: 500; font-size: 11.5px; }
.agent-mockup .am-approve .am-actions b.go { background: #d97757; color: var(--bg-soft); }
.agent-mockup .am-approve .am-actions b.no { background: transparent; color: var(--ink-3); border: 1px solid var(--line-2); }
.agent-mockup .am-ok { color: #4a8557; padding: 6px 0; font-size: 12.5px; }
.agent-mockup .am-ok::before { content: "● "; }
.agent-mockup .am-typing::after {
  content: "▋"; display: inline-block; margin-left: 6px; color: #d97757;
  animation: sg-cursor 1.1s steps(2) infinite;
}
@keyframes sg-cursor { 50% { opacity: 0; } }

/* Approval-modes strip (used on /security) */
.modes-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  max-width: 1180px;
  width: calc(100% - 56px);
  margin: 28px auto 0;
  box-sizing: border-box;
}
.modes-strip .ms {
  padding: 18px 16px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--bg-soft);
  display: flex; flex-direction: column; gap: 10px;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.modes-strip .ms:hover {
  transform: translateY(-3px);
  border-color: #d97757;
  box-shadow: 0 18px 40px -28px rgba(217,119,87,.32);
}
.modes-strip .ms .ms-icon { font-size: 18px; color: #d97757; line-height: 1; }
.modes-strip .ms .ms-name { font-family: var(--mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }
.modes-strip .ms .ms-verb { font-size: 14.5px; letter-spacing: -.01em; color: var(--ink); font-weight: 500; }
.modes-strip .ms .ms-card {
  padding: 10px 12px; border-radius: 8px; background: var(--surface); border: 1px solid var(--line);
  font-family: var(--mono); font-size: 11.5px; color: var(--ink-2); line-height: 1.5;
}
.modes-strip .ms.ms-1 .ms-card { background: #f1f7f1; }
.modes-strip .ms.ms-4 .ms-card { background: #fbf2ee; }
.modes-strip .ms .ms-card .row { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.modes-strip .ms .ms-card .row b { padding: 3px 8px; border-radius: 4px; font-size: 10.5px; font-weight: 500; }
.modes-strip .ms .ms-card .row b.go { background: #d97757; color: var(--bg-soft); }
.modes-strip .ms .ms-card .row b.no { background: transparent; border: 1px solid var(--line-2); color: var(--ink-3); }
.modes-strip .ms .ms-card .row b.type { border: 1px dashed var(--ink-3); color: var(--ink-2); }
@media (max-width: 880px) { .modes-strip { grid-template-columns: repeat(2, 1fr); } }

/* BYOK savings slider (used on /pricing) */
.byok-calc {
  max-width: 1180px;
  width: calc(100% - 56px);
  margin: 28px auto 0;
  padding: 32px 36px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(135deg, var(--bg-soft) 0%, #fbf6ec 100%);
  box-sizing: border-box;
}
.byok-calc .bc-head {
  display: flex; justify-content: space-between; align-items: baseline; margin: 0 0 22px; gap: 24px; flex-wrap: wrap;
}
.byok-calc .bc-head h3 {
  margin: 0; font-size: 22px; letter-spacing: -.015em;
}
.byok-calc .bc-head .bc-count {
  font-family: var(--mono); font-size: 20px;
  font-variant-numeric: tabular-nums;
  color: #d97757; font-weight: 500;
}
.byok-calc .bc-slider {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: var(--line);
  appearance: none;
  -webkit-appearance: none;
  outline: none;
  margin: 0 0 22px;
}
.byok-calc .bc-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px; height: 22px; border-radius: 50%;
  background: #d97757;
  border: 3px solid var(--bg-soft);
  box-shadow: 0 4px 12px rgba(217,119,87,.45);
  cursor: pointer;
  transition: transform .15s ease;
}
.byok-calc .bc-slider::-webkit-slider-thumb:hover { transform: scale(1.15); }
.byok-calc .bc-slider::-moz-range-thumb {
  width: 22px; height: 22px; border-radius: 50%;
  background: #d97757;
  border: 3px solid var(--bg-soft);
  box-shadow: 0 4px 12px rgba(217,119,87,.45);
  cursor: pointer; border-style: solid;
}
.byok-calc .bc-bars { display: grid; gap: 14px; margin: 0 0 22px; }
.byok-calc .bc-row { display: grid; grid-template-columns: 180px 1fr 120px; gap: 16px; align-items: center; }
.byok-calc .bc-row .bc-label { font-size: 13.5px; color: var(--ink-2); }
.byok-calc .bc-row .bc-bar-wrap { height: 12px; background: var(--surface); border-radius: 999px; border: 1px solid var(--line); overflow: hidden; }
.byok-calc .bc-row .bc-bar {
  height: 100%; border-radius: 999px;
  transition: width 250ms cubic-bezier(.22,.61,.36,1);
}
.byok-calc .bc-row.bc-comp .bc-bar { background: linear-gradient(90deg, #c9583e, #d97757); }
.byok-calc .bc-row.bc-azmx .bc-bar { background: linear-gradient(90deg, #2e7d5b, #4a9560); }
.byok-calc .bc-row .bc-amount {
  font-family: var(--mono); font-size: 14px;
  font-variant-numeric: tabular-nums;
  text-align: right;
}
.byok-calc .bc-row.bc-comp .bc-amount { color: #c9583e; }
.byok-calc .bc-row.bc-azmx .bc-amount { color: #2e7d5b; }
.byok-calc .bc-save {
  padding: 18px 22px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 14px;
  display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: 12px;
}
.byok-calc .bc-save .bc-save-label {
  font-family: var(--mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3);
  display: block;
}
.byok-calc .bc-save .bc-save-headline {
  font-size: 17px; color: var(--ink); margin: 4px 0 0;
}
.byok-calc .bc-save .bc-save-num {
  font-family: var(--mono); font-size: clamp(28px, 4.5vw, 42px); font-weight: 600;
  letter-spacing: -.02em;
  color: #2e7d5b;
  font-variant-numeric: tabular-nums;
}
.byok-calc .bc-note {
  margin: 16px 0 0; font-size: 12.5px; color: var(--ink-3); line-height: 1.55;
}
@media (max-width: 720px) {
  .byok-calc { padding: 24px; }
  .byok-calc .bc-row { grid-template-columns: 1fr; gap: 6px; }
  .byok-calc .bc-row .bc-amount { text-align: left; }
}

/* ── Reduced motion ────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .sg-draw, .sg-spin-slow, .sg-spin-med, .sg-spin-fast,
  .sg-pulse, .sg-breathe, .sg-floaters .f {
    animation: none !important;
    stroke-dashoffset: 0 !important;
  }
  .sigil-row { transition: none; opacity: 1; transform: none; }
  .case-grid .case, .cards .c, .bento .tile, main .step, main .board .col,
  .sg-reveal { transition: none !important; opacity: 1 !important; transform: none !important; filter: none !important; }
  body, body.sg-leaving, html.sg-page-in body {
    transition: none !important; animation: none !important; filter: none !important; opacity: 1 !important;
  }
  .agent-mockup .am-typing::after { animation: none; }
}
