:root {
    --accent: #e0913a;
    --bg: #050505;
    --card: #0f0f0f;
    --border: #222;
    --text: #ffffff;
    --text-dim: #777;
    --success: #4ade80;
    --warning: #fbbf24;
    --danger: #ef4444;
    --cyan: #06b6d4;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background: var(--bg);
    color: var(--text);
}

/* ========== SIDEBAR ========== */
.app-container {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 260px;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(10px);
    border-right: 1px solid var(--border);
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    z-index: 100;
}

.sidebar-logo {
    text-align: center;
    padding: 20px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 20px;
}

.sidebar-logo img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid var(--accent);
    padding: 3px;
}

.sidebar-logo h3 {
    margin-top: 10px;
    font-size: 1rem;
    color: var(--accent);
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 0 15px;
}

.sidebar-nav button {
    background: transparent;
    border: none;
    color: var(--text-dim);
    padding: 12px 16px;
    text-align: left;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    border-radius: 12px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.sidebar-nav button i {
    width: 24px;
    font-size: 1.1rem;
}

.sidebar-nav button:hover {
    background: rgba(224, 145, 58, 0.1);
    color: var(--accent);
}

.sidebar-nav button.active {
    background: rgba(224, 145, 58, 0.15);
    color: var(--accent);
    border-left: 3px solid var(--accent);
}

/* ========== MAIN CONTENT ========== */
.main-content {
    flex: 1;
    margin-left: 260px;
    padding: 20px 30px;
    max-width: calc(100% - 260px);
}

.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
    flex-wrap: wrap;
    gap: 15px;
}

.page-title h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent);
}

.page-title p {
    font-size: 0.75rem;
    color: var(--text-dim);
    margin-top: 5px;
}

.wallet-area {
    display: flex;
    gap: 10px;
}

/* ========== BOTÕES ========== */
.btn-sm {
    background: #222;
    border: none;
    color: #fff;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 800;
    cursor: pointer;
    border: 1px solid var(--border);
    transition: all 0.2s ease;
}

.btn-sm:hover {
    background: #333;
}

.btn-disconnect {
    background: rgba(239, 68, 68, 0.2);
    border-color: var(--danger);
    color: var(--danger);
}

.btn-disconnect:hover {
    background: rgba(239, 68, 68, 0.4);
}

.btn-main {
    width: 100%;
    padding: 16px;
    border-radius: 18px;
    border: none;
    font-weight: 800;
    font-size: 0.9rem;
    cursor: pointer;
    text-transform: uppercase;
    background: var(--accent);
    color: #000;
    transition: all 0.2s ease;
}

.btn-main:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(224, 145, 58, 0.3);
}

.btn-main:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-secondary {
    background: #2a2a2a;
    color: var(--text);
}

.btn-secondary:hover:not(:disabled) {
    background: #3a3a3a;
}

/* ========== CARDS ========== */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.stat-label {
    font-size: 0.65rem;
    font-weight: 800;
    color: var(--text-dim);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stat-value {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--accent);
    font-family: monospace;
    word-break: break-word;
}

.stat-sub {
    font-size: 0.7rem;
    color: var(--text-dim);
    margin-top: 5px;
}

.progress-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 20px;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    font-size: 0.8rem;
    flex-wrap: wrap;
    gap: 5px;
}

.progress-bar-container {
    background: var(--border);
    border-radius: 10px;
    padding: 2px;
}

.progress-bar {
    background: linear-gradient(90deg, var(--accent), #f5a623);
    height: 8px;
    border-radius: 8px;
    transition: width 0.5s ease;
}

.two-col-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

/* ========== MINERAÇÃO ========== */
.mining-animation {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    padding: 15px;
    text-align: center;
    margin-bottom: 20px;
}

.miner-icon {
    font-size: 2rem;
    display: inline-block;
}

@keyframes shake {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(5deg); }
    75% { transform: rotate(-5deg); }
}

