/* Mayo Gaming site. Values ported from Paper "Website v1" (MW-01a/b, MW-02a/b, MW-03, MW-04). */
@font-face { font-family: "Fredoka"; src: url("/assets/fonts/fredoka-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Rubik"; src: url("/assets/fonts/rubik.woff2") format("woff2"); font-weight: 300 900; font-display: swap; }

:root {
  color-scheme: dark;
  --ground: #000;
  --ink: #fff;
  --ink-60: rgb(255 255 255 / 62%);
  /* Paper: 40%. Raised to 54% so 13-14px text clears WCAG AA (4.5:1) on black. */
  --ink-40: rgb(255 255 255 / 54%);
  --hair: rgb(255 255 255 / 14%);
  --hair-strong: rgb(255 255 255 / 30%);
  --cream: #f6f1e6;
  --cream-shade: #d6c9ad;
  --display: "Fredoka", system-ui, sans-serif;
  --ui: "Rubik", system-ui, sans-serif;
  --wrap: min(1000px, 100% - 32px);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--ground); -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
::selection { background: var(--cream); color: #000; }
body {
  margin: 0; background: var(--ground); color: var(--ink);
  font: 400 15px/22px var(--ui);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  font-synthesis: none; overflow-wrap: anywhere;
  display: flex; flex-direction: column; align-items: center; min-height: 100vh;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; font: inherit; }
h1, h2, h3 { text-wrap: balance; }
p, li { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--cream); outline-offset: 3px; border-radius: 4px; }
.wrap { width: var(--wrap); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Text links: 62% → full white */
.tlink { color: var(--ink-60); transition: color 160ms var(--ease); }
.tlink:hover { color: var(--ink); }

/* Wordmark: mayo.svg + gaming.svg, offsets from Paper */
.lockup { position: relative; display: block; aspect-ratio: 520 / 264; flex-shrink: 0; }
.lockup img { position: absolute; }
.lockup .l-mayo { left: 0; top: 0; width: 100%; height: 81.44%; }
.lockup .l-gaming { left: 20.96%; top: 76.52%; width: 58.08%; height: 23.48%; }
.lockup img { transform-origin: 50% 100%; }
.lockup.is-jelly .l-mayo { animation: jelly 760ms var(--ease); }
.lockup.is-jelly .l-gaming { animation: jelly 760ms 80ms var(--ease) both; }
@keyframes jelly {
  0% { transform: scale(1, 1); }
  12% { transform: scale(1.07, 0.86); }
  34% { transform: scale(0.97, 1.06); }
  54% { transform: scale(1.02, 0.97); }
  76% { transform: scale(0.995, 1.01); }
  100% { transform: scale(1, 1); }
}
.lockup--hero { width: 520px; }
.lockup--small { width: 120px; }

/* Buttons */
.pill {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border-radius: 999px; font: 500 15px/20px var(--ui); white-space: nowrap; flex-shrink: 0;
}
.pill svg { transition: transform 160ms var(--ease); }
.pill--play { background: var(--cream); color: #000; height: 44px; padding-inline: 22px; transition: background-color 160ms var(--ease); }
a.pill--play:hover { background: var(--cream-shade); }
a.pill { transition-property: background-color, border-color, transform; }
a.pill:active { transform: scale(0.97); }
a.pill--play:hover svg { transform: translateX(3px); }
.pill--line { border: 1px solid rgb(255 255 255 / 30%); height: 48px; padding-inline: 24px; color: var(--ink); font-weight: 400; font-size: 16px; transition: border-color 160ms var(--ease), background-color 160ms var(--ease); }
a.pill--line:hover { border-color: var(--ink); background: rgb(255 255 255 / 6%); }
/* Not live yet: no fill, no pointer, reads as a status */
.pill--soon { border: 1px solid var(--hair); color: var(--ink-60); height: 44px; padding-inline: 22px; font-weight: 400; cursor: default; }
.pill--lg { height: 64px; padding-inline: 36px; font-size: 18px; line-height: 24px; }

/* ---------- Home ---------- */
.hero { width: 100%; display: flex; flex-direction: column; align-items: center; padding-bottom: 96px; overflow: hidden; }
.hero { padding-top: 200px; }
.boot { display: none; position: fixed; inset: 0; z-index: 100; background: #000; overflow: hidden; cursor: pointer; transition: opacity 0.5s ease; }
.boot.is-on { display: block; }
.boot.is-out { opacity: 0; pointer-events: none; }
.boot canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.boot-stage { position: absolute; left: 0; top: 0; width: 1920px; height: 1080px; transform-origin: 0 0; }
.boot-rig { position: absolute; inset: 0; transform-origin: 960px 540px; }
.boot-rig img { position: absolute; opacity: 0; transform-origin: 50% 100%; }
.boot-rig .b-mayo { left: 640px; top: 376px; width: 640px; height: 264.77px; }
.boot-rig .b-gaming { left: 774px; top: 624.77px; width: 372px; height: 76.47px; }
.intro-on { overflow: hidden; }
.intro-on .hero .lockup { visibility: hidden; }
.hero .lockup { z-index: 1; }
.tagline { display: flex; flex-direction: column; align-items: center; gap: 10px; padding-top: 48px; text-align: center; }
.tagline .tag-title { font: 500 26px/32px var(--display); color: var(--ink); }
.tagline p { color: var(--ink-60); }

.section-head { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: 12px; border-bottom: 1px solid var(--hair); font-size: 14px; line-height: 20px; }
.section-head h2 { font-weight: 500; }
.section-head span { color: var(--ink-40); }

.games { display: flex; flex-direction: column; gap: 24px; }
.grid { display: grid; grid-template-columns: 656fr 320fr; gap: 24px; align-items: start; }
.card { display: flex; flex-direction: column; gap: 20px; }
.media { display: block; border-radius: 16px; overflow: hidden; aspect-ratio: 656 / 369; position: relative; background: #0d0f1f; }
.media:focus-visible { outline-offset: 4px; border-radius: 16px; }
.media img { width: 100%; height: 100%; object-fit: cover; transition: transform 480ms var(--ease); }
.media::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px transparent; transition: box-shadow 240ms var(--ease); pointer-events: none; }
.card:hover .media img { transform: scale(1.03); }
.card:hover .media::after { box-shadow: inset 0 0 0 1px var(--hair-strong); }
.caption { display: flex; justify-content: space-between; align-items: start; gap: 24px; }
.caption-text { display: flex; flex-direction: column; gap: 6px; }
.card h3 { font: 500 22px/28px var(--display); }
.card h3 a { text-decoration: underline 1.5px transparent; text-underline-offset: 4px; transition: text-decoration-color 160ms var(--ease); }
.card:hover h3 a { text-decoration-color: var(--hair-strong); }
.card p { color: var(--ink-60); }
.card .meta { font-variant-numeric: tabular-nums; padding-top: 4px; color: var(--ink-40); font-size: 13px; line-height: 20px; }
.soon .empty { aspect-ratio: 320 / 369; border: 1px solid var(--hair); border-radius: 16px; display: flex; align-items: center; justify-content: center; }
.soon .empty svg { width: 20px; height: 28px; }
.soon h3, .soon p { color: var(--ink-40); }
.soon-text { display: flex; flex-direction: column; gap: 6px; }

.work { display: flex; flex-direction: column; gap: 24px; padding-top: 128px; scroll-margin-top: 48px; }
.work-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.work-card { display: flex; flex-direction: column; gap: 8px; padding: 24px; border: 1px solid var(--hair); border-radius: 16px; transition: border-color 160ms var(--ease), background-color 160ms var(--ease), transform 160ms var(--ease); }
.work-card h3 { display: flex; align-items: center; justify-content: space-between; gap: 12px; font: 500 20px/26px var(--display); }
.work-card svg { flex-shrink: 0; color: var(--ink-40); transition: transform 160ms var(--ease), color 160ms var(--ease); }
.work-card p { color: var(--ink-60); }
.work-card:hover { border-color: var(--hair-strong); background: rgb(255 255 255 / 4%); }
.work-card:hover svg { color: var(--ink); transform: translateX(3px); }
.work-card:active { transform: scale(0.98); }
.work-card:focus-visible { border-radius: 16px; }
.contact { display: flex; flex-direction: column; align-items: center; gap: 20px; padding-block: 128px 160px; text-align: center; }
.contact h2 { font: 500 26px/32px var(--display); }

/* Footer: approved layout, extended with legal links + disclaimer */
.footer { border-top: 1px solid var(--hair); padding: 20px 0 48px; margin-top: auto; display: flex; flex-direction: column; gap: 8px; font-size: 13px; line-height: 20px; color: var(--ink-60); }
.footer .row { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; }
.footer nav { display: flex; gap: 6px; flex-wrap: wrap; }
.footer nav span { color: var(--ink-40); }
.footer .quiet { color: var(--ink-40); }
.footer .back { font-size: 14px; margin-bottom: 4px; }

/* ---------- Game + legal pages ---------- */
.nav { display: flex; justify-content: space-between; align-items: center; padding: 32px 0 48px; font-size: 14px; line-height: 20px; }
.nav > a:first-child, .nav > a:last-child { width: 160px; }
.nav > a:last-child { text-align: right; }
.keyart { border-radius: 20px; overflow: hidden; aspect-ratio: 1000 / 562; background: #0d0f1f; }
.keyart img { width: 100%; height: 100%; object-fit: cover; }
.intro { display: flex; justify-content: space-between; align-items: end; gap: 48px; padding-top: 56px; }
.intro-text { width: 600px; display: flex; flex-direction: column; gap: 16px; }
.intro h1, .legal h1 { font: 500 40px/44px var(--display); }
.intro p, .legal p, .legal li { color: var(--ink-60); font-size: 18px; line-height: 28px; }
.intro .meta { color: var(--ink-40); font-size: 14px; line-height: 20px; }

.facts { margin-top: 56px; border-top: 1px solid var(--hair); display: grid; grid-template-columns: repeat(4, 1fr); }
.fact { display: flex; flex-direction: column; gap: 6px; padding: 24px; border-bottom: 1px solid var(--hair); border-left: 1px solid var(--hair); }
.fact:nth-child(4n+1) { padding-left: 0; border-left: 0; }
.fact dt { color: var(--ink-40); font-size: 14px; line-height: 20px; }
.fact dd { margin: 0; font: 500 28px/32px var(--display); font-variant-numeric: tabular-nums; }
.fineprint { margin-top: 16px; color: var(--ink-40); font-size: 13px; line-height: 20px; }

.features { margin-top: 56px; display: flex; flex-direction: column; }
.features ul { list-style: none; margin: 0; padding: 0; }
.features li { display: grid; grid-template-columns: 280px 1fr; gap: 24px; padding-block: 20px; border-bottom: 1px solid var(--hair); font-size: 18px; line-height: 28px; }
.features li b { font-weight: 500; }
.features li span { color: var(--ink-60); }

.shots { margin-top: 56px; display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.shots img { border-radius: 12px; aspect-ratio: 488 / 274; width: 100%; object-fit: cover; background: #0d0f1f; }
.page-game .footer, .page-legal .footer { margin-top: 96px; padding-bottom: 40px; padding-top: 24px; }

.legal { width: 600px; max-width: 100%; display: flex; flex-direction: column; gap: 16px; padding-top: 24px; }
.legal h2 { font: 500 18px/28px var(--ui); color: var(--ink); margin-top: 16px; }
.legal ul { margin: 0; padding-left: 20px; }
.legal a { white-space: nowrap; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--hair-strong); transition: text-decoration-color 160ms var(--ease); }
.legal a:hover { text-decoration-color: var(--ink); }
.legal .updated { color: var(--ink-40); font-size: 14px; line-height: 20px; }

/* ---------- 404 ---------- */
.page-404 .top { display: flex; justify-content: center; padding-top: 32px; }
.splat { position: relative; width: 800px; max-width: 100%; aspect-ratio: 2 / 1; margin-top: 80px; }
.splat img { width: 100%; height: 100%; }
.splat strong { position: absolute; left: 11.5%; top: 32.5%; width: 68.25%; text-align: center; font: 500 120px/130px var(--display); color: #1a1712; }
.lost { display: flex; flex-direction: column; align-items: center; gap: 24px; margin: 40px 0 96px; text-align: center; }
.lost p { color: var(--ink-60); font-size: 20px; line-height: 28px; }
.lost .pill--line { height: 52px; padding-inline: 28px; font-weight: 500; line-height: 24px; border-color: var(--hair); }

/* ---------- Phone (MW-01b / MW-02b) ---------- */
@media (max-width: 720px) {
  .lockup--hero { width: 300px; }
  .lockup--small { width: 88px; }
  .hero { padding-bottom: 56px; }
  .hero { padding-top: 120px; }
  .tagline { gap: 8px; padding-top: 36px; width: var(--wrap); }
  .tagline .tag-title { font-size: 22px; line-height: 28px; }
  .games { gap: 20px; }
  .grid { grid-template-columns: 1fr; gap: 12px; }
  .card { gap: 16px; }
  .media { border-radius: 14px; aspect-ratio: 358 / 201; }
  .caption { flex-direction: column; align-items: stretch; gap: 16px; }
  .card h3 { font-size: 20px; line-height: 26px; }
  .card .meta { padding-top: 2px; }
  .card .pill { height: 48px; font-size: 16px; }
  .soon { flex-direction: row; align-items: center; gap: 16px; padding: 20px; border: 1px solid var(--hair); border-radius: 14px; }
  .soon .empty { aspect-ratio: auto; border: 0; display: block; }
  .soon .empty svg { width: 16px; height: 22px; display: block; }
  .soon-text { gap: 2px; }
  .soon h3 { font-size: 18px; line-height: 24px; }
  .soon p { font-size: 14px; line-height: 20px; }
  .work { gap: 20px; padding-top: 88px; scroll-margin-top: 24px; }
  .work-grid { grid-template-columns: 1fr; gap: 12px; }
  .work-card { padding: 20px; border-radius: 14px; gap: 4px; }
  .work-card h3 { font-size: 18px; line-height: 24px; }
  .work-card p { font-size: 14px; line-height: 20px; }
  .contact { gap: 16px; padding-block: 88px 112px; }
  .contact h2 { font-size: 22px; line-height: 28px; }
  .footer { padding: 20px 0 40px; }
  .footer .row { flex-direction: column; gap: 8px; }

  .nav { padding: 20px 0 24px; }
  .nav > a:first-child, .nav > a:last-child { width: 90px; }
  .keyart { border-radius: 14px; aspect-ratio: 358 / 201; }
  .intro { flex-direction: column; align-items: stretch; gap: 24px; padding-top: 28px; }
  .intro-text { width: auto; gap: 12px; }
  .intro h1, .legal h1 { font-size: 30px; line-height: 34px; }
  .intro p, .legal p, .legal li { font-size: 16px; line-height: 24px; }
  .intro .meta { font-size: 13px; }
  .pill--lg { height: 56px; font-size: 17px; }
  .facts { margin-top: 32px; grid-template-columns: 1fr 1fr; }
  .fact { gap: 4px; padding: 16px; }
  .fact:nth-child(4n+1) { padding-left: 16px; border-left: 1px solid var(--hair); }
  .fact:nth-child(odd) { padding-left: 0; border-left: 0; }
  .fact dt { font-size: 13px; line-height: 18px; }
  .fact dd { font-size: 24px; line-height: 28px; }
  .features { margin-top: 32px; }
  .features li { grid-template-columns: 1fr; gap: 4px; padding-block: 16px; font-size: 16px; line-height: 24px; }
  .shots { margin-top: 32px; grid-template-columns: 1fr; gap: 12px; }
  .shots img { border-radius: 10px; aspect-ratio: 358 / 201; }
  .page-game .footer, .page-legal .footer { margin-top: 56px; padding: 20px 0 32px; }
  .legal { padding-top: 8px; gap: 12px; }
  .legal h2 { font-size: 16px; line-height: 24px; margin-top: 12px; }

  .splat { margin-top: 56px; }
  .splat strong { font-size: 15vw; line-height: 1.08; top: 30%; }
  .lost p { font-size: 18px; }
}
@media (max-width: 720px) { .only-desk { display: none; } }
@media (min-width: 721px) { .only-phone { display: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0ms !important; }
  .card:hover .media img { transform: none; }
  .lockup.is-jelly img { animation: none !important; }
}
