/* Root colors */
:root {
  --ff: 'Inter', sans-serif;
  --ff-heading: 'Montserrat', sans-serif;
  
  /* Typography Variables */
  --h1: bold max(36px, 4vw) / max(48px, 5vw) var(--ff-heading);
  --h2: 700 2rem / 2.5rem var(--ff-heading);
  --h3: 700 1.5rem / 2rem var(--ff-heading);
  --h4: 700 1.25rem / 1.75rem var(--ff-heading);
  --h5: 700 1.1rem / 1.5rem var(--ff-heading);
  --h6: 700 1rem / 1.5rem var(--ff-heading);
  --p: 400 1rem / 1.6 var(--ff);
  
  --color-primary: #68a691;
  --color-secondary: #bfd3c1;
  --color-accent1: #ffe5d4;
  --color-accent2: #efc7c2;
  --color-white: #ffffff;
  --color-black: #000000;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadowdark: 0 2px 12px rgba(0, 0, 0, 0.3);
}

/* Dark Mode */
body.dark-mode {
  --color-primary: #4a7c6f;
  --color-secondary: #2d3d39;
  --color-accent1: #d9a574;
  --color-accent2: #c9897d;
  --color-white: #1a1a1a;
  --color-black: #e0e0e0;
}

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

html {
  scroll-behavior: smooth;
}

.section {
  scroll-snap-align: start;
}

body {
  font-family: var(--ff);
  background-color: var(--color-white);
  color: var(--color-black);
  line-height: 1.6;
  transition: background-color 0.3s ease, color 0.3s ease;
}

h1 {
  font: var(--h1);
}

h2 {
  font: var(--h2);
}

h3 {
  font: var(--h3);
}

h4 {
  font: var(--h4);
}

h5 {
  font: var(--h5);
}

h6 {
  font: var(--h6);
}

p {
  font: var(--p);
}
img {
  max-width: 100%;
  height: auto;
}
@font-face {
  font-family: 'Font Awesome 6 Free';
  font-display: swap;
  src: local('Font Awesome 6 Free');
}

@font-face {
  font-family: 'Font Awesome 6 Brands';
  font-display: swap;
  src: local('Font Awesome 6 Brands');
}
#journal {
  min-height: 800px; /* Adjust this based on how tall your blog section usually is */
}
/* ========== NAVBAR ========== */
.navbar {
  background-color: var(--color-primary);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-white);
  text-decoration: none;
  transition: opacity 0.3s ease;
}

.nav-logo:hover {
  opacity: 0.8;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav-item {
  margin: 0;
}

.nav-link {
  color: var(--color-white);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-accent1);
}

/* Dark Mode Toggle Button */
.dark-mode-toggle {
  background: none;
  border: 2px solid var(--color-white);
  color: var(--color-white);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  padding: 0;
}

.dark-mode-toggle:hover {
  background-color: rgba(255, 255, 255, 0.1);
  transform: scale(1.1);
}

.mode-icon {
  transition: transform 0.3s ease;
}



/* Hamburger Menu */
.hamburger-menu {
  display: none;
  flex-direction: column;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  gap: 5px;
}

.hamburger-menu span {
  width: 25px;
  height: 3px;
  background-color: var(--color-white);
  border-radius: 2px;
  transition: all 0.3s ease;
}

.hamburger-menu:hover span {
  background-color: var(--color-accent1);
}

.hamburger-menu.active span:nth-child(1) {
  transform: rotate(45deg) translate(8px, 8px);
}

.hamburger-menu.active span:nth-child(2) {
  opacity: 0;
}

.hamburger-menu.active span:nth-child(3) {
  transform: rotate(-45deg) translate(8px, -8px);
}

