/* ==========================================================================
   Boosla marketing site — responsive layer
   --------------------------------------------------------------------------
   Loaded last on every Softec page (after style.css and boosla-overrides.css).

   Rules for this file:
   • Desktop (≥ 1200px) is the reference and is not changed here: every fluid
     value is a clamp() whose upper bound is the current desktop value.
   • Fluid first (clamp / min / max / grid auto-fit); media queries only where
     the layout itself has to change, and only at these three points:
         tablet  ≤ 991.98px     mobile  ≤ 767.98px     small  ≤ 575.98px
   • Logical properties (inline/block) so RTL and LTR both work.
   ========================================================================== */

/* ── 1. Tokens ─────────────────────────────────────────────────────────── */
:root {
    /* Type scale for tablet & mobile (≤ 991px), tuned for IBM Plex Sans Arabic.
       At 992px and up the template's own desktop sizes apply unchanged.
       Hero:    ~34px @320 · ~36px @390 · ~49px @768 · 56px @≥991
       Section: ~28px @320 · ~30px @390 · ~43px @768 · ~50px @991 */
    --bz-fs-hero:     clamp(34px, 3.41vw + 23px, 56px);
    --bz-fs-h2:       clamp(28px, 3.4vw + 17px, 53px);
    --bz-fs-h2-lg:    clamp(28px, 3.4vw + 17px, 50px);
    --bz-fs-h2-md:    clamp(26px, 2.7vw + 17.6px, 50px);
    --bz-fs-lead:     clamp(16px, 0.5vw + 14px, 20px);

    /* Header height below the desktop menu breakpoint. */
    --bz-header-h:    clamp(64px, 3.5vw + 52px, 80px);
    --bz-gutter:      clamp(16px, 2.5vw + 8px, 24px);
}

/* ── 2. Typography ─────────────────────────────────────────────────────── */
/* Desktop hero size (moved here from boosla-overrides.css, values unchanged). */
.tp-hero-title-3 { font-size: 58px; line-height: 1.3; }
@media (min-width: 1200px) {
    .tp-hero-title-3 { font-size: 64px; }
}

@media (max-width: 991.98px) {
    .tp-hero-title-3     { font-size: var(--bz-fs-hero); }
    .tp-section-title-3  { font-size: var(--bz-fs-h2); }
    .tp-section-title-4  { font-size: var(--bz-fs-h2-lg); }
    .tp-section-title-5  { font-size: var(--bz-fs-h2-md); }
    .tp-hero-title-box p { font-size: var(--bz-fs-lead); }
}

@media (max-width: 767.98px) {
    /* A touch more leading for Arabic once lines get short. */
    .tp-hero-title-3,
    .tp-section-title-3,
    .tp-section-title-4,
    .tp-section-title-5 { line-height: 1.4; }
    .tp-hero-title-box p { line-height: 1.75; }
    .boosla-inner-hero__title { font-size: clamp(30px, 6vw + 10px, 40px); }
}

/* ── 3. Spacing ────────────────────────────────────────────────────────
   Softec spaces sections with fixed utility classes (pt-110, pb-185 …) that
   are the same on a phone as on a 1440px screen. Scale the large ones down
   instead of overriding each section: ~75% on tablet, ~55% on mobile, with
   a floor so sections never touch. Smaller utilities are left alone. */
@media (max-width: 991.98px) {
    .pt-80  { padding-top: 60px; }   .pb-80  { padding-bottom: 60px; }
    .pt-90  { padding-top: 68px; }   .pb-90  { padding-bottom: 68px; }
    .pt-100 { padding-top: 75px; }   .pb-100 { padding-bottom: 75px; }
    .pt-110 { padding-top: 80px; }   .pb-110 { padding-bottom: 80px; }
    .pt-120 { padding-top: 88px; }   .pb-120 { padding-bottom: 88px; }
    .pt-130 { padding-top: 96px; }   .pb-130 { padding-bottom: 96px; }
    .pt-140 { padding-top: 100px; }  .pb-140 { padding-bottom: 100px; }
    .pt-175 { padding-top: 110px; }  .pb-185 { padding-bottom: 110px; }
}
@media (max-width: 767.98px) {
    .pt-80  { padding-top: 44px; }   .pb-80  { padding-bottom: 44px; }
    .pt-90  { padding-top: 48px; }   .pb-90  { padding-bottom: 48px; }
    .pt-100 { padding-top: 52px; }   .pb-100 { padding-bottom: 52px; }
    .pt-110 { padding-top: 56px; }   .pb-110 { padding-bottom: 56px; }
    .pt-120 { padding-top: 60px; }   .pb-120 { padding-bottom: 60px; }
    .pt-130 { padding-top: 64px; }   .pb-130 { padding-bottom: 64px; }
    .pt-140 { padding-top: 64px; }   .pb-140 { padding-bottom: 64px; }
    .pt-175 { padding-top: 64px; }   .pb-185 { padding-bottom: 64px; }
    .mb-50  { margin-bottom: 32px; } .mb-60  { margin-bottom: 36px; }
    .mb-70  { margin-bottom: 40px; } .mb-80  { margin-bottom: 44px; }
    .mt-50  { margin-top: 32px; }    .mt-60  { margin-top: 36px; }
    .tp-counter-space { padding-bottom: 48px; }
    .tp-sales-space { padding-top: 0; padding-bottom: 56px; }
}
@media (max-width: 575.98px) {
    .container,
    .container-fluid { padding-inline: var(--bz-gutter); }
}

