@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@400;600;700&family=Space+Mono:wght@400;700&display=swap');

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

/* ============================================================
   TOP BAR
   ============================================================ */
#top-bar {
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    height: 36px;
    background: rgba(8, 10, 18, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(20, 241, 149, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    z-index: 10000;
    font-family: 'Space Mono', monospace;
}

.top-bar-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(20, 241, 149, 0.7);
}

#token-address {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.75);
    padding: 6px 12px;
    font-size: 12px;
    border-radius: 6px;
    width: 300px;
    text-align: center;
    font-family: 'Space Mono', monospace;
    outline: none;
    cursor: text;
}

.top-bar-btn {
    background: rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.8);
    border: 1px solid rgba(255,255,255,0.15);
    padding: 6px 14px;
    cursor: pointer;
    font-size: 12px;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    border-radius: 6px;
    text-decoration: none;
    letter-spacing: 0.5px;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
}
.top-bar-btn:hover {
    background: rgba(255,255,255,0.12);
    border-color: rgba(255,255,255,0.3);
    color: #fff;
}

.top-bar-btn-green {
    background: rgba(20, 241, 149, 0.12);
    color: #14F195;
    border-color: rgba(20, 241, 149, 0.4);
}
.top-bar-btn-green:hover {
    background: rgba(20, 241, 149, 0.22);
    border-color: #14F195;
    color: #14F195;
}

/* ============================================================
   PROFILE WIDGET (top-right)
   ============================================================ */
#profile-widget {
    position: fixed;
    top: 40px;
    right: 12px;
    z-index: 10001;
    display: none;
    align-items: center;
    gap: 10px;
    background: rgba(8, 10, 18, 0.95);
    border: 1px solid rgba(20, 241, 149, 0.25);
    border-radius: 0 0 10px 10px;
    padding: 6px 14px 8px 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}
#profile-widget:hover {
    background: rgba(255,255,255,0.09);
    border-color: rgba(20,241,149,0.3);
}
#profile-widget.active { display: flex; }

#profile-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(135deg, #14F195, #9b8fff);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #000;
    flex-shrink: 0;
}

#profile-info {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

#profile-wallet-label {
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    color: rgba(255,255,255,0.7);
    letter-spacing: 0.3px;
}

#profile-score-label {
    font-family: 'Space Mono', monospace;
    font-size: 10px;
    color: rgba(255,255,255,0.35);
}

#profile-score-value {
    color: #14F195;
}

/* ============================================================
   FLOATING SIDE BUTTONS
   ============================================================ */
#floating-buttons {
    position: fixed;
    top: 180px;
    left: 16px;
    z-index: 8000;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: auto;
    transition: opacity 0.3s ease;
}

/* Esconde os botões flutuantes quando a gaveta está aberta */
body.drawer-open #floating-buttons {
    opacity: 0;
    pointer-events: none;
}

.float-btn {
    background: rgba(8, 10, 20, 0.85);
    color: rgba(255,255,255,0.85);
    border: 1px solid rgba(255,255,255,0.12);
    padding: 10px 16px;
    border-radius: 8px;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    letter-spacing: 0.5px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    pointer-events: auto;
    white-space: nowrap;
}
.float-btn:hover {
    background: rgba(20, 241, 149, 0.1);
    border-color: rgba(20, 241, 149, 0.5);
    color: #14F195;
    transform: translateX(2px);
}

.float-btn-x {
    text-decoration: none;
    display: flex;
    align-items: center;
    color: rgba(255,255,255,0.85);
}
.float-btn-x:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.4);
    color: #fff;
    transform: translateX(2px);
}

/* ============================================================
   SIDE DRAWER
   ============================================================ */
#side-drawer {
    position: fixed;
    top: 52px;
    left: 0;
    width: 360px;
    max-width: 88vw;
    height: calc(100% - 52px);
    background: #080a12;
    border-right: 1px solid rgba(20, 241, 149, 0.25);
    z-index: 9500;
    transform: translateX(-100%);
    transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

#side-drawer.open {
    transform: translateX(0);
    box-shadow: 8px 0 40px rgba(0,0,0,0.7);
}

.drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 20px 16px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    flex-shrink: 0;
}

.drawer-title {
    color: #fff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin: 0;
}

#close-drawer {
    background: none;
    border: none;
    color: rgba(255,255,255,0.3);
    font-size: 20px;
    cursor: pointer;
    pointer-events: auto;
    line-height: 1;
    transition: color 0.2s ease;
    padding: 4px;
    border-radius: 4px;
}
#close-drawer:hover { color: #ff4757; }

.drawer-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.1) transparent;
}
.drawer-body::-webkit-scrollbar { width: 4px; }
.drawer-body::-webkit-scrollbar-track { background: transparent; }
.drawer-body::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 2px; }

/* ============================================================
   WHITEPAPER CONTENT
   ============================================================ */
.wp-section {
    margin-bottom: 28px;
}
.wp-section h3 {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: rgba(20, 241, 149, 0.7);
    margin-bottom: 10px;
}
.wp-section p {
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    line-height: 1.8;
    color: rgba(255,255,255,0.6);
}
.wp-section strong {
    color: rgba(255,255,255,0.9);
}

.wp-flywheel {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 14px;
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    overflow: hidden;
}

.wp-flywheel-step {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    line-height: 1.7;
    color: rgba(255,255,255,0.5);
    transition: background 0.2s;
}
.wp-flywheel-step:last-child { border-bottom: none; }
.wp-flywheel-step:hover { background: rgba(20, 241, 149, 0.03); }

