body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 0;
    background: #f4f7f6;
    color: #333;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
}

header {
    margin-top: 50px;
    text-align: center;
}

header h1 {
    font-size: 2.2rem;
    color: #2c3e50;
    margin-bottom: 5px;
}

header p {
    color: #7f8c8d;
    margin-bottom: 30px;
}

.container {
    width: 95%;
    max-width: 900px;
    padding-bottom: 50px;
}

.category {
    margin-bottom: 35px;
}

.category h2 {
    font-size: 1.4rem;
    padding-left: 10px;
    border-left: 5px solid #bdc3c7;
    margin-bottom: 20px;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
}

.card {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 80px;
    border-radius: 12px;
    text-decoration: none;
    color: white;
    font-weight: bold;
    font-size: 1.1rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
    text-align: center;
    padding: 10px;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.15);
    opacity: 0.9;
}

/* Градиенты по типам контента */

/* Игры: Насыщенный сине-фиолетовый */
.game {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* Кубики: Энергичный оранжево-красный */
.dice {
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 99%, #fecfef 100%);
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

/* Инструменты: Свежий зеленый/бирюзовый */
.tool {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    color: #1e5d34; /* Темный текст для контраста на светлом фоне */
}

/* Прочее: Деловой синий */
.other {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

/* Особенная кнопка (Block Scheme): Золотисто-бронзовый */
.special {
    background: linear-gradient(135deg, #f6d365 0%, #fda085 100%);
}

/* Мобильная адаптация */
@media (max-width: 480px) {
    .grid {
        grid-template-columns: 1fr 1fr;
    }
    .card {
        font-size: 0.95rem;
        height: 70px;
    }
}
