@import url("https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;700&display=swap");

/* The site's shared navbar stylesheet supplies the design. These rules isolate
   it from the editor's generic header, button and anchor styles. */
#site-header {
  --forest: #1a2f23;
  --earth-beige: #f9f8f3;
  display: block;
  flex: 0 0 auto;
  height: auto;
  min-height: 0;
  padding: 0;
  margin: 0;
  font-family: "DM Sans", sans-serif;
}
#site-header *, #site-header *::before, #site-header *::after { box-sizing: border-box; }
#site-header .container { width: min(100% - 2rem, 80rem); margin: 0 auto; }
#site-header .brand-logo { max-width: 100%; gap: 0; text-decoration: none; }
#site-header .brand-logo img { display: block; width: 13rem; height: auto; max-width: 100%; }
#site-header nav a { text-decoration: none; font-family: inherit; line-height: normal; }
#site-header .mobile-menu-toggle {
  min-width: 44px;
  min-height: 44px;
  border: 0;
  border-radius: 0;
  margin: 0;
  box-shadow: none;
}
#site-header .mobile-menu-toggle:hover { background: transparent; }
#site-header .mobile-menu-toggle span { border-radius: 0; }
#site-header [hidden] { display: none !important; }
#site-header a:focus-visible, #site-header button:focus-visible { outline: 2px solid #315b46; outline-offset: 4px; }
#site-header .header-actions { display: flex; padding: .5rem 1rem 0; }
/* Lock the document without turning the body into a new sticky scroll container. */
html.editor-menu-open { overflow: hidden; }
body.climate-editor.menu-open { overflow: visible; }
@media (max-width: 1180px) { #site-header .brand-logo img { width: 11rem; } }
@media (max-width: 480px) { #site-header .brand-logo img { width: 9.5rem; } }
@media (min-width: 1600px) {
  #site-header .container { width: calc(100% - 5vw); max-width: none; }
}
@media (prefers-reduced-motion: reduce) {
  #site-header *, #site-header *::after { transition: none; animation: none; }
}

/* Keep compact navigation reachable and independent of the editing workspace. */
@media(max-width:1180px){
 body.climate-editor #site-header{position:sticky;top:0;z-index:100;transform:none;opacity:1;pointer-events:auto;margin-top:0;overflow:visible}
 #site-header .nav-inner{height:72px;min-height:72px;flex-wrap:nowrap;padding-block:10px;gap:12px}
 #site-header .brand-logo{min-width:0;flex:0 1 auto}
 #site-header .brand-logo img{max-height:50px;max-width:100%;object-fit:contain}
 #site-header .desktop-nav{display:none}
 #site-header .mobile-menu-toggle{display:grid;place-content:center;gap:5px;flex:0 0 44px;width:44px;height:44px;padding:10px;background:transparent;color:#315b46;touch-action:manipulation}
 #site-header .mobile-menu-toggle span{width:22px;height:2px;margin:0;transform-origin:center}
 #site-header .mobile-nav{position:absolute;top:100%;left:0;right:0;width:100%;max-width:none;margin:0;display:grid;gap:4px;padding:12px max(16px,env(safe-area-inset-left)) max(16px,env(safe-area-inset-bottom));max-height:calc(100vh - 73px);max-height:calc(100dvh - 73px);overflow-y:auto;overscroll-behavior-y:contain;scroll-padding-block:12px;background:#f9f8f3;border-top:1px solid #dedfd3;box-shadow:0 14px 24px #1a2f231a}
 #site-header .mobile-nav a{display:flex;align-items:center;min-height:44px;padding:12px 16px;white-space:normal;overflow-wrap:anywhere;line-height:1.4}
 #site-header .mobile-nav a[aria-current=page]{background:#e8ecdf;color:#1a2f23}
}
