/* ============================================================
   Mynt — main stylesheet
   Apple-inspired: system fonts, generous whitespace, sticky nav
   ============================================================ */

/* ---------- Design tokens ---------- */
:root {
  --color-bg:           #ffffff;
  --color-bg-alt:       #f5f5f7;       /* Apple's signature off-white */
  --color-text:         #1d1d1f;       /* Apple's near-black */
  --color-text-muted:   #6e6e73;       /* Apple's secondary gray */
  --color-text-faint:   #86868b;
  --color-accent:       #2d6961;       /* Mynt brand teal (M3 primary) */
  --color-accent-deep:  #003631;       /* Deep teal (raw seed) */
  --color-border:       rgba(0, 0, 0, 0.08);

  --radius-card:        20px;
  --radius-image:       24px;
  --radius-pill:        100px;

  --max-width:          1100px;
  --max-width-narrow:   780px;

  --shadow-image:       0 30px 60px rgba(0, 0, 0, 0.12);
  --shadow-card:        0 1px 3px rgba(0, 0, 0, 0.05), 0 4px 24px rgba(0, 0, 0, 0.04);

  --font-stack:         -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text",
                        "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-stack);
  font-size: 17px;
  line-height: 1.5;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; height: auto; }
a   { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

/* ---------- Navigation ---------- */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--color-border);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--color-text);
}

.nav-links {
  display: flex;
  gap: 36px;
}

.nav-links a {
  font-size: 14px;
  font-weight: 400;
  color: var(--color-text);
  opacity: 0.82;
  transition: opacity 0.2s ease, color 0.2s ease;
}

.nav-links a:hover {
  opacity: 1;
  color: var(--color-accent);
}

/* ---------- Hero ---------- */
.hero {
  padding: 120px 24px 80px;
  text-align: center;
  max-width: 980px;
  margin: 0 auto;
}

