/* style.css */
:root {
    --bg-primary: #0a192f;
    --bg-secondary: #112240;
    --bg-card: #1a2a44;
    --bg-hover: #233554;
    --border-color: #2d4263;
    --text-primary: #e6f1ff;
    --text-secondary: #a8b2d1;
    --text-muted: #8892b0;
    --accent-blue: #00FFFF;
    --accent-purple: #7b4dff;
    --accent-green: #00d26a;
    --accent-red: #ff4d6d;
    --accent-yellow: #ffd166;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.4);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
}

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); border-radius: 5px; }
::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent-blue); }

/* === Создатель в таблице Dev === */
.creator-cell {
    font-size: 0.9rem;
    color: var(--text-secondary);
    white-space: nowrap;
}
.creator-cell i {
    color: var(--accent-blue);
    margin-right: 4px;
    font-size: 0.95rem;
}

/* === Иконки групп в Dev === */
.card-title i.ti-crown { color: var(--accent-purple); }
.card-title i.ti-shield { color: var(--accent-blue); }
.card-title i.ti-users { color: var(--accent-green); }

/* === Чёткие таблицы в Dev === */
.table-wrap table { font-size: 0.92rem; }
.table-wrap th {
    font-size: 0.75rem;
    letter-spacing: 0.06em;
    padding: 12px 10px;
}
.table-wrap td {
    padding: 12px 10px;
    vertical-align: middle;
}
.role-badge {
    font-size: 0.78rem;
    padding: 3px 9px;
}

/* === HERO НА СТРАНИЦЕ АЛЬБОМА === */
.album-hero { text-align: center; margin-bottom: 32px; }
.album-owner {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 2px 4px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 5px;
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 12px;
}
.album-owner i { color: var(--accent-blue); font-size: 1.1rem; }
.album-owner b { color: var(--text-primary); }

@media (max-width: 480px) {
    .album-owner { font-size: 0.85rem; padding: 6px 12px; }
}

/* === HERO НА СТРАНИЦЕ АЛЬБОМА === */
.album-hero { text-align: center; margin-bottom: 32px; }
.album-owner {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 8px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 12px;
}
.album-owner i { color: var(--accent-blue); font-size: 1.1rem; }
.album-owner b { color: var(--text-primary); }

@media (max-width: 480px) {
    .album-owner { font-size: 0.85rem; padding: 6px 12px; }
}


/* === HERO НА СТРАНИЦЕ АЛЬБОМА === */
.album-hero {
    text-align: center;
    margin-bottom: 32px;
}
.album-owner {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 12px;
}
.album-owner i { color: var(--accent-blue); font-size: 1.1rem; }
.album-owner b { color: var(--text-primary); }

@media (max-width: 480px) {
    .album-owner { font-size: 0.85rem; padding: 6px 12px; }
}

.owner-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 0 auto 24px;
    max-width: 480px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 24px;
}
.owner-row {
    display: flex; align-items: center; gap: 10px;
    color: var(--text-secondary);
    font-size: 0.95rem;
}
.owner-row i { color: var(--accent-blue); font-size: 1.1rem; width: 20px; }
.owner-row b { color: var(--text-primary); }


/* === РОЛИ === */
.role-badge {
    display: inline-block;
    padding: 1px 4px;
    border-radius: 3px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: capitalize;
}
.role-badge.developer {
    background: rgba(123, 77, 255, 0.15);
    color: var(--accent-purple);
    border: 1px solid rgba(123, 77, 255, 0.4);
}
.role-badge.admin {
    background: rgba(0, 255, 255, 0.15);
    color: var(--accent-blue);
    border: 1px solid rgba(0, 255, 255, 0.3);
}
.role-badge.user {
    background: rgba(168, 178, 209, 0.15);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

/* === ССЫЛКА УСТАНОВКИ ПАРОЛЯ === */
.link-box {
    background: var(--bg-card);
    border: 1px dashed var(--accent-blue);
    border-radius: 10px;
    padding: 14px 16px;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    color: var(--accent-blue);
    word-break: break-all;
    user-select: all;
}

/* === ТЕГИ === */
.tag-ok, .tag-warn {
    display: inline-block;
    padding: 1px 4px;
    border-radius: 3px;
    font-size: 0.8rem;
    font-weight: 600;
    white-space: nowrap;
}
.tag-ok {
    background: rgba(0, 210, 106, 0.15);
    color: var(--accent-green);
    border: 1px solid rgba(0, 210, 106, 0.3);
}
.tag-warn {
    background: rgba(255, 209, 102, 0.15);
    color: var(--accent-yellow);
    border: 1px solid rgba(255, 209, 102, 0.3);
}

/* === АЛЬБОМЫ === */
.albums-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}
.album-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px;
    display: flex; flex-direction: column; gap: 12px;
    transition: var(--transition);
}
.album-card:hover {
    border-color: var(--accent-blue);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}