/* ── 4. Header ─────────────────────────────────────────────────────────── */
@media (max-width: 991.98px) {
    .header__space { padding-block: 0; }
    #header-sticky .row { min-height: var(--bz-header-h); }
    .boosla-logo-chip--header { height: auto; }
    .boosla-logo-chip--header .boosla-logo-chip__img { height: clamp(32px, 2vw + 26px, 44px); }
    /* 44px: comfortable touch target without dominating the bar. */
    .header-bottom__bar { width: 44px; height: 44px; line-height: 44px; font-size: 17px; }
}

/* Mobile drawer: never wider than the screen, closable within reach. */
@media (max-width: 767.98px) {
    .tpoffcanvas { width: min(320px, 88vw); padding: 28px 24px; }
    .tpoffcanvas__logo { margin-bottom: 24px; }
    .boosla-logo-chip--offcanvas { height: auto; }
    .boosla-logo-chip--offcanvas .boosla-logo-chip__img { height: 72px; }
    .tpoffcanvas__close-btn button { width: 44px; height: 44px; }
}

/* Drawer content (all widths the drawer is used at). */
.tpoffcanvas__close-btn button {
    display: grid;
    place-items: center;
    background: transparent;
    color: #fff;
    border-radius: 12px;
}
.tpoffcanvas__close-btn button:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.tpoffcanvas .mean-container .mean-nav ul li a { text-align: start; font-size: 15px; padding-block: 13px; }
.boosla-drawer-cta { display: grid; gap: 10px; margin: 24px 0 32px; }
.boosla-drawer-cta a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    border-radius: 999px;
    font-weight: 800;
    font-size: 15px;
    text-decoration: none;
}
.boosla-drawer-cta__primary { background: #1d54f8; color: #fff; }
.boosla-drawer-cta__primary:hover { background: #1640c4; color: #fff; }
.boosla-drawer-cta__secondary { border: 1.5px solid rgba(255, 255, 255, .35); color: #fff; }
.boosla-drawer-cta__secondary:hover { border-color: #fff; color: #fff; }

/* ── 5. Homepage hero ──────────────────────────────────────────────────── */
@media (max-width: 991.98px) {
    .tp-hero-area.tp-hero-pt { padding-top: calc(var(--bz-header-h) + clamp(28px, 4vw + 12px, 48px)); }
    .tp-hero-title-3.pb-5 { padding-bottom: .5rem !important; }
    .tp-hero-title-3 i i.child-1 { margin-bottom: 0; }
    /* The title's two lines are inline-block reveal wrappers; aligned to the
       baseline they pick up an extra strut gap between lines. */
    .tp-hero-title-3 > i { vertical-align: top; }
    .tp-hero-title-box p { margin-top: .25rem; padding-bottom: 0; max-width: 34rem; }
    /* The desktop line break would strand a single word on tablet widths. */
    .tp-hero-title-box p br { display: none; }
    .tp-hero-btn-3 { margin-top: clamp(20px, 3vw + 12px, 28px); margin-bottom: 0; }
    .tp-hero-3-wrapper { margin-top: clamp(28px, 4vw + 14px, 40px); }
    /* Decorative curves stay, but lighter and scaled so they sit behind
       the text rather than competing with it. */
    .tp-hero-left-shape { opacity: .45; }
    .tp-hero-left-shape img { max-width: 70vw; }
}
@media (max-width: 575.98px) {
    /* Stack the two CTAs as near-full-width buttons. */
    .tp-hero-btn-3 {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        max-width: 22rem;
        margin-inline: auto;
    }
    .tp-hero-btn-3 a { margin: 0; text-align: center; }
    .tp-hero-area.pb-70 { padding-bottom: 40px; }
}

/* ── 6. Homepage sections ──────────────────────────────────────────────── */
@media (max-width: 767.98px) {
    /* Counters: one compact band of three instead of three stacked tiles. */
    .tp-counter-wrapper { border-radius: 24px; }
    .tp-counter-wrapper .row > [class*="col-"] { flex: 0 0 33.333%; max-width: 33.333%; }
    .tp-counter-wrap { padding: 20px 6px; margin-bottom: 0; }
    .tp-counter-item h4 { font-size: 28px; line-height: 1.2; }
    .tp-counter-item p,
    .tp-counter-item span:not(.purecounter) { font-size: 12px; line-height: 1.5; }

    /* Capability cards: size to their content, not a desktop min-height. */
    .tp-service-sm-item { min-height: 0; padding: 28px 24px; }

    /* Value band: fixed 980px desktop height becomes content height. */
    .tp-rated-bg { height: auto; margin-inline: 0; border-radius: 28px; }
    .author-rated-wrapper { padding-inline: 0; padding-bottom: 8px; }
    .author-rated { margin-bottom: 8px; }
    .author-rated p { font-size: 17px; line-height: 1.65; }
    .tp-rated-title-box .pb-40 { padding-bottom: 24px; }
    .tp-testimonial-3-bg { border-radius: 28px; }
    .tp-testimonial-3-mlr { margin-inline: 0; }
    /* rtl.css mirrors the desktop 60px quote indent to the left and the
       template only resets the right one on mobile — reset both sides. */
    .tp-testimonial-3-content-box p { padding-inline: 0; font-size: 17px; line-height: 1.7; }
    .tp-testimonial-3-item { padding: 22px; }
    .tp-testimonial-3-section-box { margin-bottom: 28px; }
}

/* ── 7. Pricing ────────────────────────────────────────────────────────── */
@media (max-width: 767.98px) {
    .boosla-pricing { padding: 44px 0 36px; }
}
@media (max-width: 991.98px) {
    /* The desktop "lift" would push the popular card past the column edge. */
    .boosla-plan--popular,
    .boosla-plan--popular:hover { transform: none; }
    .boosla-plan { padding: 1.75rem 1.5rem; }
}
@media (max-width: 575.98px) {
    .boosla-pricing__toggle button { padding: .55rem 1rem; }
    .boosla-pricing__toggle .boosla-save-tag { margin-inline-start: .25rem; }
    .boosla-plan__price strong { font-size: 2.4rem; }
}

/* Comparison table: a controlled horizontal scroll on narrow screens, with
   the feature column pinned and a visible hint. Desktop is unchanged. */
.boosla-compare__hint { display: none; }
@media (max-width: 767.98px) {
    .boosla-compare__hint {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: .4rem;
        margin: -.75rem 0 .75rem;
        font-size: .8rem;
        font-weight: 700;
        color: #8894b3;
    }
    .boosla-compare__table { min-width: 32rem; }
    .boosla-compare__table th[scope="row"],
    .boosla-compare__table thead th:first-child {
        position: sticky;
        inset-inline-start: 0;
        z-index: 1;
        background: #fff;
        min-width: 8.5rem;
        max-width: 9.5rem;
        box-shadow: inset -1px 0 0 #f0f2f6;
    }
    .boosla-compare__table thead th:first-child { background: #f7f9fc; }
}

/* ── 8. Inner pages ────────────────────────────────────────────────────── */
@media (max-width: 991.98px) {
    .boosla-inner-hero { padding-top: calc(var(--bz-header-h) + 40px); padding-bottom: 56px; }
}
@media (max-width: 767.98px) {
    .boosla-inner-hero { padding-top: calc(var(--bz-header-h) + 28px); padding-bottom: 40px; }
    .boosla-inner-hero__subtitle { font-size: .95rem; line-height: 1.75; }
}

/* Content sections shared by About / Solutions / Contact / Pricing. */
@media (max-width: 991.98px) {
    .boosla-split { padding-block: clamp(44px, 5vw + 24px, 72px); }
}
@media (max-width: 767.98px) {
    /* Decorative icon panels: keep them, but as a short banner. */
    .boosla-split__art { aspect-ratio: 16 / 7; border-radius: 20px; }
    .boosla-split__art i { font-size: 3rem; }
    .boosla-prose { line-height: 1.85; }
}

/* Legal pages render Markdown; a table there scrolls inside itself rather
   than widening the page. */
.boosla-prose table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    border-collapse: collapse;
    margin: 1.25rem 0;
    font-size: .92rem;
}
.boosla-prose th,
.boosla-prose td { border: 1px solid #e5e7eb; padding: .6rem .85rem; text-align: start; vertical-align: top; }
.boosla-prose th { background: #f7f9fc; font-weight: 800; }

/* ── 9. Footer ─────────────────────────────────────────────────────────── */
@media (max-width: 767.98px) {
    .tp-footer__widget-title { font-size: 18px; padding-bottom: 14px; }
    .tp-footer__area .col-md-6 { padding-bottom: 20px !important; }
}

/* ── 10. Media ─────────────────────────────────────────────────────────── */
.tp-hero-3-main-thumb img,
.boosla-shot { max-width: 100%; height: auto; }
