/* ========================================
   WireTrade Design System
   Dark industrial, circuit-schematic aesthetic
   Syne (display) · DM Sans (body) · IBM Plex Mono (technical)
   ======================================== */

:root {
  --bg: #0c0c0e;
  --bg-alt: #111116;
  --bg-card: #16161c;
  --bg-card-hover: #1c1c24;
  --fg: #f0ece4;
  --fg-muted: #8a8680;
  --steel: #6b6b73;
  --accent: #ff5c1a;
  --accent-dim: rgba(255, 92, 26, 0.12);
  --accent-glow: rgba(255, 92, 26, 0.28);
  --accent-border: rgba(255, 92, 26, 0.22);
  --trace: rgba(255, 92, 26, 0.18);
  --node-bg: #ff5c1a;
  --font-display: 'Syne', 'Arial Black', sans-serif;
  --font-body: 'DM Sans', -apple-system, sans-serif;
  --font-mono: 'IBM Plex Mono', 'Courier New', monospace;
  --radius: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ---- TIER BADGE — per-track color token ----
   Views set --track-color inline on .tier-badge (.tier-badge--<level>); all
   derived colors (text, soft border, tinted background) come from this.
   Avoid hardcoding <color>40 alpha suffixes in markup. */
.tier-badge {
  --track-color: var(--accent);
  color: var(--track-color);
  border: 1px solid color-mix(in srgb, var(--track-color) 28%, transparent);
  background: color-mix(in srgb, var(--track-color) 8%, transparent);
}
.tier-badge--foundational,
.tier-badge--journeyman,
.tier-badge--specialist,
.tier-badge--advanced,
.tier-badge--leadership {}

/* ---- HERO ---- */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 0 clamp(24px, 7vw, 112px);
  border-bottom: 1px solid var(--trace);
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 70% 40%, rgba(255,92,26,0.04) 0%, transparent 70%);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  flex: 1;
  align-items: center;
}

.hero-left {
  padding: clamp(72px, 14vh, 128px) 0;
  padding-right: clamp(40px, 6vw, 96px);
  border-right: 1px solid var(--trace);
}

.logo-mark {
  font-family: var(--font-mono);
  font-size: clamp(36px, 5vw, 60px);
  font-weight: 700;
  line-height: 1;
  margin-bottom: 28px;
  display: flex;
  gap: 0;
}
.logo-mark .logo-w { color: var(--fg); }
.logo-mark .logo-t { color: var(--accent); }

.hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 20px;
}

.hero-headline {
  font-family: var(--font-display);
  font-size: clamp(44px, 6.5vw, 88px);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin-bottom: 28px;
}

.hero-sub {
  font-size: clamp(16px, 1.4vw, 19px);
  line-height: 1.65;
  color: var(--fg-muted);
  max-width: 480px;
  margin-bottom: 40px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 36px;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--bg);
  background: var(--accent);
  padding: 14px 28px;
  border-radius: var(--radius);
  text-decoration: none;
  transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
  box-shadow: 0 0 0 0 var(--accent-glow);
  white-space: nowrap;
}
.btn-primary:hover {
  background: #ff7029;
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(255, 92, 26, 0.3);
}
.btn-primary:active { transform: translateY(0); }

.btn-large {
  font-size: 14px;
  padding: 18px 36px;
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--fg-muted);
  background: transparent;
  border: 1px solid rgba(240, 236, 228, 0.15);
  padding: 14px 28px;
  border-radius: var(--radius);
  text-decoration: none;
  transition: border-color 0.2s ease, color 0.2s ease;
  white-space: nowrap;
}
.btn-ghost:hover {
  border-color: rgba(240, 236, 228, 0.4);
  color: var(--fg);
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.meta-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--accent);
  background: var(--accent-dim);
  border: 1px solid var(--accent-border);
  padding: 5px 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 2px;
}

/* Circuit Art */
.hero-right {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(56px, 10vh, 112px) 0;
  padding-left: clamp(40px, 6vw, 96px);
}

.circuit-art {
  position: relative;
  width: 100%;
  max-width: 520px;
  aspect-ratio: 4/3;
}

.circuit-node {
  position: absolute;
  width: 16px;
  height: 16px;
  background: var(--node-bg);
  border-radius: 50%;
  box-shadow: 0 0 20px var(--accent-glow), 0 0 6px var(--accent);
}

