/* Campaign page — McDonald's x Nextory, ES.
 *
 * Every colour here is a semantic token from tokens.css. The two values this
 * file decides itself are corner radius and shadow, because the design system
 * names neither (skill-design: "Corner radius is the one thing this system
 * does not yet name ... say in the diff that you had to choose"). Both come
 * from the campaign brief: 24px pills, 12px cards, subtle shadows only.
 *
 * Breakpoints follow the design system's Bootstrap 5 scale (576 / 768 / 992),
 * not the brief's 640 / 768 / 1024, so that layout changes land on the same
 * widths as the type scale already baked into tokens.css.
 */

@font-face {
  font-family: "NextorySans";
  src: url("/assets/design/fonts/Nextory_Sans_WOFF2/NextorySans-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "NextorySans";
  src: url("/assets/design/fonts/Nextory_Sans_WOFF2/NextorySans-Italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "NextorySans";
  src: url("/assets/design/fonts/Nextory_Sans_WOFF2/NextorySans-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "NextorySans";
  src: url("/assets/design/fonts/Nextory_Sans_WOFF2/NextorySans-HeadlineDemiBold.woff2") format("woff2"); /* shift:allow-secret - a public font path the browser fetches, not a credential */
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --radius-pill: 24px;
  --radius-card: 12px;
  --radius-button: 8px;
  --shadow-subtle: 0 2px 8px rgba(0, 0, 0, 0.08);
  --veil-image-placeholder: rgba(0, 0, 0, 0.18);
  --rule-on-dark: rgba(255, 255, 255, 0.3);
  --shadow-lifted: 0 -2px 12px rgba(0, 0, 0, 0.12);
  --shadow-raised: 0 4px 14px rgba(0, 0, 0, 0.14);
  --sticky-bar-height: 88px;
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--backgroundLight);
  color: var(--contentPrimary);
  font-family: var(--font-family);
  font-size: var(--text-body1-size);
  line-height: var(--text-body1-line);
  letter-spacing: var(--text-body1-tracking);
  font-weight: var(--text-body1-weight);
}

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

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--contentAccent);
  outline-offset: 2px;
  border-radius: var(--space-1);
}

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: calc(-1 * var(--space-12));
  z-index: 20;
  padding: var(--space-3) var(--space-4);
  background: var(--backgroundTertiary);
  color: var(--contentPrimary);
  border-radius: var(--radius-pill);
  font-size: var(--text-button2-size);
  font-weight: var(--text-button2-weight);
  text-decoration: none;
  transition: top 120ms ease;
}

