html {
    overflow-x: hidden;
}

body {
    background-color: #f8f5f0;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    margin: 0;
    padding: 0;
    color: #1f2933;
    overflow-x: hidden;
}

.bt-container {
    max-width: 800px;
    margin: 20px auto;
    padding: 0 16px 40px;
}

.bt-header {
    text-align: center;
    margin-bottom: 24px;
}

.bt-header h1 {
    font-size: 2em;
    margin: 0;
}

.bt-header .subtitle {
    color: #6b7280;
    margin-top: 4px;
}

.bt-controls {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 20px;
    align-items: center;
    max-width: 100%;
}

.bt-controls select,
.bt-controls button {
    padding: 8px 14px;
    border-radius: 6px;
    border: 1px solid #d1d5db;
    font-size: 0.95rem;
    background: #fff;
    cursor: pointer;
    max-width: 100%;
}

.bt-controls select {
    /* Constrain to viewport even when the longest option label
       (e.g. a long book title) is wider than the screen. */
    width: 100%;
    box-sizing: border-box;
}

@media (min-width: 540px) {
    .bt-controls select { width: auto; max-width: 320px; }
}

.bt-controls button {
    background: #2563eb;
    color: #fff;
    border: none;
    font-weight: 600;
}

.bt-controls button:hover {
    background: #1d4ed8;
}

.bt-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.bt-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.bt-category {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #6b7280;
    background: #f3f4f6;
    padding: 3px 8px;
    border-radius: 4px;
}

.bt-difficulty {
    font-size: 0.8rem;
    color: #9ca3af;
}

.bt-question {
    font-size: 1.1rem;
    line-height: 1.5;
    margin-bottom: 12px;
}

.bt-reveal-btn {
    background: #f3f4f6;
    border: 1px solid #d1d5db;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #374151;
}

.bt-reveal-btn:hover {
    background: #e5e7eb;
}

.bt-answer {
    margin-top: 12px;
    padding: 12px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    line-height: 1.5;
    display: none;
}

.bt-answer.visible {
    display: block;
}

.bt-source {
    font-size: 0.8rem;
    color: #9ca3af;
    margin-top: 8px;
}

.bt-empty {
    text-align: center;
    padding: 40px 20px;
    color: #9ca3af;
}

.bt-pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.bt-pagination button {
    padding: 8px 16px;
    border-radius: 6px;
    border: 1px solid #d1d5db;
    background: #fff;
    cursor: pointer;
    font-size: 0.9rem;
}

.bt-pagination button:hover {
    background: #f3f4f6;
}

.bt-pagination button:disabled {
    opacity: 0.4;
    cursor: default;
}

.bt-pagination .page-info {
    display: flex;
    align-items: center;
    font-size: 0.9rem;
    color: #6b7280;
}
