@import url('https://fonts.googleapis.com/css2?family=Google+Sans');

html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  font-family: 'Google Sans', 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background-color: #020617;
  color: #f8fafc;
  line-height: 24px;
  overscroll-behavior: none;
}

body {
  background: radial-gradient(circle at 20% 15%, #0f1f3d 0%, #060b16 55%, #030712 100%);
}

a {
  color: #38bdf8;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

button {
  cursor: pointer;
  pointer-events: auto;
}

.background-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  pointer-events: none;
}


/* Unified Collapsible Bottom Control Dock (Zero Viewport Occlusion, No backdrop-filter) */
#szbi-bottom-dock {
  position: fixed;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: max-content;
  max-width: min(940px, 94vw);
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
}

#szbi-bottom-dock > * {
  pointer-events: auto;
}

.szbi-dock-toggle-row {
  margin-bottom: 6px;
}

.szbi-toggle-btn {
  background-color: rgba(15, 23, 42, 0.94);
  color: #94a3b8;
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 8px;
  padding: 4px 14px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: none;
}

.szbi-toggle-btn:hover {
  color: #f8fafc;
  border-color: #38bdf8;
}

.szbi-dock-panel {
  background-color: rgba(15, 23, 42, 0.96);
  border: 1px solid rgba(56, 189, 248, 0.38);
  border-radius: 14px;
  padding: 10px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.65);
}

.szbi-dock-info {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
}

.szbi-badge {
  background-color: rgba(14, 165, 233, 0.2);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.4);
  padding: 2px 8px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 11px;
}

.szbi-status-text {
  color: #e2e8f0;
  font-weight: 500;
}

.szbi-dock-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.szbi-action-btn {
  background-color: rgba(30, 41, 59, 0.95);
  color: #f8fafc;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  text-transform: none;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.szbi-action-btn:hover {
  background-color: rgba(51, 65, 85, 0.98);
  border-color: #38bdf8;
}

.szbi-btn-accent {
  background-color: rgba(2, 132, 199, 0.85);
  border-color: #38bdf8;
}

.szbi-btn-accent:hover {
  background-color: rgba(14, 165, 233, 0.95);
}

.szbi-btn-success {
  background-color: rgba(5, 150, 105, 0.85);
  border-color: #34d399;
}

.szbi-btn-success:hover {
  background-color: rgba(16, 185, 129, 0.95);
}

.szbi-btn-link {
  background-color: rgba(109, 40, 217, 0.85);
  border-color: #a78bfa;
}

.szbi-btn-link:hover {
  background-color: rgba(124, 58, 237, 0.95);
}

/* Magic Link Login & Server Deployment Modal */
.szbi-modal-hidden {
  display: none;
}

.szbi-modal-visible {
  position: fixed;
  inset: 0;
  background-color: rgba(2, 6, 23, 0.85);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.szbi-modal-card {
  background-color: #0f172a;
  border: 1px solid #38bdf8;
  border-radius: 16px;
  width: 100%;
  max-width: 680px;
  padding: 24px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8);
  color: #f8fafc;
}

.szbi-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 18px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.25);
  padding-bottom: 12px;
}

.szbi-modal-header h2 {
  margin: 0 0 4px 0;
  font-size: 18px;
  color: #38bdf8;
}

.szbi-modal-header p {
  margin: 0;
  font-size: 13px;
  color: #94a3b8;
}

.szbi-close-btn {
  background-color: transparent;
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 8px;
  padding: 4px 10px;
  font-size: 12px;
  text-transform: none;
}

.szbi-close-btn:hover {
  color: #fff;
  border-color: #f8fafc;
}

.szbi-modal-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-bottom: 18px;
}

.szbi-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.szbi-field label {
  font-size: 12px;
  color: #cbd5e1;
  font-weight: 600;
}

.szbi-field input,
.szbi-field select {
  background-color: #1e293b;
  color: #f8fafc;
  border: 1px solid rgba(148, 163, 184, 0.4);
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 13px;
  outline: none;
}

.szbi-field input:focus,
.szbi-field select:focus {
  border-color: #38bdf8;
}

.szbi-link-box {
  background-color: #020617;
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 18px;
}

.szbi-link-box label {
  display: block;
  font-size: 12px;
  color: #94a3b8;
  margin-bottom: 6px;
}

.szbi-link-row {
  display: flex;
  gap: 8px;
}

.szbi-link-row input {
  flex: 1;
  background-color: #0f172a;
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 6px;
  padding: 6px 10px;
  font-family: monospace;
  font-size: 12px;
}

.szbi-copy-msg {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  color: #34d399;
}

.szbi-modal-footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

/* Interactive 15-Question Quiz Interface Overlay (No backdrop-filter, static indicators) */
.szbi-quiz-shell {
  background-color: #0f172a;
  border: 1px solid #38bdf8;
  border-radius: 16px;
  width: 100%;
  max-width: 820px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.85);
  color: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.szbi-quiz-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  flex-wrap: wrap;
  border-bottom: 1px solid rgba(148, 163, 184, 0.25);
  padding-bottom: 12px;
}

.szbi-quiz-title-group h2 {
  margin: 6px 0 0 0;
  font-size: 19px;
  color: #f8fafc;
}

.szbi-quiz-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.szbi-quiz-statusbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  background-color: rgba(2, 6, 23, 0.75);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 10px;
  padding: 8px 14px;
}

.szbi-quiz-score {
  font-weight: 600;
  color: #38bdf8;
}

.szbi-quiz-threshold {
  color: #94a3b8;
}

.szbi-quiz-nav-grid {
  display: grid;
  grid-template-columns: repeat(15, minmax(0, 1fr));
  gap: 6px;
}

.szbi-quiz-step-pill {
  background-color: #1e293b;
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 6px;
  padding: 6px 0;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
}

.szbi-quiz-step-pill.is-active {
  border-color: #38bdf8;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.35);
}

.szbi-quiz-step-pill.is-correct {
  background-color: rgba(5, 150, 105, 0.85);
  border-color: #34d399;
  color: #ffffff;
}

.szbi-quiz-step-pill.is-wrong {
  background-color: rgba(220, 38, 38, 0.85);
  border-color: #f87171;
  color: #ffffff;
}

.szbi-quiz-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.szbi-quiz-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.szbi-quiz-cat-pill {
  background-color: rgba(139, 92, 246, 0.22);
  color: #c4b5fd;
  border: 1px solid rgba(167, 139, 250, 0.4);
  border-radius: 6px;
  padding: 2px 10px;
  font-size: 12px;
  font-weight: 600;
}

.szbi-quiz-ref-pill {
  background-color: rgba(56, 189, 248, 0.14);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 6px;
  padding: 2px 10px;
  font-size: 12px;
  font-weight: 600;
}

.szbi-quiz-question {
  margin: 0;
  font-size: 17px;
  line-height: 1.45;
  color: #f8fafc;
}

.szbi-quiz-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.szbi-quiz-option-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  background-color: #1e293b;
  color: #f1f5f9;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 14px;
  line-height: 1.4;
  text-transform: none;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.szbi-quiz-option-btn:hover {
  background-color: #334155;
  border-color: #38bdf8;
}

.szbi-quiz-option-btn.opt-correct {
  background-color: rgba(6, 78, 59, 0.92);
  border-color: #10b981;
  color: #ecfdf5;
}

.szbi-quiz-option-btn.opt-wrong {
  background-color: rgba(127, 29, 29, 0.92);
  border-color: #ef4444;
  color: #fef2f2;
}

.szbi-quiz-option-btn.opt-dimmed {
  opacity: 0.65;
}

.szbi-opt-letter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 26px;
  height: 26px;
  border-radius: 6px;
  background-color: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.4);
  font-weight: 700;
  font-size: 12px;
}

.szbi-opt-text {
  flex: 1;
}

.szbi-opt-badge {
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.szbi-quiz-feedback {
  border-radius: 10px;
  padding: 12px 14px;
  border: 1px solid rgba(148, 163, 184, 0.3);
}

.szbi-feedback-idle {
  background-color: rgba(30, 41, 59, 0.72);
}

.szbi-feedback-correct {
  background-color: rgba(6, 78, 59, 0.75);
  border-color: #10b981;
}

.szbi-feedback-wrong {
  background-color: rgba(127, 29, 29, 0.72);
  border-color: #ef4444;
}

.szbi-quiz-feedback-title {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 4px;
}

.szbi-quiz-feedback-desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  color: #e2e8f0;
}

.szbi-quiz-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
  padding-top: 12px;
}

