/* ───────────────────────────────────────────────
   Narrata — Light Sumi-e Landing
   Rice paper + dark ink + blood red accent.
   ─────────────────────────────────────────────── */

:root {
  --paper: #faf8f3;
  --paper-warm: #f3efe6;
  --paper-deep: #ebe5d9;
  --ink: #1a1a18;
  --ink-soft: #4a4640;
  --ink-dim: #8a847a;
  --blood: #bb2f27;
  --blood-soft: rgba(187, 47, 39, 0.55);
  --blood-glow: rgba(187, 47, 39, 0.12);
  --border: rgba(26, 26, 24, 0.08);
  --wrap: min(1100px, 90vw);
  --radius: 6px;
}

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

html,
body {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.55;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ── Grain overlay ─────────────────────────── */

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 256px 256px;
  opacity: 0.04;
  mix-blend-mode: multiply;
}

/* ── Ambient ink washes ────────────────────── */

.ink-wash {
  position: fixed;
  pointer-events: none;
  border-radius: 50%;
  filter: blur(120px);
  z-index: 0;
}

.wash-1 {
  width: 600px;
  height: 600px;
  top: -200px;
  left: -100px;
  background: radial-gradient(circle, rgba(187, 47, 39, 0.04) 0%, transparent 70%);
}

.wash-2 {
  width: 500px;
  height: 500px;
  bottom: -150px;
  right: -100px;
  background: radial-gradient(circle, rgba(26, 26, 24, 0.03) 0%, transparent 70%);
}

/* ── Typography ────────────────────────────── */

h1,
h2,
h3 {
  font-family: "Unbounded", sans-serif;
  margin: 0;
  line-height: 1.08;
}

h1 {
  font-size: clamp(2.8rem, 6.5vw, 5.2rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--ink);
}

h2 {
  font-size: clamp(1.8rem, 4vw, 3rem);
}

h3 {
  font-size: clamp(1.3rem, 2.5vw, 1.8rem);
  font-weight: 700;
}

/* ── Navigation ────────────────────────────── */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem clamp(1rem, 5vw, 3rem);
  background: linear-gradient(to bottom, rgba(250, 248, 243, 0.95) 0%, transparent 100%);
  backdrop-filter: blur(8px);
}

.brand {
  font-family: "Unbounded", sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--ink);
  text-decoration: none;
}

.nav-cta {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--blood);
  text-decoration: none;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: opacity 0.2s;
}

.nav-cta:hover {
  opacity: 0.75;
}

/* ── Hero ──────────────────────────────────── */

.hero {
  position: relative;
  width: var(--wrap);
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  padding: 6rem 0 4rem;
}

.hero-text {
  z-index: 2;
}

.hero-sub {
  margin: 1.5rem 0 0;
  font-size: clamp(1rem, 1.5vw, 1.12rem);
  color: var(--ink-soft);
  max-width: 36ch;
  line-height: 1.65;
}

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

/* ── Hero stats ────────────────────────────── */

.hero-stats {
  margin-top: 3rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.stat {
  text-align: center;
}

.stat-value {
  display: block;
  font-family: "Unbounded", sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1;
}

.stat-label {
  font-size: 0.72rem;
  color: var(--ink-dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 0.25rem;
  display: block;
}

.stat-divider {
  width: 1px;
  height: 28px;
  background: var(--border);
}

/* ── Buttons ───────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  padding: 0.85rem 1.7rem;
  background: var(--blood);
  color: var(--paper);
  font-family: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 4px 20px var(--blood-glow);
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 28px rgba(187, 47, 39, 0.2);
}

.btn-ghost {
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  border-bottom: 1px solid rgba(26, 26, 24, 0.2);
  padding-bottom: 2px;
  transition: color 0.2s, border-color 0.2s;
}

.btn-ghost:hover {
  color: var(--ink-soft);
  border-color: var(--ink-soft);
}

/* ── Hero panels ───────────────────────────── */

.hero-panels {
  position: relative;
  height: min(62vw, 540px);
  min-height: 340px;
}

.panel {
  position: absolute;
  border: 1px solid rgba(26, 26, 24, 0.08);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--paper-warm);
  box-shadow:
    0 12px 50px rgba(26, 26, 24, 0.12),
    0 2px 8px rgba(26, 26, 24, 0.06);
}

.panel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: contrast(1.05) brightness(1.02);
}

