/* Custom styles to override the hugo-universal-theme */

/* Core variables */
:root {
  --primary-accent: #FFFFFF;
  --navbar-border-top: #FFFFFF;
  --navbar-bg: #000000;
  --navbar-text: #ffffff;
  --navbar-hover-bg: #333333;
  --navbar-active-indicator: #ffffff;
  --navbar-height-desktop: 100px;
  --navbar-height-mobile: 70px;
  --navbar-height-xs: 60px;
  --light-grey-bg: #f8f9fa;  /* Light grey for backgrounds */
  --link-dark-color: #444444; /* Dark grey for links on light backgrounds */
  --link-light-color: #ffffff; /* White for links on dark backgrounds */
  --link-dark-hover: #000000; /* Black for link hover on light backgrounds */
  --link-light-hover: #dddddd; /* Light grey for link hover on dark backgrounds */
  --pagination-active-bg: #333333; /* Dark background for active pagination items */
  --focus-outline-color: #1a73e8; /* High visibility color for focus outlines */
  --focus-outline-width: 3px; /* Width of focus outlines */
}

/* Universal link styling - dark links on light backgrounds */
a {
  color: var(--link-dark-color);
  text-decoration: underline;
}

a:hover, a:focus {
  color: var(--link-dark-hover);
  text-decoration: underline;
}

/* By default, remove all focus outlines */
a:focus, button:focus, input:focus, select:focus, textarea:focus {
  outline: none !important; /* Important to override any other styles */
  box-shadow: none !important; /* Some browsers use box-shadow for focus */
}

/* Only show focus on keyboard navigation - apply only to elements with focus-visible class */
.focus-visible,
a.focus-visible, 
button.focus-visible, 
input.focus-visible, 
select.focus-visible, 
textarea.focus-visible {
  outline: var(--focus-outline-width) solid var(--focus-outline-color) !important;
  outline-offset: 2px !important;
}

/* For browsers that support :focus-visible natively */
a:focus-visible, 
button:focus-visible, 
input:focus-visible, 
select:focus-visible, 
textarea:focus-visible {
  outline: var(--focus-outline-width) solid var(--focus-outline-color) !important;
  outline-offset: 2px !important;
}

/* When user is tabbing, show focus indicators */
.user-is-tabbing a:focus,
.user-is-tabbing button:focus,
.user-is-tabbing input:focus,
.user-is-tabbing select:focus,
.user-is-tabbing textarea:focus {
  outline: var(--focus-outline-width) solid var(--focus-outline-color) !important;
  outline-offset: 2px !important;
}

/* Links on dark backgrounds */
.navbar a, 
#footer a, 
.background-image-fixed-2 a, 
.home-carousel .dark-mask a, 
.jumbotron a, 
[style*="background-color: #000"] a, 
[style*="background-color: black"] a,
[style*="background-color: rgb(0, 0, 0)"] a,
[style*="background-color: rgba(0, 0, 0"] a,
[class*="-dark"] a {
  color: var(--link-light-color);
  text-decoration: underline;
}

.navbar a:hover, 
#footer a:hover, 
.background-image-fixed-2 a:hover, 
.home-carousel .dark-mask a:hover, 
.jumbotron a:hover, 
[style*="background-color: #000"] a:hover, 
[style*="background-color: black"] a:hover,
[style*="background-color: rgb(0, 0, 0)"] a:hover,
[style*="background-color: rgba(0, 0, 0"] a:hover,
[class*="-dark"] a:hover,
.navbar a:focus, 
#footer a:focus, 
.background-image-fixed-2 a:focus, 
.home-carousel .dark-mask a:focus, 
.jumbotron a:focus, 
[style*="background-color: #000"] a:focus, 
[style*="background-color: black"] a:focus,
[style*="background-color: rgb(0, 0, 0)"] a:focus,
[style*="background-color: rgba(0, 0, 0"] a:focus,
[class*="-dark"] a:focus {
  color: var(--link-light-hover);
  text-decoration: underline;
}

/* Fix for dropdown menu items - ensure text doesn't disappear on hover */
.navbar ul.dropdown-menu li a, 
.navbar ul.dropdown-menu li a:hover {
  color: #333333 !important; /* Dark color for better visibility */
}

/* Fix for dropdown menu background when clicked elsewhere */
.navbar ul.dropdown-menu {
  background-color: #ffffff !important; /* Ensure background remains white */
}

.navbar-default .navbar-nav > .open > a,
.navbar-default .navbar-nav > .open > a:hover,
.navbar-default .navbar-nav > .open > a:focus {
  color: var(--navbar-text) !important;
  background-color: var(--navbar-hover-bg) !important;
}

/* Keep navbar and footer links styled appropriately */
.navbar-default .navbar-nav > li > a,
.navbar-default .navbar-header .navbar-brand,
#footer .social a {
  text-decoration: none;
}

/* Ensure proper focus for navbar items */
.navbar-default .navbar-nav > li > a:focus,
.navbar-default .navbar-header .navbar-brand:focus,
#footer .social a:focus {
  outline: var(--focus-outline-width) solid var(--focus-outline-color);
  outline-offset: 2px;
}

/* Non-sticky navbar styling */
.navbar-non-sticky {
  position: relative;
  width: 100%;
  z-index: 1000;
}

/* Override the systems section background */
.systems-section-bg {
  background-color: var(--light-grey-bg) !important;
  padding-bottom: 0 !important; /* Remove bottom padding to eliminate white space */
}

/* Add extra padding to the bottom of the systems container */
.systems-section-bg .container {
  padding-bottom: 60px !important; /* Increased from 30px to 60px for more buffer space */
}

/* Fix for Font Awesome 6 social icons */
#footer .social a i {
  font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands";
  font-size: 24px;
  line-height: 24px;
}

#footer .social a {
  margin: 0 5px; /* Reduced spacing between icons */
  color: #ffffff; /* Changed to white for better visibility */
  display: inline-block;
  width: 30px;
  height: 30px;
  line-height: 30px;
  font-size: 20px;
  text-align: center;
  vertical-align: middle;
  background-color: transparent; /* Removed black background */
  padding-top: 0; /* Removed the top padding */
  transition: color 0.3s ease, transform 0.2s ease;
  opacity: 1; /* Ensure icons are visible by default */
  /* Add aria-label to each social link for screen readers */
}

#footer .social a:hover {
  color: #bbbbbb !important; /* Slightly darker on hover */
  transform: scale(1.2); /* Add subtle scale effect on hover */
}

/* Properly contrast the dark mask for better text readability */
.background-image-fixed-2 .dark-mask {
  background: rgba(0, 0, 0, 0.5) !important; /* Reduced opacity to make the overlay less visible */
  opacity: 1 !important;
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  z-index: -1 !important;
}

/* Make sure content is above the dark mask */
.background-image-fixed-2 .container {
  position: relative !important;
  z-index: 2 !important;
}

/* Explicitly hide any icons in the background-image-fixed-2 section */
.background-image-fixed-2 .icon,
.background-image-fixed-2 .icon-lg {
  display: none !important;
  visibility: hidden !important;
}

/* Enhance typography in the background image section with improved text shadow for readability */
.background-image-fixed-2 h3 {
  font-size: 2.2rem !important;
  font-weight: 700 !important;
  margin-bottom: 1.5rem !important;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.9) !important; /* Darker shadow for better contrast */
}

.background-image-fixed-2 .lead {
  font-size: 1.4rem !important;
  margin-bottom: 2rem !important;
  text-shadow: 2px 2px 3px rgba(0, 0, 0, 0.8) !important; /* Darker shadow for better contrast */
}

/* Ensure sufficient contrast for all text */
.post-content p, 
.post-content li,
.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6 {
  color: #333333; /* Darker text color for better contrast */
}

/* Ensure table contrast and accessibility */
.post-content table {
  border-collapse: collapse;
  width: 100%;
  margin-bottom: 1.5em;
}

.post-content th, 
.post-content td {
  padding: 10px;
  border: 1px solid #ddd;
  text-align: left;
}

.post-content th {
  background-color: #f2f2f2;
  color: #333333;
  font-weight: bold;
}

/* Skip to main content link - hidden visually but accessible to screen readers and keyboard navigation */
.skip-link {
  position: absolute;
  top: -40px; /* Hidden by default */
  left: 0;
  background: #000000;
  color: white;
  padding: 8px;
  z-index: 9999;
  transition: top 0.3s ease;
}

/* Modified skip link to always show on focus regardless of input method */
.skip-link:focus {
  top: 0 !important; /* Becomes visible on focus - important to override any other styles */
  outline: var(--focus-outline-width) solid var(--focus-outline-color) !important;
}

/* Ensure proper navbar focus for keyboard users */
.navbar-default .navbar-nav > li > a:focus.focus-visible,
.navbar-default .navbar-header .navbar-brand:focus.focus-visible,
#footer .social a:focus.focus-visible,
.user-is-tabbing .navbar-default .navbar-nav > li > a:focus,
.user-is-tabbing .navbar-default .navbar-header .navbar-brand:focus,
.user-is-tabbing #footer .social a:focus {
  outline: var(--focus-outline-width) solid var(--focus-outline-color) !important;
  outline-offset: 2px !important;
}

/* Ensure proper form control accessibility */
input, 
select, 
textarea, 
button {
  font-size: 1rem;
  padding: 0.5rem;
  border-radius: 4px;
  border: 1px solid #cccccc;
}

