/* ==========================================================================
   1. GLOBALE EINSTELLUNGEN
   ========================================================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 76px;
}

body {
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: var(--ink-soft);
    background-color: var(--paper);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

body.menu-open {
    overflow: hidden;
}

img {
    max-width: 100%;
}


/* ==========================================================================
   2. FARBEN, TYPOGRAFIE & VARIABLEN
   ========================================================================== */

:root {
    /* Marke — unveraendert aus dem bestehenden Farbschema */
    --dark-steel: #0d0f12;

    --section-1: #2bc3ea;
    --section-2: #72c0b2;
    --section-3: #b7ba82;
    --section-4: #edb460;

    --logo-blue: #2bc3ea;
    --logo-beige: #edb460;

    --logo-gradient: linear-gradient(135deg, var(--section-1) 0%, var(--section-2) 33%, var(--section-3) 66%, var(--section-4) 100%);
    --logo-gradient-blue: linear-gradient(135deg, var(--section-1) 0%, var(--section-2) 45%, var(--section-4) 100%);
    --logo-gradient-beige: linear-gradient(135deg, var(--section-1) 0%, var(--section-3) 55%, var(--section-4) 100%);

    /* Neutrale Basis — warmer & ruhiger als reines Schwarz/Weiss */
    --paper: #f7f4ee;
    --paper-alt: #efeadf;
    --pure-white: #ffffff;

    --ink: #1b1d20;
    --ink-soft: #4d565d;
    --ink-faint: #8a9096;

    --line: #ddd8cb;

    /* Typografie */
    --font-display: "Space Grotesk", "Inter", sans-serif;
    --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: "IBM Plex Mono", "SFMono-Regular", Menlo, monospace;
}


/* ==========================================================================
   3. ALLGEMEINES LAYOUT
   ========================================================================== */

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 6rem 0;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4.5rem;
    align-items: center;
}

.equal-height-grid {
    align-items: stretch;
}


/* ==========================================================================
   4. TYPOGRAFIE
   ========================================================================== */

h1, h2, h3 {
    font-family: var(--font-display);
    color: var(--ink);
}

h2 {
    margin-bottom: 1rem;
    font-size: 2.4rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.15;
}

.bold {
    font-weight: 700;
}

.section-head {
    max-width: 620px;
    margin-bottom: 3.5rem;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1rem;
    font-family: var(--font-mono);
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-faint);
}

.eyebrow::before {
    content: "";
    display: block;
    width: 22px;
    height: 2px;
    background: var(--logo-gradient);
    border-radius: 2px;
}

.section-head p {
    max-width: 52ch;
    color: var(--ink-soft);
}


/* Die frühere separate Scroll-Fortschrittsleiste entfaellt zugunsten
   des Header-Massbands (siehe Abschnitt 4d), das dieselbe Funktion
   uebernimmt und zusaetzlich den aktiven Abschnitt anzeigt. */


/* ==========================================================================
   4c. SCROLL-REVEAL
   ========================================================================== */

.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}


/* ==========================================================================
   4d. HEADER-MASSBAND (durchgehende Navigation)
   Ein horizontales Massband ganz oben im Header, ueber Logo und Links.
   Ein Marker gleitet beim Scrollen zum jeweils aktiven Abschnitts-Link
   und highlightet ihn wie bei :hover. Ersetzt die fruehere vertikale
   Variante auf allen Bildschirmgroessen.
   ========================================================================== */

.header-ruler {
    position: relative;
    height: 11px;
    background-color: var(--dark-steel);
    background-image:
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.5) 0 1.5px, transparent 1.5px 9px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.65) 0 2px, transparent 2px 45px);
    background-repeat: repeat-x, repeat-x;
    background-position: top left, top left;
    background-size: 9px 55%, 45px 100%;
}

.header-ruler-marker {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0;
    background: var(--marker-color, var(--section-1));
    opacity: 0;
    border-radius: 0 0 3px 3px;
    transition: left 0.4s cubic-bezier(0.65, 0, 0.35, 1), width 0.4s cubic-bezier(0.65, 0, 0.35, 1),
        opacity 0.25s ease, background-color 0.3s ease;
}

.header-ruler-marker.is-visible {
    opacity: 0.85;
}

.header-ruler-marker::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 100%;
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid var(--marker-color, var(--section-1));
    transform: translateX(-50%);
}

