* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(59, 130, 246, 0.12), transparent 34%),
    linear-gradient(180deg, #f5f8ff 0%, #eef3fb 100%);
  color: #19212f;
}

body.theme-dark {
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.18), transparent 34%),
    linear-gradient(180deg, #020617 0%, #0f172a 100%);
  color: #e2e8f0;
}

a {
  color: #2448c9;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.layout-sidebar .shell {
  flex-direction: row;
  align-items: stretch;
}

.side-nav {
  width: 290px;
  background: rgba(255, 255, 255, 0.82);
  border-right: 1px solid rgba(148, 163, 184, 0.26);
  backdrop-filter: blur(18px);
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: auto;
}

body.theme-dark .side-nav {
  background: rgba(2, 6, 23, 0.72);
  border-right-color: rgba(148, 163, 184, 0.18);
}

.side-nav-top {
  display: grid;
  gap: 12px;
}

.side-search input {
  width: 100%;
}

.side-nav-links {
  display: grid;
  gap: 16px;
}

.side-nav-group {
  display: grid;
  gap: 10px;
}

.side-nav-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #64748b;
}

body.theme-dark .side-nav-label {
  color: #94a3b8;
}

.side-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 12px;
  border-radius: 14px;
  color: #0f172a;
  border: 1px solid transparent;
  background: rgba(15, 23, 42, 0.03);
}

.side-link:hover,
.side-link.active {
  background: rgba(37, 99, 235, 0.12);
  border-color: rgba(37, 99, 235, 0.18);
  color: #1d4ed8;
}

body.theme-dark .side-link {
  color: #e2e8f0;
  background: rgba(148, 163, 184, 0.06);
}

body.theme-dark .side-link:hover,
body.theme-dark .side-link.active {
  background: rgba(37, 99, 235, 0.22);
  border-color: rgba(191, 219, 254, 0.22);
  color: #fff;
}

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

body.theme-dark .side-nav-footer {
  border-top-color: rgba(148, 163, 184, 0.14);
}

.user-chip.compact {
  min-width: 0;
  padding: 10px 12px;
}

.side-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  z-index: 40;
}

.mobile-nav-toggle {
  display: none;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 18px 24px 0;
  backdrop-filter: blur(18px);
}

.app-header-inner {
  max-width: 1400px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.9);
  color: #0f172a;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 24px;
  padding: 16px 18px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 18px;
  align-items: center;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.brand-wrap {
  min-width: 220px;
}

.brand {
  display: inline-block;
  color: #0f172a;
  text-decoration: none;
  font-size: 24px;
  font-weight: 700;
}

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

.brand-logo,
.brand-fallback {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  object-fit: cover;
  background: rgba(37, 99, 235, 0.12);
}

.brand-fallback {
  display: inline-grid;
  place-items: center;
  font-size: 18px;
  font-weight: 700;
}

.brand-text {
  display: inline-block;
}

.brand-text small,
.brand-text .muted {
  color: #64748b;
}

.main-nav {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #475569;
  padding: 11px 14px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.04);
  border: 1px solid rgba(148, 163, 184, 0.08);
  transition: 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #1d4ed8;
  background: rgba(37, 99, 235, 0.12);
  border-color: rgba(37, 99, 235, 0.18);
}

.nav-icon,
.button svg,
.icon-button svg {
  width: 18px;
  height: 18px;
  display: inline-block;
  flex: 0 0 18px;
}

.nav-icon svg,
.button svg,
.icon-button svg {
  fill: currentColor;
}

.button i,
.icon-button i {
  font-size: 14px;
  line-height: 1;
}

.header-user {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
}

.user-chip {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.04);
  color: #0f172a;
  min-width: 180px;
}

.page-main {
  width: 100%;
}

.layout-sidebar .app-header {
  display: none;
}

.layout-sidebar .page-main {
  flex: 1;
  min-width: 0;
}

.theme-toggle .theme-icon-dark {
  display: none;
}

body.theme-dark .theme-toggle .theme-icon-light {
  display: none;
}

body.theme-dark .theme-toggle .theme-icon-dark {
  display: inline-flex;
}

.sidebar {
  background: linear-gradient(180deg, #0f172a 0%, #172554 100%);
  color: #fff;
  padding: 28px 22px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.brand {
  font-size: 24px;
  font-weight: 700;
}

.brand-subtitle {
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.5;
  margin-top: 10px;
}

.nav-links {
  display: grid;
  gap: 10px;
}

.nav-links a {
  color: #e2e8f0;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
}

.nav-links a:hover {
  background: rgba(255, 255, 255, 0.12);
}

.content {
  width: 100%;
  max-width: 1520px;
  margin: 0 auto;
  padding: 28px 18px 40px;
}

.layout-sidebar .content {
  max-width: 1560px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 20px;
}

.topbar-title {
  display: grid;
  gap: 4px;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 8px;
  color: #2563eb;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.topbar h1,
.hero h2,
.panel h3,
.feature-card h4,
.nominee-card h3 {
  margin: 0;
}

.alert {
  padding: 14px 18px;
  border-radius: 12px;
  font-weight: 600;
}

.alert-success {
  background: #dcfce7;
  color: #166534;
}

.alert-error {
  background: #fee2e2;
  color: #b91c1c;
}

body.theme-dark a {
  color: #93c5fd;
}

body.theme-dark .app-header-inner {
  background: rgba(2, 6, 23, 0.88);
  color: #fff;
}

body.theme-dark .brand {
  color: #fff;
}

body.theme-dark .brand-logo,
body.theme-dark .brand-fallback {
  background: rgba(255, 255, 255, 0.14);
}

body.theme-dark .brand-text small,
body.theme-dark .brand-text .muted {
  color: #94a3b8;
}

body.theme-dark .hero-copy,
body.theme-dark .hero-card,
body.theme-dark .panel,
body.theme-dark .winner-card,
body.theme-dark .nominee-edit-card,
body.theme-dark .nominee-card,
body.theme-dark .feature-card,
body.theme-dark .stat-card,
body.theme-dark .info-card,
body.theme-dark table,
body.theme-dark .modal-panel,
body.theme-dark .admin-card {
  background: #0f172a;
  color: #e2e8f0;
  box-shadow: 0 18px 45px rgba(2, 6, 23, 0.34);
}

body.theme-dark .print-report {
  background: #fff;
  color: #0f172a;
}

body.theme-dark .muted,
body.theme-dark .detail-list,
body.theme-dark .feature-card p,
body.theme-dark .nominee-card p,
body.theme-dark .empty-state p,
body.theme-dark small,
body.theme-dark .activity-item span,
body.theme-dark .activity-item small,
body.theme-dark .ranking-item small,
body.theme-dark .stat-card span,
body.theme-dark .info-card span,
body.theme-dark .countdown-card span,
body.theme-dark th {
  color: #94a3b8;
}

body.theme-dark input,
body.theme-dark textarea,
body.theme-dark select,
body.theme-dark .icon-button,
body.theme-dark .button,
body.theme-dark button[type="submit"],
body.theme-dark .table-search input {
  background: #0b1220;
  color: #e2e8f0;
  border-color: #334155;
}

body.theme-dark .button-primary,
body.theme-dark .icon-button.primary {
  color: #fff;
  border-color: transparent;
}

body.theme-dark .auth-submit-button {
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.12), transparent 26%),
    linear-gradient(135deg, #1d4ed8 0%, #2563eb 48%, #38bdf8 100%);
  border-color: rgba(125, 211, 252, 0.2);
  box-shadow: 0 20px 40px rgba(14, 165, 233, 0.24);
}

body.theme-dark .auth-card {
  background:
    radial-gradient(circle at top left, rgba(59, 130, 246, 0.12), transparent 24%),
    linear-gradient(180deg, #0f172a 0%, #101b31 100%);
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: 0 24px 54px rgba(2, 6, 23, 0.34);
}

body.theme-dark .auth-card label > span {
  color: #cbd5e1;
}

body.theme-dark .auth-card input {
  background: #0b1220;
  border-color: rgba(148, 163, 184, 0.18);
}

body.theme-dark .auth-footnote {
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.14) 0%, rgba(15, 23, 42, 0.92) 100%);
  border-color: rgba(96, 165, 250, 0.18);
}

body.theme-dark .auth-footnote strong {
  color: #bfdbfe;
}

body.theme-dark .auth-footnote span {
  color: #cbd5e1;
}

body.theme-dark .empty-state,
body.theme-dark .ranking-item,
body.theme-dark .activity-item,
body.theme-dark .admin-card,
body.theme-dark .brand-preview-card {
  background: #111c31;
  border-color: #23324c;
}

body.theme-dark .register-panel.register-panel-alt {
  background:
    radial-gradient(circle at top left, rgba(59, 130, 246, 0.12), transparent 26%),
    linear-gradient(180deg, #0f172a 0%, #101a31 100%);
}

body.theme-dark .attendance-fieldset {
  border-color: #23324c;
  background: linear-gradient(180deg, #0d172b, #111c31);
}

body.theme-dark .attendance-fieldset legend {
  color: #93c5fd;
}

body.theme-dark .attendance-option {
  background: #0b1220;
  border-color: #23324c;
}

body.theme-dark .attendance-option:hover {
  border-color: #3b82f6;
  box-shadow: 0 20px 40px rgba(2, 6, 23, 0.32);
}

body.theme-dark .attendance-option small {
  color: #94a3b8;
}

body.theme-dark .progress-bar,
body.theme-dark .chart-bar-track,
body.theme-dark .qr-box {
  background: #0b1220;
  border-color: #23324c;
}

body.theme-dark td,
body.theme-dark th {
  border-bottom-color: #1e293b;
}

body.theme-dark .code-block {
  background: #020617;
  color: #cbd5e1;
}

.hero,
.dashboard-grid,
.feature-grid,
.info-grid,
.stat-grid {
  display: grid;
  gap: 20px;
}

.hero {
  grid-template-columns: 1.4fr 1fr;
  margin-bottom: 20px;
}

.hero-copy,
.hero-card,
.panel,
.winner-card,
.nominee-edit-card,
.nominee-card,
.feature-card,
.stat-card,
.info-card {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

.hero-copy,
.hero-card,
.panel {
  padding: 24px;
}

.hero-copy h2 {
  font-size: 36px;
  line-height: 1.2;
  margin: 12px 0;
}

.hero-copy p,
.muted,
.detail-list,
.feature-card p,
.nominee-card p,
.empty-state p {
  color: #5b6473;
  line-height: 1.6;
}

.badge,
.pill {
  display: inline-block;
  background: #dbeafe;
  color: #1d4ed8;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 12px;
}

.pill.neutral {
  background: #e2e8f0;
  color: #334155;
}

.button-row,
.split-header,
.sticky-actions,
.button-stack {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.top-actions {
  margin-top: 18px;
}

.button,
button,
input,
textarea,
select {
  font: inherit;
}

.button,
button[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: #fff;
  color: #0f172a;
  border: 1px solid #d6dce6;
  border-radius: 12px;
  padding: 11px 16px;
  cursor: pointer;
}

.button-primary {
  background: linear-gradient(90deg, #1d4ed8, #2563eb);
  color: #fff;
  border-color: transparent;
}

.button-danger {
  background: #fee2e2;
  color: #b91c1c;
  border-color: transparent;
}

.tiny {
  padding: 7px 10px;
  font-size: 12px;
}

.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid #d6dce6;
  background: #fff;
  color: #1e293b;
  cursor: pointer;
}

.icon-button.primary {
  background: linear-gradient(90deg, #1d4ed8, #2563eb);
  border-color: transparent;
  color: #fff;
}

.stat-grid,
.info-grid,
.feature-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.stat-grid-xl {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.stat-card,
.info-card,
.feature-card {
  padding: 20px;
}

.stat-card span,
.info-card span,
.countdown-card span {
  display: block;
  color: #6b7280;
  margin-bottom: 8px;
}

.stat-card strong,
.info-card strong,
.countdown-card strong {
  font-size: 28px;
}

.panel {
  margin-bottom: 20px;
}

.panel.narrow {
  max-width: 720px;
}

.register-shell {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 24px;
  align-items: stretch;
  margin-bottom: 24px;
}

.register-showcase {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  padding: 32px;
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.24), transparent 34%),
    linear-gradient(135deg, #0f172a 0%, #1d4ed8 52%, #0ea5e9 100%);
  color: #fff;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.16);
  display: grid;
  gap: 18px;
}

.register-showcase h2 {
  margin: 0;
  font-size: 38px;
  line-height: 1.15;
}

.register-showcase p {
  margin: 0;
  max-width: 560px;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.7;
}

.register-feature-list {
  display: grid;
  gap: 14px;
  margin-top: 10px;
}

.register-feature-card {
  padding: 18px 18px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  display: grid;
  gap: 6px;
}

.register-feature-card strong {
  font-size: 16px;
}

.register-feature-card span {
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.55;
}

.register-panel.register-panel-alt {
  border-radius: 28px;
  padding: 28px;
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.08), transparent 26%),
    linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.08);
}

.register-panel-head {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
}

.register-form-grid {
  gap: 18px;
}

.attendance-fieldset {
  border: 1px solid #d7e3f3;
  border-radius: 22px;
  padding: 18px;
  margin: 0;
  display: grid;
  gap: 16px;
  background: linear-gradient(180deg, #fbfdff, #f3f8ff);
}

.attendance-fieldset legend {
  padding: 0 10px;
  font-weight: 700;
  color: #1e3a8a;
}

.attendance-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.attendance-option {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 18px;
  border-radius: 20px;
  border: 1px solid #d9e6f5;
  background: #fff;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.attendance-option:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(37, 99, 235, 0.08);
  border-color: #93c5fd;
}

.attendance-option input {
  margin-top: 2px;
}

.attendance-option span {
  display: grid;
  gap: 4px;
}

.attendance-option strong {
  font-size: 16px;
}

.attendance-option small {
  color: #64748b;
  line-height: 1.5;
}

.register-submit {
  min-height: 52px;
  border-radius: 16px;
}

.form-grid {
  display: grid;
  gap: 16px;
}

.auth-login-form {
  gap: 18px;
}

.auth-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(360px, 440px);
  gap: 30px;
  align-items: stretch;
  margin-bottom: 24px;
  position: relative;
}

.auth-stage {
  position: relative;
  overflow: hidden;
  border-radius: 34px;
  padding: 32px;
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.28), transparent 30%),
    radial-gradient(circle at bottom left, rgba(14, 165, 233, 0.22), transparent 26%),
    linear-gradient(145deg, #020617 0%, #0f172a 42%, #1d4ed8 100%);
  color: #fff;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.22);
  display: grid;
  gap: 26px;
  min-height: 640px;
}

.auth-stage-voter {
  background:
    radial-gradient(circle at top right, rgba(125, 211, 252, 0.26), transparent 30%),
    radial-gradient(circle at bottom left, rgba(45, 212, 191, 0.16), transparent 24%),
    linear-gradient(145deg, #020617 0%, #0f172a 38%, #1d4ed8 76%, #0f766e 100%);
}

.auth-stage-admin {
  background:
    radial-gradient(circle at top right, rgba(125, 211, 252, 0.18), transparent 30%),
    radial-gradient(circle at bottom left, rgba(59, 130, 246, 0.18), transparent 24%),
    linear-gradient(145deg, #020617 0%, #0b1120 40%, #172554 76%, #1d4ed8 100%);
}

.auth-orb {
  position: absolute;
  border-radius: 999px;
  filter: blur(6px);
  opacity: 0.8;
  pointer-events: none;
  animation: auth-orb-float 9s ease-in-out infinite;
}

.auth-orb-one {
  width: 180px;
  height: 180px;
  top: -50px;
  right: 80px;
  background: radial-gradient(circle, rgba(125, 211, 252, 0.34) 0%, rgba(125, 211, 252, 0) 72%);
}

.auth-orb-two {
  width: 240px;
  height: 240px;
  bottom: -110px;
  left: -40px;
  background: radial-gradient(circle, rgba(45, 212, 191, 0.24) 0%, rgba(45, 212, 191, 0) 70%);
  animation-delay: -4s;
}

.auth-stage-top {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
}

.auth-brand-mark {
  width: 46px;
  height: 46px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 20px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(191, 219, 254, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.auth-brand strong,
.auth-brand small {
  display: block;
}

.auth-brand small {
  color: rgba(255, 255, 255, 0.66);
}

.auth-stage-badge {
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(191, 219, 254, 0.16);
}

.auth-stage-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 14px;
  max-width: 640px;
}

.auth-stage-copy h2 {
  margin: 0;
  font-size: clamp(36px, 4vw, 54px);
  line-height: 1.02;
  max-width: 720px;
}

.auth-stage-copy p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.8;
  max-width: 620px;
}

.auth-stage-board {
  position: relative;
  z-index: 1;
  margin-top: auto;
  padding-top: 8px;
}

.auth-stage-window {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  border: 1px solid rgba(191, 219, 254, 0.14);
  background: rgba(2, 6, 23, 0.42);
  backdrop-filter: blur(12px);
  display: grid;
  gap: 18px;
  padding: 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.auth-window-bar {
  display: inline-flex;
  gap: 8px;
}

.auth-window-bar span {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
}

.auth-window-body {
  display: grid;
  gap: 18px;
}

.auth-window-summary {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.32), rgba(14, 165, 233, 0.18));
}

.auth-window-summary strong,
.auth-window-summary span {
  display: block;
}

.auth-window-summary span {
  color: rgba(255, 255, 255, 0.76);
}

.auth-window-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.auth-window-card {
  padding: 18px;
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.68);
  border: 1px solid rgba(191, 219, 254, 0.12);
  display: grid;
  gap: 6px;
  min-height: 124px;
}

.auth-window-card strong {
  font-size: 16px;
}

.auth-window-card span {
  color: rgba(226, 232, 240, 0.72);
  line-height: 1.6;
}

.auth-window-card-active {
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.36), rgba(15, 23, 42, 0.82));
  animation: auth-pulse 3s ease-in-out infinite;
}

