/* =========================================
   CSS STYLES (assets/css/style.css)
   =========================================
*/
:root {
    --primary-color: #005f99; /* Tiefes Wasserblau */
    --primary-dark: #003f66;
    --secondary-color: #0099cc; /* Helles Blau */
    --accent-color: #e74c3c; /* Notdienst Rot */
    --text-dark: #333;
    --text-light: #f4f4f4;
    --bg-light: #ffffff;
    --bg-offwhite: #f8f9fa;
    --bg-dark: #1a1a2e;
    --shadow: 0 10px 30px rgba(0,0,0,0.1);
    --nav-height: 80px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Open Sans', sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-light);
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    font-family: 'Montserrat', sans-serif;
}

/* --- Utility Classes --- */
.hidden { display: none !important; }
.fade-in { animation: fadeIn 0.5s ease-in-out; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Water Drop Canvas Overlay --- */
#rain-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999; 
    pointer-events: none; 
    opacity: 1; /* Volle Deckkraft, Transparenz wird im JS geregelt */
}

/* --- Navigation --- */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    z-index: 1000;
    padding: 0 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    height: var(--nav-height);
    transition: height 0.3s;
}

.logo {
    font-size: 1.2rem;
    font-weight: 900;
    color: var(--primary-color);
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    z-index: 1001;
}

.logo i { font-size: 1.5rem; }
.logo span { font-weight: 400; color: #666; font-size: 0.8rem; display: block;}

.logo-img {
    height: 45px;
    width: 45px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-color);
}

/* Desktop Menu */
.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    transition: color 0.3s;
    cursor: pointer;
    white-space: nowrap;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--secondary-color);
}

.nav-btn {
    background: var(--accent-color);
    color: white !important;
    padding: 0.6rem 1.5rem;
    border-radius: 50px;
    box-shadow: 0 4px 15px rgba(231, 76, 60, 0.4);
    animation: pulse-btn 2s infinite;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    font-size: 1.8rem;
    color: var(--text-dark);
    cursor: pointer;
    z-index: 1001;
}

@keyframes pulse-btn {
    0% { box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(231, 76, 60, 0); }
    100% { box-shadow: 0 0 0 0 rgba(231, 76, 60, 0); }
}

/* --- PAGES STRUCTURE (SPA) --- */
.page-section {
    min-height: 100vh;
    padding-top: var(--nav-height);
}

/* --- Hero Section --- */
.hero {
    position: relative;
    height: 100vh; /* Fullscreen */
    min-height: 600px; /* Mindesthöhe für kleine Screens */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    overflow: hidden; /* Verhindert, dass das Video übersteht */
}

.hero-video-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: translate(-50%, -50%);
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 30, 60, 0.7); /* Dunkles Overlay für Lesbarkeit */
    z-index: 2;
}

/* Fallback für Mobile Parallax (Performance) */
@media (hover: none) {
    /* Kein Parallax-Effekt für Video nötig */
}

.hero-content {
    position: relative; /* Stellt sicher, dass der Inhalt über dem Hintergrund liegt */
    z-index: 3; /* Muss über dem Overlay liegen */
    max-width: 900px;
    padding: 20px;
    width: 100%;
}

.hero h1 {
    font-size: clamp(2rem, 5vw, 3.5rem); /* Responsive Font Size */
    margin-bottom: 20px;
    text-shadow: 0 4px 10px rgba(0,0,0,0.5);
    line-height: 1.2;
}

.hero-sub {
    font-size: clamp(1rem, 3vw, 1.3rem);
    margin-bottom: 40px;
    opacity: 0.9;
}

.hero-btns {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    border: none;
    font-size: 1rem;
    justify-content: center;
}

.btn-primary {
    background: var(--secondary-color);
    color: white;
    box-shadow: 0 5px 15px rgba(0, 153, 204, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 153, 204, 0.6);
}

.btn-whatsapp {
    background: #25D366;
    color: white;
}

/* --- Services Overview --- */
.services {
    padding: 80px 5%;
    background: var(--bg-offwhite);
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.line {
    width: 60px;
    height: 4px;
    background: var(--accent-color);
    margin: 0 auto;
}

.grid-container {
    display: flex;
    gap: 30px;
    flex-direction: row;
    align-items: center;
    align-content: center;
    flex-wrap: wrap;
    justify-content: center;
}

.card {
    background: white;
    border-radius: 15px;
    padding: 30px 25px;
    box-shadow: var(--shadow);
    transition: transform 0.3s;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    border-top: 5px solid var(--primary-color);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.card:hover {
    transform: translateY(-5px);
}

/* "Mehr erfahren" Link immer unten */
.card-footer {
    margin-top: auto;
    padding-top: 20px;
    font-size: 0.9rem;
    color: var(--secondary-color);
    font-weight: bold;
    text-align: right;
}

.card-icon {
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 20px;
}

.card h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--text-dark);
}

.category-title {
    font-size: 1.5rem;
    margin: 40px 0 20px;
    color: var(--primary-color);
    border-left: 5px solid var(--accent-color);
    padding-left: 15px;
}

/* --- SUBPAGE DETAIL VIEW STYLES --- */
.subpage-header {
    background: var(--primary-dark);
    color: white;
    padding: 100px 5% 60px;
    text-align: center;
}

