/* Social Tools Dark Theme - 2025 Edition */

/* Theme Variables */
:root {
    /* Core Colors */
    --primary: #7289da;
    --primary-hover: #5c73c7;
    --primary-active: #4a5d9e;
    --accent: #ff73a9;
    --accent-hover: #ff5c98;
    
    /* Surface Colors */
    --surface-0: #1a1a1a;  /* Background */
    --surface-1: #242424;  /* Cards */
    --surface-2: #2d2d2d;  /* Inputs */
    --surface-3: #363636;  /* Hover States */
    
    /* Text Colors */
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --text-tertiary: #808080;
    --text-accent: var(--accent);
    
    /* Status Colors */
    --success: #43b581;
    --warning: #faa61a;
    --error: #f04747;
    --info: #5865f2;
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    --gradient-surface: linear-gradient(135deg, var(--surface-1) 0%, var(--surface-2) 100%);
    
    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.4);
    
    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-full: 9999px;
}

/* Core Styles */
body {
    background-color: var(--surface-0);
    color: var(--text-primary);
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.5;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-primary);
    font-weight: 600;
}

.text-secondary {
    color: var(--text-secondary) !important;
}

/* Layout Components */
.social-tool-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.tool-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 2rem;
    background: var(--gradient-surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
}

.tool-content {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: 2fr 1fr;
}

@media (max-width: 768px) {
    .tool-content {
        grid-template-columns: 1fr;
    }
}

/* Cards */
.tool-card {
    background: var(--surface-1);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}

.tool-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Forms */
.form-control, .form-select {
    background-color: var(--surface-2);
    border: 1px solid var(--surface-3);
    color: var(--text-primary);
    border-radius: var(--radius-sm);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-control:focus, .form-select:focus {
    background-color: var(--surface-2);
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(114, 137, 218, 0.25);
    color: var(--text-primary);
}

.form-control::placeholder {
    color: var(--text-tertiary);
}

/* Buttons */
.btn-primary {
    background: var(--gradient-primary);
    border: none;
    color: var(--text-primary);
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-sm);
    font-weight: 500;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--surface-3);
    color: var(--text-primary);
}

.btn-outline:hover {
    background: var(--surface-3);
}

/* Action Buttons */
.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s;
}

/* Social Platform Colors */
.platform-youtube { --platform-color: #ff0000; }
.platform-facebook { --platform-color: #1877f2; }
.platform-twitter { --platform-color: #1da1f2; }
.platform-instagram { --platform-color: #e4405f; }
.platform-tiktok { --platform-color: #000000; }

/* Status Badges */
.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 500;
}

.status-badge.success { background: rgba(67, 181, 129, 0.2); color: var(--success); }
.status-badge.warning { background: rgba(250, 166, 26, 0.2); color: var(--warning); }
.status-badge.error { background: rgba(240, 71, 71, 0.2); color: var(--error); }
.status-badge.info { background: rgba(88, 101, 242, 0.2); color: var(--info); }

/* Toast Notifications */
.toast {
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    padding: 1rem 1.5rem;
    background: var(--surface-1);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    animation: slideIn 0.3s ease-out;
}

.toast.fade-out {
    animation: fadeOut 0.3s ease-out forwards;
}

.toast-success { border-left: 4px solid var(--success); }
.toast-error { border-left: 4px solid var(--error); }
.toast-info { border-left: 4px solid var(--info); }

/* Special Effects */
.gradient-border {
    position: relative;
    border-radius: var(--radius-md);
    background: var(--surface-1);
}

.gradient-border::before {
    content: '';
    position: absolute;
    top: -2px;
    right: -2px;
    bottom: -2px;
    left: -2px;
    background: var(--gradient-primary);
    border-radius: calc(var(--radius-md) + 2px);
    z-index: -1;
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
    gap: 0.5rem;
    max-height: 200px;
    overflow-y: auto;
}

.emoji-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-2);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: transform 0.2s;
    font-size: 1.25rem;
}

.emoji-btn:hover {
    transform: scale(1.1);
    background: var(--surface-3);
}

/* Video/Photo Preview */
.media-preview {
    background: var(--surface-2);
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    aspect-ratio: 16/9;
    margin-bottom: 1rem;
}

.media-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.media-preview .overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s;
}

.media-preview:hover .overlay {
    opacity: 1;
}

/* Metadata Display */
.metadata-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.metadata-item {
    background: var(--surface-2);
    padding: 1rem;
    border-radius: var(--radius-sm);
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.metadata-label {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.metadata-value {
    color: var(--text-primary);
    font-weight: 500;
}

/* Quality Selection */
.quality-options {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 1rem 0;
}

.quality-option {
    background: var(--surface-2);
    border: 2px solid transparent;
    border-radius: var(--radius-sm);
    padding: 0.5rem 1rem;
    cursor: pointer;
    transition: all 0.2s;
}

.quality-option:hover {
    background: var(--surface-3);
}

.quality-option.active {
    border-color: var(--primary);
    background: var(--surface-3);
}

/* Tag List */
.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0;
}

.tag-item {
    background: var(--surface-2);
    color: var(--text-primary);
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tag-item .remove-tag {
    color: var(--text-tertiary);
    cursor: pointer;
}

.tag-item .remove-tag:hover {
    color: var(--error);
}

/* Loading Indicators */
.loading-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--surface-3);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Animations */
@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes fadeOut {
    to {
        transform: translateY(100%);
        opacity: 0;
    }
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--surface-1);
}

::-webkit-scrollbar-thumb {
    background: var(--surface-3);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}
