/* 
   GDPR COMPLIANCE: 
   This project uses standard system fonts (Arial, Helvetica, etc.) 
   to avoid Google Fonts IP leaks to third-party servers. 
*/

:root {
    --primary-blue: #00aeef; /* Bright Blue from logo */
    --primary-dark: #0056b3; /* Darker blue for interactions */
    --accent-orange: #f07d00; /* Original H&R Orange */
    --dark-grey: #333333; /* Dark Grey from logo */
    --light-bg: #f8fafc;
    --overlay-dark: #1e293b;
    --text-dark: #1e293b; /* More contrast for readability */
    --text-muted: #64748b;
    --white: #ffffff;
    --section-spacing-mobile: 4rem;
    --section-spacing-desktop: 7rem;
    --border-radius: 12px;
    --shadow-elegant: 0 10px 30px rgba(0,0,0,0.05);
    --transition-smooth: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.x-small {
    font-size: 0.75rem;
}

body {
    font-family: 'Inter', -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--text-dark);
    line-height: 1.8;
    font-size: 1.05rem;
    -webkit-font-smoothing: antialiased;
}

/* Elegant Form Styling */
.form-control, .form-select {
    padding: 0.8rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.95rem;
    transition: var(--transition-smooth);
    background-color: #fcfcfc;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 4px rgba(0, 174, 239, 0.1);
    background-color: var(--white);
}

.form-label {
    margin-bottom: 0.5rem;
    color: var(--dark-grey);
}

.btn-cta {
    background: var(--primary-blue);
    color: #fff !important;
    font-weight: 800;
    border-radius: 8px;
    padding: 1rem 2rem;
    border: none;
    transition: var(--transition-smooth);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-cta:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 174, 239, 0.3);
    color: #fff !important;
}

/* Better Shadows & Transitions */
.card, .rounded-4 {
    border-radius: var(--border-radius) !important;
}
@media (min-width: 992px) {
    .dropdown:hover .dropdown-menu {
        display: block;
        margin-top: 0;
    }
}

/* Mobile specific spacing fixes */
@media (max-width: 767px) {
    .container {
        padding-left: 20px;
        padding-right: 20px;
    }
    
    .row {
        margin-left: -10px;
        margin-right: -10px;
    }
    
    .row > * {
        padding-left: 10px;
        padding-right: 10px;
    }

    .display-4 {
        font-size: 2.5rem;
    }
    
    .section-title {
        font-size: 1.85rem !important;
        margin-bottom: 1.5rem;
    }

    .card-body {
        padding: 1.25rem !important;
    }
}

/* Better responsive images */
img {
    max-width: 100%;
    height: auto;
}

/* Accessibility: Keyboard navigation focus */
:focus-visible {
    outline: 3px solid var(--primary-blue) !important;
    outline-offset: 2px;
}

/* Topbar Styling */
.topbar {
    background: #ffffff;
    padding: 10px 0;
    font-size: 0.85rem;
    color: var(--dark-grey);
    border-bottom: 1px solid #eeeeee;
}

.topbar i {
    font-size: 0.9rem;
    color: var(--primary-blue) !important;
}

.topbar a {
    color: var(--dark-grey) !important;
    text-decoration: none;
}

/* Navbar Enhancements */
.navbar {
    background: #ffffff !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.05);
    padding: 0.5rem 0;
    transition: var(--transition-smooth);
}

.navbar-brand img {
    height: 70px; /* Reduced from default */
    width: auto;
    transition: var(--transition-smooth);
}

.nav-link {
    font-weight: 600;
    color: var(--dark-grey) !important;
    padding: 0.5rem 1.2rem !important;
    transition: var(--transition-smooth);
    font-size: 0.95rem;
}

.nav-link:hover {
    color: var(--primary-blue) !important;
}

