/**
 * REFERENZEN.CSS - Komplett neu für Projekte/Testimonials
 * S.Y.Z. GmbH & Co. KG
 * Version 3.1 - Angepasst an referenzen.php
 */

/* ============================================================================
   REFERENZEN HERO
   ============================================================================ */
.referenzen-hero {
    position: relative;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    color: white;
    padding: 8rem 0 5rem;
    margin-top: 70px;
    overflow: hidden;
}

.referenzen-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><path fill="rgba(255,255,255,0.03)" d="M0,400 Q300,300 600,400 T1200,400 L1200,600 L0,600 Z"/></svg>') no-repeat bottom;
    background-size: cover;
    opacity: 0.5;
}

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

.referenzen-hero-content {
    position: relative;
    z-index: 2;
}

.referenzen-hero-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.section-subtitle {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--color-secondary);
    text-transform: uppercase;
    letter-spacing: 0.2em;
    margin-bottom: 1rem;
}

.referenzen-hero h1 {
    color: white;
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero-description {
    font-size: 1.2rem;
    line-height: 1.7;
    opacity: 0.95;
}

/* ============================================================================
   STATS SECTION - KRITISCH WICHTIG!
   ============================================================================ */
.stats-section {
    padding: 5rem 0;
    background: white;
    position: relative;
    margin-top: -3rem;
    z-index: 10;
}

.stats-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    z-index: 0;
}

.stats-section .container {
    position: relative;
    z-index: 1;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.stat-box {
    background: white;
    padding: 3rem 2rem;
    text-align: center;
    box-shadow: 0 10px 40px rgba(44, 74, 103, 0.15);
    border: 1px solid var(--color-grey);
    transition: all 0.3s ease;
}

.stat-box:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 50px rgba(44, 74, 103, 0.25);
}

.stat-number {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--color-primary);
    line-height: 1;
    margin-bottom: 0.75rem;
    font-family: var(--font-heading);
}

.stat-label {
    font-size: 1rem;
    color: var(--color-text);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.stat-description {
    font-size: 0.95rem;
    color: rgba(0, 0, 0, 0.6);
}

/* ============================================================================
   FILTER SECTION
   ============================================================================ */
.referenzen-filter {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.filter-btn {
    padding: 0.875rem 1.75rem;
    background: white;
    border: 2px solid var(--color-grey);
    color: var(--color-text);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.filter-btn:hover {
    border-color: var(--color-primary);
    background: rgba(44, 74, 103, 0.05);
}

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

/* ============================================================================
   PROJECTS GRID (referenzen-grid)
   ============================================================================ */
.referenzen-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.referenz-card {
    background: white;
    border: 1px solid var(--color-grey);
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
}

.referenz-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(44, 74, 103, 0.15);
    border-color: var(--color-primary);
}

.referenz-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--color-primary);
    color: white;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    z-index: 10;
}

.referenz-image {
    width: 100%;
    height: 250px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.referenz-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
}

.referenz-category {
    display: inline-block;
    background: rgba(255, 255, 255, 0.95);
    color: var(--color-primary);
    padding: 0.4rem 1rem;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.referenz-content {
    padding: 2rem;
}

.referenz-meta {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: var(--color-text);
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.meta-item svg {
    opacity: 0.7;
}

.referenz-title {
    font-size: 1.5rem;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
}

.referenz-subtitle {
    font-size: 1rem;
    color: var(--color-text);
    font-weight: 600;
    margin-bottom: 1rem;
}

.referenz-description {
    color: var(--color-text);
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.referenz-details {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    padding: 1.5rem 0;
    border-top: 1px solid var(--color-grey);
    border-bottom: 1px solid var(--color-grey);
    margin-bottom: 1.5rem;
}

.detail-item {
    font-size: 0.95rem;
    color: var(--color-text);
}

.detail-item strong {
    color: var(--color-primary);
    font-weight: 700;
}

.btn-block {
    display: block;
    width: 100%;
    text-align: center;
}

/* ============================================================================
   TESTIMONIALS GRID
   ============================================================================ */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.testimonial-card {
    background: white;
    padding: 2.5rem;
    border: 1px solid var(--color-grey);
    position: relative;
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(44, 74, 103, 0.15);
    border-color: var(--color-primary);
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: -20px;
    left: 30px;
    font-size: 120px;
    color: var(--color-primary);
    opacity: 0.08;
    font-family: Georgia, serif;
    line-height: 1;
}

.testimonial-rating {
    margin-bottom: 1.5rem;
}

.testimonial-rating .star {
    color: #fbbf24;
    width: 20px;
    height: 20px;
    display: inline-block;
}

.testimonial-text {
    color: var(--color-text);
    line-height: 1.8;
    font-size: 1.05rem;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 1;
    font-style: italic;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-grey);
}

.author-avatar {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    font-weight: 700;
    flex-shrink: 0;
}

.author-info {
    flex: 1;
}

.author-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 0.25rem;
}

.author-company {
    font-size: 0.95rem;
    color: var(--color-text);
}

.testimonial-service {
    margin-top: 1rem;
}

.service-tag {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: rgba(44, 74, 103, 0.08);
    color: var(--color-primary);
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ============================================================================
   SECTION HELPERS
   ============================================================================ */
.section-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 3rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 2.75rem);
    margin-bottom: 1rem;
    color: var(--color-primary-dark);
}

.section-description {
    font-size: 1.1rem;
    color: var(--color-text);
    line-height: 1.7;
}

/* ============================================================================
   BUTTONS
   ============================================================================ */
.btn {
    display: inline-block;
    padding: 1rem 2rem;
    font-size: 0.95rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
    font-family: var(--font-primary);
}

.btn-light {
    background: white;
    color: var(--color-primary);
    border: 2px solid white;
}

.btn-light:hover {
    background: var(--color-light);
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

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

.btn-lg {
    padding: 1.25rem 2.5rem;
    font-size: 1.1rem;
}

/* ============================================================================
   ANIMATIONS
   ============================================================================ */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================================================
   RESPONSIVE
   ============================================================================ */
@media (max-width: 768px) {
    .referenzen-hero {
        padding: 6rem 0 4rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .stat-box {
        padding: 2rem 1.5rem;
    }
    
    .stat-number {
        font-size: 2.75rem;
    }
    
    .referenzen-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .testimonials-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .referenzen-filter {
        flex-direction: column;
    }
    
    .filter-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .referenzen-hero {
        padding: 5rem 0 3rem;
    }
    
    .stats-section {
        padding: 3rem 0;
    }
    
    .stat-box {
        padding: 2rem 1rem;
    }
    
    .stat-number {
        font-size: 2.25rem;
    }
    
    .referenz-content {
        padding: 1.5rem;
    }
    
    .testimonial-card {
        padding: 2rem 1.5rem;
    }
}
