@font-face {
  font-family: "DM Sans";
  src: url("./fonts/DMSans_400Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "DM Sans";
  src: url("./fonts/DMSans_500Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "DM Sans";
  src: url("./fonts/DMSans_600SemiBold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "DM Sans";
  src: url("./fonts/DMSans_700Bold.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "JetBrains Mono";
  src: url("./fonts/JetBrainsMono_400Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "JetBrains Mono";
  src: url("./fonts/JetBrainsMono_500Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Playfair Display";
  src: url("./fonts/PlayfairDisplay_400Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Playfair Display";
  src: url("./fonts/PlayfairDisplay_500Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #f8f6f5;
  --surface: #ffffff;
  --surface-alt: #edeae8;
  --border: #d7d3cf;
  --border-subtle: #edeae8;
  --text: #0e0a06;
  --text-muted: #4b4742;
  --text-subtle: #8a8580;
  --text-inverse: #ffffff;
  --brand: #00624b;
  --brand-50: #f2f9f7;
  --brand-100: #d9ede6;
  --brand-400: #3d9a82;
  --brand-600: #004d3a;
  --accent: #c16e2d;
  --accent-50: #fbf5ef;
  --danger: #b83232;
  --danger-bg: #fceaea;
  --shadow: rgba(14, 10, 6, 0.1);
  --glow-brand: rgba(0, 98, 75, 0.18);
  --font-display: "Playfair Display", Georgia, serif;
  --font-body: "DM Sans", Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-2xl: 32px;
  --radius-full: 9999px;
  --content: 1120px;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0a0704;
  --surface: #130e0b;
  --surface-alt: #1a1410;
  --border: #2d2824;
  --border-subtle: #1f1a16;
  --text: #f3f1ef;
  --text-muted: #9c9793;
  --text-subtle: #6b6662;
  --text-inverse: #0e0a06;
  --brand: #5ea990;
  --brand-50: #1a2e28;
  --brand-100: #243d35;
  --brand-400: #4a9a82;
  --brand-600: #7ec4ae;
  --accent: #de8f57;
  --accent-50: #2a2018;
  --danger: #e07070;
  --danger-bg: #2e1a1a;
  --shadow: rgba(0, 0, 0, 0.35);
  --glow-brand: rgba(94, 169, 144, 0.2);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, var(--brand-100), transparent 34rem),
    radial-gradient(circle at bottom right, var(--accent-50), transparent 30rem),
    var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(rgba(14, 10, 6, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(14, 10, 6, 0.025) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.45), transparent 65%);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

.page {
  min-height: 100vh;
}

.shell {
  width: min(100% - 40px, var(--content));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid color-mix(in srgb, var(--border-subtle), transparent 45%);
  background: color-mix(in srgb, var(--bg), transparent 14%);
  backdrop-filter: blur(20px);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 20px;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  box-shadow: 0 8px 20px var(--shadow);
}

.brand-word {
  font-family: var(--font-display);
  font-size: 30px;
  line-height: 1;
  letter-spacing: -0.02em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 18px;
}

.nav a,
.footer a {
  color: var(--text-subtle);
  font-size: 13px;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  background: color-mix(in srgb, var(--surface), transparent 24%);
  color: var(--text);
  cursor: pointer;
  transition: transform 150ms ease, opacity 150ms ease;
}

.theme-toggle:active {
  transform: scale(0.96);
  opacity: 0.76;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  align-items: center;
  gap: clamp(36px, 7vw, 88px);
  padding: clamp(64px, 9vw, 112px) 0;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.headline {
  margin: 0;
  max-width: 740px;
  font-family: var(--font-display);
  font-size: clamp(46px, 8vw, 86px);
  line-height: 0.96;
  letter-spacing: -0.045em;
}

.subhead {
  margin: 24px 0 0;
  max-width: 620px;
  color: var(--text-muted);
  font-size: clamp(17px, 2vw, 21px);
  line-height: 1.65;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  font-weight: 700;
  transition: transform 150ms ease, box-shadow 150ms ease, opacity 150ms ease;
}

.button:active {
  transform: scale(0.97);
}

.button-primary {
  background: var(--brand);
  color: #ffffff;
  box-shadow: 0 16px 40px var(--glow-brand);
}

.button-secondary {
  border-color: var(--border);
  background: color-mix(in srgb, var(--surface), transparent 18%);
  color: var(--text);
}

.store-card {
  width: 100%;
  max-width: 440px;
  padding: 20px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  background: color-mix(in srgb, var(--surface), transparent 6%);
  box-shadow: 0 24px 70px var(--shadow);
}

.store-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.store-badge {
  display: block;
  height: 42px;
  object-fit: contain;
  transition: transform 150ms ease, opacity 150ms ease;
}

.store-badge.play {
  height: 54px;
}

.store-row a:active .store-badge {
  transform: scale(0.98);
  opacity: 0.86;
}

.phone-card {
  position: relative;
  width: min(100%, 390px);
  margin-inline: auto;
  padding: 18px;
  border: 1px solid var(--border-subtle);
  border-radius: 42px;
  background: linear-gradient(145deg, var(--surface), var(--brand-50));
  box-shadow: 0 30px 90px var(--shadow);
}

.phone-card::before {
  content: "";
  position: absolute;
  inset: -16px;
  z-index: -1;
  border-radius: 56px;
  background: radial-gradient(circle, var(--glow-brand), transparent 70%);
}

.phone-screen {
  min-height: 600px;
  padding: 24px;
  border: 1px solid var(--border-subtle);
  border-radius: 32px;
  background: var(--brand-50);
  overflow: hidden;
}

.phone-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}

.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--brand);
  color: #ffffff;
  font-weight: 700;
}

.tiny-label,
.metric-label {
  color: var(--text-muted);
  font-size: 12px;
}

.balance-card {
  padding: 24px;
  border: 1px solid var(--border-subtle);
  border-top: 5px solid var(--brand);
  border-radius: var(--radius-xl);
  background: var(--surface);
  box-shadow: 0 8px 24px var(--shadow);
}

.balance-value {
  margin: 14px 0 18px;
  color: var(--brand);
  font-family: var(--font-mono);
  font-size: 46px;
  letter-spacing: -0.08em;
}

.sparkline {
  height: 72px;
  margin: 18px 0;
  border-bottom: 1px solid var(--border-subtle);
  background:
    linear-gradient(var(--brand), var(--brand)) 0 56% / 100% 1px no-repeat,
    linear-gradient(var(--border-subtle), var(--border-subtle)) 0 100% / 100% 1px no-repeat;
}

.metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.metric-value {
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 20px;
}

.section {
  padding: clamp(54px, 7vw, 84px) 0;
}

.section-heading {
  max-width: 760px;
  margin-bottom: 32px;
}

.section-heading h2,
.legal-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.06;
  letter-spacing: -0.04em;
}

.section-heading p {
  margin: 14px 0 0;
  color: var(--text-muted);
  font-size: 18px;
  line-height: 1.65;
}

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

.feature-card {
  padding: 24px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  background: color-mix(in srgb, var(--surface), transparent 4%);
  box-shadow: 0 8px 28px rgba(14, 10, 6, 0.04);
}

.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  margin-bottom: 18px;
  border-radius: 14px;
  background: var(--brand-100);
  color: var(--brand);
  font-family: var(--font-mono);
  font-weight: 700;
}

.feature-card h3 {
  margin: 0 0 10px;
  font-size: 18px;
}

.feature-card p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.65;
}

.privacy-band {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 28px;
  padding: 28px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  background: var(--surface);
  box-shadow: 0 12px 40px var(--shadow);
}

.privacy-band h2 {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-size: 32px;
}

.privacy-band p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.65;
}

.footer {
  padding: 34px 0 44px;
  color: var(--text-subtle);
  text-align: center;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 12px;
}

.credit {
  margin: 0;
  font-size: 12px;
}

.legal-page {
  width: min(100% - 40px, 720px);
  margin: 0 auto;
  padding: 64px 0 48px;
}

.legal-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 56px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  background: color-mix(in srgb, var(--surface), transparent 16%);
  backdrop-filter: blur(18px);
}

.legal-hero {
  margin-bottom: 32px;
}

.legal-updated {
  margin: 16px 0 0;
  color: var(--text-subtle);
  font-family: var(--font-mono);
  font-size: 14px;
}

.legal-card {
  padding: 24px 24px 8px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  background: var(--surface);
  box-shadow: 0 12px 40px var(--shadow);
}

.legal-intro {
  margin: 0;
  color: var(--text-muted);
  font-size: 18px;
  line-height: 1.65;
}

.divider {
  height: 1px;
  margin: 24px 0 0;
  background: var(--border-subtle);
}

.legal-section {
  padding: 20px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.legal-section:last-child {
  border-bottom: 0;
}

.legal-section h2 {
  display: flex;
  gap: 12px;
  align-items: baseline;
  margin: 0 0 12px;
  font-size: 18px;
}

.legal-index {
  color: var(--brand);
  font-family: var(--font-mono);
  font-size: 14px;
  opacity: 0.85;
}

.legal-section p {
  margin: 0;
  padding-left: 32px;
  color: var(--text-muted);
  line-height: 1.65;
}

@media (max-width: 860px) {
  .hero,
  .privacy-band {
    grid-template-columns: 1fr;
  }

  .phone-card {
    order: -1;
  }

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

  .nav {
    gap: 12px;
  }
}

@media (max-width: 560px) {
  .shell,
  .legal-page {
    width: min(100% - 32px, var(--content));
  }

  .topbar-inner {
    min-height: 64px;
  }

  .brand-word {
    display: none;
  }

  .nav a {
    display: none;
  }

  .hero {
    padding-top: 42px;
  }

  .hero-actions,
  .store-row {
    align-items: stretch;
    flex-direction: column;
  }

  .store-row {
    align-items: center;
  }

  .button {
    width: 100%;
  }

  .phone-screen {
    min-height: 520px;
    padding: 18px;
  }

  .balance-value {
    font-size: 38px;
  }

  .legal-card {
    padding-inline: 20px;
  }

  .legal-section p {
    padding-left: 0;
  }
}


/* Real app screenshots */
.phone-card-shot {
  padding: 0;
  overflow: visible;
  background: none;
}

.phone-card-shot::before {
  display: none;
}

.hero-shot {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 28px;
  box-shadow: 0 24px 60px rgba(15, 40, 33, 0.28);
}

/* Screenshot carousel: swipeable filmstrip with scroll-snap. Pure CSS so it
   works on the static LAMP host with no JS. Shows one card with a peek on
   mobile, several across on wider screens. */
.screen-carousel {
  display: flex;
  gap: 22px;
  margin-top: 36px;
  padding: 6px 4px 22px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.screen-carousel::-webkit-scrollbar {
  display: none;
}

.screen-item {
  margin: 0;
  flex: 0 0 auto;
  width: min(74vw, 280px);
  scroll-snap-align: center;
}

.screen-item img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 22px;
  box-shadow: 0 16px 44px rgba(15, 40, 33, 0.2);
}

.screen-item figcaption {
  margin-top: 12px;
  font-size: 14px;
  color: var(--text-muted, #6b7d76);
  text-align: center;
}

/* Mobile hero: lead with the pitch, keep the screenshot modest and below it.
   Base .phone-card sets order:-1 (image first) which is wrong for the real
   screenshot; override so the DOM order (text then image) wins. */
@media (max-width: 860px) {
  .phone-card-shot {
    order: 0;
    max-width: 240px;
  }
}
