:root {
  --forest: #173c2d;
  --forest-deep: #0d2c20;
  --leaf: #79a94f;
  --lime: #d8ff74;
  --cream: #f8f4e8;
  --paper: #fffdf5;
  --ink: #1b281f;
  --muted: #607065;
  --line: rgba(23, 60, 45, 0.16);
  --shadow: 0 24px 80px rgba(13, 44, 32, 0.12);
  --display: "Iowan Old Style", "Baskerville", "Times New Roman", serif;
  --body: "Avenir Next", "Avenir", "Gill Sans", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}

:focus-visible {
  outline: 3px solid #4d7835;
  outline-offset: 5px;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  color: white;
  background: var(--forest-deep);
  border-radius: 999px;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 78px;
  padding: 0 5vw;
  background: rgba(255, 253, 245, 0.91);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  gap: 11px;
  align-items: center;
  color: var(--forest-deep);
  font-weight: 700;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand-mark {
  flex-shrink: 0;
  display: inline-block;
  width: 38px;
  height: 38px;
  overflow: hidden;
  background: #f8faf5 url("brand-logo.jpg") center / cover no-repeat;
  border: 1px solid rgba(23, 60, 45, 0.12);
  border-radius: 10px;
}

.site-nav {
  display: flex;
  gap: 28px;
  align-items: center;
}

.site-nav a {
  position: relative;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--forest);
}

.site-nav a[aria-current="page"]::after {
  position: absolute;
  right: 0;
  bottom: -9px;
  left: 0;
  height: 2px;
  content: "";
  background: var(--leaf);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 10px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 50%;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  margin: 5px 0;
  background: var(--forest);
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(360px, 0.98fr);
  gap: 7vw;
  align-items: center;
  min-height: calc(100vh - 78px);
  padding: 8vw 8vw 9vw;
  overflow: hidden;
  background:
    radial-gradient(circle at 82% 20%, rgba(216, 255, 116, 0.34), transparent 26%),
    linear-gradient(145deg, var(--paper) 0%, #eef3df 100%);
}

.hero::after {
  position: absolute;
  right: -8vw;
  bottom: -24vw;
  width: 52vw;
  height: 52vw;
  content: "";
  border: 1px solid rgba(23, 60, 45, 0.1);
  border-radius: 50%;
}

.eyebrow {
  margin: 0 0 18px;
  color: #507735;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin-top: 0;
  color: var(--forest-deep);
  font-family: var(--display);
  font-weight: 500;
  line-height: 1.07;
}

.hero h1 {
  max-width: 700px;
  margin-bottom: 26px;
  font-size: clamp(3.4rem, 6.8vw, 7.2rem);
  letter-spacing: -0.065em;
}

.hero h1 em {
  position: relative;
  color: var(--forest);
  font-weight: 400;
}

.hero-copy {
  position: relative;
  z-index: 2;
}

.hero-text {
  max-width: 600px;
  margin: 0 0 34px;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.5vw, 1.25rem);
}

.product-showcase {
  position: relative;
  z-index: 2;
  min-height: 620px;
  isolation: isolate;
}

.product-showcase::before {
  position: absolute;
  z-index: -1;
  top: 9%;
  right: -4%;
  bottom: 7%;
  left: -4%;
  content: "";
  background-image:
    linear-gradient(rgba(23, 60, 45, 0.075) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 60, 45, 0.075) 1px, transparent 1px);
  background-size: 42px 42px;
  border: 1px solid rgba(23, 60, 45, 0.12);
  transform: rotate(-4deg);
}

.device {
  position: absolute;
  width: 210px;
  margin: 0;
  transform-origin: center bottom;
}