.szbi-quiz-nav-btns {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

@media (max-width: 640px) {
  .szbi-quiz-nav-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

.szbi-btn-gold {
  background-color: rgba(180, 83, 9, 0.88);
  border-color: #fbbf24;
  color: #fef3c7;
}

.szbi-btn-gold:hover {
  background-color: rgba(217, 119, 6, 0.96);
}

.szbi-badge-gold {
  background-color: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  border-color: rgba(251, 191, 36, 0.45);
}

/* Firebase Real-Time Leaderboard Modal */
.szbi-lb-shell {
  background-color: #0f172a;
  border: 1px solid #fbbf24;
  border-radius: 16px;
  width: 100%;
  max-width: 880px;
  max-height: 88vh;
  overflow-y: auto;
  padding: 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.85);
  color: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.szbi-lb-authbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  background-color: rgba(2, 6, 23, 0.8);
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 10px;
  padding: 10px 14px;
}

.szbi-lb-auth-info {
  font-size: 13px;
  color: #e2e8f0;
  flex: 1;
  min-width: 240px;
}

.szbi-lb-auth-sub {
  color: #94a3b8;
  font-size: 12px;
  margin-left: 6px;
}

.szbi-lb-auth-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.szbi-lb-sync-note {
  background-color: rgba(6, 78, 59, 0.65);
  border: 1px solid #10b981;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 13px;
  color: #ecfdf5;
}

.szbi-lb-error {
  background-color: rgba(127, 29, 29, 0.72);
  border: 1px solid #ef4444;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 13px;
  color: #fef2f2;
}

.szbi-lb-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.szbi-lb-table-wrap {
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 12px;
  overflow: hidden;
  background-color: rgba(2, 6, 23, 0.65);
}

.szbi-lb-rows {
  display: flex;
  flex-direction: column;
  max-height: 44vh;
  overflow-y: auto;
}

.szbi-lb-row {
  display: grid;
  grid-template-columns: 56px minmax(180px, 1.8fr) 135px 115px 86px 145px;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
  font-size: 13px;
}

.szbi-lb-row:last-child {
  border-bottom: none;
}

.szbi-lb-head {
  background-color: #1e293b;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
  border-bottom: 1px solid rgba(148, 163, 184, 0.28);
}

.szbi-lb-row.is-own {
  background-color: rgba(14, 165, 233, 0.18);
  box-shadow: inset 3px 0 0 #38bdf8;
}

.szbi-lb-col-name {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.szbi-lb-col-name small {
  color: #94a3b8;
  font-size: 11px;
}

.szbi-lb-col-score small {
  color: #94a3b8;
}

.szbi-lb-col-time {
  font-weight: 700;
  color: #34d399;
}

.szbi-lb-col-cert code {
  font-size: 11px;
  color: #cbd5e1;
}

.szbi-lb-rank-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  padding: 2px 6px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 12px;
  background-color: rgba(51, 65, 85, 0.8);
  color: #e2e8f0;
}

.szbi-lb-rank-pill.rank-1 {
  background-color: rgba(234, 179, 8, 0.25);
  border: 1px solid #facc15;
  color: #fde047;
}

.szbi-lb-rank-pill.rank-2 {
  background-color: rgba(148, 163, 184, 0.25);
  border: 1px solid #cbd5e1;
  color: #f1f5f9;
}

.szbi-lb-rank-pill.rank-3 {
  background-color: rgba(217, 119, 6, 0.25);
  border: 1px solid #f59e0b;
  color: #fcd34d;
}

.szbi-lb-track-emp {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  background-color: rgba(14, 165, 233, 0.2);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.35);
}

.szbi-lb-track-mgr {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  background-color: rgba(139, 92, 246, 0.2);
  color: #c4b5fd;
  border: 1px solid rgba(167, 139, 250, 0.35);
}

.szbi-lb-empty {
  padding: 24px 16px;
  text-align: center;
  color: #94a3b8;
  font-size: 13px;
}

@media (max-width: 720px) {
  .szbi-lb-row {
    grid-template-columns: 44px 1fr 90px 70px;
  }
  .szbi-lb-col-track,
  .szbi-lb-col-cert {
    display: none;
  }
}

/* Top-right Download / Install Icon Button & Install Package Modal */
#szbi-floating-download-btn {
  position: fixed;
  top: 14px;
  right: 16px;
  z-index: 45;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: rgba(15, 23, 42, 0.94);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.55);
  border-radius: 9999px;
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 700;
  text-transform: none;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.55);
  transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

#szbi-floating-download-btn:hover {
  background-color: rgba(2, 132, 199, 0.92);
  color: #ffffff;
  border-color: #7dd3fc;
  transform: translateY(-1px);
}

.szbi-btn-install {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: rgba(15, 118, 110, 0.9);
  border-color: #2dd4bf;
  color: #f0fdfa;
}

.szbi-btn-install:hover {
  background-color: rgba(13, 148, 136, 0.98);
}

.szbi-dl-svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

.szbi-dl-svg-lg {
  width: 28px;
  height: 28px;
  color: #34d399;
}

.szbi-offline-hidden {
  display: none;
}

.szbi-offline-visible {
  position: fixed;
  top: 14px;
  left: 16px;
  z-index: 45;
  background-color: rgba(180, 83, 9, 0.95);
  color: #fef3c7;
  border: 1px solid #fbbf24;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
}

.szbi-install-shell {
  background-color: #0f172a;
  border: 1px solid #38bdf8;
  border-radius: 16px;
  width: 100%;
  max-width: 740px;
  max-height: 88vh;
  overflow-y: auto;
  padding: 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.85);
  color: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.szbi-install-cards {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.szbi-install-card {
  background-color: rgba(2, 6, 23, 0.78);
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.szbi-install-card-primary {
  border-color: rgba(52, 211, 153, 0.45);
}

.szbi-install-card-head {
  display: flex;
  align-items: center;
  gap: 14px;
}

.szbi-install-card-head h3 {
  margin: 0 0 4px 0;
  font-size: 15px;
  color: #f8fafc;
}

.szbi-install-desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  color: #cbd5e1;
}

.szbi-app-icon-preview {
  width: 54px;
  height: 54px;
  border-radius: 12px;
  border: 1px solid rgba(56, 189, 248, 0.45);
  flex-shrink: 0;
}

.szbi-zip-icon-box {
  width: 54px;
  height: 54px;
  border-radius: 12px;
  background-color: rgba(16, 185, 129, 0.14);
  border: 1px solid rgba(52, 211, 153, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.szbi-install-full-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 10px 14px;
  font-size: 13px;
}

.szbi-ios-guide {
  background-color: rgba(30, 41, 59, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 12px;
  line-height: 1.5;
  color: #e2e8f0;
}

.szbi-zip-progress-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.szbi-zip-progress-track {
  width: 100%;
  height: 8px;
  border-radius: 9999px;
  background-color: rgba(30, 41, 59, 0.9);
  overflow: hidden;
}

.szbi-zip-progress-fill {
  width: 0%;
  height: 100%;
  background-color: #10b981;
  transition: width 0.15s ease;
}

.szbi-zip-progress-label {
  font-size: 12px;
  color: #34d399;
}

/* ============================================================================
   CLEAN READABLE DESKTOP PORTAL VIEW (HIGH CONTRAST, SPACIOUS TYPOGRAPHY)
   ============================================================================ */
#szbi-portal-root {
  position: fixed;
  inset: 0;
  z-index: 35;
  background-color: #060b16;
  color: #f8fafc;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: 'Google Sans', 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

.portal-topbar {
  height: 64px;
  flex-shrink: 0;
  background-color: #0b1324;
  border-bottom: 1px solid #1e293b;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.portal-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.portal-brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.portal-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.portal-brand-text strong {
  font-size: 16px;
  color: #f8fafc;
}

.portal-brand-text span {
  font-size: 12px;
  color: #94a3b8;
}

.portal-top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.portal-user-pill {
  background-color: #162033;
  border: 1px solid #293548;
  color: #cbd5e1;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
}

.portal-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 9px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  text-transform: none;
  border: 1px solid transparent;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.portal-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.portal-btn-primary {
  background-color: #0284c7;
  color: #ffffff;
  border-color: #38bdf8;
}

.portal-btn-primary:hover:not(:disabled) {
  background-color: #0ea5e9;
}

.portal-btn-success {
  background-color: #059669;
  color: #ffffff;
  border-color: #34d399;
}

.portal-btn-success:hover:not(:disabled) {
  background-color: #10b981;
}

.portal-btn-teal {
  background-color: #0f766e;
  color: #f0fdfa;
  border-color: #2dd4bf;
}

.portal-btn-teal:hover:not(:disabled) {
  background-color: #0d9488;
}

.portal-btn-outline {
  background-color: #162033;
  color: #e2e8f0;
  border-color: #334155;
}

.portal-btn-outline:hover:not(:disabled) {
  background-color: #1e293b;
  border-color: #38bdf8;
}

.portal-layout {
  flex: 1;
  min-height: 0;
  display: flex;
}

.portal-sidebar {
  width: 280px;
  flex-shrink: 0;
  background-color: #0b1324;
  border-right: 1px solid #1e293b;
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  overflow-y: auto;
}

.portal-progress-card {
  background: linear-gradient(145deg, #111c34 0%, #0f172a 100%);
  border: 1px solid #1e293b;
  border-radius: 12px;
  padding: 13px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.portal-progress-card.is-complete {
  border-color: rgba(16, 185, 129, 0.45);
  background: linear-gradient(145deg, rgba(6, 78, 59, 0.35) 0%, #0f172a 100%);
}

.portal-progress-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.portal-progress-title {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.07em;
  color: #94a3b8;
}

.portal-progress-pct {
  font-size: 13px;
  font-weight: 800;
  color: #38bdf8;
  background-color: rgba(14, 165, 233, 0.14);
  border: 1px solid rgba(56, 189, 248, 0.32);
  border-radius: 999px;
  padding: 1px 8px;
  font-variant-numeric: tabular-nums;
}

.portal-progress-card.is-complete .portal-progress-pct {
  color: #34d399;
  background-color: rgba(16, 185, 129, 0.16);
  border-color: rgba(52, 211, 153, 0.4);
}

.portal-progress-track {
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background-color: #1e293b;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.45);
}

.portal-progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #0ea5e9 0%, #6366f1 100%);
  transition: width 0.35s cubic-bezier(0.22, 1, 0.36, 1), background 0.3s ease;
}

.portal-progress-fill.is-complete {
  background: linear-gradient(90deg, #10b981 0%, #34d399 100%);
}

.portal-progress-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 11px;
  color: #cbd5e1;
  line-height: 1.35;
}

.portal-progress-status {
  font-size: 11px;
  color: #94a3b8;
}

.portal-progress-card.is-complete .portal-progress-status {
  color: #6ee7b7;
  font-weight: 600;
}

.portal-progress-parts {
  margin-top: 2px;
  padding-top: 6px;
  border-top: 1px solid rgba(51, 65, 85, 0.65);
  font-size: 10.5px;
  color: #94a3b8;
}

.portal-btn-snapshot {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.18), rgba(99, 102, 241, 0.22));
  border: 1px solid rgba(56, 189, 248, 0.45);
  color: #e0f2fe;
}

.portal-btn-snapshot:hover {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.32), rgba(99, 102, 241, 0.34));
  color: #ffffff;
}

.portal-btn-snapshot.is-saved {
  background: rgba(16, 185, 129, 0.24);
  border-color: rgba(52, 211, 153, 0.6);
  color: #a7f3d0;
}

.portal-snapshot-card {
  background-color: #0f172a;
  border: 1px solid #1e293b;
  border-radius: 12px;
  padding: 11px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.portal-snapshot-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.portal-snapshot-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #94a3b8;
}

.portal-live-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.portal-snapshot-clock {
  font-size: 10px;
  color: #64748b;
  font-variant-numeric: tabular-nums;
}

.portal-snapshot-actions-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px;
}

