/* ========== Основные стили ========== */
:root {
    --primary-color: #7E57C2;
    --primary-light: #B085F5;
    --primary-dark: #4D2C91;
    --secondary-color: #64B5F6;
    --accent-color: #FFD54F;
    --text-color: #424242;
    --text-light: #757575;
    --bg-color: #FFFFFF;
    --bg-light: #F5F5F5;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --animation-slow: 1.2s;
    --animation-medium: 0.8s;
    --animation-fast: 0.4s;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--bg-color);
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: 'Playfair Display', serif;
    font-weight: 500;
}

h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

p {
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: color var(--animation-fast) ease;
}

a:hover {
    color: var(--primary-dark);
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.section-title {
    text-align: center;
    position: relative;
    margin-bottom: 3rem;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 3px;
    background: linear-gradient(to right, var(--primary-light), var(--primary-dark));
    margin: 0.8rem auto 0;
    border-radius: 50px;
}

/* ========== Анимации ========== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes scaleIn {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@keyframes slideInLeft {
    from { transform: translateX(-50px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes slideInRight {
    from { transform: translateX(50px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

/* Анимации при прокрутке */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity var(--animation-medium) ease-out, 
                transform var(--animation-medium) ease-out;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Анимации при загрузке */
.animate-in {
    animation: fadeIn var(--animation-medium) ease-out forwards;
}

.animate-in-delay {
    opacity: 0;
    animation: fadeIn var(--animation-medium) ease-out forwards;
    animation-delay: var(--animation-fast);
}

.animate-in-delay-2 {
    opacity: 0;
    animation: fadeIn var(--animation-medium) ease-out forwards;
    animation-delay: calc(var(--animation-fast) * 2);
}

/* ========== Кнопки ========== */
.btn {
    display: inline-block;
    padding: 12px 28px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary-color));
    color: white;
    border-radius: 50px;
    text-align: center;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--animation-fast) ease;
    box-shadow: 0 4px 15px rgba(126, 87, 194, 0.3);
    border: none;
}

.btn:hover {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    box-shadow: 0 6px 20px rgba(126, 87, 194, 0.4);
    transform: translateY(-2px);
    color: white;
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(126, 87, 194, 0.3);
}

/* ========== Шапка сайта ========== */
.header {
    position: absolute;
    width: 100%;
    top: 0;
    left: 0;
    z-index: 100;
    padding: 20px 0;
    transition: background var(--animation-fast) ease;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.main-nav ul {
    display: flex;
    list-style: none;
}

.main-nav li {
    margin-left: 30px;
}

.main-nav a {
    color: white;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    position: relative;
}

.main-nav a:hover {
    color: var(--accent-color);
}

.main-nav a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    transition: width var(--animation-fast) ease;
}

.main-nav a:hover::after {
    width: 100%;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: white;
    margin-bottom: 5px;
    border-radius: 5px;
    transition: all var(--animation-fast) ease;
}

/* ========== Главный экран ========== */
.hero-section {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background-color: var(--primary-dark);
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.6)), url('./img/NkEDz8.jpg');
    background-size: cover;
    background-position: center;
    z-index: 0;
    filter: brightness(0.9);
    transform: scale(1.05);
    animation: scaleIn var(--animation-slow) ease-out forwards;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: white;
    max-width: 800px;
}

.hero-content h1 {
    font-weight: 700;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    margin-bottom: 1.5rem;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

/* ========== Философия ========== */
.philosophy-section {
    padding: 120px 0;
    background-color: var(--bg-light);
    position: relative;
    overflow: hidden;
}

.philosophy-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('./img/O45Zna.jpg');
    opacity: 0.05;
    z-index: 0;
}

.philosophy-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 1;
}

.philosophy-text {
    font-size: 1.4rem;
    line-height: 1.8;
    margin-bottom: 2rem;
    color: var(--text-color);
    transition: transform var(--animation-medium) ease, opacity var(--animation-medium) ease;
}

/* ========== Тренировки ========== */
.classes-section {
    padding: 120px 0;
    background-color: var(--bg-color);
}

.classes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

.class-card {
    height: 250px;
    perspective: 1000px;
    border-radius: 15px;
    overflow: hidden;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform var(--animation-medium) ease;
    transform-style: preserve-3d;
    box-shadow: 0 10px 30px var(--shadow-color);
    border-radius: 15px;
}

.class-card:hover .card-inner {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    text-align: center;
}

.card-front {
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.6)), url('./img/NSIktt.jpg');
    background-size: cover;
    background-position: center;
    color: white;
}

