/* Yaippi Games: site styles. Mobile first; desktop from 900px. Night is the default theme. */
:root {
  --night: #14112B; --night-2: #221D45; --night-3: #2F2860; --night-deep: #0C0A1F;
  --cream: #FFF4E0; --cream-2: #FFE9C7; --paper: #FFFBF3;
  --yellow: #FFC531; --coral: #FF5A4F; --mint: #2EE6A6; --sky: #6C8CFF; --ink: #1A1430; --ink-soft: #5B5378;
  --display: 'Unbounded', system-ui, sans-serif; --body: 'Plus Jakarta Sans', system-ui, sans-serif;
  --pop: cubic-bezier(.34, 1.56, .64, 1);
  --pad: 18px; --max: 1240px;
  /* theme roles (Night) */
  --bg: var(--night); --bg-2: var(--night-2); --bg-3: var(--night-3); --fg: var(--cream); --fg-soft: #C9C2E6;
  --line: rgba(255, 244, 224, .14); --chip: rgba(255, 244, 224, .1); --accent-text: var(--yellow); --ftr: var(--night-deep);
}
:root[data-theme="day"] {
  --bg: var(--paper); --bg-2: #FFFFFF; --bg-3: var(--cream-2); --fg: var(--ink); --fg-soft: var(--ink-soft);
  --line: rgba(26, 20, 48, .14); --chip: rgba(26, 20, 48, .07); --accent-text: #B4231A; --ftr: var(--ink);
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="night"]) {
    --bg: var(--paper); --bg-2: #FFFFFF; --bg-3: var(--cream-2); --fg: var(--ink); --fg-soft: var(--ink-soft);
    --line: rgba(26, 20, 48, .14); --chip: rgba(26, 20, 48, .07); --accent-text: #B4231A; --ftr: var(--ink);
  }
}
@media (min-width: 900px) { :root { --pad: 56px; } }

*, *::before, *::after { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { background: var(--bg); color: var(--fg); font: 400 16px/1.55 var(--body); overflow-x: hidden; -webkit-font-smoothing: antialiased; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--yellow); color: var(--ink); padding: 10px 14px; border-radius: 10px; font-weight: 800; z-index: 50; text-decoration: none; }
.skip:focus { top: 12px; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); }
.eyebrow { font: 700 12px/1 var(--display); letter-spacing: .12em; text-transform: uppercase; color: var(--accent-text); margin-bottom: 14px; }
h1, h2, h3 { font-family: var(--display); font-weight: 800; letter-spacing: -.035em; line-height: 1.05; }
.lede { font-size: 17px; color: var(--fg-soft); max-width: 46ch; }
@media (min-width: 900px) { .lede { font-size: 19px; } }

/* wordmark: the i-dots are Yip's ears */
.wordmark { font-family: var(--display); font-weight: 800; letter-spacing: -.045em; line-height: 1; display: inline-block; padding-top: .18em; white-space: nowrap; }
.wordmark .wi { position: relative; display: inline-block; }
.wordmark .wi svg { position: absolute; left: 50%; top: -.02em; width: .3em; height: .44em; transform: translateX(-50%) rotate(-16deg); overflow: visible; }
.wordmark .wi.r svg { transform: translateX(-50%) rotate(16deg); }

