/*================================================
   Marketive — Refined Responsive Styles
=================================================*/

@media (max-width: 1699px) {
  header.home3-header { padding: 18px 5% 0; }
  .home3-banner-section .banner-content-wrap { margin-left: 8%; }
  .right-sidebar-menu .right-sidebar-close-btn { right: 30px; top: 30px; }
  .right-sidebar-menu .sidebar-content-wrap { padding: 60px 40px; }
}

@media (max-width: 1399px) {
  header.home3-header { padding: 16px 3.5% 0; }
  header.home3-header .header-area-wrap .left-area { gap: 40px; }
  header .header-area-wrap .company-logo img { height: 58px; max-height: 58px; }
  header .header-area-wrap .main-menu > ul > li { padding: 22px 8px; }

  .section-title.home3-section-title h2 { font-size: 42px; }
  .home3-banner-section .banner-wrapper { grid-template-columns: 48% 52%; }
  .home3-banner-section .banner-content-wrap {
    margin-left: 6%;
    padding: 50px 0 70px;
  }
  .roadmap-card { padding: 55px 22px; }
  .roadmap-card h3 { font-size: 26px; margin-bottom: 20px; }
  .service-card { padding: 42px 28px; }
  .service-card h3 { font-size: 24px; }
  .pricing-card.featured { transform: none; }
}

@media (max-width: 1199px) {
  header .header-area-wrap .nav-right { gap: 16px; }
  header .header-area-wrap .main-menu > ul > li > a { font-size: 15px; }

  .section-title.home3-section-title h2 { font-size: 36px; }
  .home3-banner-section { padding-top: 0; }
  .home3-banner-section .banner-wrapper {
    display: block;
  }
  .home3-banner-section .banner-content-wrap {
    margin-left: 8%;
    margin-right: 8%;
    padding: 60px 0 70px;
  }
  .banner-img-wrap,
  .banner-img-wrap .home3-banner-slide,
  .banner-img-wrap .img-area,
  .banner-img-wrap .img-area img {
    min-height: 420px;
  }
  .banner-img-wrap .home3-banner-slide {
    border-radius: 0 0 20px 20px;
  }
  .banner-img-wrap .counter-wrap {
    left: 16px;
    bottom: 16px;
    flex-direction: row;
  }
  .banner-img-wrap .counter-area {
    border-radius: 12px 0 0 12px;
    min-width: 140px;
  }
  .banner-img-wrap .counter-area.two {
    border-radius: 0 12px 12px 0;
  }
  .global-icon { right: 12%; bottom: 8%; }
  .home3-portfolio-section .portfolio-shell,
  .team-section .team-shell {
    padding: 60px 28px;
  }
}

