/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --beige-50:  #fffaf3;
    --beige-100: #fdf5e6;
    --beige-200: #f6e9d5;
    --beige-300: #f0dcbf;
    --beige-400: #e3cda7;
    --beige-500: #d7b68f;
    --beige-600: #c29e78;
    --beige-700: #a88361;
    --beige-800: #8f6a4d;
    --beige-900: #6e5239;

    --accent-yellow: #f4c27f;
    --accent-coral:  #e68f6d;
    --accent-mint:   #dce5c0;

    --text-primary:   #3d2b1f;
    --text-secondary: #6b5c4b;
    --text-muted:     #9c8b7b;
}

html, body {
    overflow-x: hidden;
    width: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Helvetica Neue', Arial, 'Noto Sans', 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', sans-serif;
    line-height: 1.75;
    color: var(--text-secondary);
    background-color: var(--beige-50);
}

.container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

/* Адаптивные изображения и видео */
img, video {
    max-width: 100%;
    height: auto;
    display: block;
}

iframe {
    max-width: 100%;
}

/* Header */
header {
    background: linear-gradient(135deg, var(--beige-300) 0%, var(--beige-200) 50%, var(--beige-100) 100%);
    color: var(--text-primary);
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Headings hierarchy */
h1, h2, h3 {
    color: var(--text-primary);
    letter-spacing: -0.01em;
}

h1 { font-weight: 800; }
h2 { font-weight: 700; }
h3 { font-weight: 600; color: var(--text-secondary); }

/* Comfortable paragraph reading */
section p {
    font-size: 1.125rem;
    line-height: 1.8;
    max-width: 750px;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
}
.logo-link {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 700;
    transition: opacity 0.3s ease;
    opacity: 0;
    animation: fadeInLogo 1.2s ease forwards;
    animation-delay: 0.3s;
}

.logo-link:hover {
    opacity: 0.85;
}

.logo-img {
    height: 40px;
    width: auto;
    border-radius: 8px;
    object-fit: contain;
}

@media (max-width: 480px) {
    .logo-img {
        height: 28px;
    }
}

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

nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.lang-switcher {
    display: flex;
    gap: 10px;
    align-items: center;
}

.lang-btn {
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.lang-btn:hover {
    transform: scale(1.1);
    opacity: 0.9;
}

.lang-btn.active {
    text-decoration: underline;
    color: var(--accent-yellow);
}

nav a {
    color: var(--text-primary);
    text-decoration: none;
    transition: opacity 0.3s;
}

nav a:hover {
    opacity: 0.8;
}

/* Hero Section */
.hero {
    background: linear-gradient(180deg, var(--beige-200) 0%, var(--beige-100) 50%, var(--beige-50) 100%);
    color: var(--text-primary);
    padding: 120px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="3" fill="rgba(255,255,255,0.1)"/><circle cx="80" cy="40" r="2" fill="rgba(255,255,255,0.1)"/><circle cx="40" cy="80" r="4" fill="rgba(255,255,255,0.1)"/></svg>') repeat;
    opacity: 0.3;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3.25rem;
    margin-bottom: 1rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Focus hero paragraph width */
.hero p { max-width: 700px; margin-left: auto; margin-right: auto; }

.cta-button {
    background: var(--accent-yellow);
    color: var(--text-primary);
    padding: 0.875rem 1.5rem;
    border: none;
    border-radius: 0.75rem;
    font-size: 1.0625rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    text-decoration: none;
    display: inline-block;
    box-shadow: 0 6px 14px rgba(244, 194, 127, 0.35);
}

.cta-button:hover {
    background: var(--accent-coral);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(230, 143, 109, 0.35);
}

/* Advantages Section */
.advantages {
    padding: 96px 0;
    background: var(--beige-50);
}

.advantages h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

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

.advantage-card {
    text-align: center;
    padding: 2rem;
    background: var(--beige-100);
    border-radius: 15px;
    transition: transform 0.3s;
}

/* Специальные правила для центрирования последних двух карточек при 6 элементах */
.advantages-grid .advantage-card:nth-child(5) {
    grid-column: 2;
}

.advantages-grid .advantage-card:nth-child(6) {
    grid-column: 3;
}

.advantage-card:hover {
    transform: translateY(-5px);
    background: var(--beige-200);
}

.advantage-icon {
    font-size: 1.75rem;
    margin: 0 auto 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 9999px;
    background-color: var(--accent-mint);
}

/* About Section */
.about {
    padding: 96px 0;
    background: var(--beige-50);
}

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

.about-text h2 {
    color: var(--text-primary);
    margin-bottom: 2rem;
}

.about-image {
    text-align: center;
}

.about-image-content {
    width: 100%;
    height: 100%;
    min-height: 300px;
    object-fit: cover;
    border-radius: 15px;
    transition: transform 0.4s ease;
    position: relative;
}

.about-image-content:hover {
    transform: scale(1.05);
}

.about-image-content::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.4));
    border-radius: 15px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

@media (max-width: 768px) {
    .about-image-content::after {
        opacity: 1;
    }
}

/* Formats Section */
.formats {
    padding: 96px 0;
    background: var(--beige-50);
    text-align: center;
}
.formats::before {
    content: '';
    display: block;
    width: 140px;
    height: 4px;
    border-radius: 9999px;
    background: linear-gradient(90deg, var(--accent-mint), var(--beige-100), var(--accent-yellow));
    margin: 0 auto 1.5rem;
}

.formats h2 {
    font-size: 2.25rem;
    margin-bottom: 3rem;
    color: var(--text-primary);
    font-weight: 700;
}

.formats-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
}

