/* ===== FINCULT MAIN STYLES ===== */
@tailwind base;
@tailwind components;
@tailwind utilities;

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Space+Grotesk:wght@500;600&display=swap');

/* ← сюда весь твой старый <style> код */   
        @import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&amp;family=Space+Grotesk:wght@500;600&amp;display=swap');
        
        :root {
            --emerald: #10b981;
            --mint: #14b8a6;
            --coral: #f472b6;
            --orange: #fb923c;
            --lavender: #a78bfa;
        }
        
        .tail-container {
            font-family: 'Inter', system_ui, sans-serif;
        }
        
        .logo-font {
            font-family: 'Space Grotesk', sans-serif;
        }

        .glass {
            background: rgba(255, 255, 255, 0.85);
            backdrop-filter: blur(20px);
            box-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.15);
        }



        .card-hover {
            transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        }
        
        .card-hover:hover {
            transform: translateY(-12px) scale(1.02);
            box-shadow: 0 30px 60px -15px rgb(16 185 129 / 0.25);
        }

        .float-bg {
            animation: float 8s ease-in-out infinite;
        }

        @keyframes float {
            0%, 100% { transform: translateY(0px); }
            50% { transform: translateY(-30px); }
        }

        .lesson-card {
            transition: all 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
        }

        .lesson-card:hover {
            transform: scale(1.03);
        }

        .nav-link {
            position: relative;
        }
        
        .nav-link:after {
            content: '';
            position: absolute;
            width: 0;
            height: 2px;
            bottom: -2px;
            left: 0;
            background-color: #10b981;
            transition: width 0.3s ease;
        }
        
        .nav-link:hover:after {
            width: 100%;
        }

        .section-title {
            position: relative;
            display: inline-block;
        }
        
        .section-title:after {
            content: '';
            position: absolute;
            width: 60%;
            height: 4px;
            background: linear-gradient(to right, #10b981, #a78bfa);
            bottom: -8px;
            left: 20%;
            border-radius: 9999px;
        }

        .gradient-title-hero {
        background: linear-gradient(90deg, #10b981, #14b8a6, #8b5cf6);
        -webkit-background-clip: text;
        background-clip: text;
        color: transparent;
        display: inline-block;
        }

        .modal {
            animation: modalPop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
        }
        
        @keyframes modalPop {
            0% {
                opacity: 0;
                transform: scale(0.7) translateY(50px);
            }
            100% {
                opacity: 1;
                transform: scale(1) translateY(0);
            }
        }

        .blob {
            position: absolute;
            border-radius: 50%;
            filter: blur(80px);
            opacity: 0.15;
            z-index: -1;
        }
        .xp-gained {
    animation: xpPop 1.2s ease-out forwards;
}
@keyframes xpPop {
    0% { transform: translateY(0) scale(1); opacity: 0; }
    30% { transform: translateY(-40px) scale(1.4); opacity: 1; }
    100% { transform: translateY(-60px) scale(0.8); opacity: 0; }
}

.badge-unlock {
    animation: badgeSpin 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes badgeSpin {
    0% { transform: scale(0) rotate(-180deg); opacity: 0; }
    60% { transform: scale(1.3) rotate(20deg); }
    100% { transform: scale(1) rotate(0); opacity: 1; }
}

.streak-flame { animation: flame 2s infinite; }
@keyframes flame { 0%,100% { transform: scale(1); } 50% { transform: scale(1.15); } }
/* Анимации для вариантов ответов */
.answer-btn {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.answer-btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 10px 20px -5px rgba(16, 185, 129, 0.2);
}

.answer-btn.selected {
    border-color: var(--emerald);
    background: rgba(16, 185, 129, 0.08);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.answer-btn.correct {
    border-color: var(--emerald);
    background: rgba(16, 185, 129, 0.12);
    animation: correctPulse 1.2s ease-in-out;
}

.answer-btn.wrong {
    border-color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
    animation: wrongShake 0.4s ease;
}

@keyframes correctPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.04); }
}

@keyframes wrongShake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-6px); }
    40%, 80% { transform: translateX(6px); }
}

/* Прогресс-бар теста */
#quiz-progress {
    transition: width 0.6s ease;
}

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: 'Inter', system-ui, sans-serif;
}

footer {
    background: #0f172a;
    color: #cbd5e1;
    padding: 5rem 0 2rem;
    width: 100%;
    flex-shrink: 0;          /* очень важно — не даёт футеру сжиматься */
    margin-top: auto;        /* прижимает футер к низу, если контента мало */
}

/* Карточки видеоуроков */
.lesson-card {
  background: white;
  border-radius: 1.5rem; /* 24px */
  overflow: hidden;
  box-shadow: 0 10px 20px rgba(0,0,0,0.08);
  transition: all 0.3s ease;
  height: 100%; /* карточки одинаковой высоты в ряду */
}

.lesson-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.lesson-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.lesson-card:hover img {
  transform: scale(1.05);
}

.lesson-card .tag {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  background: rgba(16, 185, 129, 0.9);
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
}

.lesson-card .duration {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: rgba(0,0,0,0.7);
  color: white;
  font-size: 0.75rem;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

/* На маленьких экранах уменьшаем отступы внутри карточки */
@media (max-width: 640px) {
  .lesson-card .p-5, .lesson-card .p-6 {
    padding: 1rem !important;
  }
  .lesson-card h4 {
    font-size: 1rem !important;
  }
  .lesson-card p {
    font-size: 0.875rem !important;
  }
}

/* ──────────────────────────────────────────────── */
/* Стили специально для симулятора инвестиций       */
/* ──────────────────────────────────────────────── */

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

.animate-float-slow {
  animation: float-slow 12s ease-in-out infinite;
}

.card-hover:hover {
  transform: translateY(-8px) scale(1.03);
  box-shadow: 0 20px 40px -10px rgba(16, 185, 129, 0.3);
}

.slider-container {
  display: flex;
  align-items: center;
  gap: 16px;
}

.slider-value {
  min-width: 80px;
  font-weight: bold;
  color: #10b981;
}

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

.animate-fadeIn {
  animation: fadeIn 0.6s ease-out forwards;
}

/* ====================== ГОРИЗОНТАЛЬНЫЙ СКРОЛЛ УРОКОВ ====================== */
.lessons-list {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding-bottom: 20px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.lessons-list::-webkit-scrollbar {
    display: none;
}

/* Карточки на мобильных — почти на всю ширину экрана */
.lesson-card {
    flex-shrink: 0;
    width: calc(100vw - 40px);     /* почти на весь экран */
    max-width: 380px;              /* ограничение на очень больших телефонах */
    scroll-snap-align: start;
    height: 100%;                  /* одинаковая высота */
}

/* На планшетах и компьютере — обычная сетка */
@media (min-width: 768px) {
    .lessons-list {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
        overflow-x: visible;
        padding-bottom: 0;
        gap: 24px;
    }
    
    .lesson-card {
        width: auto;
        max-width: none;
    }
}

/* ==================== КАРТА ЗНАНИЙ ==================== */




/* Карточки карты — красивый зум при наведении */
#map .glass {
    transition: all 0.35s ease;
}

#map .glass:hover {
    transform: scale(1.06) translateY(-4px);
    box-shadow: 0 20px 35px -10px rgb(16 185 129 / 0.25);
}




/* === ТИМ В СИМУЛЯТОРЕ (Duolingo-style) === */
#tim-sidebar {
    animation: slideInRight 0.5s ease;
}

@keyframes slideInRight {
    from { transform: translateX(50px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

#tim-chat {
    scrollbar-width: thin;
    scrollbar-color: #14b8a6 #e2e8f0;
}

.tim-message {
    background: white;
    padding: 12px 16px;
    border-radius: 18px 18px 18px 4px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
    max-width: 85%;
    align-self: flex-start;
}

/* На телефоне панель Тима прячется */
@media (max-width: 768px) {
    #tim-sidebar {
        display: none !important;
    }
}
/* Компактный Тим + липкий */
#tim-sidebar {
    animation: slideInRight 0.4s ease;
}

