/* ===================================
   RESPONSIVE.CSS - Complete Mobile & Tablet Styles
   =================================== */

/* ===================================
   LOADING ANIMATION FIX
   =================================== */

#loader {
  z-index: 9999 !important; /* Higher than nav */
}

nav {
  z-index: 100; /* Lower than loader */
}

/* Hide nav during loading */
body:has(#loader:not([style*="top: -100%"])) nav {
  opacity: 0;
  pointer-events: none;
}

/* ===================================
   MOBILE STYLES (Up to 600px)
   =================================== */

@media (max-width: 600px) {
  /* Prevent horizontal overflow */
  body,
  html {
    overflow-x: hidden !important;
    width: 100vw;
    max-width: 100%;
  }

  #main {
    overflow-x: hidden !important;
    width: 100%;
  }

  /* Enhanced Logo Styling */
  #logo {
    font-size: 7vw !important;
    font-weight: 600;
    letter-spacing: 0.5px;
  }

  /* Enhanced Nav Styles */
  nav {
    padding: 5vw 5vw !important;
    background-color: rgba(0, 0, 0, 0.98) !important;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: sticky !important;
    top: 0;
    z-index: 100;
  }

  nav h3 {
    background: linear-gradient(135deg, #ffffff 0%, #cccccc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    border: 1.5px solid rgba(255, 255, 255, 0.2) !important;
    padding: 2.5vw 6vw !important;
    font-size: 3.5vw !important;
    font-weight: 400;
    letter-spacing: 1px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    z-index: 1001; /* Ensure menu button is always clickable */
  }

  nav h3::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
  }

  nav h3:active::before {
    width: 300px;
    height: 300px;
  }

  nav h3:active {
    transform: scale(0.95);
    border-color: rgba(255, 255, 255, 0.4);
  }

  /* Hero Section - Fixed Text Overflow */
  #center {
    height: auto !important;
    /* min-height: 75vh; */
    width: 100%;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 12vw 5vw 10vw 5vw !important;
    flex-direction: column-reverse;
    position: relative;
    z-index: 9;
    gap: 8vw;
  }

  #left {
    width: 100% !important;
    padding-right: 0 !important;
  }

  #left h3 {
    width: 100% !important;
    font-size: 4.2vw !important;
    line-height: 6vw !important;
    color: #cccccc;
    font-weight: 300;
    max-width: 90vw;
  }

  #right {
    width: 100% !important;
  }

  #center h1 {
    font-size: 14vw !important;
    text-align: left !important;
    line-height: 13vw !important;
    color: #ffffff;
    font-weight: 600;
    word-break: break-word;
    hyphens: auto;
    max-width: 100%;
  }

  /* Hero Button Container - Properly Centered */
  #hero-button-container {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0vw 5vw 12vw 5vw;
  }

  .nav-button {
    padding: 4vw 10vw !important;
    font-size: 4vw !important;
    width: auto;
    border: 1.5px solid rgba(255, 255, 255, 0.3) !important;
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  }

  .nav-button::after {
    background: linear-gradient(135deg, #ffffff 0%, #e0e0e0 100%) !important;
  }

  .nav-button:active {
    transform: scale(0.95);
  }

  /* Page 2 - Moving Text Fixed */
  #page2 {
    padding: 12vw 0 !important;
    overflow-x: hidden !important;
  }

  #moving-text {
    overflow: hidden !important;
    width: 100vw;
  }

  #moving-text h1 {
    font-size: 12vw !important;
    color: #ffffff;
    white-space: nowrap;
  }

  .con {
    animation-duration: 15s !important;
  }

  #gola {
    height: 30px !important;
    width: 30px !important;
    margin: 2vw 3vw !important;
  }

  /* Page 2 Bottom - More Breathable */
  #page2-bottom {
    height: auto !important;
    min-height: auto !important;
    width: 100%;
    padding: 10vw 5vw 0vw 5vw !important;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    position: relative;
    flex-direction: column;
    z-index: 9;
    gap: 8vw;
  }

  #page2-bottom h1 {
    font-size: 7.5vw !important;
    width: 100% !important;
    line-height: 9vw !important;
    color: #ffffff;
    padding-right: 0 !important;
    margin-bottom: 0;
    font-weight: 500;
  }

  #bottom-part2 {
    width: 100% !important;
  }

  #bottom-part2 img {
    width: 100%;
    border-radius: 15px;
    margin-bottom: 5vw;
  }

  #bottom-part2 p {
    font-weight: 300;
    font-size: 4vw !important;
    line-height: 6vw !important;
    color: #cccccc;
  }

  /* Page 3 Services - More Breathable */
  #page3 {
    padding: 12vw 0 0 0 !important;
  }

  #page3 > h2 {
    font-size: 9vw !important;
    margin-bottom: 12vw !important;
    padding: 0 5vw !important;
    line-height: 10vw !important;
  }

  #elem-container {
    padding: 0 !important;
  }

  .elem {
    min-height: auto !important;
    padding: 10vw 5vw !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 0;
  }

  .elem-content {
    width: 100%;
  }

  .elem-content h2 {
    font-size: 6vw !important;
    line-height: 7vw !important;
    margin-bottom: 4vw !important;
    font-weight: 500;
  }

  .elem-content p {
    font-size: 3.8vw !important;
    line-height: 6vw !important;
    width: 100% !important;
    margin-bottom: 4vw !important;
    color: #aaaaaa;
    font-weight: 300;
  }

  .service-link {
    font-size: 3.5vw !important;
    padding: 2vw 0;
    display: inline-block;
  }

  /* Page 4 Testimonials - Much More Breathable */
  #page4 {
    height: auto !important;
    padding: 15vw 0 12vw 0 !important;
  }

  .testimonials-header {
    margin-bottom: 10vw !important;
    padding: 0 5vw;
  }

  .testimonials-header h2 {
    font-size: 9vw !important;
    margin-bottom: 5vw !important;
    line-height: 10vw !important;
  }

  .testimonials-header p {
    font-size: 4vw !important;
    line-height: 6vw !important;
    padding: 0 2vw;
  }

  /* Swiper Container */
  .swiper {
    width: 100% !important;
    padding: 5vw 0 8vw 0 !important;
    overflow: visible !important;
  }

  .swiper-wrapper {
    padding-left: 5vw;
  }

  .swiper-slide {
    width: 85vw !important;
    height: auto !important;
    margin-right: 5vw !important;
  }

  .testimonial-card {
    background-color: rgba(10, 10, 10, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 8vw !important;
    height: 100%;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    backdrop-filter: blur(10px);
  }

  .quote-icon {
    margin-bottom: 5vw !important;
    opacity: 0.3;
  }

  .quote-icon svg {
    width: 50px !important;
    height: 50px !important;
  }

  .testimonial-card .quote {
    font-size: 4vw !important;
    line-height: 6.5vw !important;
    margin-bottom: 6vw !important;
    font-weight: 300;
  }

  .client-info {
    gap: 4vw !important;
    margin-bottom: 4vw !important;
  }

  .client-avatar {
    width: 14vw !important;
    height: 14vw !important;
    font-size: 5vw !important;
    flex-shrink: 0;
  }

  .client-name {
    font-size: 4.5vw !important;
    margin-bottom: 1.5vw !important;
  }

  .client-role {
    font-size: 3.5vw !important;
  }

  .rating {
    gap: 1.5vw !important;
    font-size: 5vw !important;
  }

  /* Testimonials Stats */
  .testimonials-stats {
    grid-template-columns: 1fr !important;
    gap: 5vw !important;
    margin-top: 12vw !important;
    padding: 0 5vw !important;
  }

  .testimonials-stats .stat {
    padding: 8vw 5vw !important;
    border-radius: 15px;
    background: rgba(10, 10, 10, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
  }

  .testimonials-stats .stat h3 {
    font-size: 12vw !important;
    margin-bottom: 2vw !important;
  }

  .testimonials-stats .stat p {
    font-size: 4vw !important;
  }

  /* Page 5 CTA */
  #page5 {
    padding: 5vw 5vw !important;
    min-height: fit-content !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  #page5 h2 {
    font-size: 8vw !important;
    margin-bottom: 4vw !important;
    line-height: 10vw !important;
  }

  #page5 h4 {
    font-size: 4vw !important;
    line-height: 6vw !important;
    padding: 0 3vw;
  }

  #page5 a {
    margin-top: 8vw !important;
    padding: 4vw 10vw !important;
    font-size: 4vw !important;
    border-radius: 50px;
    border: 1.5px solid rgba(255, 255, 255, 0.3) !important;
  }

  /* Enhanced Mobile Menu */
  #full-scr {
    background: linear-gradient(135deg, #000000 0%, #0a0a0a 100%);
    backdrop-filter: blur(20px);
    z-index: 1000 !important; /* Higher than nav */
  }

  #full-div1 {
    height: 100% !important;
    border-radius: 0 !important;
    background: transparent !important;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .mobile-menu-content {
    text-align: center;
    padding: 10vw;
    width: 100%;
  }

  .mobile-menu-content h4 {
    margin: 8vw 0;
    font-size: 8vw !important;
    color: #ffffff;
    font-weight: 400;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
  }

  .mobile-menu-content h4::after {
    content: "";
    position: absolute;
    bottom: -2vw;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 60%;
    height: 1px;
    background: linear-gradient(
      90deg,
      transparent,
      rgba(255, 255, 255, 0.3),
      transparent
    );
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  }

  #full-scr.active .mobile-menu-content h4 {
    opacity: 1;
    transform: translateY(0);
  }

  #full-scr.active .mobile-menu-content h4::after {
    transform: translateX(-50%) scaleX(1);
  }

  #full-scr.active .mobile-menu-content h4:nth-child(1) {
    transition-delay: 0.15s;
  }

  #full-scr.active .mobile-menu-content h4:nth-child(2) {
    transition-delay: 0.25s;
  }

  #full-scr.active .mobile-menu-content h4:nth-child(3) {
    transition-delay: 0.35s;
  }

  .mobile-menu-content h4 a {
    color: #ffffff;
    text-decoration: none;
    display: block;
    padding: 3vw;
    transition: all 0.3s ease;
    position: relative;
  }

  .mobile-menu-content h4 a:active {
    transform: scale(0.95);
    color: #cccccc;
  }

  /* Footer Mobile */
  #footer {
    padding: 12vw 5vw 8vw 5vw !important;
  }

  #footer-top {
    flex-direction: column;
    gap: 8vw !important;
    padding-bottom: 8vw !important;
  }

  #footer-links {
    flex-direction: column;
    gap: 5vw !important;
    align-items: center;
  }

  #footer-links a {
    font-size: 4.5vw !important;
  }

  #footer-social {
    gap: 6vw !important;
  }

  #footer-social svg {
    width: 28px !important;
    height: 28px !important;
  }

  #footer-bottom {
    padding-top: 8vw !important;
  }

  #footer-bottom p {
    font-size: 3.2vw !important;
    line-height: 5vw;
  }

  /* ===================================
     INSIGHTS PAGE MOBILE STYLES
     =================================== */

  #insights-hero {
    padding: 15vw 5vw 12vw 5vw !important;
  }

  #hero-content h1 {
    font-size: 12vw !important;
    line-height: 13vw !important;
    margin-bottom: 6vw !important;
  }

  #hero-content p {
    font-size: 4vw !important;
    line-height: 6vw !important;
  }

  .insight-section {
    padding: 12vw 5vw !important;
  }

  .section-header {
    margin-bottom: 8vw !important;
  }

  .section-number {
    font-size: 10vw !important;
    margin-bottom: 3vw !important;
  }

  .section-header h2 {
    font-size: 8vw !important;
    line-height: 9vw !important;
  }

  .section-content {
    flex-direction: column !important;
    gap: 8vw !important;
  }

  .content-main,
  .content-sidebar {
    width: 100% !important;
  }

  .content-main h3 {
    font-size: 6vw !important;
    line-height: 7vw !important;
    margin-bottom: 4vw !important;
  }

  .content-main p {
    font-size: 4vw !important;
    line-height: 6vw !important;
    margin-bottom: 4vw !important;
  }

  .tech-stack {
    padding: 6vw !important;
  }

  .tech-stack h4 {
    font-size: 5vw !important;
    margin-bottom: 4vw !important;
  }

  .tech-stack ul li {
    font-size: 3.8vw !important;
    padding: 3vw 0 !important;
  }

  .section-details {
    grid-template-columns: 1fr !important;
    gap: 6vw !important;
    margin-top: 8vw !important;
  }

  .detail-block {
    padding: 6vw !important;
  }

  .detail-block h4 {
    font-size: 5vw !important;
    margin-bottom: 3vw !important;
  }

  .detail-block p {
    font-size: 3.8vw !important;
    line-height: 5.5vw !important;
  }

  .process-grid {
    grid-template-columns: 1fr !important;
    gap: 8vw !important;
  }

  .process-card {
    padding: 8vw !important;
  }

  .process-number {
    font-size: 12vw !important;
    margin-bottom: 4vw !important;
  }

  .process-card h3 {
    font-size: 6vw !important;
    margin-bottom: 4vw !important;
  }

  .process-card p {
    font-size: 3.8vw !important;
    line-height: 6vw !important;
  }

  .tech-categories {
    grid-template-columns: 1fr !important;
    gap: 8vw !important;
  }

  .tech-category h3 {
    font-size: 6vw !important;
    margin-bottom: 4vw !important;
  }

  .tech-items span {
    font-size: 3.5vw !important;
    padding: 2.5vw 4vw !important;
  }

  #insights-cta {
    padding: 15vw 5vw !important;
  }

  #insights-cta h2 {
    font-size: 8vw !important;
    line-height: 9vw !important;
    margin-bottom: 4vw !important;
  }

  #insights-cta p {
    font-size: 4vw !important;
    line-height: 6vw !important;
    margin-bottom: 8vw !important;
  }

  .cta-button {
    padding: 4vw 10vw !important;
    font-size: 4vw !important;
  }

  /* ===================================
     CONTACT PAGE MOBILE STYLES
     =================================== */

  #secondary-hero {
    padding: 12vw 5vw 8vw 5vw !important;
  }

  .secondary-heading {
    font-size: 12vw !important;
    line-height: 13vw !important;
    margin-bottom: 6vw !important;
  }

  .secondary-subheading {
    font-size: 4vw !important;
    line-height: 6vw !important;
  }

  #contact-grid-section {
    padding: 12vw 5vw !important;
  }

  .contact-info-cards {
    grid-template-columns: 1fr !important;
    gap: 6vw !important;
  }

  .info-card {
    padding: 8vw !important;
  }

  .card-icon {
    margin-bottom: 4vw !important;
  }

  .card-icon svg {
    width: 40px !important;
    height: 40px !important;
  }

  .info-card h3 {
    font-size: 5.5vw !important;
    margin-bottom: 3vw !important;
  }

  .info-card a,
  .info-card p {
    font-size: 4vw !important;
    line-height: 6vw !important;
  }

  #contact-form-section {
    padding: 12vw 5vw !important;
  }

  .form-header h2 {
    font-size: 8vw !important;
    margin-bottom: 4vw !important;
  }

  .form-header p {
    font-size: 4vw !important;
    line-height: 6vw !important;
    margin-bottom: 8vw !important;
  }

  .form-row {
    flex-direction: column !important;
    gap: 6vw !important;
  }

  .form-group {
    width: 100% !important;
    margin-bottom: 6vw !important;
  }

  .form-group label {
    font-size: 4vw !important;
    margin-bottom: 2vw !important;
  }

  .form-group input,
  .form-group select,
  .form-group textarea {
    font-size: 4vw !important;
    padding: 4vw !important;
  }

  .submit-button {
    padding: 4vw 10vw !important;
    font-size: 4vw !important;
  }

  .form-note {
    font-size: 3.5vw !important;
    margin-top: 4vw !important;
  }

  #contact-faq {
    padding: 12vw 5vw !important;
  }

  #contact-faq h2 {
    font-size: 8vw !important;
    margin-bottom: 8vw !important;
  }

  .faq-grid {
    grid-template-columns: 1fr !important;
    gap: 6vw !important;
  }

  .faq-item {
    padding: 6vw !important;
  }

  .faq-item h3 {
    font-size: 5vw !important;
    margin-bottom: 3vw !important;
  }

  .faq-item p {
    font-size: 3.8vw !important;
    line-height: 6vw !important;
  }

  #contact-cta {
    padding: 12vw 5vw !important;
  }

  #contact-cta h2 {
    font-size: 8vw !important;
    margin-bottom: 4vw !important;
  }

  #contact-cta p {
    font-size: 4vw !important;
    line-height: 6vw !important;
    margin-bottom: 8vw !important;
  }

  .cta-button-secondary {
    padding: 4vw 10vw !important;
    font-size: 4vw !important;
  }
}

