
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;900&display=swap');

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

html {
    font-family: 'Montserrat', 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Light Mode Variablen (Standard) */
:root,
html {
    --primary-color: #CC0000;
    --primary-dark: #990000;
    --secondary-color: #000000;
    --text-color: #000000;
    --text-light: #666666;
    --bg-light: #ffffff;
    --bg-white: #ffffff;
    --bg-dark: #1a1a1a;
    --border-color: #e0e0e0;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 8px 15px rgba(0, 0, 0, 0.15);
}

/* Dark Mode Variablen - werden am Ende vollständig definiert */

/* Gemeinsame Transitions */
*,
*::before,
*::after {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

body {
    font-family: inherit;
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
    background-color: var(--bg-white);
}

button,
input,
textarea,
select {
    font-family: inherit;
}

/* Dark Mode Body - wird am Ende definiert */

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

/* Header & Navigation */
.header {
    --logo-height: 82px;
    background: var(--bg-white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
    overflow: visible;
    transition: box-shadow 0.3s ease;
}

/* Dark Mode Header - wird am Ende definiert */

.nav {
    padding: 0.75rem 0;
    overflow: visible;
    position: relative;
    z-index: 1001;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: visible;
}

/* Logo Styles */
.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    z-index: 1002;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    overflow: visible;
}

.logo {
    height: var(--logo-height);
    width: auto;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

/* Burger Menu Button - auf Desktop versteckt */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 30px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1003;
    position: relative;
}

.menu-toggle span {
    width: 100%;
    height: 3px;
    background: var(--text-color);
    border-radius: 3px;
    transition: all 0.3s ease;
    transform-origin: center;
}

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

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

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

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    margin: 0;
    padding: 0;
}

/* Beide Navigationsmenüs gleich breit für perfekte Zentrierung */
.nav-menu-left {
    flex: 1;
    display: flex;
    justify-content: flex-start;
}

.nav-menu-right {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

.nav-menu a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    padding-bottom: 0.5rem;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

/* Aktiver Link mit rotem Unterstrich */
.nav-menu a.active {
    color: var(--primary-color);
    background: transparent;
    transform: none;
    box-shadow: none;
}

.nav-menu a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

/* Mobile Menü - auf Desktop versteckt, auf Mobile sichtbar */
.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    left: -100%;
    width: 100%;
    max-width: 320px;
    height: 100vh;
    background: var(--bg-white);
    z-index: 999;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.1);
}

.mobile-menu.active {
    left: 0;
}

/* Close Button im Mobile Menü */
.mobile-menu-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 4px;
}

.mobile-menu-close span {
    width: 24px;
    height: 2px;
    background: var(--text-color);
    border-radius: 2px;
    transition: all 0.3s ease;
    transform-origin: center;
    position: absolute;
}

.mobile-menu-close span:nth-child(1) {
    transform: rotate(45deg);
}

.mobile-menu-close span:nth-child(2) {
    transform: rotate(-45deg);
}

.mobile-menu-close:hover span {
    background: var(--primary-color);
}

.mobile-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
    padding-top: 4rem;
    display: flex;
    flex-direction: column;
}

.mobile-menu-list li {
    width: 100%;
    margin: 0;
    border-bottom: 1px solid var(--border-color);
}

.mobile-menu-list a {
    display: block;
    padding: 1.2rem 2rem;
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    position: relative;
    transition: all 0.3s ease;
}

.mobile-menu-list a:hover {
    color: var(--primary-color);
    background: var(--bg-light);
    padding-left: 2.5rem;
}

.mobile-menu-list a.active {
    color: var(--primary-color);
    background: transparent;
}

.mobile-menu-list a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary-color);
}

/* Overlay für Mobile Menü */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-menu-overlay.active {
    display: block;
    opacity: 1;
}