/* Tablet / Mobile nav */
@media (max-width: 991px) {
  /*
    backdrop-filter creates a containing block for position:fixed descendants,
    which traps the drawer inside the short header. Disable it on mobile so the
    menu can cover the full viewport.
  */
  header.header-area,
  header.header-area.home3-header,
  header.sticky {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background-color: rgba(248, 250, 252, 0.98);
  }

  header.home3-header { padding: 12px 12px; }

  header.sticky .header-area-wrap,
  header.home3-header .header-area-wrap {
    background: var(--white-color);
    border-radius: 16px;
    border: 1px solid var(--borders-color);
    padding: 10px 14px;
    overflow: visible;
  }

  header.home3-header .header-area-wrap .container-fluid.one {
    gap: 12px;
  }

  /* Keep logo + hamburger on one row (do NOT force left-area to 100%) */
  header.home3-header .header-area-wrap .left-area {
    gap: 0;
    flex: 1 1 auto;
    min-width: 0;
    width: auto;
    justify-content: flex-start;
  }

  header.home3-header .header-area-wrap .right-area {
    flex: 0 0 auto;
    margin-left: auto;
  }

  header .header-area-wrap .company-logo {
    position: relative;
    z-index: 1;
  }

  header .header-area-wrap .nav-right .mobile-menu-btn {
    display: inline-flex !important;
    align-items: center;
    visibility: visible !important;
    justify-content: center;
    min-width: 44px;
    max-width: 44px;
    height: 44px;
    border-radius: 8px;
    border: 1px solid var(--borders-color);
    background: var(--white-color);
    cursor: pointer;
    pointer-events: auto;
    position: relative;
    z-index: 2;
  }

  header .header-area-wrap .nav-right .mobile-menu-btn svg { fill: var(--title-color); }

  header .header-area-wrap .mobile-logo-area {
    display: flex !important;
    margin-bottom: 10px;
  }

  /* Drawer is moved to body on mobile — keep overlay under it */
  .menu-overlay.active {
    z-index: 1090;
  }

  .main-menu.is-mobile-drawer,
  body > .main-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 300px;
    max-width: 86vw;
    padding: 24px 20px !important;
    z-index: 1100;
    height: 100vh;
    height: 100dvh;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    background: #ffffff;
    border-right: 1px solid var(--borders-color);
    transform: translate3d(-105%, 0, 0);
    transition: transform 0.3s ease;
    box-shadow: 0 8px 32px rgba(15, 23, 42, 0.12);
    display: block;
    visibility: visible;
    pointer-events: none;
  }

  .main-menu.is-mobile-drawer.show-menu,
  body > .main-menu.show-menu {
    transform: translate3d(0, 0, 0);
    pointer-events: auto;
  }

  .main-menu.is-mobile-drawer > ul,
  body > .main-menu > ul { float: none; text-align: left; padding: 20px 0; list-style: none; margin: 0; }
  .main-menu.is-mobile-drawer > ul > li,
  body > .main-menu > ul > li { display: block; position: relative; padding: 0; }
  .main-menu.is-mobile-drawer > ul > li.position-inherit,
  body > .main-menu > ul > li.position-inherit { position: relative; }
  .main-menu.is-mobile-drawer > ul > li .dropdown-icon,
  body > .main-menu > ul > li .dropdown-icon {
    display: block;
    opacity: 1;
    position: absolute;
    top: 14px;
    right: 0;
    font-size: 16px;
    color: var(--title-color);
    cursor: pointer;
    z-index: 2;
  }

  .main-menu.is-mobile-drawer > ul > li .dropdown-icon.active,
  body > .main-menu > ul > li .dropdown-icon.active {
    transform: rotate(45deg);
  }
  .main-menu.is-mobile-drawer > ul > li > a,
  body > .main-menu > ul > li > a {
    padding: 15px 0; display: block; border: unset !important; color: var(--text-color); background: transparent !important;
  }
  .main-menu.is-mobile-drawer > ul > li.active > a,
  .main-menu.is-mobile-drawer > ul > li:hover > a,
  body > .main-menu > ul > li.active > a,
  body > .main-menu > ul > li:hover > a {
    border: unset !important; background: transparent !important; color: var(--title-color);
  }
  .main-menu.is-mobile-drawer > ul > li ul.sub-menu,
  body > .main-menu > ul > li ul.sub-menu {
    position: static; min-width: 0; border: none; box-shadow: none;
    padding: 0 0 8px 12px; background: transparent; display: none; top: auto;
  }
  .main-menu.is-mobile-drawer > ul > li ul.sub-menu > li > a,
  body > .main-menu > ul > li ul.sub-menu > li > a { padding: 10px 0 !important; }
  .main-menu.is-mobile-drawer > ul > li .mega-menu,
  body > .main-menu > ul > li .mega-menu {
    position: static; transform: none !important; width: 100%; min-width: 0;
    border: none; box-shadow: none; background: transparent; border-radius: 0;
    padding: 0 0 10px; display: none; top: auto;
  }
  .main-menu.is-mobile-drawer > ul > li .mega-menu .menu-row,
  body > .main-menu > ul > li .mega-menu .menu-row { display: block; }
  .main-menu.is-mobile-drawer > ul > li .mega-menu .service-wrap,
  body > .main-menu > ul > li .mega-menu .service-wrap { padding: 10px 0; }
  .main-menu.is-mobile-drawer > ul > li .mega-menu .mega-menu-title,
  body > .main-menu > ul > li .mega-menu .mega-menu-title { display: none; }
  .main-menu.is-mobile-drawer > ul > li .mega-menu .service-list,
  body > .main-menu > ul > li .mega-menu .service-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    list-style: none;
    padding: 0;
    margin: 0;
  }

  .main-menu.is-mobile-drawer > ul > li .mega-menu .service-list .single-service a,
  body > .main-menu > ul > li .mega-menu .service-list .single-service a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border: 1px solid var(--borders-color);
    border-radius: 10px;
    background: #fff;
    color: var(--title-color);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.3;
  }

  .main-menu.is-mobile-drawer > ul > li .mega-menu .service-wrap .contact-area,
  .main-menu.is-mobile-drawer > ul > li .mega-menu .industry-wrap,
  .main-menu.is-mobile-drawer > ul > li .mega-menu .support-wrap,
  body > .main-menu > ul > li .mega-menu .service-wrap .contact-area,
  body > .main-menu > ul > li .mega-menu .industry-wrap,
  body > .main-menu > ul > li .mega-menu .support-wrap { display: none; }

  .main-menu.is-mobile-drawer .mobile-logo-area,
  body > .main-menu .mobile-logo-area {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
  }

  .main-menu.is-mobile-drawer .mobile-logo-wrap img,
  body > .main-menu .mobile-logo-wrap img {
    width: auto;
    height: 48px;
    object-fit: contain;
  }

  .main-menu.is-mobile-drawer .menu-close-btn,
  body > .main-menu .menu-close-btn {
    height: 38px;
    width: 38px;
    min-width: 38px;
    border-radius: 10px;
    border: 1px solid var(--borders-color);
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
  }

  .main-menu.is-mobile-drawer .menu-close-btn i,
  body > .main-menu .menu-close-btn i {
    font-size: 20px;
    color: var(--title-color);
  }

  .section-title.home3-section-title h2 { font-size: 37px; }
  .home3-banner-section { padding-top: 0; padding-bottom: 70px; }
  .roadmap-section,
  .home3-process-section,
  .home3-service-section,
  .home3-portfolio-section,
  .testimonial-section,
  .video-counter-section,
  .award-section,
  .team-section,
  .pricing-section,
  .faq-section,
  .blog-section,
  .contact-section,
  .inner-page-section { padding: 64px 0; }

  .page-banner {
    padding: 88px 0 48px;
    text-align: left;
  }
  .page-banner .container { padding-left: 20px; padding-right: 20px; }
  .page-banner h1 {
    margin-left: 0;
    margin-right: 0;
    font-size: clamp(28px, 7vw, 40px);
  }
  .page-banner-desc { margin-left: 0; }
  .page-banner .breadcrumb { justify-content: flex-start; }

  .home3-banner-section .btm-area > li:first-child { padding-right: 0; }
  .home3-banner-section .btm-area > li:first-child::after { display: none; }
  .home3-banner-section .btm-area { gap: 28px; margin-top: 50px; }
  .process-img-area img,
  .video-card img { height: 300px; }
  .stat-item h3 { font-size: 42px; }
  .footer-top-area { flex-direction: column; align-items: flex-start; gap: 24px; }
  .footer-round-btn { width: 88px; height: 88px; }
  .right-sidebar-menu { z-index: 1200; }
  .right-sidebar-menu .right-sidebar-menu-wrap { width: min(420px, 92vw); }

  .blog-sidebar { position: static; top: auto; }
  .pricing-grid,
  .team-grid,
  .blog-grid { gap: 20px; }
  .inner-media-frame img { min-height: 220px; }
}

