:root {
  --bg: #f5f7fc;
  --panel: #ffffff;
  --panel-soft: #fbfcff;
  --border: #e3e8f4;
  --ink: #31456d;
  --muted: #7b88a5;
  --brand: #6080d1;
  --brand-deep: #4f72cb;
  --line-soft: #edf1f8;
  --green: #20b26b;
  --orange: #ff8b1f;
  --red: #eb5757;
  --shadow: 0 10px 26px rgba(91, 115, 173, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Segoe UI", Tahoma, sans-serif;
  background: #f7f9fd;
  color: var(--ink);
}

.app-shell {
  min-height: 100vh;
}

/* =============================================================================
   PRODUCTION-GRADE APP TOPBAR BANNER
   ============================================================================= */

.topbar {
  position: relative;
  background-color: #040b17;
  background-image:
    /* Ambient mesh glow 1: Dark cyan radial bloom */
    radial-gradient(ellipse 650px 180px at 26% -25%, rgba(3, 105, 161, 0.42) 0%, transparent 70%),
    /* Ambient mesh glow 2: Deep cobalt / sapphire in center */
    radial-gradient(ellipse 850px 220px at 50% 45%, rgba(15, 43, 92, 0.85) 0%, transparent 80%),
    /* Ambient mesh glow 3: Ice-blue node near right */
    radial-gradient(ellipse 550px 180px at 80% 115%, rgba(14, 165, 233, 0.25) 0%, transparent 75%),
    /* Subtle SVG Blueprint Grid & Waveform pattern */
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100%25' height='100%25'%3E%3Cdefs%3E%3Cpattern id='g' width='28' height='28' patternUnits='userSpaceOnUse'%3E%3Cpath d='M 28 0 L 0 0 0 28' fill='none' stroke='rgba(125,211,252,0.048)' stroke-width='0.8'/%3E%3Ccircle cx='28' cy='28' r='0.9' fill='rgba(125,211,252,0.11)'/%3E%3C/pattern%3E%3ClinearGradient id='w' x1='0%25' y1='0%25' x2='100%25' y2='0%25'%3E%3Cstop offset='0%25' stop-color='%230284c7' stop-opacity='0'/%3E%3Cstop offset='25%25' stop-color='%2338bdf8' stop-opacity='0.07'/%3E%3Cstop offset='50%25' stop-color='%237dd3fc' stop-opacity='0.14'/%3E%3Cstop offset='75%25' stop-color='%230ea5e9' stop-opacity='0.07'/%3E%3Cstop offset='100%25' stop-color='%230369a1' stop-opacity='0'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect width='100%25' height='100%25' fill='url(%23g)'/%3E%3Cpath d='M 0 54 Q 240 18, 480 54 T 960 54 T 1440 54 T 1920 54' fill='none' stroke='url(%23w)' stroke-width='1.8'/%3E%3C/svg%3E"),
    /* Base horizontal luxury sweep */
    linear-gradient(90deg,
      #040a17 0%,
      #071936 8%,
      #0e2a57 28%,
      #133c75 50%,
      #0f2f5e 72%,
      #071a38 90%,
      #030914 100%);
  color: #fff;
  padding: 12px 24px 14px;
  overflow: hidden;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    inset 0 -1px 0 rgba(0, 0, 0, 0.65),
    0 4px 20px rgba(0, 0, 0, 0.35);
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  border-bottom: 1px solid rgba(2, 6, 16, 0.95);
}

/* Dual Specular Top Highlight Beam */
.specular-highlight-beam {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1.5px;
  background: linear-gradient(90deg,
      transparent 0%,
      rgba(56, 189, 248, 0) 12%,
      rgba(56, 189, 248, 0.45) 35%,
      rgba(186, 230, 253, 0.95) 50%,
      rgba(56, 189, 248, 0.45) 65%,
      rgba(56, 189, 248, 0) 88%,
      transparent 100%);
  box-shadow:
    0 0 12px rgba(56, 189, 248, 0.85),
    0 0 24px rgba(14, 165, 233, 0.5);
  z-index: 4;
  pointer-events: none;
}

.topbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  position: relative;
  z-index: 2;
  width: 100%;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: nowrap;
}

.brand-logo-wrapper {
  width: 72px;
  height: 72px;
  background: #ffffff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  box-shadow:
    0 4px 16px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(255, 255, 255, 0.95),
    inset 0 1px 2px rgba(255, 255, 255, 0.9);
  flex-shrink: 0;
}

.brand-logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
}

.brand-title {
  font-size: 26px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.3px;
  line-height: 1.1;
  text-shadow: 0 2px 6px rgba(0, 10, 30, 0.5);
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.app-subheading {
  font-size: 13px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  line-height: 1.2;
  opacity: 0.98;
  text-shadow: 0 1px 3px rgba(0, 10, 30, 0.4);
}

.subtitle-tags-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 3px;
  flex-wrap: wrap;
}

.tagline-text {
  font-size: 12.5px;
  color: #d1e3f8;
  font-weight: 500;
  letter-spacing: 0.1px;
  white-space: nowrap;
  display: flex;
  align-items: center;
}

.tagline-sep {
  color: rgba(185, 215, 250, 0.45);
  margin: 0 7px;
  font-weight: 400;
}

.tagline-italic {
  font-style: italic;
  font-weight: 600;
  color: #ffffff;
  letter-spacing: 0.15px;
}

.badges-group {
  display: flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}

.banner-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 9999px;
  font-size: 10.5px;
  line-height: 1.1;
  letter-spacing: 0.15px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.28);
}

.banner-badge-version {
  background: #ffffff;
  color: #0f172a;
  border: 1px solid rgba(226, 232, 240, 0.9);
  font-weight: 700;
  padding: 3px 8px;
}

.banner-badge-license {
  background: linear-gradient(135deg, #1ca54d 0%, #15803d 100%);
  color: #ffffff;
  font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.banner-badge-ai {
  background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
  color: #ffffff;
  font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.banner-badge-opensource {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #0f172a;
  font-weight: 800;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.banner-badge-neutral {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.banner-access-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.08);
  border: 1.5px solid rgba(255, 255, 255, 0.52);
  border-radius: 9999px;
  padding: 7px 18px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.2px;
  text-decoration: none;
  backdrop-filter: blur(10px);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.28);
  transition: all 0.2s ease;
}

.banner-access-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.8);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(56, 189, 248, 0.35);
}

.banner-divider {
  width: 1px;
  height: 38px;
  background: linear-gradient(180deg,
      rgba(255, 255, 255, 0.05) 0%,
      rgba(255, 255, 255, 0.35) 50%,
      rgba(255, 255, 255, 0.05) 100%);
}

.banner-more-menu {
  display: flex;
  flex-direction: row;
  gap: 4.5px;
  padding: 6px;
  cursor: pointer;
}

.more-dot {
  width: 4.5px;
  height: 4.5px;
  background: rgba(255, 255, 255, 0.85);
  border-radius: 50%;
  display: inline-block;
}

.nav-strip {
  background: #ffffff;
  border-bottom: 1px solid var(--line-soft);
  padding: 0 12px;
}

.context-strip {
  background: #ffffff;
  border-bottom: 1px solid var(--line-soft);
  padding: 10px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.context-left,
.context-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.context-link {
  color: var(--brand-deep);
  font-size: 13px;
}

.context-title,
.context-label,
.updated-label {
  font-size: 13px;
  color: var(--ink);
}

.context-divider {
  color: #c5cfdf;
}

.status-running {
  color: var(--green);
  font-weight: 700;
  font-size: 13px;
}

.inline-select {
  min-width: 120px;
}

.small-select {
  width: 122px;
}

.medium-select {
  width: 180px;
}

.inline-select .Select-control,
.inline-select .Select__control,
.inline-select .VirtualizedSelectFocusedOption {
  border-radius: 10px;
}

.health-pill {
  background: rgba(32, 178, 107, 0.12);
  color: var(--green);
  border: 1px solid rgba(32, 178, 107, 0.16);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
}

.header-circle {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1px solid #cfd7e8;
  display: inline-block;
}

.content-wrap {
  padding: 18px 18px 22px;
}

.content-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 0 4px 16px;
}

.content-heading h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
}

.content-heading p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.content-chip {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 12px;
  color: var(--brand-deep);
  font-weight: 600;
}

.action-button-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.action-btn {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  background: #ffffff;
  cursor: pointer;
}

.action-btn:hover {
  border-color: #ced8eb;
  box-shadow: 0 4px 12px rgba(91, 115, 173, 0.08);
}

.action-btn-primary {
  background: var(--brand-deep);
  border-color: var(--brand-deep);
  color: #ffffff;
}

.action-btn-primary:hover {
  background: #4568bc;
  border-color: #4568bc;
}

.building-action-buttons {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.building-action-buttons .action-btn {
  min-width: 175px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  padding: 0 16px;
  border-radius: 10px;
  box-sizing: border-box;
  transition: all 0.2s ease;
}

.analysis-controls {
  margin-top: 8px;
}

.analysis-select {
  margin-top: 8px;
  max-width: 540px;
}

.analysis-profile-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.78fr) minmax(0, 1.22fr);
  gap: 16px;
  align-items: stretch;
}

.profile-metrics-panel,
.profile-map-panel {
  min-height: 100%;
}

.profile-map-panel {
  display: flex;
  flex-direction: column;
}

.location-map-shell {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 12px;
}

.location-map-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel-soft);
  font-size: 13px;
  align-items: center;
}

.location-map-meta strong {
  color: var(--ink);
}

.location-map-frame {
  width: 100%;
  min-height: 420px;
  border: 1px solid #dbe4f0;
  border-radius: 14px;
  background: #0f172a;
}

.data-analysis-intro-panel .action-button-row {
  margin-top: 16px;
}

.data-analysis-intro-panel .action-button-row .action-btn {
  flex: 1 1 220px;
  min-width: 220px;
  max-width: 260px;
  height: 44px;
  padding: 0 18px;
  justify-content: center;
  background: var(--brand-deep);
  border-color: var(--brand-deep);
  color: #ffffff;
}

.data-analysis-intro-panel .action-button-row .action-btn:hover {
  background: #4568bc;
  border-color: #4568bc;
  box-shadow: 0 4px 12px rgba(91, 115, 173, 0.08);
}

.data-analysis-intro-panel .action-button-row .action-btn:focus-visible {
  outline: 2px solid rgba(96, 128, 209, 0.35);
  outline-offset: 2px;
}

.nested-panel {
  margin-top: 14px;
  border-radius: 12px;
  background: var(--panel-soft);
}

.new-system-form {
  margin-top: 14px;
}

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

.new-system-field {
  display: grid;
  gap: 6px;
}

.new-system-field .muted {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.new-system-input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  background: #ffffff;
  color: var(--ink);
  font-size: 13px;
}

.new-system-input:focus {
  outline: 2px solid rgba(96, 128, 209, 0.18);
  border-color: rgba(96, 128, 209, 0.45);
}

.new-system-upload-field {
  margin-top: 14px;
}

.new-system-upload {
  border: 2px dashed #cfd8eb;
  border-radius: 12px;
  background: #ffffff;
  cursor: pointer;
  transition: border-color 0.2s;
}

.new-system-upload:hover {
  border-color: var(--brand-deep);
}

.new-system-upload-inner {
  padding: 18px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

.new-system-upload-link {
  color: var(--brand-deep);
  font-weight: 600;
}

.new-system-upload-status {
  margin-top: 8px;
  font-size: 13px;
}

.new-system-status-ready {
  color: var(--green);
  font-weight: 600;
}

.new-system-status-muted {
  color: var(--muted);
}

.new-system-actions {
  margin-top: 14px;
  display: flex;
  justify-content: flex-start;
}

.new-system-actions .action-btn {
  padding: 12px 20px;
  font-size: 13px;
  font-weight: 700;
}

.new-system-result {
  margin-top: 14px;
}

.new-system-result-success,
.new-system-result-error {
  border-radius: 12px;
  padding: 14px 16px;
  margin-top: 14px;
}

.new-system-result-success {
  background: rgba(32, 178, 107, 0.08);
  border: 1px solid rgba(32, 178, 107, 0.2);
}

.new-system-result-error {
  background: rgba(235, 87, 87, 0.08);
  border: 1px solid rgba(235, 87, 87, 0.2);
}

.new-system-result-title {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 700;
}

.new-system-result-success .new-system-result-title {
  color: var(--green);
}

.new-system-result-error .new-system-result-title {
  color: var(--red);
}

.new-system-result-text {
  margin: 4px 0;
  font-size: 13px;
  color: var(--ink);
}

.new-system-result-note {
  margin: 8px 0 0;
  font-size: 12px;
  color: var(--muted);
}

@media (max-width: 1100px) {
  .new-system-form-grid {
    grid-template-columns: 1fr;
  }
}

.panel {
  background: var(--panel);
  border: 1px solid #e7ebf4;
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 18px;
}

.panel+.panel {
  margin-top: 18px;
}

.profile-map-panel .section-subtitle {
  margin-bottom: 12px;
}

.trend-panel {
  margin-top: 18px;
  background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%);
}

.trend-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.85fr);
  gap: 16px;
  margin-bottom: 14px;
}

.trend-card {
  border: 1px solid #e2e8f4;
  border-radius: 14px;
  background: var(--panel-soft);
  padding: 14px;
}

.trend-card-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
}

.trend-card-note {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.trend-variable-checklist {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 12px;
  max-height: 240px;
  overflow: auto;
  padding-right: 4px;
}

.trend-variable-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink);
}

.trend-variable-input {
  accent-color: var(--brand-deep);
}

.trend-time-grid {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.trend-time-field {
  display: grid;
  gap: 6px;
}

.trend-datetime-input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  background: #ffffff;
  color: var(--ink);
  font-size: 13px;
}

.trend-datetime-input:focus {
  outline: 2px solid rgba(96, 128, 209, 0.18);
  border-color: rgba(96, 128, 209, 0.45);
}

.trend-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}

.trend-summary-item {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 12px;
  background: #ffffff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.trend-graph {
  border: 1px solid #e2e8f4;
  border-radius: 14px;
  overflow: hidden;
}

.kpi-grid,
.two-col-grid,
.three-col-grid,
.four-col-grid {
  display: grid;
  gap: 16px;
}

.kpi-grid,
.four-col-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

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

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

.kpi-card {
  background: #ffffff;
  border: 1px solid #e8edf7;
  border-radius: 16px;
  padding: 14px 16px;
}

.kpi-label {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.kpi-value {
  margin-top: 8px;
  font-size: 18px;
  font-weight: 700;
}

.kpi-note {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.section-title {
  margin: 0 0 10px;
  font-size: 18px;
}

.section-subtitle {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 13px;
}

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

.data-table th,
.data-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
  font-size: 13px;
}

.data-table th {
  color: var(--muted);
  font-weight: 600;
}

.pill {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.pill-green {
  background: rgba(32, 178, 107, 0.12);
  color: var(--green);
}

.pill-orange {
  background: rgba(255, 139, 31, 0.14);
  color: var(--orange);
}

.pill-red {
  background: rgba(235, 87, 87, 0.12);
  color: var(--red);
}

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

.info-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line-soft);
}

.muted {
  color: var(--muted);
}

.dash-tabs {
  display: flex;
  align-items: center;
  width: 100%;
}

.dash-tabs>div {
  border-bottom: none !important;
  display: flex !important;
  width: 100% !important;
}

.dash-tabs .tab {
  flex: 1 1 0 !important;
  border: none !important;
  background: transparent !important;
  color: #6c7892 !important;
  padding: 15px 12px 13px !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  line-height: 1 !important;
  border-bottom: 2px solid transparent !important;
  max-width: none !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  gap: 8px !important;
}

.dash-tabs .tab::before {
  content: "";
  width: 17px;
  height: 17px;
  display: inline-block;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 17px 17px;
  opacity: 0.95;
}

