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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
}

header {
    text-align: center;
    margin-bottom: 30px;
    color: white;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

header h1 i {
    margin-right: 10px;
    color: #ffd700;
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Status Card */
.status-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.status-indicator {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    font-weight: 600;
}

.status-indicator i {
    margin-right: 10px;
    font-size: 1.2rem;
}

.status-indicator.online i {
    color: #4CAF50;
}

.status-indicator.offline i {
    color: #f44336;
}

.device-id {
    font-size: 0.9rem;
    color: #666;
}

.device-id code {
    background: #f5f5f5;
    padding: 5px 10px;
    border-radius: 5px;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    color: #333;
}

/* Mode Selection */
.mode-selection {
    display: flex;
    background: white;
    border-radius: 15px;
    padding: 5px;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.mode-btn {
    flex: 1;
    padding: 15px;
    border: none;
    background: transparent;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.mode-btn i {
    font-size: 1.5rem;
}

.mode-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.mode-btn:not(.active):hover {
    background: #f8f9fa;
}

/* Mode Content */
.mode-content {
    background: white;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* File Drop Zone */
.file-drop-zone {
    border: 3px dashed #ddd;
    border-radius: 15px;
    padding: 40px 20px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    margin-bottom: 20px;
}

.file-drop-zone:hover,
.file-drop-zone.dragover {
    border-color: #667eea;
    background: #f8f9ff;
}

.file-drop-zone i {
    font-size: 3rem;
    color: #667eea;
    margin-bottom: 15px;
}

.file-drop-zone p {
    margin-bottom: 20px;
    color: #666;
    font-size: 1.1rem;
}

.select-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.select-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* Selected Files */
.selected-files {
    margin-bottom: 20px;
}

.file-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 10px;
    margin-bottom: 10px;
}

.file-info {
    display: flex;
    align-items: center;
    flex: 1;
}

.file-info i {
    margin-right: 10px;
    color: #667eea;
    font-size: 1.2rem;
}

.file-details {
    flex: 1;
}

.file-name {
    font-weight: 600;
    margin-bottom: 2px;
}

.file-size {
    font-size: 0.9rem;
    color: #666;
}

.remove-file {
    background: #f44336;
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.remove-file:hover {
    background: #d32f2f;
}

/* Connection Options */
.connection-options {
    margin-bottom: 20px;
}

.option-card {
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 15px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.option-card:hover {
    border-color: #667eea;
    background: #f8f9ff;
}

.option-card input[type="radio"] {
    display: none;
}

.option-card input[type="radio"]:checked + label {
    color: #667eea;
}

.option-card input[type="radio"]:checked ~ .option-card,
.option-card:has(input[type="radio"]:checked) {
    border-color: #667eea;
    background: #f8f9ff;
}

.option-card label {
    cursor: pointer;
    display: block;
}

.option-header {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 1.1rem;
}

.option-header i {
    margin-right: 10px;
    font-size: 1.3rem;
}

.option-card p {
    color: #666;
    font-size: 0.9rem;
    margin: 0;
}

/* Receive Options */
.receive-options {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.receive-options .option-card {
    cursor: default;
}

.receive-options .option-card:hover {
    border-color: #e0e0e0;
    background: white;
}

/* Connection Setup */
.connection-setup h3,
.pairing-code h3,
.receive-setup h3,
.incoming-request h3,
.incoming-files h3,
.transfer-progress h3 {
    margin-bottom: 20px;
    color: #333;
    font-size: 1.3rem;
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #555;
}

.input-group input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.connect-btn,
.accept-btn,
.reject-btn,
.send-btn,
.download-btn {
    padding: 12px 25px;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.connect-btn,
.accept-btn,
.send-btn,
.download-btn {
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
    color: white;
}

.reject-btn {
    background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
    color: white;
    margin-left: 10px;
}

.send-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    font-size: 1.2rem;
    padding: 15px 30px;
    width: 100%;
    justify-content: center;
    margin-top: 20px;
}

.connect-btn:hover,
.accept-btn:hover,
.reject-btn:hover,
.send-btn:hover,
.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* Send Section */
.send-section {
    text-align: center;
    padding: 20px 0;
    border-top: 2px solid #f0f0f0;
    margin-top: 20px;
}

/* Pairing Code */
.code-display {
    background: #f8f9ff;
    border: 2px solid #667eea;
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    margin-bottom: 15px;
}

.code-display span {
    font-size: 2rem;
    font-weight: bold;
    font-family: 'Courier New', monospace;
    color: #667eea;
    letter-spacing: 5px;
}

.pairing-status {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    color: #666;
    font-style: italic;
}

/* Session Display */
.session-display {
    margin-top: 20px;
}

.session-id-display {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 15px;
}

.session-id-display code {
    flex: 1;
    background: transparent;
    font-size: 1.1rem;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    color: #667eea;
}

/* Device ID Display */
.device-id-display {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.device-id-display code {
    flex: 1;
    background: transparent;
    font-size: 1.1rem;
    font-family: 'Courier New', monospace;
    font-weight: bold;
}

.copy-btn {
    background: #667eea;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 8px 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.copy-btn:hover {
    background: #5a6fd8;
}

/* Request Actions */
.request-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

/* Progress */
.progress-item {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 10px;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
    transition: width 0.3s ease;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.toast {
    background: white;
    border-radius: 10px;
    padding: 15px 20px;
    margin-bottom: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    border-left: 4px solid #4CAF50;
    animation: slideIn 0.3s ease;
    max-width: 300px;
}

.toast.error {
    border-left-color: #f44336;
}

.toast.warning {
    border-left-color: #ff9800;
}

.toast.info {
    border-left-color: #2196F3;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .mode-btn {
        padding: 12px;
        font-size: 0.9rem;
    }
    
    .mode-btn i {
        font-size: 1.3rem;
    }
    
    .file-drop-zone {
        padding: 30px 15px;
    }
    
    .file-drop-zone i {
        font-size: 2.5rem;
    }
    
    .code-display span {
        font-size: 1.5rem;
        letter-spacing: 3px;
    }
    
    .request-actions {
        flex-direction: column;
    }
    
    .reject-btn {
        margin-left: 0;
        margin-top: 10px;
    }
    
    .toast-container {
        left: 20px;
        right: 20px;
    }
    
    .toast {
        max-width: none;
    }
    
    .receive-options {
        gap: 15px;
    }
    
    .option-card {
        padding: 12px;
    }
    
    .send-btn {
        font-size: 1.1rem;
        padding: 12px 25px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 10px;
    }
    
    .mode-content {
        padding: 20px;
    }
    
    .file-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .file-info {
        width: 100%;
    }
    
    .device-id-display,
    .session-id-display {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .option-header {
        font-size: 1rem;
    }
    
    .option-header i {
        font-size: 1.2rem;
    }
}