.subpage-content {
    padding: 60px 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
}

.detail-text ul {
    list-style: none;
    margin-top: 20px;
}

.detail-text li {
    margin-bottom: 15px;
    padding-left: 30px;
    position: relative;
}

.detail-text li::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--accent-color);
    position: absolute;
    left: 0;
    top: 3px;
}

.detail-image img {
    width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: var(--shadow);
    object-fit: cover;
}

.detail-image .detail-image-round {
    border-radius: 50%;
    max-width: 400px; /* Verhindert, dass das Logo zu groß wird */
    width: 90%;       /* Macht es etwas kleiner als der Container */
    aspect-ratio: 1 / 1; /* Stellt sicher, dass es ein Kreis bleibt */
    display: block;     /* Erforderlich für margin: auto */
    margin: 0 auto;     /* Zentriert das Bild horizontal */
}

.back-btn {
    display: inline-block;
    margin-bottom: 30px;
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* --- Contact & Footer --- */
.contact-bar {
    background: var(--primary-color);
    color: white;
    padding: 40px 5%;
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 30px;
    text-align: center;
}

.contact-item {
    flex: 1;
    min-width: 250px;
}

.contact-item i {
    font-size: 1.8rem;
    margin-bottom: 15px;
    display: block;
    opacity: 0.8;
}

.contact-item a {
    color: white;
    text-decoration: none;
    font-weight: bold;
}

footer {
    background: #111;
    color: #aaa;
    padding: 60px 5% 30px;
    font-size: 0.9rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col {
    display: flex;
    flex-direction: column;
    align-content: center;
    align-items: center;
}

.footer-col h4 {
    color: white;
    margin-bottom: 20px;
    font-size: 1.2rem;
    border-bottom: 2px solid #333;
    padding-bottom: 10px;
    display: inline-block;
}

.footer-col p{
    max-width: 250px;
    text-align: justify;      /* Aktiviert den Blocksatz */
  hyphens: auto;            /* Aktiviert automatische Silbentrennung */
  -webkit-hyphens: auto;    /* Für Safari/ältere Browser */
}

.footer-links a {
    display: block;
    color: #aaa;
    text-decoration: none;
    margin-bottom: 12px;
    transition: color 0.2s;
    cursor: pointer;
}

.footer-links a:hover { color: var(--secondary-color); }

.legal-text {
    border-top: 1px solid #333;
    padding-top: 20px;
    text-align: center;
    font-size: 0.8rem;
}

/* --- CONTACT PAGE STYLES --- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
}

.contact-form-container h3, .contact-info-container h3 {
    font-size: 1.8rem;
    margin-bottom: 30px;
    color: var(--primary-color);
}

#contactForm {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

#contactForm input, #contactForm textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: 'Open Sans', sans-serif;
    font-size: 1rem;
}

#contactForm textarea {
    resize: vertical;
    min-height: 120px;
}

.form-buttons {
    display: flex;
    gap: 15px;
    margin-top: 10px;
}

.map-container {
    position: relative;
    width: 100%;
    padding-top: 75%; /* Aspect Ratio 4:3 */
    margin-top: 30px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* --- COOKIE BANNER STYLES --- */
.cookie-banner {
    position: fixed;
    bottom: -200px; /* Start outside the screen */
    left: 0;
    width: 100%;
    background: rgba(26, 26, 46, 0.95); /* --bg-dark with transparency */
    color: var(--text-light);
    padding: 25px;
    box-shadow: 0 -5px 20px rgba(0,0,0,0.2);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    transition: bottom 0.5s ease-in-out;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.cookie-banner.show {
    bottom: 0; /* Slide in */
}

.cookie-banner p {
    margin: 0;
    font-size: 0.9rem;
    max-width: 700px;
}

.cookie-banner a {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* =========================================
   MOBILE RESPONSIVENESS
   =========================================
*/
@media (max-width: 768px) {
    :root { --nav-height: 70px; }
    
    .menu-toggle { display: block; }

    .nav-links {
        position: fixed;
        top: var(--nav-height);
        right: -100%; /* Hidden by default */
        width: 80%; /* Slide in partly */
        max-width: 300px;
        height: calc(100vh - var(--nav-height));
        background: white;
        flex-direction: column;
        align-items: flex-start;
        padding: 40px 30px;
        transition: right 0.4s ease;
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
    }

    .nav-links.active {
        right: 0;
    }
    
    /* Overlay for mobile menu */
    .overlay {
        position: fixed;
        top: 0; left: 0; width: 100%; height: 100%;
        background: rgba(0,0,0,0.5);
        z-index: 999;
        display: none;
    }
    .overlay.active { display: block; }

    .hero h1 { font-size: 2rem; }
    .btn { width: 100%; } /* Full width buttons on mobile */
    
    .detail-grid { grid-template-columns: 1fr; } /* Stack detail view */
    .detail-image { order: -1; margin-bottom: 30px; } /* Image first on mobile */
    
    .contact-bar { flex-direction: column; align-items: center; }
    .contact-item { margin-bottom: 20px; }

    .contact-grid { grid-template-columns: 1fr; }

    .cookie-banner {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }
}