.dash-tabs .tab:nth-child(1)::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236c7892' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 8.5 10 3l6.5 5.5'/%3E%3Cpath d='M5.5 7.8V16h9V7.8'/%3E%3Cpath d='M8.2 16v-4h3.6v4'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(2)::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236c7892' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 4.5V15.5H16'/%3E%3Cpath d='M7 13V9.5'/%3E%3Cpath d='M10 13V6.5'/%3E%3Cpath d='M13 13v-4'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(3)::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236c7892' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='10' cy='10' r='3.1'/%3E%3Cpath d='M10 1.9v2.3M10 15.8v2.3M18.1 10h-2.3M4.2 10H1.9M15.9 4.1l-1.6 1.6M5.7 14.3l-1.6 1.6M15.9 15.9l-1.6-1.6M5.7 5.7 4.1 4.1'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(4)::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236c7892' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='10' cy='10' r='1.6'/%3E%3Cpath d='M10 3.1v2.1M10 14.8v2.1M3.1 10h2.1M14.8 10h2.1M5.1 5.1l1.5 1.5M13.4 13.4l1.5 1.5M14.9 5.1l-1.5 1.5M6.6 13.4l-1.5 1.5'/%3E%3Ccircle cx='6' cy='6' r='1.1'/%3E%3Ccircle cx='14' cy='6' r='1.1'/%3E%3Ccircle cx='6' cy='14' r='1.1'/%3E%3Ccircle cx='14' cy='14' r='1.1'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(5)::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236c7892' stroke-width='1.55' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5.6' y='5.6' width='8.8' height='8.8' rx='1.5'/%3E%3Cpath d='M10 2.8v1.8M10 15.4v1.8M15.4 10h1.8M2.8 10h1.8M14.1 4.3l-.9 1.2M6.8 14.5l-.9 1.2M15.7 6.8l-1.2.9M5.5 13.2l-1.2.9M14.1 15.7l-.9-1.2M6.8 5.5l-.9-1.2M15.7 13.2l-1.2-.9M5.5 6.8l-1.2-.9'/%3E%3Cpath d='M8.2 8.2h3.6v3.6H8.2z'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(6)::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236c7892' stroke-width='1.65' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5.3 6.4 2.9 10l2.4 3.6'/%3E%3Cpath d='M14.7 6.4 17.1 10l-2.4 3.6'/%3E%3Cpath d='M11.1 5.2 8.9 14.8'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(7)::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236c7892' stroke-width='1.65' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5.8 2.8h5.9l2.8 2.8v11H5.8z'/%3E%3Cpath d='M11.7 2.8v2.8h2.8'/%3E%3Cpath d='M7.9 9.2h4.8M7.9 12h4.8'/%3E%3Ccircle cx='13.9' cy='13.9' r='1.5'/%3E%3Cpath d='M15 15l1.3 1.3'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(8)::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236c7892' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2.5' y='3.5' width='15' height='10.5' rx='2'/%3E%3Cpath d='M8 17h4M10 14v3'/%3E%3Cpolygon points='8.5,6.8 13,8.75 8.5,10.7' fill='%236c7892'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(9)::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236c7892' stroke-width='1.65' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 4.7c0-.9.8-1.7 1.7-1.7h4.1v12.7H5.7c-.9 0-1.7.8-1.7 1.7z'/%3E%3Cpath d='M16 4.7c0-.9-.8-1.7-1.7-1.7h-4.1v12.7h4.1c.9 0 1.7.8 1.7 1.7z'/%3E%3Cpath d='M10 4.3v10.8'/%3E%3C/svg%3E");
}

.dash-tabs .tab--selected {
  color: var(--brand-deep) !important;
  border-bottom: 2px solid var(--brand-deep) !important;
}

.dash-tabs .tab--selected::before {
  filter: saturate(1.1);
}

.dash-tabs .tab:nth-child(1).tab--selected::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234f72cb' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 8.5 10 3l6.5 5.5'/%3E%3Cpath d='M5.5 7.8V16h9V7.8'/%3E%3Cpath d='M8.2 16v-4h3.6v4'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(2).tab--selected::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234f72cb' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 4.5V15.5H16'/%3E%3Cpath d='M7 13V9.5'/%3E%3Cpath d='M10 13V6.5'/%3E%3Cpath d='M13 13v-4'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(3).tab--selected::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234f72cb' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='10' cy='10' r='3.1'/%3E%3Cpath d='M10 1.9v2.3M10 15.8v2.3M18.1 10h-2.3M4.2 10H1.9M15.9 4.1l-1.6 1.6M5.7 14.3l-1.6 1.6M15.9 15.9l-1.6-1.6M5.7 5.7 4.1 4.1'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(4).tab--selected::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234f72cb' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='10' cy='10' r='1.6'/%3E%3Cpath d='M10 3.1v2.1M10 14.8v2.1M3.1 10h2.1M14.8 10h2.1M5.1 5.1l1.5 1.5M13.4 13.4l1.5 1.5M14.9 5.1l-1.5 1.5M6.6 13.4l-1.5 1.5'/%3E%3Ccircle cx='6' cy='6' r='1.1'/%3E%3Ccircle cx='14' cy='6' r='1.1'/%3E%3Ccircle cx='6' cy='14' r='1.1'/%3E%3Ccircle cx='14' cy='14' r='1.1'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(5).tab--selected::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234f72cb' stroke-width='1.55' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5.6' y='5.6' width='8.8' height='8.8' rx='1.5'/%3E%3Cpath d='M10 2.8v1.8M10 15.4v1.8M15.4 10h1.8M2.8 10h1.8M14.1 4.3l-.9 1.2M6.8 14.5l-.9 1.2M15.7 6.8l-1.2.9M5.5 13.2l-1.2.9M14.1 15.7l-.9-1.2M6.8 5.5l-.9-1.2M15.7 13.2l-1.2-.9M5.5 6.8l-1.2-.9'/%3E%3Cpath d='M8.2 8.2h3.6v3.6H8.2z'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(6).tab--selected::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234f72cb' stroke-width='1.65' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5.3 6.4 2.9 10l2.4 3.6'/%3E%3Cpath d='M14.7 6.4 17.1 10l-2.4 3.6'/%3E%3Cpath d='M11.1 5.2 8.9 14.8'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(7).tab--selected::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234f72cb' stroke-width='1.65' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5.8 2.8h5.9l2.8 2.8v11H5.8z'/%3E%3Cpath d='M11.7 2.8v2.8h2.8'/%3E%3Cpath d='M7.9 9.2h4.8M7.9 12h4.8'/%3E%3Ccircle cx='13.9' cy='13.9' r='1.5'/%3E%3Cpath d='M15 15l1.3 1.3'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(8).tab--selected::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234f72cb' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2.5' y='3.5' width='15' height='10.5' rx='2'/%3E%3Cpath d='M8 17h4M10 14v3'/%3E%3Cpolygon points='8.5,6.8 13,8.75 8.5,10.7' fill='%234f72cb'/%3E%3C/svg%3E");
}

.dash-tabs .tab:nth-child(9).tab--selected::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234f72cb' stroke-width='1.65' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 4.7c0-.9.8-1.7 1.7-1.7h4.1v12.7H5.7c-.9 0-1.7.8-1.7 1.7z'/%3E%3Cpath d='M16 4.7c0-.9-.8-1.7-1.7-1.7h-4.1v12.7h4.1c.9 0 1.7.8 1.7 1.7z'/%3E%3Cpath d='M10 4.3v10.8'/%3E%3C/svg%3E");
}

.placeholder-panel {
  min-height: 220px;
}

/* ------------------------------------------------------------------ */
/*  Preprocessing panel (Data Analysis -> Feature Engineering)        */
/* ------------------------------------------------------------------ */

.preprocessing-panel {
  margin-top: 18px;
  background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%);
}

.preprocess-tabs {
  margin-top: 14px;
}

.preprocess-tabs>div {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  border-bottom: 1px solid var(--line-soft) !important;
  overflow-x: auto;
  scrollbar-width: thin;
}

.preprocess-tabs .tab {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 auto;
  min-height: 40px;
  white-space: nowrap;
  border: none !important;
  background: transparent !important;
  color: #6c7892 !important;
  padding: 12px 12px 10px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  line-height: 1 !important;
  border-bottom: 2px solid transparent !important;
  max-width: none !important;
}

.preprocess-tabs .tab--selected {
  color: var(--brand-deep) !important;
  border-bottom: 2px solid var(--brand-deep) !important;
}

.preprocessing-step-panel {
  padding-top: 16px;
}

.preprocessing-step-panel:has(.preprocessing-action-box) {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  align-items: stretch;
  gap: 16px;
}

.preprocessing-step-panel:has(.preprocessing-action-box)>.trend-card,
.preprocessing-step-panel:has(.preprocessing-action-box)>.preprocessing-card {
  min-width: 0;
}

.preprocessing-action-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  flex-wrap: wrap;
}

.preprocessing-action-box {
  flex-direction: column;
  justify-content: center;
  align-items: stretch;
  margin-top: 0;
  padding: 20px;
  border: 1px solid var(--line-soft);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 5px 16px rgba(91, 115, 173, 0.07);
}

.preprocessing-action-box .action-btn {
  width: 100%;
}

.preprocessing-action-box .preprocessing-action-note {
  text-align: center;
}

@media (max-width: 780px) {
  .preprocessing-step-panel:has(.preprocessing-action-box) {
    grid-template-columns: 1fr;
  }

  .preprocessing-action-box {
    min-height: 132px;
  }
}

