/* Custom styles to complement Tailwind */

/* Prevent Swiper from breaking regular buttons */
button.btn,
a.btn {
  /* Reset any swiper interference */
  position: relative !important;
  width: auto !important;
  height: auto !important;
  margin: 0 !important;
  padding: 1rem 2rem !important;
  border: none !important;
  cursor: pointer !important;
  display: inline-block !important;
}

/* Swiper Custom Styling */
.swiper {
  width: 100%;
  padding-bottom: 50px;
  padding-left: 0;
  padding-right: 0;
}

.swiper-pagination {
  bottom: 0 !important;
  padding-top: 20px;
}

.swiper-pagination-bullet {
  background: #cbd5e1;
  opacity: 1;
  width: 10px;
  height: 10px;
  transition: all 0.3s ease;
}

.swiper-pagination-bullet-active {
  background: #1e3a8a;
  width: 24px;
  border-radius: 5px;
}

.swiper-slide {
  height: auto;
  display: flex;
  align-items: stretch;
}

/* Video Swiper Specific */
.video-swiper .swiper-slide {
  display: flex;
  justify-content: center;
  align-items: center;
  box-sizing: border-box;
}

.video-swiper video {
  width: 100%;
  max-width: 400px;
  height: auto;
  object-fit: contain;
  pointer-events: none;
}

/* Mobile: 2 video cards per row — fit without cramped overflow */
@media (max-width: 767px) {
  .video-swiper .swiper-slide {
    overflow: hidden;
  }
  .video-swiper video {
    max-width: 100%;
    min-width: 0;
  }
  #video-testimonials .container {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }
}

/* Work Swiper Specific */
.work-swiper .swiper-slide {
  height: auto;
  box-sizing: border-box;
}

.work-swiper .work-item {
  height: 100%;
  min-height: 16rem;
}

/* Our Recent Work — overlay text size (as per design) */
#our-work .work-overlay span {
  font-size: 0.9rem;
  line-height: 1rem;
}

/* Testimonials Swiper Specific */
.testimonials-swiper .swiper-slide {
  height: auto !important;
  display: flex !important;
  align-items: stretch !important;
  box-sizing: border-box;
}

.testimonials-swiper .testimonial {
  display: flex !important;
  flex-direction: column !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 280px;
}

.testimonials-swiper .testimonial .testimonial-text {
  flex-grow: 1;
}

/* Ensure equal heights for multi-column layout */
@media (min-width: 768px) {
  .testimonials-swiper .swiper-wrapper {
    align-items: stretch !important;
  }
  
  .testimonials-swiper .swiper-slide {
    min-height: 320px;
  }
}

/* Mobile: 2 cards per row — Recent Work & Reviews, fit without cramped overflow */
@media (max-width: 767px) {
  .work-swiper .swiper-slide {
    overflow: hidden;
  }
  .work-swiper .work-item {
    min-height: 14rem;
  }
  #our-work .container,
  #testimonials .container {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }
  .testimonials-swiper .swiper-slide {
    overflow: hidden;
  }
  .testimonials-swiper .testimonial {
    min-height: 260px;
  }
}

/* Responsive adjustments */
@media (max-width: 640px) {
  .swiper {
    padding-bottom: 40px;
  }
  
  .video-swiper video {
    max-width: 100%;
  }
  
  .work-swiper .work-item {
    min-height: 14rem;
  }
}

/* Ensure hidden class works */
.hidden {
  display: none !important;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Body base styles */
body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
}

/* Video background positioning */
.bg-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Slider dots styling */
.slider-dot {
  width: 10px;
  height: 10px;
  background: #cbd5e1;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease;
}

.slider-dot.active {
  background: #1e3a8a;
  width: 24px;
  border-radius: 5px;
}

.slider-dot:hover {
  background: #64748b;
}

/* Carousel scrollbar hide */
.carousel::-webkit-scrollbar,
.video-carousel::-webkit-scrollbar,
.testimonials-container::-webkit-scrollbar {
  display: none;
}

.carousel,
.video-carousel,
.testimonials-container {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Lightbox */
.lightbox {
  display: none;
}

.lightbox.active {
  display: flex !important;
}

/* Animate phone number on header */
@keyframes pulse-glow {
  0%, 100% {
    text-shadow: 0 0 5px rgba(255, 204, 0, 0.5);
  }
  50% {
    text-shadow: 0 0 20px rgba(255, 204, 0, 0.8);
  }
}

.animated-phone a {
  animation: pulse-glow 2s ease-in-out infinite;
}

/* Phone icon ring animation */
@keyframes phone-ring {
  0%, 100% { transform: rotate(0deg); }
  10% { transform: rotate(-15deg); }
  20% { transform: rotate(15deg); }
  30% { transform: rotate(-15deg); }
  40% { transform: rotate(15deg); }
  50% { transform: rotate(0deg); }
}

.animate-phone-ring {
  animation: phone-ring 3s ease-in-out infinite;
}

/* Focus states for accessibility */
a:focus,
button:focus,
input:focus,
select:focus,
textarea:focus {
  outline: 2px solid #e65c00;
  outline-offset: 2px;
}

/* Print styles */
@media print {
  .floating-phone,
  .form-overlay,
  video {
    display: none !important;
  }
}
