:root {
  --red: #d9252a;
  --red-dark: #a7191e;
  --navy: #172033;
  --charcoal: #202532;
  --muted: #687386;
  --line: #e5e9f0;
  --surface: #f6f8fb;
  --white: #ffffff;
  --green: #12885a;
  --green-soft: #e8f7ef;
  --amber: #b7791f;
  --amber-soft: #fff5df;
  --red-soft: #fff0f0;
  --shadow: 0 14px 40px rgba(23, 32, 51, 0.08);
  --radius: 8px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--surface);
  color: var(--charcoal);
  font-size: 15px;
  line-height: 1.45;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(217, 37, 42, 0.28);
  outline-offset: 2px;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 264px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 22px 18px;
  background: #111827;
  color: var(--white);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 8px;
  color: inherit;
  background: transparent;
  border: 0;
  text-align: left;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: var(--red);
  overflow: hidden;
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

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

.brand small,
.admin-card small {
  color: #aeb7c6;
  margin-top: 2px;
}

.main-nav {
  display: grid;
  gap: 7px;
}

.nav-item,
.presentation-button {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: #d8deea;
  background: transparent;
}

.nav-item:hover,
.presentation-button:hover,
.nav-item.active {
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
}

.nav-item.active {
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: inset 3px 0 0 var(--red);
}

.sidebar svg {
  width: 18px;
  height: 18px;
}

.sidebar-foot {
  margin-top: auto;
  display: grid;
  gap: 14px;
}

.presentation-button {
  background: rgba(217, 37, 42, 0.16);
  color: var(--white);
}

.admin-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
}

.main {
  min-width: 0;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 16px 28px;
  background: rgba(246, 248, 251, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.eyebrow {
  margin: 0 0 3px;
  display: none;
  color: var(--red);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.topbar h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.15;
}

.topbar-title {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.topbar-title>img,
.topbar-logo {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--red);
  overflow: hidden;
  flex: 0 0 auto;
  box-shadow: 0 10px 24px rgba(217, 37, 42, 0.16);
}

.topbar-title>img,
.topbar-logo img {
  object-fit: cover;
}

.topbar-title>img {
  display: none;
}

.topbar-logo {
  display: grid;
  place-items: center;
}

.topbar-logo img {
  width: 100%;
  height: 100%;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.searchbox {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(320px, 26vw);
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
}

.searchbox input {
  width: 100%;
  border: 0;
  outline: 0;
}

.content {
  padding: 26px 28px 42px;
}

.fade-in {
  animation: fadeIn 420ms ease both;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
}

.hero-grid,
.dashboard-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(320px, 0.8fr);
  gap: 18px;
  margin-bottom: 18px;
}

.story-panel,
.mission-snapshot,
.panel,
.kpi-card,
.volunteer-card,
.need-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.story-panel {
  min-height: 280px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 28px;
  overflow: hidden;
  position: relative;
}

.story-panel::after {
  content: "";
  position: absolute;
  right: -120px;
  top: -120px;
  width: 360px;
  height: 360px;
  border: 42px solid rgba(217, 37, 42, 0.08);
  border-radius: 50%;
}

.section-heading {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.section-heading h2,
.page-intro h2,
.mobilization-hero h2,
.profile-hero h2,
.mission-header h2 {
  margin: 10px 0 10px;
  color: var(--navy);
  font-size: clamp(32px, 4.4vw, 56px);
  line-height: 1.05;
  letter-spacing: 0;
}

.section-heading p,
.page-intro p,
.panel-head p,
.mobilization-hero p,
.profile-main p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.hero-actions,
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  position: relative;
  z-index: 1;
}

.primary-button,
.secondary-button,
.danger-button,
.ghost-button,
.secondary-dark-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 14px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-weight: 800;
  text-decoration: none;
}

.primary-button {
  background: var(--red);
  color: var(--white);
}

.primary-button:hover {
  background: var(--red-dark);
}

.secondary-button {
  background: var(--white);
  color: var(--navy);
  border-color: var(--line);
}

.secondary-button:hover {
  border-color: #cbd3df;
  background: #fbfcfe;
}

.danger-button {
  background: #fff1f1;
  color: var(--red-dark);
  border-color: #ffd2d2;
}

.ghost-button {
  background: transparent;
  color: var(--muted);
  border-color: var(--line);
}

.secondary-dark-button {
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.18);
}

.full {
  width: 100%;
}

.icon-button {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--charcoal);
}

.icon-button svg,
.primary-button svg,
.secondary-button svg,
.danger-button svg {
  width: 18px;
  height: 18px;
}

.mission-snapshot {
  padding: 20px;
}

.snapshot-top {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--red-dark);
  font-size: 13px;
  font-weight: 900;
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 99px;
  background: var(--green);
}

.status-dot.critical {
  background: var(--red);
  box-shadow: 0 0 0 7px rgba(217, 37, 42, 0.12);
}

.status-dot.warning {
  background: var(--amber);
  box-shadow: 0 0 0 7px rgba(183, 121, 31, 0.13);
}

.mission-snapshot h3 {
  margin: 16px 0;
  font-size: 24px;
}

.snapshot-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

.snapshot-grid span {
  padding: 12px;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
}

.snapshot-grid svg {
  width: 17px;
  height: 17px;
  margin-bottom: 6px;
  color: var(--red);
}

