/* SBJ 台選びアシスタント - モバイル対応CSS */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #1a1a2e;
    color: #eee;
    line-height: 1.5;
    min-height: 100vh;
}

.container {
    max-width: 480px;
    margin: 0 auto;
    padding: 10px;
}

/* バージョン表示（右上） */
.version-info {
    text-align: right;
    font-size: 0.7em;
    color: #555;
    padding: 2px 5px;
}

/* ヘッダー */
header {
    text-align: center;
    padding: 15px 0;
    border-bottom: 1px solid #333;
    margin-bottom: 15px;
}

header h1 {
    font-size: 1.4em;
    font-weight: 600;
    color: #fff;
}

/* タイトルの「本日」を大きく、日付を小さく */
.title-main {
    font-size: 1.2em;
    font-weight: 700;
}

.title-date {
    font-size: 0.85em;
    color: #888;
    margin-top: 2px;
}

.back-link {
    display: inline-block;
    color: #70a1ff;
    text-decoration: none;
    font-size: 0.9em;
    margin-bottom: 5px;
}

.update-info {
    font-size: 0.8em;
    color: #888;
    margin-top: 5px;
}

.refresh-btn {
    background: #333;
    color: #fff;
    border: none;
    padding: 5px 12px;
    border-radius: 4px;
    margin-left: 10px;
    cursor: pointer;
}

.refresh-btn:active {
    background: #444;
}

/* モードバッジ（営業中/閉店後） */
.mode-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
    margin-top: 5px;
}

.mode-badge.result {
    background: #4a3f70;
    color: #c9b8ff;
}

.mode-badge.collecting {
    background: #5a4a20;
    color: #ffd700;
    animation: pulse 1.5s ease-in-out infinite;
}

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

.mode-badge.realtime {
    background: #1e5128;
    color: #a8e6a3;
}

/* リアルタイム更新バー */
.realtime-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
    padding: 8px;
    background: #1e1e3a;
    border-radius: 8px;
}

.realtime-status {
    font-size: 0.85em;
    color: #888;
}

.realtime-status.loading {
    color: #ffd700;
}

.realtime-status.success {
    color: #a8e6a3;
}

.realtime-status.error {
    color: #ff6b6b;
}

.refresh-btn {
    padding: 6px 12px;
    background: #3a3a5c;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 0.85em;
    cursor: pointer;
    transition: background 0.2s;
}

.refresh-btn:hover {
    background: #4a4a7c;
}

.refresh-btn:active {
    background: #2a2a4c;
}

/* 機種リスト */
.machine-list h2,
.store-list h2 {
    font-size: 1em;
    color: #888;
    margin-bottom: 10px;
}

.machine-card {
    display: flex;
    align-items: center;
    gap: 15px;
    background: #252541;
    border-radius: 8px;
    padding: 20px 15px;
    margin-bottom: 10px;
    text-decoration: none;
    color: #fff;
    transition: background 0.2s;
}

.machine-card:active {
    background: #333355;
}

.machine-icon {
    font-size: 2em;
}

.machine-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.machine-name {
    font-size: 1.2em;
    font-weight: 600;
}

.machine-detail {
    font-size: 0.85em;
    color: #888;
    margin-top: 2px;
}

.arrow {
    font-size: 1.5em;
    color: #555;
}

/* 店舗リスト */
.store-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #252541;
    border-radius: 8px;
    padding: 18px 15px;
    margin-bottom: 10px;
    text-decoration: none;
    color: #fff;
    transition: background 0.2s;
}

.store-card:active {
    background: #333355;
}

.store-name {
    font-size: 1.1em;
    font-weight: 500;
}

.unit-count {
    font-size: 0.9em;
    color: #888;
}

/* 推奨セクション */
.recommendations {
    margin-bottom: 15px;
}

.recommendations h2 {
    font-size: 1em;
    color: #ffa502;
    margin-bottom: 8px;
}

.recommendations.top h2::before {
    content: none;
}

.recommendations.other h2 {
    color: #888;
}

.recommendations.other h2::before {
    content: "";
}

/* 台カード */
.unit-card {
    background: #252541;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 10px;
    display: block;
}

.unit-card:active {
    background: #2a2a4a;
}

.unit-card * {
    line-height: 1.4;
}

.unit-card.running {
    opacity: 0.6;
}

.unit-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    flex-wrap: nowrap;
    overflow: hidden;
}

.unit-id {
    font-size: 1.3em;
    font-weight: 700;
    color: #fff;
}

.rank-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 4px;
    font-size: 0.9em;
    font-weight: 600;
    color: #fff;
}

.rank-badge.small {
    padding: 1px 6px;
    font-size: 0.8em;
}

.stars {
    color: #ffd700;
    font-size: 0.9em;
}

.unit-status {
    margin: 5px 0;
}

.status {
    font-size: 0.9em;
    color: #2ed573;
}

.status.running {
    color: #ff6b6b;
}

.unit-today {
    font-size: 0.85em;
    color: #70a1ff;
}

.unit-note {
    font-size: 0.8em;
    color: #888;
    margin-top: 3px;
}

/* コンパクトカード */
.unit-card.compact {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
}

.unit-card.compact .unit-id {
    font-size: 1.1em;
    min-width: 50px;
}

.unit-card.compact .status {
    flex: 1;
    font-size: 0.85em;
}

.unit-card.compact .art-info {
    font-size: 0.8em;
    color: #70a1ff;
}

/* 推奨なし */
.no-recommendation {
    text-align: center;
    padding: 30px;
    background: #252541;
    border-radius: 8px;
    margin-bottom: 20px;
}

.no-recommendation p {
    font-size: 1.1em;
    color: #888;
}

.no-recommendation .sub {
    font-size: 0.9em;
    color: #666;
    margin-top: 5px;
}

/* 本日の傾向セクション */
.today-trend {
    background: #1e1e3a;
    border-radius: 10px;
    padding: 15px;
    margin-top: 20px;
}

.today-trend h2 {
    font-size: 1em;
    color: #888;
    margin-bottom: 10px;
}

.trend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 0;
    flex-wrap: wrap;
}

.trend-item.good .trend-label {
    color: #2ed573;
}

.trend-item.bad .trend-label {
    color: #ff6b6b;
}

