/* ===== ЯЗЫКОВОЙ ПЕРЕКЛЮЧАТЕЛЬ ===== */
.lang-switcher {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.lang-btn {
    background: none;
    border: 1px solid #444;
    color: #ccc;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.lang-btn:hover {
    background: #1a1a1a;
    color: #7f72cb;
}

.lang-btn.active {
    background: #7f72cb;
    color: white;
    border-color: #7f72cb;
}

/* ===== ОСНОВНЫЕ СТИЛИ (ваш оригинальный CSS, но с фиксами) ===== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #080808;
    color: #ffffff;
    line-height: 1.4;
    min-height: 100vh;
}

/* Login */
.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: #111111;
    padding: 20px;
}

.login-box {
    background: #131313;
    padding: 30px;
    border-radius: 8px;
    width: 100%;
    max-width: 350px;
}

.login-box h2 {
    text-align: center;
    margin-bottom: 25px;
    color: #ffffff;
    font-weight: 500;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.login-form input {
    padding: 12px;
    background: #111111;
    border: 1px solid #444;
    border-radius: 4px;
    color: #ffffff;
    font-size: 14px;
}

.login-form input:focus {
    outline: none;
    border-color: #7f72cb;
}

 {
    padding: 12px;
    background: #7f72cb;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
}

.login-btn:hover {
    background: #6b5abb;
}

.login-btn:disabled {
    background: #444;
    cursor: not-allowed;
}

/* Registration note */
.registration-note {
    margin-top: 20px;
    padding: 12px;
    background: #1a1a1a;
    border-radius: 4px;
    text-align: center;
    border-left: 3px solid #7f72cb;
}

.registration-note p {
    font-size: 12px;
    color: #ccc;
    margin: 0;
}

.registration-note a {
    color: #7f72cb;
    text-decoration: none;
}

.registration-note a:hover {
    text-decoration: underline;
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: #111111;
    border-bottom: 1px solid #333;
}

.header-left h1 {
    font-size: 18px;
    font-weight: 500;
    color: #ffffff;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-avatar {
    width: 30px;
    height: 30px;
    background: #7f72cb;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 13px;
}

.username {
    color: #ffffff;
    font-size: 14px;
}

.logout-btn {
    padding: 6px 12px;
    background: #111111;
    border: none;
    border-radius: 4px;
    color: #ffffff;
    cursor: pointer;
    font-size: 13px;
}

.logout-btn:hover {
    background: #222;
}

/* Tabs */
.tabs {
    display: flex;
    background: #111111;
    border-bottom: 1px solid #333;
    padding: 0 20px;
}

.tab {
    padding: 12px 20px;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: #ccc;
    cursor: pointer;
    font-size: 14px;
}

.tab.active {
    color: #7f72cb;
    border-bottom-color: #7f72cb;
}

.tab:hover {
    color: #ffffff;
}

/* Main */
.main {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Dropzone */
.dropzone {
    background: #111111;
    border: 2px dashed #333;
    border-radius: 6px;
    padding: 30px;
    text-align: center;
    cursor: pointer;
    margin-bottom: 20px;
    transition: border-color 0.2s ease;
}

.dropzone:hover {
    border-color: #7f72cb;
}

.dropzone p {
    margin-bottom: 8px;
    color: #ffffff;
}

.dropzone small {
    color: #888;
}

/* Ban message */
.ban-message {
    background: #331111;
    border: 1px solid #ff4444;
    border-radius: 6px;
    padding: 20px;
    text-align: center;
    margin-bottom: 20px;
}

.ban-message p {
    color: #ff6b6b;
    margin: 0;
    font-size: 14px;
    font-weight: bold;
}

.ban-message small {
    color: #ff9999;
    font-size: 12px;
}

/* Files Section */
.files-section {
    background: #111111;
    border-radius: 6px;
    padding: 15px;
}

.files-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 12px;
    border-bottom: 1px solid #333;
}

.files-header h3 {
    color: #ffffff;
    font-size: 15px;
    font-weight: 500;
}

.files-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.files-count {
    color: #888;
    font-size: 13px;
}

/* View Toggle */
.view-toggle {
    display: flex;
    background: #111111;
    border: 1px solid #333;
    border-radius: 4px;
    overflow: hidden;
}

.view-btn {
    background: none;
    border: none;
    color: #888;
    cursor: pointer;
    padding: 6px 10px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.view-btn.active {
    background: #7f72cb;
    color: white;
}

.view-btn:hover:not(.active) {
    background: #1a1a1a;
    color: #ffffff;
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: #888;
    font-size: 14px;
}

/* List View */
.file-list.list-view {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.file-list.list-view .file-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: #131313;
    border-radius: 4px;
    transition: background 0.2s ease;
}

.file-list.list-view .file-card:hover {
    background: #1a1a1a;
}

.file-list.list-view .file-preview img {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    object-fit: cover;
    border: 1px solid #333;
}

.file-list.list-view .file-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #111111;
    border-radius: 4px;
    font-size: 16px;
    border: 1px solid #333;
}

.file-list.list-view .file-info {
    flex: 1;
    min-width: 0;
}

.file-list.list-view .file-name {
    font-size: 13px;
    color: #ffffff;
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-list.list-view .file-meta {
    font-size: 11px;
    color: #888;
}

.file-list.list-view .file-actions {
    display: flex;
    gap: 5px;
}

/* Grid View */
.file-list.grid-view {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
    padding: 10px 0;
}

.file-list.grid-view .file-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
    padding: 15px;
    background: #131313;
    border-radius: 8px;
    transition: all 0.2s ease;
    border: 1px solid #222;
    height: 200px;
    justify-content: space-between;
}

.file-list.grid-view .file-card:hover {
    background: #1a1a1a;
    border-color: #7f72cb;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.file-list.grid-view .file-preview {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.file-list.grid-view .file-preview img {
    width: 80px;
    height: 80px;
    border-radius: 6px;
    object-fit: cover;
    border: 1px solid #333;
}

.file-list.grid-view .file-icon {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #111111;
    border-radius: 6px;
    font-size: 32px;
    border: 1px solid #333;
}

.file-list.grid-view .file-info {
    width: 100%;
    min-width: 0;
}

.file-list.grid-view .file-name {
    font-size: 12px;
    color: #ffffff;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

.file-list.grid-view .file-meta {
    font-size: 10px;
    color: #888;
    line-height: 1.3;
}

/* File actions */
.file-actions {
    display: flex;
    gap: 5px;
}

.rename-btn, .delete-btn, .download-btn {
    background: none;
    border: none;
    color: #888;
    cursor: pointer;
    padding: 6px;
    border-radius: 3px;
    font-size: 12px;
    transition: all 0.2s ease;
}

.rename-btn:hover {
    background: #1a1a1a;
    color: #7f72cb;
}

.delete-btn:hover {
    background: #1a1a1a;
    color: #ff4444;
}

.download-btn:hover {
    background: #1a1a1a;
    color: #7f72cb;
}

.file-list.grid-view .file-actions {
    display: flex;
    gap: 8px;
    justify-content: center;
    width: 100%;
    margin-top: 5px;
}

.file-list.grid-view .rename-btn,
.file-list.grid-view .delete-btn,
.file-list.grid-view .download-btn {
    padding: 8px;
    font-size: 14px;
    border-radius: 4px;
}

/* Notification */
.notification {
    position: fixed;
    top: 15px;
    right: 15px;
    padding: 12px 16px;
    border-radius: 4px;
    color: white;
    font-size: 13px;
    z-index: 1000;
    animation: slideIn 0.2s ease;
    max-width: 300px;
    word-wrap: break-word;
}

.notification.success {
    background: #00cc66;
}

.notification.error {
    background: #ff4444;
}

.notification.info {
    background: #7f72cb;
}

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

/* Responsive */
@media (max-width: 768px) {
    .header {
        padding: 12px 15px;
    }
    .tabs {
        padding: 0 15px;
    }
    .main {
        padding: 15px;
    }
    .dropzone {
        padding: 20px 15px;
    }
    .file-list.grid-view {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 10px;
    }
    .file-list.grid-view .file-card {
        height: 160px;
        padding: 12px;
    }
    .file-list.grid-view .file-preview img,
    .file-list.grid-view .file-icon {
        width: 60px;
        height: 60px;
    }
    .file-list.grid-view .file-icon {
        font-size: 24px;
    }
    .files-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    .files-controls {
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 480px) {
    .login-box {
        padding: 20px;
    }
    .header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    .header-right {
        justify-content: center;
    }
    .file-list.grid-view {
        grid-template-columns: repeat(2, 1fr);
    }
    .file-list.grid-view .file-card {
        height: 140px;
        padding: 10px;
    }
    .file-list.grid-view .file-preview img,
    .file-list.grid-view .file-icon {
        width: 50px;
        height: 50px;
    }
    .file-list.grid-view .file-icon {
        font-size: 20px;
    }
}