.wp-flywheel-num {
    font-family: 'Rajdhani', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: rgba(20, 241, 149, 0.4);
    min-width: 28px;
    line-height: 1.2;
    flex-shrink: 0;
}

.wp-flywheel-step strong { color: rgba(255,255,255,0.85); }


.reward-box {
    background: rgba(20, 241, 149, 0.05);
    border: 1px solid rgba(20, 241, 149, 0.15);
    border-radius: 8px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 4px;
}

.reward-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.reward-pct {
    font-family: 'Rajdhani', sans-serif;
    font-size: 28px;
    font-weight: 700;
    color: #14F195;
    min-width: 60px;
    line-height: 1;
}

.reward-desc {
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    color: rgba(255,255,255,0.5);
    line-height: 1.5;
}
.reward-desc strong { color: rgba(255,255,255,0.85); }

.reward-divider {
    height: 1px;
    background: rgba(255,255,255,0.06);
    margin: 2px 0;
}

/* ============================================================
   LEADERBOARD TABLE
   ============================================================ */
.leaderboard-table {
    width: 100%;
    border-collapse: collapse;
}

.leaderboard-table thead th {
    font-family: 'Space Mono', monospace;
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(255,255,255,0.25);
    padding: 0 6px 12px;
    text-align: left;
    font-weight: 400;
}
.leaderboard-table thead th:first-child { text-align: center; width: 36px; }
.leaderboard-table thead th:last-child { text-align: right; }

.leaderboard-table tbody tr {
    border-bottom: 1px solid rgba(255,255,255,0.04);
    transition: background 0.15s;
}
.leaderboard-table tbody tr:hover { background: rgba(255,255,255,0.03); }

.leaderboard-table tbody td {
    padding: 11px 6px;
    font-size: 13px;
    color: rgba(255,255,255,0.7);
    font-family: 'Space Mono', monospace;
}
.leaderboard-table tbody td:first-child {
    text-align: center;
    color: rgba(255,255,255,0.3);
    font-size: 12px;
}
.leaderboard-table tbody td:last-child {
    text-align: right;
    color: #14F195;
    font-weight: 700;
}

/* Pódio */
.leaderboard-table tbody tr:nth-child(1) td:first-child { color: #FFD700; font-size: 15px; }
.leaderboard-table tbody tr:nth-child(2) td:first-child { color: #C0C0C0; font-size: 14px; }
.leaderboard-table tbody tr:nth-child(3) td:first-child { color: #CD7F32; font-size: 14px; }

/* ============================================================
   WEB3 OVERLAY
   ============================================================ */
#web3-overlay {
    position: fixed;
    top: 52px; left: 0;
    width: 100%;
    height: calc(100% - 52px);
    background: rgba(4, 5, 12, 0.82);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 7000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease;
    pointer-events: auto;
}

#web3-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Conteúdo centralizado no overlay */
.overlay-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    text-align: center;
}

.overlay-logo {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 6px;
    text-transform: uppercase;
    color: rgba(20, 241, 149, 0.5);
    margin-bottom: 8px;
}

#connect-wallet-btn {
    background: #14F195;
    color: #030811;
    font-family: 'Rajdhani', sans-serif;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 18px 48px;
    border: 2px solid #14F195;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 0 32px rgba(20, 241, 149, 0.35), 0 4px 24px rgba(0,0,0,0.5);
    pointer-events: auto;
    position: relative;
    overflow: hidden;
}

#connect-wallet-btn::before {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

#connect-wallet-btn:hover::before { left: 150%; }

#connect-wallet-btn:hover {
    background: transparent;
    color: #14F195;
    box-shadow: 0 0 50px rgba(20, 241, 149, 0.6), 0 4px 24px rgba(0,0,0,0.5);
}

.overlay-hint {
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    color: rgba(255,255,255,0.2);
    letter-spacing: 1px;
}

/* ============================================================
   CUSTOM MODAL
   ============================================================ */
.cobb-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: modal-fade-in 0.2s ease;
}

@keyframes modal-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.cobb-modal-box {
    background: #0a0d18;
    border: 1px solid rgba(20, 241, 149, 0.2);
    border-radius: 14px;
    padding: 40px 36px 32px;
    max-width: 420px;
    width: 90%;
    text-align: center;
    box-shadow: 0 0 60px rgba(0,0,0,0.8), 0 0 30px rgba(20, 241, 149, 0.06);
    animation: modal-slide-up 0.25s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

.cobb-modal-icon {
    font-size: 44px;
    margin-bottom: 16px;
    line-height: 1;
}

.cobb-modal-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #fff;
    margin: 0 0 14px;
}

.cobb-modal-text {
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    line-height: 1.8;
    color: rgba(255,255,255,0.45);
    margin: 0 0 28px;
}

.cobb-modal-text a {
    color: #14F195;
    text-decoration: none;
}
.cobb-modal-text a:hover { text-decoration: underline; }

.cobb-modal-btn {
    background: rgba(20, 241, 149, 0.08);
    color: #14F195;
    border: 1px solid rgba(20, 241, 149, 0.3);
    padding: 12px 44px;
    border-radius: 8px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.2s ease;
}
.cobb-modal-btn:hover {
    background: rgba(20, 241, 149, 0.18);
    border-color: #14F195;
}
