/* =========================================
   Zielinski BAUWERKSABDICHTUNG - MODERN BLUE/GREY
   ========================================= */

:root {
    /* Color Palette (Gold & Black) */
    --primary-blue: #000000;
    /* Pure Black */
    --primary-dark: #111111;
    /* Soft Black */
    --secondary-grey: #f4f4f4;
    /* Light Grey Backgrounds */
    --text-main: #222222;
    /* Dark Grey Text */
    --text-light: #666666;
    /* Muted Grey */
    --accent-orange: #D4AF37;
    /* Metallic Gold */
    --accent-gold: #C5A028;
    /* Darker Gold Hover */
    --white: #ffffff;

    /* Typography */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Open Sans', sans-serif;

    /* Spacing */
    --container-width: 1200px;
    --section-padding: 80px 0;

    /* Components (2026 Modern) */
    --shadow-soft: 0 10px 30px -10px rgba(26, 60, 94, 0.1);
    --shadow-hover: 0 25px 50px -12px rgba(26, 60, 94, 0.25);
    --shadow-glow: 0 0 20px rgba(243, 156, 18, 0.4);
    --radius: 12px;
    /* Smoother, larger radius */
    --glass-bg: rgba(255, 255, 255, 0.8);
    --glass-border: 1px solid rgba(255, 255, 255, 0.5);
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    /* Smooth 'Apple-like' spring */
}

/* Reset & Base */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    color: var(--text-main);
    background-color: #fafbfc;
    /* Ultra-light blue-grey tint */
    line-height: 1.7;
    /* More breathing room */
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    /* Crisp text */
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--primary-dark);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1rem;
    letter-spacing: -0.5px;
    /* Modern tight tracking */
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
    border-radius: var(--radius);
}

/* Utilities */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 25px;
}

/* Modern Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 35px;
    background: linear-gradient(135deg, var(--accent-orange), var(--accent-gold));
    color: var(--white);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.9rem;
    border-radius: 50px;
    /* Pill shape */
    letter-spacing: 1px;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(243, 156, 18, 0.3);
    position: relative;
    overflow: hidden;
}

.btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 25px rgba(243, 156, 18, 0.5);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--white);
    /* White border for hero */
    color: var(--white);
    box-shadow: none;
}

.btn-outline:hover {
    background-color: var(--white);
    color: var(--primary-blue);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.3);
}

/* Dark outline for non-hero sections */
.btn-outline.dark {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

.btn-outline.dark:hover {
    background-color: var(--primary-blue);
    color: var(--white);
}

.section-title {
    text-align: center;
    font-size: 3rem;
    /* Larger */
    margin-bottom: 20px;
    color: var(--primary-blue);
    position: relative;
    display: inline-block;
    width: 100%;
}

.section-subtitle {
    text-align: center;
    max-width: 650px;
    margin: 0 auto 70px;
    color: var(--text-light);
    font-size: 1.2rem;
    font-weight: 400;
}

/* Scroll Animation Classes */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Header (Transparent & Sticky) */
.header {
    background-color: transparent;
    box-shadow: none;
    border-bottom: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    padding: 20px 0;
    /* Spacious at top */
    transition: all 0.4s ease;
}

/* Scrolled State (Solid Black) */
/* Scrolled State (White Mode) */
.header.scrolled {
    background-color: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 15px 0;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid rgba(212, 175, 55, 0.3);
    /* Gold border */
}

.header.scrolled .logo-text,
.header.scrolled .nav-link,
.header.scrolled .mobile-toggle {
    color: var(--primary-blue) !important;
    /* Force Black text */
}

.header.scrolled .nav-link.active {
    color: var(--accent-orange) !important;
}

.header.scrolled .nav-link::after {
    background: var(--accent-orange);
    /* Keep Gold underline */
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0;
    text-decoration: none;
}

.logo img {
    height: 90px;
    width: auto;
    margin-right: -35px;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.3));
    transition: height 0.3s ease;
}

.header.scrolled .logo img {
    height: 70px;
    /* Shrink logo on scroll */
}

