/* ==========================================================
   Daily Odyssey — Solarpunk Pixel-Art RPG theme
   Edit the color variables below to retune the palette.
   ========================================================== */

:root {
  /* Solarpunk palette: deep forest night -> warm sun */
  --color-bg: #12352b;          /* deep mossy background */
  --color-surface: #17493a;     /* panel fill */
  --color-surface-alt: #0e2b23; /* darker panel fill */
  --color-text: #f4f7e8;        /* soft parchment white */
  --color-muted: #a9d3a0;       /* leafy muted green */

  --color-sun: #f6c445;         /* golden sun */
  --color-sun-hover: #ffd766;
  --color-leaf: #7bd66b;        /* bright leaf accent */
  --color-sky-top: #6fd0d6;     /* teal sky */
  --color-sky-bottom: #bdeac2;  /* pale green horizon */

  --color-frame-dark: #0b2019;  /* pixel frame outline */
  --color-frame-light: #7bd66b; /* pixel frame inner glow */

  --max-width: 1080px;
  --px: 4px;                    /* base pixel unit */
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "VT323", "Courier New", monospace;
  font-size: 22px;
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.5;
  image-rendering: pixelated;
  /* subtle repeating dotted texture like a pixel map */
  background-image:
    radial-gradient(rgba(123, 214, 107, 0.06) 1px, transparent 1px);
  background-size: 8px 8px;
}

h1, h2, h3 {
  font-family: "Press Start 2P", "VT323", monospace;
  line-height: 1.35;
  margin: 0 0 0.6em;
  text-shadow: 3px 3px 0 var(--color-frame-dark);
}

p { margin: 0 0 1em; }

a { color: var(--color-sun); text-decoration: none; }
a:hover { color: var(--color-sun-hover); }

code {
  background: rgba(0, 0, 0, 0.35);
  padding: 0.1em 0.35em;
  font-size: 0.9em;
}

/* ---------- Scanline / CRT overlay ---------- */
.scanlines {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 50;
  background: repeating-linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.14) 0,
    rgba(0, 0, 0, 0.14) 1px,
    transparent 1px,
    transparent 3px
  );
  mix-blend-mode: multiply;
  opacity: 0.5;
}

