/* File artwork used until application artwork is available. */
.block-down__file-icon {
    box-sizing: border-box;
    display: flex;
    flex: 0 0 69px;
    height: 69px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    overflow: hidden;
    border: 1px solid #d1e4d5;
    border-radius: 14px;
    background: #edf6ee;
    color: #16833b;
}

.block-down__file-icon svg {
    display: block;
    width: 28px;
    height: 28px;
    flex-shrink: 0;
}

.block-down__file-extension {
    box-sizing: border-box;
    display: block;
    max-width: 100%;
    padding: 0 6px;
    overflow: hidden;
    font: 700 11px/14px Arial, sans-serif;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    text-overflow: ellipsis;
    white-space: nowrap;
}

[theme="dark"] .block-down__file-icon {
    border-color: #304b36;
    background: #19281d;
    color: #63c574;
}

/* Shared by both themes and by buttons inserted after the download check. */
.b-download__body .b-download__button {
    --download-icon-color: #0ba40b;
    --download-icon-surface: rgba(11, 164, 11, 0.1);
    --download-icon: url("../img/icons/download-action.svg");
    box-sizing: border-box;
    min-height: 66px;
    align-items: center;
    gap: 12px;
    padding: 18px 20px 18px 72px;
    text-align: left;
}

.b-download__body .b-download__button::before,
.b-download__body .b-download__button::after {
    content: "";
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
}

.b-download__body .b-download__button::before {
    left: 18px;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--download-icon-surface);
}

.b-download__body .b-download__button::after {
    left: 26px;
    width: 22px;
    height: 22px;
    background: var(--download-icon-color);
    -webkit-mask: var(--download-icon) center / contain no-repeat;
    mask: var(--download-icon) center / contain no-repeat;
}

.b-download__body .b-download__button_icon_tg,
.b-download__body .b-download__button_icon_tg-load {
    --download-icon: url("../img/icons/telegram-action.svg");
}

/* Partner banners can still contain the previous inline download SVG. */
.b-download__body .b-download__button .bi-download {
    display: none;
}

.b-download__body .b-download__button .download-size {
    flex-shrink: 0;
    white-space: nowrap;
}

.b-download__body .b-download__button:hover,
.b-download__body .b-download__button:focus-visible {
    --download-icon-color: #fff;
    --download-icon-surface: rgba(255, 255, 255, 0.16);
}

.b-download__body .b-download__button:focus-visible {
    outline: 2px solid #0ba40b;
    outline-offset: 3px;
    color: #f2f2f2;
    background: #0ba40b;
    border-color: #0ba40b;
}
