/**
 * Hauptstil für die öffentliche AutoHaus-Website
 * Responsives Design mit Mobile-First-Ansatz
 */

/* Basis-Styling */
:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --dark-color: #212529;
    --light-color: #f8f9fa;
    --danger-color: #dc3545;
    --success-color: #198754;
}

body {
    font-family: 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    margin-bottom: 1rem;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

a:hover {
    color: #0a58ca;
}

.section-header {
    margin-bottom: 3rem;
}

.section-header h2 {
    position: relative;
    display: inline-block;
    margin-bottom: 1rem;
    font-size: 2.5rem;
}

.section-header h2::after {
    content: '';
    position: absolute;
    width: 50px;
    height: 3px;
    background-color: var(--primary-color);
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
}

.section-header p {
    color: var(--secondary-color);
    font-size: 1.1rem;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('/images/hero-bg.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 3rem 0;
    margin-bottom: 0;
}

.hero-content {
    padding: 1rem;
    text-align: center;
}

.hero h1 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .hero {
        padding: 7rem 0;
    }

    .hero-content {
        padding: 2rem;
        text-align: left;
    }

    .hero h1 {
        font-size: 2.5rem;
        margin-bottom: 1.5rem;
    }

    .hero p {
        font-size: 1.2rem;
        margin-bottom: 2rem;
    }
}

/* Fahrzeugkarten */
.vehicle-card {
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 1.5rem;
    background-color: white;
    width: 100%;
}

.vehicle-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.vehicle-image {
    height: 180px;
    overflow: hidden;
    position: relative;
}

@media (min-width: 768px) {
    .vehicle-card {
        margin-bottom: 2rem;
    }

    .vehicle-image {
        height: 200px;
    }
}

.vehicle-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.vehicle-card:hover .vehicle-image img {
    transform: scale(1.05);
}

.vehicle-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--primary-color);
    color: white;
    padding: 5px 10px;
    border-radius: 3px;
    font-size: 0.8rem;
    font-weight: 600;
}

.vehicle-details {
    padding: 1rem;
}

.vehicle-details h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.vehicle-details .price {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.8rem;
}

@media (min-width: 768px) {
    .vehicle-details {
        padding: 1.5rem;
    }

    .vehicle-details h3 {
        font-size: 1.3rem;
    }

    .vehicle-details .price {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }
}

.vehicle-details .specs {
    list-style: none;
    padding: 0;
    margin-bottom: 1.5rem;
    display: flex;
    flex-wrap: wrap;
}

.vehicle-details .specs li {
    margin-right: 1rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    font-size: 0.9rem;
    color: var(--secondary-color);
}

.vehicle-details .specs li i {
    margin-right: 5px;
    color: var(--primary-color);
}

/* Service Cards */
.service-card {
    background-color: white;
    border-radius: 5px;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    height: 100%;
    transition: transform 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.service-card p {
    margin-bottom: 1.5rem;
    color: var(--secondary-color);
}

/* Testimonial Cards */
.testimonial-card {
    background-color: white;
    border-radius: 5px;
    padding: 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    height: 100%;
}

.rating {
    color: #ffc107;
    margin-bottom: 1rem;
}

.testimonial-text {
    font-style: italic;
    margin-bottom: 1.5rem;
}

.testimonial-author {
    display: flex;
    flex-direction: column;
}

.author-name {
    font-weight: 700;
}

.author-info {
    color: var(--secondary-color);
    font-size: 0.9rem;
}

/* CTA Section */
.cta {
    background: linear-gradient(rgba(13, 110, 253, 0.9), rgba(13, 110, 253, 0.9)), url('/images/cta-bg.jpg');
    background-size: cover;
    background-position: center;
    color: white;
}

.cta h2 {
    margin-bottom: 0.5rem;
}

/* Footer */
.footer {
    background-color: var(--dark-color);
    color: white;
    padding: 2rem var(--container-padding);
}

.footer h5 {
    color: white;
    margin-bottom: 1.2rem;
    font-size: 1.1rem;
}

.footer ul {
    padding: 0;
    list-style: none;
    margin-bottom: 2rem;
}

.footer ul li {
    margin-bottom: 0.5rem;
}

.footer ul li a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.9rem;
}

.footer ul li a:hover {
    color: white;
}

@media (min-width: 768px) {
    .footer {
        padding: 4rem 0 2rem;
    }
    
    .footer ul {
        margin-bottom: 0;
    }
}

