/* Sticky footer styles
-------------------------------------------------- */
html {
  position: relative;
  min-height: 100%;
  font-size: 14px;
}
@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

h1 {
  font-size: 2.25rem;
}

body {
  margin-bottom: 60px; /* Margin bottom by footer height */
}

.container {
 max-width: 1960px;
}

.pricing-header {
  max-width: 700px;
}

.footer {
  position: absolute;
  bottom: 0;
  width: 100%;
  height: 60px; /* Set the fixed height of the footer here */
  line-height: 60px; /* Vertically center the text there */
}
a {
  text-decoration: none;
}
th.sorted-asc a {
  text-decoration: none;
}

th.sorted-desc a {
  text-decoration: none;
}

th.sorted-asc a:after {
  content: ' ▲';
}

th.sorted-desc a:after {
  content: ' ▼';
}

.info-icon {
  display: inline-block;
  width: 1em;
  height: 1em;
  background-color: #007bff;
  color: #fff;
  border-radius: 50%;
  text-align: center;
  line-height: 1.5em;
  font-size: 0.8em;
}

/* Example styles */
.popover {
  border: 2px solid #222
}
.popover-header {
  background-color: #212529; /* Light gray background */
  font-weight: bold;
  text-align: center;
  color:white;
  padding: 10px;
  border-bottom: 1px solid #ccc; /* Optional border */
}

.popover-content {
  font-size: 14px;
  line-height: 1.5;
  padding: 15px;
}


#side-nav {
  flex: 0 0 clamp(220px, 18vw, 300px);
  max-width: clamp(220px, 18vw, 300px);
  transition: flex-basis 150ms ease, max-width 150ms ease;
}

#main-column {
  flex: 1 1 auto;
  min-width: 0;
}

@media (max-width: 767.98px) {
  #side-nav,
  #main-column {
    flex: 0 0 100%;
    max-width: 100%;
  }
}

@media (min-width: 768px) {
  #csidb-search-collapse.collapse {
    display: block !important;
    height: auto !important;
    visibility: visible;
  }
}

@media (min-width: 768px) {
  body.csidb-sidebar-collapsed #side-nav {
    flex-basis: 56px;
    max-width: 56px;
  }

  body.csidb-sidebar-collapsed .csidb-sidebar-header {
    justify-content: center !important;
  }

  body.csidb-sidebar-collapsed .csidb-sidebar-header-label {
    display: none;
  }

  body.csidb-sidebar-collapsed .csidb-side-text {
    display: none;
  }

  body.csidb-sidebar-collapsed .csidb-side-link {
    justify-content: center;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }

  body.csidb-sidebar-collapsed .csidb-sidebar-ad {
    display: none !important;
  }

  .csidb-sidebar-toggle-icon {
    transition: transform 150ms ease;
  }

  body.csidb-sidebar-collapsed .csidb-sidebar-toggle-icon {
    transform: rotate(180deg);
  }
}

#side-nav .csidb-side-nav {
  text-align: left;
}

#side-nav .csidb-side-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 0.75rem;
  border-radius: 0.5rem;
  margin: 0.15rem 0;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.85rem;
}

#side-nav .csidb-side-link:hover,
#side-nav .csidb-side-link:focus {
  background: rgba(255, 255, 255, 0.08);
}

#side-nav .csidb-side-link.active {
  background: rgba(255, 255, 255, 0.14);
  font-weight: 600;
}

#side-nav .csidb-side-icon {
  flex: 0 0 auto;
}

/* Attack Type Icons */

.detail-icon {
        width: 100%;
        max-width: 24px; /* Set a max width as needed */
        height: auto;
    }

/* Global predictive search (HTMX) */
.csidb-suggest-box {
  position: absolute;
  top: calc(100% + 0.25rem);
  left: 0;
  right: 0;
  z-index: 1080;
  background: #212529;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 0.25rem;
  max-height: 420px;
  max-height: min(60vh, 420px);
  overflow-y: auto;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.5);
}

.csidb-suggest-box .list-group-item {
  background: transparent;
  color: #f8f9fa;
  border-color: rgba(255, 255, 255, 0.08);
}

.csidb-suggest-box .list-group-item-action:hover,
.csidb-suggest-box .list-group-item-action:focus {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.csidb-suggest-box .text-muted {
  color: #adb5bd !important;
}

.csidb-suggest-section + .csidb-suggest-section {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.csidb-suggest-section-header {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 0.35rem 0.5rem;
  background: #1a1e21;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #dee2e6;
}

.csidb-suggest-flag {
  display: inline-block;
  font-size: 1rem;
  line-height: 1rem;
  height: 1rem;
  width: 1.333rem;
  flex: 0 0 auto;
  vertical-align: middle;
  border-radius: 2px;
}

.csidb-flag-placeholder {
  display: inline-block;
  height: 1rem;
  width: 1.333rem;
  flex: 0 0 auto;
}

/* Dashboard filters */
.dashboard-filter-bar .dashboard-filter-field {
  min-width: 160px;
  max-width: 240px;
}

.dashboard-filter-bar .form-select {
  width: 100%;
}

.dashboard-filter-toggle .btn {
  font-size: 0.8rem;
  line-height: 1.2;
}

.dashboard-glance-header {
  flex-wrap: nowrap;
}

.dashboard-glance-title {
  white-space: nowrap;
}

.csidb-world-map {
  height: clamp(360px, 32vw, 520px);
}

@media (max-width: 767.98px) {
  .csidb-map-zoom {
    display: none;
  }

  .csidb-map-col {
    padding-left: 0;
    padding-right: 0;
    margin-left: -0.5rem;
    margin-right: -0.5rem;
  }

  .csidb-map-card {
    border-left: 0;
    border-right: 0;
    border-radius: 0;
  }

  .csidb-map-card .card-header {
    border-radius: 0;
  }

  .csidb-map-body {
    padding: 0;
  }

  .csidb-world-map {
    height: clamp(220px, 50vw, 320px);
    border: 0;
    border-radius: 0;
  }

  .dashboard-filter-bar {
    width: 100%;
  }

  .dashboard-filter-bar .dashboard-filter-field {
    flex: 1 1 160px;
    max-width: none;
  }
}
