/* =========================================================
   BORGO CLICK - HEADER GLOBALE
========================================================= */
:root{
  --bc-head-cream:#fbf7f0;
  --bc-head-green:#2f3b2d;
  --bc-head-orange:#bf4f2b;
  --bc-head-border:#e8dfd3;
}

/* nasconde il vecchio header Astra; il nostro viene stampato prima */
.site-header{display:none!important}

.bc-header-container{
  width:min(1380px,calc(100% - 48px));
  margin:0 auto;
}

.bc-topbar{
  background:var(--bc-head-green);
  color:#fff;
  font-size:13px;
  letter-spacing:.01em;
}
.bc-topbar__inner{
  min-height:38px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:24px;
}
.bc-topbar__links{display:flex;align-items:center;gap:14px}
.bc-topbar a{color:#fff!important;text-decoration:none}
.bc-topbar a:hover{opacity:.8}

.bc-site-header{
  position:relative;
  z-index:50;
  background:rgba(251,247,240,.98);
  border-bottom:1px solid var(--bc-head-border);
  box-shadow:0 3px 14px rgba(42,32,22,.04);
}
.bc-site-header__inner{
  min-height:106px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:30px;
}

.bc-brand{
  display:flex;
  align-items:center;
  gap:13px;
  min-width:310px;
  text-decoration:none!important;
}
.bc-brand__logo .custom-logo-link{display:block;line-height:0}
.bc-brand__logo img{width:auto;max-width:82px;max-height:70px;object-fit:contain}
.bc-brand__mark{
  width:72px;height:66px;position:relative;display:block;flex:0 0 72px;
}
.bc-brand__hill{
  position:absolute;left:4px;right:1px;bottom:3px;height:26px;
  background:var(--bc-head-green);border-radius:70% 20% 55% 10%;transform:skewX(-18deg);
}
.bc-brand__tower{
  position:absolute;left:28px;bottom:23px;width:18px;height:38px;background:#b95a38;border-radius:2px 2px 0 0;
  box-shadow:-16px 13px 0 -2px #d28a59,18px 12px 0 -2px #c96643;
}
.bc-brand__tower:before{
  content:"";position:absolute;left:-3px;top:-10px;border-left:12px solid transparent;border-right:12px solid transparent;border-bottom:12px solid #8f3d27;
}
.bc-brand__sun{position:absolute;width:18px;height:18px;border-radius:50%;background:#dfa366;left:2px;top:7px}

.bc-brand__text{display:flex;flex-direction:column;line-height:1}
.bc-brand__name{font-family:Georgia,'Times New Roman',serif;font-size:38px;letter-spacing:-.04em;white-space:nowrap}
.bc-brand__name b{font-weight:500;color:var(--bc-head-orange)}
.bc-brand__name em{font-style:normal;color:var(--bc-head-green)}
.bc-brand__tag{margin-top:8px;font-size:9px;text-transform:uppercase;letter-spacing:.25em;color:#6c685f;white-space:nowrap}

.bc-main-nav{display:flex;align-items:center;gap:33px;margin-left:auto}
.bc-main-nav>a:not(.bc-header-cta):not(.bc-header-search){
  position:relative;color:#282720!important;text-decoration:none!important;font-size:16px;font-weight:500;padding:13px 0;
}
.bc-main-nav>a:not(.bc-header-cta):not(.bc-header-search):after{
  content:"";position:absolute;left:0;right:100%;bottom:6px;height:2px;background:var(--bc-head-orange);transition:right .2s ease;
}
.bc-main-nav>a:not(.bc-header-cta):not(.bc-header-search):hover:after{right:0}

.bc-header-search{display:grid;place-items:center;width:38px;height:38px;flex:0 0 38px}
.bc-header-search span{width:18px;height:18px;border:2px solid #242820;border-radius:50%;position:relative;display:block}
.bc-header-search span:after{content:"";position:absolute;width:8px;height:2px;background:#242820;right:-6px;bottom:-3px;transform:rotate(45deg);transform-origin:left center}

.bc-header-cta{
  display:inline-flex;align-items:center;justify-content:center;gap:12px;
  min-height:52px;padding:0 25px;border-radius:999px;
  background:var(--bc-head-orange);color:#fff!important;text-decoration:none!important;font-weight:700;white-space:nowrap;
  box-shadow:0 6px 16px rgba(191,79,43,.13);transition:.2s ease;
}
.bc-header-cta:hover{background:#a94124;transform:translateY(-2px)}

.bc-menu-toggle{display:none;background:transparent!important;border:0!important;padding:8px!important;margin:0!important}
.bc-menu-toggle span{display:block;width:27px;height:2px;background:#283127;margin:5px 0;transition:.2s}

@media(max-width:1180px){
  .bc-site-header__inner{min-height:92px}
  .bc-brand{min-width:260px}
  .bc-brand__name{font-size:31px}
  .bc-brand__mark{transform:scale(.86);transform-origin:left center;width:62px;flex-basis:62px}
  .bc-main-nav{gap:20px}
  .bc-main-nav>a:not(.bc-header-cta):not(.bc-header-search){font-size:15px}
  .bc-header-cta{padding:0 18px}
}

@media(max-width:940px){
  .bc-topbar__links{display:none}
  .bc-topbar__inner{justify-content:center}
  .bc-header-container{width:min(100% - 28px,1380px)}
  .bc-site-header__inner{min-height:84px;position:relative}
  .bc-brand{min-width:0}
  .bc-brand__name{font-size:29px}
  .bc-brand__tag{display:none}
  .bc-menu-toggle{display:block}
  .bc-main-nav{
    display:none;position:absolute;left:0;right:0;top:84px;background:#fff;border:1px solid var(--bc-head-border);box-shadow:0 14px 35px rgba(0,0,0,.12);padding:20px;flex-direction:column;align-items:stretch;gap:5px;
  }
  .bc-main-nav.is-open{display:flex}
  .bc-main-nav>a:not(.bc-header-cta):not(.bc-header-search){padding:12px 4px}
  .bc-header-search{display:none}
  .bc-header-cta{margin-top:8px;border-radius:5px}
}

@media(max-width:520px){
  .bc-topbar{display:none}
  .bc-site-header__inner{min-height:76px}
  .bc-main-nav{top:76px}
  .bc-brand__mark{transform:scale(.72);width:54px;flex-basis:54px}
  .bc-brand__name{font-size:26px}
  .bc-brand__logo img{max-width:62px;max-height:54px}
}

/* v3.0 - menu orientato all'organizzazione del viaggio */
@media(min-width:1181px){
  .bc-main-nav{gap:22px}
  .bc-main-nav>a:not(.bc-header-cta):not(.bc-header-search){font-size:14px}
  .bc-brand{min-width:270px}
  .bc-brand__name{font-size:34px}
  .bc-header-cta{padding:0 20px}
}

/* v4.0 - nuovo logo Borgo + percorso */
.bc-brand{min-width:285px}
.bc-brand__svg{display:block;width:78px;height:62px;flex:0 0 78px}
.bc-brand__svg svg{display:block;width:100%;height:100%}
.bc-brand__tag{text-transform:uppercase;letter-spacing:.18em}
.bc-main-nav{gap:20px}
.bc-main-nav>a:not(.bc-header-cta){font-size:14px}
@media(max-width:1180px){
  .bc-brand{min-width:245px}
  .bc-brand__svg{width:65px;height:54px;flex-basis:65px}
}
@media(max-width:520px){
  .bc-brand__svg{width:56px;height:48px;flex-basis:56px}
}

/* v4.4 - Distacco visivo header dal contenuto */
.bc-site-header{
  margin-bottom:22px;
}




/* v5.2 - Menu one-page + mobile compatto */
.bc-main-nav{gap:16px}
.bc-main-nav>a:not(.bc-header-cta){font-size:13px}
.bc-header-cta{padding:0 16px;min-height:46px}

@media(max-width:1180px){
  .bc-main-nav{gap:12px}
  .bc-main-nav>a:not(.bc-header-cta){font-size:12.5px}
  .bc-header-cta{padding:0 13px;font-size:13px}
}

@media(max-width:940px){
  .bc-topbar{display:none}
  .bc-site-header__inner{min-height:74px;position:relative;flex-direction:row;padding:8px 0}
  .bc-brand{min-width:0;flex:1 1 auto}
  .bc-brand__svg{width:44px;height:40px;flex-basis:44px}
  .bc-brand__name{font-size:22px}
  .bc-brand__tag{display:none}
  .bc-menu-toggle{display:block!important;flex:0 0 auto}
  .bc-main-nav{
    display:none;
    position:absolute;
    left:0;right:0;top:74px;
    background:#fff;
    border:1px solid var(--bc-head-border);
    box-shadow:0 12px 28px rgba(0,0,0,.12);
    padding:14px;
    grid-template-columns:1fr 1fr;
    gap:4px 10px;
    z-index:9999;
  }
  .bc-main-nav.is-open{display:grid}
  .bc-main-nav>a:not(.bc-header-cta){
    display:flex;align-items:center;justify-content:center;
    min-height:44px;padding:8px 6px!important;
    font-size:14px!important;border-radius:6px;
  }
  .bc-main-nav>a:not(.bc-header-cta):hover{background:#fbf7f0}
  .bc-main-nav>a:not(.bc-header-cta):after{display:none}
  .bc-header-cta{
    grid-column:1 / -1;
    min-height:46px!important;
    margin-top:6px!important;
    border-radius:8px!important;
    width:100%!important;
    font-size:14px!important;
  }
}

@media(max-width:520px){
  .bc-header-container{width:calc(100% - 24px)}
  .bc-site-header__inner{min-height:68px}
  .bc-main-nav{top:68px;padding:10px}
  .bc-brand__svg{width:38px;height:35px;flex-basis:38px}
  .bc-brand__name{font-size:20px}
  .bc-main-nav>a:not(.bc-header-cta){min-height:40px;font-size:13px!important}
}

/* =========================================================
   v6.0 - MOBILE RESPONSIVE REBUILD
========================================================= */
@media (max-width: 767px){
  html,body{overflow-x:hidden}
  .bc-site-header{margin-bottom:10px}
  .bc-topbar{display:none!important}
  .bc-header-container{width:calc(100% - 24px);max-width:none}
  .bc-site-header__inner{min-height:68px!important;padding:7px 0!important;display:flex!important;flex-direction:row!important;align-items:center!important;gap:10px!important}
  .bc-brand{min-width:0!important;flex:1 1 auto!important;gap:8px!important;overflow:hidden}
  .bc-brand__svg{width:42px!important;height:38px!important;flex:0 0 42px!important}
  .bc-brand__name{font-size:22px!important;line-height:1!important;white-space:nowrap}
  .bc-brand__tag{display:none!important}
  .bc-menu-toggle{display:block!important;flex:0 0 44px!important;width:44px!important;height:44px!important;border-radius:8px!important;padding:9px!important;background:#f5ede4!important;position:relative;z-index:10002}
  .bc-menu-toggle span{width:24px!important;height:2px!important;margin:5px auto!important;background:#2f3b2d!important;border-radius:3px;transition:transform .2s ease,opacity .2s ease}
  .bc-menu-toggle[aria-expanded="true"] span:nth-child(1){transform:translateY(7px) rotate(45deg)}
  .bc-menu-toggle[aria-expanded="true"] span:nth-child(2){opacity:0}
  .bc-menu-toggle[aria-expanded="true"] span:nth-child(3){transform:translateY(-7px) rotate(-45deg)}
  .bc-main-nav{
    display:none!important;
    position:absolute!important;
    top:68px!important;
    left:12px!important;
    right:12px!important;
    width:auto!important;
    max-height:calc(100vh - 92px)!important;
    overflow-y:auto!important;
    padding:12px!important;
    background:#fff!important;
    border:1px solid var(--bc-head-border)!important;
    border-radius:12px!important;
    box-shadow:0 18px 44px rgba(28,25,20,.16)!important;
    grid-template-columns:1fr!important;
    gap:2px!important;
    z-index:10001!important;
  }
  .bc-main-nav.is-open{display:grid!important}
  .bc-main-nav>a:not(.bc-header-cta){
    min-height:44px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    padding:10px 12px!important;
    font-size:15px!important;
    border-radius:7px!important;
    color:#25231f!important;
  }
  .bc-main-nav>a:not(.bc-header-cta):hover{background:#fbf7f0!important}
  .bc-main-nav>a:not(.bc-header-cta):after{display:none!important}
  .bc-header-cta{
    width:100%!important;
    min-height:46px!important;
    margin:8px 0 0!important;
    padding:0 16px!important;
    border-radius:8px!important;
    font-size:15px!important;
  }
}

@media (max-width: 390px){
  .bc-brand__svg{width:36px!important;height:34px!important;flex-basis:36px!important}
  .bc-brand__name{font-size:20px!important}
}
