/* ==========================================================================
   SOURCE COINS — HIGH-FIDELITY DESIGN SYSTEM & TOKENS (v0.5)
   Canonical visual architecture matching the authoritative Source Coins build.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Saira:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@300;400;500;600;700&display=swap');

:root {
  /* Canvas & Glass Surfaces */
  --bg: #050505;
  --surface: rgba(11, 13, 17, 0.72);
  --surface-strong: rgba(9, 12, 17, 0.92);
  --white: #f8fafc;
  --body: rgba(226, 232, 240, 0.68);
  --muted: rgba(226, 232, 240, 0.40);
  --line: rgba(255, 255, 255, 0.082);
  --line-soft: rgba(255, 255, 255, 0.045);
  --shadow: 0 34px 92px rgba(0, 0, 0, 0.48);
  --ease: cubic-bezier(.16, 1, .3, 1);
  --card-radius-lg: 1.5rem;

  /* Rich Color Spectrum */
  --gold: #d4af37;
  --scgold: #d4af37;
  --cyan: #33d2ff;
  --sccyan: #33d2ff;
  --emerald: #10b981;
  --scgreen: #10b981;
  --amber: #f59e0b;
  --scamber: #f59e0b;
  --purple: #a855f7;
  --rose: #ef4444;

  --theme-glow: rgba(212, 175, 55, 0.05);
  --theme-shadow: rgba(212, 175, 55, 0.15);
  --theme-border-glow: rgba(212, 175, 55, 0.9);

  --font: 'Saira', Arial, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

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

html {
  background: var(--bg);
  color: var(--white);
  font-family: var(--font);
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  margin: 0;
  padding: 0;
  background: transparent;
  color: var(--white);
  font-family: var(--font) !important;
  font-weight: 300;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

::selection {
  background: rgba(212, 175, 55, 0.3);
  color: #ffffff;
}

/* ==========================================================================
   AMBIENT SPOTLIGHT, GRID & MICROGRAIN
   ========================================================================== */

.bg-grain {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.022;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

.bg-glow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -2;
  background: radial-gradient(circle 800px at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(212, 175, 55, 0.035), transparent 70%);
  transition: background 0.05s ease;
  pointer-events: none;
}

.bg-grid {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
  background-size: 50px 50px;
  background-position: center center;
  mask-image: radial-gradient(circle 600px at var(--mouse-x, 50%) var(--mouse-y, 50%), black, transparent 80%);
  -webkit-mask-image: radial-gradient(circle 600px at var(--mouse-x, 50%) var(--mouse-y, 50%), black, transparent 80%);
  pointer-events: none;
}

/* Falling Rain Beams Animation Layer */
.forensic-grid-scoped {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  display: flex;
  justify-content: space-between;
  max-width: 86rem;
  margin: 0 auto;
  padding: 0 2rem;
  opacity: 0.06;
}

.grid-line-scoped {
  width: 1px;
  height: 100%;
  background: rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
}

.beam-scoped {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 220px;
  background: linear-gradient(to bottom, transparent, rgba(212, 175, 55, 0.6), transparent);
}

.sc-wrap {
  width: min(1380px, calc(100% - 48px));
  margin-inline: auto;
}

/* ==========================================================================
   TYPOGRAPHY & EYEBROWS
   ========================================================================== */

.sc-eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 20px;
}

.sc-eyebrow::before {
  content: '';
  display: block;
  width: 24px;
  height: 1px;
  background: var(--gold);
  opacity: 0.6;
}

.sc-section-title {
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: #ffffff;
  margin-bottom: 20px;
}

.sc-section-subtitle {
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  font-weight: 300;
  line-height: 1.65;
  color: var(--body);
  max-width: 780px;
  margin-bottom: 48px;
}

/* ==========================================================================
   BUTTON SYSTEMS (CHISELED & PILLS)
   ========================================================================== */

.chiseled-btn {
  position: relative;
  display: inline-flex;
  height: 44px;
  border-radius: 9999px;
  text-decoration: none;
  cursor: pointer;
  outline: none;
  border: none;
  padding: 0;
  background: transparent;
  user-select: none;
  transition: transform 0.25s var(--ease);
}

