/* Кнопка "Відтворити на весь екран" */
.fullscreen-btn {
  display: flex;
  align-items: center;
  background: #fff;
  z-index: 10;
  color: #222;
  border: none;
  border-radius: 999px;
  padding: 21px 26px 23px 26px;
  gap: 16px;
  cursor: pointer;
  width: fit-content;
  justify-content: flex-end;
  overflow: hidden;
  white-space: nowrap;
  font-size: 22px;
  line-height: 112.8%;
  font-weight: bold;
  position: relative;
  opacity: 0;
  transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  height: 70px;
}

.fullscreen-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  min-width: 20px;
  position: relative;
  right: 0;
  transition: right 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.fullscreen-icon svg {
  width: 20px;
  height: 20px;
}

.fullscreen-label {
  opacity: 0;
  max-width: 0;
  margin-right: 0;
  transition: opacity 0s,
    max-width 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.05s,
    margin-right 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.05s;
  font-size: 16px;
  overflow: hidden;
  flex-shrink: 0;
}



.fullscreen-btn:focus-visible {
  outline: 2px solid #0066cc;
  outline-offset: 2px;
}

/* Модальне вікно для відео */
.video-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  /* Dynamic viewport height для мобільних браузерів */
  background: rgba(0, 0, 0, 0.95);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  overflow: hidden;
}

/* Кнопка закриття */
.close-video-btn {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  background: rgba(0, 0, 0, 0.7);
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 1002;
  transition: all 0.3s ease;
}

.close-video-btn:hover {
  background: rgba(0, 0, 0, 0.9);
  border-color: rgba(255, 255, 255, 0.6);
  transform: scale(1.1);
}

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

/* Приховування нативної кнопки Done на iPhone/Safari */
video::-webkit-media-controls-panel {
  display: none !important;
}

video::-webkit-media-controls-play-button {
  display: none !important;
}

video::-webkit-media-controls-timeline {
  display: none !important;
}

/* Приховуємо кнопку fullscreen на iOS щоб не показувати Done */
video::-webkit-media-controls-fullscreen-button {
  display: none !important;
}

video::-webkit-media-controls-toggle-closed-captions-button {
  display: none !important;
}

.video-container {
  position: relative;
  width: 90vw;
  max-width: 1200px;
  height: auto;
}

.video-container video {
  width: 100%;
  height: auto;
  max-height: 90vh;
  object-fit: contain;
}

/* Disclaimer для мобільних */
.disclaimer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1001;
}

.disclaimer img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

/* Мобільні стилі для відео */
@media (max-width: 768px) {
  .fullscreen-btn {
    font-size: 17.1px;
  }

  .video-container {
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    /* Dynamic viewport height */
    max-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .video-container video {
    width: 100%;
    height: 100%;
    max-height: 100dvh;
    object-fit: contain;
  }

  .close-video-btn {
    top: 12px;
    right: 12px;
    width: 44px;
    height: 44px;
  }

  /* В landscape mode на мобільних */
  @media (orientation: landscape) {
    .video-container {
      padding: 0;
    }

    .video-container video {
      object-fit: contain;
      max-height: calc(100dvh - 24px);
      /* Відступ для кнопки закриття */
    }
  }
}

/* Фонове відео */
.bg-video {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  object-fit: cover;
  z-index: -1;
  pointer-events: none;
  min-width: 100%;
  min-height: 100%;
  background: #000;
}

/* Overlay для затемнення відео */
.bg-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.65);
  z-index: 0;
  pointer-events: none;
}

/* Base reset */
* {
  box-sizing: border-box;
  margin-block-start: 0;
  margin-block-end: 0;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  background: #000;
  color: #FFFFFF;
  font-family: 'Inter', -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.page {
  min-height: 100svh;
  padding: clamp(16px, 3vw, 48px);
  display: flex;
  flex-direction: column;
}

/* Header */
.header {
  margin-bottom: 86px;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 1s ease-out 0.2s forwards;
}

.brand {
  display: flex;
  align-items: center;
  gap: 28px;
  letter-spacing: 0.12em;
  font-weight: 700;
  text-transform: uppercase;
  color: #FFFFFF;
  opacity: 0.9;
}

.brand-mark {
  display: inline-flex;
}

.brand-name {
  white-space: nowrap;
  display: flex;
  max-width: 264px;
}

/* Content */
.content {
  max-width: 1640px;
  flex: 1;
  margin: 0 auto;
}

.title {
  margin: 0 0 clamp(31px, 8vh, 33px);
  font-weight: 600;
  line-height: 1.05;
  font-size: clamp(34px, 9vw, 116px);
  letter-spacing: -0.02em;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 1s ease-out 0.6s forwards;
}

.lead-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  /* gap: clamp(60px, 36vh, 162px) 12px; */
  grid-template-areas:
    "text1 text2"
    "btn email";
}

.lead-first {
  grid-area: text1;
}

.lead-second {
  grid-area: text2;
}

.fullscreen-btn {
  grid-area: btn;
}

.email {
  grid-area: email;
}



.lead {
  margin: 0;
  margin-bottom: 1.5em;
  font-size: clamp(20px, 2.2vw, 28px);
  line-height: 1.6;
  max-width: 532px;
  color: rgba(255, 255, 255, 0.85);
  opacity: 0;
  transform: translateY(25px);
  transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

.lead-first {
  animation: fadeInUp 1s ease-out 1.2s forwards;
}

.lead-second {
  animation: fadeInUp 1s ease-out 1.8s forwards;
}

.lead-third {
  animation: fadeInUp 1s ease-out 2.4s forwards;
}

.lead-fourth {
  animation: fadeInUp 1s ease-out 3.0s forwards;
}

/* Footer */
.footer {
  margin-top: auto;
  padding-top: 32px;
  /* height: clamp(30px, 6vh, 100px); */
  display: flex;
  align-items: center;
  justify-content: space-between;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 1s ease-out 2.4s forwards;
}

.email {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: clamp(20px, 2.2vw, 28px);
  color: #FFFFFF;
  text-decoration: none;
  opacity: 0.95;
  text-decoration-line: underline;
  text-underline-offset: 8px;
  opacity: 0;
  transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);

}

.email:hover {
  text-decoration: underline;
}

.icon {
  display: inline-flex;
  transform: translateY(1px);
}

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

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Layout tweaks for very small phones */
@media screen and (max-width: 768px) {
  body {
    background: #101010;
  }

  .header {
    margin-bottom: 22px;
  }

  .content {
    max-width: 100%;
  }

  .footer {
    display: none;
  }

  .lead {
    max-width: 100%;
    margin-bottom: 1em;
  }

  .lead-container {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto auto;
    gap: 24px;
    grid-template-areas:
      "text1"
      "text2"
      "btn"
      "email";
  }

  .brand {
    gap: 9px;
  }

  .icon svg {
    max-width: 18px;
  }

  .brand-mark {
    max-width: 14px;
  }

  .brand-name svg {
    max-width: 113px;
  }
}