.preprocessing-action-note {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.preprocessing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.preprocessing-card {
  border: 1px solid #e2e8f4;
  border-radius: 14px;
  background: var(--panel-soft);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.preprocessing-report-card {
  grid-column: 1 / -1;
}

.preprocessing-field {
  display: grid;
  gap: 6px;
}

.preprocessing-field .muted {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.preprocessing-select {
  font-size: 13px;
}

.preprocessing-check-row {
  margin-top: 2px;
}

.preprocessing-checklist {
  display: grid;
  gap: 6px;
}

.preprocessing-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.preprocessing-summary-item {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 5px 10px;
  background: #ffffff;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

.preprocessing-note {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.preprocessing-split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.preprocessing-selection-summary {
  max-height: 320px;
  overflow: auto;
  font-size: 12px;
}

.preprocessing-selection-table {
  font-size: 12px;
}

.preprocessing-report {
  font-size: 12px;
  max-height: 360px;
  overflow: auto;
}

.preprocessing-export-row {
  margin-top: 12px;
  display: flex;
  justify-content: flex-start;
}

.preprocessing-export-status {
  margin-top: 10px;
}

.preprocessing-export-success,
.preprocessing-export-error {
  border-radius: 12px;
  padding: 14px 16px;
  margin-top: 10px;
}

.preprocessing-export-success {
  background: rgba(32, 178, 107, 0.08);
  border: 1px solid rgba(32, 178, 107, 0.2);
}

.preprocessing-export-error {
  background: rgba(235, 87, 87, 0.08);
  border: 1px solid rgba(235, 87, 87, 0.2);
}

/* ------------------------------------------------------------------ */
/* Data Analysis typography system                                    */
/* ------------------------------------------------------------------ */

.data-analysis-page {
  --da-title-size: 20px;
  --da-section-size: 16px;
  --da-body-size: 13px;
  --da-note-size: 12px;
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
  color: var(--ink);
  font-size: var(--da-body-size);
  line-height: 1.45;
}

.data-analysis-page .section-title {
  margin: 0 0 8px;
  font-size: var(--da-title-size);
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.data-analysis-page .nested-panel .section-title,
.data-analysis-page .profile-map-panel .section-title,
.data-analysis-page .profile-metrics-panel .section-title {
  font-size: var(--da-section-size);
  line-height: 1.3;
}

.data-analysis-page .section-subtitle,
.data-analysis-page .data-analysis-intro,
.data-analysis-page .trend-card-note,
.data-analysis-page .preprocessing-note {
  margin-top: 0;
  color: var(--muted);
  font-size: var(--da-note-size);
  line-height: 1.5;
}

.data-analysis-page .section-subtitle {
  margin-bottom: 16px;
}

.data-analysis-page .trend-card-title {
  font-size: 14px;
  line-height: 1.3;
  font-weight: 700;
}

.data-analysis-page .preprocess-tabs .tab {
  font-family: inherit !important;
  font-size: 12px !important;
  line-height: 1.2 !important;
  font-weight: 600 !important;
  letter-spacing: 0.01em;
}

.data-analysis-page .preprocessing-field,
.data-analysis-page .trend-time-field {
  font-size: var(--da-body-size);
}

.data-analysis-page .preprocessing-field>.muted,
.data-analysis-page .trend-time-field>.muted,
.data-analysis-page .analysis-controls>.muted,
.data-analysis-page .new-system-field>.muted {
  color: #647493;
  font-size: 11px;
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: 0.055em;
  text-transform: uppercase;
}

.data-analysis-page .trend-variable-label,
.data-analysis-page .preprocessing-checklist,
.data-analysis-page .preprocessing-select,
.data-analysis-page .trend-datetime-input,
.data-analysis-page .new-system-input {
  font-family: inherit;
  font-size: var(--da-body-size);
  line-height: 1.35;
}

.data-analysis-page .Select,
.data-analysis-page .Select input,
.data-analysis-page .Select-control,
.data-analysis-page .Select-menu-outer,
.data-analysis-page .Select-option,
.data-analysis-page .Select-value-label {
  font-family: inherit;
  font-size: var(--da-body-size);
}

.data-analysis-page .preprocessing-action-note,
.data-analysis-page .preprocessing-summary-item,
.data-analysis-page .trend-summary-item,
.data-analysis-page .preprocessing-selection-summary,
.data-analysis-page .preprocessing-report,
.data-analysis-page .preprocessing-export-status {
  font-size: var(--da-note-size);
  line-height: 1.4;
}

.data-analysis-page .data-table th,
.data-analysis-page .data-table td {
  font-size: var(--da-body-size);
  line-height: 1.4;
}

.data-analysis-page .data-table th {
  font-weight: 700;
}

.data-analysis-page .action-btn {
  font-family: inherit;
  font-size: var(--da-body-size);
  line-height: 1.2;
  width: 220px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.data-analysis-page .action-btn:disabled {
  cursor: wait;
  opacity: 0.78;
}

.data-analysis-page .action-btn:disabled::after {
  width: 13px;
  height: 13px;
  margin-left: 8px;
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-top-color: currentColor;
  border-radius: 50%;
  content: "";
  animation: data-analysis-button-spin 0.75s linear infinite;
}

@keyframes data-analysis-button-spin {
  to {
    transform: rotate(360deg);
  }
}

.data-analysis-page .preprocessing-generate-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 0 0 10px;
  padding: 10px 12px;
  border: 1px solid #e1e8f4;
  border-radius: 10px;
  background: #fbfcff;
}

.data-analysis-export-box {
  margin-top: 18px;
}

.data-analysis-export-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.data-analysis-export-box .preprocessing-export-status {
  margin-top: 12px;
}

@media (max-width: 620px) {
  .data-analysis-export-actions .action-btn {
    width: 100%;
  }
}

.data-analysis-page .preprocessing-action-note {
  color: var(--muted);
  font-size: 12px;
}

.data-analysis-page .trend-generate-btn {
  margin-top: 12px;
}

.data-analysis-page .trend-date-time-row {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(104px, 0.65fr);
  gap: 8px;
}

.data-analysis-page .trend-date-picker,
.data-analysis-page .trend-date-picker .DateInput,
.data-analysis-page .trend-date-picker .DateInput_input {
  width: 100%;
}

.data-analysis-page .trend-date-picker .DateInput_input {
  box-sizing: border-box;
  min-height: 38px;
  border: 1px solid #cbd5e8;
  border-radius: 9px;
  padding: 8px 11px;
  color: var(--ink);
  font-family: inherit;
  font-size: var(--da-body-size);
  line-height: 20px;
}

.data-analysis-page .trend-date-picker .DateInput_input__focused {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(96, 128, 209, 0.14);
}

.data-analysis-page .trend-time-select .Select-control,
.data-analysis-page .trend-time-select .Select__control {
  min-height: 38px;
}

/* Keep PV Forecasting tables consistent with Data Analysis. */
.pv-forecasting-page {
  --da-body-size: 13px;
  --da-note-size: 12px;
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
  color: var(--ink);
  font-size: var(--da-body-size);
  line-height: 1.45;
}

/* Consistent PV Forecasting panel design. */
.pv-forecasting-page .panel {
  box-sizing: border-box;
  border: 1px solid #e7ebf4;
  border-radius: 16px;
  background: var(--panel);
  box-shadow: var(--shadow);
  padding: 18px;
}

.pv-forecasting-page .section-title {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.pv-forecasting-page .two-col-grid>.panel .section-title {
  font-size: 18px;
  line-height: 1.3;
}

.pv-forecasting-page .section-subtitle {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: var(--da-note-size);
  line-height: 1.5;
}

.pv-forecasting-page .muted {
  color: #647493;
  font-size: 13px;
  line-height: 1.35;
  font-weight: 400;
  letter-spacing: normal;
  text-transform: none;
}

.pv-forecasting-page .two-col-grid>.panel {
  margin-top: 0;
  height: 100%;
}

.pv-forecasting-page .action-btn,
.pv-forecasting-page .kpi-card,
.pv-forecasting-page .data-table,
.pv-forecasting-page .preprocessing-summary,
.pv-forecasting-page .info-list {
  font-family: inherit;
}

.pv-forecasting-page .action-btn {
  font-size: var(--da-body-size);
  line-height: 1.2;
}

.pv-forecasting-page .preprocessing-summary,
.pv-forecasting-page .preprocessing-export-status,
.pv-forecasting-page .kpi-note {
  font-size: var(--da-note-size);
  line-height: 1.4;
}

.pv-forecasting-page .data-table th,
.pv-forecasting-page .data-table td {
  font-family: inherit;
  font-size: var(--da-body-size);
  line-height: 1.4;
}

.pv-forecasting-page .data-table th {
  font-weight: 700;
}

/* The setup panels are siblings inside a grid.  The global stacked-panel
   rule adds a top margin to the second sibling, which makes the two boxes
   appear vertically offset. */
.pv-forecasting-page>.panel>.two-col-grid {
  align-items: stretch;
}

.pv-forecasting-page>.panel>.two-col-grid>.panel {
  margin-top: 0;
  height: 100%;
  box-sizing: border-box;
}

/* ==========================================================================
   PV Forecasting Page — Industrial-Grade Design System
   (Synchronized with Cooling Demand Formatting & Aesthetics)
   ========================================================================== */

.pv-forecasting-page {
  max-width: 1800px;
  margin: 0 auto;
  padding-bottom: 16px;
  color: var(--ink);
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
  font-size: 13px;
  line-height: 1.45;
}

.pv-forecasting-page>.panel {
  margin-bottom: 18px;
}

.pv-forecasting-page .panel {
  border: 1px solid #e7ebf4;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.pv-forecasting-page .section-title {
  color: var(--ink);
  font-size: 20px;
  line-height: 1.25;
  font-weight: 700;
}

.pv-forecasting-page .section-subtitle,
.pv-forecasting-page .muted {
  color: #647493;
  font-size: 13px;
  line-height: 1.4;
}

/* PV Workbench Grid & Inner Panels */
.pv-forecasting-page .two-col-grid {
  align-items: stretch;
  gap: 18px;
}

.pv-forecasting-page .pv-panel {
  height: 100%;
  min-height: 0;
  margin-top: 0 !important;
  padding: 20px;
  background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%) !important;
  border: 1px solid #e1e8f5;
  border-radius: 12px;
  box-shadow: 0 1px 4px rgba(31, 56, 92, 0.03);
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
  box-sizing: border-box;
}

.pv-forecasting-page .pv-panel:hover {
  border-color: #cbd8ee;
  box-shadow: 0 3px 8px rgba(31, 56, 92, 0.06);
}

.pv-forecasting-page .pv-panel .section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 0;
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid #f1f5f9;
  color: #1f3864;
  font-size: 14.5px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.pv-forecasting-page .pv-prediction-panel {
  background: linear-gradient(180deg, #ffffff 0%, #f8faff 100%) !important;
}

.pv-forecasting-page label.muted {
  display: block;
  margin: 12px 0 6px;
  color: #4b5563;
  font-size: 12px;
  font-weight: 600;
}

/* Dropdown & Select Controls */
.pv-forecasting-page .Select,
.pv-forecasting-page .Select-control,
.pv-forecasting-page .Select__control {
  width: 100%;
  font-family: inherit;
  font-size: 13px;
}

.pv-forecasting-page .Select-control,
.pv-forecasting-page .Select__control {
  min-height: 38px;
  border: 1px solid #cbd5e8;
  border-radius: 8px;
  box-shadow: none;
  background: #ffffff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.pv-forecasting-page .Select-control:hover,
.pv-forecasting-page .Select__control:hover {
  border-color: #8fa5d5;
}

.pv-forecasting-page .Select.is-focused .Select-control,
.pv-forecasting-page .Select__control--is-focused {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(96, 128, 209, 0.14);
}

/* Checklists & Interactive Pill Selectors */
.pv-forecasting-page .pv-checklist {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  min-height: 28px;
  color: var(--ink);
}

.pv-forecasting-page .pv-checklist label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  color: var(--ink);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
}

.pv-forecasting-page .pv-checklist input {
  accent-color: var(--brand-deep);
  width: 15px;
  height: 15px;
}

/* Horizon pills */
.pv-forecasting-page .pv-horizon-checklist label {
  padding: 6px 13px;
  background: #fbfcfe;
  border: 1px solid #cbd5e8;
  border-radius: 7px;
  transition: all 0.15s ease-in-out;
}

.pv-forecasting-page .pv-horizon-checklist label:hover {
  border-color: #1f50a2;
  background: #f2f6fe;
  color: #1f50a2;
}

.pv-forecasting-page .pv-horizon-checklist label:has(input:checked) {
  border-color: #1d4ed8;
  background: #eff6ff;
  color: #1e40af;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(30, 64, 175, 0.08);
}

/* Model checklist cards */
.pv-forecasting-page .pv-model-checklist {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 4px;
}

.pv-forecasting-page .pv-model-checklist label {
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid #cbd5e8;
  border-radius: 8px;
  background: #fbfcfe;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease-in-out;
}

.pv-forecasting-page .pv-model-checklist label:hover {
  border-color: #1f50a2;
  background: #f2f6fe;
  color: #1f50a2;
}

.pv-forecasting-page .pv-model-checklist label:has(input:checked) {
  border-color: #1d4ed8;
  background: #eff6ff;
  color: #1e40af;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(30, 64, 175, 0.08);
}

.pv-forecasting-page .pv-model-checklist label:has(input:disabled) {
  opacity: 0.55;
  cursor: not-allowed;
  background: #f1f5f9;
  border-color: #e2e8f0;
}

.pv-forecasting-page .pv-model-help {
  margin-top: 6px;
  color: #64748b;
  font-size: 11.5px;
  line-height: 1.4;
}

/* Model Hyperparameter Tuning Section */
.pv-forecasting-page .pv-model-tuning-section {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
}

.pv-forecasting-page .pv-tuning-heading {
  margin: 0 0 4px;
  color: #1f3864;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.pv-forecasting-page .pv-model-settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.pv-forecasting-page .pv-model-settings-card {
  padding: 10px 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  transition: all 0.15s ease-in-out;
}

.pv-forecasting-page .pv-model-settings-card:hover {
  border-color: #cbd5e1;
  background: #f1f5f9;
}

.pv-forecasting-page .pv-model-settings-title {
  margin: 0 0 8px;
  color: #1e293b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.pv-forecasting-page .pv-tuning-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 10px;
}

.pv-forecasting-page .pv-tuning-field {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.pv-forecasting-page .pv-tuning-label {
  color: #64748b;
  font-size: 10.5px;
  font-weight: 600;
  white-space: nowrap;
  letter-spacing: 0.01em;
}

.pv-forecasting-page .pv-tuning-input {
  width: 100%;
  height: 29px;
  min-height: 29px;
  padding: 3px 8px;
  font-size: 12px;
  font-weight: 500;
  color: #0f172a;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
  transition: all 0.15s ease;
  box-sizing: border-box;
}

.pv-forecasting-page .pv-tuning-input:focus {
  border-color: #1f50a2;
  box-shadow: 0 0 0 2.5px rgba(31, 80, 162, 0.15);
  outline: none;
}

/* Date & Time Picker Controls */
.pv-forecasting-page .pv-date-picker,
.pv-forecasting-page .pv-date-picker .DateInput,
.pv-forecasting-page .pv-date-picker .DateInput_input {
  width: 100%;
}

.pv-forecasting-page .pv-date-picker .DateInput_input {
  min-height: 38px;
  border: 1px solid #cbd5e8;
  border-radius: 8px;
  padding: 8px 11px;
  color: var(--ink);
  font-family: inherit;
  font-size: 13px;
  line-height: 20px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.pv-forecasting-page .pv-date-picker .DateInput_input__focused {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(96, 128, 209, 0.14);
}

.pv-forecasting-page .pv-time-select .Select-control,
.pv-forecasting-page .pv-time-select .Select__control {
  min-height: 38px;
  border: 1px solid #cbd5e8;
  border-radius: 8px;
}

/* Forecast Curve Control Bar */
.pv-forecasting-page .pv-curve-controls {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  padding: 12px 16px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
}

.pv-forecasting-page .pv-curve-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1 1 140px;
  min-width: 130px;
}

.pv-forecasting-page .pv-curve-field .muted {
  margin: 0;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.pv-forecasting-page .pv-prediction-controls {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pv-forecasting-page .pv-prediction-controls label.muted {
  margin: 0 !important;
  color: #475569;
  font-size: 11.5px;
  font-weight: 600;
}

/* ==========================================================================
   Industrial-Grade Button Design System — PV Forecasting
   ========================================================================== */

.pv-forecasting-page .action-button-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  margin-bottom: 0;
}

.pv-forecasting-page .pv-upload-model {
  display: inline-flex;
}

/* Tier 1: Primary Operations (Train Model, Predict, Generate Curve) */
.pv-forecasting-page .action-btn-primary,
.pv-forecasting-page .cooling-btn-main-primary,
.pv-forecasting-page #pv-train-model,
.pv-forecasting-page #pv-predict-forecast,
.pv-forecasting-page #pv-generate-forecast-curve {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 20px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: #ffffff;
  background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%);
  border: 1px solid #1d4ed8;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(30, 64, 175, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-sizing: border-box;
  white-space: nowrap;
}

.pv-forecasting-page .action-btn-primary:hover:not(:disabled),
.pv-forecasting-page .cooling-btn-main-primary:hover:not(:disabled),
.pv-forecasting-page #pv-train-model:hover:not(:disabled),
.pv-forecasting-page #pv-predict-forecast:hover:not(:disabled),
.pv-forecasting-page #pv-generate-forecast-curve:hover:not(:disabled) {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  border-color: #3b82f6;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
}

.pv-forecasting-page .action-btn-primary:active:not(:disabled),
.pv-forecasting-page .cooling-btn-main-primary:active:not(:disabled),
.pv-forecasting-page #pv-train-model:active:not(:disabled),
.pv-forecasting-page #pv-predict-forecast:active:not(:disabled),
.pv-forecasting-page #pv-generate-forecast-curve:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.35);
}

/* Tier 1: Secondary Operations (Save Model, Upload Model) */
.pv-forecasting-page #pv-save-model-btn,
.pv-forecasting-page #pv-upload-model-btn,
.pv-forecasting-page .cooling-btn-main-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 18px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.2px;
  color: #1e3a8a;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-sizing: border-box;
  white-space: nowrap;
}

.pv-forecasting-page #pv-save-model-btn:hover:not(:disabled),
.pv-forecasting-page #pv-upload-model-btn:hover:not(:disabled),
.pv-forecasting-page .cooling-btn-main-secondary:hover:not(:disabled) {
  background: #eff6ff;
  border-color: #3b82f6;
  color: #1d4ed8;
  box-shadow: 0 3px 10px rgba(37, 99, 235, 0.12);
  transform: translateY(-1px);
}

.pv-forecasting-page #pv-save-model-btn:active:not(:disabled),
.pv-forecasting-page #pv-upload-model-btn:active:not(:disabled),
.pv-forecasting-page .cooling-btn-main-secondary:active:not(:disabled) {
  transform: translateY(0);
  background: #dbeafe;
  box-shadow: inset 0 1px 3px rgba(30, 58, 138, 0.15);
}

/* Export Buttons */
.pv-forecasting-page .cooling-btn-export,
.pv-forecasting-page #pv-download-forecast-btn,
.pv-forecasting-page #pv-download-metrics-btn,
.pv-forecasting-page #pv-download-summary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 16px;
  font-family: var(--font-sans);
  font-size: 12.5px;
  font-weight: 600;
  color: #334155;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  cursor: pointer;
  transition: all 0.2s ease;
  box-sizing: border-box;
  white-space: nowrap;
}

.pv-forecasting-page .cooling-btn-export:hover:not(:disabled),
.pv-forecasting-page #pv-download-forecast-btn:hover:not(:disabled),
.pv-forecasting-page #pv-download-metrics-btn:hover:not(:disabled),
.pv-forecasting-page #pv-download-summary-btn:hover:not(:disabled) {
  background: #eff6ff;
  border-color: #3b82f6;
  color: #1d4ed8;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.15);
}

.pv-forecasting-page .cooling-btn-export:active:not(:disabled),
.pv-forecasting-page #pv-download-forecast-btn:active:not(:disabled),
.pv-forecasting-page #pv-download-metrics-btn:active:not(:disabled),
.pv-forecasting-page #pv-download-summary-btn:active:not(:disabled) {
  background: #dbeafe;
}

/* Universal Matte Disabled State */
.pv-forecasting-page button:disabled,
.pv-forecasting-page .action-btn:disabled,
.pv-forecasting-page .action-btn-primary:disabled,
.pv-forecasting-page .cooling-btn-main-primary:disabled,
.pv-forecasting-page .cooling-btn-main-secondary:disabled,
.pv-forecasting-page .cooling-btn-export:disabled,
.pv-forecasting-page #pv-predict-forecast:disabled,
.pv-forecasting-page #pv-generate-forecast-curve:disabled,
.pv-forecasting-page #pv-save-model-btn:disabled {
  background: #e2e8f0 !important;
  background-image: none !important;
  border: 1px solid #cbd5e1 !important;
  color: #94a3b8 !important;
  cursor: not-allowed !important;
  box-shadow: none !important;
  transform: none !important;
  opacity: 0.72 !important;
  pointer-events: none !important;
}

/* Training Spinner Animation */
.pv-forecasting-page #pv-train-model.pv-training-active {
  position: relative;
  padding-right: 38px;
  cursor: wait;
  color: transparent;
  transform: none;
}

.pv-forecasting-page #pv-train-model.pv-training-active::before {
  position: absolute;
  inset: 0 30px 0 0;
  display: grid;
  place-items: center;
  color: #ffffff;
  content: "Training...";
}

.pv-forecasting-page #pv-train-model.pv-training-active::after {
  position: absolute;
  top: 50%;
  right: 14px;
  width: 12px;
  height: 12px;
  margin-top: -7px;
  border: 2px solid rgba(255, 255, 255, 0.42);
  border-top-color: #ffffff;
  border-radius: 50%;
  content: "";
  animation: pv-training-spin 0.75s linear infinite;
}

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

/* KPI Cards */
.pv-forecasting-page .kpi-grid {
  margin-bottom: 18px;
  gap: 14px;
}

.pv-forecasting-page .kpi-card {
  min-height: 98px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  box-shadow: 0 1px 4px rgba(31, 56, 92, 0.04);
  padding: 14px 16px;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.pv-forecasting-page .kpi-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 3px 8px rgba(31, 56, 92, 0.06);
}