.skip-link:focus {
  top: var(--space-4);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.wrap {
  width: 100%;
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

@media (min-width: 992px) {
  .wrap {
    padding: 0 var(--space-8);
  }
}

.band {
  padding: var(--space-12) 0;
}

@media (min-width: 768px) {
  .band {
    padding: calc(var(--space-12) + var(--space-8)) 0;
  }
}

/* ---- 01 Co-branded header ------------------------------------------------ */

.cobrand {
  background: var(--backgroundPurpleDark);
}

/* The header and the hero both sit in .wrap, so the wordmark starts on the
 * same left edge as the hero copy and every band below, at every width. */
.cobrand__inner {
  display: flex;
  align-items: center;
  gap: var(--space-6);
  padding-block: var(--space-4);
}

.cobrand__logo {
  width: 120px;
  height: auto;
}

@media (min-width: 768px) {
  .cobrand__logo {
    width: 140px;
  }
}

.cobrand__partner {
  width: 40px;
  height: auto;
}

@media (min-width: 768px) {
  .cobrand__partner {
    width: 48px;
  }
}

.cobrand__divider {
  width: 1px;
  height: var(--space-8);
  background: var(--yellow500);
  flex: none;
}

/* ---- 02 Hero ------------------------------------------------------------- */

.hero {
  background: var(--backgroundPurpleDark);
  color: var(--white);
  padding-bottom: var(--space-12);
}

@media (min-width: 992px) {
  .hero {
    padding-bottom: 0;
  }
}

.hero__inner {
  display: grid;
  gap: var(--space-8);
  align-items: center;
}

/* The copy starts on .wrap's left edge like everything else, but the photo
 * still runs to the content cap on the right and both columns keep the widths
 * they had before the hero moved into .wrap - the headline holds three lines
 * and the photo is not shrunk. The 32px the copy moved in comes out of the
 * gap. */
@media (min-width: 992px) {
  .hero__inner {
    grid-template-columns: 40fr 60fr;
    gap: var(--space-4);
    padding-right: 0;
  }
}

.hero__copy {
  min-width: 0;
  padding: var(--space-12) 0 0;
}

@media (min-width: 992px) {
  .hero__copy {
    padding: var(--space-12) 0;
  }
}

.hero__kicker {
  margin: 0 0 var(--space-4);
  color: var(--yellow500);
  text-transform: uppercase;
  font-size: var(--text-meta1-size);
  line-height: var(--text-meta1-line);
  font-weight: var(--text-meta1-weight);
  letter-spacing: 1.6px;
}

.hero__headline {
  margin: 0 0 var(--space-6);
  color: var(--yellow500);
  font-size: var(--text-heading-big-1-size);
  line-height: var(--text-heading-big-1-line);
  letter-spacing: var(--text-heading-big-1-tracking);
  font-weight: var(--text-heading-big-1-weight);
}

.hero__lede {
  margin: 0 0 var(--space-8);
  max-width: 34em;
  color: var(--white);
  font-size: var(--text-preamble-size);
  line-height: var(--text-preamble-line);
  letter-spacing: var(--text-preamble-tracking);
  font-weight: var(--text-preamble-weight);
}

.hero__microcopy {
  margin: var(--space-4) 0 0;
  color: var(--contentOverBackgroundDark);
  font-size: var(--text-meta1-size);
  line-height: var(--text-meta1-line);
  font-weight: var(--text-meta1-weight);
}

.hero__media {
  position: relative;
  min-width: 0;
}

@media (min-width: 992px) {
  .hero__media {
    align-self: center;
    margin: var(--space-12) 0;
  }
}

.hero__frame {
  position: relative;
  width: 100%;
  min-width: 0;
  height: 380px;
  background-color: var(--backgroundPurpleDark);
}

@media (min-width: 992px) {
  .hero__frame {
    height: auto;
    aspect-ratio: 4 / 3;
  }
}

.hero__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  border-radius: var(--radius-card);
  color: var(--white);
  font-size: var(--text-meta1-size);
  line-height: var(--text-meta1-line);
}

@media (min-width: 768px) {
  .hero__photo {
    object-position: 55% 40%;
  }
}

.hero__badge {
  position: absolute;
  z-index: 1;
  margin: 0;
  top: 0;
  right: 0;
  transform: translate(18%, -20%);
  width: 88px;
  height: 88px;
  border-radius: 999px;
  background: var(--yellow500);
  color: var(--stickerInk);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

/* The sticker overhangs the photo's right edge only as far as the window has
 * room, so it never makes the page scroll sideways: 16px into .wrap's 24px
 * padding at 768-991, none where the photo runs to the window edge, and its
 * full 40% (54px) from 1280, where the cap leaves 70px each side. */
@media (min-width: 768px) {
  .hero__badge {
    width: 136px;
    height: 136px;
    transform: translate(var(--space-4), -40%);
  }
}

@media (min-width: 992px) {
  .hero__badge {
    transform: translate(0, -40%);
  }
}

@media (min-width: 1280px) {
  .hero__badge {
    transform: translate(40%, -40%);
  }
}

.hero__badge-line {
  font-size: 17px;
  line-height: 1.05;
  font-weight: var(--weight-headline);
}

@media (min-width: 768px) {
  .hero__badge-line {
    font-size: 22px;
  }
}

/* ---- Buttons ------------------------------------------------------------- */

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: var(--space-3) var(--space-8);
  border: none;
  border-radius: var(--radius-pill);
  background: var(--buttonCTABackground);
  color: var(--buttonCTAText);
  font-family: inherit;
  font-size: var(--text-button1-size);
  line-height: var(--text-button1-line);
  letter-spacing: var(--text-button1-tracking);
  font-weight: var(--text-button1-weight);
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow-subtle);
  transition: transform 120ms ease, filter 120ms ease;
}

.cta:hover {
  filter: brightness(0.94);
}

.cta:active {
  transform: translateY(1px);
}

.cta--block {
  display: flex;
  width: 100%;
}

.cta--squared {
  border-radius: var(--radius-button);
  gap: var(--space-2);
}

.cta__chevron {
  display: inline-flex;
  align-items: center;
}

.cta__chevron svg {
  width: var(--space-4);
  height: var(--space-4);
  fill: currentColor;
}

/* ---- 03 Marquee ---------------------------------------------------------- */

