@import url("tokens/tokens.css");

:root {
  --ink: var(--ds-text-on-dark);
  --muted: var(--ds-text2-on-dark);
  --line: var(--ds-line-dark);
  --paper: var(--ds-surface-dark);
  --mist: var(--ds-panel-dark);
  --teal: var(--ds-teal-400);
  --teal-readable: var(--ds-teal-300);
  --white: var(--ds-panel-dark);
  --panel: rgba(30, 48, 80, 0.78);
  --panel-strong: rgba(30, 48, 80, 0.94);
  --shadow: 0 34px 100px rgba(3, 9, 21, 0.38);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #131f35;
  font-family: var(--ds-font-body);
  font-size: 18px;
  line-height: 1.55;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 78px;
  padding: 18px clamp(22px, 5vw, 72px);
  background: rgba(19, 31, 53, 0.9);
  border-bottom: 1px solid rgba(46, 66, 95, 0.9);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  font-family: var(--ds-font-display);
  font-size: clamp(0.88rem, 1.5vw, 1.08rem);
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.brand img {
  display: block;
  width: 54px;
  height: auto;
}

.brand span {
  white-space: nowrap;
}

.nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.3vw, 30px);
  color: var(--muted);
  font-family: var(--ds-font-display);
  font-size: 0.84rem;
  font-weight: 600;
}

.nav a:hover,
.nav a:focus-visible {
  color: var(--ds-text-on-dark);
}

.nav .demo-button {
  margin-left: clamp(4px, 1vw, 10px);
  padding: 9px 14px;
  color: #ffffff;
  background: #c2604d;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  box-shadow: 0 12px 30px rgba(194, 96, 77, 0.28);
}

.nav .demo-button:hover,
.nav .demo-button:focus-visible,
.nav .demo-button[aria-current="page"] {
  color: #ffffff;
  background: #d86d58;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(430px, 1fr);
  gap: clamp(36px, 5vw, 76px);
  align-items: center;
  min-height: calc(100vh - 78px);
  padding: clamp(70px, 9vw, 124px) clamp(22px, 5vw, 72px) clamp(64px, 8vw, 96px);
  overflow: hidden;
  background:
    radial-gradient(circle at 84% 16%, rgba(124, 205, 189, 0.22), transparent 34%),
    radial-gradient(circle at 18% 18%, rgba(69, 133, 194, 0.18), transparent 30%),
    var(--ds-grad-deep);
}

.hero-mark {
  position: absolute;
  right: -130px;
  top: -80px;
  width: min(42vw, 520px);
  min-width: 330px;
  opacity: 0.1;
  pointer-events: none;
}

.hero-copy {
  position: relative;
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 16px;
  color: var(--teal-readable);
  font-family: var(--ds-font-display);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 820px;
  margin-bottom: 26px;
  font-family: var(--ds-font-body);
  font-size: clamp(3.6rem, 7.5vw, 6.4rem);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.01em;
}