.snapshot-grid strong {
  display: block;
  color: var(--navy);
  font-size: 24px;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(150px, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.kpi-card {
  position: relative;
  padding: 18px;
  overflow: hidden;
}

.kpi-card svg {
  position: absolute;
  right: 14px;
  top: 14px;
  width: 34px;
  height: 34px;
  padding: 7px;
  border-radius: var(--radius);
  background: var(--red-soft);
  color: var(--red);
}

.kpi-card span,
.kpi-card small {
  display: block;
  color: var(--muted);
}

.kpi-card strong {
  display: block;
  margin: 12px 0 4px;
  color: var(--navy);
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1;
}

.dashboard-operational-grid,
.dashboard-insight-grid,
.dashboard-grid,
.profile-grid {
  display: grid;
  gap: 18px;
}

.dashboard-operational-grid {
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
  align-items: stretch;
  margin-bottom: 18px;
}

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

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

.panel {
  padding: 20px;
}

.panel.wide {
  grid-column: 1 / -1;
}

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

.panel-head h2 {
  margin: 0;
  color: var(--navy);
  font-size: 20px;
}

.map-panel {
  grid-row: auto;
}

.real-map-panel {
  grid-row: auto;
}

.real-map {
  position: relative;
  min-height: 420px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(217, 37, 42, 0.08), transparent 44%),
    #e9f1f5;
}

.map-mission-focus {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  margin-top: 12px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfe;
}

.map-mission-focus strong,
.map-mission-focus small,
.map-focus-actions span {
  display: block;
}

.map-mission-focus strong {
  margin: 5px 0 2px;
  color: var(--navy);
  font-size: 18px;
}

.map-mission-focus small,
.map-focus-actions span {
  color: var(--muted);
}

.map-focus-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.map-focus-actions span {
  font-weight: 900;
}

.real-map .leaflet-control-attribution {
  font-size: 10px;
}

.map-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 800;
}

.bsmi-map-icon {
  display: grid;
  place-items: center;
}

.bsmi-map-icon span {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 3px solid var(--white);
  border-radius: 999px;
  background: var(--green);
  color: var(--white);
  box-shadow: 0 10px 26px rgba(17, 24, 39, 0.25), 0 0 0 0 rgba(217, 37, 42, 0.36);
  font-weight: 950;
  animation: pulse 2.2s infinite;
}

.bsmi-map-icon.critical span {
  background: var(--red);
}

.bsmi-map-icon.warning span {
  background: var(--amber);
}

.bsmi-map-icon.active span {
  width: 38px;
  height: 38px;
  border-width: 4px;
}

.fallback-map-grid {
  position: absolute;
  inset: 14px;
  z-index: 2;
  display: grid;
  align-content: center;
  gap: 10px;
}

.fallback-map-grid button {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.92);
  text-align: left;
}

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

.fallback-map-grid span {
  color: var(--muted);
  font-size: 12px;
}

