/**
 * Charchoob site — responsive overrides (mobile / tablet)
 */

/* --- Global --- */
body.charchoob-theme {
  overflow-x: clip;
}

body.charchoob-theme img,
body.charchoob-theme video,
body.charchoob-theme svg {
  max-width: 100%;
  height: auto;
}

body.charchoob-theme .container {
  padding-left: max(16px, calc(var(--bs-gutter-x, 1.5rem) * 0.5));
  padding-right: max(16px, calc(var(--bs-gutter-x, 1.5rem) * 0.5));
}

body.charchoob-theme h1,
body.charchoob-theme h2,
body.charchoob-theme h3,
body.charchoob-theme .accordion-button > span {
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* --- Hero: tablet portrait (768–991px, stacked columns) --- */
@media (min-width: 768px) and (max-width: 991px) {
  body.charchoob-theme .hero-area9,
  body.charchoob-theme.ltr-body .hero-area9 {
    min-height: auto;
    padding-bottom: 32px;
    overflow: hidden;
  }

  body.charchoob-theme .hero-area9 .row.align-items-center {
    align-items: flex-start !important;
  }

  body.charchoob-theme .hero-area9 .main-images,
  body.charchoob-theme.ltr-body .hero-area9 .main-images {
    position: relative;
    height: auto !important;
    min-height: 360px;
    max-width: 540px;
    margin-top: 36px;
    margin-left: auto !important;
    margin-right: auto;
    overflow: hidden;
    display: block;
  }

  /* Base frame + main screenshot (template keeps these on smaller breakpoints) */
  body.charchoob-theme .hero-area9 .main-images .image1,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image1 {
    display: flex !important;
    position: relative;
    z-index: 1;
    width: 100%;
    align-items: center;
    justify-content: center;
    text-align: center;
  }

  body.charchoob-theme .hero-area9 .main-images .image1 img,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image1 img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 280px;
    object-fit: contain;
  }

  body.charchoob-theme .hero-area9 .main-images .main-img,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .main-img {
    position: absolute !important;
    z-index: 2;
    left: 50% !important;
    right: auto !important;
    bottom: 0 !important;
    transform: translateX(-50%);
    width: 88%;
    max-width: 460px;
    margin-inline: auto;
    text-align: center;
  }

  body.charchoob-theme .hero-area9 .main-images .main-img img,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .main-img img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 340px;
    object-fit: contain;
    margin-inline: auto;
  }

  /* Accent badge — contained inside the hero image box */
  body.charchoob-theme .hero-area9 .main-images .image2,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image2 {
    display: block !important;
    position: absolute;
    z-index: 3;
    top: 24px;
    inset-inline-end: 0;
    width: auto;
    max-width: 38%;
  }

  body.charchoob-theme .hero-area9 .main-images .image2 img,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image2 img {
    width: 100%;
    height: auto;
    object-fit: contain;
  }

  /* These absolute layers overflow on stacked tablet layout */
  body.charchoob-theme .hero-area9 .main-images .image3,
  body.charchoob-theme .hero-area9 .main-images .image4,
  body.charchoob-theme .hero-area9 .main-images .image5,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image3,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image4,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image5 {
    display: none !important;
  }

  body.charchoob-theme .pages-hero .hero-image {
    margin-top: 32px;
    margin-bottom: 0;
    text-align: center;
  }

  body.charchoob-theme .pages-hero .hero-image img {
    width: auto;
    max-width: 100%;
    max-height: 400px;
    object-fit: contain;
  }
}

