/* General */
body {
  min-height: 100vh;
  background-color: #f8f9f6;
  margin: 0;
  padding: 0;
  font-family: Arial, sans-serif;
}

/* Hero Section */
.hero-section {
  position: relative;
  height: 500px;
}
.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(75%);
}
.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  padding: 16px;
  text-align: center;
}
.hero-title {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 16px;
}
@media (min-width: 768px) {
  .hero-title {
    font-size: 48px;
  }
}
.hero-description {
  font-size: 20px;
  max-width: 672px;
  margin-bottom: 24px;
}
.search-container {
  position: relative;
  width: 100%;
  max-width: 448px;
}
.search-input {
  padding-left: 40px;
  padding-right: 16px;
  padding-top: 24px;
  padding-bottom: 24px;
  border-radius: 9999px;
  color: black;
  width: 100%;
  border: none;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #6b7280;
}

/* Categories Section */
.categories-section {
  padding-top: 32px;
  padding-bottom: 32px;
  background-color: white;
}
.container {
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 16px;
  padding-right: 16px;
}
.button-group {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}
.category-button {
  border-radius: 9999px;
  padding: 8px 16px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}
.category-button.active {
  background-color: #2c6e49;
  color: white;
  border: 1px solid #2c6e49;
}
.category-button.active:hover {
  background-color: #214e36;
}
.category-button:not(.active) {
  border: 1px solid #2c6e49;
  color: #2c6e49;
  background-color: transparent;
}
.category-button:not(.active):hover {
  background-color: #e9f5db;
}
.button-icon {
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 8px;
  vertical-align: middle;
}
.category-button a {
  text-decoration: none;
}

/* Featured News Section */
.featured-news-section {
  padding-top: 48px;
  padding-bottom: 48px;
  background-color: #f8f9f6;
}
.section-title {
  font-size: 30px;
  font-weight: 700;
  margin-bottom: 32px;
  display: flex;
  align-items: center;
}
.title-icon {
  width: 24px;
  height: 24px;
  margin-right: 8px;
  color: #2c6e49;
}
.news-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}
@media (min-width: 1024px) {
  .news-grid {
    grid-template-columns: 1fr 1fr;
  }
}
.main-card {
  overflow: hidden;
  border: none;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  background-color: white;
  border-radius: 8px;
}
.card-image-container {
  position: relative;
  height: 320px;
}
.card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.badge {
  position: absolute;
  top: 16px;
  left: 16px;
  background-color: #2c6e49;
  color: white;
  padding: 4px 8px;
  font-size: 12px;
  border-radius: 4px;
}
.card-header {
  padding: 16px;
}
.card-title {
  font-size: 24px;
  font-weight: 700;
  transition: color 0.2s;
}
.card-title a {
  text-decoration: none;
  color: inherit;
}
.card-title:hover {
  color: #2c6e49;
  cursor: pointer;
}
.card-content {
  padding: 16px;
}
.card-content p {
  color: #4b5563;
  margin-bottom: 16px;
}
.card-meta {
  display: flex;
  align-items: center;
  font-size: 14px;
  color: #6b7280;
}
.card-meta span {
  margin-right: 16px;
}
.card-footer {
  padding: 16px;
}
.read-more-button {
  background-color: #2c6e49;
  color: white;
  padding: 8px 16px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s;
  display: flex;
  align-items: center;
}
.read-more-button a {
  text-decoration: none;
  color: white;
}
.read-more-button:hover {
  background-color: #214e36;
}
.read-more-button:hover a {
  text-decoration: none;
  color: white;
}
.side-cards {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.side-card {
  overflow: hidden;
  border: none;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  background-color: white;
  border-radius: 8px;
}
.side-card-wrapper {
  display: flex;
  flex-direction: column;
}
@media (min-width: 768px) {
  .side-card-wrapper {
    flex-direction: row;
  }
}
.side-card-image-container {
  width: 100%;
}
@media (min-width: 768px) {
  .side-card-image-container {
    width: 33.333%;
  }
}
.side-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.side-card-content {
  padding: 16px;
}
@media (min-width: 768px) {
  .side-card-content {
    width: 66.667%;
  }
}
.side-card-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  transition: color 0.2s;
}
.side-card-title a {
  text-decoration: none;
  color: inherit;
}
.side-card-title:hover {
  color: #2c6e49;
  cursor: pointer;
}
.side-card-content p {
  color: #4b5563;
  font-size: 14px;
  margin-bottom: 8px;
}
.side-card-meta {
  display: flex;
  align-items: center;
  font-size: 12px;
  color: #6b7280;
}
.side-card-meta span {
  margin-right: 16px;
}
.side-card-meta .badge {
  position: static;
  border: 1px solid #2c6e49;
  color: #2c6e49;
  background: none;
}