.trend-label {
    font-size: 0.9em;
    font-weight: 600;
}

.trend-store {
    color: #70a1ff;
    text-decoration: underline;
    font-size: 0.9em;
}

/* フッター */
footer {
    text-align: center;
    padding: 20px 0;
    color: #666;
    font-size: 0.8em;
}

.api-link {
    color: #555;
    text-decoration: none;
}

/* ランク別スタイル（左カラーライン 3px） */
.unit-card.rank-s {
    background: #252541;
    border-left: 3px solid #ff6b6b;
}

.unit-card.rank-a {
    background: #252541;
    border-left: 3px solid #ffa502;
}

.unit-card.rank-b {
    background: #252541;
    border-left: 3px solid #2ed573;
}

.unit-card.rank-c {
    background: #252541;
    border-left: 3px solid #70a1ff;
}

.unit-card.rank-d {
    background: #252541;
    border-left: 3px solid #747d8c;
}

/* スクレイピングボタン */
.scrape-btn {
    background: #ff6b6b;
    color: #fff;
    border: none;
    padding: 5px 12px;
    border-radius: 4px;
    margin-left: 5px;
    cursor: pointer;
    font-weight: 600;
}

.scrape-btn:active {
    background: #ee5a5a;
}

.scrape-btn:disabled {
    background: #555;
    cursor: not-allowed;
}