/* --- Hero: phone --- */
@media (max-width: 767px) {
  body.charchoob-theme .hero-area9,
  body.charchoob-theme.ltr-body .hero-area9 {
    min-height: auto;
    padding-bottom: 48px;
    overflow: hidden;
  }

  body.charchoob-theme .hero-area9 .main-heading,
  body.charchoob-theme.ltr-body .hero-area9 .main-heading {
    padding-top: 112px;
  }

  body.charchoob-theme .hero-area9 .main-heading h1,
  body.charchoob-theme.ltr-body .hero-area9 .main-heading h1 {
    font-size: clamp(1.625rem, 7vw, 2.5rem);
    line-height: 1.2;
  }

  body.charchoob-theme .hero-area9 .main-heading p,
  body.charchoob-theme.ltr-body .hero-area9 .main-heading p {
    font-size: 16px;
    line-height: 1.55;
  }

  body.charchoob-theme .hero-area9 .main-images,
  body.charchoob-theme.ltr-body .hero-area9 .main-images {
    position: relative;
    height: auto !important;
    min-height: 280px;
    max-width: 100%;
    margin-top: 32px;
    margin-left: auto !important;
    margin-right: auto;
    overflow: hidden;
    display: block;
  }

  body.charchoob-theme .hero-area9 .main-images .image1,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image1 {
    display: flex !important;
    position: relative;
    z-index: 1;
    width: 100%;
    align-items: center;
    justify-content: center;
    text-align: center;
  }

  body.charchoob-theme .hero-area9 .main-images .image1 img,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image1 img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 200px;
    object-fit: contain;
  }

  body.charchoob-theme .hero-area9 .main-images .main-img,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .main-img {
    position: absolute !important;
    z-index: 2;
    left: 50% !important;
    right: auto !important;
    bottom: 0 !important;
    transform: translateX(-50%);
    width: 92%;
    max-width: 100%;
    margin-inline: auto;
    text-align: center;
  }

  body.charchoob-theme .hero-area9 .main-images .main-img img,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .main-img img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 260px;
    object-fit: contain;
    margin-inline: auto;
  }

  body.charchoob-theme .hero-area9 .main-images .image2,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image2 {
    display: block !important;
    position: absolute;
    z-index: 3;
    top: 12px;
    inset-inline-end: 0;
    width: auto;
    max-width: 40%;
  }

  body.charchoob-theme .hero-area9 .main-images .image2 img,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image2 img {
    width: 100%;
    height: auto;
    object-fit: contain;
  }

  body.charchoob-theme .hero-area9 .main-images .image3,
  body.charchoob-theme .hero-area9 .main-images .image4,
  body.charchoob-theme .hero-area9 .main-images .image5,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image3,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image4,
  body.charchoob-theme.ltr-body .hero-area9 .main-images .image5 {
    display: none !important;
  }
}

/* --- Work2 features carousel --- */
@media (max-width: 767px) {
  .work2 .work2-carousel-wrap {
    padding: 0 44px;
  }

  .work2 .work2-carousel-arrow {
    height: 40px;
    width: 40px;
    font-size: 16px;
  }

  .work2 .tab-content .tabs-box-item h3 {
    font-size: 20px;
    line-height: 1.3;
    padding-bottom: 16px;
  }

  .work2 .shape1,
  .work2 .shape2 {
    display: none;
  }
}

@media (max-width: 575px) {
  .work2 .work2-carousel-wrap {
    padding: 0 36px;
  }
}

@media (max-width: 767px) {
  body.charchoob-theme.ltr-body .footer2 .copyright-area .coppyleft,
  .footer2 .copyright-area .coppyleft {
    justify-content: center;
    margin-top: 16px;
  }
}

/* --- Work5 tabs --- */
@media (max-width: 991px) {
  body.charchoob-theme .work5 .tab-pane .work-tab-body {
    padding: 0 16px;
  }

  body.charchoob-theme .work5 .tab-pane .work-tab-body .headding4 h3 {
    font-size: 22px;
    line-height: 1.3;
  }
}

@media (max-width: 767px) {
  body.charchoob-theme .work5 .work5-tabs-all {
    padding: 16px;
  }

  body.charchoob-theme .work5 .work5-tabs-all .nav {
    padding: 10px;
    gap: 8px;
  }

  body.charchoob-theme .work5 .work5-tabs-all .nav li {
    display: block;
    width: 100%;
    margin: 0 0 8px;
  }

  body.charchoob-theme .work5 .work5-tabs-all .nav li button {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    text-align: start;
  }

  body.charchoob-theme .work5 .tab-pane .work-tab-body {
    padding: 0 8px;
  }

  body.charchoob-theme .work5 .tab-pane .work-tab-body .work4-images {
    margin-top: 24px;
  }
}

/* --- Stapes / apps8 --- */
@media (max-width: 991px) {
  /* Text first, image underneath (DOM has image col before text col) */
  body.charchoob-theme .apps8 .row.align-items-center {
    display: flex;
    flex-direction: column;
  }

  body.charchoob-theme .apps8 .row.align-items-center > .col-lg-4 {
    order: 1;
    width: 100%;
  }

  body.charchoob-theme .apps8 .row.align-items-center > .col-lg-8 {
    order: 2;
    width: 100%;
  }

  body.charchoob-theme .apps8 .images-all {
    height: auto !important;
    min-height: 0;
    margin-top: 32px;
    margin-bottom: 0;
  }

  body.charchoob-theme .apps8 .images-all .image2 {
    position: relative !important;
    top: auto;
    right: auto;
    left: auto;
    inset-inline: auto;
    text-align: center;
  }

  body.charchoob-theme .apps8 .images-all .image2 img {
    display: block;
    width: 100%;
    height: auto;
    max-width: 100%;
    object-fit: contain;
    margin-inline: auto;
  }
}

@media (max-width: 767px) {
  body.charchoob-theme .stapes .stapes-images1 .image2 {
    display: none;
  }

  body.charchoob-theme .apps8 .images-all {
    margin-top: 24px;
  }
}