.marquee {
  background: var(--backgroundPink);
  color: var(--contentOverBackgroundPink);
  overflow: hidden;
  padding: var(--space-4) 0;
}

.marquee__track {
  display: flex;
  width: max-content;
  animation: marquee-scroll var(--marquee-duration, 192s) linear infinite;
}

.marquee__group {
  display: flex;
  flex: none;
  gap: var(--space-8);
  padding-right: var(--space-8);
}

.marquee__word {
  text-transform: uppercase;
  font-size: var(--text-subtitle-small-6-size);
  line-height: var(--text-subtitle-small-6-line);
  letter-spacing: 2px;
  font-weight: var(--weight-headline);
  white-space: nowrap;
}

@media (min-width: 768px) {
  .marquee__word {
    font-size: var(--text-subtitle-medium-4-size);
    line-height: var(--text-subtitle-medium-4-line);
  }
}

@keyframes marquee-scroll {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-50%, 0, 0);
  }
}

/* ---- 05 Book carousel ---------------------------------------------------- */

.shelf {
  background: var(--backgroundLight);
}

.shelf__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}

.shelf__title {
  margin: 0;
  font-size: var(--text-subtitle-big-2-size);
  line-height: var(--text-subtitle-big-2-line);
  letter-spacing: var(--text-subtitle-big-2-tracking);
  font-weight: var(--text-subtitle-big-2-weight);
}

.shelf__controls {
  display: none;
  gap: var(--space-2);
  flex: none;
}

@media (min-width: 992px) {
  .shelf__controls {
    display: flex;
  }
}

.shelf__arrow {
  width: var(--space-12);
  height: var(--space-12);
  border-radius: 999px;
  border: none;
  background: var(--backgroundTertiary);
  color: var(--contentPrimary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  box-shadow: var(--shadow-subtle);
  transition: background-color 150ms ease, box-shadow 150ms ease,
    transform 150ms ease;
}

.shelf__arrow:hover {
  background: var(--background);
  box-shadow: var(--shadow-raised);
}

.shelf__arrow:active {
  transform: scale(0.94);
}

.shelf__arrow:focus-visible {
  outline: 2px solid var(--contentAccent);
  outline-offset: 2px;
}

.shelf__arrow[disabled] {
  opacity: 0.35;
  box-shadow: none;
  cursor: default;
}

.shelf__arrow[disabled]:hover {
  background: var(--backgroundTertiary);
  box-shadow: none;
}

.shelf__arrow[disabled]:active {
  transform: none;
}

.shelf__arrow svg {
  width: var(--space-6);
  height: var(--space-6);
  fill: currentColor;
}

.shelf__arrow[data-carousel-prev] svg {
  transform: scaleX(-1);
}

.shelf {
  --shelf-inset: max(
    var(--space-6),
    calc((100vw - var(--content-width)) / 2 + var(--space-6))
  );
}

@media (min-width: 992px) {
  .shelf {
    --shelf-inset: max(
      var(--space-8),
      calc((100vw - var(--content-width)) / 2 + var(--space-8))
    );
  }
}

.shelf__viewport {
  overflow: hidden;
  padding-inline: var(--shelf-inset);
  touch-action: pan-y;
  cursor: grab;
}

.shelf__viewport:active {
  cursor: grabbing;
}

.shelf__track {
  display: flex;
  gap: var(--space-4);
  margin: 0;
  padding: 0 0 var(--space-2);
  list-style: none;
  width: max-content;
  will-change: transform;
}

@media (min-width: 768px) {
  .shelf__track {
    gap: var(--space-6);
  }
}

.shelf__item {
  flex: none;
  width: 200px;
}

@media (min-width: 768px) {
  .shelf__item {
    width: 232px;
  }
}

@media (min-width: 1200px) {
  .shelf__item {
    width: 264px;
  }
}

.shelf__link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.shelf__cover {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: var(--radius-card);
  background: var(--contentSkeleton);
  box-shadow: var(--shadow-subtle);
  transition: transform 160ms ease;
}

.shelf__link:hover .shelf__cover {
  transform: translateY(-2px);
}

.shelf__book-title {
  margin: var(--space-2) 0 0;
  font-size: var(--text-headline-body-7-size);
  line-height: var(--text-headline-body-7-line);
  letter-spacing: var(--text-headline-body-7-tracking);
  font-weight: var(--text-headline-body-7-weight);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: calc(2 * var(--text-headline-body-7-line));
}

.shelf__book-author {
  margin: 2px 0 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--contentSecondary);
  font-size: var(--text-meta1-size);
  line-height: var(--text-meta1-line);
  font-weight: var(--text-meta1-weight);
}

