/**
 * Vehicles Archive & Single Vehicle Styles
 * 
 * @package Marshall_Motors
 */

/* ========================================
   Page Header
   ======================================== */
.page-header-section {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    padding: 50px 0 40px;
    text-align: center;
    color: var(--color-white);
}

.page-header-section .page-title {
    font-size: clamp(36px, 5vw, 56px);
    font-weight: 800;
    margin: 0 0 16px 0;
    color: var(--color-white);
}

.page-header-section .page-subtitle {
    font-size: 20px;
    opacity: 0.9;
    margin: 0;
}

/* ========================================
   Filters Section
   ======================================== */
.filters-section {
    background-color: var(--color-white);
    padding: 32px 0;
    border-bottom: 1px solid var(--color-border);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.filter-item {
    display: flex;
    flex-direction: column;
}

.filter-item label {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    color: var(--color-primary);
}

.filter-item select {
    padding: 12px 16px;
    border: 2px solid var(--color-border);
    border-radius: var(--border-radius-sm);
    font-size: 15px;
    background-color: var(--color-white);
    transition: var(--transition-base);
    cursor: pointer;
}

.filter-item select:hover,
.filter-item select:focus {
    border-color: var(--color-accent);
    outline: none;
}

.filters-toggle {
    display: none;
    width: 100%;
    padding: 16px;
    background: var(--color-accent);
    color: var(--color-white);
    border: none;
    border-radius: var(--border-radius-sm);
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filters-toggle svg {
    transition: transform 0.3s ease;
}

.filters-toggle.active svg {
    transform: rotate(180deg);
}

@media (max-width: 768px) {
    .filters-toggle {
        display: flex;
    }
    
    .car-filter-form {
        display: none;
    }
    
    .car-filter-form.active {
        display: block;
    }
    
    .filters-grid {
        grid-template-columns: 1fr;
    }
}

.car-card-wrapper {
    transition: opacity 0.3s ease;
}

.no-results-message {
    text-align: center;
    padding: 80px 20px;
}

.no-results-message h2 {
    font-size: 32px;
    margin-bottom: 16px;
}

.no-results-message p {
    font-size: 18px;
    color: var(--color-secondary);
}

/* ========================================
   Results Section
   ======================================== */
.results-section {
    padding: 40px 0 80px;
    background-color: #fafbfc;
}

.results-header {
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--color-border);
}

.results-count {
    font-size: 18px;
    font-weight: 600;
    color: var(--color-secondary);
    margin: 0;
}

.no-results {
    text-align: center;
    padding: 80px 20px;
}

.no-results h2 {
    font-size: 32px;
    margin-bottom: 16px;
}

.no-results p {
    font-size: 18px;
    color: var(--color-secondary);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 60px;
}

.pagination .page-numbers {
    padding: 12px 20px;
    background-color: var(--color-white);
    border: 2px solid var(--color-border);
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    transition: var(--transition-base);
}

.pagination .page-numbers:hover,
.pagination .page-numbers.current {
    background-color: var(--color-accent);
    color: var(--color-white);
    border-color: var(--color-accent);
}

/* ========================================
   Single Car - Header
   ======================================== */
.car-header-section {
    background-color: var(--color-white);
    padding: 40px 0;
    border-bottom: 1px solid var(--color-border);
}

.car-header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 32px;
    flex-wrap: wrap;
}

.car-title-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 20px;
}

.car-title {
    font-size: clamp(32px, 5vw, 48px);
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.02em;
}

.car-price-wrapper .car-price {
    font-size: clamp(36px, 5vw, 56px);
    font-weight: 900;
    color: var(--color-accent);
    letter-spacing: -0.03em;
}

/* ========================================
   Car Gallery
   ======================================== */
.car-gallery-section {
    padding: 48px 0;
    background-color: #fafbfc;
}

.car-main-gallery {
    background-color: var(--color-white);
    border-radius: var(--border-radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.main-image {
    width: 100%;
    height: 600px;
    overflow: hidden;
    background-color: var(--color-light-gray);
}

.main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-thumbnails {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
    padding: 20px;
    background-color: var(--color-light-gray);
}

.thumbnail-item {
    aspect-ratio: 4/3;
    overflow: hidden;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: var(--transition-base);
}

.thumbnail-item:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-md);
}

.thumbnail-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ========================================
   Car Details
   ======================================== */
.car-details-section {
    padding: 60px 0 100px;
}

.car-details-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 48px;
}

.detail-block {
    background-color: var(--color-white);
    padding: 40px;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-sm);
    margin-bottom: 32px;
}

.detail-block h2 {
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 32px 0;
    padding-bottom: 16px;
    border-bottom: 3px solid var(--color-accent);
}

.specs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 24px;
}

.spec-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.spec-label {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--color-secondary);
}

.spec-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--color-primary);
}

.features-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.feature-badge {
    padding: 10px 20px;
    background-color: var(--color-light-gray);
    border-radius: 24px;
    font-size: 14px;
    font-weight: 600;
    color: var(--color-primary);
    border: 1px solid var(--color-border);
}

.car-description {
    font-size: 16px;
    line-height: 1.8;
    color: var(--color-secondary);
}

/* ========================================
   Sidebar
   ======================================== */
.car-sidebar {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.contact-card,
.share-card {
    background-color: var(--color-white);
    padding: 32px;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-sm);
}

.contact-card h3 {
    font-size: 24px;
    font-weight: 700;
    margin: 0 0 12px 0;
}

.contact-card p {
    color: var(--color-secondary);
    margin-bottom: 24px;
}

.contact-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btn-contact {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.share-card h4 {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 16px 0;
}

.share-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.share-btn {
    padding: 10px 16px;
    background-color: var(--color-light-gray);
    border-radius: var(--border-radius-sm);
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    transition: var(--transition-base);
}

.share-btn:hover {
    background-color: var(--color-accent);
    color: var(--color-white);
}

/* ========================================
   Similar Vehicles
   ======================================== */
.similar-vehicles-section {
    padding: 80px 0;
    background-color: var(--color-light-gray);
}

.similar-vehicles-section h2 {
    text-align: center;
    font-size: 36px;
    font-weight: 800;
    margin: 0 0 48px 0;
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 1024px) {
    .car-details-grid {
        grid-template-columns: 1fr;
    }
    
    .car-sidebar {
        order: -1;
    }
}

@media (max-width: 768px) {
    .filters-grid {
        grid-template-columns: 1fr;
    }
    
    .filter-actions {
        flex-direction: column;
    }
    
    .filter-actions .btn {
        width: 100%;
    }
    
    .main-image {
        height: 400px;
    }
    
    .specs-grid {
        grid-template-columns: 1fr;
    }
    
    .detail-block {
        padding: 24px;
    }
}
