/* Pethistoric brand shell — cream base, mint/teal primary, sunny yellow + coral accents.
   Fonts are self-hosted. No third-party requests. */

@font-face {
  font-family: Fredoka;
  src: url("assets/fonts/fredoka-latin-variable.woff2") format("woff2-variations"),
       url("assets/fonts/fredoka-latin-variable.woff2") format("woff2");
  font-weight: 300 700;
  font-stretch: 75% 125%;
  font-display: swap;
}

@font-face {
  font-family: Nunito;
  src: url("assets/fonts/nunito-latin-variable.woff2") format("woff2-variations"),
       url("assets/fonts/nunito-latin-variable.woff2") format("woff2");
  font-weight: 300 700;
  font-display: swap;
}

:root {
  --cream: #fff8ee;
  --cream-deep: #f4e6d0;
  --cream-card: #fffdf8;
  --mint: #8ec9a8;
  --teal: #2b8f8a;
  --teal-dark: #1f6f6b;
  --coral: #e96b48;
  --coral-soft: #f0896c;
  --yellow: #f5c44c;
  --sky: #d7eef6;
  --ink: #3a2f28;
  --ink-soft: #5a524a;
  --line: rgba(58, 47, 40, 0.12);
  --shadow: 0 8px 24px rgba(58, 47, 40, 0.08);
  --radius: 1.25rem;
  --radius-sm: 0.9rem;
  --space: 1.25rem;
  --max: 68rem;
  --header-h: 3.75rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html:focus-within {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  font-family: Nunito, "Segoe UI", Tahoma, sans-serif;
  font-weight: 400;
  font-size: 1.0625rem;
  line-height: 1.55;
  color: var(--ink);
  background: var(--cream);
  min-width: 320px;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--teal-dark);
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--yellow);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: -4rem;
  z-index: 100;
  background: var(--teal);
  color: #fff;
  padding: 0.7rem 1rem;
  border-radius: 0.6rem;
  font-weight: 700;
  text-decoration: none;
  min-height: 44px;
}

.skip-link:focus {
  top: 0.75rem;
}

/* ----- Header / nav ----- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 248, 238, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--cream-deep);
}

.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.5rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: var(--header-h);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--ink);
  min-height: 44px;
  flex: 0 0 auto;
}

.brand img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
}

.brand-name {
  font-family: Fredoka, Nunito, sans-serif;
  font-weight: 650;
  font-size: 1.2rem;
  letter-spacing: 0.01em;
  color: var(--teal-dark);
}

.nav-toggle summary {
  list-style: none;
  cursor: pointer;
  font-family: Fredoka, Nunito, sans-serif;
  font-weight: 600;
  font-size: 1rem;
  color: var(--teal-dark);
  background: #fff;
  border: 2px solid var(--mint);
  border-radius: 999px;
  padding: 0.55rem 1rem;
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.nav-toggle summary::-webkit-details-marker { display: none; }

.nav-toggle[open] summary {
  background: var(--mint);
  color: var(--ink);
}

.site-nav {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.5rem 1rem 1rem;
}

.site-nav a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0.35rem 0.75rem;
  text-decoration: none;
  font-weight: 700;
  color: var(--teal-dark);
  border-radius: 0.7rem;
}

.site-nav a:hover,
.site-nav a:active {
  background: var(--sky);
}

@media (min-width: 720px) {
  .nav-toggle {
    display: contents;
  }
  .nav-toggle summary {
    display: none;
  }
  /* Override UA rule that hides details content while closed */
  details.nav-toggle > .site-nav,
  .site-nav {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    padding: 0;
    gap: 0.15rem;
  }
}

/* ----- Layout ----- */
main {
  overflow-x: hidden;
}

.section {
  padding: 2.5rem 1.15rem;
}

.section-inner {
  max-width: var(--max);
  margin: 0 auto;
}

.section h1,
.section h2 {
  font-family: Fredoka, Nunito, sans-serif;
  font-weight: 650;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.75rem;
  color: var(--teal-dark);
}

.section h1 { font-size: clamp(1.85rem, 6vw, 3rem); }
.section h2 { font-size: clamp(1.65rem, 5vw, 2.35rem); }

.lede {
  margin: 0 0 1.5rem;
  color: var(--ink-soft);
  max-width: 36rem;
}

.placeholder-note {
  display: inline-block;
  margin: 0 0 1.25rem;
  padding: 0.35rem 0.7rem;
  background: var(--yellow);
  color: var(--ink);
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: 999px;
}

/* ----- Hero ----- */
#hero {
  text-align: center;
  padding-top: 2rem;
  padding-bottom: 3rem;
  background:
    radial-gradient(ellipse at 20% 0%, rgba(142, 201, 168, 0.35), transparent 50%),
    radial-gradient(ellipse at 90% 20%, rgba(245, 196, 76, 0.28), transparent 45%),
    radial-gradient(ellipse at 50% 100%, rgba(233, 107, 72, 0.12), transparent 45%),
    var(--cream);
}

.hero-logo {
  width: min(20rem, 80vw);
  margin: 0 auto 1.5rem;
}

