/* =========================================
   1. Reset & Basis-Styles
   ========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* WCAG Fokus-Indikator: Sehr wichtig für Tastaturnutzer */
:focus-visible {
    outline: 3px solid #ff6b6b;
    outline-offset: 3px;
}

:root {
    --primary: #6366f1; /* Indigo */
    --secondary: #f43f5e; /* Rose/Coral */
    --dark: #1e293b;
    --light: #f8fafc;
    --accent: #8b5cf6;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--light);
}

/* Modal Fix: Standardmäßig absolut unsichtbar */
.modal {
    display: none !important; /* Verhindert das Aufpoppen beim Laden */
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

/* =========================================
   2. Barrierefreiheit (WCAG 2.2 Hilfsklassen)
   ========================================= */

/* Versteckt Text visuell, bleibt aber für Screenreader lesbar */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Skip-Link: Erscheint nur bei Tab-Fokus */
.skip-link {
    position: absolute;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: #ff6b6b;
    color: white;
    padding: 1rem 2rem;
    z-index: 2000;
    text-decoration: none;
    font-weight: bold;
    border-radius: 0 0 10px 10px;
    transition: top 0.3s ease;
}

.skip-link:focus {
    top: 0;
}

/* =========================================
   3. Header & Suche
   ========================================= */
header {
    background: linear-gradient(90deg, 
        #D9D9D9 0%, 
        #D9D9D9 25%, 
        #0a766d 100%
    );
    height: 200px; /* Larger banner height for prominent logo */
    padding: 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-container {
    max-width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 2rem;
}

.logo {
    height: 100%;
    min-width: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.logo img {
    height: 85%;
    width: auto;
    object-fit: contain;
    display: block;
}

.search-bar {
    flex: 1;
    display: flex;
    gap: 0.5rem;
}

.search-bar input {
    flex: 1;
    padding: 0.7rem 1rem;
    border: 2px solid transparent;
    border-radius: 5px;
    font-size: 1rem;
}

.search-bar button {
    padding: 0.7rem 1.5rem;
    background-color: #ff6b6b;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.3s;
}

.search-bar button:hover {
    background-color: #ff5252;
}

/* =========================================
   4. Navigation
   ========================================= */
nav {
    background: white;
    border-bottom: 1px solid #eee;
    padding: 1rem 0;
}

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

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: #444; /* Kontrast von #666 auf #444 erhöht für AA */
    font-weight: 600;
    padding: 0.5rem 0;
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
}

.nav-links a:hover,
.nav-links a.active {
    color: #667eea;
    border-bottom: 3px solid #667eea;
}

/* =========================================
   5. Layout & Content
   ========================================= */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.page-title {
    text-align: center;
    margin-bottom: 2rem;
}

.page-title h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    color: #222;
}

.page-title p {
    font-size: 1.1rem;
    color: #444; /* Kontrast erhöht */
}

/* Filter Section */
.filters {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    border: 1px solid #eee;
}

.filter-group {
    display: flex;
    flex-direction: column; /* Vertikal für bessere Lesbarkeit */
    gap: 0.3rem;
}

.filter-group label {
    font-weight: 600;
    color: #222;
    font-size: 0.9rem;
}

.filter-group select {
    padding: 0.6rem 1rem;
    border: 2px solid #ddd;
    border-radius: 5px;
    background-color: white;
    font-size: 1rem;
}

/* =========================================
   6. Produkte & Cards
   ========================================= */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.product-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #eee;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.15);
}

.product-image {
    width: 100%;
    height: 200px;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3.5rem;
}

.product-info {
    padding: 1.2rem;
}

.product-name {
    font-size: 1.25rem;
    margin-bottom: 0.4rem;
    color: #111;
}

.product-model {
    color: #666; /* Erhöht für Lesbarkeit */
    font-size: 0.9rem;
    margin-bottom: 0.8rem;
}

.product-price {
    font-size: 1.4rem;
    font-weight: 800;
    color: #764ba2;
}

/* =========================================
   7. Modal (Produktdetails)
   ========================================= */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    display: flex; /* Benötigt JS Steuerung */
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: white;
    padding: 2.5rem;
    border-radius: 15px;
    width: 95%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.close-btn {
    position: absolute;
    right: 1.5rem;
    top: 1rem;
    background: #f0f0f0;
    border: none;
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
}

.modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 1rem;
}

/* =========================================
   8. Footer
   ========================================= */
footer {
    background: #1a1a1a;
    color: #eee;
    padding: 4rem 0 2rem;
    margin-top: 5rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
}

.footer-section h3 {
    color: white;
    margin-bottom: 1.2rem;
    font-size: 1.2rem;
}

.footer-section ul {
    list-style: none;
}

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

