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

:root {
    /* Light Theme */
    --primary: #647cf7;
    --primary-light: #8ea1ff;
    --primary-dark: #3a56c4;
    --secondary: #16a085;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #3b82f6;
    
    /* Background Colors */
    --bg-primary: #0f172a;
    --bg-secondary: #1e233c;
    --bg-tertiary: #2a3049;
    
    /* Text Colors */
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    
    /* Border Colors */
    --border: #334155;
    --border-light: #475569;
    
    /* Effects */
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    --shadow-light: 0 5px 15px rgba(0, 0, 0, 0.2);
    --glow: 0 0 20px rgba(100, 124, 247, 0.3);
    
    /* Transitions */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-full: 50px;
    
    /* Animation Delays */
    --delay: 0s;
    --delay-1: 0.1s;
    --delay-2: 0.2s;
    --delay-3: 0.3s;
    --delay-4: 0.4s;
    --delay-5: 0.5s;
}

[data-theme="light"] {
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --text-primary: #1e293b;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --border: #e2e8f0;
    --border-light: #cbd5e1;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    --shadow-light: 0 5px 15px rgba(0, 0, 0, 0.05);
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    transition: var(--transition-slow);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    padding-bottom: 90px;
    min-height: 100vh;
}

/* ===== LOADING SCREEN SIMPLE & ELEGAN ===== */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 50%, #0f172a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    overflow: hidden;
}

.loading-bg-gradient {
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, rgba(100, 124, 247, 0.1) 0%, transparent 50%);
    animation: pulseBg 4s ease-in-out infinite;
}

@keyframes pulseBg {
    0%, 100% {
        opacity: 0.3;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(1.1);
    }
}

.loading-content {
    text-align: center;
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 400px;
}

/* Logo Container Simple */
.logo-container-simple {
    margin-bottom: 30px;
}

.logo-shape-morph {
    width: 120px;
    height: 120px;
    margin: 0 auto;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: morphShape 8s ease-in-out infinite;
}

.shape-inner {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

/* Loading Text Simple */
.loading-text-simple {
    font-family: 'Montserrat', sans-serif;
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 30px;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.loading-text-simple .byy {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.loading-text-simple .verse {
    color: var(--text-primary);
    font-weight: 300;
    margin-left: 5px;
}

/* Simple Progress Bar */
.simple-progress {
    width: 300px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin: 0 auto 20px;
    position: relative;
}

.simple-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: var(--radius-full);
    transition: width 0.3s ease;
    position: relative;
    overflow: hidden;
}

.simple-progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, 
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent);
    animation: shimmer 2s infinite;
}

/* Loading Status Simple */
.loading-status-simple {
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.loading-percentage {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary);
}

.loading-message {
    font-size: 0.85rem;
    color: var(--text-muted);
    height: 20px;
    transition: all 0.3s ease;
}

/* Geometric Particles */
.geometric-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.geometric-particle {
    position: absolute;
    background: rgba(100, 124, 247, 0.15);
    animation: floatParticle 6s infinite ease-in-out;
}

.geometric-particle.square {
    border-radius: 4px;
}

.geometric-particle.circle {
    border-radius: 50%;
}

.geometric-particle.triangle {
    background: transparent;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 14px solid rgba(100, 124, 247, 0.15);
}

.geometric-particle.diamond {
    transform: rotate(45deg);
    border-radius: 2px;
}

@keyframes floatParticle {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    33% {
        transform: translate(var(--tx, 10px), var(--ty, -15px)) rotate(90deg);
    }
    66% {
        transform: translate(var(--tx, -5px), var(--ty, 10px)) rotate(180deg);
    }
}

/* ===== TRADING CHART STYLES ===== */
.trading-chart {
    position: relative;
    height: 250px;
    width: 100%;
    overflow: hidden;
}

.chart-grid {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    grid-template-rows: repeat(5, 1fr);
    opacity: 0.15;
    pointer-events: none;
}

.grid-line {
    border-right: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.chart-path {
    fill: none;
    stroke: #647cf7;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    filter: drop-shadow(0 0 10px rgba(100, 124, 247, 0.3));
}

.chart-point {
    fill: white;
    stroke: #647cf7;
    stroke-width: 2;
    r: 5;
    transition: all 0.3s ease;
    cursor: pointer;
}

.chart-point:hover {
    r: 8;
    fill: #647cf7;
    filter: drop-shadow(0 0 8px rgba(100, 124, 247, 0.6));
}

@keyframes drawChart {
    from {
        stroke-dashoffset: 1000;
    }
    to {
        stroke-dashoffset: 0;
    }
}

/* ===== FOOTER SECTION STYLES ===== */
.footer-section {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid var(--border);
}

.footer-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.footer-logo {
    font-size: 1.8rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.footer-logo i {
    color: var(--primary);
}

.footer-tagline {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 25px;
    line-height: 1.6;
}

.footer-stats {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.footer-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.footer-stat i {
    font-size: 1.3rem;
    color: var(--primary);
    background: var(--bg-tertiary);
    width: 50px;
    height: 50px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.footer-stat span {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
    padding: 5px 10px;
    border-radius: var(--radius-sm);
}

.footer-links a:hover {
    color: var(--primary);
    background: var(--bg-tertiary);
}

.footer-copyright {
    font-size: 0.8rem;
    color: var(--text-muted);
    padding-top: 20px;
    border-top: 1px solid var(--border-light);
}

/* ===== MODERN NOTIFICATION SYSTEM - SIMPLE & CLEAN ===== */
#notificationContainer {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 350px;
    pointer-events: none;
}

.notification {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25),
                0 0 0 1px rgba(255, 255, 255, 0.05);
    pointer-events: all;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transform: translateX(100%);
    opacity: 0;
    animation: notificationSlideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    max-width: 100%;
    transition: all 0.3s ease;
}

.notification:hover {
    transform: translateX(0) scale(1.02);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3),
                0 0 0 1px rgba(255, 255, 255, 0.1);
}

.notification-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: white;
    flex-shrink: 0;
}

.notification.success .notification-icon {
    background: linear-gradient(135deg, #10b981, #34d399);
}

.notification.error .notification-icon {
    background: linear-gradient(135deg, #ef4444, #f87171);
}

.notification.warning .notification-icon {
    background: linear-gradient(135deg, #f59e0b, #fbbf24);
}

.notification.info .notification-icon {
    background: linear-gradient(135deg, #3b82f6, #60a5fa);
}

.notification-content {
    flex: 1;
    min-width: 0;
    padding-right: 8px;
}

.notification-message {
    font-size: 0.9rem;
    color: var(--text-primary);
    line-height: 1.4;
    font-weight: 500;
    margin-bottom: 2px;
}

.notification-subtext {
    font-size: 0.75rem;
    color: var(--text-secondary);
    opacity: 0.8;
}

.notification-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    flex-shrink: 0;
}

.notification-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.notification-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: rgba(255, 255, 255, 0.05);
    overflow: hidden;
}

.progress-bar-inner {
    height: 100%;
    width: 100%;
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.3),
        rgba(255, 255, 255, 0.6));
    transform-origin: left;
}

