body {
  background-color: #f9f9f9;
}

#startAudit {
  --bs-btn-padding-y: 0.7rem;
}

.text-warning {
  --bs-text-opacity: 1;
  color: #fb8c00 !important;
}

.navbar-brand .gradient-text {
  font-weight: 600;
  font-size: 1.4rem;
  background: linear-gradient(45deg, #4285f4, #34a853); /* Google-inspired gradient */
  -webkit-background-clip: text;
  -moz-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  -moz-text-fill-color: transparent;
  transition: transform 0.3s ease;
}
.navbar-brand:hover .gradient-text {
  transform: scale(1.02); /* Subtle zoom effect on hover */
}
.navbar-brand .logo-icon {
  transition: transform 0.3s ease;
}
.navbar-brand:hover .logo-icon {
  transform: rotate(-10deg) scale(1.1); /* Fun rotate effect on hover */
}

.feature-card {
  border: 1px solid #eaeaea;
  border-radius: 0.5rem;
  padding: 1.5rem;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.custom-card {
  border: none;
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.logo {
  width: 60px;
  height: 60px;
  margin: 0 auto;
}

.social-button {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #ddd;
  border-radius: 5px;
  padding: 10px;
  margin-bottom: 10px;
}
.social-button img {
  margin-right: 8px;
}
.social-button:hover {
  background-color: #f8f9fa;
}
.divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 20px 0;
}
.divider::before,
.divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #ddd;
}
.divider:not(:empty)::before {
  margin-right: 0.5em;
}
.divider:not(:empty)::after {
  margin-left: 0.5em;
}

.footer-link {
  padding: 1em;
}

.footer {
  margin-top: 1em;
  margin-bottom: 1em;
  font-size: 0.8em;
  position: relative;
  bottom: 1px;
}

.dropdown-menu.profileNavi[data-bs-popper] {
  top: 100%;
  left: -140%;
  margin-top: var(--bs-dropdown-spacer);
}

.btn-primary {
  opacity: 0.8;
  background-color: #417edc;
}

.btn-outline-primary {
  opacity: 0.8;
}

#loginModal .modal-title {
  font-size: 1.1em;
}

#loginModal .modal-header {
  border-bottom: none;
}

.muted {
  opacity: 0.5;
}

.accordion-button:not(.collapsed) {
  color: var(--bs-accordion-active-color);
  background-color: #ededed;
  box-shadow: inset 0 calc(-1 * var(--bs-accordion-border-width)) 0 var(--bs-accordion-border-color);
}

.text-bg-success-subtle {
  color: var(--bs-success-text-emphasis) !important;
  background-color: var(--bs-success-bg-subtle) !important;
}

.text-bg-danger-subtle {
  color: #5b1919 !important;
  background-color: var(--bs-danger-bg-subtle) !important;
}

.resultRelativeHighlight {
  color: #1a237e !important;
  font-weight: 700 !important;
  font-size: 0.9em !important;
  background-color: #e8eaf6 !important;
  /* opacity: 0.8; */
}

/* legacy */
.resultDetailHighlight {
  color: #3e2723 !important;
  font-weight: 700 !important;
  font-size: 0.9em !important;
  background-color: #efebe9 !important;
  /* opacity: 0.8; */
}

.resultDetailAbsoluteHighlight {
  color: #3e2723 !important;
  font-weight: 700 !important;
  font-size: 0.9em !important;
  background-color: #efebe9 !important;
  /* opacity: 0.8; */
}

.pink-alert {
  --bs-alert-color: #1a237e;
  --bs-alert-bg: #ea80fc;
  --bs-alert-border-color: #ea80fc;
  --bs-alert-link-color: #1a237e;
}

.health-score-circle {
  width: 100px;
  height: 100px;
  color: #fff;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.5rem;
  font-weight: bold;
  margin: auto;
  position: relative;
}

.progress-indicator {
  position: absolute;
  bottom: -12px;
  background-color: #fff;
  border-radius: 20px;
  padding: 0.25rem 0.5rem;
  font-size: 0.75rem;
  font-weight: bold;
}

