/* ============================================================
   SkinnyScan marketing site — Claude design language
   ============================================================ */

:root {
  --bg: #f4f1e8;
  --bg-soft: #ebe6d9;
  --surface: #fffefb;
  --surface-2: #faf7ef;
  --sunken: #ebe6d9;
  --text: #292723;
  --text-2: #6e6b62;
  --text-3: #a39f93;
  --border: #e6e1d3;
  --border-strong: #d8d2bf;

  --accent: #d97757;
  --accent-press: #c15f3d;
  --accent-tint: #fbeae1;
  --accent-tint-2: #f4d8c9;
  --on-accent: #ffffff;

  --grade-a: #5e8c4f;
  --grade-b: #8aa54e;
  --grade-c: #d2a23f;
  --grade-d: #d27d3e;
  --grade-e: #c5543f;

  --shadow-sm: 0 1px 2px rgba(54, 46, 32, 0.06), 0 1px 3px rgba(54, 46, 32, 0.05);
  --shadow-md: 0 2px 8px rgba(54, 46, 32, 0.07), 0 6px 20px rgba(54, 46, 32, 0.07);
  --shadow-lg: 0 8px 24px rgba(54, 46, 32, 0.12), 0 16px 48px rgba(54, 46, 32, 0.14);

  --radius-sm: 12px;
  --radius: 18px;
  --radius-lg: 26px;
  --radius-xl: 34px;

  --max: 1120px;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1a1916;
    --bg-soft: #0f0e0c;
    --surface: #232220;
    --surface-2: #2a2825;
    --sunken: #2e2c28;
    --text: #ede9df;
    --text-2: #a39f94;
    --text-3: #6f6c63;
    --border: #36342f;
    --border-strong: #45423b;
    --accent: #e08a6a;
    --accent-press: #c97554;
    --accent-tint: #382a22;
    --accent-tint-2: #4a3528;
    --on-accent: #1a1916;
    color-scheme: dark;
  }
}

*,
*::before,
*::after { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI',
    Roboto, system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; }
ul { list-style: none; }
::selection { background: var(--accent-tint-2); color: var(--text); }

/* ---------- Layout ---------- */
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: clamp(72px, 9vw, 120px) 0;
}

/* ---------- Typography ---------- */
.serif {
  font-family: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.eyebrow {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-block;
  margin-bottom: 14px;
}

h1, h2, h3 { font-family: 'Fraunces', 'Iowan Old Style', Georgia, serif; font-weight: 600; letter-spacing: -0.02em; line-height: 1.12; }

h1 { font-size: clamp(40px, 6vw, 68px); }
h2 { font-size: clamp(30px, 4.2vw, 46px); }
h3 { font-size: clamp(20px, 2.4vw, 24px); }

.section-head { max-width: 720px; margin-bottom: 48px; }
.section-head.c { margin-inline: auto; text-align: center; }
.section-sub { font-size: clamp(15px, 1.7vw, 18px); color: var(--text-2); margin-top: 14px; line-height: 1.6; }

.muted { color: var(--text-2); }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 30;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid var(--border);
}

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

.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600; font-size: 19px;
  letter-spacing: -0.01em;
}

.brand-mark {
  width: 32px; height: 32px; border-radius: 10px;
  background: linear-gradient(150deg, var(--accent), var(--accent-press));
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  box-shadow: 0 6px 14px -6px var(--accent);
}

.nav-links {
  display: flex; gap: 22px; margin-inline-start: auto;
  font-size: 15px; font-weight: 500;
}

.nav-links a { color: var(--text-2); transition: color 0.2s; }
.nav-links a:hover { color: var(--text); }

.lang-btn, .nav-cta {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 14px; border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  font-size: 14px; font-weight: 600;
  transition: transform 0.12s, background 0.2s, border-color 0.2s;
}

.lang-btn:hover, .nav-cta:hover { border-color: var(--accent); }

