/* Reusable file upload — use <x-ui.file-upload> */

.file-upload {
    position: relative;
}

.file-upload__input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
}

.file-upload__zone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    min-height: 7.5rem;
    padding: 1.25rem 1rem;
    border: 1px dashed color-mix(in srgb, var(--neon) 35%, var(--border));
    border-radius: var(--radius);
    background:
        radial-gradient(circle at top, rgba(0, 212, 255, 0.08), transparent 55%),
        var(--bg-input);
    cursor: pointer;
    text-align: center;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s, transform 0.2s;
}

.file-upload__zone:hover,
.file-upload__zone.is-dragover {
    border-color: var(--neon);
    box-shadow: 0 0 0 3px var(--neon-glow);
    background:
        radial-gradient(circle at top, rgba(0, 212, 255, 0.14), transparent 55%),
        var(--bg-input);
}

.file-upload__zone.is-dragover {
    transform: translateY(-1px);
}

.file-upload__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 999px;
    color: var(--neon);
    background: rgba(0, 212, 255, 0.1);
    box-shadow: 0 0 18px rgba(0, 212, 255, 0.15);
}

.file-upload__icon svg {
    width: 1.35rem;
    height: 1.35rem;
}

.file-upload__title {
    font-size: 0.92rem;
    color: var(--text);
    font-weight: 500;
}

.file-upload__meta {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.file-upload__list {
    list-style: none;
    margin: 0.75rem 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.file-upload__list[hidden] {
    display: none;
}

.file-upload__item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: calc(var(--radius) - 2px);
    background: rgba(0, 212, 255, 0.04);
    font-size: 0.85rem;
    color: var(--text);
}

.file-upload__item-icon {
    flex-shrink: 0;
    width: 1.5rem;
    height: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.35rem;
    background: rgba(0, 212, 255, 0.12);
    color: var(--neon);
    font-size: 0.7rem;
    font-weight: 700;
}

.file-upload__item-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.file-upload__item-size {
    margin-left: auto;
    flex-shrink: 0;
    color: var(--text-muted);
    font-size: 0.78rem;
}
