@font-face{font-family:Arakom;src:url("Arakom-Regular.ttf") format("truetype");font-weight:400}
@font-face{font-family:Arakom;src:url("Arakom-Bold.ttf") format("truetype");font-weight:700}

:root{
  --page:#f6f7fb;
  --surface:#ffffff;
  --surface-2:#eef7f5;
  --ink:#17212b;
  --muted:#5d6675;
  --line:#d9dee8;
  --teal:#0f766e;
  --blue:#2563eb;
  --rose:#e11d48;
  --amber:#d97706;
  --green:#15803d;
  --shadow:0 18px 45px rgba(28,38,57,.12);
  --soft-shadow:0 8px 24px rgba(28,38,57,.1);
}

html.light{
  --page:var(--bg);
  --surface:var(--card);
  --ink:var(--text);
  --muted:var(--muted);
  --line:var(--border);
}

*{box-sizing:border-box}
body{
  margin:0;
  min-height:100vh;
  color:var(--ink);
  background:
    linear-gradient(120deg,rgba(15,118,110,.09),transparent 34%),
    linear-gradient(240deg,rgba(225,29,72,.08),transparent 38%),
    var(--page);
  font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  letter-spacing:0;
}

button,a{font:inherit}
button{letter-spacing:0}
.app-shell{width:min(1480px,100%);margin:0 auto;padding:18px}
.topbar{
  display:grid;
  grid-template-columns:128px 1fr auto;
  align-items:center;
  gap:18px;
  padding:18px 20px;
  background:var(--surface);
  border:1px solid var(--line);
  box-shadow:var(--soft-shadow);
  border-radius:8px;
}
.back-link{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:40px;
  color:var(--teal);
  text-decoration:none;
  border:1px solid rgba(15,118,110,.25);
  border-radius:8px;
  background:rgba(15,118,110,.08);
  font-weight:700;
  padding:0 14px;
}
.title-block{text-align:center}
.eyebrow{margin:0 0 4px;color:var(--teal);font-size:13px;font-weight:800}
.title-block h1{
  margin:0;
  direction:rtl;
  font-family:Arakom,serif;
  font-size:40px;
  line-height:1.15;
}
.title-block p:last-child{margin:4px 0 0;color:var(--muted);font-weight:700}
.summary-strip{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.summary-strip span{
  min-width:86px;
  padding:9px 10px;
  border-radius:8px;
  background:#f3f6fb;
  border:1px solid var(--line);
  text-align:center;
  color:var(--muted);
  font-size:13px;
}
.summary-strip strong{display:block;color:var(--ink);font-size:18px}

.workspace{
  display:grid;
  grid-template-columns:340px minmax(0,1fr);
  gap:18px;
  margin-top:18px;
  align-items:start;
}
.workspace.game-only{grid-template-columns:1fr}
.play-full{min-height:760px}
.hub-workspace{
  margin-top:18px;
  display:grid;
  gap:18px;
}
.hub-intro{
  padding:22px;
  border:1px solid var(--line);
  border-radius:8px;
  background:linear-gradient(90deg,#ffffff,#edf8f6);
  box-shadow:var(--soft-shadow);
}
.hub-intro h2{margin:0;font-size:28px;line-height:1.2}
.hub-intro p:last-child{margin:8px 0 0;color:var(--muted);font-size:15px;line-height:1.45}
.hub-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:12px;
}
.hub-card{
  position:relative;
  min-height:210px;
  display:grid;
  align-content:start;
  gap:8px;
  padding:16px;
  color:var(--ink);
  text-decoration:none;
  background:#fff;
  border:1px solid var(--line);
  border-radius:8px;
  box-shadow:var(--soft-shadow);
  transition:transform .16s,border-color .16s,background .16s;
}
.hub-card:hover{transform:translateY(-3px);border-color:var(--teal);background:#f7fffd}
.hub-card img{width:72px;height:72px;object-fit:contain;border-radius:8px}
.hub-number{
  position:absolute;
  top:14px;
  right:14px;
  color:var(--teal);
  font-weight:900;
  background:#e7f6f2;
  border:1px solid rgba(15,118,110,.22);
  border-radius:8px;
  padding:5px 8px;
}
.hub-card strong{font-size:17px;line-height:1.25}
.hub-ar{direction:rtl;font-family:Arakom,serif;font-size:22px;color:var(--teal)}
.hub-card small{color:var(--muted);font-size:13px;font-weight:800}
.game-menu,.play-area{
  background:var(--surface);
  border:1px solid var(--line);
  border-radius:8px;
  box-shadow:var(--shadow);
}
.game-menu{position:sticky;top:18px;max-height:calc(100vh - 36px);overflow:auto}
.menu-head{
  display:flex;
  align-items:end;
  justify-content:space-between;
  gap:12px;
  padding:18px 18px 12px;
  border-bottom:1px solid var(--line);
}
.menu-head h2{margin:0;font-size:20px}
.menu-head p{margin:0;color:var(--muted);font-size:13px;font-weight:700}
.game-list{display:grid;gap:8px;padding:12px}
.game-card{
  display:grid;
  grid-template-columns:58px 1fr;
  gap:12px;
  width:100%;
  min-height:78px;
  padding:10px;
  border:1px solid var(--line);
  border-radius:8px;
  background:#fff;
  cursor:pointer;
  text-align:left;
  color:var(--ink);
  transition:background .16s,border-color .16s,transform .16s;
}
.game-card:hover{background:#f8fbff;border-color:rgba(37,99,235,.32);transform:translateY(-1px)}
.game-card.active{border-color:var(--teal);background:var(--surface-2)}
.game-card img{width:58px;height:58px;object-fit:contain;border-radius:8px}
.game-card strong{display:block;font-size:14px;line-height:1.25}
.game-card small{display:block;margin-top:5px;color:var(--muted);font-size:12px}
.game-card .ar-title{direction:rtl;font-family:Arakom,serif;font-size:17px;color:var(--teal);margin-top:2px}

.play-area{min-height:720px;overflow:hidden}
.play-head{
  display:flex;
  justify-content:space-between;
  gap:16px;
  align-items:flex-start;
  padding:22px;
  background:linear-gradient(90deg,#ffffff,#edf8f6);
  border-bottom:1px solid var(--line);
}
.game-kicker{margin:0 0 6px;color:var(--teal);font-size:13px;font-weight:800}
.play-head h2{margin:0;font-size:clamp(26px,1.2vw + 14px,40px);line-height:1.2}
.game-instruction{margin:8px 0 0;color:var(--muted);font-size:clamp(14px,.7vw + 6px,22px);line-height:1.45}
.play-actions{display:flex;align-items:center;gap:10px;flex-shrink:0}
.score-pill{
  min-width:112px;
  padding:9px 12px;
  border-radius:8px;
  color:var(--teal);
  background:#e7f6f2;
  border:1px solid rgba(15,118,110,.25);
  text-align:center;
  font-weight:800;
  font-size:14px;
}
.icon-btn{
  width:40px;
  height:40px;
  border-radius:8px;
  border:1px solid var(--line);
  background:#fff;
  cursor:pointer;
  color:var(--ink);
  font-size:22px;
}
.icon-btn:hover{border-color:var(--teal);color:var(--teal)}
.game-area{padding:22px}

.grid{display:grid;gap:12px}
.grid.two{grid-template-columns:repeat(2,minmax(0,1fr))}
.grid.three{grid-template-columns:repeat(3,minmax(0,1fr))}
.grid.four{grid-template-columns:repeat(4,minmax(0,1fr))}
.item-card,.question-card,.choice,.token,.word-chip,.memory-card,.line-button,.category-row,.shelf-item{font-size:clamp(20px,1.2vw + 12px,40px);
  border:1px solid var(--line);
  border-radius:8px;
  background:#fff;
}
.item-card,.question-card,.category-row{padding:16px}
.item-card{box-shadow:var(--soft-shadow)}
.ar{
  direction:rtl;
  font-family:Arakom,serif;
  font-size:clamp(24px,1.5vw + 16px,48px);
  line-height:1.45;
}
.ar.small-ar{font-size:clamp(20px,1vw + 10px,32px)}
.muted{color:var(--muted)}
.feedback{margin-top:10px;font-weight:800;min-height:22px;font-size:clamp(18px,1vw + 10px,30px)}
.feedback.ok{color:var(--green)}
.feedback.no{color:var(--rose)}

.flash-wrap{display:grid;grid-template-columns:minmax(0,1fr) 230px;gap:16px;align-items:start}
.flash-card{
  min-height:340px;
  width:100%;
  border:1px solid rgba(15,118,110,.28);
  border-radius:8px;
  background:linear-gradient(135deg,#ffffff,#ecfbf8);
  box-shadow:var(--shadow);
  cursor:pointer;
  padding:28px;
  display:grid;
  place-items:center;
  text-align:center;
}
.flash-emoji{font-size:58px;line-height:1;margin-bottom:10px}
.flash-tr{font-size:26px;font-weight:900;margin:8px 0}
.flash-example{direction:rtl;font-family:Arakom,serif;font-size:23px;color:var(--teal);line-height:1.4}
.flash-side{display:grid;gap:10px}
.nav-row{display:flex;gap:8px;flex-wrap:wrap;margin-top:18px;justify-content:center}
.primary-btn,.ghost-btn{
  min-height:42px;
  padding:0 14px;
  border-radius:8px;
  border:1px solid var(--line);
  cursor:pointer;
  font-weight:800;
}
.primary-btn{background:var(--teal);border-color:var(--teal);color:#fff}
.ghost-btn{background:#fff;color:var(--ink)}
.ghost-btn:hover{border-color:var(--teal);color:var(--teal)}

.matching-board{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.match-col{display:grid;gap:10px}
.choice,.token,.word-chip,.line-button,.shelf-item{
  min-height:46px;
  padding:10px 12px;
  cursor:pointer;
  color:var(--ink);
}
.choice:hover,.token:hover,.word-chip:hover,.line-button:hover,.shelf-item:hover{border-color:var(--blue);background:#f8fbff}
.choice.correct,.token.correct,.line-button.correct,.shelf-item.correct,.category-row.correct,.memory-card.correct,.word-chip.correct{border-color:rgba(21,128,61,.5);background:#ecfdf3;color:#14532d}
.choice.wrong,.token.wrong,.line-button.wrong,.shelf-item.wrong,.category-row.wrong,.memory-card.wrong{border-color:rgba(225,29,72,.45);background:#fff1f2;color:#9f1239}
.choice[disabled],.token[disabled],.line-button[disabled],.shelf-item[disabled]{cursor:default;opacity:.82}

.category-row{display:grid;grid-template-columns:1fr auto;gap:14px;align-items:center}
.category-actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.target-list,.shelf-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
.target-chip{
  min-height:58px;
  padding:10px;
  border-radius:8px;
  background:#f3f6fb;
  border:1px dashed #b8c0ce;
  text-align:center;
}
.target-chip.done{background:#ecfdf3;border-style:solid;border-color:rgba(21,128,61,.45)}
.shelf-item{text-align:center;min-height:92px}
.shelf-item .emoji{font-size:clamp(28px,2.4vmin,40px);display:block}

.question-list{display:grid;gap:14px}
.question-top{display:flex;justify-content:space-between;gap:14px;align-items:flex-start;margin-bottom:12px}
.question-number{color:var(--muted);font-size:13px;font-weight:800}
.choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.choice{text-align:center;font-weight:800}
.choice .ar{font-size:clamp(22px,1.6vw + 14px,48px)}

/* tahta: sayfalı (tek soru) düzen — büyük punto, scroll yok */
.paged-wrap{display:grid;gap:16px;max-width:1180px;margin:0 auto;width:100%}
.paged-progress{text-align:center;font-weight:900;color:var(--muted);font-size:clamp(15px,.6vw + 8px,22px);letter-spacing:.05em}
.paged-question{padding:24px}
.paged-question .question-top{margin-bottom:18px}
.paged-next{display:block;margin:16px auto 0;min-height:56px;padding:0 32px;font-size:clamp(18px,.8vw + 10px,26px)}
.done-card{place-items:center;text-align:center;gap:16px;padding:52px 24px}
.done-emoji{font-size:clamp(56px,7vw,104px);line-height:1}
.done-text{font-weight:900;font-size:clamp(28px,2vw + 14px,52px);direction:rtl}

.sentence-output,.dialogue-output{font-size:clamp(20px,1.2vw + 12px,40px);
  min-height:58px;
  padding:12px;
  border:1px dashed #aab4c4;
  border-radius:8px;
  background:#f8fafc;
  margin:12px 0;
}
.token-bank{display:flex;gap:8px;flex-wrap:wrap}
.token{font-weight:800}
.line-stack,.chosen-lines{display:grid;gap:8px}
.line-button{text-align:right}
.line-button .speaker{display:block;color:var(--teal);font-size:13px;font-weight:800;text-align:left}

.wordsearch-layout{display:grid;grid-template-columns:auto 1fr;gap:18px;align-items:start}
.word-grid{
  border-collapse:separate;
  border-spacing:4px;
  direction:rtl;
}
.word-grid td{
  width:clamp(36px,5.2vmin,58px);
  height:clamp(36px,5.2vmin,58px);
  text-align:center;
  vertical-align:middle;
  border:1px solid var(--line);
  border-radius:7px;
  background:#fff;
  font-family:Arakom,serif;
  font-size:clamp(20px,2.8vmin,32px);
  font-weight:700;
}
.word-grid td.found{background:#fde68a;border-color:#d97706;color:#78350f}
.word-list{display:flex;gap:8px;flex-wrap:wrap}
.word-chip{font-family:Arakom,serif;font-size:clamp(20px,1.2vw + 10px,36px);background:#fff}

.memory-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}
.memory-card{
  min-height:96px;
  cursor:pointer;
  background:#0f766e;
  color:#fff;
  font-weight:900;
  display:grid;
  place-items:center;
  padding:10px;
  text-align:center;
  font-size:clamp(20px,1.2vw + 8px,34px);
}
.memory-card.open,.memory-card.correct{background:#fff;color:var(--ink)}
.role-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.role-card{padding:16px;border:1px solid var(--line);border-radius:8px;background:#fff}
.pattern-list{display:grid;gap:8px;margin-top:12px}
.pattern-list span{padding:9px 10px;border-radius:8px;background:#f3f6fb;direction:rtl;font-family:Arakom,serif;font-size:20px}

@media (orientation:landscape) and (min-width:900px){
  html,body{height:100%;overflow:hidden}
  body{min-height:100dvh}
  .app-shell{width:100%;max-width:none;height:100dvh;padding:10px 14px;display:flex;flex-direction:column;overflow:hidden}
  .topbar{flex:0 0 auto;grid-template-columns:112px minmax(0,1fr) auto;gap:10px;padding:10px 12px}
  .back-link{min-height:34px;padding:0 10px}
  .eyebrow{font-size:11px;margin-bottom:2px}
  .title-block h1{font-size:clamp(24px,2.2vw,34px);line-height:1.05}
  .title-block p:last-child{font-size:12px;margin-top:2px}
  .summary-strip{gap:6px}
  .summary-strip span{min-width:68px;padding:5px 7px;font-size:11px}
  .summary-strip strong{font-size:15px}
  .workspace{margin-top:10px;flex:1 1 auto;min-height:0;align-items:stretch}
  .workspace.game-only{display:grid}
  .play-full,.play-area{min-height:0;height:100%;display:flex;flex-direction:column;overflow:hidden}
  .play-head{padding:12px 14px;flex:0 0 auto;align-items:center}
  .game-instruction{margin-top:4px;line-height:1.25}
  .score-pill{min-width:88px;padding:6px 8px}
  .icon-btn{width:34px;height:34px;font-size:18px}
  .game-area{flex:1 1 auto;min-height:0;overflow:hidden;padding:12px 14px}
  .item-card,.question-card,.category-row{padding:10px}
  .ar{line-height:1.25}
  .feedback{margin-top:6px}
  .choice,.token,.word-chip,.line-button,.shelf-item{min-height:40px;padding:8px 10px}
  .target-list,.shelf-grid{gap:8px}
  .target-chip{min-height:46px;padding:7px}
  .shelf-item{min-height:64px}
  .matching-board{gap:10px}
  .match-col{gap:8px}
  .nav-row{margin-top:10px}
  .paged-wrap{gap:8px}
  .paged-question{padding:14px}
  .paged-next{min-height:42px;margin-top:10px}
  .done-card{padding:24px}
  .sentence-output,.dialogue-output{min-height:46px;margin:8px 0;padding:9px}
}

@media(max-width:1040px){
  .topbar{grid-template-columns:1fr}
  .title-block{text-align:left}
  .summary-strip{justify-content:flex-start}
  .workspace{grid-template-columns:1fr}
  .play-area{order:1}
  .game-menu{order:2}
  .game-menu{position:relative;top:auto;max-height:none}
  .game-list{grid-template-columns:repeat(2,minmax(0,1fr))}
  .hub-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .flash-wrap,.wordsearch-layout{grid-template-columns:1fr}
}

@media(max-width:700px){
  .app-shell{padding:10px}
  .topbar,.play-head{padding:14px}
  .game-area{padding:14px}
  .title-block h1{font-size:32px}
  .play-head{display:grid}
  .play-head h2{font-size:clamp(24px,1vw + 12px,34px)}
  .game-list,.grid.two,.grid.three,.grid.four,.matching-board,.choices,.target-list,.shelf-grid,.role-grid{grid-template-columns:1fr}
  .hub-grid{grid-template-columns:1fr}
  .category-row{grid-template-columns:1fr}
  .category-actions{justify-content:flex-start}
  .flash-card{min-height:280px}
  .memory-grid{grid-template-columns:repeat(2,1fr)}
  .word-grid{width:100%;table-layout:fixed;border-spacing:1px}
  .word-grid td{width:auto;height:24px;font-size:14px}
}

/* ════════════════════════════════════════════════════════════
   PREMIUM STANDARDI — Arakom + mavi + KOCAMAN punto (motorlarla aynı)
   ════════════════════════════════════════════════════════════ */
:root{--teal:#0f6fff;--blue:#2f86ff;--ease2:cubic-bezier(.22,.72,.24,1)}
/* —— büyük içerik (oyun alanı) —— */
.play-area .ar:not(.small-ar),.play-area .choice .ar{font-size:clamp(30px,2.3vw + 16px,62px);line-height:1.25}
.play-area .ar.small-ar{font-size:clamp(24px,1.4vw + 13px,44px)}
.play-area .choice .ar,.play-area .choice .ar.small-ar{font-size:clamp(30px,2.3vw + 16px,62px);line-height:1.22}
.play-area .token{font-size:clamp(26px,1.9vw + 13px,52px)}
.play-area .word-chip{font-size:clamp(24px,1.6vw + 12px,46px)}
.play-area .memory-card{font-size:clamp(26px,1.7vw + 12px,50px)}
.play-area .sentence-output{font-size:clamp(26px,1.8vw + 13px,54px)}
.play-area .shelf-item .emoji{font-size:clamp(34px,3vmin,52px)}
.play-head h2{font-size:clamp(30px,1.6vw + 16px,52px)}
.game-instruction{font-size:clamp(15px,.6vw + 9px,22px)}
.paged-progress{font-size:clamp(16px,.7vw + 10px,24px)}
.word-grid td{font-size:clamp(26px,3.6vmin,46px)}
/* —— premium yüzeyler —— */
.play-area{background:radial-gradient(1100px 560px at 50% -10%,#ffffff,#eef5ff 60%,#e7f0fb);box-shadow:0 2px 8px rgba(20,55,95,.06),0 18px 42px -14px rgba(20,55,95,.2)}
.question-card,.item-card,.role-card,.paged-question{background:linear-gradient(180deg,#ffffff,#fbfdff);border-color:#e9f0fa;border-radius:18px;box-shadow:0 1px 2px rgba(20,55,95,.05),0 8px 22px -8px rgba(20,55,95,.16)}
.choice,.token,.word-chip,.memory-card,.line-button,.shelf-item,.target-chip{background:linear-gradient(180deg,#ffffff,#f8fbff);box-shadow:0 1px 2px rgba(20,55,95,.05),0 6px 16px rgba(20,55,95,.06);transition:transform .14s var(--ease2),border-color .14s,box-shadow .2s,background .2s}
.play-area .choice,.play-area .token,.play-area .word-chip{animation:u2-rise .42s var(--ease2) both}
.choice:hover,.token:hover,.word-chip:hover,.shelf-item:hover{transform:translateY(-3px);border-color:#7fb4ff;box-shadow:0 10px 24px rgba(15,111,255,.16)}
.choice:active,.token:active{transform:scale(.98)}
.choice.correct,.token.correct,.word-chip.correct,.memory-card.correct,.category-row.correct,.shelf-item.correct{background:linear-gradient(180deg,#ecfdf5,#dcfce7)!important;box-shadow:0 0 0 4px rgba(52,211,153,.28),0 12px 28px rgba(16,185,129,.2)!important;animation:u2-correct .55s var(--ease2)}
.choice.wrong,.token.wrong,.line-button.wrong{background:linear-gradient(180deg,#fff1f3,#ffe4e8)!important;animation:u2-shake .42s}
.choices{gap:14px}.choice{padding:14px 18px;min-height:60px}
/* —— butonlar (mavi) —— */
.primary-btn{background:linear-gradient(135deg,#2f86ff,#0f6fff 55%,#0a5be0);border-color:transparent;color:#fff;box-shadow:0 2px 0 rgba(8,70,160,.3),0 9px 22px rgba(15,111,255,.26);transition:transform .13s var(--ease2),box-shadow .18s,filter .18s;min-height:54px;padding:0 26px;font-size:clamp(18px,.8vw + 10px,26px)}
.primary-btn:hover{transform:translateY(-2px);filter:brightness(1.05)}.primary-btn:active{transform:translateY(0) scale(.97)}
.score-pill{background:linear-gradient(180deg,#eaf3ff,#dcecff);color:#0a5be0;border-color:#bcd8ff}
.eyebrow,.game-kicker{color:#0f6fff}
.progress-bar>span,.prog>span{background:linear-gradient(90deg,#0f6fff,#4aa3ff)}
.paged-next{display:block;margin:16px auto 0}
.done-emoji{font-size:clamp(56px,7vw,104px)}.done-text{font-size:clamp(30px,2vw + 14px,52px);font-weight:900}
@keyframes u2-rise{from{opacity:0;transform:translateY(16px)}to{opacity:1;transform:none}}
@keyframes u2-correct{0%{transform:scale(1)}38%{transform:scale(1.05)}100%{transform:scale(1)}}
@keyframes u2-shake{0%,100%{transform:translateX(0)}20%{transform:translateX(-7px)}60%{transform:translateX(7px)}}
@media(prefers-reduced-motion:reduce){.play-area .choice,.play-area .token,.play-area .word-chip,.choice.correct,.choice.wrong{animation:none}}
