/* ==========================================================================
   Luna Marketing Site — Shared Stylesheet
   Editorial, asymmetric, magazine-quality design system
   ========================================================================== */

/* ---------- Design tokens ---------- */
:root {
  /* Brand palette */
  --deep-purple: #2E1058;
  --brand-purple: #450B73;
  --medium-purple: #6E427A;
  --brand-pink: #D77A87;
  --accent-pink: #BC78B8;
  --light-lavender: #EAD3F5;
  --blush-white: #FBF5FB;
  --warm-cream: #FFFAFB;

  /* Semantic text colors */
  --text-primary: #2E1058;
  --text-secondary: #6E427A;

  /* Typography */
  --font-heading: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Hanken Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  /* Layout */
  --max-width: 1200px;
  --max-width-narrow: 600px;
  --radius: 24px;
  --radius-sm: 10px;
}

/* ---------- Reset & base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--warm-cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  /* Sticky footer */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main {
  flex: 1 0 auto;
}

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

a {
  color: var(--brand-purple);
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover {
  color: var(--accent-pink);
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  color: var(--text-primary);
  line-height: 1.1;
  margin: 0 0 1rem;
}

p {
  margin: 0 0 1rem;
}

/* Italic key-word accents that create rhythm across headlines */
.hero__title em,
.section__heading em {
  font-style: italic;
  color: var(--brand-pink);
}

/* ---------- Layout helpers ---------- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: 1.5rem;
}

.section {
  padding-block: clamp(2.75rem, 5vw, 4.5rem);
}

.eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.125em;
  color: var(--brand-pink);
  margin: 0 0 1.25rem;
}

/* Skip link for accessibility */
.skip-link {
  position: absolute;
  inset-inline-start: -999px;
  top: 0;
  background: var(--brand-purple);
  color: #fff;
  padding: 0.75rem 1.25rem;
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  z-index: 100;
}

.skip-link:focus {
  inset-inline-start: 0;
  color: #fff;
}

/* ==========================================================================
   Site header / navigation
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 250, 251, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid rgba(110, 66, 122, 0.08);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 1rem;
}

/* .brand-mark is the layout/color hook for the Luna logo; the font itself
   comes from .luna-wordmark so header and footer match the app exactly. */
.brand-mark {
  font-size: 1.75rem;
  color: var(--deep-purple);
  line-height: 1;
}

.brand-mark:hover {
  color: var(--deep-purple);
  opacity: 0.8;
}

/* Nav logo: icon symbol beside the Luna wordmark */
.logo-link {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}

.logo-icon {
  height: 36px;
  width: auto;
  display: block;
}

/* Brand wordmark — Dancing Script, matching the Luna app's identity */
.luna-wordmark {
  font-family: "Dancing Script", cursive;
  font-weight: 700;
  color: var(--brand-pink);
  line-height: 1;
  font-style: normal;
}

.luna-wordmark--hero {
  font-size: 96px;
}

.luna-wordmark--footer {
  font-size: 26px;
}

.luna-wordmark--nav {
  font-size: 32px;
  line-height: 1;
}

@media (max-width: 768px) {
  .luna-wordmark--hero {
    font-size: 64px;
  }

  .luna-wordmark--footer {
    font-size: 24px;
  }

  .luna-wordmark--nav {
    font-size: 26px;
  }

  .logo-icon {
    height: 28px;
  }

  .companion__avatar {
    width: 180px;
    height: 180px;
    padding: 14px;
  }
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.nav__list {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav__link {
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.nav__link:hover {
  color: var(--brand-purple);
}

/* Mobile menu toggle */
.nav-toggle {
  display: none;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 0.5rem;
  color: var(--deep-purple);
}

.nav-toggle__bar {
  display: block;
  width: 24px;
  height: 2px;
  background: currentColor;
  margin: 5px 0;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  padding: 0.85rem 1.75rem;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.btn--primary {
  background: var(--brand-purple);
  color: #fff;
}

.btn--primary:hover {
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(69, 11, 115, 0.25);
}

/* ==========================================================================
   Hero — split-screen asymmetric layout
   ========================================================================== */
.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--blush-white) 0%, var(--light-lavender) 100%);
  padding-block: clamp(3rem, 6vw, 5rem);
}

.hero__grid {
  display: grid;
  grid-template-columns: 55fr 45fr;
  align-items: center;
  gap: clamp(2rem, 5vw, 4rem);
}

.hero__title {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: clamp(3rem, 7vw, 6rem);
  line-height: 1.04;
  color: var(--deep-purple);
  margin: 0 0 1.5rem;
}

.hero__subhead {
  max-width: 30rem;
  margin: 0 0 1.75rem;
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  line-height: 1.6;
  color: rgba(110, 66, 122, 0.75);
}

/* Call to action: caption + official store badges */
.store-badges {
  display: flex;
  gap: 12px;
  align-items: center;
}

.store-badges a {
  display: inline-block;
  transition: transform 0.15s ease, opacity 0.2s ease;
}

.store-badges a:hover {
  transform: translateY(-2px);
  opacity: 0.92;
}

.store-badge {
  height: 56px;
  width: auto;
  display: block;
}

/* Device mockup with soft gradient blob behind it */
.hero__device {
  position: relative;
  display: flex;
  justify-content: center;
}

.hero__device::before {
  content: "";
  position: absolute;
  z-index: 0;
  width: clamp(280px, 35vw, 420px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--light-lavender), var(--brand-pink));
  opacity: 0.3;
  filter: blur(80px);
}

.device {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 320px;
  border-radius: 44px;
  overflow: hidden;
  background: var(--deep-purple);
  box-shadow: 0 30px 70px rgba(46, 16, 88, 0.32);
  transform: rotate(-3deg);
}

.device img {
  width: 100%;
  border-radius: 44px;
}

/* ==========================================================================
   The product — asymmetric feature grid
   ========================================================================== */
.section__heading {
  text-align: center;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  margin: 0 0 2.25rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 1.5rem;
}

.feature {
  background: var(--warm-cream);
  border: 1px solid var(--light-lavender);
  border-radius: var(--radius);
  padding: 3rem;
}

.feature--banner {
  grid-column: 1 / -1;
  background: linear-gradient(120deg, rgba(215, 122, 135, 0.18) 0%, var(--light-lavender) 100%);
  border-color: rgba(215, 122, 135, 0.25);
}

.feature__icon {
  font-size: 1.85rem;
  line-height: 1;
  margin-bottom: 1rem;
  color: var(--brand-purple);
}

.feature__title {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
}

.feature__body {
  color: var(--text-secondary);
  margin: 0;
  max-width: 34rem;
}

/* ==========================================================================
   Companion — avatar feature, two-column
   ========================================================================== */
.companion {
  background: var(--blush-white);
}

.companion__grid {
  display: grid;
  grid-template-columns: 45fr 55fr;
  align-items: center;
  gap: clamp(2rem, 5vw, 4rem);
}

.companion__visual {
  display: flex;
  justify-content: center;
}

.companion__avatar {
  width: 280px;
  height: 280px;
  border-radius: 50%;
  padding: 20px;
  background: linear-gradient(135deg, var(--light-lavender) 0%, var(--blush-white) 100%);
  box-shadow: 0 20px 50px rgba(46, 16, 88, 0.18);
}

.companion__avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.companion__title {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: clamp(2rem, 4.5vw, 3rem);
  line-height: 1.1;
  margin: 0 0 1.5rem;
}

.companion__title em {
  font-style: italic;
  color: var(--brand-pink);
}

.companion__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.companion__item {
  position: relative;
  padding-inline-start: 1.75rem;
  color: var(--text-secondary);
}

.companion__item::before {
  content: "\2713";
  position: absolute;
  inset-inline-start: 0;
  color: var(--brand-pink);
  font-weight: 700;
}

/* ==========================================================================
   Values — full-bleed deep purple
   ========================================================================== */
.values {
  background: var(--brand-purple);
  color: #fff;
  text-align: center;
  padding-block: clamp(3rem, 6vw, 5rem);
}

.values__heading {
  color: #fff;
  font-style: italic;
  font-weight: 600;
  font-size: clamp(2.5rem, 6vw, 5rem);
  margin: 0 0 2rem;
}

.values__list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
}

