:root {
  color-scheme: light;
  --page: #f8f7f3;
  --surface: #fff;
  --surface-2: #efeee9;
  --ink: #11131a;
  --muted: #686a72;
  --line: rgba(17, 19, 26, .11);
  --accent: #117c7e;
  --accent-rgb: 17, 124, 126;
  --accent-2: #1fd4cf;
  --hero-wash: #dff5f2;
  --shadow: rgba(23, 28, 34, .13);
  --nav: rgba(248, 247, 243, .76);
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --page: #0d0f15;
  --surface: #171922;
  --surface-2: #20232d;
  --ink: #f4f1e9;
  --muted: #999ba5;
  --line: rgba(244, 241, 233, .12);
  --accent: #5de2dc;
  --accent-rgb: 93, 226, 220;
  --accent-2: #29c9c3;
  --hero-wash: #122d31;
  --shadow: rgba(0, 0, 0, .42);
  --nav: rgba(13, 15, 21, .76);
}

body[data-app="elo"] {
  --accent: #7662d9;
  --accent-rgb: 118, 98, 217;
  --accent-2: #a6e3a1;
  --hero-wash: #ebe7ff;
}

:root[data-theme="dark"] body[data-app="elo"] {
  --accent: #ab9cf9;
  --accent-rgb: 171, 156, 249;
  --accent-2: #b8f2b4;
  --hero-wash: #25223e;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--page);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  transition: background-color .35s ease, color .35s ease;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(circle at 78% 12%, rgba(var(--accent-rgb), .12), transparent 30rem),
    linear-gradient(var(--page), var(--page));
}

a { color: inherit; }
img { max-width: 100%; }
button { font: inherit; }

.site-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 4.4rem;
  display: flex;
  align-items: center;
  border-bottom: 1px solid transparent;
  background: var(--nav);
  backdrop-filter: blur(18px) saturate(1.3);
  transition: border-color .2s ease;
}

.site-nav.scrolled { border-color: var(--line); }

.nav-inner {
  width: min(74rem, calc(100% - 3rem));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  font-size: 1.18rem;
  font-weight: 800;
  letter-spacing: -.055em;
  text-decoration: none;
}

.nav-right { display: flex; align-items: center; gap: 1.4rem; }
.nav-links { display: flex; align-items: center; gap: 1.4rem; }

.nav-links a {
  color: var(--muted);
  font-size: .78rem;
  font-weight: 650;
  text-decoration: none;
}

.nav-links a:hover { color: var(--ink); }

.nav-app {
  display: flex;
  align-items: center;
  gap: .55rem;
  padding-left: 1.3rem;
  border-left: 1px solid var(--line);
  font-size: .8rem;
  font-weight: 700;
}

.nav-app img { width: 1.65rem; border-radius: 23%; box-shadow: 0 3px 8px var(--shadow); }
.nav-app img { height: 1.65rem; object-fit: cover; }

.theme-toggle {
  width: 2.25rem;
  height: 2.25rem;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
}

.theme-toggle svg {
  position: absolute;
  width: .92rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: opacity .25s ease, transform .3s ease;
}

.theme-toggle .moon { opacity: 0; transform: scale(.5) rotate(-30deg); }
[data-theme="dark"] .theme-toggle .sun { opacity: 0; transform: scale(.5) rotate(30deg); }
[data-theme="dark"] .theme-toggle .moon { opacity: 1; transform: scale(1); }

/* App overview pages */
.profile-hero {
  width: min(74rem, calc(100% - 3rem));
  margin: 0 auto;
  padding: clamp(4.5rem, 8vw, 7rem) 0 clamp(4rem, 7vw, 6rem);
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  align-items: center;
  gap: clamp(3rem, 8vw, 8rem);
  border-bottom: 1px solid var(--line);
}

.profile-copy { max-width: 34rem; }
.app-identity { display: flex; align-items: center; gap: 1.5rem; }
.app-identity .app-mark { width: clamp(4.75rem, 7vw, 6rem); flex: 0 0 auto; }
.app-identity .kicker { margin: 0 0 .45rem; }
.app-identity h1 { margin: 0; font-size: clamp(3.4rem, 6vw, 5.4rem); line-height: .9; letter-spacing: -.07em; }

.profile-summary {
  max-width: 32rem;
  margin: 2.2rem 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.5vw, 1.12rem);
  line-height: 1.65;
}

