/* main.css */

/*
  Primary color scheme:
  - Text color: #a95e13
  - Background color: #F8F2E9

*/

/* 1. Body text color */
body {
  color: #a95e13;
  line-height: 1.6;
}

/* 2. Header & Navigation */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  /* Background color matches the primary color scheme */
  background: #f8f2e9;
  position: relative;
}

/* Branding / Logo */
.logo-brand a {
  font-size: 1.5rem;
  font-weight: 700;
  color: #a95e13;
}

/* 1. Hide hamburger by default on desktop, show for mobile */
.hamburger {
  display: none; /* hidden on desktop */
  cursor: pointer;
  position: relative;
  width: 40px;
  height: 40px;
}
.hamburger {
  margin-left: auto !important; /* pushes it to the right if parent is flex */
  margin-right: 0 !important; /* add some blank space on the right */
}
@media (max-width: 768px) {
  .hamburger {
    display: block; /* show on mobile */
  }
}

/* 2. Basic lines for the hamburger */
.hamburger-lines {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 25px;
  height: 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.line {
  width: 25px;
  height: 2px;
  background-color: #a95e13;
  transition: all 0.3s ease;
  border-radius: 1px;
}

/* 3. Animate into "X" when active */
.hamburger.active .line1 {
  transform: translateY(8px) rotate(45deg);
}
.hamburger.active .line2 {
  opacity: 0;
}
.hamburger.active .line3 {
  transform: translateY(-8px) rotate(-45deg);
}

/* 4. Navigation baseline (MOBILE hidden by default) */
.main-nav ul {
  position: absolute;
  top: 70px;
  right: 1rem;
  width: 150px;
  background: #f8f2e9;
  border: 1px solid #f8f2e9;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);

  /* Start off-screen to the right and invisible */
  transform: translateX(100%); /* slides in from right */
  opacity: 0;
  pointer-events: none;
  transition: transform 0.3s ease, opacity 0.3s ease;

  position: absolute;
  top: 70px;
  right: 1rem;
  width: 150px;
  background: #f8f2e9;
  border: 1px solid #f8f2e9;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
  flex-direction: column;
  visibility: hidden; /* optional, if you want to hide visually off-screen */
}

/* When .show-nav is toggled, slide in from the right */
.main-nav.show-nav ul {
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Child items */
.main-nav ul li {
  margin: 1rem;
}
.main-nav ul li a {
  color: #a95e13;
  text-decoration: none;
}

/* 5. Desktop override (769px and above) */
@media (min-width: 769px) {
  .hamburger {
    display: none !important;
  }
  .main-nav ul {
    position: static;
    transform: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    box-shadow: none;
    display: flex;
    flex-direction: row;
    gap: 1rem;
    margin: 0;
    width: auto;
  }
}

/* 3. Hero Section */
.hero-section {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;

  /* Use a background image, adjusting path as needed: */
  background: url("../images/main_bg.jpeg") center center / cover no-repeat;

  text-align: center;
  color: #a95e13; /* If your image is bright, you might darken text */
}

.hero-content h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}
.hero-content p {
  margin-bottom: 1rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
.btn-cta {
  display: inline-block;
  background: #a95e13;
  color: #f8f2e9;
  padding: 0.75rem 1.5rem;
  border-radius: 4px;
  transition: background 0.2s;
}
.btn-cta:hover {
  background: #814610;
  color: #f8f2e9;
}

/* 4. Generic Section Styling */
.section {
  padding: 3rem 2rem;
  max-width: 1000px;
  margin: 0 auto;
}
.section h2 {
  font-size: 1.75rem;
  margin-bottom: 1rem;
  position: relative;
}
.section h2::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background: #a95e13;
  margin-top: 0.5rem;
}
/* If your "Read More" buttons or links have a class .read-more, or you can simply style your inline <a>:
   e.g., for "Read more" links in sections: */
.section a,
.read-more {
  color: #a95e13;
  text-decoration: underline;
  transition: color 0.2s;
}

.section a:hover,
.read-more:hover {
  color: #814610;
}

/* Profile Image */
.profile-pic {
  max-width: 200px;
  border-radius: 50%;
  margin-top: 1rem;
}

/* 5. Blog Section */
.blog-section {
  background: #f8f2e9;
  border-radius: 5px;
  padding: 2rem;
  margin-top: 2rem;
}
.blog-preview {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}
.blog-preview article {
  background: #f8f2e9;
  padding: 1rem;
  border-radius: 5px;
}
.blog-preview article h3 {
  margin-bottom: 0.5rem;
}
.blog-preview article a {
  color: #a95e13;
  text-decoration: underline;
}
.blog-preview article a:hover {
  color: #814610;
}

/* 6. Contact Section */
.contact-section {
  background: #f8f2e9;
  border-radius: 5px;
  padding: 2rem;
  margin-top: 2rem;
}

/* 7. Footer */
.site-footer {
  text-align: center;
  background: #f8f2e9;
  padding: 1rem;
  border-top: 1px solid #f8f2e9;
}
.site-footer p {
  color: #a95e13;
}

/* 8. Responsive Media Query */
@media (max-width: 768px) {
  .main-nav ul {
    flex-direction: column;
    position: absolute;
    top: 70px;
    right: 2rem;
    background-color: #f8f2e9;
    width: 150px;
    border: 1px solid #f8f2e9;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    max-height: 0; /* collapsed by default */
    overflow: hidden;
  }
  .main-nav.show-nav ul {
    max-height: 300px; /* expands when toggled */
  }

  .hamburger {
    display: flex;
  }

  .hero-content h1 {
    font-size: 2rem;
  }

  .blog-preview {
    grid-template-columns: 1fr;
  }
}
