/* =====================================================================
   assets/css/style.css
   University of Southampton Malaysia — Student CRM
   Branding overrides + DataTables styling to match the navy/gold theme.
   ===================================================================== */

:root {
  --usm-navy:  #002664;
  --usm-gold:  #C9A227;
  --usm-white: #FFFFFF;
  --usm-text:  #1F2937;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--usm-white);
  color: var(--usm-text);
}

/* ---- Buttons ----------------------------------------------------- */

.btn-navy {
  background-color: var(--usm-navy);
  color: #ffffff;
}
.btn-navy:hover {
  background-color: #001a45;
}

.btn-gold {
  background-color: var(--usm-gold);
  color: #ffffff;
}
.btn-gold:hover {
  background-color: #a8861f;
}

.btn-outline {
  border: 1px solid #d1d5db;
  color: var(--usm-text);
  background-color: #ffffff;
}
.btn-outline:hover {
  background-color: #f3f4f6;
}

.btn-danger {
  background-color: #dc2626;
  color: #ffffff;
}
.btn-danger:hover {
  background-color: #b91c1c;
}

/* ---- Top navbar (DataTables header uses the same navy) ------------ */

/* ---- DataTables overrides ----------------------------------------- */

/* Table header: navy background, white text, gold underline */
table.dataTable thead th {
  background-color: var(--usm-navy);
  color: #ffffff;
  border-bottom: 3px solid var(--usm-gold);
  font-weight: 600;
}

/* Zebra striping subtle grey, hover in light navy */
table.dataTable tbody tr {
  background-color: #ffffff;
}
table.dataTable.display tbody tr.odd {
  background-color: #f8fafc;
}
table.dataTable.display tbody tr:hover {
  background-color: #eef2fa;
}

/* Length / filter controls */
.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  padding: 0.25rem 0.5rem;
  color: var(--usm-text);
}
.dataTables_wrapper .dataTables_filter input:focus,
.dataTables_wrapper .dataTables_length select:focus {
  outline: none;
  border-color: var(--usm-navy);
  box-shadow: 0 0 0 2px rgba(0, 38, 100, 0.15);
}

/* Pagination */
.dataTables_wrapper .dataTables_paginate .paginate_button {
  border: 1px solid #e5e7eb;
  border-radius: 0.375rem;
  margin-left: 0.25rem;
  padding: 0.25rem 0.6rem;
  color: var(--usm-text) !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
  background: var(--usm-navy) !important;
  border-color: var(--usm-navy) !important;
  color: #ffffff !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
  background: #eef2fa !important;
  border-color: var(--usm-gold) !important;
}

/* Info line */
.dataTables_wrapper .dataTables_info {
  color: #6b7280;
  font-size: 0.875rem;
}

/* ---- Misc ---------------------------------------------------------- */

.stat-card-number {
  color: var(--usm-navy);
}

.section-title {
  color: var(--usm-navy);
  border-bottom: 3px solid var(--usm-gold);
  padding-bottom: 0.5rem;
}

.form-label {
  color: #374151;
  font-weight: 500;
  font-size: 0.875rem;
}

input[type="text"]:focus, input[type="email"]:focus, input[type="password"]:focus,
input[type="date"]:focus, input[type="number"]:focus, select:focus, textarea:focus {
  border-color: var(--usm-navy);
  outline: none;
  box-shadow: 0 0 0 2px rgba(0, 38, 100, 0.12);
}

/* ---- Searchable select -------------------------------------------
   The type-ahead widget's styles live in assets/css/searchable-select.css,
   because the standalone student layout (tickets/_student_header.php) loads
   this file's sibling slaa.css instead of this one. */

/* ---- Import previews ---------------------------------------------
   The problem summary above an import preview links to a row; this is what
   makes the row it lands on visible. The background goes on the cells, because
   a cell paints over its row. */
tr.import-row:target td {
  background-color: #fef3c7;
}