.auth-floating-card {
  position: absolute;
  display: grid;
  gap: 6px;
  width: 220px;
  padding: 16px 18px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(191, 219, 254, 0.16);
  backdrop-filter: blur(14px);
  box-shadow: 0 22px 40px rgba(2, 6, 23, 0.26);
  animation: auth-float 6s ease-in-out infinite;
}

.auth-floating-card strong {
  font-size: 15px;
}

.auth-floating-card span {
  color: rgba(226, 232, 240, 0.8);
  line-height: 1.55;
}

.auth-floating-card-top {
  top: 26px;
  right: 24px;
}

.auth-floating-card-bottom {
  bottom: 20px;
  left: 26px;
  animation-delay: -3s;
}

.auth-card {
  position: relative;
  border-radius: 34px;
  padding: 34px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(248, 251, 255, 0.98) 100%);
  border: 1px solid rgba(148, 163, 184, 0.16);
  box-shadow: 0 28px 60px rgba(15, 23, 42, 0.1);
  display: grid;
  gap: 24px;
  overflow: hidden;
}

.auth-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: linear-gradient(90deg, #2563eb, #38bdf8, #14b8a6);
}

.auth-card > * {
  position: relative;
  z-index: 1;
}

.auth-panel-head {
  display: grid;
  gap: 8px;
}

.auth-panel-head h3 {
  margin: 0;
  font-size: 32px;
  line-height: 1.12;
}

.auth-card label > span {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #334155;
}

.auth-card input {
  min-height: 54px;
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  border-color: rgba(148, 163, 184, 0.22);
}

.auth-card input:focus {
  outline: none;
  border-color: rgba(37, 99, 235, 0.42);
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.12);
}

.auth-submit-button {
  width: 100%;
  min-height: 56px;
  border-radius: 12px;
  padding: 14px 20px;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.005em;
  background: #1877f2;
  border: 1px solid #1877f2;
  color: #fff;
  box-shadow: 0 10px 24px rgba(24, 119, 242, 0.22);
  transition: background-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.auth-submit-button:hover {
  background: #166fe5;
  border-color: #166fe5;
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(24, 119, 242, 0.28);
}

.auth-submit-button:active {
  transform: translateY(0);
}

.auth-submit-button:focus-visible {
  outline: 3px solid rgba(96, 165, 250, 0.35);
  outline-offset: 2px;
}

.auth-footnote {
  padding: 18px 20px;
  border-radius: 22px;
  background: linear-gradient(180deg, #eff6ff 0%, #f8fbff 100%);
  border: 1px solid rgba(147, 197, 253, 0.2);
  display: grid;
  gap: 6px;
}

.auth-footnote strong {
  font-size: 14px;
  color: #1e3a8a;
}

.auth-footnote span {
  color: #475569;
  line-height: 1.65;
}

.auth-center-shell {
  position: relative;
  overflow: hidden;
  min-height: calc(100vh - 180px);
  margin-bottom: 24px;
  padding: 48px 20px;
  border-radius: 34px;
  background: linear-gradient(180deg, #f0f4fb 0%, #e7edf6 100%);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 24px;
}

.auth-center-orb {
  position: absolute;
  border-radius: 999px;
  pointer-events: none;
  filter: blur(12px);
  opacity: 0.8;
  animation: auth-orb-float 10s ease-in-out infinite;
}

.auth-center-orb-left {
  width: 260px;
  height: 260px;
  left: -80px;
  top: 70px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.18) 0%, rgba(59, 130, 246, 0) 72%);
}

.auth-center-orb-right {
  width: 220px;
  height: 220px;
  right: -50px;
  bottom: 60px;
  background: radial-gradient(circle, rgba(14, 165, 233, 0.16) 0%, rgba(14, 165, 233, 0) 74%);
  animation-delay: -4s;
}

.auth-center-brand {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 10px;
  text-align: center;
  max-width: 560px;
  animation: auth-card-rise 0.6s ease;
}

.auth-center-mark {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, #1f2937 0%, #0f172a 100%);
  color: #fff;
  font-size: 28px;
  font-weight: 800;
  box-shadow: 0 18px 34px rgba(15, 23, 42, 0.16);
}

.auth-center-brand h1 {
  margin: 0;
  font-size: clamp(38px, 5vw, 56px);
  line-height: 1;
  color: #1877f2;
  letter-spacing: -0.03em;
}

.auth-center-brand p {
  margin: 0;
  font-size: 20px;
  line-height: 1.5;
  color: #1f2937;
}

.auth-login-card {
  position: relative;
  z-index: 1;
  width: min(100%, 420px);
  padding: 24px 20px 18px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.14);
  display: grid;
  gap: 18px;
  animation: auth-card-rise 0.75s ease;
}

.auth-login-card-admin {
  box-shadow: 0 20px 44px rgba(15, 23, 42, 0.16);
}

.auth-login-card-head {
  text-align: center;
}

.auth-login-badge {
  justify-self: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  border-radius: 999px;
  background: #e7f3ff;
  color: #1877f2;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.auth-login-card .muted {
  color: #64748b;
}

.auth-login-card .auth-panel-head h3 {
  font-size: 30px;
}

.auth-login-card label > span {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  color: #1f2937;
}

.auth-login-card input {
  min-height: 54px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid #d0d7e2;
  padding: 14px 16px;
  font-size: 17px;
}

.auth-login-card input::placeholder {
  color: #94a3b8;
}

.auth-login-card input:focus {
  outline: none;
  border-color: #1877f2;
  box-shadow: 0 0 0 3px rgba(24, 119, 242, 0.14);
}

.auth-login-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #94a3b8;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.auth-login-divider::before,
.auth-login-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #e2e8f0;
}

.auth-login-card .auth-footnote {
  padding: 14px 16px;
  border-radius: 12px;
  background: #f8fafc;
  border-color: rgba(148, 163, 184, 0.14);
}

.auth-login-card .auth-footnote strong {
  color: #0f172a;
}

@keyframes auth-card-rise {
  0% {
    opacity: 0;
    transform: translateY(14px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.election-control-shell {
  display: grid;
  gap: 24px;
}

.election-page {
  align-items: start;
  grid-template-columns: minmax(0, 0.94fr) minmax(340px, 0.88fr);
}

.election-page-single {
  grid-template-columns: 1fr;
}

.election-command-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 18px;
  align-items: center;
  padding: 22px 24px;
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.08), transparent 28%),
    linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  border: 1px solid rgba(148, 163, 184, 0.14);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.06);
}

.election-command-copy {
  min-width: 0;
}

.election-command-copy h2 {
  margin: 0;
  font-size: clamp(26px, 3.4vw, 34px);
  line-height: 1.05;
  color: #0f172a;
  letter-spacing: -0.03em;
}

.election-command-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.election-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  font-weight: 800;
  letter-spacing: 0.01em;
  background: #eef2ff;
  color: #1d4ed8;
  border: 1px solid rgba(59, 130, 246, 0.16);
}

.election-status-pill.success {
  background: #ecfdf3;
  color: #15803d;
  border-color: rgba(34, 197, 94, 0.2);
}

