/* common.css */
:root {
  /* Основные цвета */
  --text-color-white: #ffffff;
  --text-color-dark: #3c3c3c;

  /* Семейства шрифтов */
  --font-logo: 'Montserrat', sans-serif;
  --font-universal: 'Inter', sans-serif;
  --font-h: 'IBM Plex Sans', sans-serif;

  --header-height: 80px; 
}

/* Общие стили для хедера */
.header {
    background-color: #3c3c3c;
    color: black;
    padding: 20px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    flex-shrink: 0;
    height: var(--header-height);
}

.header__inner {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 40px;
}

header .logo {
    padding-left: 40px;
    padding-right: 40px;
}

.logo {
    font-size: 1.5rem;
    font-family: var(--font-logo);
    font-weight: bold;
    color: #ffffff;
    text-decoration: none;
}

.nav {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-left: auto;
    padding-left: 40px;
    padding-right: 40px;
}

.nav__link {
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
}

.nav__link:hover,
.nav__link.active {
    color: #ff9900;
}

.nav__link.active {
    font-weight: bold;
}

.cart-wrapper {
    margin-left: 10px;
}

.cart-btn {
    position: relative;
    color: white;
    font-size: 1.2rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: #ffffff;
    color: rgb(0, 0, 0);
    border-radius: 50%;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: bold;
}

.burger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 100;
}

.burger span,
.burger__line {
    display: block;
    width: 100%;
    height: 2px;
    background-color: #ffffff;
    transition: all 0.3s ease;
}

/* Общие стили для футера */
.footer {
    background-color: #3c3c3c;
    color: white;
    padding: 50px 0 20px;
    flex-shrink: 0;
    width: 100%;
    margin-top: auto;
    flex-shrink: 0;
    margin-top: auto;
    font-size: clamp(13px, 1.3vw, 16px);
}

footer .logo {
        font-size: clamp(19px, 2.1vw, 26px);
    }

.footer__inner {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    padding-left: 40px;
    padding-right: 40px;
}

.footer__col {
    margin-bottom: 30px;
}

.footer__col h3 {
    margin-bottom: 20px;
    font-size: 1.2rem;
    font-family: var(--font-h);
}

.footer__link {
    display: block;
    color: #ccc;
    margin-bottom: 10px;
    text-decoration: none;
}

.footer__link:hover {
    color: #ff9900;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-link {
    color: white;
    font-size: 1.5rem;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .burger {
        display: flex;
    }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 55%;
        max-width: 280px;
        height: 100vh;
        background-color: #fff;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 20px;
        gap: 24px;
        transition: right 0.3s ease;
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
        z-index: 999;
    }

    .nav.active {
        right: 0;
    }

    .nav__link {
        color: #3c3c3c;
        text-align: center;
    }

    .cart-wrapper {
        margin: 10px 0 0;
        order: 1;
    }

    .cart-btn {
        color: #3c3c3c;
    }
}

/* Прижимаем футер к низу */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding-top: var(--header-height);
}

/* Отключаем прокрутку фона при открытом мобильном меню */
.no-scroll {
    overflow: hidden;
}

/* Адаптив под экрнаны до 968 px 
@media (max-width: 968px) {

    /* Header 
    .nav {
        padding-left: 40px;
        padding-right: 40px;
    }
    header .logo {
        padding-left: 40px;
        padding-right: 40px;
    }

    /* Footer 
    .footer__inner {
        padding-left: 40px;
        padding-right: 40px;
    }

}*/

/* Адаптив под экрнаны до 768 px */
@media (max-width: 768px) {

    /* Header */
    header .logo {
        padding-left: 20px;
        padding-right: 20px;
    }

    .burger {
        margin-left: auto;
        display: flex;
        margin-right: 20px;
    }

    /* Footer */
    .footer__inner {
        padding-left: 20px;
        padding-right: 20px;
    }

}

/* Адаптив под экрнаны до 375 px */
@media (max-width: 375px) {

    /* Header */
    header .logo {
        padding-left: 16px;
        padding-right: 16px;
    }

    .burger {
        margin-left: auto;
        display: flex;
        margin-right: 20px;
    }

    /* Footer */
    .footer__inner {
        padding-left: 16px;
        padding-right: 16px;
    }

}