.indonesia-map {
  position: relative;
  height: 330px;
  margin: 8px 0 14px;
  border-radius: var(--radius);
  background: linear-gradient(180deg, #eef5f9, #f8fbfd);
  overflow: hidden;
}

.map-island {
  position: absolute;
  height: 28px;
  border-radius: 999px;
  background: #d6e6df;
  transform: rotate(-8deg);
}

.island-a {
  left: 7%;
  top: 39%;
  width: 31%;
}

.island-b {
  left: 38%;
  top: 64%;
  width: 28%;
}

.island-c {
  left: 56%;
  top: 42%;
  width: 18%;
  transform: rotate(12deg);
}

.island-d {
  left: 72%;
  top: 60%;
  width: 13%;
  transform: rotate(22deg);
}

.island-e {
  left: 84%;
  top: 56%;
  width: 12%;
  height: 42px;
  transform: rotate(-18deg);
}

.region-marker {
  position: absolute;
  width: 15px;
  height: 15px;
  border: 3px solid var(--white);
  border-radius: 999px;
  background: var(--red);
  box-shadow: 0 0 0 0 rgba(217, 37, 42, 0.4);
  animation: pulse 2.2s infinite;
}

.region-marker.active {
  background: var(--green);
}

@keyframes pulse {
  70% {
    box-shadow: 0 0 0 15px rgba(217, 37, 42, 0);
  }
}

.region-detail {
  display: grid;
  grid-template-columns: 1.2fr repeat(5, 1fr);
  gap: 10px;
  align-items: stretch;
}

.region-detail h3,
.region-detail div {
  margin: 0;
  padding: 12px;
  border-radius: var(--radius);
  background: var(--surface);
}

.region-detail strong,
.region-detail span {
  display: block;
}

.region-detail span {
  color: var(--muted);
  font-size: 12px;
}

.mission-stack-panel {
  display: flex;
  flex-direction: column;
}

.mission-stack {
  display: grid;
  gap: 10px;
}

.dashboard-mission-brief {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.dashboard-mission-brief span,
.dashboard-mission-brief strong,
.dashboard-mission-brief small {
  display: block;
}

.dashboard-mission-brief span {
  color: var(--red);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.dashboard-mission-brief strong {
  margin: 3px 0;
  color: var(--navy);
}

.dashboard-mission-brief small {
  color: var(--muted);
}

.mission-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.mission-card.active {
  border-color: rgba(217, 37, 42, 0.42);
  background: #fff7f7;
}

.mission-card:hover {
  transform: translateY(-2px);
}

.mission-card button {
  display: grid;
  gap: 8px;
  width: 100%;
  padding: 14px;
  border: 0;
  background: transparent;
  text-align: left;
}

.mission-type {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--red);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.mission-type svg {
  width: 15px;
  height: 15px;
}

.mission-card strong {
  color: var(--navy);
  font-size: 18px;
}

.mission-card small {
  color: var(--muted);
}

.mission-card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

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

.bar-row {
  display: grid;
  grid-template-columns: 128px 1fr 46px;
  align-items: center;
  gap: 10px;
  font-size: 13px;
}

.bar-row div,
.progress,
.quota div {
  height: 10px;
  border-radius: 99px;
  background: #edf1f6;
  overflow: hidden;
}

.bar-row b,
.progress b,
.quota b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--red);
}

.org-flow {
  display: grid;
  gap: 8px;
}

.org-flow span {
  padding: 11px 13px;
  border-radius: var(--radius);
  background: var(--surface);
  font-weight: 800;
}

.org-flow svg {
  margin-left: 10px;
  color: var(--muted);
}

.page-intro,
.mobilization-hero,
.profile-hero {
  margin-bottom: 18px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.page-intro {
  max-width: none;
}

.pill,
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.pill svg {
  width: 14px;
  height: 14px;
}

.pill.red,
.badge.critical {
  color: var(--red-dark);
  background: var(--red-soft);
}

.pill.critical {
  color: var(--white);
  background: var(--red);
}

.badge.positive {
  color: var(--green);
  background: var(--green-soft);
}

.badge.warning {
  color: var(--amber);
  background: var(--amber-soft);
}

.badge.neutral {
  color: #4a5668;
  background: #eef2f7;
}

.filters {
  display: grid;
  grid-template-columns: 1.2fr repeat(5, minmax(130px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.filters label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.filters input,
.filters select {
  width: 100%;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--charcoal);
}

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

.volunteer-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 16px;
  transition: transform 180ms ease, border-color 180ms ease;
}

.volunteer-card:hover {
  transform: translateY(-2px);
  border-color: #cfd7e4;
}

.avatar {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: linear-gradient(135deg, #d9252a, #111827);
  color: var(--white);
  font-weight: 900;
}

.avatar-sm {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  font-size: 13px;
}

.avatar-lg {
  width: 108px;
  height: 108px;
  border-radius: 22px;
  font-size: 32px;
}

.volunteer-info h3,
.cert-card h3,
.training-card h2 {
  margin: 0 0 6px;
  color: var(--navy);
}

.volunteer-info p,
.cert-card p,
.training-card p {
  margin: 0 0 10px;
  color: var(--muted);
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag-cloud span {
  padding: 5px 8px;
  border-radius: 999px;
  background: #eef2f7;
  color: #4e5b6d;
  font-size: 12px;
  font-weight: 800;
}

.volunteer-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.profile-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
}

.profile-main {
  display: flex;
  align-items: center;
  gap: 18px;
}

.breadcrumb {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(2, 150px);
  gap: 10px;
}

.profile-stats div {
  padding: 13px;
  border-radius: var(--radius);
  background: var(--surface);
}

.profile-stats strong,
.profile-stats span {
  display: block;
}

.profile-stats strong {
  color: var(--navy);
  font-size: 28px;
}

.profile-stats span {
  color: var(--muted);
  font-size: 12px;
}

.ekta-card {
  perspective: 1200px;
  margin-bottom: 14px;
}

.ekta-inner {
  position: relative;
  min-height: 248px;
  transform-style: preserve-3d;
  transition: transform 520ms ease;
}

.ekta-card.flipped .ekta-inner {
  transform: rotateY(180deg);
}

.ekta-face {
  position: absolute;
  inset: 0;
  padding: 20px;
  border-radius: 18px;
  overflow: hidden;
  backface-visibility: hidden;
  color: var(--white);
  background: linear-gradient(135deg, #a7191e, #d9252a 52%, #182033);
}

.ekta-face::after {
  content: "";
  position: absolute;
  right: -70px;
  bottom: -110px;
  width: 250px;
  height: 250px;
  border: 34px solid rgba(255, 255, 255, 0.11);
  border-radius: 50%;
}

.ekta-back {
  display: grid;
  place-items: center;
  text-align: center;
  transform: rotateY(180deg);
}

.ekta-top span,
.ekta-top b {
  display: block;
}

.ekta-top span {
  font-size: 12px;
  opacity: 0.82;
}

.ekta-body {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 16px;
  align-items: end;
  margin-top: 34px;
}

.ekta-body h3,
.ekta-body p {
  margin: 0 0 7px;
}

.qr {
  width: 70px;
  height: 70px;
  border: 8px solid var(--white);
  background:
    linear-gradient(90deg, #111 10px, transparent 10px) 0 0 / 20px 20px,
    linear-gradient(#111 10px, transparent 10px) 0 0 / 20px 20px,
    var(--white);
}

.qr.large {
  width: 118px;
  height: 118px;
}

.skill-row {
  display: grid;
  grid-template-columns: 150px 1fr 48px;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.progress-fill {
  width: 0;
  transition: width 900ms ease;
}

.cert-list {
  display: grid;
  gap: 10px;
}

.cert-card {
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.cert-card span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 13px;
}

.level-track {
  display: grid;
  gap: 10px;
}

.level-track>div {
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 8px 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.level-track span {
  grid-row: span 3;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: #eef2f7;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.level-track .done span,
.level-track .current span {
  background: var(--green-soft);
  color: var(--green);
}

.level-track strong,
.level-track p,
.level-track small {
  margin: 0;
}

.level-track p,
.level-track small {
  color: var(--muted);
  font-size: 12px;
}

.progress-card {
  margin-top: 12px;
  padding: 13px;
  border-radius: var(--radius);
  background: var(--red-soft);
}

.timeline {
  display: grid;
  gap: 12px;
}

.timeline article {
  position: relative;
  padding: 0 0 0 24px;
  animation: fadeIn 500ms ease both;
}

.timeline article::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 99px;
  background: var(--red);
}

.timeline time {
  color: var(--red-dark);
  font-size: 12px;
  font-weight: 900;
}

.timeline h3,
.timeline p {
  margin: 4px 0;
}

.timeline span {
  color: var(--muted);
  font-size: 13px;
}

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

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

.training-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: var(--radius);
  background: var(--red-soft);
  color: var(--red);
}

.quota span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.mobilization-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, #fff, #fff6f6);
}

.mission-switcher {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.mission-switcher button {
  display: grid;
  gap: 4px;
  min-height: 84px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  text-align: left;
  transition: border-color 180ms ease, transform 180ms ease;
}

.mission-switcher button:hover,
.mission-switcher button.active {
  transform: translateY(-1px);
  border-color: rgba(217, 37, 42, 0.45);
}

.mission-switcher button.active {
  background: var(--red-soft);
}

.mission-switcher span,
.mission-switcher small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.mission-switcher strong {
  color: var(--navy);
}

.mission-switcher.dark {
  margin: 0 0 16px;
}

.mission-switcher.dark button {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.12);
}

.mission-switcher.dark button.active {
  background: rgba(217, 37, 42, 0.22);
}

.mission-switcher.dark strong {
  color: var(--white);
}

.mission-needs {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.need-card {
  padding: 16px;
}

.need-card span,
.need-card strong,
.need-card b {
  display: block;
}

.need-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.need-card strong {
  margin: 8px 0;
  color: var(--navy);
}

.need-card b {
  color: var(--red);
  font-size: 34px;
}

.matching-idle,
.match-complete {
  display: grid;
  place-items: center;
  min-height: 180px;
  text-align: center;
  color: var(--muted);
}

.matching-idle svg,
.match-complete svg {
  width: 58px;
  height: 58px;
  color: var(--red);
}

.matching-steps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  overflow: hidden;
}

.match-step {
  min-height: 132px;
  display: grid;
  place-items: center;
  padding: 16px;
  border-radius: var(--radius);
  background: var(--surface);
  text-align: center;
  opacity: 0;
  animation: stepReveal 700ms ease forwards;
}

.match-step strong {
  color: var(--red);
  font-size: 34px;
}

.match-step span {
  color: var(--muted);
}

.step-2 {
  animation-delay: 650ms;
}

.step-3 {
  animation-delay: 1300ms;
}

.step-4 {
  animation-delay: 1950ms;
}

.step-5 {
  animation-delay: 2600ms;
}

@keyframes stepReveal {
  to {
    opacity: 1;
    transform: translateY(0);
  }

  from {
    transform: translateY(14px);
  }
}

.candidate-panel,
.broadcast-panel {
  margin-top: 18px;
}

.candidate-list,
.response-list {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

.candidate-row,
.response-list article {
  display: grid;
  grid-template-columns: auto 1fr auto auto auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.candidate-row small,
.candidate-row b,
.candidate-row em {
  color: var(--muted);
  font-style: normal;
}

.broadcast-visual {
  display: grid;
  place-items: center;
  gap: 8px;
  min-height: 150px;
  margin-bottom: 14px;
  border-radius: var(--radius);
  background: var(--navy);
  color: var(--white);
  text-align: center;
}

.broadcast-visual svg {
  width: 42px;
  height: 42px;
  color: var(--red);
}

.broadcast-visual h2,
.broadcast-visual p {
  margin: 0;
}

.assignment-ready {
  padding: 16px;
  border-radius: var(--radius);
  background: var(--green-soft);
}

.assignment-ready h3,
.assignment-ready p {
  margin: 0 0 10px;
}

.mission-control {
  min-height: calc(100vh - 128px);
  padding: 22px;
  border-radius: var(--radius);
  background: #101725;
  color: var(--white);
}

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

.mission-header h2 {
  color: var(--white);
}

.mission-header p {
  color: #aeb7c6;
}

.mission-kpis {
  display: grid;
  grid-template-columns: repeat(7, minmax(100px, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.mission-kpis article {
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.06);
}

.mission-kpis strong,
.mission-kpis span {
  display: block;
}

.mission-kpis strong {
  font-size: 30px;
}

.mission-kpis span {
  color: #aeb7c6;
  font-size: 12px;
}

.mission-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 16px;
}

.live-map {
  position: relative;
  min-height: 520px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  background:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px) 0 0 / 38px 38px,
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px) 0 0 / 38px 38px,
    radial-gradient(circle at 45% 50%, rgba(217, 37, 42, 0.22), transparent 32%),
    #141e30;
  overflow: hidden;
}

.route {
  position: absolute;
  height: 3px;
  background: repeating-linear-gradient(90deg, var(--red), var(--red) 12px, transparent 12px, transparent 22px);
  transform-origin: left;
  animation: routeMove 1.1s linear infinite;
}

.route-a {
  left: 43%;
  top: 42%;
  width: 210px;
  transform: rotate(14deg);
}

.route-b {
  left: 37%;
  top: 62%;
  width: 260px;
  transform: rotate(-18deg);
}

@keyframes routeMove {
  to {
    background-position: 22px 0;
  }
}

.field-pin {
  position: absolute;
  min-width: 122px;
  min-height: 34px;
  padding: 0 9px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(18, 136, 90, 0.92);
  color: var(--white);
  font-size: 12px;
  font-weight: 900;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 0 rgba(18, 136, 90, 0.48);
  animation: fieldPulse 2s infinite;
}

.field-pin.sar,
.field-pin.logistics {
  background: rgba(183, 121, 31, 0.95);
}

.field-pin.ambulance,
.field-pin.base {
  background: rgba(217, 37, 42, 0.95);
}

@keyframes fieldPulse {
  70% {
    box-shadow: 0 0 0 16px rgba(18, 136, 90, 0);
  }
}

.team-panel {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.06);
}

.team-panel h3 {
  margin: 0;
}

.team-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.05);
  color: var(--white);
  text-align: left;
}

.team-row small,
.activity-feed time {
  display: block;
  color: #aeb7c6;
}

.activity-feed {
  display: grid;
  gap: 10px;
}

.activity-feed p {
  margin: 0;
  padding: 10px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.05);
  color: #d7deeb;
}

.line-mock {
  display: flex;
  align-items: end;
  gap: 12px;
  height: 220px;
  padding: 18px;
  border-radius: var(--radius);
  background: var(--surface);
}

.line-mock span {
  flex: 1;
  border-radius: 999px 999px 0 0;
  background: linear-gradient(180deg, var(--red), #f4b5b7);
}

.matrix-table {
  display: grid;
  gap: 8px;
}

.matrix-table article {
  display: grid;
  grid-template-columns: 1fr 1fr 1.3fr;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
}

.matrix-table strong {
  color: var(--navy);
}

.volunteer-demo-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  gap: 18px;
  align-items: center;
  margin-bottom: 18px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.volunteer-demo-hero h2 {
  margin: 10px 0;
  color: var(--navy);
  font-size: clamp(30px, 4vw, 50px);
  line-height: 1.05;
}

.volunteer-demo-hero p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.portal-identity-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-radius: var(--radius);
  background: var(--surface);
}

.portal-logo-badge {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 14px;
  background: var(--red);
  overflow: hidden;
  flex: 0 0 auto;
}

.portal-logo-badge img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.portal-identity-card strong,
.portal-identity-card span,
.portal-identity-card small {
  display: block;
}

.portal-identity-card span,
.portal-identity-card small {
  color: var(--muted);
}

.portal-volunteer-picker {
  margin-bottom: 18px;
}

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

.portal-picker-list button {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 6px 10px;
  align-items: center;
  min-height: 74px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  text-align: left;
}

.portal-picker-list button.active {
  border-color: rgba(217, 37, 42, 0.42);
  background: var(--red-soft);
}

.portal-picker-list .avatar {
  grid-row: span 2;
}

.portal-picker-list strong {
  color: var(--navy);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.portal-picker-list small {
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.portal-layout {
  display: grid;
  grid-template-columns: minmax(280px, 380px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.phone-frame {
  position: sticky;
  top: 96px;
  grid-row: 1 / span 3;
}

.phone-shell {
  display: grid;
  gap: 14px;
  max-width: 380px;
  min-height: 640px;
  padding: 18px;
  border: 12px solid #111827;
  border-radius: 34px;
  background: #f7f9fc;
  box-shadow: 0 24px 70px rgba(17, 24, 39, 0.18);
}

.phone-top,
.phone-profile {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.phone-top span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--navy);
  font-weight: 950;
}

.phone-top img {
  width: 24px;
  height: 24px;
  border-radius: 6px;
}

.phone-profile {
  justify-content: flex-start;
}

.phone-profile strong,
.phone-profile span {
  display: block;
}

.phone-profile span {
  color: var(--muted);
  font-size: 13px;
}

.phone-screen-card {
  display: grid;
  gap: 10px;
  padding: 18px;
  border-radius: 18px;
  background: var(--white);
  border: 1px solid var(--line);
}

.phone-screen-card svg {
  width: 34px;
  height: 34px;
  color: var(--red);
}

.phone-screen-card.positive svg {
  color: var(--green);
}

.phone-screen-card.warning svg {
  color: var(--amber);
}

.phone-screen-card h3,
.phone-screen-card p {
  margin: 0;
}

.phone-screen-card p {
  color: var(--muted);
}

.phone-detail-list {
  display: grid;
  gap: 8px;
}

.phone-detail-list div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 10px;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--muted);
  font-size: 13px;
}

.phone-detail-list strong {
  color: var(--navy);
  text-align: right;
}

.phone-actions {
  display: grid;
  gap: 8px;
  margin-top: auto;
}

.journey-panel,
.portal-form-panel,
.center-sync-panel {
  grid-column: 2;
  margin-bottom: 18px;
}

.journey-rail {
  display: grid;
  gap: 9px;
}

.journey-rail button {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 3px 12px;
  align-items: center;
  min-height: 64px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  text-align: left;
}

.journey-rail button.active {
  border-color: rgba(217, 37, 42, 0.5);
  background: var(--red-soft);
}

.journey-rail button.done {
  border-color: rgba(18, 136, 90, 0.25);
  background: var(--green-soft);
}

.journey-rail span {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: var(--white);
  color: var(--red);
  font-weight: 950;
}

.journey-rail strong {
  color: var(--navy);
}

.journey-rail small {
  color: var(--muted);
}

.portal-wizard {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.portal-wizard button {
  display: grid;
  align-content: start;
  gap: 7px;
  min-height: 116px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  text-align: left;
}

.portal-wizard button.active {
  border-color: rgba(217, 37, 42, 0.52);
  background: var(--red-soft);
  box-shadow: inset 0 3px 0 var(--red);
}

.portal-wizard button.done {
  border-color: rgba(18, 136, 90, 0.28);
  background: var(--green-soft);
}

.portal-wizard span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: var(--white);
  color: var(--red);
  font-weight: 950;
}

.portal-wizard button.done span {
  color: var(--green);
}

.portal-wizard strong {
  color: var(--navy);
  line-height: 1.1;
}

.portal-wizard small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.25;
}

.wizard-current-detail {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfe;
}

.wizard-current-detail.positive {
  border-color: rgba(18, 136, 90, 0.26);
  background: var(--green-soft);
}

.wizard-current-detail.warning {
  border-color: rgba(189, 127, 22, 0.24);
  background: rgba(255, 248, 231, 0.9);
}

.wizard-current-detail.critical {
  border-color: rgba(217, 37, 42, 0.36);
  background: var(--red-soft);
}

.wizard-current-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: var(--white);
  color: var(--red);
  border: 1px solid rgba(217, 37, 42, 0.14);
}

.wizard-current-icon svg {
  width: 25px;
  height: 25px;
}

.wizard-current-detail span,
.wizard-current-detail small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.wizard-current-detail h3,
.wizard-current-detail p {
  margin: 0;
}

.wizard-current-detail h3 {
  margin-top: 3px;
  color: var(--navy);
}

.wizard-current-detail p {
  margin-top: 5px;
  color: var(--muted);
}

.wizard-current-detail aside {
  display: grid;
  gap: 2px;
  min-width: 150px;
  justify-items: end;
  text-align: right;
}

.wizard-current-detail aside strong {
  color: var(--navy);
}

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

.volunteer-registration-form fieldset {
  min-width: 0;
  margin: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfe;
}

.volunteer-registration-form legend {
  padding: 0 8px;
  color: var(--navy);
  font-weight: 950;
}

.wizard-form-note {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 13px;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
}

.wizard-form-note svg {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  color: var(--red);
}

.wizard-form-note p {
  margin: 0;
}

.wizard-form-note strong {
  display: block;
  color: var(--navy);
}

.choice-grid {
  display: grid;
  gap: 10px;
}

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

.choice-card {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
}

.choice-card.active {
  border-color: rgba(217, 37, 42, 0.42);
  background: var(--red-soft);
}

.choice-card strong,
.choice-card small {
  display: block;
}

.choice-card small {
  margin-top: 3px;
  color: var(--muted);
}

.payment-gateway-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
}

.payment-gateway-card.processing {
  border-color: rgba(189, 127, 22, 0.3);
  background: rgba(255, 248, 231, 0.86);
}

.payment-gateway-card.paid {
  border-color: rgba(18, 136, 90, 0.28);
  background: var(--green-soft);
}

.payment-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.payment-summary span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-weight: 900;
}

.payment-summary svg {
  width: 20px;
  height: 20px;
  color: var(--red);
}

.payment-summary > strong {
  margin-left: auto;
  color: var(--navy);
  font-size: 24px;
  line-height: 1;
}

.payment-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.payment-meta div {
  display: grid;
  gap: 3px;
  padding: 10px;
  border-radius: var(--radius);
  background: rgba(246, 248, 251, 0.9);
}

.payment-meta span,
.payment-gateway-card p,
.payment-methods small {
  color: var(--muted);
}

.payment-meta span {
  font-size: 12px;
  font-weight: 900;
}

.payment-meta strong {
  color: var(--navy);
  overflow-wrap: anywhere;
}

.payment-methods {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.payment-methods button {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-height: 68px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  text-align: left;
}

.payment-methods button.active {
  border-color: rgba(217, 37, 42, 0.42);
  background: var(--red-soft);
}

.payment-methods button:disabled {
  cursor: not-allowed;
  opacity: 0.72;
}

.payment-methods svg {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  color: var(--red);
}

.payment-methods strong,
.payment-methods small {
  display: block;
}

.payment-methods strong {
  color: var(--navy);
}

.payment-gateway-card p {
  margin: 0;
}

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

.form-grid label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.form-grid input,
.form-grid select {
  min-width: 0;
  width: 100%;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--navy);
}

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

.checkbox-grid label {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--navy);
  font-size: 13px;
  font-weight: 800;
}

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