.card-back {
    background: linear-gradient(120deg, var(--primary-light), var(--primary-dark));
    color: white;
    transform: rotateY(180deg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-front h3 {
    margin-bottom: 15px;
    font-weight: 600;
}

/* ========== Расписание ========== */
.schedule-section {
    padding: 120px 0;
    background-color: var(--bg-light);
}

.schedule-table-container {
    overflow-x: auto;
    box-shadow: 0 10px 30px var(--shadow-color);
    border-radius: 15px;
    background-color: white;
}

.schedule-table {
    width: 100%;
    border-collapse: collapse;
    text-align: center;
}

.schedule-table th, .schedule-table td {
    padding: 15px;
    border-bottom: 1px solid #eee;
}

.schedule-table th {
    background-color: var(--primary-color);
    color: white;
    font-weight: 500;
}

.schedule-table tr:last-child td {
    border-bottom: none;
}

.schedule-table tr:nth-child(even) {
    background-color: #f9f9f9;
}

.schedule-table tr:hover td {
    background-color: #f1f1f1;
}

/* Выделение текущего дня */
.schedule-table th.current-day,
.schedule-table td.current-day {
    background-color: var(--primary-light);
    color: white;
}

/* ========== Форма записи ========== */
.signup-section {
    padding: 120px 0;
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.8)), url('./img/oQL8Vk.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
}

.signup-container {
    max-width: 600px;
    margin: 0 auto;
    background-color: rgba(255, 255, 255, 0.9);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
}

.signup-container .section-title {
    color: var(--text-color);
}

.signup-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    position: relative;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 15px;
    border: 2px solid #eee;
    border-radius: 10px;
    background-color: white;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    transition: all var(--animation-fast) ease;
}

.form-group input:focus,
.form-group select:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(126, 87, 194, 0.2);
}

.form-group input::placeholder {
    color: #aaa;
}

.signup-form .btn {
    align-self: center;
    margin-top: 10px;
}

/* Стили для ошибок формы */
.form-error {
    background-color: rgba(255, 76, 76, 0.1);
    color: #ff4c4c;
    padding: 12px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-weight: 500;
    text-align: center;
    border-left: 4px solid #ff4c4c;
}

/* ========== Отзывы ========== */
.testimonials-section {
    padding: 120px 0;
    background-color: var(--bg-color);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.testimonial-card {
    background-color: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px var(--shadow-color);
    transition: transform var(--animation-fast) ease, box-shadow var(--animation-fast) ease;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px var(--shadow-color);
}

.testimonial-content {
    padding: 30px;
    position: relative;
}

.testimonial-content::before {
    content: '"';
    font-family: 'Playfair Display', serif;
    font-size: 5rem;
    color: rgba(126, 87, 194, 0.1);
    position: absolute;
    top: 10px;
    left: 15px;
    line-height: 1;
}

.testimonial-content p {
    position: relative;
    z-index: 1;
    font-style: italic;
    margin-bottom: 15px;
}

.testimonial-author {
    font-weight: 600;
    color: var(--primary-color);
    text-align: right;
}

/* ========== Галерея ========== */
.gallery-section {
    padding: 120px 0;
    background-color: var(--bg-light);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 15px;
    height: 250px;
    box-shadow: 0 10px 30px var(--shadow-color);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform var(--animation-medium) ease, filter var(--animation-medium) ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
    filter: brightness(0.8) blur(3px);
}

.gallery-item::after {
    content: '⟲';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    font-size: 2rem;
    color: white;
    z-index: 2;
    opacity: 0;
    transition: all var(--animation-medium) ease;
}

.gallery-item:hover::after {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

/* ========== Блог ========== */
.blog-section {
    padding: 120px 0;
    background-color: var(--bg-color);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.blog-card {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px var(--shadow-color);
    transition: transform var(--animation-fast) ease, box-shadow var(--animation-fast) ease;
    background-color: white;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px var(--shadow-color);
}

.blog-image {
    height: 200px;
    overflow: hidden;
}

.blog-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--animation-medium) ease;
}

.blog-card:hover .blog-image img {
    transform: scale(1.05);
}

.blog-content {
    padding: 25px;
}

.blog-content h3 {
    margin-bottom: 15px;
    transition: color var(--animation-fast) ease;
}

.blog-card:hover .blog-content h3 {
    color: var(--primary-color);
}

.read-more {
    display: inline-block;
    margin-top: 15px;
    font-weight: 600;
    color: var(--primary-color);
    position: relative;
}

.read-more::after {
    content: '→';
    margin-left: 5px;
    transition: transform var(--animation-fast) ease;
    display: inline-block;
}

.read-more:hover::after {
    transform: translateX(5px);
}

/* ========== Контакты ========== */
.contacts-section {
    padding: 120px 0;
    background-color: var(--bg-light);
}

.contacts-container {
    display: flex;
    gap: 40px;
    justify-content: space-between;
    align-items: flex-start;
}

.contact-info {
    flex: 1;
}

.contact-detail {
    margin-bottom: 30px;
}

.contact-detail h3 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.contact-map {
    flex: 1;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px var(--shadow-color);
}

.contact-map img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ========== Политики ========== */
.policies-section {
    padding: 120px 0;
    background-color: var(--bg-color);
}

.policies-container {
    max-width: 900px;
    margin: 0 auto;
}

.tabs {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px var(--shadow-color);
    background-color: white;
}

.tab-buttons {
    display: flex;
    background-color: var(--primary-color);
}

.tab-button {
    flex: 1;
    padding: 15px;
    text-align: center;
    color: white;
    font-weight: 500;
    cursor: pointer;
    transition: background var(--animation-fast) ease;
    border-bottom: 3px solid transparent;
}

.tab-button:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.tab-button.active {
    background-color: rgba(255, 255, 255, 0.2);
    border-bottom-color: var(--accent-color);
}

.tab-content {
    position: relative;
}

.tab-content input[type="radio"] {
    display: none;
}

.content {
    padding: 30px;
    display: none;
}

#tab1:checked ~ .content1,
#tab2:checked ~ .content2,
#tab3:checked ~ .content3,
#tab4:checked ~ .content4 {
    display: block;
    animation: fadeIn var(--animation-fast) ease-out forwards;
}