.dropdown-menu {
    border-radius: 12px;
    padding: 1rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.dropdown-item {
    padding: 0.6rem 1.2rem;
    font-weight: 500;
    border-radius: 6px;
    transition: var(--transition-smooth);
}

.dropdown-item:hover {
    background-color: rgba(0, 174, 239, 0.05);
    color: var(--primary-blue);
}

@media (max-width: 991px) {
    .navbar-collapse {
        background: white;
        padding: 1.5rem;
        border-radius: 12px;
        margin-top: 1rem;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    }
}

/* Better Hero Mobile */
.hero-section {
    padding: 80px 0;
    background: linear-gradient(rgba(0, 174, 239, 0.7), rgba(51, 51, 51, 0.8)), 
                url('../img/WhatsApp-Image-2024-07-04-at-10.39.04-1.jpeg') center/cover no-repeat;
    background-attachment: scroll; /* Fixed is often buggy on mobile */
    color: white;
}

@media (max-width: 576px) {
    .hero-section {
        background-image: linear-gradient(rgba(0, 174, 239, 0.9), rgba(51, 51, 51, 0.9)) !important;
        background-color: var(--primary-blue);
    }
}

@media (min-width: 992px) {
    .hero-section {
        padding: 140px 0;
        background-attachment: fixed;
    }
}

.hero-section h1 {
    font-weight: 900;
    font-size: 2.25rem; /* Better for mobile */
    line-height: 1.2;
}

@media (min-width: 768px) {
    .hero-section h1 {
        font-size: 3.5rem;
    }
}

.border-orange {
    border-color: var(--primary-blue) !important;
}

/* Better mobile section padding */
@media (max-width: 576px) {
    section {
        padding-top: 3rem;
        padding-bottom: 3rem;
    }
    
    .py-5 {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
    }
    
    .mb-5 {
        margin-bottom: 2rem !important;
    }

    .row.g-5 {
        --bs-gutter-x: 1.5rem;
        --bs-gutter-y: 1.5rem;
    }
    
    .row.g-4 {
        --bs-gutter-x: 1rem;
        --bs-gutter-y: 1rem;
    }
}

/* Accessibility: Text contrast */
.text-muted {
    color: #4b5563 !important; /* Slightly darker than default text-muted for better AA */
}

.small.text-muted {
    font-size: 0.9rem;
    font-weight: 500;
}

.text-orange {
    color: var(--primary-blue) !important;
}

.text-warning {
    color: var(--primary-blue) !important;
}

/* Result Cards */
.card.rounded-4 {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card.rounded-4:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1) !important;
}
/* Service Cards */
.service-card {
    border: none;
    border-radius: 12px;
    background: var(--white);
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.service-icon {
    color: var(--primary-blue);
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* Modern Slider */
.ba-slider-container {
    height: 500px;
    border-radius: 12px;
}

@media (max-width: 768px) {
    .ba-slider-container {
        height: 300px;
    }
}

/* Page Headers */
.page-header {
    padding: 60px 0;
    background-color: var(--overlay-dark);
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    position: relative;
    color: white;
    text-align: center;
}

@media (min-width: 992px) {
    .page-header {
        padding: 100px 0;
    }
}

.header-fassade { background-image: linear-gradient(rgba(27, 54, 93, 0.9), rgba(27, 54, 93, 0.9)), url('../img/WhatsApp-Image-2024-07-04-at-10.39.04-1.jpeg'); }
.header-dach { background-image: linear-gradient(rgba(27, 54, 93, 0.9), rgba(27, 54, 93, 0.9)), url('../img/WhatsApp-Image-2024-07-04-at-10.39.04-1.jpeg'); }
.header-sanierung { background-image: linear-gradient(rgba(27, 54, 93, 0.9), rgba(27, 54, 93, 0.9)), url('../img/WhatsApp-Image-2024-07-04-at-10.39.04-1.jpeg'); }
.header-totalsanierung { background-image: linear-gradient(rgba(27, 54, 93, 0.9), rgba(27, 54, 93, 0.9)), url('../img/WhatsApp-Image-2024-07-04-at-10.39.04-1.jpeg'); }
.header-maler { background-image: linear-gradient(rgba(27, 54, 93, 0.9), rgba(27, 54, 93, 0.9)), url('../img/WhatsApp-Image-2024-07-04-at-10.39.04-1.jpeg'); }
.header-kontakt { background-image: linear-gradient(rgba(0, 174, 239, 0.8), rgba(51, 51, 51, 0.9)), url('../img/WhatsApp-Image-2024-07-04-at-10.39.04-1.jpeg'); }

@media (max-width: 576px) {
    .page-header {
        background-image: none !important;
        background-color: var(--primary-blue) !important;
        padding: 40px 0;
    }
}

.ba-handle::after {
    background: var(--primary-blue);
    color: white;
}

.section-title {
    color: var(--primary-blue);
    font-weight: 800;
    font-size: 2.5rem;
    margin-bottom: 2rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--primary-blue);
}

footer {
    background-color: var(--overlay-dark) !important;
    color: rgba(255, 255, 255, 0.7);
}

footer h5, footer .text-white {
    color: var(--white) !important;
}

footer a {
    color: rgba(255, 255, 255, 0.6) !important;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--primary-blue) !important;
    text-decoration: none !important;
}

