:root {
  color-scheme: dark;
  --primary: #03071e;
  --primary-rgb: 3, 7, 30;
  --surface: rgba(255, 255, 255, 0.1);
  --surface-strong: rgba(255, 255, 255, 0.16);
  --text: #f8fafc;
  --muted: #c8d2e3;
  --line: rgba(255, 255, 255, 0.18);
  --accent: #38bdf8;
  --accent-strong: #7dd3fc;
  --radius: 8px;
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.36);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--primary);
}

body {
  position: relative;
  isolation: isolate;
  min-width: 320px;
  min-height: 100svh;
  margin: 0;
  background:
    radial-gradient(circle at 16% 12%, rgba(56, 189, 248, 0.2), transparent 28rem),
    linear-gradient(145deg, #03071e 0%, #07112d 54%, #03071e 100%);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 4px;
}

.background-video,
.background-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

.background-video {
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.05);
}

.background-overlay {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(var(--primary-rgb), 0.93) 0%, rgba(var(--primary-rgb), 0.82) 48%, rgba(var(--primary-rgb), 0.7) 100%),
    rgba(var(--primary-rgb), 0.76);
}

.page-shell {
  position: relative;
  z-index: 2;
  width: min(1120px, calc(100% - 36px));
  min-height: 100svh;
  margin: 0 auto;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.site-header {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  text-decoration: none;
}

.brand span {
  color: var(--text);
  font-size: 1.08rem;
  font-weight: 800;
}

.hero {
  align-self: center;
  width: 100%;
  padding: clamp(28px, 6vw, 78px) 0 clamp(34px, 7vw, 84px);
}

.eyebrow {
  max-width: 100%;
  margin: 0 0 16px;
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.4;
  text-transform: uppercase;
}

h1,
h2,
p {
  overflow-wrap: anywhere;
}

h1 {
  max-width: 13ch;
  margin: 0;
  color: var(--text);
  font-size: clamp(3.1rem, 9vw, 7rem);
  line-height: 0.95;
  letter-spacing: 0;
}

.hero-copy {
  max-width: 710px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.18rem);
  line-height: 1.72;
}

.cards {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: clamp(32px, 5vw, 56px);
}

.resource-card {
  min-height: 168px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  padding: 18px;
  text-decoration: none;
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.resource-card:hover {
  transform: translateY(-3px);
  border-color: rgba(125, 211, 252, 0.62);
  background: var(--surface-strong);
}

.resource-card h2 {
  margin: 0;
  color: var(--accent-strong);
  font-size: clamp(1rem, 1.4vw, 1.12rem);
  line-height: 1.2;
  letter-spacing: 0;
}

.resource-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.91rem;
  line-height: 1.55;
}

.site-footer {
  padding: 22px 0 24px;
  color: rgba(248, 250, 252, 0.68);
  font-size: 0.82rem;
  line-height: 1.5;
  text-align: center;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 980px) {
  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .resource-card {
    min-height: 150px;
  }
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 28px, 1120px);
  }

  .site-header {
    min-height: 68px;
    padding: 14px 0;
  }

  .hero {
    align-self: start;
    padding: 28px 0 38px;
  }

  h1 {
    max-width: 10ch;
    font-size: clamp(3rem, 16vw, 4.8rem);
  }

  .hero-copy {
    margin-top: 20px;
    font-size: 1rem;
    line-height: 1.65;
  }

  .cards {
    grid-template-columns: 1fr;
    gap: 10px;
    margin-top: 28px;
  }

  .resource-card {
    min-height: 0;
    gap: 12px;
    padding: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  .background-video {
    display: none;
  }
}
