/* =========================================================
   "What makes us the right partner" — hybrid app development page.
   Three columns: process artwork, a reason picker, and the copy for whichever
   reason is selected. Scoped under .hb-why so it can't touch the shared
   service-page styles.
   ========================================================= */

.hb-why {
    /* Extra bottom padding: the "Our Technology Stack" section below uses pt-0,
       so the space before its heading comes entirely from here. */
    padding: 70px 0 110px;
    background: #fff;
}

/* The section above (why_hire_section.common_spacing) carries a large bottom
   spacing — padding:70px 0 150px + margin-bottom:50px — from the shared service
   template, which left the heading floating in a big white gap. Pull this section
   up on desktop to absorb that excess. (Only over empty padding/margin, so there's
   no overlap with the previous section's content.) */
@media (min-width: 992px) {
    .hb-why {
        margin-top: 0;
    }

    /* When two hb-why sections stack (process + "why us"), the second one must
       NOT pull up into the first — that negative margin only exists to absorb
       the shared template section further above. Use padding (not margin) for
       the gap so the section's white background fills it — a transparent margin
       would let the page's off-white background show through as a faint band. */
    .hb-why + .hb-why {
        margin-top: 0;
        padding-top: 40px;
    }
}

/* Title and CTA share a row, but the CTA drops to the title's baseline area
   rather than stretching with it. */
.hb-why__head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
}

.hb-why__title {
    max-width: 760px;
    margin: 0;
    color: #0b1220;
    font-size: 2.25rem;
    font-weight: 800;
    line-height: 1.28;
    letter-spacing: -.01em;
}

/* Forces the Figma two-line break (…the Right / Hybrid App Development Partner)
   at desktop; dropped below 991px so the heading wraps naturally on narrow screens. */
.hb-why__brk {
    display: inline;
}

.hb-why__title span {
    color: #1431cf;
}

.hb-why__cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    padding: 13px 24px;
    border: 1px solid #dfe3ec;
    border-radius: 999px;
    background: #fff;
    color: #0b1220;
    font-size: .9375rem;
    font-weight: 500;
    text-decoration: none;
    transition: border-color .2s ease, box-shadow .2s ease, color .2s ease;
}

.hb-why__cta:hover {
    border-color: #1431cf;
    color: #1431cf;
    box-shadow: 0 6px 18px rgba(20, 49, 207, .12);
}

.hb-why__cta svg {
    width: 14px;
    height: 14px;
}

.hb-why__lead {
    max-width: 760px;
    margin: 18px 0 0;
    color: #5a6480;
    font-size: .9375rem;
    line-height: 1.75;
}

.hb-why__grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr) minmax(0, .9fr);
    gap: 40px;
    align-items: start;
    margin-top: 36px;
}

.hb-why__media img {
    width: 100%;
    height: auto;
    border-radius: 12px;
}

/* Keep the artwork in view while the reader scrolls through the step list.
   Only on the 3-column layout; below 1200px the media spans full width above
   the picker (see the max-width:1199px block), where sticky has no effect. */
@media (min-width: 1200px) {
    .hb-why__media {
        position: sticky;
        top: 100px;
    }
}

/* ---------- Reason picker ---------- */

.hb-why__list {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hb-why__item {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    width: 100%;
    padding: 16px 18px;
    border: 1px solid #e6e9f0;
    border-radius: 10px;
    background: #fff;
    color: #3d4762;
    font-size: .8125rem;
    font-weight: 500;
    line-height: 1.4;
    text-align: left;
    cursor: pointer;
    transition: border-color .2s ease, box-shadow .2s ease, color .2s ease;
}

.hb-why__item:hover {
    border-color: #c9d2e8;
}

/* Selected row: darker label, a blue edge marking the active choice, and the
   plain arrow swapped for a filled one. */
.hb-why__item.is-active {
    color: #0b1220;
    font-weight: 700;
    box-shadow: 0 6px 20px rgba(11, 18, 32, .07);
}

.hb-why__item.is-active::after {
    content: "";
    position: absolute;
    top: 6px;
    right: -1px;
    bottom: 6px;
    width: 3px;
    border-radius: 3px;
    background: #1431cf;
}

.hb-why__arrow {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    color: #6b7590;
    transition: background-color .2s ease, color .2s ease;
}

.hb-why__arrow svg {
    width: 14px;
    height: 14px;
}

.hb-why__item.is-active .hb-why__arrow {
    background: #1431cf;
    color: #fff;
}

/* ---------- Copy for the selected reason ---------- */

.hb-why__panel {
    margin: 0;
    color: #5a6480;
    font-size: .9375rem;
    line-height: 1.75;
}

.hb-why__panel[hidden] {
    display: none;
}

/* ---------- Responsive ---------- */

@media (max-width: 1199px) {
    .hb-why__grid {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 30px;
    }

    /* The artwork spans the full width above the picker and its copy. */
    .hb-why__media {
        grid-column: 1 / -1;
        max-width: 560px;
    }
}

@media (max-width: 991px) {
    .hb-why {
        padding: 50px 0;
    }

    .hb-why__head {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .hb-why__title {
        max-width: none;
        font-size: 1.75rem;
    }

    .hb-why__brk {
        display: none;
    }
}

@media (max-width: 767px) {
    .hb-why__grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .hb-why__title {
        font-size: 1.5rem;
    }

    .hb-why__media {
        max-width: none;
    }
}
