/* =============================
   Moderne Animationen & Effekte
   ============================= */

/* 3D Hover Effekte */
.hover-3d {
    transition: transform 0.3s ease;
    transform-style: preserve-3d;
    perspective: 1000px;
}

.hover-3d:hover {
    transform: translateZ(20px) rotateX(5deg) rotateY(5deg);
}

/* Glitch Effekt */
.glitch {
    position: relative;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch::before {
    left: 2px;
    text-shadow: -2px 0 #ff0000;
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim 5s infinite linear alternate-reverse;
}

.glitch::after {
    left: -2px;
    text-shadow: -2px 0 #00ff00;
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim2 5s infinite linear alternate-reverse;
}

@keyframes glitch-anim {
    0% { clip: rect(31px, 9999px, 94px, 0); }
    5% { clip: rect(70px, 9999px, 71px, 0); }
    10% { clip: rect(29px, 9999px, 83px, 0); }
    15% { clip: rect(75px, 9999px, 91px, 0); }
    20% { clip: rect(67px, 9999px, 74px, 0); }
    25% { clip: rect(14px, 9999px, 82px, 0); }
    30% { clip: rect(1px, 9999px, 66px, 0); }
    35% { clip: rect(86px, 9999px, 30px, 0); }
    40% { clip: rect(23px, 9999px, 98px, 0); }
    45% { clip: rect(85px, 9999px, 72px, 0); }
    50% { clip: rect(71px, 9999px, 75px, 0); }
    55% { clip: rect(2px, 9999px, 48px, 0); }
    60% { clip: rect(30px, 9999px, 16px, 0); }
    65% { clip: rect(59px, 9999px, 50px, 0); }
    70% { clip: rect(41px, 9999px, 62px, 0); }
    75% { clip: rect(2px, 9999px, 82px, 0); }
    80% { clip: rect(47px, 9999px, 73px, 0); }
    85% { clip: rect(3px, 9999px, 27px, 0); }
    90% { clip: rect(26px, 9999px, 55px, 0); }
    95% { clip: rect(42px, 9999px, 97px, 0); }
    100% { clip: rect(38px, 9999px, 49px, 0); }
}

/* Neon Glow Effekt */
.neon {
    color: #fff;
    text-shadow: 0 0 5px #fff,
                 0 0 10px #fff,
                 0 0 20px #ff0000,
                 0 0 30px #ff0000,
                 0 0 40px #ff0000;
    animation: neon-pulse 1.5s ease-in-out infinite alternate;
}

@keyframes neon-pulse {
    from { text-shadow: 0 0 5px #fff,
                       0 0 10px #fff,
                       0 0 20px #ff0000,
                       0 0 30px #ff0000,
                       0 0 40px #ff0000; }
    to { text-shadow: 0 0 2px #fff,
                     0 0 5px #fff,
                     0 0 10px #ff0000,
                     0 0 20px #ff0000,
                     0 0 30px #ff0000; }
}

/* Morphing Button */
.morph-button {
    position: relative;
    padding: 1rem 2rem;
    background: linear-gradient(45deg, #ff0000, #ff3333);
    border: none;
    border-radius: 50px;
    color: white;
    font-weight: bold;
    overflow: hidden;
    transition: all 0.3s ease;
}

.morph-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #ff3333, #ff0000);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.morph-button:hover::before {
    opacity: 1;
}

.morph-button:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(255, 0, 0, 0.2);
}

/* Floating Animation */
.float {
    animation: floating 3s ease-in-out infinite;
}

@keyframes floating {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0px); }
}

/* Text Gradient Animation */
.gradient-text {
    background: linear-gradient(45deg, #ff0000, #ff3333, #ff0000);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient 3s linear infinite;
}

@keyframes gradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Card Hover Effects */
.card-hover {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

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

.card-hover:hover::before {
    left: 100%;
}

.card-hover:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(255, 0, 0, 0.2);
}

/* Scroll Reveal Animation */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

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

/* Parallax Effect */
.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* Loading Spinner */
.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid rgba(255, 0, 0, 0.3);
    border-radius: 50%;
    border-top-color: #ff0000;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Typing Effect */
.typing {
    border-right: 2px solid #ff0000;
    white-space: nowrap;
    overflow: hidden;
    animation: typing 3.5s steps(40, end),
               blink-caret 0.75s step-end infinite;
}

@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: #ff0000 }
}

/* Shake Animation */
.shake {
    animation: shake 0.82s cubic-bezier(.36,.07,.19,.97) both;
}

@keyframes shake {
    10%, 90% { transform: translate3d(-1px, 0, 0); }
    20%, 80% { transform: translate3d(2px, 0, 0); }
    30%, 50%, 70% { transform: translate3d(-4px, 0, 0); }
    40%, 60% { transform: translate3d(4px, 0, 0); }
}

/* Pulse Animation */
.pulse {
    animation: pulse 2s infinite;
}

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

/* Bounce Animation */
.bounce {
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-30px); }
    60% { transform: translateY(-15px); }
}

