/* Сброс стандартных отступов и полей */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    padding-top: 70px;
    background-color: #F2F2F2;
}

/* Контейнер для центрирования контента */
.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Шапка */
header {
    background: #333;
    color: #fff;
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Стили для логотипа */
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    z-index: 1001;
}

.logo-img {
    height: 40px;
    width: auto;
    transition: transform 0.3s ease;
}

.logo-img:hover {
    transform: scale(1.05);
}

/* Навигация для десктопа */
nav {
    display: flex;
    align-items: center;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    margin: 0;
    padding: 0;
}

.nav-menu li a {
    color: #fff;
    text-decoration: none;
    padding: 0.5rem 1rem;
    display: block;
    transition: color 0.3s ease;
    font-size: 1rem;
    white-space: nowrap;
    border-radius: 4px;
}

.nav-menu li a:hover {
    color: #252525;
    background: rgba(255, 255, 255, 0.1);
}

/* Кнопка гамбургер-меню (скрыта на десктопе) */
.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1002;
}

.menu-toggle svg {
    width: 24px;
    height: 24px;
    transition: transform 0.3s ease;
}

.menu-toggle.active svg {
    transform: rotate(90deg);
}

.hero {
    position: relative;
    padding: 150px 0 100px;
    text-align: left;
    /* Меняем center на left */
    overflow: hidden;
}

.hero .container {
    position: relative;
    z-index: 2;
    text-align: left;
    /* Добавляем */
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-align: left;
    /* Выравниваем заголовок по левому краю */
    max-width: 600px;
    /* Ограничиваем ширину для лучшей читаемости */
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    text-align: left;
    /* Выравниваем текст по левому краю */
    max-width: 500px;
    /* Ограничиваем ширину */
    margin-left: 0;
    /* Убираем auto выравнивание */
    margin-right: auto;
    /* Оставляем только слева */
}

.hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translateX(-50%) translateY(-50%);
    z-index: -1;
}

.btn {
    display: inline-block;
    background: #383838;
    color: #fff;
    padding: 0.8rem 2rem;
    text-decoration: none;
    border-radius: 5px;
    font-size: 1.1rem;
    transition: background 0.3s ease;
}

.btn:hover {
    background: #6d6d6d;
}

section {
    padding: 50px 0;
}

section h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
}