.pv-forecasting-page .kpi-card .kpi-label {
  color: #64748b;
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.pv-forecasting-page .kpi-card .kpi-value {
  color: #0f172a;
  font-size: 20px;
  font-weight: 700;
}

.pv-forecasting-page .pv-kpi-horizon-values {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px 10px;
  font-size: 12px;
  line-height: 1.35;
}

.pv-forecasting-page .pv-kpi-horizon-item {
  white-space: nowrap;
}

/* Diagnostic Tabs */
.pv-forecasting-page .pv-diagnostic-tabs {
  margin-top: 4px;
}

.pv-forecasting-page .pv-diagnostic-tabs>div:first-child {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  border-bottom: 2px solid #e2e8f0 !important;
  overflow-x: auto;
  margin-bottom: 12px;
}

.pv-forecasting-page .pv-diagnostic-tab {
  flex: 1 1 auto;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  min-height: 38px;
  padding: 8px 16px !important;
  border: none !important;
  border-bottom: 2px solid transparent !important;
  margin-bottom: -2px;
  background: transparent !important;
  color: #64748b !important;
  font-family: inherit;
  font-size: 12.5px !important;
  font-weight: 600 !important;
  cursor: pointer;
  transition: all 0.15s ease;
}

.pv-forecasting-page .pv-diagnostic-tab:hover {
  color: #1e3a8a !important;
}

.pv-forecasting-page .pv-diagnostic-tab-selected {
  color: #1e40af !important;
  border-bottom-color: #1e40af !important;
  font-weight: 700 !important;
}

.pv-forecasting-page .pv-diagnostic-tabs .tab-content {
  padding-top: 6px;
}

/* Trend Graph Container */
.pv-forecasting-page .trend-graph {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  overflow: hidden;
  background: #ffffff;
}

/* Data Tables */
.pv-forecasting-page .data-table {
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
}

.pv-forecasting-page .data-table th {
  background: #f8fafc;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 10px 12px;
  border-bottom: 1px solid #e2e8f0;
}

.pv-forecasting-page .data-table td {
  padding: 9px 12px;
  font-size: 12.5px;
  color: #1e293b;
  border-bottom: 1px solid #f1f5f9;
}

.pv-forecasting-page .data-table tbody tr:hover td {
  background: #f8fafc;
}

.pv-forecasting-page .data-table tbody tr:last-child td {
  border-bottom: none;
}

.pv-forecasting-page .preprocessing-summary {
  align-items: center;
  min-height: 24px;
  margin-top: 8px;
}

.pv-forecasting-page .preprocessing-summary>span:not(.pill) {
  color: #64748b;
  font-size: 12px;
}

.pv-forecasting-page .preprocessing-export-status:empty {
  display: none;
}

.pv-forecasting-page .info-list {
  gap: 0;
  margin-top: 10px;
}

.pv-forecasting-page .info-row {
  min-height: 40px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #f1f5f9;
}

.pv-forecasting-page .info-row strong {
  max-width: 72%;
  color: #1e293b;
  font-size: 12.5px;
  text-align: right;
  overflow-wrap: anywhere;
}

.pv-forecasting-page .pv-system-parameters {
  margin-top: 8px;
}

.pv-forecasting-page .pv-system-parameters .data-table {
  margin-top: 8px;
}

@media (max-width: 1100px) {

  .pv-forecasting-page .pv-setup-panel,
  .pv-forecasting-page .pv-source-panel {
    min-height: 0;
  }

  .pv-forecasting-page .pv-model-settings-grid {
    grid-template-columns: 1fr;
  }

  .pv-forecasting-page .pv-prediction-controls {
    grid-template-columns: 1fr;
  }

  .pv-forecasting-page .pv-curve-controls {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .pv-forecasting-page .pv-curve-controls {
    grid-template-columns: 1fr;
  }

  .pv-forecasting-page .pv-model-checklist {
    grid-template-columns: 1fr;
  }
}

/* Cooling Demand workbench */
.cooling-demand-page {
  max-width: 1800px;
  margin: 0 auto;
  padding-bottom: 16px;
  color: var(--ink);
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
  font-size: 13px;
  line-height: 1.45;
}

.cooling-demand-page>.panel {
  margin-bottom: 18px;
}

.cooling-demand-page .panel {
  border: 1px solid #e7ebf4;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.cooling-demand-page .section-title {
  color: var(--ink);
  font-size: 20px;
  line-height: 1.25;
  font-weight: 700;
}

.cooling-demand-page .section-subtitle,
.cooling-demand-page .muted {
  color: #647493;
  font-size: 13px;
  line-height: 1.4;
}

.cooling-setup-grid {
  align-items: stretch;
  gap: 18px;
}

.cooling-inner-panel {
  height: 100%;
  min-height: 620px;
  margin-top: 0 !important;
  padding: 20px;
  background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%) !important;
}

.cooling-system-heading {
  margin-top: 28px !important;
  padding-top: 20px;
  border-top: 1px solid var(--line-soft);
}

.cooling-select {
  position: relative;
  width: 100%;
  font-size: 13px;
}

.cooling-select .Select-control,
.cooling-select .Select__control,
.cooling-select .dash-dropdown {
  width: 100%;
  font-size: 13px;
}

.cooling-demand-page label.muted {
  display: block;
  margin: 13px 0 6px;
}

.cooling-select .Select-control,
.cooling-select .Select__control,
.cooling-select .dash-dropdown {
  min-height: 38px;
  border: 1px solid #cbd5e8;
  border-radius: 9px;
  box-shadow: none;
  background: #ffffff;
}

.cooling-select .Select-control:hover,
.cooling-select .Select__control:hover,
.cooling-select .dash-dropdown:hover {
  border-color: #8fa5d5;
}

.cooling-checklist {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  min-height: 28px;
  color: var(--ink);
}

.cooling-checklist label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink);
  font-size: 13px;
}

.cooling-checklist input {
  width: 15px;
  height: 15px;
  accent-color: var(--brand-deep);
}

.cooling-status,
.cooling-run-status {
  min-height: 28px;
  margin-top: 8px;
}

.cooling-subheading {
  margin: 18px 0 10px;
  color: var(--ink);
  font-size: 15px;
}

.cooling-model-settings {
  margin-top: 12px;
  padding-top: 14px;
  border-top: 1px solid var(--line-soft);
}

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

.cooling-physics-explanation {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line-soft);
}

.cooling-explanation-heading {
  margin: 0 0 10px;
  color: var(--ink);
  font-size: 13px;
  letter-spacing: .01em;
}

.cooling-equation {
  margin-bottom: 12px;
  padding: 14px 12px;
  border: 1px solid #cbd8ee;
  border-radius: 8px;
  background: linear-gradient(180deg, #f8faff 0%, #f1f5fc 100%);
  color: #263f78;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 0;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8);
}

.cooling-equation::before {
  content: "Qₚₕᵧₛ = Qₑₙᵥ + Qwall + Qᵢₙₜₑᵣₙₐₗ + Qₛₒₗₐᵣ − Qdynamic";
  font-size: 17px;
}

.cooling-equation sub {
  font-size: .65em;
}

.cooling-explanation-text {
  margin: 0;
  padding: 8px 10px;
  border-left: 2px solid #d5e0f1;
  color: #5d6d8a;
  font-size: 11px;
  line-height: 1.5;
}

.cooling-physics-explanation>.cooling-explanation-text+.cooling-explanation-text {
  margin-top: 4px;
}

.cooling-profile-fields {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-top: 18px;
}

.cooling-small-fields {
  margin-top: 4px;
}

.cooling-field {
  display: grid;
  gap: 5px;
}

.cooling-field label {
  margin: 0 !important;
  color: #647493;
  font-size: 11px !important;
  font-weight: 700;
}

.cooling-input {
  width: 100%;
  min-height: 34px;
  border: 1px solid #cbd5e8;
  border-radius: 8px;
  padding: 7px 9px;
  color: var(--ink);
  background: #ffffff;
  font: inherit;
  font-size: 12px;
}

.cooling-input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(96, 128, 209, 0.14);
}

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

.cooling-date-picker,
.cooling-date-picker .DateInput,
.cooling-date-picker .DateInput_input {
  width: 100%;
}

.cooling-date-picker .DateInput_input {
  min-height: 38px;
  border: 1px solid #cbd5e8;
  border-radius: 9px;
  padding: 8px 11px;
  color: var(--ink);
  font-size: 13px;
}

.cooling-time-select {
  margin-top: 7px;
}

.cooling-time-select .Select-control,
.cooling-time-select .Select__control {
  min-height: 36px;
  border: 1px solid #cbd5e8;
  border-radius: 9px;
}

.cooling-profile-panel {
  margin-bottom: 18px;
}

.cooling-profile-toolbar {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) auto minmax(140px, 1fr);
  align-items: end;
  gap: 12px;
}

.cooling-profile-toolbar .cooling-select {
  margin: 0;
}

.cooling-profile-toolbar .action-btn {
  min-height: 38px;
}

.cooling-kpi-grid {
  margin-bottom: 18px;
}

.cooling-demand-page .trend-graph {
  border: 1px solid #e2e8f4;
  border-radius: 14px;
  overflow: hidden;
}

.cooling-diagnostic-tabs {
  margin-top: 4px;
}

.cooling-diagnostic-tabs .tab {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.cooling-diagnostic-tabs .tab--selected {
  color: var(--brand-deep);
  border-top-color: var(--brand-deep);
}

.cooling-results-grid {
  align-items: stretch;
}

.cooling-results-grid>.panel {
  margin-top: 0;
  height: 100%;
}

.cooling-demand-page .data-table th,
.cooling-demand-page .data-table td {
  font-size: 13px;
  line-height: 1.4;
}

@media (max-width: 1100px) {
  .cooling-profile-fields {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 780px) {

  .cooling-setup-grid,
  .cooling-date-grid,
  .cooling-results-grid,
  .cooling-profile-toolbar {
    grid-template-columns: 1fr;
  }

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

  .cooling-inner-panel {
    min-height: 0;
  }
}

/* Cooling Demand workflow sequencing */
.cooling-step-heading {
  display: block;
  margin-bottom: 14px;
}

.cooling-step-heading .section-title {
  margin: 0;
}

.cooling-step-heading .section-subtitle {
  margin-top: 4px;
  margin-bottom: 0;
}

.cooling-step-number {
  display: none;
  grid-row: span 2;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 30px;
  border-radius: 999px;
  background: rgba(79, 114, 203, 0.1);
  color: var(--brand-deep);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .05em;
}

.cooling-system-card {
  min-height: 250px !important;
}

.cooling-system-card .info-list {
  margin-top: 12px;
}

.cooling-system-card .cooling-select {
  margin-bottom: 14px;
}

.cooling-source-summary .info-list {
  gap: 0;
}

.cooling-source-summary .info-row {
  min-height: 42px;
  align-items: center;
  padding: 10px 0;
}

.cooling-source-summary .info-row strong {
  max-width: 68%;
  color: var(--ink);
  font-size: 13px;
  text-align: right;
}

.cooling-system-parameters-table {
  margin-top: 2px;
}

.cooling-system-parameters-table .data-table th,
.cooling-system-parameters-table .data-table td {
  font-size: 13px;
  line-height: 1.4;
  padding: 10px 8px;
}

.cooling-system-parameters-table .data-table th {
  font-weight: 700;
}

.cooling-system-parameters-table .data-table td:last-child {
  color: var(--ink);
  font-weight: 650;
  text-align: right;
}

/* Horizon Pill Checkboxes — Cooling Demand */
.cooling-demand-page .cooling-horizon-checklist,
.cooling-demand-page #cooling-horizon-select {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  min-height: 28px;
  margin-top: 4px;
}

.cooling-demand-page .cooling-horizon-checklist label,
.cooling-demand-page #cooling-horizon-select label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 6px 13px;
  background: #fbfcfe;
  border: 1px solid #cbd5e8;
  border-radius: 7px;
  color: #334155;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease-in-out;
  user-select: none;
}

.cooling-demand-page .cooling-horizon-checklist label:hover,
.cooling-demand-page #cooling-horizon-select label:hover {
  border-color: #1f50a2;
  background: #f2f6fe;
  color: #1f50a2;
}

.cooling-demand-page .cooling-horizon-checklist input,
.cooling-demand-page #cooling-horizon-select input {
  accent-color: var(--brand-deep);
  width: 15px;
  height: 15px;
  margin: 0;
  cursor: pointer;
}

.cooling-demand-page .cooling-horizon-checklist label:has(input:checked),
.cooling-demand-page #cooling-horizon-select label:has(input:checked) {
  border-color: #1d4ed8;
  background: #eff6ff;
  color: #1e40af;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(30, 64, 175, 0.08);
}

.cooling-demand-page .cooling-model-checklist {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 4px;
}

.cooling-demand-page .cooling-model-checklist label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid #cbd5e8;
  border-radius: 8px;
  background: #fbfcfe;
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease-in-out;
}

.cooling-demand-page .cooling-model-checklist label:hover {
  border-color: #1f50a2;
  background: #f2f6fe;
  color: #1f50a2;
}

.cooling-demand-page .cooling-model-checklist input {
  accent-color: var(--brand-deep);
  width: 15px;
  height: 15px;
}

.cooling-demand-page .cooling-model-checklist label:has(input:checked) {
  border-color: #1d4ed8;
  background: #eff6ff;
  color: #1e40af;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(30, 64, 175, 0.08);
}

.cooling-demand-page .cooling-model-help {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.4;
}

.cooling-demand-page .cooling-model-tuning-section {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line-soft);
}

.cooling-demand-page .cooling-model-settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.cooling-demand-page .cooling-model-settings-card {
  padding: 12px;
  border: 1px solid #e1e8f4;
  border-radius: 10px;
  background: #fbfcff;
}

.cooling-demand-page .cooling-model-settings-title {
  margin: 0 0 10px;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.3;
  font-weight: 700;
}

.cooling-demand-page .cooling-tuning-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.cooling-demand-page .cooling-tuning-field {
  display: grid;
  gap: 4px;
}

.cooling-demand-page .cooling-tuning-label {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.cooling-demand-page .cooling-tuning-input {
  width: 100%;
  box-sizing: border-box;
  padding: 8px 9px;
  border: 1px solid #cbd8ee;
  border-radius: 7px;
  color: var(--ink);
  background: #fff;
  font: inherit;
}

@media (max-width: 900px) {

  .cooling-demand-page .cooling-model-settings-grid,
  .cooling-demand-page .cooling-model-checklist {
    grid-template-columns: 1fr;
  }
}

.cooling-profile-grid,
.cooling-model-grid {
  align-items: stretch;
  margin-top: 16px;
}

.cooling-subpanel {
  min-height: 100%;
  padding: 16px;
  border: 1px solid #e1e8f4;
  border-radius: 12px;
  background: #fbfcff;
}

.cooling-subpanel .cooling-subheading {
  margin-top: 0;
}

.cooling-radio {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-bottom: 12px;
}

.cooling-radio label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink);
  font-size: 13px;
}

.cooling-radio input {
  accent-color: var(--brand-deep);
}

.cooling-upload {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 88px;
  padding: 14px;
  border: 1px dashed #8fa5d5;
  border-radius: 10px;
  background: rgba(96, 128, 209, .05);
  color: var(--brand-deep);
  cursor: pointer;
  text-align: center;
}

.cooling-upload-status,
.cooling-help {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.cooling-training-paradigm-section {
  padding: 14px 16px;
  background: #f7f9fd;
  border: 1px solid #e2e8f5;
  border-radius: 10px;
  margin-bottom: 14px;
}

.cooling-training-mode-radio {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 8px;
}

.cooling-training-mode-radio label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
  padding: 6px 12px;
  background: #ffffff;
  border: 1px solid #cbd5e8;
  border-radius: 8px;
  transition: all 0.15s ease-in-out;
}

.cooling-training-mode-radio label:hover {
  border-color: var(--brand);
  background: #f0f4fc;
}

.cooling-exp-upload-card {
  padding: 12px 16px;
  background: #ffffff;
  border: 1px solid #e1e8f4;
  border-radius: 10px;
}

.cooling-upload-dropzone {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border: 1.5px dashed #cbd5e8;
  border-radius: 8px;
  background: #fafcff;
  color: var(--muted);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s ease-in-out;
}

.cooling-upload-dropzone:hover {
  border-color: var(--brand);
  background: #f2f6fd;
  color: var(--brand);
}

.pv-tuning-card {
  padding: 12px;
  border: 1px solid #e1e8f4;
  border-radius: 10px;
  background: #fbfcff;
}

.pv-tuning-card-title {
  margin: 0 0 10px;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.3;
  font-weight: 700;
}

.pv-tuning-field-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.cooling-forecast-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
}

.cooling-demand-page .cooling-model-selector {
  grid-column: 1 / -1;
}

.cooling-forecast-options {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) repeat(2, minmax(130px, .65fr));
  align-items: end;
  gap: 12px;
  margin-top: 14px;
}

.cooling-forecast-options .cooling-field {
  min-width: 0;
}

@media (max-width: 900px) {

  .cooling-forecast-grid,
  .cooling-forecast-options,
  .cooling-training-mode-radio,
  .pv-tuning-field-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1100px) {
  .analysis-profile-grid {
    grid-template-columns: 1fr;
  }

  .trend-toolbar {
    grid-template-columns: 1fr;
  }

  .trend-variable-checklist {
    grid-template-columns: 1fr;
  }

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

  .location-map-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .kpi-grid,
  .four-col-grid,
  .three-col-grid,
  .two-col-grid {
    grid-template-columns: 1fr;
  }

  .topbar-title,
  .context-strip,
  .content-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .context-left,
  .context-right {
    width: 100%;
  }

  .inline-select,
  .small-select,
  .medium-select {
    width: 100%;
  }

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

  .preprocessing-split-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Building Model Settings & Weather Workbench Styles
   ========================================================================== */

.building-settings-panel {
  margin-bottom: 24px;
}

.building-subtabs .tab {
  padding: 10px 18px !important;
  font-weight: 600 !important;
  font-size: 13.5px !important;
  color: var(--muted) !important;
  border-bottom: 2px solid transparent !important;
  transition: all 0.2s ease !important;
  background: transparent !important;
}

.building-subtabs .tab--selected {
  color: var(--brand) !important;
  border-bottom: 2px solid var(--brand) !important;
  background: rgba(96, 128, 209, 0.05) !important;
}

.building-subtab-pane {
  padding: 18px 6px 10px;
}

.building-fields-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px 18px;
  align-items: end;
}

.building-fields-grid-wide {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px 18px;
  align-items: end;
}

.building-actions-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 20px;
  margin-top: 18px;
  background: var(--panel-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.building-action-buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.building-metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.building-metric-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
}