/* Nav-Links werden aktiv genauso eingefaerbt wie bei :hover */
.nav-left .nav-links li:nth-child(1) a.is-active { color: var(--section-1); }
.nav-left .nav-links li:nth-child(2) a.is-active { color: var(--section-2); }
.nav-right .nav-links li:nth-child(1) a.is-active { color: var(--section-3); }
.nav-right .nav-links li:nth-child(2) a.is-active { color: var(--section-4); }


/* ==========================================================================
   5. HEADER
   ========================================================================== */

header {
    position: sticky;
    top: 0;
    z-index: 1000;

    background-color: var(--dark-steel);
    background-image: var(--logo-gradient);
    background-size: 100% 2px;
    background-repeat: no-repeat;
    background-position: bottom;
}

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


/* ==========================================================================
   6. DESKTOP NAVIGATION
   ========================================================================== */

.nav-group {
    flex: 1;
}

.nav-left {
    display: flex;
    justify-content: flex-end;
}

.nav-right {
    display: flex;
    justify-content: flex-start;
}

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

.nav-left .nav-links li {
    margin-left: 4rem;
}

.nav-right .nav-links li {
    margin-right: 4rem;
}

.nav-links a {
    position: relative;
    color: rgba(255, 255, 255, 0.85);
    font-family: var(--font-mono);
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-decoration: none;
    transition: color 0.2s ease;
}

.nav-links a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -6px;
    width: 0;
    height: 1px;
    background: currentColor;
    transition: width 0.25s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-left .nav-links li:nth-child(1) a:hover { color: var(--section-1); }
.nav-left .nav-links li:nth-child(2) a:hover { color: var(--section-2); }
.nav-right .nav-links li:nth-child(1) a:hover { color: var(--section-3); }
.nav-right .nav-links li:nth-child(2) a:hover { color: var(--section-4); }


/* ==========================================================================
   7. LOGO
   ========================================================================== */

.logo {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    padding: 0 4rem;
}

.logo img {
    display: block;
    width: auto;
    height: 42px;
    transition: transform 0.2s ease;
}

.logo img:hover {
    transform: scale(1.03);
}


/* ==========================================================================
   7b. MOBILE ABSCHNITTS-TITEL
   Zeigt in der Mitte des Headers (wo auf Mobile sonst Leerraum waere)
   den Titel des aktuell sichtbaren Abschnitts.
   ========================================================================== */

.mobile-section-label {
    display: none;
}


/* ==========================================================================
   8. MOBILE NAVIGATION
   ========================================================================== */

.menu-toggle {
    display: none;
    width: 24px;
    height: 16px;
    flex-direction: column;
    justify-content: space-between;
    padding: 0;

    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1002;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--pure-white);
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.mobile-menu {
    display: none;
}


/* ==========================================================================
   9. HERO
   ========================================================================== */

.hero {
    position: relative;
    display: flex;
    min-height: 62vh;
    align-items: center;
    overflow: hidden;
    color: var(--pure-white);

    /* Sicherheits-Fallback, falls JavaScript nicht laedt */
    background: var(--dark-steel) url("images/hero.png") center center / cover no-repeat;
}

.hero-background {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

.hero-background-track {
    display: flex;
    width: max-content;
    height: 100%;
    opacity: 0;
    will-change: transform;
}

.hero-background-track.is-ready {
    opacity: 1;
    animation: hero-background-scroll var(--hero-duration, 40s) linear infinite;
}

.hero-background-group {
    display: flex;
    flex: 0 0 auto;
    height: 100%;
}

.hero-background-tile {
    display: block;
    flex: 0 0 var(--hero-tile-width);
    width: var(--hero-tile-width);
    height: 100%;
    max-width: none;
    object-fit: fill;
    user-select: none;
    pointer-events: none;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(115deg, rgba(13, 15, 18, 0.95) 24%, rgba(13, 15, 18, 0.72) 52%, rgba(13, 15, 18, 0.35) 100%);
}

@keyframes hero-background-scroll {
    from { transform: translate3d(-50%, 0, 0); }
    to   { transform: translate3d(0, 0, 0); }
}

.hero .container {
    padding: 0;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 640px;
}

.hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 1.75rem;
    padding: 0.4rem 0.9rem 0.4rem 0.5rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 100px;
    font-family: var(--font-mono);
    font-size: 0.78rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.85);
}

