/* Custom styles for Lumos Imaging website */

.page-layout-article .main-content {
  max-width: 1200px;
  /* or your preferred value */
}

.wide-media {
  display: block;
  /* Default for mobile: fit container */
  width: 100%;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .wide-media {
    /* Break out of container but cap the size */
    width: 130%;
    /* Relative to the parent column */
    max-width: 950px;
    /* Cap at reasonable size so it's not huge */
    position: relative;
    left: 50%;
    transform: translateX(-50%);
  }
}

/* Ensure content respects the container */
.wide-media img,
.wide-media video {
  width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
  border-radius: 4px;
  /* Optional polish */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Navbar styling */
.navbar {
  background-color: white !important;
  border-bottom: 1px solid #e0e0e0;
  padding-top: 1rem;
  padding-bottom: 1rem;
  align-items: center;
}

.navbar-brand-container {
  max-width: none !important;
}

.navbar-logo {
  max-height: 60px !important;
  width: auto !important;
  max-width: 100%;
  height: auto !important;
  object-fit: contain;
}

.navbar-title {
  display: none !important;
}


.navbar-nav .nav-link {
  font-weight: 500;
  color: #333 !important;
  margin-left: 15px;
  text-align: center;
  white-space: normal;
  line-height: 1.2;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.navbar-nav .nav-link:hover {
  color: #007bff !important;
  /* Lumos Blue accent */
}

/* Hero Section (Simple & Clean) */
.hero-section {
  padding: 4rem 2rem;
  background-color: #f8f9fa;
  border-bottom: 1px solid #e9ecef;
  margin-bottom: 2rem;
  text-align: center;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 700;
  color: #2c3e50;
  margin-bottom: 1rem;
}

.hero-subtitle {
  font-size: 1.5rem;
  color: #6c757d;
  max-width: 800px;
  margin: 0 auto;
}

.hero-image {
  max-width: 100%;
  width: 30%;
  height: auto;
  border-radius: 8px;
  display: block;
  margin: 0 auto 2rem auto;
  /* Constrain to typical text width if container is wider */
  max-width: 900px;
}

/* Typography Enhancements */
h1,
h2,
h3 {
  color: #2c3e50;
  font-weight: 600;
}

p.lead {
  font-size: 1.25rem;
  color: #555;
  line-height: 1.6;
}

/* Callout adjustments */
.callout {
  border-left-width: 5px;
}

/* Team bio containers */
.team-bio {
  background-color: #f8f9fa;
  border-radius: 12px;
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.team-bio p {
  text-align: justify;
  margin-bottom: 0;
}

.team-photo-container {
  text-align: center;
  margin-bottom: 1.5rem;
}

.team-photo {
  border-radius: 50%;
  width: 160px;
  height: 160px;
  object-fit: cover;
  display: block;
  margin: 0 auto;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.15);
  filter: blur(0.5px);
}

.linkedin-icon {
  width: 16px;
  height: 16px;
  vertical-align: middle;
  margin-left: 0.5rem;
}

/* Custom adjustment to make TOC flush right */
@media (min-width: 1200px) {
  #quarto-margin-sidebar {
    position: fixed !important;
    right: 15px !important;
    /* Added right spacing */
    top: 115px;
    /* Adjust based on navbar height */
    width: 220px;
    max-height: calc(100vh - 115px);
    overflow-y: auto;
    padding-left: 0.5rem;
    z-index: 50;
  }

  /* Adjust main container if necessary so it doesn't overlap, 
     but with page-layout: article and centered content, it should be fine. 
     Currently .main-content is max-width 1200px. */
  /* Add some space if needed */
}

/* Enhanced TOC Highlighting */
#toc-title {
  font-size: 1.35rem;
  /* Larger title */
  padding-left: 10px;
  /* Align with items */
  margin-top: 5px;
  margin-bottom: 1rem;
  font-weight: 700;
  color: #2c3e50;
}

#quarto-margin-sidebar .nav-link.active,
#quarto-margin-sidebar .nav-link.custom-active {
  color: #0056b3 !important;
  font-weight: 700 !important;
  background-color: #e7f1ff;
  border-left: 3px solid #007bff;
  padding-left: 10px;
  border-radius: 0 4px 4px 0;
}