.logo-text {
    display: flex;
    flex-direction: column;
    font-family: var(--font-heading);
    line-height: 1.1;
    color: var(--white);
    /* White for Dark Mode */
    font-weight: 800;
    font-size: 1.4rem;
    text-transform: uppercase;
    letter-spacing: -0.5px;
}

.logo-text span {
    font-size: 0.85rem;
    color: var(--accent-orange);
    /* Gold */
    font-weight: 700;
    letter-spacing: 2px;
}

.nav-menu {
    display: flex;
    gap: 40px;
}

/* More space */
.nav-link {
    font-weight: 600;
    color: var(--white);
    /* White for Dark Mode */
    font-size: 0.95rem;
    position: relative;
    padding: 5px 0;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    bottom: -5px;
    /* Lower underline */
    left: 0;
    background: linear-gradient(90deg, var(--accent-orange), var(--accent-gold));
    transition: var(--transition);
    border-radius: 2px;
}

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

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link.active {
    color: var(--accent-orange);
}

.mobile-toggle {
    display: none;
    font-size: 1.5rem;
    color: var(--primary-blue);
    cursor: pointer;
}

/* Hero Section (Immersive) */
.hero {
    height: 100vh;
    /* Full height */
    min-height: 700px;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.9), rgba(20, 20, 20, 0.8)), url('../images/hero-bg.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    /* Parallax feel */
    display: flex;
    align-items: center;
    text-align: center;
    color: var(--white);
    margin-top: 0;
    /* Behind header */
    padding-top: 80px;
}

.hero-brand {
    display: inline-block;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 4px;
    color: var(--accent-orange);
    margin-bottom: 20px;
    font-weight: 700;
    background: rgba(255, 255, 255, 0.1);
    padding: 8px 20px;
    border-radius: 30px;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-content h1 {
    font-size: clamp(3rem, 5vw, 4.5rem);
    /* Massive responsive text */
    color: var(--white);
    margin-bottom: 25px;
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    font-weight: 900;
    letter-spacing: -1px;
}

.hero-content p {
    font-size: 1.35rem;
    max-width: 750px;
    margin: 0 auto 50px;
    opacity: 0.9;
    font-weight: 400;
    line-height: 1.6;
}

/* Services Grid (Modern Cards) */
.services {
    padding: 120px 0;
    /* More whitespace */
    background-color: #fafbfc;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
    /* More gap */
}

.service-card {
    background: var(--white);
    padding: 50px 40px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    text-align: left;
    /* Modern Left Align */
    border: 1px solid rgba(0, 0, 0, 0.03);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--accent-orange);
    opacity: 0;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.service-card:hover::before {
    opacity: 1;
}

.service-icon {
    font-size: 3rem;
    color: var(--accent-orange);
    margin-bottom: 25px;
    display: inline-block;
    background: rgba(243, 156, 18, 0.1);
    /* Circle bg */
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.service-card:hover .service-icon {
    background: var(--accent-orange);
    color: var(--white);
    transform: rotateY(180deg);
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--primary-blue);
}

.service-card p {
    color: var(--text-light);
    margin-bottom: 25px;
    font-size: 1rem;
    line-height: 1.7;
}

.service-link {
    color: var(--primary-blue);
    font-weight: 700;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    position: relative;
}

.service-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0%;
    height: 2px;
    background: var(--accent-orange);
    transition: var(--transition);
}

.service-link:hover {
    color: var(--accent-orange);
    gap: 12px;
}

.service-link:hover::after {
    width: 100%;
}