/* Notification animations */
@keyframes notificationSlideIn {
    0% {
        transform: translateX(100%);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes notificationSlideOut {
    0% {
        transform: translateX(0);
        opacity: 1;
    }
    100% {
        transform: translateX(100%);
        opacity: 0;
    }
}

@keyframes progressShrink {
    from {
        transform: scaleX(1);
    }
    to {
        transform: scaleX(0);
    }
}

/* Responsive notifications */
@media (max-width: 768px) {
    #notificationContainer {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
    
    .notification {
        padding: 14px;
    }
    
    .notification-icon {
        width: 32px;
        height: 32px;
        font-size: 0.9rem;
    }
    
    .notification-message {
        font-size: 0.85rem;
    }
}

/* ===== PWA INSTALL NOTIFICATION ===== */
.install-notification {
    position: fixed;
    bottom: 90px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-secondary);
    border: 2px solid var(--primary);
    border-radius: var(--radius-lg);
    padding: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    z-index: 9998;
    max-width: 400px;
    width: 90%;
    animation: slideInUp 0.3s ease;
    backdrop-filter: blur(10px);
    border-left: 4px solid var(--primary);
}

.install-content {
    display: flex;
    align-items: center;
    gap: 15px;
}

.install-content i {
    font-size: 1.5rem;
    color: var(--primary);
    background: rgba(100, 124, 247, 0.1);
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.install-content div {
    flex: 1;
}

.install-content strong {
    display: block;
    color: var(--text-primary);
    font-size: 0.95rem;
    margin-bottom: 2px;
    font-weight: 600;
}

.install-content small {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.install-btn {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.85rem;
    white-space: nowrap;
}

.install-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(100, 124, 247, 0.3);
}

.install-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 5px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
}

.install-close:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

/* ===== MAIN CONTENT ===== */
.main-content {
    position: relative;
}

.page {
    display: none;
    animation: fadeIn 0.4s ease;
}

.page.active {
    display: block;
    animation: slideInBottom 0.4s ease;
}

/* ===== HOME PAGE ===== */
.hero-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 50px;
    align-items: center;
    animation: fadeIn 0.8s ease;
}

.hero-content {
    padding-right: 20px;
}

.hero-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
    animation: fadeInUp 0.8s ease;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--primary-light), #f472b6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 30px;
    line-height: 1.6;
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-stats {
    display: flex;
    gap: 30px;
    margin-top: 30px;
}

.stat-item {
    text-align: center;
    animation: fadeInUp 0.8s ease;
}

.stat-item:nth-child(1) { animation-delay: 0.1s; }
.stat-item:nth-child(2) { animation-delay: 0.2s; }
.stat-item:nth-child(3) { animation-delay: 0.3s; }

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.hero-illustration {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.floating-element {
    width: 70px;
    height: 70px;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--primary);
    box-shadow: var(--shadow);
    animation: wave 4s ease-in-out infinite;
    transition: var(--transition);
}

.floating-element:nth-child(1) { animation-delay: 0s; }
.floating-element:nth-child(2) { 
    animation-delay: 0.2s;
    background: var(--primary);
    color: white;
}
.floating-element:nth-child(3) { animation-delay: 0.4s; }

.floating-element:hover {
    transform: scale(1.1);
    box-shadow: var(--glow);
}

/* ===== HOME PAGE NEW SECTIONS ===== */

