.apna-upload-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(15, 23, 42, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.apna-upload-panel {
    width: min(520px, 100%);
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.25);
    padding: 1.25rem 1.5rem;
}

.apna-upload-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
    font-weight: 600;
    color: #0f172a;
}

.apna-upload-overall-pct,
.apna-upload-file-pct {
    font-variant-numeric: tabular-nums;
    color: #2563eb;
    font-weight: 700;
}

.apna-upload-files {
    max-height: 240px;
    overflow-y: auto;
}

.apna-upload-file-row + .apna-upload-file-row {
    margin-top: 0.75rem;
}

.apna-upload-filename {
    max-width: 75%;
    color: #334155;
}

.apna-upload-overlay .progress {
    height: 0.75rem;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
}

.apna-upload-overlay .progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #2563eb, #3b82f6);
    border-radius: 999px;
    transition: width 0.15s ease;
}

.apna-upload-overlay .progress-bar-striped {
    background-image: linear-gradient(
        45deg,
        rgba(255, 255, 255, 0.2) 25%,
        transparent 25%,
        transparent 50%,
        rgba(255, 255, 255, 0.2) 50%,
        rgba(255, 255, 255, 0.2) 75%,
        transparent 75%,
        transparent
    );
    background-size: 1rem 1rem;
}

.apna-upload-overlay .progress-bar-animated {
    animation: apna-upload-stripes 1s linear infinite;
}

@keyframes apna-upload-stripes {
    from { background-position: 1rem 0; }
    to { background-position: 0 0; }
}

.apna-upload-overlay .d-flex {
    display: flex;
}

.apna-upload-overlay .justify-content-between {
    justify-content: space-between;
}

.apna-upload-overlay .small {
    font-size: 0.875rem;
}

.apna-upload-overlay .mb-1 {
    margin-bottom: 0.25rem;
}

.apna-upload-overlay .mb-3 {
    margin-bottom: 1rem;
}

.apna-upload-overlay .text-truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.apna-upload-overlay .spinner-border {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 0.15em solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: apna-upload-spin 0.75s linear infinite;
    vertical-align: -0.125em;
}

.apna-upload-overlay .spinner-border-sm {
    width: 0.875rem;
    height: 0.875rem;
    border-width: 0.12em;
}

.apna-upload-overlay .me-1 {
    margin-right: 0.25rem;
}

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

.apna-file-preview-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.75rem;
}

.apna-file-preview-item {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    background: #f8fafc;
}

.apna-file-preview-thumb {
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e2e8f0;
    overflow: hidden;
}

.apna-file-preview-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.apna-file-preview-thumb i {
    font-size: 1.75rem;
    color: #64748b;
}

.apna-file-preview-info {
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.apna-file-preview-name {
    font-size: 0.75rem;
    font-weight: 600;
    color: #0f172a;
    word-break: break-word;
}

.apna-file-preview-size {
    font-size: 0.7rem;
    color: #64748b;
}

.apna-multi-upload .form-control[type="file"]::file-selector-button {
    margin-right: 0.75rem;
}

.spinner-border {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 0.15em solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: apna-upload-spin 0.75s linear infinite;
    vertical-align: -0.125em;
}

.spinner-border-sm {
    width: 0.875rem;
    height: 0.875rem;
    border-width: 0.12em;
}

.me-1 {
    margin-right: 0.25rem;
}
