/* =========================
   BLOCKS LIST
   Dark red section: small icon on the left, name + text on the right.
========================= */

.blocks {
    --blocks-bg: #40110F;
    --blocks-text: rgba(255, 255, 255, 0.55);

    /* pixel border between the brown cards section and this red section.
       border2.png is 4096x483 (32px blocks); --edge-scale sets the block size:
       0.25 = 8px blocks, 0.4375 = 14px blocks */
    --edge-scale: 0.25;
    --edge-h: calc(483px * var(--edge-scale));

    position: relative;
    padding: calc(var(--edge-h) + 8px) 24px 56px;
    background: var(--blocks-bg);
    color: #fff;
}

.blocks::before {
    content: "";
    position: absolute;
    top: -1px;
    left: 0;
    right: 0;
    height: var(--edge-h);

    background: url("../img/border2.png") repeat-x center top;
    background-size: calc(4096px * var(--edge-scale)) var(--edge-h);
    image-rendering: pixelated;
    pointer-events: none;
}

.blocks-title {
    max-width: 320px;
    margin: 0 auto;

    font-family: "Texureon", Arial, sans-serif;
    font-size: 32px;
    font-weight: 400;
    line-height: 1.25;
    letter-spacing: 1px;
    text-align: center;
    text-transform: uppercase;
}

.blocks-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 44px;

    width: 100%;
    max-width: 1200px;
    margin: 48px auto 0;
}

.block-item {
    display: grid;
    grid-template-columns: 84px 1fr;
    column-gap: 24px;
    align-items: start;
}

.block-item-img {
    width: 84px;
    height: 84px;
    margin-top: 6px;
    object-fit: contain;
}

.block-item-title {
    font-size: 24px;
    font-weight: 600;
    line-height: 1.2;
}

.block-item-text {
    margin-top: 12px;
    color: var(--blocks-text);
    font-size: 18px;
    line-height: 1.55;
}

@media (min-width: 701px) {
    .blocks {
        --edge-scale: 0.4375;
        padding: calc(var(--edge-h) + 16px) 30px 88px;
    }

    .blocks-title {
        max-width: none;
        font-size: 44px;
    }

    .blocks-list {
        grid-template-columns: repeat(3, 1fr);
        gap: 40px;
        margin-top: 64px;
    }

    .block-item {
        align-self: start;
        align-content: start;
        grid-template-columns: 1fr;
        row-gap: 20px;
        justify-items: center;
        text-align: center;
    }

    .block-item-img {
        width: 120px;
        height: 120px;
        margin-top: 0;
    }
}