.election-status-pill.danger {
  background: #fff1f2;
  color: #b91c1c;
  border-color: rgba(239, 68, 68, 0.2);
}

.election-status-pill.neutral {
  background: #f8fafc;
  color: #334155;
  border-color: rgba(148, 163, 184, 0.2);
}

.election-status-meta {
  color: #64748b;
  font-weight: 600;
}

.election-live-timer {
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.election-live-timer small {
  font-size: 13px;
  color: #64748b;
}

.election-command-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.election-command-actions .button {
  min-height: 46px;
  padding-inline: 18px;
}

.election-panel {
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
  border: 1px solid rgba(148, 163, 184, 0.16);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.06);
}

.election-panel-head {
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.election-panel-head.compact h3 {
  margin-bottom: 6px;
}

.election-panel-head > :first-child {
  min-width: 0;
}

.election-overview-panel {
  padding: 24px;
}

.election-summary-badge {
  display: grid;
  gap: 4px;
  min-width: 160px;
  padding: 16px 18px;
  border-radius: 18px;
  background: #eff6ff;
  border: 1px solid rgba(37, 99, 235, 0.16);
}

.election-summary-badge span {
  color: #64748b;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.election-summary-badge strong {
  color: #0f172a;
  font-size: 22px;
}

.election-summary-badge.running {
  background: linear-gradient(180deg, #effcf3 0%, #dcfce7 100%);
  border-color: rgba(34, 197, 94, 0.18);
}

.election-summary-badge.ended {
  background: linear-gradient(180deg, #fff5f5 0%, #fee2e2 100%);
  border-color: rgba(239, 68, 68, 0.18);
}

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

.election-stat-card {
  display: grid;
  gap: 8px;
  padding: 20px;
  border-radius: 20px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  border: 1px solid rgba(148, 163, 184, 0.14);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.04);
}

.election-stat-card strong {
  font-size: clamp(28px, 3vw, 36px);
  line-height: 1;
}

.election-stat-card small {
  color: #64748b;
}

.election-kpi-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.election-kpi-chip {
  padding: 16px 18px;
  border-radius: 18px;
  background: linear-gradient(180deg, #f8fbff 0%, #eef4ff 100%);
  border: 1px solid rgba(148, 163, 184, 0.14);
}

.election-kpi-chip span {
  display: block;
  color: #64748b;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.election-kpi-chip strong {
  display: block;
  margin-top: 8px;
  color: #0f172a;
  line-height: 1.45;
}

.election-schedule-panel {
  padding: 24px;
}

.election-rule-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.election-progress-overview {
  margin-bottom: 22px;
}

.election-progress-hero {
  gap: 18px;
}

.election-progress-meta,
.election-progress-kpis {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.election-progress-side {
  gap: 16px;
}

.election-progress-chart-card {
  min-height: 100%;
}

.election-progress-feeds {
  margin-bottom: 22px;
}

.election-live-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.election-live-head h3 {
  margin: 0;
  color: #fff;
  font-size: 30px;
}

.live-sync-badge {
  display: grid;
  gap: 4px;
  min-width: 170px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(191, 219, 254, 0.18);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.live-sync-badge::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.18), transparent);
  transform: translateX(-100%);
  animation: election-live-shimmer 2.8s linear infinite;
}

.live-sync-badge strong,
.live-sync-badge small {
  position: relative;
  z-index: 1;
}

.live-sync-badge strong {
  color: #fff;
  font-size: 15px;
}

.live-sync-badge small {
  color: rgba(255, 255, 255, 0.78);
}

.live-sync-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: #4ade80;
  box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5);
  animation: election-live-heartbeat 1.8s ease-in-out infinite;
  position: relative;
  z-index: 1;
}

.live-sync-badge.is-pulsing .live-sync-dot {
  animation-duration: 0.8s;
}

.live-chart-loader {
  display: grid;
  gap: 12px;
  align-items: center;
  justify-items: start;
  min-height: 220px;
  color: #475569;
}

.live-chart-loader strong {
  font-size: 14px;
  color: #475569;
}

.live-chart-loader-bar {
  width: 100%;
  height: 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.16), rgba(56, 189, 248, 0.32), rgba(37, 99, 235, 0.16));
  background-size: 200% 100%;
  animation: election-loader-shift 1.4s linear infinite;
}

@keyframes election-live-heartbeat {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.48);
  }
  60% {
    transform: scale(1.12);
    box-shadow: 0 0 0 12px rgba(74, 222, 128, 0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(74, 222, 128, 0);
  }
}

@keyframes election-live-shimmer {
  100% {
    transform: translateX(100%);
  }
}

@keyframes election-loader-shift {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.election-table-wrap {
  margin-top: 0;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.16);
}

.election-settings-table {
  width: 100%;
  border-collapse: collapse;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.election-settings-table th,
.election-settings-table td {
  padding: 18px 20px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  vertical-align: middle;
}

.election-settings-table tr:last-child th,
.election-settings-table tr:last-child td {
  border-bottom: 0;
}

.election-settings-table th {
  width: 40%;
  text-align: left;
  color: #64748b;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: rgba(15, 23, 42, 0.03);
}

.election-settings-table td {
  color: #0f172a;
  font-weight: 700;
}

.election-lock-card {
  margin-top: 18px;
}

.election-lock-card.compact {
  padding: 16px 18px;
}

.election-modal-form {
  gap: 18px;
}

.election-candidate-pool-section {
  display: grid;
  gap: 14px;
}

.election-candidate-picker {
  display: grid;
  gap: 14px;
}

.election-candidate-search-row {
  justify-content: flex-start;
}

.election-candidate-picker-grid {
  display: block;
}

.election-candidate-list-panel {
  min-width: 0;
}

.election-candidate-card-grid {
  display: grid;
  gap: 10px;
}

.election-candidate-card {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid #dbe4f0;
  background: #f8fafc;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.election-candidate-card:hover {
  transform: translateY(-1px);
  border-color: #bfdbfe;
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.12);
}

.election-candidate-card.active,
.election-candidate-card.is-selected {
  border-color: #60a5fa;
  background: #eff6ff;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.14);
}

.election-candidate-card-copy {
  display: grid;
  min-width: 0;
  gap: 6px;
}

.election-candidate-card-title {
  display: grid;
  gap: 6px;
  align-content: center;
}

.election-candidate-card-title h5 {
  margin: 0;
  font-size: 18px;
  line-height: 1.2;
  font-weight: 800;
  color: #0f172a;
}

.election-candidate-card-media {
  display: block;
}

.election-candidate-card-photo {
  width: 70px;
  height: 54px;
  border-radius: 8px;
  object-fit: cover;
  object-position: center 18%;
  background: linear-gradient(180deg, #e2e8f0, #cbd5e1);
}

.election-candidate-card-photo.placeholder {
  display: grid;
  place-items: center;
  font-size: 20px;
  font-weight: 800;
  color: #1d4ed8;
}

.election-candidate-card-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.election-candidate-card-meta {
  font-size: 12px;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.election-candidate-card-label {
  display: inline-flex;
  align-self: start;
  width: fit-content;
  max-width: max-content;
  padding: 5px 10px;
  font-size: 11px;
  line-height: 1.1;
}

.election-candidate-pagination {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 12px;
}

.election-candidate-pagination-status {
  min-width: 92px;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  color: #475569;
}

.election-candidate-detail {
  display: grid;
  gap: 12px;
}

.election-candidate-detail-hero {
  display: grid;
  gap: 6px;
  align-items: start;
}

.election-candidate-detail-hero h4 {
  margin: 0;
  font-size: 18px;
}

.election-candidate-detail-hero p,
.election-candidate-detail-copy p {
  margin: 0;
  color: #64748b;
  line-height: 1.45;
  font-size: 13px;
}

.election-candidate-detail-photo {
  width: 100%;
  height: 170px;
  border-radius: 18px;
  object-fit: cover;
  object-position: center 18%;
  background: linear-gradient(180deg, #e2e8f0, #cbd5e1);
}

.election-candidate-detail-photo.placeholder {
  display: grid;
  place-items: center;
  font-size: 42px;
  font-weight: 800;
  color: #1d4ed8;
}

.election-candidate-detail-copy {
  display: grid;
  gap: 6px;
}

.election-candidate-detail-copy strong {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #64748b;
}

.election-settings-table-edit th {
  width: 48%;
}

.election-settings-table-edit td input {
  width: 100%;
}

body.theme-dark .election-command-panel {
  background:
    radial-gradient(circle at top right, rgba(56, 189, 248, 0.1), transparent 30%),
    linear-gradient(180deg, #101b30 0%, #0b1326 100%);
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: 0 20px 42px rgba(2, 6, 23, 0.32);
}

body.theme-dark .election-command-copy h2 {
  color: #e2e8f0;
}

body.theme-dark .election-status-meta,
body.theme-dark .election-live-timer small {
  color: #94a3b8;
}

body.theme-dark .election-status-pill.neutral {
  background: rgba(15, 23, 42, 0.9);
  color: #e2e8f0;
  border-color: rgba(148, 163, 184, 0.14);
}

body.theme-dark .bootstrap-table {
  background: #0f172a;
  border-color: rgba(148, 163, 184, 0.14);
}

body.theme-dark .bootstrap-table thead th {
  background: rgba(148, 163, 184, 0.06);
  color: #94a3b8;
  border-bottom-color: rgba(148, 163, 184, 0.12);
}

body.theme-dark .bootstrap-table.table-striped tbody tr:nth-child(even) {
  background: rgba(15, 23, 42, 0.88);
}

body.theme-dark .bootstrap-table.table-hover tbody tr:hover {
  background: rgba(30, 41, 59, 0.72);
}

body.theme-dark .election-candidate-detail-hero p,
body.theme-dark .election-candidate-detail-copy p {
  color: #94a3b8;
}

body.theme-dark .election-candidate-card {
  background: rgba(15, 23, 42, 0.86);
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: 0 16px 28px rgba(2, 6, 23, 0.22);
}

body.theme-dark .election-candidate-card-title h5 {
  color: #e2e8f0;
}

body.theme-dark .election-candidate-card.active,
body.theme-dark .election-candidate-card.is-selected {
  border-color: rgba(96, 165, 250, 0.78);
  background: rgba(37, 99, 235, 0.18);
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.18);
}

body.theme-dark .election-candidate-card-meta {
  color: #94a3b8;
}

body.theme-dark .election-candidate-pagination-status {
  color: #cbd5e1;
}

body.theme-dark .election-panel {
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.08), transparent 28%),
    linear-gradient(180deg, #101b30 0%, #0b1326 100%);
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: 0 20px 42px rgba(2, 6, 23, 0.32);
}

body.theme-dark .election-summary-badge {
  background: rgba(15, 23, 42, 0.9);
  border-color: rgba(148, 163, 184, 0.14);
}

body.theme-dark .election-summary-badge strong {
  color: #e2e8f0;
}

body.theme-dark .election-stat-card {
  background: linear-gradient(180deg, #0f172a 0%, #101b31 100%);
  border-color: rgba(148, 163, 184, 0.14);
}

body.theme-dark .election-kpi-chip {
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.9) 0%, rgba(16, 27, 49, 0.95) 100%);
  border-color: rgba(148, 163, 184, 0.14);
}

body.theme-dark .election-kpi-chip strong {
  color: #e2e8f0;
}

body.theme-dark .election-table-wrap {
  border-color: rgba(148, 163, 184, 0.14);
}

body.theme-dark .election-settings-table {
  background: linear-gradient(180deg, #0f172a 0%, #101b31 100%);
}

body.theme-dark .election-settings-table th {
  background: rgba(148, 163, 184, 0.06);
  color: #94a3b8;
}

body.theme-dark .election-settings-table td {
  color: #e2e8f0;
}

@keyframes auth-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

@keyframes auth-pulse {
  0%,
  100% {
    box-shadow: inset 0 0 0 0 rgba(125, 211, 252, 0.06);
  }
  50% {
    box-shadow: inset 0 0 0 1px rgba(125, 211, 252, 0.24), 0 18px 34px rgba(37, 99, 235, 0.18);
  }
}

@keyframes auth-orb-float {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(0, -18px, 0) scale(1.04);
  }
}

.form-grid.compact {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  align-items: end;
}

label {
  display: grid;
  gap: 8px;
  font-weight: 600;
}

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

input,
textarea,
select {
  border: 1px solid #d6dce6;
  background: #f9fbff;
  border-radius: 12px;
  padding: 12px 14px;
}

.dashboard-grid {
  grid-template-columns: 1fr 1fr;
}

.dashboard-control-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

.dashboard-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

.dashboard-shell {
  display: grid;
  gap: 18px;
  margin-bottom: 24px;
}

.dashboard-top-grid {
  display: grid;
  grid-template-columns: 1.8fr 1fr;
  gap: 18px;
  align-items: stretch;
}

.hero-panel {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  min-height: 240px;
  background: radial-gradient(circle at top right, rgba(37, 99, 235, 0.32), transparent 52%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(29, 78, 216, 0.86));
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  color: #fff;
  padding: 26px;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 18px;
}

.glass-hover {
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.glass-hover:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 48px rgba(15, 23, 42, 0.12);
  border-color: rgba(125, 211, 252, 0.34);
}

.dashboard-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.14);
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.08), transparent 32%),
    linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.dashboard-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: linear-gradient(90deg, #2563eb, #38bdf8);
  opacity: 0.8;
}

