:root {
  --navy: #651d32;
  --blue: #ba202e;
  --blue-dark: #872937;
  --orange: #c7af7f;
  --warm-black: #3e2b2e;
  --highlight: #dfdf00;
  --white: #ffffff;
  --ink: #2a171a;
  --muted: #6b5c60;
  --panel: #e5e5e0;
  --line: rgba(255, 255, 255, 0.18);
  --shadow: 0 22px 50px rgba(3, 15, 34, 0.18);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--panel);
  line-height: 1.55;
}

a {
  color: inherit;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 10;
  padding: 0.7rem 1rem;
  background: var(--orange);
  color: var(--ink);
  font-weight: 800;
}

.skip-link:focus {
  top: 1rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 8;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem clamp(1rem, 3vw, 2.5rem);
  background: rgba(62, 43, 46, 0.94);
  color: var(--white);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  font-weight: 900;
  white-space: nowrap;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 2.3rem;
  height: 2.3rem;
  background: var(--navy);
  color: var(--ink);
  color: var(--white);
  border: 2px solid var(--orange);
  font-size: 0.78rem;
}

nav {
  display: flex;
  align-items: center;
  gap: clamp(0.6rem, 2vw, 1.25rem);
  font-weight: 800;
  font-size: 0.92rem;
}

nav a {
  text-decoration: none;
  opacity: 0.9;
}

nav a:hover,
nav a:focus-visible {
  color: var(--orange);
}

.hero {
  min-height: calc(100vh - 4.2rem);
  display: grid;
  align-items: center;
  overflow: hidden;
  color: var(--white);
  background:
    linear-gradient(135deg, rgba(101, 29, 50, 0.95), rgba(62, 43, 46, 0.9)),
    repeating-linear-gradient(110deg, rgba(199, 175, 127, 0.11) 0 2px, transparent 2px 42px),
    var(--navy);
}

.hero-grid {
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.04fr 0.96fr;
  align-items: center;
  gap: clamp(2rem, 5vw, 5rem);
  padding: clamp(2rem, 6vw, 5rem) 0;
}

.eyebrow {
  margin: 0 0 0.65rem;
  color: var(--orange);
  font-weight: 950;
  text-transform: uppercase;
  font-size: 0.78rem;
}

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

h1 {
  margin: 0;
  max-width: 11ch;
  font-size: clamp(3.2rem, 9vw, 6.4rem);
  line-height: 0.92;
  font-weight: 950;
}

h2 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
  font-weight: 950;
}

h3 {
  margin: 0 0 0.8rem;
  font-size: 1.35rem;
  line-height: 1.15;
}

h4 {
  margin: 1.15rem 0 0.35rem;
  font-size: 0.92rem;
  text-transform: uppercase;
  color: var(--blue-dark);
}

.hero-intro {
  max-width: 42rem;
  margin: 1.2rem 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: 1.1rem;
}

.notice {
  max-width: 46rem;
  padding: 0.9rem 1rem;
  border-left: 5px solid var(--orange);
  background: rgba(255, 255, 255, 0.09);
}

.notice.strong {
  font-weight: 800;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.35rem;
}

.button {
  min-height: 2.85rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.8rem 1rem;
  border: 2px solid transparent;
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 950;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.22);
}

.button.primary {
  background: var(--orange);
  color: var(--ink);
}

.button.secondary {
  background: var(--blue);
  color: var(--white);
}

.button.ghost {
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.45);
}

.hero-visual {
  position: relative;
  min-height: 34rem;
  isolation: isolate;
}

.court-lines {
  position: absolute;
  inset: 5%;
  border: 3px solid rgba(255, 255, 255, 0.26);
  transform: skew(-8deg) rotate(-4deg);
}

.court-lines::before,
.court-lines::after {
  content: "";
  position: absolute;
  border: 3px solid rgba(255, 255, 255, 0.22);
}

.court-lines::before {
  width: 48%;
  height: 48%;
  border-radius: 50%;
  left: 26%;
  top: 24%;
}

.court-lines::after {
  width: 3px;
  height: 100%;
  left: 50%;
  top: 0;
  background: rgba(255, 255, 255, 0.22);
  border: 0;
}

