:root {
  color-scheme: light dark;
  --background: #f3f7fc;
  --surface: #ffffff;
  --surface-soft: #eaf3ff;
  --text: #12213a;
  --secondary: #52627b;
  --navy: #061b3d;
  --accent: #086bd8;
  --teal: #51ccd0;
  --border: #d9e4f1;
  --notice: #eaf3ff;
  --shadow: 0 22px 60px rgb(20 52 96 / 12%);
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #07101e;
    --surface: #0f1c2d;
    --surface-soft: #102b4a;
    --text: #f5f8fd;
    --secondary: #bcc8d8;
    --accent: #79b9ff;
    --border: #263d5a;
    --notice: #122b4a;
    --shadow: 0 22px 60px rgb(0 0 0 / 24%);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font: 18px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--accent); }
a:focus-visible, button:focus-visible { outline: 4px solid var(--teal); outline-offset: 4px; border-radius: 6px; }
.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  background: #fff;
  color: #061b3d;
  font-weight: 800;
  transform: translateY(-160%);
}
.skip-link:focus { transform: translateY(0); }

/* Existing information pages */
body:not(.home):not(.info-page) > header, body:not(.home):not(.info-page) > main, body:not(.home):not(.info-page) > footer {
  width: min(900px, calc(100% - 32px));
  margin-inline: auto;
}
body:not(.home):not(.info-page) > header { padding: 36px 0 20px; }
body:not(.home):not(.info-page) > header nav { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 18px; }
body:not(.home):not(.info-page) > header nav a { font-weight: 700; text-decoration: none; }
body:not(.home):not(.info-page) > main {
  padding: clamp(22px, 5vw, 52px);
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
body:not(.home):not(.info-page) > footer { padding: 28px 0 50px; color: var(--secondary); font-size: .9rem; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -.025em; }
h1 { margin: 0; font-size: clamp(2.35rem, 6vw, 4.7rem); }
h2 { margin: 0; font-size: clamp(2rem, 4vw, 3.25rem); }
h3 { margin: 0; font-size: 1.3rem; }
body:not(.home):not(.info-page) h1 { font-size: clamp(2rem, 6vw, 3.4rem); }
body:not(.home):not(.info-page) h2 { margin-top: 2.2rem; font-size: 1.7rem; }
p, li { max-width: 72ch; }
.subtitle { color: var(--secondary); font-size: 1.15rem; }
.notice { padding: 14px 18px; border-left: 5px solid var(--accent); border-radius: 10px; background: var(--notice); }
.button {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  margin: 8px 8px 8px 0;
  padding: 12px 19px;
  border: 2px solid transparent;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
}
.button:hover { transform: translateY(-1px); }

/* Homepage navigation */
.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid rgb(125 158 199 / 24%);
  background: rgb(6 27 61 / 94%);
  color: #fff;
  backdrop-filter: blur(18px);
}
.site-header__inner {
  display: flex;
  width: min(1180px, calc(100% - 40px));
  min-height: 84px;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  margin-inline: auto;
}
.brand { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 12px; color: #fff; text-decoration: none; }
.brand img { width: 52px; border-radius: 13px; box-shadow: 0 8px 22px rgb(0 0 0 / 24%); }
.brand span { display: grid; line-height: 1.05; }
.brand strong { font-size: 1.18rem; letter-spacing: .01em; }
.brand small { margin-top: 5px; color: #a9c8ea; font-size: .72rem; font-weight: 750; letter-spacing: .11em; text-transform: uppercase; }
.site-header nav, .site-footer nav { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; }
.site-header nav a { padding: 8px 0; color: #dcecff; font-size: .95rem; font-weight: 700; text-decoration: none; }
.site-header nav a:hover, .site-header nav a[aria-current="page"] { color: #fff; }
.site-header nav a[aria-current="page"] { border-bottom: 3px solid var(--teal); }

.home-main { overflow: hidden; }
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(340px, .9fr);
  min-height: 720px;
  align-items: center;
  gap: clamp(42px, 7vw, 96px);
  padding: clamp(72px, 10vw, 130px) max(24px, calc((100vw - 1180px) / 2));
  background: radial-gradient(circle at 82% 46%, rgb(26 112 220 / 38%), transparent 30%), linear-gradient(135deg, #04142f 0%, #082754 58%, #06458f 100%);
  color: #fff;
}
.hero__content { position: relative; z-index: 2; }
.eyebrow { margin: 0 0 14px; color: var(--accent); font-size: .82rem; font-weight: 850; letter-spacing: .13em; text-transform: uppercase; }
.hero .eyebrow, .eyebrow--light { color: #77e2e3; }
.hero h1 { max-width: 760px; }
.hero__summary { margin: 26px 0 24px; color: #d2e3f6; font-size: clamp(1.12rem, 2vw, 1.35rem); line-height: 1.55; }
.button-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.button--primary, .button--light { background: #fff; color: #082754; }
.button--secondary { border-color: #8ebcea; background: transparent; color: #fff; }
.trust-list { display: flex; flex-wrap: wrap; gap: 10px 26px; margin: 28px 0 0; padding: 0; color: #c6dbf1; font-size: .9rem; list-style: none; }
.trust-list li::before { content: "✓"; margin-right: 8px; color: #71e2df; font-weight: 900; }
.hero__visual { position: relative; width: min(100%, 480px); margin-inline: auto; aspect-ratio: 1; }
.app-icon-frame {
  position: absolute;
  inset: 8%;
  overflow: hidden;
  border: 1px solid rgb(255 255 255 / 28%);
  border-radius: 25%;
  background: #061b3d;
  box-shadow: 0 42px 90px rgb(0 0 0 / 38%), 0 0 0 14px rgb(255 255 255 / 5%);
  transform: rotate(2deg);
}
.app-icon-frame img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tool-pill {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 48px;
  padding: 9px 15px;
  border: 1px solid rgb(255 255 255 / 38%);
  border-radius: 999px;
  background: rgb(255 255 255 / 94%);
  color: #09224a;
  box-shadow: 0 14px 35px rgb(0 0 0 / 24%);
  font-size: .82rem;
  font-weight: 800;
}
.tool-pill span { display: grid; width: 29px; height: 29px; place-items: center; border-radius: 50%; background: #dff7f7; color: #086bd8; }
.tool-pill--journal { top: 5%; left: -3%; }
.tool-pill--reminders { right: -3%; bottom: 14%; }
.tool-pill--medications { bottom: 0; left: 9%; }

.section { width: min(1180px, calc(100% - 40px)); margin-inline: auto; padding: clamp(78px, 9vw, 120px) 0; }
.section-heading { max-width: 760px; margin-bottom: 42px; }
.section-heading > p:last-child { color: var(--secondary); font-size: 1.12rem; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature-card { min-height: 250px; padding: 30px; border: 1px solid var(--border); border-radius: 22px; background: var(--surface); box-shadow: 0 12px 36px rgb(22 55 96 / 7%); }
.feature-card__icon { display: grid; width: 54px; height: 54px; margin-bottom: 24px; place-items: center; border-radius: 15px; background: var(--surface-soft); color: var(--accent); font-size: 1.5rem; font-weight: 900; }
.feature-card p { margin-bottom: 0; color: var(--secondary); }

.clarity-section {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(46px, 8vw, 110px);
  padding: clamp(76px, 9vw, 110px) max(24px, calc((100vw - 1180px) / 2));
  background: var(--navy);
  color: #fff;
}
.clarity-section > div > p:not(.eyebrow) { color: #c6d7eb; font-size: 1.12rem; }
.text-link { display: inline-flex; gap: 9px; align-items: center; margin-top: 10px; color: var(--accent); font-weight: 850; text-decoration: none; }
.clarity-section .text-link { color: #76e1e2; }
.clarity-list { display: grid; gap: 15px; margin: 0; padding: 0; list-style: none; }
.clarity-list li { display: grid; gap: 3px; padding: 20px 22px; border: 1px solid rgb(255 255 255 / 15%); border-radius: 16px; background: rgb(255 255 255 / 6%); }
.clarity-list strong { font-size: 1.08rem; }
.clarity-list span { color: #b9cde4; }

.privacy-section { display: grid; grid-template-columns: 180px 1fr; gap: 54px; align-items: start; }
.privacy-mark { display: grid; width: 150px; height: 150px; place-items: center; border-radius: 36px; background: linear-gradient(145deg, #0b7bea, #063f88); color: #fff; font-size: 4.5rem; box-shadow: var(--shadow); }
.privacy-section h2 { max-width: 820px; }
.privacy-section p { color: var(--secondary); }
.people-section { padding-top: 20px; }
.people-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.people-grid article { padding: 28px; border-top: 5px solid var(--teal); border-radius: 0 0 18px 18px; background: var(--surface); box-shadow: 0 12px 36px rgb(22 55 96 / 7%); }
.people-grid p { color: var(--secondary); }

.medical-notice {
  display: grid;
  grid-template-columns: auto 1fr;
  width: min(1180px, calc(100% - 40px));
  align-items: start;
  gap: 16px;
  margin: 0 auto 100px;
  padding: 22px 25px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--notice);
}
.medical-notice > div { display: grid; width: 32px; height: 32px; place-items: center; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 900; }
.medical-notice p { margin: 0; color: var(--secondary); }
.medical-notice strong { color: var(--text); }
.closing-cta { padding: clamp(74px, 9vw, 110px) max(24px, calc((100vw - 900px) / 2)); background: linear-gradient(135deg, #06428c, #0873d9); color: #fff; text-align: center; }
.closing-cta p { margin-inline: auto; color: #d9ecff; }
.closing-cta .button { margin-top: 14px; }
.site-footer { background: #04142f; color: #b9cce2; }
.site-footer__inner { width: min(1180px, calc(100% - 40px)); margin-inline: auto; padding: 48px 0; }
.footer-brand { display: grid; margin-bottom: 22px; color: #fff; line-height: 1.2; }
.footer-brand strong { font-size: 1.3rem; }
.footer-brand span { color: #91afd0; font-size: .8rem; font-weight: 750; letter-spacing: .12em; text-transform: uppercase; }
.site-footer nav a { color: #d4e5f6; font-weight: 700; text-decoration: none; }
.site-footer p { margin: 26px 0 0; font-size: .86rem; }

/* Information pages */
.info-page > main { overflow: hidden; }
.page-hero {
  padding: clamp(64px, 8vw, 102px) max(24px, calc((100vw - 1080px) / 2));
  background: radial-gradient(circle at 88% 24%, rgb(81 204 208 / 22%), transparent 27%), linear-gradient(135deg, #04142f, #083a78);
  color: #fff;
}
.page-hero__inner { width: min(100%, 1080px); margin-inline: auto; }
.page-hero h1 { max-width: 900px; font-size: clamp(2.65rem, 7vw, 5rem); }
.page-hero p:not(.eyebrow) { max-width: 760px; margin: 22px 0 0; color: #d2e3f6; font-size: clamp(1.08rem, 2vw, 1.28rem); }
.page-meta { display: inline-flex; margin-top: 24px; padding: 7px 13px; border: 1px solid rgb(255 255 255 / 22%); border-radius: 999px; background: rgb(255 255 255 / 8%); color: #dcecff; font-size: .86rem; font-weight: 750; }
.info-layout {
  display: grid;
  width: min(1080px, calc(100% - 40px));
  grid-template-columns: 220px minmax(0, 1fr);
  align-items: start;
  gap: 42px;
  margin-inline: auto;
  padding: clamp(56px, 7vw, 82px) 0 100px;
}
.page-toc { position: sticky; top: 112px; display: grid; gap: 4px; padding: 8px; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); box-shadow: 0 10px 30px rgb(22 55 96 / 7%); }
.page-toc strong { padding: 12px 14px 8px; font-size: .82rem; letter-spacing: .08em; text-transform: uppercase; }
.page-toc a { padding: 9px 14px; border-radius: 9px; color: var(--secondary); font-size: .88rem; font-weight: 720; line-height: 1.3; text-decoration: none; }
.page-toc a:hover, .page-toc a:focus-visible { background: var(--surface-soft); color: var(--accent); }
.page-content { min-width: 0; padding: clamp(28px, 5vw, 54px); border: 1px solid var(--border); border-radius: 24px; background: var(--surface); box-shadow: var(--shadow); }
.page-content section + section { margin-top: 42px; padding-top: 42px; border-top: 1px solid var(--border); }
.page-content h2 { margin: 0 0 18px; font-size: clamp(1.55rem, 3vw, 2.15rem); }
.page-content p { color: var(--secondary); }
.page-content li + li { margin-top: 10px; }
.notice--calm { margin: 0 0 42px; color: var(--secondary); }
.notice--calm strong { color: var(--text); }
.detail-list { display: grid; gap: 12px; margin: 24px 0; padding: 0; list-style: none; }
.detail-list li { display: grid; gap: 4px; margin: 0; padding: 16px 18px; border: 1px solid var(--border); border-radius: 13px; background: var(--surface-soft); }
.detail-list strong { color: var(--text); }
.detail-list span { color: var(--secondary); }
.page-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.button--outline { border-color: var(--accent); background: transparent; color: var(--accent); }
.step-list { display: grid; gap: 12px; margin: 24px 0; padding: 0; list-style: none; counter-reset: none; }
.step-list li { display: grid; grid-template-columns: 42px 1fr; align-items: center; gap: 14px; margin: 0; }
.step-list li > span { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 850; }
.step-list p { margin: 0; }
.page-version { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--border); font-size: .9rem; }

@media (max-width: 900px) {
  .site-header__inner { align-items: flex-start; flex-direction: column; gap: 10px; padding: 14px 0 16px; }
  .site-header { position: static; }
  .site-header nav { gap: 2px 18px; }
  .hero { grid-template-columns: 1fr; text-align: center; }
  .hero__summary, .hero h1 { margin-inline: auto; }
  .button-row, .trust-list { justify-content: center; }
  .hero__visual { width: min(100%, 420px); }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .clarity-section, .privacy-section { grid-template-columns: 1fr; }
  .privacy-mark { width: 92px; height: 92px; border-radius: 24px; font-size: 3rem; }
  .people-grid { grid-template-columns: 1fr; }
  .info-layout { grid-template-columns: 1fr; }
  .page-toc { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .page-toc strong { grid-column: 1 / -1; }
}

@media (max-width: 580px) {
  body { font-size: 17px; }
  .site-header__inner, .section, .medical-notice, .site-footer__inner { width: min(100% - 28px, 1180px); }
  .site-header nav { display: grid; width: 100%; grid-template-columns: repeat(3, auto); justify-content: space-between; font-size: .9rem; }
  .hero { min-height: auto; padding-top: 68px; padding-bottom: 80px; }
  .hero__visual { margin-top: 24px; }
  .tool-pill { display: none; }
  .app-icon-frame { inset: 4%; }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-card { min-height: 0; }
  .medical-notice { grid-template-columns: 1fr; }
  .button-row .button { width: 100%; margin: 0; }
  .page-hero { padding-inline: 14px; }
  .info-layout { width: min(100% - 28px, 1080px); gap: 24px; padding-top: 28px; padding-bottom: 64px; }
  .page-toc { grid-template-columns: 1fr; }
  .page-toc strong { grid-column: auto; }
  .page-content { padding: 24px 20px; border-radius: 18px; }
  .page-content section + section { margin-top: 32px; padding-top: 32px; }
  .page-actions .button { width: 100%; margin: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
