* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
     font-family: EB garamond;
}

/* === Навигация === */
.nav-container {
    width: 100%;
}

.stranici {
    display: flex;
    gap: 40px;
    justify-content: center;
    align-items: center;
    padding: 15px 0;
    font-family: "Gill Sans", sans-serif;
}

.stranici a {
    text-decoration: none;
    color: black;
    transition: all 0.2s ease-in-out;
    border: 1px solid transparent;
}

.stranici a.glav,
.stranici a:hover {
    color: orange;
    border-bottom: 1px solid orange;
}

.stranici a.glav {
    font-weight: 600;
}

.menu-toggle, .menu-overlay, .close-btn {
    display: none;
}

/* Контейнер для позиционирования справа в навигации */
.lang-wrapper {
    display: flex;
    align-items: center;
    padding-right: 20px;
}

.lang-switcher {
    position: relative;
    font-family: 'Lora', serif;
    cursor: pointer;
    user-select: none;
    z-index: 1100;
}

.selected-lang {
    display: flex;
    align-items: center;
    gap: 8px;
    background: orange; /* Легкий фон, заметный на белом и цветном */
    border-radius: 6px;
    padding: 2px 10px;
    color: #ffffff; 
    border: 1px solid rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    font-weight: 500;
}

.selected-lang:hover {
    background: darkorange;
    border-color: orange;
}

.selected-lang svg {
    transition: transform 0.3s ease;
}

/* Поворот стрелочки при открытии */
.lang-switcher.active .selected-lang svg {
    transform: rotate(180deg);
}

.lang-dropdown {
    position: absolute;
    right: 0;
    background: white;
    list-style: none;
    padding: 5px 0;
    margin: 0;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
    display: none;
    min-width: 100px;
    overflow: hidden;
    animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(); }
}

.lang-switcher.active .lang-dropdown {
    display: block;
}

.lang-dropdown li {
    padding: 10px 20px;
    color: #444;
    transition: 0.2s;
    font-size: 14px;
    text-align: left;
}

.lang-dropdown li:hover {
    background: #fff9f0;
    color: orange;
}

.lang-dropdown li.active {
    font-weight: bold;
    color: orange;
    background: #fff4e6;
}


/* === Главный блок (pervi) === */
.pervi {
    position: relative;
    height: 734px;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    background-position: top;
    background-image: linear-gradient(rgba(0, 0, 0, 0.572), rgba(0, 0, 0, 0.717)), url('../img/phon1.jpg');
    background-size: cover;
    background-attachment: fixed;
}

.col-8 {
    color: #ffffff;
    text-align: center;
    position: relative;
    z-index: 10;
    padding: 20px 15px;
    max-width: 100%; /* Защита от переполнения без Bootstrap */
    flex-direction: column;
    display: flex;
    align-items: center;
}

.slov {
    font-size: 80px;
    font-weight: 700;
}

.opisa {
    font-size: 45px;
    font-weight: 600;
}

.perviknop {
    background-color: orange;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 23px;
    border-radius: 5px;
    margin-top: 40px;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    text-decoration: none;
    display: inline-block;
}

.perviknop:hover {
    background-color: darkorange;
}


/* Адаптивность для мобильного меню */
@media (max-width: 1000px) {
    .lang-wrapper {

        position: absolute;
        top: 20px;
        order: -1; /* Ставит выбор языка в начало мобильного списка */
    }
    .lang-switcher {
        width: 100%;
    }
    .selected-lang {
        justify-content: space-between;
    }
}
/* === Секция О Компании === */
.okomp {
    display: flex;
    align-items: center;
    text-align: left;
    padding: 200px 150px;
    font-family: 'EB Garamond', serif;
    gap: 30px;
}

.titleokomp {
    color: orange;
    font-size: 50px;
    font-weight: 700;
}

.opisokomp {
    font-size: 22px;
    line-height: 1.6;
    color: #555;
}

/* === Секция Преимущества === */
.advantages {
    padding: 170px 100px;
    background-color: rgb(46, 86, 43);
    color: white;
    font-family: 'Lora', serif;
}

.advantages h2 {
    text-align: left;
    font-size: 50px;
    margin-bottom: 30px;
    color: white;
    grid-column: 1/3;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px 50px;
}

.benefit-item {
    position: relative;
    padding-left: 40px;
}

.benefit-number {
    position: absolute;
    left: 0;
    top: 0;
    font-size: 55px;
    font-weight: 700;
    color: #f6a63e;
    line-height: 1;
}

.benefit-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

.benefit-text {
    font-size: 15px;
    line-height: 1.5;
}

/* === Секция Продукция === */
.section-produce {
    color: rgb(46, 86, 43);
    margin: 0 auto;
    padding: 100px;
    font-family: 'Lora', serif;
}

.section-produce h2 {
    font-size: 64px;
    font-weight: 700;
    margin-bottom: 10px;
    color: rgb(46, 86, 43);
}