/* Platform Statistics Section */
.platform-stats-section {
    margin-bottom: 50px;
    animation: fadeIn 0.8s ease 0.2s both;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 30px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Enhanced Text Animations */
.glitch-text-enhanced {
    position: relative;
    animation: glitchEnhanced 4s infinite;
    background: linear-gradient(135deg, #647cf7, #3b82f6, #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    background-size: 200% auto;
}

@keyframes glitchEnhanced {
    0% {
        transform: translate(0);
        background-position: 0% 50%;
        text-shadow: 0 0 10px rgba(100, 124, 247, 0.3);
    }
    2% {
        transform: translate(-1px, 1px);
    }
    4% {
        transform: translate(1px, -1px);
    }
    6% {
        transform: translate(-1px, 1px);
    }
    8% {
        transform: translate(0);
    }
    50% {
        background-position: 100% 50%;
        text-shadow: 0 0 20px rgba(100, 124, 247, 0.6),
                     0 0 30px rgba(139, 92, 246, 0.4);
    }
    100% {
        background-position: 0% 50%;
        text-shadow: 0 0 10px rgba(100, 124, 247, 0.3);
    }
}

.neon-wave-text-enhanced {
    background: linear-gradient(
        90deg,
        #647cf7,
        #3b82f6,
        #8b5cf6,
        #3b82f6,
        #647cf7
    );
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: neonWaveEnhanced 4s ease-in-out infinite;
    position: relative;
    font-weight: 700;
    letter-spacing: 0.5px;
}

@keyframes neonWaveEnhanced {
    0%, 100% {
        background-position: 0% 50%;
        text-shadow: 
            0 0 5px rgba(100, 124, 247, 0.3),
            0 0 10px rgba(100, 124, 247, 0.2);
    }
    25% {
        background-position: 50% 50%;
        text-shadow: 
            0 0 10px rgba(59, 130, 246, 0.4),
            0 0 20px rgba(59, 130, 246, 0.3);
    }
    50% {
        background-position: 100% 50%;
        text-shadow: 
            0 0 15px rgba(100, 124, 247, 0.5),
            0 0 25px rgba(139, 92, 246, 0.3);
    }
    75% {
        background-position: 150% 50%;
        text-shadow: 
            0 0 10px rgba(59, 130, 246, 0.4),
            0 0 20px rgba(59, 130, 246, 0.3);
    }
}

.stats-grid-enhanced {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.stat-card-enhanced {
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
    padding: 25px;
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
    transition: var(--transition);
    animation: fadeInUp 0.5s ease;
}

.stat-card-enhanced:nth-child(1) { animation-delay: 0.1s; }
.stat-card-enhanced:nth-child(2) { animation-delay: 0.2s; }
.stat-card-enhanced:nth-child(3) { animation-delay: 0.3s; }
.stat-card-enhanced:nth-child(4) { animation-delay: 0.4s; }

.stat-card-enhanced:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.stat-card-enhanced::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stat-card-enhanced:hover::before {
    opacity: 1;
}

.stat-icon {
    width: 60px;
    height: 60px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--primary);
    margin-bottom: 20px;
    position: relative;
}

.pulse-ring {
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border: 2px solid var(--primary);
    border-radius: var(--radius-lg);
    animation: pulseRing 2s ease-in-out infinite;
    opacity: 0;
}

.stat-content {
    margin-bottom: 20px;
}

.stat-value {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 5px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.stat-trend {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: var(--radius-full);
}

.stat-trend.up {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.stat-trend.down {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

.stat-trend.stable {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.stat-chart-mini {
    display: flex;
    align-items: flex-end;
    gap: 5px;
    height: 40px;
    margin-top: 15px;
}

.mini-chart-bar {
    flex: 1;
    background: linear-gradient(to top, var(--primary), var(--primary-light));
    border-radius: 3px 3px 0 0;
    animation: chartBarBounce 2s ease-in-out infinite;
}

.mini-chart-bar:nth-child(1) { animation-delay: 0s; }
.mini-chart-bar:nth-child(2) { animation-delay: 0.1s; }
.mini-chart-bar:nth-child(3) { animation-delay: 0.2s; }
.mini-chart-bar:nth-child(4) { animation-delay: 0.3s; }
.mini-chart-bar:nth-child(5) { animation-delay: 0.4s; }

@keyframes chartBarBounce {
    0%, 100% {
        height: 60%;
    }
    50% {
        height: 80%;
    }
}

/* Enhanced Chart Section */
.chart-section-enhanced {
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
    padding: 30px;
    margin-bottom: 40px;
    border: 1px solid var(--border);
}

.chart-header-enhanced {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.chart-header-enhanced h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

.chart-controls {
    display: flex;
    gap: 10px;
}

.chart-period-btn {
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.chart-period-btn:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.chart-period-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.chart-container-enhanced {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
}

@media (max-width: 1024px) {
    .chart-container-enhanced {
        grid-template-columns: 1fr;
    }
}

.chart-canvas {
    height: 250px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-lg);
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.chart-legend {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.legend-item:hover {
    transform: translateX(5px);
    background: var(--bg-secondary);
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

.legend-item span:not(.legend-color) {
    flex: 1;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.legend-value {
    font-weight: 700;
    color: var(--primary);
}

/* Performance Metrics */
.performance-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.metric-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 25px;
    border: 1px solid var(--border);
    transition: var(--transition);
}

.metric-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.metric-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.metric-header i {
    font-size: 1.5rem;
    color: var(--primary);
    background: var(--bg-tertiary);
    width: 50px;
    height: 50px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.metric-header h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.metric-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 15px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.metric-progress {
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: var(--radius-full);
    position: relative;
    overflow: hidden;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    animation: shimmer 2s infinite;
}

.metric-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* ===== TOOLS PAGE ===== */
.tools-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.page-title {
    font-size: 1.8rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
    animation: slideInLeft 0.5s ease;
}

.tools-search-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
    margin-bottom: 20px;
}

.search-box {
    background: var(--bg-secondary);
    border-radius: var(--radius-full);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    border: 2px solid var(--border);
    transition: var(--transition);
    animation: slideInRight 0.5s ease;
}

.search-box:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(100, 124, 247, 0.1);
}

.search-box i {
    color: var(--text-secondary);
}

.search-box input {
    background: none;
    border: none;
    outline: none;
    color: var(--text-primary);
    font-size: 1rem;
    flex: 1;
}

.search-box input::placeholder {
    color: var(--text-muted);
}

/* Kategori Tools Wrapper for Mobile */
.tools-categories-wrapper {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 10px;
    margin-bottom: 10px;
}

.tools-categories-wrapper::-webkit-scrollbar {
    height: 6px;
}

.tools-categories-wrapper::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
}

.tools-categories-wrapper::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: var(--radius-full);
}

.tools-categories {
    display: flex;
    gap: 10px;
    padding: 5px 0;
    flex-wrap: nowrap;
    min-width: min-content;
}

/* Desktop: wrap categories */
@media (min-width: 769px) {
    .tools-categories-wrapper {
        overflow-x: visible;
    }
    
    .tools-categories {
        flex-wrap: wrap;
        min-width: auto;
    }
}

.category-btn {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    flex-shrink: 0;
}

.category-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.category-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.category-btn i {
    font-size: 0.8rem;
}

.category-btn-text {
    display: inline;
}

@media (max-width: 768px) {
    .category-btn-text {
        font-size: 0.8rem;
    }
}

.tools-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

/* ===== TOOL CARDS STYLES ENHANCED ===== */
.tool-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    animation: fadeIn 0.5s ease;
    animation-delay: var(--delay);
    position: relative;
    overflow: hidden;
}

.tool-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--shadow);
    background: var(--bg-tertiary);
}

.tool-card:active {
    transform: scale(0.97) translateY(-5px);
    opacity: 0.9;
}

@keyframes toolCardClick {
    0% {
        transform: scale(1) translateY(-5px);
    }
    50% {
        transform: scale(0.97) translateY(-5px);
    }
    100% {
        transform: scale(1) translateY(-5px);
    }
}

.tool-card-click-effect {
    position: absolute;
    border-radius: 50%;
    background: rgba(100, 124, 247, 0.3);
    transform: scale(0);
    animation: ripple 0.6s linear;
    pointer-events: none;
}

@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

.tool-card-hover-effect {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(100, 124, 247, 0.1),
        transparent
    );
    transition: left 0.5s ease;
}

.tool-card:hover .tool-card-hover-effect {
    left: 100%;
}

.tool-icon {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
    transition: var(--transition);
    position: relative;
    z-index: 1;
}

.tool-card:hover .tool-icon {
    transform: scale(1.1) rotate(5deg);
    animation: iconBounce 0.5s ease;
}

@keyframes iconBounce {
    0%, 100% {
        transform: scale(1.1) rotate(5deg);
    }
    50% {
        transform: scale(1.15) rotate(10deg);
    }
}

.tool-info {
    flex: 1;
    position: relative;
    z-index: 1;
}

.tool-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 5px;
    transition: var(--transition);
    position: relative;
    display: inline-block;
}

.tool-name::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.tool-card:hover .tool-name::after {
    width: 100%;
}

.tool-card:hover .tool-name {
    color: var(--primary);
}

.tool-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.tool-card:hover .tool-desc {
    color: var(--text-primary);
}

.tool-category-badge {
    display: inline-block;
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    padding: 3px 10px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 500;
    border: 1px solid var(--border);
    transition: var(--transition);
}

.tool-card:hover .tool-category-badge {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    transform: translateY(-2px);
}

.tool-action {
    width: 40px;
    height: 40px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: var(--transition);
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.tool-card:hover .tool-action {
    background: var(--primary);
    color: white;
    transform: translateX(5px) rotate(90deg);
}

/* ===== KONTAK PAGE ===== */
.kontak-header {
    margin-bottom: 30px;
}

.kontak-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.kontak-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 30px;
    text-align: center;
    transition: var(--transition);
    border: 1px solid transparent;
    animation: fadeInUp 0.5s ease;
}

.kontak-card:nth-child(1) { animation-delay: 0.1s; }
.kontak-card:nth-child(2) { animation-delay: 0.2s; }
.kontak-card:nth-child(3) { animation-delay: 0.3s; }

.kontak-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.kontak-icon {
    width: 70px;
    height: 70px;
    background: var(--bg-tertiary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--primary);
    margin: 0 auto 20px;
    transition: var(--transition);
}

.kontak-card:hover .kontak-icon {
    background: var(--primary);
    color: white;
    transform: scale(1.1);
}

.kontak-card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.kontak-card p {
    color: var(--text-secondary);
    margin-bottom: 25px;
    line-height: 1.6;
}

.kontak-methods {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.method {
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: var(--transition);
}

.method:hover {
    background: var(--primary);
    transform: translateX(5px);
}

.method i {
    font-size: 1.2rem;
    color: var(--primary);
    min-width: 20px;
}

.method:hover i {
    color: white;
}

.method span {
    font-weight: 600;
    color: var(--text-primary);
    flex: 1;
    text-align: left;
}

.method:hover span {
    color: white;
}

.method-detail {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.method:hover .method-detail {
    color: rgba(255, 255, 255, 0.9);
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.about-stat {
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    padding: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.about-stat i {
    color: var(--primary);
    font-size: 1.5rem;
}

.about-stat span {
    font-size: 0.9rem;
    color: var(--text-primary);
    font-weight: 500;
}

.privacy-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 20px;
}

.privacy-links a {
    color: var(--primary);
    text-decoration: none;
    padding: 10px 15px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}

.privacy-links a:hover {
    background: var(--primary);
    color: white;
    transform: translateX(5px);
}

/* ===== MUSIK PAGE ===== */
.musik-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.music-controls-header {
    display: flex;
    gap: 15px;
    align-items: center;
    width: 100%;
    flex-wrap: wrap;
}

.tab-switcher {
    display: flex;
    background: var(--bg-tertiary);
    padding: 5px;
    border-radius: var(--radius-md);
    flex: 1;
    min-width: 200px;
}

.tab-btn {
    background: none;
    border: none;
    padding: 10px 15px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    flex: 1;
    justify-content: center;
}

.tab-btn.active {
    background: var(--primary);
    color: white;
    box-shadow: var(--shadow-light);
}

.tab-btn:hover:not(.active) {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.music-control-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: nowrap;
}

.control-btn {
    background: var(--bg-secondary);
    border: none;
    width: 45px;
    height: 45px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-primary);
    font-size: 1.2rem;
}

.control-btn:hover {
    background: var(--bg-tertiary);
    transform: scale(1.05);
}

.control-btn.active {
    background: var(--primary);
    color: white;
}

/* Music Tab Container */
.music-tab {
    display: none;
    animation: fadeIn 0.5s ease;
}

.music-tab.active {
    display: block;
}

.musik-container {
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
    padding: 30px;
    box-shadow: var(--shadow);
    animation: fadeIn 0.5s ease;
}

.now-playing {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.album-art {
    width: 90px;
    height: 90px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: white;
    box-shadow: var(--shadow-light);
    animation: morph 10s ease-in-out infinite;
}

.track-info {
    flex: 1;
    min-width: 200px;
}

.track-info h3 {
    font-size: 1.4rem;
    margin-bottom: 5px;
    color: var(--text-primary);
}

.track-info p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.track-controls {
    display: flex;
    gap: 15px;
    align-items: center;
}

.play-btn {
    background: var(--primary);
    border: none;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: white;
    font-size: 1.4rem;
    box-shadow: 0 5px 15px rgba(100, 124, 247, 0.4);
    animation: neonPulse 2s infinite, glow 1s infinite;
}

.play-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 20px rgba(100, 124, 247, 0.6);
}

.play-btn.playing i {
    transform: translateX(1px);
}

.progress-container {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
}

.progress-container span {
    color: var(--text-secondary);
    font-size: 0.9rem;
    min-width: 40px;
}

.progress-bar {
    flex: 1;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    cursor: pointer;
    overflow: hidden;
}

.progress {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: var(--radius-full);
    transition: width 0.1s linear;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
}

.volume-control i {
    color: var(--text-secondary);
    font-size: 1.2rem;
}

.volume-control input[type="range"] {
    flex: 1;
    height: 6px;
    -webkit-appearance: none;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    outline: none;
}

.volume-control input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    background: var(--primary);
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}

.volume-control input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

.playlist-title {
    font-size: 1.2rem;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
}

.playlist-tracks {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.track-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid transparent;
}

.track-item:hover {
    transform: translateX(5px);
    border-color: var(--primary);
}

.track-item.active {
    background: var(--primary);
}

.track-number {
    color: var(--text-secondary);
    font-weight: 600;
    min-width: 25px;
}

.track-item.active .track-number {
    color: white;
}

.track-details {
    flex: 1;
}

.track-title {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.track-item.active .track-title {
    color: white;
}

.track-artist {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.track-item.active .track-artist {
    color: rgba(255, 255, 255, 0.9);
}

.track-duration {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.track-item.active .track-duration {
    color: white;
}

/* Spotify Search Section */
.spotify-search-section {
    margin-bottom: 30px;
}

.search-input-group {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.search-input-group input {
    flex: 1;
    padding: 16px 20px;
    background: rgba(30, 35, 60, 0.8);
    border: 2px solid var(--border);
    border-radius: 14px;
    color: var(--text-primary);
    font-size: 16px;
    transition: var(--transition);
}

.search-input-group input:focus {
    border-color: var(--primary);
    outline: none;
}

.spotify-search-btn {
    background: #1DB954;
    color: white;
    border: none;
    padding: 16px 30px;
    border-radius: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 10px;
}

.spotify-search-btn:hover {
    background: #1ed760;
    transform: translateY(-2px);
}

.spotify-results {
    max-height: 300px;
    overflow-y: auto;
    background: rgba(30, 35, 60, 0.6);
    border-radius: 12px;
    padding: 15px;
}

.spotify-track-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px;
    background: rgba(30, 35, 60, 0.8);
    border-radius: 10px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid transparent;
}

.spotify-track-item:hover {
    background: rgba(100, 124, 247, 0.2);
    border-color: var(--primary);
    transform: translateX(5px);
}

.spotify-track-item.active {
    background: rgba(29, 185, 84, 0.2);
    border-color: #1DB954;
}

.spotify-track-art {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    overflow: hidden;
    background: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}

.spotify-track-art img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.spotify-track-info {
    flex: 1;
}

.spotify-track-title {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 3px;
}

.spotify-track-artist {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.spotify-track-duration {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* ===== TOOL PAGE STYLES ===== */
.tool-page-wrapper {
    display: none;
}

.tool-page-wrapper.active {
    display: block;
}

.tool-page-container {
    animation: fadeIn 0.4s ease;
}

.tool-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border);
}

.tool-page-title {
    font-size: 1.8rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
}

.tool-back-btn {
    background: var(--bg-secondary);
    border: 2px solid var(--border);
    color: var(--text-primary);
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

.tool-back-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    transform: translateY(-2px);
}

.tool-content {
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
    padding: 30px;
    box-shadow: var(--shadow);
}

/* Tool Button Styles */
.tool-btn {
    background: var(--primary);
    border: none;
    color: white;
    padding: 15px 25px;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 1rem;
    text-decoration: none;
}

.tool-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 20px rgba(100, 124, 247, 0.3);
}

.tool-btn:active {
    transform: translateY(0);
}

.active-mode {
    background: var(--primary) !important;
    color: white !important;
    border-color: var(--primary) !important;
}

/* Loading Spinner */
.loading-spinner {
    border: 3px solid var(--bg-tertiary);
    border-radius: 50%;
    border-top: 3px solid var(--primary);
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

/* ===== PERBAIKAN FORM AI CHAT ===== */
#byyChatContainer, #wormChatContainer {
    max-height: 400px;
    overflow-y: auto;
}

#byyPromptInput, #wormPromptInput {
    width: 100%;
    padding: 12px 16px;
    background: rgba(30, 35, 60, 0.9);
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 14px;
    transition: var(--transition);
    margin-bottom: 10px;
}

#byyPromptInput:focus, #wormPromptInput:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(100, 124, 247, 0.1);
    outline: none;
}

/* Container input untuk mobile */
@media (max-width: 768px) {
    #byyChatContainer, #wormChatContainer {
        height: 350px;
    }
    
    .worm-message, .byy-message {
        max-width: 90% !important;
    }
}

/* ===== BOTTOM NAVIGATION ===== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-around;
    padding: 15px 10px;
    z-index: 1000;
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.1);
}

.nav-btn {
    background: none;
    border: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    padding: 12px;
    border-radius: var(--radius-md);
    min-width: 60px;
    position: relative;
}

.nav-btn i {
    font-size: 1.6rem;
    transition: var(--transition);
}

/* Hapus span text dari bottom nav */
.nav-btn span {
    display: none;
}

/* Tooltip untuk desktop */
.nav-btn::after {
    content: attr(title);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
    background: var(--bg-secondary);
    color: var(--text-primary);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-light);
}

.nav-btn:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(-5px);
}

