/* ============================================
   Health Lock — Styles
   Design system: design-model.yaml
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700;800&family=Manrope:wght@400;500;600;700&display=swap');

/* --- Custom Properties --- */
:root {
  --color-background: #F3F8FC;
  --color-surface: #FFFFFF;
  --color-text: #07141E;
  --color-primary: #143B59;
  --color-secondary: #2671A9;
  --color-accent: #308DD3;
  --color-border: #D1E6F5;
  --color-ring: #308DD3;
  --color-cream: #FEF9F2;
  --color-amber: #E8864A;
  --color-sky-band: #EBF5FC;
  --color-card-border: #EAD9C6;

  --font-heading: 'Space Grotesk', system-ui, sans-serif;
  --font-body: 'Manrope', system-ui, sans-serif;

  --max-width: 1160px;
  --padding-desktop: 80px;
  --padding-mobile: 24px;

  --radius-button: 10px;
  --radius-card: 16px;
}

/* --- Reset & Base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.65;
  color: var(--color-text);
  background-color: var(--color-background);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.1;
  color: var(--color-primary);
}

/* --- Container --- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: var(--padding-mobile);
  padding-right: var(--padding-mobile);
}

@media (min-width: 768px) {
  .container {
    padding-left: var(--padding-desktop);
    padding-right: var(--padding-desktop);
  }
}

/* ============================================
   Navbar
   ============================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 16px 0;
  background: transparent;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 1px 12px rgba(7, 20, 30, 0.06);
  backdrop-filter: blur(8px);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 20px;
  color: var(--color-primary);
}

.navbar-brand img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
}

.navbar-links {
  display: none;
  list-style: none;
  gap: 32px;
  align-items: center;
}

.navbar-links li a {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 500;
  color: var(--color-primary);
  transition: color 0.2s ease;
}

.navbar-links li a:hover {
  color: var(--color-accent);
}

.navbar-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 24px;
  background: var(--color-accent);
  color: #fff;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-button);
  border: none;
  cursor: pointer;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.navbar-cta:hover {
  box-shadow: 0 4px 16px rgba(48, 141, 211, 0.35);
  transform: translateY(-1px);
}

/* Mobile menu toggle */
.navbar-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.navbar-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-primary);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.navbar-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.navbar-toggle.active span:nth-child(2) {
  opacity: 0;
}

.navbar-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.mobile-menu {
  display: none;
  position: fixed;
  top: 72px;
  left: 0;
  right: 0;
  background: var(--color-surface);
  padding: 24px;
  box-shadow: 0 8px 32px rgba(7, 20, 30, 0.1);
  z-index: 999;
}

.mobile-menu.open {
  display: block;
}

.mobile-menu ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.mobile-menu ul li a {
  font-size: 17px;
  font-weight: 500;
  color: var(--color-primary);
}

@media (min-width: 768px) {
  .navbar-links {
    display: flex;
  }
  .navbar-toggle {
    display: none;
  }
}

/* ============================================
   Hero
   ============================================ */
.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  padding-top: 120px;
  padding-bottom: 80px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(243, 248, 252, 0.92) 0%,
    rgba(243, 248, 252, 0.85) 35%,
    rgba(254, 249, 242, 0.7) 60%,
    rgba(254, 249, 242, 0.4) 100%
  );
}

.hero .container {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.hero-content {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px 6px 6px;
  background: var(--color-surface);
  border: 1.5px solid var(--color-border);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-secondary);
  margin-bottom: 24px;
  box-shadow: 0 2px 8px rgba(7, 20, 30, 0.05);
}

.hero-badge .badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-amber);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.3); }
}

.hero h1 {
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.025em;
  margin-bottom: 24px;
  color: var(--color-primary);
}

.hero h1 .accent {
  color: var(--color-accent);
}

.hero-sub {
  font-size: 20px;
  line-height: 1.6;
  color: var(--color-secondary);
  margin-bottom: 32px;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 52px;
  padding: 0 32px;
  background: var(--color-accent);
  color: #fff;
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  border-radius: var(--radius-button);
  border: none;
  cursor: pointer;
  transition: box-shadow 0.25s ease, transform 0.25s ease;
  gap: 8px;
}

