/* ===========================================================
   Good Play Zones — site styles
   Brand colours taken from the Good Play Zone stamp logo
   =========================================================== */

:root {
  --red: #D6212A;
  --red-dark: #B01820;
  --blue: #1E73B8;
  --blue-light: #2E9BD6;
  --ink: #1A1A1A;
  --grey: #5a6672;
  --line: #e6ebf0;
  --soft-blue: #f2f8fc;
  --soft-red: #fdeff0;
  --white: #ffffff;
  --radius: 16px;
  --shadow: 0 6px 24px rgba(20, 40, 60, 0.08);
  --wrap: 1080px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Nunito", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.65;
  font-size: 17px;
}

h1, h2, h3, .brand-font {
  font-family: "Fredoka", "Nunito", sans-serif;
  font-weight: 600;
  line-height: 1.15;
  color: var(--ink);
  margin: 0 0 .5em;
}

h1 { font-size: clamp(2rem, 5vw, 3.1rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.2rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1rem; }
a { color: var(--blue); }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }
.section { padding: 66px 0; }
.section.tint-blue { background: var(--soft-blue); }
.section.tint-red { background: var(--soft-red); }
.center { text-align: center; }
.lead { font-size: 1.2rem; color: var(--grey); max-width: 680px; }
.center .lead { margin-left: auto; margin-right: auto; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 10px 22px; max-width: var(--wrap); margin: 0 auto;
}
.nav-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.nav-brand img { height: 52px; width: 52px; }
.nav-brand span {
  font-family: "Fredoka", sans-serif; font-weight: 600; font-size: 1.15rem;
  color: var(--red); letter-spacing: .5px;
}
.nav-brand span em { color: var(--blue); font-style: normal; }
.nav-links { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.nav-links a {
  text-decoration: none; color: var(--ink); font-weight: 700; font-size: .98rem;
  padding: 8px 12px; border-radius: 10px;
}
.nav-links a:hover { background: var(--soft-blue); color: var(--blue); }
.nav-links a.active { color: var(--red); }
.nav-toggle { display: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; text-decoration: none; cursor: pointer;
  font-family: "Fredoka", sans-serif; font-weight: 600; font-size: 1.02rem;
  padding: 13px 26px; border-radius: 999px; border: 2px solid transparent;
  transition: transform .08s ease, box-shadow .2s ease, background .2s ease;
}
.btn:active { transform: translateY(1px); }
.btn-red { background: var(--red); color: #fff; }
.btn-red:hover { background: var(--red-dark); box-shadow: 0 8px 18px rgba(214,33,42,.28); }
.btn-blue { background: var(--blue); color: #fff; }
.btn-blue:hover { background: #175f99; box-shadow: 0 8px 18px rgba(30,115,184,.28); }
.btn-ghost { background: #fff; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--blue); color: var(--blue); }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; }
.center .btn-row { justify-content: center; }

/* ---------- Hero ---------- */
.hero { padding: 64px 0 40px; }
.hero-grid {
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center;
}
.hero .eyebrow {
  display: inline-block; font-family: "Fredoka", sans-serif; font-weight: 600;
  color: var(--blue); background: var(--soft-blue);
  padding: 6px 14px; border-radius: 999px; margin-bottom: 16px; font-size: .95rem;
}
.hero-badge { text-align: center; }
.hero-badge img { width: 100%; max-width: 360px; height: auto; filter: drop-shadow(0 10px 26px rgba(20,40,60,.12)); }

/* ---------- Cards ---------- */
.grid { display: grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow);
}
.card .ico {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  font-size: 1.4rem; margin-bottom: 12px; background: var(--soft-blue); color: var(--blue);
}
.card.red .ico { background: var(--soft-red); color: var(--red); }
.card h3 { margin-bottom: .3em; }
.card p { color: var(--grey); margin-bottom: 0; }

/* ---------- Tiers ---------- */
.tier {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow); display: flex; flex-direction: column;
}
.tier.featured { border: 2px solid var(--red); }
.tier .tag {
  align-self: flex-start; font-family: "Fredoka", sans-serif; font-weight: 600;
  font-size: .82rem; text-transform: uppercase; letter-spacing: .6px;
  padding: 4px 12px; border-radius: 999px; margin-bottom: 12px;
}
.tier.free .tag { background: var(--soft-blue); color: var(--blue); }
.tier.featured .tag { background: var(--soft-red); color: var(--red); }
.tier.flag .tag { background: #eef0f2; color: var(--ink); }
.tier .price { font-family: "Fredoka", sans-serif; font-size: 1.7rem; color: var(--ink); margin: 4px 0 4px; }
.tier .price small { font-size: .9rem; color: var(--grey); font-family: "Nunito"; font-weight: 700; }
.tier ul { list-style: none; padding: 0; margin: 14px 0 22px; }
.tier li { padding: 7px 0 7px 28px; position: relative; color: #33414d; }
.tier li::before {
  content: "✓"; position: absolute; left: 0; top: 6px; color: var(--red);
  font-weight: 900; font-family: "Fredoka", sans-serif;
}
.tier .btn { margin-top: auto; text-align: center; }

/* ---------- Steps ---------- */
.steps { counter-reset: step; display: grid; gap: 18px; grid-template-columns: repeat(4,1fr); }
.step { background:#fff; border:1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.step .n {
  counter-increment: step;
  width: 40px; height: 40px; border-radius: 50%; background: var(--red); color:#fff;
  display: grid; place-items: center; font-family:"Fredoka"; font-weight:600; font-size:1.1rem; margin-bottom: 12px;
}
.step:nth-child(even) .n { background: var(--blue); }
.step h3 { font-size: 1.08rem; }
.step p { color: var(--grey); margin: 0; font-size: .97rem; }

/* ---------- Form ---------- */
.form-wrap { max-width: 820px; margin: 0 auto; }
.fieldset {
  background:#fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px 28px; margin-bottom: 24px; box-shadow: var(--shadow);
}
.fieldset > legend, .fs-title {
  font-family:"Fredoka"; font-weight:600; font-size: 1.25rem; color: var(--blue);
  padding: 0; margin-bottom: 4px;
}
.fs-note { color: var(--grey); font-size: .95rem; margin: 0 0 18px; }
.field { margin-bottom: 18px; }
.field label { display:block; font-weight: 800; margin-bottom: 6px; font-size: .98rem; }
.field .hint { font-weight: 500; color: var(--grey); font-size: .9rem; }
.req { color: var(--red); }
.field input[type=text], .field input[type=email], .field input[type=url],
.field input[type=tel], .field input[type=date], .field input[type=number],
.field textarea, .field select {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px;
  font: inherit; color: var(--ink); background: #fff;
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(46,155,214,.15);
}
.field textarea { min-height: 90px; resize: vertical; }

/* criterion self-assessment rows */
.crit { border:1px solid var(--line); border-radius: 12px; padding: 14px 16px; margin-bottom: 14px; background:#fff; }
.crit .c-head { font-weight: 800; margin-bottom: 2px; }
.crit .c-head .ess {
  font-family:"Fredoka"; font-size:.72rem; color:#fff; background: var(--red);
  padding: 2px 8px; border-radius: 999px; margin-left: 8px; vertical-align: middle; letter-spacing:.3px;
}
.crit .c-desc { color: var(--grey); font-size: .92rem; margin-bottom: 10px; }
.ratings { display: flex; gap: 10px; flex-wrap: wrap; }
.ratings label {
  display: inline-flex; align-items: center; gap: 7px; cursor: pointer;
  border: 1.5px solid var(--line); border-radius: 999px; padding: 7px 14px; font-weight: 700; font-size: .92rem;
}
.ratings input { accent-color: var(--blue); }
.ratings label:has(input:checked) { border-color: var(--blue); background: var(--soft-blue); color: var(--blue); }

.check {
  display: flex; gap: 10px; align-items: flex-start; background: var(--soft-red);
  border: 1px solid #f4cdd0; border-radius: 12px; padding: 14px 16px; margin-bottom: 16px;
}
.check input { margin-top: 5px; width: 18px; height: 18px; accent-color: var(--red); }
.check label { font-weight: 700; }

.form-actions { text-align: center; margin-top: 10px; }
.honeypot { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* ---------- Zones directory ---------- */
.zones-toolbar { display:flex; gap:12px; flex-wrap:wrap; justify-content:center; margin-bottom: 28px; }
.zones-toolbar input, .zones-toolbar select {
  padding: 11px 14px; border:1.5px solid var(--line); border-radius: 999px; font: inherit; min-width: 220px;
}
.zone-grid { display:grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
.zone-card {
  background:#fff; border:1px solid var(--line); border-radius: var(--radius); padding: 22px;
  box-shadow: var(--shadow); display:flex; flex-direction:column;
}
.zone-card .badge-row { display:flex; align-items:center; gap:10px; margin-bottom: 10px; }
.zone-card .st {
  font-family:"Fredoka"; font-size:.72rem; text-transform:uppercase; letter-spacing:.5px;
  padding: 3px 10px; border-radius:999px;
}
.st.registered { background: var(--soft-blue); color: var(--blue); }
.st.certified { background: var(--soft-red); color: var(--red); }
.st.flagship { background: #ffe9c7; color: #a15c00; }
.zone-card h3 { font-size: 1.15rem; margin-bottom: 2px; }
.zone-card .loc { color: var(--grey); font-weight:700; font-size:.95rem; margin-bottom: 8px; }
.zone-card p { color:#33414d; font-size:.96rem; margin-bottom: 14px; }
.zone-card .z-foot { margin-top:auto; display:flex; justify-content:space-between; align-items:center; gap:10px; }
.zone-card .ages { font-size:.86rem; color: var(--grey); }
.empty { text-align:center; color: var(--grey); padding: 40px 0; }

/* ---------- Callout ---------- */
.callout {
  background: linear-gradient(120deg, var(--blue), var(--blue-light));
  color:#fff; border-radius: 22px; padding: 44px; text-align:center; box-shadow: var(--shadow);
}
.callout h2 { color:#fff; }
.callout p { color: rgba(255,255,255,.9); max-width: 620px; margin: 0 auto 22px; }
.callout .btn-ghost { background: #fff; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #cfd8e0; padding: 44px 0 30px; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.foot-grid { display:flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.foot-brand { display:flex; align-items:center; gap:12px; margin-bottom: 8px; }
.foot-brand img { height: 48px; width:48px; }
.foot-brand strong { font-family:"Fredoka"; color:#fff; font-size: 1.1rem; }
.foot-links { display:flex; gap: 26px; flex-wrap: wrap; }
.foot-col h4 { font-family:"Fredoka"; color:#fff; margin: 0 0 8px; font-size: 1rem; }
.foot-col a { display:block; color:#cfd8e0; padding: 3px 0; }
.copyright { margin-top: 28px; padding-top: 18px; border-top: 1px solid #2c2c2c; font-size:.9rem; color:#9aa7b2; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-badge { order: -1; }
  .grid-3, .zone-grid { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  .nav-links {
    display: none; position: absolute; top: 72px; left: 0; right: 0; flex-direction: column;
    background:#fff; border-bottom: 1px solid var(--line); padding: 10px 22px 18px; align-items: stretch;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px; border-radius: 10px; }
  .nav-toggle {
    display: inline-grid; place-items:center; width: 44px; height: 44px; border:1px solid var(--line);
    background:#fff; border-radius: 12px; font-size: 1.3rem; cursor:pointer; color: var(--ink);
  }
  .grid-3, .zone-grid, .steps { grid-template-columns: 1fr; }
  .section { padding: 46px 0; }
  .callout { padding: 30px 22px; }
}

/* ---------- Map & sorting (directory) ---------- */
#zoneMap {
  height: 460px; width: 100%; border-radius: var(--radius);
  border: 1px solid var(--line); box-shadow: var(--shadow); margin-bottom: 30px; z-index: 1;
}
.leaflet-popup-content { font-family: "Nunito", sans-serif; margin: 12px 14px; }
.leaflet-popup-content h4 {
  font-family: "Fredoka", sans-serif; font-weight: 600; margin: 0 0 4px; font-size: 1.02rem; color: var(--ink);
}
.leaflet-popup-content .pop-loc { color: var(--grey); font-size: .86rem; margin-bottom: 6px; }
.leaflet-popup-content .pop-st {
  font-family:"Fredoka"; font-size:.68rem; text-transform:uppercase; letter-spacing:.5px;
  padding: 2px 8px; border-radius:999px;
}
.leaflet-popup-content a.pop-link { color: var(--blue); font-weight: 800; text-decoration: none; font-size: .9rem; }
.leaflet-popup-content a.pop-link:hover { text-decoration: underline; }

.zones-toolbar .sort-group { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
#zonePostcode { text-transform: uppercase; min-width: 150px; }
#zoneSortGo {
  padding: 11px 22px; border: none; cursor: pointer; border-radius: 999px;
  font-family: "Fredoka", sans-serif; font-weight: 600; background: var(--blue); color: #fff;
}
#zoneSortGo:hover { background: #175f99; }
#zoneMsg { text-align: center; color: var(--red); font-weight: 700; margin: -14px 0 22px; min-height: 1.2em; }
#zoneMsg.ok { color: var(--grey); font-weight: 600; }
.zone-card .dist {
  display: inline-block; background: var(--soft-blue); color: var(--blue); font-weight: 800;
  font-size: .82rem; padding: 3px 10px; border-radius: 999px; margin-bottom: 8px;
}