.nav-btn.active {
    color: var(--primary);
    background: rgba(100, 124, 247, 0.1);
    transform: translateY(-5px);
}

.nav-btn.active i {
    transform: scale(1.1);
}

.nav-btn:hover:not(.active) {
    color: var(--text-primary);
    background: var(--bg-tertiary);
    transform: translateY(-2px);
}

/* Responsive untuk bottom nav */
@media (max-width: 768px) {
    .bottom-nav {
        padding: 12px 8px;
    }
    
    .nav-btn {
        padding: 10px;
        min-width: 55px;
    }
    
    .nav-btn i {
        font-size: 1.4rem;
    }
}

@media (max-width: 480px) {
    .bottom-nav {
        padding: 10px 5px;
    }
    
    .nav-btn {
        padding: 8px;
        min-width: 50px;
    }
    
    .nav-btn i {
        font-size: 1.3rem;
    }
    
    /* Sembunyikan tooltip di mobile */
    .nav-btn::after {
        display: none;
    }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

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

@keyframes fadeOut {
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-15px) rotate(3deg);
    }
}

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

@keyframes morph {
    0%, 100% {
        border-radius: 40% 60% 70% 30% / 40% 40% 60% 50%;
    }
    25% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    }
    50% {
        border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
    }
    75% {
        border-radius: 70% 40% 50% 70% / 40% 60% 40% 60%;
    }
}

