/* ═══════════════════════════════════════════════════════════════
   TDH STRATEGY - PUBLIC DASHBOARD
   A distinctive, modern design for the 6529 community
═══════════════════════════════════════════════════════════════ */

:root {
    /* Core palette - Deep space with electric accents */
    --bg-void: #05050a;
    --bg-deep: #0a0a12;
    --bg-surface: #12121f;
    --bg-elevated: #1a1a2e;
    --bg-glass: rgba(26, 26, 46, 0.7);
    
    /* Text */
    --text-primary: #f0f0f5;
    --text-secondary: #8888a0;
    --text-muted: #55556a;
    
    /* Accent - Electric teal/cyan */
    --accent-primary: #00ffd5;
    --accent-secondary: #00b8ff;
    --accent-glow: rgba(0, 255, 213, 0.3);
    
    /* Status colors */
    --success: #00ff88;
    --warning: #ffaa00;
    --danger: #ff4466;
    
    /* Borders */
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-accent: rgba(0, 255, 213, 0.3);
    
    /* Typography */
    --font-display: 'Space Grotesk', sans-serif;
    --font-mono: 'IBM Plex Mono', monospace;
    
    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;
    
    /* Radii */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 28px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-display);
    background: var(--bg-void);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
}

/* ═══════════════════════════════════════════════════════════════
   BACKGROUND EFFECTS
═══════════════════════════════════════════════════════════════ */

.noise {
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 0;
}

.gradient-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
    z-index: 0;
}

.orb-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-primary) 0%, transparent 70%);
    top: -200px;
    right: -200px;
    opacity: 0.15;
    animation: float 20s ease-in-out infinite;
}

.orb-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-secondary) 0%, transparent 70%);
    bottom: -100px;
    left: -100px;
    opacity: 0.1;
    animation: float 25s ease-in-out infinite reverse;
}

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

/* ═══════════════════════════════════════════════════════════════
   NAVBAR
═══════════════════════════════════════════════════════════════ */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-md) var(--space-xl);
    background: rgba(5, 5, 10, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-subtle);
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.logo {
    font-size: 1.5rem;
    color: var(--accent-primary);
    text-shadow: 0 0 20px var(--accent-glow);
}

.brand-text {
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: -0.02em;
}

.nav-links {
    display: flex;
    gap: var(--space-lg);
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-links a:hover {
    color: var(--accent-primary);
}

.nav-status {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(0, 255, 136, 0.4); }
    50% { opacity: 0.8; box-shadow: 0 0 0 8px rgba(0, 255, 136, 0); }
}

/* ═══════════════════════════════════════════════════════════════
   CONTAINER & LAYOUT
═══════════════════════════════════════════════════════════════ */

.container {
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
    padding: calc(80px + var(--space-2xl)) var(--space-xl) var(--space-2xl);
}

/* ═══════════════════════════════════════════════════════════════
   HERO
═══════════════════════════════════════════════════════════════ */

.hero {
    text-align: center;
    padding: var(--space-3xl) 0;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: var(--space-lg);
}

.gradient-text {
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* ═══════════════════════════════════════════════════════════════
   STATS GRID
═══════════════════════════════════════════════════════════════ */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-lg);
    margin-bottom: var(--space-2xl);
}

.stat-card {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    display: flex;
    align-items: flex-start;
    gap: var(--space-lg);
    transition: transform 0.3s, border-color 0.3s;
}

.stat-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-accent);
}

.stat-card.primary {
    background: linear-gradient(135deg, rgba(0, 255, 213, 0.1) 0%, rgba(0, 184, 255, 0.05) 100%);
    border-color: var(--border-accent);
}

.stat-icon {
    font-size: 2rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-surface);
    border-radius: var(--radius-md);
}

.stat-content {
    display: flex;
    flex-direction: column;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--space-xs);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    font-family: var(--font-mono);
    color: var(--text-primary);
    line-height: 1;
}

.stat-card.primary .stat-value {
    color: var(--accent-primary);
    text-shadow: 0 0 30px var(--accent-glow);
}

.stat-unit {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: var(--space-xs);
}

/* ═══════════════════════════════════════════════════════════════
   CONTRACT INFO
═══════════════════════════════════════════════════════════════ */

.contract-info {
    margin-bottom: var(--space-3xl);
}

.contract-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
}

.contract-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: block;
    margin-bottom: var(--space-md);
}

.contract-address {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-md);
    margin-bottom: var(--space-md);
}

