/* Bölüm 6 — büyük dil modelleri demoları */

/* ortak: tuval üstü bilgi kutuları */
.llm-ovl {
  position: absolute; pointer-events: none;
  font-family: var(--f-display); color: var(--ink-2);
  z-index: 2;
}
.llm-ovl b { color: var(--ink); font-weight: 600; }
.llm-note {
  position: absolute; left: 16px; bottom: 12px; z-index: 2; pointer-events: none;
  font-family: var(--f-display); font-size: 0.78rem; color: var(--muted);
}

/* ---------- Token ---------- */
.tk-input {
  flex: 1 1 280px; min-width: 0;
  background: var(--panel); color: var(--ink);
  border: 1px solid var(--line); border-radius: 999px;
  padding: 0.5em 1.1em; font-family: var(--f-body); font-size: 1rem;
}
.tk-input:focus { outline: none; border-color: var(--gold); }
.tk-wrap {
  position: absolute; inset: 0; overflow: auto;
  padding: 22px 22px 16px;
  display: flex; flex-direction: column; gap: 18px;
}
.tk-chips { display: flex; flex-wrap: wrap; gap: 10px 4px; align-items: flex-start; }
.tk-chip { display: inline-flex; flex-direction: column; align-items: center; gap: 3px; animation: tkIn 0.25s ease both; }
@keyframes tkIn { from { opacity: 0; transform: translateY(4px); } }
.tk-tok {
  font-family: var(--f-num); font-size: clamp(0.95rem, 1.2vw, 1.15rem);
  padding: 4px 7px; border-radius: 6px; border: 1px solid; white-space: pre; color: var(--ink);
}
.tk-tok .tk-sp { opacity: 0.45; }
.tk-id { font-family: var(--f-num); font-size: 0.7rem; color: var(--muted); }
.tk-chip.unk .tk-tok { border-style: dashed; }
.tk-stats { display: flex; gap: 28px; flex-wrap: wrap; font-family: var(--f-display); color: var(--ink-2); font-size: 0.9rem; }
.tk-stats b { display: block; font-size: 1.9rem; line-height: 1.1; color: var(--ink); font-family: var(--f-display); font-weight: 700; letter-spacing: -0.02em; }
.tk-stats .gold b { color: var(--gold); }
.tk-merges { margin-top: auto; }
.tk-merges h4 { margin: 0 0 8px; font-family: var(--f-display); font-size: 0.85rem; font-weight: 600; color: var(--muted); }
.tk-merges ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 8px; }
.tk-merges li {
  font-family: var(--f-num); font-size: 0.82rem; color: var(--ink-2);
  padding: 3px 9px; border-radius: 999px; background: rgba(255,255,255,0.04); border: 1px solid var(--line);
}
.tk-merges li:first-child { border-color: var(--gold); color: var(--gold); }
.tk-merges li i { font-style: normal; color: var(--muted); margin-right: 6px; }

/* ---------- Tensör ---------- */
.tns-info { left: 20px; top: 18px; max-width: min(420px, 70%); }
.tns-info .nm { font-size: 1.5rem; font-weight: 700; color: var(--ink); letter-spacing: -0.02em; }
.tns-info .sh { font-family: var(--f-num); color: var(--gold); font-size: 1rem; margin: 2px 0 8px; }
.tns-info .cp { font-family: var(--f-body); font-size: 0.95rem; line-height: 1.45; }

/* ---------- Dikkat ---------- */
.att-cap { left: 0; right: 0; top: 20px; text-align: center; font-size: 1.05rem; padding: 0 16px; }
.att-foot { left: 16px; right: 16px; bottom: 12px; font-size: 0.8rem; color: var(--muted); text-align: center; }