.chiseled-btn:hover {
  transform: translateY(-2px);
}

.chiseled-btn-glow {
  position: absolute;
  inset: 0;
  border-radius: 9999px;
  background: rgba(212, 175, 55, 0.18);
  filter: blur(8px);
  opacity: 0;
  transition: all 0.5s var(--ease);
  pointer-events: none;
  z-index: 0;
}

.chiseled-btn:hover .chiseled-btn-glow {
  opacity: 1;
  transform: scale(1.02);
}

.chiseled-btn-inner {
  position: relative;
  z-index: 10;
  display: flex;
  height: 100%;
  border-radius: 9999px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.6), inset 0 0 0 1px rgba(255,255,255,0.05);
  transition: all 0.5s var(--ease);
}

.chiseled-btn:hover .chiseled-btn-inner {
  box-shadow: 0 6px 24px rgba(212,175,55,0.35), inset 0 0 0 1px rgba(212,175,55,0.35);
}

.chiseled-icon-housing {
  width: 40px;
  height: 100%;
  border-radius: 9999px 0 0 9999px;
  position: relative;
  border: 1px solid rgba(255,255,255,0.12);
  border-right: 1px solid #d4af37;
  overflow: hidden;
  z-index: 20;
  background: linear-gradient(180deg, #42424a 0%, #202025 35%, #0f0f13 100%);
  box-shadow: inset 2px 0 4px rgba(0,0,0,0.4), inset 0 1px 2px rgba(255,255,255,0.18), inset 0 -2px 4px rgba(0,0,0,0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(12px);
}

.chiseled-triangle {
  width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  filter: drop-shadow(0 1px 0.5px rgba(255,255,255,0.2)) drop-shadow(0 -0.5px 0.5px rgba(0,0,0,0.65));
  transition: color 0.3s ease, filter 0.3s ease;
}

.chiseled-btn:hover .chiseled-triangle {
  color: #ffffff;
  filter: drop-shadow(0 1px 2px rgba(212,175,55,0.8));
}

.chiseled-btn-body {
  display: flex;
  align-items: center;
  padding-left: 16px;
  padding-right: 22px;
  height: 100%;
  margin-left: -1px;
  backdrop-filter: blur(14px);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-left: 0;
  border-radius: 0 9999px 9999px 0;
  position: relative;
  z-index: 10;
  overflow: hidden;
  background: linear-gradient(90deg, rgba(28, 24, 14, 0.85) 0%, rgba(14, 12, 8, 0.7) 100%);
  box-shadow: inset 0 0 12px rgba(212,175,55,0.08), inset 0 1px 1px rgba(255,255,255,0.2);
  transition: all 0.5s var(--ease);
}

.chiseled-btn:hover .chiseled-btn-body {
  border-color: rgba(212, 175, 55, 0.6);
  background: linear-gradient(90deg, rgba(38, 32, 18, 0.95) 0%, rgba(20, 16, 10, 0.85) 100%);
}

.chiseled-btn-body span {
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: #ffffff;
  transition: all 0.3s ease;
}

/* Secondary Button Styles */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 9999px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.25s var(--ease);
  user-select: none;
}

.btn-primary {
  background: var(--gold);
  color: #000000;
  font-weight: 600;
  border: 1px solid var(--gold);
  box-shadow: 0 4px 20px rgba(212, 175, 55, 0.3);
}

.btn-primary:hover {
  background: #e6c34f;
  border-color: #e6c34f;
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(212, 175, 55, 0.5);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.3);
  color: #ffffff;
  transform: translateY(-2px);
}

.btn-gold-outline {
  background: rgba(212, 175, 55, 0.05);
  color: var(--gold);
  border: 1px solid rgba(212, 175, 55, 0.35);
  backdrop-filter: blur(12px);
}

.btn-gold-outline:hover {
  background: rgba(212, 175, 55, 0.15);
  border-color: rgba(212, 175, 55, 0.65);
  color: #ffffff;
  transform: translateY(-2px);
}

