
.elvi-widget {
    max-width: 480px;
    margin: 1.5rem auto;
    border-radius: 1rem;
    padding: 1.25rem 1.5rem;
    box-shadow: 0 14px 30px rgba(0,0,0,0.18);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.elvi-widget:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 40px rgba(0,0,0,0.22);
}

.elvi-widget-dark {
    background: radial-gradient(circle at top left, #1f2933, #050816);
    color: #f9fafb;
}

.elvi-widget-light {
    background: linear-gradient(135deg, #ffffff, #f3f4ff);
    color: #111827;
}

.elvi-header h3 {
    margin: 0 0 0.25rem;
    font-size: 1.3rem;
    letter-spacing: 0.03em;
}

.elvi-subtitle {
    margin: 0;
    font-size: 0.86rem;
    opacity: 0.88;
}

.elvi-form {
    margin-top: 1rem;
}

.elvi-field {
    margin-bottom: 0.85rem;
}

.elvi-label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.35rem;
    font-size: 0.9rem;
}

.elvi-hint {
    font-size: 0.78rem;
    opacity: 0.8;
    margin-top: 0.25rem;
}

.elvi-form input[type="file"] {
    width: 100%;
    padding: 0.4rem;
    border-radius: 0.5rem;
    border: 1px solid rgba(148, 163, 184, 0.7);
    background: rgba(15,23,42,0.35);
    color: inherit;
    font-size: 0.88rem;
}

.elvi-widget-light .elvi-form input[type="file"] {
    background: rgba(255,255,255,0.94);
}

.elvi-actions {
    margin-top: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.elvi-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.55rem 1.3rem;
    border-radius: 999px;
    font-size: 0.9rem;
    border: none;
    cursor: pointer;
    font-weight: 600;
    text-decoration: none;
}

.elvi-button-primary {
    background: linear-gradient(135deg, #22d3ee, #6366f1);
    color: #0b1020;
}

.elvi-button-primary:hover {
    filter: brightness(1.05);
}

.elvi-spinner {
    width: 18px;
    height: 18px;
    border-radius: 999px;
    border: 2px solid rgba(148,163,184,0.7);
    border-top-color: #22d3ee;
    animation: elvi-spin 0.9s linear infinite;
}

@keyframes elvi-spin {
    to {
        transform: rotate(360deg);
    }
}

.elvi-messages {
    margin-top: 0.6rem;
    font-size: 0.82rem;
}

.elvi-message-success {
    color: #4ade80;
}

.elvi-message-error {
    color: #f97373;
}

.elvi-result {
    margin-top: 1rem;
    padding-top: 0.75rem;
    border-top: 1px dashed rgba(148,163,184,0.4);
}

.elvi-result h4 {
    margin: 0 0 0.5rem;
    font-size: 0.95rem;
}

.elvi-audio-player {
    width: 100%;
}

.elvi-download-wrap {
    margin-top: 0.6rem;
}

.elvi-download-link {
    font-size: 0.86rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 999px;
    padding: 0.35rem 0.8rem;
    border: 1px solid rgba(148,163,184,0.8);
}

.elvi-widget-dark .elvi-download-link {
    color: #e5e7eb;
}

.elvi-widget-light .elvi-download-link {
    color: #111827;
}

.elvi-footer {
    margin-top: 0.9rem;
    font-size: 0.75rem;
    opacity: 0.7;
    text-align: right;
}

/* Small screens */
@media (max-width: 480px) {
    .elvi-widget {
        margin: 1rem;
        padding: 1rem 1.1rem;
    }
}