.btn-primary:hover {
  box-shadow: 0 6px 24px rgba(48, 141, 211, 0.35);
  transform: translateY(-2px);
}

.btn-secondary-link {
  font-size: 15px;
  font-weight: 500;
  color: var(--color-secondary);
  transition: color 0.2s ease;
}

.btn-secondary-link:hover {
  color: var(--color-accent);
}


/* ============================================
   Problem / Outcome Section
   ============================================ */
.problem-section {
  background: var(--color-surface);
  padding: 80px 0;
}

.problem-section .container {
  text-align: center;
}

.section-label {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 16px;
}

.section-heading {
  font-size: clamp(26px, 3.5vw, 40px);
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: -0.01em;
}

.section-sub {
  font-size: 17px;
  line-height: 1.65;
  color: var(--color-secondary);
  max-width: 640px;
  margin: 0 auto 56px;
}

.stat-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}

.stat-card {
  padding: 32px 24px;
  text-align: center;
  position: relative;
}

.stat-card::before {
  content: '';
  display: block;
  width: 48px;
  height: 3px;
  background: var(--color-amber);
  border-radius: 2px;
  margin: 0 auto 20px;
}

.stat-number {
  font-family: var(--font-heading);
  font-size: clamp(36px, 4vw, 48px);
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1.1;
  margin-bottom: 8px;
}

.stat-label {
  font-size: 15px;
  font-weight: 500;
  color: var(--color-secondary);
  line-height: 1.5;
}

@media (min-width: 768px) {
  .stat-row {
    grid-template-columns: repeat(3, 1fr);
    gap: 48px;
  }
}

/* ============================================
   Feature Highlights
   ============================================ */
.features-section {
  background: var(--color-cream);
  padding: 96px 0;
}

.features-section .container {
  text-align: center;
}

.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 56px;
}

.feature-card {
  background: var(--color-surface);
  border: 1.5px solid var(--color-card-border);
  border-radius: var(--radius-card);
  padding: 28px;
  text-align: left;
  box-shadow: 0 2px 12px rgba(7, 20, 30, 0.04);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(7, 20, 30, 0.08);
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--color-sky-band);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.feature-icon svg {
  width: 24px;
  height: 24px;
  color: var(--color-accent);
}

.feature-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--color-primary);
}

.feature-card p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--color-secondary);
}

@media (min-width: 768px) {
  .features-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================
   How It Works — Workflow Rail
   ============================================ */
.workflow-section {
  background: var(--color-sky-band);
  padding: 96px 0;
}

.workflow-section .container {
  text-align: center;
}

.workflow-rail {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 56px;
  position: relative;
}

.workflow-step {
  background: var(--color-surface);
  border-radius: var(--radius-card);
  padding: 32px 28px;
  text-align: left;
  box-shadow: 0 2px 16px rgba(7, 20, 30, 0.05);
  position: relative;
  opacity: 0;
  animation: reveal-step 0.5s ease-out forwards;
}

.workflow-step:nth-child(1) { animation-delay: 0.1s; }
.workflow-step:nth-child(2) { animation-delay: 0.25s; }
.workflow-step:nth-child(3) { animation-delay: 0.4s; }

@keyframes reveal-step {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.step-time {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 16px;
}

.step-time .step-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-accent);
}

.workflow-step h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--color-primary);
}

.workflow-step p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--color-secondary);
}

.workflow-cta {
  margin-top: 48px;
}

@media (min-width: 768px) {
  .workflow-rail {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================
   Trust / Proof
   ============================================ */
.trust-section {
  background: var(--color-surface);
  padding: 96px 0;
}

.trust-section .container {
  text-align: center;
}

.trust-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-top: 56px;
}

.trust-card {
  padding: 32px 24px;
  text-align: center;
}

.trust-stat {
  font-family: var(--font-heading);
  font-size: clamp(28px, 3vw, 36px);
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1.15;
  margin-bottom: 6px;
}

.trust-stat .highlight {
  color: var(--color-accent);
}

.trust-desc {
  font-size: 15px;
  color: var(--color-secondary);
  line-height: 1.5;
}

.trust-badge-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
  margin-top: 48px;
}