#tim-chat {
    scrollbar-width: thin;
}

.tim-message {
    background: white;
    padding: 10px 14px;
    border-radius: 16px 16px 16px 4px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.07);
}

/* Компактные карточки отраслей */
#sim-invest-cards > div {
    padding: 12px !important;
    font-size: 0.95rem !important;
}

#sim-invest-cards .text-6xl {
    font-size: 2.5rem !important;
    margin-bottom: 8px !important;
}

#tim-sidebar {
    position: sticky;
    top: 24px;
    align-self: start;
    height: fit-content;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.15);
    border: 3px solid rgba(255,255,255,0.4);
}

@media (max-width: 1024px) {
    #tim-sidebar {
        position: relative;
        top: 0;
        margin-top: 20px;
    }
}

#tim-chat {
    max-height: 420px;
    overflow-y: auto;
    scroll-behavior: smooth;
    padding-right: 8px;
}

.tim-message {
    background: white;
    padding: 12px 16px;
    border-radius: 18px 18px 18px 4px;
    margin-bottom: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
    max-width: 90%;
}

#tim-sidebar {
    position: sticky;
    top: 24px;
    align-self: start;
    height: fit-content;
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.15);
    border: 3px solid rgba(255,255,255,0.4);
}

@media (max-width: 1024px) {
    #tim-sidebar {
        position: relative;
        top: 0;
        margin-top: 20px;
    }
}

.gradient-title-hero {
  background: linear-gradient(90deg, #10b981, #14b8a6, #8b5cf6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
}

.no-underline-title:after {
  display: none;
}
.gradient-title-hero {
  background: linear-gradient(90deg, #10b981, #14b8a6, #8b5cf6);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;

  display: inline-block;

  line-height: 1.2;   /* 👈 ВАЖНО */
  padding-bottom: 4px; /* 👈 спасает от обрезки */
}

@media (max-width: 640px) {
  /* Секция тестов */
  #tests {
    padding-top: 56px !important;
    padding-bottom: 56px !important;
  }

  /* Внешний контейнер теста */
  #tests .max-w-3xl {
    max-width: 100% !important;
    margin-left: auto;
    margin-right: auto;
  }

  /* Плейсхолдер, сам тест и экран результата */
  #quiz-placeholder,
  #quiz-container,
  #result-screen {
    padding: 24px 16px !important;
    border-radius: 28px !important;
  }

  /* Заголовок секции */
  #tests h2 {
    font-size: 2rem !important;
    line-height: 1.05 !important;
  }

  /* Подзаголовок */
  #tests p.text-xl {
    font-size: 1rem !important;
    line-height: 1.5 !important;
    margin-top: 12px !important;
  }

  /* Текущая тема теста */
  #current-theme {
    font-size: 1rem !important;
    margin-bottom: 16px !important;
  }

  /* Вопрос */
  #question-text {
    font-size: 1.9rem !important;
    line-height: 1.15 !important;
    margin-bottom: 24px !important;
    min-height: auto !important;
  }

  /* Варианты ответов */
  .answer-btn {
    padding: 18px 16px !important;
    font-size: 1.05rem !important;
    line-height: 1.35 !important;
    border-radius: 24px !important;
  }

  /* Кнопки внизу */
  #next-btn,
  #quiz-placeholder button,
  #result-screen button {
    width: 100% !important;
    padding: 16px 18px !important;
    font-size: 1.05rem !important;
    line-height: 1.2 !important;
    border-radius: 22px !important;
  }

  /* Иконка мозга и стартовый экран */
  #quiz-placeholder .text-7xl {
    font-size: 4rem !important;
    margin-bottom: 18px !important;
  }

  #quiz-placeholder h3 {
    font-size: 2rem !important;
    line-height: 1.15 !important;
    margin-bottom: 14px !important;
  }

  #quiz-placeholder p {
    font-size: 1rem !important;
    line-height: 1.5 !important;
    margin-bottom: 24px !important;
  }

  /* Экран результата */
  #score-text {
    font-size: 3.5rem !important;
  }

  #result-title {
    font-size: 2rem !important;
    line-height: 1.1 !important;
  }

  #result-subtitle {
    font-size: 1rem !important;
    line-height: 1.5 !important;
    margin-bottom: 28px !important;
  }
}

/* по умолчанию скрыта мобильная */
.map-mobile {
  display: none;
}

/* мобилка */
@media (max-width: 768px) {

  .map-desktop {
    display: none;
  }

  .map-mobile {
    display: block;
  }

}
@media (max-width: 768px) {

  .map-mobile {
    padding-left: 12px;
    padding-right: 12px;
  }

  .map-mobile img {
    width: 100%;
    height: auto;
  }

}

@media (max-width: 768px) {

  .node {
    text-align: center;
  }

  .node1 { top: 10%; left: 54%; }
  .node2 { top: 30%; left: 54%; }
  .node3 { top: 50%; left: 54%; }
  .node4 { top: 70%; left: 54%; }
  .node5 { top: 90%; left: 54%; }

}

@media (max-width: 768px) {

  .node-hitbox {
    width: 140px;      /* ширина блока */
    height: 70px;      /* высота блока */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    border-radius: 20px;

    /* прозрачный фон (невидимый) */
    background: rgba(255,255,255,0);

    transition: all 0.2s ease;
  }

  /* при нажатии */
  .node-hitbox:active {
    transform: scale(0.95);
    background: rgba(255,255,255,0.2);
  }

}
.node-hitbox:hover {
  background: rgba(255,255,255,0.15);
}

.hero-actions-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:14px;
}

.hero-action-card{
  position:relative;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  min-height:110px;
  padding:14px 10px;
  border-radius:20px;
  border:1px solid rgba(255,255,255,.45);
  background:rgba(255,255,255,.68);
  backdrop-filter:blur(14px);
  -webkit-backdrop-filter:blur(14px);
  box-shadow:
    0 10px 24px rgba(15,23,42,.10),
    inset 0 1px 0 rgba(255,255,255,.55);
  transition:
    transform .22s ease,
    box-shadow .22s ease,
    background .22s ease,
    border-color .22s ease;
  overflow:hidden;
  cursor:pointer;
}

.hero-action-card::before{
  content:"";
  position:absolute;
  inset:0;
  background:linear-gradient(135deg, rgba(255,255,255,.22), transparent 55%);
  pointer-events:none;
}

.hero-action-card::after{
  content:"";
  position:absolute;
  top:0;
  left:-120%;
  width:65%;
  height:100%;
  background:linear-gradient(90deg, transparent, rgba(255,255,255,.35), transparent);
  transform:skewX(-20deg);
  transition:left .7s ease;
}

.hero-action-card:hover::after{
  left:140%;
}

.hero-action-card:hover{
  transform:translateY(-5px);
  box-shadow:
    0 18px 34px rgba(15,23,42,.14),
    inset 0 1px 0 rgba(255,255,255,.65);
}

.hero-action-icon{
  width:52px;
  height:52px;
  border-radius:16px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:20px;
  margin-bottom:10px;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.45);
  transition:transform .22s ease;
}

.hero-action-card:hover .hero-action-icon{
  transform:scale(1.08) rotate(-4deg);
}

.hero-action-text{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:4px;
}

.hero-action-title{
  display:block;
  font-size:15px;
  font-weight:800;
  line-height:1.1;
  color:#1f2937;
}

.hero-action-subtitle{
  display:block;
  font-size:12px;
  line-height:1.2;
  color:#64748b;
  max-width:110px;
}

.hero-action-card--video .hero-action-icon{
  background:linear-gradient(135deg, rgba(16,185,129,.18), rgba(16,185,129,.08));
  color:#10b981;
}

.hero-action-card--test .hero-action-icon{
  background:linear-gradient(135deg, rgba(20,184,166,.18), rgba(20,184,166,.08));
  color:#14b8a6;
}

.hero-action-card--map .hero-action-icon{
  background:linear-gradient(135deg, rgba(139,92,246,.18), rgba(139,92,246,.08));
  color:#8b5cf6;
}

.hero-action-card--video:hover{
  background:rgba(236,253,245,.88);
  border-color:rgba(16,185,129,.24);
}

