/* ============================================
   VISUAL STORY FULLSCREEN SYSTEM
   Optimized for zero-scroll, maximum engagement
   ============================================ */

/* Hide navigation on fullscreen story pages */
body:has(.visual-story-fullscreen) nav,
body:has(.visual-story-fullscreen) footer {
  display: none !important;
}

.visual-story-fullscreen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  background: #000;
  z-index: 10000;
  overflow: hidden;
  font-family: 'Bricolage Grotesque', sans-serif;
  padding-top: 0;
}

/* Navigation & Progress Top Bar */
.story-nav-top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0.75rem 1rem;
  background: linear-gradient(180deg, rgba(0,0,0,0.6) 0%, transparent 100%);
}

.story-progress-bars {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 0.75rem;
}

.progress-segment {
  flex: 1;
  height: 3px;
  background: rgba(255,255,255,0.3);
  border-radius: 2px;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: background 0.2s;
}

.progress-segment:hover {
  background: rgba(255,255,255,0.5);
}

.progress-segment.completed {
  background: #fff;
}

.progress-segment.active {
  background: rgba(255,255,255,0.5);
}

.progress-segment.active::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: var(--progress, 0%);
  background: #fff;
  transition: width 0.05s linear;
}

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

.story-close-btn,
.story-share-btn {
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  cursor: pointer;
  transition: all 0.2s;
}

.story-close-btn:hover,
.story-share-btn:hover {
  background: rgba(255,255,255,0.25);
  transform: scale(1.05);
}

.story-close-btn:active,
.story-share-btn:active {
  transform: scale(0.95);
}

/* Story Slides */
.story-slides-wrapper {
  width: 100%;
  height: 100%;
  position: relative;
}

.story-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s;
}

.story-slide.active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
}

.story-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.story-content-center {
  position: relative;
  z-index: 10;
  max-width: 90%;
  text-align: center;
  color: #fff;
  padding: 2rem 1rem;
}

/* Story Typography */
.story-logo-badge {
  width: 60px;
  height: 60px;
  background: rgba(255,255,255,0.2);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  font-weight: 900;
  font-size: 1.5rem;
  color: #fff;
  animation: fadeInScale 0.6s ease;
}

.story-logo-badge-lg {
  width: 80px;
  height: 80px;
  background: rgba(255,255,255,0.2);
  backdrop-filter: blur(10px);
  border: 3px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  font-weight: 900;
  font-size: 2rem;
  color: #fff;
  animation: fadeInScale 0.6s ease;
}

.story-title-xl {
  font-size: 2.5rem;
  font-weight: 900;
  line-height: 1.1;
  margin: 0 0 0.5rem;
  animation: fadeInUp 0.6s ease 0.1s both;
  text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.story-title-lg {
  font-size: 2rem;
  font-weight: 900;
  line-height: 1.2;
  margin: 0 0 1rem;
  animation: fadeInUp 0.6s ease 0.1s both;
  text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.story-subtitle-lg {
  font-size: 1.25rem;
  font-weight: 400;
  margin: 0 0 2rem;
  opacity: 0.95;
  animation: fadeInUp 0.6s ease 0.2s both;
}

.story-text-md {
  font-size: 1.1rem;
  line-height: 1.5;
  margin: 0 0 1.5rem;
  opacity: 0.9;
  animation: fadeInUp 0.6s ease 0.2s both;
}

/* Story Elements */
.story-icon-xl {
  font-size: 5rem;
  margin: 0 0 1rem;
  animation: fadeInScale 0.6s ease;
  filter: drop-shadow(0 4px 20px rgba(0,0,0,0.3));
}

.story-swipe-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  opacity: 0.7;
  animation: pulse 2s ease-in-out infinite;
}

.story-swipe-hint svg {
  animation: slideRight 1.5s ease-in-out infinite;
}

/* Compact Lists */
.story-list-compact {
  text-align: left;
  max-width: 320px;
  margin: 0 auto 1.5rem;
  animation: fadeInUp 0.6s ease 0.3s both;
}

.list-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.75rem;
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
  border-radius: 12px;
  margin-bottom: 0.5rem;
  border: 1px solid rgba(255,255,255,0.15);
}

.list-item:last-child {
  margin-bottom: 0;
}

