/* ============================================================
   APPLE TITANIUM LUXURY EFFECTS & INTERACTIVE ANIMATIONS SUITE
   ============================================================ */

/* 1. Hardware Accelerated Base & Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

*, *::before, *::after {
    -webkit-tap-highlight-color: transparent;
}

/* 2. Custom Sleek Apple Titanium Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: #0f1012;
}
::-webkit-scrollbar-thumb {
    background: #2c2d32;
    border-radius: 9999px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}
::-webkit-scrollbar-thumb:hover {
    background: #44454d;
}

/* 3. Floating Ambient Glow Orbs in Background */
.apple-ambient-layer {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.ambient-orb-1 {
    position: absolute;
    top: -80px;
    left: 15%;
    width: 420px;
    height: 420px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.12) 0%, rgba(245, 158, 11, 0.04) 50%, transparent 70%);
    filter: blur(55px);
    animation: orbFloat1 18s ease-in-out infinite alternate;
    will-change: transform;
}

.ambient-orb-2 {
    position: absolute;
    top: 40%;
    right: -100px;
    width: 380px;
    height: 380px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.09) 0%, rgba(180, 83, 9, 0.03) 60%, transparent 75%);
    filter: blur(60px);
    animation: orbFloat2 22s ease-in-out infinite alternate;
    will-change: transform;
}

@keyframes orbFloat1 {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(35px, 50px) scale(1.1); }
    100% { transform: translate(-25px, 90px) scale(0.95); }
}

@keyframes orbFloat2 {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(-40px, -35px) scale(1.12); }
    100% { transform: translate(-20px, 45px) scale(0.92); }
}

/* 4. Interactive Spotlight Glow Following Pointer */
.apple-pointer-spotlight {
    position: fixed;
    top: 0;
    left: 0;
    width: 420px;
    height: 420px;
    margin-top: -210px;
    margin-left: -210px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.07) 0%, rgba(245, 158, 11, 0.02) 45%, transparent 70%);
    pointer-events: none;
    z-index: 1;
    filter: blur(30px);
    opacity: 0;
    transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform, opacity;
}

body:hover .apple-pointer-spotlight {
    opacity: 1;
}

/* 5. Cascading Staggered Entrance Animations */
.cascade-item {
    opacity: 0;
    animation: appleCascadeIn 0.55s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes appleCascadeIn {
    from {
        opacity: 0;
        transform: translateY(14px) scale(0.99);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.cascade-delay-1 { animation-delay: 0.04s; }
.cascade-delay-2 { animation-delay: 0.08s; }
.cascade-delay-3 { animation-delay: 0.12s; }
.cascade-delay-4 { animation-delay: 0.16s; }
.cascade-delay-5 { animation-delay: 0.20s; }
.cascade-delay-6 { animation-delay: 0.24s; }

/* 6. Titanium Card & Row Elevation & Micro-Interactions */
.titanium-card {
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease !important;
}

.titanium-row {
    position: relative;
    overflow: hidden;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.titanium-row:hover {
    transform: translateY(-1.5px);
    border-color: rgba(251, 191, 36, 0.28) !important;
    box-shadow: 0 6px 20px -2px rgba(0, 0, 0, 0.5), 0 0 16px rgba(251, 191, 36, 0.08) !important;
}

.titanium-row:active {
    transform: scale(0.985);
    transition-duration: 0.08s !important;
}

/* App Icon Squircle Spring Hover */
.titanium-row .w-11.h-11 {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease !important;
}

.titanium-row:hover .w-11.h-11 {
    transform: scale(1.06);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5), 0 0 12px rgba(251, 191, 36, 0.2) !important;
}

/* 7. Action Button Apple Haptic Bounce */
button, .btn-apple-gold {
    transition: transform 0.16s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.2s ease, box-shadow 0.2s ease !important;
}

button:active, .btn-apple-gold:active {
    transform: scale(0.93) !important;
}

/* 8. Metallic Light Sweep (Gliding Sheen) */
.metallic-glow-sweep {
    position: relative;
    overflow: hidden;
}

.metallic-glow-sweep::after {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 80%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.03) 20%,
        rgba(251, 191, 36, 0.22) 50%,
        rgba(255, 255, 255, 0.03) 80%,
        transparent 100%
    );
    transform: skewX(-25deg);
    pointer-events: none;
    animation: metallicSweepGlider 5.5s infinite cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes metallicSweepGlider {
    0%, 30% {
        left: -150%;
    }
    60%, 100% {
        left: 200%;
    }
}

/* 9. Live Radar Pulse Beacon */
.radar-beacon {
    position: relative;
}

.radar-beacon::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: inherit;
    background: inherit;
    opacity: 0.7;
    animation: radarBeaconWave 2.4s infinite cubic-bezier(0.25, 1, 0.5, 1);
    pointer-events: none;
    z-index: -1;
}

@keyframes radarBeaconWave {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }
    70% {
        transform: scale(2.4);
        opacity: 0;
    }
    100% {
        transform: scale(2.4);
        opacity: 0;
    }
}

/* 10. Apple Waterdrop Touch Ripple */
.apple-click-ripple {
    position: absolute !important;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.35) 0%, rgba(255, 255, 255, 0.2) 30%, transparent 70%);
    pointer-events: none;
    transform: translate(-50%, -50%) scale(0);
    animation: appleRippleWave 0.55s ease-out forwards;
    z-index: 99;
}

@keyframes appleRippleWave {
    0% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 0.7;
    }
    100% {
        transform: translate(-50%, -50%) scale(3.5);
        opacity: 0;
    }
}

/* 11. Subtle Float Animation for Hero Avatar */
.avatar-floating {
    animation: appleFloatAvatar 4.5s ease-in-out infinite alternate;
}

@keyframes appleFloatAvatar {
    0% { transform: translateY(0); }
    100% { transform: translateY(-3px); }
}

/* 12. Reduced Motion Fallback */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
