/* empty state (partials/empty): nothing found / nothing to show, on every list page */

.empty-state {
    --es-brand: var(--primary-color, #3b82f6);
    --es-text: #1f2328;
    --es-text-2: #5b616b;
    --es-text-3: #8a9099;
    --es-bg: #f5f6f8;
    --es-border: #e8eaee;

    clear: both;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0 0 16px;
    padding: 40px 20px 36px;
    text-align: center;
    background: #fff;
    border: 1px solid var(--es-border);
    border-radius: 24px;
}

@supports (background: color-mix(in srgb, red 10%, white)) {
    .empty-state {
        --es-brand-soft: color-mix(in srgb, var(--es-brand) 10%, #fff);
    }
}

/* the picture: an icon on a soft disc, with a slow halo */
.empty-state__art {
    position: relative;
    width: 96px;
    height: 96px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--es-brand-soft, #eef4ff);
    color: var(--es-brand);
    font-size: 44px;
}

.empty-state__art .mdi {
    position: relative;
    z-index: 1;
    line-height: 1;
}

.empty-state__halo {
    position: absolute;
    inset: -10px;
    border: 1px dashed color-mix(in srgb, var(--es-brand) 30%, transparent);
    border-radius: 50%;
    animation: empty-state-turn 24s linear infinite;
    will-change: transform;
}

@keyframes empty-state-turn {
    to {
        transform: rotate(360deg);
    }
}

.empty-state__title {
    max-width: 520px;
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 800;
    line-height: 1.7;
    color: var(--es-text);
    overflow-wrap: anywhere;
}

.empty-state__text {
    max-width: 480px;
    margin: 0;
    font-size: 13.5px;
    line-height: 2;
    color: var(--es-text-2);
}

/* search again */
.empty-state__search {
    position: relative;
    width: 100%;
    max-width: 440px;
    margin-top: 20px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px;
    background: var(--es-bg);
    border: 1px solid transparent;
    border-radius: 14px;
    transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.empty-state__search:focus-within {
    background: #fff;
    border-color: var(--es-brand);
    box-shadow: 0 0 0 4px var(--es-brand-soft, #eef4ff);
}

.empty-state__search > .mdi {
    flex: none;
    margin-right: 8px;
    font-size: 20px;
    color: var(--es-text-3);
}

.empty-state__search input {
    flex: 1 1 auto;
    min-width: 0;
    height: 38px;
    padding: 0 4px;
    font: inherit;
    font-size: 14px;
    color: var(--es-text);
    background: transparent;
    border: 0;
    outline: 0;
}

.empty-state__search input::-webkit-search-cancel-button {
    display: none;
}

.empty-state__search button {
    flex: none;
    height: 38px;
    padding: 0 18px;
    font: inherit;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    background: var(--es-brand);
    border: 0;
    border-radius: 10px;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.empty-state__search button:hover {
    opacity: 0.9;
}

/* suggestions */
.empty-state__tips {
    width: 100%;
    max-width: 440px;
    margin: 18px 0 0;
    padding: 12px 14px;
    display: grid;
    gap: 6px;
    list-style: none;
    text-align: right;
    background: var(--es-bg);
    border-radius: 14px;
}

.empty-state__tips li {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 12.5px;
    line-height: 1.9;
    color: var(--es-text-2);
}

.empty-state__tips .mdi {
    flex: none;
    margin-top: 2px;
    font-size: 16px;
    color: #e5a50a;
}

/* links */
.empty-state__actions {
    margin-top: 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

.empty-state__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 42px;
    padding: 0 18px;
    font-size: 13px;
    font-weight: 700;
    color: var(--es-text);
    background: #fff;
    border: 1px solid var(--es-border);
    border-radius: 12px;
    transition: border-color 0.2s ease, color 0.2s ease, background-color 0.2s ease;
}

/* style.css has a global `a:hover { border: none }`: the outlined button keeps its border */
.empty-state__btn:hover {
    color: var(--es-brand);
    border: 1px solid var(--es-brand);
}

.empty-state__btn.is-primary {
    color: #fff;
    background: var(--es-brand);
    border-color: var(--es-brand);
}

.empty-state__btn.is-primary:hover {
    color: #fff;
    opacity: 0.92;
}

.empty-state__btn .mdi {
    font-size: 18px;
}

@media (max-width: 575.98px) {
    .empty-state {
        padding: 30px 14px 26px;
        border-radius: 18px;
    }

    .empty-state__art {
        width: 80px;
        height: 80px;
        font-size: 36px;
    }

    .empty-state__title {
        font-size: 16px;
    }

    .empty-state__actions {
        width: 100%;
    }

    .empty-state__btn {
        flex: 1 1 0;
        justify-content: center;
        padding: 0 10px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .empty-state__halo {
        animation: none;
    }
}