.building-metric-label {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.building-metric-val {
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  margin-top: 4px;
}

.idf-preview-container {
  margin-top: 14px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #1e2433;
  color: #e2e8f0;
  padding: 14px 16px;
  max-height: 280px;
  overflow-y: auto;
  font-family: Consolas, Monaco, "Courier New", monospace;
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
}

.weather-settings-panel {
  margin-bottom: 24px;
}

.weather-fields-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px 18px;
  align-items: end;
}

.weather-actions-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 20px;
  margin-top: 18px;
  background: var(--panel-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.weather-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

/* ==========================================================================
   Interactive Hall Geometry & Multi-Window Workbench Styles
   ========================================================================== */

.geom-workbench-grid {
  display: grid;
  grid-template-columns: minmax(360px, 1.15fr) minmax(380px, 1.25fr);
  gap: 20px;
  align-items: start;
}

.geom-control-subpanel {
  background: var(--panel-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.geom-control-heading {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  margin: 0 0 4px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.wall-selector-radio .form-check-input {
  margin-right: 6px;
}

.wall-selector-radio label {
  margin-right: 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
}

.window-card-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 280px;
  overflow-y: auto;
  padding-right: 4px;
}

.window-item-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.window-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink);
}

.window-delete-icon-btn {
  background: #f1f5f9;
  color: #64748b;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  width: 24px;
  height: 24px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: bold;
  cursor: pointer;
  line-height: 1;
  transition: all 0.15s ease;
}

.window-delete-icon-btn:hover {
  background: #fee2e2 !important;
  color: #dc2626 !important;
  border-color: #fca5a5 !important;
}

.cooling-input.input-invalid {
  border-color: #ef4444 !important;
  color: #dc2626 !important;
  background-color: #fef2f2 !important;
}

.window-card-fields {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.window-card-fields .cooling-field {
  min-width: 0;
}

.window-card-fields input {
  padding: 5px 8px;
  font-size: 12.5px;
}

.window-action-btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.geom-view-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.geom-graph-container {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #ffffff;
  overflow: hidden;
}

@media (max-width: 1000px) {
  .geom-workbench-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Per-Window Building Materials & Glazing Specification Styles
   ========================================================================== */

.mat-workbench-grid {
  display: grid;
  grid-template-columns: minmax(360px, 1.05fr) minmax(420px, 1.35fr);
  gap: 20px;
  align-items: start;
}

.mat-envelope-column {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.mat-envelope-subcard {
  background: var(--panel-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.mat-envelope-subcard .cooling-explanation-heading {
  margin: 0;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--ink);
  padding-bottom: 6px;
  border-bottom: 1px solid #e2e8f0;
}

.mat-glazing-column {
  background: var(--panel-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mat-glazing-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: 8px;
}

.mat-glazing-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  background: #ffffff;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
}

.mat-toolbar-filter-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.mat-toolbar-batch-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mat-window-card-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 520px;
  overflow-y: auto;
  padding-right: 4px;
}

.mat-window-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.mat-window-card:hover {
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.mat-window-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #f1f5f9;
  padding-bottom: 6px;
}

.mat-window-card-title-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mat-window-card-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
}

.mat-facade-pill {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 12px;
  letter-spacing: 0.2px;
}

.facade-badge-south {
  background: #fff7ed;
  color: #c2410c;
  border: 1px solid #fed7aa;
}

.facade-badge-north {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

.facade-badge-east {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #bbf7d0;
}

.facade-badge-west {
  background: #faf5ff;
  color: #7e22ce;
  border: 1px solid #e9d5ff;
}

.facade-badge-generic {
  background: #f8fafc;
  color: #475569;
  border: 1px solid #e2e8f0;
}

.mat-window-dim-badge {
  font-size: 11.5px;
  color: #64748b;
  background: #f8fafc;
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
  font-family: var(--font-mono, monospace);
}

.mat-window-preset-group {
  display: flex;
  flex-direction: column;
}

.mat-preset-dropdown {
  font-size: 12px;
}

.mat-window-fields-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.mat-window-fields-grid .cooling-field {
  min-width: 0;
}

.mat-window-fields-grid label {
  font-size: 11.5px;
  margin-bottom: 2px;
}

.mat-window-fields-grid input {
  font-size: 12.5px;
  padding: 5px 8px;
}

.mat-windows-empty-state {
  background: #ffffff;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  padding: 24px 16px;
  text-align: center;
}

@media (max-width: 1000px) {
  .mat-workbench-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Categorized Occupancy & Internal Loads Specification Styles
   ========================================================================== */

.internal-loads-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  background: var(--panel-soft);
  padding: 10px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 16px;
}

.internal-loads-categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  align-items: stretch;
}

.internal-category-card {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--panel-soft);
}

.internal-category-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 8px;
  margin-bottom: 2px;
}

.internal-category-fields-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 8px;
}

.internal-category-fields-grid .cooling-field {
  min-width: 0;
}

.internal-category-fields-grid label {
  font-size: 11.5px;
  margin-bottom: 3px;
}

.internal-category-fields-grid input {
  font-size: 12.5px;
  padding: 6px 8px;
}

/* Simulation & Controls Categorized Layout */
.sim-control-categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
  align-items: stretch;
}

.sim-category-card {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--panel-soft);
}

.deadband-badge-container {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: var(--card-bg, #ffffff);
  border: 1px solid var(--border);
  border-radius: 6px;
  margin-top: 4px;
}

.deadband-pill-ok {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 11.5px;
  font-weight: 600;
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.deadband-pill-warn {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 11.5px;
  font-weight: 600;
  background: #fffbeb;
  color: #92400e;
  border: 1px solid #fde68a;
}

.deadband-pill-error {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 11.5px;
  font-weight: 600;
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.sim-engine-hint-box {
  padding: 6px 10px;
  background: var(--card-bg, #ffffff);
  border: 1px solid var(--border);
  border-radius: 6px;
  margin-top: 4px;
}

.sim-flags-checklist label {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 0;
  font-size: 12.5px;
  cursor: pointer;
}

.schedule-summary-box {
  padding: 8px 12px;
  background: var(--card-bg, #ffffff);
  border: 1px solid var(--border);
  border-radius: 6px;
  margin-top: 8px;
  font-size: 12px;
}

.schedule-info-list {
  margin: 0;
  padding-left: 18px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
}

/* 6-Domain Schedule Workbench & 24-Hour Visualizer */
.schedule-visualizer-card {
  background: var(--panel-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 16px;
}

.schedule-visualizer-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 12px;
}

.schedules-6card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
  align-items: stretch;
}

.schedule-domain-card {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--panel-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.schedule-badge-occ {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

.schedule-badge-act {
  background: #f5f3ff;
  color: #6d28d9;
  border: 1px solid #ddd6fe;
}

.schedule-badge-light {
  background: #fffbeb;
  color: #b45309;
  border: 1px solid #fde68a;
}

.schedule-badge-equip {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

.schedule-badge-hvac {
  background: #ecfeff;
  color: #0e7490;
  border: 1px solid #a5f3fc;
}

.schedule-badge-infil {
  background: #fdf2f8;
  color: #be185d;
  border: 1px solid #fbcfe8;
}

/* =============================================================================
   Fenestration & Glazing Thermal Properties Workbench (Publication-Grade)
   ============================================================================= */
.mat-fenestration-section {
  background: var(--panel-soft, #f8fafc);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 10px;
  padding: 16px 18px;
  margin-top: 6px;
}

.mat-fenestration-header-bar {
  margin-bottom: 12px;
}

.mat-fenestration-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 10px 14px;
  background: #ffffff;
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 8px;
  margin-bottom: 16px;
}

.glazing-global-preset-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.mat-fenestration-facade-filter-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mat-windows-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 14px;
  align-items: stretch;
}

.mat-window-card {
  background: #ffffff;
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 8px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.mat-window-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.06);
}

.mat-window-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 8px;
  border-bottom: 1px solid #f1f5f9;
}

.mat-window-card-title-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mat-window-card-title {
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
}

.mat-window-dim-badge {
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.2px;
}

.mat-window-preset-group {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.mat-window-preset-group label {
  font-size: 11px;
  font-weight: 600;
  color: #475569;
}

.mat-preset-dropdown .Select-control {
  height: 32px !important;
  min-height: 32px !important;
  font-size: 12px !important;
}

.mat-window-fields-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.mat-window-fields-grid .cooling-field {
  margin-bottom: 0;
}

.mat-window-fields-grid .cooling-field label {
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 3px;
  display: block;
}

.mat-window-fields-grid .cooling-input {
  height: 32px;
  padding: 4px 8px;
  font-size: 12px;
  border-radius: 6px;
  text-align: center;
  border: 1px solid var(--border, #cbd5e1);
  background: #f8fafc;
}

.mat-window-fields-grid .cooling-input:focus {
  background: #ffffff;
  border-color: #3b82f6;
  outline: none;
}

.mat-windows-empty-state {
  grid-column: 1 / -1;
  padding: 24px;
  text-align: center;
  background: #ffffff;
  border: 1px dashed var(--border, #cbd5e1);
  border-radius: 8px;
  color: #64748b;
  font-size: 13px;
}

/* ==========================================================================
   Simulation Outputs Sub-Tab Professional & Production-Grade Styling
   ========================================================================== */

.outputs-overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 16px;
  margin-bottom: 16px;
  align-items: stretch;
}

.outputs-category-card {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--panel-soft, #f8fafc);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 8px;
  transition: all 0.2s ease-in-out;
}

.outputs-category-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
}

.outputs-dates-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.outputs-dates-grid .cooling-field {
  min-width: 0;
  margin-bottom: 0;
}

.outputs-dates-grid label {
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 3px;
}

.outputs-dates-grid input {
  font-size: 12.5px;
  text-align: center;
  padding: 6px 4px;
}

.temporal-badge-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: var(--card-bg, #ffffff);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 6px;
  margin-top: 4px;
}

.outputs-package-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 14px;
  background: var(--panel-soft, #f8fafc);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 8px;
  margin-bottom: 16px;
}

.outputs-package-title {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text, #1e293b);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-right: 4px;
}

.output-package-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  font-size: 11.5px;
  font-weight: 600;
  border-radius: 6px;
  border: 1px solid var(--border, #cbd5e1);
  background: #ffffff;
  color: #334155;
  cursor: pointer;
  transition: all 0.15s ease;
}

.output-package-btn:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
  color: #0f172a;
}

.output-package-btn-primary {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1d4ed8;
}

.output-package-btn-primary:hover {
  background: #dbeafe;
  border-color: #93c5fd;
  color: #1e40af;
}

.outputs-categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.output-var-card {
  background: var(--panel-soft, #f8fafc);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 8px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.output-var-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.output-var-list label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 6px 8px;
  background: #ffffff;
  border: 1px solid #f1f5f9;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.output-var-list label:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.output-var-list input[type="checkbox"] {
  margin-top: 3px;
  cursor: pointer;
}

.output-var-label-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.output-var-name {
  font-size: 12px;
  font-weight: 600;
  color: #1e293b;
}

.output-var-desc {
  font-size: 11px;
  color: #64748b;
  line-height: 1.35;
}

.output-artifacts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.output-artifact-card {
  padding: 12px 14px;
  background: #ffffff;
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.output-artifact-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.output-artifact-ext {
  font-family: monospace;
  font-size: 11.5px;
  font-weight: 700;
  color: #2563eb;
  background: #eff6ff;
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid #dbeafe;
}

.output-artifact-desc {
  font-size: 11.5px;
  color: #64748b;
  line-height: 1.4;
}

/* =============================================================================
   Production Grade Building Model Sub-Tabs Navigation Styles
   ============================================================================= */

.bldg-subtabs-wrapper {
  margin-bottom: 16px;
  width: 100%;
}

.bldg-subtabs-nav {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  overflow-x: auto !important;
  gap: 6px !important;
  background: #f1f5f9 !important;
  padding: 5px !important;
  border-radius: 10px !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04) !important;
  scrollbar-width: thin !important;
}

.bldg-subtabs-nav::-webkit-scrollbar {
  height: 4px;
}

.bldg-subtabs-nav::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

/* Override default Dash inline Tab styles */
.bldg-subtabs-nav .bldg-subtab {
  flex: 1 1 auto !important;
  min-width: 130px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 8px 14px !important;
  font-family: inherit !important;
  font-size: 12.5px !important;
  font-weight: 500 !important;
  color: #64748b !important;
  background: transparent !important;
  border: none !important;
  border-top: none !important;
  border-bottom: none !important;
  border-left: none !important;
  border-right: none !important;
  border-radius: 7px !important;
  cursor: pointer !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
  text-align: center !important;
  box-shadow: none !important;
  user-select: none !important;
  line-height: 1.3 !important;
  white-space: nowrap !important;
}

.bldg-subtabs-nav .bldg-subtab:hover:not(.bldg-subtab--selected) {
  background: rgba(255, 255, 255, 0.75) !important;
  color: #1e293b !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05) !important;
  transform: translateY(-1px) !important;
}

.bldg-subtabs-nav .bldg-subtab.bldg-subtab--selected {
  background: #ffffff !important;
  color: #2563eb !important;
  font-weight: 600 !important;
  border: 1px solid #dbeafe !important;
  border-top: 1px solid #dbeafe !important;
  border-bottom: 1px solid #dbeafe !important;
  border-left: 1px solid #dbeafe !important;
  border-right: 1px solid #dbeafe !important;
  border-radius: 7px !important;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.14), 0 1px 2px rgba(0, 0, 0, 0.04) !important;
  transform: translateY(-1px) !important;
}

/* Diagnostics tabs */
.cooling-diagnostic-tabs {
  display: flex !important;
  gap: 6px !important;
  background: #f8fafc !important;
  padding: 4px !important;
  border-radius: 8px !important;
  border: 1px solid #e2e8f0 !important;
  margin-bottom: 12px !important;
}

.cooling-diagnostic-tabs .tab {
  flex: 1 1 auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 7px 14px !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  color: #64748b !important;
  background: transparent !important;
  border: none !important;
  border-radius: 6px !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
}

.cooling-diagnostic-tabs .tab--selected {
  background: #ffffff !important;
  color: #2563eb !important;
  font-weight: 600 !important;
  border: 1px solid #dbeafe !important;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.1) !important;
}

/* =============================================================================
   Building Model Validation Feedback Callouts
   ============================================================================= */

.validation-feedback-card {
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid transparent;
  display: flex;
  flex-direction: column;
  gap: 3px;
  animation: fadeIn 0.25s ease-in-out;
}

.validation-feedback-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.validation-feedback-info {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1e40af;
}

.validation-feedback-success {
  background: #f0fdf4;
  border-color: #bbf7d0;
  color: #166534;
}

.validation-feedback-warning {
  background: #fffbeb;
  border-color: #fde68a;
  color: #92400e;
}

.validation-feedback-error {
  background: #fef2f2;
  border-color: #fecaca;
  color: #991b1b;
}

.validation-feedback-list {
  margin: 4px 0 0 0;
  padding-left: 18px;
  list-style-type: disc;
}

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

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

/* ==========================================================================
   Cooling Demand Model Training & Configuration Styles
   ========================================================================== */

.cooling-config-card {
  padding: 14px 18px;
  background: #ffffff;
  border: 1px solid #e1e8f5;
  border-radius: 10px;
  box-shadow: 0 1px 4px rgba(31, 56, 92, 0.03);
  transition: border-color 0.15s ease-in-out;
}

.cooling-config-card:hover {
  border-color: #cbd8ee;
}

.cooling-section-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.cooling-step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #e9effa;
  color: #1f50a2;
  font-size: 11px;
  font-weight: 700;
}

.cooling-card-title {
  margin: 0;
  color: #1f3864;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.cooling-field-label {
  display: block;
  margin-bottom: 6px;
  color: #4b5563;
  font-size: 12px;
  font-weight: 600;
}

.cooling-help-banner {
  margin: 8px 0 0;
  padding: 8px 12px;
  background: #f0f5fd;
  border-left: 3px solid #1f50a2;
  border-radius: 4px;
  color: #2b3b55;
  font-size: 12px;
  line-height: 1.45;
}

.cooling-training-mode-radio {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

.cooling-training-mode-radio label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
  padding: 7px 14px;
  background: #fbfcfe;
  border: 1px solid #cbd5e8;
  border-radius: 8px;
  transition: all 0.15s ease-in-out;
}

.cooling-training-mode-radio label:hover {
  border-color: #1f50a2;
  background: #f2f6fe;
  color: #1f50a2;
}

.cooling-exp-upload-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.cooling-upload-dropzone {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  border: 1.5px dashed #b8cbe8;
  border-radius: 8px;
  background: #f9fbfe;
  color: var(--muted);
  font-size: 12.5px;
  cursor: pointer;
  transition: all 0.15s ease-in-out;
}

.cooling-upload-dropzone:hover {
  border-color: #1f50a2;
  background: #f0f5fd;
  color: #1f50a2;
}

.cooling-dropzone-inner {
  display: flex;
  align-items: center;
  gap: 6px;
}

.cooling-section-subtitle {
  margin-left: auto;
  color: #64748b;
  font-size: 11px;
  font-weight: 500;
}

.cooling-tuning-cards-wrapper {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cooling-tuning-card {
  padding: 10px 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  transition: all 0.15s ease-in-out;
}

.cooling-tuning-card:hover {
  border-color: #cbd5e1;
  background: #f1f5f9;
}

.cooling-tuning-card-header {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}

.cooling-tuning-card-title {
  color: #1e293b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.cooling-tuning-field-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px 14px;
}

.cooling-param-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 100px;
  flex: 1 1 110px;
  max-width: 150px;
}

.cooling-param-label {
  color: #64748b;
  font-size: 10.5px;
  font-weight: 600;
  white-space: nowrap;
  letter-spacing: 0.01em;
}

.cooling-param-input {
  width: 100%;
  height: 29px;
  min-height: 29px;
  padding: 3px 8px;
  font-size: 12px;
  font-weight: 500;
  color: #0f172a;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
  transition: all 0.15s ease;
}

.cooling-param-input:focus {
  border-color: #1f50a2;
  box-shadow: 0 0 0 2.5px rgba(31, 80, 162, 0.15);
  outline: none;
}

.action-btn-secondary {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  color: #1f3864;
  font-weight: 600;
}

.action-btn-secondary:hover:not(:disabled) {
  background: #e9effa;
  border-color: #1f50a2;
  color: #1f50a2;
}

@media (max-width: 900px) {

  .cooling-training-mode-radio,
  .cooling-tuning-field-row {
    flex-direction: column;
  }

  .cooling-param-item {
    max-width: 100%;
    width: 100%;
  }
}

/* ==========================================================================
   Industrial-Grade Button Design System — Cooling Demand & Subtabs
   ========================================================================== */

/* 1. Universal Industrial Disabled State: Turns any unavailable button matte grey */
.cooling-demand-page button:disabled,
.cooling-demand-page .action-btn:disabled,
.cooling-demand-page .cooling-btn-main-primary:disabled,
.cooling-demand-page .cooling-btn-main-secondary:disabled,
.cooling-demand-page .cooling-btn-subtab-action:disabled,
.cooling-demand-page .cooling-btn-subtab-preset:disabled,
.cooling-demand-page .cooling-btn-subtab-utility:disabled,
.cooling-demand-page .cooling-btn-export:disabled,
.cooling-demand-page .output-package-btn:disabled,
.pv-forecasting-page button:disabled,
.pv-forecasting-page .action-btn:disabled,
.pv-forecasting-page .cooling-btn-main-primary:disabled,
.pv-forecasting-page .cooling-btn-main-secondary:disabled,
.pv-forecasting-page .cooling-btn-export:disabled {
  background: #e2e8f0 !important;
  background-image: none !important;
  border: 1px solid #cbd5e1 !important;
  color: #94a3b8 !important;
  cursor: not-allowed !important;
  box-shadow: none !important;
  transform: none !important;
  opacity: 0.72 !important;
  pointer-events: none !important;
}

/* 2. Tier 1: Main Tab Primary Operations (Train Model, Predict Variable) */
.cooling-btn-main-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 22px;
  font-family: var(--font-sans);
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: #ffffff;
  background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%);
  border: 1px solid #1d4ed8;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(30, 64, 175, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-sizing: border-box;
}

.cooling-btn-main-primary:hover:not(:disabled) {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  border-color: #3b82f6;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
}

.cooling-btn-main-primary:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.35);
}

