/* ─── VATHMOLOGIES.CSS ── Δυναμική παρουσίαση στατιστικών βαθμολογιών 2026 ───── */

/* Controls */
.vathm-controls { display: flex; flex-wrap: wrap; gap: 14px; align-items: flex-end; margin-bottom: 22px; }
.vathm-ctl { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 600; color: var(--text-dim); }
.vathm-ctl select { padding: 10px 14px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); font-size: 14px; font-weight: 600; color: var(--text); min-width: 230px; }
.vathm-scope { display: inline-flex; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 3px; gap: 2px; }
.vathm-scope button { border: none; background: none; padding: 8px 16px; border-radius: 8px; font-size: 13px; font-weight: 700; color: var(--text-dim); cursor: pointer; }
.vathm-scope button.active { background: var(--accent); color: #fff; box-shadow: 0 3px 10px -3px rgba(234,88,12,.5); }

/* Chips επιλογής μαθήματος */
.vathm-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.vathm-chip { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); cursor: pointer; transition: all .18s ease; }
.vathm-chip:hover { border-color: var(--accent); transform: translateY(-1px); box-shadow: 0 6px 16px -8px rgba(15,23,42,.25); }
.vathm-chip .vc-name { font-size: 13px; font-weight: 600; color: var(--text); }
.vathm-chip .vc-pct { font-size: 13px; font-weight: 800; }
.vathm-chip.active { background: var(--accent); border-color: var(--accent); }
.vathm-chip.active .vc-name, .vathm-chip.active .vc-pct { color: #fff !important; }

/* Detail card */
.vathm-detail { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 22px 24px 26px; box-shadow: var(--shadow-sm, 0 2px 10px -4px rgba(15,23,42,.12)); }
.vathm-head h3 { margin: 0 0 18px; font-size: 21px; font-weight: 800; letter-spacing: -.01em; }
.vathm-head h3 small { font-weight: 600; color: var(--text-dim); font-size: 14px; }

/* KPIs με count-up */
.vathm-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 22px; }
.vkpi { background: var(--surface-2); border-radius: 12px; padding: 14px 16px; text-align: center; }
.vk-v { font-size: 26px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; }
.vk-l { font-size: 11.5px; color: var(--text-dim); margin-top: 4px; font-weight: 600; }
@media (max-width: 720px) { .vathm-kpis { grid-template-columns: repeat(2, 1fr); } }