@keyframes slideInUp {
    from {
        transform: translateY(100px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

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

@keyframes zoomIn {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes glow {
    0%, 100% {
        box-shadow: 0 0 10px rgba(100, 124, 247, 0.5);
    }
    50% {
        box-shadow: 0 0 20px rgba(100, 124, 247, 0.8),
                    0 0 30px rgba(100, 124, 247, 0.4);
    }
}

@keyframes scalePulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* ===== ANIMASI TAMBAHAN KEREN ===== */

/* 1. Glowing Border Animation */
@keyframes borderGlow {
    0%, 100% {
        border-color: var(--primary);
        box-shadow: 0 0 10px rgba(100, 124, 247, 0.3);
    }
    50% {
        border-color: var(--primary-light);
        box-shadow: 0 0 20px rgba(100, 124, 247, 0.6);
    }
}

/* 2. Shake Animation */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-2px); }
    20%, 40%, 60%, 80% { transform: translateX(2px); }
}

/* 3. Bounce In */
@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        transform: scale(1);
    }
}

/* 4. Floating Text */
@keyframes floatText {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

/* 5. Neon Pulse */
@keyframes neonPulse {
    0%, 100% {
        text-shadow: 0 0 5px var(--primary),
                     0 0 10px var(--primary),
                     0 0 15px var(--primary);
    }
    50% {
        text-shadow: 0 0 10px var(--primary-light),
                     0 0 20px var(--primary-light),
                     0 0 30px var(--primary-light);
    }
}

/* 6. Rotate Slow */
@keyframes rotateSlow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* 7. Wave Animation */
@keyframes wave {
    0%, 100% {
        transform: translateY(0);
    }
    25% {
        transform: translateY(-10px);
    }
    50% {
        transform: translateY(0);
    }
    75% {
        transform: translateY(5px);
    }
}

/* 8. Gradient Shift */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* 9. Slide In From Bottom */
@keyframes slideInBottom {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 10. Typewriter Effect */
@keyframes typewriter {
    from {
        width: 0;
        opacity: 1;
    }
    to {
        width: 100%;
        opacity: 1;
    }
}

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: var(--primary) }
}

/* ===== WAVE TEXT ANIMATION ===== */
.wave-text {
    display: inline-block;
}

.wave-text span {
    display: inline-block;
    animation: waveLetter 0.5s ease infinite alternate;
}

.wave-text span:nth-child(1) { animation-delay: 0s; }
.wave-text span:nth-child(2) { animation-delay: 0.1s; }
.wave-text span:nth-child(3) { animation-delay: 0.2s; }
.wave-text span:nth-child(4) { animation-delay: 0.3s; }
.wave-text span:nth-child(5) { animation-delay: 0.4s; }
.wave-text span:nth-child(6) { animation-delay: 0.5s; }
.wave-text span:nth-child(7) { animation-delay: 0.6s; }
.wave-text span:nth-child(8) { animation-delay: 0.7s; }

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

/* ===== ANIMASI TEXT BARU ===== */
.scale-pulse-text {
    animation: scalePulse 2s infinite ease-in-out;
}

.animated-gradient-text {
    background: linear-gradient(
        90deg,
        var(--primary) 0%,
        var(--primary-light) 25%,
        #f472b6 50%,
        var(--primary-light) 75%,
        var(--primary) 100%
    );
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientFlow 3s linear infinite;
}

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

.floating-words {
    animation: floatText 6s ease-in-out infinite;
}

.slide-in-text {
    animation: slideInLeft 0.8s ease-out forwards;
    opacity: 0;
}

.neon-flicker {
    animation: neonFlicker 3s infinite;
}

@keyframes neonFlicker {
    0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% {
        text-shadow: 
            0 0 5px var(--primary),
            0 0 10px var(--primary),
            0 0 15px var(--primary);
    }
    20%, 24%, 55% {
        text-shadow: none;
    }
}

/* ===== HEADER ===== */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    margin-bottom: 30px;
    animation: slideDown 0.6s ease;
    position: relative;
}

.logo-container {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.logo {
    font-size: 2rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: var(--transition);
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: floatText 3s ease-in-out infinite;
}

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

.tagline {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* HEADER ACTIONS WRAPPER UNTUK MENYATUKAN API STATUS DAN TOMBOL */
.header-actions-wrapper {
    display: flex;
    gap: 10px;
    align-items: center;
}

/* API STATUS STYLES */
.api-status-container {
    margin-right: 0;
    position: relative;
    height: 40px;
    display: flex;
    align-items: center;
}

.api-status {
    background: rgba(30, 35, 60, 0.85);
    border-radius: var(--radius-md);
    padding: 0 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.75rem;
    font-weight: 600;
    backdrop-filter: blur(15px);
    -webkit-background-clip: padding-box;
    background-clip: padding-box;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    width: auto;
    height: 40px;
    justify-content: center;
    min-width: 120px;
}

.api-status.online {
    border-color: rgba(16, 185, 129, 0.3);
    background: rgba(16, 185, 129, 0.08);
    color: #10b981;
}

.api-status.offline {
    border-color: rgba(239, 68, 68, 0.3);
    background: rgba(239, 68, 68, 0.08);
    color: #ef4444;
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    position: relative;
}

.status-indicator.online {
    background: #10b981;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2);
}

.status-indicator.online::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: 50%;
    border: 1px solid rgba(16, 185, 129, 0.4);
    animation: pulseRing 2s infinite;
}

.status-indicator.offline {
    background: #ef4444;
    box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.2);
}

#statusText {
    font-weight: 600;
    letter-spacing: 0.3px;
    transition: color 0.3s ease;
    font-size: 0.75rem;
}

/* Animasi khusus untuk status online */
@keyframes pulseRing {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

/* HEADER ACTIONS - TOMBOL TEMA DAN NOTIFIKASI */
.header-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

/* SEJAJARKAN SEMUA TOMBOL DENGAN UKURAN YANG SAMA */
.theme-toggle,
.notification-btn,
.api-status {
    width: auto;
    min-width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-primary);
    font-size: 1.1rem;
}

.theme-toggle,
.notification-btn {
    padding: 0;
    border: none;
    background: var(--bg-secondary);
}

.api-status {
    padding: 0 16px;
    background: rgba(30, 35, 60, 0.85);
}

.theme-toggle:hover,
.notification-btn:hover,
.api-status:hover {
    background: var(--bg-tertiary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-light);
}

.api-status:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.theme-toggle:hover {
    animation: rotateSlow 0.5s ease;
}

/* Animasi masuk */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Untuk theme light */
[data-theme="light"] .api-status {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(226, 232, 240, 0.8);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .api-status.online {
    background: rgba(16, 185, 129, 0.05);
    border-color: rgba(16, 185, 129, 0.2);
}

[data-theme="light"] .api-status.offline {
    background: rgba(239, 68, 68, 0.05);
    border-color: rgba(239, 68, 68, 0.2);
}

[data-theme="light"] .theme-toggle,
[data-theme="light"] .notification-btn {
    background: var(--bg-secondary);
}

/* Featured Tools Section */
.featured-tools-section {
    margin-bottom: 50px;
    animation: fadeIn 0.8s ease 0.4s both;
}

.featured-tools-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

@media (max-width: 1024px) {
    .featured-tools-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .featured-tools-grid {
        grid-template-columns: 1fr;
    }
}

.featured-tool-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
}