.nav-cta { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.nav-cta:hover { background: var(--accent-press); border-color: var(--accent-press); }

@media (max-width: 800px) {
  .nav-links { display: none; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 16px; font-weight: 600;
  padding: 15px 26px; border-radius: 999px;
  transition: transform 0.12s, background 0.2s, border-color 0.2s;
  border: 1.5px solid transparent;
  user-select: none;
}

.btn-primary { background: var(--accent); color: var(--on-accent); box-shadow: 0 10px 24px -10px var(--accent); }
.btn-primary:hover { background: var(--accent-press); }
.btn-primary:active { transform: scale(0.985); }

.btn-secondary { background: var(--surface); border-color: var(--border-strong); color: var(--text); }
.btn-secondary:hover { border-color: var(--accent); }

.btn-lg { padding: 18px 30px; font-size: 17px; }

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Hero ---------- */
.hero {
  padding: clamp(80px, 11vw, 140px) 0 clamp(60px, 8vw, 96px);
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 60px;
  align-items: center;
}

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; text-align: center; }
  .hero-phone-wrap { order: -1; margin-bottom: 16px; }
}

.hero h1 { white-space: pre-line; }

.hero-sub {
  font-size: clamp(16px, 1.9vw, 19px);
  color: var(--text-2);
  margin-top: 22px;
  max-width: 540px;
  line-height: 1.55;
}

@media (max-width: 900px) {
  .hero-sub { margin-inline: auto; }
}

.hero-actions { margin-top: 32px; }

.hero-trust {
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-3);
  display: flex; align-items: center; gap: 10px;
}

@media (max-width: 900px) {
  .hero-trust { justify-content: center; }
}

.hero-trust::before {
  content: '';
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent);
  flex: none;
}

.hero-phone-wrap {
  display: flex; align-items: center; justify-content: center;
  perspective: 1000px;
}

/* ---------- Phone mockup ---------- */
.phone {
  width: 280px;
  height: 580px;
  border-radius: 44px;
  border: 8px solid #2b2826;
  background: var(--surface);
  box-shadow: 0 30px 80px -30px rgba(40,28,16,0.4);
  overflow: hidden;
  position: relative;
  transform: rotate(-4deg);
}

@media (max-width: 900px) {
  .phone { width: 240px; height: 500px; transform: rotate(0deg); }
}

.phone-screen {
  position: absolute; inset: 0;
  border-radius: 36px;
  background: var(--bg);
  display: flex; flex-direction: column;
  padding: 28px 18px 18px;
  overflow: hidden;
}

.phone-notch {
  position: absolute;
  top: 6px; left: 50%; transform: translateX(-50%);
  width: 100px; height: 22px;
  background: #2b2826; border-radius: 0 0 14px 14px;
  z-index: 2;
}

.phone-eyebrow {
  font-size: 11px; color: var(--text-3); letter-spacing: 0.08em;
  text-transform: uppercase; font-weight: 700;
}

.phone-title {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 22px; font-weight: 600; margin-bottom: 14px;
}

.phone-ring-wrap {
  flex: 1;
  display: flex; align-items: center; justify-content: center;
}

.phone-row {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 10px 12px;
  font-size: 13px;
  margin-top: 8px;
}

.phone-row-emoji {
  width: 30px; height: 30px;
  background: var(--surface-2); border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  font-size: 17px;
  flex: none;
}

.phone-grade {
  width: 24px; height: 24px; border-radius: 7px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 12px;
  flex: none;
}
.phone-grade.a { background: var(--grade-a); }