.footer-contact-info i {
    width: 25px;
    text-align: center;
    margin-right: 10px;
}

/* Service icon mobile spacing */
@media (max-width: 767px) {
    .service-card {
        margin-bottom: 1rem;
    }
}

/* Trust Bar / Primary Blue Section Fix */
.bg-primary-blue {
    background: linear-gradient(90deg, #0099cc, #00aeef) !important;
    padding: 1.25rem 0;
    box-shadow: inset 0 2px 10px rgba(0,0,0,0.1);
}

.bg-primary-blue span {
    font-weight: 700 !important;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    font-size: 0.85rem !important;
}

.bg-primary-blue i {
    font-size: 1.3rem;
    margin-right: 8px;
    opacity: 0.9;
}

@media (max-width: 767px) {
    .bg-primary-blue .col-6 {
        padding: 0.75rem 0.25rem;
    }
}

.ba-slider-container {
    position: relative;
    width: 100%;
    height: 400px;
    overflow: hidden;
    border-radius: 12px;
    touch-action: none;
}

@media (min-width: 768px) {
    .ba-slider-container {
        height: 600px;
    }
}

.ba-image-before, .ba-image-after {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.ba-image-before {
    width: 50%;
    z-index: 2;
}

.ba-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: ew-resize;
    z-index: 10;
    -webkit-appearance: none; /* For touch target optimization */
}

/* Service Card Spacing */
.service-card {
    padding: 1.5rem !important;
}

@media (min-width: 992px) {
    .service-card {
        padding: 2.5rem !important;
    }
}

.ba-handle {
    position: absolute;
    top: 0;
    left: 50%;
    width: 4px;
    height: 100%;
    background: white;
    z-index: 5;
    transform: translateX(-50%);
    pointer-events: none;
}

.ba-handle::after {
    content: "\f337";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background: var(--accent-orange);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

.ba-label {
    position: absolute;
    bottom: 20px;
    padding: 5px 15px;
    background: rgba(0,0,0,0.5);
    color: white;
    border-radius: 20px;
    font-size: 0.8rem;
    pointer-events: none;
}

.ba-label-before { left: 20px; }
.ba-label-after { right: 20px; }

/* Scroll Reveal - Optimized for no-flicker */
.js-enabled [data-reveal]:not(.reveal-visible) {
    opacity: 0;
    transform: translateY(20px);
    visibility: hidden;
}

.js-enabled [data-reveal].reveal-visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
    visibility: visible !important;
    transition: opacity 0.8s ease-out, transform 0.8s ease-out !important;
}

/* Minimalist Cookie Banner */
#cookieBanner.cookie-banner {
    position: fixed;
    bottom: 25px;
    right: 25px;
    left: auto;
    width: 320px;
    max-width: calc(100vw - 40px);
    background: #ffffff !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 1.25rem;
    border-radius: 16px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    z-index: 100000 !important;
    transition: all 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
    color: #333333 !important;
    display: block !important;
    transform: translateY(150%);
    opacity: 0;
}

#cookieBanner.active {
    transform: translateY(0) !important;
    opacity: 1 !important;
}

@media (max-width: 767px) {
    #cookieBanner.cookie-banner {
        left: 15px;
        right: 15px;
        width: auto;
        bottom: 85px; /* Above mobile sticky call if present */
        padding: 1rem;
        border-radius: 12px;
    }
}

#cookieBanner h5 { color: #1e293b !important; font-weight: 700; margin-bottom: 0.5rem; font-size: 1.1rem; }
#cookieBanner p { color: #64748b !important; font-size: 0.85rem; line-height: 1.4; margin-bottom: 1.25rem; }

