/* ==========================================================
   BWS Framework - Header Premium v0.9
   SBC Construções Industriais
========================================================== */

:root{
    --bws-header-primary:#121635;
    --bws-header-secondary:#142a45;
    --bws-header-accent:#f28c28;
    --bws-header-white:#ffffff;
    --bws-header-text:#1b1f2a;
    --bws-header-muted:rgba(255,255,255,.74);
    --bws-header-height:104px;
}

body.admin-bar .bws-header{top:32px;}

.bws-header{
    position:fixed;
    top:0;
    left:0;
    right:0;
    z-index:999;
    background:linear-gradient(180deg, rgba(18,22,53,.96) 0%, rgba(18,22,53,.74) 58%, rgba(18,22,53,.08) 100%);
    color:var(--bws-header-white);
    transition:background .28s ease, box-shadow .28s ease, transform .28s ease;
    backdrop-filter:blur(10px);
}

.bws-header.is-scrolled{
    background:rgba(18,22,53,.98);
    box-shadow:0 18px 45px rgba(0,0,0,.18);
}

.bws-header-top{
    border-bottom:1px solid rgba(255,255,255,.10);
    font-size:13px;
    transition:max-height .28s ease, opacity .28s ease, transform .28s ease;
    overflow:hidden;
    max-height:42px;
}

.bws-header.is-scrolled .bws-header-top{
    max-height:0;
    opacity:0;
    transform:translateY(-10px);
}

.bws-header-top__inner{
    min-height:38px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:24px;
}

.bws-header-top__left,
.bws-header-top__right{
    display:flex;
    align-items:center;
    gap:22px;
}

.bws-top-link{
    display:inline-flex;
    align-items:center;
    gap:8px;
    color:rgba(255,255,255,.82);
    text-decoration:none;
    transition:color .2s ease;
}

.bws-top-link:hover{color:var(--bws-header-accent);}
.bws-top-icon{color:var(--bws-header-accent);font-size:13px;}

.bws-header-main__inner{
    height:82px;
    display:flex;
    align-items:center;
    gap:28px;
    transition:height .28s ease;
}

.bws-header.is-scrolled .bws-header-main__inner{height:70px;}

.bws-header-brand{flex:0 0 auto;display:flex;align-items:center;}
.bws-header-brand .site-logo{display:flex;align-items:center;text-decoration:none;}
.bws-header-brand .site-logo img{
    display:block;
    width:auto;
    max-height:58px;
    transition:max-height .28s ease, transform .28s ease;
}

.bws-header.is-scrolled .bws-header-brand .site-logo img{max-height:48px;}

.bws-main-navigation{margin-left:auto;display:flex;align-items:center;}
.bws-primary-menu,
.bws-primary-menu ul{
    list-style:none;
    margin:0;
    padding:0;
}

.bws-primary-menu{
    display:flex;
    align-items:center;
    gap:28px;
}

.bws-primary-menu > li{position:relative;}

.bws-primary-menu > li > a{
    position:relative;
    display:inline-flex;
    align-items:center;
    min-height:42px;
    color:#fff;
    font-size:13px;
    font-weight:800;
    letter-spacing:.055em;
    text-transform:uppercase;
    text-decoration:none;
    transition:color .2s ease;
}

.bws-primary-menu > li > a::after{
    content:"";
    position:absolute;
    left:0;
    bottom:2px;
    width:0;
    height:2px;
    background:var(--bws-header-accent);
    transition:width .22s ease;
}

.bws-primary-menu > li:hover > a,
.bws-primary-menu > li.current-menu-item > a,
.bws-primary-menu > li.current-menu-ancestor > a{color:var(--bws-header-accent);}

.bws-primary-menu > li:hover > a::after,
.bws-primary-menu > li.current-menu-item > a::after,
.bws-primary-menu > li.current-menu-ancestor > a::after{width:100%;}

.bws-primary-menu .sub-menu{
    position:absolute;
    top:100%;
    left:-22px;
    min-width:250px;
    padding:14px;
    background:#fff;
    border-radius:16px;
    box-shadow:0 24px 65px rgba(0,0,0,.20);
    opacity:0;
    visibility:hidden;
    transform:translateY(12px);
    transition:opacity .2s ease, transform .2s ease, visibility .2s ease;
}

