/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Base Styles */
body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  background-color: #f9f9f9;
  color: #333;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.logo {
  font-size: 1.8rem;
  font-weight: bold;
  color: white;
  letter-spacing: 1px;
  user-select: none;
}

.logo-first {
  color: #ffffff;
}

.logo-last {
  color: #ffcc00;
  margin-left: 5px;
}

main.main-content {
  flex: 1;
}

/* Navbar */
/* .navbar {
  background-color: #003366;
  transition: box-shadow 0.3s ease;
} */

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: #003366;
  color: white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

main,
.hero-section,
.post-container,
.categories-grid
{
  margin-top: 50px; /* Adjust based on your navbar height */
}

.recommended-section {
  margin-top: 0px; /* Adjust based on your navbar height */
}

.container {
  max-width: 1200px;
  margin: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  position: relative;
  flex-wrap: wrap; /* Add this for responsiveness */
}
/* Nav Toggle */
.nav-toggle {
  display: none;
  font-size: 1.8rem;
  color: white;
  cursor: pointer;
}

/* Nav Links */
.nav-links {
  list-style: none;
  display: flex;
  gap: 1rem;
  align-items: center;
}

.nav-links li a {
  color: white;
  text-decoration: none;
  padding: 0.5rem;
  transition: background 0.3s ease;
}

.nav-links li a:hover {
  background-color: #005599;
  border-radius: 4px;
}

/* Hero Section */
.hero {
  text-align: center;
  padding: 4rem 2rem;
  background-color: #e8f0fe;
}

.hero h1 {
  font-size: 2.5rem;
  color: #003366;
}

.hero p {
  margin-top: 0.5rem;
  font-size: 1.2rem;
}

/* Footer */
footer {
  background-color: #003366;
  color: white;
  text-align: center;
  padding: 1rem;
  margin-top: auto;
}


/* ==================================== CATEGORIES SECTION. ==================================== */
/* Categories Grid Section */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  padding: 3rem 2rem;
  max-width: 1200px;
  margin: auto;
}

/* Individual Category Card */
.category-card {
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 2rem 1rem;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.category-card a {
  text-decoration: none;
  color: #003366;
  font-size: 1.1rem;
  font-weight: bold;
}

.category-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

/* Blog Post CSS. */

/* .post-container {
  max-width: 800px;
  margin: 8rem auto;
  padding: 2rem;
  background: #fff;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
}

.blog-post h1.post-title {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.post-meta {
  color: #777;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.post-image {
  width: 100%;
  height: 350px;
  object-fit: fill;
  border-radius: 8px;
  margin: 1rem 0;
}

.post-content h2 {
  margin-top: 1.5rem;
  color: #003366;
}

.post-content p {
  margin-bottom: 1rem;
  line-height: 1.7;
} */


/* Blog Post CSS - Responsive */

/* Main container */
.post-container {
  max-width: 800px;
  margin: 8rem auto;
  padding: 2rem;
  background: #fff;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
}

/* Title */
.blog-post h1.post-title {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

/* Meta info */
.post-meta {
  color: #777;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

/* Post image */
.post-image {
  width: 100%;
  height: auto; /* Let image height adjust naturally */
  max-height: 450px;
  object-fit: cover;
  border-radius: 8px;
  margin: 1rem 0;
}

/* Section headings */
.post-content h2 {
  margin-top: 1.5rem;
  color: #003366;
}

/* Paragraph text */
.post-content p {
  margin-bottom: 1rem;
  line-height: 1.7;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .post-container {
    margin: 4rem 1rem;
    padding: 1.5rem;
  }
  .blog-post h1.post-title {
    font-size: 1.6rem;
  }
  .post-meta {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .post-container {
    margin: 5rem 0.5rem;
    padding: 1rem;
  }
  .blog-post h1.post-title {
    font-size: 1.4rem;
  }
  .post-meta {
    font-size: 0.8rem;
  }
  .post-content p {
    font-size: 0.95rem;
  }
}


/* RECOMMENDED BLOGS CSS. */
/* Recommended Blogs Section */
.recommended-section {
  padding: 60px 40px;
  background-color: #f8f8f8;
}

.recommended-section h2 {
  display: block;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
  font-size: 2rem;
  margin-bottom: 40px;
  color: #003366;
}

.recommended-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.recommended-card {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  transition: transform 0.2s ease;
  text-align: center;
}

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

.recommended-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.recommended-card .card-body {
  padding: 15px;
}

.recommended-card h3 {
  font-size: 1.2rem;
  margin: 0 0 10px;
  color: #003366;
}

.recommended-card p {
  font-size: 0.95rem;
  color: #333;
  line-height: 1.4;
}


/* Responsive Styles */

@media (max-width: 768px) {
  .nav-links {
    flex-wrap: nowrap;
  }

  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    align-items: center;
    background-color: #003366;
    width: 100%;
    position: absolute;
    top: 100%;
    right: 0;
    z-index: 1000;
    padding: 1rem 0;
  }

  .nav-links.show {
    display: flex;
  }

  .nav-links li {
    width: 100%;
    text-align: center;
  }

  .nav-links li a {
    display: block;
    width: 100%;
  }

  .categories-grid {
    padding: 2rem 1rem;
    gap: 1rem;
  }

  /* Responsive adjustments for recommended section */
  .recommended-grid {
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.recommended-card img {
  height: 180px;
}
}
