/* Main Page Styles */

/* Hero Banner */
.hero-banner {
    position: relative;
    background: linear-gradient(135deg, #2c2c2c 0%, #1a1a1a 100%);
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
}

.hero-image-full {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-image-full img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-text {
    color: white;
}

.hero-subtitle {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    opacity: 0.9;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0;
}

.highlight {
    color: var(--primary-color);
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

.hero-image img {
    max-width: 500px;
    height: auto;
}

.hero-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.2);
    border: none;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    z-index: 20;
}

.hero-nav-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.hero-nav-btn svg {
    width: 24px;
    height: 24px;
    color: white;
}

.hero-nav-btn.prev {
    left: 2rem;
}

.hero-nav-btn.next {
    right: 2rem;
}

/* Hero Banner Indicators */
.hero-indicators {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
    z-index: 20;
}

.hero-indicators .indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s;
}

.hero-indicators .indicator:hover {
    background: rgba(255, 255, 255, 0.8);
}

.hero-indicators .indicator.active {
    background: var(--primary-color);
    width: 30px;
    border-radius: 5px;
}

/* Search Section */
.search-section {
    padding: 3rem 2rem;
    background: white;
    display: flex;
    justify-content: center;
}

.search-box {
    max-width: 1200px;
    width: 100%;
    border: 3px solid var(--primary-color);
    border-radius: 0.5rem;
    padding: 2rem;
}

.search-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.highlight-text {
    color: var(--primary-color);
}

.search-form {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr auto;
    gap: 1.5rem;
    align-items: end;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #374151;
}

.form-select {
    padding: 0.75rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
    font-size: 0.9375rem;
    background: white;
}

.location-select {
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.2s;
}

.location-select:hover {
    border-color: var(--primary-color);
    background: #fff7ed;
}

.location-select .placeholder {
    color: #9ca3af;
}

.date-input-group {
    display: flex;
    gap: 0.5rem;
}

.date-input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
    font-size: 0.9375rem;
    background: white;
    transition: all 0.2s;
}

.date-input:hover {
    border-color: var(--primary-color);
}

.date-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1);
}

.location-select::after {
    content: '▼';
    font-size: 0.75rem;
    color: #9ca3af;
}

.date-group .date-range {
    padding: 0.75rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
    font-size: 0.9375rem;
    color: #6b7280;
}

.search-btn {
    padding: 0.875rem 2.5rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 0.375rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.search-btn:hover {
    background-color: var(--primary-hover);
}

/* Companies Section */
.companies-section {
    max-width: 1200px;
    margin: 3rem auto;
    padding: 0 2rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 2rem;
}

.section-title .count {
    color: var(--primary-color);
}

.companies-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.company-card {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    padding: 1.5rem;
}

.company-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.company-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.badge {
    background-color: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
}

.company-name {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0;
}

.company-phone {
    font-size: 0.9375rem;
    color: #6b7280;
}

.company-actions {
    display: flex;
    gap: 0.75rem;
}

.btn-call {
    padding: 0.625rem 1.25rem;
    background: white;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-call:hover {
    background-color: #fff7ed;
}

.btn-detail {
    padding: 0.625rem 1.25rem;
    background: #1f2937;
    border: none;
    color: white;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-detail:hover {
    background: #111827;
}

.cars-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
}

.car-item {
    text-align: center;
}

.car-image {
    background: #f9fafb;
    border-radius: 0.375rem;
    overflow: hidden;
    aspect-ratio: 3 / 2;
    margin-bottom: 0.5rem;
}

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

.car-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: #111827;
}

.more-btn {
    display: block;
    margin: 3rem auto 0;
    padding: 1rem 3rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 0.375rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.more-btn:hover {
    background-color: var(--primary-hover);
}

/* Statistics Section */
.stats-section {
    background: #f9fafb;
    padding: 3rem 2rem;
    display: flex;
    justify-content: center;
    gap: 4rem;
}

.stat-item {
    text-align: center;
}

.stat-label {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
}

.stat-value {
    font-size: 2.25rem;
    font-weight: 700;
    color: #111827;
    margin: 0.5rem 0;
}

.stat-value.highlight-value {
    color: var(--primary-color);
}

.stat-desc {
    font-size: 0.75rem;
    color: #9ca3af;
}

/* Auto Find Section */
.auto-find-section {
    max-width: 1200px;
    margin: 4rem auto;
    padding: 0 2rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.section-title-main {
    font-size: 1.75rem;
    font-weight: 700;
    margin: 0;
    text-align: center;
}

.view-all {
    color: #6b7280;
    font-size: 0.875rem;
    text-decoration: none;
}

.view-all:hover {
    color: var(--primary-color);
}

.auto-find-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
}

.find-card {
    position: relative;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s;
}

.find-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.card-badge {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    background: #3b82f6;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
    z-index: 10;
}

.card-image {
    position: relative;
    aspect-ratio: 4 / 3;
    background: #f3f4f6;
}

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

.card-info {
    padding: 1rem;
}

.card-location {
    font-size: 0.75rem;
    color: #6b7280;
    margin-bottom: 0.25rem;
}

.card-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: #111827;
    line-height: 1.4;
}

/* Used Cars Section */
.used-cars-section {
    background: #f9fafb;
    padding: 4rem 2rem;
}

.section-subtitle {
    text-align: center;
    font-size: 1rem;
    color: #6b7280;
    margin-top: 0.5rem;
    margin-bottom: 2rem;
}

.used-cars-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.used-car-card {
    position: relative;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s;
}

.used-car-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.car-badge {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
    z-index: 10;
}

.car-image-large {
    position: relative;
    aspect-ratio: 3 / 2;
    background: #f3f4f6;
}

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

.car-details {
    padding: 1rem;
}

.car-model {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #111827;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.car-price {
    font-size: 0.875rem;
    color: #6b7280;
}

/* Location Modal */
.location-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
}

