/* css/header.css */

/* ========== Header ========== */
.header {
    color: var(--header-color);
    background-color: var(--footer-bg);
    position: sticky;
    top: 0;
    transform: translateY(-1px);
    z-index: 100;
}

.header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 5px 40px;
    margin: 0 auto;
    position: relative;
}

/* ---- Logo ---- */
.header__logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.header__logo-link {
    display: block;
    text-decoration: none;
}

.header__logo-link img {
    max-width: 304px;
    max-height: 60px;
}

.header__logo-text {
    font-family: var(--font-serif);
    font-size: 22px;
    font-weight: 400;
    letter-spacing: 3px;
    color: var(--header-color);
    text-transform: uppercase;
    line-height: 1;
}

/* ---- Nav ---- */
.nav {
    display: flex;
    align-items: center;
}

.nav ul {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0;
    margin: 0;
}

.nav ul li {
    list-style: none;
}

.nav ul li a {
    display: block;
    padding: 6px 14px;
    font-size: 16px;
    font-weight: 400;
    color: var(--header-color);
    transition: var(--transition);
    white-space: nowrap;
}

.nav ul li a:hover {
    scale: 1.05;
}

.current_page_item {
    color: white;
    text-decoration: underline;
    text-underline-offset: 4px;
    font-weight: 500;
}



/* ---- Burger ---- */
.header__burger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 36px;
    height: 36px;
    padding: 4px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 101;
    flex-shrink: 0;
}

.header__burger-line {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--header-color);
    border-radius: 2px;
    transition: var(--transition);
}

/* ---- Sidebar (mobile) ---- */
.sidebar {
    position: fixed;
    top: 0;
    right: 0;
    width: 280px;
    height: 100vh;
    background-color: #2e2e2e;
    z-index: 200;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    padding: 20px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.sidebar--open {
    transform: translateX(0);
}

.sidebar__close {
    display: flex;
    align-self: flex-end;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    font-size: 28px;
    line-height: 1;
    color: #f8f8f8;
    background: none;
    border: none;
    cursor: pointer;
    margin-bottom: 20px;
    flex-shrink: 0;
    transition: var(--transition);
}

.sidebar__close:hover {
    color: var(--accent-light);
}

.sidebar__nav {
    flex: 1;
}

.sidebar__list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 0;
    margin: 0;
}

.sidebar__list li {
    list-style: none;
}

.sidebar__list li a {
    display: block;
    padding: 12px 16px;
    font-size: 16px;
    font-weight: 400;
    color: #f0f0f0;
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.sidebar__overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 199;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.sidebar__overlay--visible {
    opacity: 1;
    visibility: visible;
}

/* ---- Responsive ---- */
@media (max-width: 900px) {
    .nav {
        display: none;
    }

    .header__burger {
        display: flex;
    }

    .header__inner {
        padding: 14px 20px;
    }
}

@media (max-width: 550px) {
    .header__logo-link img {
        max-width: 250px;
    }

    .header__inner {
        gap: 10px;

        padding-left: 10px;
    }
}