.shelf__dots {
  display: flex;
  justify-content: center;
  gap: var(--space-2);
  margin-top: var(--space-6);
  padding: 0;
  list-style: none;
}

.shelf__dot {
  width: var(--space-2);
  height: var(--space-2);
  padding: 0;
  border: none;
  border-radius: 999px;
  background: var(--contentTertiary);
  cursor: pointer;
}

.shelf__dot[aria-current="true"] {
  background: var(--contentAccent);
  transform: scale(1.4);
}

/* ---- 06 Prize draw ------------------------------------------------------- */

/* --backgroundYellow resolves to --yellow400, a tint. These two full-width
 * bands use --yellow500 so they match the hero badge, which already does.
 * Overridden here rather than in tokens.css: that file is skill-design's,
 * synced verbatim, and editing it would be undone by the next pull. The
 * semantic token itself is still on --yellow400 for everything else. */
.prize {
  background: var(--yellow500);
  color: var(--gray900);
  text-align: center;
}

.prize {
  padding: calc(var(--space-12) + var(--space-8)) 0;
}

@media (min-width: 768px) {
  .prize {
    padding: calc(var(--space-12) * 2) 0;
  }
}

.prize__icon {
  display: block;
  width: 56px;
  height: 56px;
  margin: 0 auto var(--space-6);
  color: var(--contentAccent);
}

@media (min-width: 768px) {
  .prize__icon {
    width: 80px;
    height: 80px;
  }
}

.prize__icon svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.prize__eyebrow {
  margin: 0 0 var(--space-4);
  color: var(--pink700);
  text-transform: uppercase;
  font-size: var(--text-meta1-size);
  line-height: var(--text-meta1-line);
  font-weight: var(--text-meta1-weight);
  letter-spacing: 1.6px;
}

.prize__title {
  margin: 0 auto var(--space-6);
  max-width: 18em;
  font-size: var(--text-subtitle-big-2-size);
  line-height: var(--text-subtitle-big-2-line);
  letter-spacing: var(--text-subtitle-big-2-tracking);
  font-weight: var(--text-subtitle-big-2-weight);
}

@media (min-width: 768px) {
  .prize__title {
    font-size: var(--text-heading-big-1-size);
    line-height: var(--text-heading-big-1-line);
    letter-spacing: var(--text-heading-big-1-tracking);
  }
}

.prize__body {
  margin: 0 auto;
  max-width: 720px;
  font-size: var(--text-preamble-size);
  line-height: 28px;
  font-weight: var(--weight-regular);
}

/* The link to the legal bases, set as Button 1 Underline. Its colour is the
 * yellow ground's own pair, --contentOverBackgroundYellow: 7.34:1 on the
 * --yellow500 this band is painted with (8.31:1 on --backgroundYellow), AA at
 * any size. The focus ring takes the same token, because the page-wide
 * --contentAccent ring is only 3.08:1 on this yellow. */
.prize__terms {
  display: inline-block;
  margin-top: var(--space-6);
  color: var(--contentOverBackgroundYellow);
  font-size: var(--text-button1-size);
  line-height: var(--text-button1-line);
  letter-spacing: var(--text-button1-tracking);
  font-weight: var(--text-button1-weight);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: var(--space-1);
  transition: text-decoration-thickness 120ms ease;
}

.prize__terms:hover {
  text-decoration-thickness: 3px;
}

.prize__terms:focus-visible {
  outline-color: var(--contentOverBackgroundYellow);
}

/* ---- 07 Trust band ------------------------------------------------------- */

.trust {
  background: var(--backgroundDark);
  color: var(--contentOverBackgroundDark);
  text-align: center;
  padding: var(--space-6) 0;
}

.trust__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
}

@media (min-width: 768px) {
  .trust__row {
    flex-wrap: nowrap;
    gap: var(--space-6);
  }
}

.trust__stores {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  flex: none;
  color: var(--contentOverBackgroundDark);
}

.trust__stores svg {
  width: var(--space-4);
  height: var(--space-4);
  fill: currentColor;
}

.trust__stars {
  display: inline-flex;
  flex: none;
  color: var(--contentYellow);
}

.trust__star {
  display: inline-flex;
  flex: none;
  padding: 0 1px;
}

