/* -----------------------------------------------------
  ✅ GLOBAL RESET: applies to everything
----------------------------------------------------- */
* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  overflow-x: hidden;
}

/* -----------------------------------------------------
  ✅ HOMEPAGE ONLY — full width, no margin/sidebar
  Requires: `body-class: homepage` in index.qmd YAML
----------------------------------------------------- */
/* ✅ HOMEPAGE ONLY — full width, no sidebar constraints */
body.homepage #quarto-margin-sidebar,
body.homepage #quarto-sidebar,
body.homepage .margin-sidebar,
body.homepage .page-columns,
body.homepage .content,
body.homepage .container,
body.homepage .container-fluid {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box;
}

body.homepage .margin-sidebar,
body.homepage #quarto-margin-sidebar {
  display: none !important;
  width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
}

body.homepage {
  padding-top: 0 !important;
}

body.homepage,
body.homepage main.content,
body.homepage .page-columns,
body.homepage #quarto-content {
  margin: 0 !important;
  padding: 0 !important;
  max-width: 100vw !important;
  overflow-x: hidden;
}


/* ========== NON-HOMEPAGE PADDING FOR NAVBAR ========== */
body:not(.homepage) main,
body:not(.homepage) main.content,
body:not(.homepage) #quarto-content,
body:not(.homepage) #quarto-document-content {
  padding-top: 50px;
  max-width: 1000px;
  margin: 0 auto;
}

/* -----------------------------------------------------
  ✅ HERO BANNER (homepage)
----------------------------------------------------- */
/* Hero container takes full screen height */
.hero-container * {
  box-sizing: border-box;
}

.hero-container {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  margin: 0;
  padding: 0;
}

/* Image fills the container, not the screen */
.hero-image {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  z-index: -1;
  filter: brightness(60%);
}

/* Text overlay stays centered relative to banner, not viewport */
.hero-overlay {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  padding: 2rem;
  border-radius: 10px;
  width: fit-content;
  max-width: 90%;
  z-index: 1;
}


.hero-overlay h1,
.hero-overlay p {
  margin: 0;
  padding: 0;
}


/* -----------------------------------------------------
  ✅ NAVBAR — fixed, transparent on top, solid on scroll
----------------------------------------------------- */
/* Smooth transition and fixed position */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* Prevent content jump */
body {
  padding-top: 70px; /* Adjust based on actual navbar height */
}

/* ---------------------------------------- */
/* HOME PAGE — Initial (Transparent + White Text) */
/* ---------------------------------------- */
body.homepage .navbar {
  background-color: transparent !important;
  box-shadow: none;
}

body.homepage .navbar .navbar-brand,
body.homepage .navbar .nav-link {
  color: white !important;
}

/* ---------------------------------------- */
/* HOME PAGE — After Scrolling (White Navbar + Black Text) */
/* ---------------------------------------- */
body.homepage .navbar.scrolled {
  background-color: white !important;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

body.homepage .navbar.scrolled .navbar-brand,
body.homepage .navbar.scrolled .nav-link {
  color: black !important;
}

/* ---------------------------------------- */
/* OTHER PAGES — White Navbar + Black Text */
/* ---------------------------------------- */
body:not(.homepage) .navbar {
  background-color: white !important;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

body:not(.homepage) .navbar .navbar-brand,
body:not(.homepage) .navbar .nav-link {
  color: black !important;
}

/* Optional hover effect */
.navbar .nav-link:hover {
  opacity: 0.8;
  text-decoration: underline;
}