.portal-snap-primary-btn {
  background: linear-gradient(135deg, #0284c7, #4f46e5);
  color: #ffffff;
  border: 1px solid rgba(56, 189, 248, 0.45);
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  text-transform: none;
}

.portal-snap-primary-btn:hover {
  filter: brightness(1.1);
}

.portal-snap-toggle-btn {
  background-color: #162033;
  color: #cbd5e1;
  border: 1px solid #334155;
  border-radius: 8px;
  padding: 6px 8px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  text-transform: none;
}

.portal-snap-toggle-btn:hover {
  background-color: #1e293b;
  color: #ffffff;
}

.portal-snapshot-notice {
  font-size: 11px;
  line-height: 1.35;
  color: #6ee7b7;
  background-color: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: 7px;
  padding: 6px 8px;
}

.portal-snapshot-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 6px;
  border-top: 1px solid #1e293b;
  max-height: 220px;
  overflow-y: auto;
}

.portal-snapshot-empty {
  font-size: 11px;
  color: #64748b;
  line-height: 1.4;
}

.portal-snapshot-item {
  background-color: #131f38;
  border: 1px solid #24324d;
  border-radius: 8px;
  padding: 7px 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.portal-snapshot-item-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.portal-snapshot-item-info strong {
  font-size: 11.5px;
  color: #e2e8f0;
}

.portal-snapshot-item-info span {
  font-size: 10.5px;
  color: #94a3b8;
}

.portal-snapshot-item-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.portal-snap-mini-btn {
  background-color: #1e293b;
  color: #cbd5e1;
  border: 1px solid #334155;
  border-radius: 6px;
  padding: 3px 7px;
  font-size: 10.5px;
  font-weight: 600;
  cursor: pointer;
  text-transform: none;
}

.portal-snap-mini-btn:hover {
  background-color: #334155;
  color: #ffffff;
}

.portal-snap-mini-btn.is-restore {
  background-color: rgba(14, 165, 233, 0.16);
  border-color: rgba(56, 189, 248, 0.45);
  color: #7dd3fc;
}

.portal-snap-mini-btn.is-restore:hover {
  background-color: rgba(14, 165, 233, 0.3);
  color: #ffffff;
}

.portal-snap-mini-btn.is-del {
  margin-left: auto;
  color: #fda4af;
}

.portal-snapshot-upload-btn {
  display: block;
  text-align: center;
  font-size: 11px;
  font-weight: 600;
  color: #94a3b8;
  border: 1px dashed #334155;
  border-radius: 7px;
  padding: 6px 8px;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.portal-snapshot-upload-btn:hover {
  border-color: #38bdf8;
  color: #e2e8f0;
}

.portal-subnav-video-tag {
  margin-left: auto;
  font-size: 9px;
  color: #f87171;
  background-color: rgba(239, 68, 68, 0.14);
  border: 1px solid rgba(248, 113, 113, 0.3);
  border-radius: 4px;
  padding: 1px 5px;
  flex-shrink: 0;
}

/* YouTube Educational Video Module Section */
.portal-video-section {
  border-color: rgba(56, 189, 248, 0.32);
  background: linear-gradient(155deg, #0d182d 0%, #0a1222 100%);
}

.portal-video-subtitle {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: #94a3b8;
}

.portal-video-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 12px;
}

.portal-video-grid.is-single {
  grid-template-columns: minmax(0, 640px);
}

.portal-video-card {
  background-color: #081020;
  border: 1px solid #1e293b;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.portal-video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: #020617;
  overflow: hidden;
}

.portal-video-iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.portal-video-thumb-btn {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: #020617;
  cursor: pointer;
  overflow: hidden;
}

.portal-video-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0.88;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.portal-video-thumb-btn:hover .portal-video-thumb-img {
  transform: scale(1.03);
  opacity: 1;
}

.portal-video-play-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 42px;
  border-radius: 12px;
  background-color: rgba(220, 38, 38, 0.92);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.5);
  transition: transform 0.18s ease, background-color 0.18s ease;
}

.portal-video-thumb-btn:hover .portal-video-play-badge {
  transform: translate(-50%, -50%) scale(1.08);
  background-color: #ef4444;
}

.portal-video-thumb-chip {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background-color: rgba(2, 6, 23, 0.82);
  color: #e2e8f0;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 700;
}

.portal-video-body {
  padding: 13px 14px 15px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.portal-video-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.portal-video-channel {
  font-size: 11.5px;
  font-weight: 700;
  color: #38bdf8;
}

.portal-video-ext-link {
  font-size: 11.5px;
  font-weight: 600;
  color: #94a3b8;
  text-decoration: none;
}

.portal-video-ext-link:hover {
  color: #f8fafc;
  text-decoration: underline;
}

.portal-video-title {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.35;
  color: #f8fafc;
}

.portal-video-desc {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.45;
  color: #94a3b8;
}

@media (max-width: 900px) {
  .portal-video-grid {
    grid-template-columns: 1fr;
  }
}

.portal-sidebar-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.portal-sidebar-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #64748b;
  padding: 0 8px 4px 8px;
}

.portal-nav-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background-color: transparent;
  color: #cbd5e1;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 9px 12px;
  font-size: 14px;
  font-weight: 600;
  text-align: left;
  text-transform: none;
}

.portal-nav-btn:hover {
  background-color: #162033;
  color: #ffffff;
}

.portal-nav-btn.is-active {
  background-color: rgba(14, 165, 233, 0.16);
  border-color: rgba(56, 189, 248, 0.5);
  color: #38bdf8;
}

.portal-nav-badge {
  background-color: #1e293b;
  color: #94a3b8;
  border-radius: 6px;
  padding: 2px 7px;
  font-size: 11px;
  font-weight: 700;
}

.portal-subnav-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-left: 8px;
  margin-top: 2px;
}

.portal-subnav-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  background-color: transparent;
  color: #94a3b8;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 7px 10px;
  font-size: 13px;
  text-align: left;
  text-transform: none;
}

.portal-subnav-btn:hover {
  background-color: #162033;
  color: #f8fafc;
}

.portal-subnav-btn.is-active {
  background-color: #162033;
  border-color: #334155;
  color: #ffffff;
  font-weight: 600;
}