/* Latest News Section */
.latest-news-section {
  padding-top: 48px;
  padding-bottom: 48px;
  background-color: white;
}
.latest-news-section .news-grid {
  grid-template-columns: repeat(1, 1fr);
}
@media (min-width: 640px) {
  .latest-news-section .news-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1024px) {
  .latest-news-section .news-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
.news-card {
  overflow: hidden;
  border: none;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: box-shadow 0.2s;
  background-color: white;
  border-radius: 8px;
}
.news-card:hover {
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}
.news-card .badge {
  bottom: 8px;
  right: 8px;
  top: auto;
  left: auto;
}
.news-card .card-title {
  font-size: 18px;
}
.news-card .card-content p {
  font-size: 14px;
}
.news-card .card-meta {
  font-size: 12px;
  justify-content: space-between;
}
.news-card .read-more-button {
  background: none;
  color: #2c6e49;
  padding: 0;
}
.news-card .read-more-button a {
  color: #2c6e49;
}
.news-card .read-more-button:hover {
  color: #214e36;
}
.load-more-container {
  display: flex;
  justify-content: center;
  margin-top: 40px;
}
.load-more-button {
  background-color: #2c6e49;
  color: white;
  padding: 8px 16px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s;
}
.load-more-button:hover {
  background-color: #214e36;
}

/* Newsletter Section */
.newsletter-section {
  padding-top: 64px;
  padding-bottom: 64px;
  background-color: #e9f5db;
}
.newsletter-section .section-title {
  text-align: center;
  justify-content: center;
}
.section-description {
  color: #4b5563;
  max-width: 672px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 32px;
  text-align: center;
}
.form-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 448px;
  margin-left: auto;
  margin-right: auto;
}
@media (min-width: 640px) {
  .form-container {
    flex-direction: row;
  }
}
.form-input {
  flex-grow: 1;
  padding: 8px 16px;
  border-radius: 4px;
  border: 1px solid #ddd;
}
.form-button {
  background-color: #2c6e49;
  color: white;
  padding: 8px 16px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s;
}
.form-button:hover {
  background-color: #214e36;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  /* Tablet and Desktop styles for header menu */
  .menu {
    gap: 30px; /* Adjust gap for larger screens */
  }
}
@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  /* Ensure gap is 30px on desktop */
  .menu {
    gap: 30px;
  }
}
.branding-container {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}
.branding-icon {
  width: 24px;
  height: 24px;
}
.branding-text {
  font-size: 20px;
  font-weight: 700;
}
.branding-description {
  color: #e9f5db;
  margin-bottom: 16px;
}
.social-container {
  display: flex;
  gap: 16px;
}
.social-button {
  background: none;
  color: white;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
}
.social-button:hover {
  color: #e9f5db;
  background-color: #214e36;
}
.links-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 16px;
}
.links-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  list-style-type: none;
  padding: 0;
  margin: 0;
}
.link-item {
  color: white;
  text-decoration: none;
  transition: color 0.2s;
}
.link-item:hover {
  color: #e9f5db;
}
.contact-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 16px;
}
.contact-address {
  font-style: normal;
}
.address-item {
  margin-bottom: 8px;
}
.copyright {
  border-top: 1px solid #4d8b6c;
  margin-top: 32px;
  padding-top: 32px;
  text-align: center;
  color: #e9f5db;
}
@media (max-width: 768px) {
  /* Responsive header and menu - copied from trangchu.css mobile styles */
  .navbar {
    flex-direction: row;
    align-items: center;
    padding: 10px;
    justify-content: space-between;
    flex-wrap: nowrap;
    padding: 10px 50px !important;
    margin-left: -30px;
  }

  .hero-section .search-input{
    box-sizing: border-box;
  }

  .branding-container{
    margin-left: -10px !important;
  }

  .login-link{
    margin-right: 16px !important;
  }

  .menu-toggle {
    display: flex;
    margin-right: 10px;
    padding-left: 10px;
  }

  .menu {
    width: 100%;
    flex-direction: column;
    align-items: center;
    padding-top: 0;
    position: absolute;
    top: 100%;
    background-color: #2c6e49;
    gap: 0;
  }

  .menu a {
    font-size: 16px;
    padding: 10px 20px;
    width: 100%;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .menu a:last-child {
    border-bottom: none;
  }

  /* .branding-text {
    font-size: 18px;
  } */

  .branding-container {
    flex-shrink: 0;
  }

  /* Responsive hero section */
  .hero-section {
    height: auto;
    padding: 20px 10px;
  }

  .hero-overlay {
    padding: 10px;
  }

  .hero-title {
    font-size: 28px;
    margin-bottom: 10px;
  }

  .hero-description {
    font-size: 16px;
    margin-bottom: 15px;
  }

  .search-container {
    max-width: 95%;
  }

  .search-input {
    padding: 12px 15px 12px 40px;
    font-size: 14px;
  }

  .search-icon {
    left: 15px;
  }

  /* Responsive categories section */
  .categories-section {
    padding: 20px 10px;
  }

  .button-group {
    gap: 10px;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 10px;
  }

  .button-group::-webkit-scrollbar {
    display: none;
  }

  .category-button {
    flex-shrink: 0;
    padding: 6px 12px;
    font-size: 14px;
  }

  /* Responsive news sections */
  .featured-news-section,
  .latest-news-section {
    padding: 20px 10px;
  }

  .section-title {
    font-size: 22px;
    margin-bottom: 15px;
  }

  .news-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .main-card,
  .news-card,
  .side-card {
    margin-bottom: 15px;
  }

  .card-image-container {
    height: 180px;
  }

  .card-image {
    height: 100%;
    object-fit: cover;
  }

  .card-header {
    padding: 10px 15px 0;
  }

  .card-title {
    font-size: 18px;
    margin-bottom: 5px;
  }

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

  .card-content p {
    font-size: 14px;
    line-height: 1.4;
    margin-bottom: 10px;
  }

  .card-meta {
    font-size: 12px;
  }

  .read-more-button {
    font-size: 13px;
    padding: 6px 10px;
  }

  .side-card-wrapper {
    flex-direction: column;
    gap: 10px;
  }

  .side-card-image-container {
    width: 100%;
    height: 150px;
  }

  .side-card-content {
    padding: 0 15px;
  }

  .side-card-title {
    font-size: 16px;
    margin-bottom: 5px;
  }

  .side-card-content p {
    font-size: 13px;
    margin-bottom: 5px;
  }

  .side-card-meta {
    font-size: 11px;
  }

  /* Responsive newsletter section */
  .newsletter-section {
    padding: 20px 10px;
  }

  .section-description {
    font-size: 14px;
    margin-bottom: 15px;
  }

  .form-container {
    flex-direction: column;
    gap: 10px;
  }

  .form-input {
    padding: 10px;
    font-size: 14px;
  }

  .form-button {
    padding: 10px;
    font-size: 14px;
  }

  /* Responsive footer - copied from trangchu.css mobile styles */
  .footer-section {
    padding: 20px 15px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .links,
  .branding {
    padding: 0 10px;
    text-align: left;
  }

  .links-title {
    text-align: left;
    font-size: 16px;
    margin-bottom: 12px;
  }

  .links-list {
    text-align: left;
  }

  .social-container {
    justify-content: flex-start;
  }

  .branding-text {
    font-size: 16px;
  }

  .branding-description {
    font-size: 14px;
    margin: 10px 0;
  }

  .social-button {
    width: 35px;
    height: 35px;
  }

  .copyright {
    font-size: 12px;
    margin-top: 20px;
    padding-top: 15px;
  }
}

/* Tablet styles */
@media (min-width: 769px) and (max-width: 1024px) {
  /* Tablet styles for news sections */
  .featured-news-section .news-grid {
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }

  .latest-news-section .news-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .main-card {
    grid-column: span 1;
  }

  .side-cards {
    grid-column: span 1;
  }

  .side-card-wrapper {
    flex-direction: row;
    gap: 15px;
  }

  .side-card-image-container {
    width: 120px;
    height: 120px;
  }

  .side-card-content {
    padding: 0;
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
  }
}

/* Desktop styles */
@media (min-width: 1025px) {
  /* Desktop styles for news sections */
  .featured-news-section .news-grid {
    grid-template-columns: 2fr 1fr;
    gap: 30px;
  }

  .latest-news-section .news-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
  }

  .main-card {
    grid-column: span 2;
  }

  .side-cards {
    grid-column: span 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
  }

  .side-card {
    margin-bottom: 0;
  }

  .side-card-wrapper {
    flex-direction: row;
    gap: 15px;
  }

  .side-card-image-container {
    width: 100px;
    height: 100px;
  }

  .side-card-content {
    padding: 0;
  }

  .footer-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
  }
}