.device-shell {
  position: relative;
  padding: 9px;
  overflow: hidden;
  background: linear-gradient(145deg, #284d3e 0%, #08251c 42%, #173c2d 100%);
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 42px;
  box-shadow:
    0 34px 70px rgba(13, 44, 32, 0.22),
    0 8px 20px rgba(13, 44, 32, 0.16),
    inset 0 0 0 1px rgba(0, 0, 0, 0.28);
  transition: transform 220ms ease, box-shadow 220ms ease;
}

.device-shell::before {
  position: absolute;
  z-index: 2;
  top: 17px;
  left: 50%;
  width: 36%;
  height: 18px;
  content: "";
  background: #071c15;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 999px;
  transform: translateX(-50%);
}

.device-shell::after {
  position: absolute;
  z-index: 2;
  bottom: 17px;
  left: 50%;
  width: 30%;
  height: 4px;
  content: "";
  background: rgba(5, 22, 16, 0.92);
  border-radius: 999px;
  transform: translateX(-50%);
}

.device-screen {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 33px;
}

.device--details {
  z-index: 1;
  top: 92px;
  left: 0;
  transform: rotate(-8deg);
}

.device--overview {
  z-index: 3;
  top: 18px;
  left: 50%;
  width: 254px;
  transform: translateX(-50%) rotate(2deg);
}

.device--issues {
  z-index: 2;
  top: 100px;
  right: 0;
  transform: rotate(8deg);
}

.device:hover .device-shell {
  box-shadow:
    0 42px 84px rgba(13, 44, 32, 0.26),
    0 10px 24px rgba(13, 44, 32, 0.18),
    inset 0 0 0 1px rgba(0, 0, 0, 0.28);
  transform: translateY(-7px);
}

.section {
  padding: 110px 8vw;
}

.section-heading {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 5vw;
  align-items: end;
  max-width: 1180px;
  margin: 0 auto 60px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(2.4rem, 4.8vw, 5rem);
  letter-spacing: -0.045em;
}

.section-heading p:last-child {
  max-width: 520px;
  margin: 0 0 8px;
  color: var(--muted);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 18px;
  max-width: 1180px;
  margin: auto;
}

.feature-card {
  position: relative;
  grid-column: span 3;
  min-height: 320px;
  padding: 34px;
  overflow: hidden;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 28px 28px 28px 7px;
}

.feature-card::after {
  position: absolute;
  right: -34px;
  bottom: -52px;
  width: 150px;
  height: 150px;
  content: "";
  border: 1px solid rgba(23, 60, 45, 0.1);
  border-radius: 50%;
}

.feature-card--primary {
  grid-column: span 3;
  min-height: 360px;
}

.feature-card--dark {
  color: white;
  background: var(--forest);
}

.feature-card.feature-card--dark h3 {
  color: white;
}

.feature-card.feature-card--dark p {
  color: #dce8df;
}

.feature-card--dark::after {
  border-color: rgba(255, 255, 255, 0.12);
}

.feature-number {
  display: block;
  margin-bottom: 75px;
  color: #507735;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.feature-card h3 {
  margin-bottom: 14px;
  font-size: 1.8rem;
}

.feature-card--dark .feature-number {
  color: var(--lime);
}

.feature-card p {
  margin: 0;
  color: var(--muted);
}

.legal-hero {
  padding: 90px 7vw 70px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 0, rgba(216, 255, 116, 0.35), transparent 40%),
    var(--cream);
  border-bottom: 1px solid var(--line);
}

.legal-hero h1 {
  margin-bottom: 16px;
  font-size: clamp(3rem, 6vw, 6rem);
  letter-spacing: -0.055em;
}

.legal-hero p {
  max-width: 660px;
  margin: auto;
  color: var(--muted);
}

.legal-document {
  max-width: 860px;
  margin: 0 auto;
  padding: 80px 24px 110px;
  overflow-wrap: anywhere;
}

.document-toc {
  margin: 24px 0 36px;
  padding: 20px 24px;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 16px;
}

.document-toc p { margin: 0 0 12px; }
.document-toc ul { margin: 0; columns: 2; column-gap: 32px; list-style: none; padding: 0; }
.document-toc li { break-inside: avoid; margin: 0 0 10px; font-size: 0.9rem; }
.document-toc a { text-underline-offset: 3px; }

.legal-document h2 {
  margin: 56px 0 18px;
  padding-top: 8px;
  font-size: 2rem;
  letter-spacing: -0.025em;
}

.legal-document h3 {
  margin: 32px 0 12px;
  font-family: var(--body);
  font-size: 1.05rem;
  font-weight: 800;
}

.legal-document p,
.legal-document li {
  color: #45534a;
}

.legal-document ul {
  padding-left: 22px;
}

.legal-document li + li {
  margin-top: 10px;
}