body.theme-dark .dashboard-card {
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.16), transparent 34%),
    linear-gradient(180deg, #111b31 0%, #0b1326 100%);
  border-color: rgba(148, 163, 184, 0.18);
  box-shadow: 0 16px 40px rgba(2, 6, 23, 0.24);
}

body.theme-dark .glass-hover:hover {
  box-shadow: 0 24px 54px rgba(2, 6, 23, 0.42);
  border-color: rgba(96, 165, 250, 0.32);
}

.dashboard-card-accent {
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.12), transparent 34%),
    linear-gradient(180deg, #ffffff 0%, #f3f8ff 100%);
}

body.theme-dark .dashboard-card-accent {
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.18), transparent 34%),
    linear-gradient(180deg, #0f172a 0%, #0d1830 100%);
}

.dashboard-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 14px;
}

.card-menu {
  position: relative;
}

.card-menu summary {
  list-style: none;
}

.card-menu summary::-webkit-details-marker {
  display: none;
}

.card-menu .icon-button {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
}

body.theme-dark .card-menu .icon-button {
  background: rgba(15, 23, 42, 0.92);
  border-color: rgba(148, 163, 184, 0.18);
}

.card-menu-list {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 180px;
  padding: 8px;
  border-radius: 16px;
  background: #fff;
  border: 1px solid rgba(148, 163, 184, 0.18);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  z-index: 8;
  display: grid;
  gap: 4px;
}

.card-menu-list a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  color: #0f172a;
}

.card-menu-list a:hover {
  background: #eff6ff;
}

body.theme-dark .card-menu-list {
  background: #0b1326;
  border-color: rgba(148, 163, 184, 0.18);
  box-shadow: 0 24px 54px rgba(2, 6, 23, 0.5);
}

body.theme-dark .card-menu-list a {
  color: #f1f5f9;
}

body.theme-dark .card-menu-list a:hover {
  background: rgba(59, 130, 246, 0.14);
}

.dashboard-kicker {
  display: inline-block;
  margin-bottom: 6px;
  color: #2563eb;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

body.theme-dark .dashboard-kicker {
  color: #60a5fa;
}

.dashboard-inline-form {
  margin-top: 18px;
}

.dashboard-inline-form label > span {
  font-size: 13px;
}

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

.detail-chip {
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.16);
  display: grid;
  gap: 6px;
}

.detail-chip-wide {
  grid-column: 1 / -1;
}

.detail-chip span {
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.detail-chip strong {
  font-size: 15px;
  line-height: 1.5;
}

body.theme-dark .detail-chip {
  background: rgba(148, 163, 184, 0.08);
  border-color: rgba(148, 163, 184, 0.16);
}

body.theme-dark .detail-chip span {
  color: #94a3b8;
}

.dashboard-action-row {
  margin-top: 20px;
}

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

.system-grid div {
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.16);
}

.system-grid strong,
.system-grid span {
  display: block;
}

.system-grid strong {
  margin-bottom: 6px;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #64748b;
}

.system-grid span {
  word-break: break-word;
}

body.theme-dark .system-grid div {
  background: rgba(148, 163, 184, 0.08);
  border-color: rgba(148, 163, 184, 0.16);
}

body.theme-dark .system-grid strong {
  color: #94a3b8;
}

.dashboard-progress {
  padding: 14px 0 0;
}

.chart-card .chart-surface {
  margin-top: 14px;
  padding: 14px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.52), rgba(239, 246, 255, 0.72));
  border: 1px solid rgba(148, 163, 184, 0.14);
}

body.theme-dark .chart-card .chart-surface {
  background: linear-gradient(180deg, rgba(7, 15, 30, 0.62), rgba(15, 23, 42, 0.78));
  border-color: rgba(148, 163, 184, 0.18);
}

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

.snapshot-item {
  padding: 18px;
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.16);
}

.snapshot-item-wide {
  grid-column: 1 / -1;
}

.snapshot-item span {
  display: block;
  margin-bottom: 10px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.snapshot-item strong {
  font-size: 20px;
  line-height: 1.4;
}

body.theme-dark .snapshot-item {
  background: rgba(148, 163, 184, 0.08);
  border-color: rgba(148, 163, 184, 0.16);
}

body.theme-dark .snapshot-item span {
  color: #94a3b8;
}

.dashboard-table-card {
  margin-bottom: 24px;
}

.dashboard-table-head {
  align-items: flex-end;
  margin-bottom: 16px;
}

.table-head-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.admin-dashboard-page {
  gap: 22px;
}

.dashboard-overview-grid,
.dashboard-workspace-grid,
.dashboard-bottom-grid,
.dashboard-analytics-grid {
  display: grid;
  gap: 20px;
  margin-bottom: 22px;
}

.dashboard-overview-grid {
  grid-template-columns: 1.6fr 0.9fr;
  align-items: start;
}

.dashboard-workspace-grid {
  grid-template-columns: 1.05fr 1.35fr;
}

.dashboard-bottom-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.dashboard-hero-card {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  padding: 28px;
  color: #fff;
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.34), transparent 30%),
    radial-gradient(circle at bottom left, rgba(14, 165, 233, 0.24), transparent 30%),
    linear-gradient(135deg, #0f172a 0%, #1d4ed8 56%, #0f766e 100%);
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.18);
  display: grid;
  gap: 22px;
}

.dashboard-hero-copy {
  display: grid;
  gap: 10px;
}

.dashboard-hero-copy h2 {
  margin: 0;
  font-size: 40px;
  line-height: 1.08;
}

.dashboard-hero-copy p {
  margin: 0;
  max-width: 760px;
  color: rgba(255, 255, 255, 0.82);
}

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

.dashboard-status-chip,
.dashboard-kpi-card {
  border-radius: 20px;
  border: 1px solid rgba(191, 219, 254, 0.18);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}

.dashboard-status-chip {
  padding: 16px;
  display: grid;
  gap: 8px;
}

.dashboard-status-chip span,
.dashboard-kpi-card span {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
}

.dashboard-status-chip strong {
  font-size: 18px;
  line-height: 1.35;
}

.dashboard-hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

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

.dashboard-kpi-card {
  padding: 18px;
  display: grid;
  gap: 8px;
}

.dashboard-kpi-card strong {
  font-size: 26px;
  line-height: 1.1;
}

.dashboard-kpi-card small {
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.5;
}

.dashboard-overview-side {
  display: grid;
  gap: 20px;
}