.format-card {
    background: var(--beige-100);
    border-radius: 20px;
    padding: 2.5rem;
    max-width: 420px;
    width: 100%;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.format-card.visible {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.6s ease;
}

.format-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.format-card h3 {
    font-size: 1.35rem;
    color: #0f172a;
    margin-bottom: 1.2rem;
    font-weight: 700;
}

.format-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left;
}

.format-card li {
    font-size: 1.05rem;
    margin-bottom: 0.6rem;
    padding-left: 1.5rem;
    position: relative;
}

.format-card li::before {
    content: "✓";
    color: var(--accent-mint);
    font-weight: bold;
    position: absolute;
    left: 0;
    top: 0;
}

/* Program Section */
.program {
    padding: 96px 0;
    background: var(--beige-50);
}

.program h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

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

.level-card {
    background: var(--beige-100);
    padding: 2rem;
    border-radius: 15px;
    border-left: 5px solid var(--accent-mint);
}

/* Schedule Section */
.schedule {
    background: var(--beige-100);
    padding: 96px 20px;
    text-align: center;
}
.schedule::before {
    content: '';
    display: block;
    width: 140px;
    height: 4px;
    border-radius: 9999px;
    background: linear-gradient(90deg, var(--accent-mint), var(--beige-100), var(--accent-yellow));
    margin: 0 auto 1.5rem;
}

.schedule h2 {
    font-size: 2.25rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 1rem;
}

.schedule-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
}

.schedule-wrapper {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.schedule-column {
    background: var(--beige-50);
    border-radius: 20px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
    padding: 2rem;
    width: 100%;
    max-width: 400px;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    opacity: 0;
    transform: translateY(30px) scale(0.95);
}

.weekdays-column { border-top: 3px solid var(--accent-mint); }

.weekends-column { border-top: 3px solid var(--accent-yellow); }

.schedule-column.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.schedule-column:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

.schedule-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--beige-200);
}

.schedule-column h3 {
    color: var(--text-primary);
    font-size: 1.3rem;
    font-weight: 600;
    margin: 0;
}

.schedule-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.schedule-column li {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 1.05rem;
    color: var(--text-primary);
    background: linear-gradient(135deg, var(--beige-50) 0%, var(--beige-100) 100%);
    border-radius: 12px;
    margin: 0.5rem 0;
    padding: 0.8rem 1rem;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    border-left: 3px solid transparent;
    cursor: pointer;
}

.slot-number {
    font-size: 1.3rem;
    flex-shrink: 0;
}

.slot-time {
    font-weight: 600;
    letter-spacing: 0.3px;
}

/* Разные стили для разного времени суток */
.morning-slot { border-left-color: var(--accent-mint) !important; }

.morning-slot:hover {
    background: linear-gradient(135deg, var(--beige-50) 0%, var(--beige-100) 100%);
    transform: translateX(5px) scale(1.03);
    box-shadow: 0 4px 12px rgba(220, 229, 192, 0.35);
}