/* Contact Section */
.contact-section {
    padding: var(--section-padding);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-info-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background-color: rgba(26, 60, 94, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-blue);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.info-content h4 {
    margin-bottom: 5px;
    font-size: 1.1rem;
}

.info-content p {
    color: var(--text-light);
}

.contact-form {
    background: var(--secondary-grey);
    padding: 40px;
    border-radius: var(--radius);
}

.form-group {
    margin-bottom: 20px;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #e2e8f0;
    border-radius: var(--radius);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(26, 60, 94, 0.1);
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

/* Footer (Premium Dark - Compact) */
.footer {
    background-color: #050505;
    /* Ultra Dark */
    color: var(--white);
    padding: 30px 0 15px;
    /* Minimal padding */
    border-top: 3px solid var(--accent-orange);
    position: relative;
    z-index: 10;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    /* Reduced gap */
    margin-bottom: 20px;
    /* Reduced margin */
}

/* Footer Brand Lockup */
.footer-brand {
    display: flex;
    align-items: center;
    gap: 0;
    margin-bottom: 20px;
    text-decoration: none;
}

.footer-logo {
    width: 130px;
    height: auto;
    margin-bottom: 0;
    margin-right: -30px;
}

.footer-brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-mz {
    color: var(--white);
    font-size: 1.8rem;
    font-weight: 900;
    font-family: var(--font-heading);
    letter-spacing: -1px;
}

.brand-sub {
    color: var(--accent-orange);
    /* Gold */
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-top: 2px;
}

.footer-col h4 {
    color: var(--white);
    margin-bottom: 15px;
    /* Reduced margin */
    font-size: 1.1rem;
    /* Slightly smaller */
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-col p {
    color: #aaaaaa;
    line-height: 1.6;
    /* tighter line height */
    margin-bottom: 15px;
    font-size: 0.9rem;
}

.footer-col ul li {
    margin-bottom: 10px;
    /* Reduced margin */
    color: #cccccc;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
}

.footer-col i {
    color: var(--accent-orange);
    width: 18px;
}

.footer-links li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 8px;
    /* Reduced padding */
}

.footer-links li:last-child {
    border-bottom: none;
}

.footer a {
    color: #cccccc;
    transition: var(--transition);
}

.footer a:hover {
    color: var(--accent-orange);
    padding-left: 5px;
}

.footer-bottom {
    text-align: center;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: #555;
    font-size: 0.8rem;
}

/* Info Section (Base) */
.info-section {
    padding: 100px 0;
    background-color: var(--secondary-grey);
}

.info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

/* About Grid Layout */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-image {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
}

.about-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Gallery Styles */
.gallery-section {
    padding: var(--section-padding);
    background-color: var(--white);
}

.gallery-project {
    margin-bottom: 80px;
}

.gallery-project h3 {
    text-align: center;
    margin-bottom: 40px;
    font-size: 2rem;
    color: var(--primary-blue);
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.gallery-project h3::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--accent-orange);
}

.gallery-container {
    display: flex;
    flex-direction: column;
    gap: 50px;
    /* Space between groups */
}

/* Flex row for compact, centered, un-cropped images */
.gallery-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.gallery-item {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    cursor: pointer;
    background: #f0f0f0;

    /* Control size via height */
    height: 380px;
    width: auto;
    /* Let content define width */
    flex: 0 0 auto;
    /* Don't grow/shrink unexpectedly */
    display: flex;
    /* Remove extra bottom space */
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.gallery-item img {
    height: 100%;
    /* Fill container height */
    width: auto;
    /* Maintain aspect ratio */
    display: block;
    object-fit: contain;
    /* Ensure no cropping */
    transition: transform 0.6s ease;
}

.gallery-item:hover img {
    transform: scale(1.02);
}

/* Mobile: Allow stacking and natural width */
@media (max-width: 768px) {
    .gallery-item {
        height: auto;
        width: 100%;
        max-width: 400px;
    }

    .gallery-item img {
        width: 100%;
        height: auto;
    }
}

/* Responsive */

/* Tablet & Mobile */
@media (max-width: 1024px) {
    .container {
        padding: 0 20px;
    }

    .hero-content h1 {
        font-size: 3.5rem;
    }

    .section-title {
        font-size: 2.5rem;
    }

    .section-title {
        font-size: 2.5rem;
    }

    /* Mobile Navigation (Moved from 768px to 1024px for iPad) */
    .nav-menu {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(5, 5, 5, 0.98);
        backdrop-filter: blur(15px);
        -webkit-backdrop-filter: blur(15px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 0;
        gap: 30px;
        transform: translateY(-100%);
        transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
        z-index: 998;
    }

    .nav-menu.active {
        transform: translateY(0);
    }

    .nav-link,
    .header.scrolled .nav-link {
        color: var(--white) !important;
        font-size: 1.5rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 1px;
    }

    .nav-link:hover,
    .nav-link.active,
    .header.scrolled .nav-link.active,
    .header.scrolled .nav-link:hover {
        color: var(--accent-orange) !important;
    }

    .mobile-toggle {
        display: block;
        color: var(--white);
        z-index: 999;
        font-size: 1.8rem;
    }

    .header.scrolled .mobile-toggle {
        color: var(--primary-blue);
    }

    .mobile-toggle.active {
        color: var(--white) !important;
        position: fixed;
        right: 25px;
        top: 25px;
    }

    /* Force white color when menu is active, even if header is scrolled */
    .header.scrolled .mobile-toggle.active {
        color: var(--white) !important;
    }
}

/* Mobile Devices */
@media (max-width: 768px) {

    /* Mobile Navigation moved to 1024px block */

    /* Hero */
    .hero {
        background-attachment: scroll;
        /* Fix for mobile browsers */
        background-position: center center;
        min-height: 100vh;
        /* Ensure full height */
        padding-top: 120px;
        /* More space for fixed header */
        height: auto;
        /* Allow growth if content is long */
    }

    .hero-content h1 {
        font-size: 2rem;
        word-wrap: break-word;
        /* Prevent overflow */
    }

    .hero-content p {
        font-size: 1rem;
        padding: 0 10px;
        margin-bottom: 30px;
    }

    .hero-content .btn {
        display: block;
        width: 100%;
        margin-bottom: 20px;
        /* Space between buttons */
    }

    /* Intro Splash Mobile */
    #intro-splash h2 {
        font-size: 1.1rem !important;
        /* Smaller on mobile */
        padding: 0 20px;
    }

    #intro-splash img {
        width: 50px !important;
    }

    #intro-splash span[style*="font-size: 2.5rem"] {
        font-size: 1.8rem !important;
    }

    /* Grids & Layout */
    .contact-grid,
    .services-grid,
    .footer-grid,
    .about-grid,
    .info-section .container>div {
        grid-template-columns: 1fr !important;
        gap: 40px !important;
    }

    /* Info Section Image */
    .info-image img {
        min-height: 250px !important;
    }

    .info-text h2 {
        font-size: 1.5rem !important;
        /* Smaller font for long words */
        word-wrap: break-word;
        /* Prevent overflow */
        hyphens: auto;
    }

    /* Footer */
    .footer-brand {
        justify-content: center;
    }

    .footer-logo {
        width: 80px;
        margin-right: -15px;
    }

    .footer-col {
        text-align: center;
    }

    .footer-col ul li {
        justify-content: center;
    }

    .footer-bottom {
        font-size: 0.75rem;
    }

    /* Fix Header Overlap */
    .logo img,
    .header.scrolled .logo img {
        height: 50px;
        margin-right: -15px;
    }

    .logo-text {
        font-size: 1rem;
    }

    .logo-text span {
        font-size: 0.65rem;
    }
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: -100%;
    left: 20px;
    right: 20px;
    background: #050505;
    color: var(--white);
    padding: 30px;
    border-radius: var(--radius);
    box-shadow: 0 -5px 25px rgba(0, 0, 0, 0.5);
    z-index: 10001;
    border: 1px solid rgba(212, 175, 55, 0.3);
    transition: bottom 0.5s ease-in-out;
    max-width: 600px;
    margin: 0 auto;
}

.cookie-banner.show {
    bottom: 20px;
}

.cookie-content h3 {
    color: var(--accent-orange);
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.cookie-content p {
    font-size: 0.9rem;
    margin-bottom: 20px;
    color: var(--text-light);
    line-height: 1.5;
}

.cookie-buttons {
    display: flex;
    gap: 15px;
}

@media (max-width: 768px) {
    .cookie-banner {
        left: 10px;
        right: 10px;
        bottom: -100%;
        padding: 20px;
    }

    .cookie-banner.show {
        bottom: 10px;
    }

    .cookie-buttons {
        flex-direction: column;
        gap: 10px;
    }

    .cookie-buttons .btn {
        width: 100%;
        margin-right: 0;
    }
}