* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ========== ТЕМНЫЙ ФОН ========== */
body {
    background: #0a0a0f;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Color Emoji', sans-serif;
    color: #e0e0e0;
    position: relative;
    min-height: 100vh;
}

/* Убираем фоновое изображение для темной темы */
body::before {
    display: none;
}

/* Для мобильных устройств */
@media (max-width: 768px) {
    body::before {
        display: none;
    }
}

@media (max-width: 480px) {
    body::before {
        display: none;
    }
}

/* ========== УГЛОВЫЕ ЭЛЕМЕНТЫ ========== */
.corner {
    position: fixed;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 8px 18px;
    border-radius: 30px;
    color: white;
    font-size: 14px;
    font-weight: 600;
    z-index: 10000;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    pointer-events: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    letter-spacing: 0.5px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.top-left {
    top: 15px;
    left: 15px;
}

.top-right {
    top: 15px;
    right: 15px;
    font-family: 'Courier New', monospace;
    font-weight: 500;
}

.bottom-left {
    bottom: 15px;
    left: 15px;
    font-size: 12px;
    opacity: 0.8;
}

.bottom-right {
    bottom: 15px;
    right: 15px;
    background: rgba(139, 92, 246, 0.6);
    backdrop-filter: blur(10px);
    font-weight: bold;
}

/* Для мобильных устройств */
@media (max-width: 768px) {
    .corner {
        padding: 5px 12px;
        font-size: 10px;
        border-radius: 20px;
    }
    .top-left, .top-right {
        top: 8px;
    }
    .bottom-left, .bottom-right {
        bottom: 8px;
    }
    .top-left {
        left: 8px;
    }
    .top-right {
        right: 8px;
    }
    .bottom-left {
        left: 8px;
    }
    .bottom-right {
        right: 8px;
    }
}

/* Улучшаем читаемость контента на мобильных */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    z-index: 1;
}

/* Увеличиваем контрастность блоков на мобильных */
@media (max-width: 768px) {
    header,
    .price-list,
    .category-section,
    .brand-section,
    .modal-content {
        background: rgba(20, 20, 35, 0.95) !important;
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }

    table {
        background: rgba(20, 20, 35, 0.9) !important;
    }

    th {
        background: rgba(40, 40, 70, 0.95) !important;
    }
}

/* ========== ЗАГОЛОВКИ И ОСНОВНЫЕ БЛОКИ ========== */
header {
    background: rgba(25, 25, 45, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.05);
}