/* 3. Tier 1: Main Tab Secondary Operations (Save Model, Upload Model) */
.cooling-btn-main-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.2px;
  color: #1e3a8a;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-sizing: border-box;
}

.cooling-btn-main-secondary:hover:not(:disabled) {
  background: #eff6ff;
  border-color: #3b82f6;
  color: #1d4ed8;
  box-shadow: 0 3px 10px rgba(37, 99, 235, 0.12);
  transform: translateY(-1px);
}

.cooling-btn-main-secondary:active:not(:disabled) {
  transform: translateY(0);
  background: #dbeafe;
  box-shadow: inset 0 1px 3px rgba(30, 58, 138, 0.15);
}

/* 4. Data & Report Export Buttons */
.cooling-btn-export {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 16px;
  font-family: var(--font-sans);
  font-size: 12.5px;
  font-weight: 600;
  color: #334155;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  cursor: pointer;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.cooling-btn-export:hover:not(:disabled) {
  background: #eff6ff;
  border-color: #3b82f6;
  color: #1d4ed8;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.15);
}

.cooling-btn-export:active:not(:disabled) {
  background: #dbeafe;
}

/* 5. Tier 2: Subtab Engineering Action Buttons (Distinct Dark Steel Workbench Look) */
.cooling-btn-subtab-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 15px;
  font-family: var(--font-sans);
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: #f8fafc;
  background: linear-gradient(135deg, #334155 0%, #1e293b 100%);
  border: 1px solid #475569;
  border-radius: 6px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.15);
  cursor: pointer;
  transition: all 0.18s ease;
  box-sizing: border-box;
}

.cooling-btn-subtab-action:hover:not(:disabled) {
  background: linear-gradient(135deg, #475569 0%, #334155 100%);
  border-color: #64748b;
  color: #ffffff;
  box-shadow: 0 3px 8px rgba(15, 23, 42, 0.25);
  transform: translateY(-0.5px);
}

.cooling-btn-subtab-action:active:not(:disabled) {
  background: #1e293b;
  transform: translateY(0);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* 6. Tier 3: Subtab Quick Archetype & Preset Controls (Segmented Pill Style) */
.cooling-btn-subtab-preset {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 12px;
  font-family: var(--font-sans);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.2px;
  color: #334155;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-sizing: border-box;
}

.cooling-btn-subtab-preset:hover:not(:disabled) {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
}

.cooling-btn-subtab-preset:active:not(:disabled),
.cooling-btn-subtab-preset:focus-visible:not(:disabled) {
  background: #eff6ff;
  border-color: #2563eb;
  color: #1d4ed8;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.18);
  outline: none;
}

/* 7. Tier 4: Subtab Model Engineering Utilities (Validate, Reset, Download, Preview) */
.cooling-btn-subtab-utility {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 16px;
  font-family: var(--font-sans);
  font-size: 12.5px;
  font-weight: 600;
  color: #334155;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  cursor: pointer;
  transition: all 0.18s ease;
  box-sizing: border-box;
}

.cooling-btn-subtab-utility:hover:not(:disabled) {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.1);
  transform: translateY(-0.5px);
}

.cooling-btn-subtab-utility.utility-primary {
  background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%);
  border-color: #1d4ed8;
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 2px 5px rgba(30, 64, 175, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.cooling-btn-subtab-utility.utility-primary:hover:not(:disabled) {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  border-color: #3b82f6;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.cooling-btn-subtab-utility.utility-danger {
  color: #b91c1c;
  background: #ffffff;
  border-color: #fecaca;
}

.cooling-btn-subtab-utility.utility-danger:hover:not(:disabled) {
  background: #fef2f2;
  border-color: #fca5a5;
  color: #dc2626;
}

/* 8. Output Package Buttons Refinement */
.output-package-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 12px;
  font-family: var(--font-sans);
  font-size: 11.5px;
  font-weight: 600;
  color: #475569;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-sizing: border-box;
}

.output-package-btn:hover:not(:disabled) {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
}

.output-package-btn.output-package-btn-primary {
  background: #eff6ff;
  border-color: #3b82f6;
  color: #1d4ed8;
  font-weight: 700;
  box-shadow: inset 0 0 0 1px #3b82f6;
}

/* ==========================================================================
   Publication-Grade 3D/2D Geometry Visualizer Viewport
   ========================================================================== */

.geom-viewport-subpanel {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.geom-viewport-header {
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
  padding: 8px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  min-height: 46px;
}

.geom-view-mode-group {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.geom-view-mode-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: #64748b;
  white-space: nowrap;
}

/* Publication-Grade Segmented Control Pills for Visualizer */
.geom-view-radio {
  display: inline-flex;
  align-items: center;
  background: #e2e8f0;
  padding: 2.5px;
  border-radius: 6px;
  gap: 2px;
}

.geom-view-radio label {
  display: inline-flex;
  align-items: center;
  padding: 5px 12px;
  border-radius: 4px;
  font-size: 11.5px;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  margin: 0;
  transition: all 0.15s ease;
  user-select: none;
  white-space: nowrap;
}

.geom-view-radio input[type="radio"] {
  display: none !important;
}

.geom-view-radio label:has(input:checked) {
  background: #ffffff;
  color: #1e3a8a;
  font-weight: 700;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.geom-viewport-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.geom-kpi-footer-bar {
  background: #f8fafc;
  border-top: 1px solid var(--border);
  padding: 8px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11.5px;
  font-weight: 600;
  color: #475569;
  flex-wrap: wrap;
  gap: 8px;
}

.geom-kpi-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  padding: 2px 8px;
  border-radius: 4px;
  color: #1e293b;
  font-size: 11px;
  font-weight: 600;
}

/* =============================================================================
   Data Preprocessing & Feature Engineering: Production-Grade Subtabs & Cards
   Inspired by Cooling Demand Subtabs Architecture
   ============================================================================= */

.da-preprocess-panel {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
  padding: 22px 24px;
  margin-top: 18px;
}

.da-preprocess-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}

.da-pipeline-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 9999px;
  letter-spacing: 0.02em;
  box-shadow: 0 1px 2px rgba(37, 99, 235, 0.06);
}

.da-status-dot-pulse {
  color: #10b981;
  font-size: 13px;
  line-height: 1;
  animation: da-pulse 2s infinite ease-in-out;
}

@keyframes da-pulse {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.45;
    transform: scale(1.2);
  }
}

/* Subtabs Container matching Building Model Subtabs */
.da-preprocess-subtabs-wrapper {
  margin-bottom: 18px;
  width: 100%;
}

.da-preprocess-subtabs-nav {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  overflow-x: auto !important;
  gap: 6px !important;
  background: #f1f5f9 !important;
  padding: 5px !important;
  border-radius: 10px !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04) !important;
  scrollbar-width: thin !important;
}

.da-preprocess-subtabs-nav::-webkit-scrollbar {
  height: 4px;
}

.da-preprocess-subtabs-nav::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

/* Subtab items: Default Inactive */
.da-preprocess-subtabs-nav .da-preprocess-subtab {
  flex: 1 1 auto !important;
  min-width: 125px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 8px 14px !important;
  font-family: inherit !important;
  font-size: 12.5px !important;
  font-weight: 500 !important;
  color: #64748b !important;
  background: transparent !important;
  border: none !important;
  border-top: none !important;
  border-bottom: none !important;
  border-left: none !important;
  border-right: none !important;
  border-radius: 7px !important;
  cursor: pointer !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
  text-align: center !important;
  box-shadow: none !important;
  user-select: none !important;
  line-height: 1.3 !important;
  white-space: nowrap !important;
}

/* Subtab items: Hover */
.da-preprocess-subtabs-nav .da-preprocess-subtab:hover:not(.da-preprocess-subtab--selected) {
  background: rgba(255, 255, 255, 0.85) !important;
  color: #1e293b !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05) !important;
  transform: translateY(-1px) !important;
}

/* Subtab items: Active Selected */
.da-preprocess-subtabs-nav .da-preprocess-subtab.da-preprocess-subtab--selected {
  background: #ffffff !important;
  color: #2563eb !important;
  font-weight: 600 !important;
  border: 1px solid #dbeafe !important;
  border-top: 1px solid #dbeafe !important;
  border-bottom: 1px solid #dbeafe !important;
  border-left: 1px solid #dbeafe !important;
  border-right: 1px solid #dbeafe !important;
  border-radius: 7px !important;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.14), 0 1px 2px rgba(0, 0, 0, 0.04) !important;
  transform: translateY(-1px) !important;
}

/* Override parent .data-analysis-page .preprocess-tabs specificity */
.data-analysis-page .da-preprocess-subtabs-nav .tab,
.data-analysis-page .da-preprocess-subtabs-nav .da-preprocess-subtab {
  font-family: inherit !important;
  font-size: 12.5px !important;
  font-weight: 500 !important;
  border-bottom: none !important;
  padding: 8px 14px !important;
  min-height: unset !important;
}

.data-analysis-page .da-preprocess-subtabs-nav .tab--selected,
.data-analysis-page .da-preprocess-subtabs-nav .da-preprocess-subtab--selected {
  border-bottom: 1px solid #dbeafe !important;
  color: #2563eb !important;
}

/* Pipeline Overview Workflow Grid */
.da-pipeline-workflow-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.da-pipeline-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 15px 16px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
}

.da-pipeline-card:hover {
  border-color: #bfdbfe;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.08);
  transform: translateY(-2px);
}

.da-pipeline-card-badge {
  align-self: flex-start;
  font-size: 10.5px;
  font-weight: 700;
  color: #2563eb;
  background: #eff6ff;
  border: 1px solid #dbeafe;
  padding: 2px 8px;
  border-radius: 6px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.da-pipeline-card-title {
  font-size: 13.5px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 6px;
  line-height: 1.3;
}

.da-pipeline-card-desc {
  font-size: 12px;
  color: #64748b;
  line-height: 1.45;
  margin: 0;
  flex-grow: 1;
}

/* Bottom Execution Toolbar */
.da-pipeline-execution-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin: 20px 0 12px;
  padding: 14px 18px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.da-pipeline-exec-left {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.da-exec-btn {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
  color: #ffffff !important;
  font-weight: 600 !important;
  font-size: 13px !important;
  padding: 0 20px !important;
  min-height: 42px !important;
  border-radius: 8px !important;
  border: 1px solid #1d4ed8 !important;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25) !important;
  transition: all 0.2s ease !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.da-exec-btn:hover {
  background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%) !important;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35) !important;
  transform: translateY(-1px) !important;
}

.da-pipeline-exec-info {
  display: flex;
  flex-direction: column;
}

.da-exec-title {
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.3;
}

.da-exec-subtitle {
  font-size: 11.5px;
  color: #64748b;
  line-height: 1.35;
}

.da-exec-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  font-weight: 600;
  color: #059669;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  padding: 4px 10px;
  border-radius: 9999px;
  white-space: nowrap;
}

/* Stage Action Sidebar Card */
.da-action-card {
  border: 1px solid #e2e8f0 !important;
  border-radius: 10px !important;
  background: #ffffff !important;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04) !important;
  padding: 18px !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 10px !important;
}

.da-action-card-header {
  display: flex;
  align-items: center;
  padding-bottom: 10px;
  border-bottom: 1px solid #f1f5f9;
  margin-bottom: 2px;
}

.da-stage-btn {
  background: #2563eb !important;
  color: #ffffff !important;
  font-weight: 600 !important;
  border-radius: 6px !important;
  min-height: 38px !important;
  font-size: 12.5px !important;
  border: 1px solid #1d4ed8 !important;
  transition: all 0.2s ease !important;
}

.da-stage-btn:hover {
  background: #1d4ed8 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.2) !important;
}

.da-stage-reset-btn {
  background: #f8fafc !important;
  color: #475569 !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 6px !important;
  min-height: 34px !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  transition: all 0.2s ease !important;
}

.da-stage-reset-btn:hover {
  background: #f1f5f9 !important;
  color: #0f172a !important;
  border-color: #94a3b8 !important;
}

/* ==========================================================================
   PV Forecasting Artifact Delete Button
   ========================================================================== */

.pv-btn-delete-artifact {
  background: #fff1f2 !important;
  color: #be123c !important;
  border: 1px solid #fecdd3 !important;
  border-radius: 5px !important;
  padding: 3px 8px !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  transition: all 0.15s ease !important;
}

.pv-btn-delete-artifact:hover {
  background: #ffe4e6 !important;
  border-color: #f43f5e !important;
  color: #9f1239 !important;
  transform: translateY(-1px) !important;
}

/* ==========================================================================
   Energy Management Workbench Styles
   ========================================================================== */

.energy-management-page {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

.em-top-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: linear-gradient(135deg, #1e3a5f 0%, #0f233a 100%);
  border-radius: 12px;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(15, 35, 58, 0.25);
  gap: 16px;
}

.em-title {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.em-subtitle {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: #cbd5e1;
  max-width: 780px;
  line-height: 1.45;
}

.em-study-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.em-nav-pill {
  padding: 8px 14px;
  border-radius: 20px;
  font-size: 12.5px;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
  cursor: pointer;
  transition: all 0.2s ease;
}

.em-nav-pill:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.em-nav-pill.active {
  background: #2563eb;
  color: #ffffff;
  border-color: #3b82f6;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.4);
}

.em-nav-pill:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.em-config-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(310px, 1fr));
  gap: 16px;
  margin-top: 10px;
}

