@import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@500;700;800&family=Nunito:wght@400;600;700;800&display=swap');

:root {
  --green-dark: #2f6b2f;
  --green: #4a9c3f;
  --green-light: #7cc96f;
  --sun: #ffb703;
  --sun-dark: #e08e00;
  --sky: #eaf7ff;
  --ink: #2b3a29;
  --card: #ffffffee;
  --shadow: 0 8px 24px rgba(40, 70, 30, 0.25);
  --radius: 22px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  font-family: 'Nunito', sans-serif;
  color: var(--ink);
  background: var(--sky);
  overflow-x: hidden;
}

#app {
  position: relative;
  min-height: 100vh;
  width: 100%;
}

.screen {
  min-height: 100vh;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 28px 20px 110px;
  background-size: cover;
  background-position: center;
  animation: fadeIn 0.35s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.bg-sunflower { background-image: linear-gradient(rgba(255,255,255,0.08), rgba(255,255,255,0.15)), url('assets/images/a9b34eabf2.jpg'); }
.bg-home { background-image: url('assets/images/79f05dadbe.jpg'); }

h1, h2, h3 {
  font-family: 'Baloo 2', cursive;
  margin: 0 0 6px;
}

h1.page-title {
  font-size: clamp(28px, 5vw, 44px);
  color: var(--green-dark);
  text-shadow: 2px 2px 0 #fff, 3px 3px 6px rgba(0,0,0,0.15);
  text-align: center;
  margin-bottom: 18px;
}

.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px 30px;
  max-width: 760px;
  width: 100%;
}

.center-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
}

