/* ─── ROOT ─── */
:root {
  --bg: #F7F7F5;
  --bg-soft: #FBFBF9;
  --ink: #0A0A0A;
  --ink-soft: #4A4A47;
  --ink-faint: #8A8A85;
  --rule: #E6E6E1;
  --pill-bg: #0A0A0A;
  --pill-ink: #FAFAF8;
  --accent: #2A2A28;
}

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

html, body {
  background: var(--bg);
  color: var(--ink);
  font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

/* Subtle grain overlay for warmth */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.025;
  z-index: 1;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

a { color: inherit; }

/* ─── NAV ─── */
nav {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 40px;
  animation: fade-down 1.1s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.logo {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
}

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

.nav-link {
  font-size: 14px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 400;
  letter-spacing: 0.01em;
  transition: opacity 0.3s ease;
  position: relative;
}

.nav-link:hover { opacity: 0.55; }

.nav-link.active::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 1px;
  background: var(--ink);
}

.pill {
  display: inline-flex;
  align-items: center;
  background: var(--pill-bg);
  color: var(--pill-ink);
  padding: 11px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 400;
  text-decoration: none;
  letter-spacing: 0.01em;
  box-shadow: 0 1px 2px rgba(0,0,0,0.06), 0 8px 24px -8px rgba(0,0,0,0.18);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

.pill:hover {
  transform: translateY(-1px);
  box-shadow: 0 1px 2px rgba(0,0,0,0.08), 0 14px 32px -10px rgba(0,0,0,0.25);
}

.pill-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--ink);
  box-shadow: none;
}

.pill-ghost:hover {
  background: var(--ink);
  color: var(--pill-ink);
}

/* ─── LAYOUT ─── */
main {
  flex: 1;
  position: relative;
  z-index: 2;
  width: 100%;
}

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 40px;
}

.container-narrow {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 40px;
}

/* ─── TYPOGRAPHY ─── */
h1, h2, h3 {
  font-family: 'Fraunces', serif;
  font-weight: 300;
  letter-spacing: -0.02em;
  color: var(--ink);
}

h1 {
  font-size: clamp(40px, 6vw, 78px);
  line-height: 1.04;
  letter-spacing: -0.025em;
}

h1 em, h2 em, h3 em {
  font-style: italic;
  font-weight: 300;
}

h2 {
  font-size: clamp(32px, 4.2vw, 52px);
  line-height: 1.1;
  margin-bottom: 24px;
}

h3 {
  font-size: clamp(20px, 2vw, 24px);
  line-height: 1.25;
  margin-bottom: 12px;
}

p {
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink-soft);
}

.lede {
  font-size: clamp(16px, 1.4vw, 18px);
  line-height: 1.6;
  color: var(--ink-soft);
}

.eyebrow {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 28px;
}

.eyebrow::before,
.eyebrow::after {
  content: '';
  display: inline-block;
  width: 20px;
  height: 1px;
  background: var(--ink-faint);
  vertical-align: middle;
  margin: 0 12px;
}

.eyebrow.left {
  text-align: left;
}

.eyebrow.left::before { display: none; }
.eyebrow.left::after { display: none; }

/* ─── HERO ─── */
.hero {
  text-align: center;
  padding: 60px 0 100px;
}

.hero p.sub {
  font-size: clamp(15px, 1.3vw, 17px);
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 520px;
  margin: 28px auto 0;
}

.hero-page {
  padding: 80px 0 60px;
  text-align: center;
}

.hero-page h1 {
  margin-bottom: 24px;
}

.hero-page .lede {
  max-width: 580px;
  margin: 0 auto;
}

/* ─── SECTIONS ─── */
section.block {
  padding: 80px 0;
  position: relative;
}

section.block-alt {
  background: var(--bg-soft);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.section-head {
  text-align: center;
  margin-bottom: 64px;
}

.section-head .eyebrow { margin-bottom: 20px; }

/* ─── FEATURE GRID ─── */
.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px 40px;
}

.feature {
  text-align: left;
}

.feature-icon {
  width: 36px;
  height: 36px;
  margin-bottom: 20px;
  color: var(--ink);
}

.feature h3 {
  font-size: 19px;
  margin-bottom: 10px;
}

