/* ============================================
   404 Not Found Page - Auto Kale Ekspertiz
   Simplified & Animated Version
   ============================================ */

:root {
    --yellow: #FBD928;
    --dark: #343434;
    --light-dark: #6C6C6C;
    --gray: #f6f6f6;
    --text: #4b4b4d;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Exo", sans-serif;
    color: var(--text);
    overflow-x: hidden;
}

.notfound-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #1a1a1c 0%, #2d2d30 50%, #1a1a1c 100%);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ============================================
   Background Animation
   ============================================ */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.floating-shape {
    position: absolute;
    background: var(--yellow);
    opacity: 0.05;
    border-radius: 50%;
    animation: floatShape 20s ease-in-out infinite;
}

.shape-1 {
    width: 300px;
    height: 300px;
    top: -100px;
    left: -100px;
    animation-delay: 0s;
}

.shape-2 {
    width: 200px;
    height: 200px;
    top: 50%;
    right: -80px;
    animation-delay: 5s;
    animation-duration: 25s;
}

.shape-3 {
    width: 150px;
    height: 150px;
    bottom: -50px;
    left: 20%;
    animation-delay: 10s;
    animation-duration: 18s;
}

.shape-4 {
    width: 250px;
    height: 250px;
    bottom: 20%;
    right: 20%;
    animation-delay: 15s;
    animation-duration: 22s;
}

@keyframes floatShape {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg) scale(1);
    }

    25% {
        transform: translate(30px, -30px) rotate(90deg) scale(1.1);
    }

    50% {
        transform: translate(-20px, 40px) rotate(180deg) scale(0.9);
    }

    75% {
        transform: translate(40px, 20px) rotate(270deg) scale(1.05);
    }
}

/* ============================================
   Main Container
   ============================================ */
.notfound-container {
    position: relative;
    z-index: 1;
    max-width: 600px;
    margin: 0 auto;
    padding: 40px 20px;
    text-align: center;
}

/* ============================================
   Logo Section
   ============================================ */
.logo-section {
    margin-bottom: 40px;
}

    .logo-section a {
        display: inline-block;
    }

.logo {
    height: 50px;
    width: auto;
    filter: brightness(0) invert(1);
    transition: all 0.3s ease;
}

    .logo:hover {
        filter: brightness(0) invert(1) drop-shadow(0 0 10px rgba(251, 217, 40, 0.5));
    }

/* ============================================
   Error Scene - 404 Animation
   ============================================ */
.error-scene {
    position: relative;
    margin-bottom: 40px;
    padding: 20px 0;
}

/* 404 Display */
.error-display {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 30px;
}

.digit {
    font-size: clamp(6rem, 20vw, 10rem);
    font-weight: 900;
    color: var(--yellow);
    line-height: 1;
    text-shadow: 0 0 20px rgba(251, 217, 40, 0.5), 0 0 40px rgba(251, 217, 40, 0.3), 0 0 60px rgba(251, 217, 40, 0.1);
    animation: digitPulse 2s ease-in-out infinite;
}

    .digit:first-child {
        animation-delay: 0s;
    }

    .digit:last-child {
        animation-delay: 0.3s;
    }

@keyframes digitPulse {
    0%, 100% {
        transform: translateY(0) scale(1);
        text-shadow: 0 0 20px rgba(251, 217, 40, 0.5), 0 0 40px rgba(251, 217, 40, 0.3);
    }

    50% {
        transform: translateY(-10px) scale(1.05);
        text-shadow: 0 0 30px rgba(251, 217, 40, 0.7), 0 0 60px rgba(251, 217, 40, 0.5);
    }
}

/* Wheel (replacing 0) */
.wheel-container {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wheel {
    width: clamp(80px, 18vw, 120px);
    height: clamp(80px, 18vw, 120px);
    background: linear-gradient(145deg, #3a3a3a 0%, #1a1a1a 100%);
    border-radius: 50%;
    border: 8px solid var(--dark);
    position: relative;
    animation: wheelSpin 2s linear infinite;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5), inset 0 0 20px rgba(0, 0, 0, 0.3);
}

.wheel-inner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40%;
    height: 40%;
    background: linear-gradient(145deg, #555 0%, #333 100%);
    border-radius: 50%;
    border: 4px solid var(--yellow);
}

    .wheel-inner::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 30%;
        height: 30%;
        background: var(--yellow);
        border-radius: 50%;
    }