.section-produce p.subtitle {
    font-size: 20px;
    max-width: 900px;
    margin-bottom: 40px;
    color: #1b1b1b;
}

.produce-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 5px;
}

.produce-card {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 1px;
}

.produce-card img {
    width: 100%;
    height: 290px;
    object-fit: cover;
    display: block;
}

.produce-card .overlay {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
}

.produce-card h3 {
    color: #fff;
    font-size: 28px;
    margin: 0;
    font-weight: 500;
}

.stat-card {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    padding: 30px;
    background-size: cover;
    background-position: center;
    background-image: url('../img/ph3.png');
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.1);
}

.stat-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.55), transparent);
    z-index: 1;
}

.stat-card-content {
    position: relative;
    z-index: 2;
    color: #fff;
}

.stat-card .big-number {
    font-size: 54px;
    font-weight: 800;
    margin: 0;
    padding: 0;
}

.stat-card .text-sub {
    font-size: 22px;
    opacity: 0.9;
}

.produce-text {
    margin-top: 25px;
    padding-top: 10px;
    border-top: 2px solid orange;
    font-size: 18px;
}

/* === Секция География === */
.geo-clean {
    padding: 170px 100px;
    margin: 80px auto;
    font-family: 'Lora', serif;
    color: white;
    background-color: rgb(46, 86, 43);
}

.geo-clean h2 {
    font-size: 46px;
    font-weight: 700;
    margin-bottom: 12px;
}

.geo-clean p.subtitle {
    font-size: 21px;
    line-height: 1.55;
    margin-bottom: 55px;
    max-width: 780px;
}

.geo-line {
    display: flex;
    gap: 30px;
}

.geo-item {
    align-items: center;
    display: flex;
}

.geo-num {
    font-size: 130px;
    font-weight: 800;
    color: orange;
    line-height: 0.8;
    border-left: 2px double orange;
    padding-left: 10px;
}

.geo-text {
    font-size: 22px;
    font-weight: 600;
    margin-left: 10px;
    z-index: 2;
}

/* === Секция История === */
.history-section {
    display: flex;
    padding: 120px 100px;
    justify-content: center;
    align-items: center;
    gap: 20px;
    font-family: 'Lora', serif;
    color: #12253c;
}

.history-title {
    font-size: 46px;
    font-weight: 700;
    margin-bottom: 25px;
    color: rgb(46, 86, 43);
}

.history-text {
    font-size: 20px;
    line-height: 1.55;
    margin-bottom: 55px;
}

.history-text b {
    color: orange;
}

.history-num {
    font-size: 180px;
    margin: 0;
    color: orange;
    font-weight: 900;
    background-image: url('../img/large_TP0UJrHt0231YcBQgHmTl5D0rk81GOeE.jpg');
    background-position: center;
    background-size: cover;
    padding: 80px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* === Футер === */
.site-footer {
    background-color: #f5f5f5;
    color: #4d4d4d;
    padding: 5px 0 20px 0;
}

.footer-bottom {
    padding: 10px 90px 0 90px;
    text-align: center;
    font-size: 16px;
    color: #777;
    display: flex;
    justify-content: space-between;
}


.footer-bottom a {
    color: orange;
    text-decoration: none;
}

/* === Кнопка Наверх === */
.scroll-to-top-btn {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999;
    width: 50px;
    height: 50px;
    background-color: orange;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: opacity 0.3s, background-color 0.3s;
}

.scroll-to-top-btn:hover {
    background-color: darkorange;
}

.scroll-to-top-btn.show {
    display: block;
}

/* ======================================= */
/* === АДАПТИВНОСТЬ (MEDIA QUERIES) === */
/* ======================================= */

/* 1. Навигация и Меню (Планшеты и Мобильные) */
@media (max-width: 1070px) {
    .stranici {
        gap: 20px;
    }
}

@media (max-width: 1000px) {
    .menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 22px;
        background: transparent;
        border: none;
        cursor: pointer;
        position: fixed;
        top: 20px;
        right: 20px;
        z-index: 1200;
        padding: 0;
    }

    .menu-toggle span {
        width: 100%;
        height: 3px;
        background-color: #f8f8f8;
        border-radius: 2px;
        transition: 0.3s;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.674);
    }

    .menu-toggle.hidden {
        display: none;
    }

    .menu-overlay {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(3px);
        z-index: 1001;
        opacity: 0;
        visibility: hidden;
        transition: all 0.4s ease-in-out;
    }

    .menu-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    .stranici {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        right: 0;
        height: 100%;
        width: auto;
        min-width: 250px;
        max-width: 80%;
        background-color: #fff;
        z-index: 1002;
        padding: 60px 40px 40px 40px;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        gap: 20px;
        align-items: flex-start;
        transform: translateX(110%);
        transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
        font-size: 20px;
    }

    .stranici.active {
        transform: translateX(0);
    }

    .stranici a {
        font-size: 20px;
        border-bottom: 1px solid #eee;
        width: 100%;
        padding-bottom: 10px;
    }

    .close-btn {
        display: none;
        position: absolute;
        top: 15px;
        right: 20px;
        background: none;
        border: none;
        font-size: 36px;
        color: #555;
        cursor: pointer;
        line-height: 1;
        z-index: 1200;
    }

    .close-btn:hover {
        color: orange;
    }

    .stranici.active .close-btn {
        display: block;
    }
    .pervi{
         background-attachment: scroll;
    }
}

