* {
    -webkit-tap-highlight-color: transparent;
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

body.app-body {
    margin: 0; 
    padding: 0;
    overscroll-behavior-y: none;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #e2e8f0;
    user-select: none;
    -webkit-user-select: none;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    background: none !important; /* Убираем фон с body */
    height: 100vh;
    position: fixed;
    background-attachment: fixed;
    background-repeat: no-repeat;
    background-size: cover; 


}

/* Контейнер приложения с градиентным переливом точно как на фото */
.app-container {
    overscroll-behavior-y: none;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    /* max-width: 448px; */
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    justify-content: space-between;
    position: relative; /* Важно для z-index */
    /* overflow-x: hidden; */
    padding: 2.5rem 1.5rem;
    background: transparent !important;
    
}

.content-area, .main-menu-wrapper, .hero-image-container, .menu-buttons {
    background: transparent !important;
    overscroll-behavior-y: none;
    -webkit-overflow-scrolling: touch;
}


/* Медное свечение на заднем плане (атмосферный блик по центру) */
.bg-glow {
    position: absolute;
    top: 35%;
    left: 50%;
    transform: translateX(-50%);
    width: 220px; /* Сделали шире */
    height: 290px;
    background-color: rgba(58, 1, 1, 0.963); 
    border-radius: 9999px;
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
}

.bg-glow-top {
    position: absolute;
    top: 0%;
    left: 50%;
    transform: translateX(-50%);
    width: 300px; /* Сделайте шире для эффекта арки */
    height: 100px; /* Высота должна быть ровно в 2 раза меньше ширины для идеальной дуги */
    background-color: rgba(58, 1, 1, 0.963); 
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    border-bottom-left-radius: 200px;
    border-bottom-right-radius: 200px;
    filter: blur(70px);
    pointer-events: none;
    z-index: 0;
}

.bg-glow-trainers {
    position: absolute;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
    width: 220px; /* Сделали шире */
    height: 290px;
    background-color: rgba(58, 1, 1, 0.963); 
    border-radius: 9999px;
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
}

.glow-base {
    position: absolute;
    width: 200px;
    height: 200px;
    background-color: rgba(58, 1, 1, 0.963); /* Ваш красный цвет с прозрачностью */
    border-radius: 9999px;
    filter: blur(90px);
    pointer-events: none;
    z-index: 0;
}

/* Позиции */
.glow-top-left {
    top: 0;
    left: 0;
}

.glow-bottom-right {
    bottom: 0;
    right: 0;
}

.glow-center {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.bg-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    background: 
        /* Нижняя "волна" */
        /* radial-gradient(circle at 100% 100%, rgba(99, 62, 3, 0.25) 0%, transparent 60%), */
        /* Верхняя "волна" */
        radial-gradient(circle at 0% 0%, rgb(15, 15, 15) 0%, transparent 45%),
        /* Центральный "волновой" перелив */
        linear-gradient(90deg, #0f0f0f 20%, #0f0f0f 70%, #0f0f0f 100%);
    
    transform: translateZ(0);
}

/* Область динамического контента */
.content-area {
    width: 100%;
    z-index: 2;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overscroll-behavior-y: none;
    -webkit-overflow-scrolling: touch;
}

.main-menu-wrapper {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-top: auto;
    margin-bottom: auto;
    /* overflow: visible; */
}

/* Стили текстового логотипа */
.header-block {
    margin-bottom: 1rem;
    z-index: 1;
}


/* Контейнер и градиентная маска фотографии тренера */
.hero-image-container {
    position: relative;
    width: 113%;
    flex-grow: 0; 
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    margin-top: 1rem;
}

.hero-visual-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: visible;
    
}

/* Четкий передний план */
.hero-image-fg {
    position: relative;
    width: 116%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    z-index: 2;
    /* Ваша существующая маска для плавного перехода внизу */
    -webkit-mask-image: linear-gradient(
        to bottom, 
        transparent 0%,    /* Полная прозрачность на самом верху */
        black 15%,         /* Картинка становится полностью видимой к 15% */
        black 60%,         /* Остается видимой до 60% высоты */
        transparent 100%   /* Плавно исчезает к самому низу */
    );
    mask-image: linear-gradient(
        to bottom, 
        transparent 0%, 
        black 15%, 
        black 60%, 
        transparent 100%
    );
}

.brand-logo-img {
    width: 300px;        /* Задайте нужную ширину */
    height: auto;        /* Сохранит пропорции */
    margin: 0 auto;      /* Центрирует изображение */
    display: block;
    object-fit: contain;
}

/* Меню вертикальных кнопок */
.menu-buttons {
    width: 100%;
    max-width: 19rem;
    display: flex;
    flex-direction: column;
    /* gap: 0.8rem; */
    margin: 0 auto;
    z-index: 5;
    
}

@keyframes slow-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(5px); }
}

