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

body {
  font-family: "Arial", sans-serif;
  background: #000;
  color: white;
  overflow: hidden;
}


.video-container {
  width: 100vw;
  height: 100vh;
  background: #000;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
}

.video-wrapper {
  flex: 1;
  position: relative;
  background: #000;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.video-player {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Экран окончания видео */
.end-screen {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 50;
}

.end-screen.active {
  display: flex;
}

.end-screen-content {
  text-align: center;
  /* background: rgba(255, 255, 255, 0.1); */
  padding: 40px;
  border-radius: 15px;
  backdrop-filter: blur(10px);
  max-width: 600px;
  width: 90%;
}

.end-screen-content h2 {
  font-size: 2em;
  margin-bottom: 10px;
  color: #fff;
}

.end-screen-content p {
  font-size: 1.2em;
  margin-bottom: 30px;
  color: #ccc;
}

.action-buttons {
  display: flex;
  flex-direction: column;
  /* align-items: center; */
  gap: 15px;
  margin-top: 15px;
  position: relative;
  align-items: center; /* Центрируем элементы по горизонтали */
}

/* Убираем возможные отступы у дочерних элементов */
.action-buttons > * {
  margin-top: 0;
  margin-bottom: 0;
}

.action-btn {
  padding: 0;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s;
  text-decoration: none;
  display: block;
  width: 437px; /* 350 * 1.25 */
  height: 150px; /* 120 * 1.25 */
}

.action-btn img {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 8px;
  object-fit: contain;
}

.action-btn.primary {
  width: 562px; /* 450 * 1.25 */
  height: 233px; /* 220 * 1.25 */
}

.action-btn.secondary, .action-btn {
  width: 175px; /* 140 * 1.25 */
  height: 100px; /* assuming base height */
}

.action-btn.lower-left {
  position: absolute;
  bottom: 50px;
  left: 50px;
}

@media (max-width: 768px) {
  .action-btn.primary {
    width: 312px; /* 250 * 1.25 */
    height: 125px; /* 100 * 1.25 */
  }

  .action-btn.secondary, .action-btn {
    width: 100px; /* 80 * 1.25 */
    height: 75px; /* 60 * 1.25 */
  }

  .action-btn.lower-left {
    bottom: 30px;
    left: 30px;
  }

  .action-btn-row {
    gap: 10px;
  }
}

.action-btn-row {
  display: flex;
  gap: 15px;
  justify-content: space-between;
}

.action-btn:hover {
  transform: scale(1.05);
}

.action-btn.primary:hover {
  transform: scale(1.03);
}

.action-btn.secondary:hover, .action-btn:hover {
  transform: scale(1.05);
}

.controls-container {
  padding: 15px 20px;
  background: rgba(0, 0, 0, 0.8);
  z-index: 10000;
}

.progress-container {
  margin-bottom: 12px;
}

.progress-bar {
  width: 100%;
  height: 5px;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 3px;
  cursor: pointer;
  position: relative;
  transition: height 0.2s;
}

.progress-bar:hover {
  height: 8px;
}

.progress-filled {
  height: 100%;
  background: #ff4444;
  border-radius: 3px;
  width: 0%;
  position: relative;
  transition: height 0.2s;
}

.progress-bar:hover .progress-filled {
  height: 8px;
}

.progress-thumb {
  width: 15px;
  height: 15px;
  background: #ff4444;
  border-radius: 50%;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.2s, transform 0.2s;
}

.progress-bar:hover .progress-thumb {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.2);
}

.controls-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.control-btn {
  background: none;
  border: none;
  color: white;
  font-size: 1.3em;
  cursor: pointer;
  padding: 8px 12px;
  border-radius: 4px;
  transition: background 0.2s;
}

.control-btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.time-display {
  font-family: monospace;
  font-size: 1em;
  color: #ccc;
}

.pause-icon,
.exit-fullscreen-icon {
  display: none;
}

.playing .play-icon,
.fullscreen .fullscreen-icon {
  display: none;
}

.playing .pause-icon,
.fullscreen .exit-fullscreen-icon {
  display: inline;
}