.hero-slot {
  margin: 1.5rem auto 0;
  max-width: 28rem;
  min-height: 8rem;
  padding: 1.25rem;
  background: var(--cream-card);
  border: 2px dashed var(--mint);
  border-radius: var(--radius);
  color: var(--ink-soft);
}

/* ----- Meet the Dinos ----- */
#meet-the-dinos {
  background:
    radial-gradient(circle at 10% 20%, rgba(215, 238, 246, 0.9), transparent 40%),
    var(--sky);
}

.dino-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

.dino-card {
  background: var(--cream-card);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  padding: 0.9rem 0.75rem 1rem;
  text-align: center;
  min-height: 9.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.dino-art-slot {
  width: 100%;
  aspect-ratio: 1;
  max-width: 8.5rem;
  border-radius: 1rem;
  background:
    repeating-linear-gradient(
      -20deg,
      rgba(142, 201, 168, 0.25),
      rgba(142, 201, 168, 0.25) 8px,
      rgba(255, 248, 238, 0.5) 8px,
      rgba(255, 248, 238, 0.5) 16px
    );
  border: 2px dashed var(--teal);
  display: grid;
  place-items: center;
  color: var(--teal-dark);
  font-size: 0.75rem;
  font-weight: 700;
}

.dino-card h3 {
  font-family: Fredoka, Nunito, sans-serif;
  font-weight: 650;
  font-size: 1.1rem;
  margin: 0.35rem 0 0;
  color: var(--ink);
}

.species {
  margin: 0;
  font-size: 0.8rem;
  color: var(--ink-soft);
}

.one-liner {
  margin: 0.15rem 0 0;
  font-size: 0.9rem;
  color: var(--ink-soft);
}

@media (min-width: 600px) {
  .dino-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 900px) {
  .dino-grid { grid-template-columns: repeat(4, 1fr); gap: 1.1rem; }
}

/* ----- Coloring pages ----- */
#coloring-pages {
  background: var(--cream);
}

.coloring-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
}

.coloring-card {
  background: var(--cream-card);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.coloring-preview-slot {
  width: 100%;
  aspect-ratio: 8.5 / 11;
  max-height: 16rem;
  margin: 0 auto;
  background:
    repeating-linear-gradient(
      45deg,
      #fff,
      #fff 10px,
      var(--cream-deep) 10px,
      var(--cream-deep) 20px
    );
  border: 2px dashed var(--coral-soft);
  border-radius: 0.7rem;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 0.75rem;
  color: var(--ink-soft);
  font-weight: 700;
  font-size: 0.9rem;
}

.coloring-card h3 {
  font-family: Fredoka, Nunito, sans-serif;
  font-weight: 650;
  margin: 0;
  font-size: 1.15rem;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  font-family: Fredoka, Nunito, sans-serif;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: default;
}

.btn-primary {
  background: var(--teal);
  color: #fff;
}

.btn-secondary {
  background: #fff;
  color: var(--teal-dark);
  border-color: var(--teal);
}

.btn[aria-disabled="true"] {
  opacity: 0.55;
}

@media (min-width: 600px) {
  .coloring-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 900px) {
  .coloring-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ----- For Parents ----- */
#for-parents {
  background:
    radial-gradient(ellipse at 80% 0%, rgba(245, 196, 76, 0.28), transparent 50%),
    var(--cream-deep);
}

.parent-panel {
  background: var(--cream-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.35rem 1.15rem 1.5rem;
  max-width: 32rem;
}

.form-note {
  margin: 0 0 1rem;
  color: var(--ink-soft);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 1rem;
}

.field label {
  font-weight: 700;
}

.field input {
  min-height: 44px;
  border: 2px solid var(--mint);
  border-radius: 0.75rem;
  padding: 0.5rem 0.85rem;
  font: inherit;
  background: #fff;
  color: var(--ink);
  width: 100%;
}

.field input:disabled {
  background: var(--cream);
  color: var(--ink-soft);
}

.btn-join {
  background: var(--coral);
  color: #fff;
  border: 0;
  width: 100%;
  cursor: not-allowed;
}

.grownups-tag {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--teal-dark);
}

/* ----- Footer ----- */
#footer {
  background: var(--teal-dark);
  color: #fff8ee;
  padding: 2.25rem 1.15rem 2.5rem;
}

#footer .section-inner {
  text-align: center;
}

#footer h2 {
  color: #fff8ee;
}

.footer-slot p,
.footer-copy {
  margin: 0.4rem 0;
  color: #fff4e6;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 0.75rem;
  margin: 1rem 0;
}

.footer-links a {
  color: #fff8ee;
  font-weight: 700;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0 0.4rem;
}

/* Decorative footer egg-spots, CSS only */
#footer {
  background-image:
    radial-gradient(circle at 12% 30%, rgba(142, 201, 168, 0.28) 0 18px, transparent 19px),
    radial-gradient(circle at 88% 70%, rgba(245, 196, 76, 0.25) 0 14px, transparent 15px),
    radial-gradient(circle at 70% 20%, rgba(255, 248, 238, 0.12) 0 10px, transparent 11px);
}