.album-header { display: flex; align-items: center; gap: 12px; }
.album-icon {
    width: 44px; height: 44px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    color: white; font-size: 1.2rem; flex-shrink: 0;
}
.album-title {
    font-weight: 600;
    font-size: 1rem;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    max-width: 200px;
}
.album-meta { color: var(--text-muted); font-size: 0.85rem; }
.album-date { color: var(--text-muted); font-size: 0.8rem; }
.album-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: auto; }

/* === ГАЛЕРЕЯ === */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
}
.gallery-item {
    display: block;
    border-radius: 10px;
    overflow: hidden;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    transition: var(--transition);
    aspect-ratio: 1 / 1;
    position: relative;
}
.gallery-item img,
.gallery-item video {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s;
}
.gallery-item:hover {
    border-color: var(--accent-blue);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}
.gallery-item:hover img { transform: scale(1.05); }
.video-item { aspect-ratio: 16 / 9; grid-column: span 2; }
.video-item video { object-fit: contain; background: #000; }
.video-name {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 6px 10px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    font-size: 0.8rem;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* === СПИСОК ФАЙЛОВ === */
.files-list { display: flex; flex-direction: column; gap: 8px; }
.file-item {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition);
}
.file-item:hover { border-color: var(--accent-blue); background: var(--bg-hover); }
.file-icon {
    width: 40px; height: 40px;
    background: var(--bg-secondary);
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    color: var(--accent-blue); font-size: 1.2rem; flex-shrink: 0;
}
.file-info { flex: 1; min-width: 0; }
.file-name { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-meta { color: var(--text-muted); font-size: 0.85rem; }

/* === МОБИЛЬНЫЙ === */
@media (max-width: 768px) {
    .albums-grid { grid-template-columns: 1fr; }
    .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .video-item { grid-column: span 2; }
}
@media (max-width: 480px) {
    .gallery-grid { grid-template-columns: 1fr; }
    .video-item { grid-column: span 1; }
    .album-title { max-width: 140px; }
}

/* === АЛЬБОМЫ (грид карточек) === */
.albums-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}
.album-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px;
    transition: var(--transition);
    display: flex; flex-direction: column; gap: 12px;
}
.album-card:hover {
    border-color: var(--accent-blue);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}
.album-header { display: flex; align-items: center; gap: 12px; }
.album-icon {
    width: 44px; height: 44px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    color: white; font-size: 1.2rem; flex-shrink: 0;
}
.album-title {
    font-weight: 600;
    font-size: 1rem;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    max-width: 200px;
}
.album-meta { color: var(--text-muted); font-size: 0.85rem; }
.album-date { color: var(--text-muted); font-size: 0.8rem; }
.album-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: auto; }

/* === ГАЛЕРЕЯ АЛЬБОМА === */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
}
.gallery-item {
    display: block;
    border-radius: 10px;
    overflow: hidden;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    transition: var(--transition);
    aspect-ratio: 1 / 1;
    position: relative;
}
.gallery-item img,
.gallery-item video {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s;
}
.gallery-item:hover {
    border-color: var(--accent-blue);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}
