/* How it works page, third section (template-parts/hiw/provides.php, docs/sections/hiw/hiw-waht-amerlink-provides.png).
   Fonts and --amh-* colours: home-hero.css (body .amerlink-genesis-home). --hiw-provides-campus: inline style of
   Amerlink_Genesis_Hiw_Provides::enqueue_assets(). */

.hiw-provides {
    --hiw-provides-gap: clamp(48px, 4.2vw, 72px);
    position: relative;
    overflow: hidden;
    padding: clamp(56px, 5vw, 96px) 0 clamp(64px, 5.5vw, 104px);
    background:
        radial-gradient(ellipse 60% 70% at 85% 0%, rgba(43, 98, 178, .5) 0%, rgba(43, 98, 178, 0) 70%),
        linear-gradient(180deg, #0b2d64 0%, #082656 55%, #071f49 100%);
    color: #fff;
    isolation: isolate;
}

/* The campus of the design, faint in the top corner. */
.hiw-provides::before {
    position: absolute;
    z-index: -1;
    top: 0;
    right: 0;
    width: min(36%, 640px);
    aspect-ratio: 377 / 250;
    background: var(--hiw-provides-campus, none) center / cover no-repeat;
    content: '';
    opacity: .7;
    -webkit-mask-image: radial-gradient(ellipse 75% 85% at 70% 25%, #000 35%, transparent 80%);
    mask-image: radial-gradient(ellipse 75% 85% at 70% 25%, #000 35%, transparent 80%);
}

/* "More / Opportunities / Ahead", as in the design. */
.hiw-provides-handwritten {
    position: absolute;
    top: clamp(36px, 3.4vw, 64px);
    right: 4.5%;
    margin: 0;
    color: #fff;
    font-family: 'Segoe Print', 'Bradley Hand', cursive;
    font-size: clamp(22px, 1.9vw, 36px);
    font-style: italic;
    line-height: 1.2;
    transform: rotate(-10deg);
}

.hiw-provides-handwritten::after {
    display: block;
    width: 80%;
    height: 3px;
    margin: 10px 0 0 auto;
    border-radius: 3px;
    background: var(--amh-pink);
    content: '';
    transform: rotate(-6deg);
}

.hiw-provides-inner {
    position: relative;
    width: min(100% - 64px, 1510px);
    margin-inline: auto;
}

/* Up to where the note starts on wide screens (it stands in the page margin and a little over the content). */
.hiw-provides-header {
    max-width: 1356px;
}

.hiw-provides-eyebrow {
    margin: 0 0 clamp(8px, .7vw, 12px);
    color: var(--amh-pink);
    font-size: clamp(13px, 1vw, 17px);
    font-weight: 800;
    letter-spacing: .16em;
    line-height: 1.3;
    text-transform: uppercase;
}

.hiw-provides-title {
    margin: 0 0 clamp(12px, 1vw, 18px);
    padding: 0;
    color: #fff;
    font-family: inherit;
    font-size: clamp(28px, 2.4vw, 46px);
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.12;
}

.hiw-provides-description {
    max-width: 900px;
    margin: 0;
    color: rgba(255, 255, 255, .9);
    font-size: clamp(16px, 1.2vw, 21px);
    line-height: 1.5;
}

.hiw-provides-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--hiw-provides-gap);
    margin: clamp(28px, 2.6vw, 44px) 0 0;
    padding: 0;
    list-style: none;
}

.hiw-provides-card {
    position: relative;
    display: flex;
    min-width: 0;
    flex-direction: column;
    border-radius: 16px;
    background: #f3f8fe;
    box-shadow: 0 18px 44px rgba(0, 10, 40, .32);
}

/* The arrow in the gap before every card but the first (an element, so that it can grow under the pointer:
 * assets/css/hiw-motion.css). */
.hiw-provides-arrow {
    position: absolute;
    top: clamp(64px, 5.4vw, 100px);
    left: calc(var(--hiw-provides-gap) / -2);
    color: #fff;
    font-family: Arial, sans-serif;
    font-size: clamp(28px, 2.4vw, 44px);
    line-height: 1;
    translate: -50% -50%;
}

.hiw-provides-card-head {
    display: flex;
    flex: 1 1 auto;
    align-items: flex-start;
    gap: clamp(14px, 1.2vw, 20px);
    padding: clamp(18px, 1.5vw, 26px);
}

.hiw-provides-icon {
    display: grid;
    width: clamp(60px, 4.6vw, 84px);
    flex: 0 0 auto;
    aspect-ratio: 1;
    place-items: center;
    border-radius: 50%;
    background: #fbe7f0;
    color: var(--amh-pink);
}

.hiw-provides-icon svg {
    width: 52%;
    height: 52%;
}

.hiw-provides-card-copy {
    min-width: 0;
}

.hiw-provides-card-title {
    margin: 0 0 8px;
    padding: 0;
    color: var(--amh-navy);
    font-family: inherit;
    font-size: clamp(19px, 1.4vw, 23px);
    font-weight: 800;
    letter-spacing: -.015em;
    line-height: 1.2;
}

.hiw-provides-card-text {
    margin: 0;
    color: #33446a;
    font-size: clamp(15px, 1.05vw, 18px);
    line-height: 1.45;
}

.hiw-provides-photo {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 545 / 279;
    border-radius: 0 0 16px 16px;
    object-fit: cover;
}

/* The note would meet the heading. */
@media (max-width: 1180px) {
    .hiw-provides-handwritten {
        display: none;
    }

    .hiw-provides-header {
        max-width: none;
    }
}

/* Tablets and phones: the cards one under another, the arrows pointing down between them. */
@media (max-width: 1080px) {
    .hiw-provides-cards {
        --hiw-provides-gap: 64px;
        grid-template-columns: minmax(0, 1fr);
        max-width: 680px;
    }

    .hiw-provides-arrow {
        top: calc(var(--hiw-provides-gap) / -2);
        left: 50%;
        rotate: 90deg;
    }
}

@media (max-width: 780px) {
    .hiw-provides-inner {
        width: min(100% - 36px, 660px);
    }

    .hiw-provides::before {
        width: 70%;
        opacity: .5;
    }
}
