/* ============================================================
   ABOUT HERO — kwizzbit/about-hero
   Full-width centred mission statement. Two-line headline at 86px
   on desktop, sitting over a soft warm "light" that breathes —
   echoing the copy ("Bringing your room to life… lights up").
   ============================================================ */
.about-hero {
  background: #F0E3D9;
  padding-block: calc(clamp(3.5rem, 7vw, 6rem) + 50px);
  text-align: center;
  position: relative;
  overflow: clip;
}

/* ── Desktop padding ─────────────────────────────────────── */
@media (min-width: 1024px) {
  /* +35px top & bottom (50px → 85px) for more breathing room around the hero */
  .about-hero { padding-block: calc(clamp(5rem, 10vw, 9rem) + 85px); }
}

/* ── Inner: stacked (mobile) → text + photo-deck two-column (desktop) ── */
.about-hero__inner {
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: var(--wp--custom--layout--gutter);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(2.5rem, 5vw, 4rem);
  position: relative;
  z-index: 1;
}
@media (min-width: 1024px) {
  .about-hero__inner {
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: clamp(3rem, 6vw, 6rem);
  }
}

/* Text column — centred copy */
.about-hero__text {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
@media (min-width: 1024px) {
  .about-hero__text { flex: 0 1 auto; max-width: 540px; }
}

/* Media — holds the floating grid + the right-edge fade */
.about-hero__media {
  position: relative;
  flex-shrink: 0;
}

/* ── FLOATING ROOM GRID — adapted from the audience-split tiles ──
   Four "room" photos in a 2×2 that each drift on their own loop,
   implying the many spaces Kwizzbit lights up. Coral glow beneath.
   Keyframes are mr- prefixed (the source's float-1..4 collide with the
   homepage mantra). */
.about-hero__rooms {
  display: grid;
  grid-template-columns: repeat(2, 264px);
  gap: 18px;
  align-items: start;
  /* No group-level filter — drop-shadow on the grid bleeds through the fade.
     Individual tile depth (if needed) can be done with box-shadow instead. */
}
.about-hero__room {
  position: relative;
  width: 264px;
  aspect-ratio: 6 / 5;   /* matches the ~580×486 source images */
  overflow: hidden;
  background: #2a1a14;
  will-change: transform;
}
.about-hero__room img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* Hand-placed scatter so the grid isn't rigid */
.about-hero__room:nth-child(1) { margin-top: 18px; }
.about-hero__room:nth-child(3) { margin-left: 14px; }
.about-hero__room:nth-child(4) { margin-top: -18px; margin-left: 14px; }

/* Right-edge fade — tiles dissolve into the #F0E3D9 sand backdrop (like seg-2) */
.about-hero__rooms-fade {
  position: absolute;
  top: -10%;
  right: -20px;          /* nudge the fade 20px right */
  width: 40%;
  height: 120%;
  background: linear-gradient(to right, rgba(240, 227, 217, 0) 0%, #F0E3D9 72%);
  pointer-events: none;
  z-index: 5;
}
@media (max-width: 1023px) {
  .about-hero__rooms-fade { display: none; }
}

@keyframes mr-float-1 {
  0%{transform:translate(0,0) rotate(0)} 25%{transform:translate(2px,-4px) rotate(0.3deg)}
  50%{transform:translate(-1px,-7px) rotate(-0.2deg)} 75%{transform:translate(-3px,-3px) rotate(0.15deg)} 100%{transform:translate(0,0) rotate(0)}
}
@keyframes mr-float-2 {
  0%{transform:translate(0,0) rotate(0)} 25%{transform:translate(-2px,-5px) rotate(-0.25deg)}
  50%{transform:translate(2px,-8px) rotate(0.3deg)} 75%{transform:translate(1px,-2px) rotate(-0.1deg)} 100%{transform:translate(0,0) rotate(0)}
}
@keyframes mr-float-3 {
  0%{transform:translate(0,0) rotate(0)} 25%{transform:translate(3px,-3px) rotate(0.2deg)}
  50%{transform:translate(1px,-6px) rotate(-0.3deg)} 75%{transform:translate(-2px,-4px) rotate(0.1deg)} 100%{transform:translate(0,0) rotate(0)}
}
@keyframes mr-float-4 {
  0%{transform:translate(0,0) rotate(0)} 25%{transform:translate(-1px,-6px) rotate(0.15deg)}
  50%{transform:translate(-3px,-4px) rotate(-0.25deg)} 75%{transform:translate(2px,-2px) rotate(0.2deg)} 100%{transform:translate(0,0) rotate(0)}
}
.about-hero__room:nth-child(1) { animation: mr-float-1 6s   ease-in-out infinite; }
.about-hero__room:nth-child(2) { animation: mr-float-2 7.5s ease-in-out -2s   infinite; }
.about-hero__room:nth-child(3) { animation: mr-float-3 5.5s ease-in-out -4s   infinite; }
.about-hero__room:nth-child(4) { animation: mr-float-4 8s   ease-in-out -1.5s infinite; }

@media (prefers-reduced-motion: reduce) {
  .about-hero__room { animation: none !important; }
}

/* Tablet/mobile: slightly smaller tiles, centred under the copy */
@media (max-width: 1023px) {
  .about-hero__rooms { grid-template-columns: repeat(2, 230px); }
  .about-hero__room { width: 230px; }
}
@media (max-width: 640px) {
  .about-hero__rooms { grid-template-columns: repeat(2, 42vw); gap: 12px; }
  .about-hero__room { width: 42vw; }
}

/* ── Eyebrow ─────────────────────────────────────────────── */
.about-hero__eyebrow {
  font-family: 'Pixelar', monospace;
  font-weight: 400;
  font-size: 19px;
  line-height: 1;
  letter-spacing: 0;
  color: var(--wp--preset--color--coral);
  margin: 0 0 0.5rem;
}

/* ── Headline ────────────────────────────────────────────── */
.about-hero__title {
  font-family: var(--wp--preset--font-family--display);
  font-weight: 400;
  font-size: clamp(2.75rem, 5.5vw, 5rem);
  line-height: 0.85;
  letter-spacing: -0.10775em;
  color: var(--wp--preset--color--ink);
  margin: 0 0 1.5rem;
  text-wrap: wrap;
}

@media (min-width: 1024px) {
  .about-hero__title { font-size: 72px; }
}

/* Coral blinking period */
@keyframes ah-cursor-blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}
.about-hero__accent {
  color: var(--wp--preset--color--coral);
  animation: ah-cursor-blink 1.1s step-end infinite;
}

/* Coral word-swap: "your" and "our" breathe in antiphase */
@keyframes ah-coral-breathe {
  0%, 100% { color: var(--wp--preset--color--coral); }
  50%       { color: rgba(255, 54, 35, 0.25); }
}
.about-hero__swap {
  font-style: italic;
  color: var(--wp--preset--color--coral);
  /* 10% larger than the surrounding title text at every breakpoint — em is
     relative to the parent font-size so it scales automatically. */
  font-size: 1.1em;
  line-height: inherit;
}
.about-hero__swap--a { animation: ah-coral-breathe 3s ease-in-out 1.5s infinite; }
.about-hero__swap--b { animation: ah-coral-breathe 3s ease-in-out 3s   infinite; }

@media (prefers-reduced-motion: reduce) {
  .about-hero__accent { animation: none; opacity: 1; }
  .about-hero__swap   { animation: none !important; }
}

/* ── Lead ────────────────────────────────────────────────── */
.about-hero__lead {
  font-family: var(--wp--preset--font-family--body);
  font-weight: 500;
  font-size: 1.0625rem; /* 17px */
  line-height: 1.5;
  color: var(--wp--preset--color--ink-soft);
  max-width: 320px;
  margin: 0 auto 1.75rem;
}

/* ── Stat pill ───────────────────────────────────────────── */
.about-hero__stat {
  display: inline-flex;
  align-items: center;
  padding: 0.375rem 0.75rem;
  font-family: var(--wp--preset--font-family--body);
  font-weight: 500;
  font-size: 0.8125rem;
  line-height: 1;
  color: var(--wp--preset--color--ink-soft);
  background: transparent;
  border: 1px solid rgba(26, 26, 26, 0.18);
  border-radius: 0;
}
.about-hero__stat-em  { color: var(--wp--preset--color--coral); font-weight: 600; margin: 0 0.3em; }
.about-hero__stat-num { display: inline-block; vertical-align: baseline; }

/* ── FLOATING STICKERS ───────────────────────────────────── */

/* Stickers are hidden on mobile/tablet — only show at desktop where
   there's room either side of the headline. */
.about-hero__sticker { display: none; }

@media (min-width: 1024px) {
  /* Shared base */
  .about-hero__sticker {
    display: block;
    position: absolute;
    top: 44%;
    width: 110px;  /* 160px × 0.85 × 0.90 × 0.90 */
    pointer-events: none;
    z-index: 2;    /* above the inner text (z-index: 1) */
    will-change: transform;
  }
  .about-hero__sticker img {
    display: block;
    width: 100%;
    height: auto;
    image-rendering: pixelated;
    image-rendering: crisp-edges;
    /* Drop shadow: 15% opacity, 0px blur — clean pixel-art feel */
    filter: saturate(55%) drop-shadow(8px 10px 0px rgba(0, 0, 0, 0.15));
  }

  /* House — left side. calc(50% - 560px) at 1440px = 160px from left,
     so the house right-edge kisses the start of the headline. */
  .about-hero__sticker--house {
    left: max(0.5rem, calc(50% - 560px));
    transform: translateY(-50%);
  }

  /* Stadium — mirror on the right, nudged 20px lower */
  .about-hero__sticker--stadium {
    right: max(0.5rem, calc(50% - 560px));
    top: calc(44% + 20px);
    transform: translateY(-50%);
  }

  /* ── Load-in entrance (wrapper) ──
     Stickers spring in on page load with a slight scale + fade,
     then the float loop starts on the image inside. */
  @keyframes ah-sticker-in {
    from { opacity: 0; transform: translateY(-50%) scale(0.7) rotate(-8deg); }
    to   { opacity: 1; transform: translateY(-50%) scale(1)   rotate(0deg);  }
  }
  .about-hero__sticker--house   { animation: ah-sticker-in 0.65s 0.25s cubic-bezier(0.34,1.56,0.64,1) both; }
  .about-hero__sticker--stadium { animation: ah-sticker-in 0.65s 0.45s cubic-bezier(0.34,1.56,0.64,1) both; }

  /* ── Continuous float (on the img, so it composes independently
     of the entrance transform on the wrapper) ── */
  @keyframes ah-float-house {
    0%, 100% { transform: translateY(0)    rotate(-4deg); }
    50%       { transform: translateY(-14px) rotate(-1.5deg); }
  }
  @keyframes ah-float-stadium {
    0%, 100% { transform: translateY(0)    rotate(5deg); }
    50%       { transform: translateY(-10px) rotate(2.5deg); }
  }
  .about-hero__sticker--house   img { animation: ah-float-house   5.2s 0.9s  ease-in-out infinite; }
  .about-hero__sticker--stadium img { animation: ah-float-stadium 4.4s 1.1s  ease-in-out infinite; }

  @media (prefers-reduced-motion: reduce) {
    .about-hero__sticker,
    .about-hero__sticker img { animation: none !important; }
  }
}

/* ── Tablet ≤1023 ────────────────────────────────────────── */
@media (max-width: 1023px) {
  .about-hero { padding-block: clamp(3rem, 6vw, 5rem); }
  .about-hero__eyebrow { font-size: 18px; }
  .about-hero__lead { font-size: 1.0625rem; } /* keep 17px at tablet */
}

/* ── Mobile ≤640 ─────────────────────────────────────────── */
@media (max-width: 640px) {
  /* +80px top & bottom (was 2.5rem / 2rem) */
  .about-hero { padding-block: calc(2.5rem + 80px) calc(2rem + 80px); }
  .about-hero__eyebrow { font-size: 18px; }
  .about-hero__lead { font-size: 1rem; } /* 16px on mobile — matches hero lead */
  .about-hero__stat { font-size: 0.75rem; }
}
