/* ===========================
   SP Motors GmbH - Custom CSS
   =========================== */

:root {
    --primary-dark: #1a2332;
    --primary-darker: #111b27;
    --accent-gold: #f0a500;
    --accent-gold-dark: #c88900;
    --light-bg: #f8f9fa;
    --text-color: #333;
    --text-muted: #6c757d;
    --white: #ffffff;
    --card-shadow: 0 4px 20px rgba(0,0,0,0.1);
    --card-shadow-hover: 0 8px 30px rgba(0,0,0,0.18);
    --border-radius: 10px;
    --transition: all 0.3s ease;
}

* { box-sizing: border-box; }

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-color);
    background: var(--white);
    line-height: 1.6;
}

/* ---- Logo ---- */
.sp-logo {
    height: 44px;
    width: auto;
    display: block;
    filter: drop-shadow(0 1px 3px rgba(0,0,0,0.3));
    transition: opacity 0.2s;
}
.sp-logo:hover { opacity: 0.88; }
.sp-footer-logo {
    height: 50px;
    width: auto;
    opacity: 0.9;
    filter: brightness(1.05);
}

/* ---- Navbar ---- */
.sp-navbar {
    background: var(--primary-dark) !important;
    padding: 14px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}
.sp-brand {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--white) !important;
    letter-spacing: 0.5px;
}
.sp-brand i { color: var(--accent-gold); }
.sp-navbar .nav-link {
    color: rgba(255,255,255,0.85) !important;
    font-weight: 500;
    padding: 6px 16px !important;
    border-radius: 6px;
    transition: var(--transition);
    margin: 0 2px;
}
.sp-navbar .nav-link:hover,
.sp-navbar .nav-link.active {
    color: var(--white) !important;
    background: rgba(240,165,0,0.2);
}
.sp-navbar .nav-link.active { color: var(--accent-gold) !important; }

/* ---- Hero ---- */
.hero {
    min-height: 92vh;
    background: linear-gradient(135deg, var(--primary-darker) 0%, #243347 60%, #1a2e45 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.02'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero-content { position: relative; z-index: 1; }
.hero-eyebrow {
    display: inline-block;
    color: var(--accent-gold);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 16px;
    background: rgba(240,165,0,0.12);
    padding: 6px 18px;
    border-radius: 20px;
    border: 1px solid rgba(240,165,0,0.3);
}
.hero h1 {
    color: var(--white);
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 20px;
}
.hero h1 span { color: var(--accent-gold); }
.hero-subtitle {
    color: rgba(255,255,255,0.75);
    font-size: 1.2rem;
    font-weight: 400;
    max-width: 600px;
    margin: 0 auto 36px;
}
.btn-gold {
    background: var(--accent-gold);
    color: var(--primary-dark);
    font-weight: 700;
    padding: 14px 36px;
    border-radius: 50px;
    border: none;
    font-size: 1rem;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
}
.btn-gold:hover {
    background: var(--accent-gold-dark);
    color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(240,165,0,0.4);
}
.btn-outline-gold {
    background: transparent;
    color: var(--accent-gold);
    font-weight: 600;
    padding: 13px 32px;
    border-radius: 50px;
    border: 2px solid var(--accent-gold);
    font-size: 1rem;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
}
.btn-outline-gold:hover {
    background: var(--accent-gold);
    color: var(--primary-dark);
    transform: translateY(-2px);
}
.hero-scroll {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.5);
    font-size: 1.5rem;
    animation: bounce 2s infinite;
}
@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(8px); }
}

/* ---- Section titles ---- */
.section-title {
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 800;
    color: var(--primary-dark);
    margin-bottom: 8px;
}
.section-subtitle {
    color: var(--text-muted);
    font-size: 1.05rem;
    margin-bottom: 40px;
}
.section-divider {
    width: 60px;
    height: 4px;
    background: var(--accent-gold);
    border-radius: 2px;
    margin: 12px 0 20px;
}