.panel-a {
  width: 60%;
  aspect-ratio: 3 / 4;
  top: 8%;
  left: 18%;
  z-index: 3;
  transform: rotate(-1.5deg);
  animation: gentle-float 7s ease-in-out infinite;
}

.panel-b {
  width: 38%;
  aspect-ratio: 9 / 16;
  top: 0;
  left: 0;
  z-index: 2;
  transform: rotate(-6deg);
  animation: gentle-float 8.5s ease-in-out infinite;
  animation-delay: -2s;
}

.panel-c {
  width: 36%;
  aspect-ratio: 9 / 16;
  bottom: 0;
  right: 2%;
  z-index: 1;
  transform: rotate(4deg);
  animation: gentle-float 6.5s ease-in-out infinite;
  animation-delay: -4s;
}

@keyframes gentle-float {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 0 -7px;
  }
}

/* ── Section divider ───────────────────────── */

.section-line {
  width: 60px;
  height: 2px;
  margin: 0 auto 4rem;
  background: linear-gradient(90deg, transparent, var(--blood-soft), transparent);
  border-radius: 1px;
}

/* ── Ritual section ────────────────────────── */

.ritual {
  width: var(--wrap);
  margin: 0 auto;
  padding: 4rem 0 2rem;
}

.ritual-title {
  font-size: clamp(0.85rem, 1.5vw, 1rem);
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-dim);
  text-align: center;
  margin-bottom: 5rem;
}

.ritual-step {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  margin-bottom: clamp(4rem, 8vw, 7rem);
}

.step-reverse .panel-frame {
  order: 2;
}

.step-reverse .step-content {
  order: 1;
  text-align: right;
}

.panel-frame {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(26, 26, 24, 0.06);
  box-shadow: 0 8px 40px rgba(26, 26, 24, 0.1);
}

.panel-frame img {
  width: 100%;
  display: block;
  filter: contrast(1.02) brightness(1.0);
}

.step-content {
  padding: 1rem 0;
}

.step-num {
  font-family: "Unbounded", sans-serif;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--blood);
  display: block;
  margin-bottom: 0.8rem;
}

.ritual-step h3 {
  margin-bottom: 1rem;
}

.ritual-step p {
  color: var(--ink-soft);
  font-size: clamp(0.95rem, 1.3vw, 1.05rem);
  max-width: 34ch;
  margin: 0;
  line-height: 1.7;
}

.step-reverse p {
  margin-left: auto;
}

.step-time {
  display: inline-block;
  margin-top: 1.2rem;
  font-size: 0.78rem;
  color: var(--ink-dim);
  letter-spacing: 0.06em;
  font-weight: 500;
}

/* ── Features ──────────────────────────────── */

.features {
  width: var(--wrap);
  margin: 0 auto;
  padding: 5rem 0 6rem;
  border-top: 1px solid var(--border);
}

.features-grid {
  display: flex;
  align-items: stretch;
}

.feature {
  flex: 1;
  padding: 1.5rem 2.5rem;
  text-align: center;
}

.feature h3 {
  font-size: clamp(0.95rem, 1.3vw, 1.1rem);
  margin-bottom: 0.7rem;
}

.feature p {
  color: var(--ink-soft);
  font-size: 0.92rem;
  margin: 0;
  line-height: 1.65;
}

.brush-stroke {
  width: 1px;
  align-self: stretch;
  background: linear-gradient(
    to bottom,
    transparent 5%,
    rgba(26, 26, 24, 0.06) 25%,
    rgba(26, 26, 24, 0.12) 50%,
    rgba(26, 26, 24, 0.06) 75%,
    transparent 95%
  );
}

/* ── FAQ ───────────────────────────────────── */

.faq {
  width: var(--wrap);
  margin: 0 auto;
  padding: 3rem 0 5rem;
  max-width: 680px;
}

.faq-title {
  font-size: clamp(0.85rem, 1.5vw, 1rem);
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-dim);
  text-align: center;
  margin-bottom: 2.5rem;
}

.faq-list details {
  border-bottom: 1px solid var(--border);
}

.faq-list details:first-child {
  border-top: 1px solid var(--border);
}

.faq-list summary {
  padding: 1.2rem 0;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--ink);
  transition: color 0.2s;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "+";
  font-family: "Unbounded", sans-serif;
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--ink-dim);
  transition: transform 0.25s;
  flex-shrink: 0;
  margin-left: 1rem;
}

