/* Custom styles for Alfa PWA */
html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  max-width: 100%;
}

body {
  padding-top: 80px;
}

/* Utility classes not in main CSS */
.mr-1 {
  margin-right: 1rem !important;
}

/* Prevent horizontal overflow */
* {
  box-sizing: border-box;
}

.container, section {
  max-width: 100%;
}

img, svg {
  max-width: 100%;
  height: auto;
}

/* Desktop animation */
.app {
  transform: scale(0.6);
  position: relative;
  z-index: 1;
}

.content {
  overflow: visible !important;
  position: relative;
  z-index: 1;
}

/* Ensure header stays on top */
header {
  position: fixed !important;
  z-index: 999999 !important;
  pointer-events: auto !important;
}

header * {
  pointer-events: auto !important;
}

/* Push header buttons to the right */
header .buttons {
  margin-left: auto;
  padding-left: 20px;
}

/* Mobile phone animation adjustments */
.app .mobile {
  background-image: url(mobile-xicc-zxX.png);
  width: 90%;
  margin-top: -25px;
  margin-left: 50px;
  height: 100%;
  background-size: 100% 100%;
}

/* Mobile animation fix for responsive */
@media (max-width: 768px) {
  .app {
    transform: scale(1.1) !important;
    margin: 10px 0 !important;
  }

  .content {
    padding: 80px 20px 50px !important;
    overflow: visible !important;
  }

  .content .container {
    overflow: visible !important;
  }
}

/* iOS Install Banner */
#iosInstallBanner {
  position: fixed;
  bottom: 20px;
  left: 20px;
  right: 20px;
  background: #f7941f;
  color: white;
  padding: 20px;
  display: none;
  flex-direction: column;
  align-items: center;
  text-align: center;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
  z-index: 99999;
  max-width: 300px;
  margin: 0 auto;
}

#iosInstallBanner.show {
  display: flex;
}

#iosInstallBanner .banner-title {
  margin: 0 0 15px 0;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
}

#iosInstallBanner .banner-subtitle {
  margin: 15px 0 10px 0;
  font-size: 13px;
  line-height: 1.4;
  opacity: 0.95;
}

#iosInstallBanner .share-icon {
  margin: 10px 0;
}

#iosInstallBanner .arrow-icon {
  margin-top: 5px;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-10px);
  }
  60% {
    transform: translateY(-5px);
  }
}

/* Installation Guide Images - Single Row Layout */
.content_4 .row {
  display: flex;
  flex-wrap: nowrap;
  gap: 20px;
  padding: 20px;
  justify-content: flex-start;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.content_4 .row::-webkit-scrollbar {
  display: none;
}

.content_4 .col {
  width: 280px;
  min-width: 280px;
}

.content_4 img {
  width: 100%;
  height: auto;
  display: block;
  cursor: pointer;
  transition: transform 0.2s;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.content_4 img:hover {
  transform: scale(1.05);
}

@media (max-width: 768px) {
  .content_4 .row {
    flex-wrap: wrap;
    gap: 10px;
    padding: 15px;
  }

  .content_4 .col {
    width: 48%;
  }
}

/* Lightbox Modal - Swipeable Gallery */
.lightbox {
  display: none;
  position: fixed;
  z-index: 999999;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.95);
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.lightbox.show {
  display: flex;
}

.lightbox-gallery {
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  width: 100%;
  height: 100%;
  align-items: center;
  gap: 20px;
  padding: 0 10px;
  scrollbar-width: none;
}

.lightbox-gallery::-webkit-scrollbar {
  display: none;
}

.lightbox-gallery .lightbox-slide {
  flex: 0 0 100%;
  scroll-snap-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.lightbox-gallery img {
  max-width: 95%;
  max-height: 90%;
  object-fit: contain;
  user-select: none;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: white;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  z-index: 1000000;
  background: rgba(0,0,0,0.5);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.lightbox-close:hover {
  background: rgba(0,0,0,0.8);
}

.lightbox-counter {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  color: white;
  font-size: 16px;
  background: rgba(0,0,0,0.5);
  padding: 8px 16px;
  border-radius: 20px;
  z-index: 1000000;
}

.lightbox-arrow {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  color: white;
  font-size: 50px;
  font-weight: bold;
  cursor: pointer;
  z-index: 10000000;
  background: rgba(0,0,0,0.7);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  transition: background 0.3s;
  pointer-events: auto;
}

.lightbox-arrow:hover {
  background: rgba(0,0,0,0.8);
}

.lightbox-arrow.left {
  left: 20px;
}

.lightbox-arrow.right {
  right: 20px;
}

@media (max-width: 768px) {
  .lightbox-arrow {
    width: 50px;
    height: 50px;
    font-size: 40px;
  }

  .lightbox-arrow.left {
    left: 10px;
  }

  .lightbox-arrow.right {
    right: 10px;
  }
}
