@font-face {
  font-family: "Bricolage Grotesque";
  src: url("fonts/bricolage.woff2") format("woff2");
  font-weight: 400 800;
  font-stretch: 75% 100%;
  font-display: swap;
}
@font-face {
  font-family: "Gochi Hand";
  src: url("fonts/gochi-hand.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

:root {
  --wall: #edede8;
  --wall-line: #dcdcd5;
  --yellow: #ffe04a;
  --paper: #fbfbf7;
  --ink: #1b1b19;
  --ink-2: #4a4a45;
  --biro: #1f46c8;
  --tape: rgba(226, 214, 180, 0.88);
  --edge: rgba(27, 27, 25, 0.14);

  --font: "Bricolage Grotesque", "Arial Narrow", system-ui, sans-serif;
  --hand: "Gochi Hand", "Comic Sans MS", cursive;

  --gutter: clamp(16px, 4vw, 40px);
  --space: clamp(56px, 8vw, 112px);

  color-scheme: light;
  accent-color: var(--biro);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--wall);
  color: var(--ink);
  font: 400 1.0625rem/1.5 var(--font);
  font-variant-numeric: tabular-nums;
  caret-color: var(--biro);
  overflow-x: clip;
}
::selection { background: var(--yellow); color: var(--ink); }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: 0.18em; text-decoration-thickness: 1.5px; }
h1, h2, h3 { margin: 0; font-weight: 800; font-stretch: 78%; line-height: 0.98; letter-spacing: -0.015em; text-wrap: balance; }
h2 { font-size: clamp(1.9rem, 1.5rem + 1.8vw, 2.7rem); }
p, ul, ol, dl { margin: 0; }
:focus-visible { outline: 2.5px solid var(--biro); outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { width: 100%; max-width: 1160px; margin-inline: auto; padding-inline: var(--gutter); }
.small { font-size: 0.92rem; color: var(--ink-2); }
.hand { font-family: var(--hand); color: var(--biro); font-weight: 400; letter-spacing: 0; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 10; padding: 10px 14px; background: var(--ink); color: var(--paper); }
.skip:focus { top: 12px; }

/* ---------- top ---------- */
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; }
.brand {
  display: inline-flex; align-items: center; min-height: 44px; padding: 4px 12px;
  background: var(--ink); color: var(--yellow); text-decoration: none;
  font-weight: 800; font-stretch: 78%; font-size: 1.15rem; letter-spacing: 0.01em; transform: rotate(-1.5deg); white-space: nowrap;
}
.top__nav { display: flex; gap: 2px; }
.top__nav a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 10px; text-decoration: none; font-weight: 500; color: var(--ink-2); }
@media (hover: hover) and (pointer: fine) { .top__nav a:hover { color: var(--ink); text-decoration: underline; } }
@media (max-width: 560px) { .top__nav .hide-s { display: none; } }
.top__nav a { white-space: nowrap; }

/* ---------- paper notices ---------- */
.notice { position: relative; transform: rotate(var(--tilt, -0.8deg)); }
.notice--white, .notice--sheet { background: var(--paper); padding: clamp(26px, 4vw, 40px); border-bottom: 1px solid var(--edge); }
.notice--sheet.is-yellow { background: var(--yellow); }
.notice--yellow .notice__body { background: var(--yellow); padding: clamp(28px, 5vw, 48px) clamp(22px, 4.5vw, 44px) clamp(22px, 3vw, 30px); }
.notice h2 { margin-bottom: 18px; }

/* masking tape: flat, slightly see-through */
.tape {
  position: absolute; top: -13px; z-index: 2; width: 92px; height: 26px; background: var(--tape);
  transform: rotate(var(--tape-r, -4deg));
}
.tape--l { left: 8%; --tape-r: -6deg; }
.tape--r { right: 8%; --tape-r: 5deg; }
.tape--c { left: 50%; margin-left: -46px; --tape-r: 2deg; }

