:root {
  --bg: #09070b;
  --bg-soft: #120d12;
  --panel: rgba(18, 13, 18, 0.9);
  --panel-strong: rgba(26, 17, 22, 0.98);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(197, 70, 47, 0.35);
  --text: #f8f1ed;
  --muted: #bfaea8;
  --accent: #d24b2f;
  --accent-soft: #f3b366;
  --success: #8fd68b;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
  --serif: "Palatino Linotype", "Book Antiqua", Georgia, serif;
  --sans: "Segoe UI", "Trebuchet MS", Tahoma, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top, rgba(177, 41, 29, 0.35), transparent 32%),
    radial-gradient(circle at 85% 18%, rgba(214, 133, 48, 0.15), transparent 22%),
    linear-gradient(180deg, #170b0d 0%, #09070b 46%, #050407 100%);
  color: var(--text);
  font-family: var(--sans);
}
.Defense Decision Intelligence™ {
  color: #ffffff;
}
.hidden,
.sr-only {
  display: none !important;
}

.gate {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at top, rgba(210, 75, 47, 0.2), transparent 28%),
    linear-gradient(180deg, rgba(7, 5, 9, 0.92), rgba(7, 5, 9, 0.98));
  z-index: 10;
}

.boot-overlay {
  position: fixed;
  inset: 0;
  z-index: 9;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at center, rgba(210, 75, 47, 0.16), transparent 28%),
    linear-gradient(180deg, rgba(8, 6, 10, 0.84), rgba(8, 6, 10, 0.96));
  animation: bootFade 320ms ease;
}

.boot-panel {
  width: min(100%, 560px);
  padding: 28px;
  border-radius: 30px;
  border: 1px solid var(--border-strong);
  background:
    linear-gradient(180deg, rgba(23, 15, 18, 0.98), rgba(11, 9, 13, 0.98));
  box-shadow: var(--shadow);
  transform: scale(0.96);
  animation: bootPanelIn 420ms ease forwards;
}

.boot-panel h2 {
  margin: 0 0 18px;
  font-family: var(--serif);
  font-size: clamp(28px, 4vw, 42px);
}

.boot-meter {
  height: 14px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
}

.boot-meter-fill {
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #802014, var(--accent), var(--accent-soft));
  box-shadow: 0 0 24px rgba(210, 75, 47, 0.45);
  transition: width 700ms ease;
}

.boot-rows {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.boot-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.boot-row span {
  color: var(--accent-soft);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.boot-row strong {
  text-align: right;
}

.boot-stage-label {
  margin: 18px 0 0;
  text-align: center;
  color: #f2ddd6;
  font-family: var(--serif);
  font-size: 18px;
  letter-spacing: 0.02em;
}

.gate-panel,
.control-card,
.status-card,
.panel,
.packet-header {
  backdrop-filter: blur(20px);
}

.gate-panel {
  width: min(100%, 420px);
  padding: 32px;
  border: 1px solid var(--border-strong);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(24, 14, 18, 0.98), rgba(11, 9, 13, 0.98));
  box-shadow: var(--shadow);
  text-align: center;
}

.gate-logo {
  width: 132px;
  height: 132px;
  object-fit: cover;
  border-radius: 26px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent-soft);
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.gate-panel h1,
.hero h2,
.packet-header h3,
.panel h4 {
  font-family: var(--serif);
}

.gate-panel h1 {
  margin: 12px 0 8px;
  font-size: 40px;
}

.gate-copy,
.hero-text,
.packet-subtitle,
.panel-copy,
.selection-summary,
.field span,
.status-card,
.motion-card p,
.roi-grid span {
  color: var(--muted);
}

.gate-input,
.field input,
.field select {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font: inherit;
}

.field select,
.field select option {
  color: var(--text);
}

.field select option {
  background: #120d12;
}

.gate-input {
  margin-top: 18px;
  padding: 15px 18px;
  text-align: center;
  font-size: 18px;
}

.primary-btn {
  border: 0;
  border-radius: 16px;
  padding: 15px 22px;
  background: linear-gradient(135deg, var(--accent), #8e2013);
  color: white;
  font: inherit;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: transform 180ms ease, filter 180ms ease;
}

.primary-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.gate-error {
  min-height: 20px;
  margin: 12px 0 0;
  color: #ff9a8a;
  font-size: 13px;
}

.app-shell {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 64px;
}

.hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 28px;
  align-items: center;
  padding: 32px;
  border: 1px solid var(--border);
  border-radius: 30px;
  background:
    linear-gradient(135deg, rgba(40, 17, 18, 0.95), rgba(17, 10, 14, 0.96));
  box-shadow: var(--shadow);
}

.hero::before {
  content: "";
  position: absolute;
  inset: auto -8% -22% auto;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(210, 75, 47, 0.22), transparent 62%);
  filter: blur(14px);
  animation: heroPulse 6s ease-in-out infinite;
}