.app-facts { margin: 2.2rem 0 0; border-top: 1px solid var(--line); }
.app-facts div { padding: .8rem 0; display: grid; grid-template-columns: 6.5rem 1fr; gap: 1rem; border-bottom: 1px solid var(--line); }
.app-facts dt { color: var(--muted); font-size: .72rem; }
.app-facts dd { margin: 0; font-size: .78rem; font-weight: 700; }

.profile-links { margin-top: 1.5rem; display: flex; flex-wrap: wrap; gap: 1.35rem; }
.profile-links a { color: var(--ink); font-size: .78rem; font-weight: 700; text-decoration-color: rgba(var(--accent-rgb), .55); text-underline-offset: 4px; }

.hero-visual.profile-visual { min-height: 35rem; }
.profile-visual .phone { width: 15.5rem; }
.profile-visual .phone-secondary { width: 12.7rem; top: 6rem; }
.profile-visual .preview-note { bottom: 2rem; }

.overview-section {
  width: min(74rem, calc(100% - 3rem));
  margin: 0 auto;
  padding: clamp(4.5rem, 8vw, 6.5rem) 0 clamp(5rem, 9vw, 8rem);
}

.overview-heading { display: grid; grid-template-columns: .7fr 1.3fr; gap: 3rem; margin-bottom: 3rem; }
.overview-heading h2 { margin: 0; font-size: clamp(2rem, 3.5vw, 3rem); line-height: 1.08; letter-spacing: -.045em; }
.overview-heading p:not(.section-label) { max-width: 38rem; margin: 1rem 0 0; color: var(--muted); font-size: .95rem; line-height: 1.65; }

.capability-list { margin-left: calc(35% + 1.05rem); display: grid; grid-template-columns: 1fr 1fr; column-gap: 2.5rem; border-top: 1px solid var(--line); }
.capability-list article { padding: 1.25rem 0 1.35rem; border-bottom: 1px solid var(--line); }
.capability-list h3 { margin: 0 0 .45rem; font-size: .86rem; }
.capability-list p { margin: 0; color: var(--muted); font-size: .8rem; line-height: 1.55; }

.hero {
  position: relative;
  width: min(74rem, calc(100% - 3rem));
  min-height: calc(100vh - 4.4rem);
  margin: 0 auto;
  padding: clamp(4rem, 9vw, 8rem) 0 clamp(5rem, 10vw, 8rem);
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  align-items: center;
  gap: clamp(3rem, 8vw, 8rem);
}

.hero-copy { max-width: 34rem; }

.app-mark {
  width: clamp(5.2rem, 8vw, 6.6rem);
  height: auto;
  display: block;
  border-radius: 24%;
  box-shadow: 0 20px 42px var(--shadow), 0 1px 0 rgba(255,255,255,.6) inset;
}

.kicker {
  margin: 2.25rem 0 .85rem;
  color: var(--accent);
  font-size: .71rem;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 12ch;
  margin: 0;
  font-size: clamp(3.5rem, 7vw, 6.8rem);
  font-weight: 760;
  line-height: .93;
  letter-spacing: -.075em;
}

.hero-lede {
  max-width: 31rem;
  margin: 1.65rem 0 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.7vw, 1.27rem);
  line-height: 1.6;
}

.hero-actions { margin-top: 2rem; display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }

.button {
  min-height: 3rem;
  padding: 0 1.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .7rem;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--page);
  font-size: .82rem;
  font-weight: 750;
  text-decoration: none;
  transition: transform .2s ease, box-shadow .2s ease;
}

.button:hover { transform: translateY(-2px); box-shadow: 0 10px 24px var(--shadow); }
.button-secondary { border-color: var(--line); background: transparent; color: var(--ink); }

.coming-note { color: var(--muted); font-size: .73rem; }

.hero-visual {
  position: relative;
  min-height: 42rem;
  display: grid;
  place-items: center;
}

.hero-visual::before {
  content: "";
  position: absolute;
  width: min(42rem, 100%);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--hero-wash);
  filter: blur(.2px);
}

.preview-note {
  position: absolute;
  right: 0;
  bottom: 3.5rem;
  z-index: 4;
  padding: .55rem .78rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--nav);
  backdrop-filter: blur(12px);
  color: var(--muted);
  font-size: .64rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.phone {
  position: absolute;
  z-index: 2;
  width: 17.2rem;
  aspect-ratio: 9 / 19.35;
  padding: .48rem;
  border: 1px solid rgba(255,255,255,.38);
  border-radius: 3.2rem;
  background: #090a0d;
  box-shadow: 0 35px 75px rgba(8, 13, 21, .26), 0 0 0 1px rgba(0,0,0,.18);
  overflow: hidden;
}