.portal-subnav-dot {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background-color: #1e293b;
  color: #cbd5e1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}

.portal-subnav-btn.is-done .portal-subnav-dot {
  background-color: rgba(16, 185, 129, 0.22);
  color: #34d399;
}

.portal-subnav-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.portal-sidebar-footer {
  margin-top: auto;
  background-color: #0f172a;
  border: 1px solid #1e293b;
  border-radius: 10px;
  padding: 12px;
  font-size: 12px;
  line-height: 1.5;
  color: #94a3b8;
}

.portal-sidebar-footer code {
  color: #38bdf8;
}

.portal-main {
  flex: 1;
  overflow-y: auto;
  padding: 28px 36px 48px 36px;
}

.portal-container {
  max-width: 920px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.portal-page-header h1 {
  margin: 10px 0 6px 0;
  font-size: 26px;
  line-height: 1.3;
  font-weight: 700;
  color: #f8fafc;
}

.portal-subtitle {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: #cbd5e1;
}

.portal-legal-note {
  margin-top: 8px;
  font-size: 13px;
  color: #a78bfa;
  font-weight: 500;
}

.portal-pills-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.portal-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid transparent;
}

.pill-blue {
  background-color: rgba(14, 165, 233, 0.16);
  color: #7dd3fc;
  border-color: rgba(56, 189, 248, 0.38);
}

.pill-purple {
  background-color: rgba(139, 92, 246, 0.16);
  color: #c4b5fd;
  border-color: rgba(167, 139, 250, 0.38);
}

.pill-green {
  background-color: rgba(16, 185, 129, 0.16);
  color: #6ee7b7;
  border-color: rgba(52, 211, 153, 0.38);
}

.pill-amber {
  background-color: rgba(245, 158, 11, 0.16);
  color: #fcd34d;
  border-color: rgba(251, 191, 36, 0.38);
}

.pill-slate {
  background-color: #162033;
  color: #cbd5e1;
  border-color: #334155;
}

.portal-card {
  background-color: #0f172a;
  border: 1px solid #1e293b;
  border-radius: 14px;
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.portal-card h2,
.portal-card h3 {
  margin: 0;
  font-size: 17px;
  color: #f8fafc;
}

.portal-card-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.portal-points-list {
  margin: 0;
  padding-left: 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 15px;
  line-height: 1.6;
  color: #e2e8f0;
}

.portal-scenario-card {
  background-color: #131c31;
  border-color: rgba(245, 158, 11, 0.38);
}

.portal-scenario-card h3 {
  color: #fcd34d;
}

.portal-scenario-card p {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: #e2e8f0;
}

.portal-question-lead {
  margin: 0;
  font-size: 18px;
  line-height: 1.5;
  font-weight: 600;
  color: #ffffff;
}

.portal-options-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.portal-option-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 16px;
  background-color: #162033;
  border: 1px solid #293548;
  border-radius: 10px;
  color: #f1f5f9;
  font-size: 15px;
  line-height: 1.45;
  text-align: left;
  text-transform: none;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.portal-option-btn:hover {
  background-color: #1e293b;
  border-color: #38bdf8;
}

.portal-option-btn.is-correct {
  background-color: rgba(6, 78, 59, 0.85);
  border-color: #10b981;
  color: #ecfdf5;
}

.portal-option-btn.is-wrong {
  background-color: rgba(127, 29, 29, 0.85);
  border-color: #ef4444;
  color: #fef2f2;
}

.portal-opt-letter {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background-color: #0b1324;
  border: 1px solid #334155;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}

.portal-feedback {
  border-radius: 10px;
  padding: 14px 16px;
  border: 1px solid #334155;
  font-size: 14px;
  line-height: 1.55;
}

.portal-feedback strong {
  display: block;
  margin-bottom: 4px;
}

.portal-feedback p {
  margin: 0;
  color: #e2e8f0;
}

.portal-feedback.is-idle {
  background-color: #162033;
}

.portal-feedback.is-correct {
  background-color: rgba(6, 78, 59, 0.65);
  border-color: #10b981;
}

.portal-feedback.is-wrong {
  background-color: rgba(127, 29, 29, 0.65);
  border-color: #ef4444;
}

.portal-exam-grid {
  display: grid;
  grid-template-columns: repeat(15, minmax(0, 1fr));
  gap: 6px;
}

.portal-exam-grid.is-25 {
  grid-template-columns: repeat(13, minmax(0, 1fr));
}

.portal-step-pill {
  background-color: #162033;
  color: #cbd5e1;
  border: 1px solid #334155;
  border-radius: 8px;
  padding: 8px 0;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}

.portal-step-pill.is-active {
  border-color: #38bdf8;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.35);
}

.portal-step-pill.is-correct {
  background-color: #059669;
  border-color: #34d399;
  color: #ffffff;
}

.portal-step-pill.is-wrong {
  background-color: #dc2626;
  border-color: #f87171;
  color: #ffffff;
}

.portal-footer-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.portal-btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.portal-cert-spread {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.portal-cert-side-card {
  padding: 16px;
  align-items: center;
  gap: 12px;
}

.portal-cert-side-label {
  font-size: 13px;
  font-weight: 700;
  color: #7dd3fc;
  text-align: center;
}

.portal-cert-preview-card {
  padding: 16px;
  align-items: center;
}

.portal-cert-img {
  width: 100%;
  max-width: 540px;
  border-radius: 10px;
  border: 1px solid #334155;
  background-color: #ffffff;
}

.portal-lb-auth-card {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}

.portal-lb-auth-text {
  font-size: 14px;
  color: #e2e8f0;
  flex: 1;
  min-width: 240px;
}

.portal-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.portal-kpi-card {
  background-color: #0f172a;
  border: 1px solid #1e293b;
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.portal-kpi-card span {
  font-size: 12px;
  color: #94a3b8;
  font-weight: 600;
}

.portal-kpi-card strong {
  font-size: 24px;
  color: #f8fafc;
}

.portal-table-card {
  overflow-x: auto;
}

.portal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.portal-table th,
.portal-table td {
  padding: 10px 12px;
  border-bottom: 1px solid #1e293b;
  text-align: left;
  vertical-align: top;
}

.portal-table th {
  color: #94a3b8;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.portal-table tr.is-own-row {
  background-color: rgba(14, 165, 233, 0.14);
}

.portal-empty-msg {
  margin: 0;
  padding: 18px;
  text-align: center;
  color: #94a3b8;
  font-size: 14px;
}

#portal-return-2d-btn {
  position: fixed;
  top: 14px;
  left: 16px;
  z-index: 45;
  background-color: rgba(15, 23, 42, 0.94);
  color: #f8fafc;
  border: 1px solid #38bdf8;
  border-radius: 9999px;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 600;
  text-transform: none;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

#portal-return-2d-btn:hover {
  background-color: #0284c7;
}

/* Rich Educational Curriculum Styles */
.portal-objectives-card {
  background-color: #0d182d;
  border-color: rgba(56, 189, 248, 0.42);
}

.portal-objectives-list {
  margin: 0;
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 14px;
  line-height: 1.55;
  color: #e2e8f0;
}

.portal-lessons-stack {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.portal-lesson-card {
  gap: 14px;
}

.portal-lesson-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  border-bottom: 1px solid #1e293b;
  padding-bottom: 12px;
}

.portal-lesson-head h3 {
  font-size: 18px;
  line-height: 1.35;
  color: #f8fafc;
}

.portal-lesson-summary {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: #93c5fd;
}

.portal-lesson-details {
  margin: 0;
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 14.5px;
  line-height: 1.62;
  color: #e2e8f0;
}

.portal-redflags-box {
  background-color: rgba(127, 29, 29, 0.28);
  border: 1px solid rgba(248, 113, 113, 0.42);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 13.5px;
  line-height: 1.55;
  color: #fecaca;
}

.portal-redflags-box strong {
  display: block;
  margin-bottom: 6px;
  color: #fca5a5;
}

.portal-redflags-box ul {
  margin: 0;
  padding-left: 18px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.portal-checklist-box {
  background-color: rgba(6, 78, 59, 0.24);
  border: 1px solid rgba(52, 211, 153, 0.38);
  border-radius: 10px;
  padding: 12px 16px;
}

.portal-checklist-box strong {
  display: block;
  margin-bottom: 8px;
  font-size: 13.5px;
  color: #6ee7b7;
}

.portal-checklist-items {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.portal-check-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  line-height: 1.45;
  color: #e2e8f0;
  cursor: pointer;
}

.portal-check-item input[type='checkbox'] {
  margin-top: 3px;
  width: 16px;
  height: 16px;
  accent-color: #10b981;
  flex-shrink: 0;
  cursor: pointer;
}

.portal-check-item.is-checked span {
  color: #a7f3d0;
}

.portal-matrix-table .portal-cell-wrong {
  color: #fca5a5;
}

.portal-matrix-table .portal-cell-correct {
  color: #6ee7b7;
}

.portal-glossary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.portal-glossary-item {
  background-color: #162033;
  border: 1px solid #293548;
  border-radius: 10px;
  padding: 12px 14px;
}

.portal-glossary-item strong {
  display: block;
  margin-bottom: 4px;
  font-size: 14px;
  color: #38bdf8;
}

.portal-glossary-item p {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: #cbd5e1;
}

.portal-mini-stats {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: #94a3b8;
}

.portal-mini-nav-pills {
  display: flex;
  gap: 6px;
}

.portal-mini-pill {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background-color: #162033;
  border: 1px solid #334155;
  color: #cbd5e1;
  font-size: 13px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.portal-mini-pill.is-active {
  border-color: #38bdf8;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.35);
}

.portal-mini-pill.is-correct {
  background-color: #059669;
  border-color: #34d399;
  color: #ffffff;
}

.portal-mini-pill.is-wrong {
  background-color: #dc2626;
  border-color: #f87171;
  color: #ffffff;
}

/* Daily Workplace Application Examples & KRI/KSC Deep-Dive Compendium */
.portal-daily-examples-box {
  background-color: #0b192c;
  border: 1px solid rgba(56, 189, 248, 0.45);
  border-left: 4px solid #38bdf8;
  border-radius: 10px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.portal-daily-examples-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.portal-daily-examples-head strong {
  font-size: 14px;
  color: #7dd3fc;
}

.portal-daily-examples-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.portal-daily-example-card {
  background-color: #112239;
  border: 1px solid #1e3a5f;
  border-radius: 8px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.portal-daily-example-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  padding-bottom: 6px;
}

.portal-daily-role {
  font-size: 13px;
  font-weight: 700;
  color: #34d399;
}

.portal-daily-ref {
  font-size: 12px;
  color: #c4b5fd;
  background-color: rgba(139, 92, 246, 0.16);
  border: 1px solid rgba(167, 139, 250, 0.35);
  padding: 2px 8px;
  border-radius: 6px;
}

.portal-daily-situation {
  font-size: 13.5px;
  line-height: 1.52;
  color: #fde68a;
}

.portal-daily-situation strong {
  color: #fbbf24;
}

.portal-daily-practice {
  font-size: 13.5px;
  line-height: 1.55;
  color: #f1f5f9;
}

.portal-daily-practice strong {
  color: #6ee7b7;
}

.portal-deep-callout {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  background-color: #0d1f2d;
  border-color: rgba(20, 184, 166, 0.55);
}

.portal-deep-callout-text {
  flex: 1;
  min-width: 260px;
}

.portal-deep-callout-text strong {
  display: block;
  font-size: 15px;
  color: #5eead4;
  margin-bottom: 4px;
}

.portal-deep-callout-text p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.5;
  color: #cbd5e1;
}

.portal-deep-overview-card {
  background-color: #0d182d;
  border-color: rgba(56, 189, 248, 0.45);
  gap: 14px;
}

.portal-deep-overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.portal-deep-pillar {
  background-color: #132238;
  border: 1px solid #233854;
  border-radius: 10px;
  padding: 12px 14px;
}

.portal-deep-pillar strong {
  display: block;
  font-size: 14px;
  color: #38bdf8;
  margin-bottom: 4px;
}

.portal-deep-pillar p {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: #cbd5e1;
}

.portal-deep-tabs-bar {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.portal-deep-tab-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 10px;
  background-color: #162033;
  border: 1px solid #334155;
  color: #e2e8f0;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.portal-deep-tab-btn:hover {
  background-color: #1e293b;
  border-color: #475569;
}

.portal-deep-tab-btn.is-active {
  background-color: #0c4a6e;
  border-color: #38bdf8;
  color: #ffffff;
}

.portal-deep-tab-btn.is-done .portal-deep-tab-num {
  background-color: #059669;
  color: #ffffff;
}

.portal-deep-tab-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 24px;
  padding: 0 6px;
  border-radius: 6px;
  background-color: #0f172a;
  color: #7dd3fc;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}

.portal-deep-tab-label {
  line-height: 1.25;
}

/* ============================================================================
   SZBI OFFICER RECHARTS KPI VISUALIZATION COMPONENT
   ============================================================================ */
.szbi-kpi-dashboard-section {
  position: relative;
  background-color: #0b1426;
  border: 1px solid rgba(52, 211, 153, 0.38);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.szbi-kpi-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.szbi-kpi-title-wrap {
  flex: 1;
  min-width: 280px;
}

.szbi-kpi-title-wrap h2 {
  margin: 6px 0 4px 0;
  font-size: 19px;
  color: #f8fafc;
}

.szbi-kpi-subtitle {
  margin: 0;
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.45;
}

.szbi-kpi-controls {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.szbi-kpi-filter-group {
  display: inline-flex;
  background-color: #060b16;
  border: 1px solid #1e293b;
  border-radius: 9px;
  padding: 3px;
  gap: 4px;
}

.szbi-kpi-filter-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 11px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.szbi-kpi-filter-btn:hover {
  color: #f8fafc;
}

.szbi-kpi-filter-btn.is-active {
  background-color: #0284c7;
  color: #ffffff;
}

.szbi-kpi-action-btns {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.szbi-kpi-metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.szbi-kpi-metric-card {
  background-color: #0f1b31;
  border: 1px solid #1e293b;
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.szbi-kpi-metric-card.metric-green {
  border-left: 4px solid #34d399;
}

.szbi-kpi-metric-card.metric-blue {
  border-left: 4px solid #38bdf8;
}

.szbi-kpi-metric-card.metric-purple {
  border-left: 4px solid #a78bfa;
}

.szbi-kpi-metric-card.metric-teal {
  border-left: 4px solid #2dd4bf;
}

.szbi-kpi-metric-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.szbi-kpi-metric-label {
  font-size: 12px;
  font-weight: 700;
  color: #cbd5e1;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.szbi-kpi-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
}

.szbi-kpi-badge.badge-green {
  background-color: rgba(16, 185, 129, 0.18);
  color: #34d399;
}

.szbi-kpi-badge.badge-blue {
  background-color: rgba(14, 165, 233, 0.18);
  color: #38bdf8;
}

.szbi-kpi-badge.badge-purple {
  background-color: rgba(139, 92, 246, 0.2);
  color: #c4b5fd;
}

.szbi-kpi-badge.badge-teal {
  background-color: rgba(20, 184, 166, 0.18);
  color: #5eead4;
}

.szbi-kpi-metric-value {
  font-size: 26px;
  font-weight: 800;
  color: #f8fafc;
  line-height: 1.15;
}

.szbi-kpi-metric-value small {
  font-size: 13px;
  font-weight: 600;
  color: #94a3b8;
}

.szbi-kpi-metric-foot {
  font-size: 12px;
  color: #94a3b8;
  line-height: 1.4;
}

.szbi-recharts-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.szbi-chart-card {
  background-color: #081020;
  border: 1px solid #1e293b;
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.szbi-chart-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.szbi-chart-card-head h3 {
  margin: 0 0 3px 0;
  font-size: 15px;
  color: #f8fafc;
}

.szbi-chart-card-head p {
  margin: 0;
  font-size: 12px;
  color: #94a3b8;
}

.recharts-responsive-container {
  width: 100%;
}

.recharts-wrapper {
  position: relative;
  width: 100%;
}

.recharts-surface {
  width: 100%;
  height: auto;
  display: block;
  overflow: visible;
}

.recharts-bar-group,
.recharts-active-dot-group,
.recharts-pie-sector {
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.recharts-bar-group:hover .recharts-bar-item,
.recharts-pie-sector:hover {
  filter: brightness(1.18);
}

.recharts-legend-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(30, 41, 59, 0.8);
}

.recharts-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  color: #cbd5e1;
}

.recharts-legend-item i {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 3px;
}

.szbi-status-pie-grid {
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 24px;
  align-items: center;
}

.szbi-status-pie-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.szbi-status-pie-svg {
  max-width: 215px;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.35));
}

.szbi-status-pie-slice {
  cursor: pointer;
  transition: filter 0.18s ease, opacity 0.18s ease;
}

.szbi-status-pie-slice:hover {
  filter: brightness(1.14);
}

.szbi-status-pie-total {
  font-size: 12.5px;
  color: #94a3b8;
  background-color: #0f1b31;
  border: 1px solid #1e293b;
  border-radius: 999px;
  padding: 5px 14px;
}

.szbi-status-pie-total strong {
  color: #f8fafc;
}

.szbi-status-pie-breakdown {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.szbi-status-pie-item {
  background-color: #0f1b31;
  border: 1px solid #1e293b;
  border-radius: 10px;
  padding: 11px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.szbi-status-pie-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.szbi-status-pie-item-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  color: #f8fafc;
}

.szbi-status-pie-count {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.szbi-status-pie-item-sub {
  font-size: 12px;
  color: #94a3b8;
}

.szbi-status-pie-bar-track {
  width: 100%;
  height: 7px;
  border-radius: 999px;
  background-color: #1e293b;
  overflow: hidden;
}

.szbi-status-pie-bar-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.35s ease;
}

.recharts-donut-dept-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 20px;
  align-items: center;
}

.recharts-donut-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.recharts-donut-svg {
  max-width: 190px;
}

.recharts-donut-legend {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.recharts-donut-legend-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  color: #cbd5e1;
  background-color: #0f1b31;
  padding: 6px 10px;
  border-radius: 8px;
}

.recharts-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.recharts-donut-label {
  flex: 1;
}

.recharts-dept-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.recharts-dept-list-title {
  font-size: 13px;
  font-weight: 700;
  color: #38bdf8;
  margin-bottom: 2px;
}

.recharts-dept-row {
  background-color: #0f1b31;
  border: 1px solid #1e293b;
  border-radius: 9px;
  padding: 9px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.recharts-dept-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12.5px;
}

.recharts-dept-meta strong {
  color: #f8fafc;
}

.recharts-dept-meta span {
  color: #94a3b8;
  font-size: 12px;
}

.recharts-dept-bar-track {
  width: 100%;
  height: 7px;
  border-radius: 4px;
  background-color: #1e293b;
  overflow: hidden;
}

.recharts-dept-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #0ea5e9 0%, #34d399 100%);
  border-radius: 4px;
}

.recharts-tooltip-wrapper {
  position: absolute;
  z-index: 60;
  pointer-events: none;
  min-width: 245px;
  max-width: 310px;
}

.recharts-default-tooltip {
  background-color: #060d1b;
  border: 1px solid #38bdf8;
  border-radius: 10px;
  padding: 10px 12px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.75);
}

.recharts-tooltip-label {
  font-size: 13px;
  font-weight: 700;
  color: #f8fafc;
  margin-bottom: 2px;
}

.recharts-tooltip-sub {
  font-size: 11.5px;
  color: #94a3b8;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid #1e293b;
}

.recharts-tooltip-item-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.recharts-tooltip-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #cbd5e1;
}

.recharts-tooltip-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.recharts-tooltip-name {
  flex: 1;
}

.recharts-tooltip-value {
  color: #ffffff;
}

@media (max-width: 1100px) {
  .szbi-kpi-metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .szbi-recharts-grid,
  .szbi-status-pie-grid,
  .recharts-donut-dept-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .portal-layout {
    flex-direction: column;
  }
  .portal-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid #1e293b;
    padding: 12px 16px;
    max-height: 220px;
  }
  .portal-main {
    padding: 20px 16px 36px 16px;
  }
  .portal-kpi-grid,
  .szbi-kpi-metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .portal-exam-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
  .portal-cert-spread,
  .portal-deep-overview-grid,
  .portal-deep-tabs-bar {
    grid-template-columns: 1fr;
  }
  .portal-glossary-grid {
    grid-template-columns: 1fr;
  }
  .portal-user-pill {
    display: none;
  }
  .portal-copyright-bar {
    flex-direction: column;
    gap: 2px;
    padding: 8px 14px;
    text-align: center;
  }
  .szbi-signatory-cards,
  .szbi-attendance-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================================
   PORTAL COPYRIGHT BAR, SIGNATORY STAMP SELECTOR, BULK DELETE & PRINT A4
   ============================================================================ */
.portal-copyright-bar {
  flex-shrink: 0;
  background-color: #080f1f;
  border-top: 1px solid #1e293b;
  padding: 7px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 12px;
  color: #94a3b8;
}

.portal-copyright-bar span:first-child {
  font-weight: 600;
  color: #cbd5e1;
}

.portal-sidebar-owner {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px solid #1e293b;
  font-size: 11px;
  font-weight: 600;
  color: #38bdf8;
}

.portal-card-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.portal-signatory-bar {
  border-color: rgba(56, 189, 248, 0.4);
  background-color: #0d182d;
}

.portal-signatory-hint {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: #94a3b8;
}

.portal-signatory-hint strong {
  color: #f8fafc;
}

.szbi-signatory-select-box {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.szbi-signatory-select-box > label {
  font-size: 13px;
  font-weight: 600;
  color: #cbd5e1;
}

.szbi-signatory-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.szbi-signatory-choice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 13px 15px;
  border-radius: 10px;
  border: 1px solid #293548;
  background-color: #0b1426;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.szbi-signatory-choice:hover {
  border-color: #38bdf8;
  background-color: #111e37;
}

.szbi-signatory-choice.is-selected {
  border-color: #38bdf8;
  background-color: rgba(14, 165, 233, 0.14);
  box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.35);
}

.szbi-signatory-choice input[type='radio'] {
  margin-top: 3px;
  width: 16px;
  height: 16px;
  accent-color: #38bdf8;
  flex-shrink: 0;
}

.szbi-signatory-choice-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.szbi-signatory-choice-text strong {
  font-size: 14px;
  color: #f8fafc;
}

.szbi-signatory-choice-text span {
  font-size: 12px;
  color: #94a3b8;
}

.szbi-card-sub {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: #94a3b8;
}

.szbi-attendance-card {
  border-color: rgba(16, 185, 129, 0.38);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.szbi-attendance-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.szbi-dept-group-row td {
  background-color: #10203a !important;
  border-top: 2px solid #1e3a5f;
  border-bottom: 1px solid #1e3a5f;
  padding-top: 10px;
  padding-bottom: 10px;
}

.szbi-dept-group-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.szbi-dept-group-title {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.szbi-dept-group-title strong {
  font-size: 14px;
  color: #38bdf8;
}

.szbi-checkbox {
  width: 17px;
  height: 17px;
  accent-color: #38bdf8;
  cursor: pointer;
}

.szbi-select-all-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 9px;
  background-color: #162238;
  border: 1px solid #334155;
  color: #e2e8f0;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.szbi-row-selected td {
  background-color: rgba(14, 165, 233, 0.12) !important;
}

.szbi-row-cert-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.portal-btn-danger {
  background-color: #991b1b;
  border-color: #ef4444;
  color: #fef2f2;
}

.portal-btn-danger:hover:not(:disabled) {
  background-color: #b91c1c;
}

.portal-btn-danger:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.szbi-btn-sm {
  padding: 5px 10px;
  font-size: 12px;
  border-radius: 7px;
}

.szbi-delete-confirm-bar {
  margin: 12px 0;
  padding: 14px 16px;
  border-radius: 10px;
  background-color: rgba(127, 29, 29, 0.35);
  border: 1px solid #ef4444;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.szbi-delete-confirm-bar strong {
  color: #fecaca;
  font-size: 13.5px;
}

.szbi-delete-confirm-bar p {
  margin: 4px 0 0 0;
  color: #fee2e2;
  font-size: 12.5px;
}

/* Inline A4 Print Preview Modal */
#szbi-print-modal.szbi-print-modal-root {
  position: fixed;
  inset: 0;
  z-index: 90;
  background-color: rgba(2, 6, 23, 0.88);
  overflow-y: auto;
  padding: 24px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.szbi-print-sheet-wrap {
  width: 100%;
  max-width: 840px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.szbi-print-toolbar {
  background-color: #0f172a;
  border: 1px solid #38bdf8;
  border-radius: 12px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  color: #f8fafc;
}

.szbi-print-toolbar > div:first-child {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.szbi-print-toolbar strong {
  font-size: 14px;
}

.szbi-print-toolbar span {
  font-size: 12px;
  color: #94a3b8;
}

.szbi-a4-paper {
  background-color: #ffffff;
  color: #0f172a;
  border-radius: 6px;
  padding: 34px 36px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.65);
}

.szbi-a4-head {
  border-bottom: 2.5px solid #0f172a;
  padding-bottom: 10px;
  margin-bottom: 12px;
}

.szbi-a4-head h2 {
  margin: 0 0 4px 0;
  font-size: 18px;
  color: #0f172a;
}

.szbi-a4-head p {
  margin: 0;
  font-size: 13px;
  color: #334155;
}

.szbi-a4-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 12px;
  color: #1e293b;
  margin-bottom: 14px;
}

.szbi-a4-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.szbi-a4-table th,
.szbi-a4-table td {
  border: 1px solid #64748b;
  padding: 7px 8px;
  text-align: left;
  color: #0f172a;
}

.szbi-a4-table th {
  background-color: #e2e8f0;
  font-weight: 700;
}

.szbi-a4-sign-cell {
  height: 30px;
}

.szbi-a4-footer {
  margin-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
}

.szbi-a4-copyright {
  font-size: 10.5px;
  color: #475569;
}

.szbi-a4-stamp-block {
  text-align: center;
  min-width: 220px;
}

.szbi-a4-stamp-img {
  display: block;
  margin: 0 auto 6px auto;
  height: auto;
  max-height: 58mm;
  max-width: 100%;
  width: auto;
  object-fit: contain;
}

.szbi-a4-stamp-caption {
  border-top: 1px solid #334155;
  padding-top: 4px;
  font-size: 11px;
  color: #334155;
}

.szbi-a4-cert-page {
  width: 100%;
  max-width: 210mm;
  margin: 0 auto 18px auto;
  background: #ffffff;
  border-radius: 6px;
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.45);
  overflow: hidden;
  page-break-inside: avoid;
  break-inside: avoid;
}

.szbi-a4-cert-page:not(:last-child) {
  page-break-after: always;
  break-after: page;
}

.szbi-a4-cert-img {
  display: block;
  width: 100%;
  height: auto;
}

/* Invitation Email Draft Generator */
.szbi-email-draft-card {
  border-color: rgba(16, 185, 129, 0.36);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.96) 0%, rgba(12, 22, 39, 0.96) 100%);
  gap: 14px;
}

.szbi-email-draft-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  flex-wrap: wrap;
}

.szbi-email-subject-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.szbi-email-subject-row input {
  flex: 1;
  min-width: 0;
}

.szbi-email-textarea {
  width: 100%;
  background-color: #0b1220;
  border: 1px solid #334155;
  border-radius: 10px;
  padding: 14px 16px;
  color: #e2e8f0;
  font-family: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 13.5px;
  line-height: 1.58;
  resize: vertical;
  min-height: 240px;
  box-sizing: border-box;
}

.szbi-email-textarea:focus {
  outline: none;
  border-color: #38bdf8;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.18);
}

@media (max-width: 640px) {
  .szbi-email-subject-row {
    flex-direction: column;
  }
}

/* =========================================================
   Certificate Expiration Monitoring (< 30 days)
   ========================================================= */
.pill-amber {
  background-color: rgba(245, 158, 11, 0.18);
  color: #fcd34d;
  border: 1px solid rgba(245, 158, 11, 0.45);
}

.portal-btn-warn {
  background-color: rgba(245, 158, 11, 0.18);
  color: #fde68a;
  border: 1px solid rgba(245, 158, 11, 0.55);
}

.portal-btn-warn:hover:not(:disabled) {
  background-color: rgba(245, 158, 11, 0.32);
  color: #ffffff;
}

.szbi-expiry-monitor-card.has-alerts {
  border-color: rgba(245, 158, 11, 0.48);
  background: linear-gradient(180deg, rgba(45, 29, 10, 0.42) 0%, rgba(15, 23, 42, 0.96) 100%);
}

.szbi-expiry-monitor-card.is-clear {
  border-color: rgba(16, 185, 129, 0.36);
}

.szbi-expiry-controls {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.szbi-expiry-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.szbi-expiry-stat-box {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #334155;
  background-color: #0b1220;
}

.szbi-expiry-stat-box.is-warn {
  border-color: rgba(245, 158, 11, 0.45);
  background-color: rgba(245, 158, 11, 0.08);
}

.szbi-expiry-stat-box.is-expired {
  border-color: rgba(239, 68, 68, 0.45);
  background-color: rgba(239, 68, 68, 0.08);
}

.szbi-expiry-stat-box.is-valid {
  border-color: rgba(16, 185, 129, 0.4);
  background-color: rgba(16, 185, 129, 0.08);
}

.szbi-expiry-stat-num {
  font-size: 24px;
  font-weight: 800;
  line-height: 1.1;
}

.szbi-expiry-stat-box.is-warn .szbi-expiry-stat-num {
  color: #fbbf24;
}

.szbi-expiry-stat-box.is-expired .szbi-expiry-stat-num {
  color: #f87171;
}

.szbi-expiry-stat-box.is-valid .szbi-expiry-stat-num {
  color: #34d399;
}

.szbi-expiry-stat-lbl {
  font-size: 12px;
  color: #cbd5e1;
}

.szbi-expiry-alert-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(245, 158, 11, 0.48);
  background-color: rgba(120, 53, 15, 0.28);
}

.szbi-expiry-alert-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  color: #fef3c7;
  line-height: 1.45;
  flex: 1;
  min-width: 240px;
}

