/* ===== ROOT VARIABLES ===== */
:root {
    --gold-400: #fbbf24;
    --gold-500: #f59e0b;
    --gold-600: #d97706;
    --cyan-400: #22d3ee;
    --cyan-500: #06b6d4;
    --dark-900: #0a0a0a;
    --dark-800: #0f172a;
    --dark-700: #1e293b;
}

/* ===== BASE STYLES ===== */
* { scroll-behavior: smooth; }

body {
    background: linear-gradient(135deg, var(--dark-900) 0%, var(--dark-800) 100%);
}

body.light-mode {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    color: #1e293b;
}

::selection {
    background: var(--gold-500);
    color: #000;
}

/* ===== LOADER ===== */
.loader {
    position: fixed;
    inset: 0;
    background: var(--dark-900);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s, visibility 0.5s;
}

.loader.hidden { opacity: 0; visibility: hidden; }

.loader-logo {
    font-family: 'Orbitron', sans-serif;
    font-size: 3rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--gold-400), var(--cyan-400));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: pulse 1.5s ease-in-out infinite;
}

.loader-bar {
    width: 200px;
    height: 3px;
    background: var(--dark-700);
    border-radius: 3px;
    margin-top: 1rem;
    overflow: hidden;
}

.loader-progress {
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--gold-400), var(--cyan-400));
    animation: loading 2s ease-out forwards;
}

@keyframes loading { to { width: 100%; } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }

/* ===== NAVIGATION ===== */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(10, 10, 10, 0.9);
    backdrop-filter: blur(20px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.light-mode #navbar.scrolled {
    background: rgba(248, 250, 252, 0.9);
}

.nav-link {
    position: relative;
    color: #9ca3af;
    font-weight: 500;
    padding: 0.5rem 0;
    transition: all 0.3s;
}

.nav-link:hover, .nav-link.active {
    color: var(--gold-400);
    text-shadow: 0 0 20px rgba(251, 191, 36, 0.5);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--gold-400), var(--cyan-400));
    transition: width 0.3s;
}

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

.nav-link-mobile {
    color: #9ca3af;
    font-weight: 500;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    transition: all 0.3s;
}

.nav-link-mobile:hover { color: var(--gold-400); padding-left: 1rem; }

.theme-toggle {
    background: rgba(255,255,255,0.1);
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s;
}

.theme-toggle:hover {
    background: var(--gold-500);
    transform: rotate(180deg);
}

/* ===== BUTTONS ===== */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
    color: #000;
    font-weight: 600;
    border-radius: 9999px;
    transition: all 0.3s;
    box-shadow: 0 0 20px rgba(251, 191, 36, 0.3);
}

.btn-primary:hover {
    transform: scale(1.05);
    box-shadow: 0 0 40px rgba(251, 191, 36, 0.6);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    background: transparent;
    color: var(--cyan-400);
    font-weight: 600;
    border: 2px solid var(--cyan-400);
    border-radius: 9999px;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: var(--cyan-500);
    color: #000;
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(6, 182, 212, 0.5);
}

/* ===== HERO ===== */
.particles {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.particles::before {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.1) 0%, transparent 70%);
    top: 10%;
    left: 10%;
    animation: float 8s ease-in-out infinite;
}

.particles::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.1) 0%, transparent 70%);
    bottom: 20%;
    right: 10%;
    animation: float 6s ease-in-out infinite reverse;
}

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

.animate-gradient {
    background-size: 200% 200%;
    animation: gradient 3s ease infinite;
}

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

/* ===== SECTIONS ===== */
.section-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--gold-400), var(--cyan-400));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin-bottom: 1rem;
}

@media (min-width: 768px) { .section-title { font-size: 3rem; } }

.section-subtitle {
    color: #9ca3af;
    font-size: 1.125rem;
}

.parallax-bg {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, rgba(251, 191, 36, 0.05) 0%, transparent 70%);
    pointer-events: none;
}

/* ===== ABOUT ===== */
.about-image-container {
    position: relative;
}

.about-image-container img {
    position: relative;
    z-index: 1;
}

.about-image-glow {
    position: absolute;
    inset: -20px;
    background: linear-gradient(135deg, var(--gold-400), var(--cyan-400));
    border-radius: 1.5rem;
    opacity: 0.2;
    filter: blur(30px);
    animation: pulse 3s ease-in-out infinite;
}

.team-card {
    background: linear-gradient(135deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 1rem;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.4s;
    backdrop-filter: blur(10px);
}

.team-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--gold-400);
    box-shadow: 0 20px 40px rgba(251, 191, 36, 0.2);
}

.team-image {
    width: 120px;
    height: 120px;
    margin: 0 auto;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid transparent;
    background: linear-gradient(var(--dark-800), var(--dark-800)) padding-box,
                linear-gradient(135deg, var(--gold-400), var(--cyan-400)) border-box;
    transition: all 0.3s;
}

