:root {
  --background: #0f172a;
  --panel: #111827;
  --card: #1e293b;
  --border: #334155;
  --text: #f8fafc;
  --muted: #94a3b8;
  --cyan: #38bdf8;
  --green: #22c55e;
  --yellow: #facc15;
  --red: #ef4444;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--background);
  color: var(--text);
}

.page {
  max-width: 1600px;
  margin: 0 auto;
  padding: 20px;
}

.header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 18px;
}

.logo {
  width: auto;
  height: 82px;
  padding: 6px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgb(0 0 0 / 35%);
}

h1 {
  margin: 0;
  font-size: 38px;
}

h2 {
  margin-top: 0;
}

.subtitle {
  margin-top: 5px;
  color: var(--muted);
  font-size: 19px;
}

.powered {
  margin-top: 7px;
  color: #60a5fa;
  font-size: 14px;
}

.status-ribbon {
  display: grid;
  grid-template-columns: repeat(7, minmax(130px, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}

.status-item {
  padding: 13px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  text-align: center;
}

.dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 7px;
  border-radius: 50%;
}

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

.yellow {
  background: var(--yellow);
}

.red {
  background: var(--red);
}

.top-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.panel {
  margin-bottom: 16px;
  padding: 20px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
}

.control-row {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 10px;
}

form {
  margin: 0;
}

label {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 13px;
}

button,
select {
  min-height: 42px;
  padding: 10px 15px;
  border: 0;
  border-radius: 9px;
  font-size: 14px;
}

button {
  cursor: pointer;
}

button:hover {
  filter: brightness(0.9);
}

button.danger {
  background: #fee2e2;
}

.muted {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.weather-summary,
.system-state {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.weather-summary div,
.system-state div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 10px;
  background: var(--card);
  border-radius: 10px;
}

.weather-summary span,
.system-state span {
  color: var(--muted);
}

.mimic-panel {
  overflow: hidden;
}

.mimic {
  display: grid;
  grid-template-columns: 1fr 70px 1fr 70px 1fr;
  align-items: center;
  gap: 10px;
}

.asset {
  min-height: 160px;
  padding: 20px;
  background: var(--card);
  border-radius: 15px;
  text-align: center;
}

.asset-icon {
  font-size: 38px;
}

.asset-name {
  margin-top: 8px;
  color: var(--muted);
}

.asset-value {
  margin-top: 10px;
  color: var(--cyan);
  font-size: 28px;
  font-weight: 700;
}

.asset-detail {
  margin-top: 8px;
}

.arrow {
  color: var(--cyan);
  font-size: 36px;
  text-align: center;
}

.tank {
  position: relative;
  height: 70px;
  margin-top: 12px;
  overflow: hidden;
  border: 2px solid #64748b;
  border-radius: 10px;
}

.tank-fill {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  background: #0ea5e9;
  transition: height 0.6s ease;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(220px, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.metric-card {
  padding: 17px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.metric-label {
  color: #e2e8f0;
  font-size: 14px;
}

.metric-value {
  margin-top: 7px;
  color: var(--cyan);
  font-size: 28px;
  font-weight: 700;
}

.ok-text {
  color: var(--green);
}

.warn-text {
  color: var(--yellow);
}

.bad-text {
  color: var(--red);
}

.recommendation {
  color: var(--cyan);
  font-size: 22px;
  font-weight: 700;
}

code {
  color: #bfdbfe;
}

@media (max-width: 1150px) {
  .status-ribbon {
    grid-template-columns: repeat(3, 1fr);
  }

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

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

@media (max-width: 760px) {
  .header {
    align-items: flex-start;
  }

  .logo {
    height: 65px;
  }

  h1 {
    font-size: 28px;
  }

  .status-ribbon,
  .metric-grid {
    grid-template-columns: 1fr;
  }

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

  .arrow {
    transform: rotate(90deg);
  }
}

.chart-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(300px, 1fr));
  gap: 16px;
}

.chart-box {
  min-height: 250px;
  padding: 16px;
  background: var(--card);
  border-radius: 12px;
}

.chart-box h3 {
  margin-top: 0;
}

.chart-box canvas {
  width: 100%;
  height: 190px;
}

.two-column-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

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

.detail-grid div {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  padding: 11px;
  background: var(--card);
  border-radius: 9px;
}

.detail-grid span {
  color: var(--muted);
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.download-button {
  padding: 10px 14px;
  color: #0f172a;
  background: #e2e8f0;
  border-radius: 9px;
  text-decoration: none;
  font-weight: 700;
}

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

.register-table th,
.register-table td {
  padding: 11px;
  border-bottom: 1px solid var(--border);
  text-align: left;
}

.register-table th {
  color: var(--muted);
}

.event-log {
  max-height: 260px;
  overflow-y: auto;
  font-family: monospace;
  font-size: 13px;
}

.event-row {
  padding: 8px;
  border-bottom: 1px solid var(--border);
}

@media (max-width: 900px) {
  .chart-grid,
  .two-column-grid {
    grid-template-columns: 1fr;
  }
}


/* ================================================================
   AI-Kit Digital Twin v4.0 — Executive interface
   ================================================================ */

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  background:
    radial-gradient(
      circle at 15% 0%,
      rgb(14 165 233 / 14%),
      transparent 30%
    ),
    radial-gradient(
      circle at 90% 12%,
      rgb(34 197 94 / 10%),
      transparent 28%
    ),
    var(--background);
}

.company-header {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(390px, 0.75fr);
  gap: 26px;
  align-items: center;
  margin-bottom: 14px;
  padding: 24px;
  overflow: hidden;
  background:
    linear-gradient(
      135deg,
      rgb(15 23 42 / 98%),
      rgb(17 24 39 / 96%)
    );
  border: 1px solid rgb(56 189 248 / 26%);
  border-radius: 22px;
  box-shadow: 0 18px 50px rgb(0 0 0 / 28%);
}

.company-brand {
  display: flex;
  gap: 20px;
  align-items: center;
  min-width: 0;
}

.company-logo {
  width: 116px;
  height: 116px;
  flex: 0 0 auto;
  object-fit: contain;
  padding: 8px;
  background: white;
  border-radius: 18px;
  box-shadow:
    0 12px 32px rgb(0 0 0 / 35%),
    0 0 0 1px rgb(255 255 255 / 10%);
}

.company-copy {
  min-width: 0;
}

.company-name {
  margin-bottom: 8px;
  font-size: clamp(22px, 2.4vw, 34px);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.company-address {
  max-width: 720px;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.55;
}

.company-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 15px;
  margin-top: 12px;
  font-size: 13px;
}

.company-contact span {
  color: #cbd5e1;
}

.company-contact a {
  color: #7dd3fc;
  text-decoration: none;
}

.company-contact a:hover {
  color: white;
  text-decoration: underline;
}

.product-identity {
  position: relative;
  padding: 20px;
  background:
    linear-gradient(
      145deg,
      rgb(14 116 144 / 32%),
      rgb(30 41 59 / 55%)
    );
  border: 1px solid rgb(125 211 252 / 22%);
  border-radius: 18px;
}

.product-identity h1 {
  margin-top: 13px;
  font-size: clamp(28px, 3vw, 44px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.product-subtitle {
  margin-top: 9px;
  color: #bae6fd;
  font-size: 15px;
  line-height: 1.45;
}

.live-product-badge {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 7px 11px;
  color: #bbf7d0;
  background: rgb(34 197 94 / 12%);
  border: 1px solid rgb(34 197 94 / 30%);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.live-pulse {
  width: 9px;
  height: 9px;
  background: #22c55e;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgb(34 197 94 / 55%);
  animation: live-pulse 1.8s infinite;
}

@keyframes live-pulse {
  70% {
    box-shadow: 0 0 0 9px rgb(34 197 94 / 0%);
  }

  100% {
    box-shadow: 0 0 0 0 rgb(34 197 94 / 0%);
  }
}

.product-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 15px;
}

.product-badges span {
  padding: 6px 9px;
  color: #e0f2fe;
  background: rgb(2 132 199 / 18%);
  border: 1px solid rgb(56 189 248 / 22%);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}

.product-nav {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  gap: 7px;
  margin-bottom: 18px;
  padding: 9px;
  overflow-x: auto;
  background: rgb(15 23 42 / 92%);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 10px 28px rgb(0 0 0 / 18%);
  backdrop-filter: blur(12px);
}

.product-nav a {
  flex: 0 0 auto;
  padding: 10px 14px;
  color: #cbd5e1;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.product-nav a:hover {
  color: white;
  background: rgb(56 189 248 / 14%);
}

.platform-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(310px, 0.55fr);
  gap: 18px;
  margin-bottom: 18px;
  padding: clamp(24px, 4vw, 44px);
  background:
    linear-gradient(
      120deg,
      rgb(3 105 161 / 34%),
      rgb(15 23 42 / 80%) 55%,
      rgb(21 128 61 / 24%)
    );
  border: 1px solid rgb(56 189 248 / 28%);
  border-radius: 22px;
  box-shadow: 0 20px 55px rgb(0 0 0 / 24%);
}

.eyebrow {
  margin-bottom: 9px;
  color: #7dd3fc;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.hero-copy h2 {
  max-width: 900px;
  margin-bottom: 15px;
  font-size: clamp(28px, 4vw, 50px);
  line-height: 1.08;
  letter-spacing: -0.035em;
}

.hero-copy p {
  max-width: 830px;
  margin: 0;
  color: #cbd5e1;
  font-size: 16px;
  line-height: 1.65;
}

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

.primary-action,
.secondary-action,
.platform-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 43px;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.primary-action {
  color: #082f49;
  background: #7dd3fc;
}

.secondary-action {
  color: #e0f2fe;
  background: rgb(14 116 144 / 24%);
  border: 1px solid rgb(125 211 252 / 28%);
}

.primary-action:hover,
.secondary-action:hover,
.platform-button:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.hero-status-card {
  align-self: stretch;
  padding: 18px;
  background: rgb(15 23 42 / 72%);
  border: 1px solid rgb(148 163 184 / 20%);
  border-radius: 16px;
}

.hero-status-line {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  padding: 13px 5px;
  border-bottom: 1px solid rgb(148 163 184 / 14%);
}

.hero-status-line:last-child {
  border-bottom: 0;
}

.hero-status-line span {
  color: var(--muted);
}

.platform-launcher {
  margin-bottom: 18px;
  padding: 24px;
  background: rgb(17 24 39 / 78%);
  border: 1px solid var(--border);
  border-radius: 20px;
}

.section-heading {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 0.65fr);
  gap: 20px;
  align-items: end;
  margin-bottom: 20px;
}

.section-heading h2 {
  margin-bottom: 0;
  font-size: clamp(25px, 3vw, 36px);
}

.section-heading p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

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

.platform-card {
  position: relative;
  display: flex;
  min-height: 390px;
  flex-direction: column;
  padding: 20px;
  overflow: hidden;
  background:
    linear-gradient(
      155deg,
      rgb(30 41 59 / 96%),
      rgb(15 23 42 / 96%)
    );
  border: 1px solid var(--border);
  border-radius: 17px;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

.platform-card::after {
  position: absolute;
  top: -55px;
  right: -55px;
  width: 140px;
  height: 140px;
  content: "";
  background: rgb(56 189 248 / 10%);
  border-radius: 50%;
}

.platform-card:hover {
  transform: translateY(-4px);
  border-color: rgb(56 189 248 / 48%);
  box-shadow: 0 16px 34px rgb(0 0 0 / 23%);
}

.platform-icon {
  position: relative;
  z-index: 1;
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  color: #e0f2fe;
  background: rgb(14 165 233 / 16%);
  border: 1px solid rgb(56 189 248 / 28%);
  border-radius: 14px;
  font-size: 27px;
}

.platform-tag {
  margin-bottom: 7px;
  color: #7dd3fc;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.11em;
}

.platform-card h3 {
  margin: 0 0 10px;
  font-size: 22px;
}

.platform-card p {
  margin: 0;
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.55;
}

.platform-card ul {
  padding-left: 18px;
  margin: 18px 0 20px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.platform-button {
  width: 100%;
  margin-top: auto;
  color: #082f49;
  background: #7dd3fc;
}

.cleaning-card .platform-icon {
  color: #fef9c3;
  background: rgb(234 179 8 / 14%);
  border-color: rgb(250 204 21 / 26%);
}

.cleaning-card .platform-tag {
  color: #fde047;
}

.cleaning-card .platform-button {
  color: #422006;
  background: #fde047;
}

.simulator-card .platform-icon {
  color: #ffedd5;
  background: rgb(249 115 22 / 14%);
  border-color: rgb(251 146 60 / 26%);
}

.simulator-card .platform-tag {
  color: #fdba74;
}

.simulator-card .platform-button {
  color: #431407;
  background: #fdba74;
}

.cloud-card .platform-icon {
  color: #dcfce7;
  background: rgb(34 197 94 / 13%);
  border-color: rgb(74 222 128 / 24%);
}

.cloud-card .platform-tag {
  color: #86efac;
}

.cloud-card .platform-button {
  color: #052e16;
  background: #86efac;
}

@media (max-width: 1250px) {
  .company-header,
  .platform-hero {
    grid-template-columns: 1fr;
  }

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

  .product-identity {
    max-width: none;
  }
}

@media (max-width: 760px) {
  .page {
    padding: 10px;
  }

  .company-header,
  .platform-hero,
  .platform-launcher {
    padding: 17px;
    border-radius: 16px;
  }

  .company-brand {
    align-items: flex-start;
  }

  .company-logo {
    width: 76px;
    height: 76px;
    border-radius: 13px;
  }

  .company-contact {
    flex-direction: column;
    gap: 5px;
  }

  .product-identity {
    padding: 16px;
  }

  .section-heading {
    grid-template-columns: 1fr;
  }

  .platform-card-grid {
    grid-template-columns: 1fr;
  }

  .platform-card {
    min-height: auto;
  }
}


/* ================================================================
   AI-Kit v4.0.1 — Simplified operator comparison
   ================================================================ */

.simple-operator-view {
  margin-bottom: 18px;
  padding: 24px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 20px;
}

.simple-view-heading,
.comparison-heading,
.explanation-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
}

.simple-view-heading {
  margin-bottom: 18px;
}

.simple-view-heading h2,
.comparison-heading h3,
.explanation-heading h3 {
  margin: 0;
}

.simple-view-heading p,
.comparison-heading p {
  margin: 7px 0 0;
  color: var(--muted);
}

.simple-live-badge {
  display: inline-flex;
  flex: 0 0 auto;
  gap: 8px;
  align-items: center;
  padding: 8px 12px;
  color: #bbf7d0;
  background: rgb(34 197 94 / 12%);
  border: 1px solid rgb(34 197 94 / 28%);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

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

.simple-kpi {
  padding: 17px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
}

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

.simple-kpi strong {
  display: block;
  color: var(--text);
  font-size: 25px;
}

.simple-kpi small {
  display: block;
  margin-top: 7px;
  color: #7dd3fc;
  font-size: 12px;
}

.comparison-heading {
  align-items: end;
  margin-bottom: 13px;
}

.comparison-status {
  flex: 0 0 auto;
  padding: 9px 12px;
  color: var(--muted);
  background: rgb(30 41 59 / 70%);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 13px;
}

.comparison-status strong {
  margin-left: 5px;
  color: #7dd3fc;
}

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

.strategy-card {
  position: relative;
  padding: 19px;
  background: rgb(30 41 59 / 72%);
  border: 1px solid var(--border);
  border-radius: 15px;
  transition:
    border-color 180ms ease,
    background 180ms ease;
}

.strategy-card.active-strategy {
  background: rgb(14 116 144 / 18%);
  border-color: #38bdf8;
  box-shadow: inset 0 0 0 1px rgb(56 189 248 / 16%);
}

.strategy-card.rf-strategy.active-strategy {
  background: rgb(21 128 61 / 15%);
  border-color: #4ade80;
  box-shadow: inset 0 0 0 1px rgb(74 222 128 / 15%);
}

.strategy-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.strategy-number {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  color: #bae6fd;
  background: rgb(14 165 233 / 13%);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 800;
}

.strategy-active-badge {
  padding: 5px 8px;
  color: #bbf7d0;
  background: rgb(34 197 94 / 14%);
  border: 1px solid rgb(34 197 94 / 25%);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
}

.hidden {
  display: none !important;
}

.strategy-card h3 {
  margin: 16px 0 8px;
  font-size: 20px;
}

.strategy-frequency {
  color: var(--text);
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 800;
  letter-spacing: -0.04em;
}

.strategy-frequency small {
  color: var(--muted);
  font-size: 15px;
  font-weight: 600;
}

.strategy-card p {
  min-height: 62px;
  margin: 12px 0;
  color: #cbd5e1;
  font-size: 13px;
  line-height: 1.55;
}

.strategy-source {
  padding-top: 12px;
  color: #7dd3fc;
  border-top: 1px solid rgb(148 163 184 / 14%);
  font-size: 12px;
}

.simple-explanation-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.55fr);
  gap: 13px;
  margin-top: 13px;
}

.simple-ai-explanation,
.simple-result-card {
  padding: 19px;
  background: rgb(15 23 42 / 72%);
  border: 1px solid var(--border);
  border-radius: 15px;
}

.confidence-display {
  min-width: 115px;
  padding: 10px 13px;
  text-align: center;
  background: rgb(34 197 94 / 10%);
  border: 1px solid rgb(34 197 94 / 24%);
  border-radius: 12px;
}

.confidence-display span {
  display: block;
  color: var(--muted);
  font-size: 11px;
}

.confidence-display strong {
  display: block;
  margin-top: 3px;
  color: #86efac;
  font-size: 22px;
}

.reason-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
  margin-top: 17px;
}

.reason-grid div {
  padding: 12px;
  background: var(--card);
  border-radius: 10px;
}

.reason-grid span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 11px;
}

.reason-grid strong {
  font-size: 14px;
}

.ai-summary-text {
  margin: 15px 0 0;
  color: #cbd5e1;
  font-size: 13px;
  line-height: 1.6;
}

.decision-frequency {
  margin: 10px 0;
  color: #7dd3fc;
  font-size: clamp(38px, 5vw, 60px);
  font-weight: 800;
  letter-spacing: -0.05em;
}

.decision-frequency small {
  color: var(--muted);
  font-size: 16px;
}

.simple-result-card > p {
  color: #cbd5e1;
  line-height: 1.55;
}

.decision-comparison {
  margin-top: 15px;
}

.decision-comparison div {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  padding: 11px 0;
  border-top: 1px solid rgb(148 163 184 / 14%);
}

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

.decision-comparison strong {
  font-size: 13px;
}

.simulation-disclaimer {
  margin: 15px 0 0 !important;
  padding: 10px;
  color: #fde68a !important;
  background: rgb(234 179 8 / 9%);
  border: 1px solid rgb(234 179 8 / 20%);
  border-radius: 9px;
  font-size: 11px;
}

.advanced-section {
  margin-bottom: 14px;
  background: rgb(17 24 39 / 75%);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.advanced-section summary {
  padding: 15px 18px;
  cursor: pointer;
  color: #cbd5e1;
  font-weight: 700;
}

.advanced-section[open] summary {
  border-bottom: 1px solid var(--border);
}

.advanced-panel {
  margin: 0;
  border: 0;
  border-radius: 0 0 14px 14px;
}

.compact-advanced {
  background: transparent;
}

.advanced-action-row {
  padding: 15px 18px;
}

@media (max-width: 1050px) {
  .simple-kpi-grid,
  .reason-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .simple-explanation-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .simple-operator-view {
    padding: 16px;
  }

  .simple-view-heading,
  .comparison-heading,
  .explanation-heading {
    flex-direction: column;
    align-items: stretch;
  }

  .simple-kpi-grid,
  .strategy-comparison-grid,
  .reason-grid {
    grid-template-columns: 1fr;
  }

  .strategy-card p {
    min-height: auto;
  }

  .confidence-display {
    width: 100%;
  }
}


/* ================================================================
   AI-Kit v4.0.2 — Benefits and write-status panels
   ================================================================ */

.benefits-section,
.write-status-section {
  margin-top: 14px;
  padding: 18px;
  background: rgb(15 23 42 / 72%);
  border: 1px solid var(--border);
  border-radius: 15px;
}

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

.benefits-heading h3 {
  margin: 0;
}

.simulation-label {
  padding: 7px 10px;
  color: #fde68a;
  background: rgb(234 179 8 / 10%);
  border: 1px solid rgb(234 179 8 / 23%);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}

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

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

.benefits-table th,
.benefits-table td {
  padding: 13px 12px;
  text-align: left;
  border-bottom: 1px solid rgb(148 163 184 / 14%);
  white-space: nowrap;
}

.benefits-table th {
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.benefits-table td {
  font-size: 13px;
}

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

.benefits-table tbody tr.active-benefit-row {
  background: rgb(14 116 144 / 14%);
}

.table-note {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.benefit-positive {
  color: #86efac;
}

.benefit-negative {
  color: #fca5a5;
}

.benefits-note,
.write-status-message {
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}

.write-status-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.write-status-grid div {
  padding: 13px;
  background: var(--card);
  border-radius: 10px;
}

.write-status-grid span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 11px;
}

.write-status-grid strong {
  font-size: 14px;
}

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

@media (max-width: 600px) {
  .benefits-heading {
    flex-direction: column;
  }

  .write-status-grid {
    grid-template-columns: 1fr;
  }
}


/* ================================================================
   AI-Kit v4.0.3 — Predictive analysis and operational health
   ================================================================ */

.intelligence-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(350px, 0.55fr);
  gap: 14px;
  margin-top: 14px;
}

.predictive-panel,
.health-panel {
  padding: 19px;
  background: rgb(15 23 42 / 72%);
  border: 1px solid var(--border);
  border-radius: 15px;
}

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

.intelligence-heading h3 {
  margin: 0;
}

.prediction-badge,
.health-good,
.health-watch,
.health-alert {
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.prediction-badge {
  color: #bae6fd;
  background: rgb(14 165 233 / 12%);
  border: 1px solid rgb(14 165 233 / 25%);
}

.health-good {
  color: #bbf7d0;
  background: rgb(34 197 94 / 12%);
  border: 1px solid rgb(34 197 94 / 28%);
}

.health-watch {
  color: #fde68a;
  background: rgb(234 179 8 / 12%);
  border: 1px solid rgb(234 179 8 / 28%);
}

.health-alert {
  color: #fecaca;
  background: rgb(239 68 68 / 12%);
  border: 1px solid rgb(239 68 68 / 28%);
}

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

.prediction-summary-grid > div {
  padding: 13px;
  background: var(--card);
  border-radius: 10px;
}

.prediction-summary-grid span,
.health-score-block span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 11px;
}

.prediction-summary-grid strong {
  display: block;
  font-size: 19px;
}

.prediction-summary-grid small,
.prediction-table small,
.impact-card small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 10px;
}

.prediction-table-wrap {
  margin-top: 13px;
  overflow-x: auto;
}

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

.prediction-table th,
.prediction-table td {
  padding: 12px 10px;
  text-align: left;
  border-bottom: 1px solid rgb(148 163 184 / 14%);
  white-space: nowrap;
}

.prediction-table th {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.prediction-table td {
  font-size: 12px;
}

.prediction-active {
  background: rgb(34 197 94 / 8%);
}

.prediction-saving {
  color: #86efac;
}

.prediction-penalty {
  color: #fca5a5;
}

.rf-impact-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
  margin-top: 13px;
}

.impact-card {
  padding: 13px;
  background: rgb(21 128 61 / 10%);
  border: 1px solid rgb(74 222 128 / 18%);
  border-radius: 10px;
}

.impact-card span {
  display: block;
  margin-bottom: 7px;
  color: #bbf7d0;
  font-size: 11px;
}

.impact-card strong {
  display: block;
  color: #86efac;
  font-size: 20px;
}

.health-score-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.health-score-block > div {
  padding: 13px;
  background: var(--card);
  border-radius: 10px;
}

.health-score-block strong {
  font-size: 22px;
}

.health-progress {
  height: 10px;
  margin: 13px 0;
  overflow: hidden;
  background: #1e293b;
  border-radius: 999px;
}

.health-progress div {
  width: 0%;
  height: 100%;
  background: #22c55e;
  border-radius: inherit;
  transition: width 500ms ease;
}

.health-check-list {
  display: grid;
  gap: 7px;
}

.health-check-list > div {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 9px 10px;
  background: var(--card);
  border-radius: 9px;
  font-size: 11px;
}

.health-check-list strong {
  font-size: 11px;
}

.health-symbol {
  color: #22c55e;
}

.health-check-warning .health-symbol,
.health-check-warning strong {
  color: #facc15;
}

.health-check-bad .health-symbol,
.health-check-bad strong {
  color: #ef4444;
}

.health-advice {
  margin-top: 13px;
  padding: 12px;
  color: #dbeafe;
  background: rgb(14 116 144 / 12%);
  border: 1px solid rgb(56 189 248 / 18%);
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.55;
}

.intelligence-note {
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

@media (max-width: 1150px) {
  .intelligence-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 850px) {
  .prediction-summary-grid,
  .rf-impact-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .intelligence-heading {
    flex-direction: column;
  }

  .prediction-summary-grid,
  .rf-impact-grid,
  .health-score-block {
    grid-template-columns: 1fr;
  }
}


/* ================================================================
   AI-Kit v4.0.4 — Digital Twin experiment pocket
   ================================================================ */

.experiment-pocket {
  margin-top: 14px;
  padding: 18px;
  background: rgb(15 23 42 / 76%);
  border: 1px solid rgb(56 189 248 / 25%);
  border-radius: 15px;
}

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

.experiment-heading h3 {
  margin: 0;
}

.synthetic-only-badge {
  padding: 7px 10px;
  color: #fde68a;
  background: rgb(234 179 8 / 10%);
  border: 1px solid rgb(234 179 8 / 24%);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
}

.experiment-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.7fr) minmax(0, 1.3fr);
  gap: 13px;
}

.experiment-control,
.experiment-impact {
  padding: 16px;
  background: var(--card);
  border-radius: 12px;
}

.experiment-current {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  margin-bottom: 15px;
}

.experiment-current span,
.experiment-impact-grid span,
.experiment-status-grid span,
.model-summary-grid span,
.model-feature-grid span,
.training-metrics-grid span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
}

