/* v10 Comic Book: the cover, the chapter pages, the end-of-chapter pages, the reveal panel, the sealed next issue. */

/* ================= COVER ================= */
.cover { gap: 10px; padding-bottom: calc(var(--safe-b) + 18px); height: 100%; min-height: 0; }
.cover__mast { display: flex; align-items: stretch; gap: 10px; padding-right: 54px; animation: drop .5s cubic-bezier(.2, 1.4, .4, 1) both; }
@keyframes drop { 0% { transform: translateY(-40px); opacity: 0; } 100% { opacity: 1; } }
.cover__issue {
  flex: none; display: grid; place-content: center; text-align: center; width: 58px;
  background: var(--ink); color: var(--yellow); border: var(--line) solid var(--ink);
  font: 800 12px/1 var(--f-title); font-stretch: condensed; letter-spacing: .06em;
}
.cover__issue b { font-size: 26px; color: var(--white); }
.cover__title {
  margin: 0; flex: 1; display: flex; flex-direction: column; justify-content: center;
  font: 800 56px/0.82 var(--f-title); font-stretch: condensed; text-transform: uppercase; letter-spacing: .01em;
  color: var(--red); -webkit-text-stroke: 2px var(--ink); text-shadow: 4px 4px 0 var(--ink);
  transform: rotate(-2deg); transform-origin: left;
}
.cover__title small { font-size: 21px; color: var(--ink); -webkit-text-stroke: 0; text-shadow: none; letter-spacing: .2em; }
.cover__art {
  position: relative; flex: 1; min-height: 300px;
  border: 5px solid var(--ink); box-shadow: var(--shadow);
  background: transparent;
  animation: slam .55s .12s cubic-bezier(.2, 1.5, .4, 1) both;
}
@keyframes slam { 0% { transform: scale(1.12) rotate(1.5deg); opacity: 0; } 100% { opacity: 1; } }
.cover__fallback {
  position: absolute; inset: 0; overflow: hidden;
  background: radial-gradient(120% 80% at 50% 110%, #3cb54a 0 38%, #2a8f3a 39% 60%, var(--cyan) 61%);
  transition: opacity .9s;
}
.cover__fallback svg { position: absolute; inset: -20%; width: 140%; height: 140%; animation: spin 40s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.cover__art.is-live .cover__fallback { opacity: 0; }
.cover__art .halftone { opacity: .55; }
.cover__cap1 { position: absolute; left: -6px; top: 14px; max-width: 70%; transform: rotate(-2deg); animation: pop .4s .5s cubic-bezier(.3, 1.6, .5, 1) both; }
.bubble--cover {
  position: absolute; right: 12px; top: 33%; max-width: 62%;
  font-size: 18px; animation: pop .45s .8s cubic-bezier(.3, 1.6, .5, 1) both, float 3.5s 1.4s ease-in-out infinite;
}
.bubble--cover::before { left: auto; right: 34px; bottom: -19px; border-width: 19px 0 0 14px; border-color: var(--ink) transparent transparent; content: ''; position: absolute; border-style: solid; }
.bubble--cover::after { left: auto; right: 38.5px; bottom: -12px; border-width: 13px 0 0 9px; border-color: var(--white) transparent transparent; content: ''; position: absolute; border-style: solid; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
.cover__burst {
  position: absolute; left: 10px; bottom: 54px; width: 96px; height: 96px;
  display: grid; place-items: center; transform: rotate(-12deg);
  animation: burstIn .5s 1.05s cubic-bezier(.3, 1.8, .5, 1) both;
}
.cover__burst .burst-svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.cover__burst b { position: relative; font: 800 25px/0.85 var(--f-title); font-stretch: condensed; color: var(--yellow); text-align: center; -webkit-text-stroke: 1px var(--ink); text-shadow: 2px 2px 0 var(--ink); }
@keyframes burstIn { 0% { transform: scale(0) rotate(-60deg); } 100% { transform: rotate(-12deg); } }
.cover__cap2 { position: absolute; right: -6px; bottom: 14px; transform: rotate(1.5deg); animation: pop .4s 1.3s cubic-bezier(.3, 1.6, .5, 1) both; }
.cover__cast {
  margin: 0; text-align: center;
  font: 700 12.5px/1.35 var(--f-letter); text-transform: uppercase; letter-spacing: .02em;
}
.cover__cast b { color: var(--red); font-size: 15px; }
.cover__go:disabled {
  background: repeating-linear-gradient(-45deg, var(--grey) 0 14px, #cfc8b6 14px 28px);
  background-size: 40px 40px; color: var(--ink); text-shadow: none; font-size: 22px;
  animation: pop .42s .18s cubic-bezier(.3, 1.6, .5, 1) both, press 1s linear infinite;
}
@keyframes press { to { background-position: 40px 0; } }
.cover__go.is-ready { animation: ready .5s cubic-bezier(.3, 1.8, .5, 1) both; }
@keyframes ready { 0% { transform: scale(.9); } 60% { transform: scale(1.04) rotate(-1deg); } 100% { transform: none; } }
.cover__fail { margin: 0; text-align: center; font: 700 15px/1.4 var(--f-letter); text-transform: uppercase; background: var(--white); border: var(--line) solid var(--ink); padding: 12px; }

/* ================= CHAPTER (level page) ================= */
.chapter { justify-content: center; }
.chapter__hero { min-height: 132px; padding: 18px 16px 34px; background: var(--cyan); display: flex; flex-direction: column; gap: 14px; justify-content: center; animation: slam .5s .08s cubic-bezier(.2, 1.5, .4, 1) both; }
.chapter--scan .chapter__hero { background: var(--yellow); }
.chapter--press .chapter__hero { background: var(--red); }
.chapter__lines { position: absolute; inset: -30%; }
.chapter__lines svg { width: 100%; height: 100%; }
.chapter__title {
  position: relative; margin: 0;
  font: 800 46px/0.9 var(--f-title); font-stretch: condensed; text-transform: uppercase;
  color: var(--white); -webkit-text-stroke: 2px var(--ink); text-shadow: 4px 4px 0 var(--ink);
  transform: rotate(-1.5deg);
}
.chapter--scan .chapter__title { color: var(--red); }
.chapter__line { position: relative; align-self: flex-start; max-width: 90%; animation: pop .45s .45s cubic-bezier(.3, 1.6, .5, 1) both; }
.chapter__how { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.how {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px;
  background: var(--white); border: var(--line) solid var(--ink); box-shadow: 3px 3px 0 var(--ink);
  padding: 10px 6px 8px; text-align: center;
  animation: pop .4s calc(.35s + var(--i) * .14s) cubic-bezier(.3, 1.6, .5, 1) both;
}
.how__n { position: absolute; left: -3px; top: -3px; width: 22px; height: 22px; display: grid; place-items: center; background: var(--ink); color: var(--yellow); font: 800 14px/1 var(--f-title); }
.how__i { width: 50px; height: 50px; }
.how__i svg { width: 100%; height: 100%; }
.how__t { font: 700 11.5px/1.2 var(--f-letter); text-transform: uppercase; }
.chapter__vs { margin: 0; text-align: center; font: 700 15px/1.3 var(--f-letter); text-transform: uppercase; display: grid; gap: 2px; }
.chapter__vs b { color: var(--red); }
.chapter__vs .chapter__meta { font: 600 13px/1.2 var(--f-ui); text-transform: none; letter-spacing: .02em; opacity: .75; }
.chapter__rate { padding: 12px 12px 10px; background: var(--paper-2); animation: pop .45s .3s cubic-bezier(.3, 1.6, .5, 1) both; }
.chapter__ask { margin: 0 0 10px; text-align: center; font: 700 15px/1.25 var(--f-letter); text-transform: uppercase; }
.rate { display: grid; grid-template-columns: repeat(5, 1fr); gap: 7px; }
.rate__n {
  min-height: 50px; cursor: pointer;
  background: var(--white); border: 3px solid var(--ink); border-radius: 50%;
  box-shadow: 2px 2px 0 var(--ink);
  font: 800 24px/1 var(--f-title); font-stretch: condensed;
  transition: transform .1s, background .15s;
  animation: pop .3s calc(.45s + var(--i) * .03s) cubic-bezier(.3, 1.6, .5, 1) both;
}
.rate__n:active { transform: scale(.9); }
.rate__n.is-picked { background: var(--yellow); transform: scale(1.18) rotate(-6deg); box-shadow: 3px 3px 0 var(--ink); }
.rate.has-pick .rate__n:not(.is-picked) { opacity: .35; }
.rate__hint { margin: 9px 0 0; display: flex; justify-content: space-between; align-items: center; gap: 6px; font: 600 11.5px/1.2 var(--f-ui); }
.rate__hint b { font: 700 13px/1.2 var(--f-letter); text-transform: uppercase; color: var(--red); text-align: center; }
.rate__hint span { opacity: .7; white-space: nowrap; }

/* ================= BETWEEN (end of chapter) ================= */
.between__title {
  margin: 4px 0 0; font: 800 40px/0.92 var(--f-title); font-stretch: condensed; text-transform: uppercase;
  color: var(--red); -webkit-text-stroke: 1.5px var(--ink); text-shadow: 3px 3px 0 var(--ink);
  animation: pop .45s .1s cubic-bezier(.3, 1.6, .5, 1) both;
}
.between__sub { margin: -4px 0 0; font: 700 14px/1.3 var(--f-letter); text-transform: uppercase; }
.between__panels { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pp { position: relative; margin: 0; background: var(--white); border: var(--line) solid var(--ink); box-shadow: 4px 4px 0 var(--ink); animation: slam .5s calc(.25s + var(--i) * .2s) cubic-bezier(.2, 1.5, .4, 1) both; }
.pp:nth-child(odd) { transform: rotate(-1deg); }
.pp:nth-child(even) { transform: rotate(1deg); }
.pp__img { position: relative; aspect-ratio: 16 / 10; overflow: hidden; border-bottom: var(--line) solid var(--ink); background: var(--ink); }
.pp__img img { width: 100%; height: 100%; object-fit: cover; filter: saturate(1.5) contrast(1.15); }
.pp--grey .pp__img img { filter: grayscale(1) contrast(1.2) brightness(1.05); }
.pp__img .halftone { opacity: .7; }
.pp__stamp {
  position: absolute; right: -6px; top: 8px; z-index: 1;
  padding: 3px 9px 2px; transform: rotate(8deg);
  background: var(--yellow); border: 3px solid var(--ink); box-shadow: 2px 2px 0 var(--ink);
  font: 800 21px/1 var(--f-title); font-stretch: condensed; color: var(--red); -webkit-text-stroke: .6px var(--ink);
  animation: stamp .35s calc(.6s + var(--i) * .2s) cubic-bezier(.3, 1.8, .5, 1) both;
}
.pp--cyan .pp__stamp { background: var(--cyan); color: var(--white); }
.pp--grey .pp__stamp { background: var(--white); color: var(--ink); }
@keyframes stamp { 0% { transform: scale(2.2) rotate(-10deg); opacity: 0; } 100% { transform: rotate(8deg); opacity: 1; } }
.pp figcaption { padding: 7px 8px 8px; display: grid; gap: 2px; }
.pp figcaption b { font: 700 12.5px/1.2 var(--f-letter); text-transform: uppercase; }
.pp figcaption span { font: 600 12.5px/1.2 var(--f-ui); }
.between__progress { display: grid; gap: 6px; }
.between__progress p { margin: 0; font: 600 13.5px/1.3 var(--f-ui); }
.sqs { display: flex; gap: 6px; }
.sq {
  flex: 1; height: 30px; display: grid; place-items: center; font-style: normal;
  border: 3px solid var(--ink); background: var(--white); font: 800 15px/1 var(--f-title); color: rgba(0, 0, 0, .35);
  animation: pop .3s calc(.7s + var(--i) * .06s) cubic-bezier(.3, 1.6, .5, 1) both;
}
.sq.is-hit { background: var(--yellow); color: var(--red); }
.sq.is-miss { background: var(--grey); }
.between__next { padding: 12px 14px; background: var(--ink); color: var(--white); animation: pop .45s .9s cubic-bezier(.3, 1.6, .5, 1) both; }
.between__tbc { margin: 0; font: 800 15px/1 var(--f-title); font-stretch: condensed; letter-spacing: .12em; text-transform: uppercase; color: var(--yellow); }
.between__tt { margin: 6px 0 2px; font: 800 26px/1 var(--f-title); font-stretch: condensed; text-transform: uppercase; }
.between__tl { margin: 0; font: 600 14.5px/1.35 var(--f-ui); opacity: .9; }
.between .btn--go { margin-top: auto; }

/* ================= REVEAL (the real clip) ================= */
.reveal { gap: 12px; }
.reveal__slot {
  position: relative; width: 100%; aspect-ratio: 16 / 9; flex: none;
  border: 5px solid var(--ink); box-shadow: var(--shadow);
  background: transparent;
}
.reveal__live {
  position: absolute; left: 8px; top: 8px; z-index: 1;
  padding: 3px 8px; background: var(--red); color: var(--white); border: 2px solid var(--ink);
  font: 800 12px/1 var(--f-title); letter-spacing: .1em; text-transform: uppercase;
}
.reveal__stamp {
  position: absolute; right: -10px; bottom: -16px; z-index: 1;
  padding: 4px 12px 3px; transform: rotate(-6deg);
  background: var(--yellow); border: var(--line) solid var(--ink); box-shadow: 3px 3px 0 var(--ink);
  font: 800 30px/1 var(--f-title); font-stretch: condensed; color: var(--red); -webkit-text-stroke: .8px var(--ink);
  animation: stamp2 .4s .25s cubic-bezier(.3, 1.8, .5, 1) both;
}
.reveal__stamp--cyan { background: var(--cyan); color: var(--white); }
.reveal__stamp--grey { background: var(--white); color: var(--ink); }
@keyframes stamp2 { 0% { transform: scale(2.2) rotate(10deg); opacity: 0; } 100% { transform: rotate(-6deg); opacity: 1; } }
.reveal__slot.is-ended { animation: none; }
.reveal__saw { align-self: stretch; justify-self: stretch; text-transform: none; font-size: 14.5px; line-height: 1.35; animation: pop .4s .2s cubic-bezier(.3, 1.6, .5, 1) both; }
.reveal__times { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 10px; }
.reveal__t { display: grid; gap: 1px; text-align: center; padding: 8px 10px; animation: pop .4s .3s cubic-bezier(.3, 1.6, .5, 1) both; }
.reveal__t--pro { animation-delay: .42s; background: var(--yellow); }
.reveal__t--pro::after { border-top-color: var(--yellow); }
.reveal__t small { font-size: 12.5px; }
.reveal__t b { font: 800 34px/1 var(--f-title); font-stretch: condensed; }
.reveal__pick { margin: 0; display: grid; gap: 2px; font: 600 14px/1.3 var(--f-ui); }
.reveal__pick b { font-weight: 800; }
.reveal__pick span + span { opacity: .7; }
.reveal__next { margin-top: auto; display: grid; gap: 10px; padding: 12px; background: var(--ink); color: var(--white); border: var(--line) solid var(--ink); box-shadow: 4px 4px 0 rgba(0,0,0,.25); animation: pop .4s .5s cubic-bezier(.3, 1.6, .5, 1) both; }
.reveal__next .sq { height: 26px; font-size: 13px; animation: none; }
.reveal__up { margin: 0; display: grid; gap: 2px; }
.reveal__up small { font: 800 13px/1 var(--f-title); letter-spacing: .12em; text-transform: uppercase; color: var(--yellow); }
.reveal__up b { font: 800 26px/1 var(--f-title); font-stretch: condensed; text-transform: uppercase; }
.reveal__up span { font: 600 13.5px/1.25 var(--f-ui); opacity: .85; }
.reveal .btn--go { margin-top: 2px; }

/* ================= GATE (the sealed next issue) ================= */
.gate__bag {
  position: relative; align-self: center; width: min(78%, 300px); aspect-ratio: 3 / 3.3;
  transform: rotate(-3deg); animation: slam .55s .1s cubic-bezier(.2, 1.5, .4, 1) both;
}
.gate__comic {
  position: absolute; inset: 0; padding: 12px; display: flex; flex-direction: column; align-items: center; gap: 4px;
  background: var(--cyan); border: 4px solid var(--ink); box-shadow: var(--shadow);
  filter: blur(13px) saturate(1.1); transition: filter .6s;
}
.gate__mast { margin: 0; font: 800 26px/1 var(--f-title); font-stretch: condensed; color: var(--yellow); -webkit-text-stroke: 1px var(--ink); }
.gate__score { display: flex; align-items: baseline; font: 800 96px/0.9 var(--f-title); font-stretch: condensed; color: var(--white); text-shadow: 4px 4px 0 var(--ink); }
.gate__score small { font-size: 34px; }
.gate__rank { margin: 0; padding: 2px 10px; background: var(--red); color: var(--white); font: 800 24px/1.1 var(--f-title); font-stretch: condensed; text-transform: uppercase; }
.gate__minis { margin-top: auto; width: 100%; display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.gate__minis i { height: 26px; background: var(--white); border: 2px solid var(--ink); }
.gate__sheen {
  position: absolute; inset: -6px; border-radius: 4px;
  background: linear-gradient(115deg, rgba(255, 255, 255, .55) 0 12%, rgba(255, 255, 255, .08) 22% 58%, rgba(255, 255, 255, .45) 66%, rgba(255, 255, 255, .05) 78%);
  border: 2px solid rgba(255, 255, 255, .9); box-shadow: inset 0 0 0 2px rgba(0, 0, 0, .12);
  transition: opacity .5s, transform .6s;
}
.gate__sticker {
  position: absolute; right: -24px; top: -20px; width: 112px; height: 112px;
  display: grid; place-items: center; transform: rotate(14deg);
  animation: burstIn2 .5s .55s cubic-bezier(.3, 1.8, .5, 1) both;
}
@keyframes burstIn2 { 0% { transform: scale(0) rotate(-50deg); } 100% { transform: rotate(14deg); } }
.gate__sticker .burst-svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.gate__sticker b { position: relative; text-align: center; font: 800 18px/0.95 var(--f-title); font-stretch: condensed; color: var(--red); }
.gate__bag.is-open .gate__comic { filter: none; }
.gate__bag.is-open .gate__sheen { opacity: 0; transform: translateY(-30px) rotate(-4deg); }
.gate__bag.is-open .gate__sticker { transition: transform .4s; transform: scale(0) rotate(90deg); }
.gate__form { padding: 30px 14px 14px; display: flex; flex-direction: column; gap: 4px; overflow: visible; background: var(--paper-2); }
.gate__form.is-shake { animation: shake .4s; }
@keyframes shake { 20%, 60% { transform: translateX(-7px); } 40%, 80% { transform: translateX(7px); } }
.gate__ask { margin: -48px 0 14px; align-self: flex-start; max-width: 96%; animation: pop .45s .4s cubic-bezier(.3, 1.6, .5, 1) both; }
.field { display: grid; gap: 4px; }
.field span { font: 700 13px/1 var(--f-letter); text-transform: uppercase; }
.field input {
  width: 100%; min-height: 52px; padding: 12px 14px;
  font: 600 18px/1.2 var(--f-ui); color: var(--ink);
  background: var(--white); border: var(--line) solid var(--ink); border-radius: 4px; box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .08);
}
.field input:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px var(--ink); }
.field input.is-bad { border-color: var(--red); background: #fff1ef; }
.err { margin: 0 0 6px; min-height: 18px; font: 700 13px/1.3 var(--f-ui); color: var(--red-dk); }
.err:not(:empty)::before { content: '! '; font-weight: 800; }
.gate__small { margin: 8px 0 0; text-align: center; font: 600 12.5px/1.3 var(--f-ui); opacity: .7; }
.gate__form .btn--go { margin-top: 4px; }

/* ================= laptop ================= */
@media (min-width: 900px) {
  .cover { display: grid; grid-template-columns: 1.15fr 1fr; grid-template-rows: 1fr auto auto auto auto 1fr; column-gap: 40px; row-gap: 18px; height: 100%; }
  .cover__art { grid-column: 1; grid-row: 1 / 7; min-height: 0; }
  .cover__mast { grid-column: 2; grid-row: 2; padding-right: 0; }
  .cover__title { font-size: 104px; }
  .cover__title small { font-size: 30px; }
  .cover__issue { width: 84px; }
  .cover__issue b { font-size: 38px; }
  .cover::after {
    content: 'Play 6 real pro moments through their eyes. Get your score out of 10.';
    grid-column: 2; grid-row: 3;
    font: 700 24px/1.3 var(--f-letter); text-transform: uppercase;
    background: var(--white); border: var(--line) solid var(--ink); box-shadow: var(--shadow); padding: 18px 22px;
    animation: pop .45s .5s cubic-bezier(.3, 1.6, .5, 1) both;
  }
  .cover__cast { grid-column: 2; grid-row: 4; text-align: left; font-size: 15px; }
  .cover__go, .cover__fail { grid-column: 2; grid-row: 5; }
  .bubble--cover { font-size: 24px; max-width: 46%; }
  .cover__burst { width: 140px; height: 140px; }
  .cover__burst b { font-size: 36px; }

  .chapter { display: grid; grid-template-columns: 1.2fr 1fr; grid-template-rows: auto auto auto; gap: 18px 30px; align-content: center; }
  .chapter__how { align-self: start; }
  .chapter > .cap--top { grid-column: 1 / -1; }
  .chapter__hero { grid-column: 1; grid-row: 2; min-height: 230px; }
  .chapter__title { font-size: 76px; }
  .chapter__how { grid-column: 1; grid-row: 3; }
  .how__i { width: 70px; height: 70px; }
  .how__t { font-size: 14px; }
  .chapter__vs { grid-column: 2; grid-row: 2; align-self: center; font-size: 26px; text-align: left; gap: 8px; }
  .chapter__vs .chapter__meta { font-size: 17px; }
  .chapter__rate { grid-column: 2; grid-row: 3; padding: 18px; align-self: start; }
  .chapter__ask { font-size: 18px; }
  .rate__n { min-height: 60px; font-size: 28px; }

  .between { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px 30px; align-content: center; }
  .between > .cap--top, .between__title, .between__sub { grid-column: 1 / -1; }
  .between__title { font-size: 56px; }
  .between__panels { grid-column: 1; grid-row: 4 / 7; }
  .between__progress { grid-column: 2; grid-row: 4; }
  .between__next { grid-column: 2; grid-row: 5; }
  .between .btn--go { grid-column: 2; grid-row: 6; margin-top: 0; align-self: start; }

  .reveal { display: grid; grid-template-columns: 1.7fr 1fr; grid-template-rows: auto auto auto auto auto auto; gap: 16px 30px; align-content: center; }
  .reveal > .cap--top { grid-column: 1 / -1; }
  .reveal__slot { grid-column: 1; grid-row: 2 / 6; align-self: start; }
  .reveal__saw { grid-column: 2; grid-row: 2; font-size: 17px; }
  .reveal__times { grid-column: 2; grid-row: 3; }
  .reveal__pick { grid-column: 2; grid-row: 4; font-size: 16px; }
  .reveal__next { grid-column: 2; grid-row: 5; margin-top: 6px; align-self: start; }
  .reveal .btn--go { grid-column: 2; grid-row: 6; align-self: start; margin-top: 0; }
  .reveal__slot { grid-row: 2 / 7; }

  .gate { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 60px; align-content: center; max-width: 1000px; }
  .gate > .cap--top { grid-column: 1 / -1; justify-self: start; }
  .gate__bag { grid-column: 1; width: min(100%, 380px); }
  .gate__form { grid-column: 2; align-self: center; }
}