.dashboard-status-card .hero-status-block {
  background: linear-gradient(180deg, #f8fbff, #eef6ff);
  border-color: rgba(148, 163, 184, 0.18);
}

.dashboard-status-card .count-chip {
  background: rgba(255, 255, 255, 0.84);
  border-color: rgba(148, 163, 184, 0.18);
}

.dashboard-status-card .count-chip span,
.dashboard-status-card .hero-status-subtitle,
.dashboard-status-card .timer-label {
  color: #64748b;
}

.dashboard-status-card .hero-countdown-banner {
  color: #0f172a;
}

.dashboard-nominee-focus {
  display: grid;
  gap: 16px;
}

.dashboard-nominee-focus-body {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: center;
}

.dashboard-focus-avatar {
  width: 72px;
  height: 72px;
  border-radius: 22px;
  object-fit: cover;
  background: #dbeafe;
}

.dashboard-focus-copy {
  display: grid;
  gap: 6px;
}

.dashboard-focus-copy strong {
  font-size: 18px;
  line-height: 1.4;
}

.dashboard-focus-copy span {
  color: #64748b;
}

.dashboard-activity-panel {
  display: grid;
  gap: 18px;
}

.dashboard-activity-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.dashboard-feed-card {
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: linear-gradient(180deg, #fbfdff 0%, #f6f9ff 100%);
  padding: 16px;
  display: grid;
  gap: 14px;
}

.dashboard-feed-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.dashboard-feed-head h4 {
  margin: 0;
  font-size: 16px;
}

.dashboard-feed-head span {
  color: #64748b;
  font-size: 12px;
}

.dashboard-feed-list {
  display: grid;
  gap: 12px;
}

.dashboard-feed-list .ranking-item,
.dashboard-feed-list .activity-item {
  margin: 0;
}

body.theme-dark .dashboard-hero-card {
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.24), transparent 30%),
    radial-gradient(circle at bottom left, rgba(20, 184, 166, 0.18), transparent 30%),
    linear-gradient(135deg, #020617 0%, #10224d 56%, #0f3f46 100%);
}

body.theme-dark .dashboard-status-card .hero-status-block {
  background: linear-gradient(180deg, #0b1326, #0f172a);
  border-color: rgba(148, 163, 184, 0.18);
}

body.theme-dark .dashboard-status-card .count-chip {
  background: rgba(15, 23, 42, 0.82);
}

body.theme-dark .dashboard-status-card .count-chip span,
body.theme-dark .dashboard-status-card .hero-countdown-banner,
body.theme-dark .dashboard-focus-copy span,
body.theme-dark .dashboard-feed-head span {
  color: #94a3b8;
}

body.theme-dark .dashboard-feed-card {
  background: linear-gradient(180deg, #101b30 0%, #0b1326 100%);
  border-color: rgba(148, 163, 184, 0.18);
}


.hero-overlay {
  position: absolute;
  inset: 0;
  opacity: 0.22;
  background: radial-gradient(circle at center, rgba(255, 255, 255, 0.2), transparent 58%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 12px;
  align-content: start;
}

.hero-badge {
  display: inline-flex;
  width: fit-content;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(191, 219, 254, 0.18);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-content h2 {
  font-size: 34px;
  line-height: 1.2;
  margin: 0;
}

.hero-content p {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  max-width: 520px;
}

.stat-pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.stat-pill {
  min-width: 120px;
  padding: 10px 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
}

body.theme-dark .stat-pill {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(191, 219, 254, 0.14);
}

.stat-pill span {
  display: block;
  margin-bottom: 5px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.stat-pill strong {
  display: block;
  font-size: 14px;
  line-height: 1.35;
}

.stat-sparkline {
  height: 34px;
  margin-top: 8px;
  opacity: 0.96;
}

.stat-sparkline svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.stat-sparkline .sparkline-area {
  fill: rgba(191, 219, 254, 0.18);
}

.stat-sparkline .sparkline-line {
  fill: none;
  stroke: rgba(255, 255, 255, 0.95);
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.stat-sparkline .sparkline-dot {
  fill: #fff;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.hero-timers {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 14px;
  align-content: start;
}

.hero-status-block {
  padding: 16px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(191, 219, 254, 0.18);
  backdrop-filter: blur(10px);
}

.hero-status-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}

.status-pill {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.hero-status-subtitle {
  color: rgba(255, 255, 255, 0.68);
}

.hero-countdown-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}

.count-chip {
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.count-chip span {
  display: block;
  margin-bottom: 6px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.count-chip strong {
  display: block;
  font-size: 14px;
  line-height: 1.45;
}

.hero-countdown-banner {
  padding: 12px 14px;
  border-radius: 16px;
  background: linear-gradient(90deg, rgba(59, 130, 246, 0.18), rgba(14, 165, 233, 0.12));
  color: #fff;
  font-weight: 700;
}

.timer-label {
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.74);
}

.timer-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.timer-card {
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(191, 219, 254, 0.12);
  border-radius: 18px;
  padding: 14px 14px;
  display: grid;
  gap: 8px;
}

.timer-card span {
  color: rgba(255, 255, 255, 0.72);
}

.timer-card strong {
  font-size: 22px;
}

.hero-subinfo {
  display: grid;
  gap: 6px;
  color: rgba(255, 255, 255, 0.78);
}

.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
}

.stat-panel .chart-surface {
  min-height: 220px;
}

.mini-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 14px;
}

.mini-metric {
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.03);
  padding: 14px;
  border: 1px solid rgba(148, 163, 184, 0.18);
}

body.theme-dark .mini-metric {
  background: rgba(148, 163, 184, 0.08);
  border-color: rgba(148, 163, 184, 0.16);
}

.mini-metric span {
  display: block;
  color: #64748b;
  margin-bottom: 8px;
}

body.theme-dark .mini-metric span {
  color: #94a3b8;
}

.mini-metric strong {
  font-size: 18px;
}

.candidate-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.candidate-card {
  background: #fff;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.06);
  padding: 16px;
  display: grid;
  gap: 14px;
}

.candidate-menu {
  justify-self: end;
}

body.theme-dark .candidate-card {
  background: linear-gradient(180deg, #101b30 0%, #0b1326 100%);
  border-color: rgba(148, 163, 184, 0.18);
}

body.theme-dark .live-sync-badge {
  background: rgba(15, 23, 42, 0.56);
  border-color: rgba(148, 163, 184, 0.18);
}

body.theme-dark .live-chart-loader strong {
  color: #cbd5e1;
}

.candidate-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
}

.candidate-avatar {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  object-fit: cover;
  background: #e2e8f0;
}

.candidate-score {
  text-align: right;
}

.candidate-score span {
  display: block;
  color: #64748b;
  font-size: 12px;
}

body.theme-dark .candidate-score span {
  color: #94a3b8;
}

.candidate-bars {
  display: grid;
  gap: 12px;
}

.candidate-actions {
  display: flex;
  justify-content: flex-end;
}

.button.button-ghost {
  background: rgba(37, 99, 235, 0.08);
  color: #1d4ed8;
  border-color: rgba(59, 130, 246, 0.16);
}

.button.button-ghost:hover {
  background: rgba(37, 99, 235, 0.14);
}

body.theme-dark .button.button-ghost {
  background: rgba(96, 165, 250, 0.12);
  color: #dbeafe;
  border-color: rgba(96, 165, 250, 0.22);
}

body.theme-dark .ballot-candidate-card.selected {
  border-color: rgba(96, 165, 250, 0.4);
  background: linear-gradient(180deg, #0f172a 0%, #13213d 100%);
}

body.theme-dark .ballot-candidate-toggle {
  background: rgba(37, 99, 235, 0.16);
  border-color: rgba(96, 165, 250, 0.28);
  color: #dbeafe;
}

body.theme-dark .ballot-candidate-card input:disabled {
  background: #111c31;
  color: #64748b;
}

body.theme-dark .countdown-card.countdown-ended {
  background: rgba(127, 29, 29, 0.3);
}

body.theme-dark .countdown-card {
  color: #0f172a;
}

body.theme-dark .countdown-card span,
body.theme-dark .countdown-card small {
  color: #475569;
}

body.theme-dark .countdown-card strong {
  color: #0f172a;
}

.candidate-bar span {
  color: #64748b;
}

body.theme-dark .candidate-bar span {
  color: #94a3b8;
}

.candidate-bar strong {
  display: block;
  margin-top: 6px;
  margin-bottom: 10px;
  font-size: 18px;
}

.detail-list {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.progress-block {
  margin-top: 18px;
}

.progress-row,
.ranking-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.progress-bar {
  height: 12px;
  background: linear-gradient(180deg, #e8eef8, #dfe7f4);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 8px;
}

.progress-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #60a5fa, #7dd3fc);
  border-radius: 999px;
  transition: width 0.75s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 18px rgba(125, 211, 252, 0.32);
}

.progress-bar.accent span {
  background: linear-gradient(90deg, #93c5fd, #5eead4);
}

.progress-bar.animated span {
  animation: progressPulse 2.6s ease-in-out infinite;
}

.qr-box {
  min-height: 240px;
  border: 2px dashed #c9d2e3;
  border-radius: 16px;
  display: grid;
  place-items: center;
  padding: 16px;
  background: #f8fbff;
}

.table-wrap {
  overflow-x: auto;
}

.bootstrap-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: #ffffff;
  border: 1px solid #dbe4f0;
  border-radius: 18px;
  overflow: hidden;
}

.bootstrap-table thead th {
  background: #f8fafc;
  color: #475569;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-bottom: 1px solid #dbe4f0;
}

.bootstrap-table.table-striped tbody tr:nth-child(even) {
  background: #f8fbff;
}

.bootstrap-table.table-hover tbody tr:hover {
  background: #eef4ff;
}

.bootstrap-table tbody tr[data-row-modal-target] {
  cursor: pointer;
}

.table-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 12px;
}

.table-search {
  display: inline-flex;
  width: min(100%, 320px);
}

.table-search input {
  width: 100%;
}

.code-block {
  margin: 0;
  background: #0f172a;
  color: #e2e8f0;
  padding: 14px;
  border-radius: 12px;
  font-size: 12px;
  white-space: pre-wrap;
  word-break: break-word;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
}

tbody tr {
  transition: background 0.18s ease, transform 0.18s ease;
}

tbody tr:hover {
  background: rgba(239, 246, 255, 0.88);
}

body.theme-dark tbody tr:hover {
  background: rgba(30, 41, 59, 0.72);
}

.dashboard-table-card tbody tr {
  border-radius: 18px;
}

.dashboard-table-card tbody td {
  transition: background 0.18s ease;
}

th,
td {
  text-align: left;
  padding: 14px 12px;
  border-bottom: 1px solid #e5eaf3;
  vertical-align: top;
}

th {
  color: #475569;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

th.sortable {
  cursor: pointer;
  user-select: none;
}

th.sortable::after {
  content: " <>";
  opacity: 0.45;
}

th[data-sort-direction="asc"]::after {
  content: " ^";
  opacity: 1;
}

th[data-sort-direction="desc"]::after {
  content: " v";
  opacity: 1;
}

.inline-form {
  display: flex;
  gap: 8px;
  align-items: center;
}

.action-inline-form {
  margin: 0;
}

.action-chip {
  min-height: 36px;
  padding: 7px 10px;
  border-radius: 12px;
  gap: 6px;
  white-space: nowrap;
  font-size: 14px;
}

.action-chip-compact {
  min-height: 34px;
  padding: 7px 9px;
}

.nominee-grid {
  display: grid;
  gap: 18px;
}

.ballot-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  align-items: start;
}

.nominee-card,
.nominee-edit-card {
  overflow: hidden;
}

.nominee-photo {
  width: 100%;
  height: 240px;
  object-fit: cover;
  background: #e2e8f0;
}

.nominee-photo.small {
  width: 72px;
  height: 72px;
  border-radius: 16px;
}

.placeholder {
  display: grid;
  place-items: center;
  font-size: 42px;
  font-weight: 700;
  color: #475569;
}

.nominee-body {
  padding: 18px;
  display: grid;
  gap: 12px;
}

.ballot-candidate-card {
  border: 2px solid transparent;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.ballot-candidate-card.selected {
  border-color: rgba(37, 99, 235, 0.35);
  box-shadow: 0 22px 45px rgba(37, 99, 235, 0.12);
  background: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
}

.ballot-candidate-card:hover {
  transform: translateY(-3px);
}

.ballot-candidate-media {
  position: relative;
  padding: 16px 16px 0;
}

.ballot-candidate-photo {
  height: 260px;
  border-radius: 18px;
  object-fit: cover;
  object-position: center;
  background: linear-gradient(180deg, #e2e8f0, #cbd5e1);
}

.ballot-candidate-photo.placeholder {
  font-size: 54px;
}

.ballot-candidate-toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid #dbeafe;
  background: #eff6ff;
  color: #1d4ed8;
  font-weight: 700;
}

.ballot-candidate-toggle input {
  margin: 0;
}

.ballot-candidate-card input:disabled {
  background: #e2e8f0;
  color: #94a3b8;
  cursor: not-allowed;
}

.sticky-actions {
  position: sticky;
  bottom: 12px;
  background: #0f172a;
  color: #fff;
  border-radius: 18px;
  padding: 16px 18px;
  justify-content: space-between;
  align-items: center;
}

.sticky-actions .button[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
}

.ballot-status-text {
  min-width: min(100%, 320px);
  color: #cbd5e1;
}

.ballot-status-text.error {
  color: #fca5a5;
}

.ballot-status-text.success {
  color: #86efac;
}

.ballot-distribution-list {
  margin: 0;
  padding-left: 18px;
  color: #334155;
  display: grid;
  gap: 8px;
}

.ballot-distribution-list strong {
  color: #0f172a;
}

.countdown-card {
  background: #eff6ff;
  color: #0f172a;
  border-radius: 16px;
  padding: 18px;
  min-width: 260px;
  border: 1px solid rgba(148, 163, 184, 0.18);
}

.countdown-card span,
.countdown-card small {
  color: #64748b;
}

.countdown-card strong {
  color: #0f172a;
}

.countdown-card.countdown-ended {
  background: #fee2e2;
}

.global-timer-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.global-timer-banner small {
  font-size: 14px;
}

.empty-state {
  background: #f8fbff;
  border: 1px dashed #cfd9ea;
  padding: 20px;
  border-radius: 16px;
}

.nominee-list,
.winner-grid,
.ranking-list,
.activity-list {
  display: grid;
  gap: 16px;
}

.ranking-item,
.activity-item {
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 16px;
  background: #f8fbff;
}

.activity-item span,
.activity-item small,
.ranking-item small {
  display: block;
  margin-top: 4px;
  color: #64748b;
}

.candidate-progress-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 360px));
  gap: 20px;
  justify-content: start;
  align-items: start;
}

.candidate-progress-card {
  padding: 0;
  overflow: hidden;
  width: 100%;
  max-width: 360px;
}

.candidate-progress-media {
  position: relative;
  padding: 16px;
}

.candidate-progress-media .pill {
  position: absolute;
  left: 28px;
  bottom: 28px;
}

.candidate-progress-photo {
  width: 100%;
  height: 220px;
  border-radius: 20px;
  object-fit: cover;
  object-position: center 12%;
  background: linear-gradient(180deg, #e2e8f0, #cbd5e1);
  transform: scale(1.02);
}

.candidate-progress-body {
  padding: 0 20px 20px;
  display: grid;
  gap: 12px;
}

.nominee-edit-card {
  padding: 18px;
}

.nominee-summary-card p {
  margin: 0 0 12px;
}

.nominee-modal-preview {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nominee-group-list {
  display: grid;
  gap: 18px;
}

.nominee-management-section {
  display: block;
}

.nominee-table-panel {
  width: 100%;
}

.nominee-table-toolbar,
.voter-table-toolbar {
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 18px;
}

.nominee-toolbar-actions,
.voter-toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.nominee-table-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
}

.bulk-action-form {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.bulk-selection-count {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 12px;
  border-radius: 999px;
  background: #eef4ff;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.voter-action-pill {
  min-height: 42px;
  padding-inline: 14px;
}

.voter-registry-table-wrap {
  max-width: 100%;
  overflow-x: visible;
  overflow-y: visible;
  padding-bottom: 0;
}

.voter-registry-table {
  min-width: 0;
  width: 100%;
  overflow: visible;
}

.voter-registry-table th,
.voter-registry-table td {
  vertical-align: middle;
  padding: 12px 8px;
  overflow: visible;
}

.voter-registry-table tbody,
.voter-registry-table tr {
  overflow: visible;
}

.voter-registry-table td strong {
  font-size: 15px;
}

.voter-registry-table td small {
  font-size: 12px;
  line-height: 1.45;
}

.voter-select-column,
.voter-select-cell {
  width: 42px;
  text-align: center;
}

.voter-registry-table input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #2563eb;
}

.voter-actions-cell {
  position: relative;
  width: 88px;
  min-width: 88px;
  white-space: normal;
  overflow: visible;
}

.voter-action-menu {
  display: inline-block;
  position: relative;
}

.voter-action-menu summary {
  display: block;
  list-style: none;
  cursor: pointer;
}

.voter-menu-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  width: 100%;
  justify-content: center;
}

.voter-menu-list {
  min-width: 220px;
  right: 0;
  left: auto;
  z-index: 40;
}

.voter-menu-list .action-inline-form {
  display: block;
}

.voter-menu-action {
  width: 100%;
  justify-content: flex-start;
  min-height: 40px;
  border-radius: 12px;
  padding: 10px 12px;
  background: transparent;
  border-color: transparent;
  color: #0f172a;
}

.voter-menu-action:hover {
  background: #eff6ff;
}

.voter-menu-action.primary {
  color: #1d4ed8;
}

.voter-menu-action.danger {
  color: #dc2626;
}

body.theme-dark .voter-menu-action {
  color: #f1f5f9;
}

body.theme-dark .voter-menu-action:hover {
  background: rgba(59, 130, 246, 0.14);
}

body.theme-dark .voter-menu-action.primary {
  color: #93c5fd;
}

body.theme-dark .voter-menu-action.danger {
  color: #fca5a5;
}

.submit-progress-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(15, 23, 42, 0.56);
  backdrop-filter: blur(8px);
}

.submit-progress-overlay[hidden] {
  display: none !important;
}

.submit-progress-card {
  width: min(460px, calc(100vw - 32px));
  display: grid;
  gap: 16px;
  padding: 24px;
  border-radius: 24px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  border: 1px solid rgba(148, 163, 184, 0.18);
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.2);
}

.submit-progress-icon {
  width: 52px;
  height: 52px;
  display: inline-grid;
  place-items: center;
  border-radius: 16px;
  background: linear-gradient(135deg, #1d4ed8, #38bdf8);
  color: #fff;
  font-size: 18px;
}

.submit-progress-copy {
  display: grid;
  gap: 6px;
}

.submit-progress-copy strong {
  font-size: 22px;
  line-height: 1.15;
}

.submit-progress-copy p,
.submit-progress-card small {
  margin: 0;
  color: #64748b;
  line-height: 1.6;
}

.submit-progress-bar {
  margin-top: 0;
}

.nominee-lock-state {
  margin-bottom: 18px;
}

.nominee-empty-state {
  padding: 28px;
}

.signature-cell {
  min-width: 160px;
  height: 52px;
  border-bottom: 1px dashed #cbd5e1;
}

.nominee-group-card {
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  overflow: hidden;
}

.nominee-group-head {
  padding: 18px 18px 0;
}

.nominee-group-head .muted {
  margin-top: 6px;
}

.nominee-table {
  background: transparent;
}

.nominee-table-bio {
  max-width: 360px;
  color: #475569;
  line-height: 1.6;
}

.nominee-table-actions {
  flex-wrap: wrap;
  gap: 8px;
}

.nominee-table-actions form {
  margin: 0;
}

.nominee-table-avatar.placeholder {
  display: inline-grid;
  place-items: center;
  color: #1d4ed8;
  font-weight: 800;
}

body.theme-dark .nominee-group-card {
  background: linear-gradient(180deg, #0f172a 0%, #101b31 100%);
  border-color: rgba(148, 163, 184, 0.14);
}

body.theme-dark .nominee-toolbar-actions,
body.theme-dark .voter-toolbar-actions {
  color: #e2e8f0;
}

body.theme-dark .bulk-selection-count {
  background: rgba(37, 99, 235, 0.18);
  color: #bfdbfe;
}

body.theme-dark .submit-progress-card {
  background: linear-gradient(180deg, #0f172a 0%, #101b31 100%);
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: 0 28px 64px rgba(2, 6, 23, 0.42);
}

body.theme-dark .submit-progress-copy strong {
  color: #e2e8f0;
}

body.theme-dark .submit-progress-copy p,
body.theme-dark .submit-progress-card small {
  color: #94a3b8;
}

body.theme-dark .nominee-table-bio {
  color: #cbd5e1;
}

.message-popup {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 70;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: min(360px, calc(100vw - 32px));
  padding: 16px 18px;
  border-radius: 18px;
  background: #ffffff;
  border: 1px solid rgba(148, 163, 184, 0.18);
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.16);
  animation: auth-card-rise 0.25s ease;
}

.message-popup-copy {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.message-popup-copy strong {
  color: #0f172a;
}

.message-popup-copy span {
  color: #64748b;
  line-height: 1.5;
}

.message-popup-close {
  flex: 0 0 auto;
}

body.theme-dark .message-popup {
  background: #0f172a;
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: 0 24px 60px rgba(2, 6, 23, 0.42);
}

body.theme-dark .message-popup-copy strong {
  color: #e2e8f0;
}

body.theme-dark .message-popup-copy span {
  color: #94a3b8;
}

.nominee-edit-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

.password-box {
  display: grid;
  gap: 8px;
}

.password-value {
  background: #f8fafc;
  border: 1px solid #d9e2ef;
  border-radius: 10px;
  padding: 8px 10px;
}

small {
  color: #64748b;
}

.print-report-page {
  background: #eef2ff;
}

.print-report {
  max-width: 1040px;
  margin: 24px auto;
  background: #fff;
  border-radius: 24px;
  padding: 28px;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

.print-toolbar {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-bottom: 24px;
}

.print-header {
  border-bottom: 2px solid #dbeafe;
  padding-bottom: 18px;
  margin-bottom: 24px;
}

.print-header h1 {
  margin: 0 0 10px;
}

.print-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.print-card {
  border: 1px solid #dbeafe;
  border-radius: 16px;
  padding: 18px;
  background: #f8fbff;
}

.print-card span {
  display: block;
  color: #64748b;
  margin-bottom: 8px;
}

.print-card strong {
  font-size: 28px;
}

.print-section h2 {
  margin-top: 0;
}

.print-table {
  width: 100%;
  border-collapse: collapse;
}

.print-table th,
.print-table td {
  border: 1px solid #dbeafe;
  padding: 12px;
}

.report-center-hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
}

.report-center-copy {
  max-width: 720px;
}

.report-center-copy h3 {
  margin-bottom: 10px;
}

.report-center-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
}

.report-thumbnail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}

.report-thumbnail-card {
  display: grid;
  gap: 16px;
  padding: 20px;
  border-radius: 22px;
  border: 1px solid #dbe4f0;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.06);
  color: inherit;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.report-thumbnail-card:hover {
  transform: translateY(-2px);
  border-color: #bfdbfe;
  box-shadow: 0 20px 40px rgba(37, 99, 235, 0.12);
}

.report-thumbnail-icon {
  width: 52px;
  height: 52px;
  display: inline-grid;
  place-items: center;
  border-radius: 16px;
  background: linear-gradient(135deg, #dbeafe 0%, #eff6ff 100%);
  color: #2563eb;
}

.report-thumbnail-icon svg {
  width: 24px;
  height: 24px;
}

.report-thumbnail-copy {
  display: grid;
  gap: 8px;
}

.report-thumbnail-copy strong {
  font-size: 18px;
  color: #0f172a;
}

.report-thumbnail-copy p {
  margin: 0;
  color: #64748b;
  line-height: 1.55;
}

.report-thumbnail-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.report-thumbnail-metrics span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1e3a8a;
  font-size: 13px;
}

.report-winner-card {
  display: grid;
  gap: 12px;
}

.attendance-report-shell {
  display: grid;
  gap: 20px;
  margin-bottom: 24px;
}

.attendance-insight-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.9fr);
  gap: 18px;
}

.attendance-highlight-card,
.attendance-timeline-card {
  display: grid;
  gap: 16px;
}

.attendance-highlight-card h3,
.attendance-timeline-card h3 {
  margin: 0;
}

.attendance-highlight-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.attendance-highlight-pill {
  min-width: 150px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid #dbe4f0;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.attendance-highlight-pill span {
  display: block;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #64748b;
  margin-bottom: 6px;
}

.attendance-highlight-pill strong {
  font-size: 24px;
  color: #0f172a;
}

.attendance-timeline-list {
  display: grid;
  gap: 12px;
}

.attendance-timeline-item {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid #dbe4f0;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.attendance-timeline-item strong {
  color: #0f172a;
}

.attendance-timeline-item span {
  color: #64748b;
}

.attendance-summary-pills {
  justify-content: flex-end;
}

.professional-attendance-table td {
  vertical-align: middle;
}

.report-winner-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.report-winner-metrics span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1e3a8a;
}

