/* ========================================
   Rkk Enterprises — Custom Styles
   ======================================== */

/* Base & Smooth Scrolling */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Selection Color */
::selection {
    background-color: rgba(255, 107, 74, 0.2);
    color: #1e2127;
}

/* ========================================
   Floating Cards Animation
   ======================================== */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

@keyframes float-slow {
    0%, 100% { transform: translateY(0px) translateX(0px); }
    50% { transform: translateY(-6px) translateX(3px); }
}

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

.card-float:nth-child(2) {
    animation-delay: -3s;
    animation-duration: 7s;
}

.animate-float-slow {
    animation: float-slow 8s ease-in-out infinite;
}

/* ========================================
   Navbar Scroll State
   ======================================== */
.nav-scrolled {
    background: rgba(255, 255, 255, 0.92) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    box-shadow: 0 1px 40px rgba(0, 0, 0, 0.06), 0 4px 12px rgba(0, 0, 0, 0.04);
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.nav-transparent {
    background: transparent !important;
    box-shadow: none !important;
    border-bottom: none !important;
}

/* ========================================
   Nav Links
   ======================================== */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #ff8a6d, #f04e2b);
    border-radius: 1px;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 60%;
}

/* ========================================
   Feature Cards
   ======================================== */
.feature-card {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-card:hover {
    transform: translateY(-2px);
}

/* ========================================
   Scroll Reveal Animations
   (Progressive Enhancement — content visible without JS)
   ======================================== */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), 
                    transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Reduced motion: no animations */
@media (prefers-reduced-motion: reduce) {
    .card-float,
    .animate-float-slow {
        animation: none;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* ========================================
   Mobile Menu
   ======================================== */
.mobile-link {
    transition: all 0.2s ease;
}

#mobile-menu {
    animation: slideDown 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   Button Hover Effects
   ======================================== */
a {
    transition: all 0.2s ease;
}

/* ========================================
   Image Hover
   ======================================== */
img {
    transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ========================================
   Subtle Grain Overlay
   ======================================== */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.015;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 256px 256px;
}

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

::-webkit-scrollbar-track {
    background: #f5f5f4;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #ff8a6d, #f04e2b);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #ff6b4a, #d43a1c);
}

/* ========================================
   Focus States
   ======================================== */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #ff6b4a;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ========================================
   Responsive Adjustments
   ======================================== */
@media (max-width: 768px) {
    .card-float {
        animation: none;
    }
    
    .animate-float-slow {
        animation: none;
    }
}