.szbi-expiry-ok-strip {
  padding: 11px 14px;
  border-radius: 10px;
  border: 1px solid rgba(16, 185, 129, 0.38);
  background-color: rgba(6, 78, 59, 0.24);
  color: #a7f3d0;
  font-size: 13px;
}

.portal-table tr.szbi-row-expiring-soon td {
  background-color: rgba(245, 158, 11, 0.11);
}

.portal-table tr.szbi-row-expiring-soon td:first-child {
  box-shadow: inset 4px 0 0 #f59e0b;
}

.portal-table tr.szbi-row-expired td {
  background-color: rgba(239, 68, 68, 0.12);
}

.portal-table tr.szbi-row-expired td:first-child {
  box-shadow: inset 4px 0 0 #ef4444;
}

.szbi-name-with-alert {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.szbi-cert-validity-line {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 4px;
  font-size: 11.5px;
  color: #cbd5e1;
}

.szbi-expiry-pill {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 2px 8px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.szbi-expiry-pill.is-warn {
  background-color: rgba(245, 158, 11, 0.22);
  color: #fde68a;
  border: 1px solid rgba(245, 158, 11, 0.55);
}

.szbi-expiry-pill.is-expired {
  background-color: rgba(239, 68, 68, 0.22);
  color: #fecaca;
  border: 1px solid rgba(239, 68, 68, 0.55);
}

.szbi-expiry-pill.is-valid {
  background-color: rgba(16, 185, 129, 0.15);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.35);
}

/* =========================================================
   SZBI Documentation Architecture Tab (Management / Board)
   ========================================================= */
.szbi-docs-pyramid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.szbi-docs-tier-card {
  border-radius: 12px;
  border: 1px solid #334155;
  background-color: #0b1220;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.szbi-docs-tier-card.is-level-1 {
  border-left: 4px solid #38bdf8;
}

.szbi-docs-tier-card.is-level-2 {
  border-left: 4px solid #818cf8;
}

.szbi-docs-tier-card.is-level-3 {
  border-left: 4px solid #fbbf24;
}

.szbi-docs-tier-card.is-level-4 {
  border-left: 4px solid #34d399;
}

.szbi-docs-tier-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  flex-wrap: wrap;
}