/* Анимации */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.end-screen-content {
  animation: fadeIn 0.5s ease-out;
}

.action-btn {
  animation: fadeIn 0.5s ease-out backwards;
}

.action-btn[data-delay="0"] {
  animation-delay: 0s;
}
.action-btn[data-delay="1.5"] {
  animation-delay: 1.5s;
}
.action-btn[data-delay="2.5"] {
  animation-delay: 2.5s;
}
.action-btn[data-delay="3.5"] {
  animation-delay: 3.5s;
}

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

  .end-screen-content {
    padding: 20px;
    margin: 20px;
  }

  .end-screen-content h2 {
    font-size: 1.5em;
  }
}

/* Полноэкранные стили */
.video-container:fullscreen .controls-container {
  z-index: 2147483647;
}

.video-container:-webkit-full-screen .controls-container {
  z-index: 2147483647;
}

.video-container:-moz-full-screen .controls-container {
  z-index: 2147483647;
}

.video-container:-ms-fullscreen .controls-container {
  z-index: 2147483647;
}


/* Скрыть все контролы */
.controls-container {
    display: none !important;
}

/* Или если нужно скрывать автоматически */
.video-container.controls-hidden .controls-container {
    display: none;
}


/* Контейнер интерактивных зон */
.interactive-zones {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 40;
}

/* Базовая стилизация зоны */
.zone {
    position: absolute;
    pointer-events: none;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    opacity: 0;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 12px;
    padding: 12px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: none; /* Изначально скрываем все зоны */
}

.zone[data-zone="about"] {
    transition: opacity 0.5s ease-in-out, transform 0.3s ease, background 0.3s ease;
}

.zone.visible {
    opacity: 1; /* Значение будет управляться JavaScript */
    display: block;
    pointer-events: all;
    transition: opacity 0.3s ease; /* Более плавное изменение прозрачности */
}

/* Удалена старая анимация fadeInOut, так как мигание теперь управляется JavaScript */

/* Специфические стили для зоны about */
/* .zone-tr[data-zone="about"] {
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.3);
} */

/* Позиционирование зон */
.zone-tl { top: 20px; left: 20px; }
.zone-tr { top: 20px; right: 20px; }
.zone-tr-alt { top: 80px; right: 20px; }

.zone-tr[data-zone="about"] {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: opacity 0.5s ease-in-out, transform 0.3s ease, background 0.3s ease;
}

.zone-tr-alt[data-zone="about"] {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: opacity 0.5s ease-in-out, transform 0.3s ease, background 0.3s ease;
}

