/* Folkard Language Games: shared styles for the landing page and privacy notice.
   Colours come from the logo: sky-blue background, navy lettering with an orange outline,
   sunshine-yellow underline, and the globe's green and blue. Phone first; wider screens
   get more columns further down. One light look on purpose, because the logo artwork
   has its sky-blue background built in. */

@font-face {
  font-family: "Fredoka";
  src: url("brand/fredoka-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  --sky: #97dbfd;        /* the logo's background */
  --sky-soft: #dff3fe;
  --joga-sky: #ace3fb;   /* the Joga! logo's background */
  --cream: #fffaf0;
  --white: #ffffff;
  --navy: #15264f;       /* the logo's lettering */
  --navy-soft: #4a5a80;
  --orange: #f7a21b;     /* the logo's outline */
  --orange-deep: #d7820a;
  --sun: #ffd23c;
  --green: #5fb83a;
  --blue: #1a6fd1;
  --line: #f1e3c8;
  --green-deep: #2f7d1c;
  --error: #b3261e;
  --display: "Fredoka", ui-rounded, "Segoe UI", system-ui, sans-serif;
  --body: ui-rounded, "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  --radius: 24px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--navy);
  font: 17px/1.55 var(--body);
}

a { color: var(--blue); font-weight: 600; }
a:focus-visible, .btn:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; border-radius: 8px; }

.wrap { max-width: 1040px; margin: 0 auto; padding-inline: 16px; }

h1, h2, h3 { font-family: var(--display); font-weight: 700; text-wrap: balance; }