.featured-tool-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.featured-tool-icon {
    width: 70px;
    height: 70px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    flex-shrink: 0;
}

.featured-tool-content {
    flex: 1;
}

.featured-tool-content h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.featured-tool-content p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.tool-rating {
    display: flex;
    align-items: center;
    gap: 5px;
}

.tool-rating i {
    color: #f59e0b;
    font-size: 0.9rem;
}

.tool-rating span {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-left: 5px;
}

/* Stats Section Styles - DIHAPUS */
.stats-section {
    display: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    /* Header Responsive */
    .header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
        padding: 15px 0;
        margin-bottom: 20px;
    }
    
    .header-actions-wrapper {
        width: 100%;
        justify-content: space-between;
        margin-top: 10px;
    }
    
    .api-status-container {
        flex: 1;
        margin-right: 10px;
    }
    
    .api-status {
        min-width: 100px;
        height: 38px;
        font-size: 0.7rem;
        padding: 0 12px;
    }
    
    .theme-toggle,
    .notification-btn {
        width: 38px;
        height: 38px;
        min-width: 38px;
    }
    
    .container {
        padding: 15px;
        padding-bottom: 90px;
    }
    
    .logo {
        font-size: 1.6rem;
    }
    
    .tagline {
        font-size: 0.8rem;
    }
    
    /* Home Page Responsive */
    .hero-section {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }
    
    .hero-content {
        padding-right: 0;
    }
    
    .hero-title {
        font-size: 2.2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-stats {
        justify-content: center;
        gap: 20px;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .floating-element {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }
    
    /* Tools Page Responsive */
    .tools-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .search-box {
        min-width: 100%;
    }
    
    .tools-categories {
        justify-content: flex-start;
    }
    
    .category-btn {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
    
    .tools-container {
        grid-template-columns: 1fr;
    }
    
    /* Platform Statistics Responsive */
    .stats-grid-enhanced {
        grid-template-columns: 1fr;
    }
    
    .chart-container-enhanced {
        grid-template-columns: 1fr;
    }
    
    /* Featured Tools Responsive */
    .featured-tools-grid {
        grid-template-columns: 1fr;
    }
    
    /* Footer Responsive */
    .footer-stats {
        gap: 20px;
    }
    
    .footer-stat i {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }
    
    .footer-links {
        gap: 15px;
    }
    
    /* Tool Cards Responsive */
    .tool-card {
        padding: 15px;
    }
    
    .tool-icon {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }
    
    .tool-name {
        font-size: 1rem;
    }
    
    .tool-desc {
        font-size: 0.8rem;
    }
    
    /* Music Page Responsive */
    .musik-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .music-controls-header {
        flex-direction: row;
        width: 100%;
    }
    
    .tab-switcher {
        width: 100%;
        min-width: unset;
    }
    
    .music-control-buttons {
        width: 100%;
        justify-content: center;
    }
    
    .control-btn {
        width: 40px;
        height: 40px;
    }
    
    .now-playing {
        justify-content: center;
        text-align: center;
    }
    
    .track-info {
        min-width: 100%;
    }
    
    .track-controls {
        justify-content: center;
        width: 100%;
    }
    
    .search-input-group {
        flex-direction: column;
    }
    
    .spotify-search-btn {
        width: 100%;
        justify-content: center;
    }
    
    /* Tool Page Responsive */
    .tool-page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .tool-back-btn {
        align-self: stretch;
        text-align: center;
        justify-content: center;
    }
    
    .tool-content {
        padding: 20px;
    }
}

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

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

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

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: var(--radius-full);
}

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

/* Selection Color */
::selection {
    background: rgba(100, 124, 247, 0.3);
    color: var(--text-primary);
}

/* Focus Styles */
:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Responsive untuk Loading Screen */
@media (max-width: 768px) {
    .loading-text-simple {
        font-size: 2.2rem;
    }
    
    .logo-shape-morph {
        width: 90px;
        height: 90px;
    }
    
    .shape-inner {
        width: 45px;
        height: 45px;
    }
    
    .simple-progress {
        width: 250px;
    }
    
    .geometric-particle {
        display: none;
    }
}

/* Loading Screen untuk tema light */
[data-theme="light"] #loading-screen {
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 50%, #f8fafc 100%);
}

[data-theme="light"] .loading-text-simple .byy {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

[data-theme="light"] .loading-text-simple .verse {
    color: var(--text-primary);
}

[data-theme="light"] .logo-shape-morph {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
}

[data-theme="light"] .geometric-particle {
    background: rgba(100, 124, 247, 0.1);
}

[data-theme="light"] .geometric-particle.triangle {
    border-bottom-color: rgba(100, 124, 247, 0.1);
}

/* ===== PERBAIKAN CHART RESPONSIVE ===== */

/* Container utama chart */
.chart-section-enhanced {
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
    padding: 20px;
    margin-bottom: 30px;
    border: 1px solid var(--border);
    overflow: hidden; /* Mencegah konten keluar */
    width: 100%;
}

/* Header chart */
.chart-header-enhanced {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 20px;
    width: 100%;
}

.chart-header-enhanced h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chart-controls {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.chart-period-btn {
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    padding: 6px 12px;
    border-radius: var(--radius-md);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    flex: 1;
    min-width: 80px;
    text-align: center;
}

/* Container chart utama */
.chart-container-enhanced {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    overflow: hidden;
}

@media (min-width: 1024px) {
    .chart-container-enhanced {
        flex-direction: row;
    }
}

/* Canvas chart */
.chart-canvas {
    flex: 1;
    min-height: 300px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-lg);
    padding: 15px;
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: 100%;
}

/* Enhanced chart container */
.enhanced-chart-container {
    position: relative;
    height: 100%;
    width: 100%;
    min-height: 250px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    padding: 10px;
    overflow: hidden;
}

/* Chart timeline */
.chart-timeline {
    position: absolute;
    top: 5px;
    left: 50px;
    right: 30px;
    height: 15px;
    display: flex;
    pointer-events: none;
    z-index: 2;
    overflow: hidden;
}

.timeline-marker {
    position: absolute;
    font-size: 9px;
    color: var(--text-secondary);
    transform: translateX(-50%);
    white-space: nowrap;
    font-weight: 500;
}

/* Multi-line chart area */
.multi-line-chart {
    position: absolute;
    top: 30px;
    left: 50px;
    right: 30px;
    bottom: 30px;
    overflow: visible;
}

/* Grid enhanced */
.chart-grid-enhanced {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: repeat(10, 1fr);
    opacity: 0.15;
    pointer-events: none;
}

/* SVG chart */
#lineChartSVG {
    width: 100%;
    height: 100%;
    overflow: visible;
}

/* X-axis labels */
.x-axis-labels {
    position: absolute;
    bottom: 5px;
    left: 50px;
    right: 30px;
    height: 25px;
    pointer-events: none;
    overflow: hidden;
}

.x-axis-label {
    position: absolute;
    font-size: 9px;
    color: var(--text-secondary);
    transform: translateX(-50%);
    text-align: center;
    line-height: 1.2;
    font-weight: 500;
    white-space: nowrap;
}

/* Legend container */
.chart-legend-enhanced {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 15px;
    border: 1px solid var(--border);
    min-width: 280px;
    max-width: 100%;
    width: 100%;
}

@media (min-width: 1024px) {
    .chart-legend-enhanced {
        max-width: 320px;
        width: auto;
    }
}