.experiment-current strong {
  font-size: 20px;
}

.text-action {
  min-height: 34px;
  padding: 7px 10px;
  color: #7dd3fc;
  background: rgb(14 116 144 / 14%);
  border: 1px solid rgb(56 189 248 / 24%);
}

.frequency-input-row {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 11px;
}

.frequency-input-row input {
  width: 150px;
  min-height: 44px;
  padding: 9px 11px;
  color: var(--text);
  background: #0f172a;
  border: 1px solid var(--border);
  border-radius: 9px;
  font-size: 20px;
  font-weight: 700;
}

#experiment-frequency-slider {
  width: 100%;
  margin: 3px 0 14px;
}

.experiment-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.experiment-primary {
  color: #082f49;
  background: #7dd3fc;
}

.experiment-secondary {
  color: #e2e8f0;
  background: #334155;
}

.experiment-message {
  margin-top: 12px;
  padding: 10px;
  color: #cbd5e1;
  background: rgb(15 23 42 / 60%);
  border-radius: 8px;
  font-size: 11px;
  line-height: 1.45;
}

.experiment-impact-title {
  margin-bottom: 12px;
  color: #cbd5e1;
}

.experiment-impact-grid,
.experiment-status-grid,
.model-summary-grid,
.training-metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.experiment-impact-grid > div,
.experiment-status-grid > div,
.model-summary-grid > div,
.training-metrics-grid > div,
.model-feature-grid > div {
  padding: 11px;
  background: rgb(15 23 42 / 72%);
  border-radius: 8px;
}