.szbi-docs-tier-code {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #38bdf8;
  margin-bottom: 4px;
}

.szbi-docs-tier-card.is-level-2 .szbi-docs-tier-code {
  color: #a5b4fc;
}

.szbi-docs-tier-card.is-level-3 .szbi-docs-tier-code {
  color: #fcd34d;
}

.szbi-docs-tier-card.is-level-4 .szbi-docs-tier-code {
  color: #6ee7b7;
}

.szbi-docs-tier-head h3 {
  margin: 0 0 4px 0;
  font-size: 17px;
  color: #f8fafc;
}

.szbi-docs-tier-sub {
  margin: 0;
  font-size: 13px;
  color: #94a3b8;
}

.szbi-docs-tier-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: #cbd5e1;
  background-color: rgba(30, 41, 59, 0.7);
  border: 1px solid #334155;
  border-radius: 8px;
  padding: 8px 12px;
  max-width: 390px;
}

.szbi-docs-tier-purpose {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.5;
  color: #e2e8f0;
}

.szbi-docs-items-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.szbi-docs-item-box {
  background-color: #111c30;
  border: 1px solid #24334d;
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.szbi-docs-item-top {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.szbi-docs-item-top strong {
  font-size: 13.5px;
  color: #f8fafc;
  line-height: 1.35;
}

.szbi-docs-legal-tag {
  display: inline-block;
  width: fit-content;
  font-size: 11px;
  font-weight: 600;
  color: #93c5fd;
  background-color: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.28);
  border-radius: 6px;
  padding: 2px 7px;
}

.szbi-docs-item-box p {
  margin: 0;
  font-size: 12.8px;
  line-height: 1.5;
  color: #cbd5e1;
}

.szbi-docs-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.szbi-docs-meta-card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background-color: #0b1220;
  border: 1px solid #26354d;
  border-radius: 10px;
  padding: 12px 14px;
}