.hero-art {
  width: 100%;
  max-width: 600px;
  height: 140px;
  margin: 0 auto
  border-radius: 26px;
  background:
    linear-gradient(135deg, rgba(210, 75, 47, 0.14), rgba(243, 179, 102, 0.05)),
    url("mylogo.png") center / cover no-repeat;
  border: 1px solid rgba(255, 255, 255, 0.06);
  transform: translateY(12px) scale(0.97);
  opacity: 0;
  animation: riseIn 700ms 180ms ease forwards;
}

.hero h2 {
  margin: 0 0 10px;
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1.04;
  max-width: 11ch;
  transform: translateY(18px);
  opacity: 0;
  animation: riseIn 720ms 220ms ease forwards;
}

.hero-text,
.hero-stats {
  transform: translateY(18px);
  opacity: 0;
  animation: riseIn 760ms 340ms ease forwards;
}

.hero-stats {
  display: flex;
  gap: 18px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.hero-stat-card {
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.hero-stats div,
.roi-grid div,
.metric-strip div {
  min-width: 120px;
}

.hero-stats strong,
.roi-grid strong,
.metric-strip strong {
  display: block;
  margin-bottom: 4px;
  font-size: 26px;
  font-family: var(--serif);
  color: var(--text);
}

.control-panel,
.status-row,
.packet {
  margin-top: 18px;
}

.control-card,
.status-card,
.packet-header,
.panel {
  border: 1px solid var(--border);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.control-card {
  padding: 22px;
  border-radius: 26px;
  overflow: visible;
  position: relative;
  z-index: 5;
}

.control-grid {
  display: grid;
  grid-template-columns: 230px 250px minmax(0, 1fr);
  gap: 18px;
}

.field {
  display: block;
}

.field span {
  display: block;
  margin-bottom: 10px;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.field input,
.field select {
  padding: 14px 16px;
}

.field-search {
  position: relative;
  z-index: 20;
}

.search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  z-index: 999;
  max-height: 280px;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 22px;
  background: rgba(19, 13, 18, 0.98);
  box-shadow: var(--shadow);
}

.search-item {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  cursor: pointer;
}

.search-item:last-child {
  border-bottom: 0;
}

.search-item:hover,
.search-item.active {
  background: rgba(210, 75, 47, 0.12);
}

.search-item strong,
.motion-card h5 {
  display: block;
  margin-bottom: 4px;
}

.search-item span,
.motion-card small {
  color: var(--muted);
  font-size: 12px;
}

.control-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-top: 18px;
}

.status-card {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 999px;
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 8px rgba(143, 214, 139, 0.08);
}

.packet-header {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 24px;
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(28, 15, 18, 0.96), rgba(16, 11, 14, 0.98));
}

.packet-header h3 {
  margin: 0 0 6px;
  font-size: 30px;
}

.judge-meaning-header {
  margin: 14px 0 0;
  font-family: var(--serif);
  font-size: 24px;
  line-height: 1.3;
  color: #f4dfd4;
}

.packet-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(160px, 1fr));
  gap: 12px;
  width: min(420px, 100%);
}

.meta-card,
.motion-card {
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
}

.meta-card {
  padding: 12px 14px;
}

.meta-card span {
  display: block;
  margin-bottom: 6px;
  color: var(--accent-soft);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.packet-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.panel {
  padding: 22px;
  border-radius: 24px;
}

.reveal-panel {
  opacity: 0;
  transform: translateY(18px) scale(0.985);
}

.reveal-panel.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition: opacity 420ms ease, transform 420ms ease;
}

.panel-wide {
  grid-column: 1 / -1;
}

