@font-face {
  font-family: "Epilogue";
  src: url("/fonts/epilogue-latin.woff2") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --brand: #f24c36;
  --brand-light: #f3a795;
  --brand-dark: #f12e14;
  --blue: #5075d3;
  --blue-light: #82a3d8;
  --blue-dark: #2c5bd3;
  --ink: #111827;
  --gray-200: #e5e7eb;
  --gray-500: #6a7282;
  --gray-700: #364153;
  --gray-800: #1e2939;
  --gray-900: #101828;
  --paper: #ffffff;
  --blush: #fbefea;
  --peach: #f7d4be;
  --max: 1120px;
  --font: "Epilogue", "Segoe UI", sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.5;
  font-weight: 450;
}

img, svg { max-width: 100%; height: auto; }

h1, h2, h3 {
  font-family: var(--font);
  font-weight: 650;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 0.5rem;
}

h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); font-weight: 750; }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; }
h3 { font-size: 1.05rem; font-weight: 650; }
p { margin: 0 0 0.75rem; }
a { color: var(--blue-dark); }

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

.skip {
  position: absolute;
  left: 0.75rem;
  top: -4rem;
  z-index: 30;
  background: var(--paper);
  color: var(--ink);
  padding: 0.5rem 1rem;
  font-weight: 700;
}
.skip:focus { top: 0.5rem; }

.wrap {
  width: min(var(--max), calc(100% - 2rem));
  margin-inline: auto;
}

.promo {
  background: var(--blue-dark);
  color: #fff;
  text-align: center;
  font-size: 0.875rem;
  font-weight: 700;
  padding: 0.4rem 0.75rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  padding: 0.7rem 1rem;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--gray-200);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-right: auto;
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
  letter-spacing: -0.02em;
}
.logo:hover { color: var(--ink); }
.logo-mark { width: 32px; height: 32px; flex: none; }

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.15rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 44px;
  padding: 0.2rem 0.7rem;
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  border-bottom-color: var(--brand);
  color: var(--ink);
}

.count[hidden] {
  display: none;
}

.count {
  display: inline-grid;
  place-items: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: var(--brand);
  color: var(--ink);
  font-size: 0.72rem;
  letter-spacing: 0;
}

.header-tools { display: flex; align-items: center; gap: 0.6rem; }

.button,
.shop-now,
.product-card button,
.cart-panel button[data-checkout] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.55rem 1.15rem;
  border: 0;
  border-radius: 1.5rem;
  background: var(--brand);
  color: var(--ink);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(16, 24, 40, 0.12);
}

.button:hover { background: var(--brand-light); color: var(--ink); }
.button-small { min-height: 40px; padding: 0.4rem 0.9rem; }