h2 {
  margin-bottom: 20px;
  font-family: var(--ds-font-body);
  font-size: clamp(2rem, 4vw, 3.35rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.01em;
}

h3 {
  margin-bottom: 10px;
  font-family: var(--ds-font-body);
  font-size: 1.2rem;
  font-weight: 600;
  line-height: 1.2;
}

.hero-text,
.large-copy,
.section-copy {
  max-width: 720px;
  color: var(--muted);
  font-size: clamp(1.08rem, 1.8vw, 1.28rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 13px 20px;
  border: 1px solid var(--line);
  border-radius: var(--ds-radius);
  font-family: var(--ds-font-display);
  font-size: 0.92rem;
  font-weight: 600;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
}

.button.primary {
  color: var(--ds-surface-dark);
  background: var(--ds-text-on-dark);
  border-color: var(--ds-text-on-dark);
}

.button.secondary {
  color: var(--ds-text-on-dark);
  background: rgba(245, 248, 250, 0.08);
  border-color: rgba(245, 248, 250, 0.2);
}

.risk-panel {
  position: relative;
  width: min(100%, 640px);
  margin-left: auto;
  padding: clamp(20px, 3vw, 30px);
  background: rgba(19, 31, 53, 0.7);
  border: 1px solid rgba(175, 191, 207, 0.2);
  border-radius: var(--ds-radius-lg);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.risk-topline {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
  color: var(--muted);
  font-family: var(--ds-font-display);
  font-size: 0.82rem;
}

.risk-topline strong {
  color: var(--ds-text-on-dark);
}

.wind-demo {
  overflow: hidden;
}

.wind-demo .risk-topline strong {
  color: #7cf0dd;
}

.wind-demo-title {
  max-width: 520px;
  margin: -6px 0 18px;
  color: var(--ds-text-on-dark);
  font-family: var(--ds-font-body);
  font-size: clamp(1.3rem, 2.3vw, 1.72rem);
  font-weight: 400;
  line-height: 1.08;
}

.wind-demo-title em {
  color: #7cf0dd;
  font-style: normal;
}

.storm-stage {
  position: relative;
  height: 378px;
  margin: 0 0 16px;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 12%, rgba(119, 223, 207, 0.08), transparent 38%),
    #08111d;
  border: 1px solid rgba(175, 191, 207, 0.24);
  border-radius: 12px;
  box-shadow:
    inset 0 0 48px rgba(0, 0, 0, 0.52),
    0 18px 42px rgba(2, 8, 16, 0.24);
}

.storm-stage::before {
  content: "";
  position: absolute;
  z-index: 2;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(4, 9, 15, 0.52), transparent 12%, transparent 88%, rgba(4, 9, 15, 0.52)),
    linear-gradient(180deg, rgba(5, 11, 19, 0.08), transparent 52%, rgba(4, 9, 15, 0.42));
  pointer-events: none;
}

.wind-canvas {
  position: absolute;
  z-index: 1;
  inset: 0;
  width: 100%;
  height: 100%;
}

.comparison-stage {
  position: absolute;
  inset: 42px 0 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.comparison-stage::after {
  content: "";
  position: absolute;
  z-index: 2;
  top: 0;
  bottom: 0;
  left: 50%;
  border-left: 1px solid rgba(124, 205, 189, 0.25);
  pointer-events: none;
}

.home-view {
  position: relative;
  min-width: 0;
  overflow: hidden;
  background: #08111d;
  border-top: 1px solid rgba(124, 205, 189, 0.18);
}

.home-title {
  position: relative;
  z-index: 3;
  display: block;
  padding: 9px 11px;
  color: rgba(245, 248, 250, 0.82);
  background: rgba(5, 12, 22, 0.74);
  font-family: var(--ds-font-display);
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  pointer-events: none;
}

.home-view-a {
  border-right: 1px solid rgba(124, 205, 189, 0.28);
}

.home-view-b {
  border-left: 0;
}

.wind-canvas canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: grab;
}

.wind-canvas canvas:active {
  cursor: grabbing;
}

.storm-cloud {
  z-index: 1;
  position: absolute;
  width: 190px;
  height: 48px;
  background: rgba(175, 191, 207, 0.15);
  border-radius: 999px;
  filter: blur(1px);
}

.cloud-one { top: 26px; left: 4%; }
.cloud-two { top: 60px; right: -5%; transform: scale(0.72); }

.wind-direction {
  position: absolute;
  top: 15px;
  left: 18px;
  z-index: 3;
  margin: 0;
  color: rgba(245, 248, 250, 0.65);
  font-family: var(--ds-font-display);
  font-size: 0.59rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.wind-direction span { color: #7cf0dd; }

.scene-hint {
  position: absolute;
  right: 16px;
  bottom: 10px;
  z-index: 3;
  margin: 0;
  color: rgba(245, 248, 250, 0.5);
  font-family: var(--ds-font-display);
  font-size: 0.56rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  pointer-events: none;
}

.stress-scale {
  position: absolute;
  z-index: 5;
  right: 14px;
  bottom: 11px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(245, 248, 250, 0.62);
  font-family: var(--ds-font-display);
  font-size: 0.46rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  pointer-events: none;
}

.stress-scale i {
  display: block;
  width: 82px;
  height: 6px;
  background: linear-gradient(90deg, #53d9c1 0%, #f1d36f 42%, #f07b48 68%, #c51f36 100%);
  border: 1px solid rgba(245, 248, 250, 0.28);
  border-radius: 999px;
  box-shadow: 0 0 10px rgba(197, 31, 54, 0.2);
}

.tunnel-readout {
  position: absolute;
  z-index: 4;
  top: 12px;
  right: 16px;
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 0;
  color: rgba(245, 248, 250, 0.4);
  font-family: var(--ds-font-display);
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  pointer-events: none;
}

.tunnel-readout strong {
  color: rgba(124, 240, 221, 0.72);
  font-size: inherit;
}

.damage-tag {
  position: absolute;
  z-index: 4;
  left: 11px;
  bottom: 13px;
  max-width: calc(100% - 22px);
  padding: 5px 8px;
  color: #c5fff4;
  background: rgba(5, 12, 22, 0.76);
  border: 1px solid rgba(124, 240, 221, 0.3);
  border-radius: 999px;
  box-shadow: 0 5px 18px rgba(0, 0, 0, 0.28);
  font-family: var(--ds-font-display);
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  pointer-events: none;
  backdrop-filter: blur(7px);
}

.damage-tag-minor {
  color: #d5e6df;
  border-color: rgba(136, 203, 187, 0.5);
}

.damage-tag-moderate {
  color: #f3d496;
  border-color: rgba(226, 184, 105, 0.58);
}

.damage-tag-high,
.damage-tag-critical {
  color: #ffb7a8;
  background: rgba(54, 19, 18, 0.76);
  border-color: rgba(241, 93, 84, 0.62);
}

.wind-streams {
  position: absolute;
  inset: 45px 0 0;
  overflow: hidden;
  pointer-events: none;
}

.wind-streams i {
  position: absolute;
  display: block;
  width: 76px;
  height: 12px;
  border-top: 2px solid rgba(124, 240, 221, 0.76);
  border-radius: 50%;
  animation: wind-pass 2.8s linear infinite;
}

.wind-streams i:nth-child(1) { top: 30px; left: -90px; }
.wind-streams i:nth-child(2) { top: 72px; left: -160px; width: 110px; animation-delay: -1.3s; }
.wind-streams i:nth-child(3) { top: 118px; left: -60px; width: 55px; animation-delay: -2.1s; }
.wind-streams i:nth-child(4) { top: 152px; left: -140px; width: 94px; animation-delay: -0.7s; }
.wind-streams i:nth-child(5) { top: 202px; left: -210px; width: 135px; animation-delay: -1.8s; }
.wind-streams i:nth-child(6) { top: 224px; left: -80px; width: 68px; animation-delay: -0.2s; }

@keyframes wind-pass {
  to { transform: translateX(690px); }
}

.ground-line {
  position: absolute;
  right: 0;
  bottom: 44px;
  left: 0;
  height: 3px;
  background: rgba(124, 205, 189, 0.55);
}

.house-scene {
  position: absolute;
  z-index: 3;
  bottom: 47px;
  width: 40%;
  height: 165px;
}

.resilient { left: 8%; }
.vulnerable { right: 8%; }

.house {
  position: absolute;
  right: 9%;
  bottom: 0;
  width: 134px;
  height: 120px;
}

.house i { position: absolute; display: block; }

.house .wall {
  right: 10px;
  bottom: 0;
  width: 108px;
  height: 72px;
  background: #d6e0e3;
  border: 3px solid #9cbdc1;
  border-bottom: 0;
}

.house .roof {
  right: 0;
  bottom: 67px;
  width: 0;
  height: 0;
  border-right: 68px solid transparent;
  border-bottom: 48px solid #4e7591;
  border-left: 68px solid transparent;
}

.house .chimney {
  right: 29px;
  bottom: 102px;
  width: 15px;
  height: 34px;
  background: #b8c7ce;
  border: 2px solid #7891a1;
}

.house .window {
  bottom: 29px;
  width: 18px;
  height: 22px;
  background: #27516d;
  border: 3px solid #7ab9bc;
}

.house .window-left { left: 37px; }
.house .window-right { right: 27px; }

.house .door {
  right: 62px;
  bottom: 0;
  width: 20px;
  height: 38px;
  background: #395875;
}

.resilient .house .roof {
  right: 4px;
  width: 126px;
  height: 50px;
  border: 0;
  background: linear-gradient(135deg, #3b6985, #5e91a4);
  clip-path: polygon(15% 0, 85% 0, 100% 100%, 0 100%);
}

.resilient .house .window {
  box-shadow: -5px 0 0 #82aaa9, 5px 0 0 #82aaa9;
}

.tree {
  position: absolute;
  bottom: 0;
  left: 1%;
  width: 70px;
  height: 145px;
  transform-origin: bottom center;
  animation: tree-sway 2.4s ease-in-out infinite;
}

.tree::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 32px;
  width: 9px;
  height: 76px;
  background: #6b6256;
}

.tree i {
  position: absolute;
  width: 54px;
  height: 54px;
  background: #58a38d;
  border: 3px solid #7ccdbd;
  border-radius: 50%;
}

.tree i:nth-child(1) { top: 5px; left: 5px; }
.tree i:nth-child(2) { top: 33px; left: -7px; }
.tree i:nth-child(3) { top: 35px; right: -4px; }

@keyframes tree-sway {
  50% { transform: rotate(5deg); }
}

.vulnerable .house { animation: house-rattle 0.65s ease-in-out infinite; }
.vulnerable .house .roof { border-bottom-color: #607a8c; }
.vulnerable .house .chimney { transform: rotate(3deg); transform-origin: bottom; }
.loose-shingle {
  z-index: 1;
  right: 2px;
  bottom: 94px;
  width: 22px;
  height: 11px;
  background: #8ba5b3;
  transform: rotate(-30deg);
  animation: shingle-lift 1.2s ease-in-out infinite;
}

@keyframes house-rattle {
  50% { transform: translateX(2px) rotate(0.8deg); }
}

@keyframes shingle-lift {
  50% { transform: translate(11px, -10px) rotate(-62deg); }
}

.house-results {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.property-controls {
  display: grid;
  grid-template-columns: minmax(114px, auto) minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  margin-top: 4px;
  padding: 11px 12px;
  background: rgba(12, 23, 41, 0.42);
  border: 1px solid rgba(124, 205, 189, 0.27);
  border-radius: 10px;
}

.property-controls label {
  color: var(--muted);
  font-family: var(--ds-font-display);
  font-size: 0.57rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.property-controls select {
  width: 100%;
  min-width: 0;
  padding: 7px 27px 7px 10px;
  color: var(--ds-text-on-dark);
  appearance: none;
  background: linear-gradient(45deg, transparent 50%, #7cf0dd 50%) calc(100% - 13px) 52% / 5px 5px no-repeat,
    linear-gradient(135deg, #7cf0dd 50%, transparent 50%) calc(100% - 8px) 52% / 5px 5px no-repeat,
    rgba(86, 184, 166, 0.12);
  border: 1px solid rgba(124, 205, 189, 0.3);
  border-radius: 7px;
  font-family: var(--ds-font-display);
  font-size: 0.66rem;
  font-weight: 600;
  cursor: pointer;
}

.property-controls select:focus-visible {
  outline: 2px solid #7cf0dd;
  outline-offset: 2px;
}

.wind-control {
  display: grid;
  grid-template-columns: minmax(130px, auto) minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  margin-top: 12px;
  padding: 10px 2px 2px;
}

.wind-control label {
  display: flex;
  flex-direction: column;
  color: var(--muted);
  font-family: var(--ds-font-display);
  font-size: 0.57rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.wind-control output {
  margin-top: 2px;
  color: #7cf0dd;
  font-size: 0.86rem;
  letter-spacing: 0;
}

.wind-control input {
  width: 100%;
  accent-color: #7cf0dd;
}

.damage-panel {
  display: grid;
  grid-template-columns: minmax(110px, 0.8fr) minmax(110px, 1.2fr);
  gap: 5px 16px;
  align-items: center;
  margin-top: 11px;
  padding: 12px;
  background: rgba(12, 23, 41, 0.42);
  border: 1px solid rgba(175, 191, 207, 0.16);
  border-left: 3px solid #7cf0dd;
  border-radius: 10px;
}

.damage-comparison {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
  margin-top: 11px;
}

.damage-comparison .damage-panel {
  margin-top: 0;
  grid-template-columns: 1fr;
}

.damage-panel > div:first-child {
  display: flex;
  flex-direction: column;
}

.damage-label {
  color: var(--muted);
  font-family: var(--ds-font-display);
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.damage-level {
  color: #7cf0dd;
  font-family: var(--ds-font-display);
  font-size: 1rem;
}

.damage-meter {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
}

.damage-meter i {
  display: block;
  height: 8px;
  background: rgba(175, 191, 207, 0.2);
  border-radius: 999px;
}

.damage-low .damage-meter i:nth-child(-n + 1),
.damage-minor .damage-meter i:nth-child(-n + 2),
.damage-moderate .damage-meter i:nth-child(-n + 3),
.damage-high .damage-meter i:nth-child(-n + 4),
.damage-severe .damage-meter i:nth-child(-n + 4),
.damage-critical .damage-meter i:nth-child(-n + 5) { background: currentColor; }

.damage-panel { color: #7cf0dd; }
.damage-minor { color: #88cbbb; border-left-color: #88cbbb; }
.damage-moderate { color: #e2b869; border-left-color: #e2b869; }
.damage-high { color: #e08a6e; border-left-color: #e08a6e; }
.damage-severe { color: #eb6f61; border-left-color: #eb6f61; }
.damage-critical { color: #f15d54; border-left-color: #f15d54; }
.damage-panel .damage-level { color: currentColor; }

.damage-detail {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--muted);
  font-family: var(--ds-font-display);
  font-size: 0.59rem;
  line-height: 1.35;
}

.house-result {
  padding: 13px;
  background: rgba(12, 23, 41, 0.42);
  border: 1px solid rgba(175, 191, 207, 0.16);
  border-radius: 10px;
}

.result-heading {
  display: flex;
  align-items: center;
  gap: 7px;
  font-family: var(--ds-font-display);
  font-size: 0.7rem;
}

.result-heading strong { color: var(--ds-text-on-dark); }
.result-heading span:last-child { margin-left: auto; color: var(--muted); }
.result-dot { width: 7px; height: 7px; border-radius: 50%; background: #7cf0dd; }
.vulnerable-result .result-dot { background: #d86d58; }

.house-result p {
  margin: 8px 0 10px;
  color: var(--muted);
  font-family: var(--ds-font-display);
  font-size: 0.59rem;
  line-height: 1.35;
}

.damage-score {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(175, 191, 207, 0.15);
}

.damage-score span {
  color: rgba(175, 191, 207, 0.8);
  font-family: var(--ds-font-display);
  font-size: 0.56rem;
  font-weight: 600;
  text-transform: uppercase;
}

.damage-score strong {
  color: #7cf0dd;
  font-family: var(--ds-font-display);
  font-size: 0.78rem;
}

.vulnerable-result .damage-score strong { color: #eb8b77; }

.demo-note {
  margin: 14px 2px 0;
  color: var(--muted);
  font-family: var(--ds-font-display);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.section {
  padding: clamp(70px, 9vw, 120px) clamp(22px, 5vw, 72px);
  border-top: 1px solid var(--line);
}

.section.compact {
  display: grid;
  grid-template-columns: minmax(280px, 0.85fr) minmax(320px, 1.15fr);
  gap: clamp(32px, 7vw, 96px);
  align-items: start;
  background: var(--ds-surface-dark);
}

.section-intro {
  max-width: 860px;
}

.problem-copy {
  display: grid;
  gap: 28px;
}

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

.stat {
  padding: 22px;
  background: var(--panel);
  border: 1px solid rgba(175, 191, 207, 0.16);
  border-radius: var(--ds-radius-lg);
}

.stat strong {
  display: block;
  margin-bottom: 8px;
  color: var(--ds-text-on-dark);
  font-family: var(--ds-font-display);
  font-size: clamp(2rem, 4vw, 3.1rem);
  font-weight: 600;
  line-height: 1;
}

.stat span {
  color: var(--muted);
  font-family: var(--ds-font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.split {
  display: grid;
  grid-template-columns: minmax(280px, 0.78fr) minmax(320px, 1.22fr);
  gap: clamp(32px, 7vw, 96px);
  background: linear-gradient(135deg, #16243d 0%, #1e3050 100%);
}

.steps {
  display: grid;
  gap: 12px;
}

.steps article,
.product-grid article {
  padding: 26px;
  background: var(--panel);
  border: 1px solid rgba(175, 191, 207, 0.16);
  border-radius: var(--ds-radius-lg);
}

.steps article:nth-child(2) {
  border-color: var(--teal);
  box-shadow: inset 0 0 0 1px rgba(86, 184, 166, 0.32);
}

.steps article span {
  display: block;
  margin-bottom: 26px;
  color: var(--teal-readable);
  font-family: var(--ds-font-display);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.steps p,
.product-grid p {
  margin-bottom: 0;
  color: var(--muted);
}

.products {
  background: var(--ds-surface-dark);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 34px;
}

.demo {
  display: grid;
  grid-template-columns: minmax(280px, 0.82fr) minmax(420px, 1.18fr);
  gap: clamp(32px, 7vw, 96px);
  align-items: center;
  background: linear-gradient(135deg, #131f35 0%, #1e3050 100%);
}

.demo-page {
  min-height: calc(100vh - 78px);
}

.demo-page h1 {
  max-width: 680px;
  font-size: clamp(3.4rem, 6.5vw, 5.8rem);
}

.demo-panel {
  padding: clamp(18px, 3vw, 28px);
  background: rgba(19, 31, 53, 0.72);
  border: 1px solid rgba(175, 191, 207, 0.18);
  border-radius: var(--ds-radius-lg);
  box-shadow: var(--shadow);
}

.demo-map {
  display: block;
  width: 100%;
  aspect-ratio: 1.62;
  overflow: hidden;
  border: 1px solid rgba(175, 191, 207, 0.14);
  border-radius: 12px;
  background: #15243c;
}

.map-bg {
  fill: #172842;
}

.map-road {
  fill: none;
  stroke: rgba(175, 191, 207, 0.24);
  stroke-width: 22;
  stroke-linecap: round;
}

.map-road.wide {
  stroke-width: 42;
  stroke: rgba(175, 191, 207, 0.18);
}

.map-road.small {
  stroke-width: 14;
}

.buildings polygon {
  fill: rgba(175, 191, 207, 0.22);
  stroke: rgba(245, 248, 250, 0.42);
  stroke-width: 3;
  stroke-linejoin: round;
}

.buildings .target-building {
  fill: rgba(86, 184, 166, 0.28);
  stroke: #7cf0dd;
  stroke-width: 7;
  filter: url("#softGlow");
}

.wind-band {
  fill: none;
  stroke: rgba(124, 205, 189, 0.1);
  stroke-width: 68;
  stroke-linecap: round;
}

.wind-vector {
  fill: none;
  stroke: #7cf0dd;
  stroke-width: 9;
  stroke-linecap: round;
  marker-end: url("#windArrow");
}

.wind-vector.secondary {
  stroke: rgba(124, 205, 189, 0.44);
  stroke-width: 4;
}

#windArrow path {
  fill: #7cf0dd;
}

.site-dot {
  fill: var(--ds-text-on-dark);
  stroke: var(--ds-surface-dark);
  stroke-width: 5;
}

.demo-label,
.wind-label {
  fill: var(--ds-text-on-dark);
  font-family: var(--ds-font-display);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.wind-label {
  fill: var(--ds-teal-300);
}

.demo-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 20px;
  margin-top: 16px;
  color: var(--ds-text2-on-dark);
  font-family: var(--ds-font-display);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.demo-legend span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.demo-legend i {
  display: inline-block;
  width: 18px;
  height: 10px;
  border-radius: 999px;
}

.legend-building {
  background: rgba(175, 191, 207, 0.36);
}

.legend-target {
  background: rgba(86, 184, 166, 0.8);
}

.legend-wind {
  background: #7cf0dd;
}

.background {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(360px, 1.1fr);
  gap: clamp(32px, 7vw, 96px);
  align-items: center;
  background: linear-gradient(180deg, #16243d 0%, #131f35 100%);
}

.background .large-copy {
  margin-bottom: 0;
}

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

.logo-card {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 132px;
  padding: 28px;
  background: rgba(245, 248, 250, 0.96);
  border: 1px solid rgba(175, 191, 207, 0.16);
  border-radius: 12px;
}

.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 190px;
  height: 76px;
}

.logo-mark img {
  display: block;
  max-width: 148px;
  max-height: 54px;
  object-fit: contain;
}

.harvard .logo-mark img {
  max-width: 148px;
}

.berkeley .logo-mark img {
  max-width: 52px;
  max-height: 52px;
}

.nasa .logo-mark img {
  max-width: 70px;
  max-height: 56px;
}

.contact {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: clamp(58px, 8vw, 92px) clamp(22px, 5vw, 72px);
  overflow: hidden;
  color: var(--ds-text-on-dark);
  background: var(--ds-grad-deep);
}

.contact::before {
  content: "";
  position: absolute;
  left: -140px;
  bottom: -125px;
  width: 520px;
  height: 290px;
  background: url("assets/logo-mark-reversed.svg") center / contain no-repeat;
  opacity: 0.12;
  pointer-events: none;
}

.contact > * {
  position: relative;
}

.contact h2 {
  max-width: 850px;
  margin-bottom: 0;
  font-family: var(--ds-font-body);
  font-weight: 400;
}

.contact .eyebrow {
  color: var(--ds-teal-300);
}

.contact .button.primary {
  flex: 0 0 auto;
  color: var(--ds-surface-dark);
  background: var(--ds-text-on-dark);
  border-color: var(--ds-text-on-dark);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 24px clamp(22px, 5vw, 72px);
  color: var(--ds-text2-on-dark);
  background: #131f35;
  border-top: 1px solid var(--line);
  font-family: var(--ds-font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

@media (max-width: 980px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    position: static;
  }

  .nav {
    flex-wrap: wrap;
  }

  .hero,
  .section.compact,
  .split,
  .demo,
  .background {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .risk-panel {
    margin-left: 0;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .contact {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 17px;
  }

  .site-header {
    gap: 18px;
  }

  .brand {
    letter-spacing: 0.18em;
  }

  .nav {
    width: 100%;
    justify-content: space-between;
    gap: 10px;
    font-size: 0.78rem;
  }

  h1 {
    font-size: 3.25rem;
  }

  .eyebrow {
    letter-spacing: 0.18em;
  }

  .hero-actions {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .stat-row,
  .logo-grid {
    grid-template-columns: 1fr;
  }

  .risk-topline,
  .site-footer {
    flex-direction: column;
  }

  .storm-stage {
    height: 310px;
  }

  .house-scene {
    width: 45%;
    transform: scale(0.82);
  }

  .resilient { left: -4%; }
  .vulnerable { right: -4%; }

  .house-results {
    gap: 7px;
  }

  .wind-control {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .property-controls,
  .damage-panel {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .damage-comparison {
    grid-template-columns: 1fr;
  }

  .home-title {
    padding: 7px 8px;
    font-size: 0.47rem;
  }

  .damage-tag {
    left: 7px;
    bottom: 8px;
    max-width: calc(100% - 14px);
    font-size: 0.45rem;
  }

  .tunnel-readout,
  .scene-hint,
  .stress-scale {
    display: none;
  }

  .damage-detail {
    grid-column: auto;
  }

  .house-result {
    padding: 10px;
  }

  .house-result p {
    font-size: 0.52rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .wind-streams i,
  .tree,
  .vulnerable .house,
  .loose-shingle {
    animation: none;
  }
}

/* Storm damage demo */
.demo-body {
  background:
    radial-gradient(circle at 80% 0%, rgba(124, 205, 189, 0.1), transparent 31rem),
    #131f35;
}

.damage-demo {
  padding: 12px 12px 28px;
}

.selected-building small,
.map-title-card small {
  color: #90a3b8;
  font-family: var(--ds-font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.map-workspace {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  min-height: calc(100svh - 102px);
  max-width: none;
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid rgba(175, 191, 207, 0.18);
  border-radius: 18px;
  background: #172842;
  box-shadow: 0 32px 90px rgba(3, 9, 21, 0.42);
}

.map-sidebar {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  padding: 27px 20px 20px;
  background: linear-gradient(180deg, #1b2c48 0%, #15243c 100%);
  border-right: 1px solid rgba(175, 191, 207, 0.14);
}

.map-sidebar-top {
  padding: 0 8px;
}

.map-kicker {
  margin-bottom: 8px;
  color: #7cf0dd;
  font-family: var(--ds-font-display);
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.map-sidebar h1 {
  margin-bottom: 10px;
  font-family: var(--ds-font-display);
  font-size: 1.42rem;
  font-weight: 700;
  line-height: 1.15;
}

.map-instruction {
  margin-bottom: 22px;
  color: #9fb0c2;
  font-size: 0.82rem;
  line-height: 1.48;
}

.damage-filters {
  display: grid;
  gap: 5px;
}

.damage-filter {
  display: grid;
  grid-template-columns: 12px 1fr auto;
  gap: 11px;
  align-items: center;
  width: 100%;
  padding: 9px 10px;
  color: #c9d4df;
  text-align: left;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  cursor: pointer;
  transition: 150ms ease;
}

.damage-filter:hover,
.damage-filter:focus-visible {
  color: #ffffff;
  outline: none;
  background: rgba(255, 255, 255, 0.055);
}

.damage-filter.is-active {
  color: #ffffff;
  border-color: rgba(124, 240, 221, 0.22);
  background: rgba(124, 240, 221, 0.08);
}

.damage-filter > span:nth-child(2) {
  display: grid;
}

.damage-filter strong {
  font-family: var(--ds-font-display);
  font-size: 0.77rem;
  font-weight: 700;
  line-height: 1.15;
}

.damage-filter small {
  color: #8295aa;
  font-size: 0.62rem;
}

.damage-filter b {
  min-width: 2.3rem;
  color: #9fb0c2;
  font-family: var(--ds-font-display);
  font-size: 0.68rem;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.filter-dot,
.detail-swatch {
  width: 10px;
  height: 10px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 3px;
  background: var(--swatch);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.04);
}

.filter-all {
  background: linear-gradient(135deg, #42c7ae 0 25%, #f2cc60 25% 50%, #f08a5d 50% 75%, #e34f61 75%);
}

.filter-none { background: #42c7ae; }
.filter-minor { background: #f2cc60; }
.filter-major { background: #f08a5d; }
.filter-destroyed { background: #e34f61; }
.filter-unknown { background: #93a4b8; }

.selected-building {
  display: flex;
  gap: 12px;
  align-items: center;
  min-height: 68px;
  margin-top: auto;
  padding: 13px 14px;
  border: 1px solid rgba(175, 191, 207, 0.14);
  border-radius: 11px;
  background: rgba(7, 16, 30, 0.26);
}

.selected-building > span:last-child {
  display: grid;
  min-width: 0;
}

.selected-building strong {
  color: #ffffff;
  font-family: var(--ds-font-display);
  font-size: 0.78rem;
}

.selected-building em {
  overflow: hidden;
  color: #8498ad;
  font-family: var(--ds-font-display);
  font-size: 0.58rem;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.selection-icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  color: #7cf0dd;
  border: 1px solid rgba(124, 240, 221, 0.25);
  border-radius: 50%;
  background: rgba(124, 240, 221, 0.08);
}

.map-stage {
  position: relative;
  min-height: 590px;
  overflow: hidden;
  background: #dce2e2;
}

.damage-map {
  position: absolute;
  inset: 0;
  background: #dce2e2;
}

.map-title-card,
.swipe-label,
.map-readout,
.map-compass {
  position: absolute;
  z-index: 500;
}

.map-title-card,
.swipe-label,
.map-readout,
.map-compass {
  pointer-events: none;
}

.map-title-card {
  top: 18px;
  left: 18px;
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 11px 14px;
  color: #13243b;
  border: 1px solid rgba(18, 36, 59, 0.12);
  border-radius: 10px;
  background: rgba(250, 251, 249, 0.94);
  box-shadow: 0 9px 28px rgba(16, 35, 56, 0.14);
  backdrop-filter: blur(12px);
}

.map-title-card > span:last-child {
  display: grid;
}

.map-title-card small {
  color: #617287;
}

.map-title-card strong {
  font-family: var(--ds-font-display);
  font-size: 0.75rem;
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e34f61;
  box-shadow: 0 0 0 4px rgba(227, 79, 97, 0.13);
}

.swipe-label {
  top: 18px;
  padding: 7px 10px;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(18, 36, 59, 0.76);
  font-family: var(--ds-font-display);
  font-size: 0.61rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  box-shadow: 0 8px 24px rgba(16, 35, 56, 0.16);
  backdrop-filter: blur(12px);
  white-space: nowrap;
}

.swipe-label-left {
  left: calc(50% - 42px);
  transform: translateX(-100%);
}

.swipe-label-right {
  left: calc(50% + 42px);
}

.swipe-divider {
  position: absolute;
  z-index: 520;
  top: 0;
  bottom: 0;
  width: 42px;
  transform: translateX(-50%);
  cursor: ew-resize;
  touch-action: none;
}

.swipe-divider::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  content: "";
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 0 0 1px rgba(18, 36, 59, 0.18), 0 0 18px rgba(18, 36, 59, 0.34);
  transform: translateX(-50%);
}

.swipe-divider span {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: 39px;
  height: 39px;
  color: #172842;
  border: 2px solid #ffffff;
  border-radius: 50%;
  background: rgba(250, 251, 249, 0.96);
  font-family: var(--ds-font-display);
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: -0.18em;
  box-shadow: 0 8px 24px rgba(16, 35, 56, 0.26);
  transform: translate(-50%, -50%);
}

.swipe-divider:focus-visible {
  outline: none;
}

.swipe-divider:focus-visible span {
  outline: 3px solid #7cf0dd;
  outline-offset: 3px;
}

.map-readout {
  right: 18px;
  top: 62px;
  padding: 8px 11px;
  color: #263950;
  border: 1px solid rgba(18, 36, 59, 0.1);
  border-radius: 999px;
  background: rgba(250, 251, 249, 0.92);
  font-family: var(--ds-font-display);
  font-size: 0.63rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  box-shadow: 0 8px 24px rgba(16, 35, 56, 0.1);
}

.map-compass {
  right: 23px;
  top: 110px;
  display: grid;
  justify-items: center;
  color: #1d334d;
  font-family: var(--ds-font-display);
  font-size: 0.58rem;
  font-weight: 800;
}

.map-compass i {
  width: 0;
  height: 0;
  border-right: 5px solid transparent;
  border-bottom: 17px solid #1d334d;
  border-left: 5px solid transparent;
}

.damage-map .leaflet-control-zoom {
  overflow: hidden;
  border: 1px solid rgba(18, 36, 59, 0.14);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(16, 35, 56, 0.12);
}

.damage-map .leaflet-control-zoom a {
  color: #1d334d;
  background: rgba(250, 251, 249, 0.95);
}

.damage-map .leaflet-control-attribution {
  color: #657589;
  background: rgba(250, 251, 249, 0.8);
  font-size: 9px;
}

.damage-map .leaflet-control-attribution a {
  color: #344c66;
}

.damage-tooltip {
  color: #172842;
  border: 0;
  border-radius: 6px;
  font-family: var(--ds-font-display);
  font-size: 0.68rem;
  font-weight: 700;
  box-shadow: 0 7px 20px rgba(16, 35, 56, 0.2);
}

.demo-source {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  max-width: none;
  margin: 18px auto 0;
  color: #8fa2b7;
  font-size: 0.7rem;
}

.demo-source p {
  margin: 0;
}

.demo-source a {
  color: #7cf0dd;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.demo-source > span {
  flex: 0 0 auto;
  font-family: var(--ds-font-display);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

@media (max-width: 980px) {
  .map-workspace {
    grid-template-columns: 260px minmax(0, 1fr);
    min-height: calc(100svh - 142px);
  }
}

@media (max-width: 760px) {
  .damage-demo {
    padding: 8px 8px 24px;
  }

  .map-workspace {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .map-title-card {
    display: none;
  }

  .map-sidebar {
    border-right: 0;
    border-bottom: 1px solid rgba(175, 191, 207, 0.14);
  }

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

  .selected-building {
    margin-top: 16px;
  }

  .map-stage {
    min-height: 520px;
  }

  .map-readout {
    top: auto;
    right: auto;
    bottom: 25px;
    left: 12px;
  }

  .map-compass {
    right: 18px;
    top: 66px;
  }

  .demo-source {
    flex-direction: column;
    gap: 8px;
  }
}

@media (max-width: 480px) {
  .damage-filters {
    grid-template-columns: 1fr;
  }

  .map-stage {
    min-height: 470px;
  }

  .swipe-label {
    top: 12px;
    padding: 6px 8px;
    font-size: 0.54rem;
  }

  .swipe-label-left {
    left: 12px;
    transform: none;
  }

  .swipe-label-right {
    right: 12px;
    left: auto;
  }
}