.team-card:hover .team-image {
    transform: scale(1.1) rotate(5deg);
}

.team-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===== PORTFOLIO ===== */
.filter-btn {
    padding: 0.5rem 1.5rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 9999px;
    color: #9ca3af;
    font-weight: 500;
    transition: all 0.3s;
}

.filter-btn:hover, .filter-btn.active {
    background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
    border-color: var(--gold-500);
    color: #000;
    box-shadow: 0 0 20px rgba(251, 191, 36, 0.3);
}

.carousel-container {
    position: relative;
    overflow: hidden;
    border-radius: 1.5rem;
}

.carousel {
    display: flex;
    transition: transform 0.5s ease;
}

.carousel-slide {
    min-width: 100%;
}

.featured-app {
    position: relative;
    height: 400px;
    border-radius: 1.5rem;
    overflow: hidden;
}

.featured-app img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.7);
    color: var(--gold-400);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.5rem;
    transition: all 0.3s;
    z-index: 10;
}

.carousel-btn:hover {
    background: var(--gold-500);
    color: #000;
}

.carousel-btn.prev { left: 1rem; }
.carousel-btn.next { right: 1rem; }

.app-card {
    background: linear-gradient(135deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 1rem;
    overflow: hidden;
    transition: all 0.4s;
}

.app-card:hover {
    transform: translateY(-10px);
    border-color: var(--gold-400);
    box-shadow: 0 20px 40px rgba(251, 191, 36, 0.2);
}

.app-image {
    height: 200px;
    overflow: hidden;
}

.app-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.app-card:hover .app-image img {
    transform: scale(1.1);
}

.app-content {
    padding: 1.25rem;
}

.play-store-btn {
    padding: 0.25rem 1rem;
    background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
    color: #000;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 9999px;
    transition: all 0.3s;
}

.play-store-btn:hover {
    box-shadow: 0 0 15px rgba(251, 191, 36, 0.5);
}

/* ===== SERVICES ===== */
.services-bg {
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(ellipse at top left, rgba(251, 191, 36, 0.05) 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(6, 182, 212, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.service-card {
    background: linear-gradient(135deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 1rem;
    padding: 2rem;
    transition: all 0.4s;
    backdrop-filter: blur(10px);
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--gold-400);
    box-shadow: 0 20px 40px rgba(251, 191, 36, 0.15);
}

.service-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: #000;
    transition: all 0.3s;
}

.service-icon.cyan {
    background: linear-gradient(135deg, var(--cyan-400), var(--cyan-500));
}

.service-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 0 30px rgba(251, 191, 36, 0.5);
}

/* ===== CONTACT ===== */
.form-input {
    width: 100%;
    padding: 1rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 0.75rem;
    color: white;
    transition: all 0.3s;
}

.form-input:focus {
    outline: none;
    border-color: var(--gold-400);
    box-shadow: 0 0 20px rgba(251, 191, 36, 0.2);
}

.form-input::placeholder { color: #6b7280; }

.light-mode .form-input {
    background: rgba(0,0,0,0.05);
    color: #1e293b;
    border-color: rgba(0,0,0,0.1);
}

.map-container {
    border-radius: 1rem;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.1);
}

.contact-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
}

.social-link {
    width: 45px;
    height: 45px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    transition: all 0.3s;
}

.social-link:hover {
    background: var(--gold-500);
    border-color: var(--gold-500);
    color: #000;
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(251, 191, 36, 0.3);
}

/* ===== CHAT BUBBLE ===== */
.chat-bubble {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 50;
}

.chat-toggle {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
    box-shadow: 0 10px 30px rgba(251, 191, 36, 0.4);
    transition: all 0.3s;
    animation: bounce 2s ease-in-out infinite;
}

.chat-toggle:hover {
    transform: scale(1.1);
}

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

.chat-box {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 320px;
    background: var(--dark-800);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.chat-header {
    background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
    color: #000;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-body { padding: 1.5rem; min-height: 150px; }
.chat-input { padding: 1rem; border-top: 1px solid rgba(255,255,255,0.1); }

/* ===== LIGHT MODE ===== */
.light-mode {
    color: #1e293b;
}

.light-mode .section-subtitle,
.light-mode .nav-link,
.light-mode .text-gray-300,
.light-mode .text-gray-400 {
    color: #64748b;
}

.light-mode .team-card,
.light-mode .app-card,
.light-mode .service-card {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.1);
}

.light-mode .chat-box {
    background: #f8fafc;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .section-title { font-size: 2rem; }
    .featured-app { height: 300px; }
    .chat-box { width: 280px; right: -1rem; }
}