/* ---------- Örnekleme ---------- */
.smp-wrap { position: absolute; inset: 0; overflow: auto; padding: 24px 24px 16px; display: flex; flex-direction: column; gap: 22px; }
.smp-text {
  font-family: var(--f-body); font-size: clamp(1.4rem, 2.4vw, 2.1rem); line-height: 1.35; color: var(--ink);
  min-height: 2.8em;
}
.smp-text .gen { color: var(--gold); animation: tkIn 0.35s ease both; }
.smp-text .caret {
  display: inline-block; width: 0.08em; height: 1em; background: var(--gold); vertical-align: -0.12em;
  margin-left: 0.08em; animation: blink 1s steps(2) infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.smp-q { font-family: var(--f-display); font-size: 0.86rem; color: var(--muted); margin-bottom: -12px; }
.smp-bars { display: grid; gap: 7px; }
.smp-row {
  display: grid; grid-template-columns: minmax(6em, 8.5em) 1fr 4.2em; align-items: center; gap: 12px;
  font-family: var(--f-num); font-size: 0.92rem; color: var(--ink-2);
  animation: tkIn 0.3s ease both;
}
.smp-row .lab { color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.smp-row .trk { height: 16px; border-radius: 4px; background: rgba(255,255,255,0.05); overflow: hidden; }
.smp-row .bar { height: 100%; border-radius: 4px; background: var(--blue); transition: width 0.35s cubic-bezier(.2,.7,.2,1), background 0.2s; }
.smp-row .pv { text-align: right; }
.smp-row.top .bar { background: var(--gold); }
.smp-row.top .pv { color: var(--gold); }
.smp-row.picked .bar { background: var(--pos); box-shadow: 0 0 18px rgba(75,227,160,0.6); }
.smp-row.picked .lab, .smp-row.picked .pv { color: var(--pos); }
.smp-end { font-family: var(--f-display); color: var(--ink-2); font-size: 0.95rem; }

/* ---------- Parametre ---------- */
.prm-seg { flex-wrap: wrap; border-radius: 18px; }
.prm-panel {
  left: 16px; right: 16px; top: 14px;
  display: flex; flex-wrap: wrap; align-items: flex-end; gap: 6px 26px;
  font-size: 0.8rem;
}
.prm-panel .big { font-size: 1.45rem; font-weight: 700; color: var(--gold); letter-spacing: -0.02em; font-family: var(--f-display); margin-right: 6px; line-height: 1.1; }
.prm-panel .r { display: flex; flex-direction: column; }
.prm-panel .r span { color: var(--muted); }
.prm-panel .r b { font-family: var(--f-num); font-weight: 500; color: var(--ink); font-size: 0.95rem; }

/* ---------- Kuantizasyon ---------- */
.q-fill { display: flex; }
.q-fill > .q-cv { position: relative; flex: 1; min-width: 0; }
.q-fill > .q-cv > canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.q-side {
  width: 250px; flex: none; border-left: 1px solid var(--line);
  padding: 16px 18px; display: flex; flex-direction: column; gap: 14px;
  font-family: var(--f-display); font-size: 0.86rem; color: var(--ink-2); overflow: auto;
}
.q-side h4 { margin: 0 0 4px; font-size: 0.8rem; font-weight: 600; color: var(--muted); }
.q-side .acc { font-size: 2.4rem; font-weight: 700; line-height: 1; letter-spacing: -0.03em; color: var(--ink); }
.q-side .acc.bad { color: var(--neg); }
.q-side .acc.ok { color: var(--pos); }
.q-side .sub { font-size: 0.8rem; color: var(--muted); margin-top: 4px; }
.q-side .size { font-size: 1.3rem; font-weight: 700; color: var(--gold); }
.q-tbl { width: 100%; border-collapse: collapse; font-family: var(--f-num); font-size: 0.8rem; }
.q-tbl td { padding: 3px 4px; border-top: 1px solid rgba(42,53,112,0.6); color: var(--ink-2); }
.q-tbl td:last-child { text-align: right; }
.q-tbl tr.on td { color: #1d1300; background: var(--gold); }
.q-load { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--f-display); color: var(--ink-2); }
@media (max-width: 860px) {
  .q-fill { flex-direction: column; }
  .q-fill > .q-cv { min-height: 360px; }
  .q-side { width: auto; border-left: 0; border-top: 1px solid var(--line); }
}
