:root {
  color-scheme: dark;
  --canvas: #071411;
  --canvas-deep: #040b09;
  --panel: rgb(14 35 30 / 88%);
  --line: rgb(197 236 214 / 16%);
  --text: #f2f7f3;
  --muted: #a8beb2;
  --moss: #91e6ac;
  --teal: #62d7cf;
  --amber: #ffc96b;
  --danger: #ff9b92;
  --shadow: 0 24px 64px rgb(0 0 0 / 28%);
}

* {
  box-sizing: border-box;
}

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

body {
  min-width: 320px;
  margin: 0;
  background:
    radial-gradient(circle at 12% 0%, rgb(84 202 143 / 15%), transparent 29rem),
    radial-gradient(circle at 90% 13%, rgb(77 185 181 / 12%), transparent 26rem),
    linear-gradient(155deg, var(--canvas) 0%, var(--canvas-deep) 70%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
}

body::before {
  position: fixed;
  z-index: -1;
  inset: 0;
  background-image: linear-gradient(rgb(255 255 255 / 2%) 1px, transparent 1px), linear-gradient(90deg, rgb(255 255 255 / 2%) 1px, transparent 1px);
  background-size: 44px 44px;
  content: "";
  mask-image: linear-gradient(to bottom, black, transparent 62%);
  pointer-events: none;
}

a {
  color: var(--moss);
  text-underline-offset: 0.18em;
}

a:hover {
  color: #d0ffdf;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 4px;
}

.page-shell {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 32px 0 24px;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 28px;
  align-items: start;
  overflow: hidden;
  padding: clamp(28px, 5vw, 52px);
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(135deg, rgb(22 59 48 / 92%), rgb(7 25 21 / 89%));
  box-shadow: var(--shadow);
}

.hero::after {
  position: absolute;
  top: -7rem;
  right: -5rem;
  width: 20rem;
  height: 20rem;
  border-radius: 50%;
  background: rgb(98 215 207 / 12%);
  box-shadow: 0 0 100px rgb(98 215 207 / 15%);
  content: "";
  pointer-events: none;
}

.brand-lockup {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  font-size: 0.9rem;
  font-weight: 750;
  letter-spacing: 0.02em;
}

.brand-mark {
  display: grid;
  width: 39px;
  height: 39px;
  place-items: center;
  border: 1px solid rgb(145 230 172 / 60%);
  border-radius: 12px;
  background: linear-gradient(145deg, #9cf0b6, #45b8ad);
  box-shadow: 0 0 28px rgb(104 222 156 / 23%);
  color: #06251d;
  font-size: 0.78rem;
  font-weight: 850;
}

.hero-content {
  max-width: 630px;
}

.eyebrow,
.section-kicker {
  margin: 0 0 8px;
  color: var(--moss);
  font-size: 0.74rem;
  font-weight: 750;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

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

h1,
h2 {
  text-wrap: balance;
}

h1 {
  max-width: 11ch;
  margin-bottom: 14px;
  font-size: clamp(2.4rem, 6vw, 4.8rem);
  line-height: 0.98;
  letter-spacing: -0.065em;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(1.45rem, 3vw, 2rem);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.hero-copy {
  max-width: 50ch;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1.04rem;
}

.hero-signal {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  justify-self: end;
  padding: 8px 11px;
  border: 1px solid rgb(145 230 172 / 24%);
  border-radius: 999px;
  background: rgb(3 16 12 / 36%);
  color: #d4f7dd;
  font-size: 0.78rem;
  font-weight: 650;
  white-space: nowrap;
}

.signal-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--moss);
  box-shadow: 0 0 0 4px rgb(145 230 172 / 13%), 0 0 13px var(--moss);
}

main {
  display: grid;
  gap: 28px;
  margin-top: 28px;
}

.live-section,
.platform-overview {
  padding: clamp(24px, 4vw, 40px);
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgb(7 23 19 / 66%);
  box-shadow: var(--shadow);
}

.section-heading {
  display: flex;
  gap: 20px;
  align-items: end;
  justify-content: space-between;
  margin-bottom: 20px;
}

.freshness,
.status {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.freshness {
  max-width: 29ch;
  text-align: right;
}

.sightings-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(145deg, rgb(20 52 43 / 84%), rgb(9 28 23 / 88%));
}

.status {
  min-height: 1.5em;
  padding: 14px 18px 10px;
}

.status.error {
  color: var(--danger);
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}

table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
}

th,
td {
  padding: 15px 18px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

th {
  color: #b7d1c0;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

td {
  color: #dcebe2;
  font-size: 0.94rem;
}

tbody tr {
  transition: background-color 160ms ease;
}

tbody tr:hover {
  background: rgb(129 222 165 / 7%);
}

tbody tr:last-child td {
  border-bottom: 0;
}

.species-name {
  color: #fff;
  font-weight: 700;
}

.observed-time {
  color: var(--muted);
  white-space: nowrap;
}

.validation-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.73rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

.validation-badge.validated {
  border-color: rgb(145 230 172 / 28%);
  background: rgb(145 230 172 / 12%);
  color: #bcf7cd;
}

.validation-badge.provisional {
  border-color: rgb(255 201 107 / 27%);
  background: rgb(255 201 107 / 11%);
  color: #ffe0a2;
}

.data-key {
  margin-top: 20px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgb(17 45 37 / 62%);
}

.key-heading {
  margin-bottom: 16px;
}

.key-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
}

.key-list div {
  min-width: 0;
}

.key-list dt {
  margin-bottom: 6px;
  color: #e9f5ed;
  font-size: 0.87rem;
  font-weight: 700;
}

.key-list dd {
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.platform-overview {
  position: relative;
  overflow: hidden;
}

.platform-overview::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 80px;
  height: 2px;
  background: linear-gradient(90deg, var(--moss), var(--teal));
  content: "";
}

.platform-overview h2 {
  margin-bottom: 14px;
}

.platform-overview > p:last-child {
  max-width: 78ch;
  margin-bottom: 0;
  color: var(--muted);
}

.site-footer {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  padding: 26px 4px 0;
  color: #91a99d;
  font-size: 0.86rem;
}

.site-footer a {
  font-weight: 700;
  white-space: nowrap;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 760px) {
  .page-shell {
    width: min(100% - 24px, 680px);
    padding-top: 12px;
  }

  .hero {
    grid-template-columns: 1fr auto;
    gap: 24px 14px;
    padding: 28px;
  }

  .hero-content {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .hero-signal {
    align-self: center;
  }

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

@media (max-width: 560px) {
  .page-shell {
    width: min(100% - 20px, 540px);
    padding-bottom: 18px;
  }

  .hero,
  .live-section,
  .platform-overview {
    border-radius: 16px;
  }

  .hero {
    display: block;
    padding: 25px;
  }

  .hero-signal {
    display: inline-flex;
    margin-top: 22px;
  }

  .section-heading,
  .site-footer {
    display: block;
  }

  .freshness {
    max-width: none;
    margin-top: 12px;
    text-align: left;
  }

  .table-wrap {
    overflow: visible;
  }

  table,
  tbody,
  tr,
  td {
    display: block;
    min-width: 0;
    width: 100%;
  }

  thead {
    display: none;
  }

  tbody tr {
    padding: 6px 0;
    border-bottom: 1px solid var(--line);
  }

  tbody tr:last-child {
    border-bottom: 0;
  }

  td {
    display: grid;
    grid-template-columns: minmax(88px, 0.55fr) minmax(0, 1fr);
    gap: 12px;
    padding: 7px 18px;
    border: 0;
  }

  td::before {
    color: #9fb9aa;
    content: attr(data-label);
    font-size: 0.68rem;
    font-weight: 750;
    letter-spacing: 0.08em;
    text-transform: uppercase;
  }

  .key-list {
    grid-template-columns: 1fr;
  }

  .site-footer span {
    display: block;
    margin-bottom: 10px;
  }
}

@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;
  }
}
