/* ==========================================================================
   Coinx Vista - Design System & Custom Styles
   ========================================================================== */

/* Custom Variables */
:root {
    /* Color Palette */
    --bg-dark: #060813;
    --bg-card: rgba(13, 17, 39, 0.45);
    --bg-card-hover: rgba(20, 25, 55, 0.55);
    
    /* Neon Glow Accents */
    --accent-cyan: #00f2fe;
    --accent-purple: #9d4edd;
    --accent-green: #00ff87;
    --accent-blue: #4facfe;
    --accent-pink: #ff007f;
    
    /* Text Colors */
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --text-glow: rgba(0, 242, 254, 0.4);
    
    /* Layout & Borders */
    --border-glass: rgba(255, 255, 255, 0.06);
    --border-glow: rgba(0, 242, 254, 0.15);
    --border-radius-lg: 24px;
    --border-radius-md: 12px;
    --border-radius-sm: 8px;
    
    /* Transitions */
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    min-height: 100vh;
    background-color: var(--bg-dark);
    font-family: 'Outfit', sans-serif;
    color: var(--text-primary);
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* Interactive Background Canvas */
#particle-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    pointer-events: all; /* Allow mouse interaction */
}

/* Top Crypto Live Ticker */
.ticker-wrapper {
    position: relative;
    width: 100%;
    background: rgba(8, 10, 24, 0.85);
    border-bottom: 1px solid var(--border-glass);
    z-index: 10;
    backdrop-filter: blur(12px);
    overflow: hidden;
    height: 48px;
    display: flex;
    align-items: center;
}

.ticker-container {
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
}

.ticker-track {
    display: inline-flex;
    padding-left: 100%;
    animation: ticker-slide 30s linear infinite;
}

.ticker-track:hover {
    animation-play-state: paused;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    padding: 0 24px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    font-weight: 500;
}

.ticker-coin {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.08);
    padding: 2px 6px;
    border-radius: 4px;
    margin-right: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.ticker-price {
    margin-right: 8px;
    color: var(--text-primary);
    font-weight: 600;
}

.ticker-change {
    font-size: 0.8rem;
    font-weight: 700;
}

.ticker-change.up {
    color: var(--accent-green);
    text-shadow: 0 0 10px rgba(0, 255, 135, 0.2);
}

.ticker-change.up::before {
    content: '▲ ';
    font-size: 0.7rem;
}

.ticker-change.down {
    color: var(--accent-pink);
    text-shadow: 0 0 10px rgba(255, 0, 127, 0.2);
}

.ticker-change.down::before {
    content: '▼ ';
    font-size: 0.7rem;
}

/* App Layout Container */
.app-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* Header */
.main-header {
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 36px;
    height: 36px;
    filter: drop-shadow(0 0 8px rgba(0, 242, 254, 0.4));
    animation: rotate-logo 20s linear infinite;
}

.logo-text {
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, #ffffff 40%, #a0aec0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo-text .highlight {
    background: linear-gradient(135deg, var(--accent-cyan) 0%, var(--accent-blue) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-left: 2px;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 242, 254, 0.06);
    border: 1px solid rgba(0, 242, 254, 0.15);
    padding: 6px 14px;
    border-radius: 20px;
}

.status-dot {
    width: 8px;
    height: 8px;
    background-color: var(--accent-cyan);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-cyan);
    animation: pulse-dot 1.8s infinite alternate;
}

.status-text {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-cyan);
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Main Hero Section */
.hero-section {
    padding: 60px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
}

.hero-card {
    position: relative;
    width: 100%;
    max-width: 680px;
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: var(--border-radius-lg);
    padding: 50px 40px;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    box-shadow: 
        0 24px 80px rgba(0, 0, 0, 0.5), 
        inset 0 1px 1px rgba(255, 255, 255, 0.1);
    text-align: center;
    overflow: hidden;
    transition: var(--transition-smooth);
    animation: card-float 6s ease-in-out infinite;
}

.hero-card:hover {
    border-color: rgba(0, 242, 254, 0.2);
    box-shadow: 
        0 30px 100px rgba(0, 242, 254, 0.06),
        0 24px 80px rgba(0, 0, 0, 0.5), 
        inset 0 1px 2px rgba(255, 255, 255, 0.15);
}

/* Decorative Glows inside Card */
.card-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    opacity: 0.12;
    z-index: 1;
}

.glow-1 {
    top: -10%;
    left: -10%;
    width: 300px;
    height: 300px;
    background: var(--accent-cyan);
}

.glow-2 {
    bottom: -15%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: var(--accent-purple);
}

/* Card Contents */
.main-title {
    position: relative;
    z-index: 2;
    font-size: 2.85rem;
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: -0.02em;
    margin: 0;
}

.gradient-text {
    background: linear-gradient(135deg, var(--accent-cyan) 0%, var(--accent-purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 15px rgba(0, 242, 254, 0.15));
}

/* Footer Section */
.main-footer {
    height: auto;
    padding: 30px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.copyright {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 300;
}

/* Keyframe Animations */
@keyframes ticker-slide {
    0% {
        transform: translate3d(0, 0, 0);
    }
    100% {
        transform: translate3d(-50%, 0, 0);
    }
}

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

@keyframes pulse-dot {
    0% {
        box-shadow: 0 0 4px var(--accent-cyan);
        transform: scale(0.95);
    }
    100% {
        box-shadow: 0 0 12px var(--accent-cyan);
        transform: scale(1.05);
    }
}

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

/* Responsive Media Queries */
@media (max-width: 768px) {
    .main-header {
        height: 80px;
    }
    
    .status-text {
        display: none; /* Hide state text on small mobiles to save room, keep indicator dot */
    }
    .status-indicator {
        padding: 8px;
        border-radius: 50%;
    }
    
    .hero-section {
        padding: 40px 0;
    }

    .hero-card {
        padding: 40px 20px;
        border-radius: var(--border-radius-md);
    }

    .main-title {
        font-size: 2.1rem;
    }
}
