.cfl {
  --cfl-ivory: #f3ebdd;
  --cfl-paper: #ebe1cd;
  --cfl-sage: #b9c6a8;
  --cfl-moss: #2c3a2a;
  --cfl-ink: #1e1612;
  --cfl-red: #c8261f;
  --cfl-line: rgb(30 22 18 / 0.16);
  --cfl-display: 'Zodiak', 'Iowan Old Style', Georgia, serif;
  --cfl-body: 'Switzer', 'Helvetica Neue', Arial, sans-serif;
  --cfl-mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
  --cfl-gutter: clamp(16px, 4vw, 56px);
  --cfl-ease: cubic-bezier(0.22, 1, 0.36, 1);

  position: relative;
  background: var(--cfl-ivory);
  color: var(--cfl-ink);
  font-family: var(--cfl-body);
  font-size: 1rem;
  line-height: 1.55;
  text-transform: none;
  -webkit-font-smoothing: antialiased;
}

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

.cfl img {
  display: block;
  max-width: 100%;
}

/* Neutralise the theme's element-level type presets (h1–h6, p) inside the landing page.
   :where keeps this at class specificity, so the .cfl-* rules below still win by order. */
.cfl :where(h1, h2, h3, h4, p, dl, dt, dd, figure, legend) {
  margin: 0;
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  color: inherit;
}

.cfl-display {
  font-family: var(--cfl-display);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 0.98;
  text-wrap: balance;
}

.cfl-display em {
  font-style: italic;
  color: var(--cfl-red);
}

.cfl-display p {
  margin: 0;
}