/* ---------- hero notice ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(48px, 7vw, 64px); padding-top: 18px; padding-bottom: var(--space); }
.notice--main { --tilt: -1deg; max-width: 600px; }
.notice--main h1 { font-size: clamp(2.7rem, 1.6rem + 5.4vw, 4.9rem); }
.promise { margin-top: 14px; font-size: clamp(1.35rem, 1.1rem + 1.2vw, 1.85rem); font-weight: 700; font-stretch: 85%; line-height: 1.1; }
.lines { list-style: none; padding: 0; margin-top: 20px; display: grid; gap: 8px; }
.lines li { padding-left: 22px; position: relative; max-width: 34ch; }
.lines li::before { content: ""; position: absolute; left: 2px; top: 0.62em; width: 10px; height: 2.5px; background: var(--ink); }
.lines__price { font-weight: 800; font-size: 1.25rem; }
.sign { margin-top: 18px; font-weight: 600; color: var(--ink-2); }
.sign .hand { font-size: 1.6rem; margin-right: 4px; }

/* tear-off tabs: perforated line, cuts between tabs, number written in biro */
.tabs {
  display: grid; grid-template-columns: repeat(7, minmax(0, 1fr));
  border-top: 2px dashed rgba(27, 27, 25, 0.55);
}
.tabs--short { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.tab {
  position: relative; display: block; min-height: 150px; min-width: 0;
  color: var(--biro); text-decoration: none;
}
/* the paper of each tab is the span, so it can fall away and leave a stub */
.tab span {
  position: absolute; inset: 0; display: grid; place-items: center;
  background: var(--yellow);
  /* the span is turned 180°: border-right draws the cut on the left, border-top draws the paper edge at the bottom */
  border-right: 1px solid rgba(27, 27, 25, 0.35); border-top: 1px solid var(--edge);
  writing-mode: vertical-rl; transform: rotate(180deg);
  font: 400 1.12rem/1 var(--hand); white-space: nowrap;
  transition: transform 160ms cubic-bezier(0.23, 1, 0.32, 1);
}
.tab:first-child span { border-right: 0; }
.tab:active span { transform: rotate(177deg); }
@media (hover: hover) and (pointer: fine) { .tab:hover span { transform: rotate(178deg); } }
.tab.is-torn { pointer-events: none; }
.tab.is-torn span {
  transform: translateY(70px) rotate(194deg); opacity: 0;
  transition: transform 460ms cubic-bezier(0.55, 0, 1, 0.45), opacity 460ms ease-in;
}
/* the ragged stub that stays under the perforation */
.tab.is-torn::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 9px; background: var(--yellow);
  clip-path: polygon(0 0, 100% 0, 100% 55%, 90% 100%, 79% 40%, 66% 85%, 53% 35%, 41% 95%, 28% 45%, 15% 90%, 0 50%);
}
.tab-note {
  margin-top: 14px; padding: 12px 14px; background: var(--paper); border-bottom: 1px solid var(--edge);
  font-size: 0.98rem; transform: rotate(0.8deg);
}
.tab-note a { color: var(--biro); font-weight: 600; }

/* ---------- demo flyers ---------- */
.flyers__title { font-size: clamp(1.7rem, 1.3rem + 1.4vw, 2.3rem); }
.flyers__lead { margin-top: 8px; color: var(--ink-2); }
.hand--note { font-size: 1.35rem; margin-left: 4px; display: inline-block; transform: rotate(-3deg); }
.flyers__row {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(64vw, 250px); gap: 22px;
  margin: 26px calc(var(--gutter) * -1) 0; padding: 18px var(--gutter) 22px;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter);
  scrollbar-width: none;
}
.flyers__row::-webkit-scrollbar { display: none; }
.flyer { position: relative; scroll-snap-align: start; background: var(--paper); padding: 10px 10px 14px; border-bottom: 1px solid var(--edge); transform: rotate(var(--tilt)); }
.flyer--a { --tilt: -1.6deg; }
.flyer--b { --tilt: 1.2deg; }
.flyer--c { --tilt: -0.6deg; }
.flyer--d { --tilt: 1.5deg; }
.flyer .tape { left: 50%; margin-left: -40px; width: 80px; --tape-r: -3deg; }
.flyer__shot { display: block; aspect-ratio: 480 / 700; overflow: hidden; background: var(--wall-line); }
.flyer__shot img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.flyer__text { padding: 12px 4px 0; display: grid; gap: 4px; }
.flyer h3 { font-size: 1.3rem; }
.flyer h3 a { text-decoration: none; }
.flyer h3 a svg { display: inline-block; vertical-align: -0.08em; margin-left: 4px; }
.flyer p { font-size: 0.92rem; color: var(--ink-2); line-height: 1.35; }
@media (hover: hover) and (pointer: fine) { .flyer h3 a:hover { text-decoration: underline; } }

