:root {
    --primary: #0a5c44;
    --primary-dark: #084532;
    --primary-light: #e8f3ef;
    --accent: #f5b042;
    --accent-dark: #e09d2c;
    --danger: #e74c3c;
    --success: #27ae60;
    --warning: #f39c12;
    --info: #3498db;
    --gray-bg: #f8f9fc;
    --card-white: #ffffff;
    --border: #e9ecef;
    --text-muted: #6c7a89;
    --text-dark: #1a2634;
}

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

body {
    font-family: 'Inter', sans-serif;
    background: #f5f7fb;
    color: var(--text-dark);
    line-height: 1.5;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Navbar */
.navbar {
    background: var(--card-white);
    border-bottom: 1px solid var(--border);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0,0,0,0.02);
}

.nav-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary) 0%, #2c8c6b 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.logo i {
    background: none;
    color: var(--accent);
    margin-right: 4px;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    flex-wrap: wrap;
}

.nav-link {
    text-decoration: none;
    font-weight: 500;
    color: var(--text-muted);
    transition: 0.2s;
}

.nav-link.active, .nav-link:hover {
    color: var(--primary);
    font-weight: 600;
}

.btn-outline {
    background: transparent;
    border: 1.5px solid var(--primary);
    padding: 0.5rem 1.2rem;
    border-radius: 40px;
    font-weight: 600;
    color: var(--primary);
    cursor: pointer;
    transition: 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

.btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.85rem 2rem;
    border-radius: 48px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-outline-primary {
    background: transparent;
    border: 1.5px solid var(--primary);
    padding: 0.8rem 1.8rem;
    border-radius: 48px;
    font-weight: 600;
    color: var(--primary);
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
}

.btn-small {
    background: var(--accent);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 0.5rem;
    text-decoration: none;
    display: inline-block;
    color: var(--primary-dark);
}

.btn-full {
    width: 100%;
    text-align: center;
}

/* Hero Section */
.hero {
    padding: 4rem 0 2rem;
}

.hero-grid {
    display: flex;
    align-items: center;
    gap: 3rem;
    flex-wrap: wrap;
}

.hero-content {
    flex: 1;
}

.badge {
    background: var(--primary-light);
    color: var(--primary);
    padding: 0.3rem 1rem;
    border-radius: 40px;
    font-size: 0.8rem;
    display: inline-block;
    margin-bottom: 1rem;
}

.hero-content h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-content p {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.stats {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}

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

.stats span {
    font-weight: 800;
    color: var(--primary);
    font-size: 1.2rem;
    display: block;
}

.earning-card {
    background: linear-gradient(135deg, var(--primary) 0%, #2c8c6b 100%);
    color: white;
    padding: 2rem;
    border-radius: 32px;
    text-align: center;
    min-width: 220px;
}

.earning-card i {
    font-size: 2.5rem;
}

.earning-amount {
    font-size: 2rem;
    font-weight: 800;
    margin: 0.5rem 0;
}

/* Features */
.features, .how-it-works, .testimonials, .cta-section {
    padding: 4rem 0;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.features-grid, .steps-grid, .testimonial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.feature-card, .step, .testimonial-card {
    background: var(--card-white);
    padding: 2rem;
    border-radius: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    border: 1px solid var(--border);
    transition: transform 0.2s;
    text-align: center;
}

.feature-card:hover {
    transform: translateY(-4px);
}

.feature-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.status-tag {
    display: inline-block;
    margin-top: 0.5rem;
    font-size: 0.7rem;
    background: var(--warning);
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 20px;
}

.step-number {
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin: 0 auto 1rem;
}

.step i {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.stars {
    color: var(--accent);
    margin-bottom: 0.5rem;
}

.testimonial-card p {
    margin-bottom: 1rem;
    font-style: italic;
}

.user {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.earned {
    font-weight: 600;
    color: var(--success);
}

.cta-card {
    background: linear-gradient(135deg, var(--primary) 0%, #2c8c6b 100%);
    color: white;
    padding: 3rem;
    border-radius: 32px;
    text-align: center;
}

.cta-card h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.btn-large {
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    margin-top: 1rem;
    background: var(--accent);
    color: var(--primary-dark);
}

.btn-large:hover {
    background: var(--accent-dark);
}

/* Footer */
footer {
    background: var(--card-white);
    padding: 3rem 0 1.5rem;
    margin-top: 3rem;
    border-top: 1px solid var(--border);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-col h4 {
    margin-bottom: 1rem;
    color: var(--primary);
}

.footer-col a, .footer-col p {
    display: block;
    color: var(--text-muted);
    text-decoration: none;
    margin-bottom: 0.5rem;
}

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

.footer-copyright {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Auth Pages */
.auth-page {
    background: linear-gradient(135deg, #f5f7fb 0%, #e9ecef 100%);
    min-height: 100vh;
}

.auth-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 80px);
    padding: 2rem;
}

.auth-card {
    background: var(--card-white);
    border-radius: 32px;
    padding: 2.5rem;
    max-width: 480px;
    width: 100%;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header i {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.auth-header h2 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

/* Form Styles */
.form-group {
    margin-bottom: 1.2rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-dark);
}

.form-group input, .form-group select {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    font-size: 1rem;
    transition: 0.2s;
}

.form-group input:focus, .form-group select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(10,92,68,0.1);
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.forgot-password {
    color: var(--primary);
    text-decoration: none;
}

.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    color: var(--text-muted);
}

.auth-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

/* Dashboard Styles */
.dashboard-main, .tasks-main, .withdraw-main, .profile-main {
    padding: 2rem 0;
}

.welcome-banner {
    background: linear-gradient(135deg, var(--primary) 0%, #2c8c6b 100%);
    border-radius: 24px;
    padding: 2rem;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.welcome-text h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.streak-card {
    background: rgba(255,255,255,0.2);
    border-radius: 20px;
    padding: 1rem;
    text-align: center;
    min-width: 100px;
}

.streak-card i {
    font-size: 1.5rem;
    color: var(--accent);
}

.streak-card span {
    font-size: 1.5rem;
    font-weight: 800;
    display: block;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--card-white);
    border-radius: 20px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border: 1px solid var(--border);
}

.stat-card i {
    font-size: 2rem;
    color: var(--primary);
}

.stat-info {
    flex: 1;
}

.stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.stat-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-dark);
}

.quick-actions {
    background: var(--card-white);
    border-radius: 24px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.quick-actions h3 {
    margin-bottom: 1rem;
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.action-card {
    background: var(--gray-bg);
    border-radius: 16px;
    padding: 1.2rem;
    text-align: center;
    text-decoration: none;
    color: var(--text-dark);
    transition: 0.2s;
    cursor: pointer;
    border: 1px solid var(--border);
}

.action-card:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
}

.action-card i {
    font-size: 1.8rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.action-card span {
    display: block;
    font-weight: 600;
}

.action-card small {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.recent-activities {
    background: var(--card-white);
    border-radius: 24px;
    padding: 1.5rem;
}

.recent-activities h3 {
    margin-bottom: 1rem;
}

.view-all {
    display: inline-block;
    margin-top: 1rem;
    color: var(--primary);
    text-decoration: none;
}

/* Tasks Page */
.page-header {
    margin-bottom: 2rem;
}

.page-header h1 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.tasks-categories {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.category-btn {
    background: var(--gray-bg);
    border: 1px solid var(--border);
    padding: 0.6rem 1.2rem;
    border-radius: 40px;
    cursor: pointer;
    transition: 0.2s;
}

.category-btn.active, .category-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.tasks-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.task-card {
    background: var(--card-white);
    border-radius: 20px;
    padding: 1.5rem;
    border: 1px solid var(--border);
    transition: 0.2s;
}

.task-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.05);
}

.task-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.task-icon {
    font-size: 2rem;
    color: var(--primary);
}

.task-reward {
    background: var(--success);
    color: white;
    padding: 0.2rem 0.8rem;
    border-radius: 20px;
    font-weight: 600;
}

.task-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.task-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.task-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.task-status {
    font-size: 0.8rem;
    color: var(--danger);
}

.task-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.5rem 1.2rem;
    border-radius: 30px;
    cursor: pointer;
}

.task-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.task-btn.not-available {
    background: var(--danger);
    cursor: not-allowed;
}

.daily-challenge {
    background: var(--card-white);
    border-radius: 24px;
    padding: 1.5rem;
}

.daily-challenge h3 {
    margin-bottom: 1rem;
}

.challenge-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    background: var(--gray-bg);
    padding: 1.5rem;
    border-radius: 16px;
}

.progress-bar {
    width: 200px;
    height: 8px;
    background: var(--border);
    border-radius: 10px;
    overflow: hidden;
    margin: 0.5rem 0;
}

.progress-fill {
    height: 100%;
    background: var(--success);
    transition: width 0.3s;
}

.challenge-reward {
    background: var(--accent);
    padding: 0.5rem 1rem;
    border-radius: 30px;
    font-weight: 600;
}

/* Withdraw Page */
.withdraw-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

@media (max-width: 768px) {
    .withdraw-grid {
        grid-template-columns: 1fr;
    }
}

.withdraw-card, .withdrawal-history {
    background: var(--card-white);
    border-radius: 24px;
    padding: 1.5rem;
}

.balance-display {
    text-align: center;
    padding: 1.5rem;
    background: var(--primary-light);
    border-radius: 20px;
    margin-bottom: 1.5rem;
}

.balance-display h2 {
    font-size: 2.5rem;
    color: var(--primary);
}

.method-options {
    display: flex;
    gap: 1rem;
    margin: 1rem 0;
    flex-wrap: wrap;
}

.method-option {
    flex: 1;
    padding: 1rem;
    border: 2px solid var(--border);
    border-radius: 16px;
    text-align: center;
    cursor: pointer;
    transition: 0.2s;
}

.method-option.selected {
    border-color: var(--primary);
    background: var(--primary-light);
}

.method-option input {
    display: none;
}

.method-option i {
    font-size: 1.5rem;
    display: block;
    margin-bottom: 0.5rem;
}

.fee-info {
    background: var(--gray-bg);
    padding: 0.8rem;
    border-radius: 12px;
    margin: 1rem 0;
    font-size: 0.85rem;
}

/* Profile Page */
.profile-grid {
    display: grid;
    gap: 2rem;
}

.profile-card, .referral-card, .stats-card, .settings-card, .transactions-card {
    background: var(--card-white);
    border-radius: 24px;
    padding: 1.5rem;
}

.profile-card {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.profile-avatar i {
    font-size: 5rem;
    color: var(--primary);
}

.referral-stats {
    display: flex;
    gap: 2rem;
    margin: 1rem 0;
}

.referral-stats .stat {
    text-align: center;
}

.referral-stats .value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
    display: block;
}

.referral-link {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.referral-link input {
    flex: 1;
    padding: 0.6rem;
    border: 1px solid var(--border);
    border-radius: 12px;
}

.stats-list .stat-row {
    display: flex;
    justify-content: space-between;
    padding: 0.8rem 0;
    border-bottom: 1px solid var(--border);
}

.settings-card {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Game Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.6);
}

.modal-content {
    background-color: var(--card-white);
    margin: 5% auto;
    padding: 2rem;
    border-radius: 28px;
    width: 90%;
    max-width: 550px;
    text-align: center;
    position: relative;
}

.modal-content.small {
    max-width: 400px;
}

.close-modal {
    position: absolute;
    right: 1.5rem;
    top: 1rem;
    font-size: 1.8rem;
    cursor: pointer;
    color: var(--text-muted);
}

.game-board {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin: 1.5rem 0;
}

.card {
    aspect-ratio: 1;
    background: var(--primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    cursor: pointer;
    transition: 0.2s;
    color: white;
}

.card.flipped, .card.matched {
    background: var(--accent);
    cursor: default;
}

.card.matched {
    background: var(--success);
    opacity: 0.6;
}

.game-stats {
    display: flex;
    justify-content: space-between;
    margin: 1rem 0;
    font-weight: 600;
}

/* Table Styles */
.table-wrapper {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 0.8rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

th {
    background: var(--gray-bg);
    font-weight: 600;
}

.text-center {
    text-align: center;
}

/* Utility Classes */
.status-badge {
    display: inline-block;
    padding: 0.2rem 0.5rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
}

.status-completed {
    background: #e8f5e9;
    color: var(--success);
}

.status-pending {
    background: #fff3e0;
    color: var(--warning);
}

.status-failed {
    background: #ffebee;
    color: var(--danger);
}