/* =========================================================
   Felolvasás, szülői oldal, új játékok – stílusok
   ========================================================= */
.theme-szoepito { --c: #ff7a59; --cd: #d4532f; --cl: #ffece5; }
.theme-ora      { --c: #3f8efc; --cd: #2563c9; --cl: #e6f0ff; }
.theme-penz     { --c: #d99a00; --cd: #a87600; --cl: #fff3d1; }
.theme-villam   { --c: #f04e8c; --cd: #c22d68; --cl: #fde6ef; }

/* ---------- Felolvasó gombok ---------- */
.title-say, .slide-say {
  border: 0; cursor: pointer; background: var(--cl); color: var(--cd);
  border-radius: 50%; width: 40px; height: 40px; font-size: 1.1rem; vertical-align: middle;
  box-shadow: 0 3px 0 var(--line);
}
.title-say:active, .slide-say:active { transform: translateY(2px); box-shadow: none; }
.lesson-card { position: relative; }
.slide-say { position: absolute; top: 14px; right: 14px; }

/* ---------- Szülői oldal ---------- */
.parent-gate { max-width: 520px; margin: 30px auto 0; }
.gate-card { text-align: center; }
.gate-card h1 { margin: 6px 0; }
.gate-card p { color: var(--muted); }
.gate-form { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.gate-q { font-size: 1.6rem; font-weight: 900; }
.gate-input { width: 110px; margin: 0; text-align: center; }
.gate-err { color: var(--bad); font-weight: 800; min-height: 1.4em; }

.parents { max-width: 900px; margin: 0 auto; }
.parents-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.parents-head .btn { padding: 10px 16px; font-size: 1rem; }
.child-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 6px 0 16px; }
.child-tab {
  border: 3px solid var(--line); background: var(--card); border-radius: 999px; padding: 6px 16px;
  font-weight: 900; cursor: pointer;
}
.child-tab.on { border-color: var(--ink); background: var(--ink); color: #fff; }
.p-card { margin-top: 18px; border-top-color: var(--ink); }
.p-card h2 { font-size: 1.35rem; margin-bottom: 10px; }
.p-sub { margin: 14px 0 6px; font-size: 1.05rem; }
.p-note { color: var(--muted); margin: 0 0 8px; }
.p-tip { background: #fff6d6; border-radius: 14px; padding: 10px 14px; font-weight: 800; }
.p-tip a { color: var(--ink); text-decoration: underline; }
.p-progress { display: grid; gap: 6px; }
.p-row {
  display: grid; grid-template-columns: minmax(150px, 1.3fr) 2fr minmax(110px, auto); align-items: center; gap: 12px;
  padding: 6px 10px; border-radius: 12px;
}
.p-row:hover { background: #f6f3fa; }
.p-row .bar { background: #eee9f5; height: 12px; }
.p-name { font-weight: 800; }
.p-val { color: var(--muted); font-weight: 800; text-align: right; white-space: nowrap; }
.acc-good > span { background: var(--good) !important; }
.acc-mid > span { background: var(--gold) !important; }
.acc-low > span { background: var(--bad) !important; }
.cal-row { display: grid; grid-template-columns: repeat(14, 1fr); gap: 6px; }
.cal-day {
  display: flex; flex-direction: column; align-items: center; padding: 4px 0; border-radius: 10px;
  background: #f1eef6; color: #a59fb3; font-size: .85rem;
}
.cal-day small { font-size: .7rem; }
.cal-day.on { background: var(--good); color: #fff; }
.cal-day.today { outline: 3px solid var(--gold); }
.missed-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.missed-list li {
  display: grid; grid-template-columns: minmax(140px, 1fr) 2fr auto auto; gap: 10px; align-items: center;
  padding: 8px 12px; background: #fbf9fd; border-radius: 12px;
}
.m-where { color: var(--muted); font-size: .9rem; font-weight: 800; }
.m-q { font-weight: 800; }
.m-a { color: var(--good-d); font-weight: 900; }
.p-switch { display: flex; gap: 14px; align-items: flex-start; padding: 10px 0; cursor: pointer; border-bottom: 2px dashed var(--line); }
.p-switch input { width: 26px; height: 26px; accent-color: var(--good); flex-shrink: 0; margin-top: 2px; }
.p-switch span { display: grid; }
.p-switch small { color: var(--muted); }
.p-field { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 14px 0; }
.p-select { font: inherit; font-weight: 800; padding: 8px 12px; border-radius: 12px; border: 3px solid var(--line); }
.small-btn { padding: 8px 14px !important; font-size: .95rem !important; }
.p-warn { background: #ffe3ea; border-radius: 12px; padding: 10px 14px; font-weight: 800; }
.p-danger { margin-top: 16px; text-align: right; }
.p-danger .btn { color: var(--bad); }

/* ---------- Szóépítő ---------- */
.slots, .tiles { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.slot {
  min-width: 56px; height: 64px; padding: 0 8px; border-radius: 14px; display: grid; place-items: center;
  border: 3px dashed var(--line); font-size: 2rem; font-weight: 900; color: var(--cd);
}
.slot.next { border-color: var(--c); animation: pulse 1.4s ease-in-out infinite; }
.slot.filled { border-style: solid; border-color: var(--cl); background: var(--cl); animation: pop .3s; }
.slots.complete .slot { background: var(--good); border-color: var(--good-d); color: #fff; }
.tiles { margin-top: 22px; }
.b-tile {
  min-width: 62px; height: 66px; padding: 0 12px; font: inherit; font-size: 2rem; font-weight: 900; cursor: pointer;
  background: var(--card); border: 3px solid var(--line); border-radius: 16px; box-shadow: 0 5px 0 var(--line);
}
.b-tile:hover:not(:disabled) { border-color: var(--c); }
.b-tile.used { visibility: hidden; }
.shake { animation: shake .4s; }

/* ---------- Óra ---------- */
.clock { width: min(260px, 70vw); height: auto; }
.clock-face { fill: #fff; stroke: var(--c); stroke-width: 6; }
.tick { stroke: #b9b3c6; stroke-width: 1.5; }
.tick.big { stroke: var(--ink); stroke-width: 3; }
.clock-num { font-size: 18px; font-weight: 900; text-anchor: middle; fill: var(--ink); font-family: inherit; }
.hand { stroke-linecap: round; }
.hand.hour { stroke: var(--ink); stroke-width: 8; }
.hand.minute { stroke: var(--c); stroke-width: 5; }
.clock-pin { fill: var(--gold); stroke: var(--ink); stroke-width: 2; }
.digital {
  display: inline-block; font-size: clamp(3rem, 12vw, 4.5rem); font-weight: 900; letter-spacing: 4px;
  background: #22243a; color: #7cf29c; padding: 8px 28px; border-radius: 18px; font-variant-numeric: tabular-nums;
}

/* ---------- Pénz ---------- */
.money-row { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px; }
.coin {
  width: 66px; height: 66px; border-radius: 50%; display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
  line-height: 1; font-weight: 900; color: #5b4300; box-shadow: inset 0 0 0 4px rgba(0,0,0,.12), 0 4px 0 rgba(0,0,0,.15);
  background: radial-gradient(circle at 35% 30%, #fff3b0, #e8bf3a 60%, #c99a12);
}
.coin b { font-size: 1.25rem; }
.coin small { font-size: .65rem; }
.coin.c10, .coin.c50 { background: radial-gradient(circle at 35% 30%, #ffffff, #c9ced6 60%, #9aa1ab); color: #3b4048; }
.coin.c5 { width: 54px; height: 54px; }
.coin.c10 { width: 58px; height: 58px; }
.coin.c100, .coin.c200 {
  width: 74px; height: 74px; color: #3b4048;
  background: radial-gradient(circle, #dfe3e8 0 52%, #d9ad2f 53% 100%);
}
.bill {
  width: 112px; height: 60px; border-radius: 8px; display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
  font-weight: 900; color: #fff; box-shadow: 0 4px 0 rgba(0,0,0,.18); line-height: 1;
  background: repeating-linear-gradient(45deg, #b0563b, #b0563b 6px, #c0654a 6px, #c0654a 12px);
  border: 3px solid rgba(255,255,255,.6);
}
.bill b { font-size: 1.4rem; }
.price-tag { display: inline-flex; align-items: center; gap: 12px; }
.tag {
  display: flex; flex-direction: column; background: #fff6d6; border: 3px dashed var(--gold); border-radius: 14px;
  padding: 6px 14px; font-weight: 800; font-size: 1.1rem;
}
.tag b { font-size: 1.6rem; color: var(--cd); }
.counter {
  display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap;
  margin: 12px auto; padding: 10px; min-height: 90px; border-radius: 18px; background: var(--cl); max-width: 560px;
}
.counter > span, .counter > b { font-weight: 900; font-size: 1.2rem; }
.purse { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin: 8px 0 16px; }
.money-btn { border: 0; background: none; padding: 2px; cursor: pointer; border-radius: 50%; transition: transform .1s; }
.money-btn:hover { transform: translateY(-3px); }
.money-btn:active { transform: scale(.92); }
.money-btn.small .coin { transform: scale(.8); margin: -6px; }
.change-q { display: flex; align-items: center; justify-content: center; gap: 16px; flex-wrap: wrap; }
.change-q > div:first-child { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.change-q small { color: var(--muted); font-weight: 800; }
.change-q > b { font-size: 2rem; color: var(--muted); }
.change-q .big-emoji { font-size: 4rem; }

/* ---------- Villámszámolás ---------- */
.countdown { font-size: 8rem; font-weight: 900; color: var(--c); animation: pop .6s; }
.timebar { flex: 1; height: 18px; background: #eee9f5; border-radius: 999px; overflow: hidden; }
.timebar span { display: block; height: 100%; width: 100%; background: linear-gradient(90deg, var(--bad), var(--gold), var(--good)); transition: width .2s linear; }

@media (max-width: 560px) {
  .p-row { grid-template-columns: 1fr; gap: 4px; }
  .p-val { text-align: left; }
  .missed-list li { grid-template-columns: 1fr; gap: 2px; }
  .cal-row { grid-template-columns: repeat(7, 1fr); }
  .slot { min-width: 44px; height: 54px; font-size: 1.6rem; }
  .b-tile { min-width: 50px; height: 56px; font-size: 1.6rem; }
  .coin { width: 56px; height: 56px; }
  .coin.c100, .coin.c200 { width: 62px; height: 62px; }
}

/* ---------- Saját szólisták (szülői oldal) ---------- */
.wl-list { display: grid; gap: 6px; margin-bottom: 12px; }
.wl-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 8px 12px; background: #fbf9fd; border-radius: 12px; }
.wl-name { font-weight: 900; }
.wl-words { flex: 1; color: var(--muted); min-width: 160px; }
.wl-form { display: grid; gap: 8px; }
.wl-input, .wl-text { margin: 0; font-size: 1.05rem; font-weight: 700; }
.wl-text { resize: vertical; font-family: inherit; }
.wl-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.wl-actions .btn { padding: 10px 16px; font-size: 1rem; }
[data-theme="dark"] .wl-row { background: #2f2c47; }