.pulse-ring {
  position: absolute;
  width: 11rem;
  height: 11rem;
  border: 2px solid var(--orange);
  border-radius: 50%;
  opacity: 0.75;
  animation: pulse 2.8s ease-in-out infinite;
}

.ring-one {
  left: 4%;
  top: 10%;
}

.ring-two {
  right: 2%;
  bottom: 11%;
  border-color: var(--highlight);
  animation-delay: 0.8s;
}

.route {
  position: absolute;
  height: 4px;
  background: var(--orange);
  border-radius: 999px;
  box-shadow: 0 0 22px rgba(255, 122, 24, 0.75);
  animation: dash 3s ease-in-out infinite;
}

.route-one {
  width: 62%;
  left: 8%;
  top: 67%;
  transform: rotate(-18deg);
}

.route-two {
  width: 46%;
  right: 9%;
  top: 30%;
  background: var(--highlight);
  box-shadow: 0 0 22px rgba(223, 223, 0, 0.65);
  transform: rotate(28deg);
  animation-delay: 0.4s;
}

.ankle-card {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(78vw, 24rem);
  height: 24rem;
  transform: translate(-50%, -50%);
  border: 2px solid rgba(255, 255, 255, 0.35);
  background: linear-gradient(160deg, rgba(199, 175, 127, 0.24), rgba(255, 255, 255, 0.06));
  box-shadow: var(--shadow);
  animation: float 4s ease-in-out infinite;
}

.shoe-shape {
  position: absolute;
  width: 14rem;
  height: 6rem;
  left: 4.2rem;
  bottom: 5.4rem;
  background: var(--white);
  clip-path: polygon(2% 48%, 55% 26%, 80% 48%, 98% 72%, 82% 87%, 15% 83%);
}

.shoe-shape::after {
  content: "";
  position: absolute;
  left: 2rem;
  right: 2rem;
  bottom: 1.1rem;
  height: 0.55rem;
  background: var(--blue);
}

.ankle-joint {
  position: absolute;
  width: 6rem;
  height: 12rem;
  left: 6.2rem;
  top: 4.2rem;
  background: linear-gradient(180deg, var(--orange), var(--blue-dark));
  transform: rotate(-8deg);
}

.spu-logo-mark {
  position: absolute;
  right: 1.15rem;
  top: 1.15rem;
  width: 9.5rem;
  min-height: 6.8rem;
  display: grid;
  place-items: center;
  align-content: center;
  padding: 0.7rem;
  border: 3px solid var(--orange);
  background: linear-gradient(135deg, var(--navy), var(--warm-black));
  color: var(--white);
  text-align: center;
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.24);
  animation: chip 2.8s ease-in-out infinite;
}

.spu-logo-mark::before,
.spu-logo-mark::after {
  content: "";
  position: absolute;
  left: 0.65rem;
  right: 0.65rem;
  height: 2px;
  background: var(--orange);
}

.spu-logo-mark::before {
  top: 0.55rem;
}

.spu-logo-mark::after {
  bottom: 0.55rem;
}

.spu-logo-main {
  display: block;
  color: var(--white);
  font-weight: 950;
  font-size: 2.85rem;
  line-height: 0.95;
}