/* --- Pricing --- */
@media (max-width: 767px) {
  body.charchoob-theme .pricing5 .pricing-box {
    padding: 24px 20px;
    margin-top: 16px;
  }

  body.charchoob-theme .pricing5 .pricing-box:hover {
    transform: none;
  }

  body.charchoob-theme .pricing5 .pricing-box .plan-list li {
    font-size: 16px;
    line-height: 1.4;
    align-items: flex-start;
  }
}

/* --- Pricing feature badges marquee --- */
@keyframes ch-feat-badge-marquee {
  from {
    transform: translate3d(0, 0, 0);
  }

  to {
    transform: translate3d(calc(-100% + 100cqw), 0, 0);
  }
}

@media (max-width: 991px) {
  body.charchoob-theme .pricing5 .ch-plan-feature-badges {
    padding: 4px 0;
    margin-inline: -12px;
  }

  body.charchoob-theme .pricing5 .ch-feat-badge-marquee {
    container-type: inline-size;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(
      to right,
      transparent 0%,
      #000 8%,
      #000 92%,
      transparent 100%
    );
    mask-image: linear-gradient(
      to right,
      transparent 0%,
      #000 8%,
      #000 92%,
      transparent 100%
    );
  }

  body.charchoob-theme .pricing5 .ch-feat-badge-track {
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 0;
    width: max-content;
    animation: ch-feat-badge-marquee 22s ease-in-out infinite alternate;
    will-change: transform;
  }

  body.charchoob-theme .pricing5 .ch-feat-badge-group {
    display: flex;
    flex: 0 0 auto;
    align-items: flex-start;
    gap: 28px;
    padding-inline: 14px;
  }

  body.charchoob-theme .pricing5 .ch-feat-badge {
    flex: 0 0 auto;
    min-width: 112px;
    max-width: 140px;
  }
}

@media (max-width: 991px) and (prefers-reduced-motion: reduce) {
  body.charchoob-theme .pricing5 .ch-feat-badge-marquee {
    overflow-x: auto;
    -webkit-mask-image: none;
    mask-image: none;
    scrollbar-width: none;
  }

  body.charchoob-theme .pricing5 .ch-feat-badge-marquee::-webkit-scrollbar {
    display: none;
  }

  body.charchoob-theme .pricing5 .ch-feat-badge-track {
    animation: none;
  }
}

@media (max-width: 575px) {
  body.charchoob-theme .pricing5 .ch-feat-badge-tx {
    font-size: 13px;
  }
}

/* --- Pricing redesign --- */
@media (max-width: 1199px) {
  body.charchoob-theme .pricing5 .ch-plan {
    padding: 26px 20px;
  }

  body.charchoob-theme .pricing5 .ch-plan-price {
    font-size: 30px;
  }
}

@media (max-width: 991px) {
  body.charchoob-theme .pricing5 .ch-plans {
    row-gap: 16px;
  }

  body.charchoob-theme .pricing5 .ch-benefit {
    flex: 1 1 45%;
    min-width: 45%;
  }
}

@media (max-width: 767px) {
  body.charchoob-theme .pricing5 .ch-plans-intro {
    font-size: 15px;
    line-height: 1.8;
  }

  body.charchoob-theme .pricing5 .ch-plan {
    margin-top: 26px;
  }

  body.charchoob-theme .pricing5 .ch-plan:hover {
    transform: none;
    box-shadow: none;
  }

  body.charchoob-theme .pricing5 .ch-plan-benefits {
    gap: 18px;
  }

  body.charchoob-theme .pricing5 .ch-benefit {
    flex: 1 1 100%;
    min-width: 100%;
  }
}

/* --- Testimonials --- */
@media (max-width: 767px) {
  body.charchoob-theme .testimonial7 {
    padding-bottom: 110px;
  }

  body.charchoob-theme .testimonial7 .testimonial7-all {
    padding: 24px 20px;
  }

  body.charchoob-theme .testimonial7 .testimonial7-all p.text {
    font-size: 16px;
    line-height: 1.55;
  }

  body.charchoob-theme .testimonial7 .testimonial7-all .pagination-buttons {
    left: 0;
    right: 0;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 20px;
  }

  body.charchoob-theme .testimonial7 .testimonial7-all .pagination-buttons button {
    margin: 0;
  }
}

/* --- Footer --- */
@media (max-width: 767px) {
  body.charchoob-theme .footer2 .footer-icon-box-all .footer-icon-box::after {
    display: none;
  }

  body.charchoob-theme .footer2 .footer-icon-box-all {
    margin-top: 40px;
    padding-top: 40px;
  }

  body.charchoob-theme .footer2 .footer-icon-box-all .footer-icon-box .headding p {
    font-size: 16px;
    line-height: 1.45;
  }
}