@media (max-width: 767px) {
  .section-title.home3-section-title h2 { font-size: 30px; }
  .home3-banner-section .banner-wrapper { border-radius: 0; }
  .home3-banner-section .banner-content-wrap {
    margin-left: 6%;
    margin-right: 6%;
    padding: 48px 0 56px;
  }
  .banner-img-wrap,
  .banner-img-wrap .home3-banner-slide,
  .banner-img-wrap .img-area,
  .banner-img-wrap .img-area img { min-height: 320px; }
  .banner-img-wrap .counter-wrap { flex-direction: column; left: 12px; right: auto; }
  .banner-img-wrap .counter-area,
  .banner-img-wrap .counter-area.two { border-radius: 10px; }
  .global-icon { display: none; }
  .roadmap-card { padding: 48px 20px; }
  .roadmap-card h3 { font-size: 24px; }
  .single-process h3 { font-size: 22px; }
  .service-card h3 { font-size: 22px; }
  .testimonial-card { padding: 32px 24px; }
  .testimonial-card > p { font-size: 18px; }
  .award-list li { flex-direction: column; align-items: flex-start; gap: 8px; padding: 28px 16px; }
  .award-list span { text-align: left; min-width: 0; }
  .home3-portfolio-section .portfolio-shell,
  .team-section .team-shell { padding: 48px 18px; border-radius: 14px; }
  .contact-form { padding: 24px 18px; }
  .footer-menu-wrap { border-radius: 14px; padding: 56px 0 48px; }
  .footer-logo-area h2 { font-size: 34px; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .stat-item { padding: 24px 18px; }
  .stat-item h3 { font-size: 36px; }
  #scroll-percentage { right: 16px; bottom: 16px; width: 50px; height: 50px; }
  .copyright-inner { flex-direction: column; text-align: center; }
  .copyright-inner ul { justify-content: center; flex-wrap: wrap; }

  .partner-logos {
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px 28px;
  }

  .blog-quote { font-size: 18px; padding: 18px 16px; }
  .blog-details-meta { gap: 10px 14px; }
  .related-post img { width: 64px; height: 64px; }

  .inner-cta-panel {
    text-align: center;
    padding: 36px 20px;
  }
}

@media (max-width: 576px) {
  .section-title.home3-section-title h2 { font-size: 27px; }
  header.home3-header { padding: 12px 8px; }
  header .header-area-wrap .company-logo img { height: 52px; max-height: 52px; }
  header .header-area-wrap .nav-right { gap: 10px; }
  .home3-banner-section .banner-wrapper { border-radius: 0; }
  .partner-logos span { font-size: 16px; }
  .right-sidebar-menu .right-sidebar-menu-wrap { width: 300px; }
  .right-sidebar-menu .sidebar-content-wrap { padding: 40px 18px; }
}