/* ===================================
   EXTRA SMALL MOBILE (Up to 375px)
   =================================== */

@media (max-width: 375px) {
  #center h1 {
    font-size: 13vw !important;
    line-height: 12vw !important;
  }

  #left h3 {
    font-size: 4.5vw !important;
    line-height: 6.5vw !important;
  }

  .testimonial-card {
    min-height: 420px;
    padding: 9vw !important;
  }
}

/* ===================================
   TABLET STYLES (601px to 1024px)
   =================================== */

@media (min-width: 601px) and (max-width: 1024px) {
  #logo {
    font-size: 3.5vw;
  }

  #nav-part2 h4 {
    font-size: 1.6vw;
    padding: 1.2vw 2.2vw;
  }

  #left h3 {
    width: 40vw;
    font-size: 2vw;
    line-height: 2.4vw;
  }

  #center h1 {
    font-size: 10vw;
    line-height: 8.5vw;
  }

  #page2-bottom h1 {
    font-size: 4.2vw;
    line-height: 4.8vw;
    width: 60%;
  }

  #bottom-part2 {
    width: 35%;
  }

  #bottom-part2 p {
    font-size: 1.3vw;
    line-height: 1.9vw;
  }

  .elem-content h2 {
    font-size: 3.2vw;
  }

  .elem-content p {
    font-size: 1.4vw;
  }

  .testimonials-stats {
    gap: 4vw;
  }

  /* Insights page tablet */
  .section-content {
    gap: 4vw;
  }

  .content-main h3 {
    font-size: 3vw;
  }

  .section-details {
    grid-template-columns: repeat(2, 1fr);
  }

  .process-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .tech-categories {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Contact page tablet */
  .contact-info-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .faq-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ===================================
   LANDSCAPE MOBILE
   =================================== */

@media (max-height: 600px) and (orientation: landscape) and (max-width: 900px) {
  #center {
    min-height: 80vh;
    padding: 8vw 5vw !important;
  }

  nav {
    padding: 3vw 5vw !important;
  }

  .mobile-menu-content h4 {
    margin: 4vw 0 !important;
    font-size: 6vw !important;
  }
}

/* Hide/Show Elements */
@media (min-width: 601px) {
  nav h3 {
    display: none !important;
  }

  #full-scr {
    display: none !important;
  }
}

@media (max-width: 600px) {
  #nav-part2 {
    display: none !important;
  }

  nav h3 {
    display: block !important;
  }
}
