/* Brainery shared site navigation — hardcoded brand colors so it renders
   identically on every page regardless of that page's own CSS variables. */
#brainery-nav-root{ position:relative; z-index:300; }

.bn-nav{
  position:sticky; top:0; z-index:300;
  background:rgba(251,246,239,0.98);
  backdrop-filter:blur(8px);
  border-bottom:1px solid #E8DCC8;
  font-family:'Inter','Nunito Sans',sans-serif;
}
.bn-nav-inner{
  max-width:1280px; margin:0 auto; padding:9px 20px;
  display:flex; align-items:center; gap:10px;
}
.bn-logo{ display:flex; align-items:center; flex-shrink:0; }
.bn-logo img{ height:34px; width:auto; display:block; }

.bn-links{ display:flex; align-items:center; gap:1px; flex-wrap:wrap; flex:1; }
.bn-item{ position:relative; }
.bn-links > .bn-item > a, .bn-links > .bn-item > button.bn-toggle{
  font-family:'Inter'; font-size:.8rem; font-weight:700; color:#5E3018; text-decoration:none;
  padding:7px 9px; border-radius:8px; white-space:nowrap; background:none; border:none; cursor:pointer;
  display:inline-flex; align-items:center; gap:4px; transition:background .15s ease, color .15s ease;
}
.bn-links > .bn-item > a:hover, .bn-links > .bn-item > button.bn-toggle:hover{ background:#F3E9DB; }
.bn-links a.bn-active{ background:#8B4A2B; color:#fff !important; }
.bn-toggle .caret{ font-size:.6rem; transition:transform .15s ease; }
.bn-item.bn-open > .bn-toggle .caret{ transform:rotate(180deg); }

/* Simple dropdown (Branches, About Us, Blog) */
.bn-dropdown{
  display:none; position:absolute; top:100%; left:0; min-width:220px; background:#fff;
  border:1px solid #E8DCC8; border-radius:12px; box-shadow:0 14px 28px rgba(62,32,22,0.14);
  padding:8px; margin-top:6px; z-index:50;
}
.bn-item.bn-open > .bn-dropdown{ display:block; }
.bn-dropdown a{
  display:block; padding:9px 12px; border-radius:8px; font-size:.85rem; font-weight:600;
  color:#3B3B3B; text-decoration:none;
}
.bn-dropdown a:hover{ background:#F3E9DB; color:#5E3018; }

/* Mega menu (Courses Offered) — fixed positioning so it centers on the
   viewport rather than under wherever its trigger happens to sit in the bar */
.bn-mega{
  display:none; position:fixed; left:50%; transform:translateX(-50%); top:0;
  width:min(760px, 90vw); background:#fff; border:1px solid #E8DCC8; border-radius:14px;
  box-shadow:0 18px 34px rgba(62,32,22,0.16); padding:22px; z-index:50;
}
.bn-item.bn-open > .bn-mega{ display:block; }
.bn-mega-grid{ display:grid; grid-template-columns:repeat(5,1fr); gap:18px; }
.bn-mega-col h4{
  font-family:'Baloo 2',sans-serif; font-size:.76rem; text-transform:uppercase; letter-spacing:.04em;
  color:#C98B4E; margin:0 0 8px; font-weight:700;
}
.bn-mega-col a{
  display:block; padding:6px 4px; font-size:.83rem; font-weight:600; color:#3B3B3B; text-decoration:none;
  border-radius:6px; line-height:1.35;
}
.bn-mega-col a:hover{ color:#5E3018; background:#F3E9DB; padding-left:8px; }

/* Header CTAs */
.bn-ctas{ display:flex; align-items:center; gap:8px; flex-shrink:0; }
.bn-cta{
  font-weight:700; font-size:.8rem; padding:8px 14px; border-radius:10px; text-decoration:none;
  white-space:nowrap; transition:background .15s ease, transform .15s ease; display:inline-flex; align-items:center; gap:5px;
}
.bn-cta-primary{ background:#8B4A2B; color:#fff !important; }
.bn-cta-primary:hover{ background:#5E3018; transform:translateY(-1px); }
.bn-cta-whatsapp{ background:#EAF3EA; color:#2F5C33 !important; border:1.5px solid #cfe4cf; }
.bn-cta-whatsapp:hover{ background:#dcefdc; }
.bn-ctas-mobile{ display:none; }

.bn-burger{
  display:none; flex-shrink:0; width:36px; height:36px; border-radius:8px; border:1.5px solid #E8DCC8;
  background:#fff; cursor:pointer; align-items:center; justify-content:center; flex-direction:column; gap:4px;
}
.bn-burger span{ width:17px; height:2px; background:#5E3018; border-radius:2px; }

@media (max-width:1180px){
  .bn-mega{ width:min(640px, 92vw); }
  .bn-mega-grid{ grid-template-columns:repeat(3,1fr); row-gap:20px; }
}

@media (max-width:1030px){
  .bn-nav-inner{ padding:8px 16px; gap:8px; }
  .bn-logo img{ height:28px; }
  #bnCtasDesktop{ display:none; }

  .bn-links{
    display:none; position:absolute; top:100%; left:0; right:0;
    background:#FBF6EF; border-bottom:1px solid #E8DCC8; flex-direction:column; align-items:stretch;
    padding:6px 10px 14px; box-shadow:0 12px 24px rgba(62,32,22,0.1);
    max-height:calc(100vh - 52px); overflow-y:auto;
  }
  .bn-links.bn-mobile-open{ display:flex; }
  .bn-links > .bn-item{ width:100%; }
  .bn-links > .bn-item > a, .bn-links > .bn-item > button.bn-toggle{
    width:100%; justify-content:space-between; padding:12px 10px; border-radius:0;
    border-bottom:1px solid #F3E9DB; font-size:.9rem;
  }
  .bn-dropdown, .bn-mega{
    display:none; position:static; box-shadow:none; border:none; border-radius:0; margin:0;
    width:auto; transform:none; background:#F3E9DB; padding:6px 10px 10px 20px;
  }
  .bn-item.bn-open > .bn-dropdown, .bn-item.bn-open > .bn-mega{ display:block; }
  .bn-mega-grid{ grid-template-columns:1fr; gap:14px; }
  .bn-mega-col a{ padding:8px 4px; }

  .bn-ctas-mobile{ display:flex; flex-direction:column; gap:8px; margin-top:12px; padding:0 10px; }
  .bn-ctas-mobile .bn-cta{ width:100%; justify-content:center; padding:12px; font-size:.88rem; }
  .bn-ctas-mobile .bn-cta span.txt{ display:inline; }

  .bn-burger{ display:flex; margin-left:auto; }
}
