@charset "UTF-8";

/* BCダートマイル出馬表。共通ナビ・本文・ページ全体には適用しない。 */
.bc-racecard-page .racecard-odds-update {
  width: 100%;
  max-width: 1200px;
  margin: 0 0 12px;
  padding: 0;
  color: #252525;
  font-size: 12px;
  line-height: 1.4;
  text-align: right;
}

#racecard-local {
  --racecard-columns: 32px 20px 151px 48px 48px 72px repeat(4, minmax(0, 1fr));
  --racecard-border: #d2d2d2;
  --racecard-horse-font-size: 13px;
  container: racecard / inline-size;
  box-sizing: border-box;
  width: 100%;
  max-width: 1200px;
  min-width: 0;
  margin: 0;
  padding: 0;
  color: #252525;
  background: #fdfdfd;
  font-family: Arial, "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.45;
  text-align: left;
  text-size-adjust: 100%;
  -webkit-text-size-adjust: 100%;
}

#racecard-local *,
#racecard-local *::before,
#racecard-local *::after {
  box-sizing: border-box;
}

#racecard-local :where(dl, dt, dd, ul, li, p) {
  margin: 0;
  padding: 0;
  list-style: none;
}

#racecard-local :where(div, dl, dt, dd, ul, li, p, span, a) {
  float: none;
  min-width: 0;
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  letter-spacing: normal;
  text-indent: 0;
  text-shadow: none;
}

#racecard-local .raceCont,
#racecard-local .raceCont__inner {
  display: block;
  position: static;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  height: auto;
  margin: 0;
  padding: 0;
  border: 0;
}

#racecard-local .raceCont__inner {
  overflow: visible;
}

#racecard-local .raceCont__inner:focus-visible {
  outline: 2px solid #0078d6;
  outline-offset: 2px;
}

#racecard-local .raceTable {
  display: block;
  position: static;
  width: 100%;
  max-width: none;
  min-width: 0;
  height: auto;
  margin: 0;
  padding: 0;
  border: 0;
  border-top: 1px solid var(--racecard-border);
  border-left: 1px solid var(--racecard-border);
  background: #fdfdfd;
}

#racecard-local .raceTable__header,
#racecard-local .raceTable__details__line {
  display: grid;
  grid-template-columns: var(--racecard-columns);
  align-items: stretch;
  gap: 0;
  position: static;
  width: 100%;
  min-width: 0;
  height: auto;
  margin: 0;
  padding: 0;
  border: 0;
}

#racecard-local .raceTable__header::before,
#racecard-local .raceTable__header::after,
#racecard-local .raceTable__details__line::before,
#racecard-local .raceTable__details__line::after,
#racecard-local .raceTable__details__line__item::before,
#racecard-local .raceTable__details__line__item::after {
  content: none;
}

#racecard-local .raceTable__header {
  background: #efefef;
  font-weight: 700;
}

#racecard-local .raceTable__details {
  display: block;
  position: static;
  width: 100%;
  height: auto;
  margin: 0;
  padding: 0;
  border: 0;
}

#racecard-local .raceTable__header__item,
#racecard-local .raceTable__details__line__item {
  display: block;
  position: static;
  width: auto;
  max-width: none;
  min-width: 0;
  height: auto;
  margin: 0;
  padding: 6px 4px;
  border: 0;
  border-right: 1px solid var(--racecard-border);
  border-bottom: 1px solid var(--racecard-border);
  background: transparent;
  color: inherit;
  vertical-align: top;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: normal;
}

#racecard-local .raceTable__header__item__inner,
#racecard-local .raceTable__details__line__item__inner {
  display: block;
  position: static;
  width: 100%;
  height: auto;
  margin: 0;
  padding: 0;
  border: 0;
}

#racecard-local .raceTable__header__item--hide,
#racecard-local .raceTable__details__line__item--hide {
  display: none;
}

#racecard-local .raceTable__header__item--horseNun {
  grid-column: 1;
}

#racecard-local .raceTable__header__item--gateNun {
  grid-column: 2;
}

#racecard-local .raceTable__header__item--horse {
  grid-column: 3;
  text-align: left;
}

#racecard-local .raceTable__header__item--jockey {
  grid-column: 6;
}

#racecard-local .raceTable__header__item--horseNun,
#racecard-local .raceTable__header__item--gateNun,
#racecard-local .raceTable__header__item--jockey {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

#racecard-local .raceTable__header__item--horseNun,
#racecard-local .raceTable__header__item--gateNun {
  padding-right: 2px;
  padding-left: 2px;
}

/* オッズ見出しの下段を残りの高さ全体へ伸ばす。 */
#racecard-local .raceTable__header__item--odds {
  grid-column: 4 / 6;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  align-items: stretch;
  padding: 0;
  border-right: 0;
  text-align: center;
}