.badge-pill {
  border-radius: 50px;
  font-size: 0.75rem;
  padding: 0.25rem 0.75rem;
}

.list-item-header {
  font-weight: bold;
  font-size: 1.1rem;
}

.list-item-details {
  font-size: 0.875rem;
}

.nav-brand {
  line-height: 48px;
  padding: 0 10px 0 0;
  font-size: 28px;
  margin-right: 1rem;
  margin-top: 2px;
  text-decoration: none !important;
  color: #630877;
}

.nav-brand-text {
  position: relative;
  top: 2px;
}

.btn-trkkn {
  background-color: #db0000;
  color: #ffffff;
}

.btn-trkkn:hover {
  background-color: #e80000;
  color: #ffffff;
}

.btn-outline-primary {
  opacity: 0.8;
}

/* Base styling for the JSON container */
.json-viewer {
  background-color: #2d2d2d; /* Dark background */
  color: #f8f8f2; /* Light text color */
  padding: 1rem;
  border-radius: 5px;
  font-family: 'Fira Code', monospace;
  font-size: 14px;
  line-height: 1.4;
  overflow-x: auto; /* Horizontal scroll for long lines */
  white-space: pre-wrap; /* Wrap long lines */
  word-wrap: break-word;
}

/* Gradient bands for good → warning → bad within the benchmark window */
.risk-track {
  position: relative;
  height: 1.25rem;
  border-radius: var(--bs-border-radius-pill);
  background: linear-gradient(
    90deg,
    rgb(25, 135, 84) 0%,
    rgba(255, 193, 7, 0.25) 35%,
    rgba(174, 29, 43, 0.952) 100%
  );
  overflow: hidden;
}

/* Marker representing the user's score within the benchmark window */
.risk-marker {
  position: absolute;
  top: 50%;
  translate: -50% -50%;
  width: 0;
  height: 0;
  border-left: 0.5rem solid transparent;
  border-right: 0.5rem solid transparent;
  border-top: 0.7rem solid var(--bs-body-color);
  filter: drop-shadow(0 1px 0 rgba(0, 0, 0, 0.15));
  z-index: 2;
}

/* A subtle highlight under the marker to aid low-vision users */
.risk-marker-shadow {
  position: absolute;
  top: 0;
  height: 100%;
  width: 2px;
  translate: -1px 0;
  background: rgba(0, 0, 0, 0.15);
  z-index: 1;
}

/* “Overflow rail” that appears when score > benchmark (unbounded) */
.overflow-rail {
  position: relative;
  height: 1.25rem;
  border-radius: var(--bs-border-radius-pill);
  background-image: repeating-linear-gradient(
    45deg,
    rgba(220, 53, 69, 0.28) 0,
    rgba(220, 53, 69, 0.28) 8px,
    rgba(220, 53, 69, 0.12) 8px,
    rgba(220, 53, 69, 0.12) 16px
  );
  animation: slide 6s linear infinite;
}

@keyframes slide {
  from {
    background-position: 0 0;
  }
  to {
    background-position: 64px 0;
  }
}

/* Badge that floats just beyond the benchmark when overflowing */
.overflow-badge {
  position: absolute;
  right: -0.25rem;
  top: -0.9rem;
  transform: translateX(100%);
  white-space: nowrap;
}

/* Compact label below the track for exact values */
.metric-label {
  font-variant-numeric: tabular-nums;
}

.marker-value {
  position: absolute;
  top: -1.8rem; /* height above the bar */
  transform: translateX(-50%);
  padding: 0.15rem 0.45rem;
  font-size: 0.9rem;
  font-weight: 500;
  background: var(--bs-body-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: var(--bs-border-radius);
  white-space: nowrap;
  z-index: 3;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.legend-swatch {
  display: inline-block;
  width: 0.85rem;
  height: 0.85rem;
  border-radius: 0.25rem;
  flex: 0 0 0.85rem;
}

.legend-swatch.bg-warning {
  background-color: rgb(250, 232, 186) !important;
}

.legend-swatch.bg-danger-subtle {
  background-color: rgb(228, 174, 146) !important;
}

.legend-swatch.bg-danger {
  background-color: rgb(186, 62, 69) !important;
}