.day-slot { border-left-color: var(--accent-yellow) !important; }

.day-slot:hover {
    background: linear-gradient(135deg, var(--beige-50) 0%, var(--beige-100) 100%);
    transform: translateX(5px) scale(1.03);
    box-shadow: 0 4px 12px rgba(244, 194, 127, 0.35);
}

.afternoon-slot { border-left-color: var(--accent-coral) !important; }

.afternoon-slot:hover {
    background: linear-gradient(135deg, var(--beige-50) 0%, var(--beige-100) 100%);
    transform: translateX(5px) scale(1.03);
    box-shadow: 0 4px 12px rgba(230, 143, 109, 0.35);
}

.evening-slot { border-left-color: var(--beige-700) !important; }

.evening-slot:hover {
    background: linear-gradient(135deg, var(--beige-50) 0%, var(--beige-100) 100%);
    transform: translateX(5px) scale(1.03);
    box-shadow: 0 4px 12px rgba(168, 131, 97, 0.35);
}

.weekend-slot { border-left-color: var(--accent-mint) !important; }

.weekend-slot:hover {
    background: linear-gradient(135deg, var(--beige-50) 0%, var(--beige-100) 100%);
    transform: translateX(5px) scale(1.03);
    box-shadow: 0 4px 12px rgba(220, 229, 192, 0.35);
}

/* Pricing Section */
.pricing {
    padding: 96px 0;
    background: var(--beige-50);
}

.pricing-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
    align-items: start;
}