/* ---------- Buttons ---------- */
.btn {
  font-family: 'Baloo 2', cursive;
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(180deg, var(--green-light), var(--green));
  border: none;
  border-radius: 999px;
  padding: 14px 34px;
  cursor: pointer;
  box-shadow: 0 5px 0 #2f6b2f, 0 8px 16px rgba(0,0,0,0.2);
  transition: transform 0.12s ease, box-shadow 0.12s ease;
  text-align: center;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(3px); box-shadow: 0 2px 0 #2f6b2f, 0 4px 8px rgba(0,0,0,0.2); }

.btn.secondary {
  background: linear-gradient(180deg, #ffd166, var(--sun));
  box-shadow: 0 5px 0 var(--sun-dark), 0 8px 16px rgba(0,0,0,0.2);
}
.btn.secondary:active { box-shadow: 0 2px 0 var(--sun-dark), 0 4px 8px rgba(0,0,0,0.2); }

.btn.outline {
  background: #fff;
  color: var(--green-dark);
  box-shadow: 0 5px 0 #cfd8c5, 0 8px 16px rgba(0,0,0,0.12);
}
.btn.outline:active { box-shadow: 0 2px 0 #cfd8c5; }

.btn.small { font-size: 15px; padding: 9px 18px; box-shadow: 0 3px 0 #2f6b2f; }
.btn.small:active { box-shadow: 0 1px 0 #2f6b2f; transform: translateY(2px); }

.btn:disabled { opacity: 0.45; cursor: default; transform: none !important; }

/* ---------- Nav bar (bottom, present on lesson pages) ---------- */
.navbar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 14px calc(12px + env(safe-area-inset-bottom));
  background: linear-gradient(0deg, rgba(255,255,255,0.95), rgba(255,255,255,0.75));
  backdrop-filter: blur(4px);
  z-index: 50;
  box-shadow: 0 -4px 14px rgba(0,0,0,0.08);
}

/* ---------- Home screen ---------- */
.home-title-wrap {
  margin-top: 6vh;
  text-align: center;
  background: rgba(255,255,255,0.72);
  border-radius: 30px;
  padding: 28px 40px;
  box-shadow: var(--shadow);
}
.home-title-wrap h1 {
  font-size: clamp(32px, 6vw, 56px);
  color: var(--green-dark);
}
.home-buttons { display: flex; gap: 18px; margin-top: 22px; flex-wrap: wrap; justify-content: center; }
.about-me-btn { position: fixed; top: 22px; right: 22px; }

/* ---------- Main menu / parts menu ---------- */
.menu-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
  max-width: 520px;
  margin: 10px auto 0;
}
.menu-list .btn { width: 100%; text-align: left; font-size: 19px; }

.parts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
  width: 100%;
  max-width: 720px;
  margin-top: 10px;
}
.part-tile {
  background: #fff;
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 18px 10px;
  text-align: center;
  cursor: pointer;
  border: 3px solid transparent;
  transition: transform 0.15s, border-color 0.15s;
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  color: var(--green-dark);
  font-size: 18px;
}
.part-tile:hover { transform: translateY(-4px); border-color: var(--sun); }
.part-tile .emoji { font-size: 40px; display: block; margin-bottom: 6px; }

/* ---------- Content page ---------- */
.content-wrap {
  display: flex;
  gap: 28px;
  align-items: center;
  max-width: 900px;
  width: 100%;
  flex-wrap: wrap;
  justify-content: center;
}
.content-img {
  max-width: 280px;
  max-height: 320px;
  width: 100%;
  object-fit: contain;
  filter: drop-shadow(0 8px 14px rgba(0,0,0,0.25));
}
.content-text { flex: 1; min-width: 260px; }
.content-text p { font-size: 19px; line-height: 1.5; margin: 0 0 14px; }
.fun-fact {
  background: #fff6d9;
  border-left: 6px solid var(--sun);
  border-radius: 10px;
  padding: 10px 16px;
  font-size: 16px;
  margin-top: 10px;
}
.listen-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 2px solid var(--green);
  color: var(--green-dark);
  border-radius: 999px;
  padding: 8px 18px;
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  cursor: pointer;
  margin-bottom: 14px;
}
.listen-btn:hover { background: var(--green-light); color: #fff; }
.listen-btn.playing { background: var(--green); color: #fff; }

/* ---------- Click-here animation zones ---------- */
.animate-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.grow-stage {
  position: relative;
  width: 260px;
  height: 260px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.grow-stage img {
  width: 90px;
  transition: width 2.2s cubic-bezier(.2,.9,.3,1);
}
.grow-stage.grown img { width: 240px; }

.frame-player {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.frame-player img {
  width: min(90vw, 500px);
  border-radius: 16px;
  box-shadow: var(--shadow);
  background: #fff;
}
.frame-controls { display: flex; align-items: center; gap: 14px; }
.frame-progress {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  color: var(--green-dark);
}

/* ---------- Quiz ---------- */
.quiz-board {
  background-image: url('assets/images/01609f82ef.jpg');
  background-size: 100% 100%;
  padding: 50px 60px;
  max-width: 720px;
  width: 100%;
  min-height: 360px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 18px;
}
.quiz-q { font-family: 'Baloo 2', cursive; font-size: 22px; color: var(--green-dark); text-align: center; }
.quiz-img { max-width: 160px; display: block; margin: 0 auto 6px; filter: drop-shadow(0 6px 10px rgba(0,0,0,.2)); }
.quiz-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
@media (max-width: 560px) { .quiz-options { grid-template-columns: 1fr; } }
.quiz-opt {
  background: #fff;
  border: 3px solid #d8e6cf;
  border-radius: 14px;
  padding: 10px 14px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: border-color 0.15s, transform 0.1s;
  text-align: left;
}
.quiz-opt:hover { border-color: var(--sun); transform: translateY(-2px); }
.quiz-opt img { width: 42px; height: 42px; object-fit: contain; }
.quiz-opt.correct { border-color: var(--green); background: #eaffe0; }
.quiz-opt.wrong { border-color: #e05353; background: #ffe9e9; }
.quiz-progress { text-align: center; font-weight: 700; color: var(--green-dark); }

.feedback-overlay {
  position: fixed;
  inset: 0;
  background: rgba(20, 40, 20, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  animation: fadeIn 0.25s ease;
}
.feedback-card {
  background: #fff;
  border-radius: 24px;
  padding: 34px 40px;
  text-align: center;
  box-shadow: 0 12px 30px rgba(0,0,0,0.35);
  max-width: 380px;
}
.feedback-card img { width: 130px; margin-bottom: 10px; }
.feedback-card h2 { font-size: 30px; color: var(--green-dark); }
.feedback-card p { font-size: 18px; margin: 4px 0 18px; }
.feedback-buttons { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ---------- Credits ---------- */
.credits-card { text-align: center; }
.credits-card h1 { color: var(--green-dark); }
.credits-card .pots { display: flex; justify-content: space-between; margin-top: 20px; }
.credits-card .pots img { width: 90px; }

/* misc */
.deco-corner {
  position: absolute;
  width: 90px;
  opacity: 0.9;
  pointer-events: none;
}
.deco-tl { top: 10px; left: 10px; }
.deco-br { bottom: 90px; right: 10px; }

footer.small-note {
  font-size: 12px;
  color: #6b7a63;
  margin-top: 18px;
  text-align: center;
}
