/* TikTok Downloader Plugin Styles */
#tiktok-downloader {
    max-width: 600px;
    margin: 20px auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.tiktok-form {
    background: #ffffff;
    border: 1px solid #e1e1e1;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.tiktok-form h3 {
    color: #00ccff;
    text-align: center;
    margin-bottom: 10px;
    font-size: 24px;
    font-weight: 700;
}

.tiktok-form p em {
    color: #666;
    font-size: 14px;
    display: block;
    text-align: center;
    margin-bottom: 25px;
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

.input-group input,
.input-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e1e1e1;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: #00ccff;
    box-shadow: 0 0 0 3px rgba(0, 204, 255, 0.1);
}

#download-btn {
    width: 100%;
    background: linear-gradient(45deg, #00ccff, #33ccff);
    color: white;
    border: none;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

#download-btn:hover:not(:disabled) {
    background: linear-gradient(45deg, #0066cc, #0099cc);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0, 204, 255, 0.3);
}

#download-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

#loading {
    text-align: center;
    padding: 20px;
    color: #666;
}

#loading::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #00ccff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 10px;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

#result {
    margin-top: 25px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.video-info {
    margin-bottom: 20px;
}

.video-info h4 {
    color: #333;
    margin-bottom: 8px;
    font-size: 18px;
}

.video-info p {
    color: #666;
    margin-bottom: 12px;
}

.thumbnail {
    max-width: 200px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.download-options {
    text-align: center;
}

.download-btn {
    display: inline-block;
    padding: 12px 24px;
    margin: 8px;
    background: #007cba;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.download-btn:hover {
    background: #005a87;
    transform: translateY(-1px);
    text-decoration: none;
    color: white;
}

.video-btn {
    background: #00ccff;
}

.video-btn:hover {
    background: #0066cc;
}

.audio-btn {
    background: #1db954;
}

.audio-btn:hover {
    background: #1ed760;
}

.all-options {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #ddd;
}

.all-options h5 {
    margin-bottom: 12px;
    color: #333;
}

.download-link {
    display: inline-block;
    padding: 8px 16px;
    margin: 4px;
    background: #6c757d;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    transition: background 0.3s ease;
}

.download-link:hover {
    background: #5a6268;
    text-decoration: none;
    color: white;
}

#error {
    margin-top: 20px;
    padding: 15px;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 6px;
    color: #721c24;
}

.error-message {
    margin: 0;
    font-weight: 500;
}

/* Notifications */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    background: #28a745;
    color: white;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    font-weight: 500;
    display: none;
}

.notification.success {
    background: #28a745;
}

.notification.error {
    background: #dc3545;
}

.notification.warning {
    background: #ffc107;
    color: #212529;
}

/* Responsive */
@media (max-width: 768px) {
    #tiktok-downloader {
        margin: 10px;
        max-width: none;
    }
    
    .tiktok-form {
        padding: 20px;
    }
    
    .tiktok-form h3 {
        font-size: 20px;
    }
    
    .download-btn {
        display: block;
        margin: 8px 0;
    }
    
    .download-link {
        display: block;
        margin: 4px 0;
        text-align: center;
    }
    
    .notification {
        left: 10px;
        right: 10px;
        top: 10px;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .tiktok-form {
        background: #2c3e50;
        border-color: #34495e;
        color: #ecf0f1;
    }
    
    .input-group input,
    .input-group select {
        background: #34495e;
        border-color: #4a6741;
        color: #ecf0f1;
    }
    
    .input-group input:focus,
    .input-group select:focus {
        border-color: #00ccff;
    }
    
    #result {
        background: #34495e;
        border-color: #4a6741;
    }
    
    .video-info h4,
    .all-options h5 {
        color: #ecf0f1;
    }
    
    .video-info p {
        color: #bdc3c7;
    }
}