.experiment-impact-grid strong {
  font-size: 17px;
}

.experiment-status-grid {
  margin-top: 9px;
}

.experiment-status-grid strong {
  font-size: 12px;
}

.model-details-panel {
  margin-top: 13px;
  background: rgb(15 23 42 / 56%);
  border: 1px solid var(--border);
  border-radius: 11px;
}

.model-details-panel summary {
  padding: 13px 15px;
  cursor: pointer;
  color: #bae6fd;
  font-size: 12px;
  font-weight: 700;
}

.model-details-content {
  padding: 15px;
  border-top: 1px solid var(--border);
}

.model-details-content h4 {
  margin: 17px 0 9px;
}

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

.model-scope-note {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

@media (max-width: 950px) {
  .experiment-layout {
    grid-template-columns: 1fr;
  }

  .experiment-impact-grid,
  .experiment-status-grid,
  .model-summary-grid,
  .training-metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 570px) {
  .experiment-heading,
  .experiment-current {
    flex-direction: column;
    align-items: stretch;
  }

  .experiment-impact-grid,
  .experiment-status-grid,
  .model-summary-grid,
  .model-feature-grid,
  .training-metrics-grid {
    grid-template-columns: 1fr;
  }

  .frequency-input-row input {
    width: 100%;
  }
}