.c-node-1 { top: 8%; left: 12%; }
.c-node-2 { top: 8%; left: 50%; }
.c-node-3 { top: 8%; left: 88%; }
.c-node-4 { top: 50%; left: 12%; }
.c-node-5 { top: 50%; left: 50%; }
.c-node-6 { top: 50%; left: 88%; }

.circuit-trace {
  position: absolute;
  background: var(--trace);
}
.t-h1 { top: 9%; left: 12%; right: 12%; height: 2px; }
.t-h2 { top: 51%; left: 12%; right: 12%; height: 2px; }
.t-v1 { left: 12.8%; top: 8%; bottom: 42%; width: 2px; }
.t-v2 { left: 50.8%; top: 8%; bottom: 42%; width: 2px; }

.wire-label {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  color: var(--accent);
  background: var(--bg);
  border: 1px solid var(--accent-border);
  padding: 3px 7px;
  letter-spacing: 0.1em;
  border-radius: 2px;
}
.w-label-1 { top: 0%; left: 10%; }
.w-label-2 { top: 0%; left: 44%; }
.w-label-3 { top: 0%; left: 80%; }
.w-label-4 { top: 38%; left: 0%; writing-mode: vertical-rl; }
.w-label-5 { top: 38%; left: 36%; writing-mode: vertical-rl; }
.w-label-6 { top: 38%; left: 72%; writing-mode: vertical-rl; }
.w-label-7 { top: 70%; left: 10%; }

.hero-bottom-rule {
  padding: 20px 0;
  border-top: 1px solid var(--trace);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--steel);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ---- SECTION LABELS ---- */
.section-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

/* ---- TRACKS / TILES ---- */
.tracks {
  padding: clamp(80px, 12vh, 140px) clamp(24px, 7vw, 112px);
  border-bottom: 1px solid var(--trace);
}

.tracks-header {
  margin-bottom: 56px;
}

.tracks-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 4.5vw, 56px);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin-bottom: 16px;
}

.tracks-sub {
  font-size: clamp(15px, 1.3vw, 17px);
  color: var(--fg-muted);
  line-height: 1.65;
  max-width: 560px;
}

.tile-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.tile-card {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 32px;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius-md);
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: border-color 0.25s ease, background 0.25s ease, transform 0.2s ease;
  cursor: pointer;
}
.tile-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}
.tile-card:hover {
  border-color: var(--accent-border);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
}
.tile-card:hover::before { transform: scaleX(1); }

.tile-icon {
  color: var(--accent);
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-dim);
  border-radius: var(--radius);
  margin-top: 2px;
}

.tile-body {
  flex: 1;
  min-width: 0;
}

.tile-title {
  font-family: var(--font-display);
  font-size: clamp(18px, 2vw, 22px);
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.tile-desc {
  font-size: 14px;
  line-height: 1.65;
  color: var(--fg-muted);
}

.tile-arrow {
  color: var(--steel);
  flex-shrink: 0;
  align-self: center;
  transition: color 0.2s ease, transform 0.2s ease;
  margin-top: 2px;
}
.tile-card:hover .tile-arrow {
  color: var(--accent);
  transform: translateX(4px);
}

.tile-corner {
  position: absolute;
  bottom: 20px;
  right: 20px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.3;
}

/* ---- MODEL / PRICING ---- */
.model {
  padding: clamp(80px, 12vh, 140px) clamp(24px, 7vw, 112px);
  border-bottom: 1px solid var(--trace);
}

.model-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(48px, 6vw, 96px);
  align-items: center;
}

.model-title {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.5vw, 46px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin-bottom: 20px;
}

.model-body {
  font-size: 15px;
  line-height: 1.7;
  color: var(--fg-muted);
  margin-bottom: 28px;
}

.model-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--fg-muted);
  border: 1px solid rgba(138, 134, 128, 0.2);
  padding: 5px 12px;
  letter-spacing: 0.04em;
  border-radius: 2px;
}

/* Pricing block */
.pricing-block {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--accent-border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.pricing-tier {
  padding: 32px;
  background: var(--bg-card);
}

.pricing-tier--accent {
  background: var(--accent-dim);
  border-top: 1px solid var(--accent-border);
}

.pricing-tier-name {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 4px;
}

.pricing-tier-desc {
  font-size: 13px;
  color: var(--fg-muted);
  margin-bottom: 20px;
}

.pricing-tier-price {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 20px;
}

.price-amount {
  font-family: var(--font-mono);
  font-size: 42px;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}

.price-note {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-muted);
  font-weight: 500;
}

.pricing-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pricing-features li {
  font-size: 13px;
  color: var(--fg-muted);
  padding-left: 16px;
  position: relative;
  line-height: 1.4;
}
.pricing-features li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 6px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.6;
}

