:root {
  --ifos-white: var(--white, #fff);
  --ifos-surface: var(--ifos-white);
  --ifos-radius-xs: 2px;
  --ifos-radius-sm: 4px;
  --ifos-radius-md: 6px;
  --ifos-radius-lg: 8px;
  --ifos-radius-xl: 12px;
  --ifos-radius-pill: 999px;
  --ifos-yellow: #f5c518;
  --ifos-yellow-soft: #fffbea;
  --ifos-yellow-hover: rgba(245, 197, 24, .9);
  --ifos-yellow-focus: rgba(245, 197, 24, .22);
  --ifos-navy: #1c2b4a;
  --ifos-text-dark: #1b2b3c;
  --ifos-heading-dark: #101828;
  --ifos-form-label: #344054;
  --ifos-placeholder: #98a2b3;
  --ifos-button-muted: #6a7282;
  --ifos-button-border: #e5e7eb;
  --ifos-button-border-hover: #d1d5db;
  --ifos-button-surface-hover: #f9fafb;
  --ifos-toolbar-label: #667085;
  --ifos-destructive: #dc2626;
  --ifos-destructive-hover: #b91c1c;
  --ifos-destructive-soft: #fef2f2;
  --runtime-border: #e5e7eb;
  --runtime-muted: #6a7282;
  --runtime-surface: #f8fafc;
  --deployment-shift-day: #be185d;
  --deployment-shift-middle: #0f766e;
  --deployment-shift-night: #4338ca;
  --bs-primary: var(--primary);
  --bs-secondary: var(--secondary);
  --bs-success: var(--success);
  --bs-info: var(--info);
  --bs-danger: var(--danger);
  --bs-warning: var(--warning);
  --bs-orange: var(--orange);
  --bs-dark: var(--dark);
  --bs-primary-rgb: 33, 150, 243;
  --bs-warning-rgb: 245, 134, 70;
  --bs-body-bg: var(--white);
  --bs-body-color: var(--dark);
  --bs-emphasis-color: var(--dark);
  --bs-secondary-color: var(--secondary);
  --bs-border-color: color-mix(in srgb, var(--secondary) 28%, var(--white));
  --bs-tertiary-bg: color-mix(in srgb, var(--light) 72%, var(--white));
  --bs-secondary-bg-subtle: color-mix(in srgb, var(--secondary) 10%, var(--white));
  --bs-secondary-border-subtle: color-mix(in srgb, var(--secondary) 28%, var(--white));
  --bs-primary-bg-subtle: color-mix(in srgb, var(--primary) 12%, var(--white));
  --bs-primary-border-subtle: color-mix(in srgb, var(--primary) 32%, var(--white));
  --bs-success-bg-subtle: color-mix(in srgb, var(--success) 14%, var(--white));
  --bs-info-bg-subtle: color-mix(in srgb, var(--info) 12%, var(--white));
  --bs-info-border-subtle: color-mix(in srgb, var(--info) 32%, var(--white));
  --bs-danger-bg-subtle: color-mix(in srgb, var(--danger) 12%, var(--white));
  --bs-danger-border-subtle: color-mix(in srgb, var(--danger) 32%, var(--white));
  --bs-warning-bg-subtle: color-mix(in srgb, var(--warning) 16%, var(--white));
  --bs-warning-border-subtle: color-mix(in srgb, var(--warning) 38%, var(--white));
  --bs-warning-text-emphasis: color-mix(in srgb, var(--warning) 55%, var(--dark));
}

/* Loader Styles */
.datatable-loading-row td {
  height: 150px;
  vertical-align: middle !important;
}

.datatable-loader {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 12px !important;
  font-size: 14px !important;
  color: #666 !important;
  background: rgba(255, 255, 255, 0.95) !important;
  padding: 24px 24px !important;
  border-radius: 108px !important;
  border: 1px solid #ddd !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
}

.spinner {
  font-size: 18px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}
/* Loader Styles */

/* SectionLoader overlay */
.section-loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  background: rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(2px);
}

/* ─────────────────────────────────────────────────────────────────────
   Report-level image uploader (create forms) + comments/images cards
   & gallery (view pages). Shared by DCA, Process Confirmation, etc.
   ───────────────────────────────────────────────────────────────────── */

/* Multi-image uploader (create forms) */
.report-image-upload-shell {
  border: 2px dashed #c7b78f;
  border-radius: 10px;
  background: #fffaf0;
  padding: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.report-image-upload-shell:hover,
.report-image-upload-shell:focus,
.report-image-upload-shell.is-dragover {
  border-color: #e97451;
  background: #fdeee6;
  outline: none;
}

.report-image-upload-head {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.report-image-choose-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 8px;
  cursor: pointer;
  margin: 0;
}

.report-image-hint {
  color: #8a8577;
  font-size: 0.85rem;
}

.report-image-count {
  margin-left: auto;
  background: #e97451;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  min-width: 26px;
  height: 26px;
  padding: 0 9px;
  border-radius: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.report-image-hidden {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
}

.report-image-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.report-image-thumb {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #e6d9bf;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.report-image-thumb img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  display: block;
}

.report-image-thumb__meta {
  padding: 6px 8px;
  font-size: 0.72rem;
  color: #7a756a;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.report-image-thumb__remove {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 26px;
  height: 26px;
  border: none;
  border-radius: 50%;
  background: rgba(233, 116, 81, 0.92);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  line-height: 1;
  transition: background 0.15s ease;
}

.report-image-thumb__remove:hover {
  background: #d9502a;
}

/* Comments & images cards (view pages) */
.report-info-card {
  background: #ffffff;
  border: 1px solid #efe2c8;
  border-radius: 14px;
  padding: 20px 22px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.report-info-card__header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.report-info-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: #f5e7cf;
  color: #b5761f;
  flex-shrink: 0;
}

.report-info-card__title {
  margin: 0;
  font-weight: 700;
  color: #2d2b28;
  font-size: 1.05rem;
}

.report-info-card__count {
  margin-left: auto;
  background: #e97451;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  min-width: 24px;
  height: 24px;
  padding: 0 8px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.report-info-card__comment {
  margin: 0;
  color: #4a4740;
  line-height: 1.6;
  white-space: pre-line;
  background: #fffaf0;
  border-left: 3px solid #e9c169;
  padding: 12px 16px;
  border-radius: 8px;
}

.report-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 14px;
}

.report-gallery__item {
  position: relative;
  display: block;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  border: 1px solid #e6d9bf;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

.report-gallery__item:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.16);
}

.report-gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.report-gallery__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(45, 43, 40, 0.45);
  color: #fff;
  opacity: 0;
  transition: opacity 0.18s ease;
}

.report-gallery__item:hover .report-gallery__overlay {
  opacity: 1;
}

/* Soft-delete visual indicator � shared across all DataTables that show Areas/Machines */
.deleted-name {
  color: #dc3545;
  font-weight: 600;
}
