/* =========================================================
   BYALL GROUP — SHARED HEADER
========================================================= */

.site-header {
    position: fixed;
    top: 18px;
    left: 0;
    z-index: 100;

    width: 100%;
    padding-inline: 22px;

    pointer-events: none;
}

.site-header .header-inner {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;

    width: 100%;
    max-width: 1320px;
    min-height: 76px;
    height: auto;
    margin-inline: auto;
    padding: 12px 24px;

    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 50px;

    background: rgba(14, 24, 32, 0.94);

    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);

    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);

    pointer-events: auto;

    transition:
        background-color 0.2s ease,
        box-shadow 0.2s ease;
}

.site-header.is-scrolled .header-inner {
    background: rgba(10, 17, 23, 0.98);
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.28);
}

/* BRAND */

.site-header .brand {
    display: inline-flex;
    align-items: baseline;
    gap: 7px;
    flex-shrink: 0;

    white-space: nowrap;
}

.site-header .brand-byall {
    color: var(--byall-blue);

    font-size: 30px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -1px;
}

.site-header .brand-group {
    color: var(--byall-gold);

    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 2px;
}

/* DESKTOP NAVIGATION */

.site-header .main-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;

    min-width: 0;
}

.site-header .main-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 44px;
    padding: 10px 13px;

    border-radius: 24px;

    color: #c9d0d5;

    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;

    white-space: nowrap;

    transition:
        color 0.2s ease,
        background-color 0.2s ease;
}

.site-header .main-nav a::after {
    content: none;
}

.site-header .main-nav a:hover,
.site-header .main-nav a[aria-current="page"] {
    background: rgba(12, 163, 227, 0.14);
    color: #ffffff;
}

/* PROJECT BUTTON */

.site-header .header-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-shrink: 0;

    min-height: 44px;
    padding: 12px 20px;

    border-radius: 28px;

    background: var(--byall-gold);
    color: #111111;

    font-size: 11px;
    font-weight: 700;
    line-height: 1.4;

    white-space: nowrap;

    transition: background-color 0.2s ease;
}

.site-header .header-cta:hover {
    background: #f5c54b;
}

.site-header .header-cta span {
    font-size: 18px;
    line-height: 1;
}

/* MOBILE BUTTON */

.site-header .mobile-menu-button {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex-shrink: 0;

    width: 44px;
    height: 44px;
    padding: 0;

    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;

    background: rgba(255, 255, 255, 0.06);

    cursor: pointer;
}

.site-header .mobile-menu-button span {
    display: block;

    width: 18px;
    height: 2px;

    background: #ffffff;

    transition:
        transform 0.2s ease,
        opacity 0.2s ease;
}

.site-header .mobile-menu-button[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.site-header .mobile-menu-button[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.site-header .mobile-menu-button[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

html {
    scroll-padding-top: 120px;
}

/* TABLET & MOBILE NAVIGATION */

@media (max-width: 1050px) {
    .site-header .header-inner {
        gap: 16px;
    }

   .site-header .main-nav {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;

    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;

    max-height: calc(100vh - 125px);
    padding: 12px;
    overflow-y: auto;

    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 22px;

    background: #101b24;

    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.3);
}

    .site-header .main-nav.nav-open {
        display: flex;
    }

    .site-header .main-nav a {
        justify-content: flex-start;

        min-height: 48px;
        padding: 14px 18px;

        border-radius: 12px;

        font-size: 14px;
    }

    .site-header .header-cta {
        margin-left: auto;
    }

    .site-header .mobile-menu-button {
        display: flex;
    }
}

@media (max-width: 600px) {
    .site-header {
        top: 10px;
        padding-inline: 10px;
    }

    .site-header .header-inner {
        min-height: 64px;
        padding: 10px 14px;

        border-radius: 24px;
    }

    .site-header .brand-byall {
        font-size: 27px;
    }

    .site-header .brand-group {
        font-size: 10px;
    }

    .site-header .header-cta {
        display: none;
    }

    /* Keep page titles below the fixed navigation. */

    main > .home-hero .home-hero-content {
        padding-top: 110px;
    }

    main > .about-hero,
    main > .services-hero,
    main > .markets-hero,
    main > .projects-hero,
    main > .contact-hero {
        padding-top: 120px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .site-header * {
        transition: none;
    }
}