/* Rotate Animation */
.rotate {
    animation: rotate 2s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Fade In Up Animation */
.fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Slide In Animation */
.slide-in {
    opacity: 0;
    transform: translateX(-100px);
    transition: all 0.6s ease-out;
}

.slide-in.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Scale In Animation */
.scale-in {
    opacity: 0;
    transform: scale(0.9);
    transition: all 0.6s ease-out;
}

.scale-in.visible {
    opacity: 1;
    transform: scale(1);
}

/* Flip Animation */
.flip {
    perspective: 1000px;
    transform-style: preserve-3d;
    transition: transform 0.6s;
}

.flip:hover {
    transform: rotateY(180deg);
}

/* Gradient Border */
.gradient-border {
    position: relative;
    border-radius: 10px;
    padding: 3px;
    background: linear-gradient(45deg, #ff0000, #ff3333);
}

.gradient-border::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 10px;
    padding: 3px;
    background: linear-gradient(45deg, #ff0000, #ff3333);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
}

/* Text Shadow Animation */
.text-shadow {
    animation: text-shadow 1.5s ease-in-out infinite;
}

@keyframes text-shadow {
    0% { text-shadow: 0 0 0 rgba(255, 0, 0, 0); }
    50% { text-shadow: 0 0 20px rgba(255, 0, 0, 0.5); }
    100% { text-shadow: 0 0 0 rgba(255, 0, 0, 0); }
}

/* Blur Effect */
.blur {
    transition: filter 0.3s ease;
}

.blur:hover {
    filter: blur(5px);
}

/* Glass Effect */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
}

/* Shine Effect */
.shine {
    position: relative;
    overflow: hidden;
}

.shine::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to right,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(30deg);
    transition: 0.5s;
}

.shine:hover::after {
    left: 100%;
}

/* Ripple Effect */
.ripple {
    position: relative;
    overflow: hidden;
}

.ripple::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    background-image: radial-gradient(circle, #fff 10%, transparent 10.01%);
    background-repeat: no-repeat;
    background-position: 50%;
    transform: scale(10, 10);
    opacity: 0;
    transition: transform 0.5s, opacity 1s;
}

.ripple:active::after {
    transform: scale(0, 0);
    opacity: 0.3;
    transition: 0s;
}

/* Tilt Effect */
.tilt {
    transition: transform 0.3s ease;
    transform-style: preserve-3d;
    transform: perspective(1000px);
}

.tilt:hover {
    transform: perspective(1000px) rotateX(10deg) rotateY(10deg);
}

/* Magnetic Effect */
.magnetic {
    transition: transform 0.3s ease;
}

/* Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(to right, #ff0000, #ff3333);
    z-index: 9999;
    transition: width 0.1s ease;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #1a1a1a;
}

::-webkit-scrollbar-thumb {
    background: #ff0000;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #ff3333;
}

/* =============================
   Erweiterte Animationen & Effekte
   ============================= */

/* 1. Animierte, schwebende Kreise für den Hintergrund */
.floating-circles-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}
.floating-circle {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,0,0,0.12) 0%, rgba(255,0,0,0.04) 100%);
    animation: floatCircle 12s ease-in-out infinite alternate;
}
.floating-circle.circle1 { width: 180px; height: 180px; left: 10%; top: 20%; animation-delay: 0s; }
.floating-circle.circle2 { width: 120px; height: 120px; left: 70%; top: 10%; animation-delay: 2s; }
.floating-circle.circle3 { width: 220px; height: 220px; left: 50%; top: 60%; animation-delay: 4s; }
.floating-circle.circle4 { width: 90px; height: 90px; left: 80%; top: 70%; animation-delay: 6s; }
@keyframes floatCircle {
    0% { transform: translateY(0) scale(1) rotate(0deg); }
    50% { transform: translateY(-30px) scale(1.08) rotate(10deg); }
    100% { transform: translateY(0) scale(1) rotate(0deg); }
}

/* 2. Animiertes Grid für Technologien-Sektion */
.animated-grid-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    pointer-events: none;
    z-index: 0;
    opacity: 0.12;
    background-image: repeating-linear-gradient(90deg, #ff0000 0 1px, transparent 1px 40px),
                      repeating-linear-gradient(0deg, #ff0000 0 1px, transparent 1px 40px);
    animation: gridMove 20s linear infinite;
}
@keyframes gridMove {
    0% { background-position: 0 0, 0 0; }
    100% { background-position: 40px 40px, 40px 40px; }
}

/* 3. Shine-Effekt für Überschriften beim Hover */
.shine-hover {
    position: relative;
    overflow: hidden;
}
.shine-hover:hover::after {
    content: '';
    position: absolute;
    top: 0; left: -75%;
    width: 50%; height: 100%;
    background: linear-gradient(120deg, rgba(255,255,255,0.0) 0%, rgba(255,255,255,0.5) 50%, rgba(255,255,255,0.0) 100%);
    transform: skewX(-20deg);
    animation: shineMove 1.2s linear;
}
@keyframes shineMove {
    0% { left: -75%; }
    100% { left: 120%; }
}

/* 4. Floating-Animation für Icons */
.floating-icon {
    display: inline-block;
    animation: floatingIcon 3.5s ease-in-out infinite alternate;
}
@keyframes floatingIcon {
    0% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0); }
}

/* 5. Soft-Glow für Buttons beim Hover */
.btn.soft-glow:hover, .morph-button.soft-glow:hover {
    box-shadow: 0 0 16px 4px rgba(255,0,0,0.25), 0 2px 8px rgba(0,0,0,0.08);
    filter: brightness(1.08);
}

/* 6. Animated Border für Karten beim Hover */
.card-hover.animated-border:hover {
    box-shadow: 0 0 0 4px #ff0000, 0 10px 30px rgba(255,0,0,0.08);
    border: 2px solid #ff0000;
    transition: box-shadow 0.3s, border 0.3s;
}

/* 7. Animierte Gradients für Hero/CTA */
.animated-gradient-bg {
    background: linear-gradient(120deg, #ff0000, #ff3333, #0a0a0a, #ff0000);
    background-size: 400% 400%;
    animation: gradientBGmove 12s ease-in-out infinite;
}
@keyframes gradientBGmove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
} 