/* ローディングオーバーレイ */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(26, 26, 46, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.loading-overlay.hidden {
    display: none;
}

.loading-content {
    text-align: center;
    padding: 30px;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #333;
    border-top-color: #ff6b6b;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-text {
    font-size: 1.3em;
    color: #fff;
    margin-bottom: 20px;
}

.loading-text::after {
    content: '';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
    0% { content: ''; }
    25% { content: '.'; }
    50% { content: '..'; }
    75% { content: '...'; }
    100% { content: ''; }
}

.loading-progress {
    max-width: 250px;
    margin: 0 auto;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #333;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff6b6b, #ffa502);
    width: 0;
    transition: width 0.3s ease;
}

.progress-time {
    font-size: 1.5em;
    color: #ffa502;
    font-weight: 700;
}

.loading-hint {
    font-size: 0.85em;
    color: #888;
    margin-top: 15px;
}

/* キャッシュバッジ */
.cache-badge {
    background: #2ed573;
    color: #000;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75em;
    font-weight: 600;
    margin-left: 8px;
}

.data-source {
    color: #888;
    font-size: 0.85em;
}

.data-source.no-realtime {
    color: #ff6b6b;
    font-size: 0.75em;
}

.data-age {
    font-size: 0.85em;
    color: #666;
}

.data-age.stale {
    color: #ff6b6b;
}

/* ソース別バッジカラー */
.cache-badge.github {
    background: #2ed573;
    color: #000;
}

.cache-badge.gas {
    background: #70a1ff;
    color: #000;
}

.cache-badge.unknown {
    background: #666;
    color: #fff;
}

/* ボタンヒント */
.button-hint {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 5px;
    font-size: 0.7em;
    color: #666;
}

.hint-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* アクションボタン */
.action-buttons {
    margin-top: 8px;
}

/* スコア表示 */
.score {
    font-size: 0.85em;
    color: #888;
    margin-left: auto;
}

/* 展開アイコン */
.expand-icon {
    color: #555;
    font-size: 0.8em;
    margin-left: 8px;
    transition: transform 0.2s;
}

.expand-icon.small {
    font-size: 0.7em;
}

/* 本日ART表示 */
.today-art {
    font-size: 0.85em;
    color: #70a1ff;
    margin-left: 10px;
}

/* 詳細セクション */
.unit-details {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #333;
}

.unit-details.hidden {
    display: none;
}

/* 推奨理由セクション */
.reasons-section {
    margin-bottom: 12px;
}

.section-title {
    font-size: 0.8em;
    color: #ffa502;
    margin-bottom: 6px;
    font-weight: 600;
}

.reason-item {
    font-size: 0.85em;
    color: #ddd;
    padding: 4px 0;
    padding-left: 12px;
    border-left: 2px solid #ffa502;
    margin-bottom: 4px;
    background: rgba(255, 165, 2, 0.05);
}

.reason-item.small {
    font-size: 0.8em;
    padding: 3px 0 3px 10px;
}

/* 統計セクション */
.stats-section {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    padding: 10px;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    font-size: 0.85em;
}

.stat-label {
    color: #888;
}

.stat-value {
    color: #fff;
    font-weight: 600;
}

.stat-value.plus {
    color: #2ed573;
}

.stat-value.minus {
    color: #ff6b6b;
}

/* コンパクトカード用 */
.compact-header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.stats-row {
    display: flex;
    gap: 15px;
    font-size: 0.8em;
    color: #888;
    margin-top: 8px;
}

/* 当日データサマリー */
.today-summary {
    margin: 8px 0;
    padding: 8px 10px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
}

.today-stats {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-item .label {
    font-size: 0.7em;
    color: #888;
}

.stat-item .value {
    font-size: 1em;
    font-weight: 600;
    color: #fff;
}

.stat-item.highlight .value {
    color: #ffa502;
}

.no-data {
    font-size: 0.9em;
    color: #2ed573;
    font-weight: 500;
}

/* 未稼働表示 */
.no-today-data {
    font-size: 0.9em;
    color: #888;
    font-style: italic;
}

/* 推奨理由プレビュー */
.reasons-preview {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 8px;
    margin-top: 6px;
    background: rgba(255, 165, 2, 0.08);
    border-radius: 6px;
}

.reason-icon {
    font-size: 0.9em;
    flex-shrink: 0;
}

.reason-text {
    font-size: 0.8em;
    color: #ffa502;
    flex: 1;
}

.reason-more {
    font-size: 0.7em;
    color: #888;
    flex-shrink: 0;
}

/* 空き状態 */
.status.available {
    color: #2ed573;
    font-weight: 600;
}

/* 遊技中状態 */
.status.playing {
    color: #ff6b6b;
    font-weight: 600;
}

.unit-card.available {
    background: rgba(46, 213, 115, 0.1);
}

.unit-card.playing {
    background: rgba(255, 107, 107, 0.1);
    opacity: 0.7;
}

/* コンパクト用ゲーム数表示 */
.games-info {
    font-size: 0.8em;
    color: #888;
}

/* コンパクト用当日統計 */
.compact-stats {
    display: flex;
    gap: 10px;
    font-size: 0.8em;
    color: #aaa;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

/* ランキングボタン */
.ranking-section {
    margin-bottom: 20px;
}

.ranking-button {
    display: flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(135deg, #ffa502, #ff6b6b);
    border-radius: 10px;
    padding: 16px 18px;
    text-decoration: none;
    color: #fff;
    font-weight: 600;
    transition: transform 0.2s;
}

.ranking-button:active {
    transform: scale(0.98);
}

.ranking-icon {
    font-size: 1.5em;
}

.ranking-text {
    flex: 1;
    font-size: 1.1em;
}

/* ランキング番号 */
.ranking-num {
    font-size: 0.9em;
    font-weight: 700;
    color: #ffa502;
    min-width: 28px;
}

/* 店舗タグ */
.unit-store {
    font-size: 0.85em;
    color: #70a1ff;
    margin: 4px 0;
    line-height: 1.5;
}

.unit-store a {
    color: #70a1ff;
    text-decoration: none;
}

.store-tag {
    font-size: 0.75em;
    background: #333;
    padding: 2px 6px;
    border-radius: 3px;
    color: #aaa;
}

/* 機種ラベル */
.machine-label {
    font-size: 0.9em;
    color: #ffa502;
    margin-top: 3px;
}

/* 最終当たり時間 */
.last-hit {
    font-size: 0.8em;
    color: #70a1ff;
    margin-left: 10px;
}

/* 時間情報 */
.time-info {
    font-size: 0.8em;
    color: #888;
    margin-top: 6px;
}

.time-info.small {
    font-size: 0.75em;
    margin-top: 4px;
}

/* 確率情報（コンパクト） */
.prob-info {
    font-size: 0.75em;
    color: #ffa502;
    font-weight: 600;
}

/* フッターリンク */
.footer-link {
    color: #70a1ff;
    text-decoration: none;
    margin: 0 5px;
}

/* 非表示テキスト */
.hidden-text {
    color: #1a1a2e;
    font-size: 1px;
}

/* サブタイトル */
.subtitle {
    font-size: 0.9em;
    color: #888;
    margin-top: 5px;
}

/* ===== 空き状況表示 ===== */

/* ヘッダーの空き状況サマリ */
.availability-summary {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 8px;
    font-size: 0.9em;
}

.avail-empty {
    color: #2ed573;
    font-weight: 600;
}

.avail-playing {
    color: #ff6b6b;
    font-weight: 600;
}

/* 空き状況バッジ */
.avail-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: 700;
}

.avail-badge.empty {
    background: #2ed573;
    color: #000;
}

.avail-badge.playing {
    background: #ff6b6b;
    color: #fff;
}

/* コンパクト用バッジ */
.avail-badge-sm {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.75em;
    font-weight: 700;
}

.avail-badge-sm.empty {
    background: #2ed573;
    color: #000;
}

.avail-badge-sm.playing {
    background: #ff6b6b;
    color: #fff;
}

/* カードの空き状況スタイル */
.avail-card-empty {
    background: rgba(46, 213, 115, 0.15);
    border-left-color: #2ed573 !important;
}

.avail-card-playing {
    background: rgba(255, 107, 107, 0.1);
    opacity: 0.75;
}

/* ===== 本日の状況セクション ===== */

.today-section {
    margin: 10px 0;
    padding: 10px;
    background: rgba(0, 0, 0, 0.25);
    border-radius: 8px;
    border-left: 3px solid #70a1ff;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
}

.section-icon {
    font-size: 0.9em;
}

.section-label {
    font-size: 0.85em;
    color: #aaa;
    font-weight: 600;
}

/* 本日の統計グリッド */
.today-stats-grid {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.stat-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    min-width: 60px;
}

.stat-box .stat-label {
    font-size: 0.6em;
    color: #666;
    margin-bottom: 1px;
}

.stat-box .stat-value {
    font-size: 1.3em;
    font-weight: 800;
    color: #fff;
}

.stat-box.highlight {
    background: rgba(255, 165, 2, 0.2);
}

.stat-box.highlight .stat-value {
    color: #ffa502;
}

.stat-box.excellent {
    background: rgba(46, 213, 115, 0.2);
}

.stat-box.excellent .stat-value {
    color: #2ed573;
}

.stat-box.good {
    background: rgba(112, 161, 255, 0.2);
}

.stat-box.good .stat-value {
    color: #70a1ff;
}

.stat-box.bad {
    background: rgba(255, 107, 107, 0.2);
}

.stat-box.bad .stat-value {
    color: #ff6b6b;
}

/* 時間レンジ */
.time-range {
    font-size: 0.8em;
    color: #70a1ff;
    margin-top: 8px;
}

/* データなし（本日） */
.no-data-today {
    font-size: 0.9em;
    color: #888;
    padding: 8px 0;
}

.target-badge {
    display: inline-block;
    background: #2ed573;
    color: #000;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: 700;
    margin-right: 6px;
}

/* ===== 過去7日間セクション ===== */

.history-section {
    margin: 10px 0;
    padding: 10px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    border-left: 3px solid #ffa502;
}

.base-rank {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75em;
    font-weight: 700;
    color: #fff;
    margin-left: auto;
}

.history-stats {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    font-size: 0.85em;
}

.hist-item {
    color: #aaa;
}

.hist-item strong {
    color: #fff;
    font-weight: 700;
}

.hist-item.plus {
    color: #2ed573;
}

.hist-item.plus strong {
    color: #2ed573;
}

.hist-item.minus {
    color: #ff6b6b;
}

.hist-item.minus strong {
    color: #ff6b6b;
}

/* ===== コンパクトカード改善 ===== */

.compact-today {
    display: flex;
    gap: 8px;
    flex: 1;
    justify-content: flex-end;
    font-size: 0.8em;
}

.compact-today.no-data {
    color: #666;
}

/* 確率の色分け（コンパクト用） */
.prob-info.excellent {
    color: #2ed573;
}

.prob-info.good {
    color: #70a1ff;
}

.prob-info.bad {
    color: #ff6b6b;
}

/* 詳細セクション（コンパクト） */
.compact-detail-section {
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid #333;
}

.compact-detail-section:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.detail-label {
    font-size: 0.75em;
    color: #ffa502;
    font-weight: 600;
    margin-bottom: 4px;
}

/* 理由セクション（コンパクト） */
.reasons-section.compact {
    margin-top: 8px;
}

/* プラス/マイナス色 */
strong.plus {
    color: #2ed573;
}

strong.minus {
    color: #ff6b6b;
}

/* ===== コンパクトセクション ===== */

.today-section.compact,
.history-section.compact {
    margin: 6px 0;
    padding: 8px;
}

.today-stats-grid.compact {
    gap: 6px;
}

.today-stats-grid.compact .stat-box {
    padding: 4px 10px;
    min-width: 50px;
}

.today-stats-grid.compact .stat-box .stat-value {
    font-size: 1em;
}

/* ===== 新UI: 推奨ページ改善 ===== */

/* ランク説明 */
.rank-legend {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 15px;
    padding: 10px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    margin-bottom: 15px;
    font-size: 0.75em;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #aaa;
}

.rank-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

/* メインヘッダー */
.unit-main-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.unit-id-large {
    font-size: 1.5em;
    font-weight: 800;
    color: #fff;
    min-width: 70px;
}

.unit-id-link {
    text-decoration: underline;
    text-underline-offset: 3px;
    color: #fff;
}

.unit-id-link:hover {
    color: #70a1ff;
}

.avail-badge-lg {
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.9em;
    font-weight: 700;
}

.avail-badge-lg.empty {
    background: #2ed573;
    color: #000;
}

.avail-badge-lg.playing {
    background: #ff6b6b;
    color: #fff;
}

.avail-badge-lg.closed {
    background: #444;
    color: #888;
}

/* 営業時間外通知 */
.closed-notice {
    text-align: center;
    padding: 8px;
    background: #333;
    border-radius: 6px;
    color: #888;
    font-size: 0.85em;
    margin-top: 8px;
}

.rank-badge-lg {
    padding: 4px 14px;
    border-radius: 6px;
    font-size: 1.1em;
    font-weight: 800;
    color: #fff;
    margin-left: auto;
}

/* 本日データ横並び */
.today-data-row {
    display: flex;
    gap: 8px;
    padding: 10px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    margin-bottom: 8px;
}

.data-cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    min-width: 55px;
}

.data-cell .data-label {
    font-size: 0.55em;
    color: #666;
    margin-bottom: 1px;
    text-transform: uppercase;
}

.data-cell .data-value {
    font-size: 1.2em;
    font-weight: 800;
    color: #fff;
}

.data-cell.highlight {
    background: rgba(255, 165, 2, 0.2);
}

.data-cell.highlight .data-value {
    color: #ffa502;
}

.data-cell.excellent {
    background: rgba(46, 213, 115, 0.2);
}

.data-cell.excellent .data-value {
    color: #2ed573;
}

.data-cell.good {
    background: rgba(112, 161, 255, 0.2);
}

.data-cell.good .data-value {
    color: #70a1ff;
}

.data-cell.bad {
    background: rgba(255, 107, 107, 0.2);
}

.data-cell.bad .data-value {
    color: #ff6b6b;
}

.data-cell.warn {
    background: rgba(255, 165, 2, 0.15);
}

.data-cell.warn .data-value {
    color: #ffa502;
}

/* 差枚見込み */
.data-cell.profit-high {
    background: rgba(46, 213, 115, 0.3);
}

.data-cell.profit-high .data-value {
    color: #2ed573;
    font-size: 1.1em;
}

.data-cell.profit-mid {
    background: rgba(112, 161, 255, 0.2);
}

.data-cell.profit-mid .data-value {
    color: #70a1ff;
}

.data-cell.profit-low {
    background: rgba(255, 165, 2, 0.15);
}

.data-cell.profit-low .data-value {
    color: #ffa502;
}

.data-cell.profit-minus {
    background: rgba(255, 107, 107, 0.15);
}

.data-cell.profit-minus .data-value {
    color: #ff6b6b;
}

.no-data-inline {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #888;
    font-size: 0.9em;
}

/* 設定推定行 */
.estimation-row {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 8px;
    font-size: 0.85em;
}

.setting-estimate {
    padding: 3px 10px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 1.1em;
}

.setting-estimate .payout {
    font-weight: 400;
    font-size: 0.85em;
    opacity: 0.8;
}

/* 設定別カラー: 6=赤, 5=オレンジ, 4=黄, 3=緑, 2=青, 1=白 */
.setting-estimate.setting-6 {
    background: rgba(255, 71, 87, 0.25);
    color: #ff4757;
    border: 1px solid rgba(255, 71, 87, 0.5);
}

.setting-estimate.setting-5 {
    background: rgba(255, 165, 2, 0.25);
    color: #ffa502;
    border: 1px solid rgba(255, 165, 2, 0.5);
}

.setting-estimate.setting-4 {
    background: rgba(255, 230, 0, 0.2);
    color: #ffe600;
    border: 1px solid rgba(255, 230, 0, 0.4);
}

.setting-estimate.setting-3 {
    background: rgba(46, 213, 115, 0.2);
    color: #2ed573;
    border: 1px solid rgba(46, 213, 115, 0.4);
}

.setting-estimate.setting-2 {
    background: rgba(112, 161, 255, 0.2);
    color: #70a1ff;
    border: 1px solid rgba(112, 161, 255, 0.4);
}

.setting-estimate.setting-1,
.setting-estimate.setting-0 {
    background: rgba(200, 200, 200, 0.15);
    color: #ccc;
    border: 1px solid rgba(200, 200, 200, 0.3);
}

/* 暫定的な設定推測（参考程度） */
.setting-estimate.tentative {
    opacity: 0.8;
}

.setting-estimate.tentative .payout {
    font-size: 0.75em;
}

.setting-estimate.tentative-weak {
    background: rgba(100, 100, 100, 0.2);
    color: #888;
    border: 1px solid rgba(100, 100, 100, 0.3);
    font-size: 0.9em;
}

/* 詳細セクション強調 */
.detail-item.highlight {
    background: rgba(255, 215, 0, 0.1);
    padding: 4px 6px;
    border-radius: 4px;
    margin: 2px 0;
}

/* 単位を小さく */
.unit-small {
    font-size: 0.7em;
    opacity: 0.7;
}

/* トップページ: 機種名 */
.machine-name-top {
    font-weight: 600;
    color: #fff;
}

.machine-name-sm {
    font-size: 0.75em;
    color: #888;
    margin-left: 5px;
}

/* トップページ: 最大枚数 */
.max-medals-top {
    color: #ffd700;
    font-weight: 600;
}

.max-medals-top .num {
    font-size: 1.1em;
}

/* ===== 最大枚数バッジ ===== */
.medals-icon {
    margin-right: 2px;
}

.medals-icon-sm {
    font-size: 0.9em;
    margin-right: 1px;
}

.medals-10k {
    color: #ff4757 !important;
    text-shadow: 0 0 8px rgba(255, 71, 87, 0.5);
}

.medals-10k .num {
    color: #ff4757;
}

.medals-5k {
    color: #ffa502 !important;
}

.medals-5k .num {
    color: #ffa502;
}

.medals-3k {
    color: #ffd700 !important;
}

.medals-3k .num {
    color: #ffd700;
}

.medals-2k {
    color: #70a1ff !important;
}

.medals-2k .num {
    color: #70a1ff;
}

.medals-1k {
    color: #2ed573 !important;
}

.medals-1k .num {
    color: #2ed573;
}

/* data-cell 内のバッジ */
.data-cell.medals-10k {
    background: rgba(255, 71, 87, 0.2);
}

.data-cell.medals-5k {
    background: rgba(255, 165, 2, 0.2);
}

.data-cell.medals-3k {
    background: rgba(255, 215, 0, 0.15);
}

.data-cell.medals-2k {
    background: rgba(112, 161, 255, 0.15);
}

.data-cell.medals-1k {
    background: rgba(46, 213, 115, 0.15);
}

/* トップ5の注釈 */
.top5-note {
    font-size: 0.75em;
    color: #888;
    margin-bottom: 10px;
}

.past-eval {
    color: #888;
}

.past-eval strong {
    font-size: 1.1em;
}

/* 推奨理由 */
.reason-main {
    padding: 8px;
    background: rgba(255, 165, 2, 0.1);
    border-left: 3px solid #ffa502;
    border-radius: 0 6px 6px 0;
    margin-bottom: 5px;
}

.reason-line {
    font-size: 0.85em;
    color: #ffa502;
    padding: 2px 0;
}

/* 詳細グリッド */
.detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 10px;
}

.detail-section {
    padding: 8px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
}

.detail-title {
    font-size: 0.75em;
    color: #ffa502;
    font-weight: 600;
    margin-bottom: 6px;
}

.detail-item {
    font-size: 0.8em;
    color: #ccc;
    padding: 2px 0;
}

.detail-item.plus {
    color: #2ed573;
}

.detail-item.minus {
    color: #ff6b6b;
}

.all-reasons {
    padding: 8px;
    background: rgba(255, 165, 2, 0.05);
    border-radius: 6px;
}

/* コンパクトカード */
.unit-card-compact {
    background: #252541;
    border-radius: 6px;
    padding: 10px;
    margin-bottom: 6px;
}

.compact-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.unit-id-sm {
    font-size: 1.1em;
    font-weight: 700;
    min-width: 50px;
    color: #fff;
}

.avail-sm {
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.7em;
    font-weight: 700;
}

.avail-sm.empty {
    background: #2ed573;
    color: #000;
}

.avail-sm.playing {
    background: #ff6b6b;
    color: #fff;
}

.rank-sm {
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: 700;
    color: #fff;
}

.compact-data {
    font-size: 0.85em;
    color: #aaa;
}

.compact-data .num {
    font-size: 1.1em;
    font-weight: 700;
    color: #fff;
}

.compact-data .lbl {
    font-size: 0.7em;
    color: #666;
}

.compact-data.no-data {
    color: #666;
}

.compact-data.past-data {
    color: #70a1ff;
    font-style: italic;
}

.compact-prob {
    font-size: 0.75em;
    font-weight: 600;
}

.compact-prob.excellent {
    color: #2ed573;
}

.compact-prob.good {
    color: #70a1ff;
}

.compact-prob.bad {
    color: #ff6b6b;
}

.compact-rb {
    font-size: 0.7em;
    color: #a0a0a0;
}

.compact-rb .num {
    font-weight: 600;
    margin-left: 1px;
}

.compact-profit {
    font-size: 0.8em;
    font-weight: 600;
    margin-left: auto;
}

.compact-profit.profit-high {
    color: #2ed573;
}

.compact-profit.profit-mid {
    color: #70a1ff;
}

.compact-profit.profit-minus {
    color: #ff6b6b;
}

.compact-details {
    font-size: 0.8em;
    color: #aaa;
    padding: 8px;
    border-top: 1px solid #333;
    margin-top: 8px;
}

.compact-details div {
    padding: 2px 0;
}

.compact-reason {
    color: #ffa502;
    margin-top: 4px;
}

/* フィルタ */
.availability-summary span {
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.2s;
}

.availability-summary span:hover {
    background: rgba(255, 255, 255, 0.1);
}

.availability-summary span.active {
    background: rgba(255, 255, 255, 0.2);
}

.avail-all {
    color: #888;
    font-size: 0.85em;
}

/* ===== トップページ: 本日おすすめ店舗 ===== */

.today-stores {
    margin-bottom: 20px;
}

.today-stores h2 {
    font-size: 1em;
    color: #2ed573;
    margin-bottom: 10px;
}

.store-recommend-card {
    background: rgba(46, 213, 115, 0.15);
    border-left: 4px solid #2ed573;
    border-radius: 0 8px 8px 0;
    padding: 12px 15px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.store-recommend-card .store-name {
    font-weight: 700;
    color: #fff;
}

.store-recommend-card .store-note {
    font-size: 0.85em;
    color: #2ed573;
}

/* ===== トップページ: トップ3 統計表示 ===== */

.top3-stats {
    display: flex;
    gap: 10px;
    font-size: 0.85em;
    color: #aaa;
    margin-top: 8px;
    flex-wrap: wrap;
    align-items: baseline;
}

.top3-stats .num {
    font-size: 1.3em;
    font-weight: 800;
    color: #fff;
}

.top3-stats .label {
    font-size: 0.7em;
    color: #666;
}

.top3-stats .excellent {
    color: #2ed573;
    font-weight: 600;
}

.top3-stats .good {
    color: #70a1ff;
    font-weight: 600;
}

.top3-stats .bad {
    color: #ff6b6b;
}

.top3-stats .profit {
    font-weight: 600;
}

.top3-stats .profit.high {
    color: #2ed573;
}

.top3-stats .profit.mid {
    color: #70a1ff;
}

.top3-stats .profit.low {
    color: #ffa502;
}

/* ===== トップページ: 前日トップ3 ===== */

.yesterday-section {
    margin-bottom: 20px;
}

.yesterday-section h2 {
    font-size: 1em;
    color: #70a1ff;
    margin-bottom: 5px;
}

.yesterday-note {
    font-size: 0.8em;
    color: #888;
    margin-bottom: 10px;
}

.yesterday-card {
    background: #252541;
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 8px;
    text-decoration: none;
    display: block;
}

.yesterday-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.machine-icon-sm {
    font-size: 1em;
}

.unit-id-sm {
    font-weight: 700;
    color: #fff;
    min-width: 50px;
}

.store-name-sm {
    font-size: 0.85em;
    color: #888;
}

.yesterday-stats {
    display: flex;
    gap: 15px;
    font-size: 0.85em;
}

.yesterday-diff {
    font-weight: 700;
}

.yesterday-diff.plus {
    color: #2ed573;
}

.yesterday-diff.minus {
    color: #ff6b6b;
}

.avg-art {
    color: #aaa;
}

/* 最大枚数 */
.max-medals {
    color: #ffa502;
    font-weight: 700;
}

.max-medals .num {
    font-size: 1.2em;
    color: #ffd700;
}

/* 差枚（小さめ） */
.yesterday-diff-sm {
    font-size: 0.85em;
}

.yesterday-diff-sm.plus {
    color: #2ed573;
}

.yesterday-diff-sm.minus {
    color: #ff6b6b;
}

/* ART/RB数字を強調 */
.art-num {
    color: #ff6b6b;
    font-size: 1.2em;
    font-weight: 700;
}

.rb-num {
    color: #70a1ff;
    font-size: 1.1em;
    font-weight: 600;
}

/* ===== トップページ: 店舗別おすすめ曜日 ===== */

.store-schedule {
    margin-bottom: 20px;
}

.store-schedule h2 {
    font-size: 1em;
    color: #888;
    margin-bottom: 10px;
}

.schedule-card {
    background: #252541;
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.schedule-store {
    font-weight: 600;
    color: #fff;
    min-width: 140px;
}

.schedule-days {
    display: flex;
    gap: 5px;
}

.day-badge {
    display: inline-block;
    padding: 3px 8px;
    background: #333;
    border-radius: 4px;
    font-size: 0.8em;
    color: #aaa;
}

.day-badge.today {
    background: #ffa502;
    color: #000;
    font-weight: 700;
}

.schedule-note {
    font-size: 0.8em;
    color: #888;
    margin-left: auto;
}

/* ===== トップページ: 曜日表示 ===== */

.today-info {
    font-size: 1.1em;
    color: #ffa502;
    font-weight: 600;
    margin-top: 5px;
}

/* ===== 星評価 ===== */
.star-rating {
    display: inline-block;
    color: #ffd700;
    letter-spacing: 1px;
    font-size: 0.9em;
}

.star-rating .empty {
    color: #444;
}

/* ===== 店舗リンク ===== */
.store-link {
    color: #70a1ff;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.store-link:hover {
    color: #9ab8ff;
}

/* ===== 機種リンク ===== */
.machine-link {
    color: #ffa502;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.machine-link:hover {
    color: #ffb833;
}

/* ===== 空き状況バッジ（トップ用） ===== */
.top3-avail {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75em;
    font-weight: 700;
    margin-left: 5px;
}

.top3-avail.empty {
    background: #2ed573;
    color: #000;
}

.top3-avail.playing {
    background: #ff6b6b;
    color: #fff;
}

.top3-avail.closed {
    background: #555;
    color: #999;
}

/* ===== データ日付バッジ ===== */
.data-date-badge {
    position: absolute;
    top: -8px;
    right: 10px;
    background: #ffa502;
    color: #000;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.7em;
    font-weight: 700;
}

.data-date-badge-sm {
    display: inline-block;
    background: #ffa502;
    color: #000;
    padding: 1px 6px;
    border-radius: 3px;
    font-size: 0.65em;
    font-weight: 700;
    margin-left: 4px;
}

.art-main.past {
    opacity: 0.7;
}

.art-prob.past {
    opacity: 0.7;
}

.today-data-row {
    position: relative;
}

/* ===== 遊技中バッジ ===== */
.playing-badge {
    display: inline-block;
    background: #ff6b6b;
    color: #fff;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: 700;
}

/* ===== ランキング番号（小） ===== */
.ranking-num-sm {
    font-size: 0.8em;
    font-weight: 700;
    color: #ffa502;
    min-width: 20px;
}

/* ===== 機種名（小） ===== */
.machine-name-sm {
    font-size: 0.75em;
    color: #888;
    margin-left: auto;
}

/* ===== トップページ: ART数メイン表示 ===== */
.top3-stats-main {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 6px 0 4px 0;
}

.art-main {
    display: flex;
    align-items: baseline;
    gap: 2px;
}

.art-main.past {
    opacity: 0.7;
}

.art-num-big {
    font-size: 2em;
    font-weight: 900;
    color: #ff6b6b;
}

.art-label {
    font-size: 0.85em;
    color: #ff6b6b;
    font-weight: 600;
}

.art-prob {
    font-size: 1.1em;
    font-weight: 700;
    color: #aaa;
}

.art-prob.excellent {
    color: #2ed573;
}

.art-prob.good {
    color: #70a1ff;
}

.art-prob.bad {
    color: #ff6b6b;
}

/* サブ情報行 */
.top3-stats-sub {
    display: flex;
    gap: 12px;
    font-size: 0.8em;
    color: #888;
    margin-top: 4px;
    flex-wrap: wrap;
}

.top3-stats-sub .num {
    font-weight: 700;
    color: #aaa;
}

.current-hama {
    color: #ffa502;
}

.current-hama .num {
    color: #ffa502;
    font-size: 1.1em;
}

.total-games {
    color: #666;
}

/* 台番号をサブ情報に */
.unit-id-sub {
    font-weight: 400;
    color: #888;
    font-size: 0.95em;
}

/* ARTバッジ */
.art-badge {
    display: inline-flex;
    align-items: baseline;
    gap: 3px;
    color: #ff6b6b;
    font-weight: 600;
}

.art-badge .art-num {
    font-size: 1.3em;
    font-weight: 800;
}

/* コンパクトカード: ART強調 */
.compact-art {
    display: inline-flex;
    align-items: baseline;
    gap: 2px;
}

.compact-art .art-num {
    font-size: 1.4em;
    font-weight: 900;
    color: #ff6b6b;
}

.compact-art .art-lbl {
    font-size: 0.7em;
    color: #ff6b6b;
}

.compact-art.past .art-num {
    color: #70a1ff;
}

.compact-art.past .art-lbl {
    color: #70a1ff;
}

/* 最大枚数（コンパクト） */
.compact-max {
    color: #ffd700;
    font-size: 0.8em;
    font-weight: 600;
}

.compact-max .num {
    font-size: 1.1em;
}

/* 回転数（小さく） */
.compact-games {
    color: #666;
    font-size: 0.75em;
}

/* 推奨カード: ART大きく */
.art-num-lg {
    font-size: 1.6em;
    font-weight: 900;
    color: #ff6b6b;
}

/* ===================================
   曜日別店舗評価 - 新スタイル
   =================================== */

/* 今日の曜日の店舗評価セクション */
.today-stores h2 {
    font-size: 1em;
    color: #888;
    margin-bottom: 10px;
}

.day-section {
    margin-bottom: 15px;
}

.day-section-label {
    font-size: 0.85em;
    font-weight: 600;
    margin-bottom: 8px;
    padding: 4px 10px;
    border-radius: 4px;
    display: inline-block;
}

.day-section.good .day-section-label {
    background: #1e4620;
    color: #4ade80;
}

.day-section.bad .day-section-label {
    background: #4a2020;
    color: #f87171;
}

.day-section.neutral .day-section-label {
    background: #3a3a4a;
    color: #999;
}

.neutral-note {
    color: #666;
    font-size: 0.85em;
    padding: 10px;
}

/* 店舗カード（曜日評価用） */
.store-day-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    background: #252541;
    border-radius: 8px;
    margin-bottom: 8px;
    text-decoration: none;
    color: #fff;
    border-left: 4px solid transparent;
}

.store-day-card.good {
    border-left-color: #4ade80;
}

.store-day-card.bad {
    border-left-color: #f87171;
}

.store-day-card .store-name {
    flex: 1;
    font-weight: 600;
    font-size: 0.95em;
}

.store-day-card .day-rating {
    color: #ffd700;
    font-size: 0.85em;
}

.store-day-card .day-rating.dim {
    color: #666;
}

.store-day-card .day-rating .empty {
    color: #444;
}

.store-day-card .store-note {
    font-size: 0.75em;
    color: #888;
    max-width: 120px;
    text-align: right;
}

/* 店舗別曜日傾向（全曜日表示） */
.store-schedule h2 {
    font-size: 1em;
    color: #888;
    margin-bottom: 8px;
}

.schedule-legend {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 12px;
    font-size: 0.7em;
}

.legend-item {
    padding: 3px 8px;
    border-radius: 4px;
}

.legend-item.best {
    background: #3b2a00;
    color: #ffd700;
}

.legend-item.good {
    background: #1e3a1e;
    color: #4ade80;
}

.legend-item.normal {
    background: #2a2a3a;
    color: #888;
}

.legend-item.weak {
    background: #3a2020;
    color: #f87171;
}

/* 店舗カード（全曜日） */
.schedule-card-full {
    display: block;
    background: #252541;
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 10px;
    text-decoration: none;
    color: #fff;
}

.schedule-store-name {
    font-weight: 600;
    font-size: 0.95em;
    margin-bottom: 8px;
}

.schedule-week {
    display: flex;
    gap: 4px;
    margin-bottom: 8px;
}

.day-cell {
    flex: 1;
    text-align: center;
    padding: 6px 2px;
    border-radius: 4px;
    background: #1a1a2e;
}

.day-cell .day-name {
    display: block;
    font-size: 0.7em;
    color: #888;
    margin-bottom: 2px;
}

.day-cell .day-stars {
    font-size: 0.55em;
    letter-spacing: -1px;
}

.day-cell.best {
    background: #3b2a00;
}

.day-cell.best .day-stars {
    color: #ffd700;
}

.day-cell.good {
    background: #1e3a1e;
}

.day-cell.good .day-stars {
    color: #4ade80;
}

.day-cell.normal .day-stars {
    color: #888;
}

.day-cell.weak {
    background: #3a2020;
}

.day-cell.weak .day-stars {
    color: #f87171;
}

.day-cell.today {
    border: 2px solid #70a1ff;
}

.day-cell.today .day-name {
    color: #70a1ff;
    font-weight: 600;
}

.schedule-notes {
    font-size: 0.75em;
    color: #888;
}

.note-best {
    color: #4ade80;
}

/* ===================================
   法則コーナー (rules.html)
   =================================== */

.rules-section {
    margin-bottom: 25px;
}

.rules-section h2 {
    font-size: 1.1em;
    color: #ffa502;
    margin-bottom: 12px;
    padding-bottom: 5px;
    border-bottom: 1px solid #333;
}

.rule-card {
    background: #252541;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 12px;
}

.rule-card.machine {
    border-left: 4px solid #ffa502;
}

.rule-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.rule-store-name,
.rule-machine-name {
    font-weight: 700;
    font-size: 1.1em;
    color: #fff;
}

.rule-rating {
    font-size: 0.85em;
    color: #ffd700;
    margin-left: auto;
}

.rule-weekday {
    margin: 10px 0;
}

.weekday-grid {
    display: flex;
    gap: 4px;
}

.weekday-cell {
    flex: 1;
    text-align: center;
    padding: 8px 4px;
    background: #1a1a2e;
    border-radius: 4px;
}

.weekday-cell .day {
    display: block;
    font-size: 0.75em;
    color: #888;
    margin-bottom: 2px;
}

.weekday-cell .stars {
    font-size: 0.5em;
    color: #666;
}

.weekday-cell.best {
    background: #3b2a00;
}

.weekday-cell.best .stars {
    color: #ffd700;
}

.weekday-cell.good {
    background: #1e3a1e;
}

.weekday-cell.good .stars {
    color: #4ade80;
}

.weekday-cell.weak {
    background: #3a2020;
}

.weekday-cell.weak .stars {
    color: #f87171;
}

.rule-tips {
    margin: 10px 0;
}

.rule-tips .tip {
    font-size: 0.85em;
    padding: 4px 8px;
    margin: 4px 0;
    border-radius: 4px;
}

.rule-tips .tip.good {
    background: rgba(74, 222, 128, 0.1);
    color: #4ade80;
}

.rule-tips .tip.bad {
    background: rgba(248, 113, 113, 0.1);
    color: #f87171;
}

.rule-patterns {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #333;
}

.patterns-title {
    font-size: 0.8em;
    color: #888;
    margin-bottom: 6px;
}

.pattern-item {
    font-size: 0.85em;
    color: #ccc;
    padding: 3px 0;
    padding-left: 12px;
    border-left: 2px solid #70a1ff;
    margin: 4px 0;
}

/* 機種スペック */
.machine-specs {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    padding: 10px;
    margin: 10px 0;
}

.spec-row {
    display: flex;
    justify-content: space-between;
    padding: 3px 0;
    font-size: 0.85em;
}

.spec-label {
    color: #888;
}

.spec-value {
    color: #fff;
    font-weight: 600;
}

.machine-tips {
    margin: 10px 0;
}

.tips-title {
    font-size: 0.8em;
    color: #ffa502;
    margin-bottom: 6px;
}

.tip-item {
    font-size: 0.85em;
    color: #ccc;
    padding: 4px 0;
    padding-left: 12px;
    border-left: 2px solid #ffa502;
    margin: 4px 0;
}

.reset-info {
    margin-top: 10px;
    padding: 10px;
    background: rgba(255, 165, 2, 0.1);
    border-radius: 6px;
}

.reset-title {
    font-size: 0.8em;
    color: #ffa502;
    margin-bottom: 4px;
}

.reset-content {
    font-size: 0.85em;
    color: #ffd700;
}

/* 一般的なTips */
.general-tips {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.general-tip-card {
    display: flex;
    gap: 12px;
    background: #252541;
    border-radius: 8px;
    padding: 12px;
}

.tip-number {
    width: 30px;
    height: 30px;
    background: #ffa502;
    color: #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
}

.tip-content {
    flex: 1;
}

.tip-title {
    font-weight: 600;
    color: #fff;
    margin-bottom: 4px;
}

.tip-text {
    font-size: 0.85em;
    color: #aaa;
}

.disclaimer {
    font-size: 0.75em;
    color: #666;
    text-align: center;
    padding: 15px;
}

/* ===================================
   当たり履歴 (history.html)
   =================================== */

.history-summary {
    background: #252541;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
}

.summary-grid {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.summary-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 15px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    min-width: 70px;
}

.summary-item .summary-value {
    font-size: 1.4em;
    font-weight: 800;
    color: #fff;
}

.summary-item .summary-label {
    font-size: 0.7em;
    color: #888;
}

.summary-item.excellent .summary-value {
    color: #2ed573;
}

.summary-item.good .summary-value {
    color: #70a1ff;
}

.summary-item.bad .summary-value {
    color: #ff6b6b;
}

.summary-item.highlight {
    background: rgba(255, 215, 0, 0.1);
}

.summary-item.highlight .summary-value {
    color: #ffd700;
}

.summary-extra {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 10px;
    font-size: 0.85em;
    color: #aaa;
    flex-wrap: wrap;
}

.summary-extra strong {
    color: #fff;
}

.summary-extra .warning {
    color: #ff6b6b;
}

/* 履歴テーブル */
.history-table-section h2 {
    font-size: 1em;
    color: #888;
    margin-bottom: 10px;
}

.history-table-wrapper {
    overflow-x: auto;
}

.history-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85em;
}

.history-table th {
    background: #1a1a2e;
    color: #888;
    padding: 8px 6px;
    text-align: center;
    font-weight: 600;
}

.history-table td {
    padding: 8px 6px;
    text-align: center;
    border-bottom: 1px solid #333;
}

.history-table tr:nth-child(even) {
    background: rgba(0, 0, 0, 0.1);
}

.history-table tr.tenjou {
    background: rgba(255, 107, 107, 0.1);
}

.history-table tr.hot {
    background: rgba(255, 165, 2, 0.1);
}

.history-table .num {
    color: #666;
    font-size: 0.85em;
}

.history-table .time {
    color: #70a1ff;
}

.history-table .games {
    font-weight: 600;
}

.history-table .games.deep {
    color: #ff6b6b;
}

.history-table .games.shallow {
    color: #2ed573;
}

.history-table .type {
    font-weight: 600;
}

.history-table .type.art {
    color: #ff6b6b;
}

.history-table .type.bb {
    color: #ffd700;
}

.history-table .type.rb {
    color: #70a1ff;
}

.history-table .rensa.hot {
    color: #ffa502;
    font-weight: 700;
}

.history-table .medals {
    color: #aaa;
}

.no-history {
    text-align: center;
    padding: 30px;
    background: #252541;
    border-radius: 8px;
    color: #888;
}

/* グラフ分析 */
.history-analysis h2 {
    font-size: 1em;
    color: #888;
    margin-bottom: 10px;
}

.analysis-card {
    background: #252541;
    border-radius: 8px;
    padding: 15px;
    border-left: 4px solid #ffa502;
}

.analysis-pattern {
    font-size: 1.1em;
    font-weight: 700;
    color: #ffa502;
    margin-bottom: 6px;
}

.analysis-desc {
    font-size: 0.9em;
    color: #ccc;
    margin-bottom: 8px;
}

.analysis-rec {
    font-size: 0.85em;
    color: #2ed573;
    padding: 8px;
    background: rgba(46, 213, 115, 0.1);
    border-radius: 4px;
}