.report-allocation-grid,
.vote-audit-group-list,
.report-action-list {
  display: grid;
  gap: 18px;
}

.report-allocation-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.report-allocation-card,
.vote-audit-group-card,
.report-action-item {
  border: 1px solid #dbe4f0;
  border-radius: 22px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.report-allocation-card,
.vote-audit-group-card {
  padding: 20px;
}

.report-allocation-head,
.vote-audit-group-head,
.report-action-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
}

.report-allocation-head h4,
.vote-audit-group-head h4 {
  margin-bottom: 6px;
}

.report-allocation-head p,
.vote-audit-group-head p {
  margin: 0;
  color: #64748b;
}

.report-allocation-summary {
  display: grid;
  gap: 8px;
  justify-items: end;
}

.report-allocation-summary span,
.report-action-item strong:last-child {
  color: #0f172a;
}

.report-allocation-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.report-allocation-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(239, 246, 255, 0.9);
}

.report-allocation-item span,
.report-action-item span {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 13px;
}

.report-action-item {
  padding: 16px 18px;
}

.print-winner-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.print-audit-group {
  margin-top: 20px;
}

.print-audit-group-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  font-size: 14px;
  color: #475569;
}

body.theme-dark .report-thumbnail-card,
body.theme-dark .report-allocation-card,
body.theme-dark .vote-audit-group-card,
body.theme-dark .report-action-item {
  background: linear-gradient(180deg, #0f172a 0%, #111c33 100%);
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: 0 18px 40px rgba(2, 6, 23, 0.34);
}

body.theme-dark .report-thumbnail-copy strong,
body.theme-dark .report-allocation-summary span,
body.theme-dark .report-action-item strong:last-child {
  color: #e2e8f0;
}

body.theme-dark .report-thumbnail-copy p,
body.theme-dark .report-allocation-head p,
body.theme-dark .vote-audit-group-head p,
body.theme-dark .report-allocation-item span,
body.theme-dark .report-action-item span {
  color: #94a3b8;
}

body.theme-dark .report-thumbnail-icon {
  background: rgba(37, 99, 235, 0.18);
  color: #93c5fd;
}

body.theme-dark .report-thumbnail-metrics span,
body.theme-dark .report-winner-metrics span,
body.theme-dark .report-allocation-item {
  background: rgba(30, 64, 175, 0.18);
  color: #bfdbfe;
}

body.theme-dark .attendance-highlight-pill,
body.theme-dark .attendance-timeline-item {
  background: linear-gradient(180deg, #0f172a 0%, #111c33 100%);
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: 0 18px 40px rgba(2, 6, 23, 0.24);
}

body.theme-dark .attendance-highlight-pill span,
body.theme-dark .attendance-timeline-item span {
  color: #94a3b8;
}

body.theme-dark .attendance-highlight-pill strong,
body.theme-dark .attendance-timeline-item strong {
  color: #e2e8f0;
}

@media (max-width: 900px) {
  .report-center-hero,
  .report-allocation-head,
  .vote-audit-group-head,
  .report-action-item,
  .print-audit-group-head {
    flex-direction: column;
  }

  .report-center-actions,
  .report-allocation-summary {
    justify-content: flex-start;
    justify-items: start;
  }

  .attendance-insight-grid {
    grid-template-columns: 1fr;
  }
}

.brand-preview-card {
  margin-top: 18px;
  padding: 18px;
  border-radius: 18px;
  background: #f8fbff;
  border: 1px solid #e2e8f0;
}

.brand-preview {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 12px;
}

.brand-preview-logo,
.brand-preview-fallback {
  width: 60px;
  height: 60px;
  border-radius: 16px;
  object-fit: cover;
  background: #dbeafe;
}

.brand-preview-fallback {
  display: grid;
  place-items: center;
  font-size: 24px;
  font-weight: 700;
  color: #1d4ed8;
}

.dashboard-grid-charts {
  grid-template-columns: repeat(3, 1fr);
}

.chart-surface {
  min-height: 260px;
}

.chart-empty {
  display: grid;
  place-items: center;
  min-height: 220px;
  color: #64748b;
  border: 1px dashed #cbd5e1;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.5);
}

.chart-bars {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(52px, 1fr));
  gap: 12px;
  align-items: end;
  min-height: 240px;
}

.chart-bar-item {
  display: grid;
  gap: 10px;
  align-items: end;
  justify-items: center;
}

.chart-bar-track {
  width: 100%;
  min-height: 170px;
  background: linear-gradient(180deg, #f8fbff, #edf5ff);
  border-radius: 16px;
  display: flex;
  align-items: end;
  overflow: hidden;
}

.chart-bar-track span {
  display: block;
  width: 100%;
  background: linear-gradient(180deg, #bfdbfe, #7dd3fc);
  border-radius: 16px 16px 0 0;
}

.chart-bar-value {
  font-size: 13px;
  color: #475569;
}

.chart-line-wrap {
  display: grid;
  gap: 14px;
}

.chart-line-svg {
  width: 100%;
  height: 210px;
  color: #60a5fa;
  background: linear-gradient(180deg, rgba(125, 211, 252, 0.18), rgba(147, 197, 253, 0.04));
  border-radius: 18px;
  padding: 18px;
}

.chart-axis-labels {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
  color: #64748b;
  font-size: 12px;
}

.chart-donut-wrap {
  display: grid;
  grid-template-columns: minmax(180px, 220px) 1fr;
  gap: 20px;
  align-items: center;
}

.chart-donut {
  width: 100%;
  height: auto;
}

.chart-total-label {
  fill: #64748b;
  font-size: 10px;
}

.chart-total-value {
  fill: currentColor;
  font-size: 14px;
  font-weight: 700;
}

.chart-legend {
  display: grid;
  gap: 10px;
}

.chart-legend-item {
  display: grid;
  grid-template-columns: 14px 1fr;
  gap: 8px 12px;
  align-items: center;
}

.chart-swatch {
  width: 14px;
  height: 14px;
  border-radius: 999px;
}

.rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #eff6ff;
  color: #2563eb;
  font-weight: 700;
}

body.theme-dark .rank-badge {
  background: rgba(59, 130, 246, 0.16);
  color: #93c5fd;
}

.table-person {
  display: flex;
  align-items: center;
  gap: 12px;
}

.table-avatar {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  object-fit: cover;
  background: #dbeafe;
}

.table-position-pill {
  display: inline-flex;
  padding: 7px 12px;
  border-radius: 999px;
  background: #f8fafc;
  color: #475569;
  border: 1px solid #e2e8f0;
}

body.theme-dark .table-position-pill {
  background: rgba(148, 163, 184, 0.08);
  color: #cbd5e1;
  border-color: rgba(148, 163, 184, 0.14);
}

.table-vote-count {
  color: #1d4ed8;
}

body.theme-dark .table-vote-count {
  color: #93c5fd;
}

.candidate-drawer {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  justify-content: flex-end;
}

.candidate-drawer[hidden] {
  display: none;
}

.candidate-drawer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(6px);
}

.candidate-drawer-panel {
  position: relative;
  z-index: 1;
  width: min(460px, calc(100vw - 20px));
  height: 100%;
  padding: 22px;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(20px);
  border-left: 1px solid rgba(148, 163, 184, 0.18);
  box-shadow: -20px 0 50px rgba(15, 23, 42, 0.12);
  overflow-y: auto;
}

body.theme-dark .candidate-drawer-panel {
  background: rgba(11, 19, 38, 0.92);
  border-left-color: rgba(148, 163, 184, 0.18);
  box-shadow: -20px 0 55px rgba(2, 6, 23, 0.42);
}

.candidate-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 18px;
}