.em-config-col {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: #f8fafc;
  padding: 14px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
}

.em-config-heading {
  margin: 0 0 8px 0;
  font-size: 13.5px;
  font-weight: 700;
  color: #1e293b;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 6px;
}

.em-dropdown .Select-control {
  border-radius: 6px !important;
  border-color: #cbd5e1 !important;
  min-height: 36px !important;
}

.em-quick-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.em-quick-btn {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 500;
  color: #334155;
  cursor: pointer;
  transition: all 0.15s ease;
}

.em-quick-btn:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.em-window-info-box {
  margin-top: 10px;
  padding: 10px 12px;
  background: #eef2ff;
  border: 1px solid #c7d2fe;
  border-radius: 6px;
  display: flex;
  align-items: flex-start;
}

.em-param-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.em-param-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.em-input {
  width: 100%;
  padding: 7px 9px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 13px;
  color: #1e293b;
  background: #ffffff;
}

.em-input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.em-kpi-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.em-table-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.em-table-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: #475569;
}

.em-legend-dot {
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
}

.em-tone-green { color: #15803d; background: #dcfce7; }
.em-tone-blue  { color: #1d4ed8; background: #dbeafe; }
.em-tone-amber { color: #b45309; background: #fef3c7; }
.em-tone-red   { color: #b91c1c; background: #fee2e2; }

.em-rating-badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.em-badge-green   { background: #dcfce7; color: #15803d; border: 1px solid #86efac; }
.em-badge-blue    { background: #dbeafe; color: #1d4ed8; border: 1px solid #93c5fd; }
.em-badge-amber   { background: #fef3c7; color: #b45309; border: 1px solid #fde68a; }
.em-badge-red     { background: #fee2e2; color: #b91c1c; border: 1px solid #fca5a5; }
.em-badge-neutral { background: #f1f5f9; color: #64748b; border: 1px solid #cbd5e1; }

.em-scorecard-table th {
  background: #f1f5f9 !important;
  color: #1e293b !important;
  font-size: 11.5px !important;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 9px 10px !important;
}

.em-scorecard-table td {
  padding: 8px 10px !important;
  font-size: 12.5px !important;
}

.em-action-cell {
  color: #475569;
  font-size: 11.5px !important;
  max-width: 260px;
  line-height: 1.35;
}

.em-empty-msg {
  padding: 24px;
  text-align: center;
  color: #64748b;
  font-style: italic;
  font-size: 13.5px;
}

@media (max-width: 992px) {
  .em-header-grid {
    grid-template-columns: 1fr !important;
  }
}

/* ==========================================================================
   Energy Management Analysis Configuration Panel - Production-Grade Styles
   Consistent with Cooling Demand Design System
   ========================================================================== */

.em-config-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px;
  align-items: stretch;
}

.em-config-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 16px 18px !important;
  background: #ffffff !important;
  border: 1px solid #e1e8f5 !important;
  border-radius: 10px !important;
  box-shadow: 0 1px 4px rgba(31, 56, 92, 0.04) !important;
  transition: border-color 0.15s ease, box-shadow 0.15s ease !important;
}

.em-config-card:hover {
  border-color: #cbd8ee !important;
  box-shadow: 0 4px 12px rgba(31, 56, 92, 0.06) !important;
}

.em-config-card .cooling-field {
  display: flex;
  flex-direction: column;
  position: relative;
}

/* Dash Dropdown Popover & Menu Positioning Fixes */
.dash-dropdown-wrapper {
  position: relative !important;
  width: 100%;
}

div[data-radix-popper-content-wrapper] {
  z-index: 9999 !important;
}

.dash-dropdown-content {
  z-index: 9999 !important;
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.15), 0 8px 10px -6px rgba(15, 23, 42, 0.1) !important;
}

.cooling-select .Select-menu-outer,
.Select-menu-outer {
  z-index: 9999 !important;
}

/* Radio button pills for Energy Management */
.em-radio-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}

.em-radio-pills label {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: #334155;
  cursor: pointer;
  padding: 6px 10px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 7px;
  transition: all 0.15s ease-in-out;
  white-space: nowrap;
}

.em-radio-pills label:hover {
  border-color: #2563eb;
  background: #eff6ff;
  color: #1d4ed8;
}

.em-radio-pills input[type="radio"] {
  accent-color: #2563eb;
  margin: 0;
  cursor: pointer;
}

/* Modern Slider Styling matching Cooling Demand Blue Accent */
.rc-slider {
  position: relative;
  height: 18px;
  padding: 6px 0;
  width: 100%;
  border-radius: 6px;
  touch-action: none;
  box-sizing: border-box;
}

.rc-slider-rail {
  position: absolute;
  width: 100%;
  background-color: #e2e8f0 !important;
  height: 6px !important;
  border-radius: 6px !important;
}

.rc-slider-track {
  position: absolute;
  left: 0;
  height: 6px !important;
  border-radius: 6px !important;
  background-color: #2563eb !important;
}

.rc-slider-handle {
  position: absolute;
  width: 16px !important;
  height: 16px !important;
  cursor: pointer;
  margin-top: -5px !important;
  border-radius: 50% !important;
  border: 2.5px solid #2563eb !important;
  background-color: #ffffff !important;
  box-shadow: 0 1px 4px rgba(37, 99, 235, 0.3) !important;
  transition: transform 0.12s ease, box-shadow 0.12s ease !important;
}

.rc-slider-handle:hover,
.rc-slider-handle:active,
.rc-slider-handle-dragging {
  border-color: #1d4ed8 !important;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.2) !important;
  transform: scale(1.15) !important;
}

.rc-slider-dot {
  position: absolute;
  bottom: -2px !important;
  margin-left: -4px !important;
  width: 8px !important;
  height: 8px !important;
  border: 2px solid #cbd5e1 !important;
  background-color: #ffffff !important;
  border-radius: 50% !important;
  cursor: pointer;
}

.rc-slider-dot-active {
  border-color: #2563eb !important;
}

.rc-slider-mark-text {
  font-size: 11px !important;
  font-weight: 500 !important;
  color: #64748b !important;
  margin-top: 4px !important;
}

.rc-slider-mark-text-active {
  color: #1e293b !important;
  font-weight: 600 !important;
}

/* ==========================================================================
   Coverage & Formulation Header - Production-Grade Mathematical Typography
   ========================================================================== */

.em-header-grid {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 16px;
  margin-bottom: 16px;
  align-items: stretch;
}

.em-coverage-card,
.em-formulation-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 16px 18px !important;
  background: #ffffff !important;
  border: 1px solid #e1e8f5 !important;
  border-radius: 10px !important;
  box-shadow: 0 1px 4px rgba(31, 56, 92, 0.04) !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.em-coverage-card:hover,
.em-formulation-card:hover {
  border-color: #cbd8ee !important;
  box-shadow: 0 4px 12px rgba(31, 56, 92, 0.06) !important;
}

/* Coverage Stat Tiles Grid */
.em-coverage-tiles-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 4px;
  flex-grow: 1;
}

.em-coverage-tile {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 68px;
  transition: all 0.15s ease-in-out;
}

.em-coverage-tile:hover {
  background: #ffffff;
  border-color: #cbd5e1;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
}

.em-coverage-tile-label {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  margin-bottom: 2px;
}

.em-coverage-tile-value {
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.25;
}

.em-coverage-tile-note {
  font-size: 10.5px;
  color: #94a3b8;
  margin-top: 2px;
}

/* Mathematical Formulations Grid */
.em-equations-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 4px;
  flex-grow: 1;
}

.em-equation-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 8px 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 6px;
  min-height: 72px;
  transition: all 0.15s ease;
}

.em-equation-card:hover {
  background: #ffffff;
  border-color: #cbd5e1;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);
  transform: translateY(-1px);
}

.em-equation-meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 6px;
}

.em-equation-title {
  font-size: 11.5px;
  font-weight: 700;
  color: #1e293b;
}

.em-equation-desc {
  font-size: 10px;
  color: #64748b;
  font-style: italic;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.em-equation-math {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 4px 8px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-family: "Cambria Math", "STIX Two Math", "Latin Modern Math", "Times New Roman", serif;
  font-size: 13.5px;
  color: #0f172a;
  min-height: 38px;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.02);
}

.em-math-lhs {
  font-style: italic;
  font-weight: 700;
  color: #1e3a8a;
  white-space: nowrap;
}

.em-math-eq {
  margin: 0 4px;
  color: #64748b;
  font-style: normal;
}

.em-math-frac {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  vertical-align: middle;
  padding: 0 4px;
  line-height: 1;
}

.em-math-num {
  border-bottom: 1.5px solid #334155;
  padding: 0 3px 2px 3px;
  font-size: 12px;
  font-style: italic;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
}

.em-math-den {
  padding: 2px 3px 0 3px;
  font-size: 12px;
  font-style: italic;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
}

.em-math-op {
  margin: 0 3px;
  color: #475569;
  font-style: normal;
  font-size: 12px;
  white-space: nowrap;
}

.em-math-expr-text {
  font-size: 12.5px;
  font-style: italic;
  font-weight: 600;
  color: #334155;
  white-space: nowrap;
}

.em-math-unit {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 10px;
  font-weight: 600;
  color: #64748b;
  font-style: normal;
  margin-left: 6px;
  background: #f1f5f9;
  padding: 1px 5px;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
  white-space: nowrap;
}

@media (max-width: 1080px) {
  .em-header-grid {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 640px) {
  .em-coverage-tiles-grid,
  .em-equations-grid {
    grid-template-columns: 1fr !important;
  }
}

/* =============================================================================
   PRODUCTION-GRADE USER GUIDE STYLING
   ============================================================================= */

.guide-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-bottom: 48px;
}

.guide-hero-card {
  background: linear-gradient(135deg, #091a38 0%, #0f2c5e 55%, #183d7a 100%);
  border-radius: 14px;
  padding: 30px 34px;
  color: #ffffff;
  box-shadow: 0 10px 30px rgba(15, 44, 94, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.12);
  position: relative;
  overflow: hidden;
  margin-bottom: 8px;
}

.guide-hero-card::after {
  content: "";
  position: absolute;
  top: -50px;
  right: -50px;
  width: 260px;
  height: 260px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.18) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.guide-hero-eyebrow {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #38bdf8;
  margin-bottom: 8px;
}

.guide-hero-title {
  margin: 0 0 10px 0;
  font-size: 24px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.3px;
  line-height: 1.25;
}

.guide-hero-desc {
  margin: 0 0 18px 0;
  font-size: 13.5px;
  color: #cbd5e1;
  max-width: 880px;
  line-height: 1.65;
}

.guide-hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.guide-badge-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.guide-badge-pill.green {
  background: rgba(34, 197, 94, 0.18);
  color: #4ade80;
  border: 1px solid rgba(74, 222, 128, 0.4);
}

.guide-badge-pill.blue {
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
  border: 1px solid rgba(147, 197, 253, 0.4);
}

.guide-badge-pill.purple {
  background: rgba(168, 85, 247, 0.2);
  color: #d8b4fe;
  border: 1px solid rgba(216, 180, 254, 0.4);
}

.guide-badge-pill.cyan {
  background: rgba(6, 182, 212, 0.2);
  color: #67e8f9;
  border: 1px solid rgba(103, 232, 249, 0.4);
}

/* Pipeline Grid */
.guide-pipeline-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  margin-top: 14px;
}

.guide-pipeline-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 18px 16px;
  position: relative;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  display: flex;
  flex-direction: column;
}

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

.guide-pipeline-card.planned {
  background: #f8fafc;
  border-style: dashed;
  border-color: #cbd5e1;
}

.guide-pipeline-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #eff6ff;
  color: #1d4ed8;
  font-weight: 800;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}

.guide-pipeline-card.planned .guide-pipeline-num {
  background: #f1f5f9;
  color: #64748b;
}

.guide-pipeline-title {
  margin: 0 0 2px 0;
  font-size: 14.5px;
  font-weight: 700;
  color: #0f172a;
}

.guide-pipeline-sub {
  font-size: 11px;
  font-weight: 600;
  color: #2563eb;
  margin-bottom: 8px;
  display: block;
}

.guide-pipeline-card.planned .guide-pipeline-sub {
  color: #64748b;
}

.guide-pipeline-card p {
  margin: 0 0 12px 0;
  font-size: 12px;
  color: #475569;
  line-height: 1.55;
  flex-grow: 1;
}

.guide-pipeline-meta {
  font-size: 10.5px;
  color: #64748b;
  font-weight: 600;
  background: #f8fafc;
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
}

/* Persona Cards */
.guide-persona-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin-top: 14px;
}

.guide-persona-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.guide-persona-icon {
  font-size: 26px;
  margin-bottom: 10px;
}

.guide-persona-title {
  margin: 0 0 6px 0;
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
}

.guide-persona-card p {
  font-size: 12.5px;
  color: #475569;
  margin: 0 0 12px 0;
  line-height: 1.5;
}

.guide-persona-card ol {
  margin: 0;
  padding-left: 20px;
  font-size: 12px;
  color: #334155;
  line-height: 1.7;
}

/* Steps Grid & Step Cards */
.guide-steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 14px;
}

.guide-step-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 18px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.03);
  display: flex;
  flex-direction: column;
}

.guide-step-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.guide-step-badge {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid #bfdbfe;
}

.guide-step-title-wrap {
  display: flex;
  flex-direction: column;
}

.guide-step-title {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
}

.guide-step-pill {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  color: #2563eb;
  letter-spacing: 0.5px;
}

.guide-step-summary {
  font-size: 12.5px;
  color: #475569;
  margin: 0 0 12px 0;
  line-height: 1.55;
}

.guide-step-list {
  margin: 0;
  padding-left: 18px;
  font-size: 12px;
  color: #334155;
  line-height: 1.65;
  flex-grow: 1;
}

/* Table Wrappers */
.guide-table-wrap {
  overflow-x: auto;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  margin-top: 14px;
  background: #ffffff;
}

.guide-data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
  text-align: left;
}

.guide-data-table th {
  background: #f8fafc;
  color: #475569;
  font-weight: 700;
  padding: 12px 16px;
  border-bottom: 1.5px solid #e2e8f0;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  white-space: nowrap;
}

.guide-data-table td {
  padding: 12px 16px;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
  line-height: 1.5;
}

.guide-data-table tr:last-child td {
  border-bottom: none;
}

.guide-data-table tr:nth-child(even) td {
  background: #fafcff;
}

/* Layout Utilities */
.guide-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 10px;
}

.guide-three-col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 10px;
}

@media (max-width: 860px) {
  .guide-two-col {
    grid-template-columns: 1fr;
  }
}

.guide-sub-heading {
  margin: 0 0 10px 0;
  font-size: 14.5px;
  font-weight: 700;
  color: #0f172a;
}

.guide-check-list {
  margin: 0;
  padding-left: 20px;
  font-size: 12.5px;
  color: #334155;
  line-height: 1.7;
}

.guide-bullet-list {
  margin: 0;
  padding-left: 20px;
  font-size: 12px;
  color: #475569;
  line-height: 1.65;
}

/* Algorithm & Pillar Cards */
.guide-algo-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 16px 18px;
}

.guide-algo-title {
  margin: 0 0 10px 0;
  font-size: 13.5px;
  font-weight: 700;
  color: #0f172a;
}

.guide-algo-item {
  font-size: 12px;
  line-height: 1.55;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid #edf2f7;
}

.guide-algo-item:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.guide-pillar-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 18px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
  display: flex;
  flex-direction: column;
}

.guide-pillar-pill {
  display: inline-block;
  align-self: flex-start;
  padding: 3px 10px;
  border-radius: 14px;
  font-size: 11px;
  font-weight: 700;
  margin-bottom: 10px;
}

.guide-pillar-pill.blue {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

.guide-pillar-pill.cyan {
  background: #ecfeff;
  color: #0e7490;
  border: 1px solid #a5f3fc;
}

.guide-pillar-pill.green {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #bbf7d0;
}

.guide-pillar-card h4 {
  margin: 0 0 6px 0;
  font-size: 14.5px;
  font-weight: 700;
  color: #0f172a;
}

.guide-pillar-card p {
  margin: 0 0 12px 0;
  font-size: 12px;
  color: #475569;
  line-height: 1.55;
  flex-grow: 1;
}

.guide-pillar-note {
  font-size: 10.5px;
  color: #64748b;
  font-weight: 600;
  background: #f8fafc;
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
}

/* Equations Grid & Equation Cards */
.guide-equations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
  margin-top: 14px;
}

