/* 
====================================================================
BASE.CSS - GEMEINSAME GRUNDLAGEN FÜR ALLE SEITEN
====================================================================
*/

/* ===== CSS RESET & VARIABLES ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colors - Schwarz-Weiß Palette */
    --black: #000000;
    --white: #ffffff;
    --gray-50: #fafafa;
    --gray-100: #f5f5f5;
    --gray-200: #eeeeee;
    --gray-300: #e0e0e0;
    --gray-400: #bdbdbd;
    --gray-500: #9e9e9e;
    --gray-600: #757575;
    --gray-700: #616161;
    --gray-800: #424242;
    --gray-900: #212121;
    
    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    
    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;
    --space-4xl: 6rem;
    --space-5xl: 8rem;
    
    /* Effects */
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --shadow-glow: 0 0 30px rgba(255, 255, 255, 0.1);
    --shadow-magnetic: 0 25px 50px rgba(255, 255, 255, 0.15);
    --transition: all 0.3s ease;
    --transition-smooth: all 0.6s cubic-bezier(0.23, 1, 0.32, 1);
    --transition-bounce: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    
    /* Layout */
    --container-max: 1400px;
    --header-height: 80px;
}

/* ===== BASE STYLES ===== */
html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--white);
    background-color: var(--black);
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

/* ===== NAVIGATION ===== */
.navbar {
    position: fixed;
    top: var(--space-md);
    left: var(--space-2xl);
    right: var(--space-2xl);
    max-width: 1200px;
    margin: 0 auto;
    height: var(--header-height);
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(30px) saturate(150%);
    -webkit-backdrop-filter: blur(30px) saturate(150%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    z-index: 1000;
    transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.navbar.scrolled {
    background: rgba(0, 0, 0, 0.95);
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.navbar:hover {
    background: rgba(0, 0, 0, 0.9);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.nav-container {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--space-xl);
    position: relative;
    z-index: 1000;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--white);
    text-decoration: none;
    position: relative;
    z-index: 1001;
    background: rgba(0, 0, 0, 0.8);
    padding: var(--space-xs) var(--space-sm);
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.logo-img {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.nav-menu {
    display: flex;
    align-items: center;
    list-style: none;
    gap: var(--space-xl);
}

.nav-link {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    padding: var(--space-sm) var(--space-lg);
    border-radius: 12px;
    transition: var(--transition-smooth);
    position: relative;
    backdrop-filter: blur(10px);
}

.nav-link:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 16px rgba(255, 255, 255, 0.1);
    transform: translateY(-1px);
}

.nav-link.active {
    color: var(--white);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 
        0 4px 20px rgba(255, 255, 255, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: var(--space-sm);
    gap: 4px;
}

.hamburger span {
    width: 24px;
    height: 2px;
    background: var(--white);
    border-radius: 2px;
    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);
}

/* ===== PHONE BUTTON ===== */
.phone-sticky {
    position: fixed;
    bottom: var(--space-xl);
    right: var(--space-xl);
    z-index: 999;
}

.phone-btn {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-lg);
    background: var(--black);
    color: var(--white);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
}

.phone-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.phone-btn svg {
    width: 20px;
    height: 20px;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-xl);
    border: 1px solid transparent;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-primary {
    background: var(--white);
    color: var(--black);
    border-color: var(--white);
    position: relative;
    overflow: hidden;
    transition: var(--transition-smooth);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0,0,0,0.1), transparent);
    transition: left 0.5s;
}

.btn-primary:hover {
    background: var(--gray-200);
    transform: translateY(-3px) scale(1.02);
    box-shadow: var(--shadow-magnetic);
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-secondary {
    background: transparent;
    color: var(--white);
    border-color: var(--gray-600);
    position: relative;
    overflow: hidden;
    transition: var(--transition-smooth);
}

.btn-secondary::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: var(--white);
    transition: width 0.4s ease;
    z-index: -1;
}

.btn-secondary:hover {
    color: var(--black);
    border-color: var(--white);
    transform: translateY(-3px) scale(1.02);
    box-shadow: var(--shadow-glow);
}

.btn-secondary:hover::after {
    width: 100%;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--white);
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 900;
    letter-spacing: -0.02em;
    margin-bottom: var(--space-lg);
}

.page-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: var(--space-md);
}

.section-title {
    font-size: clamp(1.875rem, 4vw, 3rem);
    font-weight: 700;
    text-align: center;
    margin-bottom: var(--space-4xl);
}

/* ===== LAYOUT ===== */
.section {
    padding: var(--space-4xl) 0;
}

.section-sm {
    padding: var(--space-3xl) 0;
}

.section-lg {
    padding: var(--space-5xl) 0;
}

.hero-simple {
    padding: calc(var(--header-height) + var(--space-3xl)) 0 var(--space-3xl);
    text-align: center;
}

/* ===== CARDS ===== */
.card {
    background: var(--gray-900);
    border: 1px solid var(--gray-700);
    border-radius: 12px;
    padding: var(--space-xl);
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--white);
}

