:root {
  --template-placeholder-border: 1px dashed #cbd5e1;
}

.hero-context .badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #1d4ed8;
  background: #dbeafe;
}

.chart-placeholder {
  min-height: 280px;
  border: var(--template-placeholder-border);
  border-radius: 12px;
  background: repeating-linear-gradient(
    45deg,
    rgba(226, 232, 240, 0.4),
    rgba(226, 232, 240, 0.4) 12px,
    rgba(203, 213, 225, 0.4) 12px,
    rgba(203, 213, 225, 0.4) 24px
  );
}

.summary-table-card {
  margin-top: 1.5rem;
}

.summary-table td,
.summary-table th {
  text-align: left;
}

.upload-block {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid #e5e7eb;
}

.upload-block .upload-status {
  margin-top: 0.5rem;
}

.visual-output-settings details[open] {
  border: var(--template-placeholder-border);
  border-radius: 12px;
  padding: 1rem;
}

.effect-constants-card {
  border: var(--template-placeholder-border);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  background: #f8fafc;
}

.effect-constants-card h4 {
  margin: 0 0 0.35rem 0;
}

.range-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
  margin: 0.5rem 0;
}

.range-controls .custom-range {
  display: inline-flex;
  gap: 0.5rem;
}

.effect-nonfocal-levels {
  display: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.35rem 0;
}

.effect-nonfocal-levels label {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.95rem;
}

.effect-nonfocal-levels select {
  min-width: 160px;
}

.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.loading-overlay.active {
  display: flex;
}

.loading-content {
  background: #ffffff;
  padding: 1rem 1.5rem;
  border-radius: 0.75rem;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.25);
  text-align: center;
  max-width: 320px;
}

/* Run button loading state */
#mnlog-run-model.is-running {
  background-color: #b91c1c; /* deep red */
  border-color: #991b1b;
  color: #ffffff;
  cursor: wait;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

#mnlog-run-model .btn-spinner {
  width: 1rem;
  height: 1rem;
  border-radius: 999px;
  border: 2px solid rgba(255, 255, 255, 0.6);
  border-top-color: #ffffff;
  animation: mnlog-spin 0.75s linear infinite;
}

@keyframes mnlog-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}
