/* Lingwa Explorers — shared styles for every page.
   Colours come from the game: teal #087F8C is its button and title colour,
   the sky, sea and sand match the beach scene, and the sunset band matches
   the main menu. */

@font-face { font-family: "Baloo 2"; font-weight: 500 800; font-display: swap;
  src: url(fonts/baloo2-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Baloo 2"; font-weight: 500 800; font-display: swap;
  src: url(fonts/baloo2-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Nunito"; font-weight: 400 800; font-display: swap;
  src: url(fonts/nunito-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Nunito"; font-weight: 400 800; font-display: swap;
  src: url(fonts/nunito-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

@font-face { font-family: "Request Coffee"; font-weight: 400; font-display: swap;
  src: url(fonts/request-coffee.woff2) format("woff2"); }

:root {
  --teal: #087f8c;
  --teal-dark: #065f69;
  --teal-soft: #e3f4f3;
  --cream: #fff8ec;
  --paper: #fffdf8;
  --sand: #ffe7a3;
  --sun: #ffc83d;
  --coral: #f26b4f;
  --coral-dark: #d9533a;
  --sky-top: #6fe3ea;
  --sky-bottom: #a6f6e6;
  --deep: #0b4f8a;
  --deep-2: #083a6b;
  --ink: #1e2b33;
  --muted: #56646c;
  --line: #eadfca;
  --radius: 22px;
  --shadow: 0 10px 30px -12px rgb(11 79 138 / .28);
  --wrap: 72rem;
  --title: "Request Coffee", "Baloo 2", system-ui, sans-serif;
  --head: "Baloo 2", "Nunito", system-ui, sans-serif;
  --body: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink);
  font: 400 1.0625rem/1.65 var(--body); overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal); text-underline-offset: .18em; }
a:hover { color: var(--teal-dark); }
h1, h2, h3 { font-family: var(--head); line-height: 1.1; letter-spacing: -.01em; margin: 0 0 .5em; color: var(--ink); }
h1 { font: 400 clamp(2.6rem, 6.5vw, 4.6rem)/1.05 var(--title); letter-spacing: .01em; }
h2 { font: 400 clamp(2rem, 4.3vw, 3rem)/1.1 var(--title); letter-spacing: .01em; }
h3 { font-size: 1.45rem; font-weight: 700; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--sun); outline-offset: 3px; border-radius: 6px; }
.wrap { width: min(100% - 2rem, var(--wrap)); margin-inline: auto; }
.narrow { width: min(100% - 2rem, 44rem); margin-inline: auto; }
.eyebrow { font: 700 .85rem/1 var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--coral-dark); margin-bottom: .9rem; }
.lead { font-size: 1.2rem; color: var(--muted); }
.center { text-align: center; }
.skip { position: absolute; left: -999px; top: .5rem; background: var(--ink); color: #fff; padding: .5rem 1rem; border-radius: 8px; z-index: 100; }
.skip:focus { left: .5rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Buttons: chunky, with the same pressed-down base as the game's menu buttons */
.btn { --b: var(--teal); --bd: var(--teal-dark);
  display: inline-flex; align-items: center; gap: .5rem; justify-content: center;
  font: 700 1.1rem/1 var(--head); color: #fff; background: var(--b); text-decoration: none;
  padding: .95rem 1.6rem .85rem; border: 0; border-radius: 999px; cursor: pointer;
  box-shadow: 0 5px 0 var(--bd); transition: transform .12s, box-shadow .12s, filter .12s; }
.btn:hover { color: #fff; filter: brightness(1.06); transform: translateY(-1px); box-shadow: 0 6px 0 var(--bd); }
.btn:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--bd); }
.btn.coral { --b: var(--coral); --bd: var(--coral-dark); }
.btn.light { --b: #fff; --bd: #d9ccb3; color: var(--teal-dark); }
.btn.light:hover { color: var(--teal-dark); }
.btn.small { font-size: 1rem; padding: .7rem 1.2rem .6rem; box-shadow: 0 4px 0 var(--bd); }

/* ---------- Header ---------- */
.site-header { position: absolute; inset: 0 0 auto; z-index: 20; }
.site-header.solid { position: sticky; top: 0; background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .9rem; }
.brand { display: flex; align-items: center; gap: .65rem; text-decoration: none; color: var(--ink);
  font: 800 1.35rem/1 var(--head); }
.brand img { width: 44px; height: 44px; border-radius: 12px; box-shadow: 0 3px 0 rgb(0 0 0 / .12); }
.brand:hover { color: var(--ink); }
.menu { display: flex; align-items: center; gap: .35rem; list-style: none; margin: 0; padding: 0; }
.menu a { display: block; padding: .55rem .9rem; border-radius: 999px; text-decoration: none;
  color: var(--ink); font: 700 1.05rem/1 var(--head); }
.menu a:hover { background: rgb(255 255 255 / .55); color: var(--teal-dark); }
.menu a[aria-current="page"] { background: #fff; color: var(--teal-dark); box-shadow: 0 3px 0 rgb(0 0 0 / .08); }
.menu .btn { margin-left: .4rem; color: #fff; }
.menu .btn:hover { background: var(--coral); color: #fff; }
.menu-toggle { display: none; }

@media (max-width: 760px) {
  .menu-toggle { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px;
    border: 0; border-radius: 14px; background: #fff; color: var(--teal-dark); box-shadow: 0 4px 0 rgb(0 0 0 / .1); cursor: pointer; }
  .menu-toggle svg { width: 26px; height: 26px; }
  .menu { position: absolute; top: calc(100% - .2rem); right: 1rem; left: 1rem; flex-direction: column; align-items: stretch;
    gap: .2rem; background: #fff; padding: .6rem; border-radius: var(--radius); box-shadow: var(--shadow);
    opacity: 0; visibility: hidden; transform: translateY(-8px); transition: .18s; }
  .menu.open { opacity: 1; visibility: visible; transform: none; }
  .menu a { padding: .9rem 1rem; font-size: 1.15rem; }
  .menu .btn { margin: .3rem 0 0; }
}

/* ---------- Hero scene (home) ---------- */
.hero { --sand-h: 24%; --sea-h: 30%; position: relative; min-height: max(640px, 100svh); overflow: hidden; isolation: isolate;
  background: linear-gradient(var(--sky-top), var(--sky-bottom) 55%); }
.hero-copy { position: relative; z-index: 6; text-align: center; padding: clamp(6.5rem, 14vh, 9rem) 1rem 0; }
.hero-copy h1 { color: var(--teal); text-shadow: 0 4px 0 #fff, 0 7px 14px rgb(6 95 105 / .25); margin-bottom: .2em; }
.hero-copy p { font-size: clamp(1.1rem, 2.2vw, 1.35rem); color: #1d4b52; max-width: 34rem; margin: 0 auto 1.4rem; font-weight: 600; }
.hero-ctas { display: flex; gap: .8rem; justify-content: center; flex-wrap: wrap; }

.scene { position: absolute; inset: 0; z-index: 1; }
.scene .layer { position: absolute; left: 0; right: 0; background-repeat: repeat-x; }
.scene .sea { bottom: calc(var(--sand-h) * .6); height: var(--sea-h);
  background-image: url(img/sea.webp); background-size: auto 100%; }
.scene .sand { bottom: 0; height: var(--sand-h); background-image: url(img/sand.webp); background-size: auto 100%;
  background-position: 0 0; }

.sprite { position: absolute; pointer-events: none; user-select: none; -webkit-user-drag: none; }
.cloud { width: clamp(140px, 18vw, 280px); opacity: .95; animation: float-x linear infinite; }
.cloud.c1 { top: 11%; left: -20%; animation-duration: 75s; }
.cloud.c2 { top: 30%; left: -20%; width: clamp(110px, 13vw, 200px); animation-duration: 105s; animation-delay: -60s; }
.cloud.c3 { top: 5%; left: -20%; width: clamp(90px, 10vw, 160px); animation-duration: 130s; animation-delay: -20s; opacity: .8; }
@keyframes float-x { to { transform: translateX(140vw); } }

.sailboat-wrap { position: absolute; z-index: 3; bottom: calc(var(--sand-h) * .6 + var(--sea-h) * .7); left: 0; width: 100%; height: 0;
  animation: sail 70s linear infinite; }
.sailboat { width: clamp(60px, 7vw, 110px); bottom: 0; animation: bob 3.2s ease-in-out infinite; }
@keyframes sail { from { transform: translateX(-12vw); } to { transform: translateX(110vw); } }
@keyframes bob { 50% { transform: translateY(-6px) rotate(-3deg); } }

/* Scene objects: decoration only */
.t-crab { width: clamp(90px, 10vw, 150px); bottom: 12%; left: 60%; }
.t-crab { position: absolute; z-index: 4; }
.t-crab .walker { position: relative; width: 100%; animation: walk 48s ease-in-out infinite; }
@keyframes walk { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(-12vw); } }
.t-ball { width: clamp(80px, 9vw, 135px); bottom: 3%; left: 80%; }
.t-castle { width: clamp(110px, 12vw, 185px); bottom: 7%; left: 11%; }
.t-bucket { width: clamp(55px, 6vw, 85px); bottom: 4%; left: 27%; }
.t-star { width: clamp(55px, 6vw, 90px); bottom: 3%; left: 44%; rotate: -12deg; }
.t-shell { width: clamp(45px, 4.5vw, 70px); bottom: 15%; left: 37%; }
.t-sun { width: clamp(90px, 11vw, 170px); top: 12%; right: 6%; z-index: 3; }
.t-island { width: clamp(180px, 24vw, 380px); left: 58%; bottom: calc(var(--sand-h) * .6 + var(--sea-h) * .8); z-index: 2; }

@media (max-width: 640px) {
  .hero { --sand-h: 20%; --sea-h: 24%; }
  .t-crab { left: 58%; bottom: 10%; }
  .t-ball { left: 72%; }
  .t-castle { left: 4%; }
  .t-bucket { left: 30%; }
  .t-star { left: 46%; }
  .t-shell { left: 34%; bottom: 13%; }
  .t-island { left: 50%; }
  .t-sun { top: auto; bottom: calc(var(--sand-h) + var(--sea-h) + 1%); right: auto; left: 5%; width: 80px; }
}

/* ---------- Sections ---------- */
.section { padding: clamp(4rem, 9vw, 7rem) 0; }
.section.cream { background: var(--cream); }
.intro { display: grid; gap: 2.5rem; grid-template-columns: 1.1fr 1fr; align-items: center; }
.intro .shot { border-radius: var(--radius); box-shadow: var(--shadow); border: 6px solid #fff; rotate: 1.5deg; }
@media (max-width: 860px) { .intro { grid-template-columns: 1fr; } .intro .shot { rotate: 0deg; } }

.cards { display: grid; gap: 1.4rem; grid-template-columns: repeat(3, 1fr); margin-top: 2.5rem; }
@media (max-width: 860px) { .cards { grid-template-columns: 1fr; } }
.card { background: #fff; border-radius: var(--radius); padding: 1.8rem 1.6rem 1.5rem; box-shadow: var(--shadow);
  border: 1px solid var(--line); position: relative; }
.card .art { width: 86px; height: 86px; object-fit: contain; margin-bottom: .8rem; }
.card p { color: var(--muted); margin: 0; }

.gallery { display: grid; grid-auto-flow: column; grid-auto-columns: min(78%, 30rem); gap: 1.2rem; overflow-x: auto;
  scroll-snap-type: x mandatory; padding: .5rem 1rem 1.5rem; margin-top: 2rem; scrollbar-width: thin; }
.gallery figure { margin: 0; scroll-snap-align: center; }
.gallery img { border-radius: 18px; border: 5px solid #fff; box-shadow: var(--shadow); aspect-ratio: 16/9; object-fit: cover; }
.gallery figcaption { font: 700 1.05rem/1.3 var(--head); margin-top: .7rem; color: var(--teal-dark); text-align: center; }

/* Underwater band */
.under { position: relative; overflow: hidden; color: #fff; isolation: isolate;
  background: linear-gradient(#27b7d8, var(--deep) 55%, var(--deep-2)); padding: clamp(4.5rem, 10vw, 8rem) 0 clamp(9rem, 16vw, 12rem); }
.under h2, .under h3 { color: #fff; }
.under .lead { color: #d6f3fb; }
.under .eyebrow { color: #ffd66b; }
.under .swimmer { position: absolute; z-index: -1; animation: swim linear infinite; }
.under .swimmer img { animation: bob 3s ease-in-out infinite; }
.under .rtl { animation-name: swim-back; }
.under .rtl img { transform: scaleX(-1); }
@keyframes swim { from { transform: translateX(-30vw); } to { transform: translateX(130vw); } }
@keyframes swim-back { from { transform: translateX(130vw); } to { transform: translateX(-30vw); } }
.under .floor { position: absolute; z-index: -1; bottom: -6px; }
.bubble { position: absolute; z-index: -1; bottom: -40px; width: 26px; opacity: .7; animation: rise linear infinite; }
@keyframes rise { to { transform: translateY(-120vh) translateX(20px); opacity: 0; } }

.pairs { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1.6rem; }
.pair { background: rgb(255 255 255 / .12); border: 1px solid rgb(255 255 255 / .25); border-radius: 999px;
  padding: .5rem 1rem .45rem; font: 700 1.05rem/1 var(--head); color: #fff; cursor: pointer; transition: background .15s; }
.pair:hover, .pair.on { background: rgb(255 255 255 / .26); }
.pair em { font-style: normal; color: #ffd66b; margin-left: .35rem; }
.section:not(.under) .pair { background: #fff; color: var(--ink); border-color: var(--line); }
.section:not(.under) .pair em { color: var(--coral-dark); }

/* Promise list */
.promises { display: grid; gap: 1rem 2rem; grid-template-columns: repeat(2, 1fr); margin-top: 2rem; }
@media (max-width: 700px) { .promises { grid-template-columns: 1fr; } }
.promise { display: flex; gap: 1rem; align-items: flex-start; }
.promise .tick { flex: 0 0 44px; height: 44px; border-radius: 14px; background: var(--teal-soft); color: var(--teal);
  display: grid; place-items: center; }
.promise .tick svg { width: 24px; height: 24px; }
.promise h3 { font-size: 1.2rem; margin: .1rem 0 .2rem; }
.promise p { color: var(--muted); margin: 0; }

/* Sunset call to action, like the main menu */
.sunset { position: relative; overflow: hidden; isolation: isolate; color: #fff; text-align: center;
  background: linear-gradient(#5b8fd6, #9a6fb4 45%, #e4577a); padding: clamp(4.5rem, 9vw, 7rem) 1rem clamp(8rem, 14vw, 11rem); }
.sunset h2 { color: #fff; text-shadow: 0 3px 0 rgb(0 0 0 / .12); }
.sunset p { color: #fff3f6; max-width: 36rem; margin: 0 auto 1.6rem; font-size: 1.15rem; }
.sunset .moon { width: clamp(60px, 7vw, 100px); top: 12%; left: 8%; }
.sunset .twinkle { width: 30px; animation: twinkle 3s ease-in-out infinite; }
@keyframes twinkle { 50% { opacity: .35; transform: scale(.8) rotate(20deg); } }
.sunset .boat { width: clamp(150px, 20vw, 260px); bottom: 12px; left: 4%; animation: bob 4s ease-in-out infinite; z-index: -1; }
.sunset .waves { position: absolute; z-index: -2; left: 0; right: 0; bottom: 0; height: 70px;
  background: linear-gradient(#1f63b8, #174f97); }
.sunset .waves::before { content: ""; position: absolute; left: 0; right: 0; top: -18px; height: 20px;
  background: radial-gradient(22px 14px at 22px 20px, #1f63b8 98%, transparent) 0 0 / 44px 20px repeat-x; }

/* ---------- Inner pages ---------- */
.page-hero { background: linear-gradient(var(--sky-top), var(--sky-bottom)); padding: 8rem 0 4rem; position: relative; overflow: hidden; }
.page-hero h1 { color: var(--teal); text-shadow: 0 3px 0 #fff; }
.page-hero p:not(.eyebrow) { color: #1d4b52; font-weight: 600; font-size: 1.2rem; max-width: 36rem; }
.page-hero .sprite { opacity: .95; }
@media (max-width: 640px) { .page-hero { padding: 6rem 0 3.5rem; } .page-hero .sprite { display: none; } }
.page-hero::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 40px;
  background: radial-gradient(30px 22px at 30px 0, transparent 97%, var(--paper)) 0 0 / 60px 40px repeat-x; }
.prose h2 { font: 800 1.7rem/1.15 var(--head); margin-top: 2.4rem; }
.prose h3 { font-size: 1.25rem; margin-top: 1.6rem; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: .35rem; }
.note { background: var(--teal-soft); border-radius: 16px; padding: 1.1rem 1.3rem; border-left: 6px solid var(--teal); }
.note p:last-child { margin: 0; }

.about-hero { position: relative; border-radius: calc(var(--radius) + 6px); overflow: hidden; box-shadow: var(--shadow); border: 6px solid #fff; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; gap: 2rem; } }
.people { display: grid; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); gap: 1.2rem; margin-top: 1.5rem; }
.person { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem 1.4rem; }
.person b { display: block; font: 800 1.25rem/1.2 var(--head); }
.person span { color: var(--muted); }
.credits { columns: 2 18rem; gap: 2rem; color: var(--muted); font-size: .98rem; }
.credits p { break-inside: avoid; }

/* Contact form */
.contact-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 2.5rem; align-items: start; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }
.form { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.4rem, 4vw, 2.2rem); box-shadow: var(--shadow); }
.field { margin-bottom: 1.1rem; }
.field label, .field legend { display: block; font: 700 1.05rem/1.2 var(--head); margin-bottom: .4rem; }
.field small { display: block; color: var(--muted); margin-top: .35rem; font-size: .9rem; }
.field input, .field textarea, .field select { width: 100%; font: inherit; color: var(--ink); background: var(--paper);
  border: 2px solid var(--line); border-radius: 14px; padding: .75rem .9rem; transition: border-color .15s, box-shadow .15s; }
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 4px rgb(8 127 140 / .15); }
.field textarea { min-height: 9rem; resize: vertical; }
.topics { display: grid; grid-template-columns: repeat(2, 1fr); gap: .6rem; border: 0; padding: 0; margin: 0 0 1.1rem; }
.topics legend { grid-column: 1 / -1; font: 700 1.05rem/1.2 var(--head); margin-bottom: .4rem; padding: 0; }
.topics label { display: flex; align-items: center; gap: .55rem; font: 700 1rem/1.2 var(--head); background: var(--paper);
  border: 2px solid var(--line); border-radius: 14px; padding: .7rem .8rem; cursor: pointer; margin: 0; }
.topics input { accent-color: var(--teal); width: 1.1rem; height: 1.1rem; margin: 0; }
.topics label:has(input:checked) { border-color: var(--teal); background: var(--teal-soft); color: var(--teal-dark); }
@media (max-width: 480px) { .topics { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -9999px; }
.beta-only { display: none; }
.form[data-topic="beta"] .beta-only { display: block; }
.status { display: none; border-radius: 14px; padding: 1rem 1.1rem; margin-top: 1rem; font-weight: 600; }
.status.ok { display: block; background: #e5f6ea; color: #1d6b37; }
.status.err { display: block; background: #fde9e4; color: #9a3421; }
.side-card { background: var(--cream); border-radius: var(--radius); padding: 1.6rem; }
.side-card h3 { font-size: 1.25rem; }
.side-card .mail { font: 800 1.2rem/1.2 var(--head); word-break: break-all; }

/* ---------- Footer ---------- */
.site-footer { background: #0d3d45; color: #cfe6e8; padding: 3.5rem 0 2rem; font-size: .98rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.foot { display: flex; flex-wrap: wrap; gap: 2rem 3rem; justify-content: space-between; }
.foot .brand { color: #fff; margin-bottom: .8rem; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; }
.foot h4 { font: 800 1rem/1 var(--head); color: #8fd4d9; letter-spacing: .06em; text-transform: uppercase; margin: .3rem 0 .9rem; }
.legal { border-top: 1px solid rgb(255 255 255 / .12); margin-top: 2.5rem; padding-top: 1.4rem; font-size: .88rem; color: #9fc3c7; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0s !important; animation-iteration-count: 1 !important; transition-duration: 0s !important; }
  .cloud, .sailboat-wrap, .under .swimmer, .bubble { display: none; }
  html { scroll-behavior: auto; }
}