.zone-tr[data-zone="about"] .zone-icon {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.zone-tr-alt[data-zone="about"] .zone-icon {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.zone-tr[data-zone="about"] .zone-icon img {
    width: 100%;
    height: 100%;
    max-width: 50px;
    max-height: 50px;
    object-fit: contain;
    background-color: transparent;
    transition: transform 0.2s ease;
}

.zone-tr-alt[data-zone="about"] .zone-icon img {
    width: 100%;
    height: 100%;
    max-width: 50px;
    max-height: 50px;
    object-fit: contain;
    background-color: transparent;
    transition: transform 0.2s ease;
}
.zone-bl { bottom: 20px; left: 20px; }
.zone-br { bottom: 20px; right: 20px; }

/* Иконка зоны */
.zone-icon {
    font-size: 1.5em;
    transition: transform 0.2s ease;
}

.zone-icon img {
    width: 33%;
    height: 33%;
    display: block;
    object-fit: contain;
}

/* Выпадающее меню */
.zone-dropdown {
    position: absolute;
    background: rgba(0, 0, 0, 0.9);
    border-radius: 8px;
    padding: 8px 0;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Позиционирование выпадающих меню */
.zone-tl .zone-dropdown { 
    top: 100%; 
    left: 0; 
    margin-top: 8px; 
}
.zone-tr .zone-dropdown {
    top: 100%;
    right: 0;
    margin-top: 8px;
}

.zone-tr-alt .zone-dropdown {
    top: 100%;
    right: 0;
    margin-top: 8px;
}
.zone-bl .zone-dropdown { 
    bottom: 100%; 
    left: 0; 
    margin-bottom: 8px; 
}
.zone-br .zone-dropdown { 
    bottom: 100%; 
    right: 0; 
    margin-bottom: 8px; 
}

/* Элементы меню */
.dropdown-item {
    padding: 10px 15px;
    color: white;
    text-decoration: none;
    display: block;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
    cursor: pointer;
}

.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.1);
    border-left-color: #ff4444;
    padding-left: 20px;
}

/* Состояния зон */

/* Ховер на зоне - показываем меню */
.zone:hover {
    opacity: 1 !important;
    background: rgba(0, 0, 0, 0.7);
    transform: scale(1.05);
}

.zone:hover .zone-icon {
    transform: scale(1.1);
}

.zone:hover .zone-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Задержка для плавного появления меню */
.zone-dropdown {
    transition-delay: 0.1s;
}

.zone:hover .zone-dropdown {
    transition-delay: 0s;
}

/* Видео воспроизводится - зоны почти невидимы */
.video-container.playing .zone {
    opacity: 0.15;
}

/* Видео на паузе - зоны более заметны */
.video-container.paused .zone {
    opacity: 0.4;
}

/* Полноэкранный режим */
/* .video-container.fullscreen .zone {
    padding: 16px;
} */

.video-container.fullscreen .zone-icon {
    font-size: 1.8em;
}

.video-container.fullscreen .zone-dropdown {
    min-width: 220px;
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .zone {
        padding: 16px;
        opacity: 0.4;
    }
    
    .zone-icon {
        font-size: 1.8em;
    }
    
    .zone-dropdown {
        min-width: 200px;
        font-size: 1.1em;
    }
    
    .zone-tl { top: 15px; left: 15px; }
    .zone-tr { top: 15px; right: 15px; }
    .zone-bl { bottom: 15px; left: 15px; }
    .zone-br { bottom: 15px; right: 15px; }
    
    /* На мобильных меню появляется по клику */
    .zone-dropdown {
        display: none;
    }
    
    .zone.active .zone-dropdown {
        display: block;
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
}

/* Анимация появления */
@keyframes zoneAppear {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 0.3;
        transform: scale(1);
    }
}

/* Задержки для последовательного появления */
.zone-tl { animation-delay: 0.1s; }
.zone-tr { animation-delay: 0.2s; }
.zone-bl { animation-delay: 0.3s; }
.zone-br { animation-delay: 0.4s; }

/* Стили для временных кнопок */
.time-buttons {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    z-index: 100;
}

.time-btn {
    padding: 0;
    background: none;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: block;
    width: 525px; /* 350 * 1.5 */
    height: 180px; /* 120 * 1.5 */
    position: absolute;
    bottom: 20px;
    opacity: 0;
    transform: scale(0.8);
}

.time-btn.visible {
    opacity: 1;
    transform: scale(1);
}

.time-btn-center {
    left: 50%;
    transform: translateX(-50%) scale(0.8);
}

.time-btn-center.visible {
    transform: translateX(-50%) scale(1);
}

.time-btn-right {
    left: 50%;
    margin-left: 300px; /* adjust as needed */
    transform: scale(0.8);
}

.time-btn-right.visible {
    transform: scale(1);
}

.time-btn-left {
    right: 50%;
    margin-right: 300px; /* adjust as needed */
    transform: scale(0.8);
}

.time-btn-left.visible {
    transform: scale(1);
}

.time-btn:hover {
    transform: scale(1.05);
}

.time-btn:active {
    transform: scale(0.95);
}

.time-btn-center:hover {
    transform: translateX(-50%) scale(1.05);
}

.time-btn-right:hover {
    transform: scale(1.05);
}

.time-btn-left:hover {
    transform: scale(1.05);
}

.time-btn img {
    width: 100%;
    height: 100%;
    display: block;
    border-radius: 20px;
    object-fit: scale-down;
    /* backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1); */
}