:root { --red:#c51f2c; --red-dark:#8c1220; --blue:#175a9b; --blue-dark:#0b315c; --green:#16845b; --orange:#d16c19; --ink:#17212b; --muted:#6c7580; --line:#dce4ec; --paper:#fff; --shadow:0 18px 50px rgba(16,55,94,.11); }
* { box-sizing:border-box; }
html,body { min-height:100%; }
body { margin:0; background:#edf3f9; color:var(--ink); font-family:Inter,Segoe UI,Arial,sans-serif; }
button,input { font:inherit; }
button { cursor:pointer; }
.hidden { display:none!important; }
.eyebrow { margin:0 0 5px; color:var(--red); font-size:11px; font-weight:900; letter-spacing:.12em; }
.admin-login { min-height:100vh; display:grid; place-items:center; padding:25px; background:radial-gradient(circle at 20% 15%,rgba(23,90,155,.18),transparent 35%),linear-gradient(145deg,#eaf2f8,#f8fafc); }
.login-card { width:min(470px,100%); padding:38px; border:1px solid rgba(23,90,155,.15); border-radius:26px; background:#fff; box-shadow:0 26px 80px rgba(11,49,92,.17); }
.login-card > img { width:150px; height:90px; display:block; margin:0 auto 18px; object-fit:contain; border-radius:12px; }
.login-card h1 { margin:2px 0 8px; font:750 37px/1.08 Georgia,serif; text-align:center; }
.login-card > p { color:var(--muted); text-align:center; line-height:1.55; }
.login-card > .eyebrow { text-align:center; }
.login-card label { display:grid; gap:7px; margin-top:20px; font-size:12px; font-weight:900; }
.login-card input { width:100%; height:52px; padding:0 15px; border:2px solid var(--line); border-radius:13px; outline:0; }
.login-card input:focus { border-color:var(--blue); box-shadow:0 0 0 4px rgba(23,90,155,.1); }
.login-card button,.activate-button { min-height:50px; border:0; border-radius:13px; background:linear-gradient(135deg,var(--red),var(--red-dark)); color:#fff; font-weight:900; box-shadow:0 8px 20px rgba(197,31,44,.2); }
.login-card button { width:100%; margin-top:14px; }
.message { padding:12px 14px; margin:10px 0; border-radius:11px; background:#e9f7f1; color:var(--green); font-size:13px; font-weight:800; }
.message.error { background:#fff0f2; color:var(--red-dark); }
.admin-shell { min-height:100vh; display:grid; grid-template-columns:260px 1fr; }
.admin-sidebar { position:fixed; inset:0 auto 0 0; z-index:20; width:260px; display:flex; flex-direction:column; padding:25px 18px; background:#0c2033; color:#fff; }
.admin-brand { display:flex; align-items:center; gap:11px; padding:0 7px 25px; border-bottom:1px solid rgba(255,255,255,.11); }
.admin-brand img { width:64px; height:55px; object-fit:contain; border-radius:8px; background:#fff; }
.admin-brand small,.admin-brand b { display:block; }
.admin-brand small { color:#c7d6e4; font-size:10px; letter-spacing:.09em; }
.admin-brand b { color:#fff; font:800 21px/1 Georgia,serif; }
.admin-sidebar nav { display:grid; gap:7px; margin-top:25px; }
.admin-sidebar nav button { position:relative; min-height:47px; display:grid; grid-template-columns:27px 1fr auto; align-items:center; gap:7px; padding:0 13px; border:0; border-radius:12px; background:transparent; color:#cbd8e4; text-align:left; font-size:13px; font-weight:800; }
.admin-sidebar nav button:hover,.admin-sidebar nav button.active { background:rgba(255,255,255,.1); color:#fff; }
.admin-sidebar nav button.active::before { content:""; position:absolute; left:-18px; width:4px; height:27px; border-radius:0 6px 6px 0; background:#e53643; }
.admin-sidebar nav button > span { font-size:20px; }
.admin-sidebar nav button > b { min-width:25px; padding:4px 7px; border-radius:999px; background:var(--red); color:#fff; text-align:center; font-size:11px; }
.sidebar-bottom { display:grid; gap:9px; margin-top:auto; }
.sidebar-bottom button { min-height:42px; border:1px solid rgba(255,255,255,.17); border-radius:11px; background:transparent; color:#cbd8e4; font-weight:800; }
.sidebar-bottom button:hover { background:rgba(255,255,255,.08); color:#fff; }
.admin-main { grid-column:2; min-width:0; padding:28px 32px 55px; }
.admin-topbar { display:flex; align-items:center; gap:17px; margin-bottom:22px; }
.admin-topbar h1 { margin:0; font:750 37px/1 Georgia,serif; }
.server-state { display:flex; align-items:center; gap:8px; margin-left:auto; padding:10px 14px; border:1px solid #cfe2d8; border-radius:999px; background:#f4fbf7; color:var(--green); font-size:12px; font-weight:850; }
.server-state span { width:9px; height:9px; border-radius:50%; background:#1ba06e; box-shadow:0 0 0 4px rgba(27,160,110,.12); }
.menu-button { display:none; width:42px; height:42px; border:1px solid var(--line); border-radius:10px; background:#fff; }
.summary-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:14px; }
.summary-grid article { padding:20px; border:1px solid var(--line); border-radius:18px; background:#fff; box-shadow:var(--shadow); }
.summary-grid small,.summary-grid span { display:block; color:var(--muted); }
.summary-grid small { font-size:11px; font-weight:900; text-transform:uppercase; letter-spacing:.05em; }
.summary-grid b { display:block; margin:7px 0 2px; color:var(--blue-dark); font-size:31px; }
.summary-grid span { font-size:12px; }
.students-panel { margin-top:17px; padding:22px; border:1px solid var(--line); border-radius:20px; background:#fff; box-shadow:var(--shadow); }
.panel-head { display:flex; justify-content:space-between; align-items:end; gap:20px; padding-bottom:17px; border-bottom:1px solid var(--line); }
.panel-head h2 { margin:0 0 4px; font:750 27px/1.1 Georgia,serif; }
.panel-head p { margin:0; color:var(--muted); font-size:13px; }
.search-field { width:min(330px,100%); height:45px; display:flex; align-items:center; gap:8px; padding:0 13px; border:1px solid var(--line); border-radius:12px; background:#f8fafc; }
.search-field input { flex:1; min-width:0; border:0; outline:0; background:transparent; }
.students-list { display:grid; gap:13px; margin-top:17px; }
.student-card { overflow:hidden; border:1px solid var(--line); border-radius:17px; background:#fff; }
.student-main { display:grid; grid-template-columns:56px minmax(0,1fr) auto; align-items:start; gap:14px; padding:17px; }
.student-avatar { width:52px; height:52px; display:grid; place-items:center; border-radius:15px; background:linear-gradient(135deg,var(--blue),var(--blue-dark)); color:#fff; font-weight:950; }
.student-identity > div { display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.student-identity h3 { margin:0; font-size:18px; }
.student-identity > p { margin:5px 0 9px; color:var(--muted); font-size:11px; }
.status-badge { padding:5px 8px; border-radius:999px; font-size:10px; font-weight:900; text-transform:uppercase; }
.status-badge.active { background:#e9f7f1; color:var(--green); }
.status-badge.pending { background:#e8f2fc; color:var(--blue); }
.status-badge.expired { background:#fff2dd; color:var(--orange); }
.licenses { display:flex; gap:6px; flex-wrap:wrap; }
.license-chip { display:flex; align-items:center; gap:6px; padding:5px 8px; border-radius:8px; background:#f0f3f6; color:var(--muted); font-size:10px; }
.license-chip.active { background:#e9f7f1; color:#126d4d; }
.license-chip.expired { background:#fff0f2; color:var(--red-dark); }
.license-chip.revoked { background:#f1f1f1; color:#5f6670; }
.license-chip small { opacity:.8; }
.license-chip button { min-height:26px; padding:0 8px; border:1px solid #e5a5ab; border-radius:7px; background:#fff; color:var(--red-dark); font-size:9px; font-weight:900; }
.license-chip button:hover { background:#fff0f2; }
.empty-license { color:var(--muted); font-size:11px; font-style:italic; }
.student-numbers { display:flex; align-items:center; gap:13px; }
.student-numbers > div { min-width:55px; text-align:center; }
.student-numbers b,.student-numbers small { display:block; }
.student-numbers b { color:var(--blue-dark); font-size:18px; }
.student-numbers small { color:var(--muted); font-size:10px; }
.student-numbers button { min-height:38px; padding:0 12px; border:1px solid var(--line); border-radius:10px; background:#f8fafc; color:var(--blue); font-size:11px; font-weight:850; }
.activation-row { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:14px; align-items:center; padding:14px 17px; border-top:1px solid var(--line); background:#f8fafc; }
.category-choices { display:flex; gap:6px; flex-wrap:wrap; }
.category-choices label { cursor:pointer; }
.category-choices input { position:absolute; opacity:0; pointer-events:none; }
.category-choices span { display:block; padding:8px 10px; border:1px solid #d4dee7; border-radius:9px; background:#fff; color:#53606c; font-size:10px; font-weight:850; }
.category-choices input:checked + span { border-color:var(--blue); background:#e8f2fc; color:var(--blue-dark); box-shadow:inset 0 0 0 1px var(--blue); }
.category-choices label.current span::after { content:" ✓"; color:var(--green); }
.activation-actions { display:flex; align-items:end; gap:8px; }
.duration-field { display:grid; gap:5px; color:var(--muted); font-size:9px; font-weight:900; text-transform:uppercase; letter-spacing:.04em; }
.duration-field select { height:38px; padding:0 30px 0 10px; border:1px solid #ccd8e2; border-radius:9px; background:#fff; color:var(--ink); font-size:11px; font-weight:800; }
.activate-button { min-width:165px; padding:0 16px; }
.empty-state { padding:55px 20px; text-align:center; color:var(--muted); }
.empty-state > span { font-size:38px; }
.empty-state h3 { margin:8px 0 4px; color:var(--ink); }
.empty-state p { margin:0; }
.details-dialog { width:min(900px,calc(100% - 30px)); max-height:88vh; padding:0; border:0; border-radius:22px; box-shadow:0 30px 90px rgba(0,0,0,.25); }
.details-dialog::backdrop { background:rgba(8,24,39,.6); backdrop-filter:blur(3px); }
.details-dialog header { position:sticky; top:0; z-index:2; display:flex; justify-content:space-between; align-items:center; padding:22px 25px; border-bottom:1px solid var(--line); background:#fff; }
.details-dialog h2 { margin:0; font:750 29px/1.1 Georgia,serif; }
.details-dialog header button { width:40px; height:40px; border:0; border-radius:10px; background:#eef2f5; font-size:25px; }
.details-section { padding:22px 25px; }
.details-section + .details-section { border-top:1px solid var(--line); }
.details-section h3 { margin:0 0 14px; }
.topic-bars { display:grid; gap:10px; }
.topic-bar { display:grid; grid-template-columns:minmax(150px,260px) 1fr 45px 100px; align-items:center; gap:10px; font-size:12px; }
.topic-bar > div { height:9px; overflow:hidden; border-radius:999px; background:#e7ecf1; }
.topic-bar i { display:block; height:100%; border-radius:inherit; background:linear-gradient(90deg,var(--red),#f3b43f,var(--green)); }
.topic-bar b { text-align:right; }
.topic-bar small { color:var(--muted); }
.attempts-table { display:grid; }
.attempts-table > button { width:100%; display:grid; grid-template-columns:120px 130px 1fr 60px 95px; align-items:center; gap:12px; padding:11px 7px; border:0; border-bottom:1px solid #edf0f3; background:#fff; color:var(--ink); text-align:left; font-size:12px; }
.attempts-table > button:hover { background:#f5f9fc; }
.attempts-table span,.attempts-table small { color:var(--muted); }
.attempts-table strong { padding:6px; border-radius:8px; text-align:center; }
.attempts-table strong.passed { background:#e9f7f1; color:var(--green); }
.attempts-table strong.failed { background:#fff0f2; color:var(--red-dark); }
.attempts-table em { color:var(--blue); text-align:right; font-size:10px; font-style:normal; font-weight:900; }
.attempt-heading { margin:6px 0 0; color:var(--muted); font-size:11px; }
.dialog-actions { display:flex; gap:7px; }
.details-dialog header .back-button { color:var(--blue); font-size:20px; }
.attempt-summary { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; background:#f8fafc; }
.attempt-summary > div { padding:13px; border:1px solid var(--line); border-radius:12px; background:#fff; }
.attempt-summary small,.attempt-summary b { display:block; }
.attempt-summary small { margin-bottom:5px; color:var(--muted); font-size:10px; font-weight:850; text-transform:uppercase; }
.attempt-summary b { font-size:18px; }
.passed-text { color:var(--green); }
.failed-text { color:var(--red-dark); }
.attempt-review { display:grid; gap:11px; }
.attempt-question { display:grid; grid-template-columns:38px 1fr; gap:12px; padding:15px; border:1px solid var(--line); border-left:5px solid var(--green); border-radius:14px; background:#fff; }
.attempt-question.wrong { border-left-color:var(--red); background:#fffafb; }
.question-index { width:34px; height:34px; display:grid; place-items:center; border-radius:10px; background:#e9f7f1; color:var(--green); font-weight:950; }
.attempt-question.wrong .question-index { background:#fff0f2; color:var(--red-dark); }
.attempt-question small { color:var(--muted); }
.attempt-question h4 { margin:6px 0 10px; font-size:14px; line-height:1.45; }
.attempt-question img { display:block; max-width:min(420px,100%); max-height:300px; margin:10px 0; border:1px solid var(--line); border-radius:12px; object-fit:contain; background:#fff; }
.answer-comparison { display:flex; gap:8px; flex-wrap:wrap; }
.answer-comparison span { padding:7px 9px; border-radius:8px; background:#f0f4f7; font-size:11px; }
.no-data { color:var(--muted); }
@media(max-width:1100px){ .summary-grid{grid-template-columns:repeat(2,1fr)} .student-main{grid-template-columns:52px 1fr}.student-numbers{grid-column:2;justify-content:flex-start}.activation-row{grid-template-columns:1fr}.activation-actions{justify-content:flex-end} }
@media(max-width:760px){ .admin-shell{display:block}.admin-sidebar{transform:translateX(-105%);transition:.25s}.admin-sidebar.open{transform:translateX(0)}.admin-main{padding:20px 14px 40px}.menu-button{display:block}.admin-topbar h1{font-size:30px}.server-state{display:none}.summary-grid{grid-template-columns:1fr 1fr;gap:8px}.summary-grid article{padding:15px}.students-panel{padding:14px}.panel-head{align-items:stretch;flex-direction:column}.search-field{width:100%}.student-main{grid-template-columns:45px 1fr;padding:14px}.student-avatar{width:43px;height:43px}.student-numbers{grid-column:1/-1}.activation-row{padding:13px}.activation-actions{display:grid;grid-template-columns:1fr 1.4fr}.activate-button{width:100%;min-width:0}.topic-bar{grid-template-columns:1fr 45px}.topic-bar>div{grid-column:1/-1;grid-row:2}.topic-bar small{display:none}.attempts-table>button{grid-template-columns:95px 1fr 55px}.attempts-table small,.attempts-table em{display:none}.attempt-summary{grid-template-columns:1fr 1fr}.attempt-question{grid-template-columns:30px 1fr;padding:12px}.question-index{width:28px;height:28px}.login-card{padding:28px 21px} }
