@font-face {
  font-family: "Fraunces";
  src: url("/fonts/fraunces.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Fraunces";
  src: url("/fonts/fraunces-italic.woff2") format("woff2");
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}

:root {
  --espresso: #2b1d14;
  --espresso-deep: #1c130d;
  --roast: #6b3f2a;
  --ember: #c8553d;
  --ember-dark: #a8432e;
  --honey: #e3b04b;
  --cream: #f4ede3;
  --paper: #fbf7f1;
  --sand: #e9dccb;
  --ink-soft: #6a5546;
  --line: #ddcdb9;
  --radius: 24px;
  --shadow: 0 24px 48px -28px rgb(43 29 20 / 45%);
  --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-body: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--espresso);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img,
svg {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 0.45em;
  font-variation-settings: "opsz" 144;
}

h1 {
  font-size: clamp(3rem, 7.4vw, 6.4rem);
  line-height: 0.95;
  letter-spacing: -0.035em;
}

h1 em {
  font-style: italic;
  font-weight: 500;
  color: var(--ember);
}

h2 {
  font-size: clamp(2.1rem, 4.4vw, 3.6rem);
}

h3 {
  font-size: 1.55rem;
}

p {
  margin: 0 0 1em;
}

a {
  color: inherit;
}

.container {
  width: min(1200px, 100% - 32px);
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  padding: 10px 16px;
  background: var(--espresso);
  color: var(--cream);
  border-radius: 10px;
  z-index: 100;
}

.skip-link:focus {
  top: 16px;
}

:focus-visible {
  outline: 3px solid var(--honey);
  outline-offset: 3px;
}

.eyebrow {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 1.2em;
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 15px 28px;
  border-radius: 999px;
  border: 1.5px solid var(--espresso);
  background: var(--espresso);
  color: var(--cream);
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.button:hover {
  background: var(--ember);
  border-color: var(--ember);
  transform: translateY(-2px);
}

.button-small {
  padding: 10px 20px;
  font-size: 0.92rem;
}

.button-ghost {
  background: transparent;
  color: var(--espresso);
}

.button-ghost:hover {
  color: var(--cream);
}

.button-light {
  background: var(--cream);
  border-color: var(--cream);
  color: var(--espresso);
}

.button-light:hover {
  background: var(--honey);
  border-color: var(--honey);
  color: var(--espresso);
}

.button-ghost-light {
  background: transparent;
  border-color: rgb(244 237 227 / 60%);
  color: var(--cream);
}

.button-ghost-light:hover {
  background: var(--cream);
  border-color: var(--cream);
  color: var(--espresso);
}

/* Demo notice, announcement and header */
.demo-notice {
  margin: 0;
  padding: 6px 16px;
  background: var(--espresso);
  color: var(--cream);
  text-align: center;
  font-size: 0.8rem;
  line-height: 1.4;
}

.announcement {
  margin: 0;
  padding: 10px 16px;
  background: var(--sand);
  text-align: center;
  font-size: 0.88rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgb(244 237 227 / 82%);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease;
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
}

.header-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 80px;
}

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

.nav-right {
  justify-content: flex-end;
}

.nav-group a:not(.button) {
  text-decoration: none;
  font-weight: 500;
}

.nav-group a:not(.button):hover {
  color: var(--ember);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand-mark {
  width: 36px;
  height: 36px;
}

.menu-toggle {
  display: none;
  justify-self: end;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 10px;
}

.menu-bar {
  display: block;
  height: 2px;
  background: var(--espresso);
  margin: 7px 0;
  transition: transform 0.2s ease;
}

.mobile-nav {
  display: none;
}

/* Hero */
.hero {
  position: relative;
  padding: 56px 0 0;
  overflow: hidden;
  isolation: isolate;
}

.hero-copy {
  position: relative;
  z-index: 2;
  text-align: center;
}

.hero .lead {
  max-width: 40ch;
  margin: 0 auto;
  font-size: 1.2rem;
  color: var(--ink-soft);
}

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

.hero-beans {
  position: absolute;
  top: 6%;
  width: clamp(220px, 30vw, 470px);
  height: auto;
  z-index: 1;
  pointer-events: none;
  will-change: transform;
}

.hero-beans-left {
  left: clamp(-180px, -9vw, -40px);
}

.hero-beans-right {
  right: clamp(-180px, -9vw, -40px);
  top: 18%;
}

.hero-stage {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 32px;
  width: min(1200px, 100% - 32px);
  margin: 8px auto 0;
}

.bag-wrap {
  position: relative;
  width: clamp(240px, 30vw, 430px);
  perspective: 1000px;
  will-change: transform;
}

.hero-bag {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 40px 40px rgb(43 29 20 / 30%));
}

.bag-shadow {
  position: absolute;
  left: 12%;
  right: 12%;
  bottom: 2%;
  height: 28px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgb(43 29 20 / 35%), transparent);
  z-index: -1;
}

.callout {
  max-width: 280px;
}

.callout-left {
  justify-self: end;
  text-align: left;
}

.callout-right {
  justify-self: start;
}