.hero-tag .dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--logo-gradient);
}

.hero-content h1 {
    margin-bottom: 1.5rem;
    color: var(--pure-white);
    font-size: 3.4rem;
    font-weight: 600;
    line-height: 1.08;
    letter-spacing: -0.02em;
}

.highlight-gradient {
    background: var(--logo-gradient-beige);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.highlight-gradient:hover {
    background: var(--logo-gradient-blue);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-content p {
    margin-bottom: 2.5rem;
    color: rgba(255, 255, 255, 0.82);
    font-size: 1.15rem;
    max-width: 46ch;
}

.hero-content .btn {
    margin-right: 0.75rem;
}


/* ==========================================================================
   10. BUTTONS
   ========================================================================== */

.btn {
    display: inline-block;
    padding: 0.95rem 2rem;

    background-color: var(--dark-steel);
    color: var(--pure-white);

    border: 1.5px solid var(--section-1);
    border-radius: 6px;

    font-family: var(--font-display);
    font-size: 0.92rem;
    font-weight: 600;
    letter-spacing: -0.01em;

    text-decoration: none;

    cursor: pointer;

    transition: transform 0.2s ease, background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
    background-color: var(--section-1);
    color: var(--dark-steel);
    border-color: var(--section-1);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(43, 195, 234, 0.22);
}

.btn-rental {
    border-color: var(--section-3);
    background-color: transparent;
    color: var(--ink);
}

.btn-rental:hover {
    background-color: var(--section-3);
    border-color: var(--section-3);
    color: var(--dark-steel);
    box-shadow: 0 8px 20px rgba(183, 186, 130, 0.28);
}

.btn-form {
    width: 100%;
    border-color: var(--section-4);
}

.btn-form:hover {
    background-color: var(--section-4);
    border-color: var(--section-4);
    color: var(--dark-steel);
    box-shadow: 0 8px 20px rgba(237, 180, 96, 0.28);
}


/* ==========================================================================
   11. MASSBAND — SIGNATURE ELEMENT
   Ein feiner "Messband"-Streifen ersetzt die frueheren dicken Farbbalken
   unter Bildern. Nimmt den Marken-Farbverlauf auf und spielt auf die
   Werkzeug-/Praezisionswelt des Betriebs an.
   ========================================================================== */

.measure-bar {
    position: relative;
    flex: 0 0 18px; /* explizite Basis, damit Grid-Stretch + Flex die Hoehe nicht auf 0 kollabiert */
    height: 18px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    padding: 0 8px 1px;
    box-shadow: inset 0 2px 4px rgba(13, 15, 18, 0.18); /* Naht zum Bild: wirkt wie aufgelegtes Band */
    background-image:
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.85) 0 1.5px, transparent 1.5px 9px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.95) 0 2px, transparent 2px 45px),
        var(--logo-gradient);
    background-repeat: repeat-x, repeat-x, no-repeat;
    background-position: 5px top, 5px top, center;
    background-size: 9px 60%, 45px 100%, 100% 100%;
}

/* Kleine Massangaben — verstaerken den Eindruck, das Bild werde ausgemessen */
.measure-bar-tick {
    font-family: var(--font-mono);
    font-size: 0.55rem;
    line-height: 1;
    letter-spacing: 0.02em;
    color: rgba(255, 255, 255, 0.8);
    text-shadow: 0 1px 1px rgba(13, 15, 18, 0.35);
    user-select: none;
}


/* ==========================================================================
   12. GEMEINSAME BILD-LAYOUTS
   ========================================================================== */

.section-image {
    position: relative;
    min-height: 100%;
    overflow: hidden;
    border-radius: 4px;
}

.section-image img,
.about-image img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 100%;
    object-fit: cover;
}


/* ==========================================================================
   13. DER BETRIEB
   ========================================================================== */

/* Der Betrieb & Vermietung: bewusst schlicht, nur die reine
   Hintergrundfarbe - kein Muster, das mit dem Inhalt konkurriert. */

/* Portfolio & Kontakt: mehrschichtiges Blueprint-Raster statt Foto-
   Textur. Feines Grundraster + grobes Hauptraster + kleine Punkte an
   dessen Kreuzungen, dazu ein Inset-Schatten fuer Tiefe. Ergibt den
   Eindruck von Millimeterpapier/Konstruktionszeichnung, ohne dass ein
   echtes Bild geladen werden muss. */
