/* ============================================
   Modern CSS Reset & Variables
   ============================================ */
:root {
    --primary: #027af9;
    --primary-dark: #0259b8;
    --primary-light: #e8f4ff;
    --text-dark: #1a1a2e;
    --text-gray: #64748b;
    --text-light: #94a3b8;
    --bg-white: #ffffff;
    --bg-light: #f8fafc;
    --bg-dark: #1a1a2e;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
    font-size: 16px;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

/* ============================================
   Header & Navigation
   ============================================ */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: var(--transition);
}

header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--shadow-md);
}

nav {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 1.5rem;
}

.nav-logo img {
    height: 40px;
    width: auto;
    transition: var(--transition);
}

.nav-logo:hover img {
    transform: scale(1.05);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    color: var(--text-dark);
    font-weight: 500;
    padding: 0.5rem 0;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition);
}

.nav-link:hover {
    color: var(--primary);
}

.nav-link:hover::after {
    width: 100%;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 30px;
    height: 30px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.hamburger span {
    display: block;
    width: 100%;
    height: 3px;
    background: var(--text-dark);
    border-radius: 3px;
    transition: var(--transition);
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4rem;
    padding: 8rem 5% 4rem;
    background: linear-gradient(135deg, var(--bg-white) 0%, var(--primary-light) 100%);
}

.hero-content {
    flex: 1;
    max-width: 600px;
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    color: var(--text-gray);
    margin-bottom: 2rem;
    line-height: 1.7;
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-image img {
    max-width: 100%;
    max-height: 400px;
    width: auto;
    filter: drop-shadow(0 20px 40px rgba(2, 122, 249, 0.15));
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 14px rgba(2, 122, 249, 0.4);
}

.btn-primary:hover {
    background: var(--primary-dark);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(2, 122, 249, 0.5);
}

/* ============================================
   Sections General
   ============================================ */
section {
    padding: 6rem 5%;
}

.section-title {
    font-size: clamp(2rem, 4vw, 2.5rem);
    font-weight: 700;
    text-align: center;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.1rem;
    text-align: center;
    color: var(--text-gray);
    margin-bottom: 4rem;
}

/* ============================================
   Services Section
   ============================================ */
#dienstleistungen {
    background: var(--bg-white);
}

.service-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--bg-white);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    text-align: center;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-light);
}

.service-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: var(--primary-light);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.service-card:hover .service-icon {
    background: var(--primary);
    transform: scale(1.1);
}

.service-icon svg {
    width: 40px;
    height: 40px;
    color: var(--primary);
    transition: var(--transition);
}

.service-card:hover .service-icon svg {
    color: white;
}

.service-card h3 {
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.service-card p {
    color: var(--text-gray);
    line-height: 1.7;
}

/* ============================================
   Contact Section
   ============================================ */
#kontakt {
    background: var(--bg-light);
}

.contact-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.contact-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.contact-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.contact-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1.5rem;
    background: var(--primary-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-icon svg {
    width: 28px;
    height: 28px;
    color: var(--primary);
}

.contact-card h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.75rem;
}

.contact-card p {
    color: var(--text-gray);
    line-height: 1.8;
}

.contact-card a {
    color: var(--primary);
    font-weight: 500;
}

.contact-card a:hover {
    text-decoration: underline;
}

/* ============================================
   Footer
   ============================================ */
footer {
    background: var(--bg-dark);
    color: var(--text-light);
    padding: 2rem 5%;
    text-align: center;
}

footer p {
    font-size: 0.9rem;
}

/* ============================================
   Impressum Page
   ============================================ */
.impressum-content {
    max-width: 800px;
    margin: 100px auto 40px;
    padding: 3rem;
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.impressum-content h1 {
    font-size: 2rem;
    color: var(--text-dark);
    margin-bottom: 2rem;
    text-align: left;
}

.impressum-content h2 {
    font-size: 1.25rem;
    color: var(--text-dark);
    margin: 2rem 0 1rem;
    text-align: left;
}

.impressum-content p {
    color: var(--text-gray);
    margin-bottom: 1rem;
    line-height: 1.8;
}

/* ============================================
   Animations
   ============================================ */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDelay {
    0%, 20% {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.animate-fade-in {
    animation: fadeIn 0.8s ease-out forwards;
}

.animate-fade-in-delay {
    animation: fadeInDelay 1.2s ease-out forwards;
}

.animate-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.animate-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered animation for cards */
.service-card:nth-child(1) { transition-delay: 0.1s; }
.service-card:nth-child(2) { transition-delay: 0.2s; }
.service-card:nth-child(3) { transition-delay: 0.3s; }

/* ============================================
   Responsive Design
   ============================================ */

/* Tablet */
@media (max-width: 968px) {
    .hero {
        flex-direction: column;
        text-align: center;
        padding-top: 7rem;
        min-height: auto;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero-image {
        order: -1;
    }

    .hero-image img {
        max-height: 250px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background: var(--bg-white);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2rem;
        box-shadow: var(--shadow-xl);
        transition: right 0.3s ease-in-out;
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-link {
        font-size: 1.2rem;
    }

    section {
        padding: 4rem 5%;
    }

    .section-subtitle {
        margin-bottom: 2.5rem;
    }

    .service-container {
        grid-template-columns: 1fr;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }

    .impressum-content {
        margin: 80px 1rem 2rem;
        padding: 2rem;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .hero {
        padding: 6rem 1rem 3rem;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .btn {
        width: 100%;
        padding: 1rem 1.5rem;
    }

    .service-card,
    .contact-card {
        padding: 2rem 1.5rem;
    }
}