.gallery-item:hover img { transform: scale(1.05); }
.video-item { aspect-ratio: 16 / 9; grid-column: span 2; }
.video-item video { object-fit: contain; background: #000; }
.video-name {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 6px 10px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    font-size: 0.8rem;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* === ФАЙЛЫ (список) === */
.files-list { display: flex; flex-direction: column; gap: 8px; }
.file-item {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition);
}
.file-item:hover { border-color: var(--accent-blue); background: var(--bg-hover); }
.file-icon {
    width: 40px; height: 40px;
    background: var(--bg-secondary);
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    color: var(--accent-blue); font-size: 1.2rem; flex-shrink: 0;
}
.file-info { flex: 1; min-width: 0; }
.file-name { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-meta { color: var(--text-muted); font-size: 0.85rem; }

/* === ССЫЛКА УСТАНОВКИ ПАРОЛЯ === */
.link-box {
    background: var(--bg-card);
    border: 1px dashed var(--accent-blue);
    border-radius: 10px;
    padding: 14px 16px;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    color: var(--accent-blue);
    word-break: break-all;
    user-select: all;
}


/* === АДАПТИВ: мобильные === */
@media (max-width: 768px) {
    .albums-grid { grid-template-columns: 1fr; }
    .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .video-item { grid-column: span 2; }
    .gallery-item { border-radius: 8px; }
}
@media (max-width: 480px) {
    .gallery-grid { grid-template-columns: 1fr; }
    .video-item { grid-column: span 1; }
    .album-title { max-width: 140px; }
}

/* === ОСНОВНАЯ СТРУКТУРА === */
.main-header {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-card) 100%);
    border-bottom: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    box-shadow: var(--shadow-sm);
}
.header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.header-actions { display: flex; align-items: center; gap: 12px; }

.main-container {
    max-width: 1400px;
    margin: 90px auto 40px;
    padding: 0 2rem;
    flex: 1;
    width: 100%;
}

.main-footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 0.8rem 0;
    text-align: center;
    margin-top: auto;
}
.footer-content { max-width: 1400px; margin: 0 auto; padding: 0 2rem; }
.footer-text { color: var(--text-muted); font-size: 0.9rem; }

/* === ЛОГОТИП === */
.logo {
    display: flex; align-items: center; gap: 12px;
    font-weight: 700; font-size: 1.5rem;
    color: var(--text-primary); text-decoration: none;
    transition: var(--transition);
}
.logo-icon {
    width: 36px; height: 36px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    color: white; font-size: 1.2rem;
}
.logo-icon i { font-size: 1.4rem; transition: transform 0.3s; }
.logo:hover .logo-icon i { animation: spin 0.8s ease; }

/* === КНОПКИ ХЕДЕРА === */
.refresh-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 8px 16px;
    border-radius: 10px;
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    display: flex; align-items: center; gap: 8px;
    white-space: nowrap;
    height: 44px;
    text-decoration: none;
    font-family: inherit;
}
.refresh-btn:hover {
    background: var(--bg-hover);
    border-color: var(--accent-blue);
    transform: translateY(-2px);
    color: var(--accent-blue);
}
.refresh-btn:active { transform: translateY(0); }
.refresh-btn.danger { color: var(--accent-red); }
.refresh-btn.danger:hover { border-color: var(--accent-red); color: var(--accent-red); }
.refresh-btn.primary {
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    border: none;
    color: white;
    font-weight: 600;
}
.refresh-btn.primary:hover { filter: brightness(1.1); color: white; }

.user-badge {
    display: flex; align-items: center; gap: 8px;
    padding: 6px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    font-size: 0.9rem;
    color: var(--text-primary);
    height: 44px;
}
.user-badge i { color: var(--accent-blue); }

/* === SECTION TITLES === */
.section-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-align: center;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 2rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* === КАРТОЧКИ === */
.card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
}
.card-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 18px;
    display: flex; align-items: center; gap: 10px;
}
.card-title i { color: var(--accent-blue); }

