/* =====================================================
   ILYK — Scroll to top з прогрес-кільцем
   css/scroll-top.css
   ===================================================== */

.ilyk-scroll-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 44px;
    height: 44px;
    border: none;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.12);
    padding: 0;

    /* Прихований за замовчуванням */
    opacity: 0;
    transform: translateY(12px) scale(0.9);
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease, box-shadow 0.2s ease;
}
.ilyk-scroll-top.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}
.ilyk-scroll-top:hover {
    box-shadow: 0 6px 28px rgba(var(--ilyk-clr-primary-rgb), 0.25);
    transform: translateY(-2px) scale(1);
}

/* SVG кільце — абсолютно поверх кнопки */
.ilyk-scroll-top__ring {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    transform: rotate(-90deg); /* старт зверху */
    border-radius: 50%;
}

/* Трек — сіре коло */
.ilyk-scroll-top__track {
    fill: none;
    stroke: rgba(var(--ilyk-clr-primary-rgb), 0.12);
    stroke-width: 2.5;
}

/* Прогрес — синє заповнення */
.ilyk-scroll-top__progress {
    fill: none;
    stroke: var(--ilyk-clr-primary);
    stroke-width: 2.5;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.1s linear;
}

/* Іконка стрілки */
.ilyk-scroll-top__icon {
    font-size: 14px;
    color: #1e293b;
    position: relative;
    z-index: 1;
    transition: transform 0.2s ease, color 0.2s ease;
}
.ilyk-scroll-top:hover .ilyk-scroll-top__icon {
    transform: translateY(-1px);
    color: var(--ilyk-clr-primary);
}

@media (max-width: 580px) {
    .ilyk-scroll-top {
        bottom: 20px;
        right: 20px;
    }
}
