/* css/lots.css */
/* Стили для страницы со всеми лотами */

/* Хлебные крошки */
.breadcrumbs {
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.breadcrumbs a {
    color: #3498db;
    text-decoration: none;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

.breadcrumbs i {
    color: #bdc3c7;
    margin: 0 10px;
}

.breadcrumbs span {
    color: #7f8c8d;
}

/* Заголовок страницы */
.page-header {
    text-align: center;
    margin-bottom: 40px;
}

.page-header h1 {
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.page-header p {
    color: #7f8c8d;
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Основной контейнер страницы */
.lots-page {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 30px;
}

@media (max-width: 992px) {
    .lots-page {
        grid-template-columns: 1fr;
    }
}

/* Левая колонка - фильтры */
.filters-column {
    position: sticky;
    top: 20px;
    align-self: start;
}

.filters-card {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border: 1px solid #eee;
}

.filter-section {
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 1px solid #eee;
}

.filter-section:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.filter-section h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Форма поиска */
.search-form {
    margin-bottom: 20px;
}

.search-input-group {
    position: relative;
    display: flex;
}

.search-input-group input {
    flex: 1;
    padding: 12px 45px 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-input-group input:focus {
    border-color: #3498db;
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.btn-search {
    position: absolute;
    right: 0;
    top: 0;
    height: 100%;
    padding: 0 15px;
    background: #3498db;
    color: white;
    border: none;
    border-radius: 0 8px 8px 0;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease;
}

.btn-search:hover {
    background-color: #2980b9;
}

/* Категории */
.categories-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.category-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    color: #2c3e50;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.category-item:hover {
    background-color: #f8f9fa;
    color: #3498db;
}

.category-item.active {
    background-color: #3498db;
    color: white;
    border-color: #3498db;
}

.category-count {
    font-size: 0.9rem;
    color: #7f8c8d;
    background-color: #f8f9fa;
    padding: 2px 8px;
    border-radius: 10px;
}

.category-item.active .category-count {
    background-color: rgba(255,255,255,0.2);
    color: white;
}

/* Сортировка */
.sort-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sort-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 15px;
    color: #2c3e50;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.sort-option:hover {
    background-color: #f8f9fa;
    color: #3498db;
}

.sort-option.active {
    background-color: #3498db;
    color: white;
    border-color: #3498db;
}

/* Популярные категории */
.popular-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.popular-category {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    background-color: #f8f9fa;
    color: #2c3e50;
    text-decoration: none;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    flex: 1;
    min-width: calc(50% - 4px);
}

.popular-category:hover {
    background-color: #3498db;
    color: white;
    border-color: #3498db;
}

.popular-category:hover .category-badge {
    background-color: white;
    color: #3498db;
}

.category-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.category-badge {
    background-color: #e0e0e0;
    color: #7f8c8d;
    font-size: 0.8rem;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 8px;
    font-weight: 500;
}

/* Создание лота */
.create-lot-section {
    margin-top: 20px;
    text-align: center;
}

.create-lot-hint {
    font-size: 0.9rem;
    color: #7f8c8d;
    margin-top: 10px;
}

/* Правая колонка - лоты */
.lots-column {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

/* Заголовок лотов */
.lots-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.lots-stats {
    display: flex;
    align-items: center;
    gap: 25px;
    flex-wrap: wrap;
}

.stats-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #7f8c8d;
}

.stats-item strong {
    color: #2c3e50;
    font-weight: 600;
}

.clear-filters {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #e74c3c;
    text-decoration: none;
    font-size: 0.9rem;
}

.clear-filters:hover {
    text-decoration: underline;
}

.view-toggle {
    display: flex;
    gap: 5px;
}

.view-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    color: #7f8c8d;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.view-btn:hover {
    border-color: #3498db;
    color: #3498db;
}

.view-btn.active {
    background-color: #3498db;
    border-color: #3498db;
    color: white;
}

/* Сетка лотов */
.lots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

.lots-grid.active {
    display: grid;
}

.lots-table {
    display: none;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.lots-table.active {
    display: block;
}

/* Карточка лота */
.lot-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.lot-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
    border-color: #3498db;
}

.lot-card-header {
    position: relative;
    height: 200px;
}

.lot-image-link {
    display: block;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.lot-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.lot-image-link:hover .lot-image {
    transform: scale(1.05);
}

.no-image {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: #ecf0f1;
    color: #7f8c8d;
}

.no-image i {
    margin-bottom: 10px;
}

.lot-tags {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: flex-start;
}

.tag {
    font-size: 0.75rem;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 4px;
}

.tag-ending {
    background-color: #e74c3c;
    color: white;
}

.tag-category {
    background-color: rgba(52, 152, 219, 0.9);
    color: white;
}

.lot-card-body {
    padding: 20px;
    flex: 1;
}

.lot-title {
    font-size: 1.1rem;
    margin-bottom: 10px;
    line-height: 1.4;
}

.lot-title a {
    color: #2c3e50;
    text-decoration: none;
}

.lot-title a:hover {
    color: #3498db;
}

.lot-seller {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.lot-stats {
    display: flex;
    gap: 15px;
    margin-top: auto;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #7f8c8d;
    font-size: 0.9rem;
}

.lot-card-footer {
    padding: 15px 20px;
    background-color: #f8f9fa;
    border-top: 1px solid #eee;
}

.lot-price {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.price-label {
    font-size: 0.9rem;
    color: #7f8c8d;
}

.price-amount {
    font-size: 1.3rem;
    font-weight: 700;
    color: #27ae60;
}

/* Табличный вид */
.lots-table table {
    width: 100%;
    border-collapse: collapse;
}

.lots-table th {
    padding: 15px 20px;
    text-align: left;
    background-color: #2c3e50;
    color: white;
    font-weight: 500;
    font-size: 0.9rem;
}

.lots-table td {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
}

.lots-table tbody tr:hover {
    background-color: #f8f9fa;
}

.table-lot-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.table-lot-image {
    width: 60px;
    height: 60px;
    border-radius: 6px;
    object-fit: cover;
    flex-shrink: 0;
}

.table-lot-title {
    display: block;
    color: #2c3e50;
    text-decoration: none;
    font-weight: 500;
    margin-bottom: 5px;
}

.table-lot-title:hover {
    color: #3498db;
}

.table-lot-id {
    color: #7f8c8d;
    font-size: 0.85rem;
}

.category-badge {
    display: inline-block;
    padding: 4px 10px;
    background-color: #e8f4fc;
    color: #3498db;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 500;
}

.table-seller {
    color: #2c3e50;
    font-weight: 500;
}

.table-bids {
    text-align: center;
    font-weight: 600;
    color: #2c3e50;
}

.table-end {
    color: #7f8c8d;
    font-size: 0.9rem;
}

.ending-soon {
    color: #e74c3c;
    font-weight: 500;
    margin-left: 5px;
}

.table-price {
    font-weight: 700;
    color: #27ae60;
    font-size: 1.1rem;
}

.table-actions {
    display: flex;
    gap: 8px;
}

.btn-action {
    width: 35px;
    height: 35px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: 1px solid #ddd;
    color: #7f8c8d;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn-action:hover {
    transform: translateY(-2px);
}

.btn-action.view:hover {
    background-color: #3498db;
    color: white;
    border-color: #3498db;
}

.btn-action.bid:hover {
    background-color: #f39c12;
    color: white;
    border-color: #f39c12;
}

.btn-action.watch:hover {
    background-color: #e74c3c;
    color: white;
    border-color: #e74c3c;
}

/* Пустые лоты */
.empty-lots {
    text-align: center;
    padding: 60px 20px;
    background-color: #f8f9fa;
    border-radius: 10px;
    color: #7f8c8d;
}

.empty-lots i {
    margin-bottom: 20px;
    color: #bdc3c7;
}

.empty-lots h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #2c3e50;
}

.empty-lots p {
    margin-bottom: 25px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.empty-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
}

/* Пагинация */
.pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.page-numbers {
    display: flex;
    gap: 8px;
    align-items: center;
}

.page-prev,
.page-next,
.page-number {
    padding: 8px 15px;
    color: #3498db;
    text-decoration: none;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.page-prev:hover,
.page-next:hover,
.page-number:hover {
    background-color: #f8f9fa;
    border-color: #3498db;
}

.page-number.active {
    background-color: #3498db;
    color: white;
    border-color: #3498db;
}

.page-dots {
    color: #7f8c8d;
    padding: 0 5px;
}

/* Адаптивность */
@media (max-width: 768px) {
    .lots-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .lots-stats {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .lots-grid {
        grid-template-columns: 1fr;
    }
    
    .pagination {
        flex-direction: column;
        gap: 15px;
    }
    
    .page-numbers {
        order: 1;
    }
    
    .page-prev,
    .page-next {
        order: 2;
    }
    
    .lots-table {
        overflow-x: auto;
    }
    
    .lots-table table {
        min-width: 800px;
    }
}

@media (max-width: 576px) {
    .page-header h1 {
        font-size: 2rem;
    }
    
    .empty-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .empty-actions .btn {
        width: 100%;
        max-width: 250px;
    }
}