/* Мобильные устройства */
@media (max-width: 768px) {
  .main-content {
    padding-top: 80px;
    padding-left: 15px;
    padding-right: 15px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .obelisk-header {
    padding: 0;
    height: auto;
    position: fixed;
    background: none;
    backdrop-filter: none;
    width: 100%;
    z-index: 1000;
    top: 0;
  }

  .obelisk-header2 {
    background: rgba(14, 14, 14, 0.7);
    border-radius: 25px;
    padding: 16px 29px 15px 29px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: center;
    justify-content: flex-start;
    width: 305px;
    position: absolute;
    left: 50%;
    translate: -50%;
    top: 26px;
    backdrop-filter: blur(14.6px);
  }

  .frame-1 {
    display: flex;
    flex-direction: row;
    gap: 9px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    align-content: center;
    flex-shrink: 0;
    width: 266px;
    position: relative;
  }

  .frame-1 a {
    color: #ffffff;
    text-align: center;
    font-family: "SfProDisplay-Regular", sans-serif;
    font-size: 12px;
    letter-spacing: -0.01em;
    font-weight: 400;
    position: relative;
  }

  ._01-span, ._02-span, ._03-span, ._04-span, ._05-span, ._06-span {
    display: none;
  }

  ._01-span2, ._02-span2, ._03-span2, ._04-span2, ._05-span2, ._06-span2 {
    color: #ffffff;
    font-family: "SfProDisplay-Regular", sans-serif;
    font-size: 12px;
    letter-spacing: -0.01em;
    font-weight: 400;
  }

  .obelisk {
    background: #ff60ec;
    border-radius: 25px;
    width: 100px;
    height: 30px;
    padding: 7px 12px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: center;
    justify-content: flex-start;
    position: absolute;
    left: 50%;
    translate: -50%;
    top: -20px;
    backdrop-filter: blur(14.6px);
  }

  .obelisk span {
    color: #ffffff;
    text-align: center;
    font-family: "WorkSans-SemiBold", sans-serif;
    font-size: 15px;
    letter-spacing: -0.04em;
    font-weight: 600;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .obelisk .obelisk-span {
    background: none;
    -webkit-background-clip: initial;
    -webkit-text-fill-color: #ffffff;
    color: #ffffff;
    filter: none;
  }

  .obelisk .obelisk-span2 {
    color: #ffffff;
  }

  .frame-5 {
    display: none;
  }

  .subtitle {
    font-size: 30px;
    margin-top: 30px;
    opacity: 0.7;
    text-align: center;
  }

  .title {
    font-size: 60px;
    margin-bottom: 30px;
    margin-top: 10px;
    text-align: center;
    white-space: normal;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 0.8;
  }

  .content-wrapper {
    height: auto;
    padding-top: 40px;
    position: relative;
    width: 100%;
    display: flex;
    justify-content: center;
    min-height: 500px;
  }

  .kraft-paper {
    width: 100%;
    height: 350px;
    position: relative;
    left: -70px;
    top: -130px;
    transform: none;
    margin-top: 20px;
    max-width: 300px;
  }

  .macbook {
    position: absolute;
    width: 500px;
    height: 500px;
    left: 130px;
    top: 90px;
    transform: translateX(-20%);
    margin: 0;
    z-index: 2;
  }

  .diamonds {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 100;
  }

  .diamond1, .diamond2, .diamond3, .diamond4, .diamond5, .diamond6 {
    width: 200px;
    height: 200px;
    opacity: 1;
    margin: 0;
  }

  .diamond1 {
    top: -60%;
    left: 70%;
  }

  .diamond2 {
    top: 55%;
    right: 65%;
  }

  .diamond3 {
    top: 5%;
    left: -30%;
  }

  .diamond4 {
    top: 10%;
    right: -25%;
  }

  .diamond5, .diamond6 {
    display: none;
  }

  .ellipse-2362 {
    width: 100%;
    height: 100%;
    top: 50%;
    opacity: 1;
  }

  /* Работы учеников */
  .students-works {
    padding: 0;
    margin: -50px 0;
    overflow: visible;
  }

  /* Общие стили для всех секций на мобильных устройствах */
  .section-header {
    margin: 60px 0 30px;
    gap: 10px;
    padding-left: 10px;
    justify-content: flex-start;
    width: 100%;
  }

  .section-number {
    font-size: 27px !important;
    font-weight: 600 !important;
    font-family: "SfProDisplay-Semibold", sans-serif !important;
  }

  .section-title {
    font-size: 27px !important;
    font-weight: 600 !important;
    font-family: "SfProDisplay-Semibold", sans-serif !important;
    text-align: left;
  }

  /* Убираем индивидуальные стили для всех секций */
  .students-works .section-header {
    padding-left: 25px;
  }
  .advantages .section-header,
  .club-branches .section-header {
    padding-left: 10px;
  }
  .reviews .section-header {
    padding-left: 25px;
  }
  .contacts .section-header {
    padding-left: 10px;
    justify-content: flex-start;
    width: 100%;
  }

  .students-works .section-number,
  .advantages .section-number,
  .club-branches .section-number,
  .reviews .section-number,
  .contacts .section-number,
  .students-works .section-title,
  .advantages .section-title,
  .club-branches .section-title,
  .reviews .section-title,
  .contacts .section-title {
    font-weight: 600 !important;
    font-family: "SfProDisplay-Semibold", sans-serif !important;
  }

  .work-card.large,
  .work-card.small {
    width: calc(100vw - 30px);
    height: 280px;
  }

  .work-card.large::before {
    display: none;
  }

  .discount-banner {
    margin: -100px 0; /* Уменьшите это значение */
    width: 250vw;
    height: 400px;
 }
  /* Преимущества */
  .advantages {
    padding: 0 15px;
  }

  .advantages-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
  }

  .advantage-card {
    width: 100%; /* Задаем ширину 100% для адаптивности */
    height: auto;
    padding: 15px;
    border-radius: 10px;
    background: rgba(14, 14, 14, 0.7);
    transition: all 0.3s ease;
  }

  .advantage-card:nth-child(1) {
    width: 70%;
    height: var(--card-1-height);
    top: 64px;
    position: relative;
  }

  .advantage-card:nth-child(2) {
    width: 73%;
    height: var(--card-2-height);
    top: 100px;
    position: relative;
  }

  .advantage-card:nth-child(3) {
    width: 73%;
    height: var(--card-3-height);
    top: 130px;
    position: relative;
  }

  .advantage-content {
    padding-right: 0;
  }

  .advantage-title {
    font-size: 24px;
  }

  .advantage-description {
    font-size: 14px;
    line-height: 1.4;
  }

  .advantage-number {
    color: rgba(255, 255, 255, 0.05); /* Уменьшаю яркость цифр */
  }

  /* Ветки клуба */
  .club-branches {
    padding: 0 15px;
    margin: 60px auto;
  }

  .branches-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  .club-branches .section-header {
    gap: 10px;
  }

  .club-branches .section-title {
    font-size: 27px;
    z-index: 100;
  }

  .club-branches .section-number {
    font-size: 27px;
  }
  .club-diamond1 {
    width: 400px;
    height: 400px;
    left: -230px;
    top: 355px;
    z-index: -100;
  }
  .club-diamond2 {
    width: 200px;
    height: 200px;
    left: 270px;
    top: -50px;
    z-index: -1;
  }

  /* Отзывы */
  .reviews {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin: 60px 0;
    overflow: hidden;
  }

  .reviews-slider {
    margin: 0;
    padding: 0 15px;
    width: 100%;
    overflow: hidden;
  }

  .reviews-track {
    display: flex;
    gap: 15px;
    transition: transform 0.3s ease;
    width: max-content;
    padding: 0;
    margin: 0;
    touch-action: pan-x;
  }

  .review-card {
    width: calc(100vw - 30px);
    min-height: fit-content;
    height: auto !important;
    margin-bottom: 15px;
    transform: none !important;
    display: flex;
    flex-direction: column;
    position: relative;
    flex-shrink: 0;
  }

  .review-header {
    padding: 0;
    margin-bottom: 15px;
  }

  .review-content {
    padding: 20px;
    margin-bottom: 15px;
    height: auto !important;
    min-height: auto;
    background: rgba(14, 14, 14, 0.9);
    white-space: normal;
    overflow: visible;
    position: relative;
    border-radius: 25px;
  }

  .review-content p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    white-space: normal;
    overflow: visible;
    color: #ffffff;
  }

  .review-footer {
    padding: 0;
    margin-bottom: 5px;
    margin-top: -15px; /* Поднимаю кнопки выше */
    position: relative;
  }

  .reviews-controls {
    position: relative;
    margin-top: 30px;
    padding: 0;
    justify-content: center;
  }

  /* Контакты */
  .contacts {
    padding: 0 15px;
    margin: 60px auto;
    position: relative;
    overflow: hidden; /* Ограничиваем сетку */
    min-height: 700px; /* Задаем минимальную высоту для секции */
  }

  .contacts::before {
    display: none;
    content: '';
    height: 100vh;
    opacity: 1;
    background-size: 150% auto;
    transform: rotate(90deg);
    width: 100vh;
    position: absolute;
    left: -220px;
    top: 150px;
    z-index: -1;
  }

  .contacts-grid {
    position: relative;
    z-index: 2; /* Поднимаем карточки над сеткой */
    flex-direction: column;
    gap: 15px;
  }

  /* Переопределяем переменные для мобильной версии */
  :root {
    /* Первая карточка */
    --contact-card-1-width: 87%;
    --contact-card-1-height: 140px;
    --contact-card-1-x: 30px;
    --contact-card-1-y: -10px;
    
    /* Вторая карточка */
    --contact-card-2-width: 87%;
    --contact-card-2-height: 140px;
    --contact-card-2-x: 30px;
    --contact-card-2-y: 10px;
    
    /* Третья карточка */
    --contact-card-3-width: 87%;
    --contact-card-3-height: 160px;
    --contact-card-3-x: 30px;
    --contact-card-3-y: 30px;
  }

  .contacts-grid {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
  }

  .contact-card {
    background: rgba(14, 14, 14, 0.7);
    border-radius: 10px;
    padding: 15px;
    position: relative;
  }

  .contact-card:nth-child(1) {
    width: var(--contact-card-1-width);
    height: var(--contact-card-1-height);
    transform: translate(var(--contact-card-1-x), var(--contact-card-1-y));
  }

  .contact-card:nth-child(2) {
    width: var(--contact-card-2-width);
    height: var(--contact-card-2-height);
    transform: translate(var(--contact-card-2-x), var(--contact-card-2-y));
  }

  .contact-card:nth-child(3) {
    width: var(--contact-card-3-width);
    height: var(--contact-card-3-height);
    transform: translate(var(--contact-card-3-x), var(--contact-card-3-y));
  }

  .contact-content {
    margin-bottom: 5px;
    gap: 5px;
  }

  .contact-header {
    gap: 10px;
  }

  .contact-icon {
    width: 20px;
    height: 20px;
  }

  .contact-icon[alt="YouTube"] {
    width: 20px;
    height: 20px;
  }
  .contact-title {
    font-size: 18px;
    width: auto;
  }

  .contact-description {
    font-size: 12px;
    margin-bottom: 5px;
    line-height: 1.2;
  }

  .contact-button {
    padding: 8px 16px;
    margin-top: 5px;
  }

  .contact-button span {
    font-size: 12px;
  }

  /* Футер */
  .footer {
    padding: 40px 15px;
  }

  .footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
  }

  .footer-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin-bottom: 30px;
  }

  .footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 5px;
  }

  .footer-logo-o {
    color: #FF60EC;
  }

  .footer-copyright {
    font-size: 14px;
    opacity: 0.5;
  }

  .footer-nav {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    width: 100%;
    margin-bottom: 40px;
  }

  .footer-nav-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .footer-nav-section:first-child {
    align-items: flex-start;
  }

  .footer-nav-section:last-child {
    align-items: flex-end;
  }

  .footer-nav-title {
    font-size: 14px;
    opacity: 0.5;
    font-weight: 600;
    color: #fff;
  }

  .footer-nav-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .footer-nav-section:first-child .footer-nav-links {
    align-items: flex-start;
  }

  .footer-nav-section:last-child .footer-nav-links {
    align-items: flex-end;
  }

  .footer-nav-links a {
    color: #fff;
    opacity: 0.5;
    font-size: 14px;
    text-decoration: none;
    transition: opacity 0.3s ease;
  }

  .footer-nav-links a:hover {
    opacity: 0.8;
  }

  .footer-credits {
    font-size: 12px;
    opacity: 0.5;
    text-align: center;
    width: 100%;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 0;
  }

  /* Общие стили для слайдеров */
  .slider-arrows {
    display: none; /* Скрываем стрелки на мобильных устройствах */
  }

  .slider-controls {
    justify-content: center;
    padding-left: 0;
    margin-top: 30px;
  }

  .slider-progress {
    gap: 8px;
  }

  .progress-segment,
  .progress-bar {
    width: 40px;
    height: 2px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
  }

  .progress-segment.active,
  .progress-bar.active {
    height: 2px;
    background: #FF60EC;
    opacity: 1;
  }

  /* Работы учеников */
  .works-slider {
    width: 100%;
    overflow: hidden;
    margin: 0;
    padding: 0 15px;
  }

  .works-track {
    display: flex;
    gap: 15px;
    transition: transform 0.3s ease;
    width: max-content;
    padding: 0;
    margin: 0;
    touch-action: pan-x;
  }

  .work-card {
    width: calc(100vw - 30px) !important;
    height: 280px !important;
    opacity: 1 !important;
    margin: 0;
    flex-shrink: 0;
    transform: none !important;
  }

  .work-card.large,
  .work-card.small {
    background: transparent;
    box-shadow: none;
  }

  .work-card.large::before {
    display: none;
  }

  .slider-footer {
    flex-direction: column;
    align-items: center;
    gap: 20px;
  }

  .telegram-link {
    margin-left: 0;
  }

  .reviews-slider {
    overflow: hidden;
    margin: 0 -15px;
    padding: 0 15px;
    touch-action: pan-x;
  }

  .reviews-track {
    gap: 15px;
    touch-action: pan-x;
  }

  .review-card {
    width: calc(100vw - 30px);
    opacity: 1;
  }

  .review-card.active {
    opacity: 1;
  }

  .reviews-controls {
    justify-content: center;
    padding-left: 0;
    margin-top: 30px;
  }

  .review-header {
    padding: 0;
  }

  .mask-group {
    position: absolute;
    width: 120%;
    height: 120%;
    left: -35px;
    top: -50px;
    transform: none;
    opacity: 4;
    z-index: -1;
  }

  .club-diamond3 {
    top: 80%;
    left: 20%;
    transform: translateY(-100%);
  }

  .grid-background {
    display: block;
    width: 200vw; /* Увеличиваем размер */
    height: 200vh;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0.1;
    pointer-events: none;
    z-index: -2;
    transform: scale(1); /* Уменьшаем масштаб сетки */
    transform-origin: top left;
  }

  .mobile-grid-background {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: auto;
    z-index: -1;
  }

  .branch-card {
    width: 80%;
    height: 160px;
    margin: 0 auto;
    border-radius: 10px;
    padding: 0px 24px;
    display: flex;
    flex-direction: column;
  }

  .branch-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0px;
    padding-top: 20px;
  }

  .branch-title {
    font-size: 24px;
    text-align: left;
    margin: 0;
  }

  .branch-description {
    font-size: 14px;
    text-align: left;
    margin: 0px;
    line-height: 1.5;
    padding-bottom: 10px;
  }

  .branch-number {
    opacity: 0.2;
  }

  .advantage-card {
    width: 90%; /* Уменьшаем ширину карточек на мобильных устройствах */
  }

  .work-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    background: rgba(0, 0, 0, 0.2);
  }

  .work-image {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: 10px;
    background: rgba(14, 14, 14, 0.7);
  }

  .work-image.video-error::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(14, 14, 14, 0.7);
    z-index: 2;
  }

  .work-image.video-error::after {
    content: 'Нажмите для воспроизведения';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 14px;
    z-index: 3;
    background: rgba(0, 0, 0, 0.5);
    padding: 8px 16px;
    border-radius: 20px;
  }
}

@media (max-width: 480px) {
  .advantage-title {
    font-size: 20px;
  }
  .advantage-description {
    font-size: 12px;
  }
  .branch-title {
    font-size: 20px;
  }
  .branch-description {
    font-size: 12px;
  }
}

@media (max-width: 380px) {
  .advantage-title {
    font-size: 18px;
  }
  .advantage-description {
    font-size: 11px;
  }
  .branch-title {
    font-size: 18px;
  }
  .branch-description {
    font-size: 11px;
  }
}

@media (max-width: 320px) {
  .advantage-title {
    font-size: 16px;
  }
  .advantage-description {
    font-size: 10px;
  }
  .branch-title {
    font-size: 16px;
  }
  .branch-description {
    font-size: 10px;
  }
}