:root {
    --header-h: 66px;
}

/* ベーススタイル */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 20px;
}
body {
    font-family: 'Noto Sans JP', sans-serif;
    background-color: #e9ecef;
    color: #333;
    margin: 0;
    padding: var(--header-h) 0 0;
    line-height: 1.6;
}

/* ヘッダ固定時の逃がし */
body.has-fixed-header {
    padding-top: 72px; /* ヘッダ実高さに合わせて微調整 */
}

.copyright {
    padding-top: 8px;
    font-size: small;
    color: #666666;
}


/* メインコンテナ */
.container {
    max-width: 800px;
    margin: 0 auto 40px;
    padding: 35px 30px;
    background-color: #f4f6f9;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    box-sizing: border-box;
}

/* レースタイトルエリア */
.race-header {
    text-align: center;
    padding-bottom: 20px;
    margin-bottom: 25px;
    border-bottom: 1px dashed #cbd5e1;
}
.race-title {
    font-size: 1.6rem;
    color: #1a202c;
    margin: 0;
    font-weight: 900;
    line-height: 1.4;
}

/* 出走表リンクボタン */
.btn-link-wrap {
    text-align: center;
    margin: 25px 0 40px;
}
.btn-link {
    display: inline-block;
    background-color: #e60012;
    color: #fff;
    padding: 14px 45px;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    letter-spacing: 1px;
    box-shadow: 0 4px 12px rgba(230,0,18,0.25);
    transition: all 0.3s ease;
}
.btn-link:hover {
    background-color: #cc0010;
    box-shadow: 0 6px 16px rgba(230,0,18,0.35);
    transform: translateY(-2px);
}

/* PC環境ではスマホ用ボタンを非表示 */
.sp-btn {
    display: none;
}

/* セクションタイトル */
.section-title {
    color: #1a202c;
    font-size: 1.3rem;
    font-weight: 900;
    margin-top: 45px;
    margin-bottom: 20px;
    padding-left: 12px;
    border-left: 5px solid #2b6cb0;
}

