/* ==========================================================================
   📱 2026 ULTRA-RESPONSIVE MOBILE DESIGN SYSTEM (V4 PIXEL-PERFECT)
   ========================================================================== */

/* --------------------------------------------------------------------------
   0. UNIVERSAL BASE STYLES & OVERFLOW SAFETY
   -------------------------------------------------------------------------- */
html,
body {
  overflow-x: hidden !important;
  width: 100% !important;
  max-width: 100vw !important;
  -webkit-text-size-adjust: 100%;
}

*,
*::before,
*::after {
  box-sizing: border-box !important;
}

@media (max-width: 768px) {
  .container {
    padding-left: 14px !important;
    padding-right: 14px !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  section {
    padding: 38px 0 !important;
  }

  .section-header {
    margin-bottom: 24px !important;
    text-align: center !important;
  }

  .section-header h2 {
    font-size: 1.55rem !important;
    line-height: 1.25 !important;
    margin-bottom: 8px !important;
  }

  .section-header p {
    font-size: 0.85rem !important;
    line-height: 1.5 !important;
  }

  .subtitle {
    font-size: 0.75rem !important;
    letter-spacing: 0.5px !important;
    margin-bottom: 6px !important;
  }
}

/* --------------------------------------------------------------------------
   1. HEADER NAVIGATION & HAMBURGER MENU (HIGH CONTRAST & VISIBLE)
   -------------------------------------------------------------------------- */
@media (max-width: 991px) {
  .top-bar {
    padding: 6px 0 !important;
    font-size: 0.76rem !important;
  }

  .top-bar .container {
    flex-direction: column !important;
    gap: 4px !important;
    text-align: center !important;
  }

  .top-bar-left {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 6px 12px !important;
  }

  .top-bar-right {
    display: none !important;
  }

  .nav-main {
    padding: 8px 0 !important;
    background: #ffffff !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06) !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 1000 !important;
  }

  .nav-main .container {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
  }

  .logo {
    display: flex !important;
    align-items: center !important;
    gap: 7px !important;
    text-decoration: none !important;
  }

  .logo img,
  #headerLogo {
    height: 38px !important;
    max-height: 38px !important;
    width: auto !important;
    display: block !important;
  }

  .header-brand-title {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    line-height: 1.1 !important;
  }

  .header-brand-title div {
    font-size: 1.02rem !important;
    font-weight: 900 !important;
    color: #1a3a6b !important;
    letter-spacing: -0.3px !important;
  }

  .header-brand-sub {
    font-size: 0.55rem !important;
    color: #64748b !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
    white-space: nowrap !important;
  }

  .nav-cta {
    padding: 6px 11px !important;
    font-size: 0.76rem !important;
    font-weight: 800 !important;
    border-radius: 8px !important;
    white-space: nowrap !important;
  }

  /* 🔥 BOLD, HIGH-CONTRAST HAMBURGER TOGGLE BUTTON */
  .nav-toggle {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 4.5px !important;
    width: 38px !important;
    height: 36px !important;
    min-width: 38px !important;
    background: #0f172a !important;
    border: 1px solid #1e293b !important;
    border-radius: 8px !important;
    padding: 6px !important;
    cursor: pointer !important;
    z-index: 1200 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18) !important;
    transition: all 0.2s ease !important;
  }

  .nav-toggle:hover {
    background: #1e3a8a !important;
  }

  .nav-toggle span {
    display: block !important;
    width: 20px !important;
    height: 2.5px !important;
    background: #ffffff !important;
    border-radius: 2px !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  }

  .nav-toggle.active {
    background: #ea580c !important;
    border-color: #ea580c !important;
  }

  .nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px) !important;
  }

  .nav-toggle.active span:nth-child(2) {
    opacity: 0 !important;
    transform: scale(0) !important;
  }

  .nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px) !important;
  }

  /* SLICK MOBILE DRAWER MENU */
  .nav-links {
    position: fixed !important;
    top: 0 !important;
    right: -100% !important;
    width: 290px !important;
    max-width: 85vw !important;
    height: 100vh !important;
    background: #ffffff !important;
    box-shadow: -10px 0 35px rgba(0, 0, 0, 0.25) !important;
    z-index: 1500 !important;
    transition: right 0.35s cubic-bezier(0.25, 1, 0.5, 1) !important;
    flex-direction: column !important;
    padding: 20px 18px 30px !important;
    overflow-y: auto !important;
    display: flex !important;
  }

  .mobile-nav-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding-bottom: 12px !important;
    margin-bottom: 8px !important;
    border-bottom: 1.5px solid #e2e8f0 !important;
  }

  .nav-links.active {
    right: 0 !important;
  }

  .nav-links a {
    padding: 12px 14px !important;
    font-size: 0.96rem !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    border-bottom: 1px solid #f1f5f9 !important;
    display: block !important;
    text-decoration: none !important;
    border-radius: 8px !important;
    transition: background 0.2s !important;
  }

  .nav-links a:hover,
  .nav-links a.active {
    background: #f8fafc !important;
    color: #ea580c !important;
  }

  .nav-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100vh !important;
    background: rgba(0, 0, 0, 0.55) !important;
    backdrop-filter: blur(4px) !important;
    z-index: 1400 !important;
    display: none !important;
  }

  .nav-overlay.active {
    display: block !important;
  }
}