.pricing-tier--accent .pricing-features li::before {
  opacity: 0.9;
}

.pricing-divider {
  display: flex;
  align-items: center;
  padding: 0 32px;
  background: var(--bg);
  border-top: 1px solid var(--accent-border);
  border-bottom: 1px solid var(--accent-border);
}
.pricing-divider span {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 8px 0;
}

/* ---- MANIFESTO ---- */
.manifesto {
  padding: clamp(80px, 14vh, 140px) clamp(24px, 7vw, 112px);
  border-bottom: 1px solid var(--trace);
  background: var(--bg-alt);
}

.manifesto-inner {
  max-width: 900px;
  margin: 0 auto;
}

.manifesto-quote {
  margin-bottom: 48px;
  border-left: 3px solid var(--accent);
  padding-left: 32px;
}

.quote-text {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.5vw, 36px);
  font-weight: 700;
  line-height: 1.25;
  color: var(--fg);
  font-style: normal;
}

.manifesto-body {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.manifesto-body p {
  font-size: clamp(15px, 1.3vw, 17px);
  line-height: 1.75;
  color: var(--fg-muted);
}

/* ---- CLOSING ---- */
.closing {
  padding: clamp(80px, 14vh, 140px) clamp(24px, 7vw, 112px);
  border-bottom: 1px solid var(--trace);
}

.closing-inner {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.closing-headline {
  font-family: var(--font-display);
  font-size: clamp(36px, 5vw, 72px);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin-bottom: 20px;
}

.closing-sub {
  font-size: clamp(15px, 1.3vw, 18px);
  color: var(--fg-muted);
  max-width: 560px;
  margin: 0 auto 56px;
  line-height: 1.6;
}

.closing-cta {
  margin-bottom: 72px;
}

.closing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  max-width: 480px;
  width: 100%;
  background: var(--trace);
  border: 1px solid var(--trace);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.closing-stat {
  background: var(--bg-alt);
  padding: 36px 24px;
  text-align: center;
}

.stat-number {
  font-family: var(--font-mono);
  font-size: clamp(40px, 5vw, 56px);
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 10px;
}

.stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--fg-muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* ---- FOOTER ---- */
.footer {
  padding: 40px clamp(24px, 7vw, 112px);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
}

.footer-logo {
  display: flex;
  align-items: baseline;
  gap: 4px;
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 700;
}
.footer-w { color: var(--fg); }
.footer-t { color: var(--accent); }
.footer-name { color: var(--fg); }

.footer-tagline {
  font-size: 13px;
  color: var(--fg-muted);
}

.footer-links {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--steel);
  letter-spacing: 0.05em;
  opacity: 0.7;
}
.footer-links .sep { color: var(--accent); }

/* ---- PRICING PAGE ---- */
.pricing-page { min-height: 100vh; display: flex; flex-direction: column; }

.pricing-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 24px clamp(24px, 7vw, 112px);
  border-bottom: 1px solid var(--trace);
}
.pricing-nav-logo { font-family: var(--font-mono); font-size: clamp(28px, 4vw, 44px); font-weight: 700; line-height: 1; display: flex; gap: 0; }
.pricing-nav-logo .logo-w { color: var(--fg); }
.pricing-nav-logo .logo-t { color: var(--accent); }
.pricing-nav-links { display: flex; gap: 24px; }
.pricing-nav-links a { font-family: var(--font-mono); font-size: 12px; color: var(--fg-muted); text-decoration: none; }
.pricing-nav-links a:hover { color: var(--accent); }

.pricing-hero {
  text-align: center;
  padding: clamp(64px, 10vh, 112px) clamp(24px, 7vw, 112px) clamp(40px, 6vh, 72px);
}
.pricing-hero .hero-headline {
  font-size: clamp(40px, 5.5vw, 72px);
  margin-bottom: 16px;
}
.pricing-hero .hero-sub {
  max-width: 520px;
  margin: 0 auto;
}

.pricing-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 24px; max-width: 800px; margin: 0 auto; width: 100%;
  padding: 0 clamp(24px, 7vw, 112px);
}