.candidate-drawer-body {
  display: grid;
  gap: 18px;
}

.drawer-hero {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px;
  align-items: center;
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(125, 211, 252, 0.14));
  border: 1px solid rgba(148, 163, 184, 0.18);
}

body.theme-dark .drawer-hero {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.16), rgba(15, 23, 42, 0.68));
  border-color: rgba(148, 163, 184, 0.16);
}

.drawer-avatar {
  width: 78px;
  height: 78px;
  border-radius: 22px;
  object-fit: cover;
  background: #dbeafe;
}

.drawer-avatar.placeholder {
  font-size: 28px;
  font-weight: 700;
  color: #1d4ed8;
}

.drawer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.drawer-pill {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.18);
  color: #0f172a;
  font-size: 12px;
  font-weight: 700;
}

body.theme-dark .drawer-pill {
  background: rgba(15, 23, 42, 0.88);
  border-color: rgba(148, 163, 184, 0.14);
  color: #e2e8f0;
}

.drawer-section {
  padding: 18px;
  border-radius: 22px;
  background: rgba(248, 250, 252, 0.86);
  border: 1px solid rgba(148, 163, 184, 0.16);
}

body.theme-dark .drawer-section {
  background: rgba(15, 23, 42, 0.76);
  border-color: rgba(148, 163, 184, 0.16);
}

.drawer-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.drawer-stat {
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.14);
}

body.theme-dark .drawer-stat {
  background: rgba(2, 6, 23, 0.46);
  border-color: rgba(148, 163, 184, 0.14);
}

.drawer-stat span {
  display: block;
  margin-bottom: 8px;
  color: #64748b;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

body.theme-dark .drawer-stat span {
  color: #94a3b8;
}

.drawer-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.ballot-hero-panel {
  overflow: hidden;
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.2), transparent 26%),
    linear-gradient(135deg, #0f172a 0%, #1e3a8a 52%, #0f766e 100%);
  color: #fff;
}

.ballot-hero {
  display: grid;
  grid-template-columns: 1.5fr 0.9fr;
  gap: 24px;
  align-items: stretch;
}

.ballot-hero-copy {
  display: grid;
  gap: 14px;
}

.ballot-hero-copy h2 {
  margin: 0;
  font-size: 42px;
  line-height: 1.08;
}

.ballot-hero-copy p {
  margin: 0;
  max-width: 620px;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.6;
}

.ballot-rule-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 6px;
}

.ballot-rule-chip {
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(191, 219, 254, 0.16);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}

.ballot-hero-side {
  display: grid;
  gap: 16px;
}

.ballot-voter-card,
.ballot-sidebar-card {
  padding: 20px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(191, 219, 254, 0.16);
  backdrop-filter: blur(12px);
}

.ballot-voter-card span,
.ballot-voter-card small {
  color: rgba(255, 255, 255, 0.78);
}

.ballot-voter-card strong {
  display: block;
  font-size: 28px;
  line-height: 1.2;
  margin: 8px 0 6px;
}

.ballot-voter-status {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.ballot-hero-timer {
  min-width: 0;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(191, 219, 254, 0.16);
}

.ballot-hero-timer span,
.ballot-hero-timer small {
  color: rgba(255, 255, 255, 0.8);
}

.ballot-hero-timer strong {
  color: #fff;
}

.ballot-stats-panel {
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.ballot-stats-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.ballot-stat-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.08), transparent 28%),
    linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.ballot-stat-card.accent {
  background:
    radial-gradient(circle at top right, rgba(56, 189, 248, 0.16), transparent 30%),
    linear-gradient(180deg, #eff6ff 0%, #ffffff 100%);
}

.ballot-form-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(320px, 0.8fr);
  gap: 22px;
  align-items: start;
}

.ballot-form-layout.ballot-layout-gallery {
  grid-template-columns: minmax(0, 1.85fr) minmax(300px, 0.72fr);
  align-items: start;
}

.ballot-main {
  display: grid;
  gap: 20px;
}

.ballot-section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  margin-bottom: 4px;
}

.ballot-section-head h3 {
  margin: 0;
}

.ballot-table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 24px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.08);
}

.ballot-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: transparent;
}

.ballot-table thead th {
  padding: 16px 18px;
  background: rgba(37, 99, 235, 0.06);
  color: #475569;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.ballot-table tbody td {
  padding: 18px;
  vertical-align: middle;
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
}

.ballot-table tbody tr:last-child td {
  border-bottom: 0;
}

.ballot-candidate-row {
  transition: background 0.2s ease, box-shadow 0.2s ease;
}

.ballot-candidate-row.selected {
  background: rgba(219, 234, 254, 0.42);
}

.ballot-table-candidate {
  display: grid;
  grid-template-columns: 84px 1fr;
  gap: 14px;
  align-items: center;
}

.ballot-table-photo {
  width: 84px;
  height: 84px;
  border-radius: 22px;
  object-fit: cover;
  object-position: center 12%;
  background: linear-gradient(180deg, #dbe4f5, #cbd5e1);
}

.ballot-table-copy {
  display: grid;
  gap: 6px;
}

.ballot-table-copy strong {
  font-size: 20px;
  line-height: 1.2;
}

.ballot-table-copy small {
  line-height: 1.6;
}

.ballot-table-select-col {
  width: 1%;
  white-space: nowrap;
  text-align: right;
}

.ballot-share-field-inline {
  min-width: 140px;
  margin-top: 0;
}

.ballot-share-field-inline input {
  width: 100%;
}

.ballot-candidate-toggle-table {
  justify-self: end;
}

.ballot-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  align-items: stretch;
}

.ballot-grid.ballot-grid-single-row {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.ballot-grid.ballot-grid-two-rows {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.ballot-candidate-card {
  display: grid;
  grid-template-rows: auto 1fr;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 28px;
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.08), transparent 26%),
    linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.08);
}

.ballot-candidate-card.selected {
  border-color: rgba(37, 99, 235, 0.28);
  box-shadow: 0 24px 52px rgba(37, 99, 235, 0.14);
}

.ballot-candidate-card:hover {
  transform: translateY(-6px);
}

.ballot-candidate-media {
  position: relative;
  aspect-ratio: 4 / 4.8;
  overflow: hidden;
  padding: 0;
  border-radius: 28px 28px 0 0;
}

.ballot-candidate-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 12%;
  border-radius: 0;
  background: linear-gradient(180deg, #dbe4f5, #cbd5e1);
  transform: scale(1.03);
}

.ballot-candidate-photo.placeholder {
  font-size: 46px;
}

.ballot-candidate-media::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 45%;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0), rgba(15, 23, 42, 0.82));
  pointer-events: none;
}

.ballot-candidate-overlay {
  position: absolute;
  inset: auto 14px 14px 14px;
  z-index: 1;
  display: grid;
  gap: 10px;
  justify-items: start;
}

.ballot-candidate-overlay .pill {
  background: rgba(255, 255, 255, 0.88);
  color: #1e3a8a;
}

.ballot-candidate-position {
  max-width: 100%;
}

.ballot-candidate-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: auto;
  max-width: 100%;
  background: rgba(15, 23, 42, 0.78);
  border-color: rgba(255, 255, 255, 0.16);
  color: #fff;
  backdrop-filter: blur(12px);
  white-space: nowrap;
  padding: 8px 12px;
  font-size: 12px;
  line-height: 1;
}

.ballot-candidate-toggle span {
  display: inline-block;
}

.ballot-candidate-body {
  display: grid;
  gap: 12px;
  padding: 16px 16px 18px;
}

.ballot-candidate-heading {
  display: grid;
  gap: 6px;
}

.ballot-candidate-label {
  display: inline-flex;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  background: #dbeafe;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ballot-candidate-heading h3 {
  font-size: 22px;
  line-height: 1.2;
}

.ballot-share-field {
  margin-top: auto;
  padding: 12px;
  border-radius: 18px;
  background: rgba(15, 23, 42, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.14);
}

.ballot-share-field small {
  font-size: 12px;
}

.ballot-share-field input {
  background: #fff;
}

.ballot-sidebar {
  display: grid;
  gap: 18px;
  grid-template-columns: 1fr;
  align-items: start;
}

.ballot-summary-card.sticky-actions {
  position: sticky;
  top: 104px;
  display: grid;
  gap: 18px;
  padding: 22px;
  border-radius: 28px;
  background: linear-gradient(180deg, #08112d 0%, #0f172a 100%);
  border: 1px solid rgba(96, 165, 250, 0.16);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
}

.ballot-summary-head {
  display: grid;
  gap: 8px;
}

.ballot-summary-head h3 {
  margin: 0;
  color: #fff;
}

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

.ballot-summary-metric {
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(148, 163, 184, 0.12);
}

.ballot-summary-metric span {
  display: block;
  margin-bottom: 8px;
  color: #94a3b8;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.ballot-summary-metric strong {
  font-size: 28px;
  color: #fff;
}

.ballot-progress-stack {
  display: grid;
  gap: 10px;
}

.ballot-summary-card .progress-row span {
  color: #cbd5e1;
}

.ballot-summary-card .progress-row strong {
  color: #fff;
}

.ballot-balance-card {
  padding: 16px 18px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.24), rgba(14, 165, 233, 0.12));
  border: 1px solid rgba(147, 197, 253, 0.16);
}

.ballot-summary-timer {
  min-width: 0;
  padding: 16px 18px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.88), rgba(30, 41, 59, 0.96));
  border: 1px solid rgba(147, 197, 253, 0.16);
}

.ballot-summary-timer span,
.ballot-summary-timer small {
  color: #cbd5e1;
}

.ballot-summary-timer strong {
  color: #fff;
}

.ballot-summary-timer.countdown-ended {
  background: linear-gradient(135deg, rgba(127, 29, 29, 0.88), rgba(69, 10, 10, 0.96));
}

.ballot-balance-card span {
  display: block;
  margin-bottom: 8px;
  color: #bfdbfe;
}

.ballot-balance-card strong {
  display: block;
  font-size: 34px;
  line-height: 1.1;
  color: #fff;
}

.ballot-balance-card small {
  color: #dbeafe;
}

.ballot-submit-button {
  width: 100%;
  min-height: 54px;
  border-radius: 16px;
}