.pricing-table {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.pricing-card {
    background: var(--beige-100);
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.price {
    font-size: 2rem;
    font-weight: bold;
    color: var(--accent-yellow);
    margin: 1rem 0;
}

.pricing-card ul {
    list-style: none;
    padding: 0;
    text-align: left;
}

.pricing-card li {
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
}

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

.pricing-note {
    background: var(--accent-yellow);
    padding: 2rem;
    border-radius: 15px;
    color: var(--text-primary);
}

.pricing-note h3 {
    margin-bottom: 1rem;
    color: #333;
}

.pricing-note p {
    margin-bottom: 0.5rem;
}

/* Testimonials */
.testimonials {
    padding: 96px 0;
    background: var(--beige-100);
}

.testimonials h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  align-items: start;
}

.testimonial-card {
  background: var(--beige-50);
  border-radius: 16px;
  padding: 2.5rem;
  max-width: 100%;
  width: 100%;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  opacity: 0;
  transform: translateY(20px);
}

.testimonial-card.visible {
  opacity: 1;
  transform: translateY(0);
  transition: all 0.6s ease;
}

.testimonial-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.testimonial-video {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease;
}

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

.testimonial-video video {
  width: 100%;
  height: auto;
  max-width: 100%;
  border-radius: 16px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease;
}

.testimonial-video:hover video {
  transform: scale(1.02);
}

.testimonial-text {
  font-style: italic;
  line-height: 1.8;
  margin: 1rem 0 1.5rem;
  white-space: pre-line;
  color: var(--text-secondary);
}

.testimonial-author {
  font-weight: bold;
  color: var(--accent-coral);
  font-size: 1.05rem;
}

/* Location */
.location {
    padding: 96px 0;
    background: var(--beige-50);
}

.location h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

.location-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.location-info {
    padding: 2rem;
}

.map-container {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.map-link {
    color: var(--accent-coral);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.map-link:hover {
    color: var(--accent-yellow);
}

/* 2GIS Widget Styles */
.dg-widget-link {
    display: block;
    margin: 5px 0;
    font-size: 14px;
}

.dg-widget-link a {
    color: var(--accent-coral);
    text-decoration: none;
    transition: color 0.3s;
}

.dg-widget-link a:hover {
    color: var(--accent-yellow);
}

/* Contacts */
.contacts {
    padding: 96px 0;
    background: var(--beige-100);
}

.contacts h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

.contacts-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-form {
    background: var(--beige-50);
    padding: 2rem;
    border-radius: 15px;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--beige-200);
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent-yellow);
}

.contact-info {
    padding: 2rem;
}

.contact-item {
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
}

.contact-icon {
    font-size: 1.5rem;
    margin-right: 1rem;
    color: var(--accent-mint);
}

/* FAQ */
.faq {
    padding: 96px 0;
    background: var(--beige-50);
}

.faq h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

.faq-item {
    background: #f8f9fa;
    margin-bottom: 1rem;
    border-radius: 8px;
    overflow: hidden;
}

.faq-question {
    padding: 1.5rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 500;
    transition: background-color 0.3s;
}

.faq-question:hover {
    background-color: var(--beige-100);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    padding: 0 1.5rem;
    position: relative;
    transition:
      max-height 1s cubic-bezier(0.25, 0.8, 0.25, 1),
      opacity 1s ease,
      padding 1s ease;
  }

.faq-answer.open {
    max-height: 250px;
    opacity: 1;
    padding: 1rem 1.5rem;
  }

/* FAQ typewriter structure */
.faq-answer__source {
    position: absolute;
    opacity: 0;
    pointer-events: none;
    user-select: none;
    height: 0;
    overflow: hidden;
    white-space: pre-wrap;
  }

.faq-answer__typed {
    display: block;
    white-space: pre-wrap;
    transition: opacity 0.3s ease;
  }

.faq-toggle {
    font-size: 1.2rem;
    transition: transform 0.3s;
}

/* Gallery Section */
.gallery {
    padding: 96px 0;
    background: var(--beige-50);
    box-shadow: 0 -5px 15px rgba(0,0,0,0.05);
    animation: fadeInUp 0.6s ease-out;
}

.gallery h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

/* Decorative underline for section h2 */
section h2 {
    display: inline-block;
    position: relative;
}

section h2::after {
    content: '';
    display: block;
    width: 48px;
    height: 4px;
    background: #fbbf24;
    border-radius: 9999px;
    margin-top: 12px;
}

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

.gallery img {
    width: 100%;
    height: 100%;
    min-height: 250px;
    object-fit: cover;
    border-radius: 12px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
    cursor: pointer;
}

.gallery img.visible {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.6s ease;
}

.gallery img:hover {
    transform: scale(1.03);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

/* ============================================
   FOOTER - Современный дизайн
   ============================================ */

footer {
    background: linear-gradient(90deg, #E8D2B0, #D9B88C, #C79E6B);
    color: #FFF8F0;
    padding: 4rem 0 0;
    position: relative;
    box-shadow: 0 -8px 20px rgba(0, 0, 0, 0.15);
    border-top: 1px solid rgba(201, 169, 123, 0.4);
}

/* Контейнер футера */
.footer-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3.5rem;
    margin-bottom: 2.5rem;
    padding: 0 1rem;
}

/* Общие стили секций футера */
.footer-section {
    text-align: left;
}

.footer-section h3 {
    font-size: 1.4rem;
    margin-bottom: 1.2rem;
    color: #FFF8F0;
    font-weight: 600;
    letter-spacing: 0.2px;
    position: relative;
    display: inline-block;
}

.footer-section h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -6px;
    width: 40px;
    height: 3px;
    background: linear-gradient(90deg, rgba(255, 244, 226, 0.85), #FFFFFF);
    border-radius: 2px;
}

/* --- О школе --- */
.footer-about p {
    margin-bottom: 0.8rem;
    line-height: 1.7;
    color: #6E5844;
}

.footer-description {
    font-size: 1.05rem;
    font-weight: 600;
    color: #FFF8F0;
}

.footer-tagline {
    font-size: 0.95rem;
    color: #FDF5E6;
}

.footer-subtitle {
    font-size: 0.9rem;
    color: #FDF5E6;
}

/* --- Контакты --- */
.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-bottom: 1rem;
    transition: transform 0.3s ease;
}

.footer-contact-item:hover {
    transform: translateX(5px);
}

.footer-icon {
    font-size: 1.3rem;
    flex-shrink: 0;
}

.footer-contact-item a {
    color: #FFF4E2;
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
}

.footer-contact-item a:hover,
.footer-contact-item a:visited:hover {
    color: #FFFFFF;
}

.footer-contact-item a:visited { color: #FFF4E2; }

.footer-contact-item span:not(.footer-icon) {
    color: #6E5844;
    line-height: 1.6;
}

/* --- Соцсети --- */
.footer-social-links {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.footer-social-link {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    text-decoration: none;
    color: #FFF8F0;
    font-weight: 600;
    padding: 0.6rem 1rem;
    background: rgba(255, 255, 255, 0.10);
    border-radius: 10px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: saturate(120%) blur(4px);
}

.footer-social-link:hover {
    background: rgba(255, 255, 255, 0.20);
    border-color: rgba(255, 255, 255, 0.35);
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.footer-social-link:visited {
    color: #FFF8F0;
}

.footer-social-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
    border-radius: 4px;
}

/* Юбилейка Кидс */
.kids-card {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 14px;
    padding: 10px 14px;
    margin-top: 18px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.kids-card:hover {
    background: #f5f5f5;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.kids-card img {
    width: 80px;
    height: 80px;
    border-radius: 12px;
    object-fit: cover;
    background-color: white;
    flex-shrink: 0;
}

.kids-card-text {
    color: #1e3a5f;
    font-weight: 600;
    font-size: 15px;
    line-height: 1.3;
}

.kids-card-text b {
    color: #0f2847;
    font-weight: 700;
}

/* --- Copyright секция --- */
.footer-bottom {
    padding: 1.5rem 0;
    text-align: center;
}

.footer-divider {
    width: 100%;
    height: 1px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.2) 50%,
        transparent 100%
    );
    margin-bottom: 1.5rem;
}

.footer-copyright {
    color: rgba(253, 245, 230, 0.8);
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

/* Убираем фиолетовые visited ссылки глобально для футера */
footer a:visited {
    color: inherit;
}

/* Responsive */
/* Tablet и маленькие десктопы */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.1rem;
        line-height: 1.3;
    }

    .hero p {
        font-size: 1.05rem;
    }

    nav ul {
        display: none;
    }

    .location-content,
    .contacts-content,
    .about-content,
    .pricing-content {
        grid-template-columns: 1fr;
    }

    /* Make text appear above image on mobile */
    .about-text {
        order: 1;
    }

    .about-image {
        order: 2;
        margin-bottom: 2rem;
    }

    .schedule {
        padding: 60px 10px;
    }

    .schedule h2 {
        font-size: 1.6rem;
    }

    .schedule-column {
        max-width: 100%;
    }

    .schedule-column h3 {
        font-size: 1.2rem;
    }

    .schedule-header {
        flex-direction: column;
        gap: 0.5rem;
    }

    .slot-number {
        font-size: 1.2rem;
    }

    .slot-time {
        font-size: 0.95rem;
    }

    .advantages-grid,
    .formats-grid,
    .levels,
    .testimonials-grid,
    .pricing-table {
        grid-template-columns: 1fr;
    }

    /* Reset manual grid placement for last two cards on mobile */
    .advantages-grid .advantage-card:nth-child(5),
    .advantages-grid .advantage-card:nth-child(6) {
        grid-column: auto;
    }

    .formats-grid {
        flex-direction: column;
        align-items: center;
    }

    .format-card {
        max-width: 90%;
    }

    /* Галерея - максимум 2 колонки на планшете */
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .gallery h2 {
        font-size: 2rem;
        text-align: center;
    }

    .gallery {
        padding: 60px 0;
    }

    .testimonial-card {
        padding: 1.5rem;
        max-width: 100%;
    }

    .testimonial-video video {
        max-width: 100%;
    }

    .container {
        padding: 0 16px;
    }

    /* Адаптация 2GIS карты */
    .map-container iframe {
        width: 100% !important;
        height: 400px !important;
    }

    /* Футер - планшеты */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }

    .footer-section {
        text-align: center;
    }

    .footer-section h3::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-contact-item {
        justify-content: center;
    }

    .footer-social-links {
        align-items: center;
    }

    .footer-social-link {
        max-width: 320px;
    }
}

