/* --- RESET & VARIABLES --- */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --accent: #8c52ff;
    --accent-glow: rgba(140, 82, 255, 0.5);
    --bg-dark: #0a0a0a;
    --bg-card: #141414;
    --text-main: #ffffff;
    --text-muted: #aaaaaa;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

.container { width: 90%; max-width: 1200px; margin: 0 auto; }
.accent { color: var(--accent); text-shadow: 0 0 15px var(--accent-glow); }

/* GLOW BACKGROUNDS */
.glow-bg {
    position: fixed; width: 600px; height: 600px;
    background: var(--accent); filter: blur(150px); opacity: 0.15;
    border-radius: 50%; z-index: -1; animation: moveGlow 10s infinite alternate;
}
.glow-1 { top: -100px; left: -100px; background: #8c52ff; }
.glow-2 { bottom: -100px; right: -100px; background: #00f2ea; }
@keyframes moveGlow { 0% { transform: translate(0, 0); } 100% { transform: translate(50px, 50px); } }

/* HEADER */
.header {
    position: fixed; top: 0; left: 0; width: 100%; padding: 20px 0;
    z-index: 1000; background: transparent; transition: 0.4s ease;
}
.header.scrolled {
    padding: 10px 0; background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(10px); border-bottom: 1px solid rgba(140, 82, 255, 0.2);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
.header.menu-open { background: #0a0a0a !important; transition: none !important; }
.header-container { display: flex; justify-content: space-between; align-items: center; }

/* LOGO */
.logo-wrapper { display: flex; align-items: center; text-decoration: none; gap: 15px; transition: 0.3s; }
.logo-img {
    height: 50px; width: auto; object-fit: contain; border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.1); box-shadow: 0 0 15px rgba(140, 82, 255, 0.3);
    transition: 0.5s;
}
.logo-text {
    font-size: 22px; font-weight: 900; color: #fff; letter-spacing: 1px;
    text-transform: uppercase; white-space: nowrap; line-height: 1;
}
.gradient-text {
    background: linear-gradient(90deg, #8c52ff, #00f2ea);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text; position: relative; margin-left: 5px;
}
.logo-wrapper:hover .logo-img { transform: rotate(10deg) scale(1.1); box-shadow: 0 0 25px rgba(140, 82, 255, 0.6); border-color: #8c52ff; }

/* NAV */
.nav-list { display: flex; list-style: none; }
.nav-link {
    color: #fff; text-decoration: none; margin-left: 30px; font-weight: 500;
    text-transform: uppercase; font-size: 14px; position: relative; transition: 0.3s;
}
.nav-link::after {
    content: ''; position: absolute; width: 0; height: 2px; bottom: -5px; left: 50%;
    background: var(--accent); transition: 0.3s; transform: translateX(-50%);
}
.nav-link:hover::after { width: 100%; box-shadow: 0 0 10px var(--accent); }
.burger { display: none; cursor: pointer; }
.burger div { width: 25px; height: 3px; background-color: #fff; margin: 5px; transition: 0.3s; }

/* HERO */
.hero {
    height: 100vh;
    display: flex; align-items: center; justify-content: center;
    text-align: center; position: relative;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('../img/hero-bg.jpg');
    background-size: cover; background-position: center;
}
.hero h1 { font-size: 60px; line-height: 1.1; margin-bottom: 20px; text-transform: uppercase; font-weight: 900; }
.hero p { font-size: 20px; margin-bottom: 40px; color: var(--text-muted); }

.btn {
    display: inline-block; padding: 15px 50px; background: var(--accent);
    color: #fff; text-decoration: none; font-weight: 700; border-radius: 50px;
    text-transform: uppercase; transition: 0.3s; box-shadow: 0 0 20px var(--accent-glow);
    border: 2px solid var(--accent);
}
.btn:hover { transform: translateY(-5px); box-shadow: 0 0 40px var(--accent); background: transparent; }

/* MARQUEE */
.marquee {
    background: var(--accent); padding: 15px 0; overflow: hidden; position: relative;
    transform: rotate(-2deg) scale(1.05); margin: 50px 0; box-shadow: 0 0 20px var(--accent-glow);
    border-top: 2px solid #fff; border-bottom: 2px solid #fff;
}
.track { display: flex; white-space: nowrap; animation: marquee 20s linear infinite; }
.track span { font-size: 24px; font-weight: 900; color: #fff; text-transform: uppercase; padding-right: 50px; }
@keyframes marquee { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* SECTIONS */
.section { padding: 100px 0; }
.section-title {
    font-size: 40px; text-align: center; margin-bottom: 60px;
    text-transform: uppercase; font-weight: 900; position: relative;
}
.section-title::after {
    content: ''; display: block; width: 60px; height: 4px;
    background: var(--accent); margin: 15px auto 0; box-shadow: 0 0 10px var(--accent);
}
.section-subtitle { text-align: center; color: var(--text-muted); margin-bottom: 40px; font-size: 18px; }

/* ABOUT */
.about-content { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: start; }
.main-desc { font-size: 18px; margin-bottom: 20px; }
.about-list { list-style: none; margin-top: 25px; margin-bottom: 40px; }
.about-list li { margin-bottom: 10px; color: #ccc; }
.about-list i { color: var(--accent); margin-right: 10px; }

.why-us-title { font-size: 24px; color: var(--accent); margin-top: 30px; margin-bottom: 15px; text-transform: uppercase; }
.advantages-list { list-style: none; margin-bottom: 20px; }
.advantages-list li {
    margin-bottom: 12px; position: relative; padding-left: 20px; color: #ccc;
}
.advantages-list li::before {
    content: '•'; color: var(--accent); position: absolute; left: 0; font-size: 20px; line-height: 1;
}
.moto { font-style: italic; color: #fff; border-left: 3px solid var(--accent); padding-left: 15px; }

.about-img { position: relative; height: 500px; width: 100%; z-index: 1; }
.about-img img {
    width: 100%; height: 100%; object-fit: cover; border-radius: 20px;
    border: 1px solid #333; display: block; position: relative; z-index: 2;
}
.about-img::after {
    content: ''; position: absolute; top: 20px; left: 20px; width: 100%; height: 100%;
    border: 2px solid var(--accent); border-radius: 20px; z-index: 1; transition: 0.3s;
}
.about-img:hover::after { top: 10px; left: 10px; box-shadow: 0 0 20px var(--accent-glow); }

/* --- CAROUSEL STYLES (Trainers & Reviews) --- */
.carousel-wrapper {
    position: relative; width: 100%; display: flex;
    align-items: center; justify-content: center;
}

.carousel-track {
    display: flex; gap: 20px; overflow-x: auto;
    scroll-snap-type: x mandatory; scroll-behavior: smooth;
    padding-bottom: 20px; width: 100%;
    -webkit-overflow-scrolling: touch;
    /* Приховуємо скролбар */
    scrollbar-width: none;
}
.carousel-track::-webkit-scrollbar { display: none; }

/* Arrows */
.arrow-btn {
    position: absolute; top: 50%; transform: translateY(-50%);
    background: rgba(140, 82, 255, 0.2); border: 1px solid var(--accent);
    color: #fff; width: 40px; height: 40px; border-radius: 50%;
    cursor: pointer; z-index: 10; font-size: 18px;
    display: flex; align-items: center; justify-content: center;
    transition: 0.3s; backdrop-filter: blur(5px);
}
.arrow-btn:hover { background: var(--accent); box-shadow: 0 0 15px var(--accent); }
.prev-btn { left: -15px; }
.next-btn { right: -15px; }

/* TRAINERS CARD */
.trainer-card {
    background: var(--bg-card); border-radius: 20px; overflow: hidden;
    border: 1px solid #333; transition: 0.3s;
    /* Базовий стиль: на мобільному 100% ширини */
    min-width: 100%; scroll-snap-align: center;
    display: flex; flex-direction: column;
}
.trainer-card:hover { border-color: var(--accent); box-shadow: 0 10px 30px rgba(140, 82, 255, 0.2); }

.trainer-img {
    width: 100%; aspect-ratio: 3 / 4; overflow: hidden;
}
.trainer-img img {
    width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: 0.5s;
}
.trainer-info { padding: 25px; display: flex; flex-direction: column; flex-grow: 1; }
.trainer-info h3 { font-size: 22px; margin-bottom: 10px; color: #fff; }
.trainer-achievements {
    list-style: none; margin-bottom: 15px; padding-bottom: 15px;
    border-bottom: 1px solid #333;
}
.trainer-achievements li {
    color: var(--accent); font-weight: 600; margin-bottom: 5px; font-size: 14px;
}
.trainer-desc { color: #ccc; font-size: 14px; line-height: 1.6; }

/* REVIEWS CARD */
.review-card {
    background: #1a1a1a; padding: 30px; border-radius: 20px;
    border: 1px solid #333;
    min-width: 100%; scroll-snap-align: center;
    display: flex; flex-direction: column;
}
.review-icon { font-size: 30px; color: var(--accent); margin-bottom: 20px; }
.review-text {
    color: #ccc; font-style: italic; margin-bottom: 20px; line-height: 1.6; flex-grow: 1;
}
.review-author { color: #fff; font-weight: 700; text-align: right; margin-top: auto; }

/* ALBUM */
.gallery {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px;
}
.gallery-item {
    background: var(--bg-card); aspect-ratio: 4 / 3;
    border-radius: 15px; overflow: hidden; position: relative;
    border: 1px solid transparent; transition: 0.3s; cursor: pointer;
}
.gallery-item img {
    width: 100%; height: 100%; object-fit: cover; object-position: top center;
    display: block; transition: transform 0.5s ease;
}
.gallery-item::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(140, 82, 255, 0.1); opacity: 0; transition: 0.3s; z-index: 2;
}
.gallery-item:hover::before { opacity: 1; }
.gallery-item:hover { border-color: var(--accent); box-shadow: 0 10px 30px rgba(140, 82, 255, 0.3); }
.gallery-item:hover img { transform: scale(1.05); }

/* CONTACTS */
.contacts-wrapper {
    display: grid; grid-template-columns: 1fr 1.5fr; border-radius: 20px;
    overflow: hidden; background: var(--bg-card); box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}
.contact-info-box { padding: 50px 40px; }
.contact-info-box h3 { font-size: 28px; margin-bottom: 10px; }
.contact-desc { color: var(--text-muted); margin-bottom: 30px; }
.info-item { display: flex; align-items: center; margin-bottom: 20px; font-size: 16px; }
.info-item i { color: var(--accent); width: 30px; font-size: 20px; flex-shrink: 0; }
.info-item a { color: #fff; text-decoration: none; transition: 0.3s; }
.info-item a:hover { color: var(--accent); }

/* Social Buttons */
.social-buttons { margin-top: 30px; display: flex; flex-direction: column; gap: 15px; width: 100%; }
.social-btn {
    display: flex; align-items: center; justify-content: flex-start; gap: 15px;
    width: 100%; padding: 15px 25px; border-radius: 10px; color: #fff;
    text-decoration: none; font-weight: 700; background: #222; border: 1px solid #333;
    transition: 0.3s; box-sizing: border-box;
}
.social-btn i { width: 25px; text-align: center; font-size: 20px; }
.social-btn.insta:hover { background: #d62976; border-color: #d62976; box-shadow: 0 0 15px #d62976; }
.social-btn.viber:hover { background: #7360f2; border-color: #7360f2; box-shadow: 0 0 15px #7360f2; }
.social-btn.telegram:hover { background: #0088cc; border-color: #0088cc; box-shadow: 0 0 15px #0088cc; }

.map-box { min-height: 100%; position: relative; }
.map-box iframe { display: block; width: 100%; height: 100%; filter: invert(90%) hue-rotate(180deg) contrast(90%); }

/* FOOTER */
.footer {
    background-color: #050505; padding: 30px 0; border-top: 1px solid #222;
    position: relative; text-align: center;
}
.footer::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    box-shadow: 0 0 10px var(--accent);
}
.footer p { color: #555; font-size: 14px; text-transform: uppercase; letter-spacing: 1px; }

/* RESPONSIVE */
/* 1. Адаптація каруселі для різних екранів */
@media (min-width: 768px) {
    .trainer-card, .review-card {
        min-width: calc(50% - 10px); /* 2 картки на планшеті */
    }
    .prev-btn { left: -50px; }
    .next-btn { right: -50px; }
}

@media (min-width: 1024px) {
    .trainer-card, .review-card {
        min-width: calc(33.333% - 14px); /* 3 картки на комп'ютері */
    }
}

/* 2. Мобільна версія */
@media (max-width: 900px) {
    .burger { display: block; z-index: 1001; }
    
    .nav {
        position: absolute; top: 100%; left: 0; width: 100%; height: auto;
        background: #0a0a0a; padding: 30px 0; border-bottom: 2px solid var(--accent);
        transform: translateY(-200%); transition: 0.5s ease; z-index: 999; opacity: 0;
    }
    .nav.active { transform: translateY(0); opacity: 1; box-shadow: 0 10px 30px rgba(0,0,0,0.8); }
    .nav-list { flex-direction: column; text-align: center; }
    .nav-link { font-size: 18px; margin: 15px 0; margin-left: 0; display: block; }
    
    .logo-img { height: 40px; }
    .logo-text { font-size: 16px; letter-spacing: 0.5px; }
    .logo-wrapper { gap: 10px; }
    
    .hero h1 { font-size: 32px; margin-bottom: 15px; }
    .hero p { font-size: 16px; margin-bottom: 30px; }
    .section-title { font-size: 28px; margin-bottom: 40px; }
    
    .about-content, .contacts-wrapper { grid-template-columns: 1fr; }
    .map-box { height: 350px; }
    .section { padding: 50px 0; }
    .about-img { height: 300px; }
    
    /* Стрілки на мобільному по краях екрану */
    .prev-btn { left: 0; }
    .next-btn { right: 0; }
    
    .toggle .line1 { transform: rotate(-45deg) translate(-5px, 6px); }
    .toggle .line2 { opacity: 0; }
    .toggle .line3 { transform: rotate(45deg) translate(-5px, -6px); }
}