.search-area-container {
    display: flex;
    width: 100%;
}

.search-item {
    width: 80%;
}

.search-button {
    height: 100%;
    align-content: center;
    flex: 1;
}

.search-button button {
    background: #F58220;
    color: #fff;
    padding: 12px;
    border-radius: 10px;
    width: 90%;
    max-width: 320px;
    display: block;
    margin: 0 auto;
    font-weight: bold;
    border: none;
    cursor: pointer;
}

.search-button button {
    transition: background 0.2s ease;
}

.search-button button:hover {
    background: rgba(252, 167, 92, 0.8);
}

.search-mode {
    display: flex;
    align-items: center;
    width: 50%;
    margin-top: 5px;
}

.search-mode select {
    height: 100%;
    padding: 6px 8px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    margin-right: 5px;
}

.search-mode label {
    margin-right: 0.5em;
    width: 7rem;
}

.search-result {
    width: 100%;
    overflow: auto;
}

.search-result table {
    table-layout: auto;
    width: auto;
    border-collapse: collapse;
}
.search-result th,
.search-result td {
    white-space: nowrap;
    padding: 6px 12px;
    border: 1px solid #ddd;
}

/* 詳細ページ */
.detail-back {
    margin-bottom: 16px;
}

.detail-back a {
    color: #F58220;
    text-decoration: none;
    font-weight: bold;
}

.detail-title {
    font-size: 24px;
    margin-bottom: 16px;
}

.detail-section-title {
    font-size: 18px;
    margin: 24px 0 8px;
    border-left: 4px solid #F58220;
    padding-left: 8px;
}

.detail-info {
    border-collapse: collapse;
    width: 100%;
    table-layout: fixed;
}

.detail-info th,
.detail-info td {
    padding: 8px 16px;
    border: 1px solid #ddd;
    text-align: left !important;
}

.detail-info th {
    background: #e4ffd7;
    width: 120px;
    white-space: nowrap;
}

.detail-info td {
    width: calc(50% - 120px);
}

.ketto-info {
    border-collapse: collapse;
    width: 100%;
}

.ketto-info td {
    padding: 8px 16px;
    border: 1px solid #b0c4de;
    text-align: left !important;
    vertical-align: middle;
    width: 33.33%;
    border: 1px solid red;
}

.b_ml {
    background-color: #ccefff;
    color: #00008b;
}

.b_fml {
    background-color: #ffdbd5;
    color: #8b0000;
}

/* 過去のレース結果テーブル: データ長で可変・1行表示・横スクロール */
.race-result-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.race-result-wrap .race-result-table {
    width: max-content;
    table-layout: auto;
}

.race-result-wrap .race-result-table th,
.race-result-wrap .race-result-table td {
    white-space: nowrap;
    width: auto;
}