.values__item {
  margin: 0;
  font-size: clamp(1.1rem, 2.2vw, 1.4rem);
  color: rgba(255, 255, 255, 0.92);
}

.values__item::before {
  content: "\2713";
  color: var(--brand-pink);
  font-weight: 700;
  margin-inline-end: 0.6rem;
}

/* ==========================================================================
   Legal / content pages
   ========================================================================== */
.page-header {
  background: linear-gradient(180deg, var(--light-lavender) 0%, var(--warm-cream) 100%);
  text-align: center;
  padding-block: clamp(2.5rem, 6vw, 4rem) 0;
}

/* Tighten the gap between a legal page's title block and its body content
   (.page-header only appears on privacy.html and terms.html). */
.page-header + .section {
  padding-top: clamp(3rem, 6vw, 5rem);
}

.page-header__title {
  font-size: clamp(2.25rem, 6vw, 3.25rem);
  font-weight: 600;
}

.page-header__meta {
  color: var(--text-secondary);
  margin: 0;
}

.prose {
  max-width: 760px;
  margin-inline: auto;
  line-height: 1.7;
}

.prose h2 {
  font-size: 1.6rem;
  font-weight: 600;
  margin-top: 2.5rem;
}

.prose h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-top: 1.75rem;
}

.prose p,
.prose li {
  color: var(--text-secondary);
}

