.review-ack-wrapper { max-width: 720px; margin: 0 auto 10px; padding: 10px 14px; border: 1px solid #d9deea; border-radius: 12px; background: #fff; color: #263149; font-size: 12px; }
.review-ack-wrapper .check-field { align-items: flex-start; }
.review-ack-error { margin: 5px 0 0 22px; color: #b42318; font-size: 12px; }
.review-ack-error[hidden] { display: none !important; }
.span-3 {
  grid-column: 1 / -1;
}

.invoice-legal-mention,
.invoice-rectification {
  margin-top: 16px;
  padding: 10px 12px;
  border-left: 3px solid var(--paper-accent);
  background: #f6f7fa;
  color: #38445a;
  font-size: 9px;
  line-height: 1.55;
  overflow-wrap: anywhere;
  break-inside: avoid;
}

.invoice-rectification {
  margin-top: 8px;
  background: #fff;
  border: 0;
  padding: 0;
}

.invoice-rectification strong {
  display: block;
  margin-bottom: 3px;
}

.operation-advice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid #f0d8a7;
  border-radius: 9px;
  background: #fff9eb;
  color: #76561b;
  font-size: 11px;
  line-height: 1.5;
}

.operation-advice[hidden] {
  display: none !important;
}

.sensitive-operation-warning {
  grid-column: 1 / -1;
  padding: 13px 15px;
  border: 1px solid #e9b7a4;
  border-left: 4px solid #c85b3d;
  border-radius: 10px;
  background: #fff4ef;
  color: #753523;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.55;
}

.sensitive-operation-warning[hidden] {
  display: none !important;
}

.invoice-territory-tax-note {
  margin-top: 12px;
  color: #59657a;
  font-size: 9px;
  text-align: right;
}

.igic-rate-advice {
  margin-top: 0;
  color: #76561b;
  font-size: 9px;
  line-height: 1.4;
}

.preflight-actions .button:disabled {
  opacity: .48;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.invoice-legal-mention .invoice-legal-translation {
  display: block;
  margin-top: 3px;
  color: #59657a;
  font-style: italic;
}

.preflight-panel {
  position: fixed;
  z-index: 80;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(20, 29, 48, .5);
}

.preflight-panel[hidden] {
  display: none !important;
}

.preflight-card {
  width: min(100%, 560px);
  max-height: min(82vh, 720px);
  overflow: auto;
  padding: 25px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 24px 70px rgba(15, 24, 43, .24);
}

.preflight-card h2 {
  margin-bottom: 8px;
  font-size: 20px;
}

.preflight-card p,
.preflight-card li {
  color: var(--muted);
  font-size: 13px;
}

.preflight-card ul {
  display: grid;
  gap: 8px;
  padding-left: 20px;
}

.preflight-actions {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

@media print {
  @page {
    size: A4;
    margin: 12mm;
  }

  html,
  body {
    width: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    background: #fff !important;
  }

  body > .topbar,
  body > .site-footer,
  body > #mobile-preview-button {
    display: none !important;
  }

  body > #preflight-panel {
    display: none !important;
  }

  body > main {
    display: block !important;
    width: auto !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  body > main > .hero,
  body > main > .below-editor,
  body > main > .seo-content,
  body > main > .niche-links,
  body .workspace > .editor-column {
    display: none !important;
  }

  body .workspace {
    display: block !important;
    width: auto !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  body .workspace > .preview-column {
    display: block !important;
    position: static !important;
    inset: auto !important;
    width: auto !important;
    height: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    background: #fff !important;
    visibility: visible !important;
  }

  body * {
    visibility: hidden !important;
  }

  body .workspace > .preview-column,
  body .workspace > .preview-column * {
    visibility: visible !important;
  }

  .pdf-footer-settings,
  .preview-toolbar,
  .preview-footnote,
  .review-ack-wrapper {
    display: none !important;
  }

  .invoice-paper {
    position: relative !important;
    width: auto !important;
    height: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: #fff !important;
    color: #20283a !important;
    font-size: 9pt !important;
  }

  .invoice-paper.template-moderna {
    border-top: 4mm solid var(--paper-accent) !important;
    padding-top: 6mm !important;
  }

  .invoice-table thead {
    display: table-header-group;
  }

  .invoice-table tr,
  .invoice-total-legal,
  .invoice-summary,
  .invoice-notes,
  .invoice-legal-mention,
  .invoice-rectification,
  .invoice-footer-note {
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .invoice-total-legal {
    display: block !important;
  }

  .invoice-foot {
    position: static !important;
    margin-top: 12mm;
  }
}