/* header */
.hdr { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px var(--pad); max-width: calc(var(--max) + 2 * var(--pad)); margin: 0 auto; position: relative; z-index: 20; }
.logo { display: flex; align-items: center; gap: 8px; text-decoration: none; font-size: 22px; }
.logo .yip { width: 42px; transition: transform .35s var(--pop); }
.logo:hover .yip { transform: rotate(-8deg) translateY(-2px); }
.nav { display: none; }
.nav a { text-decoration: none; font: 700 15px var(--body); padding: 10px 16px; border-radius: 99px; position: relative; }
.nav a:hover { background: var(--chip); }
.nav a[aria-current] { background: var(--chip); }
.menu-btn { width: 50px; height: 50px; border-radius: 50%; background: var(--cream); border: 3px solid var(--ink); box-shadow: 0 3px 0 var(--ink); display: grid; place-items: center; overflow: hidden; padding: 0; position: relative; z-index: 31; }
.menu-btn span { width: 42px; margin-top: 10px; grid-area: 1 / 1; transition: transform .3s var(--pop), opacity .2s; }
.menu-btn .open { opacity: 0; transform: translateY(10px); }
.menu-btn[aria-expanded="true"] .rest { opacity: 0; } .menu-btn[aria-expanded="true"] .open { opacity: 1; transform: none; }
.sheet { position: fixed; inset: 0; background: var(--night); color: var(--cream); z-index: 30; padding: 96px var(--pad) 40px; display: flex; flex-direction: column; overflow: hidden; }
.sheet[hidden] { display: none; }
.sheet nav { display: flex; flex-direction: column; gap: 6px; }
.sheet nav a { font: 800 38px/1.15 var(--display); letter-spacing: -.035em; text-decoration: none; padding: 4px 0; animation: rise .45s var(--pop) both; }
.sheet nav a:nth-child(2) { animation-delay: .05s } .sheet nav a:nth-child(3) { animation-delay: .1s } .sheet nav a:nth-child(4) { animation-delay: .15s } .sheet nav a:nth-child(5) { animation-delay: .2s }
.sheet nav a.small { font: 700 17px var(--body); letter-spacing: 0; margin-top: 18px; opacity: .7; }
.sheet-yip { position: absolute; bottom: -40px; right: 24px; width: 180px; animation: peek .6s .15s var(--pop) both; }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }
@keyframes peek { from { transform: translateY(120px); } }
body.menu-open { overflow: hidden; }
@media (min-width: 900px) {
  .hdr { padding-top: 22px; padding-bottom: 22px; }
  .logo { font-size: 27px; gap: 10px; } .logo .yip { width: 52px; }
  .nav { display: flex; gap: 4px; }
  .menu-btn, .sheet { display: none !important; }
}