.contract-address code {
    font-family: var(--font-mono);
    font-size: 1rem;
    color: var(--accent-primary);
    background: var(--bg-elevated);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-sm);
}

.copy-btn {
    background: var(--bg-elevated);
    border: none;
    padding: var(--space-sm);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background 0.2s;
}

.copy-btn:hover {
    background: var(--bg-glass);
}

.etherscan-link {
    color: var(--accent-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.etherscan-link:hover {
    color: var(--accent-primary);
}

/* ═══════════════════════════════════════════════════════════════
   SECTIONS
═══════════════════════════════════════════════════════════════ */

.section-header {
    margin-bottom: var(--space-xl);
}

.section-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: var(--space-sm);
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* ═══════════════════════════════════════════════════════════════
   DEALS GRID
═══════════════════════════════════════════════════════════════ */

.deals-section {
    margin-bottom: var(--space-3xl);
}

.deals-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: var(--space-lg);
}

.deal-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
}

.deal-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-accent);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.deal-card.best {
    border-color: var(--accent-primary);
    box-shadow: 0 0 40px var(--accent-glow);
}

.deal-rank {
    position: absolute;
    top: var(--space-md);
    left: var(--space-md);
    background: var(--bg-void);
    color: var(--accent-primary);
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 0.85rem;
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius-sm);
}

.deal-image {
    position: relative;
    height: 200px;
    background: var(--bg-deep);
    display: flex;
    align-items: center;
    justify-content: center;
}

.deal-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.deal-image .placeholder {
    font-size: 3rem;
    opacity: 0.3;
}

.deal-content {
    padding: var(--space-lg);
}

.deal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--space-md);
}

.deal-token {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--accent-secondary);
}

.deal-name {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: var(--space-sm);
}

.deal-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md);
}

.deal-stat {
    display: flex;
    flex-direction: column;
}

.deal-stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.deal-stat-value {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-primary);
}

.deal-stat-value.highlight {
    color: var(--accent-primary);
}

/* ═══════════════════════════════════════════════════════════════
   HOLDINGS GRID
═══════════════════════════════════════════════════════════════ */

.holdings-section {
    margin-bottom: var(--space-3xl);
}

.holdings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: var(--space-md);
}

.holding-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: transform 0.2s;
}

.holding-card:hover {
    transform: scale(1.02);
}

.holding-image {
    height: 150px;
    background: var(--bg-deep);
    display: flex;
    align-items: center;
    justify-content: center;
}

.holding-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.holding-info {
    padding: var(--space-md);
    text-align: center;
}

.holding-token {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent-secondary);
}

.holding-amount {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: var(--space-3xl);
    color: var(--text-muted);
}

.empty-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: var(--space-md);
    opacity: 0.5;
}

/* ═══════════════════════════════════════════════════════════════
   TOKEN SECTION
═══════════════════════════════════════════════════════════════ */

.token-section {
    margin-bottom: var(--space-3xl);
}

.token-placeholder {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: var(--space-xl);
}

.token-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md);
}

.token-stat {
    background: var(--bg-elevated);
    padding: var(--space-lg);
    border-radius: var(--radius-md);
    text-align: center;
}

.token-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: block;
    margin-bottom: var(--space-sm);
}

.token-value {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--accent-primary);
}

.chart-placeholder {
    background: var(--bg-elevated);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 250px;
}

.chart-coming-soon {
    text-align: center;
    color: var(--text-muted);
}

.chart-coming-soon span {
    font-size: 3rem;
    display: block;
    margin-bottom: var(--space-md);
    opacity: 0.3;
}

/* ═══════════════════════════════════════════════════════════════
   LOADING & UTILITIES
═══════════════════════════════════════════════════════════════ */

.loading-placeholder {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-3xl);
    color: var(--text-muted);
    gap: var(--space-md);
}

.loader {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-subtle);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* ═══════════════════════════════════════════════════════════════
   FOOTER
═══════════════════════════════════════════════════════════════ */

.footer {
    background: var(--bg-deep);
    border-top: 1px solid var(--border-subtle);
    padding: var(--space-xl);
    text-align: center;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-links {
    display: flex;
    gap: var(--space-lg);
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: var(--accent-primary);
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
    .navbar {
        padding: var(--space-md);
    }
    
    .nav-links {
        display: none;
    }
    
    .container {
        padding: calc(70px + var(--space-xl)) var(--space-md) var(--space-xl);
    }
    
    .token-placeholder {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        gap: var(--space-md);
    }
}