.trust__stars svg {
  width: var(--space-4);
  height: var(--space-4);
  fill: currentColor;
}

.trust__rule {
  display: none;
}

@media (min-width: 768px) {
  .trust__rule {
    display: block;
    flex: none;
    width: 1px;
    align-self: stretch;
    min-height: var(--space-6);
    margin: 0 var(--space-6);
    background: var(--rule-on-dark);
  }
}

.trust__line {
  flex: 0 1 auto;
  margin: 0;
  max-width: 44em;
  text-align: center;
  font-size: var(--text-body2-size);
  line-height: var(--text-body2-line);
  font-weight: var(--weight-regular);
}

@media (min-width: 768px) {
  .trust__line {
    text-align: left;
  }
}

/* ---- 08 Three steps ------------------------------------------------------ */

.steps {
  background: var(--backgroundLight);
  text-align: left;
}

.steps__eyebrow {
  margin: 0 0 var(--space-3);
  color: var(--contentAccent);
  text-transform: uppercase;
  font-size: var(--text-meta1-size);
  line-height: var(--text-meta1-line);
  font-weight: var(--text-meta1-weight);
  letter-spacing: 1.6px;
}

.steps__title {
  margin: 0 0 var(--space-10);
  font-size: var(--text-heading-big-1-size);
  line-height: var(--text-heading-big-1-line);
  letter-spacing: var(--text-heading-big-1-tracking);
  font-weight: var(--text-heading-big-1-weight);
}

.steps__list {
  display: grid;
  gap: var(--space-10);
  margin: 0;
  padding: var(--space-10) 0;
  list-style: none;
  border-top: 1px solid var(--lineDivider);
  border-bottom: 1px solid var(--lineDivider);
}

@media (min-width: 768px) {
  .steps__list {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-8);
  }
}

.steps__number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--space-12);
  height: var(--space-12);
  margin-bottom: var(--space-6);
  border-radius: var(--radius-button);
  background: var(--buttonCTABackground);
  color: var(--buttonCTAText);
  font-size: var(--text-subtitle-medium-4-size);
  line-height: var(--text-subtitle-medium-4-line);
  font-weight: var(--weight-headline);
}

.steps__item-title {
  margin: 0 0 var(--space-3);
  font-size: var(--text-subtitle-small-6-size);
  line-height: var(--text-subtitle-small-6-line);
  letter-spacing: var(--text-subtitle-small-6-tracking);
  font-weight: var(--text-subtitle-small-6-weight);
}

.steps__item-body {
  margin: 0;
  color: var(--contentSecondary);
  font-size: var(--text-body2-size);
  line-height: var(--text-body2-line);
}

.steps__cta {
  display: flex;
  justify-content: center;
  padding-top: var(--space-10);
}

.steps__cta .cta {
  width: 100%;
}

@media (min-width: 768px) {
  .steps__cta .cta {
    width: auto;
  }
}

/* ---- 10 Footer ----------------------------------------------------------- */

.site-footer {
  background: var(--backgroundDark);
  color: var(--contentOverBackgroundDark);
  text-align: center;
  padding: var(--space-12) var(--space-6);
  padding-bottom: calc(var(--space-12) + var(--sticky-bar-height));
}

@media (min-width: 768px) {
  .site-footer {
    padding-bottom: var(--space-12);
  }
}

.site-footer__logo {
  width: 120px;
  margin: 0 auto var(--space-4);
}

.site-footer__copy {
  margin: 0;
  font-size: var(--text-meta1-size);
  line-height: var(--text-meta1-line);
  font-weight: var(--text-meta1-weight);
}

/* ---- 11 Sticky mobile CTA ------------------------------------------------ */

.sticky-cta {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10;
  background: var(--background);
  box-shadow: var(--shadow-lifted);
  padding: var(--space-3) var(--space-6) var(--space-4);
  padding-bottom: calc(var(--space-4) + env(safe-area-inset-bottom, 0px));
}

.sticky-cta__meta {
  margin: var(--space-2) 0 0;
  text-align: center;
  color: var(--contentSecondary);
  font-size: var(--text-meta1-size);
  line-height: var(--text-meta1-line);
  font-weight: var(--text-meta1-weight);
}

@media (min-width: 768px) {
  .sticky-cta {
    display: none;
  }
}

/* ---- Reduced motion ------------------------------------------------------ */

@media (prefers-reduced-motion: reduce) {
  .marquee__track {
    animation: none;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
