/* ─── GAMIFICATION v2.0 SPECIFIC OVERRIDES ───────────────────────── */

.scrollbar-hide::-webkit-scrollbar { display: none; }
.scrollbar-hide { -ms-overflow-style: none; scrollbar-width: none; }

/* Tabs */
.tabs { -webkit-overflow-scrolling: touch; }

.tab {
    padding: 12px 24px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-secondary, #8a919e);
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tab:hover {
    color: var(--text-primary, #ffffff);
    background: rgba(255, 255, 255, 0.02);
}

.tab.active {
    color: var(--accent, #FF6600);
    border-bottom: 2px solid var(--accent, #FF6600);
    background: linear-gradient(to top, rgba(255, 102, 0, 0.1) 0%, transparent 100%);
}

/* Sections */
.section {
    display: none;
    animation: terminalFadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.section.active { display: block; }

@keyframes terminalFadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Modals */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 1rem;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    transform: scale(0.95) translateY(10px);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.active .modal-content {
    transform: scale(1) translateY(0);
}

.modal-option {
    display: block;
    width: 100%;
    padding: 16px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-tertiary, #6b7280);
    font-size: 0.9rem;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Space Grotesk', sans-serif;
}

.modal-option:hover {
    background: rgba(255, 102, 0, 0.05);
    border-color: var(--accent, #FF6600);
    color: var(--text-primary, #ffffff);
}

.modal-option.correct {
    background: rgba(74, 222, 128, 0.1);
    border-color: rgba(74, 222, 128, 0.4);
    color: #4ade80;
}

.modal-option.wrong {
    background: rgba(244, 63, 94, 0.1);
    border-color: rgba(244, 63, 94, 0.4);
    color: #f43f5e;
}

.modal-option.disabled {
    opacity: 0.4;
    pointer-events: none;
}

/* Wallet Gate Overlay */
.wallet-gate-overlay {
    position: fixed;
    inset: 0;
    background: rgba(3, 3, 3, 0.97);
    backdrop-filter: blur(20px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.wallet-gate-overlay.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.wallet-gate-panel {
    position: relative;
}

/* Wallet Status Bar */
.wallet-status-bar {
    animation: terminalFadeIn 0.4s ease;
}

/* Task / Quiz / Badge Cards */
.task-card,
.quiz-card,
.badge-card {
    background: rgba(10, 10, 10, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
}

.task-card:hover,
.quiz-card:hover,
.badge-card:hover:not(.badge-locked) {
    border-color: rgba(255, 102, 0, 0.3);
    background: rgba(255, 102, 0, 0.03);
    transform: translateY(-2px);
}

.task-card.completed {
    opacity: 0.4;
    pointer-events: none;
    filter: grayscale(1);
    border-color: rgba(255, 255, 255, 0.02);
}

.task-card.locked {
    opacity: 0.5;
    pointer-events: none;
    position: relative;
}

.task-card.locked::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 10px,
        rgba(0,0,0,0.2) 10px,
        rgba(0,0,0,0.2) 20px
    );
}

.badge-locked {
    opacity: 0.3;
    filter: grayscale(1);
}

.badge-earned {
    border-color: rgba(255, 102, 0, 0.3);
    background: rgba(255, 102, 0, 0.05);
}

/* Leaderboard */
.leaderboard-row {
    display: grid;
    grid-template-columns: 3rem 1fr auto;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background 0.2s;
}

.leaderboard-row:hover {
    background: rgba(255, 255, 255, 0.02);
}

.leaderboard-row:last-child {
    border-bottom: none;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
}

.toast {
    background: #0a0a0a;
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 14px 20px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    font-weight: 700;
    color: #ffffff;
    animation: toastSlideIn 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.3);
    max-width: 360px;
    pointer-events: auto;
    position: relative;
    overflow: hidden;
}

.toast::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
}

.toast.success { border-color: rgba(74, 222, 128, 0.3); }
.toast.success::before { background: #4ade80; }

.toast.warning { border-color: rgba(255, 102, 0, 0.3); }
.toast.warning::before { background: #FF6600; }

.toast.error { border-color: rgba(244, 63, 94, 0.3); }
.toast.error::before { background: #f43f5e; }

.toast.info { border-color: rgba(59, 130, 246, 0.3); }
.toast.info::before { background: #3b82f6; }

.toast-title {
    font-size: 14px;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.toast-subtitle {
    font-size: 11px;
    opacity: 0.7;
    font-weight: 400;
}

@keyframes toastSlideIn {
    from { transform: translateX(120%); opacity: 0; }
    to   { transform: translateX(0); opacity: 1; }
}

@keyframes toastSlideOut {
    from { transform: translateX(0); opacity: 1; }
    to   { transform: translateX(120%); opacity: 0; }
}

/* Badge Notification (Center Popup) */
.badge-notification {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, #FF6600, #FF8533);
    color: #000;
    padding: 32px;
    text-align: center;
    font-family: 'Space Grotesk', sans-serif;
    z-index: 10000;
    animation: badgePopIn 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    border: 3px solid rgba(255, 255, 255, 0.2);
    box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.3);
    min-width: 300px;
}

@keyframes badgePopIn {
    from { transform: translate(-50%, -40%) scale(0.85); opacity: 0; }
    to   { transform: translate(-50%, -50%) scale(1); opacity: 1; }
}

@keyframes badgePopOut {
    from { transform: translate(-50%, -50%) scale(1); opacity: 1; }
    to   { transform: translate(-50%, -40%) scale(0.85); opacity: 0; }
}

/* Icon sizing helpers */
.icon-inline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1em;
    height: 1em;
    vertical-align: middle;
}

.icon-inline svg {
    width: 100%;
    height: 100%;
}

/* Brutalist border utility */
.brutal-border {
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
}

/* Loading skeleton */
.skeleton {
    background: linear-gradient(90deg, rgba(255,255,255,0.03) 25%, rgba(255,255,255,0.06) 50%, rgba(255,255,255,0.03) 75%);
    background-size: 200% 100%;
    animation: skeletonShimmer 1.5s infinite;
    border-radius: 2px;
}

@keyframes skeletonShimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Quiz explanation panel */
.quiz-explanation {
    margin-top: 12px;
    padding: 12px;
    background: rgba(255, 102, 0, 0.05);
    border-left: 2px solid rgba(255, 102, 0, 0.3);
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
    color: #a1a1aa;
    line-height: 1.5;
}

/* ─── VESTING DASHBOARD ───────────────────────── */
.vesting-tranche {
    margin-bottom: 16px;
}
.vesting-tranche:last-child {
    margin-bottom: 0;
}
.vesting-bar-track {
    height: 8px;
    background: #030303;
    border: 1px solid rgba(255,255,255,0.08);
    overflow: hidden;
    position: relative;
}
.vesting-bar-fill {
    height: 100%;
    background: #FF6600;
    transition: width 1s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
}
.vesting-bar-fill::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 2px;
    background: rgba(255,255,255,0.3);
}
.vesting-bar-fill.locked {
    background: #1F1F1F;
}
.vesting-bar-fill.locked::after {
    display: none;
}
.vesting-claimable {
    background: rgba(74, 222, 128, 0.05);
    border: 1px solid rgba(74, 222, 128, 0.15);
}
.vesting-locked {
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.05);
}

/* ─── MULTIPLIER BADGE ────────────────────────── */
.multiplier-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    font-family: 'JetBrains Mono', monospace;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 2px 8px;
    border: 1px solid rgba(255, 102, 0, 0.3);
    color: #FF6600;
    background: rgba(255, 102, 0, 0.05);
}

/* ─── PASSPORT GATE MODAL ─────────────────────── */
.passport-panel {
    border-top: 1px solid rgba(255,255,255,0.08);
    margin-top: 24px;
    padding-top: 24px;
}
.passport-score-ring {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: 3px solid rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    font-size: 18px;
    margin: 0 auto 16px;
}
.passport-score-ring.valid {
    border-color: #4ade80;
    color: #4ade80;
}
.passport-score-ring.invalid {
    border-color: #f43f5e;
    color: #f43f5e;
}

/* Optional: smaller tab padding on tiny screens */
@media (max-width: 380px) {
    .tab { padding: 10px 14px; font-size: 0.65rem; }
}