.home-share {
    position: fixed;
    z-index: 40;
    inset: 50% 12px auto auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 54px;
    padding: 7px 4px 5px;
    transform: translateY(-50%);
    border: 1px solid #e2e4ed;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 8px 26px #11103514;
    color: #111035;
}

.home-share__count {
    display: grid;
    justify-items: center;
    width: 100%;
    padding: 1px 0 7px;
    margin-bottom: 3px;
    border-bottom: 1px solid #e2e4ed;
    line-height: 1.15;
}

.home-share__count strong {
    max-width: 100%;
    overflow: hidden;
    font-size: 17px;
    font-variant-numeric: tabular-nums;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.home-share__count span {
    color: #686b80;
    font-size: 11px;
}

.home-share__action {
    display: grid;
    place-items: center;
    flex: none;
    width: 42px;
    min-height: 40px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: inherit;
    text-decoration: none;
    cursor: pointer;
}

.home-share__action:hover,
.home-share__action[aria-expanded="true"] {
    background: #edf5ef;
}

.home-share__action svg {
    flex: none;
    width: 17px;
    height: 17px;
    fill: currentColor;
}

.home-share__extra { display: contents; }
.home-share__extra strong,
.home-share__extra span,
.home-share__more,
.home-share [hidden] { display: none; }

.home-share__status {
    position: absolute;
    right: calc(100% + 10px);
    bottom: 0;
    width: max-content;
    max-width: 240px;
    margin: 0;
    padding: 8px 12px;
    border-radius: 8px;
    background: #fff;
    color: #111035;
    box-shadow: 0 6px 18px #1110351a;
    font-size: 13px;
}

.home-share__status:empty { opacity: 0; pointer-events: none; }

@media (min-width:721px) and (max-width:1360px) {
    body:has([data-home-share]) .catalog-section { width: calc(100% - 112px); margin-right: 92px; }
}

@media (min-width:721px) and (max-height:375px) {
    .home-share__action { min-height: 32px; }
}

@media (max-width:720px), (pointer:coarse) and (max-width:1024px) {
    body:has([data-home-share]) {
        padding-bottom: calc(59px + env(safe-area-inset-bottom, 0px));
    }

    body:has([data-home-share]) .catalog-section { width: calc(100% - 40px); margin-right: auto; }

    .home-share {
        inset: auto 0 0;
        flex-direction: row;
        justify-content: space-between;
        gap: 2px;
        width: auto;
        padding: 6px max(9px, env(safe-area-inset-right, 0px)) calc(8px + env(safe-area-inset-bottom, 0px)) max(9px, env(safe-area-inset-left, 0px));
        transform: none;
        border-width: 1px 0 0;
        border-radius: 0;
    }

    .home-share__count {
        flex: none;
        width: auto;
        min-width: 48px;
        padding: 0 8px 0 0;
        margin: 0 2px 0 0;
        border-right: 1px solid #e2e4ed;
        border-bottom: 0;
    }

    .home-share__action {
        flex: 1 1 44px;
        width: auto;
        min-width: 44px;
        min-height: 44px;
    }

    .home-share__more:not([hidden]) { display: grid; }
    .home-share__extra { display: none; }

    .home-share[data-share-open] .home-share__extra {
        position: absolute;
        inset: auto 10px calc(100% + 8px) auto;
        display: grid;
        width: min(354px, calc(100% - 20px));
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 2px;
        padding: 11px;
        border: 1px solid #e2e4ed;
        border-radius: 14px;
        background: #fff;
        box-shadow: 0 8px 26px #11103526;
    }

    .home-share__extra strong,
    .home-share__extra span { display: block; }

    .home-share__extra strong {
        grid-column: 1 / -1;
        margin: 0 5px 3px;
        font-size: 13px;
    }

    .home-share__extra .home-share__action {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: 9px;
        padding: 0 7px;
        font-size: 13px;
    }

    .home-share__status {
        right: 10px;
        bottom: calc(100% + 8px);
        max-width: calc(100% - 20px);
    }
}

.home-share__action:focus-visible { outline: 2px solid #247d3e; outline-offset: 2px; }
.home-share__action:hover, .home-share__action[aria-expanded="true"] { color: #247d3e; }