.ballot-summary-actions {
  display: grid;
  gap: 12px;
}

.ballot-equalize-button {
  width: 100%;
  min-height: 50px;
  border-radius: 16px;
}

.ballot-sidebar-card {
  background: linear-gradient(180deg, #f8fbff 0%, #eef5ff 100%);
  border: 1px solid rgba(148, 163, 184, 0.16);
}

.ballot-grid.ballot-grid-single-row .ballot-candidate-card {
  min-width: 0;
}

.ballot-grid.ballot-grid-single-row .ballot-candidate-toggle,
.ballot-grid.ballot-grid-two-rows .ballot-candidate-toggle {
  padding: 8px 10px;
  font-size: 12px;
}

.ballot-grid.ballot-grid-single-row .ballot-candidate-overlay .pill,
.ballot-grid.ballot-grid-two-rows .ballot-candidate-overlay .pill {
  padding: 7px 10px;
  font-size: 11px;
}

.ballot-grid.ballot-grid-single-row .ballot-candidate-body p,
.ballot-grid.ballot-grid-two-rows .ballot-candidate-body p {
  font-size: 14px;
  line-height: 1.6;
}

.ballot-rule-list {
  margin: 14px 0 0;
  padding-left: 20px;
  color: #475569;
  line-height: 1.8;
}

body.theme-dark .ballot-hero-panel {
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.16), transparent 28%),
    linear-gradient(135deg, #020617 0%, #10224d 52%, #0f3f46 100%);
}

body.theme-dark .ballot-voter-card,
body.theme-dark .ballot-hero-timer {
  background: rgba(15, 23, 42, 0.58);
  border-color: rgba(148, 163, 184, 0.18);
}

body.theme-dark .ballot-stats-panel,
body.theme-dark .ballot-stat-card,
body.theme-dark .ballot-candidate-card,
body.theme-dark .ballot-table-wrap,
body.theme-dark .ballot-sidebar-card {
  background:
    radial-gradient(circle at top right, rgba(59, 130, 246, 0.12), transparent 26%),
    linear-gradient(180deg, #0f172a 0%, #101b31 100%);
  border-color: rgba(148, 163, 184, 0.16);
}

body.theme-dark .ballot-table thead th {
  background: rgba(96, 165, 250, 0.08);
  color: #94a3b8;
  border-bottom-color: rgba(148, 163, 184, 0.16);
}

body.theme-dark .ballot-table tbody td {
  border-bottom-color: rgba(30, 41, 59, 0.9);
}

body.theme-dark .ballot-candidate-row.selected {
  background: rgba(37, 99, 235, 0.16);
}

body.theme-dark .ballot-candidate-label {
  background: rgba(37, 99, 235, 0.18);
  color: #bfdbfe;
}

body.theme-dark .ballot-share-field {
  background: rgba(148, 163, 184, 0.08);
  border-color: rgba(148, 163, 184, 0.14);
}

body.theme-dark .ballot-share-field input {
  background: #0b1220;
}

body.theme-dark .ballot-rule-list {
  color: #cbd5e1;
}

@keyframes progressPulse {
  0%, 100% {
    filter: saturate(1);
    opacity: 0.96;
  }

  50% {
    filter: saturate(1.12);
    opacity: 1;
  }
}

.chart-legend-item small {
  grid-column: 2;
}

.admin-list-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.admin-card {
  display: grid;
  gap: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 18px;
  background: #f8fbff;
}

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

.modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
}

.modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.56);
  backdrop-filter: blur(6px);
}

.modal-panel {
  position: relative;
  z-index: 1;
  width: min(720px, calc(100vw - 32px));
  max-height: calc(100vh - 40px);
  overflow: auto;
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
}

.modal-panel.modal-panel-wide {
  width: min(1180px, calc(100vw - 32px));
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 20px 24px 0;
}

.modal-body {
  padding: 20px 24px 24px;
}

body.modal-open {
  overflow: hidden;
}

.tour-modal-copy {
  display: grid;
  gap: 16px;
}

.tour-modal-copy p {
  margin: 0;
  line-height: 1.7;
}

.startup-modal-copy {
  gap: 20px;
}

.startup-modal-actions {
  justify-content: flex-end;
}

.tour-progress {
  font-size: 13px;
  font-weight: 700;
  color: #64748b;
}

.tour-highlight {
  position: relative;
  z-index: 2;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.24), 0 24px 54px rgba(15, 23, 42, 0.18);
  border-radius: 24px;
  transition: box-shadow 0.2s ease;
}

body.theme-dark .tour-progress {
  color: #94a3b8;
}

body.theme-dark .tour-highlight {
  box-shadow: 0 0 0 4px rgba(96, 165, 250, 0.32), 0 24px 54px rgba(2, 6, 23, 0.4);
}

@media print {
  .no-print {
    display: none !important;
  }

  .print-report-page {
    background: #fff;
  }

  .print-report {
    margin: 0;
    max-width: none;
    border-radius: 0;
    box-shadow: none;
    padding: 0;
  }
}

@media (max-width: 1100px) {
  .hero,
  .dashboard-grid,
  .dashboard-control-grid,
  .dashboard-info-grid,
  .dashboard-overview-grid,
  .dashboard-workspace-grid,
  .dashboard-bottom-grid,
  .register-shell,
  .ballot-hero,
  .ballot-form-layout,
  .auth-shell,
  .app-header-inner,
  .dashboard-grid-charts {
    grid-template-columns: 1fr;
  }

  .auth-stage {
    min-height: auto;
  }

  .election-page,
  .election-command-panel {
    grid-template-columns: 1fr;
  }

  .election-panel-head,
  .nominee-table-toolbar,
  .voter-table-toolbar {
    flex-direction: column;
  }

  .election-command-meta,
  .election-command-actions,
  .nominee-toolbar-actions,
  .voter-toolbar-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .election-kpi-strip {
    grid-template-columns: 1fr;
  }

  .election-summary-badge {
    width: 100%;
  }

  .election-command-actions .button {
    flex: 1 1 100%;
    width: 100%;
  }

  .ballot-hero-copy h2 {
    font-size: 34px;
  }
}

@media (max-width: 720px) {
  .election-settings-table th,
  .election-settings-table td {
    display: block;
    width: 100%;
  }

  .election-settings-table th {
    padding-bottom: 8px;
  }

  .election-settings-table td {
    padding-top: 0;
    padding-bottom: 16px;
  }

  .auth-window-grid {
    grid-template-columns: 1fr;
  }

  .auth-floating-card {
    position: static;
    width: auto;
    margin-top: 14px;
  }


  .app-header {
    padding: 16px;
  }

  .main-nav {
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 4px;
  }

  .topbar {
    flex-direction: column;
  }

  .header-user {
    justify-content: flex-start;
  }
}

@media (max-width: 820px) {
  .content {
    padding: 20px 14px 34px;
  }

  .app-header {
    padding: 12px 12px 0;
  }

  .app-header-inner {
    padding: 14px;
    gap: 14px;
  }

  .brand-wrap,
  .user-chip {
    min-width: 0;
  }

  .table-toolbar {
    justify-content: stretch;
  }

  table[data-enhanced-table],
  table[data-enhanced-table] thead,
  table[data-enhanced-table] tbody,
  table[data-enhanced-table] th,
  table[data-enhanced-table] td,
  table[data-enhanced-table] tr {
    display: block;
  }

  table[data-enhanced-table] thead {
    display: none;
  }

  table[data-enhanced-table] tbody tr {
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    margin-bottom: 14px;
    padding: 10px 12px;
    background: inherit;
  }

  table[data-enhanced-table] td {
    border-bottom: 1px dashed #dbe4f0;
    padding: 12px 0;
  }

  table[data-enhanced-table] td:last-child {
    border-bottom: 0;
  }

  table[data-enhanced-table] td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #64748b;
  }

  body.theme-dark table[data-enhanced-table] tbody tr {
    border-color: #23324c;
  }

  body.theme-dark table[data-enhanced-table] td {
    border-bottom-color: #23324c;
  }

  .chart-donut-wrap {
    grid-template-columns: 1fr;
  }

  .hero-countdown-grid,
  .mini-metrics,
  .dashboard-hero-meta,
  .dashboard-kpi-grid,
  .dashboard-activity-grid,
  .ballot-stats-grid,
  .ballot-summary-metrics {
    grid-template-columns: 1fr;
  }

  .stat-pill-row,
  .table-head-actions,
  .dashboard-hero-actions {
    width: 100%;
  }

  .attendance-options {
    grid-template-columns: 1fr;
  }

  .table-head-actions {
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .layout-sidebar .shell {
    flex-direction: column;
  }

  .mobile-nav-toggle {
    display: inline-flex;
  }

  .side-nav {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    transform: translateX(-110%);
    transition: transform 0.2s ease;
    z-index: 50;
    width: min(320px, 92vw);
  }

  .side-nav.open {
    transform: translateX(0);
  }

  .dashboard-top-grid {
    grid-template-columns: 1fr;
  }

  .election-progress-meta,
  .election-progress-kpis,
  .election-progress-feeds {
    grid-template-columns: 1fr;
  }

  .election-live-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .live-sync-badge {
    width: 100%;
  }

  .hero-panel {
    grid-template-columns: 1fr;
  }

  .system-grid,
  .snapshot-grid,
  .dashboard-detail-grid,
  .dashboard-nominee-focus-body {
    grid-template-columns: 1fr;
  }

  .detail-chip-wide,
  .snapshot-item-wide {
    grid-column: auto;
  }

  .timer-cards {
    grid-template-columns: repeat(3, 1fr);
  }

  .candidate-row {
    grid-template-columns: 1fr;
  }

  .ballot-grid,
  .candidate-progress-grid {
    grid-template-columns: 1fr;
  }

  .election-candidate-picker-grid {
    grid-template-columns: 1fr;
  }

  .election-candidate-card {
    grid-template-columns: 56px minmax(0, 1fr);
  }

  .election-candidate-card-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .election-candidate-card-photo {
    width: 56px;
    height: 56px;
  }

  .election-candidate-pagination {
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .election-candidate-detail-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .ballot-table,
  .ballot-table thead,
  .ballot-table tbody,
  .ballot-table th,
  .ballot-table td,
  .ballot-table tr {
    display: block;
  }

  .ballot-table thead {
    display: none;
  }

  .ballot-table tbody tr {
    padding: 16px;
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  }

  .ballot-table tbody td {
    padding: 10px 0;
    border-bottom: 0;
  }

  .ballot-table-select-col {
    text-align: left;
  }

  .ballot-table-candidate {
    grid-template-columns: 72px 1fr;
  }

  .ballot-table-photo {
    width: 72px;
    height: 72px;
  }

  .ballot-sidebar {
    grid-template-columns: 1fr;
  }

  .sticky-actions,
  .global-timer-banner {
    flex-direction: column;
    align-items: flex-start;
  }

  .ballot-section-head,
  .ballot-candidate-overlay {
    flex-direction: column;
    align-items: flex-start;
  }

  .ballot-summary-card.sticky-actions {
    position: static;
    top: auto;
  }

  .countdown-card {
    min-width: 0;
    width: 100%;
  }

  .ballot-hero-copy h2 {
    font-size: 30px;
  }

  .ballot-rule-chips {
    gap: 8px;
  }

  .ballot-rule-chip {
    width: 100%;
    justify-content: center;
  }

  .ballot-voter-card,
  .ballot-sidebar-card,
  .countdown-card,
  .empty-state {
    padding: 16px;
    border-radius: 18px;
  }

  .split-header {
    gap: 14px;
  }

  .ballot-section-head h3,
  .ballot-summary-head h3 {
    font-size: 22px;
  }
}

@media (max-width: 560px) {
  .ballot-hero-copy h2 {
    font-size: 26px;
  }

  .ballot-hero-copy p,
  .ballot-table-copy small,
  .ballot-status-text,
  .empty-state p {
    font-size: 14px;
    line-height: 1.5;
  }

  .ballot-voter-card strong {
    font-size: 22px;
  }

  .ballot-table tbody tr {
    padding: 14px;
    border-radius: 16px;
  }

  .ballot-table-candidate {
    grid-template-columns: 56px 1fr;
    gap: 12px;
  }

  .ballot-table-photo {
    width: 56px;
    height: 56px;
  }

  .ballot-share-field-inline {
    width: 100%;
  }

  .ballot-share-field-inline input {
    width: 100%;
  }

  .ballot-candidate-toggle-table {
    width: 100%;
    justify-content: center;
  }

  .ballot-submit-button,
  .startup-modal-actions .button {
    width: 100%;
  }
}
