/* ========================================
   EventSite - Modern CSS Styles
   ======================================== */

/* Основные переменные */
:root {
    --primary-color: #6c5ce7;
    --primary-dark: #5849c2;
    --primary-light: #a29bfe;
    --secondary-color: #00cec9;
    --accent-color: #fd79a8;
    --text-dark: #2d3436;
    --white: #ffffff;
    --text-muted: #b2bec3;
    --bg-light: #f8f9fa;
    --bg-dark: #1e272e;
    --white: #ffffff;
    --success: #00b894;
    --warning: #fdcb6e;
    --danger: #d63031;
    --info: #0984e3;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --border-radius: 12px;
    --border-radius-sm: 8px;
    --border-radius-lg: 20px;
}

/* Сброс стилей */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, 'Roboto', 'Oxygen', 'Ubuntu', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--white);
    overflow-x: hidden;
}

/* Контейнер */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Типографика */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 { font-size: 3rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.25rem; }

p {
    margin-bottom: 1rem;
    color: var (--text-ligh);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ========================================
   Навигация
   ======================================== */
.navbar {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: var(--transition);
}

.navbar.scrolled {
    box-shadow: var(--shadow);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-brand a {
    font-size: 26px;
    font-weight: 800;
    color: var(--text-dark);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.nav-brand span {
    color: var(--primary-color);
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu ul {
    display: flex;
    list-style: none;
    gap: 35px;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    font-size: 15px;
    position: relative;
    padding: 5px 0;
    transition: var(--transition);
}

.nav-menu a:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: var(--transition);
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary-color);
}

.nav-menu a:hover:after,
.nav-menu a.active:after {
    width: 100%;
}

.nav-auth {
    display: flex;
    gap: 12px;
}

.nav-auth a {
    padding: 10px 20px;
    border-radius: var(--border-radius-sm);
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-login {
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    background: transparent;
}

.btn-login:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-2px);
}

.btn-register {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: var(--white);
    border: none;
}

.btn-register:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(108, 92, 231, 0.4);
}

.btn-profile {
    background: linear-gradient(135deg, var(--secondary-color), #00b5b0);
    color: var(--white);
}

.btn-profile:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(0, 206, 201, 0.4);
}

.btn-logout {
    color: var(--text-light);
    border: 2px solid var(--text-muted);
}

.btn-logout:hover {
    background: var(--text-dark);
    color: var(--white);
    border-color: var(--text-dark);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    border-radius: 3px;
    transition: var(--transition);
}

/* ========================================
   Hero секция со слайдером
   ======================================== */
.hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    overflow: hidden;
    margin-top: 70px;
}

.slider {
    height: 100%;
    position: relative;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
}

.slide:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.7), rgba(0, 0, 0, 0.6));
}

.slide.active {
    opacity: 1;
}

.slide .container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 900px;
}

.slide h1 {
    font-size: 56px;
    margin-bottom: 20px;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 0.8s ease;
}

.slide p {
    font-size: 20px;
    margin-bottom: 35px;
    color: rgba(255, 255, 255, 0.95);
    animation: fadeInUp 0.8s ease 0.2s both;
}

.slider-controls button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    color: var(--white);
    border: 2px solid rgba(255, 255, 255, 0.3);
    width: 55px;
    height: 55px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    transition: var(--transition);
    z-index: 10;
}

.slider-controls button:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: translateY(-50%) scale(1.1);
}

.slider-prev {
    left: 30px;
}

.slider-next {
    right: 30px;
}

.slider-dots {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 10;
}

.dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
}

.dot:hover {
    background: rgba(255, 255, 255, 0.8);
}

.dot.active {
    background: var(--white);
    transform: scale(1.2);
    border-color: var(--primary-color);
}

/* ========================================
   Кнопки
   ======================================== */
.btn {
    display: inline-block;
    padding: 14px 32px;
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: var(--white);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(108, 92, 231, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-3px);
}

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    padding: 10px 24px;
}

.btn-outline:hover {
    background: var(--primary-color);
    color: var(--white);
}

.btn-success {
    background: linear-gradient(135deg, var(--success), #00a383);
    color: var(--white);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger), #c0392b);
    color: var(--white);
}

/* ========================================
   Секции
   ======================================== */
.section-padding {
    padding: 100px 0;
}