.guide-equation-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 18px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.03);
  display: flex;
  flex-direction: column;
}

.guide-equation-header {
  margin-bottom: 12px;
}

.guide-equation-title {
  margin: 0 0 2px 0;
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
}

.guide-equation-sub {
  font-size: 11px;
  color: #64748b;
  display: block;
}

.guide-equation-math-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.guide-equation-math {
  font-family: 'Cambria Math', 'Times New Roman', serif;
  font-size: 15px;
  font-weight: 600;
  color: #1e3a8a;
  display: flex;
  align-items: center;
}

.guide-equation-unit {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 10.5px;
  font-weight: 600;
  color: #475569;
  background: #ffffff;
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid #cbd5e1;
}

.guide-equation-desc {
  margin: 0;
  font-size: 12px;
  color: #475569;
  line-height: 1.5;
  flex-grow: 1;
}

/* Status Badges */
.guide-status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.guide-status-badge.ready {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.guide-status-badge.in-progress {
  background: #fef3c7;
  color: #b45309;
  border: 1px solid #fcd34d;
}

/* Upcoming Cards */
.guide-upcoming-card {
  background: #ffffff;
  border: 1.5px dashed #cbd5e1;
  border-radius: 10px;
  padding: 20px;
}

.guide-upcoming-icon {
  font-size: 26px;
  margin-bottom: 8px;
}

.guide-upcoming-card h4 {
  margin: 0 0 4px 0;
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
}

.guide-upcoming-version {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: #b45309;
  background: #fef3c7;
  padding: 2px 8px;
  border-radius: 10px;
  margin-bottom: 10px;
}

.guide-upcoming-card p {
  font-size: 12.5px;
  color: #475569;
  margin: 0 0 10px 0;
  line-height: 1.5;
}

.guide-upcoming-card ul {
  margin: 0;
  padding-left: 20px;
  font-size: 12px;
  color: #334155;
  line-height: 1.7;
}

/* =============================================================================
   DATA ANALYSIS GUIDE - PRODUCTION-GRADE CARDS & SPEC PANELS
   ============================================================================= */

/* Module Hero Banner */
.da-hero-banner {
  background: linear-gradient(135deg, #07162e 0%, #0e2a57 45%, #0a1f40 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  padding: 24px 28px;
  color: #ffffff;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 26px rgba(10, 25, 55, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.18);
  margin-bottom: 22px;
}

.da-hero-banner::after {
  content: "";
  position: absolute;
  top: -50%;
  right: -10%;
  width: 400px;
  height: 300px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.da-hero-content {
  position: relative;
  z-index: 2;
}

.da-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
  padding: 3px 10px;
  border-radius: 20px;
  border: 1px solid rgba(56, 189, 248, 0.3);
  margin-bottom: 10px;
}

.da-hero-title {
  font-size: 22px;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 8px 0;
  letter-spacing: -0.3px;
}

.da-hero-desc {
  font-size: 13.5px;
  color: #cbd5e1;
  max-width: 900px;
  line-height: 1.6;
  margin: 0 0 18px 0;
}

.da-hero-stats-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.da-hero-stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(8px);
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 12px;
  color: #f1f5f9;
  font-weight: 600;
}

.da-hero-stat-pill strong {
  color: #38bdf8;
  font-weight: 800;
}

/* Quick Jump Anchor Strip */
.da-nav-strip {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 12px 16px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  margin-bottom: 24px;
}

.da-nav-label {
  font-size: 11.5px;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-right: 4px;
}

.da-nav-chip {
  font-size: 11.5px;
  font-weight: 600;
  color: #475569;
  background: #f1f5f9;
  padding: 5px 12px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.15s ease;
  cursor: pointer;
}

.da-nav-chip:hover {
  background: #e2e8f0;
  color: #0f172a;
  border-color: #cbd5e1;
  transform: translateY(-1px);
}

/* Grid Layouts - strictly balanced without dangling cards */
.da-var-grid {
  display: grid;
  gap: 16px;
  margin-top: 14px;
}

.da-var-grid.grid-4 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

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

@media (max-width: 1100px) {
  .da-var-grid.grid-3,
  .da-var-grid.grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .da-var-grid.grid-3,
  .da-var-grid.grid-4 {
    grid-template-columns: 1fr;
  }
}

/* Enhanced Variable Card - Production Grade Themed Aesthetic */
.da-var-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  position: relative;
  overflow: hidden;
}

.da-var-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
}

.da-var-card.power:hover { border-color: #10b981; }
.da-var-card.solar:hover { border-color: #f59e0b; }
.da-var-card.weather:hover { border-color: #0ea5e9; }

.da-var-accent-bar {
  height: 4px;
  width: 100%;
  background: #cbd5e1;
}

.da-var-accent-bar.power {
  background: linear-gradient(90deg, #059669 0%, #10b981 100%);
}

.da-var-accent-bar.solar {
  background: linear-gradient(90deg, #d97706 0%, #f59e0b 100%);
}

.da-var-accent-bar.weather {
  background: linear-gradient(90deg, #0284c7 0%, #38bdf8 100%);
}

.da-var-inner {
  padding: 18px 20px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-grow: 1;
}

.da-var-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid #f1f5f9;
}

.da-var-title-group {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.da-var-title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.2px;
}

.da-var-sublabel {
  font-size: 11.5px;
  color: #64748b;
  font-weight: 500;
}

.da-var-badges-col {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
}

.da-badge-code {
  font-family: 'JetBrains Mono', Consolas, "Courier New", monospace;
  font-size: 11px;
  font-weight: 600;
  color: #1e40af;
  background: #eff6ff;
  padding: 2.5px 8px;
  border-radius: 6px;
  border: 1px solid #bfdbfe;
}

.da-badge-meta-strip {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.da-badge-unit {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  background: #f1f5f9;
  color: #475569;
}

.da-badge-unit.power {
  background: #ecfdf5;
  color: #047857;
  border-color: #a7f3d0;
}

.da-badge-unit.solar {
  background: #fffbeb;
  color: #b45309;
  border-color: #fde68a;
}

.da-badge-unit.weather {
  background: #f0f9ff;
  color: #0369a1;
  border-color: #bae6fd;
}

.da-badge-range {
  font-size: 10.5px;
  font-weight: 600;
  color: #475569;
  background: #f8fafc;
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

.da-var-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex-grow: 1;
}

.da-var-def-block {
  font-size: 12.5px;
  color: #334155;
  line-height: 1.6;
}

.da-var-def-block strong {
  color: #0f172a;
}

.da-var-diag-box {
  background: #f8fafc;
  border-radius: 8px;
  padding: 10px 14px;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #94a3b8;
  font-size: 11.5px;
  color: #334155;
  line-height: 1.55;
  margin-top: auto;
}

.da-var-diag-box.power {
  background: #f0fdf4;
  border-color: #bbf7d0;
  border-left: 4px solid #10b981;
  color: #166534;
}

.da-var-diag-box.solar {
  background: #fffbeb;
  border-color: #fde68a;
  border-left: 4px solid #f59e0b;
  color: #78350f;
}

.da-var-diag-box.weather {
  background: #f0f9ff;
  border-color: #bae6fd;
  border-left: 4px solid #0284c7;
  color: #075985;
}

.da-var-diag-title {
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.da-var-diag-box.power .da-var-diag-title { color: #065f46; }
.da-var-diag-box.solar .da-var-diag-title { color: #92400e; }
.da-var-diag-box.weather .da-var-diag-title { color: #0369a1; }

/* Stage Containers */
.da-stage-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 22px 24px;
  margin-top: 20px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.03);
}

.da-stage-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1.5px solid #f1f5f9;
  flex-wrap: wrap;
  gap: 12px;
}

.da-stage-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.da-stage-num-badge {
  background: linear-gradient(135deg, #1e40af 0%, #2563eb 100%);
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 11px;
  border-radius: 8px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.28);
}

.da-stage-title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
}

.da-stage-desc {
  font-size: 12.5px;
  color: #64748b;
  margin: 0;
  max-width: 500px;
  text-align: right;
}

/* Stage Grids */
.da-spec-grid {
  display: grid;
  gap: 16px;
}

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

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

@media (max-width: 1100px) {
  .da-spec-grid.grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .da-spec-grid.grid-3,
  .da-spec-grid.grid-2 {
    grid-template-columns: 1fr;
  }
}

/* Enhanced Parameter Specification Card */
.da-spec-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.02);
}

.da-spec-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
}

.da-spec-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.da-spec-title {
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.da-spec-default-badge {
  font-size: 11px;
  font-weight: 600;
  color: #1e40af !important;
  background: #eff6ff !important;
  padding: 2.5px 8px;
  border-radius: 6px;
  border: 1px solid #bfdbfe !important;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.da-spec-code-tag {
  font-family: 'JetBrains Mono', Consolas, monospace;
  font-size: 11px;
  color: #64748b;
  background: #f1f5f9;
  padding: 1.5px 6px;
  border-radius: 4px;
  display: inline-block;
  margin-bottom: 8px;
  width: fit-content;
}

.da-spec-options-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 6px 0 10px 0;
}

/* Parameter Option Pills (Active highlighted, options distinct) */
.da-spec-pill {
  font-size: 11px;
  font-weight: 500;
  padding: 3.5px 9px;
  border-radius: 6px;
  background: #f8fafc;
  color: #475569;
  border: 1px solid #e2e8f0;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.15s ease;
}

.da-spec-pill.active {
  background: #2563eb !important;
  color: #ffffff !important;
  font-weight: 600 !important;
  border-color: #1d4ed8 !important;
  box-shadow: 0 1px 3px rgba(37, 99, 235, 0.25) !important;
}

.da-spec-math-box {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 8px 12px;
  margin: 6px 0 10px 0;
  font-family: 'Cambria Math', 'Times New Roman', serif;
  font-size: 13px;
  font-weight: 600;
  color: #1e3a8a;
  text-align: center;
  letter-spacing: 0.2px;
}

.da-spec-desc {
  font-size: 12px;
  color: #334155;
  line-height: 1.55;
  margin: 0;
  flex-grow: 1;
}

.da-spec-tip {
  font-size: 11.5px;
  color: #92400e;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-left: 3.5px solid #f59e0b;
  padding: 8px 10px;
  border-radius: 0 6px 6px 0;
  margin-top: 10px;
  line-height: 1.5;
}

.da-spec-tip strong {
  color: #78350f;
}





/* =============================================================================
   DECISION SUPPORT DASHBOARD (PRODUCTION-GRADE EXECUTIVE WORKBENCH)
   ============================================================================= */

.dss-dashboard-page {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.dss-hero-banner {
  background: #ffffff;
  color: #0f172a;
  border-radius: 12px;
  padding: 12px 18px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
  border: 1px solid #e2e8f0;
  border-left: 4px solid #2563eb;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.dss-hero-left {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.dss-hero-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.dss-hero-title {
  margin: 0;
  font-size: 16.5px;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.2px;
}

.dss-hero-badge {
  font-size: 11px;
  font-weight: 600;
  color: #1d4ed8;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  padding: 2px 9px;
  border-radius: 999px;
}

.dss-preset-desc-box {
  font-size: 12px;
  color: #64748b;
  font-weight: 500;
  line-height: 1.3;
}

.dss-preset-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.dss-preset-bar-label {
  font-size: 11.5px;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.dss-preset-buttons {
  display: inline-flex;
  gap: 4px;
  background: #f1f5f9;
  padding: 4px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  flex-wrap: wrap;
}

.dss-preset-btn {
  background: transparent;
  color: #475569;
  border: 1px solid transparent;
  border-radius: 7px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.16s ease;
  white-space: nowrap;
}

.dss-preset-btn:hover {
  background: rgba(255, 255, 255, 0.75);
  color: #0f172a;
}

.dss-preset-btn.active {
  background: #ffffff;
  color: #2563eb;
  border-color: #dbeafe;
  box-shadow: 0 1px 4px rgba(37, 99, 235, 0.12);
}

.dss-scale-pill {
  font-size: 11.5px;
  font-weight: 700;
  color: #1d4ed8;
  background: #eff6ff;
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid #bfdbfe;
}

.dss-action-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #e2e8f0;
  flex-wrap: wrap;
}

.dss-action-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.dss-view-filter-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.dss-view-label {
  font-size: 12px;
  font-weight: 700;
  color: #334155;
}

.dss-executive-wrap {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 16px;
}

.dss-stage-grid {
  display: grid;
  grid-template-columns: 1.25fr repeat(4, 1fr);
  gap: 12px;
}

@media (max-width: 1360px) {
  .dss-stage-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  }
}

.dss-score-hero-card {
  border-radius: 12px;
  border: 2px solid #2563eb;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

.dss-score-eyebrow {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.8px;
  color: #475569;
  text-transform: uppercase;
}

.dss-score-circle-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 6px 0;
}

.dss-score-number {
  font-size: 28px;
  font-weight: 900;
  letter-spacing: -0.8px;
  line-height: 1;
}

.dss-score-meta {
  font-size: 11.5px;
  font-weight: 600;
  color: #334155;
  margin-top: 4px;
}

.dss-score-desc {
  margin: 4px 0 8px 0;
  font-size: 11.5px;
  color: #334155;
  line-height: 1.45;
}

.dss-quick-metrics-strip {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 11px;
  font-weight: 700;
  color: #0f172a;
  background: rgba(255, 255, 255, 0.75);
  padding: 5px 8px;
  border-radius: 6px;
  border: 1px solid rgba(148, 163, 184, 0.25);
}

.dss-module-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  padding: 14px 15px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.04);
}

.dss-module-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

.dss-stage-tag {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.5px;
  padding: 2.5px 7px;
  border-radius: 5px;
  text-transform: uppercase;
}

.dss-stage-tag.tag-blue {
  background: #eff6ff;
  color: #1d4ed8;
}

.dss-stage-tag.tag-amber {
  background: #fffbeb;
  color: #b45309;
}

.dss-stage-tag.tag-cyan {
  background: #ecfeff;
  color: #0369a1;
}

.dss-stage-tag.tag-green {
  background: #f0fdf4;
  color: #15803d;
}

.dss-module-big {
  font-size: 17px;
  font-weight: 800;
  color: #0f172a;
  margin: 2px 0 8px 0;
}

.dss-module-kv-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11.5px;
  color: #475569;
}

.dss-module-kv-list > div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px dashed #f1f5f9;
  padding-bottom: 2px;
}

.dss-module-kv-list strong {
  color: #0f172a;
  font-weight: 600;
}

.pill-amber {
  background: #fffbeb;
  color: #b45309;
  border: 1px solid #fde68a;
}

.pill-blue {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

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

@media (max-width: 1100px) {
  .dss-recommendations-grid {
    grid-template-columns: 1fr;
  }
}

.dss-rec-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-top: 3px solid #2563eb;
  border-radius: 12px;
  padding: 14px 16px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
}

.dss-rec-card.dss-rec-green {
  border-top-color: #16a34a;
}

.dss-rec-card.dss-rec-amber {
  border-top-color: #d97706;
}

.dss-rec-card.dss-rec-blue {
  border-top-color: #2563eb;
}

.dss-rec-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.dss-rec-cat-group {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.dss-rec-step {
  font-size: 10.5px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 5px;
  letter-spacing: 0.3px;
}

.dss-rec-step-amber {
  background: #fffbeb;
  color: #b45309;
  border: 1px solid #fde68a;
}

.dss-rec-step-blue {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

.dss-rec-step-green {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #bbf7d0;
}

.dss-rec-category {
  font-size: 11px;
  font-weight: 700;
  color: #475569;
  text-transform: uppercase;
  letter-spacing: 0.45px;
}

.dss-rec-title {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.35;
}

.dss-rec-metrics-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 7px 9px;
}

.dss-rec-metric-box {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.dss-rec-metric-label {
  font-size: 10px;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.dss-rec-metric-value {
  font-size: 11.5px;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dss-rec-detail {
  margin: 0;
  font-size: 11.5px;
  color: #475569;
  line-height: 1.45;
}

.dss-results-stack,
.dss-module-section {
  display: flex;
  flex-direction: column;
  gap: 18px;
  width: 100%;
}

.dss-results-stack .panel,
.dss-module-section .panel {
  width: 100%;
  margin-top: 0 !important;
  overflow: visible;
}

.dss-graph-tall,
.dss-graph-tall .js-plotly-plot,
.dss-graph-tall .plot-container {
  height: 580px !important;
  min-height: 580px !important;
  width: 100% !important;
}

.dss-graph-standard,
.dss-graph-standard .js-plotly-plot,
.dss-graph-standard .plot-container {
  height: 460px !important;
  min-height: 460px !important;
  width: 100% !important;
}
