/* Page Sections - Sitemap (modules/pages/sitemap.php). The search box is in sitemap_hero.css. */

/* The list: cards in three columns (masonry with CSS columns) */
.el-sm-status {
    margin: 0 0 20px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #7c8b99;
}

/* Masonry: sitemap.js puts each card in the shortest column, spanning its height in 1px rows,
   so no column is left short. Without JS: a plain grid. */
.el-sm-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: start;
    column-gap: clamp(16px, 1.6vw, 30px);
}

.el-sm-grid.is-masonry {
    grid-auto-rows: 1px;
}

.el-sm-group {
    margin: 0 0 clamp(16px, 1.6vw, 30px);
    scroll-margin-top: 120px; /* below the floating header when a hero chip scrolls here */
    padding: clamp(26px, 2.2vw, 40px);
    border: 1px solid #e3eaf0;
    border-radius: clamp(24px, 2.2vw, 40px);
    background: var(--el-color-white);
    box-shadow: 0 2px 10px rgba(12, 29, 39, 0.04);
}

.el-sm-group .el-eyebrow {
    margin-bottom: 8px;
}

.el-sm-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e3e7eb;
    font-size: clamp(24px, 1.7vw, 32px);
    line-height: 1.2;
}

.el-sm-count {
    display: grid;
    place-items: center;
    min-width: 30px;
    height: 30px;
    padding: 0 9px;
    border-radius: 999px;
    background: var(--el-color-light);
    font-family: var(--el-font-body);
    font-size: 13px;
    font-weight: 600;
    color: var(--el-color-muted);
}

.el-sm-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.el-sm-item a {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 10px 0 10px 22px;
    color: var(--el-color-blue-dark);
    transition: color var(--el-transition);
}

/* Orange ring before each page, a smaller grey one before child pages */
.el-sm-item a::before {
    content: "";
    position: absolute;
    left: 0;
    top: 1.05em;
    width: 8px;
    height: 8px;
    border: 1.5px solid var(--el-color-orange);
    border-radius: 50%;
    background: transparent;
    transition: background-color var(--el-transition);
}

.el-sm-item.is-child a {
    padding-left: 46px;
}

.el-sm-item.is-child a::before {
    left: 24px;
    width: 6px;
    height: 6px;
    border-color: #b9c6d3;
}

.el-sm-name {
    font-size: 17px;
    font-weight: 500;
    line-height: 1.35;
}

.el-sm-path {
    font-size: 13px;
    line-height: 1.3;
    color: #8a96a2;
    overflow-wrap: anywhere;
}

.el-sm-item a:hover,
.el-sm-item a:focus-visible {
    color: var(--el-color-orange);
}

.el-sm-item a:hover::before,
.el-sm-item a:focus-visible::before {
    background: var(--el-color-orange);
}

.el-sm-item a[aria-current="page"] .el-sm-name::after {
    content: "You are here";
    margin-left: 10px;
    padding: 2px 8px;
    border-radius: 999px;
    background: #fdeee6;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    vertical-align: middle;
    color: var(--el-color-orange);
}

/* A page picked from the hero search: it blinks for 3 seconds (sitemap.js, same as the FAQ search) */
.el-sm-item {
    border-radius: 12px;
    scroll-margin-block: 120px;
}

.el-sm-item.is-blink {
    animation: el-sm-blink 1s ease-in-out 3;
}

@keyframes el-sm-blink {
    0%,
    100% {
        background-color: transparent;
        box-shadow: 0 0 0 0 transparent;
    }

    50% {
        background-color: #fff4ee;
        box-shadow: 0 0 0 8px #fff4ee, 0 0 0 10px rgba(241, 98, 42, 0.45);
    }
}

/* The blink already marks the page, so no focus ring on top of it */
.el-sm-item.is-blink a:focus-visible {
    outline: 0;
}

@media (prefers-reduced-motion: reduce) {
    .el-sm-item.is-blink {
        animation: none;
        background-color: #fff4ee;
        box-shadow: 0 0 0 8px #fff4ee, 0 0 0 10px rgba(241, 98, 42, 0.45);
    }
}

/* Tablet: two columns, a little less room inside the cards. */
@media (max-width: 1199px) {
    .el-sm-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: 20px;
    }

    .el-sm-group {
        margin-bottom: 20px;
        padding: 28px 26px;
        border-radius: 24px;
    }

    .el-sm-title {
        margin-bottom: 14px;
        padding-bottom: 14px;
        font-size: 26px;
    }

    .el-sm-item a {
        padding-block: 8px;
    }

    .el-sm-item.is-child a {
        padding-left: 40px;
    }

    .el-sm-item.is-child a::before {
        left: 20px;
    }
}

/* Phones: one column of compact cards. */
@media (max-width: 767px) {
    .el-sm-status {
        margin-bottom: 14px;
    }

    .el-sm-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .el-sm-group {
        margin-bottom: 16px;
        padding: 22px 20px;
        border-radius: 20px;
    }

    .el-sm-group .el-eyebrow {
        margin-bottom: 4px;
        font-size: 12px;
    }

    .el-sm-title {
        margin-bottom: 8px;
        padding-bottom: 12px;
        font-size: 24px;
    }

    .el-sm-count {
        min-width: 26px;
        height: 26px;
        font-size: 12px;
    }

    .el-sm-item a {
        padding: 7px 0 7px 20px;
    }

    .el-sm-item a::before {
        top: 0.95em;
    }

    .el-sm-item.is-child a {
        padding-left: 36px;
    }

    .el-sm-item.is-child a::before {
        left: 18px;
    }

    .el-sm-name {
        font-size: 16px;
    }

    .el-sm-path {
        font-size: 12px;
    }

    .el-sm-item a[aria-current="page"] .el-sm-name::after {
        margin-left: 6px;
        font-size: 10px;
    }
}
