/* public/assets/css/style.css */

/* --- 1. ПЕРЕМЕННЫЕ (Цветовая тема) --- */
:root {
    --bg-color: #020617;       /* Очень темный фон */
    --surface-color: #0f172a;  /* Цвет карточек/панелей */
    --border: #1e293b;         /* Цвет рамок */
    --text-main: #f8fafc;      /* Белый текст */
    --text-muted: #94a3b8;     /* Серый текст */
    --primary: #3b82f6;        /* Синий основной */
    --primary-hover: #2563eb;
    --danger: #ef4444;         /* Красный */
    --success: #22c55e;        /* Зеленый */
}

/* --- 2. БАЗОВЫЕ СБРОСЫ --- */
body {
    margin: 0;
    padding: 0;
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.5;
}

*, *::before, *::after {
    box-sizing: border-box;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; padding: 0; margin: 0; }

/* Контейнер по центру */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- 3. ЗОНА ЗАГРУЗКИ (Общая) --- */
.upload-zone {
    border: 2px dashed var(--border);
    border-radius: 12px;
    background: rgba(30, 41, 59, 0.3);
    padding: 50px 20px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    margin-bottom: 40px;
    position: relative;
    overflow: hidden;
}

.upload-zone:hover,
.upload-zone.drag-over {
    border-color: var(--primary);
    background: rgba(59, 130, 246, 0.1);
    transform: scale(1.005);
}

.upload-icon { font-size: 48px; display: block; margin-bottom: 15px; }
.upload-text { font-size: 18px; font-weight: 600; margin-bottom: 8px; color: var(--text-main); }
.upload-hint { color: var(--text-muted); font-size: 14px; }
#fileInput { display: none; } /* Скрываем стандартный инпут */

/* --- 4. ОЧЕРЕДЬ ЗАГРУЗКИ (AJAX) --- */
.upload-queue {
    margin-bottom: 30px;
    display: flex; flex-direction: column; gap: 10px;
    width: 100%;
}
.upload-item {
    background: var(--surface-color);
    border: 1px solid var(--border);
    padding: 10px; border-radius: 8px;
    display: flex; align-items: center; gap: 15px;
    animation: slideDown 0.3s ease;
    position: relative; overflow: hidden;
}
@keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }

.upload-preview {
    width: 50px; height: 50px; border-radius: 6px;
    object-fit: cover; background: #000; border: 1px solid var(--border);
}
.upload-details { flex-grow: 1; display: flex; flex-direction: column; justify-content: center; }
.upload-filename {
    font-size: 14px; font-weight: 500; color: var(--text-main);
    margin-bottom: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 300px;
}
.progress-track {
    width: 100%; height: 6px; background: rgba(255, 255, 255, 0.1);
    border-radius: 3px; overflow: hidden;
}
.progress-fill {
    height: 100%; background: var(--primary); width: 0%;
    transition: width 0.2s linear; border-radius: 3px;
}
.upload-status { font-size: 12px; color: var(--text-muted); min-width: 60px; text-align: right; }

/* --- 5. МОДАЛЬНЫЕ ОКНА --- */
.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.7); backdrop-filter: blur(5px);
    z-index: 9999;
    display: none; align-items: center; justify-content: center;
    animation: fadeIn 0.2s ease-out;
}
.modal-content {
    background: var(--surface-color);
    padding: 30px; border-radius: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    max-width: 500px; width: 90%;
    animation: zoomIn 0.2s ease-out;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes zoomIn { from { transform: scale(0.95); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* Стили модалки загрузки */
.upload-modal-content {
    width: 500px; max-width: 95%; background: #1e293b;
    border: 1px solid #334155; border-radius: 12px; padding: 0;
    display: flex; flex-direction: column; max-height: 80vh;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7);
}
.upload-modal-header { padding: 20px; border-bottom: 1px solid #334155; display: flex; justify-content: space-between; align-items: center; }
.upload-modal-title { margin: 0; color: white; font-size: 18px; font-weight: 600; }
.upload-modal-body { padding: 20px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; }
.upload-modal-footer { padding: 20px; border-top: 1px solid #334155; display: flex; justify-content: flex-end; }
.upload-status-icon { width: 24px; height: 24px; display: flex; align-items: center; justify-content: center; }

/* --- 6. КНОПКИ --- */
.btn-primary {
    background: var(--primary); color: white; border: none;
    padding: 10px 20px; border-radius: 6px; font-weight: 600; cursor: pointer;
    text-decoration: none; display: inline-block;
}
.btn-primary:hover { background: var(--primary-hover); }

.btn-finish {
    background: var(--success); color: white; border: none;
    padding: 10px 24px; border-radius: 6px; font-weight: 600;
    cursor: pointer; opacity: 1; transition: 0.2s;
}
.btn-finish:disabled { background: #475569; cursor: not-allowed; opacity: 0.6; }
.btn-finish:hover:not(:disabled) { background: #16a34a; transform: translateY(-1px); }

.btn-cancel {
    background: transparent; border: 1px solid var(--border); color: var(--text-muted);
    padding: 8px 16px; border-radius: 6px; cursor: pointer;
}
.btn-cancel:hover { border-color: var(--text-main); color: var(--text-main); }
.btn-confirm-delete {
    background: var(--danger); color: white; border: none;
    padding: 8px 16px; border-radius: 6px; cursor: pointer; font-weight: 600;
}
.btn-confirm-delete:hover { background: #ef4444; }