.portfolio-section,
.contact-section {
    position: relative;
    background-image:
        radial-gradient(circle 1.4px at 0 0, rgba(13, 15, 18, 0.4), rgba(13, 15, 18, 0.4) 100%, transparent 100%),
        linear-gradient(rgba(13, 15, 18, 0.055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(13, 15, 18, 0.055) 1px, transparent 1px),
        linear-gradient(rgba(13, 15, 18, 0.022) 1px, transparent 1px),
        linear-gradient(90deg, rgba(13, 15, 18, 0.022) 1px, transparent 1px);
    background-size:
        128px 128px,
        128px 128px,
        128px 128px,
        32px 32px,
        32px 32px;
    box-shadow:
        inset 0 18px 24px -18px rgba(13, 15, 18, 0.16),
        inset 0 -18px 24px -18px rgba(13, 15, 18, 0.16);
}

.about-section {
    background-color: var(--paper);
}

.about-content {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 3.5rem;
    align-items: stretch;
}

.about-features {
    display: flex;
    flex-direction: column;
}

.about-feature {
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
    padding: 1.6rem 0;
    border-bottom: 1px solid var(--line);
}

.about-feature:first-child {
    padding-top: 0;
}

.about-feature-tag {
    flex: 0 0 10px;
    width: 10px;
    height: 10px;
    margin-top: 0.45rem;
    border-radius: 2px;
}

.about-feature:nth-child(1) .about-feature-tag { background: var(--section-1); }
.about-feature:nth-child(2) .about-feature-tag { background: var(--section-2); }
.about-feature:nth-child(3) .about-feature-tag { background: var(--section-3); }
.about-feature:nth-child(4) .about-feature-tag { background: var(--section-4); }

.about-feature-content {
    min-width: 0;
}

.about-feature-content h3 {
    margin-bottom: 0.35rem;
    font-size: 1.08rem;
    font-weight: 600;
}

.about-feature-content p {
    margin: 0;
    font-size: 0.98rem;
    line-height: 1.55;
}

.about-image {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 320px;
    display: flex;
    flex-direction: column;
    gap: 0;
    border-radius: 10px;
    box-shadow: 0 10px 26px rgba(13, 15, 18, 0.12);
}

.about-image .section-image {
    flex: 1;
    border-radius: 10px 10px 0 0;
    overflow: hidden;
}

.about-image .measure-bar {
    border-radius: 0 0 10px 10px;
}

.about-image img {
    position: absolute;
    inset: 0;
    object-position: top center; /* Zuschnitt passiert nur unten, Kopf/Logo oben bleibt sichtbar */
}


/* ==========================================================================
   14. PORTFOLIO
   ========================================================================== */

.portfolio-section {
    background-color: var(--paper-alt);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.75rem;
}

.portfolio-item {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0;
    cursor: pointer;
    perspective: 800px;
}

.portfolio-item-frame {
    position: relative;
    height: 300px;
    overflow: hidden;
    border-radius: 10px 10px 0 0;
    background-color: var(--dark-steel);
    box-shadow: 0 10px 26px rgba(13, 15, 18, 0.12);
    transition: transform 0.25s ease-out;
    transform-style: preserve-3d;
    will-change: transform;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease, opacity 0.3s ease;
}

.portfolio-overlay {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    padding: 1.75rem;
    color: var(--pure-white);
    background: linear-gradient(transparent, rgba(13, 15, 18, 0.95));
    transform: translateY(8px);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.portfolio-overlay h3 {
    margin-bottom: 0.2rem;
    color: var(--pure-white);
    font-size: 1.2rem;
    font-weight: 600;
}

.portfolio-overlay p {
    font-size: 0.9rem;
    font-weight: 500;
}

.portfolio-item:nth-child(1) .portfolio-overlay p { color: var(--section-1); }
.portfolio-item:nth-child(2) .portfolio-overlay p { color: var(--section-2); }
.portfolio-item:nth-child(3) .portfolio-overlay p { color: var(--section-3); }

.portfolio-item .measure-bar {
    border-radius: 0 0 10px 10px;
    background-repeat: repeat-x, repeat-x, no-repeat;
    background-position: 5px top, 5px top, center;
    background-size: 9px 60%, 45px 100%, 100% 100%;
}

.portfolio-item:nth-child(1) .measure-bar { background-image: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.85) 0 1.5px, transparent 1.5px 9px), repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.95) 0 2px, transparent 2px 45px), linear-gradient(90deg, var(--section-1), var(--section-1)); }
.portfolio-item:nth-child(2) .measure-bar { background-image: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.85) 0 1.5px, transparent 1.5px 9px), repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.95) 0 2px, transparent 2px 45px), linear-gradient(90deg, var(--section-2), var(--section-2)); }
.portfolio-item:nth-child(3) .measure-bar { background-image: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.85) 0 1.5px, transparent 1.5px 9px), repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.95) 0 2px, transparent 2px 45px), linear-gradient(90deg, var(--section-3), var(--section-3)); }