#racecard-local .raceTable__header__item--odds__title {
  display: flex;
  align-items: center;
  justify-content: center;
  position: static;
  width: 100%;
  height: auto;
  margin: 0;
  padding: 5px 2px;
  border-right: 1px solid var(--racecard-border);
  border-bottom: 1px solid var(--racecard-border);
  white-space: nowrap;
}

#racecard-local .raceTable__header__item--odds__item {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  position: static;
  width: 100%;
  height: auto;
  min-height: 0;
  margin: 0;
  padding: 0;
}

#racecard-local .raceTable__header__item--odds__item__jra,
#racecard-local .raceTable__header__item--odds__item__local {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: stretch;
  position: static;
  width: auto;
  height: auto;
  min-height: 0;
  margin: 0;
  padding: 2px;
  border: 0;
  border-right: 1px solid var(--racecard-border);
  white-space: nowrap;
}

#racecard-local .raceTable__header__item--odds__item span {
  display: inline;
  position: static;
  width: auto;
  height: auto;
  margin: 0;
  padding: 0;
  transform: none;
}

#racecard-local .raceTable__header__item--before {
  grid-column: 7 / 11;
  display: grid;
  grid-template-rows: 1fr auto;
  padding: 0;
  border-right: 0;
}

#racecard-local .raceTable__header__item--before__details {
  display: block;
  position: static;
  width: 100%;
  height: auto;
  margin: 0;
  padding: 5px 4px;
  border-right: 1px solid var(--racecard-border);
  border-bottom: 1px solid var(--racecard-border);
  text-align: left;
}

#racecard-local .raceTable__header__item--before__list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  position: static;
  width: 100%;
  height: auto;
  margin: 0;
  padding: 0;
}

#racecard-local .raceTable__header__item--before__list__item {
  display: flex;
  align-items: center;
  justify-content: center;
  position: static;
  width: auto;
  height: auto;
  margin: 0;
  padding: 4px;
  border: 0;
  border-right: 1px solid var(--racecard-border);
  text-align: center;
}

#racecard-local .raceTable__details__line {
  background: #fdfdfd;
}

#racecard-local .raceTable__details__line:nth-of-type(even) {
  background: #f9f9f9;
}

#racecard-local .raceTable__details__line__item--horseNun,
#racecard-local .raceTable__details__line__item--gateNun,
#racecard-local .raceTable__details__line__item--odds {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-right: 2px;
  padding-left: 2px;
  text-align: center;
}

#racecard-local .race-number,
#racecard-local .raceTable__details__line__item--odds p,
#racecard-local .raceTable__details__line__item--odds__jra,
#racecard-local .raceTable__details__line__item--odds__local,
#racecard-local .odds-value,
#racecard-local .past-weight,
#racecard-local .raceTable__details__line__item--jockey__weight {
  white-space: nowrap;
  overflow-wrap: normal;
  word-break: normal;
  font-variant-numeric: tabular-nums;
}

#racecard-local .raceTable__details__line__item--odds__jra,
#racecard-local .raceTable__details__line__item--odds__local,
#racecard-local .odds-value {
  display: inline;
  color: #0078d6;
  font-size: 15px;
  font-weight: 700;
}

#racecard-local .odds-top3,
#racecard-local .odds-top3 .odds-value {
  color: #d20b20;
}

#racecard-local .odds-other,
#racecard-local .odds-other .odds-value {
  color: #0078d6;
}

#racecard-local .raceTable__details__line__item--horse > .raceTable__details__line__item__inner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  height: 100%;
}

#racecard-local .raceTable__details__line__item--horse__heading {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: start;
  gap: 4px;
  width: 100%;
  margin: 0 0 3px;
}

#racecard-local .raceTable__details__line__item--horse__name,
#racecard-local .raceTable__details__line__item--horse__name:link,
#racecard-local .raceTable__details__line__item--horse__name:visited,
#racecard-local .raceTable__details__line__item--horse__name:hover,
#racecard-local .raceTable__details__line__item--horse__name:focus,
#racecard-local .raceTable__details__line__item--horse__name:active {
  color: #0078d6;
  font-size: var(--racecard-horse-font-size);
  font-weight: 700;
  overflow-wrap: anywhere;
}

#racecard-local .raceTable__details__line__item--horse__info {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  font-size: 12px;
  text-align: left;
}

#racecard-local .raceTable__details__line__item--horse__info > span {
  display: block;
  position: static;
  width: auto;
  margin: 0;
  padding: 0;
  overflow-wrap: anywhere;
}

#racecard-local .raceTable__details__line__item--horse__info > span > span {
  display: inline;
  margin-right: 3px;
}

