/* Header nav */
header nav ul {
  /* list-style-type: none; */
  margin: 0;
  padding: 0;
  /* display: flex;
  justify-content: space-between;
  background-color: #333;
  padding: 10px; */
  display: flex;
  align-items: center; /* Align items vertically */
  justify-content: space-between;
  background-color: #333;
  padding: 10px;

}

header nav ul li {
  display: inline-block;
  vertical-align: middle; /* Align items vertically */
  position: relative; /* Add position relative for pop-up bubbles */
}

header nav ul li:first-child {
  margin-right: auto;
}

header nav ul li a {
  display: block;
  padding: 10px 20px;
  text-decoration: none;
  color: #fff;
  font-weight: bold;
  transition: background-color 0.3s;
}

header nav ul li a img {
  display: block;
  height: 40px; /* Adjust the height as needed */
  width: auto; /* Maintain the aspect ratio */
}

header nav ul li a:hover {
  background-color: #555;
}

/* Pop-up bubble styles */
header nav ul li .popup {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background-color: #ffffff;
  border: 2px solid #ddd;
  border-radius: 5px;
  padding: 10px;
  z-index: 9999;
  display: none;
  min-width: 200px; /* Adjust the width as needed */
}

header nav ul li:hover .popup {
  display: block;
}

.popup-content {
  padding: 5px;
}

.popup-arrow {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-bottom: 10px solid #ddd;
}

/* Footer */
footer {
  background-color: #f2f2f2;
  padding: 20px;
  text-align: center;
  color: #333;
}

.footer-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 10px;
  text-align: center;
}

.footer-content p {
  margin: 5px 0;
  text-align: center;
  width: 100%;
}

footer p {
  margin: 10px 0;
}

footer nav ul {
  list-style-type: none;
  margin: 0;
  padding: 0;
}

footer nav ul li {
  display: inline-block;
}

footer nav ul li a {
  display: block;
  padding: 10px 20px;
  text-decoration: none;
  color: #333;
  font-weight: bold;
  margin-bottom: 5px;
  transition: background-color 0.3s;
}

footer nav ul li a:hover {
  background-color: #000fff;
  color: #fff;
}

footer p.disclaimer {
  font-size: 14px;
  font-style: italic;
  margin-top: 5px;
  text-align: center;
}

/* Additional Styles */

body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.5;
  background-color: #f9f9f9;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 10px;
}

h1,
h2,
h3 {
  color: #333;
  margin-bottom: 10px;
}

h1 {
  font-size: 28px;
}

h2 {
  font-size: 24px;
}

p {
  margin: 10px 0;
  text-align: justify; /* Justify text */
}

.button {
  display: inline-block;
  padding: 10px 20px;
  background-color: #333;
  color: #fff;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s;
}

.strikethrough {
  text-decoration: line-through;
}

.button:hover {
  background-color: #555;
}

/* Increased font size and added margin to improve readability of blog content */
.blog-content {
  font-size: 18px;
  /* margin-bottom: 20px; Tweaking spacing on main page */
  text-align: justify; /* Justify text */
}

/* Improved readability of links within blog content */
.blog-content a {
  color: blue;
  text-decoration: none;
}

.blog-content a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 10px auto;
  border-radius: 5px;
  /* box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); */
}

/* Code Blocks */
figure {
  border: 1px solid #ccc;
  border-radius: 5px;
  padding: 10px;
  margin: 10px 0;
}

pre {
  background-color: #f2f2f2;
  color: #333;
  padding: 10px;
  overflow-x: auto;
}

code {
  font-family: Consolas, monospace;
  font-size: 14px;
}

/* Mobile-friendly styles */
@media screen and (max-width: 768px) {
  .container {
    padding: 10px; /* Adjust padding for smaller screens */
  }

  h1 {
    font-size: 24px; /* Decrease font size for headings on smaller screens */
  }

  h2 {
    font-size: 20px; /* Decrease font size for subheadings on smaller screens */
  }

  p {
    font-size: 16px; /* Decrease font size for paragraphs on smaller screens */
  }

  footer {
    padding: 10px; /* Adjust padding for smaller screens */
  }
}

/* Carousel */

.carousel {
  width: 100%;
  overflow: hidden;
  margin-bottom: 20px
}

.carousel-items {
  list-style-type: none;
  margin: 0;
  padding: 0;
  display: flex;
  animation: carousel-animation 30s infinite;
}

.carousel-items li {
  flex: 0 0 100%;
  text-align: center;
  font-size: 200%;
  /* Add additional styling as desired */
}

