.favorite-products {
    margin: 38px 0 34px;
    position: relative;
    scroll-margin-top: 80px;
}

.favorite-products h2 {
    font-weight: normal;
    margin-bottom: 20px;
}

.product-dock {
    display: grid;
    grid-template-columns: repeat(8, 52px);
    gap: 12px;
    width: fit-content;
    max-width: 100%;
    padding: 12px 14px;
    margin: 0 auto;
    list-style: none;
    border: 1px solid rgba(135, 138, 143, 0.2);
    border-radius: 20px;
    background: linear-gradient(165deg, rgba(232, 233, 235, 0.85), rgba(208, 210, 214, 0.72));
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.95), inset 0 -1px 1px rgba(255, 255, 255, 0.45), 0 4px 12px rgba(25, 30, 40, 0.06);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
}

.product-dock-item {
    position: relative;
    width: 52px;
    height: 52px;
}

.product-dock-item.is-active {
    z-index: 2;
}

.bio a.product-dock-icon {
    display: block;
    width: 52px;
    height: 52px;
    border-radius: 12px;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
    transform-origin: center bottom;
    transition: transform 180ms ease;
}

.product-dock-icon img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.14));
}

.product-dock-icon--notion img {
    padding: 6px;
    border-radius: 12px;
    background: #fff;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.06);
    transform: scale(0.923);
}

.product-dock-icon:focus-visible {
    outline: 2px solid #258db7;
    outline-offset: 5px;
}

.product-dock-item.is-active .product-dock-icon {
    transform: translateY(-5px) scale(1.14);
}

.product-popover {
    --popover-shift: 0px;
    --arrow-offset: 0px;
    position: absolute;
    bottom: calc(100% + 24px);
    left: 50%;
    transform: translateX(calc(-50% + var(--popover-shift)));
    width: 244px;
    max-width: calc(100vw - 40px);
    padding: 13px 15px 14px;
    color: #f4f4f5;
    background: rgba(65, 65, 69, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 13px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.16);
    font-size: 0.8rem;
    line-height: 1.5;
    text-align: left;
    -webkit-backdrop-filter: blur(18px);
    backdrop-filter: blur(18px);
}

.product-popover[hidden] {
    display: none;
}

/* Keep the path from the icon to its links hoverable. */
.product-popover::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 26px;
}

.product-popover::after {
    content: '';
    position: absolute;
    top: 100%;
    left: calc(50% + var(--arrow-offset));
    transform: translateX(-50%);
    border: 7px solid transparent;
    border-top-color: rgba(65, 65, 69, 0.96);
}

.product-popover.is-below {
    top: calc(100% + 14px);
    bottom: auto;
}

.product-popover.is-below::before {
    top: auto;
    bottom: 100%;
    height: 16px;
}

.product-popover.is-below::after {
    top: auto;
    bottom: 100%;
    border-top-color: transparent;
    border-bottom-color: rgba(65, 65, 69, 0.96);
}

.bio .product-popover a {
    color: #fff;
    text-underline-offset: 3px;
}

.bio .product-popover a:hover {
    color: #c4e7ff;
}

.bio .product-popover a:focus-visible {
    outline: 2px solid #c4e7ff;
    outline-offset: 3px;
    border-radius: 2px;
}

.bio a.product-popover-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 4px;
    font-weight: 600;
    text-decoration: none;
}

.product-popover-title span {
    color: #c4c4c9;
    font-weight: normal;
}

.product-popover p {
    margin: 0;
    color: #e1e1e5;
}

.product-dock-credit {
    margin-top: 13px;
    color: #888;
    font-size: 0.55rem;
}

.bio .product-dock-credit a {
    color: inherit;
    text-decoration-color: #ccc;
    text-underline-offset: 3px;
}

.bio .product-dock-credit a:hover {
    color: #258db7;
}

@media (max-width: 620px) {
    .product-dock {
        grid-template-columns: repeat(4, 52px);
        gap: 18px;
        padding: 15px;
    }
}

@media (max-width: 360px) {
    .product-dock {
        gap: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .product-dock-icon {
        transition: none;
    }

    .product-dock-item.is-active .product-dock-icon {
        transform: none;
    }
}
