/* ============================================
   BURGUT MİMARLIK - ANIMATIONS
   Scroll Reveal & Interactive Effects
   ============================================ */

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

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

.reveal--left {
    transform: translateX(-60px);
}

.reveal--left.active {
    transform: translateX(0);
}

.reveal--right {
    transform: translateX(60px);
}

.reveal--right.active {
    transform: translateX(0);
}

.reveal--scale {
    transform: scale(0.9);
}

.reveal--scale.active {
    transform: scale(1);
}

/* Delayed Reveals */
.reveal--delay-1 {
    transition-delay: 0.1s;
}

.reveal--delay-2 {
    transition-delay: 0.2s;
}

.reveal--delay-3 {
    transition-delay: 0.3s;
}

.reveal--delay-4 {
    transition-delay: 0.4s;
}

.reveal--delay-5 {
    transition-delay: 0.5s;
}

/* ===== TEXT ANIMATIONS ===== */
.split-text {
    overflow: hidden;
}

.split-text span {
    display: inline-block;
    transform: translateY(100%);
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.split-text.active span {
    transform: translateY(0);
}

/* Staggered text animation */
.stagger-text span:nth-child(1) {
    transition-delay: 0.05s;
}

.stagger-text span:nth-child(2) {
    transition-delay: 0.1s;
}

.stagger-text span:nth-child(3) {
    transition-delay: 0.15s;
}

.stagger-text span:nth-child(4) {
    transition-delay: 0.2s;
}

.stagger-text span:nth-child(5) {
    transition-delay: 0.25s;
}

.stagger-text span:nth-child(6) {
    transition-delay: 0.3s;
}

.stagger-text span:nth-child(7) {
    transition-delay: 0.35s;
}

.stagger-text span:nth-child(8) {
    transition-delay: 0.4s;
}

.stagger-text span:nth-child(9) {
    transition-delay: 0.45s;
}

.stagger-text span:nth-child(10) {
    transition-delay: 0.5s;
}

/* ===== COUNTER ANIMATION ===== */
.counter {
    font-variant-numeric: tabular-nums;
}

/* ===== PARALLAX EFFECT ===== */
.parallax {
    will-change: transform;
}

/* ===== MAGNETIC BUTTON EFFECT ===== */
.magnetic {
    position: relative;
    cursor: pointer;
}

.magnetic-inner {
    position: relative;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== HOVER EFFECTS ===== */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.hover-glow {
    transition: box-shadow 0.3s ease;
}

.hover-glow:hover {
    box-shadow: 0 0 30px rgba(97, 144, 180, 0.4);
}

/* ===== IMAGE REVEAL ===== */
.image-reveal {
    position: relative;
    overflow: hidden;
}

.image-reveal::after {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--color-deep-blue);
    transform: scaleX(1);
    transform-origin: right;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.image-reveal.active::after {
    transform: scaleX(0);
}

.image-reveal img {
    transform: scale(1.2);
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.2s;
}

.image-reveal.active img {
    transform: scale(1);
}

/* ===== LOADING ANIMATION ===== */
.page-loader {
    position: fixed;
    inset: 0;
    background: var(--color-white);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.page-loader--hidden {
    opacity: 0;
    visibility: hidden;
}

.loader {
    width: 60px;
    height: 60px;
    position: relative;
}

.loader::before,
.loader::after {
    content: '';
    position: absolute;
    inset: 0;
    border: 3px solid transparent;
    border-top-color: var(--color-deep-blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loader::after {
    inset: 8px;
    border-top-color: var(--color-sky);
    animation-direction: reverse;
    animation-duration: 0.5s;
}

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

/* ===== CURSOR EFFECTS ===== */
.cursor {
    width: 20px;
    height: 20px;
    border: 2px solid var(--color-deep-blue);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9998;
    transition: transform 0.15s ease, width 0.3s ease, height 0.3s ease, background 0.3s ease;
    transform: translate(-50%, -50%);
}

.cursor--hover {
    width: 50px;
    height: 50px;
    background: rgba(97, 144, 180, 0.1);
    border-color: var(--color-sky);
}

.cursor-dot {
    width: 6px;
    height: 6px;
    background: var(--color-deep-blue);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
}

/* ===== MENU ANIMATION ===== */
.nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(44, 45, 44, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 450;
}

.nav-overlay--visible {
    opacity: 1;
    visibility: visible;
}

/* ===== SCROLL PROGRESS ===== */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--gradient-primary);
    z-index: 9999;
    transition: width 0.1s linear;
}

/* ===== FLOATING ELEMENTS ===== */
.float {
    animation: float 6s ease-in-out infinite;
}

.float--delay-1 {
    animation-delay: 0s;
}

.float--delay-2 {
    animation-delay: 2s;
}

.float--delay-3 {
    animation-delay: 4s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }
}

/* ===== PULSE ANIMATION ===== */
.pulse {
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.7;
        transform: scale(1.05);
    }
}

/* ===== RIPPLE EFFECT ===== */
.ripple {
    position: relative;
    overflow: hidden;
}

.ripple-effect {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: scale(0);
    animation: ripple 0.6s linear;
    pointer-events: none;
}

@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* ===== MARQUEE ===== */
.marquee {
    overflow: hidden;
    white-space: nowrap;
}

.marquee__content {
    display: inline-flex;
    animation: marquee 30s linear infinite;
}

.marquee__content span {
    padding: 0 2rem;
}

@keyframes marquee {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* ===== PAGE TRANSITION ===== */
.page-transition {
    position: fixed;
    inset: 0;
    background: var(--color-deep-blue);
    z-index: 9999;
    transform: scaleY(0);
    transform-origin: bottom;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.page-transition--active {
    transform: scaleY(1);
}

/* ===== GLITCH EFFECT ===== */
.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 var(--color-sky);
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim 5s infinite linear alternate-reverse;
}

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

@keyframes glitch-anim {
    0% {
        clip: rect(10px, 9999px, 31px, 0);
    }

    5% {
        clip: rect(70px, 9999px, 71px, 0);
    }

    10% {
        clip: rect(29px, 9999px, 83px, 0);
    }

    15% {
        clip: rect(99px, 9999px, 16px, 0);
    }

    20% {
        clip: rect(16px, 9999px, 91px, 0);
    }

    25% {
        clip: rect(0px, 9999px, 75px, 0);
    }

    30% {
        clip: rect(75px, 9999px, 44px, 0);
    }

    35% {
        clip: rect(47px, 9999px, 88px, 0);
    }

    40% {
        clip: rect(53px, 9999px, 97px, 0);
    }

    45% {
        clip: rect(31px, 9999px, 19px, 0);
    }

    50% {
        clip: rect(27px, 9999px, 7px, 0);
    }

    55% {
        clip: rect(63px, 9999px, 81px, 0);
    }

    60% {
        clip: rect(94px, 9999px, 53px, 0);
    }

    65% {
        clip: rect(42px, 9999px, 25px, 0);
    }

    70% {
        clip: rect(88px, 9999px, 67px, 0);
    }

    75% {
        clip: rect(4px, 9999px, 97px, 0);
    }

    80% {
        clip: rect(56px, 9999px, 34px, 0);
    }

    85% {
        clip: rect(12px, 9999px, 78px, 0);
    }

    90% {
        clip: rect(91px, 9999px, 46px, 0);
    }

    95% {
        clip: rect(38px, 9999px, 59px, 0);
    }

    100% {
        clip: rect(67px, 9999px, 23px, 0);
    }
}

@keyframes glitch-anim2 {
    0% {
        clip: rect(65px, 9999px, 99px, 0);
    }

    5% {
        clip: rect(16px, 9999px, 41px, 0);
    }

    10% {
        clip: rect(79px, 9999px, 23px, 0);
    }

    15% {
        clip: rect(49px, 9999px, 56px, 0);
    }

    20% {
        clip: rect(26px, 9999px, 1px, 0);
    }

    25% {
        clip: rect(90px, 9999px, 45px, 0);
    }

    30% {
        clip: rect(25px, 9999px, 94px, 0);
    }

    35% {
        clip: rect(97px, 9999px, 8px, 0);
    }

    40% {
        clip: rect(3px, 9999px, 67px, 0);
    }

    45% {
        clip: rect(81px, 9999px, 32px, 0);
    }

    50% {
        clip: rect(77px, 9999px, 57px, 0);
    }

    55% {
        clip: rect(13px, 9999px, 31px, 0);
    }

    60% {
        clip: rect(44px, 9999px, 3px, 0);
    }

    65% {
        clip: rect(92px, 9999px, 18px, 0);
    }

    70% {
        clip: rect(28px, 9999px, 17px, 0);
    }

    75% {
        clip: rect(54px, 9999px, 47px, 0);
    }

    80% {
        clip: rect(6px, 9999px, 84px, 0);
    }

    85% {
        clip: rect(62px, 9999px, 39px, 0);
    }

    90% {
        clip: rect(41px, 9999px, 26px, 0);
    }

    95% {
        clip: rect(88px, 9999px, 72px, 0);
    }

    100% {
        clip: rect(15px, 9999px, 95px, 0);
    }
}

/* ===== REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {

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

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

    .parallax {
        transform: none !important;
    }
}