/* Base Styles */
:root {
  --primary-color: #4caf50;
  --primary-dark: #388e3c;
  --primary-light: #a5d6a7;
  --secondary-color: #2196f3;
  --text-color: #333333;
  --text-light: #666666;
  --background-color: #ffffff;
  --background-alt: #f9f9f9;
  --border-color: #e0e0e0;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Poppins", sans-serif;
  color: var(--text-color);
  line-height: 1.6;
  background-color: var(--background-color);
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  text-decoration: none;
  color: var(--primary-color);
  transition: var(--transition);
}

a:hover {
  color: var(--primary-dark);
}

.btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 30px;
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.primary-btn {
  background-color: var(--primary-color);
  color: white;
}

.primary-btn:hover {
  background-color: var(--primary-dark);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.secondary-btn {
  background-color: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.secondary-btn:hover {
  background-color: var(--primary-color);
  color: white;
}

.section-title {
  text-align: center;
  margin-bottom: 40px;
  font-size: 2.5rem;
  font-weight: 600;
  position: relative;
  padding-bottom: 15px;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: var(--primary-color);
  border-radius: 2px;
}

/* Header Styles */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: var(--background-color);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  padding: 15px 0;
  transition: var(--transition);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo h1 {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--primary-color);
}

.main-nav .nav-list {
  display: flex;
  list-style: none;
}

.main-nav .nav-list li {
  margin-left: 30px;
}

.main-nav .nav-list a {
  color: var(--text-color);
  font-weight: 500;
  position: relative;
  padding-bottom: 5px;
}

.main-nav .nav-list a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary-color);
  transition: var(--transition);
}

.main-nav .nav-list a:hover::after,
.main-nav .nav-list a.active::after {
  width: 100%;
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
}

.mobile-menu-toggle span {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--text-color);
  margin: 5px 0;
  transition: var(--transition);
}

/* Hero Section */
.hero {
  padding: 150px 0 80px;
  background-color: var(--background-alt);
}

.hero-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.hero-text {
  flex: 1;
  padding-right: 40px;
}

.hero-text h2 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--primary-color);
}

.hero-text p {
  font-size: 1.2rem;
  margin-bottom: 30px;
  color: var(--text-light);
}

.hero-image {
  flex: 1;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

/* Featured Posts Section */
.featured-posts {
  padding: 80px 0;
}

.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 30px;
}

.post-card {
  background-color: var(--background-color);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.post-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.post-image {
  height: 200px;
  overflow: hidden;
}

.post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.post-card:hover .post-image img {
  transform: scale(1.05);
}

.post-content {
  padding: 20px;
}

.post-category {
  display: inline-block;
  background-color: var(--primary-light);
  color: var(--primary-dark);
  padding: 5px 10px;
  border-radius: 20px;
  font-size: 0.8rem;
  margin-bottom: 10px;
}

.post-content h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
  font-weight: 600;
}

.post-content p {
  color: var(--text-light);
  margin-bottom: 15px;
}

.read-more {
  font-weight: 500;
  display: inline-flex;
  align-items: center;
}

.read-more::after {
  content: "→";
  margin-left: 5px;
  transition: var(--transition);
}

.read-more:hover::after {
  margin-left: 10px;
}

/* Newsletter Section */
.newsletter {
  padding: 80px 0;
  background-color: var(--primary-color);
  color: white;
}

.newsletter-content {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

.newsletter-content h2 {
  font-size: 2.5rem;
  margin-bottom: 20px;
}

.newsletter-content p {
  margin-bottom: 30px;
  font-size: 1.1rem;
}

.newsletter-form {
  display: flex;
  max-width: 500px;
  margin: 0 auto;
}

.newsletter-form input {
  flex: 1;
  padding: 15px 20px;
  border: none;
  border-radius: 30px 0 0 30px;
  font-family: "Poppins", sans-serif;
  font-size: 1rem;
}

.newsletter-form button {
  border-radius: 0 30px 30px 0;
  background-color: var(--secondary-color);
  padding: 0 25px;
}

.newsletter-form button:hover {
  background-color: #1976d2;
}

/* Categories Section */
.categories {
  padding: 80px 0;
  background-color: var(--background-alt);
}

.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 30px;
}

.category-card {
  background-color: var(--background-color);
  border-radius: 10px;
  padding: 30px;
  text-align: center;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.category-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.category-icon {
  margin-bottom: 20px;
  display: flex;
  justify-content: center;
}

.category-icon img {
  width: 64px;
  height: 64px;
}

.category-card h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
  font-weight: 600;
}

.category-card p {
  color: var(--text-light);
  margin-bottom: 20px;
}

/* Footer Styles */
.footer {
  background-color: #333;
  color: white;
  padding: 80px 0 20px;
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr 2fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-logo h2 {
  font-size: 1.8rem;
  margin-bottom: 10px;
  color: var(--primary-light);
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.footer-column h3 {
  font-size: 1.2rem;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.footer-column h3::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background-color: var(--primary-color);
}

.footer-column ul {
  list-style: none;
}

.footer-column ul li {
  margin-bottom: 10px;
}

.footer-column ul li a {
  color: #ccc;
  transition: var(--transition);
}

.footer-column ul li a:hover {
  color: var(--primary-light);
  padding-left: 5px;
}

.footer-social h3 {
  font-size: 1.2rem;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.footer-social h3::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background-color: var(--primary-color);
}

.social-icons {
  display: flex;
  gap: 15px;
}

.social-icons a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  color: white;
  transition: var(--transition);
}

.social-icons a:hover {
  background-color: var(--primary-color);
  transform: translateY(-5px);
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeIn 0.8s forwards;
}

.delay-1 {
  animation-delay: 0.2s;
}

.delay-2 {
  animation-delay: 0.4s;
}

.delay-3 {
  animation-delay: 0.6s;
}

.delay-4 {
  animation-delay: 0.8s;
}

.delay-5 {
  animation-delay: 1s;
}

@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive Styles */
@media (max-width: 992px) {
  .hero-content {
    flex-direction: column;
  }

  .hero-text {
    padding-right: 0;
    margin-bottom: 40px;
    text-align: center;
  }

  .footer-content {
    grid-template-columns: 1fr;
  }

  .footer-links {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .mobile-menu-toggle {
    display: block;
  }

  .main-nav .nav-list {
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    background-color: var(--background-color);
    flex-direction: column;
    align-items: center;
    padding: 20px 0;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    transform: translateY(-150%);
    transition: var(--transition);
  }

  .main-nav .nav-list.active {
    transform: translateY(0);
  }

  .main-nav .nav-list li {
    margin: 15px 0;
  }

  .newsletter-form {
    flex-direction: column;
  }

  .newsletter-form input {
    border-radius: 30px;
    margin-bottom: 10px;
  }

  .newsletter-form button {
    border-radius: 30px;
  }

  .posts-grid {
    grid-template-columns: 1fr;
  }

  .categories-grid {
    grid-template-columns: 1fr;
  }

  .footer-links {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 576px) {
  .hero-text h2 {
    font-size: 2.2rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .post-card {
    margin-bottom: 20px;
  }

  .footer-logo,
  .footer-column,
  .footer-social {
    text-align: center;
  }

  .footer-column h3::after,
  .footer-social h3::after {
    left: 50%;
    transform: translateX(-50%);
  }
}