/* Мобильные устройства (до 480px) */
@media (max-width: 480px) {
    .hero {
        padding: 100px 0 60px;
    }

    .hero h1 {
        font-size: 1.85rem;
        line-height: 1.3;
    }

    .hero p {
        font-size: 0.98rem;
    }

    .container {
        padding: 0 14px;
    }

    .cta-button {
        padding: 12px 30px;
        font-size: 1rem;
        width: 100%;
        max-width: 100%;
        text-align: center;
        display: block;
        margin: 0 auto;
    }

    .logo {
        font-size: 1.3rem;
    }

    .lang-btn {
        font-size: 0.85rem;
    }

    .testimonial-card {
        padding: 1.2rem;
    }

    /* Галерея - 1 колонка на мобильном */
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .gallery {
        padding: 60px 0;
    }

    .gallery .container {
        padding: 0 16px;
    }

    .gallery h2 {
        font-size: 1.8rem;
        text-align: center;
        margin-bottom: 2rem;
    }

    .gallery img {
        min-height: 200px;
    }

    /* Уменьшение отступов секций */
    section {
        padding: 60px 0;
    }

    .advantages,
    .formats,
    .schedule,
    .pricing,
    .testimonials,
    .location,
    .contacts,
    .faq {
        padding: 60px 0;
    }

    /* Адаптация заголовков */
    h2 {
        font-size: 1.8rem;
        margin-bottom: 2rem;
    }

    h3 {
        font-size: 1.3rem;
    }

    /* Адаптация карточек */
    .advantage-card,
    .format-card,
    .pricing-card {
        padding: 1.5rem;
    }

    /* Адаптация формы */
    .form-group input,
    .form-group textarea,
    .form-group select {
        font-size: 16px; /* Предотвращает zoom на iOS */
    }

    /* Футер - адаптивность для мобильных */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        text-align: center;
    }

    .footer-section {
        text-align: center;
    }

    .footer-section h3::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-contact-item {
        justify-content: center;
        flex-wrap: wrap;
    }

    .footer-contact-item:hover {
        transform: none;
    }

    .footer-social-links {
        align-items: center;
    }

    .footer-social-link {
        width: 100%;
        max-width: 280px;
        justify-content: center;
    }

    footer {
        padding: 3rem 0 0;
    }
}

