/* rd_list (作り直しの mock): 商品一覧 ・ 絞り込み ・ 弾の選び方 ・ 空のカート / 検索 0 件
   店の色: 赤 #8A060D / #7E0308 / #B80A11、金 #D99A23 (customize.css の値)。新しい色は足していない (灰と白のみ)。 */

/* ---------- 幅 (一覧の頁だけ広げる。左の弾の欄と右の注目商品は出さない) ---------- */
body.product_page .ec-layoutRole .ec-layoutRole__contents { max-width: 1400px; }
body.product_page .ec-layoutRole__contents,
body.product_page .ec-layoutRole__main { min-width: 0; }
.rd-list { width: 100%; max-width: 1400px; margin: 0 auto; padding: 0 12px 24px; box-sizing: border-box; color: #222; }
.rd-list * { box-sizing: border-box; }

/* ---------- 上の 1〜2 段 ---------- */
.rd-top { display: flex; align-items: center; gap: 8px; min-height: 40px; }
.rd-crumb { flex: 1 1 auto; min-width: 0; margin: 0; padding: 0; }
.rd-crumb ul { display: flex; flex-wrap: nowrap; align-items: center; margin: 0; padding: 0; list-style: none; overflow-x: auto; white-space: nowrap; scrollbar-width: none; font-size: 12px; }
.rd-crumb ul::-webkit-scrollbar { display: none; }
.rd-crumb li { flex: none; margin: 0; padding: 0; }
.rd-crumb li + li::before { content: "›"; margin: 0 6px; color: #888; }
.rd-crumb a { color: #555; text-decoration: none; font-size: 12px; }
.rd-crumb__now { min-width: 0; }
.rd-crumb__now h1 { margin: 0; padding: 0; font-size: 14px; font-weight: bold; line-height: 1.4; color: #222; border: 0; background: none; display: inline; }
.rd-series-btn { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 44px; padding: 0 12px; border: 1px solid #7E0308; border-radius: 2px; background: #fff; color: #7E0308; font-size: 13px; font-weight: bold; cursor: pointer; }
.rd-series-btn[aria-expanded="true"] { background: #7E0308; color: #fff; }
.rd-caret { width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg) translate(-2px, -2px); transition: transform .15s; }
.rd-series-btn[aria-expanded="true"] .rd-caret { transform: rotate(-135deg) translate(-2px, -2px); }

/* 弾のタイル */
.rd-series { margin: 4px 0 10px; padding: 10px; border: 1px solid #ddd; border-radius: 2px; background: #fafafa; }
.rd-series[hidden] { display: none; }
.rd-series__hd { margin: 0 0 8px; font-size: 13px; font-weight: bold; }
.rd-series__hd a { color: #7E0308; }
.rd-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; margin: 0; padding: 0; list-style: none; }
.rd-tile { display: flex; align-items: center; width: 100%; min-height: 44px; padding: 8px 10px; border: 1px solid #c8c8c8; border-radius: 2px; background: #fff; color: #222; font-size: 13px; line-height: 1.4; text-decoration: none; }
.rd-tile > span { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.rd-tile:hover { border-color: #7E0308; color: #7E0308; opacity: 1; }
.rd-tile.is-on { border-color: #7E0308; background: #7E0308; color: #fff; font-weight: bold; }
.rd-tiles li { margin: 0; display: flex; align-items: stretch; }
.rd-tiles li > a { flex: 1 1 auto; }
.rd-tiles--genre { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.rd-old { margin-top: 10px; }
.rd-old > summary { cursor: pointer; display: flex; align-items: center; min-height: 44px; padding: 0 4px; font-size: 13px; font-weight: bold; color: #7E0308; list-style: none; }
.rd-old > summary::-webkit-details-marker { display: none; }
.rd-old > summary::before { content: "＋"; margin-right: 6px; }
.rd-old[open] > summary::before { content: "－"; }
.rd-oldlist { margin: 0; padding: 0; list-style: none; columns: 1; column-gap: 12px; }
.rd-oldlist li { break-inside: avoid; margin: 0; border-bottom: 1px solid #eee; }
.rd-oldlist a { display: block; padding: 10px 4px; font-size: 13px; line-height: 1.4; color: #222; text-decoration: none; }
.rd-oldlist a.is-on { color: #7E0308; font-weight: bold; }
.rd-legacy .contents_left_list_area { display: block !important; }
.rd-legacy .contents_left_list_area_hd { display: none; }
.rd-legacy .side_midashi { display: none; }
.rd-legacy .contents_left_list_item_title { margin: 10px 0 2px; font-size: 13px; font-weight: bold; color: #7E0308; }
.rd-legacy .contents_left_list_item_ul { margin: 0; padding: 0; list-style: none; }
.rd-legacy .contents_left_list_item_ul a { display: block; padding: 9px 4px; border-bottom: 1px solid #eee; font-size: 13px; color: #222; text-decoration: none; }

/* 件数 ・ 絞り込み ・ 並び ・ 次へ の 1 段 */
.rd-bar { background: #fff; }
.rd-bar__row { display: flex; align-items: center; flex-wrap: nowrap; gap: 6px; min-height: 48px; padding: 2px 0; }
.rd-count { flex: none; font-size: 12px; white-space: nowrap; }
.rd-count b { font-size: 16px; }
.rd-filter-btn { flex: none; display: inline-flex; align-items: center; justify-content: center; gap: 4px; height: 44px; padding: 0 10px; border: 2px solid #7E0308; border-radius: 0; background: #fff; color: #7E0308; font-size: 14px; font-weight: bold; cursor: pointer; }
.rd-filter-btn:active { background: #7E0308; color: #fff; }
.rd-badge { display: inline-block; min-width: 18px; padding: 0 4px; border-radius: 0; background: #7E0308; color: #fff; font-size: 12px; font-style: normal; line-height: 18px; text-align: center; }
.rd-sort, .rd-disp, .rd-sel { display: flex; align-items: center; gap: 6px; margin: 0; min-width: 0; }
.rd-sort { flex: 1 1 auto; }
.rd-sort__lb { font-size: 12px; white-space: nowrap; color: #555; }
.rd-sort .ec-select, .rd-disp .ec-select { margin: 0; flex: 1 1 auto; min-width: 0; }
.rd-sel select, .rd-bar select { width: 100%; height: 40px; padding: 0 28px 0 10px; border: 1px solid #c8c8c8; border-radius: 2px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23555'/%3E%3C/svg%3E") no-repeat right 10px center; -webkit-appearance: none; appearance: none; color: #222; font-size: 13px; cursor: pointer; }
.rd-sel select:hover { border-color: #888; }
.rd-sel select:focus-visible { outline: 2px solid #D99A23; outline-offset: 1px; }
.rd-sel .ec-select::after, .rd-sel .ec-select::before { display: none; }
.rd-disp { display: none; }

@media (max-width: 767px) {
  .rd-sort__lb { display: none; }
}

/* ---------- 商品の格子 ---------- */
.rd-list .ec-shelfRole { padding: 0; }
.rd-list .ec-shelfGrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 6px; margin: 0; padding: 0; list-style: none; }
.rd-list .ec-shelfGrid .ec-shelfGrid__item { display: flex; flex-direction: column; width: auto; margin: 0; padding: 0 !important; min-width: 0; font-size: 12px; }
.rd-list .ec-shelfGrid__item > a { display: block; color: inherit; text-decoration: none; }
.rd-list .ec-shelfGrid__item-image { margin: 0 0 4px; }
.rd-list .ec-shelfGrid__item-image img { display: block; width: 100%; height: auto; aspect-ratio: 264 / 370; object-fit: contain; background: #f4f4f4; }
.rd-list .ec-shelfGrid .ec-shelfGrid__item-image.soldOut::after { top: calc(50% - 8px); font-size: 14px; }
/* カード名と型番は 12px 以上 (プラグインの em の組み方は崩さず、基準の字だけ決める) */
.rd-list .ec-shelfGrid .ec-shelfGrid__item-text { font-size: 12px; line-height: 1.35; margin: 0; }
.rd-list .ec-shelfGrid .mzk .mzk-n { font-size: 13px; }
.rd-list .ec-shelfGrid .mzk .mzk-m { font-size: 12px; }
.rd-list .ec-shelfGrid .mzk .mzk-r, .rd-list .ec-shelfGrid .mzk .mzk-f, .rd-list .ec-shelfGrid .mzk .mzk-c { font-size: 12px; }
.rd-list .ec-shelfGrid .price02-default { margin: 2px 0 0; text-align: left; font-size: 15px; font-weight: bold; line-height: 1.3; color: #8A060D; white-space: nowrap; }
.rd-list .ec-shelfGrid .price02-default small { font-size: 12px; font-weight: normal; color: #555; margin-left: 1px; }
.rd-buy { margin-top: auto; padding-top: 4px; }
.rd-list .ec-shelfGrid .productStock { margin: 0 0 3px; font-size: 12px; color: #555; }
.rd-list .ec-shelfGrid .ec-productRole__actions { margin: 0; padding: 0; }
.rd-list .ec-shelfGrid .ec-numberInput { display: flex; align-items: center; gap: 4px; margin: 0; padding: 0; }
.rd-list .ec-shelfGrid .ec-numberInput > span { flex: none; font-size: 12px; }
.rd-list .ec-shelfGrid .ec-numberInput input[type='number'] { flex: 1 1 auto; width: 100%; max-width: none; min-width: 0; height: 44px; margin: 0; padding: 0 4px; text-align: center; font-size: 16px; border: 1px solid #222; border-radius: 2px; }
.rd-list .ec-shelfGrid .ec-select select { height: 44px; font-size: 12px; }
.rd-list .ec-shelfGrid .rd-btnwrap { margin: 4px 0 0; padding: 0; }
.rd-list .ec-shelfGrid .ec-productRole__btn .ec-blockBtn--action { width: 100%; height: 44px; padding: 0 2px; font-size: 12px; line-height: 1.2; border-radius: 2px; color: #fff; white-space: nowrap; }
.rd-list .ec-shelfGrid .ec-productRole__btn .ec-blockBtn--action:disabled { background: #bbb; color: #fff; }
@media (max-width: 359px) {
  .rd-list .ec-shelfGrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rd-list { padding: 0 8px 24px; }
}
@media (min-width: 768px) {
  .rd-list .ec-shelfGrid { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px 10px; }
  .rd-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .rd-tiles--genre { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .rd-oldlist { columns: 2; }
  .rd-disp { display: flex; flex: none; }
  .rd-sort { flex: none; }
  .rd-sel select { width: auto; min-width: 120px; }
  .rd-rar select { min-width: 150px; }
  .rd-bar__row { justify-content: flex-start; }
  .rd-filter-btn { display: none; }
}
@media (min-width: 960px) {
  .rd-list .ec-shelfGrid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .rd-tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .rd-oldlist { columns: 3; }
}
@media (min-width: 1200px) {
  .rd-list .ec-shelfGrid { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 20px 10px; }
  /* PC は小さい画面より少し大きく (6 列より字を詰めない) */
}

/* ---------- 絞り込みの板 (SP) ---------- */
.rd-sheet[hidden] { display: none; }
.rd-sheet { position: fixed; inset: 0; z-index: 2000; }
.rd-sheet__ov { position: absolute; inset: 0; background: rgba(0, 0, 0, .45); }
.rd-sheet__panel { position: absolute; left: 0; right: 0; bottom: 0; height: 56vh; height: 56dvh; min-height: 380px; max-height: 92dvh; display: flex; flex-direction: column; background: #fff; border-radius: 0; box-shadow: 0 -4px 16px rgba(0, 0, 0, .25); animation: rd-up .18s ease-out; }
@keyframes rd-up { from { transform: translateY(40px); opacity: .6; } to { transform: none; opacity: 1; } }
.rd-sheet__hd { flex: none; display: flex; align-items: center; justify-content: space-between; padding: 0 8px 0 14px; height: 48px; border-bottom: 3px solid #7E0308; font-size: 16px; }
.rd-sheet__x { height: 44px; min-width: 44px; padding: 0 10px; border: 0; background: none; color: #555; font-size: 14px; cursor: pointer; }
.rd-sheet__body { flex: 1 1 auto; overflow-y: auto; padding: 8px 14px; -webkit-overflow-scrolling: touch; }
.rd-fs { margin: 0 0 10px; padding: 0; border: 0; min-width: 0; }
.rd-fs legend { padding: 0; margin: 4px 0 6px; font-size: 14px; font-weight: bold; }
.rd-fs legend small { font-weight: normal; color: #666; font-size: 12px; }
.rd-boxes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.rd-box { position: relative; display: block; margin: 0; }
.rd-box input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.rd-box span { display: flex; align-items: center; justify-content: center; gap: 4px; min-height: 44px; padding: 0 6px; border: 1px solid #888; border-radius: 0; background: #fff; font-size: 14px; font-weight: bold; text-align: center; }
.rd-box span small { font-size: 12px; font-weight: normal; color: #666; }
.rd-box input:checked + span { background: #7E0308; border-color: #7E0308; color: #fff; }
.rd-box input:checked + span small { color: #f0d0d0; }
.rd-box input:focus-visible + span { outline: 3px solid #D99A23; outline-offset: 1px; }
.rd-box--wide { max-width: 240px; }
.rd-price { display: flex; align-items: center; gap: 8px; }
.rd-price input { flex: 1 1 0; min-width: 0; height: 44px; padding: 0 10px; border: 1px solid #888; border-radius: 2px; font-size: 16px; }
.rd-sheet__ft { flex: none; display: flex; gap: 8px; padding: 8px 14px calc(8px + env(safe-area-inset-bottom)); border-top: 1px solid #ddd; background: #fff; }
.rd-btn { display: inline-flex; align-items: center; justify-content: center; height: 44px; padding: 0 14px; border-radius: 2px; font-size: 14px; font-weight: bold; text-decoration: none; cursor: pointer; border: 1px solid #7E0308; }
.rd-btn--main { background: #7E0308; color: #fff; flex: 1 1 auto; }
.rd-btn--ghost { background: #fff; color: #7E0308; flex: none; }
.rd-btn[disabled] { opacity: .5; }
body.rd-sheet-open { overflow: hidden; }
@media (min-width: 768px) { .rd-sheet { display: none !important; } }

/* ---------- 検索 0 件 / 空のカート ---------- */
.rd-empty { padding: 16px 4px 24px; }
.rd-empty__hd { margin: 0 0 12px; font-size: 16px; font-weight: bold; line-height: 1.5; }
.rd-empty__tips { margin: 12px 0 16px; padding-left: 1.2em; font-size: 13px; line-height: 1.8; }
.rd-empty__tips a { color: #7E0308; text-decoration: underline; }
.rd-empty__h2 { margin: 20px 0 8px; padding: 0 0 4px; border-bottom: 2px solid #7E0308; font-size: 15px; font-weight: bold; }
.rd-cart-empty { padding: 8px 0 24px; }
.rd-cart-empty .rd-empty__hd { font-size: 16px; }
.rd-cart-empty .rd-btn { margin: 0 0 12px; }

/* ---------- 11-04 直し (先輩の 6 点): 左の弾の欄 ・ レア度のプルダウン ・ 在庫あり ・ 数字のページ送り ---------- */
.rd-pc-only { display: none !important; }
.rd-side { display: none; }
@media (min-width: 768px) {
  .rd-pc-only { display: revert !important; }
  label.rd-pc-only, a.rd-pc-only, div.rd-pc-only { display: flex !important; }
}
/* 左の欄 (PC 960px 以上。前の店と同じく弾の一覧 ・ 店の案内 ・ X) */
@media (min-width: 960px) {
  .rd-wrap { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 0 30px; max-width: 1640px; margin: 0 auto; padding: 0 12px; box-sizing: border-box; }
  .rd-wrap > .rd-list { max-width: none; padding: 0 0 24px; }
  body.product_page .ec-layoutRole .ec-layoutRole__contents { max-width: 1640px; }
  .rd-side { display: block; padding-top: 8px; }  /* 中身は元の contents_left_box のまま (11-04 先輩「サイドバーは何も弄らず」) */
  .rd-side__box { margin-bottom: 16px; }
  .rd-side__hd { margin: 0; padding: 8px 10px; background: #7E0308; color: #fff; font-size: 14px; font-weight: bold; letter-spacing: .05em; }
  .rd-series--side { margin: 0; padding: 0; border: 1px solid #ddd; border-top: 0; background: #fff; }
  .rd-series--side .rd-series__hd { margin: 0; padding: 8px 10px; border-bottom: 1px solid #eee; font-size: 12px; color: #555; font-weight: normal; }
  .rd-series--side .rd-tiles { display: block; }
  .rd-series--side .rd-tiles li { display: block; }
  .rd-series--side .rd-tile { min-height: 0; padding: 9px 10px 9px 12px; border: 0; border-bottom: 1px solid #eee; border-left: 3px solid transparent; font-size: 13px; }
  .rd-series--side .rd-tile:hover { background: #fbf3f3; border-left-color: #c9a0a2; }
  .rd-series--side .rd-tile.is-on { background: #fbf3f3; color: #7E0308; border-left-color: #7E0308; }
  .rd-series--side .rd-old { margin: 0; border-bottom: 1px solid #eee; }
  .rd-series--side .rd-old > summary { min-height: 40px; padding: 0 10px; }
  .rd-series--side .rd-oldlist { columns: 1; max-height: 420px; overflow-y: auto; }
  .rd-series--side .rd-oldlist a { padding: 8px 10px; }
  .rd-series--side .rd-legacy { padding: 0 10px 8px; }
  .rd-side .rd-tiles { display: block; }
  .rd-side > .rd-side__box > .rd-tiles .rd-tile { border: 1px solid #ddd; border-top: 0; min-height: 0; }
  .rd-sp-only, .rd-series-btn { display: none !important; }
  .rd-wrap .rd-bar { margin: 0 0 12px; padding: 0; }
}
/* 上の段 */
@media (min-width: 768px) {
  .rd-bar__row { gap: 14px; flex-wrap: wrap; }
  .rd-sel { flex: none; gap: 6px; }
  .rd-stock { flex: none; align-items: center; gap: 6px; height: 40px; padding: 0 4px; color: #222; font-size: 13px; text-decoration: none; white-space: nowrap; }
  .rd-stock i { width: 18px; height: 18px; border: 1px solid #888; border-radius: 2px; background: #fff; position: relative; }
  .rd-stock.is-on i { background: #7E0308; border-color: #7E0308; }
  .rd-stock.is-on i::after { content: ""; position: absolute; left: 5px; top: 1px; width: 5px; height: 10px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
  .rd-stock:hover { color: #7E0308; opacity: 1; }
  .rd-clear { flex: none; align-items: center; height: 40px; color: #7E0308; font-size: 12px; text-decoration: underline; }
  .rd-bar__pg { align-items: center; justify-content: space-between; gap: 12px; padding: 6px 0 8px; border-top: 1px solid #eee; }
  .rd-bar { position: sticky; top: var(--rd-hdr-h, 0px); z-index: 30; border-bottom: 1px solid #ddd; margin: 0 -12px 12px; padding: 0 12px; }
}
.rd-range { font-size: 12px; color: #555; white-space: nowrap; }
/* 数字のページ送り: 今の頁を店の赤で塗る、他は白地に灰の枠 */
.rd-pg { display: flex; align-items: center; flex-wrap: wrap; gap: 4px; }
.rd-pg__n, .rd-pg__step { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; height: 34px; padding: 0 8px; border: 1px solid #c8c8c8; border-radius: 2px; background: #fff; color: #222; font-size: 13px; text-decoration: none; box-sizing: border-box; }
.rd-pg a:hover { border-color: #7E0308; color: #7E0308; opacity: 1; }
.rd-pg__n.is-on { background: #7E0308; border-color: #7E0308; color: #fff; font-weight: bold; }
.rd-pg__step { font-weight: bold; color: #7E0308; }
.rd-pg__step.is-off { color: #bbb; border-color: #e4e4e4; }
.rd-pg__gap { min-width: 16px; text-align: center; color: #888; }
.rd-pager-bt { display: flex; flex-direction: column; align-items: center; gap: 8px; margin: 24px 0 8px; }
.rd-pg--big .rd-pg__n, .rd-pg--big .rd-pg__step { min-width: 44px; height: 44px; font-size: 15px; }
@media (max-width: 767px) {
  .rd-pg--big { gap: 3px; justify-content: center; }
  .rd-pg--big .rd-pg__n { min-width: 40px; padding: 0 4px; }
  .rd-pg--big .rd-pg__step { padding: 0 8px; }
}