.hero-action-card--test:hover{
  background:rgba(240,253,250,.88);
  border-color:rgba(20,184,166,.24);
}

.hero-action-card--map:hover{
  background:rgba(245,243,255,.88);
  border-color:rgba(139,92,246,.24);
}

@media (max-width: 640px){
  .hero-actions-grid{
    gap:10px;
  }

  .hero-action-card{
    min-height:96px;
    padding:12px 8px;
    border-radius:16px;
  }

  .hero-action-icon{
    width:44px;
    height:44px;
    font-size:17px;
    border-radius:14px;
    margin-bottom:8px;
  }

  .hero-action-title{
    font-size:13px;
  }

  .hero-action-subtitle{
    font-size:11px;
    max-width:84px;
  }
}

html[data-theme="dark"] .hero-action-card{
  background:rgba(15,23,42,.58);
  border-color:rgba(255,255,255,.10);
  box-shadow:
    0 10px 26px rgba(2,6,23,.28),
    inset 0 1px 0 rgba(255,255,255,.05);
}

html[data-theme="dark"] .hero-action-title{
  color:#e2e8f0;
}

html[data-theme="dark"] .hero-action-subtitle{
  color:#94a3b8;
}

.about-project-card{
  position: relative;
  background:
    linear-gradient(135deg, rgba(255,255,255,.52), rgba(255,255,255,.24));
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  border: 1px solid rgba(255,255,255,.42);
  box-shadow:
    0 24px 70px rgba(15, 23, 42, 0.12),
    inset 0 1px 0 rgba(255,255,255,.45);
  overflow: hidden;
  isolation: isolate;
  animation: aboutCardFloat 6s ease-in-out infinite;
}

.about-project-card::before{
  content:"";
  position:absolute;
  inset:0;
  background:
    radial-gradient(circle at top left, rgba(255,255,255,.46), transparent 34%),
    radial-gradient(circle at 85% 15%, rgba(45,212,191,.10), transparent 24%),
    radial-gradient(circle at 80% 80%, rgba(167,139,250,.10), transparent 28%);
  pointer-events:none;
  z-index:0;
}

.about-project-card > *{
  position: relative;
  z-index: 1;
}

.about-project-preview{
  position: relative;
  background: rgba(255,255,255,.42);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,.35);
  box-shadow:
    0 14px 35px rgba(15,23,42,.08),
    inset 0 1px 0 rgba(255,255,255,.38);
  transition:
    transform .28s ease,
    box-shadow .28s ease,
    background .28s ease;
}

.about-project-preview:hover{
  transform: translateY(-4px);
  box-shadow:
    0 20px 42px rgba(15,23,42,.12),
    inset 0 1px 0 rgba(255,255,255,.45);
  background: rgba(255,255,255,.50);
}

@keyframes aboutCardFloat{
  0%,100%{ transform: translateY(0); }
  50%{ transform: translateY(-5px); }
}
/* затемнение фона */
.map-modal-overlay{
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,.35);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}

/* сама модалка */
.map-modal{
  position: relative;
  width: 100%;
  max-width: 420px;
  padding: 22px 22px 20px;
  border-radius: 22px;

  background: rgba(255,255,255,.75);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);

  border: 1px solid rgba(255,255,255,.5);

  box-shadow:
    0 20px 50px rgba(15,23,42,.18),
    inset 0 1px 0 rgba(255,255,255,.6);

  animation: modalFade .25s ease;
}

/* крестик */
.map-modal-close{
  position: absolute;
  top: 14px;
  right: 14px;
  border: none;
  background: transparent;
  font-size: 18px;
  color: #64748b;
  cursor: pointer;
}