@media (min-width: 960px) {
  .hero { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: start; gap: 56px; padding-top: 28px; }
  .flyers { padding-top: 34px; }
  .flyers__row { grid-auto-flow: row; grid-template-columns: repeat(2, 1fr); grid-auto-columns: auto; overflow: visible; margin: 26px 0 0; padding: 18px 0 0; gap: 30px 26px; }
  .flyer__shot { aspect-ratio: 480 / 470; }
  .flyer--a { position: relative; z-index: 3; }
}

/* ---------- board of sheets ---------- */
.board { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(44px, 6vw, 64px); padding-bottom: var(--space); }
.sheet-incluye { --tilt: 0.6deg; }
.sheet-precio { --tilt: -1.2deg; }
.sheet-como { --tilt: 0.9deg; }
.sheet-faq { --tilt: -0.4deg; }
@media (min-width: 900px) {
  .board {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    grid-template-areas: "inc pre" "inc como" "faq faq";
    align-items: start; column-gap: 56px;
  }
  .sheet-incluye { grid-area: inc; }
  .sheet-precio { grid-area: pre; }
  .sheet-como { grid-area: como; }
  .sheet-faq { grid-area: faq; max-width: 860px; justify-self: center; width: 100%; }
}

.checks { list-style: none; padding: 0; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 36px; max-width: 46ch; }
.checks li::before { content: ""; position: absolute; left: 0; top: 0.12em; width: 20px; height: 20px; border: 2px solid var(--ink); }
/* ticked by hand, in biro */
.checks li::after {
  content: ""; position: absolute; left: 6px; top: -0.02em; width: 9px; height: 17px;
  border: solid var(--biro); border-width: 0 3px 3px 0; transform: rotate(40deg);
}

.prices { display: grid; }
.prices div { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 2px dashed rgba(27, 27, 25, 0.35); }
.prices dt { font-weight: 500; }
.prices dd { margin: 0; font-weight: 800; font-stretch: 80%; font-size: 1.6rem; white-space: nowrap; }
.prices + .small { margin-top: 16px; color: var(--ink-2); }

.steps { list-style: none; padding: 0; counter-reset: s; display: grid; gap: 16px; }
.steps li { counter-increment: s; position: relative; padding-left: 48px; max-width: 48ch; }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: -0.08em;
  font-weight: 800; font-stretch: 75%; font-size: 2rem; line-height: 1;
}

.faq details { border-bottom: 2px dashed rgba(27, 27, 25, 0.3); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  min-height: 52px; padding: 12px 0; font-weight: 700; font-size: 1.08rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 14px; height: 14px;
  background: linear-gradient(var(--ink), var(--ink)) center / 14px 2.5px no-repeat, linear-gradient(var(--ink), var(--ink)) center / 2.5px 14px no-repeat;
  transition: transform 200ms cubic-bezier(0.23, 1, 0.32, 1);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 0 16px; max-width: 62ch; color: var(--ink-2); }

/* ---------- close ---------- */
.close { padding-bottom: var(--space); display: grid; justify-items: center; }
.notice--close { --tilt: 0.8deg; width: 100%; max-width: 520px; }
.notice--close h2 { margin-bottom: 10px; }

/* ---------- footer ---------- */
.foot { display: grid; gap: 8px; justify-items: center; text-align: center; padding-block: 28px 40px; border-top: 1px solid var(--wall-line); font-size: 0.95rem; }
.foot__links { display: flex; gap: 6px; }
.foot__links a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 8px; }

/* ---------- legal pages ---------- */
.legal { max-width: 46rem; padding-block: 24px var(--space); }
.legal .notice { --tilt: 0deg; }
.legal h1 { font-size: clamp(2.2rem, 1.8rem + 2vw, 3rem); margin-bottom: 16px; }
.legal h2 { font-size: 1.35rem; margin: 28px 0 8px; }
.legal ul { padding-left: 1.2em; }
.legal p + p { margin-top: 10px; }
.back { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; margin-bottom: 18px; font-weight: 600; }

@media (prefers-reduced-motion: reduce) {
  .tab span, .tab.is-torn span { transition: opacity 200ms ease; }
  .tab.is-torn span, .tab:active span, .tab:hover span { transform: rotate(180deg); }
}