.szbi-docs-meta-num {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background-color: rgba(56, 189, 248, 0.16);
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #7dd3fc;
  font-size: 12px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.szbi-docs-meta-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.szbi-docs-meta-body strong {
  font-size: 13.5px;
  color: #f8fafc;
}

.szbi-docs-meta-example {
  font-size: 12px;
  color: #94a3b8;
}

.szbi-docs-meta-example code {
  color: #6ee7b7;
  font-size: 11.5px;
}

.szbi-docs-meta-body p {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.48;
  color: #cbd5e1;
}

.szbi-docs-progress-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 14px;
  background-color: #0b1220;
  border: 1px solid #293548;
  border-radius: 10px;
}

.szbi-docs-progress-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: #cbd5e1;
}

.szbi-docs-progress-head strong {
  color: #38bdf8;
}

.szbi-docs-checklist-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.szbi-docs-check-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #26354d;
  background-color: #0b1220;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.szbi-docs-check-row:hover {
  border-color: #38bdf8;
}

.szbi-docs-check-row.is-checked {
  border-color: rgba(16, 185, 129, 0.45);
  background-color: rgba(6, 78, 59, 0.22);
}

.szbi-docs-check-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.szbi-docs-check-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  flex-wrap: wrap;
}

.szbi-docs-check-top strong {
  font-size: 13.5px;
  color: #f8fafc;
}

.szbi-docs-check-row.is-checked .szbi-docs-check-top strong {
  color: #a7f3d0;
}

.szbi-docs-check-tags {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.szbi-docs-check-content p {
  margin: 0;
  font-size: 12.8px;
  line-height: 1.48;
  color: #cbd5e1;
}

.szbi-raci-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
}

.szbi-raci-badge.is-a {
  background-color: rgba(239, 68, 68, 0.2);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.45);
}

.szbi-raci-badge.is-r {
  background-color: rgba(56, 189, 248, 0.2);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.45);
}

.szbi-raci-badge.is-c {
  background-color: rgba(245, 158, 11, 0.18);
  color: #fcd34d;
  border: 1px solid rgba(245, 158, 11, 0.42);
}

.szbi-raci-badge.is-i {
  background-color: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.35);
}

@media (max-width: 860px) {
  .szbi-docs-items-grid,
  .szbi-docs-meta-grid,
  .szbi-expiry-stats-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== ZERO-TRUST ACCESS GATE & 2FA TOKEN UI ===== */
.szbi-access-gate {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px 18px;
  overflow-y: auto;
  background: radial-gradient(circle at top, rgba(14, 165, 233, 0.14), transparent 55%),
    #060b16;
}

.szbi-gate-card {
  width: 100%;
  max-width: 640px;
  background-color: #0f172a;
  border: 1px solid #1e293b;
  border-radius: 18px;
  padding: 28px 30px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.szbi-gate-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.szbi-gate-brand {
  display: flex;
  align-items: center;
  gap: 16px;
}

.szbi-gate-logo {
  width: 58px;
  height: 58px;
  border-radius: 14px;
  flex-shrink: 0;
  border: 1px solid rgba(56, 189, 248, 0.35);
  background-color: #0b1220;
  padding: 6px;
}

.szbi-gate-brand h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.2;
  color: #f8fafc;
}

.szbi-gate-brand p {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: #94a3b8;
}

.szbi-gate-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 5px;
  background-color: #0b1220;
  border: 1px solid #1e293b;
  border-radius: 12px;
}