/* Ensure proper form control accessibility - for keyboard users */
input:focus.focus-visible, 
select:focus.focus-visible, 
textarea:focus.focus-visible, 
button:focus.focus-visible,
.user-is-tabbing input:focus, 
.user-is-tabbing select:focus, 
.user-is-tabbing textarea:focus, 
.user-is-tabbing button:focus {
  outline: var(--focus-outline-width) solid var(--focus-outline-color) !important;
  outline-offset: 2px !important;
  border-color: var(--focus-outline-color) !important;
}

/* Ensure proper button contrast */
.btn {
  font-weight: 600;
  text-decoration: none;
}

/* Ensure proper button contrast - maintain focus styles for keyboard users */
.btn:focus {
  outline: none !important;
  box-shadow: none !important;
}

.btn:focus.focus-visible,
.user-is-tabbing .btn:focus {
  outline: var(--focus-outline-width) solid var(--focus-outline-color) !important;
  outline-offset: 2px !important;
}

/* Ensure pagination contrast */
.pagination > .active > a,
.pagination > .active > span,
.pagination > .active > a:hover,
.pagination > .active > span:hover,
.pagination > .active > a:focus,
.pagination > .active > span:focus {
  background-color: #333333;
  border-color: #333333;
  color: #ffffff;
}

.pagination > li > a,
.pagination > li > span {
  color: #333333;
}

/* Ensure pagination focus styles - for keyboard users */
.pagination > li > a:focus.focus-visible,
.pagination > li > span:focus.focus-visible,
.user-is-tabbing .pagination > li > a:focus,
.user-is-tabbing .pagination > li > span:focus {
  outline: var(--focus-outline-width) solid var(--focus-outline-color) !important;
  outline-offset: 2px !important;
}

/* For screen reader only content */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ======= Navbar styling ======= */
/* Base navbar styling */
.navbar {
  background-color: var(--navbar-bg) !important;
  border-color: var(--navbar-bg) !important;
}

.navbar > .container {
  padding-left: 25px !important;
}

/* Navbar text colors */
.navbar-default .navbar-nav > li > a,
.navbar-default .navbar-header .navbar-brand {
  color: var(--navbar-text) !important;
}

/* Hover and active states */
.navbar-default .navbar-nav > li > a:hover,
.navbar-default .navbar-nav > li > a:focus,
.navbar-default .navbar-nav > .active > a,
.navbar-default .navbar-nav > .active > a:hover,
.navbar-default .navbar-nav > .active > a:focus {
  color: var(--navbar-text) !important;
  background-color: var(--navbar-hover-bg) !important;
}

/* Navbar indicators - consolidated selectors */
.navbar-default .navbar-nav li > a::before,
.navbar-default .navbar-nav li > a::after,
.navbar-default .navbar-nav .active > a::before,
.navbar-default .navbar-nav .active > a::after {
  background: var(--navbar-active-indicator) !important;
  background-color: var(--navbar-active-indicator) !important;
  border-color: var(--navbar-active-indicator) !important;
}

/* Home carousel styling */
.home-carousel {
  background: var(--primary-accent) !important;
  background-size: cover;
}

.home-carousel .dark-mask {
  background: transparent !important;
  opacity: 1 !important;
}

/* Carousel item container styling - adding lift effect */
.home-carousel .item {
  background-color: #f8f8f8;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  margin: 15px 0;
  padding: 20px;
  transition: all 0.3s ease;
}