.phone::before {
  content: "";
  position: absolute;
  top: .78rem;
  left: 50%;
  z-index: 7;
  width: 5.2rem;
  height: 1.45rem;
  border-radius: 999px;
  background: #050608;
  transform: translateX(-50%);
}

.phone-primary { right: 9%; transform: rotate(4deg); }
.phone-secondary { left: 0; top: 7rem; z-index: 1; width: 14.2rem; transform: rotate(-8deg); opacity: .94; }

.phone-screen {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 2.75rem;
  overflow: hidden;
  background: #f7f7f9;
}

.ios-status {
  height: 2.7rem;
  padding: .75rem 1.05rem 0;
  display: flex;
  justify-content: space-between;
  color: #101218;
  font-size: .56rem;
  font-weight: 750;
}

.signal { letter-spacing: .1em; }
.appbar { padding: .15rem .85rem .7rem; text-align: center; border-bottom: 1px solid #e4e5e8; }
.appbar strong { display: block; font-size: .78rem; }
.appbar span { color: #777b83; font-size: .52rem; }

.chat-thread { padding: .85rem .6rem 3.7rem; display: flex; flex-direction: column; gap: .45rem; }
.chat-day { margin-bottom: .15rem; color: #9699a0; font-size: .48rem; font-weight: 650; text-align: center; }
.bubble { max-width: 78%; padding: .5rem .65rem; border-radius: 1rem; font-size: .61rem; line-height: 1.35; }
.bubble.in { align-self: flex-start; background: #e9eaed; color: #1b1c21; border-bottom-left-radius: .28rem; }
.bubble.out { align-self: flex-end; background: #25c9c5; color: #071e20; border-bottom-right-radius: .28rem; }
.bubble-photo { height: 5.2rem; display: grid; place-items: center; background: linear-gradient(145deg, #b8e7f1, #d6c7f7 55%, #ffd4b5); color: rgba(20,20,30,.65); font-size: .5rem; }
.typing { align-self: flex-start; padding: .46rem .65rem; border-radius: 1rem; background: #e9eaed; color: #8d9096; font-size: .8rem; letter-spacing: .11em; }
.composer { position: absolute; left: .6rem; right: .6rem; bottom: .7rem; height: 2.2rem; padding: 0 .4rem 0 .75rem; display: flex; align-items: center; justify-content: space-between; border: 1px solid #d9dadd; border-radius: 999px; background: rgba(255,255,255,.86); color: #9a9ca3; font-size: .56rem; }
.send-dot { width: 1.45rem; aspect-ratio: 1; display: grid; place-items: center; border-radius: 50%; background: #20c9c4; color: white; font-size: .75rem; }

.login-screen { background: #f8f8fa url("jabba-login.webp") center / cover; }
.login-panel { position: absolute; left: 1rem; right: 1rem; bottom: 2.2rem; padding: 1rem; border-radius: 1.15rem; background: rgba(255,255,255,.72); backdrop-filter: blur(14px); color: #0c1930; text-align: center; }
.login-panel strong { display: block; font-size: 1.1rem; }
.login-panel span { display: block; margin: .4rem 0 .8rem; color: #5d6470; font-size: .51rem; line-height: 1.4; }
.login-field { height: 1.7rem; margin-top: .35rem; padding: .45rem .55rem; border-radius: .5rem; background: rgba(255,255,255,.9); color: #90949c; font-size: .48rem; text-align: left; }
.login-button { margin-top: .55rem; padding: .5rem; border-radius: .55rem; background: #0d1e3c; color: #fff; font-size: .5rem; font-weight: 700; }

.elo-screen { background: #1e1e2e; color: #cdd6f4; font-family: "SFMono-Regular", Consolas, monospace; }
.elo-screen .ios-status { color: #cdd6f4; background: #181825; }
.elo-toolbar { height: 2rem; padding: .4rem .7rem; display: flex; justify-content: space-between; border-bottom: 1px solid #313244; background: #181825; color: #6c7086; font-size: .47rem; }
.elo-toolbar strong { color: #a6adc8; font-size: .55rem; }
.elo-doc { padding: 1.1rem .85rem; display: grid; grid-template-columns: 1fr auto; gap: .72rem .5rem; font-size: .58rem; line-height: 1.35; }
.elo-doc .head { color: #89b4fa; font-weight: 800; }
.elo-doc .comment { color: #585b70; font-style: italic; }
.elo-doc .label { color: #f9e2af; }
.elo-doc output { color: #a6e3a1; text-align: right; }
.elo-doc output.date { color: #cba6f7; }
.elo-caret { display: inline-block; width: 1px; height: .68rem; margin-left: .1rem; background: #cdd6f4; vertical-align: middle; animation: blink 1.1s steps(1) infinite; }
.elo-status { position: absolute; left: 0; right: 0; bottom: 0; padding: .4rem .7rem .75rem; display: flex; justify-content: space-between; border-top: 1px solid #313244; background: #181825; color: #6c7086; font-size: .42rem; }

.elo-secondary .phone-screen { background: #242437; }
.example-card { position: absolute; left: .8rem; right: .8rem; padding: .8rem; border: 1px solid #38384c; border-radius: .8rem; background: #1e1e2e; color: #cdd6f4; font-family: "SFMono-Regular", monospace; font-size: .53rem; box-shadow: 0 9px 20px rgba(0,0,0,.18); }
.example-card:nth-child(2) { top: 5.5rem; transform: rotate(2deg); }
.example-card:nth-child(3) { top: 10.2rem; transform: rotate(-2deg); }
.example-card:nth-child(4) { top: 15rem; transform: rotate(1deg); }
.example-card output { display: block; margin-top: .35rem; color: #a6e3a1; font-size: .7rem; }

@keyframes blink { 50% { opacity: 0; } }

.section {
  width: min(74rem, calc(100% - 3rem));
  margin: 0 auto;
  padding: clamp(5rem, 10vw, 8rem) 0;
  border-top: 1px solid var(--line);
}

.section-heading { display: grid; grid-template-columns: .7fr 1.3fr; gap: 3rem; margin-bottom: 3.5rem; }
.section-label { margin: .25rem 0 0; color: var(--accent); font-size: .68rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.section-heading h2 { max-width: 14ch; margin: 0; font-size: clamp(2.3rem, 4.5vw, 4.2rem); line-height: 1.02; letter-spacing: -.055em; }
.section-heading p { max-width: 38rem; margin: 1.4rem 0 0; color: var(--muted); font-size: 1.05rem; line-height: 1.65; }

.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.feature-card { min-height: 16rem; padding: 1.6rem; display: flex; flex-direction: column; justify-content: space-between; border: 1px solid var(--line); border-radius: 1.5rem; background: var(--surface); }
.feature-icon { width: 2.65rem; height: 2.65rem; display: grid; place-items: center; border-radius: .85rem; background: rgba(var(--accent-rgb), .11); color: var(--accent); font-size: 1.05rem; font-weight: 800; }
.feature-card h3 { margin: 2rem 0 .55rem; font-size: 1rem; }
.feature-card p { margin: 0; color: var(--muted); font-size: .86rem; line-height: 1.55; }

.quote-band { position: relative; width: min(74rem, calc(100% - 3rem)); margin: 1rem auto 7rem; padding: clamp(3rem, 7vw, 5.5rem); border-radius: 2rem; overflow: hidden; background: var(--ink); color: var(--page); }
.quote-band::after { content: ""; position: absolute; width: 30rem; aspect-ratio: 1; right: -12rem; top: -13rem; border-radius: 50%; background: rgba(var(--accent-rgb), .4); filter: blur(2px); }
.quote-band blockquote { position: relative; z-index: 1; max-width: 18ch; margin: 0; font-family: ui-serif, Georgia, serif; font-size: clamp(2rem, 5vw, 4.4rem); font-style: italic; line-height: 1.07; letter-spacing: -.035em; }
.quote-band p { position: relative; z-index: 1; margin: 1.5rem 0 0; opacity: .6; font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; }

.cta { padding: 2rem 0 8rem; text-align: center; }
.cta img { width: 5.4rem; border-radius: 24%; box-shadow: 0 15px 32px var(--shadow); }
.cta img { height: auto; }
.cta h2 { margin: 1.5rem 0 .7rem; font-size: clamp(2.3rem, 5vw, 4.5rem); letter-spacing: -.06em; }
.cta p { margin: 0 auto 1.8rem; color: var(--muted); }

.site-footer { border-top: 1px solid var(--line); }
.footer-inner { width: min(74rem, calc(100% - 3rem)); min-height: 7rem; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: .72rem; }
.footer-links { display: flex; gap: 1.2rem; }
.footer-links a { text-underline-offset: 3px; text-decoration-color: var(--line); }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.8,.2,1); }
.reveal.visible { opacity: 1; transform: none; }

/* Legal and support pages */
.legal-shell { width: min(48rem, calc(100% - 3rem)); min-height: calc(100vh - 11.4rem); margin: 0 auto; padding: clamp(5rem, 10vw, 8rem) 0; }
.legal-header { padding-bottom: 3rem; border-bottom: 1px solid var(--line); }
.legal-header img { width: 4rem; border-radius: 23%; box-shadow: 0 10px 22px var(--shadow); }
.legal-header img { height: auto; }
.legal-header .kicker { margin-top: 1.4rem; }
.legal-header h1 { margin: 0; font-size: clamp(2.9rem, 7vw, 5.1rem); line-height: .95; letter-spacing: -.065em; }
.legal-header p { max-width: 37rem; margin: 1.3rem 0 0; color: var(--muted); font-size: 1rem; line-height: 1.65; }
.legal-content { padding-top: 2rem; }
.legal-content h2 { margin: 2.6rem 0 .7rem; font-size: 1.18rem; letter-spacing: -.02em; }
.legal-content h3 { margin: 1.7rem 0 .5rem; font-size: .93rem; }
.legal-content p, .legal-content li { color: var(--muted); font-size: .92rem; line-height: 1.72; }
.legal-content ul { padding-left: 1.25rem; }
.legal-content a { color: var(--ink); text-decoration-color: rgba(var(--accent-rgb), .55); text-underline-offset: 3px; }
.legal-callout { margin: 2rem 0; padding: 1.25rem 1.35rem; border-left: 3px solid var(--accent); border-radius: 0 .8rem .8rem 0; background: rgba(var(--accent-rgb), .08); }
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { padding: 1.25rem 2rem 1.25rem 0; font-size: .94rem; font-weight: 700; cursor: pointer; }
.faq details p { margin: -.4rem 0 1.3rem; }
.support-card { margin-top: 2.5rem; padding: 1.7rem; border: 1px solid var(--line); border-radius: 1.25rem; background: var(--surface); }
.support-card h2 { margin-top: 0; }

@media (max-width: 900px) {
  .profile-hero { grid-template-columns: 1fr; }
  .profile-copy { margin: 0 auto; }
  .hero-visual.profile-visual { min-height: 34rem; max-width: 36rem; width: 100%; margin: 0 auto; }
  .overview-heading { grid-template-columns: 1fr; gap: 1rem; }
  .capability-list { margin-left: 0; }
  .hero { grid-template-columns: 1fr; padding-top: 5rem; }
  .hero-copy { text-align: center; margin: 0 auto; }
  .hero .app-mark { margin-inline: auto; }
  .hero h1, .hero-lede { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-visual { min-height: 39rem; max-width: 36rem; width: 100%; margin: 0 auto; }
  .section-heading { grid-template-columns: 1fr; gap: 1rem; }
  .feature-grid { grid-template-columns: 1fr 1fr; }
  .feature-card:last-child { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  .nav-inner, .profile-hero, .overview-section, .hero, .section, .quote-band, .footer-inner { width: min(100% - 2rem, 74rem); }
  .nav-links { display: none; }
  .nav-app { padding-left: 0; border-left: 0; }
  .profile-hero { padding-top: 3.5rem; gap: 1.5rem; }
  .app-identity { gap: 1.1rem; }
  .profile-summary { margin-top: 1.7rem; }
  .hero-visual.profile-visual { min-height: 32rem; transform: scale(.9); transform-origin: top center; margin-bottom: -3rem; }
  .capability-list { grid-template-columns: 1fr; }
  .hero { gap: 1.5rem; }
  .hero-visual { min-height: 35rem; transform: scale(.9); transform-origin: top center; margin-bottom: -3rem; }
  .phone-primary { right: 3%; }
  .phone-secondary { left: -4%; }
  .preview-note { right: -2%; }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-card:last-child { grid-column: auto; }
  .feature-card { min-height: 13rem; }
  .quote-band { margin-bottom: 5rem; border-radius: 1.4rem; }
  .footer-inner { padding: 1.5rem 0; gap: 1rem; align-items: flex-start; flex-direction: column; }
  .legal-shell { width: min(100% - 2rem, 48rem); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