.mining-progress-bar {
    background: var(--border);
    border-radius: 10px;
    padding: 2px;
    margin-top: 15px;
}

.mining-progress-fill {
    background: linear-gradient(90deg, var(--accent), var(--cyan));
    height: 6px;
    border-radius: 8px;
    transition: width 0.1s linear;
}

/* ========== LOG DE MINERAÇÃO ========== */
.mining-log {
    background: #0d0d0d;
    border-radius: 10px;
    padding: 10px;
    height: 200px;
    overflow-y: auto;
    font-size: 12px;
    color: #00ff88;
    font-family: 'Courier New', monospace;
    border: 1px solid var(--border);
    margin: 15px 0;
}

.log-entry {
    border-left: 2px solid var(--accent);
    padding-left: 8px;
    margin-bottom: 4px;
    animation: fadeIn 0.2s ease;
}

.log-error {
    color: #ff6b6b;
    border-left-color: #ff6b6b;
}

.log-warning {
    color: #ffd93d;
    border-left-color: #ffd93d;
}

.log-success {
    color: #6bcb77;
    border-left-color: #6bcb77;
}

.log-info {
    color: #4d96ff;
    border-left-color: #4d96ff;
}

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

/* ========== HISTÓRICO ========== */
.history-list {
    max-height: 200px;
    overflow-y: auto;
}

.history-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.8rem;
}

.history-amount {
    color: var(--success);
    font-weight: 700;
}

.history-date {
    color: var(--text-dim);
    font-size: 0.7rem;
}

/* ========== BADGES E ALERTAS ========== */
.badge {
    background: rgba(224, 145, 58, 0.2);
    color: var(--accent);
    padding: 5px 12px;
    border-radius: 100px;
    font-size: 0.7rem;
    display: inline-block;
    font-weight: 700;
}

.security-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(74, 222, 128, 0.1);
    border: 1px solid rgba(74, 222, 128, 0.3);
    padding: 8px 15px;
    border-radius: 40px;
    font-size: 0.7rem;
    color: var(--success);
    margin-right: 10px;
    margin-bottom: 10px;
}

.alert-warning {
    background: rgba(251, 191, 36, 0.15);
    border-left: 3px solid var(--warning);
    padding: 10px;
    border-radius: 12px;
    margin-bottom: 15px;
    font-size: 0.75rem;
}

.alert-danger {
    background: rgba(239, 68, 68, 0.15);
    border-left: 3px solid var(--danger);
    padding: 10px;
    border-radius: 12px;
    margin-bottom: 15px;
    font-size: 0.75rem;
}

/* ========== NOTIFICAÇÕES ========== */
.success-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    left: 20px;
    max-width: 400px;
    margin: 0 auto;
    padding: 12px 20px;
    border-radius: 40px;
    font-weight: 700;
    font-size: 0.8rem;
    z-index: 1001;
    animation: slideIn 0.3s ease-out;
    text-align: center;
}

.success-notification.success {
    background: rgba(74, 222, 128, 0.95);
    color: #000;
}

.success-notification.error {
    background: rgba(239, 68, 68, 0.95);
    color: #fff;
}

.success-notification.warning {
    background: rgba(251, 191, 36, 0.95);
    color: #000;
}

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

/* ========== RESPONSIVIDADE ========== */
@media (max-width: 768px) {
    .sidebar {
        width: 70px;
    }
    .sidebar-logo h3,
    .sidebar-nav button span {
        display: none;
    }
    .sidebar-nav button {
        justify-content: center;
    }
    .sidebar-nav button i {
        margin: 0;
    }
    .main-content {
        margin-left: 70px;
        padding: 15px;
        max-width: calc(100% - 70px);
    }
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    .two-col-grid {
        grid-template-columns: 1fr;
    }
    .stat-value {
        font-size: 1.2rem;
    }
    .btn-main {
        padding: 14px;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .stat-card {
        padding: 12px;
    }
    .hero-title {
        padding: 20px;
    }
    .mining-log {
        height: 150px;
        font-size: 10px;
    }
}
