/* ============================================================
   tech-console.css — "Nordic data-console" overlay (additive)
   Sits AFTER styles.css, BEFORE <style id="dk-variation-overrides"> in cascade.
   No new HTTP requests. System fonts only. Compositor-only animations.
   ============================================================ */

:root{
  --mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
  --scan-line: repeating-linear-gradient(0deg, transparent 0 2px, rgba(255,255,255,0.035) 2px 3px);
  --dot-grid-bg: radial-gradient(circle at 1px 1px, rgba(15,42,74,0.08) 1px, transparent 0) 0 0 / 16px 16px;
  --clip-chamfer-24: polygon(0 0, calc(100% - 24px) 0, 100% 24px, 100% 100%, 24px 100%, 0 calc(100% - 24px));
  --clip-chamfer-12: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px));
  --step-radius: 0 24px 0 24px;
  --step-radius-sm: 0 12px 0 12px;
  --console-border: rgba(15,42,74,0.14);
  --console-border-strong: rgba(15,42,74,0.28);
}

/* ---------- console-section: subtle dot-grid in top-right ---------- */
.console-section{
  position: relative;
  isolation: isolate;
}
.console-section::before{
  content: "";
  position: absolute;
  inset: 0;
  background: var(--dot-grid-bg);
  -webkit-mask-image: radial-gradient(ellipse 60% 40% at 100% 0%, #000 0%, transparent 70%);
          mask-image: radial-gradient(ellipse 60% 40% at 100% 0%, #000 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.console-section > *{ position: relative; z-index: 1; }

/* ---------- console-card: base ---------- */
.console-card{
  position: relative;
  background: var(--white, #fff);
  border: 1px solid var(--console-border);
  border-radius: var(--step-radius);
  padding: 1.5rem 1.4rem;
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease;
  will-change: transform;
}
.console-card:hover{
  transform: translateY(-2px);
  border-color: var(--console-border-strong);
  box-shadow: 0 8px 24px -16px rgba(15,42,74,0.25);
}
.console-card--chamfer{
  border-radius: 0;
  clip-path: var(--clip-chamfer-24);
  -webkit-clip-path: var(--clip-chamfer-24);
}

/* ---------- console-id-badge: monospace tier badges ---------- */
.console-id-badge{
  display: inline-flex;
  align-items: center;
  font-family: var(--mono);
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 8px;
  border: 1px solid var(--console-border-strong);
  border-radius: 2px;
  background: transparent;
  color: var(--navy, #0F2A4A);
  white-space: nowrap;
  font-weight: 500;
}
.console-id-badge--accent{
  border-color: var(--gold, #C8102E);
  color: var(--gold, #C8102E);
}
.console-id-badge--inverse{
  border-color: rgba(250,247,242,0.4);
  color: var(--ivory, #FAF7F2);
}

/* ---------- console-stat: large tabular numerics ---------- */
.console-stat{
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--navy, #0F2A4A);
}

/* ---------- scan-line overlay ---------- */
.scan-line{
  position: relative;
}
.scan-line::before{
  content: "";
  position: absolute;
  inset: 0;
  background: var(--scan-line);
  pointer-events: none;
  mix-blend-mode: overlay;
  z-index: 1;
}

/* ---------- hex-tier indicator (CSS-only) ---------- */
.hex-tier{
  display: inline-block;
  width: 18px;
  aspect-ratio: 1 / 1.15;
  background: var(--gold, #C8102E);
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  -webkit-clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  vertical-align: middle;
}
.hex-tier--lg{ width: 28px; }
.hex-tier--outline{
  background: transparent;
  position: relative;
}
.hex-tier--outline::before{
  content: "";
  position: absolute;
  inset: 1.5px;
  background: var(--white, #fff);
  clip-path: inherit;
}

/* ---------- tech-divider: full-width SVG dot-grid line ---------- */
.tech-divider{
  position: relative;
  height: 8px;
  margin: 1.25rem 0;
  color: var(--navy, #0F2A4A);
  opacity: .85;
}
.tech-divider::before{
  content: "";
  display: block;
  height: 8px;
  width: 100%;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='8' height='8'><circle cx='1' cy='4' r='1' fill='%230F2A4A' opacity='0.35'/></svg>");
  background-repeat: repeat-x;
  background-size: 8px 8px;
}

/* ---------- diag-clip-bottom: diagonal section bottom edge ---------- */
.diag-clip-bottom{
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 48px), 50% 100%, 0 calc(100% - 48px));
  -webkit-clip-path: polygon(0 0, 100% 0, 100% calc(100% - 48px), 50% 100%, 0 calc(100% - 48px));
  padding-bottom: calc(48px + 2.5rem) !important;
}

/* ---------- tech-grid--methodology: 6-card grid with monospace numbers ---------- */
.tech-grid--methodology{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-top: 2rem;
}
.tech-grid--methodology .console-card,
.tech-grid--methodology .card{
  position: relative;
  padding-top: 2.6rem;
  overflow: hidden;
}
.tech-grid--methodology .console-card::after,
.tech-grid--methodology .card::after{
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--scan-line), linear-gradient(90deg, var(--gold, #C8102E) 0%, transparent 60%);
  pointer-events: none;
}
.tech-grid--methodology .console-stat{
  position: absolute;
  top: .75rem;
  left: 1.1rem;
  font-size: 1.6rem;
  color: var(--gold, #C8102E);
  opacity: .85;
  letter-spacing: 0;
}

/* ---------- tech-grid--operators: comparison cards ---------- */
.tech-grid--operators{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}
.tech-grid--operators .console-card{
  display: flex;
  flex-direction: column;
  gap: .6rem;
}
.tech-grid--operators .console-card__head{
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: .6rem;
}
.tech-grid--operators .console-card__sparkline{
  display: block;
  width: 100%;
  height: 24px;
  margin: .4rem 0 .2rem;
  color: var(--navy, #0F2A4A);
  opacity: .55;
}

/* Inline sparkline pattern usable as ::after on operator cards */
.tech-grid--operators .console-card[data-spark]::after{
  content: "";
  display: block;
  height: 22px;
  margin-top: .4rem;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 22' preserveAspectRatio='none'><polyline points='0,16 12,12 24,14 36,8 48,11 60,5 72,9 84,4 96,7 108,3 120,6' fill='none' stroke='%230F2A4A' stroke-width='1.2' stroke-linecap='round' stroke-linejoin='round' opacity='0.45'/></svg>");
  background-repeat: no-repeat;
  background-size: 100% 100%;
}

/* ---------- terminal-faq: '>' chevron prefix ---------- */
.terminal-faq{ position: relative; }
.terminal-faq .faq-list{ display: flex; flex-direction: column; gap: .75rem; }
.terminal-faq .faq-item{
  position: relative;
  border-left: 0 solid transparent;
  transition: padding-left .22s ease;
}
.terminal-faq .faq-item::before{
  content: "";
  position: absolute;
  left: -3px; top: 0; bottom: 0;
  width: 3px;
  background: var(--gold, #C8102E);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform .22s ease;
}
.terminal-faq .faq-item:hover::before,
.terminal-faq .faq-item:focus-within::before{
  transform: scaleY(1);
}
.terminal-faq .faq-question{
  font-family: var(--font-sans, inherit);
}
.terminal-faq .faq-question::before{
  content: ">";
  display: inline-block;
  margin-right: .5em;
  font-family: var(--mono);
  color: var(--gold, #C8102E);
  font-weight: 600;
}

/* ---------- numeric-tabular utility ---------- */
.numeric-tabular{
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  letter-spacing: 0.04em;
}

/* ---------- console-h2: monospace eyebrow + serif H2 ---------- */
.console-h2{
  display: flex;
  flex-direction: column;
  gap: .35rem;
  margin-bottom: 1.25rem;
}
.console-h2__eyebrow{
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold, #C8102E);
  font-weight: 500;
}
.console-h2__eyebrow::after{
  content: " — ";
  opacity: .5;
  margin: 0 .25em;
}
.console-h2__title{
  font-family: var(--font-serif, "Fraunces", Georgia, serif);
  margin: 0;
  font-weight: 400;
}

/* ---------- Apply tabular numerics to common comparison-table cells ---------- */
.comparison-table td:nth-child(3),
.comparison-table .console-stat,
.comparison-table .min-deposit{
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  letter-spacing: 0.02em;
}

/* ---------- Hero: monospace eyebrow inside hero ---------- */
.hero .console-id-badge{
  display: inline-flex;
  margin: 0 auto 1rem;
  border-color: rgba(250,247,242,0.4);
  color: var(--ivory, #FAF7F2);
}

/* ---------- Trust-strip: badge-style ---------- */
.trust-strip__item .console-id-badge{
  font-size: 11px;
  padding: 4px 9px;
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce){
  .console-card,
  .terminal-faq .faq-item,
  .terminal-faq .faq-item::before{
    transition: none !important;
  }
  .console-card:hover{ transform: none; }
  .terminal-faq .faq-item:hover::before,
  .terminal-faq .faq-item:focus-within::before{ transform: scaleY(1); }
}

/* ---------- Mobile adjustments ---------- */
@media (max-width: 768px){
  :root{
    --clip-chamfer-24: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px));
    --step-radius: 0 12px 0 12px;
  }
  .diag-clip-bottom{
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 24px), 50% 100%, 0 calc(100% - 24px));
    -webkit-clip-path: polygon(0 0, 100% 0, 100% calc(100% - 24px), 50% 100%, 0 calc(100% - 24px));
    padding-bottom: calc(24px + 2rem) !important;
  }
  .tech-grid--methodology{ gap: .9rem; }
  .tech-grid--methodology .console-stat{ font-size: 1.3rem; }
  .console-h2__eyebrow{ font-size: 10px; }
}

/* Console-overlay v1 — overrides only sit AFTER styles.css and BEFORE <style id="dk-variation-overrides"> in cascade. Ships ~12KB before brotli. */