@media (hover: hover) and (pointer: fine) {
    .portfolio-item:hover img {
        transform: scale(1.05);
        opacity: 0.35;
    }
    .portfolio-item:hover .portfolio-overlay {
        transform: translateY(0);
        opacity: 1;
    }
}


/* ==========================================================================
   PORTFOLIO LIGHTBOX
   ========================================================================== */

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    background-color: rgba(13, 15, 18, 0.95);
    backdrop-filter: blur(8px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.lightbox.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.lightbox-content {
    position: relative;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.lightbox-image-wrapper {
    width: 100%;
    max-height: 65vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.lightbox-image-wrapper img {
    max-width: 100%;
    max-height: 65vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.lightbox-caption {
    width: 100%;
    max-width: 700px;
    margin-top: 1.5rem;
    text-align: center;
    color: var(--pure-white);
}

.lightbox-caption h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
    color: var(--pure-white);
}

.lightbox-caption p {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.5;
    margin-bottom: 0.6rem;
}

.lightbox-counter {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    color: var(--section-3);
    margin-top: 0.2rem;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
    position: absolute;
    background: rgba(255, 255, 255, 0.08);
    color: var(--pure-white);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
    z-index: 2010;
}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(255, 255, 255, 0.16);
    border-color: var(--section-2);
    color: var(--section-2);
}

.lightbox-close {
    top: 1.5rem;
    right: 1.5rem;
    width: 44px;
    height: 44px;
    font-size: 1.7rem;
    line-height: 1;
}

.lightbox-prev,
.lightbox-next {
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    font-size: 1.3rem;
}

.lightbox-prev { left: 1.5rem; }
.lightbox-next { right: 1.5rem; }

.lightbox-prev:hover { transform: translateY(-50%) scale(1.06); }
.lightbox-next:hover { transform: translateY(-50%) scale(1.06); }

@media (max-width: 768px) {
    .lightbox-prev, .lightbox-next { width: 40px; height: 40px; font-size: 1.1rem; }
    .lightbox-prev { left: 0.5rem; }
    .lightbox-next { right: 0.5rem; }
    .lightbox-close { top: 1rem; right: 1rem; width: 40px; height: 40px; font-size: 1.5rem; }
    .lightbox-image-wrapper { max-height: 50vh; }
    .lightbox-image-wrapper img { max-height: 50vh; }
    .lightbox-caption h3 { font-size: 1.15rem; }
    .lightbox-caption p { font-size: 0.9rem; }
}


/* ==========================================================================
   15. WERKZEUGVERMIETUNG
   ========================================================================== */

.rental-section {
    background-color: var(--paper);
}

.rental-content p {
    margin-bottom: 1.1rem;
    font-size: 1.05rem;
    max-width: 48ch;
}

.rental-content .btn {
    margin-top: 1.25rem;
}

.rental-image-wrap {
    display: flex;
    flex-direction: column;
    gap: 0;
    height: 100%;
    border-radius: 10px;
    box-shadow: 0 10px 26px rgba(13, 15, 18, 0.12);
}

.rental-image-wrap .section-image {
    flex: 1;
    border-radius: 10px 10px 0 0;
    overflow: hidden;
}

.rental-image-wrap .measure-bar {
    border-radius: 0 0 10px 10px;
    background-image:
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.85) 0 1.5px, transparent 1.5px 9px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.95) 0 2px, transparent 2px 45px),
        linear-gradient(90deg, var(--section-3), var(--section-3));
    background-repeat: repeat-x, repeat-x, no-repeat;
    background-position: 5px top, 5px top, center;
    background-size: 9px 60%, 45px 100%, 100% 100%;
}