.szbi-gate-tab {
  border: 1px solid transparent;
  background-color: transparent;
  color: #94a3b8;
  padding: 10px 12px;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.szbi-gate-tab:hover {
  color: #f8fafc;
  background-color: #162033;
}

.szbi-gate-tab.is-active {
  background-color: rgba(14, 165, 233, 0.18);
  border-color: rgba(56, 189, 248, 0.45);
  color: #38bdf8;
}

.szbi-gate-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.szbi-gate-panel-intro h2 {
  margin: 0 0 6px 0;
  font-size: 18px;
  color: #f8fafc;
}

.szbi-gate-panel-intro p {
  margin: 0;
  font-size: 13.8px;
  line-height: 1.55;
  color: #cbd5e1;
}

.szbi-gate-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.szbi-gate-token-input {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important;
  font-size: 17px !important;
  font-weight: 700 !important;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 12px 14px !important;
  border-color: rgba(56, 189, 248, 0.45) !important;
  background-color: #070d19 !important;
  color: #7dd3fc !important;
}

.szbi-gate-submit-btn {
  width: 100%;
  justify-content: center;
  padding: 12px 18px !important;
  font-size: 14.5px !important;
}

.szbi-gate-error {
  padding: 12px 14px;
  border-radius: 10px;
  background-color: rgba(239, 68, 68, 0.14);
  border: 1px solid rgba(248, 113, 113, 0.45);
  color: #fecaca;
  font-size: 13.5px;
  line-height: 1.48;
  font-weight: 600;
}

.szbi-gate-ok-pill {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 11px 14px;
  border-radius: 10px;
  background-color: rgba(16, 185, 129, 0.14);
  border: 1px solid rgba(52, 211, 153, 0.42);
  color: #a7f3d0;
  font-size: 13px;
  line-height: 1.45;
}

.szbi-gate-ok-pill code {
  color: #ecfdf5;
  background-color: rgba(6, 78, 59, 0.55);
  padding: 1px 6px;
  border-radius: 5px;
}

.szbi-gate-hint {
  padding: 12px 14px;
  border-radius: 10px;
  background-color: #0b1220;
  border: 1px solid #1e293b;
  color: #94a3b8;
  font-size: 12.8px;
  line-height: 1.5;
}

.szbi-gate-security-box {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px;
  border-radius: 12px;
  background-color: #0b1220;
  border: 1px solid rgba(56, 189, 248, 0.28);
}

.szbi-gate-sec-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 13px;
  line-height: 1.45;
  color: #cbd5e1;
}

.szbi-gate-sec-item strong {
  color: #7dd3fc;
}

.szbi-gate-sec-item code {
  color: #34d399;
}

.szbi-token-pill-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding: 13px 16px;
  border-radius: 12px;
  background-color: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(52, 211, 153, 0.42);
}

.szbi-token-pill-label {
  display: block;
  font-size: 12px;
  color: #a7f3d0;
  font-weight: 600;
  margin-bottom: 4px;
}

.szbi-token-pill-code {
  display: inline-block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #ecfdf5;
  background-color: #064e3b;
  border: 1px solid rgba(52, 211, 153, 0.55);
  border-radius: 8px;
  padding: 4px 10px;
}

.szbi-row-token-meta {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 4px;
}

.szbi-token-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  font-size: 12px;
  padding: 2px 7px;
  border-radius: 6px;
  background-color: rgba(16, 185, 129, 0.14);
  border: 1px solid rgba(52, 211, 153, 0.35);
  color: #6ee7b7;
}

.szbi-token-chip code {
  color: #ecfdf5;
  font-weight: 700;
}

.szbi-inline-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 8px;
  background-color: #0b1220;
  border: 1px solid #334155;
  color: #e2e8f0;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
}

.szbi-logout-btn {
  border-color: rgba(248, 113, 113, 0.45) !important;
  color: #fca5a5 !important;
}

.szbi-logout-btn:hover {
  background-color: rgba(239, 68, 68, 0.16) !important;
  color: #fecaca !important;
}

@media (max-width: 640px) {
  .szbi-gate-card {
    padding: 20px 16px;
  }
  .szbi-gate-tabs {
    grid-template-columns: 1fr;
  }
}

/* =========================================================================
   PROGRESS OVERVIEW (RECHARTS DEPARTMENT COMPLETION & LAGGARD TRACKER)
   ========================================================================= */
.szbi-progress-overview-card {
  position: relative;
  border: 1px solid rgba(56, 189, 248, 0.28);
  background: linear-gradient(155deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.88));
}

.szbi-po-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 16px;
}

.szbi-po-header h2 {
  margin: 0 0 4px;
  font-size: 1.28rem;
  color: #f8fafc;
}

.szbi-po-summary-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.szbi-po-mini-kpi {
  background: rgba(30, 41, 59, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.szbi-po-mini-kpi span {
  font-size: 0.78rem;
  color: #94a3b8;
  font-weight: 600;
}

.szbi-po-mini-kpi strong {
  font-size: 1.38rem;
  color: #f8fafc;
  letter-spacing: -0.01em;
}

.szbi-po-alert-strip {
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.szbi-po-alert-strip.is-critical {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(248, 113, 113, 0.38);
}

.szbi-po-alert-strip.is-warning {
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(251, 191, 36, 0.35);
}

.szbi-po-alert-strip.is-healthy {
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.35);
}

.szbi-po-alert-copy {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  color: #e2e8f0;
}

.szbi-po-laggard-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.szbi-po-laggard-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px;
  border-radius: 8px;
  font-size: 0.8rem;
  cursor: pointer;
  border: 1px solid rgba(248, 113, 113, 0.45);
  background: rgba(15, 23, 42, 0.72);
  color: #fecaca;
  transition: transform 0.15s ease, background-color 0.15s ease;
}

.szbi-po-laggard-chip.is-warning {
  border-color: rgba(251, 191, 36, 0.45);
  color: #fde68a;
}

.szbi-po-laggard-chip:hover {
  transform: translateY(-1px);
  background: rgba(30, 41, 59, 0.95);
}

.szbi-po-chart-panel {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 14px;
  padding: 14px 16px;
  margin-bottom: 16px;
}

.szbi-po-chart-legend-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.szbi-po-chart-legend-row h3 {
  margin: 0;
  font-size: 0.98rem;
  color: #f1f5f9;
}

.szbi-po-chart-wrap {
  width: 100%;
  overflow-x: auto;
}

.szbi-po-bar-row:hover rect:first-child {
  fill: rgba(56, 189, 248, 0.12);
  stroke: rgba(56, 189, 248, 0.45);
}

.szbi-po-dept-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 12px;
}

.szbi-po-dept-card {
  background: rgba(30, 41, 59, 0.56);
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.szbi-po-dept-card.is-critical {
  border-left: 4px solid #f87171;
}

.szbi-po-dept-card.is-warning {
  border-left: 4px solid #f59e0b;
}

.szbi-po-dept-card.is-healthy {
  border-left: 4px solid #10b981;
}

.szbi-po-dept-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
}

.szbi-po-dept-card-head h4 {
  margin: 0 0 3px;
  font-size: 0.94rem;
  color: #f8fafc;
}

.szbi-po-dept-stats {
  font-size: 0.78rem;
  color: #94a3b8;
}

.szbi-po-dept-head-right {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.szbi-po-status-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
}

.szbi-po-status-badge.is-critical {
  background: rgba(239, 68, 68, 0.18);
  color: #fca5a5;
}

.szbi-po-status-badge.is-warning {
  background: rgba(245, 158, 11, 0.18);
  color: #fcd34d;
}

.szbi-po-status-badge.is-healthy {
  background: rgba(16, 185, 129, 0.18);
  color: #6ee7b7;
}

.szbi-po-member-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.szbi-po-member-item {
  background: rgba(15, 23, 42, 0.58);
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 8px;
  padding: 7px 10px;
}

.szbi-po-member-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.83rem;
  color: #f1f5f9;
  margin-bottom: 4px;
}

.szbi-po-member-item.is-done .szbi-po-member-pct {
  color: #34d399;
}

.szbi-po-member-item.is-active .szbi-po-member-pct {
  color: #38bdf8;
}

.szbi-po-member-item.is-idle .szbi-po-member-pct {
  color: #94a3b8;
}

.szbi-po-member-bar {
  height: 6px;
  background: rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 4px;
}

.szbi-po-member-bar span {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: #38bdf8;
}

.szbi-po-member-item.is-done .szbi-po-member-bar span {
  background: #10b981;
}

.szbi-po-member-item.is-idle .szbi-po-member-bar span {
  background: #475569;
}

.szbi-po-member-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.74rem;
  color: #94a3b8;
}

.szbi-table-progress-cell {
  min-width: 96px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.szbi-table-progress-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.82rem;
}

.szbi-table-progress-bar {
  height: 6px;
  width: 100%;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.18);
  overflow: hidden;
}

.szbi-table-progress-bar span {
  display: block;
  height: 100%;
  border-radius: 999px;
}

.szbi-dept-group-row.szbi-dept-highlight td {
  background: rgba(56, 189, 248, 0.22) !important;
  transition: background-color 0.35s ease;
}

@media (max-width: 900px) {
  .szbi-po-summary-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media print {
  @page {
    size: A4 portrait;
    margin: 0;
  }
  html,
  body {
    height: auto !important;
    overflow: visible !important;
    background: #ffffff !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  #szbi-portal-root,
  #szbi-install-modal,
  #szbi-offline-banner,
  .no-print {
    display: none !important;
  }
  #szbi-print-modal.szbi-print-modal-root {
    position: static !important;
    background: #ffffff !important;
    padding: 0 !important;
    overflow: visible !important;
  }
  .szbi-print-sheet-wrap {
    max-width: none !important;
    width: 100% !important;
    margin: 0 !important;
  }
  .szbi-a4-paper {
    box-shadow: none !important;
    padding: 12mm !important;
    border-radius: 0 !important;
    width: 100% !important;
    max-width: none !important;
  }
  .szbi-a4-cert-page {
    box-shadow: none !important;
    border-radius: 0 !important;
    margin: 0 !important;
    max-width: none !important;
    width: 210mm !important;
    height: 297mm !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    page-break-inside: avoid !important;
    break-inside: avoid !important;
  }
  .szbi-a4-cert-page:not(:last-child) {
    page-break-after: always !important;
    break-after: page !important;
  }
  .szbi-a4-cert-img {
    width: 100% !important;
    max-height: 297mm !important;
    object-fit: contain;
  }
}