.document-grid label {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
}

.document-grid label.checked {
  border-color: rgba(18, 136, 90, 0.28);
  background: var(--green-soft);
}

.document-grid strong,
.document-grid small {
  display: block;
}

.document-grid small {
  margin-top: 3px;
  color: var(--muted);
}

.approval-route {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.approval-route article {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.approval-route article.done {
  border-color: rgba(18, 136, 90, 0.28);
  background: var(--green-soft);
}

.approval-route span {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: var(--white);
  color: var(--red);
  font-weight: 950;
}

.approval-route strong {
  color: var(--navy);
}

.approval-route small {
  color: var(--muted);
}

.sync-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.sync-grid article {
  display: grid;
  gap: 7px;
  padding: 13px;
  border-radius: var(--radius);
  background: var(--surface);
}

.sync-grid svg {
  width: 20px;
  height: 20px;
  color: var(--red);
}

.sync-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.sync-grid strong {
  color: var(--navy);
  overflow-wrap: anywhere;
}

.center-event-log {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

.center-event-log p {
  position: relative;
  margin: 0;
  padding: 11px 12px 11px 56px;
  min-height: 48px;
  border-radius: var(--radius);
  background: #fbfcfe;
  border: 1px solid var(--line);
  color: var(--charcoal);
}

.center-event-log time {
  position: absolute;
  left: 10px;
  top: 11px;
  display: grid;
  place-items: center;
  min-width: 38px;
  min-height: 26px;
  border-radius: 999px;
  background: var(--red-soft);
  color: var(--red);
  font-weight: 950;
  font-size: 12px;
}

.modal-root:empty,
.toast-stack:empty {
  display: none;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(17, 24, 39, 0.62);
}

.modal {
  position: relative;
  width: min(640px, 100%);
  max-height: min(86vh, 760px);
  overflow: auto;
  padding: 28px;
  border-radius: 12px;
  background: var(--white);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.28);
  animation: modalIn 240ms ease both;
}

.modal.emergency {
  background: #fff6f6;
  border: 1px solid #ffcaca;
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.98);
  }
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
}