/* ---------- Layout helpers ---------- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}
.container--narrow { max-width: 700px; }

.section { padding: 72px 0; position: relative; }
.section--alt { background: var(--color-surface-alt); }
.section--message { background: rgba(0, 0, 0, 0.15); }

.section__title {
  font-size: clamp(1rem, 3.2vw, 1.75rem);
  color: var(--color-sun);
}
.section__eyebrow,
.panel__label {
  font-family: "Press Start 2P", monospace;
  font-size: 0.7rem;
  color: var(--color-leaf);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 1.25rem;
  text-shadow: 2px 2px 0 var(--color-frame-dark);
}
.section__eyebrow { text-align: center; display: block; }

.lead { font-size: 1.35rem; color: var(--color-muted); }

.eyebrow {
  font-family: "Press Start 2P", monospace;
  font-size: 0.65rem;
  letter-spacing: 1px;
  color: var(--color-leaf);
  margin-bottom: 1.5rem;
  text-shadow: 2px 2px 0 var(--color-frame-dark);
}

/* ---------- Pixel frame panels (RPG dialog boxes) ---------- */
.panel {
  position: relative;
  background: var(--color-surface);
  border: var(--px) solid var(--color-frame-dark);
  padding: 32px;
  /* double pixel frame + hard drop shadow */
  box-shadow:
    0 0 0 var(--px) var(--color-frame-light),
    0 0 0 calc(var(--px) * 2) var(--color-frame-dark),
    8px 8px 0 0 rgba(0, 0, 0, 0.45);
}
.panel--dialog { margin: 0 auto; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: "Press Start 2P", monospace;
  font-size: 0.8rem;
  padding: 16px 28px;
  border: var(--px) solid var(--color-frame-dark);
  cursor: pointer;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.35);
  transition: transform 0.05s steps(2), background 0.1s;
}
.btn--primary {
  background: var(--color-sun);
  color: #3a2600;
  box-shadow:
    0 0 0 var(--px) var(--color-frame-dark),
    6px 6px 0 0 rgba(0, 0, 0, 0.5);
}
.btn--primary:hover { background: var(--color-sun-hover); }
.btn--primary:active {
  transform: translate(4px, 4px);
  box-shadow:
    0 0 0 var(--px) var(--color-frame-dark),
    2px 2px 0 0 rgba(0, 0, 0, 0.5);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 24px;
  overflow: hidden;
}
.hero__sky {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--color-sky-top) 0%, var(--color-sky-bottom) 100%);
}
/* Pixel sun: blocky circle via layered radial + stepped edges */
.sun {
  position: absolute;
  top: 12%;
  left: 50%;
  width: 140px;
  height: 140px;
  margin-left: -70px;
  background: var(--color-sun);
  border-radius: 50%;
  box-shadow:
    0 0 0 12px rgba(246, 196, 69, 0.35),
    0 0 0 26px rgba(246, 196, 69, 0.18);
  image-rendering: pixelated;
}
.cloud {
  position: absolute;
  background: #ffffff;
  height: 20px;
  box-shadow:
    20px 0 0 #fff, 40px 0 0 #fff,
    20px -16px 0 #fff, 40px -16px 0 #fff,
    -8px 4px 0 rgba(0,0,0,0.06);
  opacity: 0.85;
}
.cloud--1 { top: 20%; left: 14%; width: 20px; }
.cloud--2 { top: 32%; right: 16%; width: 20px; transform: scale(1.4); }