/* Hero: the logo sits on its own sky blue, with soft edges so it melts into the page */
.hero { background: var(--sky); padding-block: 12px 56px; text-align: center; }
.hero-logo {
  display: block; width: 100%; max-width: 560px; height: auto; margin: 0 auto;
  -webkit-mask-image: radial-gradient(ellipse 72% 70% at 50% 50%, #000 62%, transparent 100%);
          mask-image: radial-gradient(ellipse 72% 70% at 50% 50%, #000 62%, transparent 100%);
}
.hero .tagline { font: italic 500 clamp(16px, 4.4vw, 20px)/1.2 var(--display); color: var(--navy-soft); margin: calc(min(100vw - 32px, 560px) * -0.06) auto 36px; position: relative; /* tucked into the empty sky under the logo */ letter-spacing: 0.01em; }
.hero h1 { font-size: clamp(30px, 8vw, 50px); line-height: 1.08; margin: 4px 0 10px; }
.hero h1 em { font-style: normal; color: var(--white); -webkit-text-stroke: 0; text-shadow: 0 3px 0 var(--orange), 0 -2px 0 var(--orange), 2px 0 0 var(--orange), -2px 0 0 var(--orange); }
.hero p { font-size: 19px; margin: 0 auto; max-width: 30em; color: var(--navy); }
.pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 20px 0 0; padding: 0; list-style: none; }
.pills li { background: var(--white); border: 2px solid var(--orange); border-radius: 999px; padding: 5px 14px; font-size: 15px; font-weight: 700; }

/* Game cards on cream, which curves up over the sky */
.games { background: var(--cream); border-radius: 32px 32px 0 0; margin-top: -28px; padding-block: 32px 8px; position: relative; }
.games h2 { font-size: 26px; margin: 0 0 16px; }
.cards { display: grid; gap: 16px; grid-template-columns: 1fr; }
.card { background: var(--white); border: 2px solid var(--line); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.card-top { display: flex; align-items: center; gap: 12px; }
.flags { display: flex; flex-shrink: 0; }
.flags img { width: 42px; height: 31px; border-radius: 7px; object-fit: cover; box-shadow: 0 0 0 2px var(--white); }
.flags img + img { margin-left: -10px; }
.card h3 { margin: 0; font-size: 28px; line-height: 1.05; }
.card .lang { margin: 2px 0 0; color: var(--navy-soft); font-size: 15px; font-weight: 700; }
.card p { margin: 0; }
.card.featured { border: 3px solid var(--orange); box-shadow: 0 6px 0 var(--orange-deep); }
.card.featured h3 { color: var(--navy); }
/* Joga! logo on its own sky tile (the artwork has a sky-blue background built in) */
.joga-head { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.joga-logo { margin: 0; background: var(--joga-sky); border-radius: 18px; overflow: hidden; width: 100%; max-width: 320px; }
.joga-logo img { display: block; width: 100%; height: auto; aspect-ratio: 2 / 1; object-fit: cover; }
.card .lang.lang { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 16px; }
.card .lang .flags img { width: 34px; height: 25px; }
.card.soon { background: var(--sky-soft); border-color: transparent; }
.card.soon h3 { font-size: 22px; }
.card.soon .flags img { filter: saturate(0.5); opacity: 0.85; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 54px; padding: 0 28px; border-radius: 999px;
  background: var(--orange); color: var(--navy);
  font: 700 20px/1 var(--display); text-decoration: none;
  box-shadow: 0 5px 0 var(--orange-deep);
  transition: transform 0.08s, box-shadow 0.08s;
}
.btn:hover { background: var(--sun); }
.btn:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--orange-deep); }
.badge { align-self: flex-start; background: var(--white); color: var(--navy-soft); border-radius: 999px; padding: 4px 12px; font-size: 14px; font-weight: 700; }

/* Footer */
.site-footer { margin-top: 48px; padding-block: 28px 40px; background: var(--navy); color: var(--sky-soft); font-size: 15px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-bottom: 10px; }
.site-footer a { color: var(--sun); }
.site-footer .email { color: var(--sun); font-weight: 600; }
.site-footer p { margin: 0; }

/* Privacy notice and other text pages */
.page-header { background: var(--sky); padding-block: 4px; }
.page-header a { display: inline-block; }
.page-header img { display: block; height: 120px; width: auto;
  -webkit-mask-image: radial-gradient(ellipse 70% 68% at 50% 50%, #000 60%, transparent 100%);
          mask-image: radial-gradient(ellipse 70% 68% at 50% 50%, #000 60%, transparent 100%); }
.prose { max-width: 40em; padding-block: 24px 0; }
.prose h1 { font-size: clamp(30px, 7vw, 42px); line-height: 1.1; margin: 8px 0 6px; }
.prose h2 { font-size: 22px; margin: 30px 0 6px; }
.prose p, .prose li { margin: 0 0 10px; }
.updated { color: var(--navy-soft); font-size: 15px; margin-top: 0; }

/* Top navigation (landing page hero and inner-page headers) */
.top-nav { display: flex; gap: 6px; }
.top-nav a { color: var(--navy); text-decoration: none; font: 600 16px/1 var(--display); padding: 9px 14px; border-radius: 999px; background: rgba(255, 255, 255, 0.7); }
.top-nav a:hover, .top-nav a[aria-current="page"] { background: var(--white); box-shadow: 0 0 0 2px var(--orange); }
.hero .top-nav { justify-content: flex-end; padding-top: 4px; }
.page-header-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 12px; }
.page-header-row .top-nav { margin-left: auto; } /* stays on the right even when it wraps under the logo */
@media (max-width: 480px) {
  .page-header img { height: 88px; }
  .top-nav { gap: 4px; }
  .top-nav a { font-size: 15px; padding: 8px 11px; }
}

/* About page */
.about-intro { display: flex; align-items: center; gap: 18px; margin-top: 4px; }
.about-intro h1 { margin: 0; }
.eyebrow { margin: 0 0 4px; font: 700 14px/1 var(--display); letter-spacing: 0.08em; text-transform: uppercase; color: var(--orange-deep); }
.photo { position: relative; margin: 22px 0; border-radius: var(--radius); overflow: hidden; background: var(--sky-soft); }
.photo img { display: block; width: 100%; height: 100%; object-fit: cover; position: relative; z-index: 1; }
.photo-empty { position: absolute; inset: 0; display: grid; place-items: center; padding: 8px; text-align: center; font-size: 14px; font-weight: 600; color: var(--navy-soft); border: 2px dashed var(--sky); border-radius: inherit; }
.photo.portrait { flex: 0 0 auto; width: 104px; height: 104px; margin: 0; border-radius: 50%; border: 4px solid var(--orange); }
.photo.portrait .photo-empty { font-size: 11px; border: 0; }
.prose.about { max-width: none; }
.travel-strip { list-style: none; padding: 0; margin: 24px 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.travel-strip li { margin: 0; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.travel-strip img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 18px; border: 3px solid var(--white); box-shadow: 0 2px 0 var(--line); }
.travel-strip span { font-size: 15px; font-weight: 600; line-height: 1.25; color: var(--navy-soft); text-align: center; }
.callout { font: 700 22px/1.3 var(--display); color: var(--navy); }
.mission { font: 600 20px/1.4 var(--display); background: var(--white); border: 3px solid var(--orange); border-radius: var(--radius); padding: 16px 18px; }
.signoff { font: 700 22px/1.2 var(--display); margin-top: 28px !important; }
.tagline-end { font-style: italic; color: var(--navy-soft); }

/* Feedback page */
.prose.wide { max-width: none; }
.feedback-layout { display: grid; gap: 24px; margin-top: 8px; }
.feedback-card { background: var(--white); border: 3px solid var(--orange); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.field { display: flex; flex-direction: column; gap: 6px; border: 0; padding: 0; margin: 0; min-width: 0; }
.field > label, .field legend { font: 700 18px/1.2 var(--display); padding: 0; margin-bottom: 4px; }
.optional { font: 500 15px var(--body); color: var(--navy-soft); }
.field input[type="text"], .field input[type="email"], .field select, .field textarea { font: inherit; color: var(--navy); background: var(--cream); border: 2px solid var(--line); border-radius: 14px; padding: 10px 12px; width: 100%; }
.field textarea { resize: vertical; min-height: 120px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 3px solid var(--sky); border-color: var(--blue); }
.hint { margin: 0; font-size: 14px; color: var(--navy-soft); }
.stars { display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 4px; }
.stars input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.stars label { font-size: 42px; line-height: 1; color: var(--line); cursor: pointer; transition: transform 0.1s; }
.stars label:hover, .stars label:hover ~ label, .stars input:checked ~ label { color: var(--orange); }
.stars input:focus-visible + label { outline: 3px solid var(--navy); outline-offset: 2px; border-radius: 6px; }
.stars label:active { transform: scale(1.15); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.trap { position: absolute; left: -9999px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 16px; cursor: pointer; }
.check input { width: 22px; height: 22px; margin-top: 2px; accent-color: var(--orange-deep); flex-shrink: 0; }
.feedback-card .btn { align-self: flex-start; border: 0; cursor: pointer; }
.feedback-card .btn:disabled { opacity: 0.6; cursor: wait; }
.form-status { margin: 0; font-weight: 700; min-height: 1.5em; }
.form-status.ok { color: var(--green-deep); }
.form-status.error { color: var(--error); }
.reviews h2 { font-size: 24px; margin: 0 0 12px; }
.review-list { display: grid; gap: 14px; }
.review-card { margin: 0; background: var(--white); border: 2px solid var(--line); border-radius: var(--radius); padding: 18px; }
.review-card blockquote { margin: 6px 0 8px; font-size: 17px; }
.review-card figcaption { color: var(--navy-soft); font-weight: 700; font-size: 15px; }
.review-stars { margin: 0; color: var(--orange); font-size: 22px; letter-spacing: 2px; }
.review-empty { background: var(--sky-soft); border: 2px dashed var(--sky); border-radius: var(--radius); padding: 22px; text-align: center; }
.review-empty p { margin: 0; }
.review-empty .review-stars { color: var(--sky); margin-bottom: 6px; }

/* Wider screens */
@media (min-width: 640px) {
  .cards { grid-template-columns: repeat(3, 1fr); }
  .card.featured { grid-column: 1 / -1; flex-direction: row; align-items: center; gap: 24px; padding: 24px 28px; }
  .card.featured .card-body { flex: 1; min-width: 0; }
  .card.featured .joga-head { flex: 0 0 240px; }
  .hero { padding-block: 16px 64px; }
  .photo.portrait { width: 140px; height: 140px; }
  .travel-strip { grid-template-columns: repeat(3, 1fr); gap: 18px; }
}
@media (min-width: 900px) {
  .feedback-layout { grid-template-columns: 3fr 2fr; align-items: start; }
  .feedback-card { padding: 28px; }
}

@media (prefers-reduced-motion: reduce) { .btn { transition: none; } }
