body {
  background: #f7f7f7;
}
.sidebar {
  min-width: 220px;
  max-width: 250px;
  background: #fff;
  min-height: 100vh;
  border-right: 1px solid #e2e2e2;
}
.sidebar .nav-link.active {
  background: #e9ecef;
  font-weight: bold;
}
.adsense-top, .adsense-side, .adsense-bottom {
  background: #e7e7e7;
  color: #888;
  text-align: center;
  margin-bottom: 20px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  /* Ensure minimum width for AdSense */
  min-width: 300px;
  width: 100%;
  box-sizing: border-box;
}
.adsense-top {
  min-height: 90px;
  /* Ensure proper width for top ads */
  max-width: 100%;  
}
.adsense-side {
  min-height: 600px;
  margin-top: 20px;
  /* Ensure proper width for side ads */
  width: 100%;
  max-width: 300px;  
}
.adsense-bottom {
  min-height: 90px;
  /* Ensure proper width for bottom ads */
  max-width: 100%;  
}
/* AdSense specific fixes */
.adsbygoogle {
  display: block !important;
  width: 100% !important;
  min-width: 300px !important;
  box-sizing: border-box !important;
}

/* Ensure containers have proper dimensions before AdSense loads */
.adsense-top .adsbygoogle {
  min-height: 90px !important;
  width: 100% !important;
}

.adsense-side .adsbygoogle {
  min-height: 250px !important;
  width: 100% !important;
  max-width: 300px !important;
}

.adsense-bottom .adsbygoogle {
  min-height: 90px !important;
  width: 100% !important;
}
.footer {
  background: #222;
  color: #ccc;
  padding: 20px 0;
  text-align: center;
}
.menu-fixed {
  position: sticky;
  top: 0;
  z-index: 1020;
}
.carousel-caption {
  background: rgba(0,0,0,0.45);
  border-radius: 8px;
}

.versiculo-numero {
  font-weight: bold;
  color: #222;
  margin-right: 0.3em;
}
ol {
  padding-left: 2em;
}
ol li {
  margin-bottom: 0.5em;
  line-height: 1.7;
}


/* Mobile menu toggle button */
.mobile-menu-toggle {
  display: none;
  background: #007bff;
  color: white;
  border: none;
  padding: 10px 15px;
  border-radius: 5px;
  margin-bottom: 15px;
  font-size: 14px;
  cursor: pointer;
}

.mobile-menu-toggle:hover {
  background: #0056b3;
}

/* Mobile responsive adjustments */
@media (max-width: 991px) {
  .sidebar {
    max-width: 100%;
    min-width: 100%;
    border-right: none;
    border-bottom: 1px solid #eee;
    position: relative !important; /* Override sticky positioning */
    top: auto !important;
    z-index: auto !important;
    min-height: auto;
    padding-bottom: 0;
  }
  .adsense-side { min-height: 150px; }
  .mobile-menu-toggle {
    display: block;
  }
  
  .sidebar .nav {
    display: none; /* Hidden by default on mobile */
    background: white;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 15px;
    margin-top: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  }
  
  .sidebar .nav.show {
    display: block; /* Show when toggled */
  }
  
  .adsense-side { 
    min-height: 150px; 
  }
  
  /* Ensure main content doesn't have extra padding */
  main.col-lg-8 {
    padding-top: 15px !important;
  }
  
  /* Make the menu items more touch-friendly */
  .sidebar .nav-link {
    padding: 12px 15px;
    margin-bottom: 2px;
    border-radius: 4px;
  }
  
  .sidebar .nav-link:hover {
    background-color: #f8f9fa;
  }
  /* Mobile AdSense adjustments */
  .adsense-top, .adsense-bottom {
    min-width: 280px; /* Smaller minimum for mobile */
    width: 100%;
    max-width: 100%;
  }
  
  .adsense-side {
    min-width: 280px;
    width: 100%;
    max-width: 100%;
    min-height: 150px;
  }
  
  .adsbygoogle {
    min-width: 280px !important; /* Mobile minimum */
  }
  
  .adsense-top .adsbygoogle,
  .adsense-bottom .adsbygoogle {
    min-width: 280px !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  
  .adsense-side .adsbygoogle {
    min-width: 280px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-height: 150px !important;
  }
}



/* Improve readability on mobile */
@media (max-width: 768px) {
  ol li {
    line-height: 1.8;
    margin-bottom: 0.8em;
    font-size: 16px; /* Slightly larger text for better readability */
  }
  
  h2 {
    font-size: 1.5rem;
  }
  
  .btn-sm {
    padding: 8px 12px;
    margin: 2px;
  }
}

.topic-card {
  transition: box-shadow 0.2s, transform 0.2s;
  border: none;
  border-radius: 1.1rem;
}
.topic-card:hover {
  box-shadow: 0 0.5rem 2rem 0 rgba(70,130,180,0.15), 0 0.125rem 0.5rem 0 rgba(0,0,0,0.07);
  transform: translateY(-3px) scale(1.015);
  background: #f8fafc;
}
.topic-icon {
  font-size: 2.1rem;
}
@media (max-width: 767px) {
  .topic-card { border-radius: .7rem; }
}