h1 {
    color: #f0f0f0;
    margin-bottom: 15px;
    font-size: 28px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

/* ========== ИНФОРМАЦИЯ О ПОЛЬЗОВАТЕЛЕ ========== */
.user-info {
    background: rgba(30, 30, 60, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 10px 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
    border: 1px solid rgba(255,255,255,0.05);
}

.user-info span {
    font-size: 14px;
    font-weight: 500;
    color: #d0d0d0;
}

.logout-btn {
    background: #c0392b;
    color: white;
    padding: 5px 15px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 14px;
    margin-left: auto;
    transition: all 0.3s;
}

.logout-btn:hover {
    background: #e74c3c;
    transform: translateY(-1px);
}

/* ========== АДМИН-ССЫЛКИ ========== */
.admin-links {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.admin-link {
    background: #6c3483;
    color: white;
    padding: 8px 15px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s;
}

.admin-link:hover {
    background: #8e44ad;
    transform: translateY(-1px);
}

/* ========== АВТООБНОВЛЕНИЕ ========== */
.auto-update-info {
    background: rgba(30, 30, 60, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 10px 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
    border: 1px solid rgba(255,255,255,0.05);
}

.update-status, .update-timer {
    font-size: 14px;
    font-weight: 500;
    color: #d0d0d0;
}

.update-status {
    color: #4ade80;
}

.update-status.paused {
    color: #f87171;
}

.btn-small {
    padding: 5px 12px;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-small:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

/* ========== ФИЛЬТРЫ ========== */
.filters {
    display: flex;
    gap: 15px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
    flex: 1;
    min-width: 200px;
}

.filter-group label {
    font-size: 14px;
    font-weight: 600;
    color: #b0b0b0;
}

.filter-group select,
.filter-group input {
    padding: 10px 12px;
    border: 2px solid #2a2a4a;
    border-radius: 8px;
    font-size: 14px;
    background: rgba(20, 20, 40, 0.9);
    color: #e0e0e0;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    cursor: pointer;
    transition: all 0.3s;
}

.filter-group select option {
    background: #1a1a2e;
    color: #e0e0e0;
}

.filter-group select:hover,
.filter-group input:hover {
    border-color: #3b82f6;
}

.filter-group input:focus,
.filter-group select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

/* ========== КНОПКИ ========== */
.btn {
    padding: 10px 24px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    background: #3b82f6;
    color: white;
}

.btn-primary:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.btn-secondary {
    background: #4a4a6a;
    color: white;
}

.btn-secondary:hover {
    background: #5a5a7a;
    transform: translateY(-1px);
}

.btn-refresh {
    padding: 10px 24px;
    background: #22c55e;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-refresh:hover {
    background: #16a34a;
    transform: translateY(-1px);
}

/* ========== ПРАЙС-ЛИСТ ========== */
.price-list {
    background: rgba(20, 20, 40, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.05);
}

/* ========== СЕКЦИИ КАТЕГОРИЙ ========== */
.category-section {
    margin-bottom: 40px;
    background: rgba(25, 25, 50, 0.4);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-radius: 12px;
    padding: 15px;
    border: 1px solid rgba(255,255,255,0.03);
}

.category-title {
    font-size: 24px;
    color: #f0f0f0;
    border-left: 4px solid #3b82f6;
    padding: 12px 20px;
    margin-bottom: 20px;
    margin-top: 20px;
    background: rgba(30, 30, 60, 0.5);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border-radius: 0 10px 10px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.category-title:first-child {
    margin-top: 0;
}

/* ========== СЕКЦИИ БРЕНДОВ ========== */
.brand-section {
    margin-bottom: 35px;
    background: rgba(25, 25, 50, 0.3);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-radius: 8px;
    padding: 15px;
    border: 1px solid rgba(255,255,255,0.03);
}

.brand-title {
    font-size: 20px;
    color: #e8e8e8;
    padding: 10px 15px;
    border-bottom: 2px solid rgba(60, 60, 100, 0.3);
    margin-bottom: 15px;
    background: rgba(30, 30, 60, 0.3);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-radius: 8px 8px 0 0;
}

/* ========== СЕКЦИИ СУБКАТЕГОРИЙ ========== */
.subcategory-section {
    margin-bottom: 20px;
    margin-left: 20px;
}

.subcategory-title {
    font-size: 16px;
    color: #b0b0c0;
    padding: 8px 15px;
    margin: 10px 0 10px 10px;
    border-left: 3px solid rgba(100, 100, 150, 0.3);
    background: rgba(30, 30, 60, 0.25);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border-radius: 0 6px 6px 0;
}

/* ========== ТАБЛИЦЫ ========== */
.products-table {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    background: rgba(20, 20, 40, 0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border-radius: 8px;
    overflow: hidden;
}

thead {
    background: rgba(40, 40, 80, 0.4);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-bottom: 2px solid rgba(60, 60, 100, 0.3);
}

th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    color: #b0b0c0;
}

td {
    padding: 10px 12px;
    border-bottom: 1px solid rgba(60, 60, 100, 0.15);
    vertical-align: middle;
    color: #d0d0d0;
}

tr:hover {
    background: rgba(50, 50, 90, 0.25);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.model {
    font-weight: 600;
    color: #e8e8e8;
}

.price {
    font-weight: 700;
    color: #4ade80;
    font-size: 16px;
}

.actions {
    white-space: nowrap;
}

/* ========== КНОПКИ ДЕЙСТВИЙ ========== */
.btn-order, .btn-discount {
    padding: 6px 12px;
    margin: 0 4px;
    border: none;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-order {
    background: #22c55e;
    color: white;
}

.btn-order:hover {
    background: #16a34a;
    transform: scale(1.05);
}

.btn-discount {
    background: #f59e0b;
    color: white;
}

.btn-discount:hover {
    background: #d97706;
    transform: scale(1.05);
}

/* ========== МОДАЛЬНЫЕ ОКНА ========== */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.7);
    animation: fadeIn 0.3s;
}

.modal-content {
    background: rgba(20, 20, 40, 0.98);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    margin: 5% auto;
    padding: 30px;
    border-radius: 16px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 4px 30px rgba(0,0,0,0.5);
    animation: slideIn 0.3s;
    border: 1px solid rgba(255,255,255,0.05);
    color: #e0e0e0;
}

.modal-content h2 {
    color: #f0f0f0;
}

.close {
    color: #888;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.close:hover {
    color: #fff;
}

.product-info {
    background: rgba(30, 30, 60, 0.5);
    padding: 15px;
    border-radius: 8px;
    margin: 20px 0;
}

.product-info p {
    margin: 8px 0;
    color: #d0d0d0;
}

.product-info strong {
    color: #f0f0f0;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #b0b0b0;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 10px;
    border: 2px solid #2a2a4a;
    border-radius: 8px;
    font-size: 14px;
    transition: 0.3s;
    background: rgba(10, 10, 30, 0.9);
    color: #e0e0e0;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #22c55e;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2);
}

.form-group select option {
    background: #1a1a2e;
    color: #e0e0e0;
}

.hint {
    display: block;
    font-size: 12px;
    color: #888;
    margin-top: 5px;
}

.btn-submit {
    width: 100%;
    padding: 12px;
    background: #22c55e;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

.btn-submit:hover {
    background: #16a34a;
    transform: translateY(-2px);
}

/* ========== УВЕДОМЛЕНИЯ ========== */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    z-index: 1001;
    animation: slideInRight 0.3s;
    display: none;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.notification.success {
    background: #22c55e;
}

.notification.error {
    background: #ef4444;
}

.notification.info {
    background: #3b82f6;
}

/* ========== ИКОНКА УВЕДОМЛЕНИЙ ========== */
.notifications-icon {
    position: relative;
    text-decoration: none;
    color: #d0d0d0;
    font-size: 20px;
    padding: 5px;
}

.badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #f59e0b;
    color: white;
    border-radius: 50%;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: bold;
    min-width: 18px;
    text-align: center;
}

/* ========== СОСТОЯНИЯ ЗАГРУЗКИ ========== */
.loading, .error, .no-results {
    text-align: center;
    padding: 40px;
    font-size: 18px;
}

.loading {
    color: #3b82f6;
}

.error {
    color: #ef4444;
}

.no-results {
    color: #888;
}

/* ========== АДМИН-РЕДАКТИРОВАНИЕ ========== */
.admin-actions {
    margin-top: 20px;
    padding: 10px;
    background: rgba(30, 30, 60, 0.5);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-radius: 5px;
}

.edit-mode-btn {
    background: #f59e0b;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    margin-right: 10px;
    transition: all 0.3s;
}

.edit-mode-btn.active {
    background: #22c55e;
}

.price.editable {
    cursor: pointer;
    background: rgba(245, 158, 11, 0.15);
    padding: 3px 6px;
    border-radius: 3px;
    transition: background 0.2s;
    display: inline-block;
}

.price.editable:hover {
    background: rgba(245, 158, 11, 0.3);
}

.quantity.editable {
    cursor: pointer;
    background: rgba(59, 130, 246, 0.15);
    padding: 3px 6px;
    border-radius: 3px;
    transition: background 0.2s;
    display: inline-block;
}

.quantity.editable:hover {
    background: rgba(59, 130, 246, 0.3);
}

.edit-input {
    width: 100px;
    padding: 5px;
    border: 2px solid #f59e0b;
    border-radius: 3px;
    font-size: 14px;
    background: rgba(10, 10, 30, 0.9);
    color: #e0e0e0;
}

.save-btn {
    background: #22c55e;
    color: white;
    border: none;
    padding: 3px 8px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
    margin-left: 5px;
}

.cancel-btn {
    background: #ef4444;
    color: white;
    border: none;
    padding: 3px 8px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
    margin-left: 5px;
}

.btn-edit-full {
    background: #f59e0b;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
    margin-left: 5px;
    transition: background 0.3s;
}

.btn-edit-full:hover {
    background: #d97706;
}

.add-product-btn {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    margin-left: 10px;
    transition: background 0.3s;
}

.add-product-btn:hover {
    background: #2563eb;
}

.code-hint {
    color: #666;
    font-size: 10px;
    display: block;
    margin-top: 3px;
}

/* ========== МОДАЛЬНОЕ ОКНО РЕДАКТИРОВАНИЯ ========== */
.edit-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.7);
    animation: fadeIn 0.3s;
}

.edit-modal-content {
    background: rgba(20, 20, 40, 0.98);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    margin: 5% auto;
    padding: 25px;
    border-radius: 12px;
    width: 90%;
    max-width: 650px;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    animation: slideDown 0.3s;
    border: 1px solid rgba(255,255,255,0.05);
    color: #e0e0e0;
}

.edit-modal-content h2 {
    margin-top: 0;
    color: #f0f0f0;
    border-bottom: 2px solid #f59e0b;
    padding-bottom: 10px;
}

.edit-form-group {
    margin-bottom: 15px;
}

.edit-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #b0b0b0;
    font-size: 14px;
}

.edit-form-group input,
.edit-form-group textarea,
.edit-form-group select {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid #2a2a4a;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
    background: rgba(10, 10, 30, 0.9);
    color: #e0e0e0;
}

.edit-form-group input:focus,
.edit-form-group textarea:focus,
.edit-form-group select:focus {
    outline: none;
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}

.edit-form-group select option {
    background: #1a1a2e;
    color: #e0e0e0;
}

.edit-form-group input[type="checkbox"] {
    width: auto;
    margin-right: 8px;
}

.edit-buttons {
    display: flex;
    gap: 10px;
    margin-top: 25px;
}

.edit-buttons button {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.3s;
}

.btn-save {
    background: #22c55e;
    color: white;
}

.btn-save:hover {
    background: #16a34a;
}

.btn-delete {
    background: #ef4444;
    color: white;
}

.btn-delete:hover {
    background: #dc2626;
}

.btn-cancel {
    background: #4a4a6a;
    color: white;
}

.btn-cancel:hover {
    background: #5a5a7a;
}

/* ========== КНОПКА СМЕНЫ ПАРОЛЯ ========== */
.change-password-btn {
    background: #f59e0b;
    color: white;
    border: none;
    padding: 5px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    margin-left: 10px;
    transition: all 0.3s;
}

.change-password-btn:hover {
    background: #d97706;
    transform: translateY(-1px);
}

/* ========== КНОПКА «НАВЕРХ» ========== */
#scroll-top-btn {
    position: fixed;
    right: 16px;
    bottom: 16px;
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 50%;
    background: rgba(59, 130, 246, 0.55);
    color: #fff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    z-index: 9000;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    transition: background 0.2s, transform 0.2s;
}

#scroll-top-btn.visible {
    display: flex;
}

#scroll-top-btn:hover {
    background: rgba(59, 130, 246, 0.85);
    transform: translateY(-2px);
}