/* === DROPZONE === */
.dropzone {
    display: block;
    border: 2px dashed var(--border-color);
    border-radius: 12px;
    padding: 48px 24px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    background: var(--bg-card);
    position: relative;
}
.dropzone:hover, .dropzone.over {
    border-color: var(--accent-blue);
    background: rgba(0, 255, 255, 0.04);
    transform: translateY(-2px);
}
.dropzone.over { box-shadow: 0 0 0 4px rgba(0, 255, 255, 0.1); }
.dropzone input { display: none; }
.dz-icon { font-size: 3rem; margin-bottom: 12px; color: var(--accent-blue); }
.dz-text { color: var(--text-secondary); margin-bottom: 8px; font-size: 1rem; }
.dz-text span { color: var(--accent-blue); font-weight: 600; }
.dz-hint { color: var(--text-muted); font-size: 0.85rem; }

.file-list-preview {
    margin-top: 16px;
    display: flex; flex-direction: column; gap: 8px;
}
.file-preview-item {
    display: flex; align-items: center; justify-content: space-between;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 10px 14px;
    gap: 12px;
    animation: fadeIn 0.3s;
}
.file-preview-item .name {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.9rem;
}
.file-preview-item .size {
    color: var(--text-muted);
    font-size: 0.85rem;
    white-space: nowrap;
}
.file-preview-item .remove {
    background: rgba(255, 77, 109, 0.15);
    border: 1px solid rgba(255, 77, 109, 0.3);
    color: var(--accent-red);
    border-radius: 6px;
    width: 28px; height: 28px;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.9rem;
    transition: var(--transition);
}
.file-preview-item .remove:hover { background: rgba(255, 77, 109, 0.3); }

.action-button {
    display: flex; align-items: center; justify-content: center;
    gap: 10px;
    padding: 14px 24px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    width: 100%;
    margin-top: 16px;
    font-family: inherit;
}
.action-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 255, 255, 0.3);
}
.action-button:disabled { opacity: 0.5; cursor: not-allowed; }
.action-button:active:not(:disabled) { transform: translateY(0); }

/* === ПРОГРЕСС === */
.progress {
    display: none;
    margin-top: 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    height: 30px;
    position: relative;
}
#bar {
    width: 0; height: 100%;
    background: linear-gradient(90deg, var(--accent-blue), var(--accent-purple));
    text-align: center;
    font-size: 13px;
    line-height: 30px;
    color: white;
    font-weight: 600;
    transition: width 0.2s;
}

/* === ТАБЛИЦА ФАЙЛОВ === */
.table-wrap { overflow-x: auto; border-radius: 10px; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--border-color); }
th {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    font-weight: 600;
    background: var(--bg-card);
}
tbody tr { transition: background 0.2s; }
tbody tr:hover { background: rgba(0, 255, 255, 0.03); }
tbody tr:last-child td { border-bottom: none; }
.fname { display: flex; align-items: center; gap: 10px; font-weight: 500; word-break: break-all; }
.fname i { color: var(--accent-blue); font-size: 1.2rem; flex-shrink: 0; }
.fsize, .fdate { color: var(--text-muted); font-size: 0.9rem; white-space: nowrap; }
.actions-cell { display: flex; gap: 6px; flex-wrap: wrap; }

.btn-mini {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    font-family: inherit;
    white-space: nowrap;
}
.btn-mini:hover {
    border-color: var(--accent-blue);
    color: var(--accent-blue);
    background: var(--bg-hover);
}
.btn-mini.danger { color: var(--accent-red); }
.btn-mini.danger:hover { border-color: var(--accent-red); background: rgba(255, 77, 109, 0.1); }
.btn-mini i { font-size: 0.9rem; }

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}
.empty-state i { font-size: 3rem; margin-bottom: 12px; opacity: 0.5; display: block; }