.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--color-sky-band);
  border-radius: 100px;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-primary);
}

.trust-badge svg {
  width: 18px;
  height: 18px;
  color: var(--color-accent);
}

@media (min-width: 768px) {
  .trust-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================
   Pricing Preview
   ============================================ */
.pricing-section {
  background: var(--color-cream);
  padding: 96px 0;
}

.pricing-section .container {
  text-align: center;
}

.pricing-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 56px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.pricing-card {
  background: var(--color-surface);
  border: 1.5px solid var(--color-card-border);
  border-radius: var(--radius-card);
  padding: 36px 28px;
  text-align: center;
  box-shadow: 0 2px 12px rgba(7, 20, 30, 0.04);
  position: relative;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.pricing-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(7, 20, 30, 0.08);
}

.pricing-card.featured {
  border-color: var(--color-accent);
  box-shadow: 0 4px 24px rgba(48, 141, 211, 0.12);
}

.pricing-card.featured::before {
  content: 'Best Value';
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-accent);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 16px;
  border-radius: 100px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.pricing-label {
  font-family: var(--font-heading);
  font-size: 15px;
  font-weight: 600;
  color: var(--color-secondary);
  margin-bottom: 8px;
}

.pricing-amount {
  font-family: var(--font-heading);
  font-size: clamp(36px, 4vw, 48px);
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1.1;
}

.pricing-amount .period {
  font-size: 16px;
  font-weight: 500;
  color: var(--color-secondary);
}

.pricing-desc {
  font-size: 15px;
  color: var(--color-secondary);
  margin-top: 12px;
  margin-bottom: 24px;
  line-height: 1.5;
}

.pricing-card .btn-primary {
  width: 100%;
}

@media (min-width: 768px) {
  .pricing-grid {
    grid-template-columns: repeat(3, 1fr);
    margin-top: 56px;
  }
}

/* ============================================
   CTA Band
   ============================================ */
.cta-section {
  position: relative;
  padding: 96px 0;
  overflow: hidden;
  background: linear-gradient(135deg, var(--color-sky-band) 0%, var(--color-cream) 100%);
}

.cta-section .container {
  text-align: center;
  position: relative;
  z-index: 1;
}

.cta-section .section-heading {
  margin-bottom: 16px;
}

.cta-section .section-sub {
  margin-bottom: 40px;
}

.cta-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.cta-app-icon {
  width: 80px;
  height: 80px;
  border-radius: 18px;
  box-shadow: 0 8px 32px rgba(7, 20, 30, 0.1);
  margin-bottom: 8px;
  margin-left: auto;
  margin-right: auto;
}

/* ============================================
   Footer
   ============================================ */
.footer {
  background: var(--color-primary);
  color: rgba(255, 255, 255, 0.7);
  padding: 56px 0 40px;
}

.footer .container {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.footer-top {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 20px;
  color: #fff;
}

.footer-brand img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.footer-desc {
  font-size: 15px;
  line-height: 1.6;
  max-width: 360px;
  color: rgba(255, 255, 255, 0.6);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  list-style: none;
}

.footer-links a {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.7);
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 13px;
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.5);
  transition: color 0.2s ease;
}

.footer-bottom a:hover {
  color: #fff;
}

@media (min-width: 768px) {
  .footer-top {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
  }

  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

/* ============================================
   Section fade-in animation
   ============================================ */
.fade-in-section {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.fade-in-section.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   Utility
   ============================================ */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* App Store badge styling */
.app-store-badge {
  display: inline-block;
  height: 44px;
  opacity: 0.5;
  cursor: not-allowed;
  position: relative;
}

.app-store-badge svg {
  height: 44px;
  width: auto;
}

/* Coming soon pill */
.coming-soon-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: rgba(232, 134, 74, 0.12);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-amber);
}

/* ============================================
   Responsive fine-tuning
   ============================================ */
@media (max-width: 767px) {
  .hero {
    min-height: 70vh;
    padding-top: 100px;
    padding-bottom: 64px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .section-heading {
    font-size: 28px;
  }

  .problem-section,
  .features-section,
  .workflow-section,
  .trust-section,
  .pricing-section,
  .cta-section {
    padding: 64px 0;
  }
}