.cookie-banner .btn-cta {
    background: var(--primary-blue);
    color: white !important;
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    border-radius: 8px;
    text-transform: none;
    letter-spacing: 0;
}

.cookie-banner .btn-cta:hover {
    background: var(--primary-dark);
    box-shadow: 0 4px 12px rgba(0, 174, 239, 0.3);
}

.cookie-banner .btn-outline-secondary {
    color: #64748b;
    border-color: #e2e8f0;
    font-size: 0.8rem;
    font-weight: 500;
    border-radius: 8px;
}

.cookie-banner .btn-outline-secondary:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #334155;
}

/* Quote Widget Refinements */
.quote-toggle-btn {
    position: fixed;
    right: 25px;
    bottom: 90px; /* Above sticky mobile call */
    background: var(--primary-blue);
    color: white !important;
    padding: 1rem 1.5rem;
    border-radius: 50px;
    cursor: pointer;
    z-index: 1040;
    box-shadow: 0 10px 25px rgba(0, 174, 239, 0.4);
    font-weight: 700;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.quote-toggle-btn:hover {
    transform: translateY(-5px) scale(1.05);
    background: var(--primary-dark);
}

@media (min-width: 992px) {
    .quote-toggle-btn {
        right: 0;
        top: 50%;
        bottom: auto;
        transform: translateY(-50%) rotate(-90deg);
        transform-origin: right center;
        border-radius: 12px 12px 0 0;
        padding: 0.8rem 1.8rem;
        white-space: nowrap;
        transition: transform 0.3s ease, background 0.3s ease, right 0.3s ease;
    }
    
    .quote-toggle-btn:hover {
        right: 0;
        transform: translateY(-50%) rotate(-90deg);
        background: var(--primary-dark);
    }
}

.quote-toggle-btn.hidden {
    opacity: 0;
    pointer-events: none;
    transform: scale(0.8);
}

.quote-widget {
    position: fixed;
    right: 25px;
    bottom: 25px;
    z-index: 1060;
    width: 380px;
    max-width: calc(100vw - 50px);
    background: white;
    border-radius: 24px;
    box-shadow: 0 30px 100px rgba(0,0,0,0.2);
    overflow: hidden;
    transform: translateY(130%);
    opacity: 0;
    transition: transform 0.7s cubic-bezier(0.165, 0.84, 0.44, 1), opacity 0.5s ease;
    border: 1px solid rgba(0,0,0,0.05);
}

.quote-widget.active {
    transform: translateY(0);
    opacity: 1;
}

.quote-widget-header {
    background: var(--primary-blue);
    color: white;
    padding: 1.25rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.quote-widget-header .fw-bold {
    font-size: 1.1rem;
    letter-spacing: 0.5px;
}

.quote-widget-body {
    padding: 1.75rem;
}

.quote-widget .form-label {
    font-weight: 600;
    color: #4b5563;
    margin-bottom: 0.4rem;
}

.quote-widget .btn-cta {
    background: var(--primary-blue);
    color: white !important;
    font-weight: 700;
    padding: 0.8rem;
    border-radius: 10px;
}

.quote-widget .btn-cta:hover {
    background: var(--primary-dark);
    box-shadow: 0 8px 20px rgba(0, 174, 239, 0.2);
}

@media (max-width: 576px) {
    .quote-widget {
        right: 15px;
        left: 15px;
        bottom: 85px;
        width: auto;
    }
}

/* Sticky Mobile Call Improvements */
.sticky-mobile-call .btn {
    border-radius: 0;
    font-weight: 800;
    letter-spacing: 0.5px;
    box-shadow: 0 -5px 20px rgba(0,0,0,0.1);
}



  
/* Review Read More Styling */  
.review-content { position: relative; max-height: 120px; overflow: hidden; transition: max-height 0.5s ease; }  
.review-content.expanded { max-height: 1000px; }  
.read-more-btn { color: var(--primary-blue); cursor: pointer; font-weight: 600; display: block; margin-top: 5px; font-size: 0.9rem; }  
.read-more-btn:hover { text-decoration: underline; } 