/* ---- Vehicle Card ---- */
.vehicle-card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    overflow: hidden;
    transition: var(--transition);
    border: none;
    height: 100%;
    display: flex;
    flex-direction: column;
}
.vehicle-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--card-shadow-hover);
}
.vehicle-card-img {
    height: 220px;
    overflow: hidden;
    position: relative;
    background: #f0f0f0;
}
.vehicle-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.vehicle-card:hover .vehicle-card-img img { transform: scale(1.05); }
.vehicle-card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--accent-gold);
    color: var(--primary-dark);
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.vehicle-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.vehicle-card-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 8px;
    line-height: 1.3;
}
.vehicle-card-meta {
    display: flex;
    gap: 12px;
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-bottom: 14px;
    flex-wrap: wrap;
}
.vehicle-card-meta span { display: flex; align-items: center; gap: 4px; }
.price-tag {
    color: var(--accent-gold);
    font-size: 1.3rem;
    font-weight: 800;
    margin-top: auto;
    margin-bottom: 14px;
}
.vehicle-card .btn-details {
    background: var(--primary-dark);
    color: var(--white);
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 600;
    transition: var(--transition);
    text-decoration: none;
    text-align: center;
    display: block;
}
.vehicle-card .btn-details:hover {
    background: var(--accent-gold);
    color: var(--primary-dark);
}

/* ---- No image placeholder ---- */
.no-image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e8e8e8, #d0d0d0);
    color: #aaa;
    font-size: 3rem;
}

/* ---- Stats Bar ---- */
.stats-bar {
    background: var(--primary-dark);
    padding: 50px 0;
}
.stat-item { text-align: center; }
.stat-number {
    font-size: 2.6rem;
    font-weight: 800;
    color: var(--accent-gold);
    line-height: 1;
    margin-bottom: 6px;
}
.stat-label {
    color: rgba(255,255,255,0.7);
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.stat-divider {
    width: 1px;
    height: 60px;
    background: rgba(255,255,255,0.15);
    margin: 0 auto;
}
@media (max-width: 767px) { .stat-divider { display: none; } }

/* ---- About section ---- */
.about-section { background: var(--light-bg); padding: 80px 0; }
.about-icon-box {
    width: 60px;
    height: 60px;
    background: rgba(240,165,0,0.15);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-gold);
    font-size: 1.5rem;
    margin-bottom: 16px;
}
.about-feature h6 { font-weight: 700; color: var(--primary-dark); }

/* ---- Contact Teaser ---- */
.contact-teaser {
    background: linear-gradient(135deg, var(--primary-dark), #243347);
    color: var(--white);
    padding: 80px 0;
    text-align: center;
}
.contact-teaser h2 { color: var(--white); font-weight: 800; }
.contact-teaser p { color: rgba(255,255,255,0.75); font-size: 1.1rem; }

/* ---- Section padding ---- */
.section-pad { padding: 80px 0; }

/* ---- Page hero (inner pages) ---- */
.page-hero {
    background: linear-gradient(135deg, var(--primary-dark), #243347);
    color: var(--white);
    padding: 60px 0 40px;
}
.page-hero h1 { font-weight: 800; color: var(--white); margin-bottom: 8px; }
.page-hero .breadcrumb-item { color: rgba(255,255,255,0.6); }
.page-hero .breadcrumb-item.active { color: var(--accent-gold); }
.page-hero .breadcrumb-item + .breadcrumb-item::before { color: rgba(255,255,255,0.4); }
.page-hero a.breadcrumb-item { color: rgba(255,255,255,0.7); text-decoration: none; }
.page-hero a.breadcrumb-item:hover { color: var(--white); }

/* ---- Filter Sidebar ---- */
.filter-sidebar {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 24px;
    box-shadow: var(--card-shadow);
    position: sticky;
    top: 90px;
}
.filter-sidebar h6 {
    font-weight: 700;
    color: var(--primary-dark);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}
.filter-sidebar .form-control,
.filter-sidebar .form-select {
    border: 1.5px solid #e0e0e0;
    border-radius: 6px;
    font-size: 0.9rem;
    padding: 8px 12px;
}
.filter-sidebar .form-control:focus,
.filter-sidebar .form-select:focus {
    border-color: var(--accent-gold);
    box-shadow: 0 0 0 3px rgba(240,165,0,0.15);
}
.btn-filter {
    background: var(--primary-dark);
    color: var(--white);
    border: none;
    padding: 10px;
    border-radius: 6px;
    font-weight: 600;
    width: 100%;
    transition: var(--transition);
}
.btn-filter:hover { background: var(--accent-gold); color: var(--primary-dark); }
.btn-filter-reset {
    background: transparent;
    color: var(--text-muted);
    border: 1.5px solid #e0e0e0;
    padding: 9px;
    border-radius: 6px;
    font-weight: 500;
    width: 100%;
    transition: var(--transition);
    margin-top: 8px;
    font-size: 0.9rem;
}
.btn-filter-reset:hover { border-color: var(--primary-dark); color: var(--primary-dark); }

/* ---- Active filter tags ---- */
.filter-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(240,165,0,0.12);
    color: var(--primary-dark);
    border: 1px solid rgba(240,165,0,0.4);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 600;
    margin: 0 4px 4px 0;
}

/* ---- Inventory results header ---- */
.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}
.results-count {
    font-weight: 700;
    color: var(--primary-dark);
    font-size: 1rem;
}