/* --------------------------------------------------------------------------
   2. HERO SECTION & STATS (MOBILE PHONES ONLY: MAX 768PX)
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .hero {
    padding: 30px 0 40px !important;
  }

  .hero .container {
    display: flex !important;
    flex-direction: column !important;
    gap: 24px !important;
  }

  .hero-content {
    text-align: center !important;
    max-width: 100% !important;
  }

  .hero-badge {
    font-size: 0.78rem !important;
    padding: 4px 12px !important;
    margin-bottom: 12px !important;
    display: inline-block !important;
  }

  .hero-content h1 {
    font-size: clamp(1.6rem, 6vw, 2.1rem) !important;
    line-height: 1.22 !important;
    margin-bottom: 12px !important;
  }

  .hero-content p {
    font-size: 0.88rem !important;
    line-height: 1.55 !important;
    margin: 0 auto 18px !important;
    max-width: 540px !important;
  }

  .hero-buttons {
    display: flex !important;
    justify-content: center !important;
    gap: 10px !important;
    flex-wrap: wrap !important;
  }

  .hero-trust {
    justify-content: center !important;
    gap: 8px 14px !important;
    margin-top: 16px !important;
  }

  .hero-slider-card,
  #heroSlider {
    height: clamp(240px, 55vw, 340px) !important;
    border-radius: 14px !important;
    margin-bottom: 12px !important;
  }

  .hero-slide-info {
    padding: 10px 14px !important;
  }

  .hero-slide-info h3 {
    font-size: 0.95rem !important;
    margin-bottom: 2px !important;
  }

  .hero-slide-info p {
    display: none !important;
  }

  /* 2 Stat Cards Side-by-Side */
  .hero-stats {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .stat-card {
    padding: 10px 8px !important;
    border-radius: 10px !important;
    text-align: center !important;
  }

  .stat-card .stat-number {
    font-size: 1.35rem !important;
    line-height: 1.1 !important;
  }

  .stat-card .stat-label {
    font-size: 0.68rem !important;
    margin-top: 2px !important;
  }
}

@media (max-width: 480px) {
  .hero-buttons .btn {
    width: 100% !important;
    text-align: center !important;
    padding: 11px 16px !important;
  }
}

/* --------------------------------------------------------------------------
   3. CORE SERVICES: 2 CARDS SIDE-BY-SIDE ON MOBILE (PASHA PASHI 2 TA CARD)
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .services-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
  }

  .service-card {
    padding: 14px 10px !important;
    border-radius: 12px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04) !important;
  }

  .service-card-header {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    margin-bottom: 8px !important;
  }

  .service-card-icon {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    font-size: 1.1rem !important;
    border-radius: 8px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  .service-card-title {
    font-size: 0.88rem !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
    margin: 0 !important;
  }

  .service-card-desc {
    font-size: 0.72rem !important;
    line-height: 1.35 !important;
    color: #64748b !important;
    margin-bottom: 8px !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
  }

  .service-capabilities-list {
    display: none !important;
    /* Kept hidden on 2-col mobile cards for crisp symmetry */
  }

  .service-card-footer a {
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    color: #1a3a6b !important;
    text-decoration: none !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
  }
}

