:root {
  --gvv-primary: #006a60;
  --gvv-primary-hover: #00564e;
  --gvv-primary-soft: #e4f3ef;
  --gvv-accent: #0a8a73;
  --gvv-bg: #f4f7f8;
  --gvv-surface: #ffffff;
  --gvv-surface-soft: #f8fafb;
  --gvv-text: #17212b;
  --gvv-muted: #637083;
  --gvv-border: #dbe2e7;
  --gvv-shadow: 0 18px 50px rgba(22, 33, 43, 0.08);
  --gvv-shadow-soft: 0 8px 24px rgba(22, 33, 43, 0.06);
  --gvv-radius-lg: 1.15rem;
  --gvv-radius-md: 0.8rem;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--gvv-text);
  background:
    radial-gradient(circle at top left, rgba(192, 225, 216, 0.22), transparent 26rem),
    var(--gvv-bg);
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: var(--gvv-primary);
}

a:hover {
  color: var(--gvv-primary-hover);
}

.skip-link {
  position: fixed;
  z-index: 10000;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.65rem 0.9rem;
  border-radius: 0.5rem;
  color: #fff;
  background: #111827;
  transform: translateY(-180%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: relative;
  z-index: 10;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  background:
    linear-gradient(120deg, #005b53 0%, var(--gvv-primary) 46%, #0a8a73 100%);
  box-shadow: 0 8px 28px rgba(6, 28, 22, 0.14);
}

.site-header::after {
  position: absolute;
  inset: 0;
  pointer-events: none;
  content: "";
  opacity: 0.18;
  background-image:
    radial-gradient(circle at 12% 20%, #fff 0 1px, transparent 1px),
    radial-gradient(circle at 78% 34%, #fff 0 1px, transparent 1px);
  background-size: 28px 28px, 36px 36px;
}

.site-header__inner {
  position: relative;
  z-index: 1;
  display: flex;
  min-height: 7.25rem;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.95rem;
  color: #fff;
  text-decoration: none;
}

.brand:hover {
  color: #fff;
}

.brand__logo-wrap {
  display: grid;
  width: 4.55rem;
  height: 4.55rem;
  flex: 0 0 auto;
  place-items: center;
  backdrop-filter: blur(10px);
  transition: transform 160ms ease, background 160ms ease;
}

.brand:hover .brand__logo-wrap {
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-2px);
}

.brand__logo {
  display: block;
  width: 3.75rem;
  height: 3.75rem;
  object-fit: contain;
}

.brand__content {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand__title {
  font-size: 1.58rem;
  font-weight: 800;
  letter-spacing: -0.025em;
}

.brand__subtitle {
  margin-top: 0.42rem;
  color: rgba(255, 255, 255, 0.86);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.site-header__login {
  min-width: 7.2rem;
  padding: 0.55rem 0.9rem;
  border: 0;
  border-radius: 999px;
  color: var(--gvv-primary);
  font-weight: 700;
  box-shadow: 0 7px 18px rgba(0, 0, 0, 0.12);
}

.site-main {
  width: min(100% - 2rem, 1280px);
  min-height: 68vh;
  padding-top: 2.4rem;
  padding-bottom: 3.5rem;
}

.listing-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 1.35rem;
  padding: 0.4rem 0.15rem;
}

.listing-hero__eyebrow,
.catalogue-card__eyebrow {
  margin: 0 0 0.35rem;
  color: var(--gvv-accent);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.listing-hero__title {
  margin: 0;
  color: var(--gvv-text);
  font-size: clamp(2rem, 4vw, 3.25rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1.05;
}

.listing-hero__description {
  max-width: 50rem;
  margin: 0.7rem 0 0;
  color: var(--gvv-muted);
  font-size: 1rem;
  line-height: 1.65;
}

.listing-hero__description p {
  margin: 0;
}

.listing-hero__summary {
  display: flex;
  min-width: 9.5rem;
  flex-direction: column;
  align-items: flex-end;
  padding: 0.85rem 1rem;
  border: 1px solid var(--gvv-border);
  border-radius: var(--gvv-radius-md);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--gvv-shadow-soft);
  backdrop-filter: blur(8px);
}

.listing-hero__summary-value {
  color: var(--gvv-primary);
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1;
}

.listing-hero__summary-label {
  margin-top: 0.3rem;
  color: var(--gvv-muted);
  font-size: 0.78rem;
  font-weight: 600;
}

.catalogue-card {
  overflow: hidden;
  border: 1px solid var(--gvv-border);
  border-radius: var(--gvv-radius-lg);
  background: var(--gvv-surface);
  box-shadow: var(--gvv-shadow);
}

.catalogue-card__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.35rem 1.4rem 1.15rem;
  border-bottom: 1px solid var(--gvv-border);
  background:
    linear-gradient(135deg, rgba(192, 225, 216, 0.18), transparent 50%),
    var(--gvv-surface);
}

.catalogue-card__title {
  margin: 0;
  color: var(--gvv-text);
  font-size: 1.25rem;
  font-weight: 750;
}

.catalogue-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
}

.catalogue-search {
  position: relative;
  width: min(23rem, 45vw);
}

.catalogue-search__icon {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 0.85rem;
  display: inline-flex;
  width: 1.1rem;
  height: 1.1rem;
  color: var(--gvv-muted);
  pointer-events: none;
  transform: translateY(-50%);
}

.catalogue-search__icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.8;
}

.catalogue-search input {
  min-height: 2.75rem;
  padding-left: 2.55rem;
  border-color: var(--gvv-border);
  border-radius: 0.7rem;
  color: var(--gvv-text);
  background: var(--gvv-surface);
}

.catalogue-search input::placeholder {
  color: #8691a0;
}

.catalogue-search input:focus {
  border-color: var(--gvv-primary);
  box-shadow: 0 0 0 0.2rem rgba(0, 106, 96, 0.12);
}

.catalogue-page-size {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--gvv-muted);
  font-size: 0.8rem;
  font-weight: 650;
}

.catalogue-page-size select {
  width: 4.75rem;
  min-height: 2.75rem;
  border-color: var(--gvv-border);
  border-radius: 0.7rem;
  color: var(--gvv-text);
  background-color: var(--gvv-surface);
}

.catalogue-table-wrap {
  overflow-x: auto;
}

.catalogue-table {
  margin: 0 !important;
  color: var(--gvv-text);
}

.catalogue-table thead th {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--gvv-border) !important;
  color: var(--gvv-muted);
  background: var(--gvv-surface-soft);
  font-size: 0.73rem;
  font-weight: 800;
  letter-spacing: 0.055em;
  text-transform: uppercase;
  white-space: nowrap;
}