/* Tier cards */
.pricing-card {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.pricing-card-inner {
  padding: 36px 32px;
  display: flex; flex-direction: column; height: 100%;
  box-sizing: border-box;
}
.pricing-card-inner--accent {
  background: var(--accent-dim);
  border-top: 1px solid var(--accent-border);
}

.pricing-card-name {
  font-family: var(--font-display);
  font-size: 20px; font-weight: 700;
  color: var(--fg); margin-bottom: 4px;
}
.pricing-card-desc {
  font-size: 13px; color: var(--fg-muted); margin-bottom: 24px;
}
.pricing-card-price {
  display: flex; align-items: baseline; gap: 6px; margin-bottom: 24px;
}
.pricing-card .price-amount {
  font-family: var(--font-mono); font-size: 48px; font-weight: 700;
  color: var(--accent); line-height: 1;
}
.pricing-card .price-note {
  font-family: var(--font-mono); font-size: 12px; color: var(--fg-muted); font-weight: 500;
}
.pricing-card .pricing-features { margin-bottom: 32px; flex: 1; }

.btn-card {
  display: block; text-align: center;
  font-family: var(--font-mono); font-size: 13px; font-weight: 600;
  letter-spacing: 0.04em; color: var(--bg); background: var(--accent);
  padding: 14px 28px; border-radius: var(--radius);
  text-decoration: none; transition: background 0.2s ease, transform 0.15s ease;
  width: 100%; box-sizing: border-box;
}
.btn-card:hover { background: #ff7029; transform: translateY(-1px); }

/* Most Popular badge */
.tier-popular { position: relative; }
.tier-popular .badge-popular {
  position: absolute; top: -1px; left: 50%; transform: translateX(-50%);
  background: var(--accent); color: var(--bg);
  font-family: var(--font-mono); font-size: 10px; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  padding: 5px 16px; border-radius: 0 0 var(--radius) var(--radius);
  white-space: nowrap; z-index: 1;
}

/* Comparison table */
.pricing-comparison {
  max-width: 800px; margin: 56px auto; width: 100%;
  padding: 0 clamp(24px, 7vw, 112px);
}
.comparison-table-wrapper {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.comparison-table {
  width: 100%; border-collapse: collapse; font-size: 14px;
}
.comparison-table th {
  font-family: var(--font-mono); font-size: 11px; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--fg-muted);
  text-align: left; padding: 16px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.comparison-table th:not(:first-child) { text-align: center; }
.comparison-table td {
  padding: 14px 20px; border-bottom: 1px solid rgba(255,255,255,0.04);
  color: var(--fg-muted);
}
.comparison-table td:not(:first-child) { text-align: center; }
.comparison-table tr:last-child td { border-bottom: none; }
.comparison-table .check { color: var(--accent); font-size: 16px; }
.comparison-table .dash { color: var(--steel); font-size: 16px; }

/* CTA section */
.pricing-cta {
  text-align: center; padding: clamp(48px, 8vh, 80px) clamp(24px, 7vw, 112px);
  border-top: 1px solid var(--trace);
}
.pricing-cta-text {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.5vw, 32px); font-weight: 700;
  color: var(--fg); margin-bottom: 24px;
}

/* Billing toggle */
.billing-toggle {
  display: flex; justify-content: center; gap: 8px;
  margin: 0 auto 40px; max-width: 300px;
}
.toggle-btn {
  font-family: var(--font-mono); font-size: 12px; font-weight: 600;
  letter-spacing: 0.06em; text-transform: uppercase;
  padding: 10px 20px; border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,0.12);
  background: transparent; color: var(--fg-muted);
  cursor: pointer; transition: background 0.2s ease, color 0.2s ease;
}
.toggle-btn--active {
  background: var(--accent); color: var(--bg); border-color: var(--accent);
}
.toggle-save {
  font-size: 10px; opacity: 0.8; margin-left: 4px;
}

/* ---- RESPONSIVE ---- */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-left {
    border-right: none;
    padding-right: 0;
    padding-bottom: 48px;
  }
  .hero-right {
    display: none;
  }
  .tile-grid {
    grid-template-columns: 1fr;
  }
  .model-inner {
    grid-template-columns: 1fr;
  }
  .pricing-grid {
    grid-template-columns: 1fr;
  }
  .comparison-table th, .comparison-table td {
    padding: 12px 14px;
    font-size: 13px;
  }
}

@media (max-width: 640px) {
  .tile-card {
    padding: 24px 20px;
  }
  .tile-icon {
    width: 36px;
    height: 36px;
  }
  .closing-grid {
    max-width: 280px;
  }
  .hero-actions {
    flex-direction: column;
    align-items: flex-start;
  }
  .btn-primary, .btn-ghost {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .tracks-title br,
  .model-title br,
  .closing-headline br {
    display: none;
  }
}