.hero-pill {
  display: inline-block;
  padding: 6px 16px;
  margin-bottom: 28px;
  background: rgba(45, 105, 97, 0.10);
  color: var(--color-accent);
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

a.hero-pill {
  transition: background 0.2s ease, transform 0.2s ease;
}

a.hero-pill:hover {
  background: rgba(45, 105, 97, 0.18);
  transform: translateY(-1px);
}

.hero h1 {
  font-size: clamp(36px, 6vw, 72px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin-bottom: 24px;
}

.muted-headline {
  color: var(--color-text-muted);
  font-weight: 700;
}

.hero .lead {
  font-size: clamp(18px, 2vw, 22px);
  font-weight: 400;
  color: var(--color-text-muted);
  max-width: 640px;
  margin: 0 auto 64px;
  line-height: 1.4;
}

.hero-image {
  max-width: 320px;
  margin: 0 auto;
}

.hero-image img {
  border-radius: var(--radius-image);
  box-shadow: var(--shadow-image);
}

/* ---------- Generic section ---------- */
.section {
  padding: 100px 24px;
}

.section-alt {
  background: var(--color-bg-alt);
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
}

.container-narrow {
  max-width: var(--max-width-narrow);
  margin: 0 auto;
}

.section h2 {
  font-size: clamp(30px, 4vw, 48px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  text-align: center;
  margin-bottom: 16px;
}

.section-lead {
  font-size: clamp(16px, 1.6vw, 19px);
  color: var(--color-text-muted);
  text-align: center;
  max-width: 620px;
  margin: 0 auto 64px;
  line-height: 1.5;
}

/* ---------- Features overview grid ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature {
  padding: 36px 28px;
  background: #ffffff;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}

.feature-icon {
  margin-bottom: 20px;
}

.feature-icon img {
  width: 52px;
  height: 52px;
  display: block;
}

.feature h3 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 10px;
}

.feature p {
  font-size: 16px;
  color: var(--color-text-muted);
  line-height: 1.55;
}

/* ---------- Feature deep-dive sections ---------- */
.section-feature .feature-row {
  display: flex;
  flex-direction: row-reverse;       /* default: image RIGHT, text LEFT */
  align-items: center;
  gap: 80px;
  max-width: 1000px;
  margin: 0 auto;
}

.section-feature.feature-reverse .feature-row {
  flex-direction: row;               /* reversed: image LEFT, text RIGHT */
}

.feature-text {
  flex: 1 1 0;
}

.feature-image {
  flex: 0 0 300px;
}

.feature-image img {
  border-radius: var(--radius-image);
  box-shadow: var(--shadow-image);
}

.feature-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 18px;
}

.feature-icon-large {
  margin-bottom: 20px;
}

.feature-icon-large img {
  width: 64px;
  height: 64px;
  display: inline-block;
}

.feature-headline {
  font-size: clamp(28px, 3.5vw, 42px) !important;   /* override centered .section h2 */
  text-align: left !important;
  margin-bottom: 20px !important;
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.feature-text p {
  font-size: 18px;
  line-height: 1.55;
  color: var(--color-text-muted);
}

/* ---------- Roadmap ---------- */
.roadmap-placeholder {
  text-align: center;
  color: var(--color-text-faint);
  font-size: 15px;
  font-style: italic;
  margin-top: 24px;
}

/* ---------- Footer ---------- */
footer {
  padding: 56px 24px 48px;
  background: var(--color-bg);
  border-top: 1px solid var(--color-border);
  text-align: center;
}

.footer-brand {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
  color: var(--color-accent);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 28px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.footer-links a {
  font-size: 14px;
  color: var(--color-text-muted);
  transition: color 0.2s ease;
}

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

.footer-copyright {
  font-size: 12px;
  color: var(--color-text-faint);
}

/* ---------- Confirmation pages (welcome + share) ---------- */
.confirmation-wrap {
  min-height: calc(100vh - 200px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
}

.confirmation-card {
  max-width: 560px;
  width: 100%;
  text-align: center;
  padding: 56px 40px;
  background: #ffffff;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}

.confirmation-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(45, 105, 97, 0.10);
  color: var(--color-accent);
  margin-bottom: 28px;
}

.confirmation-icon-image {
  background: transparent;
  width: auto;
  height: auto;
}

.confirmation-icon-image img {
  width: 72px;
  height: 72px;
}

.confirmation-headline {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin-bottom: 16px;
}

.confirmation-lead {
  font-size: 18px;
  color: var(--color-text-muted);
  line-height: 1.5;
  margin-bottom: 32px;
}

.confirmation-cta {
  margin: 32px 0 24px;
}

.btn-primary {
  display: inline-block;
  padding: 14px 32px;
  background: var(--color-accent);
  color: #ffffff;
  border-radius: var(--radius-pill);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: background 0.2s ease, transform 0.2s ease;
}

.btn-primary:hover {
  background: var(--color-accent-deep);
  transform: translateY(-1px);
}

.confirmation-fallback {
  font-size: 14px;
  color: var(--color-text-faint);
  margin-top: 16px;
  line-height: 1.5;
}

.confirmation-fallback a {
  color: var(--color-accent);
  font-weight: 500;
}

.confirmation-fallback a:hover {
  text-decoration: underline;
}

/* ---------- Legal pages (privacy, terms) ---------- */
.legal-page {
  max-width: 720px;
  margin: 0 auto;
  padding: 80px 24px 100px;
}

.legal-header h1 {
  font-size: clamp(36px, 5vw, 52px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin-bottom: 16px;
}

.legal-updated {
  display: inline-block;
  padding: 4px 12px;
  background: var(--color-bg-alt);
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 500;
  color: var(--color-text-muted);
  margin-bottom: 24px;
}

.legal-intro {
  font-size: 18px;
  color: var(--color-text-muted);
  line-height: 1.55;
  margin-bottom: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--color-border);
}

.legal-section {
  margin-bottom: 40px;
}

.legal-section h2 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--color-text);
  margin-bottom: 16px;
  text-align: left;
  line-height: 1.3;
}

.legal-section p,
.legal-section li {
  font-size: 16px;
  color: var(--color-text);
  line-height: 1.65;
  margin-bottom: 14px;
}

.legal-section ul {
  list-style: disc;
  padding-left: 24px;
  margin-bottom: 14px;
}

.legal-section li {
  margin-bottom: 8px;
}

.legal-section a {
  color: var(--color-accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.legal-section a:hover {
  text-decoration-thickness: 2px;
}

.legal-section strong {
  color: var(--color-text);
  font-weight: 600;
}

.legal-callout {
  margin-top: 48px;
  padding: 32px;
  background: var(--color-bg-alt);
  border-radius: var(--radius-card);
  text-align: center;
}

.legal-callout h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--color-text);
}

.legal-callout p {
  font-size: 15px;
  color: var(--color-text-muted);
  line-height: 1.55;
  margin-bottom: 12px;
}

.legal-callout p:last-child {
  margin-bottom: 0;
}

.legal-callout-copy {
  font-size: 13px !important;
  color: var(--color-text-faint) !important;
  margin-top: 16px !important;
}

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .nav-links { gap: 18px; }
  .nav-links a { font-size: 13px; }
  .hero { padding: 80px 20px 60px; }
  .hero .lead { margin-bottom: 48px; }
  .section { padding: 72px 20px; }
  .section h2 { margin-bottom: 12px; }
  .section-lead { margin-bottom: 48px; }
  .feature-grid { grid-template-columns: 1fr; }

  /* Stack feature deep-dive sections, image always on top */
  .section-feature .feature-row,
  .section-feature.feature-reverse .feature-row {
    flex-direction: column;
    gap: 40px;
    text-align: center;
  }

  .feature-image {
    flex-basis: auto;
    max-width: 260px;
    margin: 0 auto;
  }

  .feature-tag {
    margin-bottom: 12px;
  }

  .feature-headline {
    text-align: center !important;
  }

  /* Confirmation cards on mobile */
  .confirmation-card { padding: 40px 24px; }
  .confirmation-lead { font-size: 16px; }

  /* Legal pages on mobile */
  .legal-page { padding: 56px 20px 72px; }
  .legal-intro { font-size: 16px; margin-bottom: 36px; padding-bottom: 36px; }
  .legal-section { margin-bottom: 32px; }
  .legal-section h2 { font-size: 20px; }
  .legal-section p, .legal-section li { font-size: 15px; }
  .legal-callout { padding: 24px; }
}

@media (max-width: 520px) {
  .nav-links { display: none; } /* TODO: hamburger menu in a later pass */
  .hero { padding: 60px 20px 50px; }
}