/* ---- Pagination ---- */
.pagination .page-link {
    color: var(--primary-dark);
    border-radius: 6px !important;
    margin: 0 2px;
    border: 1.5px solid #dee2e6;
    font-weight: 500;
}
.pagination .page-link:hover { background: var(--accent-gold); border-color: var(--accent-gold); color: var(--primary-dark); }
.pagination .page-item.active .page-link {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: var(--white);
}

/* ---- Vehicle Detail ---- */
.vehicle-detail-gallery { margin-bottom: 30px; }
.gallery-main {
    border-radius: var(--border-radius);
    overflow: hidden;
    background: #f0f0f0;
    height: 450px;
}
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs {
    display: flex;
    gap: 8px;
    margin-top: 10px;
    flex-wrap: wrap;
}
.gallery-thumb {
    width: 80px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition);
}
.gallery-thumb:hover, .gallery-thumb.active { border-color: var(--accent-gold); }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }

.specs-table { width: 100%; border-collapse: separate; border-spacing: 0; }
.specs-table tr:nth-child(even) td { background: var(--light-bg); }
.specs-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    font-size: 0.95rem;
}
.specs-table td:first-child {
    font-weight: 600;
    color: var(--text-muted);
    width: 40%;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.specs-table td:last-child { color: var(--primary-dark); font-weight: 500; }

.vehicle-price-box {
    background: var(--primary-dark);
    border-radius: var(--border-radius);
    padding: 24px;
    color: var(--white);
    margin-bottom: 20px;
}
.vehicle-price-box .price-big {
    font-size: 2rem;
    font-weight: 800;
    color: var(--accent-gold);
    margin-bottom: 4px;
}

.features-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 8px;
}
.features-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--text-color);
}
.features-list li::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--accent-gold);
    font-size: 0.8rem;
}

/* ---- Contact Page ---- */
.contact-form-wrapper {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 36px;
    box-shadow: var(--card-shadow);
}
.contact-info-box {
    background: var(--primary-dark);
    border-radius: var(--border-radius);
    padding: 36px;
    color: var(--white);
    height: 100%;
}
.contact-info-box h4 { color: var(--white); font-weight: 700; }
.contact-info-item {
    display: flex;
    gap: 14px;
    margin-bottom: 20px;
    align-items: flex-start;
}
.contact-info-icon {
    width: 42px;
    height: 42px;
    min-width: 42px;
    background: rgba(240,165,0,0.15);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-gold);
    font-size: 1rem;
}
.contact-info-text { color: rgba(255,255,255,0.85); font-size: 0.95rem; }
.contact-map {
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-bottom: 24px;
    box-shadow: var(--card-shadow);
    min-height: 350px;
    background: #e8e8e8;
}
.contact-map iframe { width: 100%; min-height: 350px; border: none; display: block; }
.map-placeholder {
    min-height: 350px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e8e8e8, #d5d5d5);
    color: #999;
    flex-direction: column;
    gap: 12px;
}

