@font-face {
  font-family: 'Gochi Hand';
  src: url('/assets/fonts/GochiHand-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
/* ===== Engliplay - base styles (Claymorphism) ===== */
@import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@500;600;700;800&family=Comic+Neue:wght@400;700&family=IBM+Plex+Mono:wght@500;600&display=swap');

:root {
  /* Brand palette - Learning blue + play amber + fun pink */
  --primary: #2563EB;
  --primary-dark: #1D4ED8;
  --primary-shadow: #1E40AF;
  --on-primary: #FFFFFF;

  --secondary: #F59E0B;
  --secondary-dark: #D97706;
  --secondary-shadow: #B45309;
  --on-secondary: #0F172A;

  --accent: #EC4899;
  --accent-dark: #DB2777;
  --accent-shadow: #BE185D;
  --on-accent: #FFFFFF;

  --hp-color: #22C55E;

  --bg: #0B1220;
  --text: #F1F5F9;
  --text-muted: #94A3B8;

  --card: #131C31;
  --card-text: #F1F5F9;
  --tint: #1B2540;
  --border: #1E293B;
  --border-strong: #334155;

  --success-bg: rgba(34,197,94,.15);
  --success-text: #4ADE80;
  --error-bg: rgba(248,113,113,.15);
  --error-text: #FCA5A5;

  --radius: 20px;
  --radius-sm: 12px;
  --radius-lg: 28px;

  /* Chunky "clay" shadow: a solid block offset + a soft glow underneath */
  --shadow: 0 3px 0 var(--border-strong), 0 8px 18px rgba(37,99,235,.25);
  --shadow-hover: 0 5px 0 var(--border-strong), 0 14px 26px rgba(37,99,235,.35);

  --font-display: 'Baloo 2', 'Segoe UI', system-ui, sans-serif;
  --font-body: 'Comic Neue', 'Segoe UI', system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', 'Courier New', monospace;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  background: var(--sky-bottom, var(--bg));
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
}

a { color: var(--primary); text-decoration: none; }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; font-family: var(--font-display); font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: 2.3rem; }
h2 { font-size: 1.6rem; }

.container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }

/* ---------- Header / Nav: glowing icon-circle menu over the shared night sky ---------- */
.site-header {
  background: rgba(0,10,30,.4);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom: 2px solid rgba(255,255,255,.1);
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 14px 20px;
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  max-width: 1280px; margin: 0 auto;
}
.logo {
  display: inline-flex; flex-direction: row; align-items: center; gap: 14px; text-align: left;
}
.logo-img { width: 150px; height: 64px; object-fit: contain; filter: drop-shadow(0 0 15px rgba(0,191,255,.6)); }
.logo-subtitle {
  font-size: .72rem; font-weight: 800; color: #fff; background: rgba(0,191,255,.2);
  padding: 4px 12px; border-radius: 20px; border: 1px solid #00bfff; letter-spacing: .04em;
  text-shadow: 0 0 10px #00bfff; white-space: nowrap;
}