.bws-primary-menu li:hover > .sub-menu{
    opacity:1;
    visibility:visible;
    transform:translateY(0);
}

.bws-primary-menu .sub-menu a{
    display:block;
    padding:11px 13px;
    color:var(--bws-header-text);
    border-radius:10px;
    font-weight:750;
    font-size:14px;
    text-decoration:none;
    transition:background .2s ease, color .2s ease;
}

.bws-primary-menu .sub-menu a:hover{
    background:rgba(242,140,40,.12);
    color:var(--bws-header-primary);
}

.bws-header-actions{
    display:flex;
    align-items:center;
    gap:12px;
    flex:0 0 auto;
}

.bws-header-whatsapp{
    color:rgba(255,255,255,.82);
    font-size:13px;
    font-weight:800;
    text-decoration:none;
    transition:color .2s ease;
}

.bws-header-whatsapp:hover{color:var(--bws-header-accent);}

.bws-btn{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-height:46px;
    padding:0 22px;
    border-radius:999px;
    font-size:13px;
    font-weight:900;
    letter-spacing:.035em;
    text-transform:uppercase;
    text-decoration:none;
    white-space:nowrap;
    transition:transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.bws-btn-primary{
    background:var(--bws-header-accent);
    color:#11162d;
    box-shadow:0 14px 30px rgba(242,140,40,.24);
}

.bws-btn-primary:hover{
    transform:translateY(-2px);
    box-shadow:0 18px 42px rgba(242,140,40,.34);
}

.bws-menu-toggle{
    display:none;
    width:46px;
    height:46px;
    padding:0;
    margin-left:auto;
    background:rgba(255,255,255,.08);
    border:1px solid rgba(255,255,255,.14);
    border-radius:12px;
    cursor:pointer;
}

.bws-menu-toggle span{
    display:block;
    width:21px;
    height:2px;
    margin:5px auto;
    background:#fff;
    border-radius:99px;
    transition:transform .22s ease, opacity .22s ease;
}

.bws-menu-toggle.is-active span:nth-child(1){transform:translateY(7px) rotate(45deg);}
.bws-menu-toggle.is-active span:nth-child(2){opacity:0;}
.bws-menu-toggle.is-active span:nth-child(3){transform:translateY(-7px) rotate(-45deg);}

@media(max-width:1120px){
    .bws-primary-menu{gap:18px;}
    .bws-primary-menu > li > a{font-size:12px;}
    .bws-header-whatsapp{display:none;}
}

@media(max-width:980px){
    body.admin-bar .bws-header{top:46px;}
    .bws-header-top{display:none;}
    .bws-header-main__inner,
    .bws-header.is-scrolled .bws-header-main__inner{height:74px;}
    .bws-header-brand .site-logo img,
    .bws-header.is-scrolled .bws-header-brand .site-logo img{max-height:50px;}
    .bws-menu-toggle{display:block;}
    .bws-header-actions{display:none;}
    .bws-main-navigation{
        position:fixed;
        top:74px;
        left:0;
        right:0;
        display:none;
        margin:0;
        padding:22px 20px 28px;
        background:rgba(18,22,53,.985);
        box-shadow:0 24px 55px rgba(0,0,0,.22);
        max-height:calc(100vh - 74px);
        overflow:auto;
    }
    .bws-main-navigation.is-open{display:block;}
    .bws-primary-menu{display:block;}
    .bws-primary-menu > li{border-bottom:1px solid rgba(255,255,255,.10);}
    .bws-primary-menu > li > a{display:flex;min-height:52px;font-size:14px;}
    .bws-primary-menu > li > a::after{display:none;}
    .bws-primary-menu .sub-menu{
        position:static;
        visibility:visible;
        opacity:1;
        transform:none;
        box-shadow:none;
        background:rgba(255,255,255,.06);
        border-radius:14px;
        margin:0 0 14px;
        padding:8px;
        min-width:0;
    }
    .bws-primary-menu .sub-menu a{color:#fff;}
}

@media(max-width:782px){body.admin-bar .bws-header{top:46px;}}
@media(max-width:600px){body.admin-bar .bws-header{top:0;}}