.footer .social-icons a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
    transition: background-color 0.3s ease;
}

.footer .social-icons a:hover {
    background-color: var(--primary-color);
}

.footer hr {
    border-color: rgba(255, 255, 255, 0.1);
}

.footer .list-inline-item:not(:last-child) {
    margin-right: 1.5rem;
}

/* Back to Top Button */
.back-to-top-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    text-align: center;
    line-height: 1;
    z-index: 99;
    opacity: 0;
    transition: all 0.3s ease;
}

.back-to-top-btn.show {
    opacity: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Fahrzeugdaten-Box Responsive Fix */
@media (max-width: 1023px) {
  .vehicle-specs-box, .fahrzeugdaten-box {
    max-width: 100% !important;
    width: 100% !important;
    margin-top: 2rem !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    float: none !important;
    display: block !important;
  }
  .vehicle-details-main-row, .fahrzeugdetails-main-row {
    flex-direction: column !important;
  }
}

/* Media-Queries für responsives Design */
/* Mobile-first - Default Styling für kleine Geräte */

/* Tablets */
@media (min-width: 768px) {
    .hero {
        padding: 10rem 0;
    }
    
    .hero h1 {
        font-size: 3.5rem;
    }
    
    .hero p {
        font-size: 1.4rem;
    }
    
    .section-header h2 {
        font-size: 3rem;
    }
}

/* Desktop */
@media (min-width: 992px) {
    .hero {
        padding: 12rem 0;
    }
    
    .hero h1 {
        font-size: 4rem;
    }
    
    .vehicle-image {
        height: 220px;
    }
}

/* Price Range Slider Styles */
.price-slider-container {
    margin-bottom: 1rem;
}

.price-slider-container .form-label {
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
    font-weight: 500;
}

/* Price Filter Dropdown Styles */
.price-filter-dropdown .btn {
    text-align: left;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dropdown-menu-price {
    min-width: 250px;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.dropdown-menu-price .price-slider-container {
    margin-bottom: 0;
}

@media (max-width: 767px) {
    .dropdown-menu-price {
        min-width: 100%;
        width: 100% !important;
        margin-top: 0.125rem;
    }
}

.dual-range-slider {
    position: relative;
    height: 40px;
    margin: 10px 0;
}

.range-slider {
    position: absolute;
    width: 100%;
    height: 6px;
    outline: none;
    border: none;
    border-radius: 3px;
    background: transparent;
    -webkit-appearance: none;
    -moz-appearance: none;
    pointer-events: none;
}

.range-slider::-webkit-slider-track {
    width: 100%;
    height: 6px;
    cursor: pointer;
    background: transparent;
    border-radius: 3px;
}

.range-slider::-webkit-slider-thumb {
    position: relative;
    height: 20px;
    width: 20px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    -webkit-appearance: none;
    pointer-events: all;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    z-index: 2;
}

.range-slider::-webkit-slider-thumb:hover {
    background: #0a58ca;
    transform: scale(1.1);
}

.range-slider::-moz-range-track {
    width: 100%;
    height: 6px;
    cursor: pointer;
    background: transparent;
    border-radius: 3px;
    border: none;
}

.range-slider::-moz-range-thumb {
    position: relative;
    height: 20px;
    width: 20px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    pointer-events: all;
    z-index: 2;
}

.range-slider::-moz-range-thumb:hover {
    background: #0a58ca;
    transform: scale(1.1);
}

.slider-track {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    z-index: 0;
}

.slider-range {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    height: 6px;
    background: var(--primary-color);
    border-radius: 3px;
    z-index: 1;
}

.price-display {
    text-align: center;
    font-size: 0.85rem;
    color: var(--secondary-color);
    margin-top: 0.5rem;
    font-weight: 500;
}

.price-display span {
    color: var(--primary-color);
    font-weight: 600;
}

/* Mobile responsiveness for price slider */
@media (max-width: 767px) {
    .dual-range-slider {
        height: 35px;
        margin: 8px 0;
    }
    
    .range-slider::-webkit-slider-thumb {
        height: 18px;
        width: 18px;
    }
    
    .range-slider::-moz-range-thumb {
        height: 18px;
        width: 18px;
    }
    
    .price-display {
        font-size: 0.8rem;
    }
}

/* Focus states for accessibility */
.range-slider:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.range-slider:focus::-webkit-slider-thumb {
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.25);
}

.range-slider:focus::-moz-range-thumb {
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.25);
}