/* ==========================================================================
   SIGNATURE CARD STYLE P (.gc-style1-p)
   ========================================================================== */

.gc-style1-p {
  background: rgba(0, 0, 0, 0.65) !important;
  backdrop-filter: blur(14px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(14px) saturate(140%) !important;
  border: none !important;
  border-radius: var(--card-radius-lg);
  padding: 2.2rem;
  box-shadow: 
    inset 1px 1px 0px rgba(255, 255, 255, 0.07),
    inset -1px -1px 0px rgba(0, 0, 0, 0.45),
    0 20px 40px -10px rgba(0, 0, 0, 0.7);
  position: relative;
  overflow: hidden;
  transform-style: preserve-3d;
  transition: transform 0.6s var(--ease), box-shadow 0.6s, background 0.4s;
}

.gc-style1-p::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 250 250' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  opacity: 0.018;
  mix-blend-mode: overlay;
  pointer-events: none;
  z-index: 5;
}

.gc-style1-p:hover {
  background: radial-gradient(circle at var(--glare-x, 50%) var(--glare-y, 50%), var(--theme-glow, rgba(212, 175, 55, 0.05)) 0%, rgba(0, 0, 0, 0.96) 80%) !important;
  box-shadow: 
    inset 1px 1px 0px rgba(255, 255, 255, 0.12),
    inset -1px -1px 0px rgba(0, 0, 0, 0.5),
    0 25px 50px var(--theme-shadow, rgba(212, 175, 55, 0.15)),
    0 15px 35px -5px rgba(0, 0, 0, 0.6);
}

.gc-style1-p .border-glare {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: radial-gradient(circle 100px at var(--glare-x, 50%) var(--glare-y, 50%), var(--theme-border-glow, rgba(212, 175, 55, 0.9)) 0%, transparent 100%);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  z-index: 15;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.3s, visibility 0.3s;
}

.gc-style1-p:hover .border-glare {
  visibility: visible;
  opacity: 1;
}

.gc-style1-p::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 40%, rgba(255, 255, 255, 0.06) 50%, transparent 60%);
  background-size: 300% 300%;
  background-position: var(--glare-x, 50%) var(--glare-y, 50%);
  opacity: 0;
  mix-blend-mode: normal;
  pointer-events: none;
  z-index: 10;
  transition: opacity 0.3s;
}

.gc-style1-p:hover::before {
  opacity: 1;
}

/* Theme Spectrum Overrides */
.gc-style1-p.theme-gold { --theme-glow: rgba(212, 175, 55, 0.06); --theme-shadow: rgba(212, 175, 55, 0.18); --theme-border-glow: rgba(212, 175, 55, 0.95); }
.gc-style1-p.theme-cyan { --theme-glow: rgba(51, 210, 255, 0.06); --theme-shadow: rgba(51, 210, 255, 0.18); --theme-border-glow: rgba(51, 210, 255, 0.95); }
.gc-style1-p.theme-emerald { --theme-glow: rgba(16, 185, 129, 0.06); --theme-shadow: rgba(16, 185, 129, 0.18); --theme-border-glow: rgba(16, 185, 129, 0.95); }
.gc-style1-p.theme-purple { --theme-glow: rgba(168, 85, 247, 0.06); --theme-shadow: rgba(168, 85, 247, 0.18); --theme-border-glow: rgba(168, 85, 247, 0.95); }
.gc-style1-p.theme-amber { --theme-glow: rgba(245, 158, 11, 0.06); --theme-shadow: rgba(245, 158, 11, 0.18); --theme-border-glow: rgba(245, 158, 11, 0.95); }

/* HUD Top Elements */
.hud-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 20;
}

