/* ── Sticky navbar ───────────────────────────────────── */
.cnt-navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 100;
  background: #fff;
  border-bottom: 1px solid #e5e7eb;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}

.cnt-navbar-logo {
  height: 32px;
  width: auto;
  display: block;
}

.cnt-lang-select {
  margin-left: auto;
  font-family: inherit;
  font-size: 14px;
  color: #00243D;
  background: #fff;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  padding: 5px 28px 5px 10px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2300243D' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 9px center;
  transition: border-color 0.15s, box-shadow 0.15s;
  min-width: 90px;
}
.cnt-lang-select:focus {
  outline: none;
  border-color: #0073AB;
  box-shadow: 0 0 0 3px rgba(0,115,171,0.13);
}
.cnt-lang-select option {
  font-size: 14px;
  font-family: inherit;
}

@media (min-width: 768px) {
  .cnt-navbar { padding: 12px 24px; }
  .cnt-navbar-logo { height: 36px; }
}

*, *::before, *::after { box-sizing: border-box; }

/* ── Footer ─────────────────────────────────────────── */
.cnt-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 4px 12px;
  padding: 8px 16px;
  font-size: 13px;
  color: #6b7280;
  background: #fff;
  border-top: 1px solid #e5e7eb;
  z-index: 90;
}
.cnt-footer span {
  font-size: 13px;
  line-height: 1;
  vertical-align: middle;
}
.cnt-footer-copy {
  font-size: 17px;
  vertical-align: middle;
  line-height: 1;
}
.cnt-footer-links {
  display: flex;
  align-items: center;
  gap: 12px;
}
/* Cookie preferences reopens the consent banner rather than navigating, so it
   is a button; these rules give it the same appearance as the policy link. */
.cnt-footer-links a,
.cnt-link-btn {
  font-family: inherit;
  font-size: 13px;
  line-height: 1;
  color: inherit;
  text-decoration: underline;
  cursor: pointer;
}
.cnt-link-btn {
  padding: 0;
  border: 0;
  background: none;
}
.cnt-footer-links a:hover,
.cnt-link-btn:hover {
  color: #111827;
}
.cnt-footer-links a:focus-visible,
.cnt-link-btn:focus-visible {
  outline: 2px solid #42b0d5;
  outline-offset: 2px;
}

@media (min-width: 768px) {
  .cnt-footer { padding: 8px 24px; }
}

body {
  font-family: 'Maersk Text', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: #f5f7fa;
  margin: 0;
  padding: 68px 0 48px; /* bottom clears fixed footer */
  color: #141414;
  -webkit-text-size-adjust: 100%;
}

/* mobile: 100%, flush edges */
.cnt-wrapper {
  width: 100%;
  margin: 0 auto;
  background: #fff;
  border-radius: 0;
  padding:0px 8px 10px 8px;
  box-shadow: none;
}

/* tablet (≥768px): 100%, still flush */
@media (min-width: 768px) {
  body { padding: 76px 0 48px; }
  .cnt-wrapper { width: 100%; padding: 10px 10px; border-radius: 0; box-shadow: none; }
}

/* desktop (≥1024px): 80%, rounded card */
@media (min-width: 1024px) {
  body { padding: 80px 24px 48px; }
  .cnt-wrapper {
    width: 80%;
    padding: 32px;
    border-radius: 10px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08), 0 4px 16px rgba(0,0,0,0.05);
  }
}

/* ── Instructions panel ─────────────────────────────── */
.cnt-instructions {
  padding: 12px 4px 4px;
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 4px;
}

@media (min-width: 1024px) {
  .cnt-instructions {
    padding: 0 0 20px;
    margin-bottom: 8px;
  }
}

.cnt-instr-section {
  margin-bottom: 14px;
}
.cnt-instr-section:last-child {
  margin-bottom: 0;
}

.cnt-instr-region {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: #00243D;
  margin-bottom: 4px;
}

.cnt-instr-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.cnt-instr-list li {
  font-size: 13px;
  color: #374151;
  line-height: 1.6;
}

.cnt-instr-list li::before {
  content: '* ';
  color: #00243D;
  font-weight: 600;
}

.cnt-header {padding-left:4px;padding-top:12px; }