.prose ul {
  padding-inline-start: 1.25rem;
}

.prose li {
  margin-bottom: 0.5rem;
}

.prose a {
  text-decoration: underline;
}

/* ==========================================================================
   Contact page
   ========================================================================== */
.contact {
  text-align: center;
  max-width: var(--max-width-narrow);
  margin-inline: auto;
}

.contact__intro {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  line-height: 1.7;
}

.contact__title {
  font-family: var(--font-heading);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(2.5rem, 6vw, 3.5rem);
  margin: 0 0 1rem;
}

.contact__card {
  display: inline-block;
  margin: 1.5rem 0 1rem;
  padding: 1.25rem 2.5rem;
  background: var(--light-lavender);
  border: 1px solid rgba(110, 66, 122, 0.15);
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-style: italic;
  font-size: clamp(1.25rem, 4vw, 1.85rem);
  color: var(--brand-purple);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.contact__card:hover {
  color: var(--brand-purple);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(46, 16, 88, 0.15);
}

.contact__note {
  margin-top: 2rem;
  color: var(--medium-purple);
  font-size: 0.95rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--deep-purple);
  color: rgba(255, 255, 255, 0.8);
  padding-block: 1.75rem 1.5rem;
  margin-top: auto;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.8);
}

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

/* Minimal centered footer: wordmark, tagline, links, language switcher */
.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  text-align: center;
}

/* Footer wordmark cluster: avatar beside the small Luna wordmark */
.footer__wordmark {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer__avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
}

.footer__tagline {
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
  font-size: 0.95rem;
}

.footer__nav,
.footer__langs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.footer__sep {
  color: rgba(255, 255, 255, 0.35);
}

.footer__langs a.current {
  color: #fff;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.footer__copyright {
  margin: 0.5rem 0 0;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.55);
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 900px) {
  .hero__grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3rem;
  }

  .hero__subhead {
    margin-inline: auto;
  }

  .store-badges {
    justify-content: center;
  }

  .device {
    transform: none;
    margin-inline: auto;
  }

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

  .companion__grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 2.5rem;
  }

  .companion__list {
    align-items: center;
  }

  .companion__item {
    text-align: start;
  }
}

@media (max-width: 640px) {
  .nav-toggle {
    display: block;
  }

  .nav {
    position: absolute;
    top: 100%;
    inset-inline: 0;
    flex-direction: column;
    gap: 0;
    background: var(--warm-cream);
    border-bottom: 1px solid rgba(110, 66, 122, 0.12);
    padding: 1rem 1.5rem;
    display: none;
  }

  .nav.is-open {
    display: flex;
  }

  .nav__list {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    width: 100%;
  }

  .feature {
    padding: 2.25rem;
  }

  .store-badge {
    height: 48px;
  }
}
