/* ========================================
   Общие стили и переменные
   ======================================== */
:root {
    --primary-color: #2563eb;
    --secondary-color: #10b981;
    --accent-color: #f59e0b;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --bg-light: #f9fafb;
    --bg-white: #ffffff;
    --border-color: #e5e7eb;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

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

/* ========================================
   Анимация появления секций
   ======================================== */
section.section-animate {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

section.section-visible {
    opacity: 1;
    transform: translateY(0);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========================================
   Типографика
   ======================================== */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-dark);
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.75rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 3vw, 1.75rem); }

.lead {
    font-size: 1.25rem;
    line-height: 1.7;
    color: var(--text-light);
}

/* ========================================
   Кнопки
   ======================================== */
.btn {
    display: inline-block;
    padding: 12px 32px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 8px;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-family: 'Montserrat', sans-serif;
}

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

.btn-primary:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

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

.btn-small {
    padding: 8px 20px;
    font-size: 0.9rem;
}

.btn-large {
    padding: 16px 48px;
    font-size: 1.1rem;
}

/* ========================================
   Header & Navigation
   ======================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow-sm);
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo h2 {
    font-size: 1.25rem;
    color: var(--primary-color);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 600;
    transition: var(--transition);
}

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

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

.burger span {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    transition: var(--transition);
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding-top: 80px;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="40" fill="rgba(255,255,255,0.05)"/></svg>');
    opacity: 0.3;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    color: white;
    text-align: center;
    margin: 0 auto;
}

.hero-title {
    margin-bottom: 1rem;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.hero-description {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ========================================
   Stats Section
   ======================================== */