@media (min-width: 1024px) {
  .cnt-header { padding: 0; }
}
.cnt-header h2 {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 400;
  color: #00243D;
}
.cnt-header p {
  margin: 0;
  font-size: 14px;
  color: #6b7280;
  line-height: 1.55;
}
.cnt-header code {
  background: #e8f4fb;
  color: #005A87;
  padding: 2px 6px;
  border-radius: 3px;
  font-family: 'Roboto Mono', 'Courier New', monospace;
  font-size: 13px;
}

/* ── Tag box ─────────────────────────────────────────── */
.cnt-box {
  min-height: 100px;
  max-height: 50vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  border: 2px solid #d1d5db;
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-content: flex-start;
  cursor: text;
  background: #fff;
  transition: border-color 0.15s, box-shadow 0.15s;
  position: relative;
}
.cnt-box:focus-within {
  border-color: #0073AB;
  box-shadow: 0 0 0 3px rgba(0,115,171,0.13);
}

/* ── Tags ────────────────────────────────────────────── */
.cnt-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #E6F4FA;
  border: 1px solid #9DD5EE;
  border-radius: 6px;
  padding: 6px 8px 6px 12px;
  font-size: 14px;
  font-family: 'Roboto Mono', 'Courier New', monospace;
  font-weight: 600;
  color: #004A72;
  white-space: nowrap;
  user-select: none;
  animation: tagIn 0.14s ease;
  flex-shrink: 0;
  min-height: 40px;
}
@keyframes tagIn {
  from { opacity: 0; transform: scale(0.85); }
  to   { opacity: 1; transform: scale(1); }
}
.cnt-tag-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: transparent;
  border: none;
  cursor: pointer;
  color: #005A87;
  font-size: 16px;
  line-height: 1;
  padding: 0;
  opacity: 0.6;
  transition: opacity 0.12s, background 0.12s;
  flex-shrink: 0;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.cnt-tag-remove:hover,
.cnt-tag-remove:active { opacity: 1; background: rgba(0,90,135,0.15); }

/* ── Editable cursor area ────────────────────────────── */
.cnt-editable {
  outline: none;
  flex: 1;
  min-width: 160px;
  font-size: 16px; /* prevents iOS auto-zoom */
  font-family: inherit;
  color: #141414;
  background: transparent;
  padding: 0 2px;
  align-self: center;
  word-break: break-all;
  white-space: pre-wrap;
  min-height: 40px;
  line-height: 40px;
  caret-color: #0073AB;
  touch-action: manipulation;
  text-transform: uppercase;
}
.cnt-editable:empty::before {
  content: attr(data-placeholder);
  color: #adb5bd;
  pointer-events: none;
  font-size: 12px;
  text-transform: capitalize;
}

@media (max-width: 640px) {
  .cnt-editable {
    flex-basis: 100%;
    min-width: 0;
    align-self: stretch;
    line-height: 1.4;
    word-break: normal;
    overflow-wrap: anywhere;
  }
}

/* ── Toolbar ─────────────────────────────────────────── */
.cnt-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 12px;
}

@media (min-width: 1024px) {
  .cnt-toolbar { padding: 0; }
}

