:root {
    --bg-color: #0f172a;
    --card-bg: rgba(30, 41, 59, 0.7);
    --border-color: rgba(255, 255, 255, 0.1);
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --success: #10b981;
    --error: #ef4444;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: radial-gradient(circle at top right, #1e293b, #0f172a);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.app-container {
    width: 100%;
    max-width: 600px;
    padding: 2rem;
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.app-header {
    text-align: center;
    margin-bottom: 2rem;
}

.app-header h1 {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, #60a5fa, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
}

.app-header p {
    color: var(--text-muted);
}

/* Upload Section */
.drop-zone {
    border: 2px dashed var(--border-color);
    border-radius: 16px;
    padding: 3rem 2rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    background: rgba(15, 23, 42, 0.4);
}

.drop-zone.dragover {
    border-color: var(--primary);
    background: rgba(59, 130, 246, 0.1);
    transform: scale(1.02);
}

.upload-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    color: var(--primary);
}

.drop-zone h2 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.browse-link {
    color: var(--primary);
    font-weight: 600;
    text-decoration: underline;
}

.file-types-info {
    margin-top: 1rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Progress Section */
.progress-container {
    margin-top: 1.5rem;
    background: rgba(15, 23, 42, 0.6);
    padding: 1rem;
    border-radius: 12px;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: var(--primary);
    border-radius: 4px;
    transition: width 0.3s ease;
}

/* Result Section */
.result-section {
    text-align: center;
    animation: fadeIn 0.5s ease;
}

.success-header {
    margin-bottom: 1.5rem;
}

.success-icon {
    width: 64px;
    height: 64px;
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.success-icon svg {
    width: 32px;
    height: 32px;
}

.preview-container {
    margin-bottom: 1.5rem;
    border-radius: 12px;
    overflow: hidden;
    background: rgba(0,0,0,0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
    max-height: 300px;
}

.preview-container img, 
.preview-container video {
    max-width: 100%;
    max-height: 300px;
    object-fit: contain;
}

.link-container {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.link-container input {
    flex: 1;
    padding: 0.75rem 1rem;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-main);
    font-family: inherit;
    font-size: 0.875rem;
    outline: none;
}

.btn-copy {
    padding: 0.75rem 1.5rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.btn-copy:hover {
    background: var(--primary-hover);
}

.btn-primary {
    width: 100%;
    padding: 1rem;
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-primary:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* Utils */
.hidden {
    display: none !important;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Toast */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.toast {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    animation: slideIn 0.3s ease forwards;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.toast.error { background: var(--error); }
.toast.success { background: var(--success); }

@keyframes slideIn {
    from { opacity: 0; transform: translateX(100%); }
    to { opacity: 1; transform: translateX(0); }
}