.shop-now,
.product-card button { background: var(--gray-800); color: #fff; }
.shop-now:hover,
.product-card button:hover { background: var(--gray-900); color: #fff; }

.text-link { font-weight: 700; text-underline-offset: 0.2em; }

.hero {
  background: var(--blush);
  border-bottom: 1px solid var(--gray-200);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1rem;
  align-items: center;
  padding: 1.25rem 0 1.5rem;
}

.eyebrow {
  margin: 0 0 0.35rem;
  color: var(--brand);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.lede, .section-lead { max-width: 38rem; color: var(--gray-700); font-size: 1.05rem; }
.fine { color: var(--gray-700); font-size: 0.95rem; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.9rem 1.1rem;
  margin-top: 1rem;
}

.hero-visual { position: relative; width: min(440px, 100%); margin-inline: auto; }
.hero-art { display: block; width: 62%; height: auto; flex: 1 1 auto; min-width: 0; }

.yarn-tag {
  position: absolute;
  left: 0;
  bottom: 8%;
  margin: 0;
  padding: 0.45rem 0.7rem;
  background: #fff;
  border: 1px solid var(--gray-200);
  border-radius: 12px;
  box-shadow: 0 8px 18px rgba(16, 24, 40, 0.08);
}
.yarn-tag span, .yarn-tag strong { display: block; }
.yarn-tag span {
  color: var(--blue-dark);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tiles {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.8rem;
  margin: 1.25rem auto 0;
}

.tile {
  display: flex;
  align-items: center;
  min-height: 132px;
  padding: 1.1rem 1.2rem;
  text-decoration: none;
  color: var(--ink);
  background: var(--peach);
}
.tile:nth-child(2) { background: var(--blue-light); }
.tile:nth-child(3) { background: #e3d9ff; }
.tile strong { display: block; font-size: 1.25rem; font-weight: 700; }
.tile span {
  display: inline-flex;
  margin-top: 0.35rem;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: underline;
  text-underline-offset: 0.25em;
}

.section { padding: 2.4rem 0; }
.section-alt { background: #f9fafb; border-block: 1px solid var(--gray-200); }

.feature-grid, .steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.8rem;
  margin: 1.1rem 0 0;
  padding: 0;
  list-style: none;
}

.card, .steps li, .stitch-card, .product-card, .cart-panel {
  background: #fff;
  border: 1px solid var(--gray-200);
  padding: 1rem;
}
.card p:last-child, .steps p:last-child { margin-bottom: 0; color: var(--gray-700); }
.icon { width: 36px; height: 36px; margin-bottom: 0.55rem; }

.step-num {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  margin-bottom: 0.6rem;
  background: var(--blue-dark);
  color: #fff;
  font-weight: 800;
}

.stitch-layout, .preview-layout {
  display: grid;
  gap: 1.25rem;
  align-items: center;
}

.stitch-top { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }
.stitch-abbr { margin: 0; font-size: 2.4rem; font-weight: 750; color: var(--brand); line-height: 1; }
.stitch-abbr abbr { text-decoration: none; }
.stitch-diagram { width: 140px; }
.term-row { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.term-row span { background: var(--blush); border-radius: 999px; padding: 0.15rem 0.6rem; font-size: 0.92rem; }
.stitch-steps, .plain-list { margin: 0.4rem 0 0; padding-left: 1.1rem; color: var(--gray-700); }

.phone {
  width: min(300px, 100%);
  margin-inline: auto;
  padding: 12px;
  border-radius: 32px;
  background: #101828;
}
.phone-screen {
  border-radius: 22px;
  background: #1e2939;
  color: #fff;
  padding: 0.35rem 0.9rem 0.95rem;
}
.phone-screen::before {
  content: "";
  display: block;
  width: 88px;
  height: 14px;
  margin: 0 auto 0.65rem;
  background: #101828;
  border-radius: 0 0 10px 10px;
}
.app-kicker, .check-label {
  margin: 0;
  color: #bacdf4;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.app-project { margin: 0.1rem 0 0; font-size: 1.45rem; font-weight: 700; }
.device-figure figcaption { color: var(--gray-500); }
.phone-screen .app-meta { color: #bacdf4; margin: 0.1rem 0 0.7rem; }
.app-step { font-size: 1.2rem; font-weight: 700; }
.app-chip { display: inline-flex; gap: 0.4rem; align-items: center; }
.app-chip span, .app-next { background: var(--brand); color: var(--ink); font-weight: 800; }
.app-chip span, .round-btn, .app-back, .app-next {
  display: grid;
  place-items: center;
  min-width: 2rem;
  min-height: 44px;
  border-radius: 12px;
}
.round-btn { width: 44px; background: #f3a795; color: var(--ink); font-size: 1.3rem; }
.app-counter, .app-actions, .counter-row { display: flex; align-items: center; gap: 0.5rem; }
.app-counter, .checkpoint { margin-bottom: 0.7rem; }
.app-actions { display: grid; grid-template-columns: 1fr 1.4fr; }
.app-back { color: #fff; border: 2px solid #bacdf4; }
.checkpoint { padding: 0.55rem 0.7rem; border: 1px solid #bacdf4; }

.faq-wrap { max-width: 760px; }
.faq-list { display: grid; gap: 0.6rem; margin-top: 1rem; }
.faq-list details { border: 1px solid var(--gray-200); padding: 0.75rem 0.9rem; background: #fff; }
.faq-list summary { cursor: pointer; font-weight: 700; min-height: 44px; display: flex; align-items: center; }
.faq-list details p { margin: 0.6rem 0 0; color: var(--gray-700); }

.page-intro { padding: 1.6rem 0 0.4rem; }
.note { color: var(--gray-700); max-width: 42rem; }

.product-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
  margin: 1rem 0 1.5rem;
}
.product-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0.9rem 0.8rem 1rem;
}
.product-card h3 { margin-top: 0.8rem; color: var(--gray-700); font-size: 0.95rem; }
.sample-flag {
  align-self: flex-start;
  margin: 0 0 0.4rem;
  padding: 0.1rem 0.45rem;
  background: var(--blush);
  color: var(--ink);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.photo-link { display: block; width: 100%; text-decoration: none; }
.photo-box {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: var(--blush);
  overflow: hidden;
}
.photo-box img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: transparent;
}
.hero-visual { display: flex; align-items: center; gap: 0.6rem; }
.hero-hook {
  display: block;
  flex: 0 0 34%;
  aspect-ratio: 3 / 4;
  background: #f7d4be;
  overflow: hidden;
}
.hero-hook img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.price { margin: 0.25rem 0; color: var(--gray-500); font-size: 0.95rem; }
.meta, .network { color: var(--gray-700); font-size: 0.9rem; }
.product-card .shop-now, .product-card button { margin-top: auto; }
.amazon-link {
  display: inline-block;
  margin-top: 0.55rem;
  font-size: 0.85rem;
  font-weight: 700;
  text-underline-offset: 0.18em;
}

.cart-panel { margin: 0 0 2rem; }
.cart-panel h2 { font-size: 1.3rem; }
.cart-lines { list-style: none; margin: 0 0 0.8rem; padding: 0; display: grid; gap: 0.55rem; }
.cart-lines li, .qty { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; flex-wrap: wrap; }
.cart-lines li > span:first-child { flex: 1 1 10rem; }
.qty button {
  width: 44px;
  height: 44px;
  border: 1px solid var(--gray-200);
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.cart-total { font-weight: 700; }
.cart-panel button[data-checkout]:disabled { opacity: 0.45; cursor: not-allowed; }
.status { min-height: 1.4rem; margin: 0.7rem 0 0; font-weight: 700; }
.disclosure {
  background: var(--blush);
  border: 1px solid var(--brand-light);
  padding: 0.75rem 0.9rem;
  margin: 0.8rem 0 0;
}

.site-footer {
  margin-top: 2.5rem;
  background: var(--blue-dark);
  color: #fff;
  padding: 2rem 0;
  font-size: 0.82rem;
  line-height: 1.55;
}
.site-footer a { color: #fff; }
.footer-grid { display: grid; gap: 1.2rem; }
.footer-brand { margin: 0 0 0.35rem; font-size: 1.2rem; font-weight: 750; }
.site-footer h2 {
  margin: 0 0 0.45rem;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li a {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
}
.site-footer li a:hover { text-decoration: underline; }
.privacy, .copyright { margin: 0; max-width: 38rem; }
.missing { padding: 3.5rem 0 4rem; }

@media (min-width: 700px) {
  .tiles, .feature-grid { grid-template-columns: repeat(3, 1fr); }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(3, 1fr); }
  .hero-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); padding: 2rem 0 2.2rem; }
  .hero-visual { width: min(480px, 100%); }
  .stitch-layout, .preview-layout { grid-template-columns: 1.1fr 0.9fr; }
  .footer-grid { grid-template-columns: 1.4fr 0.8fr auto; align-items: start; }
}

@media (min-width: 1000px) {
  .product-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 699px) {
  .site-header { display: grid; grid-template-columns: 1fr auto; }
  .site-nav { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

section, .cart-panel { scroll-margin-top: 7.5rem; }