/* ---- Legal pages ---- */
.legal-content h2 { font-size: 1.4rem; font-weight: 700; color: var(--primary-dark); margin-top: 32px; }
.legal-content h3 { font-size: 1.1rem; font-weight: 600; color: var(--primary-dark); margin-top: 24px; }
.legal-content p, .legal-content li { line-height: 1.8; color: #444; }

/* ---- Alerts ---- */
.alert-sp-success {
    background: rgba(25,135,84,0.1);
    border: 1.5px solid rgba(25,135,84,0.3);
    color: #0a5c38;
    border-radius: 8px;
    padding: 16px 20px;
}
.alert-sp-error {
    background: rgba(220,53,69,0.1);
    border: 1.5px solid rgba(220,53,69,0.3);
    color: #842029;
    border-radius: 8px;
    padding: 16px 20px;
}

/* ---- Footer ---- */
.sp-footer {
    background: var(--primary-darker);
    color: rgba(255,255,255,0.7);
}
.footer-brand {
    color: var(--white) !important;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 16px;
}
.footer-brand i { color: var(--accent-gold); }
.footer-text { color: rgba(255,255,255,0.6); font-size: 0.9rem; line-height: 1.8; }
.footer-heading {
    color: var(--white);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
}
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 10px; }
.footer-links a, .footer-link {
    color: rgba(255,255,255,0.6);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
}
.footer-links a:hover, .footer-link:hover { color: var(--accent-gold); }
.footer-hr { border-color: rgba(255,255,255,0.1); margin: 0; }
.footer-copy { color: rgba(255,255,255,0.45); font-size: 0.85rem; }
.footer-copy a { color: rgba(255,255,255,0.55); text-decoration: none; }
.footer-copy a:hover { color: var(--accent-gold); }

/* ---- Form Styles ---- */
.sp-form .form-label {
    font-weight: 600;
    font-size: 0.88rem;
    color: var(--primary-dark);
    margin-bottom: 6px;
}
.sp-form .form-control,
.sp-form .form-select {
    border: 1.5px solid #e0e0e0;
    border-radius: 8px;
    padding: 11px 14px;
    font-size: 0.95rem;
    transition: var(--transition);
}
.sp-form .form-control:focus,
.sp-form .form-select:focus {
    border-color: var(--accent-gold);
    box-shadow: 0 0 0 3px rgba(240,165,0,0.15);
}
.btn-sp-primary {
    background: var(--primary-dark);
    color: var(--white);
    border: none;
    padding: 13px 30px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1rem;
    transition: var(--transition);
    width: 100%;
}
.btn-sp-primary:hover {
    background: var(--accent-gold);
    color: var(--primary-dark);
    transform: translateY(-1px);
}

/* ---- Honeypot (hidden spam trap) ---- */
.sp-trap { display: none !important; }

/* ---- Utility ---- */
.text-gold { color: var(--accent-gold) !important; }
.bg-primary-dark { background: var(--primary-dark) !important; }
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}
.empty-state i { font-size: 4rem; margin-bottom: 16px; opacity: 0.3; }
.section-bg-light { background: var(--light-bg); }

/* ---- Responsive ---- */
@media (max-width: 767px) {
    .hero { min-height: 85vh; padding: 80px 20px; }
    .hero h1 { font-size: 2rem; }
    .gallery-main { height: 260px; }
    .contact-form-wrapper { padding: 24px 16px; }
    .contact-info-box { padding: 24px 16px; margin-top: 24px; }
    .filter-sidebar { position: static; }
    .vehicle-price-box { margin-top: 16px; }
}