.animate-bounce-slow {
    animation: slow-bounce 2s ease-in-out infinite;
}

/* Оформление контейнера */
.cta-container {
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.cta-container:hover {
    opacity: 1;
}

.btn-accent {
    display: block;
    width: 300px;
    height: 100%;
    text-align: center;
    background: #821616;
    color: #d2d2d2 !important;
    font-weight: 700 !important;
    
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 1.1rem 0 !important;
    border-radius: 0.75rem !important;
    font-size: 1rem !important;
    text-decoration: none !important;
    transition: all 0.15s ease;

    margin-top: 1rem !important;  /* Убеждаемся, что отступ сверху железный */
    margin-bottom: 2rem !important; /* Добавляем отступ снизу, чтобы не прилипало к низу экрана */
    
    /* Сбрасываем наследование от кнопок со "склеенными" линиями */
    margin-left: 0 !important;
    margin-right: 0 !important;
    position: relative !important;
    z-index: 10 !important;
    
    /* Если кнопка всё равно заезжает, используем clear */
    clear: both;
}

.btn-accent:active {
    transform: scale(0.97);
    filter: brightness(0.9);
}

.btn-outline {
    width: 100% !important;
    background: transparent !important;
    border: none !important;
    color: #d4d4d8 !important;
    text-transform: uppercase;
    letter-spacing: 0.15em !important;
    padding: 1.2rem 0 !important;
    font-size: 1rem !important;
    font-weight: 300 !important;
    cursor: pointer;
    
    position: relative;
    /* Ключевой момент: смещаем кнопку на 1px вверх, 
       чтобы её верхняя граница легла на нижнюю границу предыдущей */
    margin-top: -1px !important; 
    transition: background-color 0.3s ease, color 0.3s ease;
}

.btn-outline.active {
    background: linear-gradient(90deg, #0f0f0f 0%, #710f0f 50%, #0f0f0f 100%) !important;
    border: 2px solid transparent;
    color: white !important;   
}

/* Градиентная линия */
.btn-outline::before {
    content: "";
    position: absolute;
    top: 0;
    left: 1%;
    width: 100%;
    height: 1.5px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
}

/* Добавляем линию снизу только для самой последней кнопки */
.menu-buttons button:last-child::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 1%;
    width: 100%;
    height: 1.5px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
}

/* Брендинг внизу страницы */
.app-footer {
    width: 100%;
    text-align: center;
    font-size: 0.6rem;
    color: #3f3f46;
    letter-spacing: 0.08em;
    /* text-transform: uppercase; */
    /* pointer-events: none; */
    z-index: 10;
    padding-top: 1.5rem;
}

.content-divider {
    width: 100%;
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.1), transparent);
    margin: 2rem 0; /* Создает отступ сверху и снизу */
}

/* Карточка трансформации */
.result-card {
    background: rgba(20, 22, 26, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 1.5rem;
    overflow: hidden;
    backdrop-filter: blur(15px);
    transition: transform 0.3s ease, border-color 0.3s ease;
    display: flex;
    flex-direction: column;
    overscroll-behavior-y: none;
    -webkit-overflow-scrolling: touch;
}

.result-card:hover {
    border-color: rgba(217, 119, 6, 0.4);
    transform: translateY(-5px);
}

/* Контейнер для изображения */
.result-img-wrapper {
    position: relative;
    aspect-ratio: 3 / 4;
    width: 100%;
    background: #000;
}

.result-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.9;
}

/* Блок с описанием внутри карточки */
.result-info {
    padding: 1.25rem;
    flex-grow: 1;
}

