body {
  /*font-family: Arial, Helvetica, sans-serif;*/
  font-family: Calibri, Candara, Segoe, "Segoe UI", Optima, Arial, sans-serif;
  color: #000;
  margin: 0;
  padding: 0;
  background-color: #f8f8f8;
}

/* Spinner styles */
.spinner-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    pointer-events: none; 
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(164, 210, 51, 0.3);
    border-top: 4px solid #A4D233;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.report-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 20px;
}

.report-table td {
  padding: 2px 10px;
  vertical-align: top;
  font-size: 13px;
}

.report-table .label {
  font-weight: bold;
  width: 240px; 
  /*white-space: nowrap;*/
  word-wrap: break-word;
  overflow-wrap: anywhere;
  white-space: normal;
}

.report-container {
  max-width: 800px;
  margin: auto;
  padding: 40px;
  background: #fff;
  min-height: 90vh;
}

.project-header {
  padding-bottom: 30px;
}

.report-header {
  
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
}

.project-name {
  text-align: center;
  font-size: 24px;
  color: #A4D233; 
  margin: 0;
}

.project-subtitle {
  text-align: center;
  font-size: 18px;
  color: #555;
  margin: 0;
}

.report-logo {
  margin-left: auto;
  text-align: right;
  overflow: visible;
}

.report-logo img {
  
  display: inline-block;
  max-height: 40px;
  height: auto;
  width: auto;
  max-width: 100%;
}

.section-title {
  font-size: 16px;
  font-weight: bold;
  margin-top: 25px;
  margin-bottom: 10px;
  text-transform: uppercase;
  color: #A4D233;
}

.label {
  font-weight: bold;
}

.commentary {
  margin-left: 20px;
}

.observations-table {
    table-layout: fixed !important;   
    width: 100% !important;
    border-collapse: collapse;
    font-size: 13px;
  }

.observations-table td {
    border: 1px solid #d3d3d3; 
    padding-left: 10px;
} 

.image-placeholder {
  margin: 10px 0 20px 0;
}

.image-placeholder img {
  width: 100%;
  height: auto;
  margin-right: 10px;
  margin-left: 10px;
  /*border: 1px solid #ccc;*/
}

.error-message {
    font-family: 'FF Mark Bold', Arial, sans-serif;
    color: #004643; 
    font-size: 16px;
    margin: 20px 0;
    padding: 15px;
    border-left: 5px solid red; 
    background-color: #F1F3F4; 
  }

.divider {
  margin: 20px 0;
  border: none;
  border-top: 1px solid lightgray;
}

.print-btn {
  background-color: #f1f1f1;
  color: black;
  border: 1px solid #ccc;
  padding: 10px 15px;
  cursor: pointer;
  border-radius: 5px;
  /*font-family: Arial, sans-serif;*/
  font-family: Calibri, Candara, Segoe, "Segoe UI", Optima, Arial, sans-serif;
  font-size: 16px;
}

.print-btn:hover {
  background-color: #ddd;
}

footer.copyright {
  text-align: center;
  font-size: 12px;
  color: #555;
  margin-top: 40px;
  padding-top: 10px;
  padding-bottom: 10px;
  border-top: 1px solid #ddd;
}

/* Two-column layout container */
.report-row {
  display: flex;
  flex-wrap: nowrap; 
  gap: 20px;
  align-items: flex-start;      
  margin-bottom: 20px;  
}

/* Left column: data fields (tables) */
.report-row .col-left {
  flex: 1 1 50%;
  min-width: 0;                   
}

/* Right column: images */
.report-row .col-right {
  flex: 1 1 30%;
  max-width: 30%;                  
  min-width: 140px;               
}

/* Image wrapper in right column */
.col-right .image-placeholder {
  margin: 0;                      
}

.col-right .image-placeholder img {
  display: block;
  width: 100%;                   
  height: auto;
  max-width: 100%;
  border: 0;
  margin: 0 0 10px 0;             
}

/* Thumbnails */
.col-right .image-placeholder img.thumbnail {
  width: 85%;                    
  margin-left: auto;
  margin-right: auto;
}

/* Divider spacing between items */
.divider {
  margin: 16px 0;
}

.actions {
 padding-top: 25px;
}

/* On narrow screens, stack columns */
@media (max-width: 800px) {
  .report-row {
    flex-direction: column;
  }
  .report-row .col-right {
    max-width: 100%;
  }
}

/* Print Styles */
@media print {
  body {
    background: #fff;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .no-print {
    display: none !important;
  }

  .report-container {
    max-width: 100% !important;
    width: 100% !important;
    padding: 0 !important;
  }

  .report-header {
    page-break-inside: avoid;
  }

  .report-logo img {
    max-width: 40mm !important;
    max-height: 15mm !important;
    object-fit: contain !important;
    padding-right: 0;
  }

  .observations-table {
    table-layout: fixed !important;
    width: 100% !important;
    border-collapse: collapse !important;
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .observations-table td {
    word-break: break-word !important;
    overflow-wrap: anywhere !important;
    overflow: hidden;
  }

  .image-cell img {
    display: block;
    width: 100% !important;
    height: auto !important;
    margin: 0 0 6px 0 !important;
    page-break-inside: avoid;
  }

  .report-table {
    table-layout: fixed !important;
    width: 100% !important;
    border-collapse: collapse;
  }

  .report-table td {
    word-break: break-word;
    overflow-wrap: anywhere;
  }

  img {
    page-break-inside: avoid;
  }

  .divider {
    margin: 8px 0;
  }

  @page {
    size: auto;
    margin: 15mm 15mm 15mm 15mm;
  }
}