/* Legend title */
.legend-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.legend-update-time {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-weight: normal;
    background: var(--bg-tertiary);
    padding: 3px 8px;
    border-radius: var(--radius-sm);
}

/* Legend items container */
.legend-items-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
    max-height: 250px;
    overflow-y: auto;
    padding-right: 5px;
    width: 100%;
}

/* Legend item */
.legend-item-enhanced {
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    padding: 10px;
    border: 1px solid transparent;
    transition: var(--transition);
    cursor: pointer;
    width: 100%;
    min-width: 0; /* Important for flexbox */
}

/* Legend item header */
.legend-item-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    width: 100%;
    min-width: 0;
}

.legend-color {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
    min-width: 10px;
}

.legend-tool-name {
    flex: 1;
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0; /* Important for text truncation */
}

.legend-usage-value {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--primary);
    background: rgba(100, 124, 247, 0.1);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    flex-shrink: 0;
    white-space: nowrap;
}

/* Progress bar dalam legend */
.legend-item-progress {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: 6px;
    width: 100%;
}

.legend-item-progress .progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: var(--radius-full);
    transition: width 0.5s ease;
}

/* Legend item meta */
.legend-item-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 10px;
}

.meta-category {
    font-size: 0.7rem;
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
    min-width: 0;
}

.meta-change {
    font-size: 0.7rem;
    font-weight: 600;
    white-space: nowrap;
}

/* Legend stats */
.legend-stats {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 15px;
    border-top: 1px solid var(--border);
    width: 100%;
}

.legend-stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 10px;
}

.legend-stat .stat-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    white-space: nowrap;
}

.legend-stat .stat-value {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    white-space: nowrap;
}

/* Chart footer controls */
.chart-footer-controls {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border);
    width: 100%;
}

@media (min-width: 640px) {
    .chart-footer-controls {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

.chart-scale-controls {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.scale-btn {
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    padding: 6px 12px;
    border-radius: var(--radius-md);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
}

.chart-info {
    display: flex;
    justify-content: center;
}

.info-badge {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 5px 10px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    white-space: nowrap;
}

/* Tooltip adjustments */
.chart-tooltip {
    position: absolute;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3),
                0 0 0 1px var(--border);
    z-index: 1000;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    max-width: 250px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.85rem;
}

/* Responsive fixes for very small screens */
@media (max-width: 640px) {
    .chart-section-enhanced {
        padding: 15px;
    }
    
    .chart-canvas {
        min-height: 250px;
        padding: 10px;
    }
    
    .enhanced-chart-container {
        min-height: 200px;
        padding: 8px;
    }
    
    .multi-line-chart {
        left: 40px;
        right: 20px;
        top: 25px;
        bottom: 25px;
    }
    
    .chart-timeline {
        left: 40px;
        right: 20px;
        top: 3px;
    }
    
    .x-axis-labels {
        left: 40px;
        right: 20px;
        bottom: 3px;
    }
    
    .chart-legend-enhanced {
        padding: 12px;
    }
    
    .legend-items-container {
        max-height: 200px;
    }
    
    .legend-title {
        font-size: 0.9rem;
    }
    
    .legend-tool-name {
        font-size: 0.8rem;
    }
    
    .chart-period-btn {
        padding: 5px 10px;
        font-size: 0.75rem;
        min-width: 70px;
    }
    
    .scale-btn {
        padding: 5px 10px;
        font-size: 0.75rem;
    }
    
    .info-badge {
        font-size: 0.75rem;
        padding: 4px 8px;
    }
}

/* Fix untuk sangat lebar pada desktop */
@media (min-width: 1400px) {
    .chart-container-enhanced {
        max-width: 1200px;
        margin: 0 auto;
    }
}

/* Perbaikan overflow pada chart */
#lineChartSVG {
    max-width: 100%;
    overflow: visible;
}

.chart-grid-enhanced {
    max-width: 100%;
}

/* Animasi untuk chart loading */
.chart-loading {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-lg);
    z-index: 100;
}

/* ===== FIX UNTUK PERFORMANCE METRICS ===== */
.performance-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-top: 30px;
    width: 100%;
    overflow: hidden;
}

.metric-card {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 20px;
    border: 1px solid var(--border);
    transition: var(--transition);
    width: 100%;
    min-width: 0; /* Important for grid */
}

/* Responsive untuk metrics */
@media (max-width: 768px) {
    .performance-metrics {
        grid-template-columns: 1fr;
    }
    
    .metric-card {
        padding: 15px;
    }
    
    .metric-value {
        font-size: 1.8rem;
    }
}

/* ===== SERVICE CHART STYLES ===== */

.service-chart-area {
    filter: drop-shadow(0 4px 12px rgba(100, 124, 247, 0.15));
}

.service-chart-line {
    filter: drop-shadow(0 2px 8px rgba(100, 124, 247, 0.25));
}

@keyframes drawLine {
    from {
        stroke-dashoffset: 1000;
    }
    to {
        stroke-dashoffset: 0;
    }
}

/* Responsive chart */
@media (max-width: 768px) {
    #lineChartSVG {
        height: 250px;
    }
    
    .enhanced-chart-container {
        min-height: 200px;
    }
    
    .chart-canvas {
        height: 280px;
    }
}

/* Legend untuk service chart */
.legend-item-service {
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    padding: 12px;
    margin-bottom: 8px;
    border-left: 3px solid #647cf7;
}

.legend-service-value {
    font-size: 1.5rem;
    font-weight: 800;
    color: #647cf7;
    margin-bottom: 5px;
}

.legend-service-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Timeline untuk service chart */
.service-timeline {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    padding: 0 10px;
}

.timeline-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-align: center;
    flex: 1;
}

/* Grid untuk service chart */
.service-chart-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(to right, rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 20px 20px;
    opacity: 0.3;
    pointer-events: none;
}