#racecard-local .raceTable__details__line__item--horse__info > .raceTable__details__line__item--horse__info__rating {
  align-self: flex-end;
  margin-top: auto;
  padding-top: 3px;
  color: #000000;
  font-size: 14px;
  font-weight: 700;
  text-align: right;
  white-space: nowrap;
}

#racecard-local .raceTable__details__line__item--horse__info__rating:empty {
  display: none;
}

/* 公式sprite（1245×335px）と公式race.cssの20px旗指定を確認。 */
#racecard-local .flags {
  display: block;
  position: static;
  flex: 0 0 20px;
  width: 20px;
  min-width: 20px;
  max-width: 20px;
  height: 14px;
  margin: 2px 0 0;
  padding: 0;
  border: 0;
  background: none;
}

#racecard-local .flags::before {
  content: "";
  display: block;
  position: static;
  width: 20px;
  height: 13px;
  margin: 0;
  padding: 0;
  background-image: none;
  background-repeat: no-repeat;
  background-size: 209px auto;
  transform: none;
}

#racecard-local .flags.flag_usa::before,
#racecard-local .flags.flag_jpn::before {
  background-image: url("https://world.jra-van.jp/img/flags.png");
}

#racecard-local .flags.flag_usa::before {
  background-position: -63px 0;
}

#racecard-local .flags.flag_jpn::before {
  background-position: -147px 0;
}

#racecard-local .flags::after {
  content: none;
}

#racecard-local .raceTable__details__line__item--jockey {
  text-align: center;
}

#racecard-local .raceTable__details__line__item--jockey > .raceTable__details__line__item__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}

#racecard-local .cloth-space,
#racecard-local .current-jockey-slot,
#racecard-local .current-weight-slot {
  display: contents;
}

#racecard-local .raceTable__details__line__item--jockey__cloth {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  margin: 3px auto;
  padding: 0;
  border: 0;
  background: none;
}

#racecard-local .raceTable__details__line__item--jockey__name,
#racecard-local .race-jockey,
#racecard-local .raceTable__details__line__item--jockey__name a,
#racecard-local .race-jockey a {
  color: #000;
}

#racecard-local .raceTable__details__line__item--jockey__name,
#racecard-local .raceTable__details__line__item--jockey__weight {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
  text-align: center;
}

#racecard-local .raceTable__details__line__item--before.number-one {
  background: #ffe4e4;
}

#racecard-local .raceTable__details__line__item--before.number-two {
  background: #fff7e3;
}

#racecard-local .raceTable__details__line__item--before.number-three {
  background: #e1f8ff;
}

#racecard-local .raceTable__details__line__item--before__info {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: center;
  gap: 4px;
  position: static;
  width: 100%;
  height: auto;
  margin: 0 0 3px;
  padding: 0;
}

#racecard-local .raceTable__details__line__item--before__info__rank {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: stretch;
  position: static;
  width: 24px;
  height: auto;
  margin: 0;
  padding: 0;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.25;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

#racecard-local .raceTable__details__line__item--before__info__rank span {
  display: inline;
  position: static;
  width: auto;
  height: auto;
  margin: 0;
  padding: 0;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  transform: none;
}

#racecard-local .raceTable__details__line__item--before__info__name {
  display: block;
  position: static;
  width: 100%;
  height: auto;
  margin: 0;
  padding: 0;
  overflow-wrap: anywhere;
  word-break: normal;
}

#racecard-local .race-name {
  display: block;
  position: static;
  width: 100%;
  height: auto;
  margin: 0;
  padding: 0;
  color: #000;
  font-size: 12px;
  font-weight: 700;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: normal;
}

#racecard-local .race-name a,
#racecard-local a.race-name,
#racecard-local .race-name :is(a:link, a:visited, a:hover, a:focus, a:active),
#racecard-local a.race-name:is(:link, :visited, :hover, :focus, :active),
#racecard-local .race-name .grade {
  color: #000;
  font-weight: 700;
}

#racecard-local .race-name .grade {
  display: inline;
  width: auto;
  font-size: inherit;
  white-space: nowrap;
}

#racecard-local .race-venue:empty {
  display: none;
}

#racecard-local .raceTable__details__line__item--before__details {
  display: block;
  position: static;
  width: 100%;
  height: auto;
  margin: 0;
  padding: 0;
  color: #252525;
  font-size: 12px;
  text-align: left;
  overflow-wrap: anywhere;
  word-break: normal;
}

#racecard-local .race-time {
  font-size: 14px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* 表が利用できる実際の幅で切り替え、ページ本体へ横幅を伝播させない。 */
@container racecard (width < 960px) {
  #racecard-local .raceCont__inner {
    overflow-x: auto;
    overflow-y: visible;
  }

  #racecard-local .raceTable {
    width: 1200px;
    min-width: 1200px;
  }
}