/* Hero Section */
.hero {
    background: var(--bg-white);
    color: var(--text-color);
    padding: clamp(2rem, 5vw, 4rem) clamp(1rem, 3vw, 2rem) clamp(4rem, 10vw, 6rem) clamp(1rem, 3vw, 2rem);
    text-align: center;
    position: relative;
    overflow: hidden;
    border-bottom: 5px solid var(--primary-color);
    transition: background-color 0.3s ease, color 0.3s ease;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Dark Mode Hero - wird am Ende definiert */

/* 3 Ecken Design */
.corner-decoration {
    position: absolute;
    background: var(--primary-color);
    z-index: 0;
    opacity: 0.9;
}

.corner-1 {
    top: 0;
    left: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 0 200px 300px;
    border-color: transparent transparent var(--primary-color) transparent;
}

.corner-2 {
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 250px 180px 0;
    border-color: transparent var(--primary-color) transparent transparent;
}

.corner-3 {
    bottom: 0;
    left: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 150px 0 0 280px;
    border-color: transparent transparent transparent var(--primary-color);
}

.hero-content {
    position: relative;
    z-index: 1;
    margin: 0 auto;
    padding: 0;
    width: 100%;
    max-width: 1200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.hero-logo {
    margin-bottom: clamp(2rem, 4vw, 4rem);
    max-height: clamp(150px, 60vw, 800px);
    width: auto;
    height: auto;
    display: block;
    margin-left: auto;
    margin-right: auto;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.hero-title {
    color: var(--text-color);
    font-size: clamp(3rem, 12vw, 14rem);
    font-weight: 900;
    margin: 0 auto 0.3rem auto;
    padding: 0;
    animation: fadeInDown 1s ease-out;
    letter-spacing: clamp(1px, 0.3vw, 3px);
    text-transform: uppercase;
    line-height: 1.1;
    text-align: center;
    width: 100%;
    max-width: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    justify-items: center;
    align-items: baseline;
    gap: clamp(0.1em, 0.8vw, 0.35em);
    white-space: nowrap;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.hero-word {
    display: block;
}

.hero-word-left {
    justify-self: end;
    text-align: right;
}

.hero-word-right {
    justify-self: start;
    text-align: left;
}

.hero-x {
    color: var(--primary-color);
    font-size: 1.3em;
    font-weight: 900;
}

.hero-subtitle {
    font-size: clamp(1rem, 1.5vw, 1.2rem);
    margin-bottom: 0.5rem;
    margin-top: 0.2rem;
    color: var(--text-color);
    animation: fadeInUp 1s ease-out 0.3s both;
    text-align: center;
    width: 100%;
}

.hero-slogan {
    font-size: clamp(0.9rem, 1.3vw, 1.1rem);
    font-style: italic;
    margin-bottom: 1rem;
    margin-top: 0.5rem;
    color: var(--primary-color);
    animation: fadeInUp 1s ease-out 0.5s both;
    text-align: center;
    width: 100%;
    font-weight: 600;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeIn 1s ease-out 0.6s both;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 1rem 2rem;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    border: 2px solid var(--text-color);
    cursor: pointer;
    font-size: 1rem;
    background: transparent;
}

.btn-primary {
    background: transparent;
    color: var(--text-color);
    border: 2px solid var(--text-color);
}

.btn-primary:hover {
    background: transparent;
    color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background: transparent;
    color: var(--text-color);
    border: 2px solid var(--text-color);
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: transparent;
    color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

/* Section Styles */
section {
    padding: 5rem 0;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

/* Impressum Section */
.impressum {
    background: var(--bg-white);
}

.impressum-content {
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
}

.impressum-section {
    margin-bottom: 3rem;
}

.impressum-section h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.5rem;
}

.impressum-section h4 {
    font-size: 1.2rem;
    color: var(--text-color);
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    transition: color 0.3s ease;
}

.impressum-section p {
    color: var(--text-color);
    line-height: 1.8;
    margin-bottom: 1rem;
    transition: color 0.3s ease;
}

.impressum-section strong {
    color: var(--primary-color);
    font-weight: 600;
}

/* Services Section */
.services {
    background: var(--bg-white);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    background: var(--bg-white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s, background-color 0.3s ease, border-color 0.3s ease;
    border: 2px solid var(--primary-color);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary-dark);
    background: var(--bg-white);
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: inline-block;
    transition: transform 0.3s ease;
    position: relative;
}

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


.service-card p {
    color: var(--text-color);
    line-height: 1.8;
}

/* Service Icon Animations beim Hover */

/* Glühbirne - Leuchten (Elektro – Kleinmontagen) */
.service-card[data-service="elektro-kleinmontagen"]:hover .service-icon {
    animation: lightbulb-glow 0.8s ease-in-out infinite;
    filter: brightness(1.3) drop-shadow(0 0 15px rgba(255, 255, 0, 0.6));
}

@keyframes lightbulb-glow {
    0%, 100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
    50% {
        transform: scale(1.15) rotate(5deg);
        opacity: 0.9;
    }
}

/* Wasserhahn - Tropfen (Sanitär – Kleinreparaturen) */
.service-card[data-service="sanitaer-kleinreparaturen"]:hover .service-icon {
    animation: faucet-drip 0.6s ease-in-out infinite;
    position: relative;
}

.service-card[data-service="sanitaer-kleinreparaturen"]:hover .service-icon::after {
    content: '💧';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    animation: water-drip 0.6s ease-in-out infinite;
    font-size: 1.2rem;
    opacity: 0.8;
}

@keyframes faucet-drip {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-3px) rotate(3deg);
    }
}

@keyframes water-drip {
    0% {
        transform: translateX(-50%) translateY(0);
        opacity: 0.8;
    }
    100% {
        transform: translateX(-50%) translateY(25px);
        opacity: 0;
    }
}

/* Säge - Sägen (Zimmerei – Montagearbeiten) */
.service-card[data-service="zimmerei-montage"]:hover .service-icon {
    animation: saw-cut 0.7s ease-in-out infinite;
    transform-origin: center center;
}

@keyframes saw-cut {
    0%, 100% {
        transform: translateX(0) rotate(0deg);
    }
    25% {
        transform: translateX(10px) rotate(-10deg);
    }
    50% {
        transform: translateX(-10px) rotate(10deg);
    }
    75% {
        transform: translateX(5px) rotate(-5deg);
    }
}

/* Farbpalette - Pinselbewegung (Maler – Renovierung) */
.service-card[data-service="maler-renovierung"]:hover .service-icon {
    animation: paint-brush 0.9s ease-in-out infinite;
    transform-origin: center center;
}

@keyframes paint-brush {
    0%, 100% {
        transform: translateX(0) translateY(0) rotate(0deg);
    }
    25% {
        transform: translateX(12px) translateY(3px) rotate(-8deg);
    }
    50% {
        transform: translateX(-12px) translateY(3px) rotate(8deg);
    }
    75% {
        transform: translateX(6px) translateY(2px) rotate(-4deg);
    }
}

/* Werkzeugkasten - Öffnen/Schließen (Montage- & Helferservice) */
.service-card[data-service="montage-helfer"]:hover .service-icon {
    animation: toolbox-open 0.8s ease-in-out infinite;
    transform-origin: center center;
}

@keyframes toolbox-open {
    0%, 100% {
        transform: scale(1) rotate(0deg);
    }
    25% {
        transform: scale(1.1) rotate(-5deg);
    }
    50% {
        transform: scale(1.05) rotate(5deg);
    }
    75% {
        transform: scale(1.08) rotate(-3deg);
    }
}

/* About Section */
.about {
    background: var(--bg-white);
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
}

.about-description {
    font-size: 1.1rem;
    color: var(--text-color);
    margin-bottom: 2rem;
    text-align: center;
    transition: color 0.3s ease;
}

.about-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.feature {
    padding: 1.5rem;
    background: var(--bg-white);
    border-radius: 8px;
    border: 2px solid var(--primary-color);
    transition: background-color 0.3s ease;
}

.feature strong {
    display: block;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.feature p {
    color: var(--text-color);
}

/* Contact Section */
.contact {
    background: var(--bg-white);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-top: 3rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.contact-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.contact-details h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.contact-item {
    border-left: 3px solid var(--primary-color);
    padding-left: 1rem;
}

.contact-details p {
    color: var(--text-color);
}

/* Contact Form */
.contact-form {
    background: var(--bg-white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: var(--shadow);
    border: 2px solid var(--primary-color);
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-color);
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-family: inherit;
    font-size: 1rem;
    background: var(--bg-white);
    color: var(--text-color);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.form-group textarea {
    resize: vertical;
}

/* Form Message Styles */
.form-message {
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 5px;
    font-weight: 500;
    text-align: center;
    animation: fadeIn 0.3s ease;
}

.form-message-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.form-message-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.form-message:empty {
    /* display: none !important; */
}

/* Disabled Button State */
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

/* Theme Toggle Button */
.theme-toggle {
    border-radius: 50%;
    border: 2px solid var(--primary-color);
    background: var(--bg-white);
    color: var(--text-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1001;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    pointer-events: auto;
    -webkit-touch-callout: none;
    /* Größe wird durch Varianten wie .theme-toggle-nav festgelegt */
}

.theme-toggle-hero {
    position: fixed;
    top: 20px;
    right: 20px;
    width: clamp(60px, 8vw, 72px);
    height: clamp(60px, 8vw, 72px);
    min-width: clamp(60px, 8vw, 72px);
    min-height: clamp(60px, 8vw, 72px);
    font-size: clamp(1.6rem, 3vw, 2rem);
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.theme-toggle-hero:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-hover);
    background: var(--primary-color);
    color: var(--bg-white);
}

.theme-toggle-hero:active {
    transform: scale(0.96);
}

.theme-toggle--hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Theme Toggle Button in Navigation */
.theme-toggle-nav {
    position: absolute !important;
    top: 50% !important;
    right: 2rem !important;
    transform: translateY(-50%) !important;
    width: var(--logo-height) !important;
    height: var(--logo-height) !important;
    min-width: var(--logo-height) !important;
    min-height: var(--logo-height) !important;
    font-size: calc(var(--logo-height) * 0.45) !important;
    margin-left: 1rem !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.12) !important;
    display: flex !important;
}

.theme-toggle-nav:hover {
    transform: translateY(-50%) scale(1.05);
    box-shadow: var(--shadow-hover);
    background: var(--primary-color);
    color: var(--bg-white);
}

.theme-toggle-nav:active {
    transform: translateY(-50%) scale(0.96);
}

.header.sticky-active {
    --logo-height: 66px;
}

/* Footer */
.footer {
    background: #000000;
    color: white;
    padding: 3rem 0 1rem;
    border-top: 3px solid var(--primary-color);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

/* Footer h3 - WORKXPERT: Der gesamte Text ist rot */
.footer-section h3 {
    color: var(--primary-color) !important;
}

/* Footer X - Das X ist weiß */
.footer-x {
    color: #ffffff !important;
    font-size: 1.3em;
    font-weight: 900;
}

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

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

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 1400px) {
    .hero-title {
        font-size: clamp(5rem, 11vw, 12rem);
        margin: 0 auto 0.3rem auto;
        text-align: center;
    }
    
    .hero-logo {
        max-height: clamp(200px, 55vw, 700px);
        margin-bottom: clamp(2rem, 4vw, 4rem);
    }
}

@media (max-width: 1200px) {
    .hero-title {
        font-size: clamp(4rem, 10vw, 10rem);
        margin: 0 auto 0.3rem auto;
        text-align: center;
    }
    
    .hero-logo {
        max-height: clamp(180px, 50vw, 600px);
        margin-bottom: clamp(2rem, 4vw, 4rem);
    }
    
    .hero-content {
        margin: clamp(-4rem, -6vw, -5rem) auto 0 auto;
    }
}

@media (max-width: 1024px) {
    .hero-title {
        font-size: clamp(3.5rem, 8vw, 8rem);
        margin: 0 auto 0.3rem auto;
        text-align: center;
    }
    
    .hero-logo {
        max-height: clamp(160px, 45vw, 500px);
        margin-bottom: clamp(2rem, 4vw, 4rem);
    }
    
    .hero-content {
        margin: clamp(-3rem, -5vw, -4rem) auto 0 auto;
    }
}

@media (max-width: 900px) {
    .hero-title {
        font-size: clamp(3rem, 7vw, 6rem);
        margin: 0 auto 0.3rem auto;
        text-align: center;
    }
    
    .hero-logo {
        max-height: clamp(150px, 40vw, 400px);
        margin-bottom: clamp(1.5rem, 3vw, 3rem);
    }
    
    .hero-content {
        margin: clamp(-2rem, -4vw, -3rem) auto 0 auto;
    }
}

@media (max-width: 768px) {
    .theme-toggle-hero {
        top: 15px;
        right: 15px;
        width: clamp(50px, 14vw, 60px);
        height: clamp(50px, 14vw, 60px);
        min-width: clamp(50px, 14vw, 60px);
        min-height: clamp(50px, 14vw, 60px);
        font-size: clamp(1.4rem, 4vw, 1.8rem);
    }

    .header {
        --logo-height: 82px;
    }

    .header.sticky-active {
        --logo-height: 72px;
    }

    .theme-toggle-nav {
        right: 1rem !important;
        z-index: 1002;
    }
    
    .nav-container {
        position: relative;
        justify-content: space-between;
        padding-right: 4rem; /* Platz für Theme-Toggle Button */
    }
    
    .logo-link {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }
    
    /* Burger-Menü auf Mobile anzeigen */
    .menu-toggle {
        display: flex;
        z-index: 1003;
        order: -1;
    }
    
    /* Mobile Menü auf Mobile-Geräten anzeigen */
    .mobile-menu {
        display: block;
    }
    
    /* Desktop-Navigation auf Mobile verstecken */
    .nav-menu-left,
    .nav-menu-right {
        display: none !important;
    }
    
    /* Logo auf Mobile anpassen */
    .logo-link {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }
    
    
    .corner-1 {
        border-width: 0 0 120px 200px;
    }
    
    .corner-2 {
        border-width: 0 150px 120px 0;
    }
    
    .corner-3 {
        border-width: 100px 0 0 180px;
    }
    
    .hero-logo {
        max-height: 200px;
        margin-bottom: clamp(2rem, 4vw, 3rem);
    }
    
    .hero-content {
        margin: -2rem auto 0 auto;
    }
    
    .hero-title {
        font-size: 3rem;
        margin: 0 auto 0.3rem auto;
        text-align: center;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }
    
    .btn {
        width: 100%;
        text-align: center;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
    }
    
    .about-features {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .theme-toggle-hero {
        top: 12px;
        right: 12px;
        width: clamp(44px, 16vw, 52px);
        height: clamp(44px, 16vw, 52px);
        min-width: clamp(44px, 16vw, 52px);
        min-height: clamp(44px, 16vw, 52px);
        font-size: clamp(1.2rem, 5vw, 1.6rem);
    }

    .header {
        --logo-height: 72px;
    }

    .header.sticky-active {
        --logo-height: 62px;
    }

    .nav-container {
        padding: 0 1rem;
    }
    
    .menu-toggle {
        left: 1rem;
    }
    
    .theme-toggle-nav {
        right: 1rem !important;
    }
    
    .nav-container {
        padding-right: 3.5rem; /* Platz für Theme-Toggle Button auf kleinen Geräten */
    }
    
    .hero {
        padding: 2rem 1rem 4rem 1rem;
        min-height: auto;
    }
    
    .corner-1 {
        border-width: 0 0 100px 150px;
    }
    
    .corner-2 {
        border-width: 0 120px 100px 0;
    }
    
    .corner-3 {
        border-width: 80px 0 0 140px;
    }
    
    .hero-logo {
        max-height: 120px;
        margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
    }
    
    .hero-content {
        margin: -1rem auto 0 auto;
    }
    
    .hero-title {
        font-size: 1.75rem;
        margin: 0 auto 0.3rem auto;
        text-align: center;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-slogan {
        font-size: 0.85rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .container {
        padding: 0 1rem;
    }
}

/* ========================================
   DARK MODE - Konsolidierte Überschreibungen
   ======================================== */
html[data-theme="dark"] {
    --primary-color: #FF3333;
    --primary-dark: #CC0000;
    --secondary-color: #ffffff;
    --text-color: #ffffff;
    --text-light: #cccccc;
    --bg-light: #1a1a1a;
    --bg-white: #2d2d2d;
    --bg-dark: #1a1a1a;
    --border-color: #404040;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 8px 15px rgba(0, 0, 0, 0.4);
}

html[data-theme="dark"] body {
    background-color: #2d2d2d;
    color: #ffffff;
}

html[data-theme="dark"] .header,
html[data-theme="dark"] .hero,
html[data-theme="dark"] .services,
html[data-theme="dark"] .about,
html[data-theme="dark"] .contact,
html[data-theme="dark"] .impressum {
    background-color: #2d2d2d;
    color: #ffffff;
}

html[data-theme="dark"] .footer {
    background-color: #000000;
}

html[data-theme="dark"] p,
html[data-theme="dark"] h1,
html[data-theme="dark"] h2,
html[data-theme="dark"] h3,
html[data-theme="dark"] h4,
html[data-theme="dark"] li,
html[data-theme="dark"] span,
html[data-theme="dark"] div,
html[data-theme="dark"] .nav-menu a,
html[data-theme="dark"] .about-description,
html[data-theme="dark"] .hero-title,
html[data-theme="dark"] .hero-subtitle,
html[data-theme="dark"] .impressum-section h4,
html[data-theme="dark"] .impressum-section p,
html[data-theme="dark"] .contact-details p {
    color: #ffffff;
}

html[data-theme="dark"] .hero-x,
html[data-theme="dark"] .hero-slogan,
html[data-theme="dark"] .nav-menu a:hover,
html[data-theme="dark"] .nav-menu a.active,
html[data-theme="dark"] .footer-section h3,
html[data-theme="dark"] .impressum-section h3,
html[data-theme="dark"] .impressum-section strong {
    color: #FF3333;
}

html[data-theme="dark"] .nav-menu a.active::after {
    background-color: #FF3333;
}

html[data-theme="dark"] .footer-x {
    color: #ffffff;
}

html[data-theme="dark"] .service-card,
html[data-theme="dark"] .feature,
html[data-theme="dark"] .contact-form {
    background-color: #1a1a1a;
    color: #ffffff;
}

html[data-theme="dark"] .service-card p,
html[data-theme="dark"] .service-card h3,
html[data-theme="dark"] .feature p {
    color: #ffffff;
}

html[data-theme="dark"] .contact-form label,
html[data-theme="dark"] .contact-form input,
html[data-theme="dark"] .contact-form textarea {
    color: #ffffff;
    background-color: #2d2d2d;
    border-color: #404040;
}

html[data-theme="dark"] .section-subtitle {
    color: #cccccc;
}

html[data-theme="dark"] .form-message-success {
    background-color: #155724;
    color: #d4edda;
    border-color: #0f4015;
}

html[data-theme="dark"] .form-message-error {
    background-color: #721c24;
    color: #f8d7da;
    border-color: #5a1419;
}

html[data-theme="dark"] .impressum-section h3 {
    border-bottom-color: #FF3333;
}