.pill-meta {
  padding: 4px 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 9999px;
  font-size: 9.5px;
  font-family: var(--font-mono);
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.pill-status {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 9.5px;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.status-gold { color: var(--gold); border-color: rgba(212, 175, 55, 0.25); background: rgba(212, 175, 55, 0.06); }
.status-cyan { color: var(--cyan); border-color: rgba(51, 210, 255, 0.25); background: rgba(51, 210, 255, 0.06); }
.status-emerald { color: var(--emerald); border-color: rgba(16, 185, 129, 0.25); background: rgba(16, 185, 129, 0.06); }

.status-pulse {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  animation: pulse-dot 2s infinite;
}

.pulse-gold { background: var(--gold); box-shadow: 0 0 8px var(--gold); }
.pulse-cyan { background: var(--cyan); box-shadow: 0 0 8px var(--cyan); }
.pulse-emerald { background: var(--emerald); box-shadow: 0 0 8px var(--emerald); }

@keyframes pulse-dot {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50% { transform: scale(1.5); opacity: 1; }
}

.ghost-num {
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  font-family: var(--font);
  font-size: 8rem;
  font-weight: 800;
  color: #ffffff;
  opacity: 0.025;
  line-height: 0.8;
  pointer-events: none;
  z-index: 1;
  transition: all 0.8s var(--ease);
}

.gc-style1-p:hover .ghost-num {
  opacity: 0.06;
  transform: scale(1.05);
}

/* ==========================================================================
   EVIDENCE BADGES
   ========================================================================== */

.evidence-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 11px;
  border-radius: 9999px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: all 0.2s ease;
  cursor: pointer;
  user-select: none;
}

.badge-research {
  background: rgba(212, 175, 55, 0.08);
  border: 1px solid rgba(212, 175, 55, 0.3);
  color: var(--gold);
}

.badge-research:hover {
  background: rgba(212, 175, 55, 0.2);
  border-color: var(--gold);
}

.badge-designed {
  background: rgba(51, 210, 255, 0.08);
  border: 1px solid rgba(51, 210, 255, 0.3);
  color: var(--cyan);
}

.badge-prototype {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: var(--emerald);
}

/* ==========================================================================
   MATRIX COMPARISON TABLE
   ========================================================================== */

.sc-matrix-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.sc-matrix-table th,
.sc-matrix-table td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid var(--line-soft);
  font-size: 13px;
}

.sc-matrix-table th {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.4);
  background: rgba(6, 7, 10, 0.95);
  position: sticky;
  top: 0;
  z-index: 10;
}

.sc-matrix-col-highlight {
  background: rgba(212, 175, 55, 0.03) !important;
  border-left: 1px solid rgba(212, 175, 55, 0.2);
  border-right: 1px solid rgba(212, 175, 55, 0.2);
}

th.sc-matrix-col-highlight {
  color: var(--gold) !important;
  border-top: 1px solid rgba(212, 175, 55, 0.4);
}

.cell-state {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: 4px;
}

.cell-full {
  background: rgba(212, 175, 55, 0.15);
  color: var(--gold);
  border: 1px solid rgba(212, 175, 55, 0.35);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.15);
}

