.color-swatch {
    display: inline-block;
    position: relative;
    vertical-align: middle;

    width: 1em;
    height: 1em;
    margin: 0 0.1em;
    border-radius: 0.1em;

    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.color-swatch:hover {
    transform: scale(1.1);
    box-shadow: 0 0 6px rgba(0, 0, 0, 0.2);
}

.color-swatch::after {
    position: absolute;
    left: 50%;
    bottom: 120%;
    z-index: 10;

    display: block;
    content: attr(data-tooltip);

    padding: 0.5em 0.8em;
    border-radius: 0.1em;
    white-space: nowrap;

    background: #333;
    color: #fff;
    font-size: 0.6em;

    opacity: 0;
    pointer-events: none;

    transition: opacity 0.3s ease;
    transform: translateX(-50%);
}

.color-swatch:hover::after {
    opacity: 1;
}

/* Toast container */
.toast-container {
    position: fixed;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5em;
}

/* Individual toast */
.copied-toast {
    background: #2ecc71;
    color: white;
    padding: 0.75em 1.25em 1.25em;
    border-radius: 0.5em;
    font-size: 1em;
    min-width: 220px;
    text-align: center;
    position: relative;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.copied-toast .close-toast {
    position: absolute;
    top: 0.3em;
    left: 50%;
    transform: translateX(-50%);
    font-weight: bold;
    font-size: 1.2em;
    line-height: 1;
    cursor: pointer;
    user-select: none;
}