.badges-page {
    width: 100%;
}

.intro-section {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 30px;
    text-align: center;
}

.intro-section p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
}

/* Category Tabs */
.category-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

.tab-btn {
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 10px 20px;
    color: var(--text-primary);
    cursor: pointer;
    font-size: 1em;
    font-weight: 500;
    transition: all 0.2s ease;
}

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

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

/* Badges Grid */
.badges-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.badge-card {
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.badge-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.badge-card:hover::before {
    opacity: 1;
}

.badge-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.2);
}

/* Difficulty badges */
.badge-card[data-difficulty="easy"]::after {
    content: '⭐';
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 1.2em;
}

.badge-card[data-difficulty="medium"]::after {
    content: '⭐⭐';
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 1em;
}

.badge-card[data-difficulty="hard"]::after {
    content: '⭐⭐⭐';
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 0.9em;
}

.badge-icon-large {
    font-size: 4em;
    margin-bottom: 15px;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

.badge-card h3 {
    color: var(--text-primary);
    margin: 10px 0;
    font-size: 1.3em;
    font-weight: 600;
}

.badge-description {
    color: var(--text-secondary);
    margin: 10px 0;
    font-size: 0.95em;
    line-height: 1.4;
}

.badge-requirement {
    margin-top: 15px;
    padding: 10px;
    background: var(--background-color);
    border-radius: 6px;
    font-size: 0.9em;
    color: var(--accent-green);
    font-weight: 500;
}

/* Tips Section */
.tips-section {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 25px;
    margin-top: 40px;
}

.tips-section h2 {
    color: var(--text-primary);
    margin-top: 0;
    margin-bottom: 20px;
}

.tips-section ul {
    list-style: none;
    padding: 0;
}

.tips-section li {
    color: var(--text-secondary);
    margin-bottom: 15px;
    padding-left: 25px;
    position: relative;
    line-height: 1.6;
}

.tips-section li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

.tips-section strong {
    color: var(--text-primary);
}

/* Responsive Design */
@media (max-width: 768px) {
    .badges-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 15px;
    }

    .badge-card {
        padding: 20px;
    }

    .badge-icon-large {
        font-size: 3em;
    }

    .badge-card h3 {
        font-size: 1.1em;
    }

    .category-tabs {
        justify-content: stretch;
    }

    .tab-btn {
        flex: 1;
        min-width: 80px;
        padding: 8px 12px;
        font-size: 0.9em;
    }
}

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

    .badge-card {
        padding: 15px;
    }

    .badge-icon-large {
        font-size: 2.5em;
    }
}

/* Dark mode specific adjustments */
:root[data-theme="dark"] .badge-card:hover {
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

:root[data-theme="dark"] .badge-requirement {
    background: rgba(255, 255, 255, 0.05);
}