.scan-modal,
.verified-modal,
.processing,
.emergency-modal,
.closing-modal {
  display: grid;
  place-items: center;
  gap: 12px;
  text-align: center;
}

.scanner {
  position: relative;
  width: 170px;
  height: 170px;
  border-radius: var(--radius);
  background:
    linear-gradient(90deg, #111 12px, transparent 12px) 0 0 / 28px 28px,
    linear-gradient(#111 12px, transparent 12px) 0 0 / 28px 28px,
    #fff;
  border: 12px solid #eef2f7;
  overflow: hidden;
}

.scanner div {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 4px;
  background: var(--green);
  animation: scan 1.2s ease-in-out infinite;
}

@keyframes scan {
  50% {
    top: calc(100% - 4px);
  }
}

.verified-modal svg,
.processing svg {
  width: 56px;
  height: 56px;
  color: var(--green);
}

.processing svg {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.verified-modal dl,
.assignment-letter dl {
  display: grid;
  gap: 8px;
  width: 100%;
}

.verified-modal dl div,
.assignment-letter dl div {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 10px;
  padding: 10px;
  border-radius: var(--radius);
  background: var(--surface);
  text-align: left;
}

dt {
  color: var(--muted);
  font-weight: 800;
}

dd {
  margin: 0;
  font-weight: 900;
}

.assignment-letter {
  border: 1px solid var(--line);
  padding: 22px;
}

.assignment-letter header {
  text-align: center;
  border-bottom: 2px solid var(--red);
  margin-bottom: 18px;
  padding-bottom: 14px;
}

.assignment-letter h2 {
  margin: 6px 0;
}

.letter-foot {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: center;
  margin: 16px 0;
}

.emergency-modal span {
  color: var(--red);
  font-weight: 900;
}

.emergency-modal h2 {
  margin: 0;
  color: var(--red-dark);
  font-size: 36px;
}

.closing-modal h2 {
  margin: 0;
  color: var(--navy);
  font-size: 34px;
}

.toast-stack {
  position: fixed;
  top: 86px;
  right: 22px;
  z-index: 90;
  display: grid;
  gap: 10px;
}

.toast {
  width: min(360px, calc(100vw - 44px));
  padding: 12px 14px;
  border-radius: var(--radius);
  background: var(--navy);
  color: var(--white);
  box-shadow: var(--shadow);
  animation: toastIn 220ms ease both;
}

.toast.success {
  background: var(--green);
}

.toast.warning {
  background: var(--amber);
}

.toast.info {
  background: var(--navy);
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateX(12px);
  }
}

.demo-overlay {
  position: fixed;
  inset: auto 24px 24px auto;
  z-index: 80;
}

.demo-overlay.hidden {
  display: none;
}

.demo-card {
  width: min(430px, calc(100vw - 48px));
  padding: 18px;
  border-radius: 12px;
  background: var(--navy);
  color: var(--white);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

.demo-card span,
.demo-card p,
.demo-progress {
  color: #c8d1df;
}

.demo-card h2 {
  margin: 8px 0;
}

.demo-card .secondary-button,
.demo-card .ghost-button {
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.16);
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 240px;
  padding: 34px;
  border: 1px dashed #cbd3df;
  border-radius: var(--radius);
  background: var(--white);
  text-align: center;
  color: var(--muted);
}

.empty-state svg {
  width: 48px;
  height: 48px;
  color: var(--red);
}

@media (max-width: 1180px) {
  .app-shell {
    grid-template-columns: 86px minmax(0, 1fr);
  }

  .brand span:not(.brand-mark),
  .nav-item span,
  .presentation-button span,
  .admin-card div {
    display: none;
  }

  .sidebar {
    align-items: center;
  }

  .kpi-grid,
  .training-grid,
  .mission-needs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-grid,
  .dashboard-hero,
  .volunteer-demo-hero,
  .dashboard-operational-grid,
  .dashboard-insight-grid,
  .dashboard-grid,
  .profile-grid,
  .mission-layout,
  .profile-hero,
  .portal-layout {
    grid-template-columns: 1fr;
  }

  .filters {
    grid-template-columns: repeat(2, 1fr);
  }

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

  .mission-switcher {
    grid-template-columns: 1fr;
  }

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

  .portal-picker-list,
  .sync-grid,
  .form-grid,
  .document-grid,
  .payment-meta,
  .payment-methods {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portal-wizard {
    grid-template-columns: repeat(5, minmax(150px, 1fr));
    overflow-x: auto;
    padding-bottom: 4px;
    scroll-snap-type: x mandatory;
  }

  .portal-wizard button {
    scroll-snap-align: start;
  }

  .checkbox-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .phone-frame {
    position: static;
    grid-row: auto;
  }

  .journey-panel,
  .portal-form-panel,
  .center-sync-panel {
    grid-column: auto;
  }
}

@media (max-width: 760px) {
  .app-shell {
    display: block;
    min-width: 0;
  }

  .main,
  .content,
  .portal-layout,
  .journey-panel,
  .portal-form-panel,
  .center-sync-panel,
  .phone-frame,
  .panel {
    min-width: 0;
    width: 100%;
  }

  .sidebar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    height: 74px;
    flex-direction: row;
    align-items: center;
    padding: 8px max(8px, env(safe-area-inset-left)) calc(8px + env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-right));
    overflow-x: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
  }

  .brand,
  .sidebar-foot {
    display: none;
  }

  .main-nav {
    display: flex;
    width: 100%;
    min-width: max-content;
    justify-content: flex-start;
    gap: 4px;
  }

  .nav-item {
    min-width: 58px;
    min-height: 58px;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    padding: 6px 4px;
    font-size: 10px;
    border-radius: 10px;
  }

  .nav-item.active {
    box-shadow: inset 0 3px 0 var(--red);
  }

  .topbar,
  .topbar-actions,
  .mobilization-hero,
  .volunteer-card,
  .profile-main,
  .mission-header {
    flex-direction: column;
    align-items: stretch;
  }

  .topbar {
    position: sticky;
    min-height: auto;
    padding: 14px 16px;
    gap: 12px;
  }

  .topbar h1 {
    font-size: 21px;
  }

  .searchbox {
    width: 100%;
  }

  .content {
    padding: 18px 14px 102px;
  }

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

  .filters,
  .dashboard-operational-grid,
  .dashboard-insight-grid,
  .training-grid,
  .mission-needs,
  .matching-steps,
  .mission-kpis,
  .snapshot-grid {
    grid-template-columns: 1fr;
  }

  .story-panel,
  .volunteer-demo-hero,
  .page-intro,
  .mobilization-hero,
  .profile-hero,
  .panel {
    padding: 16px;
  }

  .section-heading h2,
  .page-intro h2,
  .mobilization-hero h2,
  .profile-hero h2,
  .mission-header h2 {
    font-size: clamp(28px, 11vw, 40px);
  }

  .mission-snapshot {
    padding: 16px;
  }

  .real-map,
  .live-map {
    min-height: 330px;
  }

  .region-detail {
    gap: 8px;
  }

  .map-mission-focus,
  .dashboard-mission-brief,
  .map-focus-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .map-focus-actions {
    justify-content: flex-start;
  }

  .mission-switcher {
    display: flex;
    overflow-x: auto;
    padding-bottom: 4px;
    scroll-snap-type: x mandatory;
  }

  .mission-switcher button {
    min-width: 240px;
    scroll-snap-align: start;
  }

  .mission-card button {
    padding: 12px;
  }

  .portal-picker-list {
    display: flex;
    overflow-x: auto;
    padding-bottom: 4px;
    scroll-snap-type: x mandatory;
  }

  .portal-picker-list button {
    min-width: 230px;
    scroll-snap-align: start;
  }

  .portal-layout {
    gap: 14px;
  }

  .phone-shell {
    width: 100%;
    max-width: none;
    min-height: auto;
    border-width: 8px;
    border-radius: 24px;
    padding: 14px;
  }

  .phone-detail-list div {
    align-items: flex-start;
  }

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

  .choice-grid.two,
  .form-grid,
  .checkbox-grid,
  .document-grid,
  .approval-route,
  .payment-meta,
  .payment-methods {
    grid-template-columns: 1fr;
  }

  .payment-summary {
    align-items: flex-start;
    flex-direction: column;
  }

  .payment-summary > strong {
    margin-left: 0;
  }

  .portal-wizard {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    margin-inline: -2px;
    padding: 2px 2px 6px;
  }

  .portal-wizard button {
    min-width: 164px;
    min-height: 104px;
    padding: 11px;
  }

  .wizard-current-detail {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
  }

  .wizard-current-detail aside {
    grid-column: 1 / -1;
    min-width: 0;
    justify-items: start;
    text-align: left;
    padding-top: 8px;
    border-top: 1px solid var(--line);
  }

  .wizard-form-note {
    padding: 12px;
  }

  .volunteer-registration-form fieldset {
    padding: 12px;
  }

  .bar-row,
  .skill-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .ekta-inner {
    min-height: 320px;
  }

  .modal-backdrop {
    padding: 12px;
    align-items: end;
  }

  .modal {
    width: 100%;
    max-height: 88vh;
    border-radius: 14px 14px 0 0;
  }

  .demo-overlay {
    inset: auto 12px 88px 12px;
  }

  .demo-card {
    width: 100%;
  }

  .volunteer-card,
  .candidate-row,
  .region-detail,
  .ekta-body,
  .matrix-table article,
  .verified-modal dl div,
  .assignment-letter dl div {
    grid-template-columns: 1fr;
  }

  .volunteer-meta,
  .profile-stats {
    display: grid;
    grid-template-columns: 1fr;
  }
}