/* header */
.map-modal-header{
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.map-modal-icon{
  font-size: 22px;
}

.map-modal-title{
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
}

/* текст */
.map-modal-text{
  font-size: 14px;
  color: #475569;
  line-height: 1.5;
  margin-bottom: 18px;
}

/* кнопки */
.map-modal-actions{
  display: flex;
  gap: 10px;
}

.map-btn{
  flex: 1;
  height: 40px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: .2s;
}

/* основная кнопка */
.map-btn--primary{
  background: linear-gradient(135deg,#10b981,#059669);
  color: white;
}

.map-btn--primary:hover{
  transform: translateY(-1px);
}

/* вторичная */
.map-btn--secondary{
  background: rgba(255,255,255,.6);
  border: 1px solid rgba(0,0,0,.06);
  color: #334155;
}

/* анимация */
@keyframes modalFade{
  from{
    opacity: 0;
    transform: translateY(10px) scale(.96);
  }
  to{
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* тёмная тема */
html[data-theme="dark"] .map-modal{
  background: rgba(15,23,42,.7);
  border-color: rgba(255,255,255,.08);
}

html[data-theme="dark"] .map-modal-title{
  color: #e2e8f0;
}

html[data-theme="dark"] .map-modal-text{
  color: #94a3b8;
}

html[data-theme="dark"] .map-btn--secondary{
  background: rgba(15,23,42,.6);
  border-color: rgba(255,255,255,.08);
  color: #e2e8f0;
}

.map-modal-card {
    animation: mapModalPop 0.28s ease-out;
}

@keyframes mapModalPop {
    0% {
        opacity: 0;
        transform: translateY(14px) scale(0.96);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.map-modal-btn {
    min-height: 60px;
    border-radius: 20px;
    padding: 0 24px;
    font-size: 1.125rem;
    font-weight: 700;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease, color 0.18s ease;
}

.map-modal-btn:hover {
    transform: translateY(-1px);
}

.map-modal-btn:active {
    transform: scale(0.98);
}

.map-modal-btn-primary {
    background: linear-gradient(135deg, #10b981, #14b8a6);
    color: white;
    box-shadow: 0 14px 30px rgba(16, 185, 129, 0.28);
    border: none;
}

.map-modal-btn-primary:hover {
    box-shadow: 0 18px 34px rgba(16, 185, 129, 0.34);
}

.map-modal-btn-secondary {
    background: rgba(255,255,255,0.78);
    color: #1e293b;
    border: 1px solid rgba(203, 213, 225, 0.95);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.map-modal-btn-secondary:hover {
    background: rgba(255,255,255,0.95);
}

@media (max-width: 640px) {
    .map-modal-card {
        border-radius: 28px;
        padding: 24px 20px;
    }

    .map-modal-btn {
        min-height: 56px;
        font-size: 1rem;
        border-radius: 18px;
    }
}
/* =========================
   TESTS BLOCK UPGRADE
========================= */

.quiz-hero {
  max-width: 1100px !important;
}

.quiz-topic-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-bottom: 42px;
}
.quiz-topic-chip{
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  gap:8px !important;

  padding:14px 22px !important;
  min-height:56px !important;

  border:1px solid rgba(255,255,255,0.7) !important;
  border-radius:22px !important;
  background:rgba(255,255,255,0.88) !important;
  color:#1e293b !important;

  font-size:1.05rem !important;
  font-weight:700 !important;
  line-height:1 !important;
  white-space:nowrap !important;

  box-shadow:0 8px 24px rgba(15,23,42,.06) !important;
  backdrop-filter:blur(10px) !important;

  transition:transform .18s ease, box-shadow .18s ease, background-color .18s ease !important;
}

.quiz-topic-chip:hover{
  transform:translateY(-2px) !important;
  box-shadow:0 14px 28px rgba(15,23,42,.10) !important;
  background:rgba(255,255,255,0.96) !important;
}

.quiz-topic-row{
  display:flex !important;
  flex-wrap:wrap !important;
  justify-content:center !important;
  gap:14px !important;
  margin-bottom:42px !important;
}

/* ===== TEST HERO FINAL FIX ===== */

.quiz-hero{
  max-width: 1100px !important;
  padding: 46px 38px !important;
  border-radius: 40px !important;

  background: rgba(255, 255, 255, 0.42) !important;
  border: 1px solid rgba(255,255,255,0.55) !important;
  backdrop-filter: blur(18px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(18px) saturate(140%) !important;

  box-shadow:
    0 24px 60px rgba(109, 76, 145, 0.10),
    inset 0 1px 0 rgba(255,255,255,0.32) !important;
}

.quiz-hero-inner{
  min-height: 320px !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
}

.quiz-hero-icon{
  font-size: 3.8rem !important;
  line-height: 1 !important;
  margin-bottom: 20px !important;
}

.quiz-hero-title{
  font-size: clamp(2rem, 4vw, 3.3rem) !important;
  line-height: 1.08 !important;
  font-weight: 800 !important;
  color: #1e293b !important;
  margin-bottom: 14px !important;
}

.quiz-hero-subtitle{
  font-size: 1.45rem !important;
  line-height: 1.6 !important;
  color: #475569 !important;
  max-width: 760px !important;
  margin: 0 auto 34px !important;
}

.quiz-main-btn{
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;

  min-width: 320px !important;
  min-height: 76px !important;
  padding: 22px 34px !important;

  border: none !important;
  border-radius: 28px !important;
  background: linear-gradient(135deg, #10b981, #14b8a6) !important;
  color: #ffffff !important;

  font-size: 1.35rem !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  text-decoration: none !important;

  box-shadow: 0 18px 40px rgba(16,185,129,.28) !important;
  transition: transform .18s ease, box-shadow .18s ease !important;
}

.quiz-main-btn:hover{
  transform: translateY(-2px) !important;
  box-shadow: 0 24px 46px rgba(16,185,129,.34) !important;
}

.quiz-main-btn:active{
  transform: scale(.985) !important;
}

.quiz-result-btn{
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  min-width:260px !important;
  min-height:64px !important;
  padding:18px 28px !important;
  border-radius:22px !important;
  font-size:1.1rem !important;
  font-weight:700 !important;
  line-height:1 !important;
  transition:transform .18s ease, box-shadow .18s ease, background-color .18s ease !important;
}

.quiz-result-btn:hover{
  transform:translateY(-2px) !important;
}

.quiz-result-btn-primary{
  border:none !important;
  color:#fff !important;
  background:linear-gradient(135deg,#10b981,#14b8a6) !important;
  box-shadow:0 16px 32px rgba(16,185,129,.24) !important;
}

.quiz-result-btn-secondary{
  border:2px solid #cbd5e1 !important;
  background:rgba(255,255,255,.7) !important;
  color:#334155 !important;
}

.quiz-result-effects{
  position:absolute;
  inset:0;
  overflow:hidden;
  z-index:0;
}

#result-screen > *:not(#quiz-result-effects){
  position:relative;
  z-index:1;
}

.rain-drop{
  position:absolute;
  top:-30px;
  width:8px;
  height:22px;
  border-radius:999px;
  background:linear-gradient(to bottom, rgba(59,130,246,0), rgba(59,130,246,.75));
  animation:rain-fall linear forwards;
  opacity:.9;
}

@keyframes rain-fall{
  0%{
    transform:translateY(-20px);
    opacity:.9;
  }
  100%{
    transform:translateY(560px);
    opacity:0;
  }
}

.confetti-piece{
  position:absolute;
  top:-20px;
  width:10px;
  height:18px;
  border-radius:3px;
  opacity:.9;
  animation:confetti-fall linear forwards;
}

@keyframes confetti-fall{
  0%{
    transform:translateY(-20px) rotate(0deg);
    opacity:1;
  }
  100%{
    transform:translateY(520px) rotate(720deg);
    opacity:0;
  }
}



.hero .section-title,
.hero h1 {
  /* hero не трогаем */
}

/* светлая тема */
section:not(.hero) .section-title {
  background: none !important;
  color: #0f172a !important;
  -webkit-text-fill-color: #0f172a !important;
  font-weight: 900 !important;
  letter-spacing: -0.03em !important;
}

/* тёмная тема */
html[data-theme="dark"] section:not(.hero) .section-title {
  color: #e5eefc !important;
  -webkit-text-fill-color: #e5eefc !important;
}
.topbar-wrap{
  position: sticky;
  top: 12px;
  z-index: 1000;
  padding: 0 14px;
}

.topbar{
  max-width: 1440px;
  margin: 0 auto;
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 20px;
  border-radius: 28px;

  background: linear-gradient(135deg, rgba(255,255,255,.72), rgba(255,255,255,.42));
  border: 1px solid rgba(255,255,255,.58);

  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);

  box-shadow:
    0 18px 48px rgba(15,23,42,.10),
    inset 0 1px 0 rgba(255,255,255,.55);
}

.topbar-brand{
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
  flex-shrink: 0;
}

.topbar-brand-icon{
  width: 48px;
  height: 48px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #10b981, #8b5cf6);
  color: #fff;
  font-size: 1.65rem;
  font-weight: 800;
  box-shadow: 0 12px 28px rgba(99,102,241,.22);
  flex-shrink: 0;
}

.topbar-brand-text{
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.topbar-brand-title{
  font-size: 1.9rem;
  font-weight: 800;
  color: #059669;
  letter-spacing: -0.02em;
}

.topbar-brand-subtitle{
  font-size: .84rem;
  color: #64748b;
  margin-top: 3px;
}

.topbar-nav{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.topbar-link{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  color: #334155;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: .22s ease;
  white-space: nowrap;
}

.topbar-link:hover{
  background: rgba(255,255,255,.52);
  color: #059669;
  transform: translateY(-1px);
}

.topbar-right{
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.topbar-mobile-btn{
  display: none;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 16px;
  background: rgba(255,255,255,.52);
  color: #059669;
  font-size: 1.35rem;
  box-shadow: 0 8px 20px rgba(15,23,42,.06);
}

.topbar-mobile-menu{
  max-width: 1440px;
  margin: 12px auto 0;
  padding: 14px;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(255,255,255,.88), rgba(255,255,255,.72));
  border: 1px solid rgba(255,255,255,.6);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 16px 40px rgba(15,23,42,.08);
}

.topbar-mobile-menu a,
.topbar-mobile-menu button{
  width: 100%;
}

.theme-toggle{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.56);
  background: rgba(255,255,255,.55);
  color: #0f766e;
  font-weight: 700;
  transition: .2s ease;
  box-shadow: 0 10px 24px rgba(15,23,42,.06);
}

.theme-toggle:hover{
  transform: translateY(-1px);
  background: rgba(255,255,255,.72);
}

.topbar-start-btn{
  min-height: 48px;
  padding: 0 24px;
  border: 0;
  border-radius: 18px;
  background: #059669;
  color: #fff;
  font-weight: 700;
  box-shadow: 0 14px 30px rgba(5,150,105,.22);
  transition: .2s ease;
}

.topbar-start-btn:hover{
  transform: translateY(-1px);
  background: #047857;
}

@media (max-width: 1180px){
  .topbar-brand-title{
    font-size: 1.7rem;
  }

  .topbar-link{
    padding: 0 11px;
    font-size: .95rem;
  }
}

@media (max-width: 980px){
  .topbar{
    min-height: 72px;
    padding: 12px 16px;
    border-radius: 24px;
  }

  .topbar-nav,
  .topbar-right{
    display: none;
  }

  .topbar-mobile-btn{
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .topbar-brand{
    min-width: 0;
  }

  .topbar-brand-title{
    font-size: 1.6rem;
  }

  .topbar-brand-subtitle{
    font-size: .76rem;
  }

  .topbar-brand-icon{
    width: 44px;
    height: 44px;
    border-radius: 16px;
    font-size: 1.45rem;
  }
}

@media (max-width: 640px){
  .topbar-wrap{
    top: 8px;
    padding: 0 10px;
  }

  .topbar{
    padding: 11px 14px;
    border-radius: 22px;
  }

  .topbar-brand{
    gap: 10px;
  }

  .topbar-brand-title{
    font-size: 1.45rem;
  }

  .topbar-brand-subtitle{
    font-size: .72rem;
  }

  .topbar-brand-icon{
    width: 42px;
    height: 42px;
    border-radius: 14px;
    font-size: 1.3rem;
  }
}

/* ===== ГЛАВНАЯ СТЕКЛЯННАЯ КАРТОЧКА (правая колонка) ===== */
.glass-main {
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);

  border: 1px solid rgba(255, 255, 255, 0.6);

  box-shadow: 
    0 10px 30px rgba(0, 0, 0, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);

  position: relative;
  overflow: hidden;
}

/* лёгкий блик */
.glass-main::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;

  background: linear-gradient(
    120deg,
    rgba(255,255,255,0.6),
    rgba(255,255,255,0.2) 40%,
    transparent 60%
  );

  pointer-events: none;
}


/* ===== МАЛЕНЬКИЕ КАРТОЧКИ (100% и 5 тем) ===== */
.stat-card {
  background: #ffffff;
  border-radius: 24px;

  border: 1px solid rgba(0,0,0,0.04);

  box-shadow: 0 10px 25px rgba(0,0,0,0.05);

  transition: all 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(0,0,0,0.08);
}


/* ===== ОСНОВНЫЕ КАРТОЧКИ (уроки, тесты и т.д.) ===== */
.card-soft {
  background: #ffffff;
  border-radius: 28px;

  border: 1px solid rgba(0,0,0,0.05);

  box-shadow: 0 12px 30px rgba(0,0,0,0.06);

  transition: all 0.3s ease;
}

.card-soft:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 50px rgba(0,0,0,0.08);
}

.stat-card {
  background: rgba(255, 255, 255, 0.85); /* чуть прозрачности */
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);

  border-radius: 20px;

  border: 1px solid rgba(255,255,255,0.6);

  box-shadow:
    0 8px 20px rgba(0,0,0,0.05),
    inset 0 1px 0 rgba(255,255,255,0.7);

  transition: all 0.3s ease;
}



.team-more-btn{
  position:relative;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:14px 18px;
  border-radius:22px;
  background:linear-gradient(135deg, rgba(255,255,255,.68), rgba(255,255,255,.38));
  border:1px solid rgba(255,255,255,.48);
  box-shadow:0 14px 32px rgba(15,23,42,.08), inset 0 1px 0 rgba(255,255,255,.45);
  backdrop-filter:blur(14px);
  -webkit-backdrop-filter:blur(14px);
  transition:transform .25s ease, box-shadow .25s ease, background .25s ease;
  overflow:hidden;
}

.team-more-btn::before{
  content:"";
  position:absolute;
  inset:0;
  background:linear-gradient(90deg, rgba(16,185,129,.08), rgba(139,92,246,.06));
  opacity:.9;
  pointer-events:none;
}

.team-more-btn:hover{
  transform:translateY(-3px);
  box-shadow:0 18px 38px rgba(15,23,42,.12), inset 0 1px 0 rgba(255,255,255,.55);
}

.team-more-btn > *{ position:relative; z-index:1; }
.team-more-btn__icon{
  width:42px; height:42px; border-radius:16px; display:flex; align-items:center; justify-content:center;
  background:linear-gradient(135deg, #34d399, #8b5cf6); color:#fff; font-size:16px;
  box-shadow:0 10px 22px rgba(52,211,153,.25); flex-shrink:0;
}
.team-more-btn__text{ font-weight:800; color:#1f2937; flex:1; text-align:left; }
.team-more-btn__arrow{ color:#10b981; font-size:14px; }

.team-modal-card{
  position:relative;
  animation:teamModalPop .28s ease;
}
.team-modal-card::before{
  content:""; position:absolute; inset:0; pointer-events:none;
  background:radial-gradient(circle at top left, rgba(255,255,255,.55), transparent 30%),
             radial-gradient(circle at bottom right, rgba(167,139,250,.12), transparent 26%),
             radial-gradient(circle at 82% 18%, rgba(52,211,153,.10), transparent 22%);
}
.team-modal-head, .team-modal-body{ position:relative; z-index:1; }
.team-modal-close{
  width:44px; height:44px; border-radius:999px; border:1px solid rgba(255,255,255,.55);
  background:rgba(255,255,255,.72); color:#334155; display:flex; align-items:center; justify-content:center;
  box-shadow:0 10px 26px rgba(15,23,42,.10); transition:.25s ease;
}
.team-modal-close:hover{ transform:rotate(90deg) scale(1.05); background:rgba(255,255,255,.9); }
.team-grid{ display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:18px; }
.team-member-card{
  position:relative;
  display:flex; gap:16px; align-items:flex-start;
  padding:18px; border-radius:28px;
  background:rgba(255,255,255,.58);
  border:1px solid rgba(255,255,255,.50);
  backdrop-filter:blur(16px); -webkit-backdrop-filter:blur(16px);
  box-shadow:0 18px 34px rgba(15,23,42,.08);
  transition:transform .25s ease, box-shadow .25s ease;
  opacity:0; transform:translateY(14px) scale(.98);
  animation:teamCardIn .45s ease forwards;
}
.team-member-card:nth-child(2){ animation-delay:.05s; }
.team-member-card:nth-child(3){ animation-delay:.10s; }
.team-member-card:nth-child(4){ animation-delay:.15s; }
.team-member-card:nth-child(5){ animation-delay:.20s; }
.team-member-card:hover{ transform:translateY(-4px); box-shadow:0 22px 40px rgba(15,23,42,.12); }
.team-member-card--emerald{ box-shadow:0 18px 34px rgba(16,185,129,.10); }
.team-member-card--pink{ box-shadow:0 18px 34px rgba(244,114,182,.10); }
.team-member-card--violet{ box-shadow:0 18px 34px rgba(139,92,246,.10); }
.team-member-card--amber{ box-shadow:0 18px 34px rgba(245,158,11,.10); }
.team-member-card--sky{ box-shadow:0 18px 34px rgba(14,165,233,.10); }
.team-member-photo-wrap{
  width:88px; height:88px; border-radius:24px; padding:4px; flex-shrink:0;
  background:linear-gradient(135deg, rgba(16,185,129,.22), rgba(139,92,246,.20));
  box-shadow:0 8px 18px rgba(15,23,42,.08);
}
.team-member-photo{ width:100%; height:100%; object-fit:cover; border-radius:20px; display:block; background:#e2e8f0; }
.team-member-content{ min-width:0; }
.team-member-role{ font-size:12px; font-weight:800; letter-spacing:.08em; text-transform:uppercase; color:#10b981; }
.team-member-name{ margin-top:5px; font-size:22px; line-height:1.1; font-weight:800; color:#0f172a; }
.team-member-desc{ margin-top:8px; font-size:15px; line-height:1.55; color:#475569; }
.team-member-meta{
  margin-top:12px; display:inline-flex; align-items:center; gap:8px;
  padding:7px 12px; border-radius:999px; background:rgba(255,255,255,.72); border:1px solid rgba(255,255,255,.55);
  color:#334155; font-size:13px; font-weight:700;
}

@keyframes teamModalPop{
  from{ opacity:0; transform:translateY(16px) scale(.97); }
  to{ opacity:1; transform:none; }
}
@keyframes teamCardIn{
  to{ opacity:1; transform:none; }
}

html[data-theme="dark"] .team-more-btn{
  background:linear-gradient(135deg, rgba(15,23,42,.78), rgba(15,23,42,.62));
  border-color:rgba(255,255,255,.10);
  box-shadow:0 18px 38px rgba(2,6,23,.26), inset 0 1px 0 rgba(255,255,255,.05);
}
html[data-theme="dark"] .team-more-btn__text{ color:#e2e8f0; }
html[data-theme="dark"] .team-modal-card{ background:rgba(15,23,42,.82); border-color:rgba(255,255,255,.10); }
html[data-theme="dark"] .team-modal-close{ background:rgba(30,41,59,.9); border-color:rgba(255,255,255,.08); color:#e2e8f0; }
html[data-theme="dark"] .team-member-card{ background:rgba(15,23,42,.66); border-color:rgba(255,255,255,.08); }
html[data-theme="dark"] .team-member-name{ color:#f8fafc; }
html[data-theme="dark"] .team-member-desc{ color:#cbd5e1; }
html[data-theme="dark"] .team-member-meta{ background:rgba(30,41,59,.82); border-color:rgba(255,255,255,.08); color:#e2e8f0; }
html[data-theme="dark"] #team-modal h3{ color:#f8fafc; }
html[data-theme="dark"] #team-modal p{ color:#cbd5e1; }

@media (max-width: 900px){
  .team-grid{ grid-template-columns:1fr; }
}
@media (max-width: 640px){
  .team-member-card{ padding:15px; gap:13px; border-radius:24px; }
  .team-member-photo-wrap{ width:74px; height:74px; border-radius:20px; }
  .team-member-photo{ border-radius:16px; }
  .team-member-name{ font-size:19px; }
  .team-member-desc{ font-size:14px; }
  .team-more-btn{ padding:12px 14px; border-radius:18px; }
  .team-more-btn__icon{ width:38px; height:38px; border-radius:14px; }
}


.team-modal-close-btn {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: #334155;
  cursor: pointer;
  transition: all 0.25s ease;
}

.team-modal-close-btn span {
  display: inline-block;
  transition: transform 0.3s ease;
}

/* 🔥 ХОВЕР */
.team-modal-close-btn:hover {
  transform: scale(1.1);
  background: rgba(255,255,255,0.9);
}

.team-modal-close-btn:hover span {
  transform: rotate(90deg);
}
#teamModal {
  opacity: 0;
  transition: opacity 0.25s ease;
}

#teamModal.flex {
  opacity: 1;
}

#teamModal .modal-box {
  transform: translateY(20px) scale(0.97);
  transition: all 0.25s ease;
}

#teamModal.flex .modal-box {
  transform: translateY(0) scale(1);
}


  .modal-box{
    animation: teamModalShow .25s ease;
  }

  @keyframes teamModalShow{
    from{
      opacity: 0;
      transform: translateY(14px) scale(.98);
    }
    to{
      opacity: 1;
      transform: translateY(0) scale(1);
    }
  }

  .team-modal-scroll{
    overflow-y: auto;
    max-height: calc(92dvh - 96px);
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: rgba(16,185,129,.45) transparent;
  }

  .team-modal-scroll::-webkit-scrollbar{
    width: 8px;
  }

  .team-modal-scroll::-webkit-scrollbar-track{
    background: transparent;
  }

  .team-modal-scroll::-webkit-scrollbar-thumb{
    background: rgba(16,185,129,.35);
    border-radius: 999px;
  }

  .team-modal-close-btn{
    width: 44px;
    height: 44px;
    border-radius: 9999px;
    border: 1px solid rgba(255,255,255,.7);
    background: rgba(255,255,255,.82);
    color: #334155;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    line-height: 1;
    box-shadow: 0 8px 24px rgba(15,23,42,.08);
    transition: transform .2s ease, background .2s ease, color .2s ease;
  }

  .team-modal-close-btn:hover{
    transform: rotate(90deg) scale(1.04);
    background: rgba(255,255,255,.96);
    color: #0f172a;
  }

  @media (max-width: 640px){
    .team-modal-close-btn{
      width: 40px;
      height: 40px;
      font-size: 26px;
    }

    .team-modal-scroll{
      max-height: calc(92dvh - 88px);
    }
  }

  html[data-theme="dark"] .modal-box{
    background: rgba(15,23,42,.84) !important;
    border-color: rgba(255,255,255,.08) !important;
  }

  html[data-theme="dark"] .modal-box > div:first-child{
    background: rgba(15,23,42,.88) !important;
    border-color: rgba(255,255,255,.08) !important;
  }

  html[data-theme="dark"] .team-modal-scroll > .grid > div{
    background: rgba(15,23,42,.72) !important;
    border-color: rgba(255,255,255,.08) !important;
  }

  html[data-theme="dark"] .modal-box h3,
  html[data-theme="dark"] .modal-box .font-extrabold{
    color: #f8fafc !important;
  }

  html[data-theme="dark"] .modal-box p,
  html[data-theme="dark"] .modal-box .text-slate-600,
  html[data-theme="dark"] .modal-box .text-slate-500{
    color: #cbd5e1 !important;
  }

  html[data-theme="dark"] .team-modal-close-btn{
    background: rgba(15,23,42,.78);
    border-color: rgba(255,255,255,.08);
    color: #e2e8f0;
  }

  .modal-box{
    animation: teamModalShow .25s ease;
  }

  @keyframes teamModalShow{
    from{
      opacity: 0;
      transform: translateY(14px) scale(.98);
    }
    to{
      opacity: 1;
      transform: translateY(0) scale(1);
    }
  }

  .team-modal-scroll{
    overflow-y: auto;
    max-height: calc(92dvh - 96px);
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: rgba(16,185,129,.45) transparent;
  }

  .team-modal-scroll::-webkit-scrollbar{
    width: 8px;
  }

  .team-modal-scroll::-webkit-scrollbar-track{
    background: transparent;
  }

  .team-modal-scroll::-webkit-scrollbar-thumb{
    background: rgba(16,185,129,.35);
    border-radius: 999px;
  }

  .team-modal-close-btn{
    width: 44px;
    height: 44px;
    border-radius: 9999px;
    border: 1px solid rgba(255,255,255,.7);
    background: rgba(255,255,255,.82);
    color: #334155;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    line-height: 1;
    box-shadow: 0 8px 24px rgba(15,23,42,.08);
    transition: transform .2s ease, background .2s ease, color .2s ease;
  }

  .team-modal-close-btn:hover{
    transform: rotate(90deg) scale(1.04);
    background: rgba(255,255,255,.96);
    color: #0f172a;
  }

  @media (max-width: 640px){
    .team-modal-close-btn{
      width: 40px;
      height: 40px;
      font-size: 26px;
    }

    .team-modal-scroll{
      max-height: calc(92dvh - 88px);
    }
  }

  html[data-theme="dark"] .modal-box{
    background: rgba(15,23,42,.84) !important;
    border-color: rgba(255,255,255,.08) !important;
  }

  html[data-theme="dark"] .modal-box > div:first-child{
    background: rgba(15,23,42,.88) !important;
    border-color: rgba(255,255,255,.08) !important;
  }

  html[data-theme="dark"] .team-modal-scroll > .grid > div{
    background: rgba(15,23,42,.72) !important;
    border-color: rgba(255,255,255,.08) !important;
  }

  html[data-theme="dark"] .modal-box h3,
  html[data-theme="dark"] .modal-box .font-extrabold{
    color: #f8fafc !important;
  }

  html[data-theme="dark"] .modal-box p,
  html[data-theme="dark"] .modal-box .text-slate-600,
  html[data-theme="dark"] .modal-box .text-slate-500{
    color: #cbd5e1 !important;
  }

  html[data-theme="dark"] .team-modal-close-btn{
    background: rgba(15,23,42,.78);
    border-color: rgba(255,255,255,.08);
    color: #e2e8f0;
  }


.team-mobile-btn{
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 18px 22px;
  border: 1px solid rgba(255,255,255,.62);
  border-radius: 26px;
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow:
    0 10px 30px rgba(15, 23, 42, 0.08),
    inset 0 1px 0 rgba(255,255,255,.7);
  color: #334155;
  font-weight: 700;
  transition:
    transform .22s ease,
    box-shadow .22s ease,
    background .22s ease,
    border-color .22s ease;
  overflow: hidden;
}

.team-mobile-btn::before{
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(16,185,129,.10) 0%,
    rgba(168,85,247,.10) 50%,
    rgba(16,185,129,.10) 100%
  );
  opacity: 0;
  transition: opacity .25s ease;
}

.team-mobile-btn:hover{
  transform: translateY(-2px);
  box-shadow:
    0 16px 34px rgba(15, 23, 42, 0.12),
    inset 0 1px 0 rgba(255,255,255,.8);
  border-color: rgba(255,255,255,.78);
}

.team-mobile-btn:hover::before{
  opacity: 1;
}

.team-mobile-btn:active{
  transform: scale(.985);
}

.team-mobile-btn__icon{
  position: relative;
  z-index: 1;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(16,185,129,.16), rgba(16,185,129,.08));
  color: #059669;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.7);
  transition: transform .25s ease, box-shadow .25s ease;
}

.team-mobile-btn__text{
  position: relative;
  z-index: 1;
  font-size: 1.02rem;
  line-height: 1.2;
}

.team-mobile-btn__arrow{
  position: relative;
  z-index: 1;
  color: #059669;
  font-size: 1rem;
  transition: transform .25s ease, color .25s ease;
}

.team-mobile-btn:hover .team-mobile-btn__arrow{
  transform: translateX(4px);
}

.team-mobile-btn:hover .team-mobile-btn__icon{
  transform: scale(1.06) rotate(-4deg);
}

@media (max-width: 640px){
  .team-mobile-btn{
    padding: 16px 18px;
    border-radius: 24px;
    gap: 10px;
  }

  .team-mobile-btn__icon{
    width: 38px;
    height: 38px;
    border-radius: 14px;
  }

  .team-mobile-btn__text{
    font-size: .98rem;
  }
}


.team-mobile-btn{
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 18px 22px;
  border: 1px solid rgba(255,255,255,.62);
  border-radius: 26px;
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow:
    0 10px 30px rgba(15, 23, 42, 0.08),
    inset 0 1px 0 rgba(255,255,255,.7);
  color: #334155;
  font-weight: 700;
  transition:
    transform .22s ease,
    box-shadow .22s ease,
    background .22s ease,
    border-color .22s ease;
  overflow: hidden;
}

.team-mobile-btn::before{
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(16,185,129,.10) 0%,
    rgba(168,85,247,.10) 50%,
    rgba(16,185,129,.10) 100%
  );
  opacity: 0;
  transition: opacity .25s ease;
}

.team-mobile-btn:hover{
  transform: translateY(-2px);
  box-shadow:
    0 16px 34px rgba(15, 23, 42, 0.12),
    inset 0 1px 0 rgba(255,255,255,.8);
  border-color: rgba(255,255,255,.78);
}

.team-mobile-btn:hover::before{
  opacity: 1;
}

.team-mobile-btn:active{
  transform: scale(.985);
}

.team-mobile-btn__icon{
  position: relative;
  z-index: 1;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(16,185,129,.16), rgba(16,185,129,.08));
  color: #059669;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.7);
  transition: transform .25s ease, box-shadow .25s ease;
}

.team-mobile-btn__text{
  position: relative;
  z-index: 1;
  font-size: 1.02rem;
  line-height: 1.2;
}

.team-mobile-btn__arrow{
  position: relative;
  z-index: 1;
  color: #059669;
  font-size: 1rem;
  transition: transform .25s ease, color .25s ease;
}

.team-mobile-btn:hover .team-mobile-btn__arrow{
  transform: translateX(4px);
}

.team-mobile-btn:hover .team-mobile-btn__icon{
  transform: scale(1.06) rotate(-4deg);
}

@media (max-width: 640px){
  .team-mobile-btn{
    padding: 16px 18px;
    border-radius: 24px;
    gap: 10px;
  }

  .team-mobile-btn__icon{
    width: 38px;
    height: 38px;
    border-radius: 14px;
  }

  .team-mobile-btn__text{
    font-size: .98rem;
  }
}


.mobile-btn{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 16px 20px;
  border-radius: 26px;
  font-weight: 600;
  font-size: 15px;
  transition: all .25s ease;
  backdrop-filter: blur(14px);
}

/* PRIMARY */
.mobile-btn--primary{
  background: linear-gradient(90deg,#10b981,#14b8a6);
  color: white;
  box-shadow: 0 10px 25px rgba(16,185,129,.35);
}

.mobile-btn--primary:active{
  transform: scale(.97);
}

/* SECONDARY */
.mobile-btn--secondary{
  border: 1.5px solid rgba(100,116,139,.3);
  background: rgba(255,255,255,.4);
  color: #334155;
}

.mobile-btn--secondary:hover{
  border-color: #10b981;
}

/* ACCENT (игра — но в системе!) */
.mobile-btn--accent{
  background: linear-gradient(90deg,#8b5cf6,#d946ef,#10b981);
  color: white;
  box-shadow: 0 10px 25px rgba(139,92,246,.25);
}

/* SOFT */
.mobile-btn--soft{
  background: rgba(255,255,255,.65);
  border: 1px solid rgba(255,255,255,.6);
  color: #334155;
}

/* ОБЩИЕ ЭФФЕКТЫ */
.mobile-btn:hover{
  transform: translateY(-2px);
}

.mobile-btn:active{
  transform: scale(.97);
}

@media (min-width: 768px){
  .mobile-btn{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    min-height: 58px;
    padding: 0 28px;
    border-radius: 22px;
    font-size: 1rem;
    font-weight: 700;
  }
}


/* ===== WHY US SECTION ===== */
.why-us-section{
  position: relative;
  overflow: hidden;
}

.why-us-section::before{
  content: "";
  position: absolute;
  width: 380px;
  height: 380px;
  left: -120px;
  top: 40px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(16,185,129,0.14) 0%, rgba(16,185,129,0) 70%);
  filter: blur(28px);
  pointer-events: none;
}

.why-us-section::after{
  content: "";
  position: absolute;
  width: 360px;
  height: 360px;
  right: -120px;
  bottom: 0;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(139,92,246,0.12) 0%, rgba(139,92,246,0) 70%);
  filter: blur(30px);
  pointer-events: none;
}

.why-us-badge{
  background: rgba(187, 247, 208, 0.55);
  color: #047857;
  border: 1px solid rgba(255,255,255,0.45);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.why-us-title{
  color: #0f172a;
  line-height: 0.98;
  letter-spacing: -0.04em;
}

.why-us-title span{
  background: linear-gradient(90deg, #10b981, #14b8a6, #8b5cf6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.why-us-subtitle{
  color: #64748b;
  font-size: 1.05rem;
  line-height: 1.65;
}

/* ===== CARD BASE ===== */
.why-card{
  position: relative;
  overflow: hidden;
  min-height: 300px;
  padding: 1.5rem;
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(255,255,255,0.72), rgba(255,255,255,0.58));
  border: 1px solid rgba(255,255,255,0.55);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow:
    0 16px 40px rgba(15,23,42,0.08),
    inset 0 1px 0 rgba(255,255,255,0.68);
  transition:
    transform 0.35s ease,
    box-shadow 0.35s ease,
    border-color 0.35s ease;
}

.why-card::before{
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.26), transparent 35%);
  pointer-events: none;
}

.why-card::after{
  content: "";
  position: absolute;
  top: 0;
  left: -140%;
  width: 70%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.35), transparent);
  transform: skewX(-18deg);
  transition: left 0.85s ease;
  pointer-events: none;
}

.why-card:hover{
  transform: translateY(-10px);
  box-shadow:
    0 24px 52px rgba(15,23,42,0.13),
    inset 0 1px 0 rgba(255,255,255,0.78);
  border-color: rgba(255,255,255,0.82);
}

.why-card:hover::after{
  left: 150%;
}

.why-card h3{
  color: #1e293b;
  letter-spacing: -0.02em;
}

.why-card p{
  line-height: 1.7;
  max-width: 26ch;
  position: relative;
  z-index: 2;
}

/* ===== GLOW ===== */
.why-card-glow{
  position: absolute;
  inset: auto -40px -40px auto;
  width: 140px;
  height: 140px;
  border-radius: 999px;
  filter: blur(32px);
  opacity: 0.22;
  pointer-events: none;
}

/* ===== ICON ===== */
.why-icon{
  position: relative;
  z-index: 2;
  transition: transform 0.32s ease, box-shadow 0.32s ease;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.75),
    0 10px 24px rgba(15,23,42,0.06);
}

.why-card:hover .why-icon{
  transform: rotate(-10deg) scale(1.06);
}

/* ===== LINE ===== */
.why-line{
  height: 4px;
  width: 34%;
  min-width: 84px;
  border-radius: 999px;
  transition: width 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  z-index: 2;
}

.why-card:hover .why-line{
  width: 44%;
  transform: translateX(4px);
}

/* ===== EMERALD ===== */
.why-card-emerald .why-icon{
  background: #d1fae5;
  color: #059669;
}
.why-card-emerald .why-card-glow{
  background: rgba(16,185,129,0.45);
}
.why-card-emerald .why-line{
  background: linear-gradient(90deg, #34d399, #2dd4bf);
  box-shadow: 0 0 18px rgba(45,212,191,0.25);
}

/* ===== TEAL ===== */
.why-card-teal .why-icon{
  background: #ccfbf1;
  color: #0f766e;
}
.why-card-teal .why-card-glow{
  background: rgba(20,184,166,0.42);
}
.why-card-teal .why-line{
  background: linear-gradient(90deg, #2dd4bf, #22d3ee);
  box-shadow: 0 0 18px rgba(34,211,238,0.24);
}

/* ===== ROSE ===== */
.why-card-rose .why-icon{
  background: #ffe4e6;
  color: #e11d48;
}
.why-card-rose .why-card-glow{
  background: rgba(244,63,94,0.36);
}
.why-card-rose .why-line{
  background: linear-gradient(90deg, #fb7185, #f472b6);
  box-shadow: 0 0 18px rgba(244,114,182,0.22);
}

/* ===== VIOLET ===== */
.why-card-violet .why-icon{
  background: #ede9fe;
  color: #7c3aed;
}
.why-card-violet .why-card-glow{
  background: rgba(139,92,246,0.38);
}
.why-card-violet .why-line{
  background: linear-gradient(90deg, #a78bfa, #c084fc);
  box-shadow: 0 0 18px rgba(168,85,247,0.22);
}

/* ===== MOBILE ===== */
@media (max-width: 767px){
  .why-us-section{
    padding-top: 5rem;
    padding-bottom: 5rem;
  }

  .why-us-title{
    font-size: 2.3rem;
    line-height: 1.02;
  }

  .why-us-subtitle{
    font-size: 0.98rem;
    line-height: 1.6;
    padding: 0 0.5rem;
  }

  .why-card{
    min-height: auto;
    padding: 1.25rem;
    border-radius: 24px;
  }

  .why-card p{
    max-width: none;
  }

  .why-line{
    width: 82px;
  }

  .why-card:hover .why-line{
    width: 98px;
  }
}

.why-us-section{
  position: relative;
  background: linear-gradient(
    to bottom,
    rgba(240, 253, 250, 0.6),
    rgba(255,255,255,0.8)
  );
}
/* ласт  ВЕРСИЯЧ*/

/* ===== WHY US SECTION ===== */
.why-us-section{
  position: relative;
  overflow: hidden;
}

.why-us-section::before{
  content: "";
  position: absolute;
  width: 380px;
  height: 380px;
  left: -120px;
  top: 40px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(16,185,129,0.14) 0%, rgba(16,185,129,0) 70%);
  filter: blur(28px);
  pointer-events: none;
}

.why-us-section::after{
  content: "";
  position: absolute;
  width: 360px;
  height: 360px;
  right: -120px;
  bottom: 0;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(139,92,246,0.12) 0%, rgba(139,92,246,0) 70%);
  filter: blur(30px);
  pointer-events: none;
}

.why-us-badge{
  background: rgba(187, 247, 208, 0.55);
  color: #047857;
  border: 1px solid rgba(255,255,255,0.45);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.why-us-title{
  color: #0f172a;
  line-height: 0.98;
  letter-spacing: -0.04em;
}

.why-us-title span{
  background: linear-gradient(90deg, #10b981, #14b8a6, #8b5cf6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.why-us-subtitle{
  color: #64748b;
  font-size: 1.05rem;
  line-height: 1.65;
}

/* ===== CARD BASE ===== */
.why-card{
  position: relative;
  overflow: hidden;
  min-height: 300px;
  padding: 1.5rem;
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(255,255,255,0.72), rgba(255,255,255,0.58));
  border: 1px solid rgba(255,255,255,0.55);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow:
    0 16px 40px rgba(15,23,42,0.08),
    inset 0 1px 0 rgba(255,255,255,0.68);
  transition:
    transform 0.35s ease,
    box-shadow 0.35s ease,
    border-color 0.35s ease;
}

.why-card::before{
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.26), transparent 35%);
  pointer-events: none;
}

.why-card::after{
  content: "";
  position: absolute;
  top: 0;
  left: -140%;
  width: 70%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.35), transparent);
  transform: skewX(-18deg);
  transition: left 0.85s ease;
  pointer-events: none;
}

.why-card:hover{
  transform: translateY(-10px);
  box-shadow:
    0 24px 52px rgba(15,23,42,0.13),
    inset 0 1px 0 rgba(255,255,255,0.78);
  border-color: rgba(255,255,255,0.82);
}

.why-card:hover::after{
  left: 150%;
}

.why-card h3{
  color: #1e293b;
  letter-spacing: -0.02em;
}

.why-card p{
  line-height: 1.7;
  max-width: 26ch;
  position: relative;
  z-index: 2;
}

/* ===== GLOW ===== */
.why-card-glow{
  position: absolute;
  inset: auto -40px -40px auto;
  width: 140px;
  height: 140px;
  border-radius: 999px;
  filter: blur(32px);
  opacity: 0.22;
  pointer-events: none;
}

/* ===== ICON ===== */
.why-icon{
  position: relative;
  z-index: 2;
  transition: transform 0.32s ease, box-shadow 0.32s ease;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.75),
    0 10px 24px rgba(15,23,42,0.06);
}

.why-card:hover .why-icon{
  transform: rotate(-10deg) scale(1.06);
}

/* ===== LINE ===== */
.why-line{
  height: 4px;
  width: 34%;
  min-width: 84px;
  border-radius: 999px;
  transition: width 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  z-index: 2;
}

.why-card:hover .why-line{
  width: 44%;
  transform: translateX(4px);
}

/* ===== EMERALD ===== */
.why-card-emerald .why-icon{
  background: #d1fae5;
  color: #059669;
}
.why-card-emerald .why-card-glow{
  background: rgba(16,185,129,0.45);
}
.why-card-emerald .why-line{
  background: linear-gradient(90deg, #34d399, #2dd4bf);
  box-shadow: 0 0 18px rgba(45,212,191,0.25);
}

/* ===== TEAL ===== */
.why-card-teal .why-icon{
  background: #ccfbf1;
  color: #0f766e;
}
.why-card-teal .why-card-glow{
  background: rgba(20,184,166,0.42);
}
.why-card-teal .why-line{
  background: linear-gradient(90deg, #2dd4bf, #22d3ee);
  box-shadow: 0 0 18px rgba(34,211,238,0.24);
}

/* ===== ROSE ===== */
.why-card-rose .why-icon{
  background: #ffe4e6;
  color: #e11d48;
}
.why-card-rose .why-card-glow{
  background: rgba(244,63,94,0.36);
}
.why-card-rose .why-line{
  background: linear-gradient(90deg, #fb7185, #f472b6);
  box-shadow: 0 0 18px rgba(244,114,182,0.22);
}

/* ===== VIOLET ===== */
.why-card-violet .why-icon{
  background: #ede9fe;
  color: #7c3aed;
}
.why-card-violet .why-card-glow{
  background: rgba(139,92,246,0.38);
}
.why-card-violet .why-line{
  background: linear-gradient(90deg, #a78bfa, #c084fc);
  box-shadow: 0 0 18px rgba(168,85,247,0.22);
}

/* ===== MOBILE ===== */
@media (max-width: 767px){
  .why-us-section{
    padding-top: 5rem;
    padding-bottom: 5rem;
  }

  .why-us-title{
    font-size: 2.3rem;
    line-height: 1.02;
  }

  .why-us-subtitle{
    font-size: 0.98rem;
    line-height: 1.6;
    padding: 0 0.5rem;
  }

  .why-card{
    min-height: auto;
    padding: 1.25rem;
    border-radius: 24px;
  }

  .why-card p{
    max-width: none;
  }

  .why-line{
    width: 82px;
  }

  .why-card:hover .why-line{
    width: 98px;
  }
}