.main-nav { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; justify-content: center; }
.menu-item {
  display: flex; flex-direction: column; align-items: center; gap: 8px; width: 66px;
  text-decoration: none; opacity: .85; transition: opacity .2s ease, transform .2s ease;
}
.menu-item:hover { opacity: 1; transform: translateY(-3px); }
.icon-circle {
  width: 54px; height: 54px; border-radius: 50%; border: 3px solid rgba(255,255,255,.8);
  display: flex; align-items: center; justify-content: center; font-size: 1.3rem; color: #fff;
  background: radial-gradient(circle at 30% 30%, var(--icon-bg1), var(--icon-bg2));
  box-shadow: 0 0 16px var(--glow-color), inset 0 0 8px rgba(255,255,255,.3);
  transition: box-shadow .2s ease, border-color .2s ease;
}
.menu-item:hover .icon-circle { box-shadow: 0 0 26px var(--glow-color), inset 0 0 12px rgba(255,255,255,.5); border-color: #fff; }
.menu-label {
  font-size: .68rem; font-weight: 800; color: #fff; text-transform: uppercase;
  text-shadow: 0 2px 4px rgba(0,0,0,.8); text-align: center; letter-spacing: .02em; line-height: 1.15;
}
.menu-item.home   { --icon-bg1: #3b6bc2; --icon-bg2: #0a1c4a; --glow-color: #00bfff; }
.menu-item.about  { --icon-bg1: #9b59b6; --icon-bg2: #4a0e4e; --glow-color: #b830ff; }
.menu-item.classes{ --icon-bg1: #e67e22; --icon-bg2: #7e3f00; --glow-color: #ff9900; }
.menu-item.games  { --icon-bg1: #e74c3c; --icon-bg2: #7a1a1a; --glow-color: #ff4d4d; }
.menu-item.clock  { --icon-bg1: #2ecc71; --icon-bg2: #145a32; --glow-color: #00ff88; }
.menu-item.login  { --icon-bg1: #f1c40f; --icon-bg2: #7d6608; --glow-color: #ffe600; }
.menu-item.login .menu-label { max-width: 84px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Logout stays a light secondary link, not a glowing circle. */
.logout-link {
  flex-direction: row; width: auto; gap: 6px; color: rgba(255,255,255,.75); font-size: .78rem; font-weight: 700;
}
.logout-link:hover { color: #fff; }
.logout-link .menu-label { text-transform: none; }

.nav-toggle {
  display: none; background: none; border: none; font-size: 1.6rem; cursor: pointer;
  color: #fff; padding: 6px 10px; line-height: 1;
}

/* ---------- Glow effects ---------- */
@property --angle {
  syntax: '<angle>';
  inherits: false;
  initial-value: 0deg;
}
@keyframes spin-glow { to { --angle: 360deg; } }

body { position: relative; }
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  padding: 3px;
  background: conic-gradient(from var(--angle), var(--primary), var(--accent), var(--secondary), var(--hp-color), var(--primary));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: .5;
  animation: spin-glow 10s linear infinite;
}

/* ====================================================================
   Game World Background System
   Reusable across every EngliPlay page (markup lives in header.php):
     .game-bg     — fixed night-sky gradient,      z-index: 0
     .star-field  — fixed twinkling stars (JS),     z-index: 1
     page content (.site-header, main, .site-footer) sits at z-index: 10+
   .game-platform is the separate decorative "game world" strip that can
   be dropped in wherever it fits (hero end, section transition, page
   bottom) — see index.php for the current placement.
   ==================================================================== */
:root {
  --sky-top: #0B1734;
  --sky-middle: #1D4ED8;
  --sky-bottom: #0EA5E9;
  --star-opacity: .9;
}

.game-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-middle) 55%, var(--sky-bottom) 100%);
}

.star-field {
  position: fixed;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}
.star-field .star {
  position: absolute;
  border-radius: 50%;
  background: #fff;
  opacity: var(--star-base-opacity, .4);
  box-shadow: 0 0 4px rgba(255,255,255,.6);
  animation: star-twinkle var(--star-duration, 4s) ease-in-out var(--star-delay, 0s) infinite;
}
.star-field .star.is-steady { animation: none; opacity: var(--star-base-opacity, .5); }
@keyframes star-twinkle {
  0%, 100% { opacity: var(--star-base-opacity, .3); transform: scale(1); }
  50% { opacity: calc(var(--star-peak-opacity, .9) * var(--star-opacity)); transform: scale(1.15); }
}
@media (prefers-reduced-motion: reduce) {
  .star-field .star { animation: none !important; opacity: var(--star-base-opacity, .5); }
}

/* Real content always paints above the sky/star layers. (.site-header already
   sits above via its own position:sticky + z-index:50, left untouched here.) */
main, .site-footer { position: relative; z-index: 10; }

/* ---- GamePlatform: decorative game-world image strip ---- */
.game-platform {
  position: relative;
  z-index: 10;
  overflow: hidden;
  line-height: 0;
  margin-top: 48px;
}
.game-platform img { display: block; width: 100%; height: auto; }

@media (max-width: 780px) {
  .game-platform { height: 200px; }
  .game-platform img {
    position: absolute;
    top: 0;
    right: 0;
    width: auto;
    height: 100%;
    max-width: none;
  }
}

/* ---------- Buttons (glassmorphism pill) ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  min-height: 46px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: .01em;
  text-transform: none;
  font-size: .95rem;
  cursor: pointer;
  color: #fff;
  background: rgba(255,255,255,.08);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,.18);
  position: relative;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 6px 18px rgba(0,0,0,.22);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, border-color .15s ease;
}
.btn::after { content: "\2192"; font-weight: 500; opacity: .7; transition: transform .15s ease; }
.btn:hover { transform: translateY(-2px); background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.3); box-shadow: inset 0 1px 0 rgba(255,255,255,.22), 0 10px 24px rgba(0,0,0,.28); }
.btn:hover::after { transform: translateX(3px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: linear-gradient(180deg, rgba(59,130,246,.32), rgba(37,99,235,.24));
  border-color: rgba(147,197,253,.45);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.25), 0 6px 20px rgba(37,99,235,.28);
}
.btn-primary:hover {
  background: linear-gradient(180deg, rgba(59,130,246,.44), rgba(37,99,235,.34));
  border-color: rgba(147,197,253,.65);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.3), 0 10px 26px rgba(37,99,235,.38);
}
.btn-outline { background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.34); }
.btn-outline:hover { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.5); }
.btn-ghost { background: rgba(255,255,255,.03); border-color: rgba(255,255,255,.12); }
.btn-ghost:hover { background: rgba(255,255,255,.08); }
.btn-danger { color: var(--error-text); border-color: rgba(252,165,165,.35); background: rgba(248,113,113,.1); }
.btn-danger::after { content: none; }
.btn-lg { padding: 15px 34px; font-size: 1rem; min-height: 52px; }
.btn-block { width: 100%; }
.btn-sm { padding: 8px 18px; font-size: .82rem; min-height: 38px; font-weight: 600; }
.btn-sm:active { transform: translateY(0); }

/* ---------- Flash messages ---------- */
.flash { padding: 14px 18px; border-radius: var(--radius-sm); margin: 16px 0; font-weight: 700; border: 3px solid transparent; border-left-width: 6px; }
.flash-success { background: var(--success-bg); color: var(--success-text); border-color: var(--success-text); }
.flash-error { background: var(--error-bg); color: var(--error-text); border-color: var(--error-text); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  text-align: center;
  padding: 76px 20px 36px;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  top: -120px; left: 50%; transform: translateX(-50%);
  width: 640px; height: 420px;
  background:
    radial-gradient(circle at 22% 30%, rgba(245,158,11,.20), transparent 45%),
    radial-gradient(circle at 78% 25%, rgba(236,72,153,.16), transparent 45%),
    radial-gradient(circle at 50% 65%, rgba(37,99,235,.14), transparent 50%);
  pointer-events: none;
  z-index: 0;
}
.hero > * { position: relative; z-index: 1; }
.hero p { color: var(--text-muted); max-width: 640px; margin: 0 auto 18px; font-size: 1.1rem; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 32px; }
.hero-tweet { max-width: 620px; margin: 32px auto 0; text-align: left; }

/* Mouse-following dot grid */
.hero-dots {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  --mx: 50%;
  --my: 15%;
}
.hero-dots::before,
.hero-dots::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, var(--text) 1.6px, transparent 1.6px);
  background-size: 24px 24px;
}
.hero-dots::before { opacity: .08; }
.hero-dots::after {
  opacity: .55;
  -webkit-mask-image: radial-gradient(circle 200px at var(--mx) var(--my), #000 0%, transparent 75%);
  mask-image: radial-gradient(circle 200px at var(--mx) var(--my), #000 0%, transparent 75%);
}

.stats-row {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px;
  max-width: 1140px; margin: 44px auto; padding: 0 20px;
}
.stat-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 3px solid var(--border-strong);
  padding: 22px; text-align: center; transition: transform .15s ease, box-shadow .15s ease;
}
.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.stat-num { display: block; font-size: 1.9rem; font-weight: 800; color: var(--primary); font-family: var(--font-display); }
.stat-card:nth-child(2) .stat-num { color: var(--secondary-dark); }
.stat-card:nth-child(3) .stat-num { color: var(--accent-dark); }
.stat-card:nth-child(4) .stat-num { color: var(--hp-color); }
.stat-label { color: var(--text-muted); font-size: .9rem; font-weight: 700; }

/* ---------- Sections / cards ---------- */
.section { padding: 44px 20px; max-width: 1140px; margin: 0 auto; }
.section.narrow { max-width: 620px; }
.section.center { text-align: center; }

/* Anasayfada bu bölüm doğrudan koyu/mavi .game-bg zemininin üzerinde oturuyor
   (kart arkaplanı yok) - varsayılan mavi link rengi (--primary) o zeminle
   neredeyse aynı tona düşüp okunmaz hale geliyordu. Sarı + altı çizili net
   kontrast veriyor. */
.grade-links-section p { color: var(--text); }
.grade-links-section a {
  color: var(--hp-yellow);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 700;
}
.grade-links-section a:hover { color: #fff; }

.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; margin-top: 20px; }

/* Sliding class-card carousel */
.class-slider { overflow: hidden; margin-top: 20px; -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.class-slider-track { display: flex; gap: 20px; width: max-content; animation: class-slide 26s linear infinite; }
.class-slider:hover .class-slider-track { animation-play-state: paused; }
.class-slider-track .class-card { flex: 0 0 220px; }
@keyframes class-slide {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

.class-card, .class-card-detailed, .game-card, .feature-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 3px solid var(--border-strong);
  padding: 26px; transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.class-card:hover, .class-card-detailed:hover, .game-card:hover, .feature-card:hover {
  transform: translateY(-3px); box-shadow: var(--shadow-hover); border-color: var(--primary);
}
.class-card { text-align: center; color: var(--text); display: block; }
.class-card-badge {
  width: 48px; height: 48px; border-radius: 50%; background: var(--secondary); border: 3px solid var(--secondary-dark);
  color: var(--on-secondary); display: flex; align-items: center; justify-content: center;
  font-weight: 800; margin: 0 auto 12px; font-family: var(--font-display);
}
.class-card-detailed { text-align: center; }
.class-card-detailed p { color: var(--text-muted); margin: 8px 0 16px; }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-top: 20px; }
.feature-card { position: relative; z-index: 0; }
.feature-icon {
  font-size: 1.8rem; display: flex; align-items: center; justify-content: center;
  width: 56px; height: 56px; border-radius: 16px; margin-bottom: 14px;
  background: var(--tint); border: 3px solid var(--border-strong);
}
.feature-card p { color: var(--text-muted); }

.highlight-section {
  background: linear-gradient(160deg, rgba(245,158,11,.14) 0%, rgba(19,28,49,.9) 45%, rgba(236,72,153,.14) 100%);
  border-radius: var(--radius-lg); border: 3px solid var(--border-strong);
}

/* ---------- Forms ---------- */
.auth-form { display: flex; flex-direction: column; gap: 16px; text-align: left; margin-top: 20px; }
.auth-form label { font-weight: 700; font-size: .95rem; display: flex; flex-direction: column; gap: 6px; }
.auth-form input, .auth-form select {
  padding: 12px 14px; border-radius: var(--radius-sm); border: 3px solid var(--border);
  font-size: 1rem; font-family: inherit; background: var(--card); color: var(--text);
}
.auth-form input:focus, .auth-form select:focus { outline: none; border-color: var(--primary); }
.center-note { text-align: center; margin-top: 18px; color: var(--text-muted); }

.login-choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 24px 0; }
.login-choice-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 3px solid var(--border-strong);
  padding: 32px 16px; text-align: center; color: var(--text); transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.login-choice-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); border-color: var(--primary); }

.role-toggle { display: flex; justify-content: center; gap: 10px; margin: 20px 0; }
.role-toggle a {
  padding: 9px 22px; border-radius: 12px; border: 3px solid var(--border-strong); color: var(--text-muted); font-weight: 700;
}
.role-toggle a.active { border-color: var(--primary); color: var(--primary); background: var(--tint); }

/* ---------- Auth card (register/login) ---------- */
.auth-card {
  max-width: 460px; margin: 30px auto 0; padding: 40px 34px;
  border-radius: var(--radius-lg);
  color: #F8FAFC;
  background:
    radial-gradient(circle at 25% 0%, rgba(37,99,235,.55), transparent 55%),
    radial-gradient(circle at 85% 100%, rgba(236,72,153,.40), transparent 55%),
    linear-gradient(160deg, #0F172A, #1E293B 60%, #0F172A);
  box-shadow: var(--shadow-hover);
  border: 3px solid rgba(255,255,255,.08);
}
.auth-card-icon {
  width: 56px; height: 56px; margin: 0 auto 16px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 1.4rem;
  display: flex; align-items: center; justify-content: center;
}
.auth-card h1 { color: #fff; text-align: center; margin-bottom: 4px; }
.auth-card .auth-subtitle { text-align: center; color: #CBD5E1; margin: 0 0 8px; }
.auth-card .role-toggle a { color: #CBD5E1; border-color: rgba(255,255,255,.18); }
.auth-card .role-toggle a.active { color: #fff; border-color: var(--secondary); background: rgba(245,158,11,.15); }
.auth-card .auth-form label { color: #E2E8F0; }
.input-icon-wrap { position: relative; display: flex; align-items: center; }
.input-icon-wrap input,
.input-icon-wrap select { flex: 1; min-width: 0; }
.input-icon-wrap .input-icon {
  position: absolute; left: 14px; font-size: 1.05rem; opacity: .8; pointer-events: none;
}
.input-icon-wrap input[type="password"] { padding-right: 42px; }
.auth-card .auth-form input,
.auth-card .auth-form select {
  width: 100%; background: rgba(255,255,255,.07); border: 3px solid rgba(255,255,255,.14); color: #fff;
  padding-left: 42px;
}
.auth-card .auth-form select { padding-left: 42px; }
.auth-card .auth-form input::placeholder { color: #94A3B8; }
.auth-card .auth-form input:focus,
.auth-card .auth-form select:focus { border-color: var(--secondary); }
.password-toggle {
  position: absolute; right: 12px; background: none; border: none; cursor: pointer;
  font-size: 1.05rem; opacity: .8; color: #E2E8F0; padding: 4px;
}
.auth-card .center-note { color: #CBD5E1; }
.auth-card .center-note a { color: var(--secondary); font-weight: 700; }
.auth-card .flash-error { background: rgba(199,93,74,.18); color: #FCA5A5; border-color: #FCA5A5; }

/* ---------- About page: X/Twitter-style card ---------- */
.tweet-card {
  background: #0F1419; color: #E7E9EA; border: 1px solid #2F3336; border-radius: 18px;
  padding: 22px 24px; box-shadow: var(--shadow);
}
.tweet-header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.tweet-avatar { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.tweet-id { display: flex; flex-direction: column; line-height: 1.25; flex: 1; min-width: 0; }
.tweet-name { font-weight: 800; color: #fff; display: flex; align-items: center; gap: 4px; }
.tweet-name svg { width: 16px; height: 16px; color: #1D9BF0; flex-shrink: 0; }
.tweet-handle { color: #71767B; font-size: .9rem; }
.tweet-x-logo { width: 20px; height: 20px; color: #E7E9EA; flex-shrink: 0; }
.tweet-card h1 { font-size: 1.05rem; font-weight: 700; color: #E7E9EA; margin: 0 0 10px; }
.tweet-card p { color: #E7E9EA; margin: 0 0 12px; line-height: 1.5; font-size: .98rem; }
.tweet-meta { color: #71767B; font-size: .85rem; border-top: 1px solid #2F3336; padding-top: 12px; margin-top: 4px; }

/* ---------- Dashboards ---------- */
.dash-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 16px; margin: 24px 0; }
.dash-stat-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 3px solid var(--border-strong);
  padding: 20px; text-align: center;
}
.dash-stat-num { display: block; font-size: 1.7rem; font-weight: 800; color: var(--primary); font-family: var(--font-display); }
.dash-stat-label { color: var(--text-muted); font-size: .85rem; font-weight: 700; }
.admin-stats { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }

.dash-actions { margin: 10px 0 30px; }
.dash-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; margin-top: 20px; }
.dash-col h2 { font-size: 1.15rem; }
.empty-state { color: var(--text-muted); background: var(--tint); padding: 16px 18px; border-radius: var(--radius-sm); border: 3px dashed var(--border-strong); font-weight: 600; }
.plain-list, .badge-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.plain-list li, .badge-list li { background: var(--card); border-radius: var(--radius-sm); padding: 12px 16px; border: 3px solid var(--border-strong); }

/* ---------- Footer ---------- */
.site-footer { text-align: center; padding: 34px 20px; color: var(--text-muted); font-weight: 600; }

/* ---------- Admin ---------- */
.admin-subnav { display: flex; gap: 8px; flex-wrap: wrap; margin: 16px 0 8px; }
.admin-subnav a { padding: 9px 18px; border-radius: 12px; background: var(--card); border: 3px solid var(--border-strong); font-weight: 700; color: var(--text); }
.admin-subnav a.active { background: var(--primary); border-color: var(--primary-dark); color: var(--on-primary); }

.admin-grade-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 16px 0; }
.admin-grade-tabs a { padding: 6px 14px; border-radius: 10px; border: 3px solid var(--border-strong); color: var(--text-muted); font-weight: 700; font-size: .9rem; }
.admin-grade-tabs a.active { border-color: var(--primary); color: var(--primary); background: var(--tint); }

.admin-header-row { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; }

.admin-filter-form { display: flex; gap: 10px; flex-wrap: wrap; margin: 18px 0; }
.admin-filter-form select, .admin-filter-form input[type="text"] {
  padding: 9px 12px; border-radius: var(--radius-sm); border: 3px solid var(--border); font-family: inherit;
}

.admin-table { width: 100%; border-collapse: collapse; background: var(--card); border-radius: var(--radius); overflow: hidden; border: 3px solid var(--border-strong); }
.admin-table th, .admin-table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--border); font-size: .92rem; }
.admin-table th { background: var(--tint); font-weight: 700; }
.admin-table tr:last-child td { border-bottom: none; }

.badge-pill {
  display: inline-block; padding: 4px 12px; border-radius: 8px; font-size: .75rem; font-weight: 700;
  border: 1.5px dashed currentColor; cursor: pointer; font-family: var(--font-mono);
  text-transform: uppercase; letter-spacing: .04em;
}
.badge-live { background: var(--success-bg); color: var(--success-text); }
.badge-hidden { background: var(--tint); color: var(--text-muted); }

.btn-sm { padding: 6px 14px; font-size: .85rem; }
.inline-form { display: inline; }

.pagination { display: flex; gap: 6px; margin-top: 20px; flex-wrap: wrap; }
.pagination a { padding: 7px 14px; border-radius: 10px; border: 3px solid var(--border-strong); color: var(--text); font-weight: 700; }
.pagination a.active { background: var(--primary); color: var(--on-primary); border-color: var(--primary-dark); }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.checkbox-label { flex-direction: row !important; align-items: center; gap: 8px !important; }
.checkbox-label input { width: auto; }
.muted { color: var(--text-muted); font-size: .92rem; }

/* ---------- Units / Words / Sentences (student) ---------- */
.unit-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 3px solid var(--border-strong); padding: 22px; display: block; color: var(--text); position: relative; transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease; }
.unit-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); border-color: var(--primary); }
.unit-card.unit-completed { border-color: var(--success-text); }

.unit-subnav { display: flex; gap: 10px; margin: 18px 0; }
.unit-subnav a, .unit-subnav span { padding: 9px 20px; border-radius: 12px; font-weight: 700; }
.unit-subnav a { background: var(--card); border: 3px solid var(--border-strong); color: var(--text); }
.unit-subnav span.active { background: var(--primary); color: var(--on-primary); }

.word-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 3px solid var(--border-strong); padding: 22px; text-align: center; }
.word-card-image { height: 100px; display: flex; align-items: center; justify-content: center; margin-bottom: 10px; }
.word-card-image img { max-height: 100px; max-width: 100%; border-radius: var(--radius-sm); object-fit: cover; }
.word-card-placeholder { font-size: 2.4rem; opacity: .4; display: flex; align-items: center; justify-content: center; height: 100%; }
.word-meaning { color: var(--primary-dark); font-weight: 700; }
.word-phonetic { color: var(--text-muted); font-style: italic; font-size: .9rem; }
.word-example { font-size: .88rem; color: var(--text-muted); margin-top: 10px; }

.sentence-list { display: flex; flex-direction: column; gap: 14px; margin-top: 20px; }
.sentence-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 3px solid var(--border-strong); padding: 18px 22px; display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.sentence-en { font-weight: 700; font-size: 1.05rem; margin: 0; }
.sentence-tr { margin: 2px 0 0; }
.sentence-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; text-align: right; }

.word-card-learned { border-color: var(--success-text); }
.learned-badge { align-self: center; }

/* ---------- Games ---------- */
.game-section { max-width: 900px; }
.game-hud { display: flex; gap: 20px; font-weight: 800; font-size: 1.1rem; margin: 10px 0 20px; font-family: var(--font-mono); letter-spacing: .02em; }
/* Opaque panel so game text/lines (many use var(--primary)/var(--primary-dark),
   which is the exact same blue as the shared sky background's middle band —
   see "Game World Background System") stay readable regardless of what
   page-level decorative background sits behind this page. */
.game-root {
  min-height: 200px;
  background: var(--card);
  border: 3px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: var(--shadow);
}

.game-result-overlay {
  position: fixed; inset: 0; background: rgba(15, 23, 42, 0.55); z-index: 200;
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.game-result-box {
  background: var(--card); border-radius: var(--radius); padding: 34px; max-width: 420px; width: 100%;
  text-align: center; box-shadow: var(--shadow-hover); border: 3px solid var(--border-strong);
}
.result-xp { font-weight: 800; color: var(--primary); font-size: 1.1rem; margin: 10px 0; font-family: var(--font-mono); }
#result-badges { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-bottom: 14px; }

/* Misafir oyun modu: oyun sırasında üstte uyarı şeridi, bitince dönüşüm CTA'sı. */
.guest-play-banner {
  background: rgba(251,191,36,.12); border: 2px solid var(--hp-yellow, #FBBF24);
  border-radius: var(--radius-sm); padding: 10px 16px; margin: 14px 0;
  font-weight: 700; font-size: .92rem;
}
.guest-play-banner a { color: var(--hp-yellow, #FBBF24); text-decoration: underline; }
#result-guest-cta { margin-bottom: 16px; }
.guest-cta-text { font-weight: 700; margin: 0 0 10px; }

.game-card-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 18px; margin-top: 20px; }
.game-card-tile {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 3px solid var(--border-strong);
  padding: 24px; text-align: center; color: var(--text); transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.game-card-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); border-color: var(--primary); }
.game-card-tile-link { display: block; color: inherit; text-decoration: none; }
.game-card-play-btn { display: inline-block; margin-top: 14px; }
.game-card-tile .feature-icon { font-size: 2.2rem; width: 64px; height: 64px; margin: 0 auto 14px; }
/* Emoji yerine gerçek oyun görseli; emoji ile aynı küçük ikon boyutunda. */
.game-card-tile .game-icon-thumb {
  display: block; width: 64px; height: 64px; margin: 0 auto 14px;
  border-radius: 16px; object-fit: cover; border: 3px solid var(--border-strong);
}

/* Hangman */
.hangman-meaning { text-align: center; color: var(--text-muted); margin-bottom: 10px; }

/* Darağacı sahnesi: direk her zaman görünür (ahşap), yanlış tahminde
   sırayla baş/gövde/kol/bacak eklenir. Bkz. assets/js/games/hangman.js. */
.hangman-stage {
  position: relative;
  display: flex; justify-content: center; align-items: flex-end;
  margin: 4px auto 8px; min-height: 190px;
}
.hangman-stage::before {
  content: ''; position: absolute; left: 50%; bottom: 6px;
  width: 200px; height: 140px; transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(37,99,235,.35), transparent 72%);
  z-index: 0;
}
.hangman-gallows { position: relative; z-index: 1; width: 160px; height: auto; overflow: visible; }
.hangman-gallows .hg-wood { stroke: #B4813F; stroke-width: 7; stroke-linecap: round; fill: none; }
.hangman-gallows .hg-rope { stroke: #8B5E34; stroke-width: 3; }
.hangman-gallows .hg-figure { stroke: #F1F5F9; stroke-width: 5; stroke-linecap: round; fill: none; }

/* Kelime: her harf ayrı bir "karo" (fayans) olarak, boşluklar sadece aralık. */
.hangman-word { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; align-items: center; margin: 18px 0; }
.hangman-tile {
  min-width: 38px; height: 48px; padding: 0 4px;
  display: flex; align-items: center; justify-content: center;
  background: #fff; color: #0F172A; font-weight: 800; font-size: 1.35rem;
  border-radius: 10px; box-shadow: 0 3px 0 #CBD5E1, 0 6px 10px rgba(0,0,0,.25);
  font-family: var(--font-mono); text-transform: uppercase;
}
.hangman-tile-fixed { background: rgba(255,255,255,.18); color: var(--text); box-shadow: none; border: 3px solid rgba(255,255,255,.35); }
.hangman-gap { width: 14px; }

/* Klavye: her tuş farklı renk (bkz. hangman.js --tile-a/--tile-b), doğru=yeşil, yanlış=gri. */
.hangman-keyboard { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; max-width: 520px; margin: 0 auto; }
.hangman-keyboard button {
  width: 44px; height: 46px; border-radius: 12px; border: none;
  background: linear-gradient(180deg, var(--tile-a, #3B82F6), var(--tile-b, #1D4ED8));
  box-shadow: 0 4px 0 #1E3A8A, 0 6px 10px rgba(0,0,0,.3);
  color: #fff; font-weight: 800; font-size: 1.05rem; cursor: pointer; text-transform: uppercase;
  transition: transform .08s ease, box-shadow .08s ease, background .15s ease;
}
.hangman-keyboard button:hover:not(:disabled) { transform: translateY(-2px); }
.hangman-keyboard button:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 2px 0 #1E3A8A, 0 3px 6px rgba(0,0,0,.3); }
.hangman-keyboard button.is-correct { background: linear-gradient(180deg, #4ADE80, #16A34A); box-shadow: 0 4px 0 #15803D, 0 6px 10px rgba(0,0,0,.3); color: #08350F; }
.hangman-keyboard button.is-wrong { background: linear-gradient(180deg, #64748B, #475569); box-shadow: 0 4px 0 #334155; color: rgba(255,255,255,.7); }
.hangman-keyboard button:disabled { cursor: default; }

/* Sayfa başlığı: darağacı temasına uygun asılı ahşap tabela. */
.page-game-hangman .game-section { text-align: center; }
.page-game-hangman .game-hud { justify-content: center; }
.page-game-hangman .game-section h1 {
  display: table; margin: 10px auto 6px; padding: 10px 36px;
  background: linear-gradient(180deg, #C98A46, #8B5E34);
  border: 4px solid #6B4423; border-radius: 14px;
  color: #fff; text-shadow: 0 2px 0 rgba(0,0,0,.35);
  box-shadow: 0 6px 14px rgba(0,0,0,.35);
}

/* Word matching / memory */
/* Renkli "bulmaca etiketi" kartlar + doğru eşleşmede iki kart arasında
   parlayan bağlantı çizgisi (bkz. assets/js/games/word-matching.js). */
.match-stage { position: relative; max-width: 720px; margin: 0 auto; }
.match-lines { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1; overflow: visible; }
.match-line {
  fill: none; stroke: #FBBF24; stroke-width: 5; stroke-linecap: round;
  filter: drop-shadow(0 0 6px rgba(251,191,36,.75));
  opacity: 0; transition: opacity .35s ease;
}
.match-line.is-visible { opacity: 1; }
.match-columns { position: relative; z-index: 2; display: grid; grid-template-columns: 1fr 1fr; gap: 56px; }
.match-col { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.match-item {
  position: relative; padding: 14px 18px; border-radius: 16px; margin: 0;
  cursor: pointer; text-align: center; font-weight: 800; color: #fff;
  background: linear-gradient(160deg, var(--tag-a, var(--primary)), var(--tag-b, var(--primary-dark)));
  border: 3px solid rgba(255,255,255,.55);
  box-shadow: 0 4px 0 rgba(0,0,0,.22), 0 8px 14px rgba(0,0,0,.28);
  transition: transform .15s ease, box-shadow .15s ease, opacity .3s ease;
}
.match-item::after {
  content: ''; position: absolute; top: 50%; transform: translateY(-50%);
  width: 14px; height: 14px; border-radius: 50%;
  background: #fff; border: 3px solid rgba(255,255,255,.7); opacity: .9;
}
#en-col .match-item::after { right: -10px; }
#tr-col .match-item::after { left: -10px; }
.match-item:hover:not(.matched) { transform: translateY(-2px); box-shadow: 0 6px 0 rgba(0,0,0,.22), 0 10px 16px rgba(0,0,0,.3); }
.match-item.selected { outline: 3px solid #fff; box-shadow: 0 0 0 4px rgba(255,255,255,.45), 0 8px 14px rgba(0,0,0,.3); }
.match-item.matched { opacity: .55; cursor: default; }
.match-item.matched::after { background: #22C55E; }
.match-item.wrong { animation: match-shake .4s ease; box-shadow: 0 0 0 4px rgba(239,68,68,.5), 0 8px 14px rgba(0,0,0,.3); }
@keyframes match-shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

.page-game-word-matching .game-section { text-align: center; }
.page-game-word-matching .game-hud { justify-content: center; }
.page-game-word-matching .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2.2rem; font-family: var(--font-display);
  color: #FBBF24;
  background: linear-gradient(180deg, #FFE066, #FFB020);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}

/* Hafıza kartları: kapalıyken mavi "?" kart arkası (kesikli iç çerçeve),
   açılınca beyaz kart + kelime; eşleşince altın parıltı halkası. */
.memory-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; max-width: 560px; margin: 0 auto; }
.memory-card {
  position: relative; aspect-ratio: 1; border-radius: 16px; display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-weight: 800; font-family: var(--font-display); text-align: center; padding: 6px;
  background: linear-gradient(160deg, #3B82F6, #1D4ED8);
  border: 3px solid rgba(255,255,255,.45);
  color: #fff; font-size: .95rem;
  box-shadow: 0 4px 0 #1E3A8A, 0 8px 14px rgba(0,0,0,.3);
  transition: transform .15s ease, box-shadow .15s ease;
}
.memory-card::before {
  content: ''; position: absolute; inset: 5px; border-radius: 11px;
  border: 2px dashed rgba(255,255,255,.4); pointer-events: none;
}
.memory-card:hover:not(.flipped):not(.matched) { transform: translateY(-2px); }
.memory-mark { font-size: 2rem; text-shadow: 0 2px 0 rgba(0,0,0,.25); }
.memory-card.flipped {
  background: #fff; color: #0F172A; border: 3px solid #FBBF24;
  box-shadow: 0 4px 0 #CBD5E1, 0 8px 14px rgba(0,0,0,.25);
}
.memory-card.flipped::before { display: none; }
.memory-card.matched {
  background: #fff; color: #16A34A; border: 3px solid #FBBF24;
  box-shadow: 0 0 0 4px rgba(251,191,36,.4), 0 0 20px rgba(251,191,36,.55);
  cursor: default; animation: memory-pop .35s ease;
}
.memory-card.matched::before { display: none; }
.memory-card.wrong { animation: match-shake .4s ease; border-color: #EF4444; }
@keyframes memory-pop {
  0% { transform: scale(.9); }
  60% { transform: scale(1.06); }
  100% { transform: scale(1); }
}

.page-game-memory .game-section { text-align: center; }
.page-game-memory .game-hud { justify-content: center; }
.page-game-memory .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2.2rem; font-family: var(--font-display);
  color: #FBBF24;
  background: linear-gradient(180deg, #FFE066, #FFB020);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}

/* Oyun butonlari tarayici varsayilani siyah metin yerine acik metin alsin
   (.btn kendi rengini acikca verdigi icin etkilenmez) */
:where(#game-root) button { color: var(--text); }

/* Letter tiles (word hunt / word creation) — her harf taşı JS'ten gelen
   --tile-a/--tile-b değişkenleriyle farklı renkte (bkz. word-hunt.js,
   word-creation.js). Kırmızı/yeşil paletten kasıtlı olarak çıkarıldı: bu
   tonlar sadece aşağıdaki .hunt-feedback doğru/yanlış bildiriminde kullanılır. */
.letter-cloud { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; max-width: 560px; margin: 16px auto; }
.letter-tile {
  width: 52px; height: 52px; border-radius: 14px; border: 3px solid rgba(255,255,255,.5);
  background: linear-gradient(160deg, var(--tile-a, #2E3B57), var(--tile-b, #1E293B));
  color: #fff; font-weight: 800; font-family: var(--font-display); font-size: 1.2rem; cursor: pointer;
  box-shadow: 0 4px 0 rgba(0,0,0,.25), 0 8px 12px rgba(0,0,0,.3); text-transform: uppercase;
  transition: transform .12s ease, box-shadow .12s ease;
}
.letter-tile:hover:not(:disabled) { transform: translateY(-2px); border-color: rgba(255,255,255,.7); }
.letter-tile:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 1px 0 rgba(0,0,0,.25); }
.letter-tile:disabled { opacity: .3; cursor: default; box-shadow: none; }
.build-slot { min-height: 50px; display: flex; gap: 10px; justify-content: center; align-items: center; margin-bottom: 16px; }
.build-slot span {
  width: 44px; height: 54px; min-width: 44px; display: flex; align-items: center; justify-content: center;
  border-radius: 10px; background: rgba(15,23,42,.6); border: 3px solid #22D3EE;
  box-shadow: 0 0 10px rgba(34,211,238,.6), inset 0 0 8px rgba(34,211,238,.25);
  color: #fff; font-size: 1.4rem; font-weight: 800; font-family: var(--font-mono);
}
.word-target-meaning { text-align: center; font-size: 1.2rem; font-weight: 700; color: var(--primary-dark); margin-bottom: 4px; }
.hunt-feedback { text-align: center; font-weight: 800; font-size: 1.15rem; margin-top: 16px; }
.hunt-feedback.is-correct { color: #4ADE80; }
.hunt-feedback.is-wrong { color: #F87171; }

/* English Word Hunt / Word Creation: bulma temalı başlık + ipucu rozeti. */
.page-game-word-hunt .game-section,
.page-game-word-creation .game-section { text-align: center; }
.page-game-word-hunt .game-hud,
.page-game-word-creation .game-hud { justify-content: center; }
.page-game-word-hunt .game-section h1,
.page-game-word-creation .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2.1rem; font-family: var(--font-display);
  color: #FBBF24;
  background: linear-gradient(180deg, #FFE066, #FFB020);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}
.page-game-word-hunt .game-section h1::before { content: '🔍 '; -webkit-text-fill-color: initial; }
.page-game-word-creation .game-section h1::before { content: '🧩 '; -webkit-text-fill-color: initial; }

.page-game-word-hunt .word-target-meaning,
.page-game-word-creation .word-target-meaning {
  display: table; margin: 0 auto 18px; padding: 10px 20px;
  background: rgba(15,23,42,.55); border: 2px solid #38BDF8; border-radius: 14px;
  box-shadow: 0 0 14px rgba(56,189,248,.45);
  color: #FBBF24; font-size: 1rem;
}
.page-game-word-hunt .word-target-meaning strong,
.page-game-word-creation .word-target-meaning strong { color: #fff; }
.hint-icon { margin-right: 4px; }

/* Wordsearch: beyaz "kağıt" ızgara + her kelime kendi renginde (bkz.
   wordsearch.js --tile-a/--tile-b). Liste öğesi ve bulunan hücreler aynı
   rengi paylaşır, tanımayı kolaylaştırır. */
.wordsearch-wrap { display: flex; gap: 30px; flex-wrap: wrap; justify-content: center; align-items: flex-start; }
.wordsearch-grid {
  display: grid; gap: 4px; user-select: none;
  --ws-cell: 36px;
  grid-template-columns: repeat(var(--cols), var(--ws-cell));
  background: #1D4ED8; padding: 10px; border-radius: 16px;
  border: 4px solid #2563EB; box-shadow: 0 10px 0 #1E3A8A, 0 16px 26px rgba(0,0,0,.35);
}
.wordsearch-cell {
  width: var(--ws-cell); height: var(--ws-cell); display: flex; align-items: center; justify-content: center;
  background: #F8FAFC; color: #0F172A; border: none; border-radius: 6px;
  font-weight: 800; font-family: var(--font-mono); cursor: pointer; font-size: .95rem; text-transform: uppercase;
  transition: background .12s ease, transform .1s ease;
}
.wordsearch-cell.selecting { background: #FBBF24; color: #1D4ED8; }
.wordsearch-cell.found { background: linear-gradient(160deg, var(--tile-a, #34D399), var(--tile-b, #059669)); color: #fff; box-shadow: 0 0 0 2px rgba(255,255,255,.5) inset; }
.wordsearch-cell.wrong { background: #EF4444; color: #fff; }
.wordsearch-list { list-style: none; padding: 0; min-width: 180px; display: flex; flex-direction: column; gap: 10px; }
.wordsearch-list li {
  padding: 10px 18px; border-radius: 999px; text-align: center;
  font-weight: 800; font-family: var(--font-display);
  background: linear-gradient(160deg, var(--tile-a, var(--primary)), var(--tile-b, var(--primary-dark)));
  color: #fff; border: 3px solid rgba(255,255,255,.5);
  box-shadow: 0 4px 0 rgba(0,0,0,.22), 0 8px 12px rgba(0,0,0,.25);
  transition: opacity .2s ease;
}
.wordsearch-list li.found { opacity: .45; text-decoration: line-through; box-shadow: none; transform: none; }

.page-game-wordsearch .game-section { text-align: center; }
.page-game-wordsearch .game-hud { justify-content: center; }
.page-game-wordsearch .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2.1rem; font-family: var(--font-display);
  color: #FBBF24;
  background: linear-gradient(180deg, #FFE066, #FFB020);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}
.page-game-wordsearch .game-section h1::before { content: '🔎 '; -webkit-text-fill-color: initial; }

/* Sentence ordering: renkli, 3D "kabartma" kelime blokları. Her kelime
   pool/build arasında taşınırken aynı rengi korur (bkz. sentence-ordering.js
   --tile-a/--tile-b), yerleştirilince altına sıra numarası rozeti çıkar. */
.sentence-build-area {
  min-height: 76px; border: 3px dashed rgba(255,255,255,.3); border-radius: var(--radius-sm);
  padding: 16px 12px 28px; display: flex; flex-wrap: wrap; gap: 14px; justify-content: center;
  max-width: 700px; margin: 16px auto; background: rgba(15,23,42,.35);
}
.sentence-pool { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; max-width: 700px; margin: 0 auto; }
.word-chip {
  position: relative; padding: 12px 20px; border-radius: 14px;
  font-weight: 800; font-family: var(--font-display); font-size: 1.05rem; cursor: pointer;
  color: #fff; background: linear-gradient(160deg, var(--tile-a, var(--primary)), var(--tile-b, var(--primary-dark)));
  border: 3px solid rgba(255,255,255,.55);
  box-shadow: 0 5px 0 rgba(0,0,0,.25), 0 9px 14px rgba(0,0,0,.3);
  transition: transform .15s ease, box-shadow .15s ease;
}
.word-chip:hover { transform: translateY(-3px); }
.word-chip:active { transform: translateY(2px); box-shadow: 0 2px 0 rgba(0,0,0,.25); }
.word-chip .chip-num {
  position: absolute; left: 50%; bottom: -24px; transform: translateX(-50%);
  width: 22px; height: 22px; border-radius: 50%; background: #0F172A;
  border: 2px solid var(--tile-a, #fff); color: #fff; font-size: .75rem; font-family: var(--font-mono);
  display: flex; align-items: center; justify-content: center;
}
.word-chip.outline {
  background: rgba(255,255,255,.05); color: var(--tile-a, #fff);
  border: 3px solid var(--tile-a, var(--border-strong));
  box-shadow: 0 3px 0 rgba(0,0,0,.2);
}
.word-chip.outline:hover { background: rgba(255,255,255,.12); }

.page-game-sentence-ordering .game-section { text-align: center; }
.page-game-sentence-ordering .game-hud { justify-content: center; }
.page-game-sentence-ordering .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2.1rem; font-family: var(--font-display);
  color: #FBBF24;
  background: linear-gradient(180deg, #FFE066, #FFB020);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}
.page-game-sentence-ordering .game-section h1::before { content: '🔤 '; -webkit-text-fill-color: initial; }

/* Grammar games */
.grammar-sentence { font-size: 1.3rem; text-align: center; margin: 24px 0; line-height: 2; }
.grammar-tf-buttons { display: flex; gap: 14px; justify-content: center; margin-top: 20px; }

/* Grammar Detective: renkli "kanıt" kelime kartları (bkz. grammar-detective.js
   --tile-a/--tile-fg). Kırmızı/yeşil sadece tıklanan kelime ve gerçek
   hatanın ortaya çıkmasında kullanılır. */
.grammar-sentence {
  display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; align-items: center;
  font-size: 1.15rem; line-height: 1.4; max-width: 720px; margin: 24px auto;
}
.g-word {
  position: relative; cursor: pointer; padding: 10px 16px; border-radius: 12px;
  font-weight: 800; font-family: var(--font-display);
  background: var(--tile-a, #F8FAFC); color: var(--tile-fg, #0F172A);
  border: 3px solid rgba(255,255,255,.55);
  box-shadow: 0 4px 0 rgba(0,0,0,.22), 0 8px 12px rgba(0,0,0,.25);
  transition: transform .15s ease, box-shadow .15s ease;
}
.g-word:hover { transform: translateY(-2px); }
.g-word.is-correct { background: #22C55E; color: #fff; border-color: rgba(255,255,255,.6); }
.g-word.is-wrong { background: #EF4444; color: #fff; border-color: rgba(255,255,255,.6); }
.g-word.is-error-reveal { background: #EF4444; color: #fff; border-color: #FBBF24; box-shadow: 0 0 0 4px rgba(251,191,36,.4), 0 8px 12px rgba(0,0,0,.3); }
.g-word.is-error-reveal::after { content: '🔍'; position: absolute; top: -16px; right: -10px; font-size: 1.1rem; filter: drop-shadow(0 2px 2px rgba(0,0,0,.5)); }

.detective-clue {
  display: table; margin: 6px auto 14px; padding: 8px 18px;
  border: 2px dashed #38BDF8; border-radius: 999px; background: rgba(15,23,42,.5);
  color: #38BDF8; font-weight: 700; font-size: .95rem;
}

.page-game-grammar-detective .game-section { text-align: center; }
.page-game-grammar-detective .game-hud { justify-content: center; }
.page-game-grammar-detective .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2.1rem; font-family: var(--font-display);
  color: #38BDF8;
  background: linear-gradient(180deg, #7DD3FC, #38BDF8);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}
.page-game-grammar-detective .game-section h1::before { content: '🕵️ '; -webkit-text-fill-color: initial; }

/* Grammar Police: "tutanak" panosu — krem kart, mavi çerçeve, sarı-siyah
   şerit alt kenar; CORRECT/INCORRECT büyük yeşil/kırmızı haplar. */
.page-game-grammar-police .game-section { text-align: center; }
.page-game-grammar-police .game-hud { justify-content: center; }
.page-game-grammar-police .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2.1rem; font-family: var(--font-display);
  color: #FBBF24;
  background: linear-gradient(180deg, #FFE066, #FFB020);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}
.page-game-grammar-police .game-section h1::before { content: '👮 '; -webkit-text-fill-color: initial; }

.page-game-grammar-police .police-board {
  position: relative; max-width: 640px; margin: 22px auto 10px;
  background: #F8FAFC; border: 6px solid #2563EB; border-radius: 20px;
  padding: 30px 26px 24px; box-shadow: 0 10px 0 #1D4ED8, 0 18px 30px rgba(0,0,0,.4);
  overflow: hidden;
}
.page-game-grammar-police .police-board-clip {
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%) rotate(-3deg);
  width: 46px; height: 26px; background: #2563EB; border-radius: 6px; z-index: 1;
}
.page-game-grammar-police .police-board-clip::after {
  content: ''; position: absolute; inset: 6px; border-radius: 3px; background: #FBBF24;
}
.page-game-grammar-police .police-board::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 10px;
  background: repeating-linear-gradient(45deg, #FBBF24 0 14px, #0F172A 14px 28px);
}
.page-game-grammar-police .grammar-sentence {
  display: block; color: #0F172A; font-size: 1.4rem; font-weight: 800;
  text-align: center; margin: 0; line-height: 1.5; font-family: var(--font-display);
}

.page-game-grammar-police .grammar-tf-buttons { gap: 20px; margin-top: 26px; }
.page-game-grammar-police .grammar-tf-buttons .btn {
  flex: 1 1 200px; max-width: 220px; padding: 16px 10px; border-radius: 999px;
  font-weight: 800; font-size: 1.05rem; font-family: var(--font-display); color: #fff;
  border: 3px solid rgba(255,255,255,.5);
  box-shadow: 0 5px 0 rgba(0,0,0,.25), 0 9px 14px rgba(0,0,0,.3);
  transition: transform .12s ease, box-shadow .12s ease;
}
.page-game-grammar-police .grammar-tf-buttons .btn:hover:not(:disabled) { transform: translateY(-2px); }
.page-game-grammar-police .grammar-tf-buttons .btn:active:not(:disabled) { transform: translateY(2px); }
.page-game-grammar-police #btn-true { background: linear-gradient(180deg, #4ADE80, #16A34A); }
.page-game-grammar-police #btn-false { background: linear-gradient(180deg, #F87171, #DC2626); }
.page-game-grammar-police .grammar-tf-buttons .btn:disabled { opacity: .55; cursor: default; }
.page-game-grammar-police .grammar-tf-buttons .btn.is-correct { box-shadow: 0 0 0 4px rgba(74,222,128,.6), 0 5px 0 rgba(0,0,0,.25); }
.page-game-grammar-police .grammar-tf-buttons .btn.is-wrong { box-shadow: 0 0 0 4px rgba(248,113,113,.6), 0 5px 0 rgba(0,0,0,.25); }

/* Picture puzzle: "Bu ne?" — beyaz ışıltılı çerçeveli görsel + 2x2 beyaz
   kartlar; doğru cevap yeşil + yıldızlar + onay işareti. */
.puzzle-caption {
  display: table; margin: 0 auto 16px; padding: 6px 18px;
  background: rgba(15,23,42,.5); border: 2px solid #38BDF8; border-radius: 999px;
  color: #38BDF8; font-weight: 700; font-size: .95rem;
}
.puzzle-image-frame {
  max-width: 340px; margin: 0 auto 24px; padding: 10px;
  background: #fff; border-radius: 20px; box-shadow: 0 0 0 4px rgba(56,189,248,.35), 0 12px 24px rgba(0,0,0,.35);
}
.puzzle-image { max-width: 100%; max-height: 240px; display: block; margin: 0 auto; border-radius: 14px; }
.puzzle-options { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 14px; max-width: 600px; margin: 0 auto; }
.puzzle-choice {
  position: relative; padding: 16px 14px; border-radius: 14px; cursor: pointer;
  background: #F8FAFC; color: #1D4ED8; font-weight: 800; font-family: var(--font-display); font-size: 1.05rem;
  border: 3px solid rgba(255,255,255,.6);
  box-shadow: 0 4px 0 rgba(0,0,0,.2), 0 8px 12px rgba(0,0,0,.25);
  transition: transform .15s ease, box-shadow .15s ease;
}
.puzzle-choice:hover:not(:disabled) { transform: translateY(-2px); }
.puzzle-choice-text { display: inline-flex; align-items: center; gap: 6px; }
.puzzle-choice.is-correct { background: linear-gradient(180deg, #4ADE80, #16A34A); color: #fff; }
.puzzle-choice.is-wrong { background: linear-gradient(180deg, #F87171, #DC2626); color: #fff; opacity: .8; }
.puzzle-choice .puzzle-stars {
  position: absolute; top: -20px; left: 50%; transform: translateX(-50%);
  font-size: 1rem; filter: drop-shadow(0 2px 3px rgba(0,0,0,.4));
}
.puzzle-choice .puzzle-check { margin-left: 6px; }

.page-game-picture-puzzle .game-section { text-align: center; }
.page-game-picture-puzzle .game-hud { justify-content: center; }
.page-game-picture-puzzle .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2.1rem; font-family: var(--font-display);
  color: #FBBF24;
  background: linear-gradient(180deg, #FFE066, #FFB020);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}
.page-game-picture-puzzle .game-section h1::before { content: '🖼️ '; -webkit-text-fill-color: initial; }

/* Hero builder */
.hero-stage { text-align: center; }
.hero-avatar { font-size: 5rem; margin: 10px 0; }
.hero-hp-bar { max-width: 320px; margin: 0 auto 20px; height: 20px; background: var(--border); border-radius: 999px; overflow: hidden; border: 3px solid var(--border-strong); }
.hero-hp-fill { height: 100%; background: linear-gradient(90deg, var(--hp-color), var(--primary)); transition: width .3s ease; }
.hero-question { text-align: center; font-size: 1.4rem; font-weight: 800; margin: 16px 0; font-family: var(--font-display); }

/* Interactive Story Maker: açık kitap sayfası + renkli seçenekler + altta
   büyüyen "bölüm günlüğü" (her doğru cevaptan sonra bir satır + yıldız). */
.story-book { max-width: 640px; margin: 0 auto; }
.story-page {
  background: #FDFBF6; color: #1E293B; border-radius: 20px;
  padding: 28px 26px; box-shadow: 0 10px 0 #1D4ED8, 0 18px 28px rgba(0,0,0,.35);
  border: 4px solid #2563EB;
}
.story-sentence { font-size: 1.25rem; line-height: 1.7; font-weight: 700; margin: 0 0 12px; }
.story-blank {
  display: inline-block; min-width: 70px; padding: 0 6px; border-bottom: 3px dashed #2563EB;
  color: #2563EB; text-align: center; font-family: var(--font-mono);
}
.story-hint { color: #64748B; font-size: .95rem; margin: 0 0 18px; }

.story-choices { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.story-choice {
  padding: 12px 22px; border-radius: 999px; cursor: pointer;
  font-weight: 800; font-family: var(--font-display); font-size: 1rem; color: #fff;
  background: linear-gradient(160deg, var(--tile-a, var(--primary)), var(--tile-b, var(--primary-dark)));
  border: 3px solid rgba(255,255,255,.6);
  box-shadow: 0 4px 0 rgba(0,0,0,.2), 0 8px 12px rgba(0,0,0,.25);
  transition: transform .15s ease, box-shadow .15s ease, opacity .2s ease;
}
.story-choice:hover:not(:disabled) { transform: translateY(-2px); }
.story-choice.is-correct { background: linear-gradient(160deg, #4ADE80, #16A34A); box-shadow: 0 0 0 4px rgba(74,222,128,.5), 0 8px 12px rgba(0,0,0,.3); }
.story-choice.is-wrong { opacity: .45; }
.story-choice:disabled { cursor: default; }

.story-log { margin: 18px auto 0; display: flex; flex-direction: column; gap: 10px; }
.story-log-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: rgba(15,23,42,.5); border: 2px solid #334155; border-radius: 14px;
  padding: 12px 16px; color: var(--text); font-size: .95rem;
}
.story-log-word { color: #4ADE80; font-weight: 800; }
.story-star { flex: 0 0 auto; font-size: 1.1rem; }

.page-game-interactive-story .game-section { text-align: center; }
.page-game-interactive-story .game-hud { justify-content: center; }
.page-game-interactive-story .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2rem; font-family: var(--font-display);
  color: #FBBF24;
  background: linear-gradient(180deg, #FFE066, #FFB020);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}
.page-game-interactive-story .game-section h1::before { content: '📖 '; -webkit-text-fill-color: initial; }

/* ---------- Responsive: tablet ---------- */
@media (max-width: 1024px) {
  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .memory-grid { max-width: 460px; }
}

/* ---------- Responsive: phone ---------- */
@media (max-width: 780px) {
  .header-inner { padding: 10px 16px; flex-wrap: wrap; justify-content: center; }
  .main-nav { display: none; }
  .nav-toggle { display: block; }

  /* Opens inline (pushes the page content below it down) instead of
     floating on top of it) as a wrapped row of icon-circles. */
  .main-nav.open {
    display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-start; gap: 16px;
    position: static;
    flex: 1 1 100%;
    order: 5;
    margin-top: 14px; padding: 14px 0 6px;
    border-top: 1px solid rgba(255,255,255,.15);
  }

  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .login-choice-grid { grid-template-columns: 1fr; }
  h1 { font-size: 1.7rem; }
  h2 { font-size: 1.3rem; }
  .form-row { grid-template-columns: 1fr; }
  .admin-table { display: block; overflow-x: auto; white-space: nowrap; }
  .sentence-card { flex-direction: column; align-items: flex-start; }
  .sentence-meta { align-items: flex-start; text-align: left; }

  /* Touch-friendly buttons everywhere */
  .btn { padding: 12px 22px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; }
  .btn-sm { padding: 10px 16px; min-height: 40px; }
  button.badge-pill { min-height: 40px; padding: 8px 16px; }

  /* Games */
  .game-hud { font-size: 1rem; gap: 14px; }
  .hangman-word { font-size: 1.5rem; letter-spacing: 4px; }
  .hangman-keyboard button { width: 34px; height: 40px; font-size: .9rem; }
  .match-columns { gap: 28px; }
  .match-item { padding: 10px 12px; font-size: .82rem; }
  .memory-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; max-width: 340px; }
  .memory-card { font-size: .78rem; }
  .memory-mark { font-size: 1.6rem; }
  .letter-tile { width: 42px; height: 42px; border-radius: 10px; font-size: 1.05rem; }
  .build-slot span { width: 36px; height: 44px; min-width: 36px; font-size: 1.1rem; }
  .wordsearch-wrap { flex-direction: column; align-items: center; }
  .wordsearch-grid { --ws-cell: 24px; max-width: 100%; overflow-x: auto; padding-bottom: 8px; font-size: .8rem; }
  .word-chip { padding: 10px 14px; font-size: .9rem; }
  .grammar-sentence { font-size: 1.05rem; line-height: 1.9; }
  .grammar-tf-buttons { flex-direction: column; align-items: stretch; }
  .grammar-tf-buttons .btn { width: 100%; }
  .page-game-grammar-police .grammar-tf-buttons .btn { max-width: none; width: 100%; }
  .page-game-grammar-police .police-board { padding: 24px 18px 20px; }
  .page-game-grammar-police .grammar-sentence { font-size: 1.15rem; }
  .puzzle-image { max-width: 100%; }
  .story-choice { flex: 1 1 45%; padding: 12px 14px; font-size: .92rem; }
  .story-page { padding: 20px 16px; }
  .story-sentence { font-size: 1.1rem; }
}

@media (max-width: 420px) {
  .memory-grid { grid-template-columns: repeat(3, 1fr); max-width: 280px; }
  .hangman-keyboard button { width: 30px; height: 38px; font-size: .8rem; }
  .dash-stats, .admin-stats { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Trace the Word ---------- */
.trace-word-stage { text-align: center; }
/* Mavi çerçeveli "yazı tahtası": kalın mavi kenarlık + beyaz iç kart,
   içinde noktalı kılavuz harfler çiziliyor (bkz. trace-word.js). */
.trace-board {
  display: inline-block; padding: 10px; margin: 16px 0;
  background: linear-gradient(180deg, #60A5FA, #2563EB);
  border-radius: 22px; box-shadow: 0 10px 0 #1D4ED8, 0 18px 28px rgba(0,0,0,.35);
  max-width: 100%;
}
.trace-canvas {
  display: block; border-radius: 14px; background: #fff;
  touch-action: none; max-width: 100%; cursor: crosshair;
}
.trace-buttons { display: flex; gap: 12px; justify-content: center; margin-top: 16px; }
.trace-status { margin-top: 14px; min-height: 28px; font-weight: 700; font-family: var(--font-mono); }
.trace-status.ok { color: var(--success-text); }
.trace-status.err { color: var(--error-text); }

.page-game-trace-word .game-section { text-align: center; }
.page-game-trace-word .game-hud { justify-content: center; }
.page-game-trace-word .game-section h1 {
  display: table; margin: 10px auto 6px; font-size: 2.1rem; font-family: var(--font-display);
  color: #38BDF8;
  background: linear-gradient(180deg, #FBBF24, #38BDF8);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 0 #1D4ED8, 0 8px 16px rgba(0,0,0,.35);
}
.page-game-trace-word .game-section h1::before { content: '✏️ '; -webkit-text-fill-color: initial; }

@media (max-width: 780px) {
  .trace-canvas { width: 100%; height: auto; }
  .trace-board { padding: 6px; border-radius: 16px; }
}
/* ---------- Class Card Images ---------- */
.class-card-image {
  width: 100%;
  max-width: 100%;
  height: 150px;
  margin-bottom: 16px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 3px solid var(--border-strong);
  background: var(--tint);
}

.class-card-image img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  object-fit: cover;
}

/* ---------- SEO / Ziyaretçi sayfaları ---------- */
.breadcrumb {
  max-width: 1140px;
  margin: 18px auto 0;
  padding: 0 20px;
  font-size: .9rem;
  color: var(--text-muted);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.breadcrumb a { color: var(--primary); font-weight: 700; text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb span[aria-current] { color: var(--text); font-weight: 700; }

.unit-card-num {
  display: inline-block;
  font-size: .78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--primary);
  margin-bottom: 6px;
}
.unit-card h2 { margin: 4px 0 8px; font-size: 1.15rem; }

.word-chip-list {
  list-style: none;
  padding: 0;
  margin: 14px 0 6px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 8px;
}
.word-chip-list li {
  background: var(--tint);
  border: 2px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-size: .92rem;
}

.game-card-thumb {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 3px solid var(--border-strong);
  margin-bottom: 12px;
}

/* Oyun demo sayfası */
.game-demo { max-width: 860px; }
.game-demo .game-demo-intro { font-size: 1.12rem; color: var(--text); margin: 8px 0 20px; }
.game-demo-figure { margin: 0 0 24px; }
.game-demo-figure img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 3px solid var(--border-strong);
  box-shadow: var(--shadow);
}
.game-demo-figure figcaption { margin-top: 8px; font-size: .85rem; }

/* Oyun demo sayfasında üye olmadan doğrudan oynama seçeneği (misafir modu). */
.game-demo-play-picker {
  background: var(--tint); border: 3px solid var(--primary);
  border-radius: var(--radius); padding: 16px 18px; margin: 0 0 24px;
}
.game-demo-play-label { font-weight: 800; margin: 0 0 10px; }
.game-demo-play-nav { display: flex; flex-wrap: wrap; gap: 10px; }

.yt-embed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  border: 3px solid var(--border-strong);
  background: var(--tint);
  margin-bottom: 24px;
}
.yt-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.yt-embed-placeholder { display: flex; align-items: center; justify-content: center; text-align: center; }
.yt-embed-placeholder .feature-icon { font-size: 3rem; }

/* Ziyaretçi CTA bloğu */
.visitor-cta { max-width: 860px; }
.visitor-cta-box {
  background: linear-gradient(180deg, var(--card), var(--tint));
  border: 3px solid var(--primary);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  text-align: center;
  box-shadow: var(--shadow);
}
.visitor-cta-box h2 { margin-top: 0; }
.visitor-cta-box p { color: var(--text-muted); max-width: 620px; margin: 10px auto; }
.visitor-cta-box .hero-actions { margin-top: 20px; }

/* Ünite ileri/geri gezinme */
.unit-pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 28px;
}
.unit-pager-link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  background: var(--card);
  border: 3px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--text);
  text-decoration: none;
  transition: border-color .15s ease, transform .15s ease;
}
.unit-pager-link:hover { border-color: var(--primary); transform: translateY(-2px); }
.unit-pager-next { text-align: right; align-items: flex-end; }

/* Sınıf hızlı bağlantıları */
.grade-quick-nav { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0 6px; }
.grade-quick-nav a {
  padding: 8px 14px;
  background: var(--tint);
  border: 2px solid var(--border-strong);
  border-radius: 999px;
  font-weight: 700;
  font-size: .9rem;
  color: var(--primary);
  text-decoration: none;
}
.grade-quick-nav a:hover { border-color: var(--primary); }

/* SSS */
.faq-list { margin: 14px 0; display: flex; flex-direction: column; gap: 10px; }
.faq-item {
  background: var(--card);
  border: 3px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
}
.faq-item summary { font-weight: 800; cursor: pointer; font-family: var(--font-display); }
.faq-item[open] summary { margin-bottom: 8px; }
.faq-item p { margin: 0; color: var(--text-muted); }

@media (max-width: 600px) {
  .unit-pager { grid-template-columns: 1fr; }
  .unit-pager-next { text-align: left; align-items: flex-start; }
}

/* ======================================================================
   HOMEPAGE ("Explore. Learn. Play!" adventure lobby) — scoped, doesn't
   touch the global dark-theme tokens used by every other page.
   ====================================================================== */
.page-home {
  --hp-purple: #7C3AED;
  --hp-purple-dark: #5B21B6;
  --hp-teal: #14B8A6;
  --hp-teal-dark: #0D9488;
  --hp-yellow: #FBBF24;
}

.section-heading-center { text-align: center; }

/* One single image behind the entire home-page world (hero, class carousel,
   stats, "Nasıl Çalışır?" and "Neden EngliPlay?") — never per-section, so
   there is exactly one continuous background with no seams anywhere. */
.page-world {
  position: relative;
  background:
    linear-gradient(rgba(5,15,40,.6), rgba(5,15,40,.6)),
    url('../../maskot1.jpg') center 40% / cover no-repeat;
}
.hero-map-panel {
  margin: 0;
  overflow: hidden;
  position: relative;
  z-index: 1;
  background: transparent;
}

/* ======================================================================
   HOMEPAGE — sections are transparent now: the shared Game World
   Background (night sky + stars, see the "Game World Background System"
   section above) shows through everywhere instead of a page-local
   purple/teal panel.
   ====================================================================== */
.page-home .how-it-works {
  position: relative;
  border: none;
  border-radius: 0;
  max-width: none;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding-left: 0;
  padding-right: 0;
  background: transparent;
}
.page-home .how-it-works-inner { max-width: 1140px; margin: 0 auto; padding: 0 20px; }
.page-home .highlight-section {
  position: relative;
  border: none;
  border-radius: 0;
  max-width: none;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding-left: 0;
  padding-right: 0;
  background: transparent;
}
.page-home .highlight-inner { max-width: 1140px; margin: 0 auto; padding: 0 20px; }

/* Stats row: sits inside .hero-map-panel, which already paints the shared
   background — kept transparent here so that one image stays continuous
   behind the hero text, class carousel and stats row alike. */
.page-home .stats-row {
  display: block;
  width: 100vw;
  max-width: none;
  margin: 0 calc(50% - 50vw);
  padding: 44px 0;
  background: transparent;
}
.page-home .stats-row-inner {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px;
  max-width: 1140px; margin: 0 auto; padding: 0 20px;
}
@media (max-width: 1024px) {
  .page-home .stats-row-inner { grid-template-columns: repeat(2, 1fr); }
}
.page-home .hiw-icon,
.page-home .feature-icon {
  background: rgba(255,255,255,.14);
  border-color: rgba(255,255,255,.3);
}
.page-home .hiw-step p,
.page-home .feature-card p { color: rgba(255,255,255,.85); }
.page-home .feature-card {
  background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.22);
}
.page-home .stat-card {
  background: transparent; border-color: rgba(255,255,255,.35);
}
.page-home .stat-label { color: rgba(255,255,255,.85); }
.page-home .how-it-works h2,
.page-home .highlight-section h2,
.page-home .hiw-step h4,
.page-home .feature-card h3 { color: #fff; }
.page-home .home-hero-inner {
  position: relative;
  width: 100vw;
  max-width: none;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding: 44px 0;
  background: transparent;
}
.home-hero-content {
  display: flex; align-items: center; justify-content: center; gap: 36px; flex-wrap: wrap;
  position: relative; z-index: 1;
  max-width: 1140px; margin: 0 auto; padding: 0 32px;
}
.home-hero-text { flex: 1 1 360px; text-align: center; }
.home-eyebrow {
  display: inline-block; margin: 0 0 12px; padding: 6px 16px; border-radius: 999px;
  background: rgba(255,255,255,.16); color: #fff; font-weight: 800; font-size: .8rem;
  letter-spacing: .04em; text-transform: uppercase;
}
.home-hero-text h1 {
  color: #fff; font-size: 2.6rem; letter-spacing: .02em; margin: 0 0 16px;
  text-shadow: 0 3px 0 rgba(0,0,0,.15);
}
.home-hero-sub { color: rgba(255,255,255,.9); max-width: 480px; font-size: 1.05rem; margin: 0 auto 26px; }
.home-hero-sub strong { color: var(--hp-yellow); }
.home-hero-actions { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.home-hero-art {
  flex: 0 0 auto; width: 220px; height: 220px;
  position: relative; z-index: 1;
}
.home-hero-art img {
  width: 100%; height: 100%; object-fit: contain;
  filter: drop-shadow(0 14px 18px rgba(0,0,0,.35));
  transition: transform .15s ease-out;
  will-change: transform;
}

.adventure-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; margin-top: 24px; }

/* Winding "game map" road for the featured adventures (Yay World style) */
.adventure-map {
  position: relative;
  max-width: 720px;
  margin: 28px auto 0;
  padding: 34px 20px;
  border-radius: var(--radius-lg);
  border: 3px solid var(--border-strong);
  box-shadow: var(--shadow);
  background:
    radial-gradient(circle at 15% 10%, rgba(20,184,166,.14), transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(124,58,237,.16), transparent 45%),
    var(--card);
}
.adventure-map::before {
  content: "";
  position: absolute; top: 34px; bottom: 34px; left: 50%; width: 3px;
  background: repeating-linear-gradient(to bottom, var(--border-strong) 0 10px, transparent 10px 20px);
  transform: translateX(-50%);
}
.adventure-map .map-stop-node {
  border: 4px solid rgba(255,255,255,.25);
}
.adventure-map .map-stop-node.adv-color-0 { background: linear-gradient(160deg, var(--hp-purple), var(--hp-purple-dark)); }
.adventure-map .map-stop-node.adv-color-1 { background: linear-gradient(160deg, var(--hp-teal), var(--hp-teal-dark)); }
.adventure-map .map-stop-node.adv-color-2 { background: linear-gradient(160deg, #F59E0B, #B45309); }
.adventure-map .map-stop-node.adv-color-3 { background: linear-gradient(160deg, #EC4899, #BE185D); }
.adventure-map .adventure-stats { color: var(--text-muted); font-size: .85rem; font-weight: 700; margin: 4px 0 12px; }

@media (max-width: 700px) {
  .adventure-map::before { left: 30px; }
  .adventure-map .map-stop, .adventure-map .map-stop-right { flex-direction: row; }
  .adventure-map .map-stop-right .map-stop-card { text-align: left; }
}
.adventure-card {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px;
  padding: 28px 20px; border-radius: var(--radius); color: #fff; text-decoration: none;
  border: 3px solid transparent; box-shadow: var(--shadow); transition: transform .15s ease, box-shadow .15s ease;
}
.adventure-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.adventure-card h3 { color: #fff; margin: 4px 0 0; }
.adventure-icon { font-size: 2.4rem; }
.adventure-stats { color: rgba(255,255,255,.85); font-size: .85rem; font-weight: 700; margin: 0 0 6px; }
.adventure-start { pointer-events: none; margin-top: 6px; }
.adv-color-0 { background: linear-gradient(160deg, var(--hp-purple), var(--hp-purple-dark)); }
.adv-color-1 { background: linear-gradient(160deg, var(--hp-teal), var(--hp-teal-dark)); }
.adv-color-2 { background: linear-gradient(160deg, #F59E0B, #B45309); }
.adv-color-3 { background: linear-gradient(160deg, #EC4899, #BE185D); }

.how-it-works-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 20px; margin-top: 24px; }
.hiw-step { text-align: center; padding: 20px; }
.hiw-icon {
  display: flex; align-items: center; justify-content: center; margin: 0 auto 12px;
  width: 68px; height: 68px; border-radius: 50%; font-size: 1.8rem;
  background: var(--tint); border: 3px solid var(--border-strong);
}
.hiw-step h4 { margin: 0 0 6px; }
.hiw-step p { color: var(--text-muted); margin: 0; font-size: .92rem; }

@media (max-width: 780px) {
  .page-home .home-hero-inner { padding: 32px 0; }
  .home-hero-content { padding: 0 22px; }
  .home-hero-text h1 { font-size: 1.9rem; }
  .home-hero-art { width: 130px; height: 130px; }
  .class-map-header { padding: 0 22px 22px; text-align: center; }
  .class-map-header h1 { font-size: 1.4rem; }
}

/* ======================================================================
   STUDENT DASHBOARD ("Cyber Kids" sidebar + progress tracker layout)
   ====================================================================== */
.dashboard-shell { display: flex; gap: 28px; align-items: flex-start; }
.dashboard-main { flex: 1; min-width: 0; }

.dashboard-sidebar {
  flex: 0 0 220px;
  background: linear-gradient(180deg, var(--primary), var(--primary-dark));
  border-radius: var(--radius-lg);
  padding: 26px 18px;
  text-align: center;
  position: sticky;
  top: 20px;
  box-shadow: var(--shadow-hover);
}
.dash-avatar {
  width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 50%;
  background: rgba(255,255,255,.18); color: #fff; font-family: var(--font-display);
  font-weight: 800; font-size: 1.6rem; display: flex; align-items: center; justify-content: center;
  border: 3px solid rgba(255,255,255,.35);
}
.dash-user-name { color: #fff; font-weight: 800; font-family: var(--font-display); }
.dash-user-role { color: rgba(255,255,255,.75); font-size: .85rem; margin-bottom: 22px; }
.dash-nav { display: flex; flex-direction: column; gap: 6px; text-align: left; }
.dash-nav a {
  display: block; padding: 10px 14px; border-radius: 12px; color: rgba(255,255,255,.85);
  font-weight: 700; font-size: .92rem; transition: background .15s ease, color .15s ease;
}
.dash-nav a:hover { background: rgba(255,255,255,.12); color: #fff; }
.dash-nav a.active { background: #fff; color: var(--primary-dark); }

.progress-tracker-card {
  display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  background: linear-gradient(120deg, var(--tint), var(--card));
  border: 3px solid var(--border-strong); border-radius: var(--radius-lg);
  padding: 26px 30px; margin: 20px 0;
}
.progress-tracker-text h2 { margin: 0 0 8px; }
.progress-tracker-text p { color: var(--text-muted); margin: 0 0 16px; }
.progress-tracker-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.progress-tracker-coins { font-size: 2rem; opacity: .8; }

.level-shelf { display: flex; align-items: flex-end; justify-content: center; gap: 20px; margin: 24px 0; flex-wrap: wrap; }
.level-shield {
  background: var(--card); border: 3px solid var(--border-strong); border-radius: var(--radius);
  padding: 18px 20px; text-align: center; min-width: 130px; opacity: .6; transform: scale(.92);
}
.level-shield-icon { font-size: 1.8rem; display: block; margin-bottom: 6px; }
.level-shield-label { font-weight: 800; display: block; }
.level-shield-current, .level-current {
  opacity: 1; transform: scale(1); border-color: var(--secondary); box-shadow: var(--shadow-hover);
}
.level-shield-bar { height: 10px; background: var(--tint); border-radius: 999px; overflow: hidden; margin: 10px 0 6px; border: 2px solid var(--border-strong); }
.level-shield-fill { height: 100%; background: linear-gradient(90deg, var(--primary), var(--accent)); border-radius: 999px; }
.level-shield-sub { font-size: .75rem; color: var(--text-muted); font-weight: 700; }

.dash-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 20px 0; }
.quest-mini-card, .leaderboard-card {
  background: var(--card); border: 3px solid var(--border-strong); border-radius: var(--radius-lg);
  padding: 24px 26px; box-shadow: var(--shadow);
}
.quest-head { font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--secondary); font-size: .8rem; margin-bottom: 8px; }
.quest-title { margin: 0 0 16px; }
.quest-progress-bar { height: 14px; background: var(--tint); border-radius: 999px; overflow: hidden; border: 2px solid var(--border-strong); }
.quest-progress-fill { height: 100%; background: linear-gradient(90deg, var(--primary), var(--accent)); border-radius: 999px; transition: width .4s ease; }
.quest-progress-label { margin-top: 6px; font-weight: 800; color: var(--text-muted); font-family: var(--font-mono); }
.quest-reward { margin: 14px 0; font-weight: 800; }
.quest-reward strong { color: var(--secondary); }
.quest-start { margin-top: 4px; }

.leaderboard-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.leaderboard-list li {
  display: flex; align-items: center; gap: 10px; padding: 9px 12px;
  border-radius: 12px; background: var(--tint); border: 2px solid var(--border-strong); font-weight: 700;
}
.leaderboard-list li.is-me { border-color: var(--secondary); background: rgba(245,158,11,.12); }
.lb-rank { color: var(--text-muted); font-family: var(--font-mono); width: 30px; }
.lb-name { flex: 1; }
.lb-xp { color: var(--primary); font-family: var(--font-mono); }

@media (max-width: 900px) {
  .dashboard-shell { flex-direction: column; }
  .dashboard-sidebar { position: static; width: 100%; flex: none; }
  .dash-nav { flex-direction: row; flex-wrap: wrap; justify-content: center; }
  .dash-two-col { grid-template-columns: 1fr; }
}

/* ======================================================================
   UNITS MAP ("Yay World" winding path of stops)
   ====================================================================== */
.unit-map { position: relative; max-width: 720px; margin: 30px auto 0; }
.unit-map::before {
  content: "";
  position: absolute; top: 0; bottom: 0; left: 50%; width: 3px;
  background: repeating-linear-gradient(to bottom, var(--border-strong) 0 10px, transparent 10px 20px);
  transform: translateX(-50%);
}
.map-stop { position: relative; display: flex; align-items: center; gap: 20px; margin: 0 0 32px; }
.map-stop-right { flex-direction: row-reverse; }
.map-stop-node {
  position: relative; z-index: 1; flex: 0 0 auto;
  width: 64px; height: 64px; border-radius: 50%; background: var(--card); border: 3px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center; font-size: 1.8rem;
  box-shadow: var(--shadow); text-decoration: none; transition: transform .15s ease, box-shadow .15s ease;
}
.map-stop-node:hover { transform: scale(1.08); box-shadow: var(--shadow-hover); }
.map-stop-node.is-completed { border-color: var(--success-text); box-shadow: 0 0 0 4px rgba(74,222,128,.18); }
.map-stop-card {
  flex: 1; background: var(--card); border: 3px solid var(--border-strong); border-radius: var(--radius);
  padding: 16px 20px; box-shadow: var(--shadow);
}
.map-stop-card h3 { margin: 0 0 4px; }
.map-stop-right .map-stop-card { text-align: right; }
.map-stop-stars { margin: 6px 0; letter-spacing: 2px; }
.star-off { opacity: .25; filter: grayscale(1); }
.map-stop-meta { color: var(--text-muted); font-size: .85rem; margin: 6px 0; }

.map-quicknav {
  display: flex; justify-content: center; gap: 10px; margin: 44px auto 0; padding: 14px 10px;
  max-width: 460px; background: var(--card); border: 3px solid var(--border-strong); border-radius: 999px;
  box-shadow: var(--shadow-hover);
}
.map-quicknav a {
  display: flex; flex-direction: column; align-items: center; gap: 4px; flex: 1;
  color: var(--text-muted); font-weight: 800; font-size: .68rem; text-transform: uppercase; letter-spacing: .03em;
}
.map-quicknav a span { font-size: 1.3rem; }
.map-quicknav a.active, .map-quicknav a:hover { color: var(--primary); }

@media (max-width: 700px) {
  .unit-map::before { left: 30px; }
  .map-stop, .map-stop-right { flex-direction: row; }
  .map-stop-right .map-stop-card { text-align: left; }
  .map-stop-node { width: 52px; height: 52px; font-size: 1.4rem; }
}

/* ======================================================================
   CLASS SELECTION MAP — "Choose Your World" (pastel children's game map)
   Scoped entirely to .class-map-* / .class-node — doesn't touch any other
   section's styles, DB, links or logic.
   ====================================================================== */
.class-map-header {
  position: relative; z-index: 1; text-align: left; padding: 0 32px 28px;
}
.class-map-header h1 {
  font-family: var(--font-display); font-size: 1.7rem; margin: 0; letter-spacing: .02em;
  color: #fff; text-shadow: 0 2px 0 rgba(0,0,0,.2);
}

.class-map-wrap {
  margin: 0;
}

.class-map {
  position: relative;
  aspect-ratio: 1000 / 420;
}

.map-deco {
  position: absolute;
  font-size: 2.6rem;
  opacity: .55;
  filter: drop-shadow(0 3px 3px rgba(0,0,0,.15));
  pointer-events: none;
  user-select: none;
  z-index: 0;
}
.map-deco-cloud1 { top: 5%; left: 10%; font-size: 3.3rem; opacity: .85; }
.map-deco-cloud2 { top: 8%; left: 68%; font-size: 2.6rem; opacity: .75; }
.map-deco-cloud3 { top: 3%; left: 42%; font-size: 2rem; opacity: .6; }
.map-deco-tree1 { bottom: 5%; left: 3%; font-size: 3.6rem; }
.map-deco-tree2 { top: 40%; left: 47%; font-size: 2.7rem; opacity: .55; }
.map-deco-bush1 { bottom: 8%; left: 32%; font-size: 2.3rem; opacity: .65; }
.map-deco-bush2 { top: 58%; left: 90%; font-size: 2.2rem; opacity: .5; }
.map-deco-star1 { top: 18%; left: 57%; font-size: 1.7rem; opacity: .7; }
.map-deco-star2 { bottom: 14%; left: 77%; font-size: 1.6rem; opacity: .6; }

.class-map-path { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; }
.class-map-path-mobile { display: none; }

.class-node-layer { position: relative; z-index: 2; height: 100%; }

.class-node {
  position: absolute;
  left: calc(var(--nx) * 1%);
  top: calc(var(--ny) * 1%);
  transform: translate(-50%, -50%);
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  width: 118px; text-align: center; text-decoration: none;
  transition: transform .18s ease, left .2s ease, top .2s ease;
  z-index: 2;
}
.class-node:hover { transform: translate(-50%, -50%) scale(1.08) translateY(-4px); z-index: 3; }
.class-node.is-available:hover { animation: node-float 1.1s ease-in-out infinite; }
@keyframes node-float {
  0%, 100% { transform: translate(-50%, -50%) scale(1.08) translateY(-4px); }
  50% { transform: translate(-50%, -50%) scale(1.08) translateY(-9px); }
}

.class-node-badge {
  position: relative;
  width: 88px; height: 88px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-size: 2.7rem;
  border: 5px solid #fff;
  box-shadow: 0 8px 0 rgba(0,0,0,.15), 0 10px 16px rgba(0,0,0,.28);
}
.class-node.node-color-0 .class-node-badge { background: linear-gradient(160deg, #FDE047, #F59E0B); }
.class-node.node-color-1 .class-node-badge { background: linear-gradient(160deg, #60A5FA, #2563EB); }
.class-node.node-color-2 .class-node-badge { background: linear-gradient(160deg, #F472B6, #DB2777); }
.class-node.node-color-3 .class-node-badge { background: linear-gradient(160deg, #34D399, #059669); }

.class-node.is-locked .class-node-badge { filter: grayscale(.75) brightness(.8); box-shadow: 0 6px 0 rgba(0,0,0,.15), 0 8px 12px rgba(0,0,0,.22); }
.class-node.is-locked { opacity: .82; }
.class-node.is-locked:hover { transform: translate(-50%, -50%); }

.class-node-lock {
  position: absolute; bottom: -4px; right: -8px;
  width: 32px; height: 32px; border-radius: 50%;
  background: #475569; border: 3px solid #fff;
  display: flex; align-items: center; justify-content: center; font-size: 1.05rem;
}

.class-node-title { font-family: var(--font-display); font-weight: 800; color: #fff; text-shadow: 0 2px 0 rgba(0,0,0,.25); font-size: .92rem; margin-top: 9px; white-space: nowrap; }
.class-node-sub {
  color: rgba(255,255,255,.92); font-size: .64rem; font-weight: 700; text-shadow: 0 1px 0 rgba(0,0,0,.2);
  max-width: 118px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.class-node-stars { font-size: .98rem; letter-spacing: 2px; }
.class-node-stars .star-off { opacity: .35; filter: grayscale(1); }

.class-node.is-available::after {
  content: "✨"; position: absolute; top: -10px; right: 0; font-size: 1.3rem; opacity: 0;
  transition: opacity .18s ease, transform .18s ease;
}
.class-node.is-available:hover::after { opacity: 1; transform: translateY(-5px) rotate(15deg); }

@media (max-width: 860px) {
  .map-deco { display: none; }
  .class-map { aspect-ratio: 400 / 1400; }
  .class-map-path-desktop { display: none; }
  .class-map-path-mobile { display: block; }

  .class-node { left: calc(var(--nx-m) * 1%); top: calc(var(--ny-m) * 1%); width: 96px; }
  .class-node:hover { transform: translate(-50%, -50%) scale(1.06); }
  .class-node.is-available:hover {
    animation: node-float-mobile 1.1s ease-in-out infinite;
  }
  @keyframes node-float-mobile {
    0%, 100% { transform: translate(-50%, -50%) scale(1.06); }
    50% { transform: translate(-50%, -50%) scale(1.06) translateY(-6px); }
  }
  .class-node-badge { width: 70px; height: 70px; font-size: 2rem; border-width: 4px; }
  .class-node-title { font-size: .8rem; margin-top: 4px; }
  .class-node-sub { font-size: .58rem; max-width: 96px; }
  .class-node-stars { font-size: .85rem; }
  .class-node-lock { width: 26px; height: 26px; font-size: .85rem; }
}

/* ======================================================================
   Sınıflar (classes.php) — continuously sliding class carousel, same
   full-bleed "Neden EngliPlay" background treatment as the homepage.
   ====================================================================== */
.class-carousel {
  position: relative;
  display: flex; align-items: center; gap: 10px;
  width: 100vw;
  max-width: none;
  margin: 28px calc(50% - 50vw) 0;
  padding: 40px 60px;
  background: transparent;
}
.class-track {
  display: flex; gap: 18px; flex: 1; min-width: 0;
  overflow-x: auto; scroll-behavior: smooth; scrollbar-width: none;
}
.class-track::-webkit-scrollbar { display: none; }
.class-slide {
  position: relative; flex: 0 0 220px; width: 220px; height: 220px;
  border-radius: 16px; overflow: hidden; text-decoration: none; flex-shrink: 0;
  border: 3px solid rgba(255,255,255,.55);
  box-shadow: 0 10px 22px rgba(0,0,0,.35);
  transition: transform .18s ease, box-shadow .18s ease;
}
.class-slide:hover, .class-slide:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 16px 28px rgba(0,0,0,.45);
}
.class-slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.class-slide.img-missing { background: transparent; }
.class-slide.img-missing img { display: none; }
.class-slide-overlay {
  position: absolute; inset: auto 0 0 0;
  display: flex; align-items: flex-end; justify-content: center;
  padding: 16px 10px 14px;
  background: linear-gradient(0deg, rgba(5,10,30,.92) 10%, rgba(5,10,30,0) 100%);
  transform: translateY(100%);
  transition: transform .3s ease;
  pointer-events: none;
}
.class-slide:hover .class-slide-overlay,
.class-slide:focus-visible .class-slide-overlay { transform: translateY(0); }
.class-slide-cta {
  color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 1rem;
  text-shadow: 0 2px 4px rgba(0,0,0,.5);
}
.carousel-arrow {
  position: relative; z-index: 2; flex: 0 0 42px; width: 42px; height: 42px; border-radius: 50%;
  border: none; background: rgba(255,255,255,.92); color: var(--primary-dark);
  font-size: 1.5rem; line-height: 1; display: flex; align-items: center; justify-content: center;
  cursor: pointer; box-shadow: 0 4px 10px rgba(0,0,0,.3);
  transition: transform .15s ease, background .15s ease;
}
.carousel-arrow:hover { background: #fff; transform: scale(1.08); }

@media (max-width: 1024px) {
  .class-carousel { padding: 32px 46px; }
  .class-slide { flex-basis: 190px; width: 190px; height: 190px; }
}
@media (max-width: 780px) {
  .class-carousel { padding: 24px 14px; gap: 8px; }
  .class-slide { flex-basis: 150px; width: 150px; height: 150px; }
  .carousel-arrow { flex-basis: 34px; width: 34px; height: 34px; font-size: 1.2rem; }
  .class-slide-cta { font-size: .82rem; }
}

/* Oklar sadece kaydırılacak içerik varsa görünür; [hidden] class
   selector'lerden daha spesifik olmalı ki "display:flex" onu ezmesin. */
.carousel-arrow[hidden] { display: none; }

/* ======================================================================
   Anasayfa: "Yeni ve Popüler Oyunlar" — CrazyGames tarzı yatay oyun
   carousel'i. Video yok; kart üzerine gelince sadece görsel zoom + gölge.
   Dokunmatikte native overflow-x kaydırması (swipe) çalışır.
   ====================================================================== */
.game-carousel-section {
  position: relative;
  width: 100vw; max-width: none;
  margin: 36px calc(50% - 50vw) 0;
  padding: 4px 0 0;
  background: transparent;
}
.game-carousel-section .section-heading-center { color: #fff; margin: 0 0 18px; text-shadow: 0 2px 6px rgba(0,0,0,.35); }
.game-carousel {
  position: relative;
  display: flex; align-items: center; gap: 10px;
  padding: 0 60px;
}
.game-carousel-track {
  display: flex; gap: 18px; flex: 1; min-width: 0;
  overflow-x: auto; scroll-snap-type: x proximity; scroll-behavior: smooth; scrollbar-width: none;
}
.game-carousel-track::-webkit-scrollbar { display: none; }
.game-carousel-card {
  position: relative;
  flex: 0 0 260px; width: 260px; height: 190px; flex-shrink: 0; scroll-snap-align: start;
  display: block; text-decoration: none; color: var(--text);
  border-radius: var(--radius); overflow: hidden;
  border: 3px solid var(--border-strong); box-shadow: 0 10px 22px rgba(0,0,0,.3);
  transition: transform .18s ease, box-shadow .18s ease;
}
.game-carousel-card:hover, .game-carousel-card:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 16px 28px rgba(0,0,0,.4);
}
.game-carousel-thumb {
  display: block; width: 100%; height: 100%; object-fit: cover;
  transition: transform .3s ease;
}
.game-carousel-card:hover .game-carousel-thumb,
.game-carousel-card:focus-visible .game-carousel-thumb { transform: scale(1.06); }
/* Başlık/açıklama sadece hover'da görselin üzerinde belirir (CrazyGames
   tarzı); SEO için metin DOM'da hep var, sadece varsayılan olarak gizli. */
.game-carousel-overlay {
  position: absolute; inset: auto 0 0 0;
  display: flex; flex-direction: column; gap: 4px;
  padding: 16px 14px 14px;
  background: linear-gradient(0deg, rgba(5,10,30,.94) 20%, rgba(5,10,30,0) 100%);
  transform: translateY(100%);
  transition: transform .3s ease;
  pointer-events: none;
}
.game-carousel-card:hover .game-carousel-overlay,
.game-carousel-card:focus-visible .game-carousel-overlay { transform: translateY(0); }
.game-carousel-title {
  display: block; font-size: 1rem; line-height: 1.3; margin: 0;
  color: #fff; text-shadow: 0 2px 4px rgba(0,0,0,.5);
}
.game-carousel-desc {
  display: block; font-size: .82rem; line-height: 1.35;
  color: rgba(255,255,255,.85);
}

@media (max-width: 1024px) {
  .game-carousel { padding: 0 46px; }
  .game-carousel-card { flex-basis: 220px; width: 220px; height: 162px; }
}
@media (max-width: 780px) {
  .game-carousel { padding: 0 14px; gap: 8px; }
  .game-carousel-card { flex-basis: 190px; width: 190px; height: 140px; }
  .game-carousel-title { font-size: .88rem; }
  .game-carousel-desc { display: none; }
}