.panel-kicker {
  margin: 0 0 10px;
  color: var(--accent-soft);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.panel h4 {
  margin: 0 0 12px;
  font-size: 24px;
}

.bri-panel {
  background:
    radial-gradient(circle at top right, rgba(210, 75, 47, 0.14), transparent 38%),
    linear-gradient(180deg, rgba(31, 14, 18, 0.98), rgba(16, 11, 14, 0.98));
}

.bri-value-wrap {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
}

.bri-topline {
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 18px;
  align-items: center;
}

.bri-dial {
  position: relative;
  width: 160px;
  height: 160px;
  margin: 0 auto;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, rgba(255, 255, 255, 0.03) 0 42%, transparent 43%),
    conic-gradient(from 220deg, rgba(128,32,20,0.8), rgba(210,75,47,0.95), rgba(243,179,102,0.9), rgba(128,32,20,0.8));
  box-shadow: inset 0 0 0 10px rgba(255,255,255,0.05), 0 18px 35px rgba(0,0,0,0.28);
}

.bri-dial-ring {
  position: absolute;
  inset: 12px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.08);
}

.bri-needle {
  position: absolute;
  left: 50%;
  bottom: 50%;
  width: 4px;
  height: 58px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--accent-soft), #fff2d0);
  transform-origin: bottom center;
  transform: translateX(-50%) rotate(-120deg);
  box-shadow: 0 0 20px rgba(243,179,102,0.35);
  transition: transform 1.4s cubic-bezier(.2,.8,.2,1);
}

.bri-dial-center {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff0d6;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 6px rgba(255,255,255,0.08);
}

.bri-first-read {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 12px;
  align-items: end;
  margin: 10px 0 6px;
}

.bri-first-read span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.bri-first-read strong {
  font-family: var(--serif);
  font-size: 24px;
}

.bri-value {
  font-family: var(--serif);
  font-size: 80px;
  line-height: 0.92;
}

.bri-band {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--accent-soft);
  font-size: 12px;
  white-space: nowrap;
}

.meter {
  height: 12px;
  margin: 16px 0 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.meter-fill {
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #a42919, var(--accent), var(--accent-soft));
  transition: width 450ms ease;
}

.metric-strip,
.roi-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.roi-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.bullet-list {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 10px;
  line-height: 1.55;
}

.motion-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.motion-card {
  padding: 16px;
}

.motion-card.is-typing {
  border-color: rgba(243,179,102,0.28);
  box-shadow: inset 0 0 0 1px rgba(243,179,102,0.06);
}

.typewriter-line {
  min-height: 18px;
}

.motion-card h5 {
  margin: 0;
  font-size: 18px;
}

.motion-card p {
  margin: 8px 0 0;
  line-height: 1.55;
}

.motion-card strong {
  color: var(--text);
}

.script-card {
  margin: 0;
  padding: 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  line-height: 1.7;
  color: #f2ddd6;
}

.value-tracker-headline {
  margin: 0 0 10px;
  font-size: 38px;
  line-height: 1;
  color: var(--accent-soft);
}

.value-tracker-lead {
  margin: 0 0 18px;
  color: #f1ddd4;
  font-size: 16px;
  line-height: 1.5;
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes heroPulse {
  0%, 100% {
    transform: scale(1);
    opacity: 0.75;
  }
  50% {
    transform: scale(1.08);
    opacity: 1;
  }
}

@keyframes bootFade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes bootPanelIn {
  from {
    opacity: 0;
    transform: scale(0.94) translateY(12px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@media (max-width: 920px) {
  .hero,
  .packet-header,
  .control-grid,
  .packet-grid,
  .motion-list {
    grid-template-columns: 1fr;
  }

  .hero {
    gap: 20px;
  }

  .control-actions,
  .packet-header {
    flex-direction: column;
    align-items: stretch;
  }

  .packet-meta-grid {
    width: 100%;
  }

  .bri-topline,
  .bri-first-read {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .app-shell {
    width: min(100%, calc(100% - 20px));
    padding-top: 16px;
  }

  .hero,
  .control-card,
  .packet-header,
  .panel,
  .gate-panel {
    padding: 20px;
    border-radius: 22px;
  }

  .hero h2 {
    max-width: none;
  }

  .metric-strip,
  .hero-stats,
  .roi-grid {
    grid-template-columns: 1fr 1fr;
  }

  .bri-value {
    font-size: 62px;
  }
}