/* === ФОРМА ЛОГИНА === */
.auth-wrap {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: radial-gradient(1200px 600px at 50% -20%, rgba(123, 77, 255, 0.15) 0%, var(--bg-primary) 60%);
}
.auth-card {
    width: 100%;
    max-width: 400px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 40px 32px;
    box-shadow: var(--shadow-lg);
    text-align: center;
}
.auth-logo {
    width: 64px; height: 64px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    border-radius: 16px;
    margin: 0 auto 20px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.8rem;
    color: white;
}
.auth-card h1 {
    font-size: 1.6rem;
    margin-bottom: 6px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.auth-card .subtitle { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 24px; }
.auth-card form { text-align: left; }

.form-input {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    outline: none;
    font-size: 0.95rem;
    font-family: inherit;
    transition: var(--transition);
    margin-bottom: 12px;
}
.form-input:focus {
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 3px rgba(0, 255, 255, 0.1);
}
.form-input::placeholder { color: var(--text-muted); }

/* === INLINE FORM (админка) === */
.inline-form {
    display: grid;
    grid-template-columns: 1fr 1fr auto auto;
    gap: 12px;
    align-items: center;
}
.inline-form .form-input, .inline-form select { margin: 0; }
.inline-form .action-button { width: auto; margin: 0; padding: 12px 24px; }


/* === TOAST === */
.toast-container {
    position: fixed;
    top: 90px; right: 2rem;
    z-index: 999;
    display: flex; flex-direction: column; gap: 10px;
    max-width: 400px;
}
.notification {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 12px;
    transform: translateX(120%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.notification.show { transform: translateX(0); }
.notification-icon {
    width: 36px; height: 36px;
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}
.notification.success .notification-icon { background: rgba(0, 210, 106, 0.15); color: var(--accent-green); }
.notification.error .notification-icon { background: rgba(255, 77, 109, 0.15); color: var(--accent-red); }
.notification.info .notification-icon { background: rgba(0, 255, 255, 0.15); color: var(--accent-blue); }
.notification-content { flex: 1; }
.notification-title { font-weight: 600; font-size: 0.95rem; color: var(--text-primary); }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fadeIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }


/* ==================== СТИЛИ ДЛЯ ТАБЛИЦ ==================== */

.table-wrap {
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.table-wrap table {
    width: 100%;
    border-collapse: collapse;
    text-align: center;
}

.table-wrap th, 
.table-wrap td {
    padding: 12px 10px;
    border: 1px solid var(--border-color); /* Сетка */
    text-align: center;
    vertical-align: middle;
}

.table-wrap th {
    background: var(--bg-card);
    color: var(--text-muted);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Чтобы убрать двойные рамки по краям */
.table-wrap tr th:first-child,
.table-wrap tr td:first-child {
    border-left: none;
}
.table-wrap tr th:last-child,
.table-wrap tr td:last-child {
    border-right: none;
}
.table-wrap tr:last-child td {
    border-bottom: none;
}

/* Центрируем кнопки в колонке действий */
.actions-cell {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
}

/* === АДАПТИВ === */
@media (max-width: 768px) {
    .header-content { padding: 0 1rem; height: 60px; }
    .logo { font-size: 1.3rem; gap: 10px; }
    .logo-icon { width: 32px; height: 32px; font-size: 1.1rem; }
    .btn-text { display: none; }
    .refresh-btn { width: 44px; padding: 0; justify-content: center; }
    .user-badge { padding: 6px 10px; }
    .user-badge span { display: none; }
    .main-container { margin-top: 80px; padding: 0 1rem; }
    .section-title { font-size: 1.5rem; }
    .card { padding: 18px; }
    .dropzone { padding: 32px 16px; }
    .dz-icon { font-size: 2.4rem; }
    .inline-form { grid-template-columns: 1fr; }
    .inline-form .action-button { width: 100%; }
    .toast-container { top: 80px; right: 1rem; left: 1rem; max-width: none; }
    th, td { padding: 10px 8px; font-size: 0.9rem; }
    .actions-cell { flex-direction: column; }
}

@media (max-width: 480px) {
    .header-content { padding: 0 0.8rem; height: 56px; }
    .logo span { font-size: 1.2rem; }
    .logo-icon { width: 30px; height: 30px; }
    .refresh-btn { width: 40px; height: 40px; }
    .user-badge { height: 40px; }
    .card { padding: 16px; }
}