#back-to-top {
    position: fixed;
    right: calc(16px + env(safe-area-inset-right, 0px));
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    z-index: 40;
    display: grid;
    place-items: center;
    box-sizing: border-box;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 1px solid #64748b;
    border-radius: 50%;
    background: #1e293b;
    color: #fff;
    font: 600 22px/1 system-ui, sans-serif;
    cursor: pointer;
}

#back-to-top[hidden] {
    display: none;
}

#back-to-top:hover {
    background: #334155;
}

#back-to-top:focus-visible {
    outline: 2px solid #38bdf8;
    outline-offset: 2px;
}