@keyframes carousel-animation {
  0% {
    transform: translateX(0);
  }
  33.33% {
    transform: translateX(-100%);
  }
  66.66% {
    transform: translateX(-200%);
  }
  100% {
    transform: translateX(0);
  }
}

/* Author Footer */

/* Style the Author Footer container */
.author-footer {
  display: flex;
  align-items: center;
  background-color: #f9f9f9;
  border-radius: 8px;
  padding: 20px;
  max-width: 600px; /* Set the maximum width */
  margin: 0 auto; /* Center the author card horizontally */
}

/* Style the Author Avatar image */
.author-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  margin-right: 20px;
}

/* Style the Author Info container */
.author-info {
  display: flex;
  align-items: center;
}

/* Style the Author Name heading */
.author-name {
  font-size: 20px;
  margin-bottom: 5px;
}

/* Style the Author Bio paragraph */
.author-bio {
  color: #555555;
  font-size: 14px;
  margin-top: 0;
}

.about-avatar {
  width: 250px;
  height: 250px;
  border-radius: 50%;
}

/* post tags display on individual posts */
.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 2px solid #e0e0e0;
}

.tag-badge {
  display: inline-block;
  padding: 6px 14px;
  background-color: #007bff;
  color: #fff !important;
  text-decoration: none;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 500;
  transition: background-color 0.3s, transform 0.2s;
}

.tag-badge:hover {
  background-color: #0056b3;
  text-decoration: none !important;
  transform: translateY(-2px);
}

/* post filter for index */
.post-filter ul {
  list-style-type: none;
  padding: 0;
  margin: 0;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
}

.post-filter li {
  margin: 5px 10px;
  cursor: pointer;
}

.post-filter li span {
  display: inline-block;
  padding: 8px 16px;
  background-color: #f0f0f0;
  border-radius: 20px;
  transition: all 0.3s ease;
  user-select: none;
}

.post-filter li span:hover {
  background-color: #e0e0e0;
}

/* Strikethrough effect for eliminated filter tags */
.post-filter li.strikethrough span {
  text-decoration: line-through;
  opacity: 0.5;
}

/* key table */

.table {
  border-collapse: collapse;
  width: 100%;
}

.table th,
.table td {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: left;
}

.table th {
  background-color: #f2f2f2;
  text-align: center;
}

.table tr:nth-child(even) {
  background-color: #f9f9f9;
}

.table img {
  display: block;
  height: 80px;
  width: auto;
  margin-right: 5px;
  border-radius: 20%;
}

/* card details */
.card-container {
  display: flex; /* Use flexbox */
  flex-wrap: wrap; /* Allow cards to wrap to the next line */
  justify-content: center; /* Center cards horizontally */
  align-items: flex-start; /* Align cards to the top */
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

.card {
  width: 240px;
  margin: 10px;
  border: 2px solid #ddd;
  border-radius: 5px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  display: flex; /* Use flexbox */
  flex-direction: column; /* Arrange content vertically */
  justify-content: flex-start; /* Align content to the top */
}

.card img {
  width: 100%;
  margin: 0;
  height: auto;
  display: block;
  border-radius: 5px 5px 0 0;
}

/* Watch slideshow styles */
.watch-slideshow {
  position: relative;
}

.watch-images {
  position: relative;
  width: 100%;
  padding-bottom: 100%; /* Creates square aspect ratio */
}

.watch-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
}

/* Animation for single image - always visible */
[data-image-count="1"] .watch-image {
  opacity: 1;
  animation: none;
}

/* Animation for 2 images */
[data-image-count="2"] .watch-image {
  animation: watch-fade-2 8s infinite;
}

@keyframes watch-fade-2 {
  0% { opacity: 0; }
  6.25% { opacity: 1; }
  50% { opacity: 1; }
  56.25% { opacity: 0; }
  100% { opacity: 0; }
}

/* Animation for 3 images */
[data-image-count="3"] .watch-image {
  animation: watch-fade-3 12s infinite;
}

@keyframes watch-fade-3 {
  0% { opacity: 0; }
  4.17% { opacity: 1; }
  33.33% { opacity: 1; }
  37.5% { opacity: 0; }
  100% { opacity: 0; }
}

/* Animation for 4 images */
[data-image-count="4"] .watch-image {
  animation: watch-fade-4 16s infinite;
}

@keyframes watch-fade-4 {
  0% { opacity: 0; }
  3.125% { opacity: 1; }
  25% { opacity: 1; }
  28.125% { opacity: 0; }
  100% { opacity: 0; }
}