/* 並び予想 */
.prediction-box {
    display: flex;
    justify-content: center;
    gap: 20px;
    background-color: #e2e8f0;
    padding: 25px 20px;
    border-radius: 10px;
    overflow-x: auto;
    margin-bottom: 30px;
}
.line-group {
    display: flex;
    gap: 6px;
}
.player-col {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.bracket {
	display: flex;
	align-items: center;
	font-size: 1.5rem;
	font-weight: 900;
	color: #4a5568;
	padding: 0 2px;
	margin-top: -3rem;
}

/* 車番 */
.number {
    width: 34px;
    height: 34px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 1.15rem;
    margin-bottom: 10px;
    border: 1px solid #d1d5db;
    flex-shrink: 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
.role {
    writing-mode: vertical-rl;
    letter-spacing: 2px;
    font-weight: 700;
    color: #4a5568;
    font-size: 0.95rem;
}

/* 選手ジャンプナビゲーション */
.player-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    padding: 15px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}
.nav-link {
    text-decoration: none;
    display: block;
    transition: transform 0.2s ease;
}
.nav-link:hover {
    transform: scale(1.1);
}
.nav-link .number {
    margin-bottom: 0;
    cursor: pointer;
}

/* 車番カラー */
.color-1 { background-color: #fff; color: #000; }
.color-2 { background-color: #000; color: #fff; border-color: #000; }
.color-3 { background-color: #e60012; color: #fff; border-color: #e60012; }
.color-4 { background-color: #0068b7; color: #fff; border-color: #0068b7; }
.color-5 { background-color: #f3e100; color: #000; border-color: #f3e100; }
.color-6 { background-color: #009944; color: #fff; border-color: #009944; }
.color-7 { background-color: #f39800; color: #000; border-color: #f39800; }
.color-8 { background-color: #ea618e; color: #000; border-color: #ea618e; }
.color-9 { background-color: #920783; color: #fff; border-color: #920783; }

/* 選手コメントカード */
.comment-card {
    background-color: #fff;
    border: none;
    border-radius: 12px;
    margin-bottom: 25px;
    box-shadow: 0 6px 16px rgba(0,0,0,0.05);
    overflow: hidden;
}
.comment-header {
    display: flex;
    align-items: center;
    background-color: #fff;
    padding: 20px 20px 15px 20px;
    border-bottom: 1px solid #f1f5f9;
}
.comment-header .number {
    margin-bottom: 0;
    margin-right: 15px;
}
.player-profile {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 12px;
}
.player-name {
    font-size: 1.35rem;
    font-weight: 900;
    color: #1a202c;
    letter-spacing: 1px;
}
.player-meta {
    font-size: 0.95rem;
    color: #718096;
    font-weight: 500;
}

/* コメントエリア */
.comment-body {
    padding: 15px 20px 25px 20px;
}

/* 日別のブロック */
.day-block {
    margin-bottom: 25px;
}
.day-block:last-child {
    margin-bottom: 0;
}

/* 日付バッジ */
.day-badge {
    display: inline-block;
    background-color: #003366;
    color: #fff;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 4px;
    margin-bottom: 12px;
    letter-spacing: 1px;
}

/* アコーディオン */
details.accordion-block {
    /* margin-bottom: 25px; */
    background-color: #f8fafc;
    border-radius: 8px;
    padding: 10px 15px;
}
details.accordion-block:last-child {
    margin-bottom: 0;
}
details.accordion-block summary {
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 700;
    color: #4a5568;
}
details.accordion-block summary .accordion-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #4a5568;
}
/* Safari対応（デフォルト矢印消去） */
details.accordion-block summary::-webkit-details-marker {
    display: none;
}
/* オリジナルの開閉アイコン */
details.accordion-block summary::after {
    content: "▼";
    font-size: 0.8rem;
    color: #94a3b8;
    transition: transform 0.3s;
}
details[open].accordion-block summary::after {
    transform: rotate(180deg);
}
details[open].accordion-block summary {
    margin-bottom: 15px;
    border-bottom: 1px dashed #cbd5e1;
    padding-bottom: 10px;
}
.accordion-content {
    padding-left: 5px;
}

/* 質問と回答 */
.qa-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.question {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    color: #4a5568;
    font-size: 0.95rem;
    font-weight: 700;
}
.q-mark {
    color: #2b6cb0;
    font-weight: 900;
    font-size: 1.1rem;
    line-height: 1.4;
}
.q-text {
    line-height: 1.5;
    padding-top: 1px;
}
.answer {
    color: #111;
    font-size: 1.1rem;
    font-weight: 900;
    line-height: 1.7;
    margin: 0;
    padding-left: 23px;
}
.no-comment {
    color: #999;
    font-size: 0.95rem;
    font-weight: 400;
    padding-top: 5px;
}
.absent {
	color: #e60012;
	font-size: 0.95rem;
	font-weight: 700;
	padding-top: 5px;
}

/* 記者情報 */
.reporter-info {
    text-align: right;
    margin-top: 40px;
    padding-top: 20px;
    font-weight: 700;
    color: #718096;
    font-size: 0.95rem;
    border-top: 1px solid #cbd5e1;
}

/* レスポンシブ対応 */
@media (max-width: 600px) {
    .container {
        margin: 20px 0;
        padding: 25px 15px;
        border-radius: 0;
    }
    .prediction-box {
        justify-content: flex-start;
        padding: 20px 15px;
    }
    .race-title {
        font-size: 1.4rem;
    }
    .comment-header {
        padding: 15px;
    }
    .comment-body {
        padding: 10px 15px 20px 15px;
    }
    .answer {
        padding-left: 0;
        margin-top: 4px;
    }
    details.accordion-block {
    padding: 10px;
    }
    
    /* PC/スマホボタンを切り替え */
    .pc-btn {
        display: none;
    }
    .sp-btn {
        display: inline-block;
    }
}


/* レース一覧へ戻るボタン */
.back-link-wrap {
    text-align: left;
    margin-bottom: 15px;
}

.bottom-back-link-wrap {
    text-align: left;
    margin-top: 20px;
}

.back-link {
    color: #2b6cb0;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 700;
}

.back-link:hover {
    text-decoration: underline;
}

/* ロゴ */
.reporter-info{
    margin-top: 24px;
    line-height: 1.8;
}

.reporter-logo{
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.reporter-logo img{
    height: 36px;
    width: auto;
    display: block;
}