/* ==========================================================================
   akvinbg - Mobil Destekli & Sesli Video Deneyimi
   ========================================================================== */

:root {
  --bg-color: #060608;
  --text-primary: #ffffff;
  --text-secondary: rgba(255, 255, 255, 0.65);
  --glass-bg: rgba(18, 18, 24, 0.68);
  --glass-border: rgba(255, 255, 255, 0.12);
  --watermark-color: rgba(255, 255, 255, 0.40);
  --font-display: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'Space Grotesk', monospace;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
}

html, body {
  width: 100%;
  height: 100%;
  height: 100dvh;
  overflow: hidden;
  background-color: var(--bg-color);
  font-family: var(--font-display);
  color: var(--text-primary);
  position: fixed;
}

.hidden {
  display: none !important;
}

/* ==========================================================================
   1. AKVINBG YÜKLENME EKRANI & SESLİ BAŞLATMA
   ========================================================================== */

.loader-screen {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  z-index: 9999;
  background: radial-gradient(circle at center, #12121c 0%, #050508 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.6s ease;
}

.loader-screen.fade-out {
  opacity: 0;
  transform: scale(1.06);
  filter: blur(10px);
  pointer-events: none;
}

.loader-box {
  width: min(88vw, 380px);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.brand-loader {
  margin-bottom: 24px;
}

.loader-title {
  font-size: clamp(2.6rem, 8.5vw, 4rem);
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  background: linear-gradient(135deg, #ffffff 40%, rgba(255, 255, 255, 0.5) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 25px rgba(255, 255, 255, 0.3));
  animation: logoGlow 2s ease-in-out infinite alternate;
}

@keyframes logoGlow {
  0% { filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.2)); }
  100% { filter: drop-shadow(0 0 35px rgba(96, 165, 250, 0.6)); }
}

.loader-subtitle {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 6px;
}

/* Yüklenme Çubuğu */
.progress-wrapper {
  width: 100%;
  transition: opacity 0.3s ease;
}

.progress-track {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #3b82f6, #60a5fa, #ffffff);
  border-radius: 4px;
  box-shadow: 0 0 12px #3b82f6;
  transition: width 0.1s linear;
}

.progress-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
  padding: 0 2px;
}

.pulse-dot {
  width: 6px;
  height: 6px;
  background: #3b82f6;
  border-radius: 50%;
  box-shadow: 0 0 8px #3b82f6;
  animation: pulse 1s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.3; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1.2); }
}

.loader-percent {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.65);
}


/* ==========================================================================
   2. ANA VİDEO SAHNESİ & MOBİL UYUM
   ========================================================================== */

.main-stage {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  background-color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bg-video-blur {
  position: absolute;
  inset: -10%;
  width: 120%;
  height: 120%;
  object-fit: cover;
  filter: blur(40px) brightness(0.28) saturate(1.2);
  transform: scale(1.05);
  pointer-events: none;
  z-index: 1;
}

.video-container {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.main-video {
  max-width: 100%;
  max-height: 100%;
  max-height: 100dvh;
  width: auto;
  height: auto;
  object-fit: contain;
  box-shadow: 0 0 80px rgba(0, 0, 0, 0.9);
}

@media (max-width: 768px) and (orientation: portrait) {
  .main-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  .bg-video-blur {
    display: none;
  }
}

/* ==========================================================================
   3. VİDEO ÜZERİNDEKİ ŞEFFAF & UÇUK "akvinbg" YAZISI
   ========================================================================== */

.watermark-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 5;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0 16px;
}

.watermark-text {
  font-family: var(--font-display);
  font-size: clamp(2.3rem, 11vw, 6.5rem);
  font-weight: 900;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--watermark-color);
  opacity: 0.5;
  mix-blend-mode: overlay;
  text-shadow: 
    0 0 15px rgba(255, 255, 255, 0.3),
    0 0 35px rgba(255, 255, 255, 0.15),
    0 4px 15px rgba(0, 0, 0, 0.45);
  animation: watermarkBreath 7s ease-in-out infinite alternate;
}

@keyframes watermarkBreath {
  0% {
    transform: scale(0.97);
    opacity: 0.42;
    letter-spacing: 0.26em;
  }
  100% {
    transform: scale(1.03);
    opacity: 0.62;
    letter-spacing: 0.30em;
  }
}

/* ==========================================================================
   4. HUD VE KONTROLLER
   ========================================================================== */

.top-hud {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 10;
  padding: max(20px, env(safe-area-inset-top)) 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  pointer-events: none;
}

.hud-brand {
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand-dot {
  width: 7px;
  height: 7px;
  background: #3b82f6;
  border-radius: 50%;
  box-shadow: 0 0 8px #3b82f6;
}

.brand-name {
  font-weight: 700;
  font-size: 0.92rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.8);
}

.hud-status {
  display: flex;
  align-items: center;
  gap: 8px;
}

.status-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.5);
}

.audio-waves {
  display: flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 12px;
}

.audio-waves span {
  width: 2.5px;
  height: 100%;
  background: #60a5fa;
  border-radius: 2px;
  animation: wave 1.2s ease-in-out infinite;
}

.audio-waves span:nth-child(1) { animation-delay: 0.1s; height: 35%; }
.audio-waves span:nth-child(2) { animation-delay: 0.3s; height: 75%; }
.audio-waves span:nth-child(3) { animation-delay: 0.15s; height: 95%; }
.audio-waves span:nth-child(4) { animation-delay: 0.4s; height: 50%; }

.audio-waves.paused span {
  animation: none;
  height: 20%;
  background: rgba(255, 255, 255, 0.25);
}

@keyframes wave {
  0%, 100% { height: 20%; }
  50% { height: 100%; }
}

/* Alt Kontrol Barı */
.bottom-hud {
  position: absolute;
  bottom: calc(16px + var(--safe-bottom));
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  justify-content: center;
  padding: 0 16px;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.bottom-hud.idle {
  opacity: 0;
  transform: translateY(14px);
  pointer-events: none;
}

.controls-glass {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  padding: 8px 16px;
  border-radius: 40px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  max-width: 580px;
  width: 100%;
}

.hud-btn {
  background: none;
  border: none;
  color: #ffffff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  min-height: 38px;
  border-radius: 50%;
  transition: transform 0.2s ease, color 0.2s ease;
}

.hud-btn:hover {
  color: #60a5fa;
  transform: scale(1.08);
}

.hud-btn:active {
  transform: scale(0.92);
}

.progress-container {
  flex: 1;
  height: 5px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 5px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  padding: 4px 0;
  background-clip: content-box;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #3b82f6, #60a5fa);
  border-radius: 5px;
  transition: width 0.1s linear;
}

.time-display {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: rgba(255, 255, 255, 0.7);
  white-space: nowrap;
}

.volume-group {
  display: flex;
  align-items: center;
  gap: 6px;
}

.volume-slider {
  width: 55px;
  height: 4px;
  -webkit-appearance: none;
  appearance: none;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 4px;
  outline: none;
  cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ffffff;
}

.click-feedback {
  position: absolute;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(8px);
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.5);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.click-feedback.active {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.15);
}

@media (max-width: 600px) {
  .watermark-text {
    letter-spacing: 0.2em;
  }
  .volume-slider {
    display: none;
  }
  .controls-glass {
    gap: 8px;
    padding: 6px 14px;
  }
  .top-hud {
    padding: max(16px, env(safe-area-inset-top)) 16px;
  }
}