.effective-date {
  display: inline-block;
  margin-bottom: 16px;
  padding: 8px 13px;
  color: var(--forest);
  font-size: 0.82rem;
  font-weight: 700;
  background: #ecf3df;
  border-radius: 999px;
}

.notice {
  margin: 32px 0;
  padding: 24px;
  background: var(--cream);
  border-left: 4px solid var(--leaf);
  border-radius: 0 16px 16px 0;
}

.text-link {
  color: var(--forest);
  font-weight: 700;
  text-underline-offset: 3px;
}

.support-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.support-card {
  padding: 28px;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 22px 22px 22px 6px;
}

.support-card h2 {
  margin-top: 0;
  font-size: 1.55rem;
}

.site-footer {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: end;
  padding: 60px 5vw;
  background: var(--cream);
  border-top: 1px solid var(--line);
}

.site-footer p {
  max-width: 470px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}

.footer-links a {
  color: var(--forest);
  font-size: 0.86rem;
  font-weight: 700;
  text-decoration: none;
}

@media (prefers-reduced-motion: no-preference) {
  .hero-copy > * {
    animation: rise-in 700ms both;
  }

  .hero-copy > :nth-child(2) { animation-delay: 90ms; }
  .hero-copy > :nth-child(3) { animation-delay: 180ms; }
  .hero-copy > :nth-child(4) { animation-delay: 270ms; }
  .product-showcase { animation: rise-in 900ms 160ms both; }

  @keyframes rise-in {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: translateY(0); }
  }
}

@media (max-width: 900px) {
  .site-header { flex-wrap: wrap; }

  .nav-ready .nav-toggle {
    display: block;
    flex-shrink: 0;
  }

  .site-nav {
    width: 100%;
    flex-wrap: wrap;
    gap: 8px 20px;
    padding-bottom: 12px;
  }

  .nav-ready .site-nav {
    position: absolute;
    top: 68px;
    right: 4vw;
    left: 4vw;
    width: auto;
    display: none;
    gap: 6px;
    align-items: stretch;
    padding: 12px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow);
  }

  .nav-ready .site-nav.is-open {
    display: grid;
  }

  .site-nav a {
    padding: 10px 12px;
  }

  .site-nav a[aria-current="page"]::after {
    display: none;
  }

  .hero {
    grid-template-columns: 1fr;
    padding: 80px 7vw 90px;
  }

  .product-showcase {
    width: min(620px, 100%);
    min-height: 620px;
    margin: auto;
  }

  .section-heading {
    grid-template-columns: 1fr;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .feature-card,
  .feature-card--primary {
    grid-column: auto;
    min-height: auto;
  }

  .feature-number {
    margin-bottom: 36px;
  }
}

@media (max-width: 620px) {
  .site-header > .brand { max-width: calc(100% - 54px); }
  .brand span:last-child { line-height: 1.35; }
  .document-toc ul { columns: 1; }
  .site-header {
    min-height: 68px;
    padding: 0 20px;
  }

  .brand span:last-child {
    font-size: 0.92rem;
  }

  .hero h1 {
    font-size: clamp(3rem, 16vw, 4.6rem);
  }

  .product-showcase {
    display: flex;
    width: calc(100% + 14vw);
    min-height: 0;
    gap: 16px;
    margin: 10px -7vw 0;
    padding: 22px 7vw 38px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scroll-padding-inline: 7vw;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .product-showcase::-webkit-scrollbar {
    display: none;
  }

  .product-showcase::before {
    top: 4%;
    right: 3vw;
    bottom: 5%;
    left: 3vw;
    transform: rotate(-2deg);
  }

  .device,
  .device--overview {
    position: relative;
    top: auto;
    right: auto;
    left: auto;
    flex: 0 0 min(68vw, 250px);
    width: min(68vw, 250px);
    scroll-snap-align: center;
    transform: none;
  }

  .device:first-child {
    margin-left: calc((100% - min(68vw, 250px)) / 2 - 7vw);
  }

  .device:last-child {
    margin-right: calc((100% - min(68vw, 250px)) / 2 - 7vw);
  }

  .section {
    padding: 80px 22px;
  }

  .legal-hero {
    padding: 70px 22px 55px;
  }

  .legal-document {
    padding: 55px 22px 80px;
  }

  .support-grid,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .site-footer {
    padding: 48px 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .device-shell { transition: none; }
}
