/* Piporia website. Pixel look from the app's pixel kit: dark outline, parchment panels,
   blue dialogue box, Pixelify Sans. Every picture is pixel art, so it scales without smoothing. */
@font-face { font-family: "Pixelify Sans"; src: url(/assets/fonts/PixelifySans-Regular.ttf) format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Pixelify Sans"; src: url(/assets/fonts/PixelifySans-Bold.ttf) format("truetype"); font-weight: 700; font-display: swap; }

:root {
  --outline: #2b1d2e;
  --parchment: #fbf3dc;
  --parchment-shade: #e2cfa3;
  --ink: #5a4030;
  --paper: #fffaf0;
  --dialogue: #3d4fb6;
  --dialogue-edge: #9fb0ff;
  --go: #7bd35a;
  --go-dark: #4e9a35;
  --gold: #ffd45c;
  --heart: #e2485b;
  --grass: #8fd16a;
  --fire: #f2a36b;
  --water: #7cc4f2;
  --electric: #ffe066;
  --night: #1d2245;
  --px: 4px; /* one "pixel" of UI chrome */
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { margin: 0; background: var(--night); color: var(--ink); font: 400 18px/1.5 "Pixelify Sans", ui-monospace, monospace; -webkit-font-smoothing: antialiased; font-variant-ligatures: none; font-feature-settings: "liga" 0, "clig" 0; }
img, .sprite { image-rendering: pixelated; image-rendering: crisp-edges; }
a { color: inherit; }
h1, h2, h3 { font-weight: 700; line-height: 1.15; margin: 0; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; z-index: 99; background: var(--gold); padding: 8px 12px; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.center { text-align: center; }
.gold { color: var(--gold); }

/* Pixel boxes: a hard outline with notched corners, the way the app's PixelPanel looks. */
.panel, .btn, .dialogue, .panel-dark, .store {
  border: var(--px) solid var(--outline);
  box-shadow: inset calc(var(--px) * -1) calc(var(--px) * -1) 0 rgba(0,0,0,.12), 0 var(--px) 0 var(--outline);
  clip-path: polygon(var(--px) 0, calc(100% - var(--px)) 0, calc(100% - var(--px)) var(--px), 100% var(--px), 100% calc(100% - var(--px)), calc(100% - var(--px)) calc(100% - var(--px)), calc(100% - var(--px)) 100%, var(--px) 100%, var(--px) calc(100% - var(--px)), 0 calc(100% - var(--px)), 0 var(--px), var(--px) var(--px));
}
.panel { background: var(--parchment); padding: 24px; }
.panel-dark { background: #213a7a; padding: 12px; }

.btn { display: inline-block; padding: 10px 22px; background: var(--paper); color: var(--outline); font-weight: 700; text-decoration: none; transition: transform .12s steps(2); }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(2px); }
.btn-go { background: var(--go); }

/* Header */
.nav { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 24px; padding: 8px 24px; background: rgba(29,34,69,.92); backdrop-filter: blur(4px); border-bottom: var(--px) solid var(--outline); }
.nav-logo img { display: block; width: 126px; height: auto; }
.nav nav { display: flex; gap: 20px; margin-left: auto; }
.nav nav a { color: #fff1e8; text-decoration: none; font-weight: 700; }
.nav nav a:hover { color: var(--gold); }
.nav-cta { padding: 6px 16px; }
@media (max-width: 820px) { .nav nav { display: none; } .nav-cta { margin-left: auto; } }

/* Hero */
.hero { position: relative; overflow: hidden; padding: 56px 0 96px; color: #fff; background: var(--sky, linear-gradient(#7cc4f2, #bfe6ff)); transition: background 2s; }
.hero-inner { position: relative; z-index: 2; max-width: 1120px; margin: 0 auto; padding: 0 24px; display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; }
.kicker { display: inline-block; margin: 0 0 14px; padding: 4px 10px; background: var(--outline); color: var(--gold); font-weight: 700; font-size: 15px; }
.hero h1 { font-size: clamp(36px, 5.2vw, 60px); color: #fff; text-shadow: 0 4px 0 var(--outline), 4px 0 0 var(--outline), -4px 0 0 var(--outline), 0 -4px 0 var(--outline), 4px 4px 0 var(--outline), 0 8px 0 rgba(43,29,46,.35); }
.lede { font-size: 21px; max-width: 34em; margin: 18px 0 22px; color: #fff; text-shadow: 2px 0 0 var(--outline), -2px 0 0 var(--outline), 0 2px 0 var(--outline), 0 -2px 0 var(--outline), 2px 2px 0 var(--outline); }
.hero-buttons { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 22px; }

.dialogue { display: flex; gap: 14px; align-items: flex-start; background: var(--dialogue); color: #fff; padding: 14px 18px 16px; outline: 2px solid var(--dialogue-edge); outline-offset: -8px; max-width: 560px; }
.dialogue-face { flex: none; width: 64px; height: auto; margin-top: -4px; object-fit: cover; object-position: top; height: 72px; background: #7cc4f2; border: 3px solid var(--outline); }
.dialogue-name { margin: 0; color: var(--gold); font-weight: 700; }
.dialogue-text { margin: 2px 0 0; min-height: 4.5em; }
.dialogue-text::after { content: "▼"; display: inline-block; margin-left: 6px; font-size: 12px; animation: bob 1s steps(2) infinite; }
.typing .dialogue-text::after { content: ""; }

.phone { justify-self: center; padding: 12px; background: var(--outline); border-radius: 28px; box-shadow: 0 12px 0 rgba(43,29,46,.35); }
.camp { position: relative; width: 300px; height: 600px; border-radius: 18px; overflow: hidden; }
.camp-bg { width: 100%; height: 100%; display: block; }
.tint { position: absolute; inset: 0; background: var(--tint, transparent); mix-blend-mode: multiply; transition: background 2s; pointer-events: none; }
.fire-glow { position: absolute; left: 156px; top: 418px; width: 160px; height: 120px; transform: translate(-50%, -50%); background: radial-gradient(closest-side, rgba(255,190,90,var(--glow, .25)), transparent); mix-blend-mode: screen; animation: flicker 1.6s steps(4) infinite; }
.embers i { position: absolute; left: 154px; top: 400px; width: 4px; height: 4px; background: #ffd45c; opacity: 0; animation: ember 2.4s linear infinite; }
.embers i:nth-child(2) { left: 160px; animation-delay: .5s; background: #ff9a4a; }
.embers i:nth-child(3) { left: 148px; animation-delay: 1s; }
.embers i:nth-child(4) { left: 166px; animation-delay: 1.5s; background: #ff9a4a; }
.embers i:nth-child(5) { left: 152px; animation-delay: 2s; }
.camp-pip { position: absolute; left: 70px; top: 430px; --scale: 1.25; }
.camp-wren { position: absolute; left: 228px; top: 382px; width: 40px; height: 65px; animation: breathe 3s steps(2) infinite; }
.clock { position: absolute; top: 10px; right: 12px; padding: 2px 8px; background: rgba(43,29,46,.75); color: #fff; font-size: 14px; }

/* Sky: clouds and night stars */
.sky { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.cloud { position: absolute; width: 96px; height: 24px; background: #fff; opacity: var(--cloud, .9); box-shadow: 24px -12px 0 #fff, 48px -12px 0 #fff, 48px 0 0 #fff, 72px 0 0 #fff, -24px 0 0 #fff; animation: drift 90s linear infinite; }
.c1 { top: 70px; left: -200px; }
.c2 { top: 190px; left: -200px; animation-delay: -35s; transform: scale(.7); }
.c3 { top: 320px; left: -200px; animation-delay: -60s; }
.stars { position: absolute; inset: 0; opacity: var(--stars, 0); transition: opacity 2s; background-image: radial-gradient(2px 2px at 10% 20%, #fff 50%, transparent 51%), radial-gradient(2px 2px at 30% 8%, #fff 50%, transparent 51%), radial-gradient(2px 2px at 55% 30%, #fff 50%, transparent 51%), radial-gradient(2px 2px at 80% 12%, #fff 50%, transparent 51%), radial-gradient(2px 2px at 92% 40%, #fff 50%, transparent 51%), radial-gradient(2px 2px at 20% 50%, #fff 50%, transparent 51%), radial-gradient(2px 2px at 70% 55%, #fff 50%, transparent 51%); animation: twinkle 3s steps(2) infinite; }
.grass-edge { position: absolute; left: 0; right: 0; bottom: 0; height: 40px; z-index: 1; background: linear-gradient(#6fbf4f 0 16px, #4e9a35 16px); border-top: var(--px) solid var(--outline); }
.leaves i { position: absolute; top: -20px; z-index: 3; width: 8px; height: 8px; background: #8fd16a; box-shadow: 4px 4px 0 #4e9a35; animation: fall 12s linear infinite; }
.leaves i:nth-child(1) { left: 8%; animation-delay: 0s; }
.leaves i:nth-child(2) { left: 22%; animation-delay: -4s; background: #ffd45c; box-shadow: 4px 4px 0 #e89a3a; }
.leaves i:nth-child(3) { left: 37%; animation-delay: -8s; }
.leaves i:nth-child(4) { left: 51%; animation-delay: -2s; background: #f2a36b; box-shadow: 4px 4px 0 #c0603a; }
.leaves i:nth-child(5) { left: 64%; animation-delay: -6s; }
.leaves i:nth-child(6) { left: 77%; animation-delay: -10s; background: #ffd45c; box-shadow: 4px 4px 0 #e89a3a; }
.leaves i:nth-child(7) { left: 88%; animation-delay: -3s; }
.leaves i:nth-child(8) { left: 95%; animation-delay: -7s; }

/* Sprites: horizontal strips of square frames (--f px each, --n frames), played in steps. */
.sprite { --scale: 2; width: calc(var(--f) * var(--scale) * 1px); height: calc(var(--f) * var(--scale) * 1px); background: var(--src) 0 0 / calc(var(--f) * var(--n) * var(--scale) * 1px) 100% no-repeat; animation: play 1.4s steps(9) infinite; }
.sprite.big { --scale: 2.5; }

/* Bands */
.band { padding: 80px 0; position: relative; }
.band-parchment { background: var(--parchment-shade); }
.band-glade { background: linear-gradient(rgba(29,34,69,.55), rgba(29,34,69,.7)), url(/assets/scenes/bg_starter_glade.png) center / cover; }
.band-sea { background: #2a52a8; }
.band-night { background: var(--night); }
.band-dawn { background: linear-gradient(rgba(29,34,69,.35), rgba(29,34,69,.75)), url(/assets/scenes/bg_title.png) center 30% / cover; padding: 110px 0; }
.title { font-size: clamp(30px, 4vw, 44px); color: var(--outline); text-align: center; }
.title.light { color: #fff; text-shadow: 0 4px 0 var(--outline); }
.split .title { text-align: left; }
.sub { text-align: center; max-width: 40em; margin: 10px auto 40px; font-size: 20px; }
.sub.light, .ticks.light { color: #fff1e8; }

.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.steps h3 { font-size: 24px; color: var(--outline); margin: 8px 0; }
.step-no { display: inline-grid; place-items: center; width: 40px; height: 40px; background: var(--gold); color: var(--outline); font-weight: 700; font-size: 22px; border: 3px solid var(--outline); }
.gentle { text-align: center; margin: 32px 0 0; font-weight: 700; color: var(--outline); }

.starters { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.starter { text-align: center; }
.starter .sprite { margin: 0 auto 8px; }
.starter-art { height: 150px; display: grid; place-items: end center; margin: -24px -24px 16px; padding-bottom: 6px; }
.starter h3 { font-size: 26px; color: var(--outline); display: inline; }
.tag { display: inline-block; margin-left: 8px; padding: 2px 8px; font-size: 14px; font-weight: 700; color: var(--outline); border: 2px solid var(--outline); vertical-align: middle; }
.el-grass .tag { background: var(--grass); } .el-fire .tag { background: var(--fire); } .el-water .tag { background: var(--water); } .el-electric .tag { background: var(--electric); }
.el-grass { background: linear-gradient(#e4f6d8 0 150px, var(--parchment) 150px); }
.el-fire { background: linear-gradient(#ffe6d2 0 150px, var(--parchment) 150px); }
.el-water { background: linear-gradient(#dcf0ff 0 150px, var(--parchment) 150px); }
.el-electric { background: linear-gradient(#fff4c2 0 150px, var(--parchment) 150px); }
.forms { font-size: 15px; color: #8a6a4a; margin-bottom: 0; }
.grow { display: flex; justify-content: center; align-items: flex-end; gap: 20px; margin-top: 44px; }
.grow img:nth-of-type(1) { width: 116px; height: auto; } .grow img:nth-of-type(2) { width: 152px; height: auto; } .grow img:nth-of-type(3) { width: 192px; height: auto; }
.grow .arrow { color: var(--gold); font-size: 48px; font-weight: 700; padding-bottom: 40px; animation: nudge 1.2s steps(2) infinite; }

.map { position: relative; }
.map-inner { position: relative; }
.map-inner img { display: block; width: 100%; height: auto; }
.pins { position: absolute; inset: 0; }
.pin { position: absolute; width: clamp(9px, 1.9vw, 21px); height: clamp(10px, 2.2vw, 24px); transform: translate(-50%, -100%); background: url(/assets/logo/pin.png) 0 0 / 100% 100% no-repeat; border: 0; padding: 0; cursor: pointer; image-rendering: pixelated; animation: pinbob 2.4s steps(2) infinite; animation-delay: var(--d, 0s); }
.pin:hover, .pin:focus-visible, .pin.on { background-image: url(/assets/logo/pin-gold.png); z-index: 2; outline: none; }
.map-tip { margin: 10px 0 0; color: #fff; text-align: center; font-weight: 700; min-height: 1.5em; }
.places { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; margin-top: 32px; }
.place { margin: 0; position: relative; border: var(--px) solid var(--outline); overflow: hidden; aspect-ratio: 3 / 4; }
.place img { width: 100%; height: 100%; object-fit: cover; object-position: center 60%; display: block; transition: transform .6s; }
.place:hover img { transform: scale(1.06); }
.place figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 8px 10px; background: rgba(43,29,46,.85); color: #fff; font-weight: 700; }
.place small, .pipgrid small { display: block; font-weight: 400; opacity: .8; font-size: 14px; }

.pipgrid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.pipgrid figure { margin: 0; background: var(--parchment); border: var(--px) solid var(--outline); padding: 10px 6px; text-align: center; display: grid; justify-items: center; align-content: end; min-height: 200px; }
.pipgrid img { width: auto; height: 110px; max-width: 100%; object-fit: contain; animation: peek 3s steps(2) infinite; animation-delay: var(--d, 0s); }
.pipgrid figure:nth-child(3n) img { --d: -1s; } .pipgrid figure:nth-child(3n+1) img { --d: -2s; }
.mystery { position: relative; }
.mystery::before { content: "?"; position: absolute; top: 8px; right: 10px; width: 26px; height: 26px; display: grid; place-items: center; background: var(--gold); color: var(--outline); font-weight: 700; border: 3px solid var(--outline); animation: bob 1.2s steps(2) infinite; }
.grow img:nth-of-type(n+2) { filter: drop-shadow(0 0 6px rgba(255,212,92,.6)); }
.pipgrid figcaption { font-weight: 700; color: var(--outline); margin-top: 6px; font-size: 16px; }
.shots { display: flex; justify-content: center; gap: 24px; margin-top: 44px; }
.shots img, .shot-one { width: 260px; height: auto; border: 10px solid var(--outline); border-radius: 26px; image-rendering: auto; background: var(--outline); }

.split { display: grid; grid-template-columns: 1fr auto; gap: 48px; align-items: center; }
.ticks { list-style: none; padding: 0; margin: 20px 0 0; }
.ticks li { position: relative; padding-left: 32px; margin: 10px 0; font-size: 19px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 7px; width: 16px; height: 16px; background: var(--go); border: 3px solid var(--outline); }

.plans { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; max-width: 820px; margin: 0 auto; }
.plan h3 { font-size: 28px; color: var(--outline); }
.price { font-size: 44px; font-weight: 700; color: var(--outline); margin: 6px 0 0; }
.price small { font-size: 18px; font-weight: 400; }
.price-alt { margin: 0; }
.plan-plus { background: #fff4c2; position: relative; }
.ribbon { position: absolute; top: 18px; right: 18px; background: var(--heart); color: #fff; font-weight: 700; padding: 2px 10px; border: 3px solid var(--outline); }

.stores { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }
.store { display: inline-block; padding: 12px 22px; background: var(--outline); color: #fff; font-weight: 700; font-size: 20px; border-color: #fff1e8; }
.store small { display: block; font-size: 13px; color: var(--gold); font-weight: 400; }
#soon img { width: 252px; height: auto; margin-bottom: 16px; }

.foot { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; padding: 28px 24px; background: var(--outline); color: #cfc3d8; font-size: 15px; }
.foot img { width: 112px; height: auto; }
.foot nav { display: flex; gap: 18px; }
.foot a { color: #fff1e8; }
.foot p { margin: 0 0 0 auto; }

/* Legal pages */
.legal { background: var(--parchment-shade); padding: 48px 0 80px; }
.legal .panel { max-width: 820px; margin: 0 auto; padding: 36px 40px; }
.legal h1 { font-size: 38px; color: var(--outline); }
.legal h2 { font-size: 24px; color: var(--outline); margin: 28px 0 6px; }
.legal p, .legal li { font-size: 17px; }
.legal .updated { color: #8a6a4a; }

@keyframes play { to { background-position-x: calc(var(--f) * var(--n) * var(--scale) * -1px); } }
@keyframes flicker { 0% { opacity: .85; } 25% { opacity: 1; } 50% { opacity: .75; } 75% { opacity: .95; } }
@keyframes ember { 0% { opacity: 0; transform: translate(0, 0); } 15% { opacity: 1; } 100% { opacity: 0; transform: translate(8px, -70px); } }
@keyframes breathe { 50% { transform: translateY(1px); } }
@keyframes drift { to { transform: translateX(calc(100vw + 400px)); } }
@keyframes twinkle { 50% { opacity: calc(var(--stars, 0) * .6); } }
@keyframes fall { 0% { transform: translate(0, 0) rotate(0); } 25% { transform: translate(30px, 25vh) rotate(90deg); } 50% { transform: translate(-10px, 50vh) rotate(180deg); } 75% { transform: translate(25px, 75vh) rotate(270deg); } 100% { transform: translate(0, 105vh) rotate(360deg); } }
@keyframes peek { 50% { transform: translateY(-3px); } }
@keyframes bob { 50% { transform: translateY(3px); } }
@keyframes nudge { 50% { transform: translateX(4px); } }
@keyframes pinbob { 50% { transform: translate(-50%, calc(-100% - 2px)); } }

@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; }
  .phone { zoom: .85; }
  .starters { grid-template-columns: repeat(2, 1fr); }
  .pipgrid { grid-template-columns: repeat(3, 1fr); }
  .places { grid-template-columns: repeat(3, 1fr); }
  .places .place:nth-child(n+4) { display: none; }
  .steps, .plans, .split { grid-template-columns: 1fr; }
  .shot-one { justify-self: center; }
}
@media (max-width: 560px) {
  body { font-size: 17px; }
  .starters { grid-template-columns: 1fr; }
  .pipgrid { grid-template-columns: repeat(2, 1fr); }
  .places { grid-template-columns: repeat(2, 1fr); }
  .places .place:nth-child(n+3) { display: none; }
  .phone { zoom: .75; }
  .shots img { width: 44%; }
  .foot p { margin: 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