/* --------------------------------------------------------------------------
   4. WHY CHOOSE US: 2 FLIP CARDS SIDE-BY-SIDE (PASHA PASHI 2 TA CARD)
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .why-us-grid,
  .features-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
  }

  .flip-card {
    height: 175px !important;
  }

  .flip-card-front,
  .flip-card-back {
    padding: 12px 8px !important;
    border-radius: 12px !important;
  }

  .flip-card-front .icon {
    font-size: 1.5rem !important;
    margin-bottom: 6px !important;
  }

  .flip-card-front h3,
  .flip-card-back h3 {
    font-size: 0.86rem !important;
    font-weight: 800 !important;
    margin-bottom: 4px !important;
    line-height: 1.2 !important;
  }

  .flip-card-front p,
  .flip-card-back p {
    font-size: 0.7rem !important;
    line-height: 1.3 !important;
  }
}

/* --------------------------------------------------------------------------
   5. TESTIMONIALS SLIDER: CLEAN & NON-SQUISHED MOBILE CARDS
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .testimonials-slider-wrapper {
    padding: 0 !important;
    position: relative !important;
  }

  .tslider-overflow {
    overflow: hidden !important;
    border-radius: 14px !important;
  }

  .tslider-slide {
    flex: 0 0 100% !important;
    min-width: 100% !important;
    margin-right: 0 !important;
    padding: 0 4px !important;
  }

  .testimonial-card-v2 {
    padding: 18px 16px !important;
    border-radius: 14px !important;
    min-height: 160px !important;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05) !important;
  }

  .tcard-quote {
    font-size: 3.5rem !important;
    top: 8px !important;
    right: 12px !important;
  }

  .tcard-stars {
    font-size: 0.85rem !important;
    margin-bottom: 6px !important;
  }

  .tcard-message {
    font-size: 0.84rem !important;
    line-height: 1.45 !important;
    margin-bottom: 12px !important;
  }

  .tcard-avatar {
    width: 36px !important;
    height: 36px !important;
    font-size: 0.78rem !important;
  }

  .tcard-info strong {
    font-size: 0.84rem !important;
  }

  .tcard-info span {
    font-size: 0.7rem !important;
  }

  /* Hide overlay arrows on mobile to maximize card touch space */
  .tslider-nav {
    display: none !important;
  }

  .tslider-dots {
    margin-top: 14px !important;
    display: flex !important;
    justify-content: center !important;
    gap: 6px !important;
  }

  .tslider-dots .tdot {
    width: 8px !important;
    height: 8px !important;
    border-radius: 50% !important;
  }

  .tslider-dots .tdot.active {
    width: 22px !important;
    border-radius: 10px !important;
  }
}