/* Animation for 5 images */
[data-image-count="5"] .watch-image {
  animation: watch-fade-5 20s infinite;
}

@keyframes watch-fade-5 {
  0% { opacity: 0; }
  2.5% { opacity: 1; }
  20% { opacity: 1; }
  22.5% { opacity: 0; }
  100% { opacity: 0; }
}

/* Animation for 6 images */
[data-image-count="6"] .watch-image {
  animation: watch-fade-6 24s infinite;
}

@keyframes watch-fade-6 {
  0% { opacity: 0; }
  2.08% { opacity: 1; }
  16.67% { opacity: 1; }
  18.75% { opacity: 0; }
  100% { opacity: 0; }
}

/* Animation for 7+ images - generic fallback */
[data-image-count="7"] .watch-image,
[data-image-count="8"] .watch-image,
[data-image-count="9"] .watch-image,
[data-image-count="10"] .watch-image {
  animation: watch-fade-many 28s infinite;
}

@keyframes watch-fade-many {
  0% { opacity: 0; }
  1.5% { opacity: 1; }
  12.5% { opacity: 1; }
  14% { opacity: 0; }
  100% { opacity: 0; }
}

.watch-card {
  width: 240px;
  height: 240px;
  margin: 10px;
  border: 2px solid #ddd;
  border-radius: 5px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  display: flex; /* Use flexbox */
  flex-direction: column; /* Arrange content vertically */
  justify-content: flex-start; /* Align content to the top */
}

.watch-card img {
  width: 100%;
  margin: 0;
  height: auto;
  display: block;
  border-radius: 5px 5px 0 0;
}

.card-content {
  padding: 10px 10px 0;
} 

.caption {
  font-weight: bold;
  margin-top: 5px;
  font-size: 10px; /* Adjust font size as desired */
  text-align: center; /* Center text */
}

.date {
  margin-top: auto;
  font-size: 8px; /* Adjust font size as desired */
  text-align: center; /* Center text */
}

/* Hide the desktop menu by default */
.desktop-menu {
  display: block;
}

/* Hide the mobile menu dropdown by default */
.mobile-menu-dropdown, .mobile-menu {
  display: none;
}

/* Style the mobile menu items */
.mobile-menu-items {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  padding: 0;
  text-align: center;
}

.mobile-menu-items a {
  display: block;
  padding: 10px;
  text-decoration: none;
  color: #000;
  text-align: center;
}

/* Add hover effect to the mobile menu items */
.mobile-menu-items a:hover {
  background-color: #ccc;
}

/* Media query for mobile devices with a maximum width of 768 pixels */
@media (max-width: 768px) {
  /* Hide the desktop menu */
  .desktop-menu {
    display: none;
  }
  
  /* Show the mobile menu */
  .mobile-menu {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
  }

  .mobile-menu-logo {
    display: block;
    width: 100%;
    text-align: center;
  }

  .mobile-menu-logo a {
    display: inline-block;
    text-align: center;
  }
  
  .mobile-menu-items {
    width: 100%;
    justify-content: center;
  }
  
  /* Show the mobile menu icon */
  .mobile-menu-icon {
    display: block;
    font-size: 24px; /* Adjust the font size as desired */
    margin: 0 auto; /* Center the icon */
    text-align: center;
  }
}

/* Table Styles */

table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 20px;
}

table th,
table td {
  border: 1px solid #ddd;
  padding: 15px;
  text-align: center; /* Center the text */
}

table th {
  background-color: #333;
  color: #fff;
}

table tr:nth-child(even) {
  background-color: #f2f2f2;
}

table tr:hover {
  background-color: #ddd;
}

/* RSS Link Styling */
.rss-link {
  color: #ff6600 !important; /* Traditional RSS orange color */
  display: inline-flex;
  align-items: center;
  gap: 6px; /* Space between icon and text */
  text-decoration: none;
}

.rss-link:hover {
  color: #cc5200 !important; /* Darker orange on hover */
}

.rss-icon {
  vertical-align: middle;
  flex-shrink: 0; /* Prevent icon from shrinking */
}

/* Ensure the SVG inherits the link color */
.rss-link svg {
  fill: currentColor;
  display: block;
}

/* For mobile responsiveness */
@media (max-width: 768px) {
  .rss-link {
    gap: 4px;
  }
  
  .rss-icon {
    width: 14px;
    height: 14px;
  }
}
