:root {
  --navy: #0E2A47;
  --teal: #1F7A8C;
  --green: #3FA34D;
  --green-dark: #338b3f;
  --yellow: #F2C84B;
  --cream: #FAF7F0;
  --white: #FFFFFF;
  --ink: #1A1A1A;
  --muted: #5B6B7B;
  --line: #E6E9EE;

  --radius: 12px;
  --radius-lg: 20px;
  --shadow-sm: 0 4px 12px rgba(14, 42, 71, 0.06);
  --shadow-md: 0 10px 30px rgba(14, 42, 71, 0.08);
  --shadow-lg: 0 24px 60px rgba(14, 42, 71, 0.18);

  --font-sans: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }

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

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.25rem;
}


/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-weight: 600;
  border: 0;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: transform .08s ease, box-shadow .15s ease, background .15s ease;
  line-height: 1;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-sm { padding: 0.55rem 0.9rem; font-size: 0.92rem; }
.btn-lg { padding: 1rem 1.5rem; font-size: 1.05rem; }
.btn-xl { padding: 1.15rem 1.85rem; font-size: 1.15rem; }

.btn-primary {
  background: var(--green);
  color: #fff;
  box-shadow: 0 6px 18px rgba(63, 163, 77, 0.35);
}
.btn-primary:hover { background: var(--green-dark); }

.btn-green {
  background: var(--green);
  color: #fff;
  box-shadow: 0 10px 28px rgba(63, 163, 77, 0.4);
}
.btn-green:hover { background: var(--green-dark); }

.price-chip {
  background: var(--yellow);
  color: var(--navy);
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95em;
}
.price-chip-dark { background: var(--yellow); color: var(--navy); }


/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--navy);
}
.brand:hover { text-decoration: none; }
.brand-mark {
  color: var(--green);
  font-size: 1.4rem;
  line-height: 1;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 1.6rem;
}
.nav-menu a {
  color: var(--navy);
  font-weight: 500;
  font-size: 0.96rem;
}
.nav-menu a.btn { color: #fff; }

.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  width: 40px;
  height: 40px;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--navy);
  margin: 5px 0;
  border-radius: 2px;
  transition: transform .2s ease, opacity .2s ease;
}


/* ---------- Hero ---------- */
.hero {
  padding: 4rem 0 5rem;
  background:
    radial-gradient(1200px 500px at 80% -10%, rgba(31, 122, 140, 0.10), transparent 60%),
    radial-gradient(900px 500px at -10% 20%, rgba(242, 200, 75, 0.12), transparent 60%),
    var(--white);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 3.5rem;
  align-items: center;
}

.eyebrow {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 1.1rem;
}

.hero-copy h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  line-height: 1.05;
  color: var(--navy);
  margin: 0 0 1rem;
  letter-spacing: -0.01em;
}

.hero-sub {
  font-size: 1.12rem;
  color: var(--muted);
  margin: 0 0 1.75rem;
  max-width: 36rem;
}

.trust-badges {
  list-style: none;
  margin: 0 0 2rem;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.4rem;
  color: var(--navy);
  font-size: 0.95rem;
  font-weight: 500;
}
.trust-badges li {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.trust-badges svg { color: var(--teal); flex-shrink: 0; }

.hero-cta {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.text-link {
  color: var(--navy);
  font-weight: 600;
  font-size: 0.98rem;
}

.hero-cover {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 480px;
}
.cover-accent {
  position: absolute;
  width: 80%;
  aspect-ratio: 1;
  background: var(--yellow);
  border-radius: 32% 68% 60% 40% / 45% 40% 60% 55%;
  opacity: 0.55;
  filter: blur(2px);
  z-index: 0;
}
.cover-img {
  position: relative;
  z-index: 1;
  width: clamp(220px, 60%, 320px);
  height: auto;
  border-radius: 6px;
  box-shadow: var(--shadow-lg);
  transform: rotate(-2deg);
  transition: transform .3s ease;
}
.cover-img:hover { transform: rotate(0) scale(1.02); }

/* Fallback when Amazon image fails, keeps layout */
.cover-img.cover-fallback {
  width: 280px;
  height: 420px;
  background: linear-gradient(160deg, var(--navy) 0%, var(--teal) 100%);
  display: block;
  position: relative;
}
.cover-img.cover-fallback::after {
  content: "The AFIB Hack";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--yellow);
  font-size: 1.6rem;
  padding: 2rem;
  text-align: center;
}


/* ---------- Sections ---------- */
.section {
  padding: 5.5rem 0;
}
.section-cream { background: var(--cream); }

.section-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  color: var(--navy);
  margin: 0 0 0.5rem;
  position: relative;
  letter-spacing: -0.01em;
}
.section-title::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  background: var(--yellow);
  border-radius: 2px;
  margin-top: 0.75rem;
}
.section-sub {
  color: var(--muted);
  font-size: 1.05rem;
  margin: 1.25rem 0 2.5rem;
  max-width: 42rem;
}