/* Chart container untuk service */
.chart-canvas {
    position: relative;
    background: var(--bg-tertiary);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

/* Animation untuk chart update */
@keyframes chartUpdate {
    0% {
        opacity: 0.8;
    }
    100% {
        opacity: 1;
    }
}

.chart-updating {
    animation: chartUpdate 0.5s ease;
}

/* ===== TOKEN MODAL STYLES ===== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 9999;
    animation: modalFadeIn 0.3s ease;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
    width: 90%;
    max-width: 450px;
    border: 1px solid var(--border);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5),
                0 0 0 1px rgba(255, 255, 255, 0.05);
    animation: modalSlideUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    overflow: hidden;
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, rgba(100, 124, 247, 0.1), rgba(139, 92, 246, 0.1));
}

.modal-header h3 {
    font-size: 1.3rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 8px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
}

.modal-close:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    transform: rotate(90deg);
}

.modal-body {
    padding: 30px 25px;
}

.token-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    font-size: 2.5rem;
    color: white;
    box-shadow: 0 10px 30px rgba(100, 124, 247, 0.3);
    animation: pulse 2s infinite;
}

.token-info h4 {
    font-size: 1.2rem;
    color: var(--text-primary);
    margin-bottom: 10px;
    text-align: center;
}

.token-info p {
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 25px;
    line-height: 1.6;
}

.token-input-group {
    margin-bottom: 25px;
}

.input-with-icon {
    position: relative;
    margin-bottom: 10px;
}

.input-with-icon i {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.input-with-icon input {
    width: 100%;
    padding: 16px 50px 16px 50px;
    background: var(--bg-tertiary);
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 500;
    letter-spacing: 1px;
    transition: var(--transition);
}

.input-with-icon input:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(100, 124, 247, 0.1);
}

.show-token-btn {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 5px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.show-token-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.input-hint {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    color: var(--text-muted);
    padding: 5px 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-sm);
}

.token-actions {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
}

.btn-primary, .btn-secondary {
    flex: 1;
    padding: 16px;
    border-radius: var(--radius-lg);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 2px solid transparent;
    font-size: 0.95rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(100, 124, 247, 0.3);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--border);
}

.btn-secondary:hover {
    background: var(--bg-secondary);
    transform: translateY(-2px);
}

.token-note {
    background: rgba(100, 124, 247, 0.05);
    border-radius: var(--radius-lg);
    padding: 20px;
    border: 1px solid rgba(100, 124, 247, 0.1);
}

.note-header {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 15px;
    font-size: 0.95rem;
}

.note-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.note-list li {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 8px;
    padding-left: 20px;
    position: relative;
}

.note-list li:before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--success);
    font-weight: bold;
}

.modal-footer {
    padding: 20px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-tertiary);
}

.session-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.session-info i {
    color: var(--warning);
}

#sessionTimer {
    color: var(--primary);
    font-weight: 600;
    font-family: monospace;
    background: rgba(0, 0, 0, 0.2);
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    min-width: 70px;
    display: inline-block;
    text-align: center;
}

.btn-logout {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 0.2);
    transform: translateY(-2px);
}

/* Animations */
@keyframes modalFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(50px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Token Error State */
.token-input-error input {
    border-color: #ef4444 !important;
    background: rgba(239, 68, 68, 0.05);
    animation: shake 0.5s ease;
}

.token-success {
    color: var(--success) !important;
}

/* Loading State */
.token-loading {
    opacity: 0.7;
    pointer-events: none;
}

.token-loading::after {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
    margin-left: 10px;
}

/* ===== FIX TOKEN MODAL MOBILE RESPONSIVE ===== */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        max-width: 95%;
        margin: 20px;
        max-height: 90vh;
        overflow-y: auto;
    }
    
    .modal-body {
        padding: 20px 15px;
    }
    
    .token-icon {
        width: 70px;
        height: 70px;
        font-size: 2rem;
        margin-bottom: 20px;
    }
    
    .token-info h4 {
        font-size: 1.1rem;
    }
    
    .token-info p {
        font-size: 0.9rem;
        margin-bottom: 20px;
    }
    
    .input-with-icon {
        margin-bottom: 15px;
    }
    
    .input-with-icon i {
        left: 15px;
        font-size: 1rem;
    }
    
    .input-with-icon input {
        padding: 14px 45px 14px 45px;
        font-size: 0.95rem;
    }
    
    .show-token-btn {
        right: 12px;
        width: 28px;
        height: 28px;
        background: var(--bg-secondary);
        border: 1px solid var(--border);
    }
    
    .show-token-btn:hover {
        background: var(--bg-tertiary);
    }
    
    .token-actions {
        flex-direction: column;
        gap: 12px;
    }
    
    .btn-primary, .btn-secondary {
        padding: 14px;
        font-size: 0.9rem;
        width: 100%;
    }
    
    .token-note {
        padding: 15px;
    }
    
    .note-list li {
        font-size: 0.8rem;
        margin-bottom: 6px;
    }
    
    .modal-footer {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
        padding: 15px;
    }
    
    .session-info {
        justify-content: center;
        text-align: center;
        font-size: 0.8rem;
    }
    
    .btn-logout {
        width: 100%;
        justify-content: center;
        padding: 10px;
    }
}

/* FIX UNTUK INPUT EYE BUTTON YANG MENCENG */
.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.show-token-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 6px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.show-token-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

/* Perbaikan border radius untuk input yang konsisten */
.input-with-icon input {
    width: 100%;
    padding: 16px 50px 16px 50px;
    background: var(--bg-tertiary);
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 500;
    letter-spacing: 1px;
    transition: var(--transition);
}

/* Tambahan untuk tampilan yang lebih baik di mobile sangat kecil */
@media (max-width: 480px) {
    .modal-content {
        margin: 10px;
        max-height: 85vh;
    }
    
    .modal-header {
        padding: 15px;
    }
    
    .modal-header h3 {
        font-size: 1.1rem;
    }
    
    .token-icon {
        width: 60px;
        height: 60px;
        font-size: 1.8rem;
    }
    
    .input-with-icon input {
        padding: 12px 42px 12px 42px;
        font-size: 0.9rem;
    }
    
    .show-token-btn {
        width: 30px;
        height: 30px;
        right: 10px;
    }
}

/* Perbaikan untuk modal yang terlalu tinggi */
.modal {
    align-items: flex-start;
    padding-top: 20px;
    overflow-y: auto;
}

@media (max-height: 700px) {
    .modal {
        align-items: flex-start;
        padding-top: 10px;
    }
    
    .modal-content {
        max-height: 90vh;
        overflow-y: auto;
        margin-top: 10px;
    }
}

/* FIX: Mencegah konten modal terpotong di mobile */
.modal-body {
    min-height: auto;
}

/* Tambahan untuk scroll yang lebih baik di modal */
.modal-content {
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.modal-body {
    flex: 1;
    overflow-y: auto;
    max-height: calc(90vh - 140px);
}

/* Perbaikan scroll untuk modal body */
.modal-body {
    scrollbar-width: thin;
    scrollbar-color: var(--primary) var(--bg-tertiary);
}

.modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-body::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
}

.modal-body::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: var(--radius-full);
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Eye button dengan border yang lebih jelas di light theme */
[data-theme="light"] .show-token-btn {
    background: rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .show-token-btn:hover {
    background: rgba(0, 0, 0, 0.1);
}

/* Icon eye yang lebih jelas */
.show-token-btn i {
    font-size: 0.9rem;
    transition: transform 0.2s ease;
}

.show-token-btn:hover i {
    transform: scale(1.1);
}

/* ===== ANIMASI MODAL ===== */
@keyframes modalSlideOut {
    from {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    to {
        opacity: 0;
        transform: translateY(50px) scale(0.95);
    }
}

/* Loading state untuk button */
.btn-primary.token-loading {
    opacity: 0.8;
    pointer-events: none;
}

.btn-primary.token-loading i {
    animation: spin 1s linear infinite;
}

/* Animasi sukses untuk button */
.btn-primary.token-success {
    background: linear-gradient(135deg, #10b981, #34d399) !important;
    animation: bounceIn 0.5s ease;
}

/* ===== PERBAIKAN MODAL BODY ===== */
.token-note {
    margin-bottom: 20px;
}

/* Container untuk tombol link tambahan */
.token-link-extra {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
}

/* Tombol tutorial */
.btn-tutorial {
    background: linear-gradient(135deg, #ff0000, #ff4444);
    color: white;
    border: none;
    padding: 14px;
    border-radius: var(--radius-lg);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 0.9rem;
    text-decoration: none;
    text-align: center;
}

.btn-tutorial:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(255, 0, 0, 0.3);
}

.btn-tutorial i {
    font-size: 1.1rem;
}

/* Animasi tambahan untuk button loading */
@keyframes buttonPulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

.btn-primary:disabled {
    animation: buttonPulse 1.5s infinite;
}

/* Animasi untuk icon spinner */
.fa-spinner {
    animation: spin 1s linear infinite;
}

/* Responsive untuk tombol tambahan */
@media (max-width: 768px) {
    .token-link-extra {
        margin-top: 10px;
    }
    
    .btn-tutorial {
        padding: 12px;
        font-size: 0.85rem;
    }
}

/* Smooth transition untuk modal */
.modal-content {
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
                opacity 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Overlay animation */
.modal {
    transition: backdrop-filter 0.4s ease,
                background-color 0.4s ease;
}

.modal.show {
    backdrop-filter: blur(10px);
    background: rgba(0, 0, 0, 0.8);
}