.stats {
    background: var(--bg-white);
    padding: 4rem 0;
    box-shadow: var(--shadow-md);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.stat-item {
    text-align: center;
    padding: 1.5rem;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* ========================================
   Section Styles
   ======================================== */
section {
    padding: 5rem 0;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-tag {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: var(--bg-light);
    color: var(--primary-color);
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.section-title {
    margin-bottom: 1rem;
}

.section-description {
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

/* ========================================
   About Section
   ======================================== */
.about {
    background: var(--bg-light);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.feature-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.feature-item {
    display: flex;
    gap: 1.5rem;
}

.feature-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feature-icon i {
    width: 40px;
    height: 40px;
    color: var(--primary-color);
}

.feature-text h4 {
    margin-bottom: 0.5rem;
}

.feature-text p {
    color: var(--text-light);
}

.about-image {
    margin: 16px 0;
}

.about-image .image-wrapper {
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.about-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* ========================================
   Relevance Section
   ======================================== */
.relevance {
    background: var(--bg-white);
}

.relevance-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.relevance-card {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: 12px;
    position: relative;
    transition: var(--transition);
}

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

.card-number {
    position: absolute;
    top: -15px;
    right: 20px;
    font-size: 4rem;
    font-weight: 700;
    color: var(--primary-color);
    opacity: 0.1;
}

.relevance-card h3 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.relevance-card p {
    color: var(--text-light);
}

/* ========================================
   Courses Section
   ======================================== */
.courses {
    background: var(--bg-light);
}

.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.course-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    transition: var(--transition);
    border: 2px solid transparent;
}

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

.course-card.featured {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
}

.course-card.featured h3,
.course-card.featured p {
    color: white;
}

.course-icon {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.course-icon i {
    width: 48px;
    height: 48px;
    color: var(--primary-color);
}

.course-card.featured .course-icon i {
    color: white;
}

.course-card h3 {
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.course-card p {
    color: var(--text-light);
    font-size: 0.95rem;
}

.motto {
    text-align: center;
    margin-top: 3rem;
    padding: 2rem;
}

.motto blockquote {
    font-size: 1.5rem;
    color: var(--text-dark);
    font-style: italic;
    max-width: 800px;
    margin: 0 auto;
}

/* ========================================
   Geography Section
   ======================================== */
.geography {
    background: var(--bg-white);
}

.geography-content {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.geography-description {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.advantages-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.advantages-list li {
    padding: 1rem;
    margin-bottom: 0.5rem;
    background: var(--bg-light);
    border-radius: 8px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.advantages-list li i {
    width: 24px;
    height: 24px;
    color: var(--secondary-color);
    flex-shrink: 0;
}

.map-placeholder {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.map-placeholder img {
    width: 100%;
    height: auto;
    display: block;
}

.map-container {
    width: 100%;
    height: 400px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

#yandex-map {
    width: 100%;
    height: 100%;
}

/* ========================================
   Facilities Section
   ======================================== */
.facilities {
    background: var(--bg-light);
}

.facility-block {
    background: white;
    padding: 3rem;
    border-radius: 16px;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-md);
}

.facility-block.alt {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
}

.facility-content h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.facility-content h4 {
    margin: 1.5rem 0 1rem;
    color: var(--secondary-color);
}

.features-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

.therapy-list {
    list-style: none;
}

.therapy-list li {
    padding: 1rem;
    margin-bottom: 1rem;
    background: rgba(37, 99, 235, 0.05);
    border-left: 4px solid var(--primary-color);
    border-radius: 4px;
}

/* ========================================
   Team Section
   ======================================== */
.team {
    background: var(--bg-white);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.team-category {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: 12px;
}

.team-category h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-color);
}

.team-category ul {
    list-style: none;
}

.team-category li {
    padding: 0.5rem 0;
    color: var(--text-light);
}

.partners {
    margin-top: 4rem;
}

.partners h3 {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--primary-color);
}

.partners-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.partner-item {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: 12px;
}

.partner-item h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.partner-item p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* ========================================
   Funding Section
   ======================================== */
.funding {
    background: var(--bg-light);
}

.funding-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.funding-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    position: relative;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    min-height: 280px;
}

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

.funding-number {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
    opacity: 0.1;
}

.funding-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    padding-right: 3rem;
}

.funding-card ul {
    list-style: none;
    margin-top: auto;
}

.funding-card li {
    padding: 0.5rem 0;
    color: var(--text-light);
    padding-left: 1.5rem;
    position: relative;
}

.funding-card li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--secondary-color);
    font-weight: bold;
}

/* ========================================
   Contact Section
   ======================================== */
.contact {
    background: var(--bg-white);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group.full {
    grid-column: 1 / -1;
}

.form-group label {
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-dark);
}

.form-group input,
.form-group textarea {
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.contact-form button {
    grid-column: 1 / -1;
}

.form-note {
    grid-column: 1 / -1;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-light);
}

.contact-info {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: 12px;
    height: fit-content;
}

.contact-info h3 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.contact-item {
    margin-bottom: 1.5rem;
}

.contact-item strong {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.contact-item p {
    color: var(--text-light);
}

.contact-item a {
    color: var(--primary-color);
    text-decoration: none;
}

.contact-item a:hover {
    text-decoration: underline;
}

/* ========================================
   Footer
   ======================================== */
.footer {
    background: var(--text-dark);
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-info h3 {
    color: white;
    margin-bottom: 1rem;
}

.footer-info p {
    color: rgba(255, 255, 255, 0.7);
}

.footer-links h4,
.footer-contact h4 {
    color: white;
    margin-bottom: 1rem;
}

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

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: white;
}

.footer-contact p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.5rem;
}

.footer-contact a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
}

.footer-contact a:hover {
    color: white;
}

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

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

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 968px) {
    .about-grid {
        grid-template-columns: 1fr;
    }

    .contact-wrapper {
        grid-template-columns: 1fr;
    }

    .features-two-col {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .funding-grid {
        grid-template-columns: 1fr;
    }

    .advantages-list {
        grid-template-columns: 1fr;
    }

    .feature-list {
        grid-template-columns: 1fr;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow-lg);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .burger {
        display: flex;
    }

    .hero {
        min-height: 80vh;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-form {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }

    .hero-buttons .btn {
        width: 100%;
    }

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