.card-featured {
    border: 2px solid var(--white);
    position: relative;
}

.card-featured::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--white);
    border-radius: 12px 12px 0 0;
}

/* ===== FOOTER ===== */
.footer {
    background: var(--gray-900);
    color: var(--white);
    padding: var(--space-4xl) 0 var(--space-xl);
    margin-top: var(--space-5xl);
    border-top: 1px solid var(--gray-800);
}

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

.footer-section h4 {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: var(--space-md);
    color: var(--white);
}

.footer-section p,
.footer-section li {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: var(--space-sm);
}

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

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

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

.footer-logo {
    width: 60px;
    height: 60px;
    margin-bottom: var(--space-md);
    object-fit: contain;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--space-lg);
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
}

/* ===== MODERN ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes magneticHover {
    0% { transform: translateY(0) scale(1); }
    100% { transform: translateY(-8px) scale(1.02); }
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

@keyframes ctaPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* ===== HARDWARE ACCELERATION ===== */
.gpu-optimized {
    will-change: transform, opacity;
    backface-visibility: hidden;
    perspective: 1000px;
    transform: translateZ(0);
}

/* ===== MAGNETIC HOVER SYSTEM ===== */
.magnetic-hover {
    position: relative;
    transition: var(--transition-smooth);
    transform-style: preserve-3d;
}

.magnetic-hover:hover {
    animation: magneticHover 0.6s cubic-bezier(0.23, 1, 0.32, 1);
    box-shadow: var(--shadow-magnetic);
    filter: drop-shadow(0 20px 40px rgba(255,255,255,0.15));
}

/* ===== SHIMMER EFFECT ===== */
.shimmer-effect {
    position: relative;
    overflow: hidden;
}

.shimmer-effect::before {
    content: '';
    position: absolute;
    top: 0;
    left: -200%;
    width: 200%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    animation: shimmer 2s infinite;
}

/* ===== SCROLL REVEAL ANIMATIONS ===== */
.scroll-reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

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

/* Performance optimizations */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
    will-change: transform, opacity;
}

.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Lazy loading images */
.lazy {
    opacity: 0;
    transition: opacity 0.3s;
}

.lazy.loaded {
    opacity: 1;
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    .scroll-reveal,
    .animate-on-scroll,
    .magnetic-hover,
    .shimmer-effect {
        animation: none;
        transition: none;
    }
}

/* ===== FLOATING CTA ===== */
.floating-cta {
    position: fixed;
    bottom: var(--space-xl);
    right: var(--space-xl);
    z-index: 999;
    backdrop-filter: blur(20px);
    animation: ctaPulse 3s infinite;
    transition: var(--transition-bounce);
}

.floating-cta:hover {
    transform: scale(1.1) translateY(-5px);
    animation: none;
}

/* ===== UTILITIES ===== */
.text-center { text-align: center; }
.text-muted { color: var(--gray-600); }
.mb-0 { margin-bottom: 0; }
.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .container {
        padding: 0 var(--space-md);
    }
}

@media (max-width: 768px) {
    :root {
        --space-4xl: 4rem;
        --space-5xl: 6rem;
    }
    
    .navbar {
        top: var(--space-sm);
        left: var(--space-md);
        right: var(--space-md);
        border-radius: 16px;
        margin: 0;
    }
    
    .nav-container {
        padding: 0 var(--space-md);
    }
    
    .hamburger {
        display: flex;
        padding: var(--space-xs);
        border-radius: 8px;
        transition: var(--transition);
    }
    
    .hamburger:hover {
        background: rgba(255, 255, 255, 0.1);
    }
    
    .nav-menu {
        position: fixed;
        top: calc(var(--header-height) + var(--space-lg));
        right: var(--space-md);
        height: auto;
        width: 280px;
        flex-direction: column;
        justify-content: flex-start;
        background: rgba(0, 0, 0, 0.9);
        backdrop-filter: blur(30px) saturate(150%);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 16px;
        padding: var(--space-lg);
        gap: var(--space-sm);
        transform: translateX(350px) scale(0.95);
        opacity: 0;
        transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
        box-shadow: 
            0 16px 48px rgba(0, 0, 0, 0.4),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
    }
    
    .nav-menu.active {
        transform: translateX(0) scale(1);
        opacity: 1;
    }
    
    .nav-link {
        font-size: 1rem;
        padding: var(--space-md) var(--space-lg);
        border-radius: 12px;
        width: 100%;
        text-align: center;
    }
    
    .phone-sticky {
        bottom: var(--space-md);
        right: var(--space-md);
    }
    
    .phone-btn span {
        display: none;
    }
}

@media (max-width: 480px) {
    :root {
        --space-3xl: 3rem;
        --space-4xl: 3rem;
        --space-5xl: 4rem;
    }
    
    .container {
        padding: 0 var(--space-sm);
    }
    
    .card {
        padding: var(--space-md);
    }
}