:root {
    --primary-color: #6366f1;
    --secondary-color: #a855f7;
    --text-color: #ffffff;
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.2);
    --blob-1: #ff0080;
    --blob-2: #7928ca;
    --blob-3: #0070f3;
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    background-color: #0f172a;
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
}

/* Dynamic Background */
.background-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    filter: blur(80px);
}

.blob {
    position: absolute;
    border-radius: 50%;
    opacity: 0.6;
    animation: move 10s infinite alternate;
}

.blob-1 {
    width: 400px;
    height: 400px;
    background: var(--blob-1);
    top: -100px;
    left: -100px;
}

.blob-2 {
    width: 300px;
    height: 300px;
    background: var(--blob-2);
    bottom: -50px;
    right: -50px;
    animation-delay: -5s;
}

.blob-3 {
    width: 350px;
    height: 350px;
    background: var(--blob-3);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation-duration: 15s;
}

@keyframes move {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(20px, -20px) scale(1.1);
    }
}

/* Glassmorphism Container */
.glass-container {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    text-align: center;
}

h1 {
    margin-top: 0;
    font-weight: 600;
    margin-bottom: 8px;
}

.subtitle {
    opacity: 0.7;
    margin-bottom: 30px;
    font-size: 0.95rem;
}

/* Drop Zone */
.drop-zone {
    border: 2px dashed var(--glass-border);
    border-radius: 16px;
    padding: 40px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(0, 0, 0, 0.2);
}

.drop-zone:hover,
.drop-zone.drag-over {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.1);
}

.drop-zone .icon {
    font-size: 48px;
    margin-bottom: 10px;
}

/* File List */
.file-list {
    margin-top: 20px;
    text-align: left;
}

.file-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 12px 16px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--glass-border);
}

.file-info {
    flex: 1;
    overflow: hidden;
    margin-right: 10px;
}

.file-name {
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

.file-status {
    font-size: 0.75rem;
    opacity: 0.6;
}

/* Controls */
.controls {
    margin-top: 30px;
}

.primary-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 12px 32px;
    border-radius: 100px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    width: 100%;
}

.primary-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

.primary-btn:active:not(:disabled) {
    transform: translateY(0);
}

.primary-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #4b5563;
}

/* Status Message */
.status-message {
    margin-top: 20px;
    font-size: 0.9rem;
    min-height: 1.2em;
    color: #cbd5e1;
}

.success {
    color: #4ade80;
}

.error {
    color: #f87171;
}

/* Ad Modal */
.ad-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
}

.ad-modal.hidden {
    display: none;
}

.ad-content {
    background: #1e293b;
    padding: 20px;
    border-radius: 16px;
    text-align: center;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.5), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border: 1px solid var(--glass-border);
}

.ad-placeholder {
    width: 100%;
    min-height: 250px;
    background: #0f172a;
    border: 2px dashed #334155;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: #94a3b8;
    margin-top: 20px;
}

.close-ad-btn {
    background: #ef4444;
    /* distinct color for close */
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    margin-bottom: 0;
}

.close-ad-btn:hover {
    background: #dc2626;
}

/* Download Button (Dynamic) */
.download-btn {
    background: #22c55e;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: background 0.2s;
}

.download-btn:hover {
    background: #16a34a;
}