.home-carousel .item:hover {
  /* Removed box-shadow enhancement and transform properties to eliminate lift effect */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Improve spacing and alignment in carousel item */
.home-carousel .item .row {
  display: flex;
  align-items: center;
}

/* Adjust text color for better visibility on light grey background */
.home-carousel h1,
.home-carousel h2,
.home-carousel h3,
.home-carousel p,
.home-carousel ul {
  color: #333333 !important;
}

/* Center carousel content */
.home-carousel .item .row .col-sm-5 h1,
.home-carousel .item .row .col-sm-5 p {
  text-align: center !important;
  width: 100% !important;
}

.home-carousel .item .row .col-sm-5 h1 {
  font-weight: bold !important;
}

/* Carousel control styling */
.home-carousel .owl-theme .owl-controls .owl-page span {
  background: #cccccc !important;
}

.home-carousel .owl-theme .owl-controls .owl-page.active span,
.home-carousel .owl-theme .owl-controls .owl-page:hover span {
  background: #666666 !important;
}

/* Carousel images */
.home-carousel .col-sm-7 img.img-responsive {
  max-width: 100%;
  height: auto;
  width: 100%;
  object-fit: contain;
  margin: 0 auto;
}

.home-carousel .col-sm-7 img[src$=".svg"] {
  width: 100%;
  height: auto;
  max-height: 450px;
}

/* Feature box styling */
.box-simple {
  margin-bottom: 40px;
  text-align: center;
}

.box-simple .icon {
  width: 120px;
  height: 120px;
  margin: 0 auto;
  margin-bottom: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #000000;
  color: #fff;
  font-size: 50px;
  transition: all 0.3s ease-out;
}

.box-simple h3 {
  font-weight: 500;
  font-size: 18px;
  text-transform: uppercase;
  margin-bottom: 15px;
}

.box-simple:hover .icon {
  -webkit-transform: scale(1.1, 1.1);
  -ms-transform: scale(1.1, 1.1);
  -o-transform: scale(1.1, 1.1);
  transform: scale(1.1, 1.1);
}

/* ======= DESKTOP STYLING ======= */
@media (min-width: 992px) {
  /* Navbar sizing */
  .navbar {
    min-height: var(--navbar-height-desktop) !important;
  }

  /* Header container alignment */
  .navbar-header, 
  .navbar > .container, 
  .navbar > .container .navbar-header {
    display: flex !important;
    align-items: center !important;
    height: var(--navbar-height-desktop) !important;
  }

  /* Logo styling */
  .navbar-default .navbar-header .navbar-brand {
    padding: 0 0 0 10px !important;
    height: var(--navbar-height-desktop) !important;
    line-height: var(--navbar-height-desktop) !important;
    display: flex !important;
    align-items: center !important;
  }

  .navbar-brand img {
    height: calc(var(--navbar-height-desktop) - 2px) !important;
    max-height: calc(var(--navbar-height-desktop) - 2px) !important;
    margin: 0 auto !important;
    object-fit: contain !important;
    padding: 0 !important;
  }

  /* Menu items alignment */
  .navbar-nav > li > a {
    line-height: var(--navbar-height-desktop) !important;
    padding-top: 0 !important; 
    padding-bottom: 0 !important;
  }

  /* Navbar layout */
  .navbar > .container {
    justify-content: space-between !important;
    width: 100% !important;
  }

  .navbar-collapse {
    flex-grow: 0 !important;
    margin-left: auto !important;
  }

  .navbar-nav {
    float: right !important;
    margin-right: 0 !important;
  }
}

/* ======= MOBILE STYLING ======= */
@media (max-width: 991px) {
  /* Mobile navbar sizing */
  .navbar {
    min-height: var(--navbar-height-mobile) !important;
  }
  
  .navbar-header {
    height: var(--navbar-height-mobile) !important;
  }
  
  /* Hamburger menu styling */
  .navbar-toggle {
    border-radius: 0 !important;
    margin-top: 18px !important;
    margin-right: 15px !important;
    padding: 9px 10px !important;
    background-color: transparent !important;
    border: 1px solid var(--navbar-text) !important;
  }
  
  .navbar-toggle .icon-bar {
    background-color: var(--navbar-text) !important;
    width: 22px !important;
    height: 2px !important;
    border-radius: 1px !important;
  }
  
  .navbar-toggle:hover, 
  .navbar-toggle:focus {
    background-color: var(--navbar-hover-bg) !important;
  }
  
  /* Mobile logo */
  .navbar-brand {
    height: var(--navbar-height-mobile) !important;
    padding: 2px 15px 2px 25px !important;
    display: flex !important;
    align-items: center !important;
  }
  
  .navbar-brand img {
    height: calc(var(--navbar-height-mobile) - 4px) !important;
    width: auto !important;
    padding: 0 !important;
  }
  
  /* Mobile menu container */
  .navbar-collapse {
    border: none !important;
    box-shadow: none !important;
    background-color: var(--navbar-bg) !important;
    padding: 0 !important;
    margin: 0 !important;
    position: absolute !important;
    top: var(--navbar-height-mobile) !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 1000 !important;
    max-height: calc(100vh - var(--navbar-height-mobile)) !important;
    overflow-y: auto !important;
  }
  
  /* Mobile menu items */
  .navbar-nav {
    margin: 0 !important;
    float: none !important;
  }
  
  .navbar-nav > li {
    border-bottom: 1px solid #333 !important;
  }
  
  .navbar-nav > li > a {
    padding: 15px 20px !important;
    line-height: 20px !important;
    color: var(--navbar-text) !important;
    font-size: 16px !important;
  }
  
  .navbar-nav > li > a:hover,
  .navbar-nav > li > a:focus,
  .navbar-nav > .active > a {
    background-color: var(--navbar-hover-bg) !important;
  }
  
  /* Dropdown styling */
  .dropdown-menu {
    padding: 0 !important;
    background-color: #111 !important;
    border: none !important;
    box-shadow: none !important;
  }
  
  .dropdown-menu > li > a {
    padding: 12px 30px !important;
    border-bottom: 1px solid #222 !important;
    color: #333333 !important; /* Changed from var(--navbar-text) to dark color for visibility */
    font-size: 14px !important;
  }
  
  /* Show dropdowns by default on mobile */
  .dropdown.open > .dropdown-menu {
    display: block !important;
  }
  
  /* Systems dropdown specific styling for mobile */
  .navbar-nav .dropdown-menu.systems-dropdown > li > a {
    color: #333333 !important;
    background-color: #ffffff !important;
  }
  
  .navbar-nav .dropdown-menu.systems-dropdown > li > a:hover {
    background-color: #f5f5f5 !important;
    color: #000000 !important;
  }
  
  /* Remove any before/after elements on mobile */
  .navbar-default .navbar-nav li a::before,
  .navbar-default .navbar-nav li a::after {
    display: none !important;
  }
}

/* Extra small phones */
@media (max-width: 480px) {
  .navbar, 
  .navbar-header {
    height: var(--navbar-height-xs) !important;
    min-height: var(--navbar-height-xs) !important;
  }
  
  .navbar-brand {
    height: var(--navbar-height-xs) !important;
    padding: 1px 15px 1px 25px !important;
  }
  
  .navbar-brand img {
    height: calc(var(--navbar-height-xs) - 2px) !important;
    padding: 0 !important;
  }
  
  .navbar-toggle {
    margin-top: 14px !important;
  }
  
  .navbar-collapse {
    top: var(--navbar-height-xs) !important;
  }
}

/* Podcast signup form in carousel */
.podcast-signup, .carousel-content {
  margin-top: 20px;
  text-align: center;
}

.button-container {
  display: flex;
  justify-content: center;
  margin-top: 15px;
}

.notify-button {
  height: 40px;
  background-color: #333;
  color: white;
  border: none;
  border-radius: 4px;
  padding: 10px 20px;
  cursor: pointer;
  transition: background-color 0.3s ease;
  font-size: 16px;
  display: inline-flex;
  align-items: center;
}

.notify-button:hover {
  background-color: #ffffff;
  color: #000000;
  text-decoration: none;
}

/* Mobile styles for buttons consolidated below */

.join-button {
  height: 44px;
  background-color: #000000;
  color: white;
  border: 2px solid #ffffff;
  padding: 10px 20px;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  text-transform: uppercase;
  white-space: nowrap;
  letter-spacing: 1px;
  border-radius: 4px;
}

.join-button:hover {
  background-color: #ffffff;
  color: #000000;
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

/* Consolidated mobile styles */
@media (max-width: 767px) {
  /* Button styling for mobile */
  .podcast-signup, .carousel-content {
    margin-top: 15px;
    text-align: center !important;
  }
  
  .notify-button {
    width: 150px;
    margin: 10px auto !important;
  }
  
  .join-button {
    width: 150px;
  }
  
  /* Adjust carousel item for mobile */
  .home-carousel .item {
    margin: 10px 0;
    padding: 15px;
  }
  
  .home-carousel .item .row {
    flex-direction: column;
  }
  
  .home-carousel .col-sm-5, 
  .home-carousel .col-sm-7 {
    width: 100%;
    padding: 10px;
  }
}

/* System icons styling */
.systems-row .box-simple {
  margin-bottom: 30px;
}

.systems-row .box-simple .icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  transition: all .3s ease;
  box-shadow: 0 5px 15px rgba(0, 0, 0, .1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 15px;
}

.systems-row .box-simple .icon img,
.systems-row .box-simple .icon picture img {
  width: 50px;
  height: auto;
  object-fit: contain;
  filter: brightness(0) invert(1); /* Makes SVG icons white */
}

.systems-row .box-simple a {
  display: block;
  text-decoration: none;
}

.systems-row .box-simple h3 {
  margin-top: 0;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.3s ease;
}

.systems-row .box-simple:hover .icon {
  transform: scale(1.1);
}

.systems-row .box-simple:hover h3 {
  color: var(--primary-accent);
}

/* System-specific icon colors */
.icon-hormonal {
  background-color: #8E44AD !important; /* Purple for hormones */
}

.icon-metabolic {
  background-color: #27AE60 !important; /* Green for metabolism */
}

.icon-cardiovascular {
  background-color: #E74C3C !important; /* Red for heart */
}

.icon-neurologic {
  background-color: #3498DB !important; /* Blue for brain */
}

.icon-musculoskeletal {
  background-color: #F39C12 !important; /* Orange for bones */
}

.icon-gi {
  background-color: #16A085 !important; /* Teal for digestive */
}

.icon-kidney {
  background-color: #2980B9 !important; /* Blue for water/filtering */
}

.icon-skin {
  background-color: #D35400 !important; /* Orange-brown for skin */
}

/* Additional system icon colors */
.icon-immunological {
  background-color: #9B59B6 !important; /* Violet for immune system */
}

.icon-oral {
  background-color: #1ABC9C !important; /* Turquoise for oral health */
}

.icon-cancer {
  background-color: #C0392B !important; /* Deep red for cancer */
}

/* Custom styles for TDKD */

/* Make sure all email links are visible */
a[href^="mailto:"] {
    color: #0056b3 !important; /* Blue color for all email links */
    text-decoration: underline !important;
    font-weight: 500 !important;
}

/* Specific styling for footer email */
footer a[href^="mailto:"] {
    color: white !important;
    font-weight: bold !important;
    text-decoration: underline !important;
}

/* Make sure legal page emails are always visible */
.container a[href^="mailto:"] {
    color: #0056b3 !important;
    font-weight: 500 !important;
    text-decoration: underline !important;
}

/* Enhanced Huberman-style Carousel Styles */
.full-width-carousel {
  overflow: hidden;
  width: 100%;
  padding: 0 0 40px 0; /* Added bottom padding to make room for pagination dots */
  margin: 0;
  background-color: #f0f0f0; /* Slightly darker background to create contrast */
}

.full-width-carousel .home-carousel {
  background: transparent !important;
  padding: 0 !important;
  margin: 0 !important;
  position: relative; /* Ensure proper positioning context */
}

.full-width-carousel .container-fluid {
  max-width: 1400px;
  padding: 0 30px;
  margin: 0 auto;
}

/* Add proper slide transition styles */
.full-width-carousel .owl-carousel .owl-wrapper-outer {
  overflow: hidden;
  position: relative;
  width: 100%;
}

.full-width-carousel .owl-carousel .owl-wrapper {
  transition: all 0.5s ease !important;
}

.full-width-carousel .owl-carousel .owl-item {
  padding: 10px; /* Add padding around each item to create visual separation */
}

.full-width-carousel .home-carousel .item {
  background-color: #ffffff; /* White background for the slide */
  border-radius: 12px; /* Rounded corners */
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12); /* Enhanced shadow for lifted effect */
  margin: 0;
  padding: 0;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 480px; /* Reduced height to fit better on screen */
  overflow: hidden;
  border: 1px solid rgba(0,0,0,0.05); /* Subtle border for better delineation */
}

.full-width-carousel .home-carousel .item:hover {
  /* Removed the lift effect and keep consistent box-shadow */
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
}

.full-width-carousel .home-carousel .item .row {
  display: flex;
  align-items: center;
  height: 100%;
  margin: 0;
}

.full-width-carousel .home-carousel .content-col,
.full-width-carousel .home-carousel .image-col {
  height: 100%;
  padding: 0;
}

.full-width-carousel .home-carousel .content-col {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 40px;
  border-radius: 12px 0 0 12px; /* Match the container's border radius */
}

.full-width-carousel .carousel-text-content {
  max-width: 540px;
  margin: 0 auto;
  padding: 40px;
}

.full-width-carousel .home-carousel h1 {
  font-size: 2.8rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  color: #333 !important;
}

.full-width-carousel .carousel-description {
  font-size: 1.35rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.full-width-carousel .carousel-description p {
  margin-bottom: 0;
  font-weight: 500;
}

.full-width-carousel .carousel-image-container {
  height: 100%;
  width: 100%;
  overflow: hidden;
  border-radius: 0 12px 12px 0; /* Round the image container on the right side */
}

.full-width-carousel .carousel-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

/* Move pagination dots below the carousel but closer */
.full-width-carousel .owl-theme .owl-controls {
  position: absolute;
  bottom: -35px; /* Position dots closer to the carousel */
  left: 0;
  right: 0;
  text-align: center;
  margin-top: 10px;
}

.full-width-carousel .owl-theme .owl-controls .owl-page span {
  width: 12px;
  height: 12px;
  margin: 5px 7px;
  background: rgba(0,0,0,0.3) !important;
  border-radius: 50%;
  display: inline-block;
}

.full-width-carousel .owl-theme .owl-controls .owl-page.active span,
.full-width-carousel .owl-theme .owl-controls .owl-page:hover span {
  background: rgba(0,0,0,0.7) !important;
}

/* Responsive adjustments for the new carousel */
@media (max-width: 991px) {
  .full-width-carousel .home-carousel .item {
    height: 420px; /* Reduced height for medium screens */
  }
  
  .full-width-carousel .home-carousel h1 {
    font-size: 2.2rem;
  }
  
  .full-width-carousel .carousel-description {
    font-size: 1.2rem;
  }
  
  /* Maintain proper pagination positioning */
  .full-width-carousel {
    padding-bottom: 45px;
  }
}

@media (max-width: 767px) {
  .full-width-carousel {
    padding-bottom: 40px;
  }
  
  .full-width-carousel .home-carousel .item {
    height: 580px; /* Adjusted height for vertical layout on mobile */
  }
  
  .full-width-carousel .home-carousel .item .row {
    flex-direction: column-reverse;
  }
  
  .full-width-carousel .home-carousel .content-col,
  .full-width-carousel .home-carousel .image-col {
    height: 50%;
    width: 100%;
  }
  
  .full-width-carousel .home-carousel .content-col {
    border-radius: 0 0 12px 12px; /* Adjust border radius for mobile */
  }
  
  .full-width-carousel .carousel-image-container {
    border-radius: 12px 12px 0 0; /* Adjust border radius for mobile */
  }
  
  /* Fix for mobile images being cut off */
  .full-width-carousel .carousel-image {
    object-fit: contain; /* Change to contain to prevent cutting off */
    padding: 10px; /* Add some padding around the image */
    background-color: #ffffff; /* Match the background */
  }
  
  .full-width-carousel .carousel-text-content {
    padding: 20px;
    text-align: center;
  }
  
  .full-width-carousel .home-carousel h1 {
    font-size: 1.8rem;
  }
}

@media (max-width: 480px) {
  .full-width-carousel {
    padding-bottom: 40px;
  }
  
  .full-width-carousel .home-carousel .item {
    height: 520px; /* Further reduced height for smallest screens */
  }
  
  .full-width-carousel .home-carousel h1 {
    font-size: 1.5rem;
  }
  
  .full-width-carousel .carousel-description {
    font-size: 1rem;
  }
  
  /* Adjust item padding on small screens */
  .full-width-carousel .owl-carousel .owl-item {
    padding: 5px;
  }
  
  /* Additional mobile image adjustments for very small screens */
  .full-width-carousel .home-carousel .image-col {
    height: 45%; /* Give slightly less space to image */
  }
  
  .full-width-carousel .home-carousel .content-col {
    height: 55%; /* Give slightly more space to content */
  }
  
  .full-width-carousel .carousel-image {
    max-height: 100%;
    object-position: center top; /* Focus on top portion of image */
  }
}

/* iPhone SE and other very small devices */
@media (max-width: 375px) {
  .full-width-carousel .home-carousel .item {
    height: 470px;
  }
  
  .full-width-carousel .carousel-text-content {
    padding: 15px 10px;
  }
  
  .full-width-carousel .home-carousel h1 {
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
  }
}

/* Heights for specific common viewport sizes */
@media (min-height: 800px) and (min-width: 1200px) {
  .full-width-carousel .home-carousel .item {
    height: 520px; /* Larger height for taller screens */
  }
}

@media (min-height: 900px) and (min-width: 1200px) {
  .full-width-carousel .home-carousel .item {
    height: 600px; /* Even larger height for very tall screens */
  }
}

/* For particularly short viewports */
@media (max-height: 700px) and (min-width: 992px) {
  .full-width-carousel .home-carousel .item {
    height: 400px; /* Reduced height for shorter screens */
  }
  
  .full-width-carousel {
    padding: 10px 0 45px 0;
  }
}

/* Override btn-template-main styling to make it more visible and consistent */
.btn-template-main {
  background-color: #444444 !important; /* Dark grey instead of black */
  color: #ffffff !important;
  border: 1px solid #444444 !important; /* Thinner border for sleeker look */
  border-radius: 30px !important; /* Rounded corners */
  padding: 10px 25px !important; /* Slightly more horizontal padding */
  transition: all 0.2s ease-in-out !important; /* Smoother transition */
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15) !important; /* Subtler shadow */
  font-weight: 500 !important;
  letter-spacing: 0.5px !important;
}

.btn-template-main:hover,
.btn-template-main:focus,
.btn-template-main:active {
  background-color: #777777 !important;
  color: #ffffff !important;
  border-color: #777777 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2) !important;
}

/* Make sure all buttons use the same style by overriding other button classes */
.btn.join-button, 
.btn.notify-button {
  background-color: #444444 !important;
  color: #ffffff !important;
  border: 1px solid #444444 !important;
  border-radius: 30px !important;
  padding: 10px 25px !important;
  transition: all 0.2s ease-in-out !important;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15) !important;
  font-weight: 500 !important;
  letter-spacing: 0.5px !important;
}