.cell-partial {
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.cell-substrate {
  background: rgba(51, 210, 255, 0.1);
  color: var(--cyan);
  border: 1px solid rgba(51, 210, 255, 0.25);
}

.cell-none {
  background: transparent;
  color: rgba(255, 255, 255, 0.25);
}

/* ==========================================================================
   CLAIM DRAWER & MODAL OVERLAY
   ========================================================================== */

.sc-claim-overlay {
  position: fixed;
  inset: 0;
  background: rgba(2, 3, 5, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 100000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s var(--ease);
}

.sc-claim-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.sc-claim-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(580px, 100vw);
  background: rgba(8, 10, 14, 0.97);
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: -20px 0 70px rgba(0, 0, 0, 0.9);
  z-index: 100001;
  transform: translateX(100%);
  transition: transform 0.35s var(--ease);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sc-claim-drawer.active {
  transform: translateX(0);
}

.sc-claim-drawer-header {
  padding: 24px 32px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.sc-claim-drawer-body {
  padding: 32px;
  overflow-y: auto;
  flex: 1;
}

.sc-claim-drawer-close {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  color: #ffffff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.sc-claim-drawer-close:hover {
  background: rgba(255, 255, 255, 0.15);
}

/* ==========================================================================
   CANONICAL MEDIA FRAME SYSTEM (HARDENED TEMPLATE SPEC)
   ========================================================================== */

.sc-media-frame {
  position: relative;
  width: 100%;
  border-radius: var(--card-radius-lg);
  overflow: hidden;
  background: #080a10;
  border: 1px solid var(--theme-frame-border, rgba(255, 255, 255, 0.1));
  box-shadow: 
    inset 0 1px 1px rgba(255, 255, 255, 0.12),
    inset 0 -2px 8px rgba(0, 0, 0, 0.8),
    0 24px 64px -12px rgba(0, 0, 0, 0.75);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  transition: border-color 0.4s var(--ease), box-shadow 0.4s var(--ease), transform 0.4s var(--ease);
}

.sc-media-frame:hover {
  border-color: var(--theme-accent, rgba(207, 173, 110, 0.45));
  box-shadow: 
    inset 0 1px 1px rgba(255, 255, 255, 0.2),
    inset 0 -2px 10px rgba(0, 0, 0, 0.9),
    0 32px 80px -10px var(--theme-shadow, rgba(0, 0, 0, 0.8));
}

.sc-media-frame img,
.sc-media-frame video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  z-index: 1;
  filter: brightness(0.92) contrast(1.05);
  transition: transform 0.7s var(--ease), filter 0.5s ease;
}

.sc-media-frame:hover img,
.sc-media-frame:hover video {
  transform: scale(1.03);
  filter: brightness(0.98) contrast(1.08);
}

/* Canonical Aspect Ratio Classes */
.aspect-golden {
  aspect-ratio: 1.618 / 1;
}

.aspect-square {
  aspect-ratio: 1 / 1;
}

.aspect-portrait {
  aspect-ratio: 4 / 5;
}

.aspect-cinematic {
  aspect-ratio: 16 / 9;
}

.aspect-ultrawide {
  aspect-ratio: 2 / 1;
}

/* Media Frame Scrim Overlay */
.sc-media-scrim {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(to top, rgba(5, 5, 7, 0.9) 0%, rgba(5, 5, 7, 0.25) 45%, transparent 75%);
  pointer-events: none;
}

/* Media Frame HUD Caption Strip */
.sc-media-caption {
  position: relative;
  z-index: 3;
  padding: 0.9rem 1.3rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: rgba(7, 9, 13, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--font-mono);
  font-size: 11px;
  color: rgba(255, 255, 255, 0.75);
}

.sc-media-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 4;
}

/* ==========================================================================
   PAGE-LEVEL DETERMINISTIC ACCENT THEMING
   ========================================================================== */

:root,
body.theme-page-home,
[data-page-theme="home"] {
  --theme-accent: #cfad6e;
  --theme-accent-rgb: 207, 173, 110;
  --theme-accent-soft: rgba(207, 173, 110, 0.08);
  --theme-frame-border: rgba(207, 173, 110, 0.25);
  --theme-glow: rgba(207, 173, 110, 0.05);
  --theme-shadow: rgba(207, 173, 110, 0.15);
  --theme-border-glow: rgba(207, 173, 110, 0.9);
}

body.theme-page-platform,
[data-page-theme="platform"] {
  --theme-accent: #33d2ff;
  --theme-accent-rgb: 51, 210, 255;
  --theme-accent-soft: rgba(51, 210, 255, 0.08);
  --theme-frame-border: rgba(51, 210, 255, 0.25);
  --theme-glow: rgba(51, 210, 255, 0.05);
  --theme-shadow: rgba(51, 210, 255, 0.15);
  --theme-border-glow: rgba(51, 210, 255, 0.9);
}

body.theme-page-convert,
[data-page-theme="convert"] {
  --theme-accent: #10b981;
  --theme-accent-rgb: 16, 185, 129;
  --theme-accent-soft: rgba(16, 185, 129, 0.08);
  --theme-frame-border: rgba(16, 185, 129, 0.25);
  --theme-glow: rgba(16, 185, 129, 0.05);
  --theme-shadow: rgba(16, 185, 129, 0.15);
  --theme-border-glow: rgba(16, 185, 129, 0.9);
}

body.theme-page-simulation,
[data-page-theme="simulation"] {
  --theme-accent: #818cf8;
  --theme-accent-rgb: 129, 140, 248;
  --theme-accent-soft: rgba(129, 140, 248, 0.08);
  --theme-frame-border: rgba(129, 140, 248, 0.25);
  --theme-glow: rgba(129, 140, 248, 0.05);
  --theme-shadow: rgba(129, 140, 248, 0.15);
  --theme-border-glow: rgba(129, 140, 248, 0.9);
}

body.theme-page-sc0,
[data-page-theme="sc0"] {
  --theme-accent: #eab308;
  --theme-accent-rgb: 234, 179, 8;
  --theme-accent-soft: rgba(234, 179, 8, 0.08);
  --theme-frame-border: rgba(234, 179, 8, 0.3);
  --theme-glow: rgba(234, 179, 8, 0.06);
  --theme-shadow: rgba(234, 179, 8, 0.18);
  --theme-border-glow: rgba(248, 250, 252, 0.95);
}

body.theme-page-capital,
[data-page-theme="capital"] {
  --theme-accent: #f59e0b;
  --theme-accent-rgb: 245, 158, 11;
  --theme-accent-soft: rgba(245, 158, 11, 0.08);
  --theme-frame-border: rgba(245, 158, 11, 0.25);
  --theme-glow: rgba(245, 158, 11, 0.05);
  --theme-shadow: rgba(245, 158, 11, 0.15);
  --theme-border-glow: rgba(245, 158, 11, 0.9);
}

body.theme-page-research,
[data-page-theme="research"] {
  --theme-accent: #38bdf8;
  --theme-accent-rgb: 56, 189, 248;
  --theme-accent-soft: rgba(56, 189, 248, 0.08);
  --theme-frame-border: rgba(56, 189, 248, 0.25);
  --theme-glow: rgba(56, 189, 248, 0.05);
  --theme-shadow: rgba(56, 189, 248, 0.15);
  --theme-border-glow: rgba(56, 189, 248, 0.9);
}

body.theme-page-builders,
[data-page-theme="builders"] {
  --theme-accent: #2dd4bf;
  --theme-accent-rgb: 45, 212, 191;
  --theme-accent-soft: rgba(45, 212, 191, 0.08);
  --theme-frame-border: rgba(45, 212, 191, 0.25);
  --theme-glow: rgba(45, 212, 191, 0.05);
  --theme-shadow: rgba(45, 212, 191, 0.15);
  --theme-border-glow: rgba(45, 212, 191, 0.9);
}

body.theme-page-start,
[data-page-theme="start"] {
  --theme-accent: #94a3b8;
  --theme-accent-rgb: 148, 163, 184;
  --theme-accent-soft: rgba(148, 163, 184, 0.08);
  --theme-frame-border: rgba(148, 163, 184, 0.25);
  --theme-glow: rgba(148, 163, 184, 0.05);
  --theme-shadow: rgba(148, 163, 184, 0.15);
  --theme-border-glow: rgba(148, 163, 184, 0.9);
}

/* ==========================================================================
   SEMANTIC EVIDENCE STATE BADGES (STRICTLY PRESERVED & INDEPENDENT)
   ========================================================================== */

.badge-proven {
  background: rgba(16, 185, 129, 0.1) !important;
  border: 1px solid rgba(16, 185, 129, 0.35) !important;
  color: #10b981 !important;
}

.badge-operational {
  background: rgba(51, 210, 255, 0.1) !important;
  border: 1px solid rgba(51, 210, 255, 0.35) !important;
  color: #33d2ff !important;
}

.badge-simulated {
  background: rgba(168, 85, 247, 0.1) !important;
  border: 1px solid rgba(168, 85, 247, 0.35) !important;
  color: #a855f7 !important;
}

.badge-research {
  background: rgba(212, 175, 55, 0.1) !important;
  border: 1px solid rgba(212, 175, 55, 0.35) !important;
  color: #d4af37 !important;
}

.badge-designed {
  background: rgba(245, 158, 11, 0.1) !important;
  border: 1px solid rgba(245, 158, 11, 0.35) !important;
  color: #f59e0b !important;
}