.catalogue-table tbody td {
  padding: 1rem;
  border-color: var(--gvv-border);
  background: var(--gvv-surface);
  vertical-align: middle;
}

.catalogue-table tbody tr {
  transition: background 150ms ease, box-shadow 150ms ease;
}

.catalogue-table tbody tr:hover td {
  background: var(--gvv-surface-soft);
}

.catalogue-table tbody tr:last-child td {
  border-bottom: 0;
}

.catalogue-table__action-column {
  width: 1%;
}

.serial-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 4.1rem;
  padding: 0.32rem 0.62rem;
  border: 1px solid rgba(0, 106, 96, 0.14);
  border-radius: 999px;
  color: var(--gvv-primary);
  background: var(--gvv-primary-soft);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.82rem;
  font-weight: 800;
}

.virus-name-link {
  display: inline-block;
  max-width: 28rem;
  color: var(--gvv-text);
  font-weight: 750;
  line-height: 1.45;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.virus-name-link:hover {
  color: var(--gvv-primary);
  text-decoration: underline;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.16em;
}

.catalogue-description {
  display: -webkit-box;
  max-width: 28rem;
  overflow: hidden;
  color: var(--gvv-muted);
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.function-text {
  display: -webkit-box;
  max-width: 21rem;
  overflow: hidden;
  color: var(--gvv-text);
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.empty-value {
  color: var(--gvv-muted);
  font-style: italic;
}

.catalogue-table__action {
  text-align: right;
}

.record-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.43rem 0.66rem;
  border-radius: 999px;
  color: var(--gvv-primary);
  background: transparent;
  font-size: 0.82rem;
  font-weight: 750;
  text-decoration: none;
  white-space: nowrap;
}

.record-link:hover {
  color: #fff;
  background: var(--gvv-primary);
}

.record-link svg {
  width: 0.85rem;
  height: 0.85rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.catalogue-footer {
  display: flex;
  min-height: 4.2rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1.35rem;
  border-top: 1px solid var(--gvv-border);
  background: var(--gvv-surface-soft);
}

.catalogue-info {
  color: var(--gvv-muted);
  font-size: 0.84rem;
}

.catalogue-pagination .pagination {
  margin: 0;
}

.catalogue-pagination .page-link {
  min-width: 2.25rem;
  border-color: var(--gvv-border);
  color: var(--gvv-primary);
  background: var(--gvv-surface);
  text-align: center;
}

.catalogue-pagination .page-item.active .page-link {
  border-color: var(--gvv-primary);
  color: #fff;
  background: var(--gvv-primary);
}

.catalogue-pagination .page-item.disabled .page-link {
  color: #98a2b3;
  background: var(--gvv-surface-soft);
}

.catalogue-empty {
  display: flex;
  min-height: 22rem;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 2rem;
  color: var(--gvv-muted);
  text-align: center;
}

.catalogue-empty__icon {
  display: grid;
  width: 4rem;
  height: 4rem;
  place-items: center;
  margin-bottom: 1rem;
  border-radius: 1rem;
  color: var(--gvv-primary);
  background: var(--gvv-primary-soft);
}

.catalogue-empty__icon svg {
  width: 2rem;
  height: 2rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.catalogue-empty h2 {
  margin: 0;
  color: var(--gvv-text);
  font-size: 1.2rem;
  font-weight: 750;
}

.catalogue-empty p {
  margin: 0.4rem 0 0;
}

.site-footer {
  margin-top: auto;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.86);
  background: linear-gradient(120deg, #004e47, var(--gvv-primary));
}

.site-footer__inner {
  display: flex;
  min-height: 5rem;
  align-items: center;
  justify-content: center;
  font-size: 0.86rem;
  text-align: center;
}

/* Hide the default DataTables controls because this design uses a custom toolbar. */
.dataTables_wrapper > .row:last-child {
  display: none;
}

table.dataTable.dtr-inline.collapsed > tbody > tr > td.dtr-control::before,
table.dataTable.dtr-inline.collapsed > tbody > tr > th.dtr-control::before {
  top: 50%;
  border: 0;
  color: #fff;
  background: var(--gvv-primary);
  box-shadow: none;
  transform: translateY(-50%);
}

table.dataTable > tbody > tr.child ul.dtr-details {
  width: 100%;
}

table.dataTable > tbody > tr.child span.dtr-title {
  min-width: 8.5rem;
  color: var(--gvv-muted);
}

@media (max-width: 900px) {
  .catalogue-card__header {
    align-items: stretch;
    flex-direction: column;
  }

  .catalogue-toolbar {
    justify-content: space-between;
  }

  .catalogue-search {
    width: 100%;
  }
}

@media (max-width: 700px) {
  .site-header__inner {
    min-height: 6.25rem;
  }

  .brand__logo-wrap {
    width: 3.7rem;
    height: 3.7rem;
  }

  .brand__logo {
    width: 3rem;
    height: 3rem;
  }

  .brand__title {
    font-size: 1.2rem;
  }

  .brand__subtitle {
    margin-top: 0.3rem;
    font-size: 0.72rem;
  }

  .site-header__login {
    min-width: auto;
  }

  .site-main {
    width: min(100% - 1rem, 1280px);
    padding-top: 1.5rem;
  }

  .listing-hero {
    align-items: stretch;
    flex-direction: column;
    gap: 1rem;
  }

  .listing-hero__summary {
    min-width: 0;
    align-items: flex-start;
  }

  .catalogue-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .catalogue-page-size {
    justify-content: flex-end;
  }

  .catalogue-card__header,
  .catalogue-footer {
    padding-right: 1rem;
    padding-left: 1rem;
  }

  .catalogue-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .catalogue-pagination {
    overflow-x: auto;
  }
}

@media (max-width: 480px) {
  .brand__content {
    display: none;
  }

  .catalogue-page-size {
    justify-content: flex-start;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --gvv-primary: #72d8ce;
    --gvv-primary-hover: #9ae9e1;
    --gvv-primary-soft: #173d39;
    --gvv-accent: #89e0d5;
    --gvv-bg: #11161b;
    --gvv-surface: #1c232a;
    --gvv-surface-soft: #151b20;
    --gvv-text: #f2f6f8;
    --gvv-muted: #bac4ce;
    --gvv-border: #3e4852;
    --gvv-shadow: 0 18px 50px rgba(0, 0, 0, 0.32);
    --gvv-shadow-soft: 0 8px 24px rgba(0, 0, 0, 0.24);
  }

  body {
    background:
      radial-gradient(circle at top left, rgba(114, 216, 206, 0.08), transparent 27rem),
      var(--gvv-bg);
  }

  .listing-hero__summary {
    background: rgba(28, 35, 42, 0.88);
  }

  .catalogue-search input,
  .catalogue-page-size select {
    color-scheme: dark;
  }

  .catalogue-search input::placeholder {
    color: #9ca8b4;
    opacity: 1;
  }

  .site-header__login {
    color: #004f49;
    background: #f5ffff;
  }

  .site-header__login:hover {
    color: #003f3a;
    background: #dff8f5;
  }

  .record-link:hover {
    color: #06211e;
  }

  .catalogue-pagination .page-item.active .page-link {
    color: #06211e;
  }

  table.dataTable.dtr-inline.collapsed > tbody > tr > td.dtr-control::before,
  table.dataTable.dtr-inline.collapsed > tbody > tr > th.dtr-control::before {
    color: #06211e;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