.btn.join-button:hover, 
.btn.notify-button:hover {
  background-color: #777777 !important;
  color: #ffffff !important;
  border-color: #777777 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2) !important;
}

/* About page image styling - UPDATED */
.content-blog-post img, 
.about-content img, 
#blog-post img,
.markdown img,
.content img {
  max-width: 250px; /* Reduced from 300px */
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  margin: 0 0 15px 20px;
  float: right;
  clear: right;
  animation: fadeIn 0.8s ease-in-out;
}

/* Direct descendant selector for the first image in content areas */
.content > p:first-of-type > img,
#blog-post > p:first-of-type > img,
.markdown > p:first-of-type > img {
  max-width: 250px !important;
  height: auto !important;
  float: right !important;
  margin: 0 0 15px 20px !important;
  clear: right !important;
}

/* Ensure images in about.md specifically are handled correctly */
body.page-about .markdown img,
body.page-about .content img,
body.page-about #blog-post img {
  max-width: 250px !important;
  float: right !important;
  margin: 0 0 15px 20px !important;
}

/* Make sure paragraphs clear properly for text wrapping */
#blog-post p, 
.markdown p {
  margin-bottom: 15px;
  overflow: visible; /* Helps with wrapping */
}

/* Make sure the headers don't wrap under the image */
#blog-post h2,
.markdown h2 {
  clear: none;
  margin-top: 0;
}

/* Make about page layout more compact */
#blog-post p, 
#blog-post ul,
.markdown p,
.markdown ul {
  margin-bottom: 15px;
}

/* Add a nice fade-in effect for the about page image */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Responsive adjustments */
@media (max-width: 767px) {
  .content-blog-post img,
  .about-content img,
  #blog-post img,
  .markdown img,
  #blog-post > p:first-of-type > img,
  .markdown > p:first-of-type > img {
    float: none;
    margin: 0 auto 20px auto;
    max-width: 250px;
    width: auto;
    display: block;
  }
}

/* About page image styling */
.about-content img, 
#blog-post img {
  max-width: 300px;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  margin: 0 0 20px 0;
  display: block;
  float: right;
  margin-left: 25px;
}

/* Make about page layout more compact */
#blog-post p, 
#blog-post ul {
  margin-bottom: 15px;
}

/* Help image float nicely in text on larger screens */
@media (min-width: 768px) {
  .image-right {
    float: right;
    margin: 0 0 20px 30px;
    max-width: 40%;
  }
  
  .image-left {
    float: left;
    margin: 0 30px 20px 0;
    max-width: 40%;
  }
}

/* Make about page layout more compact on mobile */
@media (max-width: 767px) {
  .about-content .row {
    margin-bottom: 15px;
  }
  
  .about-image {
    margin-bottom: 20px;
  }
}

/* Target the first image in the content area specifically */
#content .container .row .col-md-12 > div > p:first-of-type > img,
#content .container .row .col-md-12 > div > p:first-child > img {
  max-width: 250px !important;
  height: auto !important;
  float: right !important;
  margin: 0 0 15px 20px !important;
  border-radius: 8px !important;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1) !important;
}

/* Critical fix: ensure the first paragraph containing the image doesn't create a block */
#content .container .row .col-md-12 > div > p:first-of-type,
#content .container .row .col-md-12 > div > p:first-child {
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Make the second paragraph (first actual text) start at the top */
#content .container .row .col-md-12 > div > p:nth-of-type(2),
#content .container .row .col-md-12 > div > h2:first-of-type {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Fix specific to about page */
body.page-about #content .container .row .col-md-12 > div > p:first-of-type + h2 {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Ensure headers don't wrap underneath the image */
#content .container .row .col-md-12 > div > h2 {
  clear: none !important;
}

/* Override the patterned background */
body.boxed {
  background: #ffffff !important; /* Replace with solid white background */
  background-image: none !important; /* Ensure no background image is used */
}

/* Do not override the background for the see more section */
.bar.background-image-fixed-1 {
  background: #f8f9fa !important; /* Light grey background */
  background-image: none !important; /* Ensure no background image is used */
}

/* Special handling for the see more section - allow the inline style to take precedence */
.bar.background-image-fixed-2 {
  /* Styles are defined inline in the template */
  min-height: 500px !important; 
}

/* Override the heading-breadcrumbs pattern background */
#heading-breadcrumbs {
  background: #ffffff !important; /* Replace with white background */
  background-image: none !important; /* Ensure no background image is used */
}

/* Hide the title in breadcrumbs since it's redundant with the page header */
#heading-breadcrumbs h1 {
  display: none !important;
}

/* Add styles for the blog post banner image */
.post-banner-image {
    margin-bottom: 35px; /* Increased bottom margin */
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    width: 100%;
    display: block; /* Changed from text-align: center to ensure block display */
    text-align: center;
}

.post-banner-image img {
    width: 100%;
    height: auto;
    min-height: 300px;
    max-height: 600px;
    object-fit: cover;
    transition: transform 0.3s ease;
    display: block;
    margin: 0 auto; /* Center the image */
}

