:root {
  --bg: #f4f4f6;
  --surface: #fdfdfd;
  --surface-muted: #f9f9fb;
  --text-primary: #1e2c28;
  --text-secondary: #676788;
  --brand: #11a5a0;
  --brand-dark: #0f8884;
  --brand-ink: #034d54;
  --accent: #b96f00;
  --stroke: #e1e8e7;
  --radius-lg: 32px;
  --radius-xl: 60px;
  --shadow-card:
    0 1px 1px -0.5px rgba(0, 0, 0, 0.03),
    0 3px 3px -1.5px rgba(0, 0, 0, 0.03),
    0 20px 20px -12px rgba(0, 0, 0, 0.03);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Plus Jakarta Sans', sans-serif;
  color: var(--text-primary);
  background: #fff;
  line-height: 1.45;
}

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

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(1224px, calc(100% - 64px));
  margin: 0 auto;
}

.section {
  padding: 80px 0;
}

#about {
  scroll-margin-top: 110px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(225, 232, 231, 0.7);
}

.nav-wrap {
  min-height: 88px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}

.brand {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.main-nav {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 32px;
  font-family: 'Inter', sans-serif;
}

.main-nav a {
  font-size: 17px;
  font-weight: 500;
}

.main-nav a:hover {
  color: var(--brand);
}

.social-icons {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 8px;
}

.social-icons img {
  width: 42px;
  height: 42px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr minmax(500px, 640px);
  align-items: center;
  gap: 72px;
}

.hero-copy h1 {
  margin: 0;
  font-size: clamp(40px, 5vw, 54px);
  line-height: 1.3;
  letter-spacing: -0.025em;
}

.hero-copy p {
  margin: 20px 0 0;
  color: var(--text-secondary);
  font-size: 20px;
}

.hero-copy .hero-note {
  margin-top: 20px;
  color: rgba(185, 111, 0, 1);
  font-family: 'Inter', sans-serif;
  font-size: 18px;
  font-weight: 600;
}

.hero-shell {
  width: 100%;
  border-radius: var(--radius-xl);
}

.store-buttons {
  margin-top: 30px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.btn {
  min-height: 62px;
  padding: 12px 18px;
  border-radius: 14px;
  border-style: solid;
  border-width: 2px 2px 4px 2px;
  border-color: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 700;
  transition: transform 140ms ease, box-shadow 140ms ease;
}

.btn img {
  width: 20px;
  height: auto;
}

.btn img[src*='android.svg'] {
  width: 24px;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--brand);
  border-color: var(--brand-dark);
  box-shadow: inset 0 3px 3px rgba(255, 255, 255, 0.12);
  color: #fff;
}

.btn-light {
  background: #fff;
  border-color: var(--stroke);
  color: var(--brand);
}

.btn-light img {
  filter: brightness(0) saturate(100%) invert(36%) sepia(59%) saturate(741%)
    hue-rotate(135deg) brightness(92%) contrast(92%);
}

.phone-shell {
  background: linear-gradient(315deg, #025a63 0%, #14b8a6 100%);
  border-radius: var(--radius-lg);
  display: flex;
  justify-content: center;
  align-items: flex-end;
  overflow: hidden;
  position: relative;
  padding-top: 18px;
}

.phone-shell.shell-teal {
  min-height: 610px;
}

.phone-shell.tall {
  min-height: 732px;
  border-radius: var(--radius-xl);
}

/* Keep hero container corners extra rounded (overrides base phone-shell radius). */
.phone-shell.hero-shell {
  border-radius: var(--radius-xl);
}

.phone {
  width: min(90%, 500px);
  filter: drop-shadow(0 14px 36px rgba(0, 0, 0, 0.22));
  margin-bottom: -2px;
}

.phone.phone-tilt {
  width: min(78%, 360px);
  transform: rotate(5deg) translateY(38px);
  transform-origin: bottom center;
}

.hero-phone {
  width: 83%;
  max-width: none;
  transform: translateY(0);
}

.phone.phone-tilt.hero-phone {
  width: 83%;
  max-width: none;
  transform: translateY(0);
}

.feature-grid {
  background: var(--surface-muted);
}

.section-title {
  margin: 0;
  text-align: center;
  font-size: clamp(32px, 4vw, 52px);
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.grid-layout {
  margin-top: 48px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.card {
  background: var(--surface);
  border: 2px solid var(--stroke);
  border-bottom-width: 4px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 40px 28px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.card h3 {
  margin: 20px 0 12px;
  font-size: 24px;
  line-height: 1.15;
}

.card p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 20px;
}

.card-wide {
  grid-column: span 2;
  display: grid;
  grid-template-columns: 1fr 330px;
  gap: 20px;
  align-items: end;
  overflow: hidden;
  padding-bottom: 0;
}

.card-wide > .card-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 100%;
}

.card-phone {
  width: 100%;
  max-width: 330px;
  margin-left: auto;
}

.top-home-phone {
  width: 108%;
  max-width: 360px;
  margin: 0 -10px -3px auto;
  align-self: end;
}

.card-wide > img.card-phone.top-home-phone {
  width: calc(100% + 28px);
  max-width: 390px;
  align-self: end;
  margin: 0 -28px 0 auto;
  object-fit: contain;
  object-position: center bottom;
}

.icon-72 {
  width: 72px;
  height: 72px;
  border-radius: 16px;
}

.icon-56 {
  width: 56px;
  height: 56px;
  flex: 0 0 56px;
}

.split {
  background: var(--surface-muted);
}

.split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 84px;
  align-items: center;
}

.reverse .split-grid {
  grid-template-columns: 1fr 1fr;
}

.preview-shell {
  align-items: center;
  padding-top: 26px;
  padding-bottom: 0;
}

.preview-phone {
  width: min(84%, 420px);
  transform: translateY(12px);
}

.phone-shell.preview-shell > img.phone.preview-phone {
  align-self: end;
  margin-bottom: 0;
  transform: none;
  object-fit: contain;
  object-position: center bottom;
  width: min(90%, 460px);
}

.goals-shell {
  align-items: flex-start;
  padding-top: 0;
}

.goals-phone {
  width: min(88%, 500px);
  margin-top: -14px;
  margin-bottom: 0;
}

.phone-shell.goals-shell > img.phone.goals-phone {
  width: min(94%, 560px);
  align-self: start;
  object-fit: contain;
  object-position: center top;
}

.split-copy h2 {
  margin: 0;
  font-size: clamp(34px, 3.4vw, 52px);
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.split-copy > p {
  margin: 18px 0 0;
  color: var(--text-secondary);
  font-size: 20px;
}

.bullet-card,
.bullet-row {
  margin-top: 22px;
  display: flex;
  gap: 18px;
  align-items: flex-start;
}

.bullet-card {
  padding: 12px;
  border-radius: 24px;
}

.bullet-card.active {
  background: #e8f0f1;
  border: 2px solid rgba(16, 163, 157, 0.4);
  border-bottom-width: 4px;
}

.bullet-card h3,
.bullet-row h3 {
  margin: 2px 0 6px;
  font-family: 'Inter', sans-serif;
  font-size: 20px;
  line-height: 1.25;
}

.bullet-card p,
.bullet-row p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 20px;
}

/* Add extra spacing between rows in the "Take Control" list only. */
.split.section.reverse .bullet-row + .bullet-row {
  margin-top: 30px;
}

.cta.section {
  background: var(--surface-muted);
  padding-top: 200px;
}

.cta-panel {
  background: linear-gradient(315deg, #025a63 0%, #14b8a6 100%);
  border-radius: var(--radius-xl);
  min-height: 483px;
  padding: 64px 84px;
  position: relative;
  display: grid;
  grid-template-columns: 1fr minmax(280px, 420px);
  align-items: center;
  gap: 32px;
  overflow: hidden;
}

.cta-copy h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(36px, 3.6vw, 52px);
  line-height: 1.3;
}

.cta-copy ul {
  margin: 10px 0 0;
  padding-left: 18px;
  color: #fff;
  font-size: 20px;
}

.cta-phone {
  width: min(44%, 560px);
  max-width: 560px;
  position: absolute;
  right: 20px;
  bottom: -192px;
  filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.3));
}

