.exportEngine {
  padding: 4px 0;
}

.exportEngineToggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  background: none;
  border: none;
  padding: 4px 0 12px;
  cursor: pointer;
  font-family: inherit;
}

.exportEngineToggle:hover .exportEngineTitle {
  color: var(--blue, #1f4aff);
}

.exportEngineToggle > span {
  display: flex;
  align-items: center;
  gap: 0;
}

.exportEngineIcon {
  font-size: 20px;
  flex-shrink: 0;
  margin-right: 10px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.exportEngineIcon img {
  width: 32px;
  height: 32px;
}

.exportEngineTitle {
  font-size: 17px;
  font-weight: 800;
  color: var(--ink, #0f172a);
  transition: color 120ms;
}

.exportEngineChevron {
  width: 22px;
  height: 22px;
  color: var(--muted, #64748b);
  transition: transform 200ms;
  flex-shrink: 0;
}

.exportEngineBody {
  padding-top: 4px;
}

.exportEngineSectionLabel {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0 12px;
}

.exportEngineSectionLabel::before,
.exportEngineSectionLabel::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line, #e2e8f0);
}

.exportEngineSectionLabel span {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted, #64748b);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.exportEngineGroup {
  margin-bottom: 12px;
}

.exportEngineGroupDesc {
  font-size: 12px;
  color: var(--muted, #64748b);
  line-height: 1.5;
}

.exportEngineGroupDesc--warning {
  background: rgba(220, 38, 38, 0.06);
  border: 1px solid rgba(220, 38, 38, 0.18);
  border-radius: 8px;
  padding: 8px 11px;
  color: #7f1d1d;
}

.exportEngineBtnRestore {
  background: rgba(220, 38, 38, 0.07);
  color: #b91c1c;
  border: 1px solid rgba(220, 38, 38, 0.25);
}

.exportEngineBtnRestore:hover {
  background: rgba(220, 38, 38, 0.13);
}

/* More specific rule so red restore styling wins over .exportEngineFileLabel */
.exportEngineFileLabel.exportEngineBtnRestore {
  background: rgba(220, 38, 38, 0.07);
  color: #b91c1c;
  border: 1px solid rgba(220, 38, 38, 0.25);
}

.exportEngineFileLabel.exportEngineBtnRestore:hover {
  background: rgba(220, 38, 38, 0.13);
}

/* Tint the restore icon to match the button's red text color #b91c1c */
.exportEngineBtnRestoreIcon {
  filter: brightness(0) saturate(100%) invert(16%) sepia(96%) saturate(1500%) hue-rotate(346deg) brightness(85%);
}

.exportEngineGroupLabel {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted, #64748b);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}

.exportEngineActions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.exportEngineBtn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: opacity 120ms, background 120ms, color 120ms, border-color 120ms;
  white-space: nowrap;
  font-family: inherit;
}

.exportEngineBtn:hover {
  opacity: 0.82;
}

.exportEngineBtn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.exportEngineBtnPrimary {
  background: var(--blue, #1f4aff);
  color: #fff;
}

.exportEngineBtnSecondary {
  background: rgba(31, 74, 255, 0.08);
  color: var(--blue, #1f4aff);
  border: 1px solid rgba(31, 74, 255, 0.2);
}

.exportEngineFileLabel {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  background: rgba(15, 23, 42, 0.05);
  color: var(--ink, #0f172a);
  border: 1px solid var(--line, #e2e8f0);
  transition: background 120ms, color 120ms, border-color 120ms;
}

.exportEngineFileLabel:hover {
  background: rgba(15, 23, 42, 0.09);
}

.exportEngineStatus {
  font-size: 13px;
  padding: 10px 14px;
  border-radius: 9px;
  margin: 10px 0;
  line-height: 1.45;
}

.exportEngineStatus--ok {
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.exportEngineStatus--err {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.exportEngineDesc {
  font-size: 12px;
  color: var(--muted, #64748b);
  background: rgba(255, 180, 0, 0.10);
  border: 1px solid rgba(255, 180, 0, 0.28);
  border-radius: 8px;
  padding: 9px 12px;
  margin-bottom: 4px;
  line-height: 1.5;
}

.exportEngineDesc strong {
  color: var(--ink, #0f172a);
}

@media (max-width: 640px) {
  .exportEngineActions {
    flex-direction: column;
    align-items: stretch;
  }

  .exportEngineBtn,
  .exportEngineFileLabel {
    width: 100%;
    justify-content: center;
  }

  .exportEngineToggle {
    padding-bottom: 10px;
  }

  .exportEngineTitle {
    font-size: 14px;
  }

  .exportEngineGroupLabel,
  .exportEngineSectionLabel span {
    font-size: 10px;
  }
}

/* --- Import success overlay --- */
.exportEngineImportOverlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.exportEngineImportOverlay--visible {
  opacity: 1;
}

.exportEngineImportOverlayCard {
  background: #fff;
  border-radius: 18px;
  padding: 36px 32px 30px;
  max-width: 320px;
  width: 88%;
  text-align: center;
  box-shadow: 0 8px 40px rgba(0,0,0,0.18);
}

.exportEngineImportOverlayIcon {
  font-size: 52px;
  line-height: 1;
  margin-bottom: 16px;
}

.exportEngineImportOverlayMsg {
  font-size: 16px;
  font-weight: 700;
  color: #166534;
  margin-bottom: 10px;
  line-height: 1.4;
}

.exportEngineImportOverlaySub {
  font-size: 13px;
  color: #64748b;
}
/* ─────────────────────────────────────────────
   Drive backup button + subtext
   ───────────────────────────────────────────── */
.exportEngineBtnDrive {
  background: var(--primary, #1f4aff);
  color: #fff;
  border: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.exportEngineBtnDrive:hover {
  background: #1639cc;
}

.exportEngineBtnDrive:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.driveGIcon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  color: #1f4aff;
  font-size: 11px;
  font-weight: 800;
  flex-shrink: 0;
  line-height: 1;
}

.driveGIcon--muted {
  color: #94a3b8;
}

.driveBackupSubtext {
  font-size: 12px;
  color: var(--muted, #64748b);
  margin-top: 6px;
}

.driveBackupStatus {
  font-size: 13px;
  padding: 8px 12px;
  border-radius: 8px;
  margin-top: 8px;
  line-height: 1.4;
}

.driveBackupStatus--progress {
  background: #f0f9ff;
  color: #0369a1;
}

.driveBackupStatus--ok {
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.driveBackupStatus--error {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.driveBackupStatus--info {
  background: #fafafa;
  color: #475569;
}

/* ─────────────────────────────────────────────
   Drive wizard overlay
   ───────────────────────────────────────────── */
.driveWizardOverlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.driveWizardOverlay--visible {
  opacity: 1;
}

.driveWizardCard {
  background: #fff;
  border-radius: 18px;
  padding: 32px 28px 26px;
  max-width: 360px;
  width: 92%;
  box-shadow: 0 8px 40px rgba(0,0,0,0.18);
}

.driveWizardStep {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted, #64748b);
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: 10px;
}

.driveWizardTitle {
  font-size: 19px;
  font-weight: 800;
  color: var(--ink, #0f172a);
  margin-bottom: 14px;
  line-height: 1.3;
}

.driveWizardBody {
  font-size: 14px;
  color: var(--ink, #0f172a);
  line-height: 1.6;
  margin-bottom: 16px;
}

.driveWizardBody p { margin: 0 0 10px; }
.driveWizardBody p:last-child { margin-bottom: 0; }

.driveWizardBody ul {
  margin: 8px 0 10px 18px;
  padding: 0;
}

.driveWizardBody li {
  margin-bottom: 4px;
}

.driveWizardSmall {
  font-size: 12px;
  color: var(--muted, #64748b);
}

.driveWizardWhy {
  margin-bottom: 16px;
}

.driveWizardWhyToggle {
  background: none;
  border: none;
  padding: 0;
  font-size: 12px;
  color: var(--primary, #1f4aff);
  cursor: pointer;
  text-align: left;
}

.driveWizardWhyBody {
  font-size: 12px;
  color: var(--muted, #64748b);
  margin-top: 8px;
  line-height: 1.5;
  padding: 10px 12px;
  background: #f8fafc;
  border-radius: 8px;
}

.driveWizardActions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 20px;
}

.driveWizardLink {
  background: none;
  border: none;
  padding: 4px 0;
  font-size: 13px;
  color: var(--muted, #64748b);
  cursor: pointer;
  text-align: center;
}

.driveWizardLink:hover {
  color: var(--ink, #0f172a);
}

.driveWizardSuccessIcon {
  font-size: 48px;
  text-align: center;
  margin-bottom: 16px;
  color: #16a34a;
  font-weight: 800;
}

.driveWizardErr {
  font-size: 13px;
  color: #991b1b;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 8px;
  padding: 8px 12px;
  margin-bottom: 12px;
}

/* ─────────────────────────────────────────────
   Phase 4 — Duplicate shared-container choice modal
   ───────────────────────────────────────────── */
.exportEngineDupCard {
  max-width: 340px;
  text-align: left;
}

.exportEngineDupIcon {
  font-size: 36px;
  line-height: 1;
  margin-bottom: 12px;
}

.exportEngineDupTitle {
  font-size: 15px;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 10px;
  line-height: 1.4;
}

.exportEngineDupList {
  margin: 0 0 14px 0;
  padding-left: 20px;
  font-size: 13px;
  color: #475569;
  line-height: 1.6;
}

.exportEngineDupQuestion {
  font-size: 13px;
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 12px;
}

.exportEngineDupButtons {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.exportEngineDupBtn {
  width: 100%;
  padding: 11px 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  text-align: center;
  transition: opacity 0.15s;
}

.exportEngineDupBtn:active {
  opacity: 0.75;
}

.exportEngineDupBtn--new {
  background: var(--primary, #1f4aff);
  color: #fff;
}

.exportEngineDupBtn--cancel {
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #e2e8f0;
}

/* ── Backup panel accordions (Save / Import / Restore) ── */
.eeAccordionHeader {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: none;
  border: none;
  border-top: 1px solid var(--line, rgba(15,23,42,.12));
  padding: 11px 0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted, #5b667a);
  cursor: pointer;
  text-align: left;
}
.eeAccordionHeader:first-of-type { border-top: none; margin-top: 8px; }
.eeAccordionHeader:hover { color: var(--ink, #0f172a); }
.eeAccordionHeader--warning { color: #b45309; }
.eeAccordionHeader--warning:hover { color: #92400e; }
.eeAccordionChevron {
  flex-shrink: 0;
  transition: transform 0.2s ease;
  opacity: 0.5;
}
.eeAccordionBody { padding-bottom: 4px; }

/* ── Spacing between Save button groups ── */
.exportEngineGroup--spaced { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line, rgba(15,23,42,.08)); }