.item-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.list-item strong {
  font-weight: 700;
  color: #fff;
}

/* Stat Box */
.story-stat-box {
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(255,255,255,0.2);
  border-radius: 16px;
  padding: 1rem 1.5rem;
  margin: 1.5rem auto 0;
  max-width: 200px;
  animation: fadeInUp 0.6s ease 0.4s both;
}

.stat-value {
  font-size: 2rem;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 0.25rem;
}

.stat-label {
  font-size: 0.85rem;
  opacity: 0.8;
  font-weight: 400;
}

/* Grid Layout */
.story-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin: 1.5rem auto 0;
  max-width: 340px;
  animation: fadeInUp 0.6s ease 0.3s both;
}

.info-card {
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 12px;
  padding: 1rem;
  text-align: center;
  transition: transform 0.2s;
}

.info-card:active {
  transform: scale(0.95);
}

.card-icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  filter: drop-shadow(0 2px 10px rgba(0,0,0,0.2));
}

.card-text {
  font-size: 0.9rem;
  line-height: 1.3;
  font-weight: 600;
}

/* Checklist */
.story-checklist {
  text-align: left;
  max-width: 300px;
  margin: 0 auto 1.5rem;
  animation: fadeInUp 0.6s ease 0.3s both;
}

.check-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  margin-bottom: 0.5rem;
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.15);
  font-size: 0.95rem;
  font-weight: 600;
}

.check-item:last-child {
  margin-bottom: 0;
}

.check-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
}

.check-item.danger .check-icon {
  color: #ff4444;
}

/* Price Range */
.story-price-range {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  font-size: 1.5rem;
  font-weight: 900;
  margin-top: 1.5rem;
  animation: fadeInUp 0.6s ease 0.4s both;
}

.price-separator {
  opacity: 0.5;
  font-weight: 400;
}

/* CTA Buttons */
.story-cta-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin: 2rem auto 1.5rem;
  max-width: 280px;
  animation: fadeInUp 0.6s ease 0.3s both;
}

.btn-story-primary {
  background: rgba(255,255,255,0.95);
  color: #1B2B4B;
  padding: 1rem 1.5rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.2s;
  border: 2px solid transparent;
}

.btn-story-primary:hover {
  background: #fff;
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.btn-story-primary:active {
  transform: translateY(0);
}

.btn-story-secondary {
  background: transparent;
  color: #fff;
  padding: 0.875rem 1.5rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 2px solid rgba(255,255,255,0.4);
  transition: all 0.2s;
}

.btn-story-secondary:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.6);
}

.btn-story-secondary:active {
  transform: scale(0.97);
}

.story-footer-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  opacity: 0.7;
  animation: fadeIn 0.6s ease 0.5s both;
}

/* Touch Areas for Navigation */
.story-tap-areas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  z-index: 50;
  pointer-events: none;
}

.tap-area {
  flex: 1;
  pointer-events: all;
  cursor: pointer;
}

.tap-left {
  cursor: w-resize;
}

.tap-right {
  cursor: e-resize;
}

/* Animations */
@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

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

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes pulse {
  0%, 100% {
    opacity: 0.7;
  }
  50% {
    opacity: 1;
  }
}

@keyframes slideRight {
  0%, 100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(5px);
  }
}

/* Tablet Optimization */
@media (min-width: 768px) {
  .story-content-center {
    max-width: 600px;
    padding: 3rem 2rem;
  }
  
  .story-title-xl {
    font-size: 3.5rem;
  }
  
  .story-title-lg {
    font-size: 2.5rem;
  }
  
  .story-subtitle-lg {
    font-size: 1.5rem;
  }
  
  .story-icon-xl {
    font-size: 6rem;
  }
  
  .story-list-compact,
  .story-checklist {
    max-width: 400px;
  }
  
  .story-grid-2 {
    max-width: 440px;
    gap: 1rem;
  }
  
  .story-cta-buttons {
    flex-direction: row;
    max-width: 500px;
  }
}

/* Desktop - Max Width Container */
@media (min-width: 1024px) {
  .visual-story-fullscreen {
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .story-slides-wrapper,
  .story-nav-top,
  .story-tap-areas {
    max-width: 480px;
    margin: 0 auto;
  }
  
  .story-content-center {
    max-width: 90%;
  }
}
