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

body {
  font-family: Georgia, "Helvetica Neue", Helvetica, Arial, sans-serif;
  background: #eef4fa;
  color: #333;
  line-height: 1.6;
}

/* HEADER (TOP SIDE) */
header.top-side {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  background: #001f3f;
  color: white;
  display: flex;
  justify-content: center; /* Desktop: centered. This will now also be the effective base for mobile. */
  align-items: center;
  gap: 100px; /* Desktop: gap. We'll adjust for mobile. */
  padding: 5px 30px 5px 15px; /* Desktop padding */
  z-index: 1000;
  transition: top 0.4s ease-in-out;
  will-change: top;
}

header.top-side .logo {
  display: flex;
  align-items: center;
  font-size: 1.8em;
  font-weight: bold;
  letter-spacing: 2px;
  margin-right: 60px; /* Desktop margin */
}

header.top-side .logo img {
  height: 100px;
  width: 100px;
  object-fit: cover;
  border-radius: 50%;
  margin-right: 15px;
  margin-top: 12.5px;
}

header.top-side nav ul {
  list-style: none;
  display: flex;
  margin: 0;
  padding: 0;
  margin-right: 15px;
}

header.top-side nav li {
  margin-left: 20px;
}

header.top-side nav a {
  color: white;
  text-decoration: none;
  font-weight: 500;
  font-size: 1em;
}

header.top-side nav a:hover {
  text-decoration: underline;
}

.menu-toggle {
  display: none; /* Shown in media query */
}

.menu-toggle::after {
  content: "☰";
}

.menu-toggle.active::after {
  content: "✕";
}

#menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.4);
  z-index: 999;
  display: none;
}

#menu-overlay.active {
  display: block;
}

/* HERO */
.hero {
  position: relative;
  overflow: hidden;
}

.hero-bg { /* Applies to the <img> inside <picture> */
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.hero.scroll-fade.show .hero-bg {
  opacity: 1;
  transform: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  color: white;
  text-align: center;
  padding: 200px 20px;
}

.hero-content h1 {
  text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.5);
  font-size: 3.5em; /* Desktop font size */
  font-family: 'Playfair Display', serif;
  font-weight: 500;
}

.hero-content p {
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.4);
  font-size: 1.5em; /* Desktop font size */
}


/* BLOG POSTS SECTION (Content of your Misyonumuz page) */
.blog-posts {max-width: 900px; margin: 80px auto; padding: 0 20px; display: flex; flex-direction: column; gap: 0px;}
.post {padding-top: 0px;}
.post p {
  font-size: 1.1em;
  line-height: 1.8;
  color: #333;
  margin-bottom: 20px;
  text-align: justify;
  font-family: Georgia, "Helvetica Neue", Helvetica, Arial, sans-serif;
}


/* SCROLL ANIMATION */
.scroll-fade {opacity: 0; transform: translateY(30px); transition: opacity 0.6s ease-out, transform 0.6s ease-out;}
.scroll-fade.show {opacity: 1; transform: none;}

/* FOOTER */
footer {background: #001f3f; color: white; text-align: center; padding: 20px 10px; font-size: 0.9em;}
footer a {color: #bbbbbb; text-decoration: none; margin: 0 5px;}
footer a:hover {color: white; text-decoration: underline;}

/* Close toggle global style */
.close-toggle {background: none; border: none; color: white; font-size: 2em; position: absolute; top: 20px; right: 20px; cursor: pointer; z-index: 1101; display: none;}


@media screen and (max-width: 768px) {
  /* === MOBILE HEADER STYLES === */
  header.top-side {
    /* display: flex; align-items: center; are inherited */
    /* justify-content: center; is inherited from desktop, which works with margin:auto on logo */
    padding: 5px 15px; /* Mobile padding */
    gap: 10px; /* Reduce desktop gap for mobile */
    z-index: 1002;
  }

  header.top-side .logo {
    margin-left: 0;
    margin-right: auto !important; /* MODIFIED: This pushes the logo left and other in-flow items right */
    /* Resetting desktop text-related styles if they were for .logo div itself */
    font-size: initial;
    font-weight: normal;
    letter-spacing: normal;
  }

  /* NO MOBILE-SPECIFIC STYLES FOR header.top-side .logo img */
  /* It will INHERIT desktop styles (height: 100px, margin-top: 12.5px, etc.)
     for the large, overflowing logo. */

  .nav-wrapper {
    /* This container for <nav> will be pushed to the right by the logo's auto margin.
       If .menu-toggle is now a direct child of header, .nav-wrapper only contains <nav> */
    /* display: flex; align-items: center; (No longer strictly needed for menu-toggle positioning) */
  }

  .menu-toggle { /* Assuming .menu-toggle is a DIRECT CHILD of header.top-side as per your Misyonumuz HTML */
    display: block !important;
    position: absolute !important; /* MODIFIED: Use absolute positioning */
    top: 50%;                   /* MODIFIED: Vertically center */
    transform: translateY(-50%);  /* MODIFIED: Adjust for exact vertical center */
    right: 15px;                /* MODIFIED: Position from right edge (match header padding) */
    font-size: 2em;
    color: white;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0; /* Remove any default padding */
    z-index: 1100; /* Above other header content, below nav panel when open if needed */
  }

  header.top-side nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 75%; /* Adjusted from the 80% in your "team page" CSS for consistency */
    height: 100vh;
    background-color: #001f3f;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 100px 20px 20px 30px;
    transition: right 0.3s ease-in-out;
    z-index: 1000; /* Below menu toggle */
  }

  header.top-side nav.active {
    right: 0;
  }

  header.top-side nav ul {
    flex-direction: column;
    width: 100%;
  }

  header.top-side nav li {
    margin: 15px 0;
    text-align: left;
    width: 100%;
  }

  header.top-side nav a {
    font-size: 1.2em;
    width: 100%;
    display: block;
    padding: 10px 0;
  }
  /* === END OF MOBILE HEADER STYLES === */


  /* === MOBILE HERO BACKGROUND IMAGE === */
  /* REMOVED object-position for .hero-bg as new mobile_mission.png via <picture> should be centered by default */
  /* If mobile_mission.png still needs specific positioning, a .hero-bg { object-position: ... } rule can be added here */
  /* === END OF MOBILE HERO BACKGROUND IMAGE === */


  /* Mobile hero text adjustments */
  .hero-content h1 {
    font-size: 2.5rem; /* From "other pages" example */
  }
   .hero-content p {
     font-size: 1.2em;
   }


  /* Close toggle for mobile nav (if used) */
  .close-toggle { /* Ensure this is styled and displayed if your JS uses a separate close button */
    display: block !important;
  }

} /* End of @media screen and (max-width: 768px) block */