/* ==========================================================================
   ReederDevelopments — Futuristic Cyber-Studio Design System
   ========================================================================== */

:root {
    --bg-deep: #060913;
    --bg-surface: #0d1326;
    --accent-cyan: #00f2fe;
    --accent-blue: #2563eb;
    --accent-teal: #10b981;
    --accent-purple: #8b5cf6;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    background-color: var(--bg-deep);
}

body {
    background-color: var(--bg-deep);
    color: #f8fafc;
    font-family: 'Plus Jakarta Sans', sans-serif;
    overflow-x: hidden;
    position: relative;
}

/* Futuristic Cyber Grid & Scanline Overlay */
.cyber-grid-bg {
    background-size: 50px 50px;
    background-image: 
        linear-gradient(to right, rgba(14, 165, 233, 0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(14, 165, 233, 0.05) 1px, transparent 1px);
    mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 50%, transparent 100%);
    -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 50%, transparent 100%);
}

/* Custom Cursor Follower */
#cursor-glow {
    position: fixed;
    width: 420px;
    height: 420px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(14, 165, 233, 0.13) 0%, rgba(30, 107, 230, 0.05) 40%, transparent 70%);
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 1;
    transition: width 0.3s ease, height 0.3s ease, opacity 0.3s ease;
}

#cursor-dot {
    position: fixed;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #38bdf8;
    box-shadow: 0 0 12px #38bdf8, 0 0 24px #0ea5e9;
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 9999;
    transition: transform 0.12s ease-out;
}

/* Scroll Progress Bar */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #00f2fe, #3b82f6, #10b981, #8b5cf6);
    width: 0%;
    z-index: 9999;
    box-shadow: 0 0 12px rgba(0, 242, 254, 0.8);
}

/* Glassmorphism & Futuristic Cards */
.glass-card {
    background: rgba(13, 19, 38, 0.65);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
    overflow: hidden;
}

/* Spotlight Radial Hover Effect inside Cards */
.spotlight-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(
        600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
        rgba(56, 189, 248, 0.12),
        transparent 40%
    );
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
    z-index: 1;
}

.spotlight-card:hover::before {
    opacity: 1;
}

.spotlight-card::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: radial-gradient(
        400px circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
        rgba(56, 189, 248, 0.55),
        rgba(16, 185, 129, 0.2) 40%,
        transparent 70%
    );
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.spotlight-card:hover::after {
    opacity: 1;
}

/* 3D Tilt Transition */
.tilt-card {
    transform-style: preserve-3d;
    transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.3s ease, border-color 0.3s ease;
    will-change: transform;
}

.tilt-card:hover {
    box-shadow: 0 20px 50px -15px rgba(14, 165, 233, 0.28);
}

/* Animated Text Gradients */
.text-gradient {
    background: linear-gradient(135deg, #38bdf8 0%, #60a5fa 35%, #10b981 70%, #a855f7 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 6s ease infinite;
}

.text-gradient-cyber {
    background: linear-gradient(90deg, #00f2fe 0%, #4facfe 50%, #00f2fe 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 4s linear infinite;
}

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

/* Floating & Pulse Animations */
@keyframes floatSlow {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-12px) rotate(1deg); }
}

@keyframes floatReverse {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(10px); }
}

@keyframes pulseGlow {
    0%, 100% { opacity: 0.4; transform: scale(1); }
    50% { opacity: 0.8; transform: scale(1.06); }
}

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

@keyframes marqueeScroll {
    0% { transform: translateX(0%); }
    100% { transform: translateX(-50%); }
}

@keyframes scanlineMove {
    0% { top: -10%; }
    100% { top: 110%; }
}

.animate-float {
    animation: floatSlow 6s ease-in-out infinite;
}

.animate-float-delayed {
    animation: floatReverse 7s ease-in-out infinite 1.5s;
}

.animate-spin-slow {
    animation: spinSlow 18s linear infinite;
}

.animate-marquee {
    display: flex;
    width: max-content;
    animation: marqueeScroll 28s linear infinite;
}

.animate-marquee:hover {
    animation-play-state: paused;
}

/* Futuristic Scanline inside Terminal / Device */
.scanline {
    position: absolute;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(to bottom, transparent, rgba(56, 189, 248, 0.08), transparent);
    pointer-events: none;
    animation: scanlineMove 5s linear infinite;
}

/* Scroll Reveal States */
.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1), transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.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; }

/* Neon Button Glow */
.btn-cyber {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-cyber::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent);
    transition: left 0.5s ease;
}

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

.btn-cyber:hover {
    box-shadow: 0 0 25px rgba(14, 165, 233, 0.55), 0 0 50px rgba(16, 185, 129, 0.25);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #060913;
}
::-webkit-scrollbar-thumb {
    background: #1e293b;
    border-radius: 4px;
    border: 1px solid rgba(56, 189, 248, 0.2);
}
::-webkit-scrollbar-thumb:hover {
    background: #0ea5e9;
}

/* Code / Terminal Styling */
.code-font {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
}