.footer-section a {
    color: #bbb;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-section a:hover {
    color: #ff6b6b;
    text-decoration: underline;
}

.footer-bottom {
    text-align: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #333;
    font-size: 0.9rem;
    color: #888;
}

/* =========================================
   9. Responsive Design
   ========================================= */
@media (max-width: 768px) {
    .header-container {
        flex-direction: column;
        padding: 1rem;
    }

    .modal-body {
        grid-template-columns: 1fr;
    }

    .nav-links {
        justify-content: center;
        font-size: 0.9rem;
        gap: 1rem;
    }

    .page-title h1 {
        font-size: 1.8rem;
    }
}

/* Hero & Gradient */
.hero-banner {
    height: 60vh;
    background: linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.3)), url('../assets/images/6 cases different colors.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    border-bottom: 10px solid #909090; /* Dein HEX-Wunsch */
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7);
}

.hero-content p {
    font-size: 1.5rem;
    color: #e0e0e0;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

/* Video Placeholder */
/* Container für das Video */
.video-banner-container {
    position: relative;
    width: 100%;
    height: 40vh; /* Höhe des Banners (70% des Bildschirms) */
    overflow: hidden;
    background-color: #000; /* Fallback-Farbe */
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Das Video-Element */
.video-banner {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Video wird beschnitten, um den Container zu füllen */
    z-index: 1;
}

/* Text-Overlay auf dem Video */
.video-overlay-content {
    position: relative;
    z-index: 2; /* Über dem Video */
    text-align: center;
    color: white;
    text-shadow: 0 4px 15px rgba(0,0,0,0.6);
}

.video-overlay-content h1 {
    font-size: 4rem;
    font-weight: 900;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.video-overlay-content p {
    font-size: 1.5rem;
    font-weight: 300;
}

/* Anpassung für mobile Geräte */
@media (max-width: 768px) {
    .video-banner-container {
        height: 50vh;
    }
    .video-overlay-content h1 {
        font-size: 2.5rem;
    }
}

/* Product Images */
.product-img-container img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.modal-img-display {
    width: 100%;
    max-height: 400px;
    object-fit: contain;
}

/* Container für die Karten-Anordnung */
/* =========================================
   Deals Full-Width Design
   ========================================= */

.deals-fullwidth {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0; /* Nahtloser Übergang zwischen den Sektionen */
}

.deal-card {
    position: relative;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    min-height: 600px; /* Angemessene Höhe statt 1000px */
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Parallax-Effekt für mehr Hochwertigkeit */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Der zentrierte Text-Kasten (Frosted Glass Effekt) */
.deal-content.full-overlay {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    padding: 3rem;
    border-radius: 20px;
    max-width: 600px;
    width: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.deal-content h2 {
    font-size: 2.5rem;
    color: white;
    margin-bottom: 1rem;
    font-weight: 800;
}

.deal-content p {
    font-size: 1.2rem;
    color: #e0e0e0;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.deal-pricing {
    margin-bottom: 2rem;
}

.deal-price {
    font-size: 1.5rem;
    font-weight: 900;
    color: #fbbf24;
    background: rgba(251, 191, 36, 0.2);
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    border: 2px solid #fbbf24;
}

/* Button & Badge Fixes */
.deal-badge {
    position: absolute;
    top: 30px;
    left: 30px;
    background: var(--secondary);
    color: white;
    padding: 0.8rem 1.5rem;
    font-weight: 800;
    border-radius: 50px;
    z-index: 5;
    font-size: 1.1rem;
}

.btn-deal-huge {
    padding: 1.2rem 2.5rem;
    border-radius: 50px; /* Rundere Buttons für modernen Look */
    transition: transform 0.3s ease;
}

.btn-deal-huge:hover {
    transform: scale(1.05);
}

/* Der große Button am Boden */
.btn-deal-huge {
    display: block;
    width: 100%;
    padding: 1.2rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: white !important;
    text-align: center;
    text-decoration: none;
    font-weight: 800;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: opacity 0.3s;
}

.btn-deal-huge:hover {
    opacity: 0.9;
}

/* Badge Design */
.deal-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--secondary);
    color: white;
    font-size: 0.9rem;
    font-weight: 700;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

/* Table Style */
.table-container {
    overflow-x: auto;
    margin-top: 2rem;
    background: white;
    border-radius: 10px;
    padding: 1rem;
}

.device-table {
    width: 100%;
    border-collapse: collapse;
}

.device-table th, .device-table td {
    padding: 1rem;
    border-bottom: 1px solid #eee;
    text-align: left;
}

.btn-table {
    padding: 0.5rem 1rem;
    background: #667eea;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 0.9rem;
}

.hero-img-small {
    width: 100%;
    max-height: 300px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 1rem;
}