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

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    padding: 20px;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.search-section {
    margin-bottom: 30px;
}

.search-wrapper {
    position: relative;
    width: 100%;
}

#searchInput {
    width: 100%;
    padding: 12px 40px 12px 12px;
    font-size: 16px;
    border: 2px solid #ddd;
    border-radius: 6px;
}

.clear-search {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 20px;
    color: #999;
    cursor: pointer;
    padding: 5px;
    line-height: 1;
}

.clear-search:hover {
    color: #666;
}

.content-wrapper {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 30px;
}

.categories-section {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.categories-section h2,
.qa-section h2 {
    margin-bottom: 20px;
    color: #333;
}

#categoriesList {
    list-style: none;
}

.category-item {
    padding: 10px;
    cursor: pointer;
    border-radius: 4px;
    margin-bottom: 5px;
    transition: background-color 0.2s;
}

.category-item:hover {
    background-color: #f0f0f0;
}

.category-item.active {
    background-color: #e0e0e0;
    font-weight: bold;
}

.qa-section {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.qa-item {
    margin-bottom: 20px;
    padding: 15px;
    border: 1px solid #eee;
    border-radius: 6px;
}

.qa-item h3 {
    color: #2c3e50;
    margin-bottom: 10px;
}

.qa-item p {
    color: #666;
}

.hidden {
    display: none;
}

.qa-item.loading {
    text-align: center;
    padding: 20px;
    color: #666;
    font-style: italic;
    background-color: #f9f9f9;
    border: 1px dashed #ddd;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
}