.wheel-spoke {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 80%;
    height: 4px;
    background: #555;
    transform-origin: center;
}

    .wheel-spoke:nth-child(2) {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    .wheel-spoke:nth-child(3) {
        transform: translate(-50%, -50%) rotate(90deg);
    }

@keyframes wheelSpin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Broken Road */
.broken-road {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 20px;
}

.road-piece {
    width: 120px;
    height: 20px;
    background: linear-gradient(180deg, #555 0%, #3a3a3a 100%);
    position: relative;
}

    .road-piece::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 0;
        right: 0;
        height: 4px;
        background: var(--yellow);
        transform: translateY(-50%);
    }

    .road-piece.left {
        border-radius: 10px 0 0 10px;
        transform: translateY(0) rotate(-3deg);
        animation: roadShakeLeft 3s ease-in-out infinite;
    }

    .road-piece.right {
        border-radius: 0 10px 10px 0;
        transform: translateY(0) rotate(3deg);
        animation: roadShakeRight 3s ease-in-out infinite;
    }

@keyframes roadShakeLeft {
    0%, 100% {
        transform: translateY(0) rotate(-3deg);
    }

    50% {
        transform: translateY(-5px) rotate(-5deg);
    }
}

@keyframes roadShakeRight {
    0%, 100% {
        transform: translateY(0) rotate(3deg);
    }

    50% {
        transform: translateY(5px) rotate(5deg);
    }
}

.road-gap {
    width: 40px;
    height: 30px;
    position: relative;
}

.gap-crack {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 30px;
    height: 50px;
    background: repeating-linear-gradient( 180deg, transparent 0px, transparent 5px, rgba(251, 217, 40, 0.3) 5px, rgba(251, 217, 40, 0.3) 10px );
    animation: crackGlow 1.5s ease-in-out infinite;
}

@keyframes crackGlow {
    0%, 100% {
        opacity: 0.5;
    }

    50% {
        opacity: 1;
    }
}

/* Warning Cones */
.warning-cones {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 10px;
}

.cone {
    width: 0;
    height: 0;
    border-left: 12px solid transparent;
    border-right: 12px solid transparent;
    border-bottom: 30px solid #ff6b35;
    position: relative;
    animation: coneBounce 2s ease-in-out infinite;
}

    .cone::before {
        content: '';
        position: absolute;
        top: 10px;
        left: -8px;
        width: 16px;
        height: 6px;
        background: #fff;
        border-radius: 2px;
    }

    .cone::after {
        content: '';
        position: absolute;
        bottom: -35px;
        left: -15px;
        width: 30px;
        height: 8px;
        background: #ff6b35;
        border-radius: 3px;
    }

.cone-1 {
    animation-delay: 0s;
}

.cone-2 {
    animation-delay: 0.3s;
}

.cone-3 {
    animation-delay: 0.6s;
}

@keyframes coneBounce {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

/* Dust Particles */
.dust-particles {
    position: absolute;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
}

.dust {
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(251, 217, 40, 0.6);
    border-radius: 50%;
    animation: dustFloat 2s ease-out infinite;
}

.d1 {
    left: -60px;
    animation-delay: 0s;
}

.d2 {
    left: -20px;
    animation-delay: 0.5s;
}

.d3 {
    left: 20px;
    animation-delay: 1s;
}

.d4 {
    left: 60px;
    animation-delay: 1.5s;
}

@keyframes dustFloat {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }

    100% {
        opacity: 0;
        transform: translateY(-50px) scale(0.3);
    }
}

/* ============================================
   Message Section
   ============================================ */
.notfound-message {
    margin-bottom: 40px;
}

    .notfound-message h1 {
        font-size: clamp(1.4rem, 4vw, 2rem);
        font-weight: 800;
        color: #fff;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        margin-bottom: 15px;
        text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    }

    .notfound-message p {
        font-size: 1rem;
        color: #aaa;
        line-height: 1.7;
        max-width: 400px;
        margin: 0 auto;
    }

/* ============================================
   Home Button
   ============================================ */
.notfound-action {
    margin-bottom: 50px;
}

.btn-home {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 18px 40px;
    background: var(--yellow);
    color: var(--dark);
    border: 3px solid var(--dark);
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: all 0.3s ease;
    box-shadow: 0 8px 0 var(--dark);
}

    .btn-home:hover {
        transform: translateY(-4px);
        box-shadow: 0 12px 0 var(--dark);
    }

    .btn-home:active {
        transform: translateY(2px);
        box-shadow: 0 4px 0 var(--dark);
    }

    .btn-home i {
        font-size: 1.3rem;
        transition: transform 0.3s ease;
    }

    .btn-home:hover i {
        transform: scale(1.2);
    }

/* ============================================
   Footer
   ============================================ */
.notfound-footer {
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

    .notfound-footer p {
        font-size: 0.85rem;
        color: #555;
    }

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 768px) {
    .notfound-container {
        padding: 30px 15px;
    }

    .wheel {
        border-width: 6px;
    }

    .road-piece {
        width: 80px;
        height: 15px;
    }

    .warning-cones {
        gap: 20px;
    }

    .cone {
        border-left-width: 10px;
        border-right-width: 10px;
        border-bottom-width: 25px;
    }
}

@media (max-width: 480px) {
    .error-display {
        gap: 5px;
    }

    .road-piece {
        width: 60px;
        height: 12px;
    }

    .road-gap {
        width: 25px;
    }

    .btn-home {
        padding: 15px 30px;
        font-size: 0.9rem;
    }
}

/* ============================================
   Animation States (for JS)
   ============================================ */
.fade-in {
    animation: fadeIn 0.6s ease-out forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}
