/**
 * storage_estimator.css
 *
 * Styles for estimate display and justification modal.
 * All classes prefixed with sse-.
 */

/* ── Estimate display ────────────────────────────────────────── */

.sse-box {
  background: #f0f4f8;
  border: 1px solid #b7ddf2;
  border-radius: 4px;
  padding: 10px 14px;
  margin: 10px 0;
  font-family: "Lucida Grande", "Lucida Sans Unicode", Verdana, Arial, Helvetica, sans-serif;
  font-size: 12px;
  clear: both;
  transition: background 0.3s ease, border-color 0.3s ease;
}

.sse-box.sse-pending {
  background: #f7fafc;
  border-style: dashed;
  border-color: #cbd5e0;
  text-align: center;
  padding: 12px;
}

.sse-box.sse-pending span {
  color: #999;
  font-style: italic;
  font-size: 11px;
}

.sse-box.sse-updated {
  background: #e6fffa;
  border-color: #38b2ac;
}

.sse-stage-label {
  display: inline-block;
  font-size: 10px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 6px;
  border-radius: 2px;
  margin: 0 0 6px 0;
}

.sse-stage-early {
  background: #ebf4fb;
  color: #2b6cb0;
}

.sse-value {
  font-size: 22px;
  font-weight: bold;
  color: #2c5282;
  line-height: 1.2;
}

.sse-range {
  font-size: 11px;
  color: #718096;
  margin: 2px 0 0 0;
}

.sse-summary {
  font-size: 11px;
  color: #4a5568;
  margin: 6px 0 0 0;
  padding: 4px 8px;
  background: #e8edf2;
  border-radius: 3px;
  display: inline-block;
}

.sse-defaults {
  background: #ebf4fb;
  border-left: 3px solid #0b77b7;
  border-radius: 3px;
  padding: 6px 10px;
  margin: 0 0 8px 0;
  font-size: 11px;
  color: #4a5568;
}

/* ── Warnings ────────────────────────────────────────────────── */

.sse-warn {
  padding: 6px 10px;
  border-radius: 3px;
  font-size: 11px;
  margin: 6px 0 0 0;
  line-height: 1.4;
}

.sse-warn-critical {
  background: #f8caca;
  border-left: 3px solid #e53e3e;
  color: #742a2a;
}

.sse-warn-warning {
  background: #fffff0;
  border-left: 3px solid #d69e2e;
  color: #744210;
}

.sse-warn-info {
  background: #ebf8ff;
  border-left: 3px solid #3182ce;
  color: #2a4365;
}

.sse-note {
  margin: 8px 0 0 0;
  padding: 4px 0 0 0;
  border-top: 1px solid #dde4ea;
  font-size: 10px;
  color: #a0aec0;
}

/* ── Modal overlay ───────────────────────────────────────────── */

.sse-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sse-modal {
  background: #fff;
  border-radius: 6px;
  width: 520px;
  max-width: 90vw;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
  font-family: "Lucida Grande", "Lucida Sans Unicode", Verdana, Arial, Helvetica, sans-serif;
  font-size: 12px;
}

.sse-modal-header {
  background: #f62c2c;
  color: #fff;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: bold;
  border-radius: 6px 6px 0 0;
}

.sse-modal-icon {
  font-size: 16px;
}

.sse-modal-body {
  padding: 16px;
}

.sse-modal-body p {
  margin: 0 0 10px 0;
  line-height: 1.5;
  color: #333;
  font-size: 12px;
}

.sse-modal-field {
  margin: 12px 0;
}

.sse-modal-field label {
  display: block;
  font-weight: bold;
  font-size: 12px;
  color: #333;
  margin: 0 0 4px 0;
  width: auto;
  float: none;
  text-align: left;
}

.sse-required {
  color: #c0392b;
  font-weight: normal;
}

.sse-modal-textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid #cbd5e0;
  border-radius: 4px;
  font-family: inherit;
  font-size: 12px;
  resize: vertical;
  box-sizing: border-box;
  display: block;
}

.sse-modal-textarea:focus {
  border-color: #3182ce;
  outline: none;
  box-shadow: 0 0 0 2px rgba(49, 130, 206, 0.15);
}

.sse-modal-cb {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  font-size: 11px;
  color: #4a5568;
  cursor: pointer;
  margin: 12px 0 0 0;
  font-weight: normal;
  width: auto;
  float: none;
}

.sse-modal-cb input[type="checkbox"] {
  width: auto !important;
  float: none !important;
  margin: 2px 0 0 0 !important;
  border: none !important;
  padding: 0 !important;
  flex-shrink: 0;
}

.sse-modal-footer {
  padding: 12px 16px;
  border-top: 1px solid #e2e8f0;
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.sse-modal-btn {
  padding: 8px 16px;
  border: none;
  border-radius: 4px;
  font-family: inherit;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
}

.sse-modal-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.sse-modal-btn-primary {
  background: #2b6cb0;
  color: #fff;
}

.sse-modal-btn-primary:hover:not(:disabled) {
  background: #2c5282;
}

.sse-modal-btn-secondary {
  background: #e2e8f0;
  color: #4a5568;
}

.sse-modal-btn-secondary:hover {
  background: #cbd5e0;
}

.sse-modal-footer-note {
  width: 100%;
  font-size: 10px;
  color: #718096;
  text-align: center;
  margin-bottom: 8px;
  font-style: italic;
}