/* ==========================================================================
   Why FG Safety - alternating "reasons" rows
   Every row is a two column flex: thumb + content, mirrored on even rows.
   The thumb keeps a fixed 1/1 box (object-fit: cover), so any image the
   client drops into img/why/ keeps the same layout on every screen.
   ========================================================================== */
.why-fg-area {
    background-color: var(--white);
    padding-top: 120px;
    padding-bottom: 130px;
    position: relative;
    overflow: hidden;
}

@media only screen and (max-width: 1399px) {
    .why-fg-area {
        padding-top: 100px;
        padding-bottom: 100px;
    }
}

@media only screen and (max-width: 991px) {
    .why-fg-area {
        padding-top: 80px;
        padding-bottom: 80px;
    }
}

@media only screen and (max-width: 767px) {
    .why-fg-area {
        padding-top: 60px;
        padding-bottom: 60px;
    }
}

/* ---------- section intro: shared .hp-section heading (custom.css) ---------- */

/* ---------- row ---------- */
.why-fg-list {
    display: flex;
    flex-direction: column;
    gap: 130px;
}

@media only screen and (max-width: 1399px) {
    .why-fg-list {
        gap: 110px;
    }
}

@media only screen and (max-width: 1199px) {
    .why-fg-list {
        gap: 90px;
    }
}

@media only screen and (max-width: 991px) {
    .why-fg-list {
        gap: 70px;
    }
}

@media only screen and (max-width: 767px) {
    .why-fg-list {
        gap: 60px;
    }
}

.why-fg-row {
    display: flex;
    align-items: center;
    gap: 100px;
}

@media only screen and (max-width: 1399px) {
    .why-fg-row {
        gap: 70px;
    }
}

@media only screen and (max-width: 1199px) {
    .why-fg-row {
        gap: 50px;
    }
}

/* every second reason mirrors: image on the end side */
.why-fg-row.is-reverse {
    flex-direction: row-reverse;
}

@media only screen and (max-width: 991px) {

    .why-fg-row,
    .why-fg-row.is-reverse {
        flex-direction: column;
        align-items: stretch;
        gap: 40px;
    }
}

/* ---------- thumb ---------- */
.why-fg-thumb {
    flex: 1 1 48%;
    min-width: 0;
    position: relative;
    z-index: 1;
}

@media only screen and (max-width: 991px) {
    .why-fg-thumb {
        flex: 1 1 auto;
        max-width: 520px;
        width: 100%;
        margin-inline: auto;
    }
}

.why-fg-thumb-inner {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 28px;
    overflow: hidden;
    background-color: var(--fg-tint);
    box-shadow: 0 24px 60px rgba(34, 46, 71, 0.16);
    z-index: 2;
}

@media only screen and (max-width: 767px) {
    .why-fg-thumb-inner {
        border-radius: 20px;
    }
}

.why-fg-thumb-inner img {
    display: block;
    width: 100%;
    height: 100%;
    -o-object-fit: cover;
    object-fit: cover;
    -o-object-position: center;
    object-position: center;
}

/* solid amber block, tucked behind the top/start corner */
.why-fg-thumb .why-fg-shape-solid {
    position: absolute;
    top: -34px;
    inset-inline-start: -34px;
    width: 46%;
    aspect-ratio: 1 / 1;
    max-height: 270px;
    background-color: var(--fg-amber);
    border-radius: 22px;
    z-index: 1;
}

/* outlined amber block, peeking out of the bottom/end corner */
.why-fg-thumb .why-fg-shape-outline {
    position: absolute;
    bottom: -34px;
    inset-inline-end: -34px;
    width: 46%;
    aspect-ratio: 1 / 1;
    max-height: 270px;
    border: 3px solid var(--fg-amber);
    border-radius: 22px;
    z-index: 1;
}

/* narrower gutters at this width: pull the blocks in so they never graze the viewport edge */
@media only screen and (max-width: 1399px) {

    .why-fg-thumb .why-fg-shape-solid,
    .why-fg-thumb .why-fg-shape-outline {
        top: -24px;
        bottom: -24px;
        inset-inline-start: -24px;
        inset-inline-end: -24px;
    }

    .why-fg-thumb .why-fg-shape-solid {
        bottom: auto;
        inset-inline-end: auto;
    }

    .why-fg-thumb .why-fg-shape-outline {
        top: auto;
        inset-inline-start: auto;
    }
}

@media only screen and (max-width: 767px) {

    .why-fg-thumb .why-fg-shape-solid,
    .why-fg-thumb .why-fg-shape-outline {
        top: -10px;
        bottom: -10px;
        inset-inline-start: -10px;
        inset-inline-end: -10px;
        border-radius: 16px;
    }

    .why-fg-thumb .why-fg-shape-solid {
        bottom: auto;
        inset-inline-end: auto;
    }

    .why-fg-thumb .why-fg-shape-outline {
        top: auto;
        inset-inline-start: auto;
        border-width: 2px;
    }
}

/* dotted grid, opposite corner from the solid block */
.why-fg-thumb .why-fg-shape-dots {
    position: absolute;
    top: -6px;
    inset-inline-end: -58px;
    width: 120px;
    height: 78px;
    background-image: radial-gradient(var(--fg-line) 2.2px, transparent 2.2px);
    background-size: 15px 15px;
    z-index: 0;
}

/* mirrored rows keep the dots on the gap side, never against the viewport edge */
.why-fg-row.is-reverse .why-fg-thumb .why-fg-shape-dots {
    top: auto;
    bottom: -6px;
    inset-inline-start: -58px;
    inset-inline-end: auto;
}

@media only screen and (max-width: 1199px) {
    .why-fg-thumb .why-fg-shape-dots {
        display: none;
    }
}

/* ---------- content ---------- */
.why-fg-content {
    flex: 1 1 52%;
    min-width: 0;
}

@media only screen and (max-width: 991px) {
    .why-fg-content {
        flex: 1 1 auto;
    }
}

.why-fg-content .why-fg-title {
    font-size: 44px;
    font-weight: 700;
    line-height: 1.12;
    color: var(--fg-navy);
    margin-bottom: 24px;
    text-transform: capitalize;
    font-family: 'gallery_modernregular';
    letter-spacing: 3px;
}

@media only screen and (max-width: 1399px) {
    .why-fg-content .why-fg-title {
        font-size: 40px;
    }
}

@media only screen and (max-width: 1199px) {
    .why-fg-content .why-fg-title {
        font-size: 34px;
    }
}

@media only screen and (max-width: 767px) {
    .why-fg-content .why-fg-title {
        font-size: 28px;
        margin-bottom: 18px;
    }
}

/* second line of the heading carries the amber accent */
.why-fg-content .why-fg-title span {
    display: block;
    color: var(--fg-amber);
}

.why-fg-content .why-fg-text {
    font-size: 17px;
    font-weight: 400;
    line-height: 1.68;
    color: var(--fg-navy);
    opacity: 0.78;
    margin-bottom: 34px;
}

/* last paragraph carries no trailing space, so the column stays optically centred */
.why-fg-content .why-fg-text:last-child {
    margin-bottom: 0;
}

@media only screen and (max-width: 767px) {
    .why-fg-content .why-fg-text {
        font-size: 16px;
        margin-bottom: 26px;
    }
}