/* ==========================================================================
   16. KONTAKT
   ========================================================================== */

.contact-section {
    background-color: var(--paper-alt);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 4rem;
    align-items: start;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--ink);
    font-family: var(--font-mono);
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.9rem 1rem;

    background-color: var(--pure-white);
    color: var(--ink);

    border: 1.5px solid var(--line);
    border-radius: 4px;

    font: inherit;

    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group textarea {
    resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--section-4);
    box-shadow: 0 0 0 3px rgba(237, 180, 96, 0.14);
}

.contact-details {
    display: flex;
    flex-direction: column;
}

.map-wrap {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-bottom: 1.75rem;
    border-radius: 10px;
    box-shadow: 0 10px 26px rgba(13, 15, 18, 0.12);
}

.map-container {
    width: 100%;
    height: 240px;
    overflow: hidden;
    border-radius: 10px 10px 0 0;
}

.map-container iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    filter: grayscale(0.4) contrast(1.05);
}

.map-wrap .measure-bar {
    border-radius: 0 0 10px 10px;
    background-image:
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.85) 0 1.5px, transparent 1.5px 9px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.95) 0 2px, transparent 2px 45px),
        linear-gradient(90deg, var(--section-4), var(--section-4));
    background-repeat: repeat-x, repeat-x, no-repeat;
    background-position: 5px top, 5px top, center;
    background-size: 9px 60%, 45px 100%, 100% 100%;
}

.address-box {
    display: flex;
    gap: 1.5rem;
    align-items: stretch;
    padding: 1.5rem;
    background-color: var(--pure-white);
    border: 1px solid var(--line);
    border-radius: 4px;
}

.address-image {
    flex: 0 0 120px;
    width: 120px;
    border-radius: 6px;
    overflow: hidden;
}

.address-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
}

.address-content {
    flex: 1;
}

.address-box h3 {
    margin-bottom: 0.4rem;
    font-size: 1.05rem;
    font-weight: 600;
}

.address-content > p {
    font-size: 0.95rem;
}

.contact-meta {
    margin-top: 1.1rem;
    padding-top: 1.1rem;
    border-top: 1px solid var(--line);
    font-size: 0.95rem;
}

.contact-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0 0.4rem;
}

.contact-meta-row + .contact-meta-row {
    margin-top: 0.3rem;
}

.contact-meta a {
    color: var(--ink);
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s ease;
}

.contact-meta a:hover {
    color: var(--section-4);
}


/* ==========================================================================
   17. FOOTER
   ========================================================================== */

footer {
    padding: 2.5rem 0;
    background-color: var(--dark-steel);
    background-image: var(--logo-gradient);
    background-size: 100% 2px;
    background-repeat: no-repeat;
    background-position: top;
    color: rgba(255, 255, 255, 0.45);
    text-align: center;
}

footer .container {
    padding: 0;
}

footer p {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    letter-spacing: 0.03em;
}


/* ==========================================================================
   18. MOBILE
   ========================================================================== */