.cfl-mono {
  font-family: var(--cfl-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cfl-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-family: var(--cfl-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.cfl-eyebrow::before {
  content: '';
  inline-size: 0.5em;
  block-size: 0.5em;
  border-radius: 50%;
  background: var(--cfl-red);
}

/* Buttons */
.cfl-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75em;
  min-block-size: 52px;
  padding: 0 1.6em;
  border: 1px solid var(--cfl-ink);
  border-radius: 999px;
  background: transparent;
  color: var(--cfl-ink);
  font: 500 0.95rem/1 var(--cfl-body);
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform 0.4s var(--cfl-ease),
    background-color 0.3s,
    color 0.3s,
    border-color 0.3s;
}

.cfl-btn:hover {
  transform: translateY(-2px);
}

.cfl-btn:focus-visible,
.cfl a:focus-visible,
.cfl button:focus-visible,
.cfl input:focus-visible {
  outline: 2px solid var(--cfl-red);
  outline-offset: 3px;
}

.cfl-btn--red {
  border-color: var(--cfl-red);
  background: var(--cfl-red);
  color: #fff;
}

.cfl-btn--red:hover {
  background: #a91e18;
  border-color: #a91e18;
}

.cfl-btn--ghost:hover {
  background: var(--cfl-ink);
  color: var(--cfl-ivory);
}

.cfl-btn--small {
  min-block-size: 42px;
  padding: 0 1.2em;
  font-size: 0.85rem;
}

.cfl-btn--block {
  inline-size: 100%;
}

.cfl-btn[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.cfl-placeholder {
  inline-size: 100%;
  block-size: 100%;
  background: var(--cfl-paper);
  fill: rgb(30 22 18 / 0.25);
}

/* Reveal on scroll: hidden only once the page script has confirmed it is running. */
.cfl-js .cfl [data-cfl-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.9s var(--cfl-ease),
    transform 0.9s var(--cfl-ease);
  transition-delay: var(--cfl-delay, 0s);
}

.cfl-js .cfl [data-cfl-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* ------------------------------------------------------------------ Hero */
.cfl-hero {
  block-size: 340vh;
  background:
    radial-gradient(120% 70% at 78% 40%, #f8f2e7 0%, transparent 60%),
    var(--cfl-ivory);
}

.cfl-hero__sticky {
  position: sticky;
  inset-block-start: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  grid-template-rows: auto 1fr auto;
  block-size: 100vh;
  block-size: 100svh;
  padding: clamp(20px, 3vw, 36px) var(--cfl-gutter);
  overflow: hidden;
}

.cfl-hero__brand {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  z-index: 2;
}

.cfl-hero__mark {
  inline-size: 40px;
  block-size: 40px;
}

.cfl-hero__wordmark {
  font-family: var(--cfl-display);
  font-size: 1.35rem;
  letter-spacing: -0.01em;
}

.cfl-hero__coords {
  margin-inline-start: auto;
  opacity: 0.7;
}

.cfl-hero__copy {
  grid-column: 1;
  grid-row: 2;
  align-self: center;
  display: grid;
  gap: clamp(18px, 2.4vw, 28px);
  max-inline-size: 36rem;
  z-index: 2;
}

.cfl-hero__title {
  font-size: clamp(3.2rem, 8.4vw, 8.75rem);
}

.cfl-hero__lede {
  max-inline-size: 30rem;
  font-size: clamp(1.02rem, 1.25vw, 1.2rem);
  color: rgb(30 22 18 / 0.8);
}

.cfl-hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.cfl-hero__stage {
  grid-column: 2;
  grid-row: 2 / 4;
  position: relative;
  display: grid;
  place-items: center;
  min-block-size: 0;
}

.cfl-hero__frames {
  position: relative;
  inline-size: min(100%, 64vh);
  aspect-ratio: 4 / 5;
}

.cfl-hero__frame {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.04);
  transition:
    opacity 0.25s linear,
    transform 0.25s linear;
  -webkit-mask-image: radial-gradient(closest-side, #000 72%, transparent 100%);
  mask-image: radial-gradient(closest-side, #000 72%, transparent 100%);
}

.cfl-hero__frame.is-active {
  opacity: 1;
  transform: none;
}

.cfl-hero__img {
  inline-size: 100%;
  block-size: 100%;
  object-fit: cover;
}

.cfl-hero__steps {
  position: absolute;
  inset-inline-end: 0;
  inset-block-end: 0;
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cfl-hero__step {
  display: flex;
  gap: 10px;
  align-items: baseline;
  opacity: 0.35;
  transition: opacity 0.3s;
}

.cfl-hero__step.is-active {
  opacity: 1;
}

.cfl-hero__step.is-active .cfl-hero__step-num {
  color: var(--cfl-red);
}

.cfl-hero__thread {
  position: absolute;
  inset: 0;
  inline-size: 100%;
  block-size: 100%;
  pointer-events: none;
  z-index: 1;
}

.cfl-hero__thread path {
  fill: none;
  stroke: var(--cfl-red);
  stroke-width: 1.6;
  stroke-linecap: round;
}

.cfl-hero__bead {
  position: absolute;
  inset-block-start: 0;
  inset-inline-start: 0;
  inline-size: 14px;
  block-size: 14px;
  margin: -7px 0 0 -7px;
  border-radius: 50%;
  background: var(--cfl-red);
  box-shadow: 0 0 0 6px rgb(200 38 31 / 0.14);
  pointer-events: none;
  z-index: 1;
  opacity: 0;
}

.cfl-hero__cue {
  grid-column: 1;
  grid-row: 3;
  align-self: end;
  opacity: 0.6;
  z-index: 2;
}

.cfl-hero__cue::after {
  content: ' ↓';
}

/* ------------------------------------------------------------------ Marquee */
.cfl-marquee {
  position: relative;
  overflow: hidden;
  background: var(--cfl-moss);
  color: var(--cfl-ivory);
  border-block: 1px solid rgb(243 235 221 / 0.12);
}

.cfl-marquee__track {
  display: flex;
  inline-size: max-content;
  animation: cfl-marquee var(--cfl-marquee-duration, 55s) linear infinite;
}

.cfl-marquee:hover .cfl-marquee__track,
.cfl-marquee.is-paused .cfl-marquee__track {
  animation-play-state: paused;
}

.cfl-marquee__list {
  display: flex;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cfl-marquee__item {
  display: flex;
  align-items: baseline;
  gap: 0.9em;
  padding: 22px 2.6em 22px 0;
  white-space: nowrap;
  font-size: 0.82rem;
}

.cfl-marquee__item::before {
  content: '';
  align-self: center;
  inline-size: 7px;
  block-size: 7px;
  margin-inline-end: 0.4em;
  border-radius: 50%;
  background: var(--cfl-red);
}

.cfl-marquee__label {
  opacity: 0.55;
}

.cfl-marquee__toggle {
  position: absolute;
  inset-block: 0;
  inset-inline-end: 0;
  padding: 0 18px 0 40px;
  border: 0;
  background: linear-gradient(90deg, transparent, var(--cfl-moss) 40%);
  color: var(--cfl-ivory);
  font: 500 0.7rem/1 var(--cfl-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
}

@keyframes cfl-marquee {
  to {
    transform: translateX(-50%);
  }
}

/* ------------------------------------------------------------------ Roasts */
.cfl-roasts {
  padding: clamp(80px, 11vw, 160px) var(--cfl-gutter);
  background: var(--cfl-ivory);
}

.cfl-roasts__head {
  display: grid;
  gap: 18px;
  max-inline-size: 52rem;
  margin-block-end: clamp(40px, 6vw, 80px);
}

.cfl-roasts__title,
.cfl-chapters__title {
  font-size: clamp(2.6rem, 6.4vw, 6rem);
}

.cfl-roasts__intro {
  max-inline-size: 32rem;
  font-size: 1.08rem;
  color: rgb(30 22 18 / 0.78);
}

.cfl-roasts__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(12px, 1.6vw, 22px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.cfl-roast {
  position: relative;
  display: flex;
  flex-direction: column;
  min-inline-size: 0;
  border-radius: 22px;
  overflow: hidden;
  background: var(--cfl-paper);
  isolation: isolate;
}

.cfl-roast::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--cfl-swatch);
  clip-path: circle(0% at 50% 30%);
  transition: clip-path 0.8s var(--cfl-ease);
}

.cfl-roast:hover::before,
.cfl-roast:focus-within::before {
  clip-path: circle(150% at 50% 30%);
}

.cfl-roast:hover .cfl-roast__body,
.cfl-roast:focus-within .cfl-roast__body {
  color: var(--cfl-swatch-ink);
}

.cfl-roast__media {
  aspect-ratio: 4 / 5;
  overflow: hidden;
}

.cfl-roast__img {
  inline-size: 100%;
  block-size: 100%;
  object-fit: cover;
  transition: transform 1.1s var(--cfl-ease);
}

.cfl-roast:hover .cfl-roast__img {
  transform: scale(1.04) translateY(-6px);
}

.cfl-roast__body {
  display: grid;
  gap: 8px;
  flex: 1;
  align-content: start;
  padding: 20px 20px 22px;
  transition: color 0.4s;
}

.cfl-roast__roast {
  opacity: 0.7;
}

.cfl-roast__name {
  font-size: clamp(1.9rem, 2.6vw, 2.6rem);
}

.cfl-roast__notes {
  font-size: 0.95rem;
  opacity: 0.85;
}

.cfl-roast__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-block-start: 10px;
}

.cfl-roast__price {
  font-family: var(--cfl-mono);
  font-size: 0.85rem;
  white-space: nowrap;
}

.cfl-roast__cta {
  border-color: currentColor;
  color: inherit;
}

.cfl-roast__cta:hover {
  background: var(--cfl-red);
  border-color: var(--cfl-red);
  color: #fff;
}

/* ------------------------------------------------------------------ Chapters */
.cfl-chapters {
  padding: clamp(80px, 11vw, 160px) 0 clamp(60px, 8vw, 120px);
  background: var(--cfl-paper);
}

.cfl-chapters__head {
  display: grid;
  gap: 18px;
  max-inline-size: 60rem;
  padding: 0 var(--cfl-gutter);
  margin-block-end: clamp(48px, 7vw, 96px);
}

.cfl-chapters__layout {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr);
  gap: clamp(16px, 3vw, 48px);
  padding-inline-end: var(--cfl-gutter);
}

.cfl-chapters__rail {
  position: sticky;
  inset-block-start: 24vh;
  align-self: start;
  padding-inline-start: var(--cfl-gutter);
}

.cfl-chapters__rail ol {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
  border-inline-start: 1px solid var(--cfl-line);
}

.cfl-chapters__rail a {
  position: relative;
  display: flex;
  gap: 10px;
  padding: 7px 0 7px 14px;
  color: inherit;
  text-decoration: none;
  opacity: 0.45;
  transition: opacity 0.3s;
}

.cfl-chapters__rail a::before {
  content: '';
  position: absolute;
  inset-block: 6px;
  inset-inline-start: -1px;
  inline-size: 2px;
  background: var(--cfl-red);
  transform: scaleY(0);
  transition: transform 0.4s var(--cfl-ease);
}

.cfl-chapters__rail a:hover,
.cfl-chapters__rail a.is-current {
  opacity: 1;
}

.cfl-chapters__rail a.is-current::before {
  transform: none;
}

.cfl-chapters__rail-num {
  min-inline-size: 2.2em;
  color: var(--cfl-red);
}

.cfl-chapters__list {
  display: grid;
  gap: clamp(72px, 10vw, 150px);
  min-inline-size: 0;
}

.cfl-chapter {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  align-items: center;
  gap: clamp(20px, 3vw, 44px);
  scroll-margin-block-start: 80px;
}

.cfl-chapter__media {
  grid-column: 1 / span 7;
  grid-row: 1;
  overflow: hidden;
  border-radius: 18px;
  aspect-ratio: 4 / 5;
  max-block-size: 82vh;
}

.cfl-chapter__img {
  inline-size: 100%;
  block-size: 100%;
  object-fit: cover;
}

.cfl-chapter__body {
  grid-column: 8 / span 5;
  grid-row: 1;
  display: grid;
  gap: 18px;
  max-inline-size: 30rem;
}

.cfl-chapter--end .cfl-chapter__media {
  grid-column: 6 / span 7;
}

.cfl-chapter--end .cfl-chapter__body {
  grid-column: 1 / span 5;
}

.cfl-chapter__num {
  display: flex;
  gap: 12px;
  align-items: baseline;
}

.cfl-chapter__num span:first-child {
  font-family: var(--cfl-display);
  font-size: 2.6rem;
  letter-spacing: 0;
  text-transform: none;
  color: var(--cfl-red);
  line-height: 1;
}

.cfl-chapter__title {
  font-size: clamp(2.1rem, 4vw, 3.6rem);
}

.cfl-chapter__text {
  font-size: 1.05rem;
  color: rgb(30 22 18 / 0.8);
}

.cfl-chapter__text p + p {
  margin-block-start: 0.9em;
}

.cfl-chapter__fact {
  display: flex;
  gap: 14px;
  padding-block-start: 14px;
  border-block-start: 1px solid var(--cfl-line);
}

.cfl-chapter__fact dt {
  opacity: 0.55;
}

/* Wide chapter: full-bleed image with text over the lower edge */
.cfl-chapter--wide .cfl-chapter__media {
  grid-column: 1 / -1;
  aspect-ratio: 16 / 9;
  max-block-size: none;
}

.cfl-chapter--wide .cfl-chapter__body {
  grid-column: 1 / span 6;
  grid-row: 1;
  align-self: end;
  margin: clamp(16px, 3vw, 40px);
  padding: clamp(20px, 2.6vw, 34px);
  border-radius: 16px;
  background: rgb(243 235 221 / 0.92);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

/* ------------------------------------------------------------------ Closing */
.cfl-closing {
  overflow: hidden;
  padding: clamp(90px, 12vw, 180px) var(--cfl-gutter) clamp(40px, 5vw, 64px);
  background: var(--cfl-moss);
  color: var(--cfl-ivory);
}

.cfl-closing__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: clamp(40px, 6vw, 96px);
  align-items: end;
}

.cfl-closing__title {
  font-size: clamp(3rem, 8vw, 7.5rem);
}

.cfl-closing__title em {
  color: #ef6a5d;
}

.cfl-closing .cfl-eyebrow {
  color: rgb(243 235 221 / 0.75);
}

.cfl-closing__steps {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: cfl-step;
}

.cfl-closing__step {
  display: grid;
  grid-template-columns: 3.2rem minmax(0, 1fr);
  gap: 10px;
  padding: 16px 0;
  border-block-start: 1px solid rgb(243 235 221 / 0.18);
  counter-increment: cfl-step;
}

.cfl-closing__step::before {
  content: '0' counter(cfl-step);
  font-family: var(--cfl-mono);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: #ef6a5d;
  padding-block-start: 0.3em;
}

.cfl-closing__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-block-start: 32px;
}

.cfl-closing .cfl-btn--ghost {
  border-color: rgb(243 235 221 / 0.5);
  color: var(--cfl-ivory);
}

.cfl-closing .cfl-btn--ghost:hover {
  background: var(--cfl-ivory);
  color: var(--cfl-moss);
}

.cfl-closing__sign {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-block-start: clamp(70px, 10vw, 140px);
  padding-block-start: 22px;
  border-block-start: 1px solid rgb(243 235 221 / 0.18);
}

.cfl-closing__mark {
  inline-size: 34px;
  block-size: 34px;
}

.cfl-closing__sign .cfl-mono {
  margin-inline-start: auto;
  opacity: 0.6;
}

.cfl-closing__wordmark {
  font-family: var(--cfl-display);
  font-size: 1.2rem;
}

/* ------------------------------------------------------------------ Order dialog */
html.cfl-modal-open {
  overflow: hidden;
}

.cfl-modal {
  /* .cfl sets position: relative; a modal dialog must stay fixed to the viewport. */
  position: fixed;
  inset: 0;
  margin: auto;
  inline-size: min(980px, calc(100vw - 32px));
  max-inline-size: none;
  max-block-size: calc(100dvh - 32px);
  padding: 0;
  border: 0;
  border-radius: 26px;
  background: var(--cfl-ivory);
  color: var(--cfl-ink);
  overflow: auto;
  overscroll-behavior: contain;
}

.cfl-modal::backdrop {
  background: rgb(30 22 18 / 0.55);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

.cfl-modal[open] {
  animation: cfl-modal-in 0.5s var(--cfl-ease);
}

@keyframes cfl-modal-in {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
  }
}

.cfl-modal__panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1fr);
}

.cfl-modal__close {
  position: absolute;
  inset-block-start: 14px;
  inset-inline-end: 14px;
  z-index: 2;
  display: grid;
  place-items: center;
  inline-size: 44px;
  block-size: 44px;
  padding: 0;
  border: 1px solid var(--cfl-line);
  border-radius: 50%;
  background: var(--cfl-ivory);
  color: var(--cfl-ink);
  cursor: pointer;
}

.cfl-modal__close svg {
  inline-size: 18px;
  block-size: 18px;
}

.cfl-modal__visual {
  position: relative;
  display: grid;
  place-items: center;
  min-block-size: 100%;
  padding: 28px;
  background: var(--cfl-modal-swatch, var(--cfl-sage));
  transition: background-color 0.5s;
}

.cfl-modal__img {
  inline-size: 100%;
  block-size: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 16px;
}

.cfl-modal__mark {
  position: absolute;
  inset-block-start: 22px;
  inset-inline-start: 22px;
  inline-size: 30px;
  block-size: 30px;
  color: var(--cfl-modal-swatch-ink, var(--cfl-ink));
}

.cfl-modal__form {
  display: grid;
  align-content: start;
  gap: 18px;
  padding: clamp(28px, 4vw, 44px);
  padding-block-start: clamp(36px, 5vw, 56px);
}

.cfl-modal__title {
  font-size: clamp(2.4rem, 4.4vw, 3.6rem);
}

.cfl-modal__notes {
  margin-block-start: -6px;
  color: rgb(30 22 18 / 0.75);
}

[data-cfl-options] {
  display: grid;
  gap: 18px;
}

[data-cfl-options]:empty {
  display: none;
}

.cfl-field {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  border: 0;
  min-inline-size: 0;
}

.cfl-field__legend {
  padding: 0;
  margin-block-end: 2px;
  font-family: var(--cfl-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.7;
}

.cfl-swatches,
.cfl-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cfl-choice {
  position: relative;
}

.cfl-choice input {
  position: absolute;
  opacity: 0;
  inset: 0;
  margin: 0;
  cursor: pointer;
}

.cfl-choice span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-block-size: 42px;
  padding: 0 16px;
  border: 1px solid var(--cfl-line);
  border-radius: 999px;
  font-size: 0.9rem;
  transition:
    border-color 0.2s,
    background-color 0.2s,
    color 0.2s;
}

.cfl-choice input:checked + span {
  border-color: var(--cfl-ink);
  background: var(--cfl-ink);
  color: var(--cfl-ivory);
}

.cfl-choice input:focus-visible + span {
  outline: 2px solid var(--cfl-red);
  outline-offset: 2px;
}

.cfl-choice input:disabled + span {
  opacity: 0.4;
  text-decoration: line-through;
}

.cfl-choice__dot {
  inline-size: 14px;
  block-size: 14px;
  border-radius: 50%;
  background: var(--cfl-dot);
  box-shadow: inset 0 0 0 1px rgb(30 22 18 / 0.2);
}

.cfl-qty {
  display: inline-flex;
  align-items: center;
  inline-size: max-content;
  border: 1px solid var(--cfl-line);
  border-radius: 999px;
}

.cfl-qty__btn {
  inline-size: 44px;
  block-size: 44px;
  border: 0;
  background: none;
  color: inherit;
  font-size: 1.2rem;
  cursor: pointer;
}

.cfl .cfl-qty__input {
  inline-size: 3em;
  padding: 0;
  border-radius: 0;
  border: 0;
  background: none;
  color: inherit;
  font: 500 1rem var(--cfl-mono);
  text-align: center;
  -moz-appearance: textfield;
}

.cfl-qty__input::-webkit-inner-spin-button,
.cfl-qty__input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.cfl-btn__price {
  font-family: var(--cfl-mono);
  font-size: 0.85rem;
}

.cfl-btn__price:not(:empty)::before {
  content: '· ';
}

.cfl-modal__status {
  min-block-size: 1.2em;
  font-size: 0.9rem;
}

.cfl-modal__status.is-error {
  color: var(--cfl-red);
}

.cfl-modal__fine {
  opacity: 0.6;
}

.cfl-modal__done {
  display: grid;
  gap: 16px;
  padding: 20px;
  border-radius: 16px;
  background: var(--cfl-paper);
}

.cfl-modal__done[hidden] {
  display: none;
}

.cfl-modal__done-title {
  font-size: 1.8rem;
}

.cfl-modal__done-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* ------------------------------------------------------------------ Responsive */
@media (max-width: 989px) {
  .cfl-roasts__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cfl-hero {
    block-size: 300vh;
  }

  .cfl-hero__sticky {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto auto minmax(0, 1fr) auto;
    gap: 14px;
  }

  .cfl-hero__copy {
    grid-row: 2;
    gap: 14px;
  }

  .cfl-hero__title {
    font-size: clamp(2.7rem, 12vw, 4.6rem);
  }

  .cfl-hero__lede {
    font-size: 0.98rem;
  }

  .cfl-hero__stage {
    grid-column: 1;
    grid-row: 3;
  }

  .cfl-hero__frames {
    inline-size: auto;
    block-size: 100%;
    max-inline-size: 100%;
  }

  .cfl-hero__steps {
    inset-inline-end: 0;
    inset-block-end: 4px;
  }

  .cfl-hero__cue {
    grid-row: 4;
  }

  .cfl-hero__coords {
    display: none;
  }

  .cfl-chapters__layout {
    grid-template-columns: minmax(0, 1fr);
    padding-inline: var(--cfl-gutter);
  }

  .cfl-chapters__rail {
    display: none;
  }

  .cfl-chapter,
  .cfl-chapter--end {
    grid-template-columns: minmax(0, 1fr);
  }

  .cfl-chapter .cfl-chapter__media,
  .cfl-chapter--end .cfl-chapter__media,
  .cfl-chapter .cfl-chapter__body,
  .cfl-chapter--end .cfl-chapter__body {
    grid-column: 1;
    grid-row: auto;
  }

  .cfl-chapter__media {
    max-block-size: none;
  }

  .cfl-chapter--wide .cfl-chapter__media {
    aspect-ratio: 4 / 3;
  }

  .cfl-chapter--wide .cfl-chapter__body {
    margin: -48px 12px 0;
    position: relative;
  }

  .cfl-closing__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .cfl-modal__panel {
    grid-template-columns: minmax(0, 1fr);
  }

  .cfl-modal__visual {
    min-block-size: 0;
    padding: 18px 18px 0;
    background: linear-gradient(var(--cfl-modal-swatch, var(--cfl-sage)) 70%, var(--cfl-ivory) 70%);
  }

  .cfl-modal__img {
    inline-size: min(34vw, 180px);
  }

  .cfl-modal__form {
    gap: 14px;
    padding-block-start: 20px;
  }

  .cfl-modal__title {
    font-size: 2.2rem;
  }

  /* Keep the add button in reach while the options scroll. */
  .cfl-modal [data-cfl-submit] {
    position: sticky;
    inset-block-end: 12px;
    z-index: 1;
    box-shadow: 0 10px 30px rgb(30 22 18 / 0.18);
  }
}

@media (max-width: 749px) {
  .cfl-hero__ctas .cfl-btn {
    flex: 1 1 auto;
  }

  .cfl-roasts__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .cfl-roast {
    display: grid;
    grid-template-columns: 42% minmax(0, 1fr);
  }

  .cfl-roast__media {
    aspect-ratio: auto;
    block-size: 100%;
  }

  .cfl-roast__body {
    padding: 16px;
  }

  .cfl-roast__foot {
    flex-wrap: wrap;
  }

  .cfl-chapter--wide .cfl-chapter__body {
    margin: -36px 8px 0;
  }

  .cfl-closing__sign {
    flex-wrap: wrap;
  }

  .cfl-closing__sign .cfl-mono {
    margin-inline-start: 0;
    inline-size: 100%;
  }
}

/* No scroll-driven hero for reduced motion: show the four frames as a strip. */
@media (prefers-reduced-motion: reduce) {
  .cfl-hero {
    block-size: auto;
  }

  .cfl-hero__sticky {
    position: relative;
    block-size: auto;
    min-block-size: 100svh;
  }

  .cfl-hero__frames {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    aspect-ratio: auto;
    block-size: auto;
    inline-size: min(100%, 64vh);
  }

  .cfl-hero__frame {
    position: relative;
    aspect-ratio: 4 / 5;
    opacity: 1;
    transform: none;
  }

  .cfl-hero__steps,
  .cfl-hero__thread,
  .cfl-hero__bead,
  .cfl-hero__cue {
    display: none;
  }

  .cfl-marquee__track {
    animation: none;
    inline-size: auto;
  }

  .cfl-marquee__list {
    flex-wrap: wrap;
    padding-inline: var(--cfl-gutter);
  }

  .cfl-marquee__list[aria-hidden='true'],
  .cfl-marquee__toggle {
    display: none;
  }

  .cfl *,
  .cfl *::before {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }

  .cfl-js .cfl [data-cfl-reveal] {
    opacity: 1;
    transform: none;
  }
}