.faq-list details[open] summary::after {
  transform: rotate(45deg);
}

.faq-list summary:hover {
  color: var(--blood);
}

.faq-list details p {
  padding: 0 0 1.2rem;
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.92rem;
  line-height: 1.65;
}

/* ── Final CTA ─────────────────────────────── */

.final-cta {
  width: var(--wrap);
  margin: 0 auto;
  padding: 5rem 0 6rem;
  text-align: center;
}

.final-cta h2 {
  margin-bottom: 2.2rem;
}

.btn-appstore {
  font-size: 1.1rem;
  padding: 1rem 2.2rem;
}

.cta-footnote {
  margin-top: 1.2rem;
  font-size: 0.78rem;
  color: var(--ink-dim);
  display: flex;
  justify-content: center;
  gap: 0.6rem;
  letter-spacing: 0.02em;
}

.sep {
  opacity: 0.35;
}

/* ── Footer ────────────────────────────────── */

.footer {
  padding: 2.5rem clamp(1rem, 5vw, 3rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border);
}

.brand-sm {
  font-family: "Unbounded", sans-serif;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  color: var(--ink-dim);
}

.footer-links {
  display: flex;
  gap: 1.4rem;
}

.footer-links a {
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 0.8rem;
  transition: color 0.2s;
}

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

/* ── Mobile sticky CTA ────────────────────── */

.mobile-cta {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 90;
  padding: 1rem;
  background: var(--blood);
  color: var(--paper);
  text-align: center;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  box-shadow: 0 -4px 20px rgba(26, 26, 24, 0.1);
}

/* ── Scroll animations ─────────────────────── */

.ink-up,
.ink-fade,
.ink-left,
.ink-right {
  opacity: 0;
  transition: opacity 0.9s ease, transform 0.9s ease;
}

.ink-up {
  transform: translateY(32px);
}

.ink-fade {
  transform: scale(0.96);
}

.ink-left {
  transform: translateX(-40px);
}

.ink-right {
  transform: translateX(40px);
}

.ink-up.in-view,
.ink-fade.in-view,
.ink-left.in-view,
.ink-right.in-view {
  opacity: 1;
  transform: none;
}

.ink-up.delay-1 { transition-delay: 0.1s; }
.ink-up.delay-2 { transition-delay: 0.2s; }
.ink-up.delay-3 { transition-delay: 0.3s; }

/* ── Utility ───────────────────────────────── */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* ── Responsive ────────────────────────────── */

@media (max-width: 768px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding: 5.5rem 0 2rem;
    gap: 2.5rem;
  }

  .hero-panels {
    position: static;
    height: auto;
    min-height: 0;
    max-width: 75%;
    margin: 0 auto;
  }

  .panel-b,
  .panel-c {
    display: none;
  }

  .panel-a {
    position: static;
    width: 100%;
    aspect-ratio: 3 / 4;
    transform: none;
    animation: none;
    border-radius: var(--radius);
  }

  .ritual {
    padding-top: 2rem;
  }

  .ritual-step,
  .step-reverse {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 4rem;
  }

  .step-reverse .panel-frame {
    order: 0;
  }

  .step-reverse .step-content {
    order: 0;
    text-align: left;
  }

  .step-reverse p {
    margin-left: 0;
  }

  .features-grid {
    flex-direction: column;
  }

  .brush-stroke {
    width: 50%;
    height: 1px;
    margin: 0 auto;
    background: linear-gradient(
      to right,
      transparent 0%,
      rgba(26, 26, 24, 0.08) 30%,
      rgba(26, 26, 24, 0.12) 50%,
      rgba(26, 26, 24, 0.08) 70%,
      transparent 100%
    );
  }

  .feature {
    padding: 1.5rem 0.5rem;
  }

  .mobile-cta {
    display: block;
  }

  .final-cta {
    padding-bottom: 7rem;
  }

  .ritual-title {
    margin-bottom: 3rem;
  }

  .hero-stats {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 2.4rem;
  }

  .hero-panels {
    max-width: 85%;
    height: 85vw;
  }

  .nav {
    padding: 1rem;
  }

  .hero-stats {
    gap: 1rem;
  }

  .stat-divider {
    height: 20px;
  }
}