.feature p {
  font-size: 15px;
  line-height: 1.6;
}

/* ─── CATEGORY CHIPS ─── */
.categories {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 12px;
  max-width: 680px;
  margin: 40px auto 0;
}

.chip {
  display: inline-flex;
  align-items: center;
  padding: 8px 18px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  font-size: 13px;
  color: var(--ink-soft);
  background: var(--bg-soft);
  letter-spacing: 0.01em;
}

/* ─── PHONE MOCKUPS ─── */
.mockups {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 32px;
  margin-top: 56px;
  perspective: 1400px;
}

.phone {
  width: 248px;
  height: 528px;
  background: #0A0A0A;
  border-radius: 42px;
  padding: 7px;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.05),
    0 30px 70px -25px rgba(0,0,0,0.5),
    0 12px 30px -10px rgba(0,0,0,0.25);
  position: relative;
  flex-shrink: 0;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.phone-center {
  transform: translateY(-32px);
  z-index: 3;
}

.phone-side {
  transform: scale(0.94);
  opacity: 0.96;
  z-index: 1;
}

.phone-left { transform: scale(0.94) rotate(-2deg); transform-origin: bottom right; }
.phone-right { transform: scale(0.94) rotate(2deg); transform-origin: bottom left; }

.phone-screen-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 34px;
  overflow: hidden;
  background: #000;
}

.phone-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  display: block;
}

/* ─── APP SHOWCASE (dark section) ─── */
.showcase {
  background: linear-gradient(180deg, #0E0D0B 0%, #1A1815 100%);
  color: #FAFAF8;
  padding: 120px 0;
  border-top: 1px solid var(--rule);
  position: relative;
  overflow: hidden;
}

.showcase::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 800px 400px at 30% 0%, rgba(184, 104, 48, 0.18), transparent 60%),
    radial-gradient(ellipse 600px 300px at 80% 100%, rgba(184, 104, 48, 0.12), transparent 60%);
  pointer-events: none;
}

.showcase > .container { position: relative; z-index: 2; }

.showcase h2 {
  color: #FAFAF8;
}

.showcase .eyebrow {
  color: #B86830;
}

.showcase .eyebrow::before,
.showcase .eyebrow::after {
  background: rgba(184, 104, 48, 0.4);
}

.showcase .lede {
  color: rgba(250, 250, 248, 0.65);
}

/* Screenshot showcase rows */
.showcase-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 80px;
  max-width: 980px;
  margin: 0 auto;
  padding: 60px 0;
}

.showcase-row.reverse { direction: rtl; }
.showcase-row.reverse > * { direction: ltr; }

.showcase-text { max-width: 420px; }

.showcase-text .eyebrow {
  text-align: left;
  margin-bottom: 16px;
}

.showcase-text .eyebrow::before { display: none; }
.showcase-text .eyebrow::after { display: none; }

.showcase-text h3 {
  font-family: 'Fraunces', serif;
  font-weight: 300;
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #FAFAF8;
  margin-bottom: 18px;
}

.showcase-text h3 em { font-style: italic; }

.showcase-text p {
  font-size: 16px;
  line-height: 1.7;
  color: rgba(250, 250, 248, 0.65);
}

.showcase-phone {
  display: flex;
  justify-content: center;
}

/* ─── ABOUT / CONTENT SECTIONS ─── */
.prose {
  max-width: 680px;
  margin: 0 auto;
}

.prose p {
  font-size: 16px;
  line-height: 1.75;
  margin-bottom: 20px;
  color: var(--ink-soft);
}

.prose p:first-of-type {
  font-size: 18px;
  color: var(--ink);
}

.prose h2 {
  font-size: clamp(26px, 3vw, 34px);
  margin-top: 56px;
  margin-bottom: 16px;
}

.prose h3 {
  font-size: 18px;
  margin-top: 36px;
  margin-bottom: 10px;
  color: var(--ink);
}

.prose ul {
  list-style: none;
  margin: 0 0 24px;
  padding: 0;
}

.prose ul li {
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink-soft);
  padding-left: 22px;
  position: relative;
  margin-bottom: 6px;
}

.prose ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 12px;
  width: 10px;
  height: 1px;
  background: var(--ink-faint);
}

