html, body { height: auto; min-height: 0; overflow: visible; margin: 0; padding: 0; }
    body { font-family: 'DM Sans', sans-serif; }
    .sidebar { width: 220px; background: #2d1b69; position: fixed; top: 0; left: 0; height: 100vh; overflow-y: auto; z-index: 50; transition: transform .3s; display: flex; flex-direction: column; }
    .main-area { margin-left: 220px; min-height: auto; }
    .nav-item { padding: 10px 16px; cursor: pointer; border-left: 3px solid transparent; transition: all .2s; }
    .nav-item:hover { background: rgba(255,255,255,.08); }
    .nav-item.active { background: rgba(124,58,237,.25); border-left-color: #7c3aed; }
    .nav-item.active .nav-name { color: #fff; }
    .nav-name { color: #c4b5fd; font-weight: 600; font-size: 13px; }
    .nav-owner { color: #7c6faa; font-size: 11px; }
    .kpi-card { background: #fff; border-radius: 12px; padding: 20px; box-shadow: 0 1px 3px rgba(0,0,0,.08); transition: transform .2s, box-shadow .2s; }
    .kpi-card:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,.1); }
    .sparkbar { display: flex; align-items: flex-end; gap: 3px; height: 24px; }
    .sparkbar div { width: 8px; border-radius: 2px 2px 0 0; background: #7c3aed; opacity: .5; }
    .sparkbar div:last-child { opacity: 1; }
    .status-dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
    .mobile-nav { display: none; }
    @media (max-width: 767px) {
      .sidebar { transform: translateX(-100%); }
      .sidebar.open { transform: translateX(0); }
      .main-area { margin-left: 0; }
      .mobile-nav { display: flex; background: #2d1b69; padding: 8px 12px; gap: 4px; overflow-x: auto; position: sticky; top: 0; z-index: 40; }
      .mob-btn { padding: 6px 10px; border-radius: 6px; color: #c4b5fd; font-size: 11px; font-weight: 600; white-space: nowrap; cursor: pointer; border: none; background: transparent; }
      .mob-btn.active { background: rgba(124,58,237,.3); color: #fff; }
    }
    .matrix-cell { border: 1px solid #e2e8f0; display: flex; align-items: center; justify-content: center; min-height: 56px; position: relative; cursor: default; transition: filter .15s; font-size: 12px; font-weight: 600; color: rgba(0,0,0,.3); gap: 4px; flex-wrap: wrap; }
    .matrix-cell:hover { filter: brightness(.92); }
    .risk-dot { width: 22px; height: 22px; border-radius: 50%; background: #2d1b69; color: #fff; font-size: 10px; font-weight: 700; display: flex; align-items: center; justify-content: center; cursor: pointer; }
    .risk-dot:hover { transform: scale(1.15); }
    .mini-matrix-cell { width: 18px; height: 18px; border: 1px solid #e2e8f0; display: flex; align-items: center; justify-content: center; font-size: 8px; font-weight: 700; color: rgba(0,0,0,.5); cursor: pointer; }
    .inline-form { background: #f9f7ff; border: 1px solid #e9e3f5; border-radius: 12px; padding: 16px; margin-bottom: 16px; }
    .inline-form label { font-size: 12px; font-weight: 600; color: #4c1d95; display: block; margin-bottom: 2px; }
    .inline-form input, .inline-form select, .inline-form textarea { width: 100%; border: 1px solid #ddd6fe; border-radius: 6px; padding: 6px 8px; font-size: 13px; font-family: inherit; }
    .inline-form input:focus, .inline-form select:focus, .inline-form textarea:focus { outline: none; border-color: #7c3aed; box-shadow: 0 0 0 2px rgba(124,58,237,.15); }
    .btn-primary { background: #7c3aed; color: #fff; border: none; padding: 7px 16px; border-radius: 8px; font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit; }
    .btn-primary:hover { background: #6d28d9; }
    .btn-secondary { background: #e9e3f5; color: #4c1d95; border: none; padding: 7px 16px; border-radius: 8px; font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit; }
    .btn-secondary:hover { background: #ddd6fe; }
    .btn-danger { background: #fee2e2; color: #dc2626; border: none; padding: 7px 14px; border-radius: 8px; font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit; }
    .btn-danger:hover { background: #fecaca; }
    .empty-state { text-align: center; padding: 48px 20px; color: #7c6faa; }
    .empty-state p { margin-bottom: 12px; font-size: 14px; }
    .toast { position: fixed; bottom: 20px; right: 20px; background: #2d1b69; color: #fff; padding: 10px 20px; border-radius: 8px; font-size: 13px; z-index: 999; opacity: 0; transition: opacity .3s; pointer-events: none; }
    .toast.show { opacity: 1; }
    .stat-card { background: #fff; border-radius: 12px; padding: 16px 20px; box-shadow: 0 1px 3px rgba(0,0,0,.08); }
    .area-summary-card { background: #fff; border-radius: 12px; padding: 20px; box-shadow: 0 1px 3px rgba(0,0,0,.08); cursor: pointer; transition: transform .2s, box-shadow .2s; }
    .area-summary-card:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,.1); }
    .detail-panel { background: #fff; border-radius: 16px; padding: 24px; box-shadow: 0 2px 8px rgba(0,0,0,.08); }
    .score-badge { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 12px; font-size: 22px; font-weight: 700; color: #fff; }
    .view-section { display: none; }
    .view-section.active { display: block; }

html, body {
  height: auto;
  min-height: 0;
  overflow: visible;
  margin: 0;
  padding: 0;
}
body {
  font-family: Arial, Helvetica, sans-serif;
  background: #f3f0f9 url('../assets/background.png') center center / cover no-repeat fixed;
  color: #111827;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.82);
  pointer-events: none;
  z-index: -1;
}
*, *::before, *::after { box-sizing: border-box; }
img { max-width: 100%; display: block; }
.hidden { display: none !important; }
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.block { display: block; }
.grid { display: grid; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.gap-1 { gap: .25rem; }
.gap-2 { gap: .5rem; }
.gap-3 { gap: .75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.p-2 { padding: .5rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.py-2 { padding-top: .5rem; padding-bottom: .5rem; }
.py-3 { padding-top: .75rem; padding-bottom: .75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.px-2 { padding-left: .5rem; padding-right: .5rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.mb-1 { margin-bottom: .25rem; }
.mb-2 { margin-bottom: .5rem; }
.mb-3 { margin-bottom: .75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mt-0\.5 { margin-top: .125rem; }
.mt-1 { margin-top: .25rem; }
.mt-2 { margin-top: .5rem; }
.mt-3 { margin-top: .75rem; }
.mt-4 { margin-top: 1rem; }
.mr-1 { margin-right: .25rem; }
.ml-1 { margin-left: .25rem; }
.ml-2 { margin-left: .5rem; }
.rounded { border-radius: .25rem; }
.rounded-lg { border-radius: .5rem; }
.rounded-xl { border-radius: .75rem; }
.text-xs { font-size: .75rem; }
.text-sm { font-size: .875rem; }
.text-base { font-size: 1rem; }
.text-xl { font-size: 1.25rem; }
.text-2xl { font-size: 1.5rem; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.text-left { text-align: left; }
.text-center { text-align: center; }
.text-white { color: #fff; }
.text-gray-900 { color: #111827; }
.text-gray-800 { color: #1f2937; }
.text-gray-700 { color: #374151; }
.text-gray-500 { color: #6b7280; }
.text-gray-400 { color: #9ca3af; }
.bg-white { background: rgba(255,255,255,0.96); }
.bg-gray-100 { background: #f3f4f6; }
.border { border: 1px solid #e5e7eb; }
.border-b { border-bottom: 1px solid #e5e7eb; }
.border-gray-200 { border-color: #e5e7eb; }
.border-gray-100 { border-color: #f3f4f6; }
.shadow-sm { box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.w-full { width: 100%; }
.max-w-2xl { max-width: 42rem; }
.min-w-\[420px\] { min-width: 420px; }
.min-w-\[900px\] { min-width: 900px; }
.min-w-\[1000px\] { min-width: 1000px; }
.cursor-pointer { cursor: pointer; }
.overflow-x-auto { overflow-x: auto; }
.whitespace-nowrap { white-space: nowrap; }
.transform { transform: translateZ(0); }
.-rotate-90 { transform: rotate(-90deg); }
.last\:border-0:last-child { border: 0; }
.grid-cols-1 { grid-template-columns: 1fr; }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.md\:grid-cols-2, .md\:grid-cols-3, .lg\:grid-cols-2, .lg\:grid-cols-3, .lg\:grid-cols-4 {
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .md\:col-span-2 { grid-column: span 2 / span 2; }
}
@media (min-width: 1024px) {
  .lg\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lg\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
table { border-collapse: collapse; width: 100%; }
th, td { vertical-align: top; }
select, input, textarea, button { font: inherit; }
button { cursor: pointer; }
header.bg-white { backdrop-filter: blur(6px); }
.logo-card {
  background: rgba(255,255,255,.9);
  border-radius: 20px;
  padding: 10px 14px;
  display: inline-flex;
  box-shadow: 0 6px 18px rgba(0,0,0,.08);
}


/* DCC-i brand sheet overrides based on uploaded palette PDF */
:root {
  --dcci-purple: #8E44AD;
  --dcci-purple-dark: #6C3483;
  --dcci-green: #27AE60;
  --dcci-green-dark: #1E8449;
  --dcci-pink: #C2185B;
  --dcci-pink-dark: #AD1457;
  --dcci-indigo: #303F9F;
  --dcci-indigo-dark: #1A237E;
  --dcci-bg: #ECF0F1;
  --dcci-surface: rgba(255,255,255,0.94);
  --dcci-surface-strong: rgba(255,255,255,0.98);
  --dcci-text: #2C3E50;
  --dcci-text-soft: #34495E;
  --dcci-border: #BDC3C7;
  --dcci-amber: #F39C12;
  --dcci-red: #C0392B;
}
html, body, body *, button, input, select, textarea {
  font-family: 'Montserrat', Arial, Helvetica, sans-serif !important;
  font-weight: 500 !important;
  color: var(--dcci-text);
}
body {
  background: var(--dcci-bg) url('../assets/background.png') center center / cover no-repeat fixed;
}
body::before {
  background:
    linear-gradient(180deg, rgba(236,240,241,0.86), rgba(236,240,241,0.92)),
    linear-gradient(90deg, rgba(142,68,173,0.06), rgba(39,174,96,0.06), rgba(194,24,91,0.06), rgba(48,63,159,0.05));
}
header.bg-white {
  position: sticky;
  top: 0;
  z-index: 35;
  background: var(--dcci-surface-strong) !important;
  border-bottom: 1px solid rgba(189,195,199,0.95) !important;
}
header.bg-white::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 6px;
  background: linear-gradient(90deg, var(--dcci-purple) 0 30%, var(--dcci-green) 30% 60%, var(--dcci-pink) 60% 85%, var(--dcci-indigo) 85% 100%);
}
.sidebar {
  background: linear-gradient(180deg, var(--dcci-purple-dark), var(--dcci-indigo-dark)) !important;
  box-shadow: 10px 0 24px rgba(26,35,126,0.12);
}
.mobile-nav {
  background: linear-gradient(90deg, var(--dcci-purple-dark), var(--dcci-indigo-dark)) !important;
}
.nav-name, .nav-owner, .text-white { color: #ECF0F1 !important; }
.nav-item:hover { background: rgba(236,240,241,0.08) !important; }
.nav-item.active {
  background: rgba(236,240,241,0.12) !important;
  border-left-color: var(--dcci-green) !important;
}
.mob-btn.active {
  background: rgba(39,174,96,0.22) !important;
  color: #fff !important;
}
.logo-card {
  background: rgba(255,255,255,0.96) !important;
  border: 1px solid rgba(189,195,199,0.9);
}
.bg-white, .stat-card, .kpi-card, .area-summary-card, .detail-panel,
.bg-white.rounded-xl, .inline-form {
  background: var(--dcci-surface) !important;
  border: 1px solid rgba(189,195,199,0.55);
  box-shadow: 0 8px 22px rgba(44,62,80,0.08) !important;
}
.inline-form {
  background: rgba(236,240,241,0.88) !important;
}
.btn-primary {
  background: linear-gradient(135deg, var(--dcci-purple), var(--dcci-indigo)) !important;
  color: #fff !important;
}
.btn-primary:hover {
  background: linear-gradient(135deg, var(--dcci-purple-dark), var(--dcci-indigo-dark)) !important;
}
.btn-secondary {
  background: rgba(39,174,96,0.12) !important;
  color: var(--dcci-green-dark) !important;
  border: 1px solid rgba(39,174,96,0.28);
}
.btn-secondary:hover {
  background: rgba(39,174,96,0.2) !important;
}
.btn-danger {
  background: rgba(194,24,91,0.12) !important;
  color: var(--dcci-pink-dark) !important;
  border: 1px solid rgba(194,24,91,0.24);
}
.btn-danger:hover {
  background: rgba(194,24,91,0.2) !important;
}
.status-dot { box-shadow: 0 0 0 2px rgba(255,255,255,0.9); }
.score-badge {
  background: linear-gradient(135deg, var(--dcci-purple), var(--dcci-pink)) !important;
  color: #fff !important;
}
.risk-dot {
  background: linear-gradient(135deg, var(--dcci-purple-dark), var(--dcci-indigo)) !important;
}
.sparkbar div { background: var(--dcci-purple) !important; }
.matrix-cell, .mini-matrix-cell, th, td {
  border-color: rgba(189,195,199,0.7) !important;
}
.text-gray-900, .text-gray-800, .text-gray-700, .text-gray-500, .text-gray-400,
.font-bold, .font-semibold, .font-medium {
  color: var(--dcci-text) !important;
}
select, input, textarea {
  background: #fff;
  border: 1px solid rgba(189,195,199,0.95) !important;
  color: var(--dcci-text) !important;
}
select:focus, input:focus, textarea:focus,
.inline-form input:focus, .inline-form select:focus, .inline-form textarea:focus {
  outline: none;
  border-color: var(--dcci-purple) !important;
  box-shadow: 0 0 0 3px rgba(142,68,173,0.15) !important;
}
.toast {
  background: linear-gradient(135deg, var(--dcci-purple-dark), var(--dcci-indigo-dark)) !important;
  color: #fff !important;
}
@media (max-width: 767px) {
  .main-area { background: transparent; }
}


.space-y-2 > * + *, .space-y-3 > * + * { margin-top: .75rem; }
.rounded-full { border-radius: 999px; }
.text-red-800 { color: #991b1b; }
.text-red-700 { color: #b91c1c; }
.border-red-200 { border-color: #fecaca; }
.bg-red-50 { background: #fef2f2; }
.tracking-wide { letter-spacing: .04em; }
.uppercase { text-transform: uppercase; }
.lg\:col-span-2 { grid-column: span 1 / span 1; }
@media (min-width: 1024px) { .lg\:col-span-2 { grid-column: span 2 / span 2; } }
input[type="checkbox"] { width: auto; margin-right: .35rem; }
textarea { resize: vertical; }
#dynamic-content .btn-secondary, #dynamic-content .btn-primary, #dynamic-content .btn-danger { line-height: 1.25; }
