/* ============================================================
   UW-Madison Brand Overrides
   Cardinal Red: #C5050C | Dark Red: #9b0000
   ============================================================ */

/* --- Prevent layout shift from scrollbar appearing/disappearing --- */
html {
  scrollbar-gutter: stable;
}

/* --- Page background --- */
body {
  background-color: #f7f7f7;
}

/* --- UW-Madison Fonts (Red Hat Display + Red Hat Text) --- */
@import url('https://fonts.googleapis.com/css2?family=Red+Hat+Display:wght@400;600;700&family=Red+Hat+Text:wght@400;500;600&display=swap');

body {
  font-family: 'Red Hat Text', sans-serif;
}

h1, h2, h3, h4, h5, h6,
.fs-4, .card-title {
  font-family: 'Red Hat Display', sans-serif;
}

/* --- Red top accent bar on every page --- */
body::before {
  content: '';
  display: block;
  height: 5px;
  background-color: #C5050C;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9999;
}

/* Push content down so the fixed bar doesn't overlap */
.col-lg-8.mx-auto {
  padding-top: 1.5rem !important;
}

/* --- Main container --- */
.col-lg-8.mx-auto {
  background-color: #ffffff;
  border-radius: 0.5rem;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
  margin-top: 1.5rem !important;
  margin-bottom: 2rem !important;
}

/* --- Header --- */
header {
  border-bottom: 3px solid #C5050C !important;
  padding-bottom: 1.25rem !important;
  margin-bottom: 2rem !important;
}

header a {
  text-decoration: none;
  color: #212529 !important;
}

header .fs-4 {
  font-weight: 600;
  letter-spacing: -0.01em;
}

/* --- Buttons --- */
.btn-primary {
  background-color: #C5050C !important;
  border-color: #C5050C !important;
  color: #fff !important;
}

.btn-primary:hover,
.btn-primary:focus {
  background-color: #9b0000 !important;
  border-color: #9b0000 !important;
}

.btn-outline-primary {
  color: #C5050C !important;
  border-color: #C5050C !important;
}

.btn-outline-primary:hover,
.btn-outline-primary.active,
.btn-check:checked + .btn-outline-primary {
  background-color: #C5050C !important;
  border-color: #C5050C !important;
  color: #fff !important;
}

/* --- Cards --- */
.card {
  border: none !important;
  border-radius: 0.5rem !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08) !important;
}

.card.bg-light {
  background-color: #fafafa !important;
}

.card-title {
  font-weight: 700;
  color: #212529;
}

/* Red top accent on info cards */
.card-accent {
  border-top: 3px solid #C5050C !important;
}

/* --- DataTable styling --- */
table.dataTable thead th,
table.dataTable thead td {
  background-color: #fdf2f2;
  color: #212529;
  font-weight: 600;
  border-bottom: 2px solid #C5050C !important;
}

table.dataTable tbody tr:hover {
  background-color: #fff5f5 !important;
}

table.dataTable.table-striped tbody tr:nth-child(odd) {
  background-color: #fafafa;
}

/* DataTable search input focus */
#myTable_filter input:focus {
  border-color: #C5050C;
  box-shadow: 0 0 0 0.2rem rgba(197, 5, 12, 0.2);
  outline: none;
}

/* --- Table wrapper card --- */
.table-card {
  background: #fff;
  border-radius: 0.5rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  padding: 1.25rem;
  margin-top: 1rem;
}

/* --- Links --- */
a {
  color: #C5050C;
}

a:hover {
  color: #9b0000;
}

/* Keep header link dark */
header a,
header a:hover {
  color: #212529 !important;
}

/* --- Footer --- */
footer {
  background-color: #ffffff;
  border-top: 2px solid #dee2e6 !important;
  border-radius: 0 0 0.5rem 0.5rem;
  margin: 0 -1rem -1rem -1rem !important;
  padding: 1.25rem 1rem 1rem 1rem !important;
  color: #6c757d;
}

footer a {
  color: #C5050C;
}

footer a:hover {
  color: #9b0000;
}

/* --- Releases page --- */
.release-block {
  border-left: 4px solid #C5050C;
  padding-left: 1rem;
  margin-bottom: 2rem;
}

.release-block h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #212529;
}

/* --- Checkboxes (order column) --- */
.order-checkbox {
  width: 1.1em;
  height: 1.1em;
  cursor: pointer;
  accent-color: #C5050C;
}

/* --- Floating cart button --- */
#cart-bar .btn {
  background-color: #C5050C !important;
  border-color: #C5050C !important;
  color: #fff !important;
  font-weight: 600;
}

#cart-bar .btn:hover {
  background-color: #9b0000 !important;
  border-color: #9b0000 !important;
}

/* --- Upload page consistency --- */
.upload-card {
  border-top: 4px solid #C5050C !important;
}

#drop-zone.drag-over {
  border-color: #C5050C !important;
  background-color: #fff5f5 !important;
}