/* --------------------------------------------------------------------------
   6. TEAM & LEADERSHIP SLIDER (MOBILE CARDS)
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .team-slider-header-wrap {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 12px !important;
    margin-bottom: 18px !important;
  }

  .team-slider-header-wrap h2 {
    font-size: 1.45rem !important;
  }

  .team-slider-track {
    gap: 10px !important;
  }

  .team-slider-item {
    flex: 0 0 calc(50% - 5px) !important;
    min-width: calc(50% - 5px) !important;
    max-width: calc(50% - 5px) !important;
  }

  .team-card-v4 {
    padding: 12px 8px !important;
    border-radius: 12px !important;
    text-align: center !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    height: 100% !important;
  }

  .team-card-topbar {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    gap: 4px !important;
    margin-bottom: 6px !important;
    flex-wrap: nowrap !important;
    width: 100% !important;
    min-height: 22px !important;
  }

  .dept-badge {
    display: inline-flex !important;
    align-items: center !important;
    font-size: 0.64rem !important;
    padding: 2px 7px !important;
    text-transform: none !important;
    white-space: nowrap !important;
    width: fit-content !important;
    max-width: max-content !important;
    flex: 0 0 auto !important;
  }

  .team-card-exp-tag {
    display: inline-flex !important;
    align-items: center !important;
    font-size: 0.62rem !important;
    padding: 2px 5px !important;
    white-space: nowrap !important;
    flex: 0 0 auto !important;
    margin-left: auto !important;
  }

  .team-card-avatar-center {
    margin: 4px auto 6px !important;
  }

  .team-avatar-circle {
    width: 52px !important;
    height: 52px !important;
    font-size: 1.05rem !important;
    margin: 0 auto !important;
  }

  .team-card-identity {
    margin-bottom: 4px !important;
  }

  .team-card-name {
    margin: 0 !important;
  }

  .team-card-name a {
    font-size: 0.88rem !important;
    font-weight: 800 !important;
    line-height: 1.15 !important;
  }

  .team-card-role {
    font-size: 0.68rem !important;
    line-height: 1.2 !important;
    color: #ea580c !important;
    font-weight: 700 !important;
  }

  .team-card-bio {
    font-size: 0.68rem !important;
    line-height: 1.3 !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    margin: 4px 0 8px !important;
    color: #64748b !important;
  }

  .team-card-skills {
    display: none !important;
    /* Hide extra badges on 2-col mobile cards for clean symmetry */
  }

  .btn-view-profile {
    padding: 6px 8px !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    border-radius: 6px !important;
    width: 100% !important;
    justify-content: center !important;
  }

  .team-bottom-actions {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    max-width: 320px !important;
    gap: 10px !important;
    align-items: center !important;
  }

  .team-view-all-btn {
    width: 100% !important;
    padding: 11px 18px !important;
    font-size: 0.84rem !important;
    font-weight: 700 !important;
    border-radius: 10px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    text-align: center !important;
    box-shadow: 0 4px 14px rgba(26, 58, 107, 0.25) !important;
  }

  .team-about-btn {
    width: 100% !important;
    padding: 10px 16px !important;
    font-size: 0.82rem !important;
    font-weight: 700 !important;
    border-radius: 10px !important;
    background: #ffffff !important;
    color: #1a3a6b !important;
    border: 1.5px solid #cbd5e1 !important;
    text-align: center !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
  }
}

/* Desktop Styles for Team Bottom Actions */
.team-bottom-actions {
  display: flex;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
}

.team-view-all-btn {
  padding: 13px 26px;
  font-weight: 800;
  font-size: 0.94rem;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 6px 20px rgba(26, 58, 107, 0.25);
  transition: all 0.25s ease;
}

.team-view-all-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(26, 58, 107, 0.35);
}

.team-about-btn {
  padding: 13px 22px;
  font-weight: 700;
  font-size: 0.92rem;
  border-radius: 12px;
  background: #ffffff;
  color: #1a3a6b;
  border: 1.5px solid #cbd5e1;
  transition: all 0.25s ease;
}

.team-about-btn:hover {
  background: #f8fafc;
  border-color: #94a3b8;
  transform: translateY(-2px);
}

/* --------------------------------------------------------------------------
   7. BEFORE/AFTER SLIDER, FAQ & FOOTER (MOBILE CLEANUP)
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .before-after-wrapper {
    height: clamp(230px, 55vw, 320px) !important;
    border-radius: 12px !important;
  }

  .before-badge,
  .after-badge {
    top: 12px !important;
    bottom: auto !important;
    padding: 4px 10px !important;
    font-size: 0.68rem !important;
    border-radius: 8px !important;
    max-width: 44% !important;
    white-space: nowrap !important;
    text-overflow: ellipsis !important;
    overflow: hidden !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4) !important;
    z-index: 6 !important;
  }

  .before-badge {
    left: 12px !important;
  }

  .after-badge {
    right: 12px !important;
  }

  .badge-long {
    display: none !important;
  }

  .badge-short {
    display: inline !important;
  }

  .before-after-handle {
    width: 36px !important;
    height: 36px !important;
    font-size: 0.8rem !important;
  }

  .faq-question {
    padding: 13px 14px !important;
    font-size: 0.88rem !important;
  }

  .faq-answer {
    padding: 0 14px 14px !important;
    font-size: 0.82rem !important;
    line-height: 1.55 !important;
  }

  .footer-grid {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }
}

.badge-short {
  display: none;
}

.badge-long {
  display: inline;
}