.prose a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--ink-faint);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.3s ease;
}

.prose a:hover {
  text-decoration-color: var(--ink);
}

.prose strong {
  color: var(--ink);
  font-weight: 500;
}

/* ─── CTA BAND ─── */
.cta-band {
  text-align: center;
  padding: 100px 0;
  border-top: 1px solid var(--rule);
}

.cta-band h2 {
  margin-bottom: 28px;
}

/* ─── DIVIDER ─── */
.divider {
  height: 1px;
  background: var(--rule);
  margin: 0 40px;
  position: relative;
  z-index: 2;
}

/* ─── FOOTER ─── */
footer {
  position: relative;
  z-index: 2;
  padding: 40px 40px 36px;
  font-size: 12px;
  color: var(--ink-soft);
  letter-spacing: 0.02em;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: end;
  max-width: 1080px;
  margin: 0 auto;
}

.footer-left { display: flex; flex-direction: column; gap: 10px; }
.footer-right { display: flex; flex-direction: column; gap: 10px; align-items: flex-end; text-align: right; }

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px 22px;
}

.footer-links a {
  color: var(--ink-soft);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

.footer-meta {
  color: var(--ink-faint);
  font-size: 11px;
  letter-spacing: 0.04em;
}

.footer-socials {
  display: flex;
  gap: 14px;
  margin-bottom: 4px;
}

.footer-socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--rule);
  border-radius: 50%;
  color: var(--ink-soft);
  text-decoration: none;
  transition: all 0.3s ease;
}

.footer-socials a:hover {
  background: var(--ink);
  color: var(--pill-ink);
  border-color: var(--ink);
}

.footer-socials svg {
  width: 14px;
  height: 14px;
}

/* ─── ANIMATIONS ─── */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fade-down {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-in {
  animation: fade-up 1s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.fade-in.d1 { animation-delay: 0.15s; }
.fade-in.d2 { animation-delay: 0.3s; }
.fade-in.d3 { animation-delay: 0.45s; }

/* ─── MOBILE ─── */
@media (max-width: 820px) {
  .features { grid-template-columns: 1fr 1fr; gap: 36px 32px; }
  .mockups { gap: 14px; }
  .phone { width: 210px; height: 444px; }
  .showcase-row { grid-template-columns: 1fr; gap: 40px; padding: 40px 0; }
  .showcase-row.reverse { direction: ltr; }
  .showcase-row.reverse .showcase-phone { order: -1; }
}

@media (max-width: 640px) {
  nav { padding: 22px 24px; }
  .nav-right { gap: 14px; }
  .nav-link { display: none; }
  .nav-right .pill { display: inline-flex; }
  .container, .container-narrow { padding: 0 24px; }
  .hero { padding: 40px 0 64px; }
  .hero-page { padding: 48px 0 32px; }
  section.block { padding: 56px 0; }
  .section-head { margin-bottom: 44px; }
  .features { grid-template-columns: 1fr; gap: 32px; }
  .mockups { flex-direction: column; align-items: center; gap: 24px; perspective: none; }
  .phone-center, .phone-side, .phone-left, .phone-right { transform: none; opacity: 1; }
  .phone { width: 240px; height: 510px; }
  .divider { margin: 0 24px; }
  footer { padding: 32px 24px; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; align-items: flex-start; }
  .footer-right { align-items: flex-start; text-align: left; }
  .cta-band { padding: 72px 0; }
  .prose h2 { margin-top: 40px; }
  .showcase { padding: 72px 0; }
  .showcase-row { padding: 32px 0; gap: 32px; }
  .showcase-text { max-width: 100%; }
}

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  margin-right: -8px;
}

.menu-toggle svg { width: 22px; height: 22px; }

@media (max-width: 640px) {
  .menu-toggle { display: inline-flex; }
  .nav-right.open .nav-link {
    display: block;
  }
  .nav-right.open {
    position: absolute;
    top: 70px;
    right: 24px;
    background: var(--bg-soft);
    border: 1px solid var(--rule);
    border-radius: 16px;
    padding: 20px 24px;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    box-shadow: 0 16px 40px -16px rgba(0,0,0,0.15);
  }
}