.callout h2 {
  font-size: 1.6rem;
  margin-bottom: 0.4em;
}

.callout p {
  color: var(--ink-soft);
  font-size: 0.98rem;
  margin: 0;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.callout-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-bottom: 18px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  color: var(--ember);
}

.callout-icon svg {
  width: 22px;
  height: 22px;
}

/* Highlights strip */
.strip {
  position: relative;
  z-index: 5;
  background: var(--espresso);
  color: var(--sand);
}

.strip-track {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px 56px;
  padding: 22px 16px;
}

.strip p {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-style: italic;
}

.strip p::before {
  content: "\2726";
  color: var(--honey);
  font-style: normal;
  margin-right: 12px;
}

/* Sections */
.section {
  padding: 120px 0;
}

.section-tight {
  padding-top: 40px;
}

.section-soft {
  background: var(--sand);
}

.section-head {
  max-width: 660px;
  margin-bottom: 60px;
}

.section-head-center {
  margin-inline: auto;
  text-align: center;
}

.section-head p:last-child {
  color: var(--ink-soft);
}

/* Coffee cards */
.card-grid,
.pricing-grid,
.quote-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.card-grid {
  perspective: 1400px;
}

.coffee-card {
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  background: var(--paper);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transform: rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  transform-style: preserve-3d;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.coffee-card:hover {
  box-shadow: 0 36px 64px -28px rgb(43 29 20 / 55%);
}

.coffee-art {
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 0.96;
  overflow: hidden;
}

.coffee-art img {
  width: auto;
  height: 92%;
  object-fit: contain;
  transition: transform 0.35s ease;
}

.coffee-card:hover .coffee-art img {
  transform: translateY(-8px) scale(1.04);
}

.coffee-card-honey .coffee-art {
  background: radial-gradient(circle at 50% 40%, #fbefd3, #efd9a8);
}

.coffee-card-ember .coffee-art {
  background: radial-gradient(circle at 50% 40%, #f8e1d8, #ebbfae);
}

.coffee-card-dark .coffee-art {
  background: radial-gradient(circle at 50% 40%, #eadfd5, #cdbcad);
}

.coffee-body {
  padding: 28px;
}

.coffee-body p {
  color: var(--ink-soft);
}

.tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--sand);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.coffee-meta {
  display: flex;
  justify-content: space-between;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.coffee-meta strong {
  font-family: var(--font-display);
  font-size: 1.3rem;
}

/* Process: full-bleed photo with glass cards */
.process {
  position: relative;
  padding: 140px 0;
  color: var(--cream);
  overflow: hidden;
  isolation: isolate;
}

.process-media {
  position: absolute;
  inset: -12% 0;
  z-index: -2;
  will-change: transform;
}

.process-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.process::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgb(28 19 13 / 92%) 0%, rgb(28 19 13 / 70%) 55%, rgb(28 19 13 / 35%) 100%);
}

.process .eyebrow {
  color: var(--honey);
}

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.step {
  padding: 30px 26px;
  border: 1px solid rgb(244 237 227 / 18%);
  border-radius: var(--radius);
  background: rgb(244 237 227 / 8%);
  backdrop-filter: blur(16px);
}

.step p {
  color: var(--sand);
  margin: 0;
}

.step-number {
  display: block;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 2.6rem;
  color: var(--honey);
  margin-bottom: 16px;
}

/* Brew ritual: a pinned clip that the scroll position plays forwards and backwards */
.ritual {
  background: var(--espresso-deep);
  color: var(--cream);
  overflow: hidden;
}

.ritual-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 72px;
  min-height: 100vh;
  padding-block: 64px;
}

.ritual .eyebrow {
  color: var(--honey);
}

.ritual-steps {
  display: grid;
  gap: 28px;
  list-style: none;
  padding: 0;
  margin: 40px 0 0;
}

.ritual-step {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 18px;
  transition: opacity 0.4s ease;
}

.ritual-step h3 {
  margin: 0 0 6px;
}

.ritual-step p {
  margin: 0;
  color: var(--sand);
}

.ritual-number {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 2.2rem;
  line-height: 1;
  color: var(--honey);
}

/* Only dim the inactive steps when the scroll is driving the clip */
.ritual.is-scrubbing .ritual-step:not(.is-active) {
  opacity: 0.32;
}

/* Leave room for the sticky header while the section is pinned */
.ritual.is-scrubbing .ritual-inner {
  padding-block: 112px 48px;
}

.ritual-media {
  position: relative;
  aspect-ratio: 9 / 16;
  height: min(calc(100vh - 176px), 780px);
  justify-self: center;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 40px 80px -40px rgb(0 0 0 / 70%);
}

.ritual-still,
.ritual-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ritual-video {
  opacity: 0;
  transition: opacity 0.4s ease;
}

.ritual-video.is-ready {
  opacity: 1;
}

/* Pricing */
.plan {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 38px 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.plan ul {
  list-style: none;
  padding: 0;
  margin: 0 0 32px;
  flex: 1;
}

.plan li {
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.plan li::before {
  content: "\2713";
  color: var(--ember);
  font-weight: 700;
  margin-right: 10px;
}

.plan-price {
  color: var(--ink-soft);
}

.plan-price strong {
  font-family: var(--font-display);
  font-size: 3.2rem;
  color: var(--espresso);
}

.plan-featured {
  background: var(--espresso);
  color: var(--cream);
  border-color: var(--espresso);
  transform: translateY(-12px);
  box-shadow: var(--shadow);
}

.plan-featured .plan-price,
.plan-featured .plan-price strong {
  color: var(--cream);
}

.plan-featured li {
  border-bottom-color: rgb(244 237 227 / 16%);
}

.plan-badge {
  position: absolute;
  top: -14px;
  left: 32px;
  padding: 4px 14px;
  border-radius: 999px;
  background: var(--honey);
  color: var(--espresso);
  font-size: 0.8rem;
  font-weight: 700;
}

/* Testimonials */
.quote {
  margin: 0;
  padding: 34px;
  background: var(--paper);
  border-radius: var(--radius);
}

.quote blockquote {
  margin: 0 0 26px;
  font-family: var(--font-display);
  font-size: 1.3rem;
  line-height: 1.45;
}

.quote figcaption {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.avatar {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--ember);
  color: var(--cream);
  font-weight: 700;
  font-size: 0.85rem;
}

/* FAQ */
.faq-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 56px;
}

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

.faq-list summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 1.15rem;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

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

.faq-list summary::after {
  content: "+";
  color: var(--ember);
  font-size: 1.5rem;
  line-height: 1;
  transition: transform 0.2s ease;
}

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

.faq-list details p {
  margin: 14px 0 0;
  color: var(--ink-soft);
}

/* Call to action */
.cta-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  padding: 64px;
  border-radius: 32px;
  background: linear-gradient(135deg, var(--ember) 0%, var(--roast) 100%);
  color: var(--cream);
}

.cta-card .eyebrow {
  color: var(--honey);
}

.cta-card h2 {
  max-width: 16ch;
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  flex-shrink: 0;
}

/* Footer */
.site-footer {
  padding: 40px 0;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 32px;
}

.footer-inner p {
  margin: 0;
}

/* 404 page */
.not-found {
  display: grid;
  place-items: center;
  min-height: 70vh;
  text-align: center;
  padding: 64px 0;
}

.not-found .lead {
  margin-inline: auto;
  color: var(--ink-soft);
}

/* Scroll reveal: only hidden when JavaScript is running */
.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

.js .coffee-card.reveal.is-visible {
  transform: rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
}

/* Responsive */
@media (max-width: 1080px) {
  .nav-group {
    gap: 20px;
  }

  .nav-left a:nth-child(3),
  .nav-right a:not(.button) {
    display: none;
  }
}

@media (max-width: 960px) {
  .card-grid,
  .pricing-grid,
  .quote-grid,
  .faq-grid {
    grid-template-columns: 1fr;
  }

  .card-grid,
  .pricing-grid,
  .quote-grid {
    max-width: 520px;
  }

  .steps {
    grid-template-columns: repeat(2, 1fr);
  }

  .plan-featured {
    transform: none;
  }

  .cta-card {
    flex-direction: column;
    align-items: flex-start;
    padding: 40px 28px;
  }

  .hero-stage {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .callout {
    display: none;
  }
}

@media (max-width: 760px) {
  .header-inner {
    grid-template-columns: auto 1fr;
  }

  .nav-group {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .brand {
    font-size: 1.45rem;
  }

  .mobile-nav.is-open {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 20px 16px 28px;
    border-top: 1px solid var(--line);
  }

  .mobile-nav a {
    font-size: 1.1rem;
    text-decoration: none;
  }

  .menu-toggle[aria-expanded="true"] .menu-bar:first-of-type {
    transform: translateY(4.5px) rotate(45deg);
  }

  .menu-toggle[aria-expanded="true"] .menu-bar:last-of-type {
    transform: translateY(-4.5px) rotate(-45deg);
  }

  .hero {
    padding-top: 48px;
  }

  .hero-beans {
    width: 46vw;
    top: auto;
    bottom: 4%;
    opacity: 0.95;
  }

  .hero-beans-left {
    left: -18vw;
  }

  .hero-beans-right {
    right: -18vw;
    bottom: 12%;
  }

  .bag-wrap {
    width: 62vw;
  }

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

  .section {
    padding: 80px 0;
  }

  .process {
    padding: 90px 0;
  }

  .ritual-inner {
    grid-template-columns: 1fr;
    gap: 32px;
    min-height: auto;
    padding-block: 80px;
  }

  .ritual.is-scrubbing .ritual-inner {
    min-height: 100vh;
    padding-block: 96px 24px;
    gap: 20px;
  }

  .ritual-steps {
    margin-top: 24px;
    gap: 18px;
  }

  .ritual.is-scrubbing .ritual-step:not(.is-active) {
    display: none;
  }

  .ritual-media {
    width: auto;
    height: min(52vh, 560px);
    max-width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
  }
}