/* Pass/fail bar (grow animation) */
.vathm-passbar { display: flex; height: 36px; border-radius: 10px; overflow: hidden; margin-bottom: 8px; }
.vathm-detail.go .vathm-passbar { animation: vgrowx .7s cubic-bezier(.2,.8,.2,1) backwards; }
.vathm-passbar span { display: flex; align-items: center; justify-content: center; font-size: 12.5px; font-weight: 800; color: #fff; white-space: nowrap; }
.pb-below { background: linear-gradient(180deg, #f87171, #dc2626); }
.pb-above { background: linear-gradient(180deg, #34d399, #0d7c8b); }
.vathm-passlegend { display: flex; gap: 18px; font-size: 12px; color: var(--text-dim); margin-bottom: 20px; }
.vathm-passlegend .dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: middle; }
.vathm-passlegend .dot.below { background: #dc2626; } .vathm-passlegend .dot.above { background: #0d7c8b; }

/* Γράφημα κατανομής 12 κλιμάκων */
.vathm-chart { display: flex; align-items: stretch; gap: 6px; height: 300px; padding-top: 26px; position: relative; }
.vbar { flex: 1 1 0; display: flex; flex-direction: column; align-items: center; position: relative; }
.vbar-pct { font-size: 10.5px; font-weight: 800; color: var(--text-dim); margin-bottom: 5px; }
.vbar-col { flex: 1; width: 100%; display: flex; align-items: flex-end; min-height: 0; }
.vbar-fill { width: 100%; height: var(--h); min-height: 2px; border-radius: 6px 6px 0 0; transform: scaleY(0); transform-origin: bottom; }
.vathm-detail.go .vbar-fill { animation: vgrow .55s cubic-bezier(.2,.85,.3,1) forwards; animation-delay: var(--d); }
.vbar.fail .vbar-fill { background: linear-gradient(180deg, #fdba74, #ef4444); }
.vbar.pass .vbar-fill { background: linear-gradient(180deg, #5eead4, #0d7c8b); }
.vbar-lbl { font-size: 9px; color: var(--text-faint); margin-top: 7px; white-space: nowrap; font-weight: 600; }
.vbar:hover .vbar-fill { filter: brightness(1.08) saturate(1.1); }
/* base-10 διαχωριστικό */
.vbar.base-start::before { content: ""; position: absolute; left: -4px; top: 0; bottom: 24px; border-left: 2px dashed #94a3b8; }
/* tooltip */
.vbar-tip { position: absolute; bottom: calc(100% - 18px); left: 50%; transform: translateX(-50%) translateY(6px); background: #0f172a; color: #fff; font-size: 11px; font-weight: 600; padding: 5px 9px; border-radius: 7px; white-space: nowrap; opacity: 0; pointer-events: none; transition: all .15s ease; z-index: 5; }
.vbar:hover .vbar-tip { opacity: 1; transform: translateX(-50%) translateY(0); }
.vathm-chart-axis { display: flex; justify-content: space-between; font-size: 11px; color: var(--text-faint); margin-top: 6px; font-weight: 600; }

@keyframes vgrow { to { transform: scaleY(1); } }
@keyframes vgrowx { from { transform: scaleX(0); transform-origin: left; } }

@media (max-width: 640px) {
  .vbar-lbl { display: none; }
  .vathm-chart { height: 240px; gap: 3px; }
  .vathm-ctl select { min-width: 0; width: 100%; }
}

/* ── Overview highlight cards ── */
.vathm-overview { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 22px; }
.vov-card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 16px 16px 14px; border-top: 3px solid var(--border); }
.vov-card.easy { border-top-color: #15803d; } .vov-card.hard { border-top-color: #b91c1c; }
.vov-card.arista { border-top-color: #ea580c; } .vov-card.avg { border-top-color: #0d7c8b; }
.vov-icon { font-size: 18px; }
.vov-l { font-size: 11.5px; font-weight: 700; color: var(--text-dim); margin-top: 4px; }
.vov-subj { font-size: 14.5px; font-weight: 800; color: var(--text); line-height: 1.25; margin: 3px 0 6px; min-height: 2.4em; }
.vov-v { font-size: 24px; font-weight: 800; letter-spacing: -.02em; }
.vov-sub { font-size: 11px; color: var(--text-faint); margin-top: 1px; }
@media (max-width: 860px) { .vathm-overview { grid-template-columns: repeat(2, 1fr); } }

/* ── Ranking (σύγκριση μαθημάτων) ── */
.vathm-rankwrap { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 18px 20px; margin-bottom: 22px; }
.vrank-head { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.vrank-head h3 { margin: 0; font-size: 17px; font-weight: 800; }
.vmetric-tabs { display: inline-flex; flex-wrap: wrap; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 3px; gap: 2px; }
.vmetric-tab { border: none; background: none; padding: 7px 12px; border-radius: 8px; font-size: 12.5px; font-weight: 700; color: var(--text-dim); cursor: pointer; white-space: nowrap; }
.vmetric-tab.active { background: var(--accent); color: #fff; }
.vathm-ranking { display: flex; flex-direction: column; gap: 7px; }
.vrank-row { display: grid; grid-template-columns: 190px 1fr 52px; align-items: center; gap: 12px; cursor: pointer; padding: 4px 6px; border-radius: 8px; transition: background .15s; }
.vrank-row:hover { background: var(--surface-2); }
.vrank-row.sel { background: var(--accent-soft, #fff7ed); box-shadow: inset 0 0 0 1px #fdba74; }
.vrank-name { font-size: 13px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vrank-track { background: var(--surface-2); border-radius: 6px; height: 16px; overflow: hidden; }
.vrank-bar { height: 100%; border-radius: 6px; transition: width .5s cubic-bezier(.2,.8,.2,1); }
.vrank-val { font-size: 13px; font-weight: 800; text-align: right; }
.vrank-hint { font-size: 12px; color: var(--text-faint); margin: 12px 0 0; text-align: center; }
@media (max-width: 560px) { .vrank-row { grid-template-columns: 110px 1fr 44px; gap: 8px; } .vrank-name { font-size: 12px; } }

/* ── Headline «κορυφαία στοιχεία» ── */
.vathm-headline { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px;
  background: linear-gradient(100deg, #fff7ed, #ecfeff); border: 1px solid var(--border); border-radius: 14px; padding: 14px 20px; margin-bottom: 18px; }
.vh-main { display: flex; align-items: baseline; gap: 10px; }
.vh-big { font-size: 30px; font-weight: 800; letter-spacing: -.02em; color: var(--accent); }
.vh-lbl { font-size: 13px; font-weight: 600; color: var(--text-dim); }
.vh-fact { font-size: 13px; color: var(--text-dim); } .vh-fact b { color: var(--text); }

/* ── Ημερήσια vs Εσπερινά ── */
.vathm-scopecmp { background: var(--surface-2); border-radius: 12px; padding: 14px 16px; margin-bottom: 18px; }
.vsc-title { font-size: 13px; font-weight: 800; color: var(--text-dim); margin-bottom: 10px; }
.vsc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.vsc-col { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 11px 13px; }
.vsc-col.active { box-shadow: inset 0 0 0 2px #fdba74; }
.vsc-h { font-size: 12px; font-weight: 700; color: var(--text-dim); }
.vsc-n { font-size: 20px; font-weight: 800; margin: 2px 0 8px; } .vsc-n span { font-size: 12px; font-weight: 600; color: var(--text-faint); }
.vsc-bar { display: flex; height: 12px; border-radius: 5px; overflow: hidden; }
.vsc-bar .pb-below { background: #dc2626; } .vsc-bar .pb-above { background: #0d7c8b; }
.vsc-pct { font-size: 12px; color: var(--text-dim); margin-top: 7px; }

/* ── Threshold slider ── */
.vathm-thresh { background: var(--accent-soft, #fff7ed); border: 1px solid #fed7aa; border-radius: 12px; padding: 14px 16px; margin: 4px 0 18px; }
.vt-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.vt-row label { font-size: 13px; font-weight: 700; color: var(--text); }
.vt-row input[type=range] { flex: 1; min-width: 180px; accent-color: var(--accent); }
.vt-out { font-size: 14px; color: var(--text); margin-top: 10px; }
.vbar.th-dim .vbar-fill { opacity: .2; }

/* ── Σύγκριση ομάδων προσανατολισμού ── */
.vathm-groupcmp { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--border); }
.vgc-title { font-size: 13.5px; font-weight: 800; color: var(--text-dim); margin-bottom: 12px; }
.vgc-row { display: grid; grid-template-columns: 200px 1fr 48px; align-items: center; gap: 12px; margin-bottom: 7px; }
.vgc-name { font-size: 13px; font-weight: 600; }
.vgc-track { background: var(--surface-2); border-radius: 6px; height: 14px; overflow: hidden; }
.vgc-bar { height: 100%; border-radius: 6px; transition: width .5s cubic-bezier(.2,.8,.2,1); }
.vgc-val { font-size: 13px; font-weight: 800; text-align: right; }
@media (max-width: 560px) { .vsc-grid { grid-template-columns: 1fr; } .vgc-row { grid-template-columns: 120px 1fr 42px; } }

/* Σημείωση ΕΠΑΛ (κοινά μαθήματα) */
.vathm-note { font-size: 12.5px; color: var(--text-dim); background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 9px 13px; margin: 0 0 18px; }
.vathm-note b { color: var(--text); }
