/* ══════════════════════════════════════════════
   LEVAIN — landing page (erly.co structure)
   Palette: beige #F1F0ED · mustard #D2922D / #C4872A · warm brown ink
   Fonts: Inter (all) · Caveat (accent) — matches the app
   ══════════════════════════════════════════════ */

:root {
  --bg: #F1F0ED;        /* beige */
  --bg-2: #F7F6F3;
  --card: #FFFFFF;
  --card-soft: #E9E5DD; /* mockup card bg */
  --ink: #2A2016;       /* warm near-black brown (headings/text) */
  --ink-soft: #6E6255;  /* muted body */
  --mustard: #D2922D;
  --mustard-deep: #C4872A;  /* app buttonPrimary */
  --mustard-dark: #9F4C00;  /* deep accent text */
  --amber-bg: #EFE3CD;
  --line: #E3DDD6;
  --dark: #241A10;      /* espresso — App Store badge / dark text */

  --maxw: 1120px;
  --radius: 20px;
  --radius-lg: 28px;
  --shadow-sm: 0 4px 16px rgba(42, 32, 22, .06);
  --shadow-md: 0 18px 44px rgba(42, 32, 22, .12);
  --shadow-lg: 0 34px 80px rgba(36, 26, 16, .20);
  --ease: cubic-bezier(.22, 1, .36, 1);

  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --font-hand: 'Caveat', cursive;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  font-family: var(--font); color: var(--ink); background: var(--bg);
  line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3 { font-weight: 800; line-height: 1.05; letter-spacing: -.035em; }
.hl { color: var(--mustard-deep); }

/* ───── Buttons / badges ───── */
.btn {
  display: inline-flex; align-items: center; gap: .5rem; font-weight: 600; font-size: .95rem;
  border-radius: 999px; padding: .7rem 1.35rem; cursor: pointer;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), background .25s;
}
.btn--dark { background: var(--dark); color: #fff; }
.btn--dark:hover { background: #000; transform: translateY(-2px); box-shadow: var(--shadow-sm); }

.badge-store {
  display: inline-flex; align-items: center; gap: .6rem; background: var(--dark); color: #fff;
  padding: .7rem 1.3rem; border-radius: 14px; transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.badge-store:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.badge-store span { display: flex; flex-direction: column; line-height: 1.06; text-align: left; }
.badge-store small { font-size: .64rem; opacity: .82; font-weight: 500; }
.badge-store b { font-size: 1.1rem; font-weight: 600; }

/* ───── Reveal ───── */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal[data-delay="1"] { transition-delay: .08s; }
.reveal[data-delay="2"] { transition-delay: .16s; }
.reveal[data-delay="3"] { transition-delay: .24s; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .phone--front, .phone--back { animation: none !important; }
}

/* ───── Shared section head ───── */
.section-head { text-align: center; max-width: 640px; margin: 0 auto 3rem; }
.pill-label {
  display: inline-block; font-weight: 700; font-size: .74rem; letter-spacing: .06em; text-transform: uppercase;
  color: var(--mustard-dark); background: var(--amber-bg); padding: .38rem .85rem; border-radius: 999px; margin-bottom: 1.2rem;
}
.section-head h2 { font-size: clamp(2rem, 4.6vw, 3.1rem); }
.section-sub { color: var(--ink-soft); font-size: 1.08rem; margin-top: 1rem; }

/* ══════════════ NAVBAR ══════════════ */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 100; transition: background .4s var(--ease), box-shadow .4s, backdrop-filter .4s; }
.nav.scrolled { background: rgba(241,240,237,.8); backdrop-filter: saturate(180%) blur(16px); -webkit-backdrop-filter: saturate(180%) blur(16px); box-shadow: 0 1px 0 rgba(42,32,22,.07); }
.nav__inner { max-width: var(--maxw); margin: 0 auto; padding: .8rem 1.4rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: .55rem; }
.brand__mark { width: 34px; height: 34px; border-radius: 9px; box-shadow: var(--shadow-sm); }
.brand__word { font-family: var(--font-hand); font-size: 1.7rem; font-weight: 700; color: var(--ink); line-height: 1; }
.nav__links { display: flex; gap: 2rem; }
.nav__links a { font-weight: 500; font-size: .93rem; color: var(--ink); opacity: .8; transition: opacity .2s, color .2s; }
.nav__links a:hover { opacity: 1; color: var(--mustard-deep); }

/* ══════════════ HERO ══════════════ */
.hero {
  padding: 9rem 1.4rem 4.5rem;
  background:
    radial-gradient(90% 70% at 88% 0%, #FAF1DF 0%, rgba(250,241,223,0) 55%),
    var(--bg);
}
.hero__inner { max-width: var(--maxw); margin: 0 auto; display: grid; grid-template-columns: 1.02fr .98fr; gap: 2rem; align-items: center; }
.rating { display: inline-flex; align-items: center; gap: .6rem; margin-bottom: 1.5rem; }
.rating__avatars { display: flex; }
.rating__avatars span { width: 26px; height: 26px; border-radius: 50%; margin-left: -8px; border: 2px solid var(--bg); background: linear-gradient(135deg, var(--mustard), var(--mustard-dark)); }
.rating__avatars span:first-child { margin-left: 0; background: linear-gradient(135deg,#E7C088,#C4872A); }
.rating__avatars span:nth-child(2){ background: linear-gradient(135deg,#D6A24A,#9F4C00); }
.rating__text { font-size: .88rem; color: var(--ink-soft); }
.rating__text b { color: var(--mustard-dark); }
.hero h1 { font-size: clamp(2.7rem, 6.4vw, 4.6rem); letter-spacing: -.045em; }
.hero__sub { font-size: 1.16rem; color: var(--ink-soft); max-width: 30rem; margin: 1.4rem 0 2rem; }

/* hero devices — two overlapping phones */
.hero__devices { position: relative; display: flex; justify-content: center; align-items: center; min-height: 520px; }
.phone--back { position: absolute; right: 4%; top: 6%; transform: rotate(5deg) scale(.9); opacity: .96; z-index: 1; animation: floatB 7s ease-in-out infinite; }
.phone--front { position: relative; z-index: 2; transform: rotate(-3deg); animation: floatA 6s ease-in-out infinite; }
@keyframes floatA { 0%,100% { transform: rotate(-3deg) translateY(0); } 50% { transform: rotate(-3deg) translateY(-14px); } }
@keyframes floatB { 0%,100% { transform: rotate(5deg) scale(.9) translateY(0); } 50% { transform: rotate(5deg) scale(.9) translateY(-18px); } }

/* ══════════════ PHONE MOCKUP ══════════════ */
.phone { width: 280px; border-radius: 42px; padding: 11px; background: linear-gradient(160deg, #33281c, #16100a); box-shadow: var(--shadow-lg), inset 0 0 0 2px rgba(255,255,255,.05); }
.phone--card { width: 100%; max-width: 210px; margin: 0 auto; }
.phone__notch { position: absolute; top: 17px; left: 50%; transform: translateX(-50%); width: 112px; height: 24px; background: #16100a; border-radius: 0 0 14px 14px; z-index: 5; }
.phone__screen { position: relative; border-radius: 31px; overflow: hidden; aspect-ratio: 9 / 19.3; background: var(--bg); padding: 2.4rem .8rem .9rem; display: flex; flex-direction: column; }
.status-bar { display: flex; justify-content: space-between; font-size: .68rem; font-weight: 600; color: var(--ink); padding: 0 .3rem .5rem; }
.status-bar__icons { letter-spacing: 1px; }
.scr-title { font-size: 1.25rem; font-weight: 800; letter-spacing: -.03em; margin: .1rem .2rem .6rem; }

/* tags / bars / ring (mustard) */
.tag { display: inline-block; font-size: .6rem; font-weight: 700; padding: .18rem .5rem; border-radius: 999px; text-transform: uppercase; letter-spacing: .04em; background: var(--amber-bg); color: var(--mustard-dark); }
.tag--ready { background: rgba(210,146,45,.18); color: var(--mustard-dark); }
.bar { height: 7px; border-radius: 999px; background: rgba(42,32,22,.1); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--mustard-deep), var(--mustard)); }
.bar--onmustard { background: rgba(255,255,255,.28); }
.bar--onmustard i { background: #fff; }

.ring { --p: 80; width: 72px; height: 72px; border-radius: 50%; flex: none; background: conic-gradient(var(--mustard-deep) calc(var(--p)*1%), rgba(42,32,22,.1) 0); display: grid; place-items: center; }
.ring--lg { width: 116px; height: 116px; margin: .5rem auto .3rem; }
.ring__hole { width: 58px; height: 58px; border-radius: 50%; background: var(--bg); display: grid; place-items: center; flex-direction: column; }
.ring--lg .ring__hole { width: 94px; height: 94px; }
.ring__hole b { font-size: 1.15rem; font-weight: 800; color: var(--ink); letter-spacing: -.03em; }
.ring--lg .ring__hole b { font-size: 1.7rem; }
.ring__hole small { font-size: .56rem; color: var(--ink-soft); margin-top: -2px; }

/* screen: HOME */
.sh-greet { display: flex; align-items: center; justify-content: space-between; margin: .1rem .2rem .8rem; }
.sh-hello { font-size: 1.02rem; font-weight: 800; letter-spacing: -.03em; }
.sh-tag { font-family: var(--font-hand); font-size: 1.1rem; color: var(--mustard-dark); line-height: 1; }
.sh-avatar { width: 32px; height: 32px; border-radius: 50%; background: linear-gradient(135deg, var(--mustard), var(--mustard-dark)); }
.sh-card { background: var(--card); border-radius: 18px; padding: .75rem; display: flex; gap: .7rem; align-items: center; box-shadow: var(--shadow-sm); margin-bottom: .6rem; }
.sh-card__title { font-weight: 700; font-size: .82rem; margin: .25rem 0 .08rem; }
.sh-card__meta { font-size: .66rem; color: var(--ink-soft); }
.sh-actions { display: flex; gap: .4rem; margin-bottom: .6rem; }
.sh-act { flex: 1; background: var(--card); border-radius: 13px; padding: .5rem .3rem; text-align: center; font-size: .64rem; font-weight: 600; box-shadow: var(--shadow-sm); }
.sh-act span { display: block; font-size: 1rem; margin-bottom: .08rem; }
.sh-act--fill { background: var(--mustard-deep); color: #fff; }
.sh-lesson { background: linear-gradient(135deg, var(--mustard-deep), var(--mustard-dark)); border-radius: 16px; padding: .8rem; color: #fff; }
.sh-lesson__row { display: flex; justify-content: space-between; font-size: .64rem; opacity: .9; margin-bottom: .22rem; }
.sh-lesson__title { font-weight: 700; font-size: .8rem; margin-bottom: .5rem; }

/* screen: TRACK (step 1) */
.tk-name { text-align: center; font-weight: 800; font-size: .9rem; letter-spacing: -.02em; margin: .3rem 0 0; }
.tk-name span { color: var(--mustard-dark); font-weight: 500; }
.tk-curve { margin-top: .3rem; }
.tk-curve svg { width: 100%; height: 60px; }

/* screen: BAKE (step 2) */
.bake-now { background: linear-gradient(135deg, var(--mustard-deep), var(--mustard-dark)); border-radius: 16px; padding: .85rem; color: #fff; text-align: center; margin-bottom: .6rem; }
.bake-now__k { font-size: .6rem; opacity: .9; }
.bake-now__timer { font-size: 1.7rem; font-weight: 800; letter-spacing: -.03em; margin: .15rem 0 .55rem; font-variant-numeric: tabular-nums; }
.bake-now .bar { background: rgba(255,255,255,.28); }
.bake-now .bar i { background: #fff; }
.bake-list { display: flex; flex-direction: column; gap: .4rem; }
.bake-row { display: flex; align-items: center; gap: .5rem; background: var(--card); border-radius: 12px; padding: .5rem .6rem; font-size: .72rem; font-weight: 500; box-shadow: var(--shadow-sm); }
.bake-row span { width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid var(--line); display: grid; place-items: center; font-size: .54rem; flex: none; }
.bake-row em { margin-left: auto; font-style: normal; font-size: .6rem; color: var(--ink-soft); }
.bake-row.done span { background: var(--mustard-deep); border-color: var(--mustard-deep); color: #fff; }
.bake-row.on { outline: 2px solid var(--mustard); }
.bake-row.on span { background: var(--mustard); border-color: var(--mustard); color: #fff; }
.bake-row.on em { color: var(--mustard-dark); font-weight: 700; }

/* screen: JOURNAL (step 3) */
.jr-done { text-align: center; margin: .3rem 0 .7rem; }
.jr-done span { font-size: 1.7rem; }
.jr-done p { font-weight: 800; font-size: .95rem; letter-spacing: -.02em; margin-top: .1rem; }
.jr-done small { font-size: .64rem; color: var(--ink-soft); }
.jr-photo { height: 90px; border-radius: 14px; background: linear-gradient(135deg, #C98A34, #7a4f18); margin-bottom: .55rem; }
.jr-rate { background: var(--card); border-radius: 13px; padding: .55rem .7rem; box-shadow: var(--shadow-sm); margin-bottom: .55rem; }
.jr-rate__row { display: flex; justify-content: space-between; font-size: .72rem; padding: .12rem 0; }
.jr-rate__row b { color: var(--mustard); letter-spacing: 1px; }
.jr-streak { background: var(--amber-bg); border-radius: 13px; padding: .55rem .7rem; font-size: .72rem; color: var(--mustard-dark); display: flex; align-items: center; gap: .35rem; }
.jr-streak em { margin-left: auto; font-style: normal; font-size: .62rem; opacity: .8; }

/* screen: RECIPES (hero back phone) */
.rc-chips { display: flex; gap: .35rem; margin-bottom: .6rem; }
.rc-chip { font-size: .62rem; font-weight: 600; padding: .3rem .6rem; border-radius: 999px; background: var(--card); color: var(--ink-soft); box-shadow: var(--shadow-sm); }
.rc-chip--on { background: var(--mustard-deep); color: #fff; }
.rc-img { border-radius: 13px; }
.rc-img-1 { height: 92px; background: linear-gradient(135deg, #C98A34, #8a5a1c); }
.rc-img-2 { height: 60px; background: linear-gradient(135deg, #8a6b3a, #5c421f); }
.rc-img-3 { height: 60px; background: linear-gradient(135deg, #d8b25f, #b07e2a); }
.rc-card { background: var(--card); border-radius: 16px; padding: .45rem; box-shadow: var(--shadow-sm); margin-bottom: .55rem; }
.rc-meta { padding: .45rem .3rem .15rem; }
.rc-meta p { font-weight: 700; font-size: .82rem; margin: .3rem 0 .12rem; }
.rc-meta small { font-size: .62rem; color: var(--ink-soft); }
.rc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .45rem; }
.rc-mini { background: var(--card); border-radius: 13px; padding: .35rem; box-shadow: var(--shadow-sm); }
.rc-mini p { font-size: .66rem; font-weight: 600; margin: .3rem .15rem .1rem; }

/* ══════════════ HOW IT WORKS ══════════════ */
.how { padding: 5rem 1.4rem; max-width: var(--maxw); margin: 0 auto; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.step__card { position: relative; background: var(--card-soft); border-radius: var(--radius-lg); padding: 2.4rem 1.6rem 2rem; margin-bottom: 1.5rem; overflow: hidden; }
.step__num { position: absolute; top: 1rem; left: 1.1rem; z-index: 6; width: 34px; height: 34px; border-radius: 10px; background: var(--mustard-deep); color: #fff; font-weight: 800; font-size: .9rem; display: grid; place-items: center; box-shadow: var(--shadow-sm); }
.step h3 { font-size: 1.35rem; margin-bottom: .5rem; }
.step > p { color: var(--ink-soft); font-size: .98rem; }

/* ══════════════ BEYOND (features) ══════════════ */
.beyond { padding: 4.5rem 1.4rem 5rem; max-width: var(--maxw); margin: 0 auto; }
.beyond__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.6rem; }
.feat { padding: .4rem; }
.feat__icon { width: 54px; height: 54px; border-radius: 16px; background: var(--amber-bg); display: grid; place-items: center; font-size: 1.6rem; margin-bottom: 1rem; }
.feat h3 { font-size: 1.16rem; margin-bottom: .45rem; letter-spacing: -.02em; }
.feat p { color: var(--ink-soft); font-size: .95rem; }

/* ══════════════ FAQ ══════════════ */
.faq { padding: 4rem 1.4rem 5rem; max-width: 760px; margin: 0 auto; }
.faq__list { border-top: 1px solid var(--line); }
.qa { border-bottom: 1px solid var(--line); }
.qa summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.25rem .4rem; font-weight: 600; font-size: 1.05rem; color: var(--ink); }
.qa summary::-webkit-details-marker { display: none; }
.qa .chev { color: var(--mustard-deep); font-size: 1.4rem; line-height: 1; transition: transform .3s var(--ease); flex: none; }
.qa[open] .chev { transform: rotate(180deg); }
.qa__body { padding: 0 .4rem 1.3rem; color: var(--ink-soft); font-size: .98rem; max-width: 62ch; }
.qa__body em { color: var(--mustard-dark); font-style: italic; }

/* ══════════════ FOOTER / DOWNLOAD ══════════════ */
.footer { max-width: var(--maxw); margin: 0 auto; padding: 3rem 1.4rem 2rem; }
.footer__cta { text-align: center; padding: 3rem 1rem 3.5rem; border-top: 1px solid var(--line); }
.brand--lg .brand__mark { width: 48px; height: 48px; border-radius: 13px; }
.brand--lg .brand__word { font-size: 2.4rem; }
.footer__tagline { font-family: var(--font-hand); font-size: 1.65rem; color: var(--ink); line-height: 1.15; margin: 1rem 0 1.8rem; }
.footer__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; max-width: 520px; margin: 0 auto; padding: 2.4rem 0; border-top: 1px solid var(--line); }
.footer__cols h4 { font-size: .78rem; text-transform: uppercase; letter-spacing: .07em; color: var(--ink-soft); margin-bottom: .9rem; font-weight: 700; }
.footer__cols a { display: block; font-size: .93rem; margin-bottom: .55rem; color: var(--ink); opacity: .85; transition: color .2s, opacity .2s; }
.footer__cols a:hover { color: var(--mustard-deep); opacity: 1; }
.footer__bar { display: flex; justify-content: space-between; padding-top: 1.6rem; border-top: 1px solid var(--line); font-size: .82rem; color: var(--ink-soft); }

/* ══════════════ LANGUAGE BANNER (Apple-style) ══════════════ */
.lang-banner {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center; gap: 1rem; flex-wrap: wrap;
  background: var(--dark); color: #fff; padding: .6rem 1rem; font-size: .9rem;
  box-shadow: 0 2px 14px rgba(0,0,0,.18);
  transform: translateY(-100%); transition: transform .5s var(--ease);
}
.lang-banner.show { transform: none; }
.lang-banner__msg { opacity: .95; }
.lang-banner__go {
  background: var(--mustard); color: #241a10; border: 0; cursor: pointer;
  font-weight: 700; font-size: .85rem; padding: .4rem .9rem; border-radius: 999px;
  transition: background .2s, transform .2s;
}
.lang-banner__go:hover { background: #E0A23C; transform: translateY(-1px); }
.lang-banner__x {
  background: transparent; border: 0; color: #fff; opacity: .7; cursor: pointer;
  font-size: .9rem; padding: .3rem .4rem; line-height: 1; transition: opacity .2s;
}
.lang-banner__x:hover { opacity: 1; }
html.banner-open .nav { top: 44px; }

/* ══════════════ FOOTER LANGUAGE DROPDOWN ══════════════ */
.lang-switch { display: flex; justify-content: center; padding: 1.6rem 0; border-top: 1px solid var(--line); }
.lang-select {
  position: relative; display: inline-flex; align-items: center;
  background: var(--card); border: 1px solid var(--line); border-radius: 999px;
  padding: 0 2.2rem 0 .9rem; height: 42px;
  transition: border-color .2s, box-shadow .2s;
}
.lang-select:hover { border-color: var(--mustard-deep); }
.lang-select:focus-within { border-color: var(--mustard-deep); box-shadow: 0 0 0 3px rgba(210,146,45,.18); }
.lang-select__globe { color: var(--mustard-deep); flex: none; margin-right: .55rem; }
.lang-select select {
  appearance: none; -webkit-appearance: none; -moz-appearance: none;
  background: transparent; border: 0; outline: none; cursor: pointer;
  font-family: var(--font); font-size: .92rem; font-weight: 600; color: var(--ink);
  padding: .5rem 0; line-height: 1;
}
.lang-select__chev {
  position: absolute; right: .9rem; top: 50%; transform: translateY(-58%);
  color: var(--mustard-deep); font-size: 1.2rem; pointer-events: none;
}

/* ══════════════ RESPONSIVE ══════════════ */
@media (max-width: 900px) {
  .hero__inner { grid-template-columns: 1fr; text-align: center; gap: 2.5rem; }
  .hero__copy { display: flex; flex-direction: column; align-items: center; width: 100%; }
  .hero__copy h1, .hero__sub { width: 100%; max-width: 100%; }
  .hero__devices { min-height: 470px; }
  .steps { grid-template-columns: 1fr; max-width: 380px; margin: 0 auto; gap: 3rem; }
  .beyond__grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .nav__links { display: none; }
}
@media (max-width: 540px) {
  .hero { padding-top: 7rem; }
  .hero h1 { font-size: 2.35rem; letter-spacing: -.03em; }
  .hero__sub { font-size: 1.02rem; }
  .section-head h2 { font-size: 2rem; }
  .beyond__grid { grid-template-columns: 1fr; }
  .footer__cols { grid-template-columns: 1fr 1fr; }
  .footer__bar { flex-direction: column; gap: .4rem; text-align: center; }
}