/* --- Inner pages (about, contact) --- */
@media (max-width: 991px) {
  body.charchoob-theme .pages-hero {
    min-height: auto;
    padding-bottom: 40px;
  }

  body.charchoob-theme .pages-hero .hero-image {
    margin-left: 0;
    margin-right: 0;
    text-align: center;
  }
}

@media (max-width: 767px) {
  body.charchoob-theme .pages-hero .main-headding h1 {
    font-size: clamp(1.625rem, 7vw, 2.5rem);
    line-height: 1.2;
  }

  body.charchoob-theme .pages-hero .main-headding p {
    font-size: 16px;
    line-height: 1.55;
  }

  body.charchoob-theme .about-page-area1 .headding2 h2 {
    font-size: clamp(1.5rem, 6vw, 2rem);
    line-height: 1.25;
  }

  body.charchoob-theme .contact-page-area {
    margin-top: 0;
    padding-top: 96px;
  }

  body.charchoob-theme .contact-page-area .contact-form-all {
    padding: 24px 20px;
  }

  body.charchoob-theme .common-main-headding h1 {
    font-size: clamp(1.625rem, 7vw, 2.5rem);
    line-height: 1.2;
  }

  body.charchoob-theme .contact-page-area .contact-form-all .contact-page-boxs .single-box {
    margin-bottom: 16px;
  }
}

/* --- Demo request --- */
@media (max-width: 767px) {
  body.charchoob-theme .demo-request-form {
    padding: 28px 20px;
  }

  body.charchoob-theme .demo-request-form .headding h2 {
    font-size: 26px;
  }

  body.charchoob-theme .demo-request-form .headding p {
    font-size: 14px;
  }

  body.charchoob-theme .demo-request-top > .col-lg-4 {
    max-width: 42%;
  }

  body.charchoob-theme .demo-request-toolbar {
    gap: 10px;
  }

  body.charchoob-theme .demo-request-toolbar .lang-switcher {
    margin-inline-end: 0;
  }

  body.charchoob-theme .demo-request-logo {
    max-width: 90px;
    text-align: start;
  }
}

/* --- Utilities --- */
@media (max-width: 767px) {
  body.charchoob-theme .space60 {
    height: 36px;
  }

  body.charchoob-theme .theme-btn15,
  body.charchoob-theme .theme-btn5,
  body.charchoob-theme .theme-btn7,
  body.charchoob-theme .theme-btn8 {
    max-width: 100%;
  }
}

@media (max-width: 575px) {
  body.charchoob-theme .heading9 h2,
  body.charchoob-theme .headding4 h2,
  body.charchoob-theme .heading7 h2,
  body.charchoob-theme .heading5 h2,
  body.charchoob-theme .heading6 h2,
  body.charchoob-theme .heading8 h2 {
    font-size: clamp(1.375rem, 6vw, 1.75rem);
    line-height: 1.25;
  }
}

/*
 * Mobile nav — align with Bootstrap d-lg-none (<992px).
 * mobile-menu.css previously stopped at 769px, so portrait tablets
 * showed the sidebar in normal document flow above the hero.
 */
@media (max-width: 991px) {
  body.charchoob-theme .mobile-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 999;
    background: rgba(255, 255, 255, 0.94);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(128, 141, 124, 0.14);
  }

  body.charchoob-theme .mobile-sidebar {
    position: fixed;
    top: 0;
    right: -100%;
    left: auto;
    width: 100%;
    height: 100%;
    max-height: 100%;
    z-index: 9999;
    visibility: hidden;
    opacity: 0;
    overflow-y: auto;
    pointer-events: none;
    transition: right 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
  }

  body.charchoob-theme .mobile-sidebar.mobile-menu-active {
    right: 0;
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
  }

  body.charchoob-theme .mobile-sidebar .logo-m {
    margin-top: 0;
    margin-bottom: 24px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding-inline-end: 48px;
    position: relative;
    z-index: 1;
  }

  body.charchoob-theme .mobile-sidebar .menu-close {
    top: 24px;
    z-index: 2;
  }

  body.charchoob-theme .mobile-sidebar .logo-m img {
    content: url("../img/logo/header-white.png");
    max-width: 170px;
    width: auto;
    height: auto;
    display: block;
  }

  html[data-ch-lang="en"] body.charchoob-theme .mobile-sidebar .logo-m img {
    content: url("../img/logo/header-white-latin.png");
  }

  html[dir="ltr"] body.charchoob-theme .mobile-sidebar .menu-close {
    left: auto;
    right: 20px;
  }

  html[dir="ltr"] body.charchoob-theme .mobile-sidebar {
    right: auto;
    left: -100%;
    transition-property: left, opacity, visibility;
  }

  html[dir="ltr"] body.charchoob-theme .mobile-sidebar.mobile-menu-active {
    left: 0;
    right: auto;
  }

  body.charchoob-theme .contact-page-area {
    margin-top: 0;
    padding-top: 100px;
  }
}
