/**
* BFH Science Self-Service Portal
* Copyright (C) 2025-2026 IKUS Software
*/

/*
 * Let scale everything by default.
 * For reference, printing view port are 720px x 960px for US Letter.
 */
body {
  zoom: 0.75;
  /* Remove shadow */
  --bs-box-shadow: none;
}

/* Force navbar to be printed with background. */
.navbar.navbar-expand-lg {
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

/* Hide navbar content. */
.navbar.navbar-expand-lg .navbar-collapse, .navbar.navbar-expand-lg .navbar-toggler {
  display: none !important;
}

/* Force badge to be printed with background color. */
.badge {
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

/* Force background of card header to be printed. */
.card-header {
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

/* Remove white background from table as it overlap with rounded corner. */
.table > :not(caption) > * > * {
  background: none;
}

/* Adjust MD breakpoints. */
@media (min-width: 700px) {
  .col-md-2 {
    flex: 0 0 auto;
    width: 16.66666667%;
  }
  .col-md-4 {
    flex: 0 0 auto;
    width: 33.33333333%;
  }
  .col-md-6 {
    flex: 0 0 auto;
    width: 50%;
  }
}

/* Hide tooltip icons when printing */
.ssp-tooltip[data-bs-toggle="tooltip"]::after {
  display: none;
}

/* Adjust main container for printing */
.container {
  max-width: 100% !important;
  width: 100% !important;
}

/* Hide external link arrow. */
a.ssp-external::after {
  display: none;
}

/* Avoid page break after Header */
h2 {
  break-after: avoid;
}

/* Avoid paage break within a card */
.card {
  break-inside: avoid;
}

/* For printing we need to display original header and hide fixed-header */
div.dt-scroll-body thead tr,
div.dt-scroll-body tfoot tr {
  height: auto !important;
}
div.dt-scroll-body thead tr th, div.dt-scroll-body thead tr td,
div.dt-scroll-body tfoot tr th,
div.dt-scroll-body tfoot tr td {
  height: auto !important;
  padding: 10px !important;
  border-bottom-width: 1px !important;
}
div.dt-scroll-body thead tr th div.dt-scroll-sizing, div.dt-scroll-body thead tr td div.dt-scroll-sizing,
div.dt-scroll-body tfoot tr th div.dt-scroll-sizing,
div.dt-scroll-body tfoot tr td div.dt-scroll-sizing {
  height: auto !important;
}
.dt-scroll-head{
  display: none;
}

/* Remove height limit */
div.dt-scroll-body {
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
}

/* Expand table to proper width */
table.dataTable {
  width: 100% !important;
}
