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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: #f5f5f5;
    color: #333;
}

.container { max-width: 900px; margin: 0 auto; padding: 20px; }

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

header h1 { font-size: 1.5rem; }

.status { display: flex; align-items: center; gap: 12px; }

#toggle-btn {
    padding: 8px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    color: #fff;
    background: #e74c3c;
}

#toggle-btn.active { background: #27ae60; }

.stats { margin-bottom: 20px; }

.stat-card {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.stat-card h3 { font-size: 0.9rem; color: #888; margin-bottom: 8px; }
.stat-card span { font-size: 2rem; font-weight: 700; }

.settings-section {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.settings-section h2 { margin-bottom: 14px; }

.setting-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.setting-row label {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 100px;
    font-weight: 600;
}

.setting-row input[type="text"] {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 0.9rem;
}

.conversations { margin-bottom: 20px; }
.conversations h2 { margin-bottom: 12px; }

.conv-item {
    background: #fff;
    padding: 14px 20px;
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.conv-item:hover { background: #f0f0f0; }

.detail { margin-top: 20px; }
.detail h2 { margin-bottom: 12px; }
.hidden { display: none; }

.message {
    padding: 10px 14px;
    margin-bottom: 6px;
    border-radius: 8px;
    max-width: 80%;
}

.message.user {
    background: #e3f2fd;
    margin-left: auto;
    text-align: right;
}

.message.bot {
    background: #fff;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}