.spu-logo-sub {
  display: block;
  margin-top: 0.35rem;
  color: var(--orange);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.section {
  padding: clamp(3.5rem, 8vw, 6.5rem) clamp(1rem, 3vw, 2.5rem);
}

.section-head {
  max-width: 820px;
  margin: 0 auto 2rem;
  text-align: center;
}

.section-head p:not(.eyebrow) {
  color: var(--muted);
  font-size: 1.05rem;
}

.ankle-guide-section,
.prevention-section,
.bibliography-section {
  background: var(--panel);
}

.sprain-grid {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.sprain-card,
.sport-card,
.info-card,
.play-card,
.guide-callout,
.source-notes,
.bibliography-list {
  border: 1px solid rgba(62, 43, 46, 0.16);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 16px 36px rgba(4, 20, 44, 0.09);
}

.sport-grid,
.info-grid,
.play-grid {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 1rem;
}

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

.info-grid,
.play-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.sport-card,
.info-card,
.play-card {
  padding: 1.25rem;
  overflow: hidden;
}

.sprain-card {
  position: relative;
  padding: 1.25rem;
  overflow: hidden;
  border-top: 7px solid var(--navy);
}

.medial-card {
  border-top-color: var(--blue);
}

.high-card {
  border-top-color: var(--warm-black);
}

.guide-tag {
  display: inline-flex;
  margin-bottom: 1rem;
  padding: 0.4rem 0.7rem;
  background: var(--navy);
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 950;
  text-transform: uppercase;
}

.medial-card .guide-tag {
  background: var(--blue);
}

.high-card .guide-tag {
  background: var(--warm-black);
}

.guide-callout {
  width: min(960px, 100%);
  margin: 1rem auto 0;
  padding: 1.25rem;
  border-left: 7px solid var(--orange);
  font-weight: 850;
}

.sport-card {
  border-top: 7px solid var(--orange);
}

.soccer {
  border-top-color: var(--blue);
}

.track {
  border-top-color: var(--warm-black);
}

.card-icon {
  width: 3.2rem;
  height: 3.2rem;
  display: grid;
  place-items: center;
  margin-bottom: 1rem;
  background: var(--warm-black);
  color: var(--white);
  font-size: 1.55rem;
}

ul,
ol {
  padding-left: 1.2rem;
}

li + li {
  margin-top: 0.35rem;
}

.mini-icon {
  width: 2.7rem;
  height: 2.7rem;
  margin-bottom: 0.9rem;
  background: var(--orange);
  clip-path: polygon(50% 0, 100% 35%, 80% 100%, 20% 100%, 0 35%);
}

.mini-icon.mobility {
  background: var(--blue);
  clip-path: circle(50%);
}

.mini-icon.recovery {
  background: var(--navy);
  clip-path: polygon(0 25%, 65% 25%, 65% 0, 100% 50%, 65% 100%, 65% 75%, 0 75%);
}

.mini-icon.swelling {
  background: var(--blue);
  clip-path: polygon(50% 0, 62% 35%, 100% 35%, 69% 58%, 82% 100%, 50% 74%, 18% 100%, 31% 58%, 0 35%, 38% 35%);
}

.urgent {
  border-color: rgba(186, 32, 46, 0.32);
}

.play-card {
  background: var(--navy);
  color: var(--white);
}

.play-card:nth-child(2) {
  background: var(--blue-dark);
}

.play-card:nth-child(3) {
  background: var(--warm-black);
}

.play-card:nth-child(4) {
  background: #2a171a;
}

.play-number {
  display: inline-block;
  margin-bottom: 1.5rem;
  color: var(--orange);
  font-weight: 950;
  font-size: 1.8rem;
}

.source-notes,
.bibliography-list {
  width: min(960px, 100%);
  margin: 0 auto;
  padding: 1.25rem;
}

.bibliography-list li {
  margin-bottom: 0.7rem;
}

.site-footer {
  padding: 1.25rem;
  background: var(--warm-black);
  color: var(--white);
  text-align: center;
  font-weight: 800;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 650ms ease, transform 650ms ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(0.85);
    opacity: 0.45;
  }
  50% {
    transform: scale(1.08);
    opacity: 0.85;
  }
}

@keyframes dash {
  0%,
  100% {
    clip-path: inset(0 85% 0 0);
  }
  50% {
    clip-path: inset(0 0 0 0);
  }
}

@keyframes float {
  0%,
  100% {
    translate: 0 -8px;
  }
  50% {
    translate: 0 12px;
  }
}

@keyframes chip {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-7px) rotate(-1deg);
  }
}

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

  nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 0.25rem;
  }

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

  .hero {
    min-height: auto;
  }

  .hero-visual {
    min-height: 26rem;
  }

  .sprain-grid,
  .sport-grid,
  .info-grid,
  .play-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .sprain-grid,
  .sport-grid,
  .info-grid,
  .play-grid {
    grid-template-columns: 1fr;
  }

  .cta-row .button {
    width: 100%;
  }

  h1 {
    max-width: 9ch;
  }

  .hero-visual {
    min-height: 21rem;
  }

  .ankle-card {
    height: 19rem;
  }

  .shoe-shape {
    left: 2.8rem;
    bottom: 4rem;
    width: 12rem;
  }

  .ankle-joint {
    left: 5rem;
    top: 2.8rem;
  }
}

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