/* ========== HERO SECTION ========== */
.hero {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  padding: 8rem 2rem;
  text-align: center;
  color: var(--color-white);
  transition: background 0.3s ease;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-title {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.hero-subtitle {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  opacity: 0.95;
}

.hero-btn {
  background-color: var(--color-accent1);
  color: var(--color-black);
  border: none;
  padding: 0.75rem 2rem;
  font-size: 1rem;
  border-radius: 50px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease;
}

.hero-btn:hover {
  background-color: var(--color-accent2);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* ========== BLOG POSTS SECTION ========== */
.blog-posts {
  padding: 4rem 2rem;
  background-color: var(--color-white);
}

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

.blog-title {
  font-size: 2.5rem;
  text-align: center;
  margin-bottom: 3rem;
  color: var(--color-primary);
}

.blog-cards {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
  margin-top: 40px;
}

.blog-cards > * {
  flex: 1;
  min-width: 200px;
}

.blog-card {
  background-color: var(--color-secondary);
  box-shadow: var(--shadow);
  border-radius: 10px;
  padding: 20px 28px 40px 28px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.blog-card.dark-shadow {
  box-shadow: var(--shadowdark);
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadowdark);
}

.card-image {
  width: calc(100% + 56px);
  height: 200px;
  object-fit: cover;
  background-color: var(--color-secondary);
  margin: -20px -28px 20px -28px;
}

.card-content {
  padding: 20px 28px 40px 28px;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 0.5rem;
}

.card-description {
  color: var(--color-black);
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.card-link {
  display: inline-block;
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  padding-bottom: 0.25rem;
  border-bottom: 2px solid transparent;
}

.card-link:hover {
  color: var(--color-accent2);
  border-bottom-color: var(--color-accent2);
}

/* ========== NEWSLETTER SECTION ========== */
.newsletter {
  background-color: var(--color-accent1);
  padding: 4rem 2rem;
  transition: background-color 0.3s ease;
}

.newsletter-container {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.newsletter-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-black);
  margin-bottom: 1rem;
}

.newsletter-description {
  color: var(--color-black);
  margin-bottom: 2rem;
  font-size: 0.95rem;
  line-height: 1.8;
}

.newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-input {
  padding: 0.75rem 1rem;
  border: 2px solid var(--color-secondary);
  border-radius: 6px;
  font-family: var(--ff);
  font-size: 1rem;
  background-color: var(--color-white);
  color: var(--color-black);
  transition: border-color 0.3s ease, background-color 0.3s ease, color 0.3s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--color-primary);
}

.form-input::placeholder {
  color: #999;
}

.form-input.error {
  border-color: #ff6b6b;
  background-color: rgba(255, 107, 107, 0.05);
}

.form-input.valid {
  border-color: var(--color-primary);
}

.newsletter-btn {
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
  padding: 0.75rem 2rem;
  font-size: 1rem;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  font-family: var(--ff);
  transition: all 0.3s ease;
}

.newsletter-btn:hover {
  background-color: var(--color-secondary);
  color: var(--color-black);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* ========== FOOTER ========== */
.footer {
  background-color: var(--color-primary);
  color: var(--color-white);
  padding: 4rem 2rem;
  transition: background-color 0.3s ease, color 0.3s ease;
}

body.dark-mode .footer {
  background-color: #1a1a1a;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.footer-tagline {
  font-size: 1.25rem;
  font-weight: 500;
  margin: 0;
  letter-spacing: 0.5px;
}

body.dark-mode .footer-tagline {
  color: var(--color-accent2);
}

.heart {
  color: var(--color-accent2);
  display: inline-block;
  margin: 0 0.5rem;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin: 1rem 0;
}

.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  transition: all 0.3s ease;
  text-decoration: none;
  background-color: transparent;
}

.social-link:hover {
  border-color: var(--color-primary);
  transform: translateY(-3px);
}

.social-icon {
  font-size: 1.5rem;
  transition: transform 0.3s ease;
}

.social-link:hover .social-icon {
  transform: scale(1.2);
}

.footer-copyright {
  font-size: 0.95rem;
  font-weight: 400;
  margin: 0;
  letter-spacing: 0.3px;
  color: rgba(255, 255, 255, 0.9);
}

.admin-link {
  color: var(--color-primary); /* Same color as footer background = Invisible */
  background-color: transparent;
  text-decoration: none;
  font-size: 0.9rem;
  margin-top: 1.5rem;
  transition: color 0.3s ease;
  cursor: pointer;
  display: inline-block;
  border: none;
  padding: 0;
}

.admin-link:hover {
  color: var(--color-white); /* Show white text on hover */
  text-decoration: underline;
  background-color: transparent;
  border: none;
}

body.dark-mode .admin-link {
  color: #1a1a1a; /* Match footer background to stay invisible */
}

body.dark-mode .admin-link:hover {
  color: #e0e0e0; /* Show light text on hover */
}

/* Scroll to Top Button */
.scroll-top-btn {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 50px;
  height: 50px;
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
  transition: all 0.3s ease;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.scroll-top-btn:hover {
  background-color: var(--color-accent2);
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3);
}

/* Screen Reader Only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* ========== RESPONSIVE DESIGN ========== */
@media (max-width: 768px) {
  .hamburger-menu {
    display: flex;
  }

  .nav-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--color-primary);
    flex-direction: column;
    width: 100%;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding: 0;
  }

  .nav-menu.active {
    max-height: 300px;
    padding: 1rem 0;
  }

  .nav-item {
    text-align: center;
    padding: 0.75rem 0;
  }

  .nav-item a {
    display: block;
  }

  .nav-container {
    position: relative;
  }

  .hero {
    padding: 5rem 1rem;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .blog-posts {
    padding: 3rem 1rem;
  }

  .blog-title {
    font-size: 1.75rem;
    margin-bottom: 2rem;
  }

  .blog-cards {
    gap: 1.5rem;
    margin-top: 2rem;
  }

  .newsletter {
    padding: 3rem 1rem;
  }

  .newsletter-container {
    max-width: 100%;
  }

  .newsletter-form {
    flex-direction: column;
  }

  .footer {
    padding: 3rem 1rem;
  }

  .footer-container {
    gap: 1.5rem;
  }

  .footer-tagline {
    font-size: 1rem;
  }

  .social-links {
    gap: 1.5rem;
  }

  .social-link {
    width: 45px;
    height: 45px;
  }

  .social-icon {
    font-size: 1.2rem;
  }

  .footer-copyright {
    font-size: 0.85rem;
  }

  .admin-link {
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  /* Fix nav menu stacking */
  .nav-menu {
    position: absolute; /* Keep it absolute so it doesn't push content down */
    top: 100%;
    left: 0;
    right: 0;
    width: 100%;
    background-color: var(--color-primary);
    flex-direction: column;
    max-height: 0;
    overflow: hidden;
    padding: 0;
    /* Don't override gap or display unless active */
  }

  /* When active (toggled via JS), show it */
  .nav-menu.active {
    max-height: 300px;
    padding: 1rem 0;
    display: flex;
  }

  body {
    font-size: 14px;
  }

  .nav-container {
    padding: 0.75rem;
  }

  .nav-logo {
    font-size: 1rem;
  }

  /* Don't force column layout on nav-menu if not active */
  /* .nav-menu { flex-direction: column; gap: 0.5rem; width: 100%; } REMOVED THIS */

  .nav-item {
    text-align: center;
    padding: 0.5rem 0;
  }

  .hero {
    padding: 4rem 1rem; /* Slightly more padding so it's not cramped, but less than 8rem */
    min-height: auto; /* Remove any min-height if set */
  }

  .hero-title {
    font-size: 2rem; /* Reduce title size */
    margin-bottom: 0.5rem;
    line-height: 1.2;
  }

  .hero-subtitle {
    font-size: 1rem;
    margin-bottom: 1.5rem;
  }

  .hero-btn {
    padding: 0.6rem 1.5rem;
    font-size: 0.9rem;
  }
}

  .blog-posts {
    padding: 2rem 1rem;
  }

  .blog-title {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
  }

  .blog-cards {
    gap: 1rem;
  }

  .card-image {
    height: 150px;
  }

  .card-content {
    padding: 1rem;
  }

  .card-title {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
  }

  .card-description {
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
  }

  .card-link {
    font-size: 0.9rem;
  }

  .newsletter {
    padding: 2rem 1rem;
  }

  .newsletter-title {
    font-size: 1.5rem;
  }

  .newsletter-description {
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
  }

  .form-input {
    padding: 0.6rem 0.75rem;
    font-size: 0.9rem;
  }

  .newsletter-btn {
    padding: 0.6rem 1.5rem;
    font-size: 0.9rem;
  }

  .footer {
    padding: 2rem 1rem;
  }

  .footer-container {
    gap: 1rem;
  }

  .footer-tagline {
    font-size: 0.9rem;
  }

  .heart {
    margin: 0 0.3rem;
  }

  .social-links {
    gap: 1rem;
    margin: 0.75rem 0;
  }

  .social-link {
    width: 40px;
    height: 40px;
  }

  .social-icon {
    font-size: 1rem;
  }

  .footer-copyright {
    font-size: 0.75rem;
  }

  .scroll-top-btn {
    bottom: 1.5rem;
    right: 1.5rem;
    width: 45px;
    height: 45px;
    font-size: 1.2rem;
  }