.site-footer {
  background: #fff;
  border-top: 1px solid #c8c8d5;
  padding: 80px 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.7fr 1fr;
  gap: 56px;
}

.footer-brand p {
  margin: 18px 0 0;
  color: var(--text-secondary);
  font-size: 17px;
  max-width: 320px;
}

.footer-links,
.footer-social {
  display: flex;
  flex-direction: column;
  gap: 16px;
  font-family: 'Inter', sans-serif;
}

.footer-links h4,
.footer-social h4 {
  margin: 0 0 10px;
  font-size: 17px;
  font-weight: 800;
  color: #050229;
}

.footer-links a,
.footer-social a {
  color: var(--text-secondary);
  font-size: 17px;
  font-weight: 500;
}

.footer-links a:hover,
.footer-social a:hover {
  color: var(--brand);
}

.footer-social a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.footer-social img {
  width: 42px;
  height: 42px;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  animation: rise 680ms cubic-bezier(0.2, 0.75, 0.2, 1) forwards;
}

.reveal-stagger > .reveal:nth-child(1) {
  animation-delay: 40ms;
}

.reveal-stagger > .reveal:nth-child(2) {
  animation-delay: 150ms;
}

.reveal-stagger > .reveal:nth-child(3) {
  animation-delay: 260ms;
}

@keyframes rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    animation: none;
  }
}

