@font-face { font-family: Figtree; font-style: normal; font-weight: 400 800; font-display: swap; src: url('assets/fonts/figtree-latin.woff2') format('woff2'); }
@font-face { font-family: Fraunces; font-style: normal; font-weight: 600 900; font-display: swap; src: url('assets/fonts/fraunces-latin.woff2') format('woff2'); }

:root {
  color-scheme: light;
  --yolk: #fdb40c;
  --cream: #fff8e6;
  --cacau: #2c150c;
  --cacau-soft: #4a2a1d;
  --red: #d9231a;
  --red-deep: #a8160f;
  --white: #fff;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100svh;
  min-height: 100dvh;
  display: grid;
  align-items: center;
  background: var(--yolk);
  color: var(--cacau);
  font-family: Figtree, system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 18px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
h1, p { margin: 0; }
[hidden] { display: none !important; }
.presell {
  width: min(100%, 1200px);
  margin-inline: auto;
  padding: 48px 40px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas: 'copy cocoa' 'action cocoa';
  column-gap: clamp(32px, 6vw, 80px);
  align-content: center;
}
.presell__copy { grid-area: copy; align-self: end; }
.presell__eyebrow { margin-bottom: 24px; font-size: 16px; font-weight: 800; }
h1 {
  max-width: 10ch;
  font-family: Fraunces, Georgia, serif;
  font-weight: 800;
  font-size: clamp(46px, 4.8vw, 66px);
  line-height: 1.06;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
.presell__description { max-width: 32ch; margin-top: 20px; font-size: 20px; color: var(--cacau-soft); }
.presell__action { grid-area: action; align-self: start; margin-top: 36px; min-height: 108px; }
.progress__meta { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 12px; font-size: 16px; font-weight: 700; }
.progress__meta strong { font-variant-numeric: tabular-nums; }
.progress { height: 14px; overflow: hidden; border-radius: 7px; background: rgb(44 21 12 / 14%); }
.progress__fill { display: block; width: 100%; height: 100%; background: var(--cacau); transform: scaleX(0); transform-origin: left; transition: transform 110ms linear; border-radius: inherit; }
.presell__button {
  min-height: 64px;
  width: 100%;
  padding: 16px 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  border-radius: 999px;
  background: var(--red-deep);
  color: var(--white);
  font-size: 21px;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 5px 0 #7e100b;
  transition: transform 160ms ease, background-color 160ms ease;
}
.presell__button:hover { background: #96130d; transform: translateY(-2px); }
.presell__button:active { transform: translateY(2px); }
.presell__button:focus-visible { outline: 3px solid var(--cacau); outline-offset: 6px; }
.presell__button span { font-size: 28px; line-height: 1; }
.presell__noscript { margin-top: 16px; }

/* Ilustração sem embalagem de marca. O movimento acompanha o carregamento. */
.cocoa { grid-area: cocoa; position: relative; width: 100%; aspect-ratio: 1; max-width: 480px; align-self: center; justify-self: center; isolation: isolate; }
.cocoa__halo { position: absolute; inset: 7%; background: var(--cream); border-radius: 50%; }
.cocoa__shadow { position: absolute; left: 27%; right: 20%; bottom: 10%; height: 7%; background: rgb(44 21 12 / 13%); border-radius: 50%; filter: blur(4px); }
.cocoa__float { position: absolute; inset: 11% 23% 13% 24%; }
.cocoa__bar {
  position: relative; height: 100%; padding: 7%; border-radius: 12px;
  transform: rotate(-15deg);
  background: #492619;
  box-shadow: 8px 9px 0 #2c150c, 16px 22px 20px rgb(44 21 12 / 17%), inset 2px 2px 0 #a76c42;
}
.cocoa__tiles { height: 100%; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(4, minmax(0, 1fr)); gap: 5%; }
.cocoa__tiles i { display: block; border: 1px solid #4a2719; border-radius: 6px; background: linear-gradient(135deg, #9b6040, #72412b 56%, #58301f); box-shadow: inset 3px 3px 0 rgb(236 179 127 / 30%), inset -4px -4px 0 rgb(44 21 12 / 30%), 1px 2px 1px #2c150c; }
.cocoa__wrapper { position: absolute; bottom: -4%; left: -7%; right: -7%; height: 43%; overflow: hidden; border-radius: 4px 4px 10px 10px; background: var(--cream); box-shadow: inset -10px 0 0 #e8dbbd, 2px 4px 0 rgb(44 21 12 / 10%); clip-path: polygon(0 0, 15% 5%, 34% 0, 55% 6%, 73% 0, 100% 5%, 100% 100%, 0 100%); }
.cocoa__wrapper::before { content: ''; position: absolute; inset: 28% 0 24%; background: var(--red); }
.cocoa__wrapper span { position: absolute; inset: 0 70% 0 13%; background: rgb(255 255 255 / 17%); transform: skewX(-7deg); }
.cocoa__piece { position: absolute; width: 9%; aspect-ratio: 1; background: #77442c; border: 3px solid #4a2719; border-radius: 4px; box-shadow: inset 2px 2px 0 #bc865b, 3px 3px 0 var(--cacau); }
.cocoa__piece--one { left: 12%; top: 27%; transform: rotate(20deg); }
.cocoa__piece--two { right: 11%; top: 39%; width: 7%; transform: rotate(-22deg); }
.cocoa__piece--three { left: 18%; bottom: 18%; width: 6%; transform: rotate(-12deg); }
.cocoa__ready { display: none; position: absolute; right: 6%; bottom: 12%; width: 22%; aspect-ratio: 1; place-items: center; background: var(--cacau); border: 5px solid var(--yolk); border-radius: 50%; }
.cocoa__ready span { display: block; width: 38%; height: 23%; margin-top: -8%; border-left: 4px solid var(--cream); border-bottom: 4px solid var(--cream); transform: rotate(-45deg); }
body[data-state='ready'] .cocoa__ready { display: grid; }

@media (prefers-reduced-motion: no-preference) {
  body[data-state='loading'] .cocoa__float { animation: cocoa-float 3s ease-in-out infinite; }
  body[data-state='loading'] .cocoa__piece { animation: cocoa-piece 3s ease-in-out infinite; }
  body[data-state='loading'] .cocoa__piece--two { animation-delay: -1s; }
  body[data-state='loading'] .cocoa__piece--three { animation-delay: -2s; }
  @keyframes cocoa-float { 50% { transform: translateY(-10px) rotate(2deg); } }
  @keyframes cocoa-piece { 50% { translate: 0 -7px; } }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
@media (max-width: 767px) {
  .presell { max-width: 480px; padding: 28px 24px; grid-template-columns: minmax(0, 1fr); grid-template-areas: 'copy' 'cocoa' 'action'; text-align: center; }
  .presell__eyebrow { margin-bottom: 14px; font-size: 14px; }
  h1 { max-width: 11ch; margin-inline: auto; font-size: clamp(36px, 9.6vw, 46px); }
  .presell__description { margin: 14px auto 0; font-size: 18px; max-width: 28ch; }
  .cocoa { width: min(100%, 284px); margin-top: 10px; }
  .presell__action { margin-top: 16px; min-height: 100px; text-align: left; }
  .presell__button { font-size: 20px; min-height: 60px; }
}
@media (max-height: 650px) and (max-width: 767px) {
  .presell { padding-block: 20px; }
  .cocoa { width: min(58vw, 220px); }
  .presell__eyebrow { margin-bottom: 10px; }
  .presell__action { margin-top: 8px; }
}