/* ========== КОММЕНТАРИИ ========== */
.comment-cell {
    max-width: 200px;
    word-wrap: break-word;
}

.comment-text {
    color: #999;
    font-style: italic;
    font-size: 12px;
    display: inline-block;
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.comment-text:hover {
    white-space: normal;
    word-wrap: break-word;
}

.btn-edit-comment {
    background: #8b5cf6;
    color: white;
    border: none;
    padding: 2px 6px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 10px;
    margin-left: 5px;
    transition: all 0.3s;
}

.btn-edit-comment:hover {
    background: #7c3aed;
}

/* ========== ПОИСК ТОВАРОВ (АДМИН) ========== */
.search-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.7);
    animation: fadeIn 0.3s;
}

.search-modal-content {
    background: rgba(20, 20, 40, 0.98);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    margin: 5% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 800px;
    max-height: 85vh;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    animation: slideDown 0.3s;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(255,255,255,0.05);
}

.search-header {
    padding: 20px;
    background: linear-gradient(135deg, #1a1a2e 0%, #2d1b4e 100%);
    color: white;
}

.search-header h2 {
    margin: 0 0 10px 0;
    font-size: 24px;
    color: #f0f0f0;
}

.search-input-wrapper {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.search-input-wrapper input {
    flex: 1;
    padding: 12px 15px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    outline: none;
    background: rgba(255, 255, 255, 0.95);
    color: #1a1a2e;
}

.search-input-wrapper button {
    padding: 12px 24px;
    background: #f59e0b;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s;
}

.search-input-wrapper button:hover {
    background: #d97706;
    transform: translateY(-1px);
}

.search-results {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    max-height: 500px;
    background: rgba(10, 10, 30, 0.5);
}

.search-result-item {
    background: rgba(30, 30, 60, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 15px;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.search-result-item:hover {
    background: rgba(50, 50, 90, 0.8);
    border-color: #f59e0b;
    transform: translateX(5px);
}

.search-result-item.selected {
    background: rgba(245, 158, 11, 0.15);
    border-color: #f59e0b;
}

.result-model {
    font-size: 18px;
    font-weight: bold;
    color: #f0f0f0;
    margin-bottom: 5px;
}

.result-code {
    font-size: 12px;
    color: #666;
    margin-bottom: 5px;
}

.result-details {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    font-size: 13px;
    color: #999;
    margin-bottom: 10px;
}

.result-price {
    font-size: 20px;
    font-weight: bold;
    color: #4ade80;
}

.result-price.editable {
    cursor: pointer;
    background: rgba(245, 158, 11, 0.15);
    padding: 5px 10px;
    border-radius: 5px;
    display: inline-block;
}

.result-price.editable:hover {
    background: rgba(245, 158, 11, 0.3);
}

.result-actions {
    margin-top: 10px;
    display: flex;
    gap: 10px;
}

.result-actions button {
    padding: 6px 12px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s;
}

.btn-edit-price {
    background: #22c55e;
    color: white;
}

.btn-edit-full-search {
    background: #f59e0b;
    color: white;
}

.no-results-search {
    text-align: center;
    padding: 40px;
    color: #888;
}

.search-loading {
    text-align: center;
    padding: 40px;
    color: #8b5cf6;
}

.close-search {
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 28px;
    cursor: pointer;
    color: #aaa;
}

.close-search:hover {
    color: #f59e0b;
}

/* ========== РЕДАКТИРУЕМАЯ ЦЕНА В ТАБЛИЦЕ ========== */
.editable-price-inline {
    cursor: pointer;
    background: rgba(245, 158, 11, 0.15);
    padding: 3px 6px;
    border-radius: 3px;
    transition: background 0.2s;
    display: inline-block;
}

.editable-price-inline:hover {
    background: rgba(245, 158, 11, 0.3);
}

/* ========== АНИМАЦИИ ========== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* ========== АДАПТИВНОСТЬ ДЛЯ МОБИЛЬНЫХ УСТРОЙСТВ ========== */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }

    .filters {
        flex-direction: column;
    }

    .filter-group {
        width: 100%;
    }

    .filter-group select,
    .filter-group input {
        width: 100%;
    }

    .btn, .btn-refresh {
        width: 100%;
    }

    .auto-update-info {
        flex-direction: column;
        align-items: flex-start;
    }

    th, td {
        padding: 8px;
        font-size: 12px;
    }

    .category-title {
        font-size: 20px;
    }

    .brand-title {
        font-size: 18px;
    }

    .price {
        font-size: 14px;
    }

    .btn-order, .btn-discount {
        padding: 10px 15px;
        font-size: 14px;
        margin: 3px;
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }

    .actions {
        white-space: normal;
    }

    .modal-content {
        margin: 10% auto;
        padding: 20px;
        width: 95%;
    }

    .subcategory-section {
        margin-left: 10px;
    }

    .btn-order, .btn-discount, .btn-edit-full, .btn-edit-comment {
        padding: 10px 15px;
        margin: 4px;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 22px;
    }

    .category-title {
        font-size: 18px;
    }

    .brand-title {
        font-size: 16px;
    }

    table {
        font-size: 11px;
    }

    th, td {
        padding: 6px;
    }
}
/* ========== КНОПКА «ОТМЕНА» В ФОРМАХ ========== */
.edit-buttons .btn-cancel {
    background: #4b5563;
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
}
.edit-buttons .btn-cancel:hover {
    background: #6b7280;
}
