/* ===================================
   DEMAESTRO CORPORATE WEBSITE
   Advanced CSS with Dynamic Effects
   =================================== */

/* ===== BASE & RESETS ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --maestroDark: #0B1120;
    --maestroBlack: #020617;
    --maestroGold: #c29b40;
    --maestroGoldLight: #FCD34D;
    --maestroGray: #94a3b8;
    --transition-smooth: cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--maestroBlack);
    color: white;
    overflow-x: hidden;
    line-height: 1.6;
}

/* ===== UTILITY CLASSES ===== */
.font-serif { font-family: 'Playfair Display', serif; }
.text-maestroGold { color: var(--maestroGold); }
.bg-maestroDark { background-color: var(--maestroDark); }
.bg-maestroBlack { background-color: var(--maestroBlack); }

/* ===== ENHANCED ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

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

@keyframes spin-reverse {
    100% { transform: rotate(-360deg); }
}

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

@keyframes pulse-glow {
    0%, 100% { 
        box-shadow: 0 0 20px rgba(194, 155, 64, 0.3);
    }
    50% { 
        box-shadow: 0 0 40px rgba(194, 155, 64, 0.6);
    }
}

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

/* Scroll-triggered animations */
.animate-on-scroll {
    opacity: 0;
    transition: all 0.8s var(--transition-smooth);
}

.animate-on-scroll.animate-fade-in-up {
    animation: fadeInUp 0.8s var(--transition-smooth) forwards;
}

.animate-on-scroll.animate-fade-in-left {
    animation: fadeInLeft 0.8s var(--transition-smooth) forwards;
}

.animate-on-scroll.animate-fade-in-right {
    animation: fadeInRight 0.8s var(--transition-smooth) forwards;
}

.animate-on-scroll.animate-scale-in {
    animation: scaleIn 0.8s var(--transition-bounce) forwards;
}

/* Stagger delays for multiple items */
.animate-on-scroll:nth-child(1) { animation-delay: 0.1s; }
.animate-on-scroll:nth-child(2) { animation-delay: 0.2s; }
.animate-on-scroll:nth-child(3) { animation-delay: 0.3s; }
.animate-on-scroll:nth-child(4) { animation-delay: 0.4s; }

