/* general styles */
html {
  scroll-behavior: smooth;
}
#contact-form, [id] {
  scroll-margin-top: 5rem;
}
.contrast-text {
  color: var(--color-contrast, #ffd700); /* Gold color for contrast */
  text-shadow: 0 0 5px rgba(0, 0, 0, 0.3); /* Added shadow for better visibility */
}

/* home page  */
.highlight-text {
  background: linear-gradient(90deg, var(--color-primary, #e53e3e), var(--color-secondary, #9f1239));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  display: inline-block;
}
.floating {
  animation: floating 3s ease-in-out infinite;
}
@keyframes floating {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
  100% {
    transform: translateY(0px);
  }
}
.glow {
  animation: glow 2s ease-in-out infinite alternate;
}
@keyframes glow {
  from {
    box-shadow: 0 0 5px rgba(var(--color-primary-rgb, 229, 62, 62), 0.5);
  }
  to {
    box-shadow: 0 0 20px rgba(var(--color-primary-rgb, 229, 62, 62), 0.8);
  }
}
.scroll-container {
  scroll-behavior: smooth;
}
.scroll-container::-webkit-scrollbar {
  display: none;
}
/* Improved dropdown hover behavior */
.dropdown-container {
  position: relative;
}
.dropdown-menu {
  position: absolute;
  left: 0;
  top: 100%;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 50;
}
.dropdown-container:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
}
.dropdown-menu:hover {
  opacity: 1;
  visibility: visible;
}
.africa-icon {
  width: 24px;
  height: 24px;
  display: inline-block;
  margin-right: 8px;
  vertical-align: middle;
}

/* homepage end */

/* Subpage Hero Section - Guaranteed uniform height & centering across all subpages */
.hero-subpage {
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 2.5rem;
  padding-bottom: 2.5rem;
  position: relative;
  overflow: hidden;
}

@media (min-width: 768px) {
  .hero-subpage {
    min-height: 320px;
    padding-top: 3.5rem;
    padding-bottom: 3.5rem;
  }
}

/* ==========================================================================
   Interactive Product Cards & iMac Computer Animations
   ========================================================================== */
.interactive-product-card {
  position: relative;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
              box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
              border-color 0.3s ease;
  overflow: hidden;
  will-change: transform, box-shadow;
}

.interactive-product-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--color-primary, #e53e3e), var(--color-secondary, #9f1239));
  opacity: 0;
  transform: scaleX(0);
  transform-origin: center;
  transition: opacity 0.35s ease, transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 10;
}

.interactive-product-card:hover {
  transform: translateY(-8px);
  border-color: rgba(var(--color-primary-rgb, 229, 62, 62), 0.35);
  box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.09), 0 10px 20px -8px rgba(var(--color-primary-rgb, 229, 62, 62), 0.16);
}

.interactive-product-card:hover::before {
  opacity: 1;
  transform: scaleX(1);
}

/* iMac Screen Glass Glare Sweep on Hover */
.imac-screen-glass {
  position: relative;
  overflow: hidden;
}

.imac-screen-glass::after {
  content: '';
  position: absolute;
  top: -60%;
  left: -80%;
  width: 50%;
  height: 220%;
  background: linear-gradient(
    to right, 
    rgba(255, 255, 255, 0) 0%, 
    rgba(255, 255, 255, 0.16) 50%, 
    rgba(255, 255, 255, 0) 100%
  );
  transform: rotate(25deg);
  transition: left 0.75s ease-in-out;
  pointer-events: none;
  z-index: 4;
}

.interactive-product-card:hover .imac-screen-glass::after {
  left: 150%;
}

/* iMac Device Floating Lift */
.imac-device-lift {
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.interactive-product-card:hover .imac-device-lift {
  transform: translateY(-4px) scale(1.015);
}

/* Hover Quick Preview Pill Overlay on Screen */
.imac-hover-pill {
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
  z-index: 5;
}

.interactive-product-card:hover .imac-hover-pill {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   Navigation & Core Responsive Breakpoints
   Ensures desktop navbar and layout remain solid and immune to runtime
   DOM mutations or third-party script interference (e.g. Meta Pixel / Event Setup Tool).
   ========================================================================== */

/* Desktop viewports (1024px and wider) */
@media screen and (min-width: 1024px) {
  .desktop-nav-menu,
  .hidden.lg\:flex,
  div[class*="lg:flex"] {
    display: flex !important;
  }
  .mobile-menu-btn,
  .inline-flex.lg\:hidden,
  button.lg\:hidden,
  button[class*="lg:hidden"] {
    display: none !important;
  }
  #mobile-menu,
  div.lg\:hidden,
  div[class*="lg:hidden"] {
    display: none !important;
  }
}

/* Extra-large viewports (1280px and wider) */
@media screen and (min-width: 1280px) {
  .desktop-action-btn,
  .hidden.xl\:inline-flex,
  a[class*="xl:inline-flex"] {
    display: inline-flex !important;
  }
}

/* Mobile & Tablet viewports (under 1024px) */
@media screen and (max-width: 1023.98px) {
  .desktop-nav-menu,
  .hidden.lg\:flex {
    display: none !important;
  }
  .mobile-menu-btn,
  .inline-flex.lg\:hidden {
    display: inline-flex !important;
  }
  .desktop-action-btn,
  .hidden.xl\:inline-flex {
    display: none !important;
  }
}

/* Responsive Grid & Flex fallbacks */
@media screen and (min-width: 640px) {
  .flex-col.sm\:flex-row {
    flex-direction: row !important;
  }
}

@media screen and (min-width: 768px) {
  .md\:text-6xl {
    font-size: 3.75rem !important;
    line-height: 1 !important;
  }
  .md\:text-2xl {
    font-size: 1.5rem !important;
    line-height: 2rem !important;
  }
  .md\:py-32 {
    padding-top: 8rem !important;
    padding-bottom: 8rem !important;
  }
  .md\:flex-row {
    flex-direction: row !important;
  }
}


