:root{
  --bg: #fffdf6;
  --card: #ffffff;
  --accent: #ffb84d;
  --accent-2: #7ad3a7;
  --text: #2b2b2b;
  --muted: #6b6b6b;
  --max-width: 1000px;
  --radius: 12px;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  color-scheme: light;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  background:linear-gradient(180deg, var(--bg) 0%, #f7f6f3 100%);
  color:var(--text);
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  line-height:1.5;
}

.container{
  width:clamp(300px, 92%, var(--max-width));
  margin:0 auto;
  padding:2rem 0;
}

/* Header */
.site-header{
  background:transparent;
  position:sticky;
  top:0;
  z-index:20;
  backdrop-filter: blur(6px);
}
.header-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
}
.logo{display:flex;align-items:center;gap:.75rem;text-decoration:none;color:inherit}
.logo-img{width:56px;height:56px}
.site-title{font-weight:700;font-size:1.1rem}

/* Nav */
.nav-toggle{
  display:none;
  background:var(--accent);
  color:white;
  border:0;
  padding:.5rem .75rem;
  border-radius:8px;
}
.nav-list{display:flex;gap:1rem;list-style:none;padding:0;margin:0}
.nav-list a{color:var(--text);text-decoration:none;padding:.35rem .5rem;border-radius:8px}
.nav-list a:hover{background:rgba(0,0,0,0.04)}

/* Hero */
.hero{
  padding:3rem 0;
}
.hero-grid{
  display:grid;
  grid-template-columns:1fr 360px;
  gap:2rem;
  align-items:center;
}
.lead{color:var(--muted);font-size:1.05rem}
.cta{
  display:inline-block;
  background:var(--accent);
  color:#fff;
  padding:.6rem 1rem;
  border-radius:10px;
  text-decoration:none;
  font-weight:600;
}
.hero-img{width:100%;max-width:360px;display:block}

/* Sections */
.section{padding:2rem 0}
.section.alt{background:linear-gradient(180deg,#fff 0%, #f9fbf8 100%)}

.card{
  background:var(--card);
  padding:1rem;
  border-radius:var(--radius);
  box-shadow:0 6px 18px rgba(16,16,16,0.06);
  margin-bottom:1rem;
}

/* Gallery */
.gallery{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(160px,1fr));
  gap:1rem;
}
.gallery-item img{width:100%;height:160px;object-fit:contain;background:linear-gradient(180deg,#fff,#fff);border-radius:10px;padding:1rem}

/* Contact form */
.contact-form{display:grid;gap:.75rem;max-width:540px}
.contact-form label{display:flex;flex-direction:column;font-size:.95rem}
.contact-form input,
.contact-form textarea{
  margin-top:.35rem;
  padding:.6rem .75rem;
  border:1px solid #e6e6e6;
  border-radius:8px;
  font:inherit;
}
.btn{background:var(--accent-2);color:#fff;border:0;padding:.6rem .9rem;border-radius:10px;cursor:pointer}

/* Footer */
.site-footer{padding:1.5rem 0;background:transparent}
.footer-inner{display:flex;flex-direction:column;gap:.5rem;align-items:flex-start}

/* Quote */
.quote{
  margin:1rem 0;
  padding:1rem;
  border-left:6px solid var(--accent);
  background:#fffefb;
  border-radius:8px;
  color:var(--muted);
}

/* Responsive */
@media (max-width:900px){
  .hero-grid{grid-template-columns:1fr}
  .hero-art{order:-1}
  .nav-toggle{display:inline-block}
  .nav-list{flex-direction:column;position:absolute;right:1rem;top:64px;background:rgba(255,255,255,0.98);padding:.5rem;border-radius:10px;box-shadow:0 8px 24px rgba(16,16,16,0.12)}
  .header-inner{position:relative}
}

/* Small */
.small{font-size:.9rem;color:var(--muted)}

/* Games Section */
.game-card{margin-bottom:2rem}

/* Memory Game */
.memory-game{
  display:grid;
  grid-template-columns:repeat(4, 1fr);
  gap:1rem;
  margin:1.5rem 0;
  max-width:600px;
}
.memory-card{
  aspect-ratio:1;
  background:var(--card);
  border:2px solid var(--accent);
  border-radius:12px;
  cursor:pointer;
  position:relative;
  transition:transform 0.3s;
}
.memory-card:hover{
  transform:scale(1.05);
}
.memory-card.flipped .card-front{
  transform:rotateY(180deg);
}
.memory-card.flipped .card-back{
  transform:rotateY(0deg);
}
.memory-card.matched{
  opacity:0.6;
  cursor:default;
  border-color:var(--accent-2);
}
.card-front, .card-back{
  position:absolute;
  width:100%;
  height:100%;
  backface-visibility:hidden;
  transition:transform 0.6s;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:10px;
}
.card-front{
  background:linear-gradient(135deg, var(--accent) 0%, #ffcc70 100%);
  color:white;
  font-size:2rem;
  font-weight:bold;
}
.card-back{
  background:white;
  transform:rotateY(180deg);
  padding:0.5rem;
}
.card-back img{
  width:100%;
  height:100%;
  object-fit:contain;
}

/* Click Game */
.click-game{margin:1.5rem 0}
.click-game-area{
  position:relative;
  height:300px;
  background:linear-gradient(180deg, #e3f2fd 0%, #bbdefb 100%);
  border-radius:12px;
  overflow:hidden;
  margin-bottom:1rem;
}
.clickable-giraffe{
  position:absolute;
  width:80px;
  height:120px;
  cursor:pointer;
  transition:all 0.5s ease;
}
.clickable-giraffe:hover{
  transform:scale(1.1);
}
.clickable-giraffe.clicked{
  animation:bounce 0.5s;
}
@keyframes bounce{
  0%, 100%{transform:scale(1)}
  50%{transform:scale(1.3) rotate(10deg)}
}

/* Quiz Game */
.quiz-game{margin:1.5rem 0}
.quiz-question{
  background:linear-gradient(135deg, #fff9e6 0%, #fff 100%);
  padding:1.5rem;
  border-radius:12px;
  margin-bottom:1rem;
  font-size:1.1rem;
}
.quiz-options{
  display:grid;
  gap:0.75rem;
  margin-bottom:1rem;
}
.quiz-option{
  background:white;
  border:2px solid var(--accent);
  padding:1rem;
  border-radius:10px;
  cursor:pointer;
  transition:all 0.3s;
  text-align:left;
}
.quiz-option:hover{
  background:var(--accent);
  color:white;
  transform:translateX(5px);
}
.quiz-option.correct{
  background:var(--accent-2);
  color:white;
  border-color:var(--accent-2);
}
.quiz-option.wrong{
  background:#ff6b6b;
  color:white;
  border-color:#ff6b6b;
}
.quiz-option.disabled{
  cursor:not-allowed;
  opacity:0.6;
}

/* Game Stats */
.game-stats{
  margin-top:1rem;
  padding:1rem;
  background:rgba(255,184,77,0.1);
  border-radius:10px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  flex-wrap:wrap;
  gap:1rem;
}
.game-stats p{
  margin:0;
  font-weight:600;
}

/* Responsive Games */
@media (max-width:600px){
  .memory-game{
    grid-template-columns:repeat(4, 1fr);
    gap:0.5rem;
  }
  .click-game-area{
    height:250px;
  }
  .clickable-giraffe{
    width:60px;
    height:90px;
  }
}
