/**
 * Vehizo Base CSS - Grundlegende Styles
 * Wird IMMER geladen wenn Vehizo aktiv ist
 * Version: 4.1.0
 */

/* ==========================================================================
   CSS Custom Properties - werden von PHP überschrieben
   ========================================================================== */
:root {
    --vehizo-primary: #3b82f6;
    --vehizo-secondary: #6c757d;
    --vehizo-button-hover: #2563eb;
    --vehizo-text: #4b5563;
    --vehizo-text-light: #6b7280;
    --vehizo-title: #1f2937;
    --vehizo-bg: #f8fafc;
    --vehizo-card-bg: #ffffff;
    --vehizo-card-border: #e5e7eb;
    --vehizo-card-radius: 12px;
    --vehizo-card-border-width: 1px;
    --vehizo-specs-bg: #f8fafc;
    --vehizo-font-size: 16px;
    --vehizo-heading-size: 24px;
    --vehizo-title-weight: 700;
    --vehizo-shadow-small: 0 1px 3px rgba(0,0,0,0.05);
    --vehizo-shadow-medium: 0 4px 16px rgba(0,0,0,0.08);
    --vehizo-shadow-large: 0 12px 32px rgba(0,0,0,0.15);
    --vehizo-primary-rgb: 59, 130, 246;
}

/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */
.vehizo-main-container * {
    box-sizing: border-box;
}

.vehizo-main-container {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    line-height: 1.6;
    color: var(--vehizo-text);
    font-size: var(--vehizo-font-size);
    background-color: var(--vehizo-bg);
}

/* ==========================================================================
   Button System - Einheitlich für alle Bereiche
   ========================================================================== */
.vehizo-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: 1px solid transparent;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    background: transparent;
    line-height: 1;
}

.vehizo-button--primary {
    background: var(--vehizo-primary);
    color: white;
    border-color: var(--vehizo-primary);
}

.vehizo-button--primary:hover {
    background: var(--vehizo-button-hover);
    border-color: var(--vehizo-button-hover);
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
}

.vehizo-button--secondary {
    background: transparent;
    color: var(--vehizo-primary);
    border-color: var(--vehizo-primary);
}

.vehizo-button--secondary:hover {
    background: var(--vehizo-primary);
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
}

.vehizo-button--small {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.vehizo-button--large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

/* Legacy button classes - für Rückwärtskompatibilität */
.btn {
    @extend .vehizo-button;
}

.btn-primary {
    @extend .vehizo-button--primary;
}

.btn-secondary {
    @extend .vehizo-button--secondary;
}

/* Für CSS ohne @extend Support */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: 1px solid transparent;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    background: transparent;
    line-height: 1;
}

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

.btn-primary:hover {
    background: var(--vehizo-button-hover);
    border-color: var(--vehizo-button-hover);
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
}

.btn-secondary {
    background: transparent;
    color: var(--vehizo-primary);
    border-color: var(--vehizo-primary);
}

.btn-secondary:hover {
    background: var(--vehizo-primary);
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
}

/* ==========================================================================
   Card System - Basis für Fahrzeugkarten
   ========================================================================== */
.vehizo-card,
.fahrzeug-card {
    background: var(--vehizo-card-bg);
    border: var(--vehizo-card-border-width) solid var(--vehizo-card-border);
    border-radius: var(--vehizo-card-radius);
    box-shadow: var(--vehizo-shadow-medium);
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.vehizo-card:hover,
.fahrzeug-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--vehizo-shadow-large);
    border-color: var(--vehizo-primary);
}

.vehizo-card__image,
.card-image {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
}

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

.vehizo-card:hover .vehizo-card__image img,
.fahrzeug-card:hover .card-image img {
    transform: scale(1.03);
}

.vehizo-card__content,
.card-content {
    padding: 1.5rem;
}

/* ==========================================================================
   Typography System
   ========================================================================== */
.vehizo-card__title,
.card-title {
    font-size: var(--vehizo-heading-size);
    font-weight: var(--vehizo-title-weight);
    color: var(--vehizo-title);
    margin: 0 0 1rem 0;
    line-height: 1.3;
}

.vehizo-card__title a,
.card-title a {
    color: inherit;
    text-decoration: none;
}

.vehizo-card__title a:hover,
.card-title a:hover {
    color: var(--vehizo-primary);
}

.vehizo-subtitle {
    color: var(--vehizo-text-light);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

/* ==========================================================================
   Price Display
   ========================================================================== */
.vehizo-price,
.price-badge,
.price-display {
    background: var(--vehizo-primary);
    color: white;
    font-weight: 700;
    border-radius: 20px;
    padding: 0.5rem 1rem;
}

.price-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 1rem;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(var(--vehizo-primary-rgb), 0.3);
}

/* ==========================================================================
   Specs System
   ========================================================================== */
.vehizo-card__specs,
.specs-list,
.specs-grid {
    display: grid;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.vehizo-card__spec-item,
.spec-item,
.spec-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--vehizo-specs-bg);
    border-radius: 6px;
    border-left: 4px solid var(--vehizo-primary);
    transition: all 0.3s ease;
}

.vehizo-card__spec-item:hover,
.spec-item:hover,
.spec-row:hover {
    background: #e2e8f0;
    transform: translateX(3px);
}

.vehizo-card__spec-label,
.spec-label {
    font-weight: 600;
    color: var(--vehizo-text-light);
    font-size: 0.875rem;
}

.vehizo-card__spec-value,
.spec-value {
    font-weight: 700;
    color: var(--vehizo-text);
    font-size: 0.9rem;
}

/* ==========================================================================
   Grid System
   ========================================================================== */
.vehizo-grid,
.fahrzeuge-grid {
    display: grid;
    gap: 2rem;
}

.vehizo-main-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* ==========================================================================
   Utilities
   ========================================================================== */
.vehizo-text-center { text-align: center; }
.vehizo-text-left { text-align: left; }
.vehizo-text-right { text-align: right; }

.vehizo-mb-1 { margin-bottom: 0.5rem; }
.vehizo-mb-2 { margin-bottom: 1rem; }
.vehizo-mb-3 { margin-bottom: 1.5rem; }
.vehizo-mb-4 { margin-bottom: 2rem; }

.vehizo-hidden { display: none; }
.vehizo-block { display: block; }
.vehizo-flex { display: flex; }
.vehizo-grid { display: grid; }

/* ==========================================================================
   Form Elements
   ========================================================================== */
.vehizo-input,
.vehizo-select,
.vehizo-textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--vehizo-card-border);
    border-radius: 6px;
    background: white;
    color: var(--vehizo-text);
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.vehizo-input:focus,
.vehizo-select:focus,
.vehizo-textarea:focus {
    outline: none;
    border-color: var(--vehizo-primary);
    box-shadow: 0 0 0 3px rgba(var(--vehizo-primary-rgb), 0.1);
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 1024px) {
    .vehizo-main-container {
        padding: 1.5rem 1rem;
    }
}

@media (max-width: 768px) {
    .vehizo-main-container {
        padding: 1rem 0.75rem;
    }
    
    .vehizo-card__content,
    .card-content {
        padding: 1.25rem;
    }
    
    .vehizo-button {
        padding: 0.625rem 1.25rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .vehizo-main-container {
        padding: 0.75rem 0.5rem;
    }
    
    .vehizo-card__content,
    .card-content {
        padding: 1rem;
    }
    
    .vehizo-card__title,
    .card-title {
        font-size: 1.2rem;
    }
}