.post-banner-image:hover img {
    transform: scale(1.02);
}

/* Blog typography improvements */
.post-title {
    font-size: 2.5rem;
    margin-bottom: 20px; /* Increased margin */
    color: #333;
    line-height: 1.2;
    font-weight: 700;
    font-family: 'Open Sans', 'Roboto', sans-serif;
}

.post-meta {
    margin-bottom: 30px; /* Increased margin */
    font-size: 16px; /* Updated from 0.95rem to 16px */
    color: #666;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    font-family: 'Open Sans', 'Roboto', sans-serif;
}

.post-meta i {
    margin-right: 5px;
    color: #999;
}

.post-meta a {
    color: #0056b3;
    text-decoration: none;
}

.post-meta a:hover {
    text-decoration: underline;
}

/* Content styling with improved typography and spacing */
.post-content {
    font-size: 16px !important;
    line-height: 1.6 !important;
    color: #333; /* Dark text for contrast */
    font-family: 'Open Sans', 'Roboto', sans-serif;
    letter-spacing: 0.01em;
}

/* Force spacing between paragraphs and headings */
.post-content p + h2,
.post-content p + h3 {
    margin-top: 55px; /* Extra spacing when h2/h3 follows a paragraph */
}

/* Increased spacing between elements */
.post-content h1 {
    font-size: 2.8rem !important;
    margin-top: 45px; /* Increased margin */
    margin-bottom: 25px; /* Increased margin */
    color: #222;
    font-family: 'Open Sans', 'Roboto', sans-serif;
    line-height: 1.3;
}

.post-content h2 {
    font-size: 2.2rem !important;
    margin-top: 40px; /* Increased margin */
    margin-bottom: 20px; /* Increased margin */
    color: #222;
    font-family: 'Open Sans', 'Roboto', sans-serif;
    line-height: 1.3;
}

.post-content h3 {
    font-size: 1.8rem !important;
    margin-top: 35px; /* Increased margin */
    margin-bottom: 18px; /* Increased margin */
    color: #222;
    font-family: 'Open Sans', 'Roboto', sans-serif;
    line-height: 1.3;
}

.post-content p {
    margin-bottom: 1.7rem; /* Increased margin for better paragraph spacing */
}

/* Ensure spacing between adjacent paragraphs - prevents collapsing */
.post-content p + p {
    margin-top: 1.7rem;
}

.post-content ul, 
.post-content ol {
    margin-bottom: 1.7rem; /* Increased margin */
    padding-left: 25px; /* Slightly increased padding */
}

.post-content li {
    margin-bottom: 0.7rem; /* Increased margin */
}

.post-content a {
    color: #0056b3;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.post-content a:hover {
    border-bottom-color: #0056b3;
}

.post-content strong, 
.post-content b {
    font-weight: 600;
    color: #222;
}

.post-content blockquote {
    border-left: 4px solid #0056b3;
    padding: 15px 25px; /* Increased padding */
    margin: 35px 0; /* Increased margin */
    font-style: italic;
    color: #555;
    background-color: #f9f9f9;
}

/* Author bio styling */
.post-author {
    margin-top: 60px; /* Increased margin */
    padding: 30px; /* Increased padding */
    background-color: #f8f9fa;
    border-radius: 8px;
    font-family: 'Open Sans', 'Roboto', sans-serif;
}

.author-info h4 {
    margin-top: 0;
    font-size: 1.4rem;
    color: #333;
    font-family: 'Open Sans', 'Roboto', sans-serif;
}

.author-info p {
    font-size: 1.05rem;
    color: #555;
    margin-bottom: 0;
    line-height: 1.5;
}

/* Responsive adjustments with larger font for mobile */
@media (max-width: 768px) {
    .post-title {
        font-size: 2rem;
    }
    
    .post-content {
        font-size: 18px; /* Larger font for mobile as requested */
    }
    
    #blog-post .post-banner-image img {
        min-height: 200px;
    }
    
    #blog-post {
        padding: 0 20px;
    }
}

/* Keep other existing styles from before */
@media (min-width: 768px) {
  .image-right {
    float: right;
    margin-left: 25px; /* Increased margin */
    margin-bottom: 15px; /* Increased margin */
  }

  .image-left {
    float: left;
    margin-right: 25px; /* Increased margin */
    margin-bottom: 15px; /* Increased margin */
  }
}

@media (max-width: 767px) {
  .about-content .row {
    display: flex;
    flex-direction: column-reverse;
    margin-bottom: 30px; /* Added margin */
  }
  
  .about-image {
    text-align: center;
    margin-bottom: 25px; /* Increased margin */
  }
}

/* Hide breadcrumbs title to avoid duplication */
#heading-breadcrumbs h1 {
    display: none !important;
}

/* Additional styles for image positioning in the body */
.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 30px 0; /* Increased margin */
    display: block; /* Ensure images are block elements */
    margin-left: auto;
    margin-right: auto; /* Center images */
}

/* Add custom web fonts */
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600;700&family=Roboto:wght@400;500;700&display=swap');

/* Full width blog post container */
#blog-post {
    max-width: 800px; /* Narrower width for optimal line length (50-75 characters) */
    margin: 0 auto;
    float: none;
    padding: 0 25px; /* Slightly increased padding */
}

/* Banner image display - ensure full width and centered */
#blog-post .post-banner-image {
    margin-bottom: 30px;
    width: 100%;
    display: block;
    float: none !important;
    clear: both !important;
    text-align: center;
    box-shadow: none !important;
    border-radius: 0 !important;
    overflow: visible !important;
}

/* Target the image inside the banner container */
#blog-post .post-banner-image img {
    width: 100%;
    height: auto;
    display: block;
    float: none !important;
    margin: 0 auto;
    object-fit: contain;
    max-width: 100%;
    box-shadow: none !important;
    border-radius: 0 !important;
}

/* Remove any hover effects */
#blog-post .post-banner-image:hover img {
    transform: none !important;
    box-shadow: none !important;
}

/* Ensure content text size is large enough */
.post-content {
  font-size: 16px !important;
  line-height: 1.6 !important;
}

.post-content h1 {
  font-size: 2.8rem !important;
  margin-top: 2rem !important;
  margin-bottom: 1.5rem !important;
}

.post-content h2 {
  font-size: 2.2rem !important;
  margin-top: 2rem !important;
  margin-bottom: 1.2rem !important;
}

.post-content h3 {
  font-size: 1.8rem !important;
  margin-top: 1.8rem !important;
  margin-bottom: 1rem !important;
}

/* Hide any carousel navigation elements that might appear */
#blog-post .owl-controls,
#blog-post .owl-pagination,
#blog-post .owl-buttons {
  display: none !important;
}

/* Ensure blog post container doesn't have carousel styling */
#blog-post {
  max-width: 800px !important;
  margin: 0 auto !important;
  padding: 0 15px !important;
  transform: none !important;
  background: transparent !important;
}

/* Remove carousel-related transitions */
#blog-post * {
  transition: none !important;
}

/* Target any background elements */
#blog-post .bg,
#blog-post .dark-mask {
  display: none !important;
}

/* Make sure paragraphs have consistent font size */
#blog-post p, 
.markdown p,
.post-content p,
.post-content li,
#blog-post li,
.markdown li {
  font-size: 16px !important;
}

/* Add consistent font family to all pages */
body {
  font-family: 'Open Sans', 'Roboto', sans-serif;
}

/* Apply the same font styling to main content areas */
.markdown,
#content,
#blog-post,
.content {
  font-family: 'Open Sans', 'Roboto', sans-serif;
  font-size: 16px !important;
  line-height: 1.6 !important;
  color: #333;
  letter-spacing: 0.01em;
}

/* Make headings consistent across the site */
#content h1, 
#content h2, 
#content h3,
.markdown h1,
.markdown h2,
.markdown h3,
#blog-post h1,
#blog-post h2,
#blog-post h3 {
  font-family: 'Open Sans', 'Roboto', sans-serif;
  color: #222;
  line-height: 1.3;
}

#content h1,
.markdown h1,
#blog-post h1 {
  font-size: 2.8rem !important;
}

#content h2,
.markdown h2,
#blog-post h2 {
  font-size: 2.2rem !important;
}

#content h3,
.markdown h3,
#blog-post h3 {
  font-size: 1.8rem !important;
}

/* Specifically target podcast page elements */
.podcast-notify, 
.podcast-notify h3,
.podcast-notify p,
.podcast-signup p {
  font-family: 'Open Sans', 'Roboto', sans-serif;
}

/* Contact form elements */
form label,
form input,
form textarea,
form button {
  font-family: 'Open Sans', 'Roboto', sans-serif !important;
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .markdown,
  #content,
  #blog-post,
  .content {
    font-size: 18px !important; /* Larger font for mobile as requested */
  }
}

/* Specifically target contact page content */
#contact,
#contact section,
#contact h1,
#contact h2,
#contact h3,
#contact p,
#contact .heading,
#contact label,
#contact input,
#contact textarea,
#contact .form-group,
#contact button {
  font-family: 'Open Sans', 'Roboto', sans-serif !important;
}

#contact h1 {
  font-size: 2.8rem !important;
  color: #222 !important;
  line-height: 1.3 !important;
}

#contact h3 {
  font-size: 1.8rem !important;
  color: #222 !important;
  line-height: 1.3 !important;
}