#quarto-margin-sidebar .nav-link {
  font-size: 0.95rem;
  padding-left: 13px;
  border-left: 3px solid transparent;
  transition: all 0.2s ease;
  margin-bottom: 0.2rem;
  display: block;
  text-align: left;
  line-height: 1.4;
}

/* Section Icons */
.section-icon {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  margin-bottom: 10px;
}

.section-icon-large-round {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  margin-bottom: 10px;
}

.section-icon-large-square {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 0;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  margin-bottom: 10px;
}

/* Mobile: Simple Float */
@media (max-width: 767.98px) {
  .section-icon {
    float: left;
    margin-right: 15px;
    margin-top: 5px;
  }

  .section-icon-large-round,
  .section-icon-large-square {
    float: left;
    margin-right: 20px;
    margin-top: 5px;
  }
}

/* Desktop: Hanging Indent */
@media (min-width: 768px) {
  .section-icon {
    float: left;
    margin-left: -100px;
    margin-right: 20px;
    margin-top: 0;
  }

  .section-icon-large-round,
  .section-icon-large-square {
    float: left;
    margin-left: -100px;
    margin-right: 30px;
    margin-top: 0;
  }
}

/* Ensure sections clear each other */
h3 {
  clear: both;
  padding-top: 1rem;
}

/* Interactive Tooltips (Pure CSS/Attribute Based) */
.interactive-term {
  cursor: help;
  border-bottom: 1px dashed #666;
  position: relative;
  color: #2c3e50;
  transition: color 0.2s, border-bottom-color 0.2s;
}

.interactive-term:hover {
  color: #007bff;
  border-bottom-color: #007bff;
}

/* Tooltip Body via Pseudo-element */
.interactive-term::after {
  content: attr(data-definition);
  visibility: hidden;
  width: 250px;
  background-color: #333;
  color: #fff;
  text-align: left;
  border-radius: 6px;
  padding: 10px 14px;
  position: absolute;
  z-index: 1000;
  bottom: 125%;
  /* Position above */
  left: 50%;
  transform: translateX(-50%);
  opacity: 0;
  transition: opacity 0.2s, visibility 0.2s;
  font-size: 0.85rem;
  font-weight: 400;
  line-height: 1.4;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  /* Prevent tooltip from handling pointer events so it doesn't flicker on hover edges */
  pointer-events: none;
}

/* Tooltip Arrow via Pseudo-element */
.interactive-term::before {
  content: "";
  visibility: hidden;
  position: absolute;
  top: 100%;
  /* Just below the top position, effectively bottom of tooltip */
  /* We need to position this relative to the tooltip box, but here it's relative to the span.
       Actually, standard ::after/::before on the span works best if we position both absolutely relative to the span.
    */
  bottom: 115%;
  /* Roughly connects to the bottom of the tooltip at 125% */
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: #333 transparent transparent transparent;
  opacity: 0;
  transition: opacity 0.2s, visibility 0.2s;
  z-index: 1000;
}

/* Show states */
.interactive-term.active::after,
.interactive-term.active::before,
.interactive-term:hover::after,
.interactive-term:hover::before {
  visibility: visible;
  opacity: 1;
}

/* Dimensionality Curse Table Styling */
.dimensionality-curse-table table tbody tr {
  background-color: #ffecec;
  /* Light Red background for all rows (Comparison/Bad) */
}

.dimensionality-curse-table table tbody tr:last-child {
  background-color: #e8f5e9;
  /* Light Green background for the last row (Lumos/Good) */
  font-weight: bold;
  /* Optional: make it pop a bit more */
}

/* Data Calculator Table Styling Override */
#data-table tr.table-success,
#data-table tr.table-success>td {
  background-color: #e8f5e9 !important;
}

#data-table tr.table-danger,
#data-table tr.table-danger>td {
  background-color: #ffecec !important;
}

/* Custom Lumos Solution Box */
.lumos-solution {
  background-color: #f8f9fa;
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 1rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  border-left: 5px solid #007bff;
}

/* Value Proposition Icons round crop*/
.value-prop-icon {
  width: 120px;
  height: auto;
  border-radius: 50%;
  margin-bottom: 1.5rem;
  display: inline-block;
  object-fit: contain;
}