/* ---------- Stats row ---------- */
.stats {
  padding: clamp(40px, 5vw, 64px) 0;
  background: var(--surface-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.stats-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  align-items: start;
}

@media (max-width: 720px) {
  .stats-grid { grid-template-columns: 1fr; }
}

.stat-card {
  text-align: center;
}

.stat-num {
  font-family: 'Fraunces', Georgia, serif;
  font-size: clamp(40px, 5vw, 60px);
  font-weight: 600;
  color: var(--accent);
  line-height: 1;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.stat-label {
  font-size: 15px;
  color: var(--text-2);
  margin-top: 14px;
  line-height: 1.5;
}

.stat-source {
  font-size: 11.5px;
  color: var(--text-3);
  margin-top: 8px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 700;
}

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

@media (max-width: 980px) { .feat-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .feat-grid { grid-template-columns: 1fr; } }

.feat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 22px;
  box-shadow: var(--shadow-sm);
  display: flex; flex-direction: column; gap: 12px;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.feat:hover { transform: translateY(-3px); border-color: var(--border-strong); box-shadow: var(--shadow-md); }

.feat-icon {
  width: 46px; height: 46px;
  background: linear-gradient(150deg, var(--accent-tint), var(--accent-tint-2));
  color: var(--accent);
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
}

.feat-tag {
  align-self: flex-start;
  display: inline-block;
  padding: 4px 9px;
  background: var(--accent-tint);
  color: var(--accent);
  border-radius: 6px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.feat h3 { font-size: 19px; }
.feat-desc { font-size: 14.5px; color: var(--text-2); line-height: 1.55; }

/* ---------- How it works ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  position: relative;
}

@media (max-width: 800px) { .steps { grid-template-columns: 1fr; } }

.step {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  position: relative;
}

.step-num {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 42px; font-weight: 600;
  color: var(--accent);
  opacity: 0.65;
  letter-spacing: -0.04em;
  line-height: 1;
}

.step h3 { margin-top: 14px; font-size: 21px; }
.step p { color: var(--text-2); margin-top: 8px; font-size: 15px; }

/* ---------- Science / studies ---------- */
.science {
  background: var(--surface-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.studies {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

@media (max-width: 800px) { .studies { grid-template-columns: 1fr; } }

.study {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
  display: flex; flex-direction: column; gap: 10px;
}

.study-tag {
  align-self: flex-start;
  display: inline-block;
  padding: 4px 10px;
  background: var(--accent-tint);
  color: var(--accent);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.study-claim {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.study-meta {
  border-top: 1px solid var(--border);
  padding-top: 12px;
  margin-top: auto;
}

.study-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
}

.study-ref {
  font-size: 12px;
  color: var(--text-2);
  margin-top: 4px;
  line-height: 1.5;
}

.study-doi {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  font-size: 12px;
  color: var(--accent);
  font-weight: 600;
}

.study-doi:hover { text-decoration: underline; }

/* ---------- Languages section ---------- */
.lang-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 9px;
  margin-top: 36px;
}

.lang-pill {
  display: flex; align-items: center; gap: 7px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 500;
}

.lang-pill-flag { font-size: 14px; flex: none; }
.lang-pill-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.lang-callout {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 32px;
  padding: 18px 22px;
  background: var(--accent-tint);
  border: 1px solid var(--accent-tint-2);
  border-radius: var(--radius);
  font-size: 14.5px;
  color: var(--text);
}

.lang-callout-icon {
  flex: none;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--surface);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
}

/* ---------- Privacy section ---------- */
.privacy-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

@media (max-width: 800px) {
  .privacy-grid { grid-template-columns: 1fr; }
}

.privacy-list {
  display: flex; flex-direction: column; gap: 16px;
}

.privacy-list li {
  display: flex; align-items: center; gap: 14px;
  font-size: 16px;
  font-weight: 500;
}

.privacy-list-check {
  width: 28px; height: 28px;
  background: var(--accent-tint);
  color: var(--accent);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex: none;
}

/* ---------- FAQ ---------- */
.faq-list {
  display: flex; flex-direction: column; gap: 8px;
  max-width: 760px;
  margin: 0 auto;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.faq-q {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%;
  padding: 18px 22px;
  font-size: 16px;
  font-weight: 600;
  text-align: start;
  background: none;
  border: none;
  cursor: pointer;
  gap: 12px;
}

.faq-q .chev {
  transition: transform 0.25s ease;
  color: var(--text-3);
  flex: none;
}

.faq-item.open .chev { transform: rotate(180deg); color: var(--accent); }

.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.32s ease;
}

.faq-item.open .faq-a {
  max-height: 360px;
}

.faq-a-inner {
  padding: 0 22px 22px;
  color: var(--text-2);
  font-size: 15px;
  line-height: 1.6;
}

/* ---------- CTA ---------- */
.cta {
  text-align: center;
  background: linear-gradient(180deg, var(--surface-2), var(--bg));
}

.cta h2 { font-size: clamp(34px, 4.6vw, 52px); }

.cta-actions {
  margin-top: 32px;
  display: flex; justify-content: center; gap: 12px; flex-wrap: wrap;
}

/* ---------- Footer ---------- */
footer {
  padding: 60px 0 40px;
  background: var(--surface-2);
  border-top: 1px solid var(--border);
}

.foot-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 36px;
  align-items: start;
}

@media (max-width: 720px) { .foot-grid { grid-template-columns: 1fr; } }

.foot-tagline {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-top: 18px;
  color: var(--text-2);
}

.foot-links {
  display: flex; flex-direction: column; gap: 10px;
  font-size: 14.5px;
}

.foot-links a { color: var(--text-2); }
.foot-links a:hover { color: var(--accent); }

.foot-bottom {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  font-size: 13px;
  color: var(--text-3);
}

.foot-disclaimer {
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--text-3);
  max-width: 680px;
  line-height: 1.6;
}

/* ---------- Language picker overlay ---------- */
.lang-overlay {
  position: fixed; inset: 0;
  background: rgba(28, 24, 16, 0.42);
  z-index: 90;
  display: none;
  align-items: center; justify-content: center;
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
  padding: 24px;
}

.lang-overlay.open { display: flex; }

.lang-sheet {
  width: 100%;
  max-width: 560px;
  max-height: 80vh;
  background: var(--bg);
  border-radius: var(--radius-lg);
  display: flex; flex-direction: column;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  animation: pop 0.28s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes pop { from { opacity: 0; transform: scale(0.94); } to { opacity: 1; transform: scale(1); } }

.lang-sheet-head {
  display: flex; align-items: center; gap: 12px;
  padding: 18px 20px 12px;
}

.lang-sheet-head h3 { font-size: 19px; flex: 1; }

.lang-close {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  color: var(--text);
}

.lang-search {
  margin: 0 20px 8px;
  display: flex; align-items: center; gap: 10px;
  background: var(--sunken);
  border-radius: 14px;
  padding: 11px 14px;
}

.lang-search input {
  flex: 1; border: none; background: none;
  font-size: 15px;
  color: var(--text);
}

.lang-search input:focus { outline: none; }

.lang-list {
  overflow-y: auto;
  padding-bottom: 12px;
}

.lang-row {
  display: flex; align-items: center; gap: 12px;
  width: 100%;
  padding: 12px 20px;
  text-align: start;
  background: none;
  border: none;
  cursor: pointer;
}

.lang-row + .lang-row { border-top: 1px solid var(--border); }
.lang-row:hover { background: var(--surface-2); }

.lang-row-flag { font-size: 20px; flex: none; }
.lang-row-native { font-weight: 600; font-size: 15px; }
.lang-row-en { font-size: 12px; color: var(--text-2); }
.lang-row-check { color: var(--accent); margin-inline-start: auto; }

/* ---------- Animations ---------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.in { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}

/* ---------- Utility ---------- */
.text-c { text-align: center; }
.mt-4 { margin-top: 4px; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-20 { margin-top: 20px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mt-48 { margin-top: 48px; }

.flex { display: flex; align-items: center; }
.gap-10 { gap: 10px; }
.gap-14 { gap: 14px; }
.flex-1 { flex: 1; min-width: 0; }
