/**
 * OneDrive Upload / Dropzone styles
 * Matches the shadcn dropzone in odse-popup-all.html exactly. Scoped under the modal.
 */

/* Hidden by default; opened via .odse-open (toggled by the Upload button) */
.odse-modal-overlay .odse-upload-form {
    display: none;
}

.odse-modal-overlay .odse-upload-form.odse-open {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border: 1.5px dashed var(--odse-border);
    border-radius: var(--odse-radius);
    background: var(--odse-muted);
    padding: 20px;
    margin: 0 0 16px;
    box-sizing: border-box;
    width: 100%;
    cursor: pointer;
    animation: odsedzOpen .18s ease;
    transition: border-color .15s ease, background .15s ease;
}

/* Drag-over highlight */
.odse-modal-overlay .odse-upload-form.odse-open.odse-dragover {
    border-color: var(--odse-brand);
    background: var(--odse-brand-soft);
}

@keyframes odsedzOpen {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: none; }
}

/* Visually hidden native file input (still programmatically clickable) */
.odse-modal-overlay .odse-dz-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
    opacity: 0;
}

/* Left side: icon + text */
.odse-dz-left {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.odse-dz-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--odse-background);
    border: 1px solid var(--odse-border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--odse-muted-foreground);
    flex-shrink: 0;
}

.odse-dz-icon svg {
    width: 18px;
    height: 18px;
}

.odse-dz-text {
    min-width: 0;
}

.odse-dz-title {
    display: block;
    font-size: 13.5px;
    font-weight: 560;
    color: var(--odse-foreground);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.odse-dz-hint {
    display: block;
    color: var(--odse-muted-foreground);
    font-size: 12px;
    margin-top: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Right side: actions */
.odse-dz-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.odse-modal-overlay .odse-dz-submit {
    -webkit-appearance: none;
    appearance: none;
}

/* RTL: keep text on the right, actions on the left (flex follows inherited dir) */
html[dir="rtl"] .odse-modal-overlay .odse-dz-text,
body.rtl .odse-modal-overlay .odse-dz-text {
    text-align: right;
}

/* Responsive: stack vertically like the reference */
@media screen and (max-width: 782px) {
    .odse-modal-overlay .odse-upload-form.odse-open {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .odse-dz-actions {
        width: 100%;
    }

    .odse-dz-actions .odse-btn {
        flex: 1;
    }
}
