/* qxmd312: Create Own Test polish: compact bottom bar, no nested scroll, 360px fit, light + dark */
.ct-wizard-overlay{z-index:2147480000 !important}
body:has(.ct-wizard-overlay) .jovi-fab,body:has(.ct-wizard-overlay) [class*="jovi-fab"],body:has(.ct-wizard-overlay) #joviFab{display:none !important}
.ct-wiz-sum-line{display:none;font-size:12.5px;font-weight:700;line-height:1.3;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#e2e8f0}
html[data-theme="light"] .ct-wiz-sum-line{color:#0f172a}
.ct-wiz-diff-chips,.ct-wiz-mark-chips{flex-wrap:wrap}
.ct-wizard-overlay .ct-wiz-preview-bar .ct-wiz-next-btn{background:linear-gradient(135deg,#2563eb,#38bdf8) !important;color:#fff !important;font-weight:800;border:none !important}
.ct-wizard-overlay .ct-wiz-preview-bar .ct-wiz-next-btn.disabled,.ct-wizard-overlay .ct-wiz-preview-bar .ct-wiz-next-btn:disabled{background:#334155 !important;color:#94a3b8 !important;opacity:1 !important}
html[data-theme="light"] .ct-wizard-overlay .ct-wiz-preview-bar .ct-wiz-next-btn{background:linear-gradient(135deg,#1d4ed8,#3b82f6) !important;color:#fff !important}
html[data-theme="light"] .ct-wizard-overlay .ct-wiz-preview-bar .ct-wiz-next-btn.disabled,html[data-theme="light"] .ct-wizard-overlay .ct-wiz-preview-bar .ct-wiz-next-btn:disabled{background:#e2e8f0 !important;color:#94a3b8 !important}
@media (max-width:768px){
  .ct-wizard-overlay{inset:0 !important;height:100vh;height:100dvh;background:#12151c !important;overflow:hidden}
  html[data-theme="light"] .ct-wizard-overlay{background:#f8fafc !important}
  .ct-wizard-shell,.ct-wizard-shell.wide{width:100% !important;max-width:100% !important;height:100%;overflow-y:auto;overflow-x:hidden;-webkit-overflow-scrolling:touch;overscroll-behavior:contain;display:block !important;border:0 !important}
  .ct-wizard-split{display:block !important;min-height:0 !important}
  .ct-wizard-left-panel{overflow:visible !important;border:0 !important}
  .ct-wizard-left-inner{padding:14px 14px calc(92px + env(safe-area-inset-bottom,0px)) !important;min-height:0 !important}
  .ct-wizard-right-inner{min-height:0 !important;padding:8px 14px calc(96px + env(safe-area-inset-bottom,0px)) !important}
  .ct-wizard-split:not(.ct-wizard-years-split) .ct-wizard-left-inner{padding-bottom:8px !important}
  .ct-wiz-years-summary{display:none !important}
  .ct-wiz-head{margin-bottom:8px}
  .ct-wiz-head h2{font-size:18px !important}
  .ct-wiz-close{width:36px;height:36px}
  .ct-wiz-steps{margin-bottom:6px}
  .ct-wiz-progress{margin-bottom:12px}
  .ct-wiz-section{margin-bottom:14px}
  .ct-wiz-section h4{margin-bottom:8px}
  .ct-wiz-multi-tip,.ct-wiz-right-head small,.ct-wiz-hint{display:none}
  /* exam + subject cards: compact rows, no inner scroll box */
  .ct-wiz-exam-grid,.ct-wiz-subj-grid{max-height:none !important;overflow:visible !important;grid-template-columns:1fr 1fr !important;gap:8px !important}
  .ct-wiz-card{min-height:52px !important;padding:8px 10px !important;display:flex !important;flex-direction:row !important;align-items:center !important;justify-content:flex-start !important;gap:8px !important;text-align:left !important;position:relative}
  .ct-wiz-card img,.ct-wiz-card svg,.ct-wiz-card .ct-exam-ic,.ct-wiz-card .ct-subj-ic{width:28px !important;height:28px !important;flex:0 0 28px;margin:0 !important}
  .ct-wiz-card strong{font-size:13px !important;line-height:1.25 !important;margin:0 !important;min-width:0;overflow-wrap:anywhere}
  .ct-wiz-subj-check{top:4px !important;right:4px !important;width:18px !important;height:18px !important;font-size:11px !important}
  .ct-wiz-set-chip{min-height:38px;padding:6px 12px !important;font-size:13px !important}
  .ct-wiz-set-chips{gap:6px !important}
  .ct-wiz-duration-row{flex-wrap:wrap;gap:6px}
  .ct-wiz-year-presets{gap:8px !important}
  .ct-wiz-year-preset{min-height:64px !important;padding:8px !important}
  .ct-wiz-year-preset small{display:none}
  .ct-wiz-subj-row{flex-wrap:wrap;gap:6px}
  .ct-wiz-unit-head{flex-wrap:wrap;gap:6px}
  /* compact fixed bottom bar: back · one-line summary · primary */
  .ct-wizard-overlay .ct-wiz-preview-bar,.ct-wizard-left-panel .ct-wiz-preview-bar{position:fixed !important;left:0 !important;right:0 !important;bottom:0 !important;top:auto !important;transform:none !important;margin:0 !important;z-index:20 !important;display:flex !important;align-items:center !important;gap:10px !important;padding:10px 12px max(10px,env(safe-area-inset-bottom,0px)) !important;min-height:64px;box-sizing:border-box;background:#12151c !important;border-top:1px solid #2a2f3d !important;box-shadow:0 -6px 18px rgba(0,0,0,.25)}
  html[data-theme="light"] .ct-wizard-overlay .ct-wiz-preview-bar{background:#fff !important;border-top-color:#e2e8f0 !important;box-shadow:0 -6px 18px rgba(15,23,42,.08)}
  .ct-wiz-preview-bar .ct-wiz-back-btn{flex:0 0 44px;width:44px;height:44px;padding:0}
  .ct-wiz-preview-mid{flex:1 1 auto;min-width:0}
  .ct-wiz-preview-mid small{font-size:11px;opacity:.75}
  .ct-wiz-preview-mid .ct-wiz-prev-badges,.ct-wiz-preview-mid .ct-wiz-prev-stats{display:none !important}
  .ct-wiz-sum-line{display:block}
  .ct-wiz-preview-bar .ct-wiz-next-btn{flex:0 0 auto;min-height:44px;padding:0 16px !important;border-radius:12px;font-size:14px !important;white-space:nowrap}
}
.ct-qs-section{border:1px solid rgba(212,160,23,.35);border-radius:14px;padding:12px 12px 8px;background:linear-gradient(180deg,rgba(30,41,59,.35),rgba(15,23,42,.2))}
html[data-theme="light"] .ct-qs-section{background:linear-gradient(180deg,#fffbeb,#fff);border-color:#f3d27a}
.ct-qs-mode{display:flex;flex-wrap:wrap;gap:8px}
.ct-qs-slots{display:flex;flex-direction:column;gap:6px;max-height:280px;overflow:auto;margin:8px 0 4px;padding-right:2px}
.ct-qs-slot-row{display:grid;grid-template-columns:36px minmax(110px,1fr) 96px 58px;gap:6px;align-items:center;font-size:12px;font-weight:700}
.ct-qs-prize{display:flex;align-items:center;gap:4px;min-width:0}
.ct-qs-prize input{width:100%;min-width:0;min-height:34px;border-radius:8px;border:1px solid #334155;background:#0f172a;color:#e2e8f0;padding:4px 8px}
html[data-theme="light"] .ct-qs-prize input{background:#fff;color:#0f172a;border-color:#cbd5e1}
.ct-qs-slot-row select{min-height:34px;border-radius:8px;border:1px solid #334155;background:#0f172a;color:#e2e8f0}
html[data-theme="light"] .ct-qs-slot-row select{background:#fff;color:#0f172a;border-color:#cbd5e1}
.ct-qs-safe{display:flex;align-items:center;gap:4px;font-size:11px;white-space:nowrap}
@media (max-width:768px){
  .ct-qs-slot-row{grid-template-columns:32px 1fr 88px;grid-template-rows:auto auto}
  .ct-qs-safe{grid-column:1 / -1}
}
@media (prefers-reduced-motion:reduce){.ct-wizard-overlay *{animation:none !important;transition:none !important}}

/* qxmd356 — selected chips/cards obvious in light + dark; icons never black blobs */
.ct-wizard-overlay .ct-wiz-steps{
  display:flex !important;
  align-items:center;
  gap:6px;
  flex-wrap:wrap;
  pointer-events:auto !important;
}
.ct-wizard-overlay button.ct-wiz-step{
  display:inline-flex !important;
  align-items:center;
  gap:6px;
  font-size:12px;
  font-weight:800;
  color:#94a3b8;
  background:transparent;
  border:0;
  padding:6px 8px;
  border-radius:999px;
  cursor:pointer;
  font-family:inherit;
  pointer-events:auto !important;
}
.ct-wizard-overlay button.ct-wiz-step i{
  width:20px;height:20px;border-radius:50%;
  border:1px solid #3b4254;
  display:inline-flex;align-items:center;justify-content:center;
  font-style:normal;font-size:11px;
}
.ct-wizard-overlay button.ct-wiz-step.on{
  color:#fff !important;
  background:#2563eb !important;
}
.ct-wizard-overlay button.ct-wiz-step.on i{
  background:#fff !important;border-color:#fff !important;color:#1d4ed8 !important;
}
.ct-wizard-overlay button.ct-wiz-step.done{
  color:#86efac !important;
  background:rgba(22,163,74,.16) !important;
}
.ct-wizard-overlay button.ct-wiz-step.done i{
  background:#166534 !important;border-color:#166534 !important;color:#dcfce7 !important;
}

html body .ct-wizard-overlay .ct-wiz-set-chip,
html[data-theme="light"] body .ct-wizard-overlay .ct-wiz-set-chip,
html[data-theme="dark"] body .ct-wizard-overlay .ct-wiz-set-chip{
  pointer-events:auto !important;
  cursor:pointer !important;
}
html body .ct-wizard-overlay .ct-wiz-set-chip.on,
html[data-theme="light"] body .ct-wizard-overlay .ct-wiz-set-chip.on,
html[data-theme="dark"] body .ct-wizard-overlay .ct-wiz-set-chip.on{
  background:#2563eb !important;
  border-color:#1d4ed8 !important;
  color:#ffffff !important;
  -webkit-text-fill-color:#ffffff !important;
  box-shadow:0 0 0 2px rgba(37,99,235,.35) !important;
}
html body .ct-wizard-overlay .ct-wiz-card.on,
html body .ct-wizard-overlay .ct-wiz-ch-card.on,
html body .ct-wizard-overlay .ct-wiz-ch-card.ct-folder.on,
html[data-theme="light"] body .ct-wizard-overlay .ct-wiz-card.on,
html[data-theme="light"] body .ct-wizard-overlay .ct-wiz-ch-card.on,
html[data-theme="dark"] body .ct-wizard-overlay .ct-wiz-card.on{
  border-color:#2563eb !important;
  background:rgba(37,99,235,.16) !important;
  box-shadow:0 0 0 2px rgba(37,99,235,.4) !important;
}
html[data-theme="light"] body .ct-wizard-overlay .ct-wiz-card.on,
html[data-theme="light"] body .ct-wizard-overlay .ct-wiz-ch-card.on,
html[data-theme="light"] body .ct-wizard-overlay .ct-wiz-ch-card.ct-folder.on{
  background:#eff6ff !important;
  color:#0f172a !important;
}
html body .ct-wizard-overlay .ct-wiz-year-preset.on,
html body .ct-wizard-overlay .ct-year-cell.on,
html[data-theme="light"] body .ct-wizard-overlay .ct-wiz-year-preset.on,
html[data-theme="light"] body .ct-wizard-overlay .ct-year-cell.on{
  border-color:#16a34a !important;
  background:rgba(22,163,74,.16) !important;
  box-shadow:0 0 0 2px rgba(22,163,74,.35) !important;
}
html[data-theme="light"] body .ct-wizard-overlay .ct-wiz-year-preset.on,
html[data-theme="light"] body .ct-wizard-overlay .ct-year-cell.on{
  background:#ecfdf5 !important;
  color:#14532d !important;
}

html body .ct-wizard-overlay .ct-wiz-card img,
html body .ct-wizard-overlay .ct-wiz-card-logo,
html body .ct-wizard-overlay .ct-wiz-card svg,
html body .ct-wizard-overlay .ct-wiz-subj-emoji,
html body .ct-wizard-overlay .ct-wiz-subj-emoji img,
html body .ct-wizard-overlay .qx-ch-glyph-img,
html body .ct-wizard-overlay .qx-ch-icon,
html body .ct-wizard-overlay .qx-ch-icon img,
html body .ct-wizard-overlay .qx-ch-plate,
html body .ct-wizard-overlay .cpyqb-ch-ic,
html body .ct-wizard-overlay .ct-wiz-ch-card img{
  opacity:1 !important;
  visibility:visible !important;
  filter:none !important;
  -webkit-filter:none !important;
  mix-blend-mode:normal !important;
}
html body .ct-wizard-overlay .ct-wiz-card-logo{
  background:#ffffff !important;
  border-radius:10px;
  padding:3px;
  box-sizing:content-box;
}
html body .ct-wizard-overlay .qx-ch-icon,
html body .ct-wizard-overlay .qx-ch-plate,
html body .ct-wizard-overlay .cpyqb-ch-ic{
  background:linear-gradient(145deg,var(--qx-plate-a,#eff6ff),var(--qx-plate-b,#93c5fd)) !important;
  border-radius:14px;
  display:inline-flex !important;
  align-items:center;
  justify-content:center;
}
html body .ct-wizard-overlay .ct-wiz-ch-card.ct-folder .qx-topic-ic,
html body .ct-wizard-overlay .ct-wiz-ch-card.ct-folder .cpyqb-ch-ic,
html body .ct-wizard-overlay .ct-wiz-ch-card.ct-folder .qx-ch-icon{
  width:72px !important;
  height:72px !important;
}
html body .ct-wizard-overlay .ct-wiz-ch-check{
  width:22px !important;
  height:22px !important;
  accent-color:#2563eb !important;
  pointer-events:auto !important;
}
html body .ct-wizard-overlay .ct-wiz-ch-card.on .qx-ch-pill{
  background:#2563eb !important;
  color:#fff !important;
}
.ct-qs-custom-n{
  display:inline-flex;
  align-items:center;
  gap:6px;
  font-size:12px;
  font-weight:800;
  color:#94a3b8;
}
.ct-qs-custom-n input{
  width:64px;
  min-height:34px;
  border-radius:8px;
  border:1px solid #334155;
  background:#0f172a;
  color:#e2e8f0;
  padding:4px 8px;
  font-weight:800;
}
html[data-theme="light"] .ct-qs-custom-n{color:#475569}
html[data-theme="light"] .ct-qs-custom-n input{background:#fff;color:#0f172a;border-color:#cbd5e1}
@media (max-width:768px){
  .ct-wizard-overlay .ct-wiz-ch-card{min-height:0 !important;height:auto !important;padding-bottom:10px !important}
  .ct-wizard-overlay .ct-wiz-ch-card .qx-topic-details{margin-top:6px !important}
}