/* ===== NAVIGATION ===== */
.glass-nav {
    background: rgba(11, 17, 32, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: all 0.3s var(--transition-smooth);
}

.glass-nav.scrolled {
    background: rgba(11, 17, 32, 0.95);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* ===== GLASS CARDS ===== */
.glass-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.4s var(--transition-smooth);
}

.glass-card:hover {
    border-color: rgba(194, 155, 64, 0.4);
    background: rgba(255, 255, 255, 0.04);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* ===== ORBITAL SYSTEM ===== */
.orbit-system {
    position: relative;
    width: 380px;
    height: 380px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.orbit-core {
    position: absolute;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle at 30% 30%, var(--maestroGold), #785a15);
    border-radius: 50%;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 60px rgba(194, 155, 64, 0.4);
    animation: pulse-glow 3s ease-in-out infinite;
}

.ring {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.08);
    transform-style: preserve-3d;
}

.ring-1 {
    width: 200px;
    height: 200px;
    animation: spin 20s linear infinite;
    border-color: rgba(194, 155, 64, 0.2);
}

.ring-2 {
    width: 300px;
    height: 300px;
    animation: spin-reverse 30s linear infinite;
    border-color: rgba(194, 155, 64, 0.1);
}

.ring-3 {
    width: 380px;
    height: 380px;
    animation: spin 45s linear infinite;
    border-color: rgba(194, 155, 64, 0.05);
}

.planet {
    position: absolute;
    top: 50%;
    left: 50%;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 0 10px #fff;
}

.planet-1 {
    width: 8px;
    height: 8px;
    margin-left: -100px;
    margin-top: -4px;
}

.planet-2 {
    width: 6px;
    height: 6px;
    margin-left: 150px;
    margin-top: -3px;
    background: var(--maestroGold);
    box-shadow: 0 0 10px var(--maestroGold);
}

.planet-3 {
    width: 10px;
    height: 10px;
    margin-top: 190px;
    margin-left: -5px;
}

.orbit-label {
    position: absolute;
    padding: 4px 12px;
    background: rgba(0,0,0,0.7);
    border: 1px solid rgba(194, 155, 64, 0.3);
    border-radius: 20px;
    color: var(--maestroGold);
    font-size: 10px;
    font-weight: bold;
    letter-spacing: 1px;
    text-transform: uppercase;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.label-gov {
    top: 10%;
    right: 10%;
    animation: float 4s ease-in-out infinite;
}

.label-risk {
    bottom: 20%;
    left: 0%;
    animation: float 5s ease-in-out infinite 1s;
}

.label-comp {
    top: 40%;
    left: -10%;
    animation: float 6s ease-in-out infinite 2s;
}

/* ===== HERO SECTION ===== */
.hero-parallax {
    position: relative;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.15;
    transform: scale(1.1);
    transition: transform 0.1s ease-out;
}

/* ===== PARTICLE BACKGROUND ===== */
.particles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background: var(--maestroGold);
    border-radius: 50%;
    opacity: 0;
    animation: particleFloat 20s infinite;
}

@keyframes particleFloat {
    0% {
        opacity: 0;
        transform: translateY(100vh) translateX(0);
    }
    10% {
        opacity: 0.5;
    }
    90% {
        opacity: 0.5;
    }
    100% {
        opacity: 0;
        transform: translateY(-100vh) translateX(100px);
    }
}

/* ===== GRADIENT TEXT ===== */
.gradient-text {
    background: linear-gradient(135deg, var(--maestroGold) 0%, white 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 3s ease infinite;
}

/* ===== TEAM CARDS ===== */
.team-card {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    height: 400px;
    transition: transform 0.4s var(--transition-smooth);
}

.team-card:hover {
    transform: scale(1.05);
}

.team-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter 0.7s var(--transition-smooth);
}

.team-card:hover img {
    filter: grayscale(0%);
}

.team-card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, black, rgba(0,0,0,0.5) 50%, transparent);
    opacity: 0.9;
}

.team-card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 2rem;
    transform: translateY(4px);
    transition: transform 0.5s var(--transition-smooth);
}

.team-card:hover .team-card-content {
    transform: translateY(0);
}

.team-card-bio {
    opacity: 0;
    transition: opacity 0.5s var(--transition-smooth) 0.1s;
}

.team-card:hover .team-card-bio {
    opacity: 1;
}

/* ===== LOADING SPINNER ===== */
.lazy-loading {
    background: linear-gradient(90deg, 
        rgba(255,255,255,0.02) 25%, 
        rgba(255,255,255,0.05) 50%, 
        rgba(255,255,255,0.02) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ===== NOISE TEXTURE ===== */
.bg-noise {
    position: relative;
}

.bg-noise::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('data:image/svg+xml,%3Csvg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"%3E%3Cfilter id="noiseFilter"%3E%3CfeTurbulence type="fractalNoise" baseFrequency="0.65" numOctaves="3" stitchTiles="stitch"/%3E%3C/filter%3E%3Crect width="100%25" height="100%25" filter="url(%23noiseFilter)" opacity="0.05"/%3E%3C/svg%3E');
    opacity: 0.5;
    pointer-events: none;
    z-index: 1;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .orbit-system {
        width: 280px;
        height: 280px;
    }
    
    .ring-1 { width: 150px; height: 150px; }
    .ring-2 { width: 220px; height: 220px; }
    .ring-3 { width: 280px; height: 280px; }
    
    .orbit-core {
        width: 80px;
        height: 80px;
    }
}

/* ===== SCROLL INDICATOR ===== */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-10px);
    }
    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

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

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--maestroBlack);
}

::-webkit-scrollbar-thumb {
    background: var(--maestroGold);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--maestroGoldLight);
}

/* ===== PROGRESS BAR ===== */
.progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--maestroGold), var(--maestroGoldLight));
    z-index: 9999;
    transform-origin: left;
    transition: transform 0.1s ease-out;
}