.result-title {
    font-size: 0.95rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.result-description {
    font-size: 0.8rem;
    color: #a1a1aa;
    line-height: 1.5;
    font-weight: 400;
}

.carousel-container {
    position: relative;
    width: 100%;
}

/* Отключаем любой скролл в блоке */
.results-slider {
    display: flex;
    overflow: hidden; /* Скрываем все, что не поместилось */
    scroll-behavior: smooth;
    width: 100%;
    gap: 0 1.5rem;
    justify-content: center;
}

.arrow-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 10px;
    z-index: 10;
    cursor: pointer;
}

.arrow-left { left: 0; }
.arrow-right { right: 0; }




/*БЛОК ПРАЙСЫ*/
.price-card-box {
    background: transparent;
    border: 1.5px solid rgba(255, 255, 255, 0.473);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
}

.price-title-text {
    font-size: 1rem;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #ffffff;
    margin-bottom: 1rem;
}

.price-description-text {
    font-size: 0.85rem;
    color: #a1a1aa;
    line-height: 1.4;
    margin-bottom: 1.5rem;
}

/* Кнопка "ЗАКАЗАТЬ" как на фото */
.btn-order-square {
    background: linear-gradient(135deg, #a16207 0%, #78350f 100%);
    color: #ffffff;
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border: none;
    cursor: pointer;
    align-self: flex-end; /* Сдвиг кнопки вправо */
}

.price-cost-text {
    font-size: 1.5rem;
    font-weight: 400;
    color: #ff8000f3; /* Оранжевый акцент цены */
    letter-spacing: 0.02em;
}
/*БЛОК ПРАЙСЫ*/

/*БЛОК КАЛЬКУЛЯТОРА*/
/* Контейнер калькулятора */

.calc-header-main {
    font-size: 4rem;
    font-weight: 550;
    text-align: center;
    color: #b91c1c !important;
    letter-spacing: 0.1em;
    margin: 0 !important;
    line-height: 0.8;
}

.calc-header-sub {
    color: #ffffff !important;
    font-size: 2.3rem;
    text-align: center;
    letter-spacing: 0.1em;
    margin-bottom: 2rem;
    font-weight: 300;
    margin: 0 !important;  /* Убираем все отступы вокруг */
    margin-top: -15px !important;
    margin-bottom: 3rem !important; /* Увеличиваем отступ снизу */
    line-height: 1;
}


/* .calc-card {
    background: rgba(15, 15, 15, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 1.5rem;
} */


/* Поля ввода калькулятора */
.calc-input {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    padding: 9px;
    width: 100%;
    height: 40px;   /* Фиксированная высота */
    color: white;
    
}

.calc-input:focus {
    border-color: #ea580c;
}

/* Лейблы калькулятора */
.calc-label {
    font-size: 0.9rem;
    color: #71717a;
    text-transform: uppercase;
    font-weight: 400;
    margin-bottom: 0.5rem;
    letter-spacing: 0.1em;
}

/* Кнопка калькулятора */
.calc-btn {
    width: 80%;
    margin-top: 45px; /* Фиксированный отступ сверху */
    margin-left: auto; /* В сочетании с margin-right: auto центрирует кнопку */
    margin-right: auto;
    display: block;
    
    padding: 15px;
    background: #b91c1c;
    border-radius: 0.75rem;
    border: none;
    color: white;
    font-size: 1.2rem;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    box-shadow: 0 0 15px rgba(77, 4, 4, 0.5);
}

/* Элементы результата */
.calc-result-value {
    font-size: 2.5rem;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: -0.05em;
    margin-bottom: 0.5rem;
}

.calc-nutrient-label {
    font-size: 0.5rem;
    color: #71717a;
    text-transform: uppercase;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.calc-nutrient-value {
    font-size: 0.875rem;
    font-weight: 900;
}


/* Контейнер списка */
.trainers-container { padding: 20px; }
.trainers-header { margin-bottom: 40px; }
.trainers-title { font-size: 28px; font-weight: 900; color: #fff; text-transform: uppercase; letter-spacing: -1px; }
.title-underline { height: 4px; width: 60px; background: #b91c1c; margin-top: 12px; border-radius: 2px; }

.gradient-divider {
    position: relative;
    width: 100%;      /* Чуть меньше 100%, чтобы были отступы по краям */
    margin: 0 auto;  /* Центрирование */
    height: 1px; /* Чуть толще для выразительности */
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
    margin-top: 15px;   /* Отступ сверху */
    margin-bottom: 15px; 
}



/* Контейнер карточки */
.trainer-card {
    position: relative;
    display: flex;
    flex-direction: column;
    margin-bottom: 140px;
    background: #0f0f0f; /* Или ваш цвет фона */
    z-index: 1;
}

/* Обертка фото: убираем лишние ограничения */
.trainer-image-wrapper {
    display: flex;
    flex-direction: column;
    width: 100%;
    background: transparent;
}

/* Фото: теперь оно просто подстраивается под ширину */
.trainer-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain; /* Картинка не обрезается */
    z-index: 2;
}

/* Линия: прилипает прямо к фото */
.gradient-line-attached {
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
    margin-top: -2px; /* Подтягиваем линию к картинке */
    z-index: 10;
}

/* Инфо-блок */
.name-badge { display: inline-block; background: #b91c1c; padding: 6px 12px; border-radius: 4px; margin-bottom: 12px; }
.trainer-name { font-size: 18px; font-weight: 800; color: #fff; text-transform: uppercase; }
.trainer-specialization { font-size: 14px; font-weight: 700; color: #fff; text-transform: uppercase; margin-bottom: 4px; margin-top: 14px }
.trainer-description { font-size: 14px; color: #d4d4d8; line-height: 1.6; white-space: pre-line;}



/* Админ-кнопки */
.btn-add-trainer { background: #b91c1c; color: #fff; padding: 12px 24px; border: none; border-radius: 8px; font-weight: 900; text-transform: uppercase; cursor: pointer; margin-bottom: 20px; }
.admin-controls { display: flex; gap: 10px; margin-top: 20px; }
.btn-edit { flex: 1; padding: 10px; background: #27272a; color: #fff; border: none; border-radius: 6px; font-size: 10px; font-weight: 700; text-transform: uppercase; }
.btn-delete { flex: 1; padding: 10px; background: rgba(127, 29, 29, 0.3); color: #f87171; border: 1px solid rgba(127, 29, 29, 0.5); border-radius: 6px; font-size: 10px; font-weight: 700; text-transform: uppercase; }

.red {color: #b91c1c; font-weight: bold;}

.trainer-info {margin-top: 20px;}


.hall-title-main {
    font-size: 2.5rem;
    font-weight: 300;
    text-align: center;
    color: #ffffff;
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
}

.hall-title-red {
    color: #821616; /* Тот же красный, что на кнопке */
    font-weight: 700;
}

/* Блок описания */
.hall-description {
    color: #d4d4d8;
    font-size: 0.9rem;
    line-height: 1.6;
    text-align: center;
    margin: 2rem 0;
    padding: 0 1rem;
}

/* Сетка для фото */

.gallery-section-wrapper {
    width: 100%;
    margin-top: 2rem;
    padding: 0 1rem;
}

/* Заголовок блока (ВХОД, ЗАЛ и т.д.) */
.block-header {
    font-size: 1.5rem;
    font-weight: 300;
    color: #ffffff;
    letter-spacing: 0.15em;
    text-align: center;
    margin: 2rem 0 1rem 0;
    position: relative;
}

/* Линия под заголовком */
.block-header::after {
    content: "";
    display: block;
    width: 100px;
    height: 1px;
    background: linear-gradient(90deg, transparent, #821616, transparent);
    margin: 0.5rem auto 0 auto;
}

/* Сетка блоков */
.gallery-scroll-container {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    
    padding: 0 15px; /* Вот здесь вы задаете отступ ОТ КРАЯ ЭКРАНА */
    box-sizing: border-box; /* Чтобы padding не ломал ширину */
    
    gap: 20px; /* Расстояние между фотками */
    -webkit-overflow-scrolling: touch;
    margin-bottom: 100px;

}

/* Скрываем скроллбар — это безопасно и не ломает отображение */
.gallery-scroll-container::-webkit-scrollbar {
    display: none;
}



/* Сами блоки с фото */
.gallery-item {
    flex: 0 0 95%; /* 80% ширины экрана */
    height: 280px; /* Фиксированная высота для теста */
    background-color: #222; /* Серый фон, чтобы видеть блок, если фото не загрузилось */
    border-radius: 2px;
    overflow: hidden;
    display: flex; /* Чтобы картинка центрировалась */
    align-items: center;
    justify-content: center;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