.cnt-count { font-size: 15px; color: #6b7280; flex-shrink: 0; }
.cnt-count strong { color: #0073AB; font-weight: 700; }

.cnt-actions { display: flex; gap: 10px; flex: 1; justify-content: flex-end; }

.cnt-print-header,
.cnt-print-footer {
  display: none;
}
.cnt-btn {
  font-size: 15px;
  padding: 10px 18px;
  min-height: 44px;
  border-radius: 8px;
  border: 1.5px solid #d1d5db;
  background: #fff;
  cursor: pointer;
  color: #374151;
  font-family: inherit;
  transition: background 0.1s, border-color 0.1s;
  font-weight: 600;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

#downloadPdfBtn[hidden] {
  display: none !important;
}
.cnt-btn:active { opacity: 0.8; }
.cnt-btn:focus-visible {
  outline: 3px solid #0073AB;
  outline-offset: 3px;
}
.cnt-btn-primary {
  background: #0073AB;
  border-color: #0073AB;
  color: #fff;
}
.cnt-btn-primary:focus-visible {
  outline: 3px solid #fff;
  outline-offset: -5px;
  box-shadow: 0 0 0 4px #0073AB;
}
.cnt-btn-primary:active { background: #005A87; }
.cnt-btn-danger { color: #dc2626; border-color: #fca5a5; }
.cnt-btn-danger:active { background: #fef2f2; }
.cnt-btn-secondary {
  background: #fff;
  border-color: #0073AB;
  color: #0073AB;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.cnt-btn-secondary:hover { background: #e8f4fb; }
.cnt-btn-secondary:active { background: #d0eaf6; }
.cnt-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: auto;
}

/* ── Main location website button wrapper ────────────── */
.cnt-main-location-wrap {
  display: flex;
  justify-content: center;
  margin-top: 20px;
  margin-bottom: 28px;
}
.cnt-main-location-wrap[hidden] { display: none; }
.cnt-main-location-btn {
  font-size: 15px;
  padding: 10px 24px;
}

/* ── Results section ─────────────────────────────────── */
.cnt-results {
  width: 100%;
  margin: 0 auto;
  margin-top: 28px;
  padding:10px;
}

@media (min-width: 768px) {
  .cnt-results { width: 100%; }
}

@media (min-width: 1024px) {
  .cnt-results { width: 80%; }
}

.cnt-results-header {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 12px;
}
.cnt-results-header h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  color: #00243D;
}
.cnt-results-count {
  font-size: 13px;
  color: #6b7280;
}
/* Count of what the printout carries; swapped in for the screen count in @media print. */
.cnt-print-results-count {
  display: none;
}

/* ── Table ───────────────────────────────────────────── */
.cnt-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1.5px solid #e5e7eb;
  border-radius: 8px;
}

.cnt-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.cnt-table thead {
  background: #f0f7fb;
}

.cnt-table th {
  text-align: left;
  padding: 11px 14px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #00243D;
  border-bottom: 2px solid #d1d5db;
  white-space: nowrap;
}

.cnt-table td {
  padding: 12px 14px;
  vertical-align: top;
  color: #374151;
  border-bottom: 1px solid #f3f4f6;
  line-height: 1.5;
}

.cnt-table tbody tr:last-child td {
  border-bottom: none;
}

/* Zebra stripes — desktop table */
.cnt-table tbody tr:nth-child(odd) td  { background: #ffffff; }
.cnt-table tbody tr:nth-child(even) td { background: #f3f4f6; }

.cnt-table tbody tr:hover td {
  filter: brightness(0.96);
}

/* Container number badge inside the table */
.cnt-table-tag {
  display: inline-block;
  background: #E6F4FA;
  border: 1px solid #9DD5EE;
  border-radius: 4px;
  padding: 2px 8px;
  font-family: 'Roboto Mono', 'Courier New', monospace;
  font-size: 13px;
  font-weight: 600;
  color: #004A72;
  white-space: nowrap;
}

.cnt-table-loading,
.cnt-table-error {
  text-align: center;
  padding: 28px 14px;
  color: #6b7280;
  font-size: 14px;
}
.cnt-table-error { color: #dc2626; }
/* ── Error list (below table) ────────────────────── */
.cnt-error-list {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.cnt-error-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 6px;
  font-size: 14px;
}
.cnt-error-msg {
  color: #dc2626;
}

.cnt-coords {
  margin-top: 4px;
  font-size: 12px;
  color: #6b7280;
  white-space: nowrap;
}
/* ── Contact cell ────────────────────────────────────── */
.cnt-contact-wrap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* Call button — mobile/tablet only */
.cnt-call-btn {
  display: none;
}

@media (max-width: 1023px) {
  .cnt-call-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #0073AB;
    color: #fff;
    text-decoration: none;
    font-size: 18px;
    flex-shrink: 0;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    transition: background 0.12s;
  }
  .cnt-call-btn:active { background: #005A87; }
}

/* ── Card layout on small screens ────────────────────── */
@media (max-width: 640px) {
  .cnt-table thead { display: none; }

  .cnt-table,
  .cnt-table tbody,
  .cnt-table tr,
  .cnt-table td {
    display: block;
    width: 100%;
  }

  .cnt-table tr {
    border-bottom: 2px solid #e5e7eb;
    padding: 10px 0;
  }

  /* Zebra stripes — mobile/tablet cards */
  .cnt-table tbody tr:nth-child(odd)  { background: #ffffff; }
  .cnt-table tbody tr:nth-child(even) { background: #f3f4f6; }

  .cnt-table td {
    padding: 6px 14px;
    border-bottom: none;
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .cnt-table td::before {
    content: attr(data-label);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #9ca3af;
  }

  .cnt-table-loading,
  .cnt-table-error {
    display: block;
  }

  /* Radio cell (feedback sections only): aligned left, inline with the facility card */
  .cnt-container-section .cnt-facility-row .cnt-radio-cell {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
    text-align: left;
    padding: 10px 14px 0;
  }
  .cnt-container-section .cnt-facility-row .cnt-radio-cell::before { content: none; }
  .cnt-container-section .cnt-facility-row .cnt-radio-cell input[type="radio"] {
    display: block;
    margin: 0;
  }
}

/* ── Container section card ──────────────────────────── */
/* Spacing between the flat no-location table and the section cards */
.cnt-table-wrap:has(.cnt-flat-table) {
  margin-bottom: 28px;
}

.cnt-container-section {
  margin-bottom: 20px;
  border: 1.5px solid #e5e7eb;
  border-radius: 8px;
  overflow: hidden;
}
.cnt-container-section .cnt-table-wrap {
  border: none;
  border-radius: 0;
}

/* ── Group header ────────────────────────────────────── */
.cnt-group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #f0f7fb;
  border-bottom: 1.5px solid #e5e7eb;
  flex-wrap: wrap;
  gap: 8px;
}
.cnt-group-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.cnt-group-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #6b7280;
}
.cnt-return-options {
  font-size: 13px;
  color: #6b7280;
  white-space: nowrap;
  margin-left: auto;
}

/* ── Collapsible sections (more than 7 containers) ──── */
.cnt-collapse-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 12px;
}
.cnt-toggle-all-btn {
  font-size: 14px;
  padding: 6px 14px;
  min-height: 36px;
}

.cnt-collapsible .cnt-group-header {
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.cnt-collapsible .cnt-group-header:hover { background: #e3f0f8; }
.cnt-collapsible .cnt-group-header:focus-visible {
  outline: 3px solid #0073AB;
  outline-offset: -3px;
}

.cnt-collapse-icon {
  width: 12px;
  height: 8px;
  flex-shrink: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2300243D' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  transform: rotate(180deg);
  transition: transform 0.15s;
}
.cnt-collapsed .cnt-collapse-icon { transform: rotate(0deg); }

.cnt-collapsed .cnt-section-body { display: none; }
.cnt-collapsed .cnt-group-header { border-bottom: none; }

/* ── Equipment type badge ────────────────────────────── */
.cnt-equipment-type {
  display: inline-block;
  background: #e5e7eb;
  border-radius: 4px;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 700;
  color: #374151;
  font-family: 'Roboto Mono', 'Courier New', monospace;
  white-space: nowrap;
}

/* ── Radio column ────────────────────────────────────── */
.cnt-radio-th {
  width: 44px;
  min-width: 44px;
}
.cnt-radio-cell {
  width: 44px;
  min-width: 44px;
  text-align: center;
  vertical-align: middle;
  padding: 12px 8px;
}
.cnt-radio-cell input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: #0073AB;
  cursor: pointer;
  display: block;
  margin: 0 auto;
}

/* ── Selected row highlight ──────────────────────────── */
.cnt-facility-row.cnt-row-selected td {
  background: #e8f4fb !important;
}

/* ── Confirmed badge ─────────────────────────────────── */
.cnt-confirmed-badge {
  display: inline-block;
  background: #d1fae5;
  color: #065f46;
  border: 1px solid #6ee7b7;
  border-radius: 4px;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  margin-top: 4px;
}

/* Printed only (a confirmed location that is no longer offered is still the one on record). */
.cnt-print-only {
  display: none;
}

/* ── Confirmed location the user has moved away from ── */
.cnt-prev-confirmed-badge {
  display: block;
  width: fit-content;
  margin-top: 4px;
  padding: 2px 8px;
  background: #f3f4f6;
  color: #4b5563;
  border: 1px dashed #9ca3af;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
}

/* ── Previously confirmed location no longer offered ─── */
.cnt-prev-confirmation {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 0;
  padding: 10px 14px;
  background: #fffbeb;
  border-bottom: 1px solid #fde68a;
  border-inline-start: 4px solid #f59e0b;
  color: #78350f;
  font-size: 14px;
  overflow-wrap: anywhere;
}
.cnt-prev-confirmation span {
  font-size: 13px;
}

/* ── No-location placeholder ─────────────────────────── */
.cnt-no-location {
  padding: 20px 16px;
  font-size: 14px;
  color: #6b7280;
  text-align: center;
}

/* ── Confirm bar (in-flow, below results) ────────────── */
.cnt-confirm-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 16px 0;
  margin-top: 16px;
  border-top: 2px solid #e5e7eb;
}
.cnt-confirm-bar[hidden] { display: none; }
.cnt-confirm-count {
  font-size: 14px;
  color: #374151;
}
.cnt-confirm-count:empty { display: none; }
/* Print sits beside Confirm Selection */
.cnt-confirm-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-left: auto;
}

/* ── Mobile: scroll within section, sticky header & confirm bar ── */
@media (max-width: 640px) {
  /* Each container's return locations scroll inside their own card */
  .cnt-container-section .cnt-table-wrap {
    max-height: 55vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Container number + type header sticks to the top of the scroll area */
  .cnt-group-header {
    position: sticky;
    top: 0;
    z-index: 2;
    align-items: flex-start;
  }

  /* Label, container number and type badge stay together on one line */
  .cnt-group-header-left {
    align-items: center;
    row-gap: 6px;
    column-gap: 8px;
    width: 100%;
  }
  .cnt-container-section .cnt-return-options {
    margin-left: 0;
    margin-top: 4px;
  }

  /* Confirm bar pinned above the footer; body scrolls behind it */
  .cnt-confirm-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 32px; /* clears the fixed footer */
    margin-top: 0;
    padding: 12px 16px;
    background: #fff;
    border-top: 1.5px solid #e5e7eb;
    box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.08);
    z-index: 95;
  }
  /* Count on its own line, Print + Confirm share the row below it */
  .cnt-confirm-bar .cnt-confirm-count { flex: 1 1 100%; }
  .cnt-confirm-bar .cnt-confirm-actions {
    flex: 1 1 100%;
    margin-left: 0;
    gap: 8px;
  }
  .cnt-confirm-bar .cnt-btn { flex: 1; }

  /* Extra bottom space so the last card isn't hidden behind the fixed bar/footer */
  .cnt-results:has(.cnt-confirm-bar:not([hidden])) {
    padding-bottom: 168px;
  }
}

/* ── Summary modal ───────────────────────────────────── */
.cnt-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.cnt-modal-overlay[hidden] { display: none; }
.cnt-modal {
  background: #fff;
  border-radius: 10px;
  padding: 28px;
  width: 100%;
  max-width: 520px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.18);
  max-height: 90vh;
  overflow-y: auto;
}
.cnt-modal h3 {
  margin: 0 0 6px;
  font-size: 18px;
  font-weight: 700;
  color: #00243D;
}
.cnt-modal-subtitle {
  margin: 0 0 20px;
  font-size: 14px;
  color: #6b7280;
}
.cnt-modal-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}
.cnt-modal-row {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 14px;
  background: #f9fafb;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}
.cnt-modal-container {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
  min-width: 90px;
}
.cnt-modal-facility {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 14px;
  color: #374151;
  flex: 1;
}
.cnt-modal-facility strong {
  color: #00243D;
  font-size: 15px;
}
.cnt-modal-hours {
  color: #0073AB;
  font-size: 13px;
  font-weight: 600;
}
.cnt-modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

@media print {
  /* ─────────────────────────────────────────────
    A4 PAGE
     ───────────────────────────────────────────── */
  @page {
    size: A4 portrait;
    margin: 2mm 6mm;
  }

  html,
  body {
    margin: 0 !important;
    padding: 0 !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    background: #fff !important;
    color: #000 !important;
    font-size: 10pt;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
  }

  body,
  body * {
    font-family: "Maersk Text", sans-serif !important;
    font-weight: 400 !important;
    font-synthesis: none !important;
  }

  b,
  strong,
  .cnt-print-title,
  .cnt-results-header h3,
  .cnt-table th {
    font-weight: 700 !important;
  }

  .cnt-instr-list li::before,
  .cnt-table-tag {
    font-weight: 600 !important;
  }

  /* ─────────────────────────────────────────────
    HIDE EVERYTHING BY DEFAULT
     ───────────────────────────────────────────── */
  body * {
    visibility: hidden !important;
  }

  /* Never print the interactive UI */
  .cnt-navbar,
  .cnt-header,
  .cnt-box,
  .cnt-toolbar,
  .cnt-download-row,
  .cnt-confirm-bar,
  .cnt-collapse-toolbar,
  .cnt-collapse-icon,
  .cnt-main-location-wrap,
  .cnt-footer {
    display: none !important;
  }

  /* Collapsing is an on-screen convenience; the printout always shows every section. */
  .cnt-collapsed .cnt-section-body {
    display: block !important;
  }

  /* ─────────────────────────────────────────────
    PRINT-ONLY CONTENT
     ───────────────────────────────────────────── */
  #cntPrintHeader,
  #cntPrintHeader *,
  #cntInstructions:not([hidden]),
  #cntInstructions:not([hidden]) *,
  #cntResults,
  #cntResults *,
  #cntPrintFooter,
  #cntPrintFooter * {
    visibility: visible !important;
  }

  #cntInstructions[hidden],
  #cntResults[hidden] {
    display: none !important;
  }

  .cnt-print-header,
  .cnt-print-footer {
    box-sizing: border-box;
    width: 100% !important;
    max-width: none !important;
  }

  .cnt-print-header {
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    gap: 12px;

    color: #1f2937;
    border-bottom: 2px solid #1f2937;
    padding: 0 0 6mm;
    margin: 0 0 8mm;

    font-size: 10pt;

    break-inside: avoid;
    page-break-inside: avoid;
  }

  .cnt-print-title {
    font-size: 12pt;
    font-weight: 700;
    color: #111827;
  }

  .cnt-print-generated {
    font-size: 9pt;
  }

  /* Confirmed and printed timestamps stacked at the end of the header */
  .cnt-print-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 1mm;
  }

  .cnt-print-footer {
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    gap: 12px;

    font-size: 9pt;
    color: #1f2937;

    border-top: 1px solid #d1d5db;
    padding: 2mm 0 0;
    margin: 1mm 0 0;

    break-inside: avoid;
    page-break-inside: avoid;
  }

  /* ─────────────────────────────────────────────
    MAIN PRINT CONTAINERS
     ───────────────────────────────────────────── */
  .cnt-wrapper,
  .cnt-results,
  .cnt-table-wrap {
    width: 100% !important;
    max-width: none !important;

    margin-left: 0 !important;
    margin-right: 0 !important;

    padding-left: 0 !important;
    padding-right: 0 !important;

    box-sizing: border-box !important;

    background: #fff !important;
    box-shadow: none !important;
    border-radius: 0 !important;
  }

  #cntInstructions:not([hidden]),
  #cntResults {
    display: block !important;
  }

  /* ─────────────────────────────────────────────
    INSTRUCTIONS
     ───────────────────────────────────────────── */
  #cntInstructions:not([hidden]) {
    border-bottom: 1px solid #d1d5db;
    margin-bottom: 10mm;
    padding: 0 0 4mm;

    break-inside: avoid;
    page-break-inside: avoid;
  }

  .cnt-instr-region {
    font-size: 8pt;
    line-height: 1.2;
  }

  .cnt-instr-list {
    margin: 0;
    padding: 0;
  }

  .cnt-instr-list li {
    font-size: 8pt;
    line-height: 1.4;

    break-inside: avoid;
    page-break-inside: avoid;
  }

  /* ─────────────────────────────────────────────
    RESULTS
     ───────────────────────────────────────────── */
  .cnt-results {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
  }

  /* ─────────────────────────────────────────────
    TABLE CONTAINER
     ───────────────────────────────────────────── */
  .cnt-table-wrap {
    overflow: visible !important;
    border: none !important;

    height: auto !important;
    max-height: none !important;
  }

  /* ─────────────────────────────────────────────
    IMPORTANT:
    Restore the table layout that is changed to
    display:block on screens <= 640px.
     ───────────────────────────────────────────── */
  .cnt-table {
    display: table !important;
    width: 100% !important;
    max-width: none !important;

    table-layout: fixed !important;
    border-collapse: collapse !important;
    border-spacing: 0 !important;

    font-size: 8pt;
    border: 1px solid #d1d5db;

    break-inside: auto;
    page-break-inside: auto;
  }

  .cnt-table thead {
    display: table-header-group !important;

    /*
     * Keep the table heading attached to the following
     * table content and repeat it on every printed page.
     */
    break-inside: avoid !important;
    page-break-inside: avoid !important;
  }

  .cnt-table thead tr {
    display: table-row !important;

    break-inside: avoid !important;
    page-break-inside: avoid !important;
  }

  .cnt-table tbody {
    display: table-row-group !important;

    break-inside: auto;
    page-break-inside: auto;
  }

  .cnt-table tr {
    display: table-row !important;
    width: auto !important;

    border: 0 !important;
    padding: 0 !important;

    break-inside: avoid;
    page-break-inside: avoid;
  }

  .cnt-table th,
  .cnt-table td {
    display: table-cell !important;

    box-sizing: border-box !important;

    border: 1px solid #d1d5db !important;
    padding: 6px 4px !important;

    vertical-align: top;

    overflow-wrap: anywhere !important;
    word-break: break-word !important;

    max-width: 0;
  }

  .cnt-table th {
    white-space: normal !important;
    word-break: break-word !important;
    overflow-wrap: anywhere !important;

    font-size: 7pt;
    line-height: 1.2;
    letter-spacing: 0;

    break-inside: avoid;
    page-break-inside: avoid;
  }

  .cnt-table td {
    font-size: 8pt;
    line-height: 1.2;
  }

  /* Remove the mobile card labels:
     "Container", "Location", etc. */
  .cnt-table td::before {
    display: none !important;
    content: none !important;
  }

  /* ─────────────────────────────────────────────
    TABLE COLUMN WIDTHS
    Total = 100%
     ───────────────────────────────────────────── */
  .cnt-table th:nth-child(1),
  .cnt-table td:nth-child(1) {
    width: 14%;
  }

  .cnt-table th:nth-child(2),
  .cnt-table td:nth-child(2) {
    width: 12%;
  }

  .cnt-table th:nth-child(3),
  .cnt-table td:nth-child(3) {
    width: 16%;
  }

  .cnt-table th:nth-child(4),
  .cnt-table td:nth-child(4) {
    width: 8%;
  }

  .cnt-table th:nth-child(5),
  .cnt-table td:nth-child(5) {
    width: 8%;
  }

  .cnt-table th:nth-child(6),
  .cnt-table td:nth-child(6) {
    width: 8%;
  }

  .cnt-table th:nth-child(7),
  .cnt-table td:nth-child(7) {
    width: 17%;
  }

  .cnt-table th:nth-child(8),
  .cnt-table td:nth-child(8) {
    width: 17%;
  }

  /* ─────────────────────────────────────────────
    LONG TEXT / COORDINATES
     ───────────────────────────────────────────── */
  .cnt-table th:nth-child(8),
  .cnt-table td:nth-child(8) {
    white-space: normal !important;
    word-break: break-word !important;
    overflow-wrap: anywhere !important;
  }

  .cnt-table th:last-child,
  .cnt-table td:last-child {
    white-space: normal !important;
    word-break: break-word !important;
    overflow-wrap: anywhere !important;
  }

  .cnt-coords {
    white-space: normal !important;
    word-break: break-word !important;
    overflow-wrap: anywhere !important;

    font-size: 8pt;
    line-height: 1.2;
  }

  .cnt-coords a {
    white-space: nowrap;
  }

  /* ─────────────────────────────────────────────
    PRINT TABLE COLORS
     ───────────────────────────────────────────── */
  .cnt-table tbody tr:nth-child(odd) td,
  .cnt-table tbody tr:nth-child(even) td,
  .cnt-table tbody tr:hover td {
    background: #fff !important;
    filter: none !important;
  }

  /* ─────────────────────────────────────────────
    BADGES
     ───────────────────────────────────────────── */
  .cnt-table-tag {
    font-size: 8pt;
  }

  .cnt-table,
  .cnt-table th,
  .cnt-table td,
  .cnt-print-header,
  .cnt-print-footer {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
  /* ─────────────────────────────────────────────
    IOS PRINT FONT SIZE
    ───────────────────────────────────────────── */
  @supports (-webkit-touch-callout: none) {
    .cnt-table {
      font-size: 7pt !important;
    }

    .cnt-table th {
      font-size: 6pt !important;
      line-height: 1.15 !important;
    }

    .cnt-table td {
      font-size: 7pt !important;
      line-height: 1.15 !important;
    }

    .cnt-table-tag {
      font-size: 7pt !important;
    }

    .cnt-coords {
      font-size: 7pt !important;
      line-height: 1.15 !important;
    }
  }

  /* ─────────────────────────────────────────────
    GROUPED RESULTS (feedback / read-only / flat)
     ───────────────────────────────────────────── */
  /* The printout is return instructions only: containers without a return
     location (the flat no-location table) and failed lookups are left out. */
  .cnt-table-wrap:has(.cnt-flat-table),
  .cnt-error-list {
    display: none !important;
  }

  /* Once a container has a confirmed location, print that row alone — the other
     radio options were choices, not part of the instructions. Read-only
     containers never have a confirmation and still print all of their options. */
  .cnt-container-section:has(.cnt-row-confirmed) .cnt-facility-row:not(.cnt-row-confirmed) {
    display: none !important;
  }

  /* Feedback-on containers are printed only when a confirmation is on record; read-only ones are unaffected. */
  .cnt-feedback-section:not(:has(.cnt-row-confirmed)):not(:has(.cnt-row-on-record)) {
    display: none !important;
  }

  /* Without a confirmed row, print the location on record: the confirmation the user moved away from
     but has not replaced, or the confirmed location that is no longer offered. */
  tr.cnt-print-only {
    display: table-row !important;
  }
  div.cnt-print-only {
    display: block !important;
  }
  .cnt-container-section:not(:has(.cnt-row-confirmed)):has(.cnt-row-on-record) tbody tr:not(.cnt-row-on-record),
  .cnt-container-section:has(.cnt-row-confirmed) .cnt-row-on-record {
    display: none !important;
  }

  /* Every printed row is a confirmed one, so the badge (and the line break
     setRowConfirmed adds before it) carries no information on paper. */
  .cnt-confirmed-badge,
  .cnt-facility-name-cell br {
    display: none !important;
  }

  /* The "select again" notice and "previously confirmed" mark are on-screen prompts, not return instructions. */
  .cnt-prev-confirmation,
  .cnt-prev-confirmed-badge {
    display: none !important;
  }

  /* The screen count covers every result; the printout counts only what it shows. */
  #cntResultsCount {
    display: none !important;
  }

  #cntPrintResultsCount {
    display: inline !important;
  }

  /* The option count only misleads next to a single confirmed row. */
  .cnt-container-section:has(.cnt-row-confirmed) .cnt-return-options,
  .cnt-container-section:has(.cnt-row-on-record) .cnt-return-options {
    display: none !important;
  }

  /* No radio column either — the printed row is the confirmed one by definition. */
  .cnt-container-section .cnt-radio-th,
  .cnt-container-section .cnt-radio-cell {
    display: none !important;
  }

  /* Re-spread the width freed by the hidden radio column. nth-child still
     counts it, so these stay 1-based against the original 8-column markup. */
  .cnt-container-section .cnt-table th:nth-child(2),
  .cnt-container-section .cnt-table td:nth-child(2) { width: 14%; }
  .cnt-container-section .cnt-table th:nth-child(3),
  .cnt-container-section .cnt-table td:nth-child(3) { width: 20%; }
  .cnt-container-section .cnt-table th:nth-child(4),
  .cnt-container-section .cnt-table td:nth-child(4) { width: 9%; }
  .cnt-container-section .cnt-table th:nth-child(5),
  .cnt-container-section .cnt-table td:nth-child(5) { width: 9%; }
  .cnt-container-section .cnt-table th:nth-child(6),
  .cnt-container-section .cnt-table td:nth-child(6) { width: 8%; }
  .cnt-container-section .cnt-table th:nth-child(7),
  .cnt-container-section .cnt-table td:nth-child(7) { width: 19%; }
  .cnt-container-section .cnt-table th:nth-child(8),
  .cnt-container-section .cnt-table td:nth-child(8) { width: 21%; }

  /* Read-only sections have no radio column, so the same widths start at column 1. */
  .cnt-container-section .cnt-readonly-table th:nth-child(1),
  .cnt-container-section .cnt-readonly-table td:nth-child(1) { width: 14%; }
  .cnt-container-section .cnt-readonly-table th:nth-child(2),
  .cnt-container-section .cnt-readonly-table td:nth-child(2) { width: 20%; }
  .cnt-container-section .cnt-readonly-table th:nth-child(3),
  .cnt-container-section .cnt-readonly-table td:nth-child(3) { width: 9%; }
  .cnt-container-section .cnt-readonly-table th:nth-child(4),
  .cnt-container-section .cnt-readonly-table td:nth-child(4) { width: 9%; }
  .cnt-container-section .cnt-readonly-table th:nth-child(5),
  .cnt-container-section .cnt-readonly-table td:nth-child(5) { width: 8%; }
  .cnt-container-section .cnt-readonly-table th:nth-child(6),
  .cnt-container-section .cnt-readonly-table td:nth-child(6) { width: 19%; }
  .cnt-container-section .cnt-readonly-table th:nth-child(7),
  .cnt-container-section .cnt-readonly-table td:nth-child(7) { width: 21%; }
}