.about p {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.feature-item {
    background: #f9f9f9;
    padding: 2rem;
    border-radius: 5px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.feature-item h3 {
    margin-bottom: 1rem;
}

footer {
    background: #333;
    color: #fff;
    text-align: center;
    padding: 2rem 0;
}

/* Shit */
.features-grid-1 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.features-1 {
    margin-top: -200px;
}

.feature-item-1 {
    /* background: #f9f9f9; */
    padding: 2rem;
    border-radius: 5px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-item-1:hover {
    transform: translateY(-5px);
    /* box-shadow: 0 10px 20px rgba(0,0,0,0.1); */
}

.feature-item-1 h3 {
    /* margin-bottom: 0.5rem; */
}

.feature-item-1 h2 {
    text-align: center;
    margin: 0;
}

.feature-item-1-pic {
    width: 100%;
    height: 100%;
    object-fit: cover; 
}

.i-hate-css {
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    /* Вертикальное выравнивание */
    justify-content: center;
    /* Горизонтальное выравнивание */
}

.team-photo-container {
    width: 100%;
    display: flex;
    justify-content: center;
}

/* .team-photo{
    width: 80%;
} */

/* Shit */




/* ==================== */
/* МОБИЛЬНАЯ ВЕРСИЯ С ВЫПАДАЮЩИМ МЕНЮ */
/* ==================== */

@media (max-width: 768px) {
    body {
        padding-top: 65px;
    }

    header {
        padding: 0.8rem 0;
    }

    /* Показываем кнопку гамбургера */
    .menu-toggle {
        display: flex;
    }

    /* Скрываем меню по умолчанию */
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: #333;
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        padding-top: 80px;
        transition: right 0.3s ease;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.3);
        gap: 0;
    }

    /* Когда меню открыто */
    .nav-menu.active {
        right: 0;
    }

    .nav-menu li {
        width: 100%;
        text-align: center;
        border-bottom: 1px solid #444;
    }

    .nav-menu li:last-child {
        border-bottom: none;
    }

    .nav-menu li a {
        padding: 1.2rem 1rem;
        font-size: 1.1rem;
        display: block;
        width: 100%;
        border-radius: 0;
        background: none;
    }

    .nav-menu li a:hover {
        background: rgba(255, 255, 255, 0.1);
        color: #007bff;
    }

    /* Оверлей при открытом меню */
    .nav-menu::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
        opacity: 0;
        transition: opacity 0.3s ease;
        pointer-events: none;
    }

    .nav-menu.active::before {
        opacity: 1;
        pointer-events: all;
    }

    .hero {
        padding: 30px 0 60px;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    section {
        padding: 60px 0;
    }

    section h2 {
        font-size: 1.8rem;
    }

    .features-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .features-grid-1 {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .features-1 {
        margin-top: 0px;
    }
}

/* Еще меньшие экраны */
@media (max-width: 480px) {
    body {
        padding-top: 65px;
    }

    .logo-img {
        height: 30px;
    }

    .nav-menu {
        width: 85%;
    }

    .hero h1 {
        font-size: 1.8rem;
    }

    section h2 {
        font-size: 1.6rem;
    }

    .container {
        padding: 0 15px;
    }

    .feature-item {
        padding: 1.5rem;
    }

    .feature-item-1 {
        padding: 1.5rem;
    }

    .feature-item-1-1 {
        padding: 1.5rem;
    }

    .features-1 {
        margin-top: -100px;
    }
}


/* Стили для карусели портфолио */
.portfolio-carousel {
    padding: 60px 0;
    background: #f8f9fa;
}

.carousel-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.carousel-header {
    text-align: center;
    margin-bottom: 50px;
}

.carousel-header h2 {
    font-size: 2.5rem;
    color: #333;
    margin-bottom: 10px;
}

.custom-carousel {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.1);
    background: white;
    /* Фиксируем высоту контейнера */
    height: 650px; /* Высота изображения + контент */
}

.carousel-inner {
    position: relative;
    width: 100%;
    height: 100%;
}

.carousel-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.carousel-item.active {
    opacity: 1;
    visibility: visible;
}

.carousel-img {
    width: 100%;
    height: 450px;
    object-fit: cover;
    display: block;
}

.carousel-text {
    padding: 35px;
    text-align: center;
    background: white;
}

.carousel-text h3 {
    font-size: 1.6rem;
    color: #2c3e50;
    margin-bottom: 15px;
    font-weight: 600;
}

.carousel-text p {
    color: #7f8c8d;
    line-height: 1.7;
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.9);
    border: none;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    font-size: 26px;
    color: #333;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-nav:hover {
    background: white;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    transform: translateY(-50%) scale(1.1);
}

.carousel-prev-btn {
    left: 25px;
}

.carousel-next-btn {
    right: 25px;
}

.carousel-dots {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 20;
}

.carousel-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid white;
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-dot.active {
    background: white;
    transform: scale(1.2);
}

.carousel-dot:hover {
    background: rgba(255,255,255,0.7);
}

/* Адаптивность */
@media (max-width: 768px) {
    .portfolio-carousel {
        padding: 40px 0;
    }
    
    .carousel-header h2 {
        font-size: 2rem;
    }
    
    .custom-carousel {
        height: 580px; /* Уменьшаем высоту для мобильных */
    }
    
    .carousel-img {
        height: 350px;
    }
    
    .carousel-text {
        padding: 25px 20px;
    }
    
    .carousel-nav {
        width: 45px;
        height: 45px;
        font-size: 22px;
    }
    
    .carousel-prev-btn {
        left: 15px;
    }
    
    .carousel-next-btn {
        right: 15px;
    }
}

@media (max-width: 480px) {
    .custom-carousel {
        height: 520px; /* Еще меньше для маленьких экранов */
    }
    
    .carousel-img {
        height: 280px;
    }
    
    .carousel-text h3 {
        font-size: 1.4rem;
    }
    
    .carousel-text p {
        font-size: 1rem;
    }
}