.section-padding-sm {
    padding: 60px 0;
}

.bg-light {
    background: var(--bg-light);
}

.bg-dark {
    background: var(--bg-dark);
    color: var(--white);
}

.section-title {
    text-align: center;
    font-size: 42px;
    margin-bottom: 20px;
    position: relative;
    color: var(--text-dark);
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    font-size: 18px;
    max-width: 600px;
    margin: 0 auto 60px;
}

.section-title:after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    margin: 20px auto 0;
    border-radius: 2px;
}

/* ========================================
   Категории
   ======================================== */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.category-card {
    text-align: center;
    padding: 45px 25px;
    background: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.category-card:hover {
    transform: translateY(-15px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.category-card i {
    font-size: 56px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
}

.category-card h3 {
    margin-bottom: 12px;
    color: var(--text-dark);
}

.category-card p {
    color: var(--text-light);
    font-size: 14px;
}

/* ========================================
   Карточки событий
   ======================================== */
.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 35px;
}

.event-card {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.event-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.event-image {
    position: relative;
    height: 220px;
    overflow: hidden;
}

.event-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.event-card:hover .event-image img {
    transform: scale(1.1);
}

.event-date {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: var(--white);
    padding: 8px 16px;
    border-radius: var(--border-radius-sm);
    font-weight: 700;
    font-size: 14px;
    box-shadow: 0 3px 10px rgba(108, 92, 231, 0.3);
}

.event-content {
    padding: 25px;
}

.event-content h3 {
    margin-bottom: 12px;
    font-size: 20px;
    color: var(--text-dark);
    line-height: 1.4;
}

.event-short-desc {
    color: var(--text-light);
    margin-bottom: 18px;
    font-size: 14px;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.event-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 18px;
    font-size: 14px;
    color: var(--text-light);
    flex-wrap: wrap;
}

.event-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.event-meta i {
    color: var(--primary-color);
    font-size: 16px;
}

.event-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 18px;
    border-top: 1px solid var(--bg-light);
}

.event-price {
    font-size: 22px;
    font-weight: 700;
    color: var(--primary-color);
}

/* ========================================
   Отзывы
   ======================================== */
.reviews-slider {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.review-card {
    background: var(--white);
    padding: 35px;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.review-rating {
    margin-bottom: 18px;
    display: flex;
    gap: 5px;
}

.review-rating i {
    color: #ddd;
    font-size: 18px;
}

.review-rating i.active {
    color: #fdcb6e;
}

.review-text {
    font-style: italic;
    margin-bottom: 20px;
    color: var(--text-light);
    line-height: 1.8;
    font-size: 15px;
}

.review-text:before {
    content: '"';
    font-size: 40px;
    color: var(--primary-light);
    line-height: 1;
    margin-right: 5px;
}

.review-text:after {
    content: '"';
    font-size: 40px;
    color: var(--primary-light);
    line-height: 1;
    margin-left: 5px;
}

.review-author {
    border-top: 1px solid var(--bg-light);
    padding-top: 18px;
}

.review-author strong {
    display: block;
    color: var(--text-dark);
    font-weight: 600;
    margin-bottom: 4px;
}

.review-author span {
    font-size: 13px;
    color: var(--text-muted);
}

/* ========================================
   Контактная форма
   ======================================== */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.contact-info h2 {
    font-size: 36px;
    margin-bottom: 20px;
    color: var(--text-dark);
}

.contact-info > p {
    color: var(--text-light);
    margin-bottom: 35px;
    font-size: 16px;
}

.contact-details {
    margin-top: 30px;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 25px;
}

.contact-item i {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.contact-item span {
    color: var(--text-dark);
    font-size: 16px;
    padding-top: 12px;
}

.form {
    background: var(--white);
    padding: 40px;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 25px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 15px 18px;
    border: 2px solid #e9ecef;
    border-radius: var(--border-radius-sm);
    font-size: 15px;
    font-family: inherit;
    transition: var(--transition);
    background: var(--white);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(108, 92, 231, 0.1);
}

.form-group textarea {
    min-height: 140px;
    resize: vertical;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-dark);
    font-size: 14px;
}

/* ========================================
   Футер
   ======================================== */
.footer {
    background: linear-gradient(135deg, var(--bg-dark), #2d3436);
    color: var(--white);
    padding: 70px 0 25px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 50px;
    margin-bottom: 50px;
}

.footer-col h4 {
    margin-bottom: 25px;
    font-size: 18px;
    color: var(--white);
    position: relative;
    padding-bottom: 12px;
}

.footer-col h4:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

.footer-col p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
    font-size: 15px;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 12px;
}

.footer-col a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition);
    font-size: 15px;
}

.footer-col a:hover {
    color: var(--primary-light);
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.social-links a {
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 18px;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(108, 92, 231, 0.4);
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
}

/* ========================================
   Модальное окно
   ======================================== */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background-color: var(--white);
    margin: 10% auto;
    padding: 40px;
    border-radius: var(--border-radius-lg);
    width: 90%;
    max-width: 500px;
    position: relative;
    animation: slideIn 0.3s ease;
    box-shadow: var(--shadow-lg);
}

.close {
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 28px;
    font-weight: 300;
    cursor: pointer;
    color: var(--text-muted);
    transition: var(--transition);
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close:hover {
    color: var(--text-dark);
    background: var(--bg-light);
}

/* ========================================
   Анимации
   ======================================== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* ========================================
   Вспомогательные классы
   ======================================== */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 1.5rem; }
.mt-3 { margin-top: 2rem; }
.mt-4 { margin-top: 3rem; }

.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 1.5rem; }
.mb-3 { margin-bottom: 2rem; }
.mb-4 { margin-bottom: 3rem; }

.d-flex { display: flex; }
.justify-center { justify-content: center; }
.align-center { align-items: center; }
.gap-1 { gap: 1rem; }
.gap-2 { gap: 1.5rem; }

/* ========================================
   Адаптивность
   ======================================== */
@media (max-width: 1024px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 992px) {
    .slide h1 { font-size: 42px; }
    .contact-grid { grid-template-columns: 1fr; gap: 40px; }
    .section-title { font-size: 36px; }
}

@media (max-width: 768px) {
    .nav-menu,
    .nav-auth {
        display: none;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-menu.active,
    .nav-auth.active {
        display: flex;
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 20px;
        box-shadow: var(--shadow);
    }

    .nav-menu ul {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .nav-auth {
        top: auto;
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    .hero {
        min-height: 500px;
    }

    .slide h1 {
        font-size: 32px;
    }

    .slide p {
        font-size: 16px;
    }

    .section-title {
        font-size: 28px;
    }

    .section-padding {
        padding: 60px 0;
    }

    .events-grid {
        grid-template-columns: 1fr;
    }

    .slider-controls button {
        width: 45px;
        height: 45px;
        font-size: 16px;
    }

    .slider-prev { left: 15px; }
    .slider-next { right: 15px; }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .categories-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .container {
        padding: 0 15px;
    }

    .btn {
        padding: 12px 24px;
        font-size: 14px;
    }

    .category-card {
        padding: 35px 20px;
    }

    .form {
        padding: 25px;
    }

    .event-footer {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }
}

/* ========================================
   Уведомления (Alerts)
   ======================================== */
.alert {
    padding: 15px 20px;
    border-radius: var(--border-radius-sm);
    margin-bottom: 20px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 12px;
    animation: slideIn 0.3s ease;
}

.alert i {
    font-size: 20px;
}

.alert-success {
    background: rgba(0, 184, 148, 0.1);
    color: var(--success);
    border: 1px solid rgba(0, 184, 148, 0.2);
}

.alert-danger {
    background: rgba(214, 48, 49, 0.1);
    color: var(--danger);
    border: 1px solid rgba(214, 48, 49, 0.2);
}

.alert-warning {
    background: rgba(253, 203, 110, 0.1);
    color: #b7890b;
    border: 1px solid rgba(253, 203, 110, 0.2);
}

.alert-info {
    background: rgba(9, 132, 227, 0.1);
    color: var(--info);
    border: 1px solid rgba(9, 132, 227, 0.2);
}

/* ========================================
   Загрузчик (Loader)
   ======================================== */
.loader {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid var(--bg-light);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ========================================
   Плавная прокрутка
   ======================================== */
html {
    scroll-behavior: smooth;
}

/* ========================================
   Скрытие полосы прокрутки для горизонтальных элементов
   ======================================== */
.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.no-scrollbar::-webkit-scrollbar {
    display: none;
}