.location-modal.active {
    display: block;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

.modal-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 0.5rem;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.modal-tabs {
    display: flex;
    gap: 0.5rem;
}

.tab-btn {
    padding: 0.5rem 1.5rem;
    background: transparent;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
    font-size: 0.9375rem;
    font-weight: 600;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.2s;
}

.tab-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.tab-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.modal-close {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.25rem;
    transition: all 0.2s;
}

.modal-close:hover {
    background: #f3f4f6;
}

.modal-close svg {
    width: 24px;
    height: 24px;
    color: #6b7280;
}

.modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
}

.search-area {
    margin-bottom: 1.5rem;
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input-wrapper svg {
    position: absolute;
    left: 1rem;
    width: 20px;
    height: 20px;
    color: #9ca3af;
}

.search-input-wrapper input {
    width: 100%;
    padding: 0.875rem 1rem 0.875rem 3rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
    font-size: 0.9375rem;
    transition: all 0.2s;
}

.search-input-wrapper input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(255, 138, 0, 0.1);
}

.transport-section {
    margin-bottom: 1.5rem;
}

.section-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.75rem;
}

.transport-buttons {
    display: flex;
    gap: 0.75rem;
}

.transport-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s;
}

.transport-btn:hover {
    border-color: var(--primary-color);
    background: #fff7ed;
    color: var(--primary-color);
}

.transport-btn svg {
    width: 20px;
    height: 20px;
}

.location-section {
    margin-bottom: 1rem;
}

.location-content {
    display: flex;
    gap: 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
    overflow: hidden;
    min-height: 300px;
    max-height: 400px;
}

.location-sidebar {
    width: 200px;
    background: #f9fafb;
    border-right: 1px solid #e5e7eb;
    overflow-y: auto;
}

.location-category {
    padding: 0.875rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    border-bottom: 1px solid #e5e7eb;
    transition: all 0.2s;
}

.location-category:hover {
    background: #f3f4f6;
}

.location-category.active {
    background: white;
    color: var(--primary-color);
    border-left: 3px solid var(--primary-color);
}

.location-main {
    flex: 1;
    padding: 0.5rem;
    overflow-y: auto;
}

.location-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.location-item {
    padding: 0.5rem 1rem;
    background: transparent;
    border: none;
    border-bottom: 1px solid #f3f4f6;
    font-size: 0.875rem;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s;
    text-align: left;
    display: flex;
    align-items: center;
}

.location-item:hover {
    background: #f9fafb;
    color: var(--primary-color);
}

.location-item:last-child {
    border-bottom: none;
}

.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid #e5e7eb;
    display: flex;
    justify-content: center;
}

.btn-modal-close {
    padding: 0.75rem 3rem;
    background: #6b7280;
    color: white;
    border: none;
    border-radius: 0.375rem;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-modal-close:hover {
    background: #4b5563;
}

.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: #9ca3af;
}

.empty-state svg {
    width: 48px;
    height: 48px;
    margin: 0 auto 1rem;
    opacity: 0.3;
}

/* Responsive */
@media (max-width: 1024px) {
    .hero-content {
        flex-direction: column;
        text-align: center;
    }
    
    .search-form {
        grid-template-columns: 1fr;
    }
    
    .cars-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .auto-find-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .used-cars-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .modal-container {
        width: 95%;
        max-height: 85vh;
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .company-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .cars-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-section {
        flex-direction: column;
        gap: 2rem;
    }
    
    .auto-find-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .used-cars-grid {
        grid-template-columns: 1fr;
    }
    
    .location-content {
        flex-direction: column;
        min-height: 400px;
    }
    
    .location-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #e5e7eb;
        max-height: 150px;
    }
    
    .transport-buttons {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .hero-banner {
        height: 300px;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .search-box {
        padding: 1.5rem;
    }
    
    .cars-grid {
        grid-template-columns: 1fr;
    }
    
    .auto-find-grid {
        grid-template-columns: 1fr;
    }
}