#contact p {
  font-size: 16px !important;
  line-height: 1.6 !important;
  color: #333 !important;
  letter-spacing: 0.01em !important;
}

@media (max-width: 768px) {
  #contact p {
    font-size: 18px !important;
  }
}

/* Social Sharing Buttons */
.social-sharing {
    margin: 30px 0;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.social-sharing h4 {
    margin-top: 0;
    margin-bottom: 15px;
    color: #333;
    font-size: 18px;
}

.social-buttons {
    display: flex;
    gap: 10px;
}

.btn-social-icon {
    display: inline-flex;
    align-items: center;
    padding: 8px 15px;
    border-radius: 4px;
    color: white;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-facebook {
    background-color: #3b5998;
}

.btn-facebook:hover {
    background-color: #2d4373;
    color: white;
    text-decoration: none;
}

.btn-twitter {
    background-color: #000000; /* X's black color */
}

.btn-twitter:hover {
    background-color: #333333;
    color: white;
    text-decoration: none;
}

.btn-linkedin {
    background-color: #0077b5;
}

.btn-linkedin:hover {
    background-color: #005e93;
    color: white;
    text-decoration: none;
}

.btn-social-icon i {
    margin-right: 8px;
}

@media (max-width: 768px) {
    .social-buttons {
        flex-direction: column;
    }
    
    .btn-social-icon {
        width: 100%;
        justify-content: center;
    }
}

/* Embedded form styles */
.form-container {
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    padding: 0;
    margin: 30px 0;
    overflow: hidden;
}

.form-container iframe {
    border: none;
    width: 100%;
    min-height: 800px;
    overflow: hidden;
}

@media (max-width: 768px) {
    .form-container {
        padding: 0;
        margin: 20px 0 50px 0; /* Add bottom margin for mobile */
    }
    
    .form-container iframe {
        min-height: 1200px; /* Significantly increased height for mobile */
    }
}

/* Small phones may need even more height */
@media (max-width: 480px) {
    .form-container iframe {
        min-height: 1300px;
    }
}

/* Additional CSS to help Google Form blend with your site */
.form-container iframe {
    background-color: transparent !important;
}

/* Additional styling for responsive image in system icons */
.systems-row .box-simple .icon picture {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

/* Recent Posts section styling */
.box-image-text.blog {
  margin-bottom: 20px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  height: 100%;
}

.box-image-text.blog:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.box-image-text.blog .top {
  overflow: hidden;
  position: relative;
}

.box-image-text.blog .top img {
  transition: transform 0.3s ease;
  height: 180px;
  width: 100%;
  object-fit: cover;
}

.box-image-text.blog:hover .top img {
  transform: scale(1.05);
}

.box-image-text.blog .content {
  padding: 15px;
}

.box-image-text.blog .content h4 {
  margin-top: 0;
  height: 50px;
  overflow: hidden;
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 10px;
}

.box-image-text.blog .content .date-comments {
  font-size: 12px;
  color: #777;
}

/* Footer Logo Styling */
.footer-logo {
  margin-bottom: 15px;
  padding-top: 10px;
}

.footer-logo a {
  display: block;
  text-decoration: none;
}

.footer-logo-img {
  max-width: 100px;
  height: auto;
  margin-bottom: 15px;
}

@media (max-width: 767px) {
  .footer-logo {
    text-align: center;
  }
  
  .footer-logo-img {
    max-width: 80px;
    margin: 0 auto 15px;
  }
}

/* Author byline styling */
.byline {
  margin: 5px 0 20px;
  font-size: 0.95rem;
  color: #666666;
  font-style: normal;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  position: relative;
  padding-left: 0;
  display: flex;
  align-items: center;
  letter-spacing: 0.01em;
}

.byline .author {
  font-weight: 500;
  color: #333333;
  position: relative;
}

.byline .author::after {
  content: "•";
  display: inline-block;
  margin: 0 8px;
  color: #999;
  font-weight: 400;
}

.byline .post-date {
  color: #777777;
  font-weight: 400;
  position: relative;
}

.byline .post-date::after {
  content: "•";
  display: inline-block;
  margin: 0 8px;
  color: #999;
  font-weight: 400;
}

/* Add styles for the copy link button */
.byline .copy-link {
    display: inline-block;
    margin-left: 0;
    position: relative;
}

.byline .copy-link a {
    color: #555;
    text-decoration: none;
    font-size: 0.9em;
    padding: 2px 8px;
    border-radius: 4px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    transition: all 0.2s ease;
}

.byline .copy-link a:hover {
    background-color: #e8e8e8;
    color: #333;
}

.byline .copy-link a i {
    margin-right: 4px;
}

@media (max-width: 768px) {
    .byline {
        margin: 2px 0 15px;
        font-size: 0.9rem;
    }
    
    .byline .copy-link {
        margin-left: 0;
    }
}

/* Table styling for blog posts and article content */
.post-content table,
#blog-post table,
.content table,
.markdown table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 25px 0;
  font-size: 16px;
  text-align: left;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.06);
}

.post-content th, .post-content td,
#blog-post th, #blog-post td,
.content th, .content td,
.markdown th, .markdown td {
  padding: 14px 16px;
  border-bottom: 1px solid #e0e0e0;
  vertical-align: middle;
}

.post-content tr:last-child td,
#blog-post tr:last-child td,
.content tr:last-child td,
.markdown tr:last-child td {
  border-bottom: none;
}

.post-content th,
#blog-post th,
.content th,
.markdown th {
  background-color: #f5f7fa;
  font-weight: 600;
  color: #333;
  text-transform: none;
  letter-spacing: 0.5px;
  border-bottom: 2px solid #e0e0e0;
}

/* Add subtle row hover effect */
.post-content tbody tr:hover,
#blog-post tbody tr:hover,
.content tbody tr:hover,
.markdown tbody tr:hover {
  background-color: rgba(0, 0, 0, 0.02);
}

/* Add alternating row colors for better readability */
.post-content tbody tr:nth-child(even),
#blog-post tbody tr:nth-child(even),
.content tbody tr:nth-child(even),
.markdown tbody tr:nth-child(even) {
  background-color: #fafafa;
}

/* Make tables responsive on small screens */
@media (max-width: 768px) {
  .post-content table,
  #blog-post table,
  .content table,
  .markdown table {
    font-size: 14px;
    border-radius: 6px;
    margin: 20px 0;
    display: block;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
  }
  
  .post-content th, .post-content td,
  #blog-post th, #blog-post td,
  .content th, .content td,
  .markdown th, .markdown td {
    padding: 10px 12px;
  }
}

/* Specific styles for centered data in tables */
.post-content td[align="center"],
#blog-post td[align="center"],
.content td[align="center"],
.markdown td[align="center"] {
  text-align: center;
}

/* Specific styles for right-aligned data in tables */
.post-content td[align="right"],
#blog-post td[align="right"],
.content td[align="right"],
.markdown td[align="right"] {
  text-align: right;
}

/* Search Styles */
#search-page {
  margin-bottom: 40px;
}

#search-page h1 {
  margin-bottom: 30px;
}

.search-container {
  margin-bottom: 30px;
  max-width: 600px;
}

/* Improved search button styling */
.search-container .input-group {
  display: flex;
  align-items: center;
}

.search-container .input-group-btn {
  display: flex;
  height: 34px; /* Match the height of Bootstrap's default form-control */
}

.search-container .btn-template-main {
  height: 34px; /* Exact height to match the search input */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 20px;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  font-weight: 500;
  letter-spacing: 0.5px;
  margin-left: 5px; /* Add spacing between input and button */
  box-sizing: border-box; /* Ensure padding doesn't increase element size */
}

.search-results article.search-result {
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 1px solid #eee;
}

.search-results h3 {
  margin-top: 0;
  margin-bottom: 5px;
}

.search-results p.date {
  color: #999;
  font-size: 0.9em;
  margin-bottom: 10px;
}

.search-results .summary {
  margin-bottom: 15px;
}

#search-loading, #search-no-results {
  margin: 20px 0;
}

@media (max-width: 767px) {
  .search-container {
    max-width: 100%;
  }
}

/* Improved search form styling */
.search-form-wrapper {
  display: flex;
  align-items: center;
  max-width: 100%;
}

.search-form-wrapper input.form-control {
  flex: 1;
  height: 34px;
  border-radius: 4px;
}

.search-form-wrapper .btn-template-main {
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 20px;
  margin-left: 10px;
  font-weight: 500;
  letter-spacing: 0.5px;
  border-radius: 4px;
}

/* Fix for pagination - ensure visibility of page numbers */
.pagination > li > a,
.pagination > li > span {
  color: #333333; /* Dark color for text */
  background-color: #ffffff;
  border: 1px solid #dddddd;
}

.pagination > li > a:hover,
.pagination > li > span:hover,
.pagination > li > a:focus,
.pagination > li > span:focus {
  color: #333333;
  background-color: #f8f9fa;
}

.pagination > .active > a,
.pagination > .active > span,
.pagination > .active > a:hover,
.pagination > .active > span:hover,
.pagination > .active > a:focus,
.pagination > .active > span:focus {
  color: #ffffff; /* White text */
  background-color: var(--pagination-active-bg); /* Dark background */
  border-color: var(--pagination-active-bg);
}

/* Fallback for browsers that don't support :focus-visible 
   This CSS will be loaded by JavaScript if needed */