/* Очень маленькие экраны (iPhone SE, 320px) */
@media (max-width: 375px) {
    .hero h1 {
        font-size: 1.5rem;
    }

    .hero p {
        font-size: 0.95rem;
    }

    .container {
        padding: 0 12px;
    }

    .cta-button {
        padding: 10px 20px;
        font-size: 0.95rem;
    }

    .testimonial-card {
        padding: 1rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    .advantage-icon {
        font-size: 2.5rem;
    }

    /* Футер - маленькие экраны */
    .footer-section h3 {
        font-size: 1.2rem;
    }

    .footer-description {
        font-size: 0.95rem;
    }

    .footer-social-link {
        padding: 0.5rem 0.8rem;
        font-size: 0.9rem;
    }

    footer {
        padding: 2.5rem 0 0;
    }

    .footer-content {
        gap: 2rem;
    }
}

/* Увеличенная безопасность для всех экранов */
@media (max-width: 1200px) {
    .container {
        max-width: 100%;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Motion-safe generic reveal */
.reveal {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* Плавная смена текста при переключении языка */
.lang-fade-out {
    opacity: 0;
    transition: opacity 0.2s ease;
}

.lang-fade-in {
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* Запрет анимации для всей страницы во время смены языка */
.lang-switch {
    transition: none !important;
    animation: none !important;
}

/* Hide content until translations are loaded */
body.loading-translations {
    opacity: 0;
    transition: opacity 0.3s ease;
}

body.loaded-translations {
    opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation: none !important;
        transition: none !important;
    }
}

/* --- FAQ Toggle Animated with Spring + Rotate --- */
.faq-toggle {
  position: relative;
  width: 16px;
  height: 16px;
  display: inline-block;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  transform-origin: center;
}

.faq-toggle::before,
.faq-toggle::after {
  content: '';
  position: absolute;
  background-color: var(--text-primary);
  transition: all 0.3s ease;
}

/* Горизонтальная линия */
.faq-toggle::before {
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  transform: translateY(-50%);
}

/* Вертикальная линия */
.faq-toggle::after {
  left: 50%;
  top: 0;
  width: 2px;
  height: 100%;
  transform: translateX(-50%);
}

/* Активное состояние (превращается в минус) */
.faq-question.active .faq-toggle {
  transform: rotate(0deg) scale(1.2);
  animation: smoothPulse 0.4s ease-out;
}

.faq-question.active .faq-toggle::after {
  transform: translateX(-50%) scaleY(0);
}

.faq-question.active .faq-toggle::before {
  background-color: var(--accent-yellow);
}