/* ========== Футер ========== */
.footer {
    background-color: var(--primary-dark);
    padding: 60px 0 30px;
    color: white;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: 40px;
}

.footer-logo {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.footer-nav ul {
    list-style: none;
}

.footer-nav li {
    margin-bottom: 10px;
}

.footer-nav a {
    color: rgba(255, 255, 255, 0.8);
    transition: color var(--animation-fast) ease;
}

.footer-nav a:hover {
    color: var(--accent-color);
}

.footer-contact p {
    margin-bottom: 10px;
    color: rgba(255, 255, 255, 0.8);
}

.footer-bottom {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* ========== Куки ========== */
.cookies-popup {
    position: fixed;
    bottom: -100px;
    left: 0;
    width: 100%;
    background-color: white;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.1);
    padding: 20px 0;
    z-index: 1000;
    transition: transform var(--animation-medium) ease;
    transform: translateY(100px);
    opacity: 0;
}

.cookies-popup.show {
    transform: translateY(0);
    opacity: 1;
}

.cookies-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    padding: 0 20px;
}

.cookies-content p {
    margin-bottom: 0;
    flex: 1;
}

.cookies-buttons {
    display: flex;
    gap: 15px;
}

.btn-accept {
    background: linear-gradient(135deg, var(--primary-light), var(--primary-color));
}

.btn-reject {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-reject:hover {
    background: rgba(126, 87, 194, 0.1);
    color: var(--primary-dark);
}

/* ========== Адаптивность ========== */
@media screen and (max-width: 1024px) {
    h1 {
        font-size: 3rem;
    }
    
    h2 {
        font-size: 2.2rem;
    }
    
    .contacts-container {
        flex-direction: column;
    }
    
    .contact-map {
        width: 100%;
        height: 300px;
    }
}

@media screen and (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }
    
    h2 {
        font-size: 2rem;
    }
    
    .main-nav {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .philosophy-text {
        font-size: 1.2rem;
    }
    
    .tab-buttons {
        flex-direction: column;
    }
    
    .tab-button {
        text-align: left;
        padding: 15px 20px;
        border-left: 3px solid transparent;
        border-bottom: none;
    }
    
    .tab-button.active {
        border-left-color: var(--accent-color);
        border-bottom-color: transparent;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 30px;
    }
    
    .footer-logo, .footer-nav, .footer-contact {
        width: 100%;
    }
    
    .cookies-content {
        flex-direction: column;
        text-align: center;
    }
}

@media screen and (max-width: 480px) {
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.8rem;
    }
    
    .section-title {
        margin-bottom: 2rem;
    }
    
    .blog-grid, .testimonials-grid, .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .signup-container {
        padding: 30px 20px;
    }
    
    .content {
        padding: 20px;
    }
}

/* ========== JS-free Mobile Navigation (CSS only) ========== */
.mobile-nav-input {
    display: none;
}

.mobile-nav {
    position: fixed;
    top: 0;
    right: -300px;
    width: 250px;
    height: 100vh;
    background-color: var(--primary-color);
    z-index: 200;
    padding: 60px 0 30px;
    transition: right var(--animation-medium) ease;
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.2);
}

.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 190;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--animation-medium) ease, visibility var(--animation-medium) ease;
}

.mobile-nav-input:checked ~ .mobile-nav {
    right: 0;
}

.mobile-nav-input:checked ~ .mobile-nav-overlay {
    opacity: 1;
    visibility: visible;
}

.mobile-nav ul {
    list-style: none;
    padding: 0;
}

.mobile-nav li {
    margin-bottom: 15px;
}

.mobile-nav a {
    display: block;
    padding: 10px 30px;
    color: white;
    transition: background var(--animation-fast) ease;
}

.mobile-nav a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.mobile-nav-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 30px;
    height: 30px;
    cursor: pointer;
}

.mobile-nav-close::before,
.mobile-nav-close::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: white;
}

.mobile-nav-close::before {
    transform: rotate(45deg);
}

.mobile-nav-close::after {
    transform: rotate(-45deg);
}

/* CSS-only Scroll Animations */
@media (prefers-reduced-motion: no-preference) {
    .animate-on-scroll {
        transition: opacity var(--animation-medium) ease-out, transform var(--animation-medium) ease-out;
        opacity: 0;
        transform: translateY(30px);
    }
    
    .animate-on-scroll.visible {
        opacity: 1;
        transform: translateY(0);
    }
} 