/* Rolling hills silhouette */
.hero__hills {
  position: absolute;
  left: 0; right: 0; bottom: 90px;
  height: 220px;
  background:
    radial-gradient(120px 120px at 20% 100%, #3c9a52 0 60%, transparent 61%),
    radial-gradient(180px 160px at 55% 100%, #2f7f45 0 60%, transparent 61%),
    radial-gradient(140px 130px at 85% 100%, #3c9a52 0 60%, transparent 61%);
  background-repeat: no-repeat;
}
/* Grass ground band */
.hero__grass {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 96px;
  background: #2f7f45;
  border-top: var(--px) solid #1c5a2f;
  box-shadow: inset 0 8px 0 rgba(255, 255, 255, 0.08);
}

.hero__content {
  position: relative;
  z-index: 2;
  max-width: 760px;
  background: rgba(11, 32, 25, 0.72);
  border: var(--px) solid var(--color-frame-dark);
  box-shadow:
    0 0 0 var(--px) var(--color-frame-light),
    0 0 0 calc(var(--px) * 2) var(--color-frame-dark),
    10px 10px 0 0 rgba(0, 0, 0, 0.4);
  padding: 40px 36px;
}
.hero__title {
  font-size: clamp(1.6rem, 6vw, 3.4rem);
  color: var(--color-sun);
  text-shadow: 4px 4px 0 var(--color-frame-dark);
}
.hero__tagline {
  font-size: clamp(1.15rem, 2.5vw, 1.5rem);
  color: var(--color-text);
  margin: 1rem 0 2rem;
}
.hero__hint {
  font-family: "Press Start 2P", monospace;
  font-size: 0.6rem;
  color: var(--color-leaf);
  margin: 1.5rem 0 0;
  animation: blink 1.4s steps(2, start) infinite;
}
@keyframes blink { 50% { opacity: 0.35; } }

/* ---------- Features ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 32px;
}
.feature { text-align: center; }
.feature__icon {
  font-size: 2.4rem;
  margin-bottom: 14px;
  filter: drop-shadow(3px 3px 0 var(--color-frame-dark));
}
.feature__title { font-size: 0.95rem; color: var(--color-sun); }
.feature p { color: var(--color-muted); margin: 0; font-size: 1.2rem; }

/* ---------- Message / signature ---------- */
.signature {
  font-family: "Press Start 2P", monospace;
  font-size: 0.75rem;
  color: var(--color-leaf);
  margin-top: 1.5rem;
  text-shadow: 2px 2px 0 var(--color-frame-dark);
}

/* ---------- Signup ---------- */
.section--signup { text-align: center; }
.signup-form {
  display: flex;
  gap: 14px;
  max-width: 500px;
  margin: 1.5rem auto 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
}
.signup-form__input {
  flex: 1 1 240px;
  font-family: "VT323", monospace;
  font-size: 1.25rem;
  padding: 14px 16px;
  border: var(--px) solid var(--color-frame-dark);
  background: var(--color-surface-alt);
  color: var(--color-text);
  box-shadow: inset 3px 3px 0 rgba(0, 0, 0, 0.35);
}
.signup-form__input::placeholder { color: #6fa36a; }
.signup-form__input:focus {
  outline: none;
  border-color: var(--color-leaf);
  box-shadow:
    inset 3px 3px 0 rgba(0, 0, 0, 0.35),
    0 0 0 var(--px) var(--color-leaf);
}
.signup-note {
  font-family: "Press Start 2P", monospace;
  font-size: 0.75rem;
  color: var(--color-leaf);
  margin-top: 1rem;
  text-shadow: 2px 2px 0 var(--color-frame-dark);
}
.signup-error {
  font-family: "Press Start 2P", monospace;
  font-size: 0.7rem;
  line-height: 1.6;
  color: #ff8f6b;
  margin-top: 1rem;
  text-shadow: 2px 2px 0 var(--color-frame-dark);
}
.btn:disabled { opacity: 0.6; cursor: not-allowed; }
.signup-fineprint { font-size: 1.05rem; color: #6fa36a; margin-top: 0.5rem; }
.signup-privacy {
  font-size: 0.95rem;
  line-height: 1.5;
  color: #6fa36a;
  max-width: 460px;
  margin: 0.75rem auto 0;
}
.signup-privacy a { color: var(--color-leaf); text-decoration: underline; }
.signup-privacy a:hover { color: var(--color-sun); }

/* ---------- Legal / privacy page ---------- */
.legal-updated { font-size: 1rem; color: #6fa36a; margin-bottom: 1.5rem; }
.legal-heading {
  font-size: 0.8rem;
  color: var(--color-leaf);
  margin: 1.75rem 0 0.6rem;
}
.legal-list { margin: 0 0 1em; padding-left: 1.4em; color: var(--color-muted); }
.legal-list li { margin-bottom: 0.4em; }
.legal-back {
  margin-top: 2rem;
  font-family: "Press Start 2P", monospace;
  font-size: 0.7rem;
}

/* ---------- Footer ---------- */
.footer {
  background: var(--color-frame-dark);
  padding: 40px 0;
  text-align: center;
  border-top: var(--px) solid var(--color-leaf);
}
.footer__brand {
  font-family: "Press Start 2P", monospace;
  font-size: 0.9rem;
  color: var(--color-sun);
  margin-bottom: 0.75rem;
  text-shadow: 2px 2px 0 #000;
}
.footer__social {
  display: flex;
  gap: 24px;
  justify-content: center;
  margin-bottom: 1rem;
  font-family: "Press Start 2P", monospace;
  font-size: 0.6rem;
}
.footer__copy { color: var(--color-muted); font-size: 1rem; margin: 0; }

/* ---------- Utilities ---------- */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Responsive ---------- */
@media (max-width: 600px) {
  body { font-size: 20px; }
  .sun { width: 96px; height: 96px; margin-left: -48px; }
  .panel { padding: 24px; }
  .hero__content { padding: 28px 22px; }
}