/* 2. Адаптация контента */

@media (max-width: 1055px) {
    .slov { font-size: 65px; }
    .opisa { font-size: 35px; }
    .perviknop { font-size: 20px; margin-top: 10px; }
}

/* Планшеты (Landscape) */
@media (max-width: 1024px) {
    .pervi { height: 600px; }

    .okomp {
        padding: 80px 50px;
        flex-direction: column;
        text-align: center;
    }
    .okomp > div:first-child { width: 100%; margin-bottom: 30px; }
    .titleokomp { font-size: 40px; text-align: center; }
    .opisokomp { font-size: 18px; text-align: left; }

    .advantages { padding: 80px 50px; }
    .advantages h2 { font-size: 40px; text-align: center; }
    .benefits-grid { grid-template-columns: repeat(2, 1fr); gap: 30px; }

    .section-produce { padding: 80px 20px; }
    .section-produce h2 { font-size: 50px; }
    .produce-grid { display: flex; flex-direction: column; }
    
    .stat-card { min-height: 250px; }
    .stat-card .big-number { font-size: 48px; }

    .geo-clean { padding: 100px 50px; }
    .geo-line { flex-wrap: wrap; gap: 40px; }
    .geo-item { justify-content: center; }
    .geo-num { font-size: 120px; }
    .geo-text { font-size: 20px; margin-left: 20px; }

    .history-section {
        padding: 80px 50px;
        flex-direction: column-reverse;
        text-align: center;
    }
    .history-title { font-size: 40px; margin-top: 20px; }
    .history-num { font-size: 120px; padding: 60px; }
}

@media (max-width: 923px) {
    .slov { font-size: 55px; }
    .opisa { font-size: 30px; }
}

/* Мобильные (Portrait) */
@media (max-width: 768px) {
    .slov { font-size: 45px; }
    .opisa { font-size: 30px; }
    .perviknop {  padding: 8px 15px; font-size: 14px; }
    
    .pervi { height: 500px; }

    .okomp { padding: 60px 20px; }
    .titleokomp { font-size: 32px; text-align: left; }
    .opisokomp { font-size: 16px; text-align: left; }

    .advantages { padding: 60px 20px; }
    .advantages h2 { font-size: 32px; padding: 0; text-align: center; }
    .benefits-grid { grid-template-columns: 1fr; gap: 20px; }
    .benefit-item { padding-left: 35px; }
    .benefit-number { font-size: 45px; }

    .section-produce { padding: 60px 15px; }
    .section-produce h2 { font-size: 40px; }
    .produce-grid { grid-template-columns: 1fr; }
    .produce-card img, .stat-card { height: 220px; }
    .stat-card .big-number { font-size: 40px; }
    .stat-card .text-sub { font-size: 18px; }

    .geo-clean { padding: 80px 20px; }
    .geo-clean h2 { font-size: 32px; }
    .geo-clean p.subtitle { font-size: 18px; margin-bottom: 40px; }
    .geo-num { font-size: 90px; }
    .geo-text { font-size: 18px; margin-left: 15px; }
    .geo-item { justify-content: start; }

    .history-section { padding: 60px 20px; }
    .history-title { font-size: 32px; margin-bottom: 15px; }
    .history-text { font-size: 16px; }
    .history-num { font-size: 90px; padding: 50px; }

    .site-footer { padding: 40px 20px 20px 20px; }
    .footer-bottom { font-size: 12px; }
}

@media (max-width: 680px) {
    .footer-bottom { padding: 3px 60px 3px 10px; }
}

@media (max-width: 627px) {
    .pervi { height: 350px; } /* Объединено из двух правил */
    .slov { font-size: 40px; }
    .opisa { font-size: 25px; }
}

@media (max-width: 580px) {
    .footer-bottom {
        flex-direction: column;
        gap: 10px;
        padding: 3px 20px 3px 10px;
        font-size: 20px;
    }
}

@media (max-width: 530px) {
    .pervi { height: 300px; }
    .slov { font-size: 35px; }
    .opisa { font-size: 20px; }
    .perviknop { font-size: 13px; padding: 7px 10px; }

    .okomp, .advantages, .section-produce, .geo-clean, .history-section {
        padding: 40px 15px;
    }
}

@media (max-width: 490px) {
    .slov { font-size: 31px; }
    .footer-bottom{
        font-size: 20px;
        padding: 2px;
    }
}

@media (max-width: 420px) {
    .slov { font-size: 28px; }
}

@media (max-width: 390px) {
    .slov { font-size: 23px; }
    .opisa { font-size: 16px; }
}