/* ---------- Benefits cards ---------- */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2.5rem;
}
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.card-icon {
  width: 52px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: rgba(31, 122, 140, 0.10);
  color: var(--teal);
  margin-bottom: 1rem;
}
.card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.2rem;
  color: var(--navy);
  margin: 0 0 0.5rem;
}
.card p {
  color: var(--muted);
  margin: 0;
  font-size: 0.98rem;
}


/* ---------- Inside ---------- */
.inside-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}
.inside-copy p { color: var(--muted); font-size: 1.05rem; }
.inside-copy .muted { font-size: 0.95rem; }

.check-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.85rem;
}
.check-list li {
  position: relative;
  padding-left: 2.25rem;
  color: var(--ink);
  font-size: 1.02rem;
}
.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.15rem;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--green);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'><polyline points='20 6 9 17 4 12'/></svg>");
  background-repeat: no-repeat;
  background-position: center;
}


/* ---------- Reviews ---------- */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 1rem;
}
.review {
  margin: 0;
  background: var(--cream);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line);
}
.stars {
  color: var(--yellow);
  font-size: 1.1rem;
  letter-spacing: 2px;
  margin-bottom: 0.75rem;
}
.review blockquote {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  color: var(--ink);
  line-height: 1.55;
}
.review figcaption {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 500;
}


/* ---------- Author / disclaimer ---------- */
.author-inner { max-width: 760px; }
.author-inner p {
  color: var(--ink);
  font-size: 1.08rem;
  margin: 1.25rem 0 0;
}
.disclaimer {
  margin-top: 1.5rem !important;
  padding: 1rem 1.25rem;
  background: rgba(31, 122, 140, 0.08);
  border-left: 4px solid var(--teal);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--muted) !important;
  font-size: 0.96rem !important;
}


/* ---------- FAQ ---------- */
.faq-inner { max-width: 760px; }
.faq-item {
  border-bottom: 1px solid var(--line);
  padding: 1.15rem 0;
}
.faq-item:first-of-type { border-top: 1px solid var(--line); margin-top: 2rem; }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--navy);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.4rem 0;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-size: 1.4rem;
  color: var(--teal);
  margin-left: 1rem;
  transition: transform .2s ease;
  line-height: 1;
}
.faq-item[open] summary::after { content: "−"; }
.faq-item p {
  margin: 0.75rem 0 0.4rem;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.65;
}


/* ---------- CTA band ---------- */
.cta-band {
  background:
    radial-gradient(800px 400px at 80% 30%, rgba(31, 122, 140, 0.6), transparent 60%),
    var(--navy);
  color: #fff;
  padding: 5.5rem 0;
  text-align: center;
}
.cta-inner { max-width: 720px; margin: 0 auto; }
.cta-inner h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.9rem, 3.4vw, 2.6rem);
  line-height: 1.15;
  margin: 0 0 0.75rem;
  color: #fff;
}
.cta-inner > p {
  color: rgba(255, 255, 255, 0.82);
  font-size: 1.1rem;
  margin: 0 0 2rem;
}
.cta-fineprint {
  margin-top: 1.25rem !important;
  color: rgba(255, 255, 255, 0.7) !important;
  font-size: 0.92rem !important;
}


/* ---------- Footer ---------- */
.footer {
  background: #07182C;
  color: rgba(255, 255, 255, 0.7);
  padding: 2.5rem 0;
  font-size: 0.9rem;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.footer p { margin: 0; }
.footer-disclaimer { color: rgba(255, 255, 255, 0.5); }
.footer-links { display: flex; gap: 1.25rem; }
.footer-links a {
  color: rgba(255, 255, 255, 0.75);
  font-weight: 500;
}


/* ---------- Mobile ---------- */
@media (max-width: 768px) {
  .nav-toggle { display: block; }

  .nav-menu {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: #fff;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.5rem 1.25rem 1rem;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    display: none;
  }
  .nav-menu.is-open { display: flex; }
  .nav-menu a {
    padding: 0.85rem 0;
    border-bottom: 1px solid var(--line);
  }
  .nav-menu a:last-child { border-bottom: 0; margin-top: 0.5rem; text-align: center; }

  .hero { padding: 2.5rem 0 3rem; }
  .hero-inner { grid-template-columns: 1fr; gap: 2.5rem; }
  .hero-cover { min-height: 360px; order: -1; }
  .cover-img { width: 220px; }

  .section { padding: 3.5rem 0; }
  .benefits-grid,
  .reviews-grid { grid-template-columns: 1fr; }
  .inside-grid { grid-template-columns: 1fr; gap: 2rem; }

  .cta-band { padding: 3.5rem 0; }
  .footer-inner { flex-direction: column; text-align: center; }
}