@media (max-width: 768px) {

    .container {
        padding: 3.5rem 0;
    }

    h2 {
        font-size: 1.9rem;
    }

    .section-head {
        margin-bottom: 2.5rem;
    }

    .grid-2,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .equal-height-grid {
        align-items: initial;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .about-image {
        min-height: 240px;
        order: -1;
    }

    .rental-image-wrap {
        min-height: 240px;
    }

    /* Header */

    .navbar {
        position: relative;
        padding: 0.8rem 0;
    }

    .nav-group {
        display: none;
    }

    .logo {
        padding: 0;
    }

    .logo img {
        height: 38px;
    }

    .mobile-section-label {
        display: flex;
        flex: 1;
        align-items: center;
        justify-content: center;
        gap: 0.45rem;
        overflow: hidden;
        padding: 0 0.75rem;
        font-family: var(--font-mono);
        font-size: 0.72rem;
        font-weight: 500;
        letter-spacing: 0.06em;
        text-transform: uppercase;
        color: rgba(255, 255, 255, 0.88);
        white-space: nowrap;
        opacity: 0;
        transform: translateY(3px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

    .mobile-section-label::before {
        content: "";
        flex: 0 0 auto;
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: var(--dot-color, var(--section-1));
        box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
        transition: background-color 0.3s ease;
    }

    .mobile-section-label.is-visible {
        opacity: 1;
        transform: translateY(0);
    }

    /* Vereinfachter Marker: ein kleiner Pin in Form eines auf dem
       Kopf stehenden Hauses (flaches Dach oben mit kleinen
       Dachvorspruengen, spitz zulaufend nach unten) statt eines
       Segments, da auf Mobile keine Nav-Links sichtbar sind, ueber
       die er gleiten koennte. */
    .header-ruler-marker {
        top: 0;
        height: 16px;
        width: 11px !important;
        border-radius: 0;
        clip-path: polygon(0% 0%, 100% 0%, 100% 68.75%, 116% 68.75%, 50% 100%, -16% 68.75%, 0% 68.75%);
        transform: translateX(-50%);
        box-shadow: none;
    }

    .header-ruler-marker::after {
        display: none;
    }

    /* Burger */

    .menu-toggle {
        display: flex;
    }

    .menu-toggle.active span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }

    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle.active span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }

    /* Mobile Navigation */

    .mobile-menu {
        position: fixed;
        top: 62px;
        left: 0;

        display: flex;
        width: 100%;
        height: calc(100vh - 62px);

        align-items: flex-start;
        justify-content: center;

        padding-top: 3rem;

        background-color: rgba(13, 15, 18, 0.98);

        opacity: 0;
        visibility: hidden;
        pointer-events: none;

        transform: translateY(-10px);

        transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    }

    .mobile-menu.active {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }

    .mobile-menu ul {
        width: 90%;
        list-style: none;
        text-align: center;
    }

    .mobile-menu li {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .mobile-menu a {
        display: block;
        padding: 1.2rem;
        color: var(--pure-white);
        font-family: var(--font-display);
        font-size: 1.1rem;
        font-weight: 600;
        text-decoration: none;
    }

    .mobile-menu li:nth-child(1) a { color: var(--section-1); }
    .mobile-menu li:nth-child(2) a { color: var(--section-2); }
    .mobile-menu li:nth-child(3) a { color: var(--section-3); }
    .mobile-menu li:nth-child(4) a { color: var(--section-4); }

    /* Hero */

    .hero {
        min-height: 70vh;
        background-position: center center;
    }

    .hero .container {
        padding: 3rem 0;
    }

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

    .hero-content p {
        font-size: 1.05rem;
    }

    /* Bilder */

    .section-image {
        min-height: 240px;
        height: 240px;
    }

    /* Portfolio */

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .portfolio-item-frame {
        height: 260px;
    }

    .portfolio-overlay {
        transform: translateY(0);
        opacity: 1;
        background: linear-gradient(transparent 15%, rgba(13, 15, 18, 0.95));
    }

    /* Mobile Buttons */

    .btn {
        width: 100%;
        text-align: center;
        transition: background-color 0.45s ease, color 0.45s ease, border-color 0.45s ease, box-shadow 0.45s ease, transform 0.45s ease;
    }

    .hero-content .btn {
        margin-right: 0;
    }

    .btn.mobile-highlight {
        background-color: var(--section-1);
        color: var(--dark-steel);
        border-color: var(--section-1);
        transform: translateY(-2px);
        box-shadow: 0 7px 18px rgba(43, 195, 234, 0.25);
    }

    .btn-rental.mobile-highlight {
        background-color: var(--section-3);
        border-color: var(--section-3);
        box-shadow: 0 7px 18px rgba(183, 186, 130, 0.3);
    }

    .btn-form.mobile-highlight {
        background-color: var(--section-4);
        border-color: var(--section-4);
        box-shadow: 0 7px 18px rgba(237, 180, 96, 0.3);
    }

    /* Kontakt */

    .map-container {
        height: 200px;
    }

    .address-box {
        gap: 1rem;
        padding: 1.25rem;
    }

    .address-image {
        flex-basis: 92px;
        width: 92px;
    }
}


/* ==========================================================================
   19. REDUZIERTE BEWEGUNGEN
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {

    html {
        scroll-behavior: auto;
    }

    .hero-background-track.is-ready {
        animation: none;
        transform: translate3d(0, 0, 0);
    }

    .reveal {
        opacity: 1;
        transform: none;
    }

    .portfolio-item-frame,
    .hero-content {
        transform: none !important;
    }

    *,
    *::before,
    *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }

}
