/* 利用履歴・共通テーブルスタイル */

/* 件数表示 */
.usage-summary {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 8px;
    text-align: right;
}

/* テーブルコンテナ */
.usage-table-improved,
.feedback-table-improved {
    margin-top: 0.5rem;
    overflow-x: auto;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border: 1px solid #e0e0e0;
}

.usage-table-improved table,
.feedback-table-improved table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    table-layout: fixed;
}

/* ヘッダー */
.usage-table-improved th,
.feedback-table-improved th {
    background: #0891b2;
    padding: 10px 8px;
    text-align: left;
    font-weight: 600;
    color: white;
    border-bottom: 2px solid #067a94;
    cursor: pointer;
    white-space: nowrap;
    font-size: 0.8rem;
}

.usage-table-improved th:hover,
.feedback-table-improved th:hover {
    background: #067a94;
}

/* セル */
.usage-table-improved td,
.feedback-table-improved td {
    padding: 8px;
    border-bottom: 1px solid #eee;
    vertical-align: top;
    line-height: 1.5;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* 偶数行 */
.usage-table-improved tr:nth-child(even),
.feedback-table-improved tr:nth-child(even) {
    background-color: #fafafa;
}

/* ホバー */
.usage-table-improved tr:hover,
.feedback-table-improved tr:hover {
    background-color: #e8f4f8;
}

/* カラム幅クラス */
.col-app { width: 60px; white-space: nowrap; }
.col-type { width: 55px; white-space: nowrap; }
.col-id { width: 35px; text-align: center; white-space: nowrap; }
.col-category { width: 12%; }
.col-question { width: 15%; }
.col-answer { width: auto; }
.col-date { width: 110px; white-space: nowrap; }
.col-reason { width: 10%; }
.col-content { width: 15%; }

/* セル内容 */
.path-cell {
    color: #666;
    font-size: 0.8rem;
    overflow: hidden;
    word-break: break-word;
}

.question-cell {
    overflow: hidden;
    word-break: break-word;
}

.answer-cell {
    overflow: hidden;
    word-break: break-word;
}

.reason-cell {
    overflow: hidden;
    word-break: break-word;
}

.content-cell {
    overflow: hidden;
    word-break: break-word;
}
}

.question-cell {
    font-weight: 500;
    overflow: hidden;
    word-break: break-word;
}

.answer-cell {
    color: #444;
    font-size: 0.82rem;
    overflow: hidden;
    word-break: break-word;
}

.reason-cell,
.content-cell {
    font-size: 0.82rem;
    overflow: hidden;
    word-break: break-word;
}

.date-cell {
    color: #888;
    font-size: 0.8rem;
    white-space: nowrap;
}

/* バッジ共通 */
.app-badge {
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.72rem;
    font-weight: 600;
    display: inline-block;
    white-space: nowrap;
}

.app-chat { background: #1976d2; color: white; }
.app-bot { background: #388e3c; color: white; }

.type-badge {
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 0.72rem;
    font-weight: 600;
    display: inline-block;
    white-space: nowrap;
}

.type-faq { background: #1976d2; color: white; }
.type-category { background: #f57c00; color: white; }
.type-resolved { background: #10b981; color: white; }
.type-not-resolved { background: #ef4444; color: white; }
.type-not-resolved-detail { background: #dc2626; color: white; }
.type-detail { background: #f87171; color: white; font-size: 10px; margin-top: 2px; }
.type-form { background: #f59e0b; color: white; }

/* 日付フィルター */
.date-filter {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 0.8rem 1rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 1rem;
}

.date-filter input, .date-filter select {
    padding: 6px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.9rem;
}

.btn-filter {
    background: #0891b2;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
}

.btn-filter:hover { background: #0e7490; }