.js-focus-visible :focus:not(.focus-visible) {
  outline: none;
}

/* Added for browsers that DO support :focus-visible but implement it differently */
.js-focus-visible .focus-visible {
  outline: var(--focus-outline-width) solid var(--focus-outline-color);
  outline-offset: 2px;
}

/* This comment and CSS below will be removed by JavaScript that detects :focus-visible support */
/* END-FOCUS-VISIBLE-POLYFILL */

/* Podcast Styles */
.podcast-player {
  margin-bottom: 2rem;
  border-radius: 8px;
  overflow: hidden;
}

.podcast-player iframe {
  width: 100%;
  border: none;
}

.podcast-meta {
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #eee;
}

.systems-tags .badge {
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
  padding: 0.5rem 0.8rem;
  font-size: 0.85rem;
}

.episode-card {
  transition: transform 0.3s ease;
  margin-bottom: 3rem;  /* Increased margin between cards */
}

.episode-card:hover {
  transform: translateY(-5px);
}

.latest-episode .card {
  border: none;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.latest-episode .card-body {
  padding: 2rem;
}

.subscribe-section {
  margin-bottom: 3rem;
}

.podcast-platforms .btn {
  padding: 10px;
  font-weight: 600;
}

.podcast-platforms .btn i {
  margin-right: 5px;
}

.suggestions-section {
  margin-top: 3rem;
}

.episode-navigation {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid #eee;
}

@media (max-width: 767px) {
  .podcast-meta .col-md-6.text-md-right {
    text-align: left;
    margin-top: 0.5rem;
  }
  
  .episode-card .card-body .row {
    flex-direction: column;
  }
  
  .episode-card .col-md-3 {
    margin-top: 1rem;
    justify-content: flex-start !important;
  }
}

/* END-FOCUS-VISIBLE-POLYFILL */ 

.podcast-player-container {
  margin: 2rem 0;  /* Added margin around the player */
  padding: 1rem;
  background: #f8f9fa;
  border-radius: 8px;
}

.podcast-player-container {
  margin-bottom: 25px;
  position: relative;
}

/* Latest Podcast Section Styling for Homepage */
section.bar.latest-podcast {
  padding: 40px 0; /* Reduced from 60px */
  background-color: var(--light-grey-bg);
  position: relative;
}

.latest-podcast .heading h2 {
  margin-bottom: 20px; /* Reduced from 30px */
  font-weight: 700;
}

.latest-podcast .podcast-episode-card {
  border: none;
  box-shadow: 0 8px 24px rgba(0,0,0,0.07);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  margin-bottom: 20px; /* Reduced from 30px */
}

/* Card body padding adjustments */
.latest-podcast .podcast-episode-card .card-body {
  padding: 1.5rem; /* Reduced padding */
}

/* Podcast player container adjustments */
.latest-podcast .podcast-player-container {
  margin: 15px 0 20px;
  padding: 0;
  background: transparent;
  border-radius: 0;
}

.latest-podcast .podcast-player {
  margin-bottom: 0;
}

.latest-podcast .podcast-player iframe {
  display: block;
  margin: 0;
}

/* Episode title margin adjustment */
.latest-podcast .episode-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.75rem; /* Reduced from 1rem */
}

/* Episode description margin adjustment */
.latest-podcast .episode-description {
  font-size: 1.05rem;
  line-height: 1.5;
  color: #444;
  margin-bottom: 1.2rem;
  padding: 0 0.25rem;
}

.latest-podcast .episode-description p {
  margin-bottom: 0;
}

/* Footer spacing adjustment */
.latest-podcast .episode-footer {
  margin-top: 1rem;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.latest-podcast .episode-footer .btn {
  margin-left: auto;
}

/* View All Episodes button adjustment */
.latest-podcast .text-center {
  margin-top: 1.5rem; /* Reduced from 4 */
}

.latest-podcast .podcast-episode-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.latest-podcast .episode-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.latest-podcast .episode-description {
  font-size: 1rem;
  line-height: 1.6;
  color: #666;
}

.latest-podcast .btn-outline-primary {
  border: 2px solid #333;
  color: #333;
  background-color: transparent;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 30px;
  transition: all 0.3s ease;
}

.latest-podcast .btn-outline-primary:hover {
  background-color: #333;
  color: #fff;
}

@media (max-width: 767px) {
  .latest-podcast {
    padding: 40px 0;
  }
  
  .latest-podcast .podcast-episode-card {
    margin-bottom: 20px;
  }
  
  .latest-podcast .episode-title {
    font-size: 1.3rem;
  }
}

.episode-meta-header {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-start;
  padding: 0 5px;
}

.episode-badge {
  background-color: #343a40;
  color: #ffffff;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  margin-left: 5px;
}

.meta-separator {
  margin: 0 8px;
  color: #777;
}

.episode-duration, .episode-date {
  color: #666;
  font-size: 0.9rem;
}

/* Latest podcast additional styles */
.latest-podcast .podcast-episode-card .card-header {
  padding: 0.6rem 1.2rem; /* Reduced from 0.8rem 1.5rem */
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
}

.latest-podcast .episode-meta-header {
  padding-left: 5px;
}

/* Podcast Listing Section Styling - for both podcast page and homepage */
.podcast-listing-section {
  padding: 40px 0;
  background-color: var(--light-grey-bg);
  position: relative;
}

.podcast-listing-section .heading h2 {
  margin-bottom: 25px;
  font-weight: 700;
}

.all-episodes .episode-card {
  margin-bottom: 30px;
}

.all-episodes .podcast-episode-card {
  border: none;
  box-shadow: 0 8px 24px rgba(0,0,0,0.07);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.all-episodes .podcast-episode-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.all-episodes .podcast-episode-card .card-header {
  padding: 0.8rem 1.25rem;
  background-color: #f8f9fa;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  text-align: left;
}

.all-episodes .episode-meta-header {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-start;
  padding: 0 5px;
}

.all-episodes .episode-badge {
  background-color: #343a40;
  color: #ffffff;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  margin-left: 5px;
}

.all-episodes .meta-separator {
  margin: 0 8px;
  color: #777;
}

.all-episodes .episode-duration, 
.all-episodes .episode-date {
  color: #666;
  font-size: 0.9rem;
}

.all-episodes .episode-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.3;
}

.all-episodes .podcast-player-container {
  margin: 20px 0;
  padding: 0;
  background: transparent;
}

.all-episodes .podcast-player {
  margin-bottom: 0;
}

.all-episodes .podcast-player iframe {
  display: block;
  width: 100%;
  border: none;
}

.all-episodes .episode-description {
  font-size: 1.05rem;
  line-height: 1.5;
  color: #444;
  margin-bottom: 1.5rem;
}

.all-episodes .episode-description p {
  margin-bottom: 0;
}

.all-episodes .episode-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}

.all-episodes .btn-primary {
  background-color: #444;
  border-color: #444;
  color: #fff;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 30px;
}

.all-episodes .btn-primary:hover {
  background-color: #333;
  border-color: #333;
}

.all-episodes .btn-outline-primary {
  border: 2px solid #444;
  color: #444;
  background-color: transparent;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 30px;
  transition: all 0.3s ease;
}

.all-episodes .btn-outline-primary:hover {
  background-color: #444;
  color: #fff;
  border-color: #444;
}

/* Mobile Responsive Adjustments */
@media (max-width: 767px) {
  .podcast-listing-section {
    padding: 30px 0;
  }
  
  .all-episodes .episode-card {
    margin-bottom: 20px;
  }
  
  .all-episodes .episode-title {
    font-size: 1.3rem;
  }
  
  .all-episodes .podcast-player-container {
    margin: 15px 0;
  }
  
  .all-episodes .podcast-episode-card .card-body {
    padding: 1.25rem;
  }
}

/* Remove the older styles that are now replaced */
section.bar.latest-podcast {
  padding: 40px 0;
  background-color: var(--light-grey-bg);
  position: relative;
}

.latest-podcast .heading h2 {
  margin-bottom: 20px;
  font-weight: 700;
}

.latest-podcast .podcast-episode-card {
  border: none;
  box-shadow: 0 8px 24px rgba(0,0,0,0.07);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  margin-bottom: 20px;
}

/* Card body padding adjustments */
.latest-podcast .podcast-episode-card .card-body {
  padding: 1.5rem;
}

/* Podcast player container adjustments */
.latest-podcast .podcast-player-container {
  margin: 15px 0 20px;
  padding: 0;
  background: transparent;
  border-radius: 0;
}

.latest-podcast .podcast-player {
  margin-bottom: 0;
}

.latest-podcast .podcast-player iframe {
  display: block;
  margin: 0;
}

/* Episode title margin adjustment */
.latest-podcast .episode-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

/* Episode description margin adjustment */
.latest-podcast .episode-description {
  font-size: 1.05rem;
  line-height: 1.5;
  color: #444;
  margin-bottom: 1.2rem;
  padding: 0 0.25rem;
}

.latest-podcast .episode-description p {
  margin-bottom: 0;
}