/* buttons, chips, tags */
.btn { display: inline-flex; align-items: center; gap: 10px; font: 800 15px/1 var(--body); padding: 15px 22px; border-radius: 99px; border: 3px solid var(--ink); background: var(--yellow); color: var(--ink); box-shadow: 0 5px 0 var(--ink); text-decoration: none; transition: transform .18s var(--pop), box-shadow .18s; }
.btn:hover { transform: translateY(-3px); box-shadow: 0 8px 0 var(--ink); }
.btn:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink); }
.btn.ghost { background: transparent; color: var(--fg); border-color: currentColor; box-shadow: none; }
.btn.ghost:hover { background: var(--chip); }
.chip { display: inline-flex; align-items: center; gap: 6px; font: 700 12px/1 var(--body); padding: 7px 11px; border-radius: 99px; background: rgba(0, 0, 0, .25); color: #fff; }
.chip.y { background: var(--yellow); color: var(--ink); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font: 700 11px/1 var(--body); padding: 6px 9px; border-radius: 99px; background: rgba(0, 0, 0, .28); color: #fff; }
.tag.out { background: var(--mint); color: var(--ink); }
.soon-pill { display: inline-flex; align-items: center; gap: 10px; background: #000; color: #fff; border-radius: 12px; padding: 9px 16px 9px 12px; border: 1.5px solid rgba(255, 255, 255, .3); font: 600 10px/1.15 var(--body); }
.soon-pill b { display: block; font-size: 15px; font-weight: 700; }
.soon-pill svg { width: 22px; height: 22px; }

/* section heads */
.sec { padding: 56px 0; }
.sec-h { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 12px 20px; margin-bottom: 10px; }
.sec-h h2 { font-size: 30px; }
.sec-h .more { color: var(--accent-text); font-weight: 800; text-decoration: none; font-size: 15px; white-space: nowrap; }
.sec-h .more:hover { text-decoration: underline; text-underline-offset: 4px; }
@media (min-width: 900px) { .sec { padding: 88px 0; } .sec-h h2 { font-size: 46px; } }

/* home hero */
.hero { display: grid; gap: 30px; padding-top: 4px; padding-bottom: 30px; }
.hero-copy { position: relative; padding-top: 140px; }
.hero-trail { position: absolute; top: 18px; left: 0; width: min(420px, 100%); color: var(--yellow); opacity: .75; }
.hero-hop { position: absolute; top: 0; left: min(250px, 58%); width: 84px; animation: hop 2.6s var(--pop) 1s infinite; }
.hero-hop svg { transform: rotate(8deg); }
@keyframes hop { 0%, 55%, 100% { transform: translateY(0); } 25% { transform: translateY(-16px) rotate(-4deg); } }
.hero h1 { font-size: clamp(40px, 11vw, 84px); margin-bottom: 18px; }
.hero h1 .hl { color: var(--yellow); }
:root[data-theme="day"] .hero h1 .hl { color: var(--ink); background: linear-gradient(transparent 58%, var(--yellow) 58% 92%, transparent 92%); }
@media (prefers-color-scheme: light) { :root:not([data-theme="night"]) .hero h1 .hl { color: var(--ink); background: linear-gradient(transparent 58%, var(--yellow) 58% 92%, transparent 92%); } }
.hero .ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.spot { position: relative; background: #3D6B70; color: #FFF6E6; border-radius: 28px; padding: 22px 22px 0; overflow: hidden; display: flex; flex-direction: column; text-decoration: none; isolation: isolate; }
.spot::before { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 70px; background: #4B3448; z-index: -1; }
.spot::after { content: ''; position: absolute; left: 0; right: 0; bottom: 70px; height: 18px; background: #D39A62; border-top: 4px solid #221B26; border-bottom: 9px solid #9A6238; z-index: -1; }
.spot h2 { font: 800 40px/0.95 'Bricolage Grotesque', var(--display); letter-spacing: -.035em; margin: 14px 0 10px; }
.spot h2 em { font-style: normal; color: #F28C38; }
.spot p { font-size: 15px; opacity: .9; max-width: 34ch; }
.spot .acts { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 18px; }
.spot .go { font-weight: 800; color: #FFC93C; }
.spot .phone { width: 180px; margin: 22px auto -150px; border-radius: 26px; border: 6px solid #221B26; box-shadow: 0 18px 40px rgba(0, 0, 0, .35); transform: rotate(4deg); transition: transform .4s var(--pop); }
.spot:hover .phone { transform: rotate(1deg) translateY(-8px); }
@media (min-width: 900px) {
  .hero { grid-template-columns: 1.1fr 1fr; align-items: center; gap: 48px; padding-bottom: 40px; }
  .hero-copy { padding-top: 160px; }
  .hero-hop { width: 104px; left: 300px; }
  .spot { padding: 36px 36px 150px; display: block; min-height: 470px; }
  .spot > div { max-width: calc(100% - 210px); }
  .spot::before { height: 96px; } .spot::after { bottom: 96px; }
  .spot h2 { font-size: 52px; }
  .spot .phone { position: absolute; right: 30px; bottom: -150px; width: 190px; margin: 0; }
}

/* worlds: each game in its own palette, type and voice */
.worlds .intro { color: var(--fg-soft); max-width: 52ch; font-size: 16px; }
.wgrid { display: grid; gap: 14px; margin-top: 28px; }
.w { position: relative; border-radius: 28px; overflow: hidden; min-height: 330px; display: flex; flex-direction: column; justify-content: flex-end; padding: 22px; text-decoration: none; isolation: isolate; transition: transform .3s var(--pop); }
a.w:hover { transform: translateY(-4px) rotate(-.4deg); }
.w .bg { position: absolute; inset: 0; z-index: -1; }
.w .bg svg { width: 100%; height: 100%; }
.w h3 { margin-bottom: 4px; }
.w .line { font: 600 16px/1.35 var(--body); margin: 4px 0 12px; max-width: 32ch; }
.w.vase { background: #3D6B70; color: #FFF6E6; justify-content: flex-start; min-height: 470px; }
.w.vase::before { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 30%; background: #4B3448; z-index: -1; }
.w.vase::after { content: ''; position: absolute; left: 0; right: 0; bottom: 30%; height: 18px; background: #D39A62; border-top: 4px solid #221B26; border-bottom: 10px solid #9A6238; z-index: -1; }
.w.vase h3 { font: 800 46px/0.95 'Bricolage Grotesque', var(--display); letter-spacing: -.035em; }
.w.vase h3 em { font-style: normal; color: #F28C38; }
.w.vase .line, .w.vase .tags { max-width: 60%; position: relative; z-index: 1; }
.w.vase .shots { position: absolute; right: -6px; bottom: -40px; display: flex; align-items: end; }
.w.vase .shots img { width: 116px; height: auto; border-radius: 18px; border: 5px solid #221B26; box-shadow: 0 16px 30px rgba(0, 0, 0, .35); }
.w.vase .shots img:first-child { transform: rotate(-7deg) translate(18px, -10px); }
.w.vase .shots img:last-child { transform: rotate(5deg); width: 126px; }
.w.cart { color: #2B2135; }
.w.cart .bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(transparent 35%, rgba(244, 233, 216, .96) 80%); }
.w.cart h3 { font: 400 32px/0.95 'Bowlby One', var(--display); display: inline-block; background: #E8505B; color: #fff; padding: 8px 14px 6px; border: 3px solid #2B2135; transform: rotate(-3deg); align-self: flex-start; box-shadow: 4px 4px 0 #2B2135; text-transform: uppercase; letter-spacing: .01em; }
.w.cart .tag { background: #2B2135; }
.w.cheese { color: #fff; }
.w.cheese .bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(transparent 30%, rgba(52, 33, 82, .92) 82%); }
.w.cheese h3 { font: italic 900 40px/1 Fraunces, Georgia, serif; letter-spacing: -.02em; }
.w.cheese .flash { position: absolute; top: 18px; right: 18px; font: 800 11px/1 var(--body); letter-spacing: .12em; background: #fff; color: #342152; padding: 6px 8px; border-radius: 4px; }
.w.next { background: var(--bg-3); color: var(--fg); min-height: 0; flex-direction: row; align-items: center; gap: 18px; justify-content: flex-start; padding: 26px 22px 26px; }
.w.next .q { font: 800 80px/1 var(--display); color: var(--yellow); flex: none; transform: rotate(-8deg); }
.w.next h3 { font-size: 19px; line-height: 1.15; }
.w.next p { color: var(--fg-soft); font-size: 14px; margin-top: 6px; max-width: 46ch; padding-right: 70px; }
.w.next .peek { position: absolute; right: 8px; bottom: -30px; width: 92px; }
@media (min-width: 900px) {
  .wgrid { grid-template-columns: repeat(12, 1fr); grid-auto-rows: 280px; gap: 22px; margin-top: 40px; }
  .w.vase { grid-column: span 7; grid-row: span 2; padding: 40px; min-height: 0; }
  .w.vase h3 { font-size: 78px; }
  .w.vase .line, .w.vase .tags { max-width: 52%; }
  .w.vase .line { font-size: 18px; }
  .w.vase .shots { right: 30px; bottom: -80px; }
  .w.vase .shots img { width: 170px; } .w.vase .shots img:last-child { width: 186px; }
  .w.cart, .w.cheese { grid-column: span 5; padding: 28px; min-height: 0; }
  .w.next { grid-column: span 12; padding: 30px 44px; gap: 30px; }
  .w.next h3 { font-size: 26px; } .w.next p { font-size: 16px; }
  .w.next .peek { width: 140px; right: 60px; bottom: -56px; }
}

/* about */
.about { display: grid; gap: 26px; align-items: center; }
.stage { position: relative; aspect-ratio: 1; max-width: 320px; width: 100%; margin: 0 auto; border-radius: 50%; background: var(--bg-3); display: grid; place-items: end center; }
.stage > svg { width: 64%; margin-bottom: 4%; }
.stage .bubble { position: absolute; top: 9%; right: -2%; background: var(--cream); color: var(--ink); font: 800 14px/1.15 var(--display); padding: 10px 13px; border-radius: 16px 16px 16px 4px; border: 2.5px solid var(--ink); transform: rotate(6deg); }
.about h2 { font-size: 32px; margin-bottom: 12px; }
.about p { color: var(--fg-soft); font-size: 17px; max-width: 46ch; }
.about .faces { display: flex; gap: 10px; margin-top: 20px; }
.about .faces span { width: 56px; height: 56px; border-radius: 16px; background: var(--bg-2); padding: 5px; }
@media (min-width: 900px) { .about { grid-template-columns: 1fr 1.15fr; gap: 70px; } .stage { max-width: 440px; } .about h2 { font-size: 46px; } .about p { font-size: 19px; } .about .faces span { width: 68px; height: 68px; } }

/* say hello */
.hello { background: var(--bg-2); border-radius: 32px; padding: 30px 24px 130px; position: relative; overflow: hidden; }
.hello h2 { font-size: 28px; }
.hello p { color: var(--fg-soft); margin: 10px 0 20px; max-width: 46ch; }
.hello .yip-run { position: absolute; right: 8px; bottom: -36px; width: 124px; transform: rotate(-10deg); }
@media (min-width: 900px) { .hello { padding: 50px 56px; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 40px; } .hello h2 { font-size: 40px; } .hello .yip-run { position: static; width: 170px; margin: -30px 30px -60px 0; transform: rotate(-8deg); } }

/* game cards (games page, "more from Yaippi") */
.cards { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr)); margin-top: 30px; }
.gcard { position: relative; display: flex; flex-direction: column; background: var(--bg-2); border-radius: 22px; text-decoration: none; box-shadow: inset 0 -6px 0 var(--g); transition: transform .25s var(--pop); isolation: isolate; }
a.gcard:hover, a.gcard:focus-visible { transform: translateY(-6px) rotate(-1deg); }
.gcard .cov { aspect-ratio: 4 / 3; border-radius: 22px 22px 0 0; overflow: hidden; background: var(--g); }
.gcard .cov svg { width: 100%; height: 100%; transition: transform .4s var(--pop); }
a.gcard:hover .cov svg { transform: scale(1.06) rotate(1.5deg); }
.gcard .gb { padding: 16px 18px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.gcard .gt { font-size: 21px; }
.gcard p { font-size: 14px; line-height: 1.45; color: var(--fg-soft); }
.gcard .tags { margin-top: auto; padding-top: 6px; }
.gcard .tag { background: var(--chip); color: var(--fg); }
.gcard .tag.out { background: var(--mint); color: var(--ink); }
.gcard .peek { position: absolute; top: -40px; right: 18px; width: 64px; z-index: -1; transform: translateY(36px); transition: transform .35s var(--pop); }
a.gcard:hover .peek, a.gcard:focus-visible .peek { transform: none; }
.g-vase .gt { font-family: 'Bricolage Grotesque', var(--display); font-size: 26px; } .g-vase .gt em { font-style: normal; color: #F28C38; }
.g-cart .gt { font-family: 'Bowlby One', var(--display); font-weight: 400; text-transform: uppercase; letter-spacing: .01em; color: #FF7A83; }
.g-cheese .gt { font: italic 900 25px/1.05 Fraunces, Georgia, serif; letter-spacing: -.02em; }
:root[data-theme="day"] .g-cart .gt { color: #C2303B; }
@media (prefers-color-scheme: light) { :root:not([data-theme="night"]) .g-cart .gt { color: #C2303B; } }

/* page header (inner pages) */
.page-h { padding-top: 26px; padding-bottom: 10px; position: relative; }
.page-h h1 { font-size: clamp(38px, 9vw, 72px); margin-bottom: 12px; }
.page-h .yip-peek { position: absolute; right: var(--pad); top: 10px; width: 76px; }
@media (min-width: 900px) { .page-h { padding-top: 46px; } .page-h .yip-peek { width: 140px; top: 20px; } }

/* footer */
.ftr { background: var(--ftr); color: var(--cream); margin-top: 96px; padding: 74px max(var(--pad), calc((100% - var(--max)) / 2)) 28px; position: relative; }
.ftr .sleeper { position: absolute; top: -66px; left: var(--pad); width: 104px; }
.ftr-word { font-size: 28px; text-decoration: none; display: inline-block; }
.ftr-brand p { opacity: .6; font-size: 14px; margin: 6px 0 24px; }
.ftr-nav { display: flex; flex-wrap: wrap; gap: 8px 22px; font: 700 15px var(--body); margin-bottom: 26px; }
.ftr-nav a { text-decoration: none; } .ftr-nav a:hover { text-decoration: underline; text-underline-offset: 4px; }
.ftr-base { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; font-size: 13px; border-top: 1px solid rgba(255, 244, 224, .12); padding-top: 18px; }
.ftr-base > span, .ftr-base > a { opacity: .65; }
.theme-btn { margin-left: auto; background: rgba(255, 244, 224, .1); border: 0; border-radius: 99px; padding: 7px 12px; font-size: 12.5px; font-weight: 700; color: var(--cream); }
.theme-btn .t-day { display: none; }
:root[data-theme="day"] .theme-btn .t-night { display: none; } :root[data-theme="day"] .theme-btn .t-day { display: inline; }
@media (prefers-color-scheme: light) { :root:not([data-theme="night"]) .theme-btn .t-night { display: none; } :root:not([data-theme="night"]) .theme-btn .t-day { display: inline; } }
.theme-btn::before { content: 'Theme: '; opacity: .7; font-weight: 500; }
@media (min-width: 900px) { .ftr { padding-top: 84px; display: grid; grid-template-columns: 1fr auto; align-items: start; column-gap: 40px; } .ftr .sleeper { width: 120px; top: -76px; left: max(var(--pad), calc((100% - var(--max)) / 2)); } .ftr-nav { margin-top: 12px; } .ftr-base { grid-column: 1 / -1; } }

/* scroll reveal (only when JS has run) */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .55s ease-out, transform .55s var(--pop); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .js .reveal { opacity: 1; transform: none; }
}