@media (max-width: 1100px) {
  .container {
    width: min(1224px, calc(100% - 40px));
  }

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

  .hero-visual {
    max-width: 640px;
    margin: 0 auto;
  }

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

  .card-wide {
    grid-column: span 2;
  }

  .split-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .reverse .split-visual {
    order: 1;
  }

  .reverse .split-copy {
    order: 2;
  }

  .cta-panel {
    grid-template-columns: 1fr;
    padding: 52px 34px 0;
    align-items: end;
    overflow: visible;
  }

  .cta-phone {
    width: min(84%, 460px);
    max-width: 460px;
    position: static;
    justify-self: center;
    align-self: end;
    margin: 0 auto 0;
    transform: none;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
}

@media (max-width: 760px) {
  .section {
    padding: 60px 0;
  }

  .cta.section {
    padding-top: 140px;
  }

  .nav-wrap {
    min-height: 76px;
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 12px 0;
  }

  .brand,
  .main-nav,
  .social-icons {
    justify-self: center;
  }

  .brand {
    font-size: 26px;
  }

  .main-nav {
    gap: 18px;
  }

  .main-nav a {
    font-size: 15px;
  }

  .social-icons img,
  .footer-social img {
    width: 36px;
    height: 36px;
  }

  .hero-copy p,
  .card p,
  .split-copy > p,
  .bullet-card p,
  .bullet-row p,
  .cta-copy ul {
    font-size: 17px;
  }

  .phone-shell.shell-teal {
    min-height: 430px;
  }

  .phone-shell.tall {
    min-height: 520px;
    border-radius: 34px;
  }

  .phone.phone-tilt {
    width: min(80%, 290px);
    transform: rotate(4deg) translateY(26px);
  }

  .hero-phone {
    width: 78%;
    max-width: none;
    transform: translateY(0);
  }

  .phone.phone-tilt.hero-phone {
    width: 78%;
    max-width: none;
    transform: translateY(0);
  }

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

  .card-wide {
    grid-column: span 1;
    grid-template-columns: 1fr;
  }

  .card-phone {
    margin: 6px auto 0;
  }

  .top-home-phone {
    width: 100%;
    max-width: 330px;
    margin: 6px auto -2px;
  }

  .preview-phone,
  .goals-phone {
    width: min(88%, 420px);
    transform: none;
    margin-top: 0;
  }

  .goals-shell {
    align-items: center;
  }

  .icon-72 {
    width: 64px;
    height: 64px;
  }

  .cta-panel {
    border-radius: 34px;
  }

  .cta .store-buttons.light {
    width: 100%;
    max-width: 420px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 18px;
  }

  .cta .store-buttons.light .btn {
    min-height: 50px;
    padding: 8px 10px;
    font-size: 13px;
    gap: 6px;
    white-space: nowrap;
  }

  .cta .store-buttons.light .btn img {
    width: 16px;
  }

  .cta .cta-panel {
    overflow: visible !important;
    align-items: end !important;
    padding: 42px 20px 0 !important;
    gap: 16px !important;
  }

  .cta .cta-panel .cta-phone {
    width: min(90%, 330px) !important;
    max-width: 330px !important;
    display: block !important;
    margin: 0 auto 0 !important;
    justify-self: center !important;
    align-self: end !important;
    transform: none !important;
    position: static !important;
  }

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

/* Final size locks for section mockups (kept last to avoid override) */
.split .phone-shell.preview-shell > img.phone.preview-phone {
  width: min(92%, 500px) !important;
}

.split .phone-shell.goals-shell > img.phone.goals-phone {
  width: min(96%, 590px) !important;
}

@media (max-width: 760px) {
  .split .phone-shell.preview-shell > img.phone.preview-phone {
    width: min(94%, 470px) !important;
  }

  .split .phone-shell.goals-shell > img.phone.goals-phone {
    width: min(98%, 560px) !important;
  }

  /* Mobile fix: Take Control section copy should use full width, then bullets */
  .split.section.reverse .split-grid {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }

  .split.section.reverse .split-copy {
    order: 1 !important;
    width: 100% !important;
    max-width: none !important;
  }

  .split.section.reverse .split-copy h2,
  .split.section.reverse .split-copy > p {
    width: 100% !important;
    max-width: none !important;
  }

  .split.section.reverse .bullet-row {
    width: 100% !important;
    margin-top: 24px !important;
  }

  .split.section.reverse .split-visual {
    order: 2 !important;
    width: 100% !important;
  }
}

/* Final lock: CTA phone pops out in desktop without clipping */
@media (min-width: 1101px) {
  .cta .cta-panel {
    overflow: visible !important;
  }

  .cta .cta-panel .cta-copy {
    position: relative;
    z-index: 2;
  }

  .cta .cta-panel .cta-phone {
    width: min(38%, 500px) !important;
    max-width: 500px !important;
    position: absolute !important;
    right: 14px !important;
    bottom: 0 !important;
    transform: none !important;
    z-index: 4 !important;
  }
}