/* Footer spacing adjustment */
.latest-podcast .episode-footer {
  margin-top: 1rem;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.latest-podcast .episode-footer .btn {
  margin-left: auto;
}

/* View All Episodes button adjustment */
.latest-podcast .text-center {
  margin-top: 1.5rem;
}

.latest-podcast .btn-outline-primary {
  border: 2px solid #333;
  color: #333;
  background-color: transparent;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 30px;
  transition: all 0.3s ease;
}

.latest-podcast .btn-outline-primary:hover {
  background-color: #333;
  color: #fff;
}

@media (max-width: 767px) {
  .latest-podcast {
    padding: 40px 0;
  }
  
  .latest-podcast .podcast-episode-card {
    margin-bottom: 20px;
  }
  
  .latest-podcast .episode-title {
    font-size: 1.3rem;
  }
}

/* Latest podcast additional styles */
.latest-podcast .podcast-episode-card .card-header {
  padding: 0.6rem 1.2rem;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
}

.latest-podcast .episode-meta-header {
  padding-left: 5px;
}

/* Podcast Header Styles - Huberman Lab Inspired */
.podcast-header {
  padding: 4rem 0;
  border-bottom: 1px solid #eaeaea;
  margin-bottom: 3rem;
}

.podcast-logo {
  border-radius: 12px;
  box-shadow: 0 8px 16px rgba(0,0,0,0.15);
  max-width: 100%;
  width: 400px; /* Increased from 350px */
  height: auto;
}

.podcast-title {
  font-size: 5.5rem; /* Dramatically increased from 4rem */
  font-weight: 800; /* Increased from 700 for more impact */
  color: #333;
  margin-bottom: 1.5rem;
  line-height: 1.1;
  letter-spacing: -0.02em; /* Slight negative letter spacing for better visual appearance at large sizes */
}

.podcast-description {
  font-size: 1.8rem; /* Increased from 1.4rem */
  line-height: 1.6;
  color: #444;
  margin-bottom: 2rem;
}

.platform-icon {
  text-align: center;
  color: #333;
  text-decoration: none;
  transition: transform 0.3s ease;
  display: inline-block;
  margin-right: 2.5rem; /* Increased from 2rem */
}

.platform-icon:hover {
  transform: translateY(-3px);
  color: #007bff;
  text-decoration: none;
}

.platform-icon span {
  font-size: 1.1rem; /* Increased from 1rem */
  display: block;
  margin-top: 0.5rem;
}

.platform-icon i {
  font-size: 3rem; /* Increased from 2.5rem */
}

@media (max-width: 767px) {
  .podcast-title {
    font-size: 3.5rem; /* Increased from 3rem for mobile */
    text-align: center;
  }
  
  .podcast-description {
    font-size: 1.5rem; /* Increased from 1.25rem */
    text-align: center;
  }
  
  .podcast-platforms {
    justify-content: center;
    text-align: center;
  }
  
  .platform-icon {
    margin: 0 1.2rem 1.5rem; /* Increased horizontal margin */
  }
}

.byline .post-date::after {
  content: "•";
  display: inline-block;
  margin: 0 8px;
  color: #999;
  font-weight: 400;
}

.byline .episode-number::after {
  content: "•";
  display: inline-block;
  margin: 0 8px;
  color: #999;
  font-weight: 400;
}

/* Add styles for the copy link button */
.byline .episode-duration::after {
  content: "•";
  display: inline-block;
  margin: 0 8px;
  color: #999;
  font-weight: 400;
}

/* Exit Intent Popup Styles */
.exit-intent-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.75);
  z-index: 9999;
  display: none;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  padding: 20px;
  overflow-y: auto;
}

.exit-intent-overlay.show {
  display: flex;
  opacity: 1;
}

.exit-intent-popup {
  background-color: #ffffff;
  width: 95%;
  max-width: 900px;
  max-height: 90vh; /* Limit height to 90% of viewport height */
  border-radius: 12px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
  display: flex;
  transform: translateY(20px);
  transition: transform 0.4s ease;
  margin: auto;
}

.exit-intent-overlay.show .exit-intent-popup {
  transform: translateY(0);
}

.exit-intent-content-side {
  flex: 0 0 40%;
  background-color: #000000;
  color: #ffffff;
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  overflow-y: auto;
}

.exit-intent-logo {
  text-align: center;
  margin-bottom: 20px;
}

.exit-intent-logo img {
  max-width: 180px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.exit-intent-content-side h3 {
  margin: 0 0 25px;
  font-size: 2.2rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
  line-height: 1.2;
  text-transform: none;
}

.exit-intent-content-side p {
  font-size: 1.3rem;
  line-height: 1.4;
  margin-bottom: 25px;
  color: #ffffff;
  font-weight: 500;
}

.exit-intent-content-side ul {
  list-style-type: none;
  padding-left: 0;
  margin-bottom: 0;
  text-align: left;
  width: 100%;
}

.exit-intent-content-side ul li {
  position: relative;
  padding-left: 35px;
  margin-bottom: 16px;
  font-size: 1.6rem;
  color: #ffffff;
  font-weight: 500;
  line-height: 1.3;
}

.exit-intent-content-side ul li:before {
  content: "✓";
  position: absolute;
  left: 0;
  color: #4CAF50;
  font-weight: bold;
  font-size: 1.6rem;
}

.exit-intent-form-side {
  flex: 0 0 60%;
  padding: 30px;
  background: #ffffff;
  display: flex;
  flex-direction: column;
}

.exit-intent-form-side .form-heading {
  display: none; /* Hidden since Beehiiv form has its own heading */
}

.exit-intent-form {
  height: 100%;
  width: 100%;
  position: relative;
  overflow: hidden;
  flex: 1;
  min-height: 420px; /* Added minimum height */
}

.exit-intent-form iframe {
  width: 100%;
  height: calc(100% + 30px); /* Add extra height for the footer */
  border: none;
  position: absolute;
  top: 0;
  left: 0;
}

.exit-intent-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  background-color: rgba(255, 255, 255, 0.95);
  border: 2px solid rgba(0, 0, 0, 0.1);
  color: #333333;
  font-size: 2rem;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: all 0.2s ease;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.exit-intent-close:hover {
  transform: scale(1.1);
  background-color: #ffffff;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.3);
}

/* Additional style for the "Never show again" option */
.exit-intent-footer {
  position: absolute;
  bottom: 10px;
  left: 30px;
  text-align: left;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
}

.exit-intent-footer label {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}

.exit-intent-footer input {
  margin-right: 8px;
  width: 14px;
  height: 14px;
}

/* Add responsive adjustments */
@media (max-width: 768px) {
  .exit-intent-overlay {
    align-items: flex-start;
    padding: 10px;
  }
  
  .exit-intent-popup {
    flex-direction: column;
    max-height: none; /* Remove height restriction */
    height: auto;
    width: 95%;
    max-width: 480px;
    margin: 30px auto;
    overflow-y: auto;
  }
  
  /* Make close button more visible and easier to tap on mobile */
  .exit-intent-close {
    width: 36px;
    height: 36px;
    top: 8px;
    right: 8px;
    font-size: 2.2rem;
    background-color: #ffffff;
    border: 2px solid rgba(0, 0, 0, 0.15);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
  }
  
  .exit-intent-content-side {
    flex: 0 0 auto;
    padding: 20px 15px;
    max-height: none;
  }
  
  .exit-intent-logo {
    margin-bottom: 15px;
  }
  
  .exit-intent-logo img {
    max-width: 120px;
  }
  
  .exit-intent-content-side h3 {
    font-size: 1.6rem;
    margin-bottom: 12px;
  }
  
  .exit-intent-form-side .form-heading {
    font-size: 1.5rem;
    margin-bottom: 8px; /* Reduced from 15px to 8px */
  }
  
  .exit-intent-content-side p {
    font-size: 1rem;
    margin-bottom: 12px;
  }
  
  .exit-intent-content-side ul {
    margin-bottom: 40px; /* Space for footer */
  }
  
  .exit-intent-content-side ul li {
    font-size: 0.95rem;
    padding-left: 25px;
    margin-bottom: 10px;
    line-height: 1.3;
  }
  
  .exit-intent-content-side ul li:before {
    font-size: 1.1rem;
  }
  
  .exit-intent-form-side {
    flex: 0 0 auto;
    padding: 15px;
    height: 520px; /* Increased from 480px */
  }
  
  .exit-intent-footer {
    position: relative;
    bottom: auto;
    left: auto;
    padding: 0;
    margin-top: 15px;
    text-align: center;
    color: rgba(255, 255, 255, 0.8);
  }
}

/* Additional styles for very small screens */
@media (max-width: 480px) {
  .exit-intent-overlay {
    padding: 0;
  }
  
  .exit-intent-popup {
    width: 100%;
    border-radius: 0;
    margin: 0;
    height: 100%;
    max-height: 100%;
  }
  
  .exit-intent-content-side {
    padding: 15px 10px;
  }
  
  /* Extra prominent close button on very small screens */
  .exit-intent-close {
    width: 40px;
    height: 40px;
    top: 5px;
    right: 5px;
    font-size: 2.4rem;
    background-color: #ffffff;
    border: 2px solid rgba(0, 0, 0, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  }
  
  .exit-intent-logo img {
    max-width: 100px;
  }
  
  .exit-intent-content-side h3 {
    font-size: 1.4rem;
  }
  
  .exit-intent-form-side .form-heading {
    font-size: 1.3rem;
    margin-bottom: 6px; /* Reduced from 12px to 6px */
  }
  
  .exit-intent-content-side ul li {
    margin-bottom: 8px;
  }
  
  .exit-intent-form-side {
    height: 500px; /* Increased from 450px */
    padding: 10px;
  }
}