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

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
    --bg: #0f0f1a;
    --bg-light: #1a1a2e;
    --bg-lighter: #25253d;
    --text: #e2e8f0;
    --text-muted: #94a3b8;
    --border: #3b3b5c;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    max-width: 600px;
    width: 100%;
}

header {
    text-align: center;
    margin-bottom: 40px;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    background: linear-gradient(135deg, var(--primary), #a855f7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    color: var(--text-muted);
    font-size: 1rem;
}

.section {
    background: var(--bg-light);
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 20px;
    border: 1px solid var(--border);
}

.hidden {
    display: none !important;
}

/* Drop Zone */
.drop-zone {
    border: 2px dashed var(--border);
    border-radius: 12px;
    padding: 60px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

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

.drop-zone-content .drop-icon {
    font-size: 4rem;
    display: block;
    margin-bottom: 20px;
}

.drop-zone-content p {
    color: var(--text-muted);
    margin-bottom: 10px;
}

.or {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-small {
    padding: 6px 12px;
    font-size: 0.85rem;
    background: var(--bg-lighter);
    color: var(--text-muted);
}

.btn-small:hover {
    background: var(--error);
    color: white;
}

/* File Info */
.file-info {
    display: flex;
    align-items: center;
    gap: 15px;
    background: var(--bg-lighter);
    padding: 15px 20px;
    border-radius: 10px;
    margin-top: 20px;
}

.file-icon {
    font-size: 2rem;
}

.file-icon.large {
    font-size: 4rem;
}

.file-details {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.file-name {
    font-weight: 600;
    word-break: break-all;
}

.file-size {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Password block */
.password-block {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.password-block label {
    font-weight: 600;
    color: var(--text);
}

.password-block input {
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-lighter);
    color: var(--text);
    font-size: 0.95rem;
}

.password-block .hint {
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* Link Section */
.link-section {
    margin-top: 25px;
}

.link-section h3 {
    margin-bottom: 15px;
    color: var(--text);
}

.link-container {
    display: flex;
    gap: 10px;
}

.link-container input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-lighter);
    color: var(--text);
    font-size: 0.9rem;
}

/* Status */
.status {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 15px;
    color: var(--text-muted);
}

.status-waiting {
    color: var(--warning);
}

.status-connected {
    color: var(--success);
}

.status-error {
    color: var(--error);
}

.pulse {
    width: 10px;
    height: 10px;
    background: currentColor;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.2); }
}

/* Progress */
.progress-container {
    margin-top: 20px;
}

.progress-bar {
    height: 20px;
    background: var(--bg-lighter);
    border-radius: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), #a855f7);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 10px;
}

.progress-stats {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Receiver Section */
.receiver-info {
    text-align: center;
}

.receiver-info h2 {
    margin-bottom: 20px;
}

.incoming-file-info {
    background: var(--bg-lighter);
    padding: 30px;
    border-radius: 12px;
    margin-bottom: 20px;
}

/* Complete Section */
.complete-content,
.error-content {
    text-align: center;
}

.complete-icon,
.error-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.complete-content h2,
.error-content h2 {
    margin-bottom: 15px;
}

.complete-content p,
.error-content p {
    color: var(--text-muted);
    margin-bottom: 20px;
}

.integrity-check {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    padding: 12px 20px;
    border-radius: 8px;
    margin-bottom: 25px;
}

/* Footer */
footer {
    text-align: center;
    padding: 20px;
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 480px) {
    header h1 {
        font-size: 1.8rem;
    }
    
    .section {
        padding: 20px;
    }
    
    .link-container {
        flex-direction: column;
    }
    
    .progress-stats {
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }
}

/* Copied Toast */
.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--success);
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    animation: toast-in 0.3s ease;
    z-index: 1000;
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

/* Compteur d'utilisateurs connectés */
.connected-users {
    text-align: center;
    font-size: 1.1rem;
    color: var(--success);
    margin: 10px 0;
    padding: 8px 16px;
    background: rgba(16, 185, 129, 0.1);
    border-radius: 8px;
    display: inline-block;
    width: 100%;
}

/* Bouton recevoir fichier */
#receive-file-btn {
    width: 100%;
    margin-top: 15px;
    padding: 15px;
    font-size: 1.1rem;
}
