* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #ffffff;
    min-height: 100vh;
    color: #1f2937;
}

.header {
    text-align: center;
    padding: 20px 20px 10px;
}

.logo {
    font-size: 28px;
    font-weight: bold;
    background: linear-gradient(135deg, #064e3b 0%, #059669 50%, #10b981 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 1px;
}

.main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.search-section {
    background: #eff6ff;
    padding: 12px 20px;
    margin-bottom: 18px;
}

.search-row {
    margin-bottom: 8px;
}

.search-row:last-child {
    margin-bottom: 0;
}

.search-form {
    display: flex;
    gap: 10px;
    max-width: 500px;
    margin: 0 auto;
}

.search-input {
    flex: 1;
    height: 40px;
    padding: 0 16px;
    border-radius: 4px;
    font-size: 15px;
    transition: all 0.2s;
    outline: none;
    background: #ffffff;
}

.search-btn {
    height: 40px;
    padding: 0 28px;
    background: #3b82f6;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 600;
}

.search-btn:hover {
    background: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.sites-section {
    background: #f0f7ff;
    padding: 10px 15px;
    margin-bottom: 15px;
}

.section-title {
    font-size: 18px;
    font-weight: 600;
    color: #1e40af;
    margin-bottom: 18px;
    padding-bottom: 12px;
}

.sites-list {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 8px;
}

.site-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    text-decoration: none;
    color: #333333;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.2s;
    min-height: 40px;
}

.site-item:hover {
    color: #3b82f6;
    transform: translateY(-2px);
}

.categories-section {
    background: #f0f9ff;
    padding: 20px;
    margin-bottom: 24px;
}

.category-block {
    margin-bottom: 20px;
}

.category-block:last-child {
    margin-bottom: 0;
}

.category-title {
    font-size: 17px;
    font-weight: 700;
    color: #1e40af;
    margin-bottom: 12px;
    padding-left: 14px;
    border-left: 3px solid #3b82f6;
}

.category-title a {
    color: #1e40af;
    text-decoration: none;
}

.category-title a:hover {
    text-decoration: underline;
    color: #2563eb;
}

.category-links {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    padding-left: 11px;
}

.category-links a {
    text-decoration: none;
    color: #3b82f6;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.2s;
}

.category-links a:hover {
    color: #2563eb;
    text-decoration: underline;
    font-weight: 600;
}

.footer {
    text-align: center;
    padding: 30px 20px;
    color: #6b7280;
    font-size: 14px;
    margin-top: 30px;
    background: #f9fafb;
}

.friend-links {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e5e7eb;
}

.friend-links-title {
    font-size: 15px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 12px;
}

.friend-links-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.friend-links-list a {
    text-decoration: none;
    color: #6b7280;
    font-size: 14px;
    transition: color 0.2s;
}

.friend-links-list a:hover {
    color: #374151;
    text-decoration: underline;
}

.footer-category {
    background: #dbeafe;
    padding: 20px;
    margin-bottom: 24px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: #1e40af;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    padding-bottom: 10px;
    transition: color 0.2s;
}

.back-link:hover {
    color: #2563eb;
}

.back-link svg {
    margin-right: 6px;
    width: 14px;
    height: 14px;
}

.category-sites-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.category-site-item {
    display: inline-flex;
    align-items: center;
    padding: 10px 18px;
    background: #ffffff;
    border-radius: 4px;
    text-decoration: none;
    color: #3b82f6;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.2s;
}

.category-site-item:hover {
    background: #3b82f6;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

@media (max-width: 576px) {
    .logo {
        font-size: 28px;
    }

    .search-section {
        padding: 12px 16px;
    }

    .search-row {
        width: 100%;
        margin-bottom: 10px;
    }

    .search-row:last-child {
        margin-bottom: 0;
    }

    .search-form {
        flex-direction: row;
    }

    .search-input {
        height: 40px;
    }

    .search-btn {
        height: 40px;
    }

    .sites-list {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .category-links,
    .category-sites-list {
        gap: 10px;
    }

    .site-item,
    .category-site-item {
        padding: 7px 12px;
        font-size: 13px;
    }

    .category-links a {
        font-size: 13px;
    }
}
