/* =========================
   Page Layout
========================= */

.all-games-page {
  margin: 0 auto;
  padding: 40px 0px;
}

.all-games-header h1{
  font-size: 42px;
  margin-bottom: 40px;
  margin-left: 20px;
  line-height: 1.8em;
  font-weight: 400;
  text-transform: none;
}

/* =========================
   Table Base
========================= */

.table-scroll {
  position: relative;
  overflow-x: auto;
}

.all-games-table table {
  width: 100%;
  min-width: 1400px;
  border-collapse: separate;
  border-spacing: 0;
}

.all-games-table th,
.all-games-table td {
  padding: 8px;
  text-align: center;
  background: #fff;
  white-space: pre-line;
  font-size: 18px;
  line-height: 1.2;
  font-weight: 500;
}



/* =========================
   Sticky Header
========================= */

.all-games-table thead th {
  position: sticky;
  top: 0;
  z-index: 3;
  color: #fff;
  background: #9c4747;
}

.all-games-table thead .col-date,
.all-games-table thead .col-opponent {
  z-index: 4;
}

/* =========================
   Sticky Columns
========================= */

.col-date {
  position: sticky;
  left: 0;
  z-index: 2;
  min-width: 120px;
  background: #fff;
}

.col-opponent {
  position: sticky;
  left: 120px;
  z-index: 2;
  min-width: 140px;
  background: #fff;
}

/* =========================
   Column Alignment
========================= */

.col-scorers,
.col-topic {
  text-align: left !important;
}


/* =========================
   Competition Row Colors
========================= */

/* J1：薄い赤 */
tr.comp-j1 td {
  background-color: #e2bebe;
}

/* EC：薄い緑 */
tr.comp-ec td {
  background-color: #c8d6c8;
}

/* LC：薄い黄 */
tr.comp-lc td {
  background-color: #dfdec8;
}

/* ACL：薄い紫 */
tr.comp-acl td {
  background-color: #c3b8cb;
}

/* PSM（プレシーズン） */
tr.comp-psm td {
  background-color: #d5e5e7;
}

/* CWC：薄いゴールド寄り */
tr.comp-cwc td {
  background-color: #ece2c5;
}

/* TM（テストマッチ）：薄いグレー */
tr.comp-tm td {
  background-color: #e0e0e0;
}

/* CS*/
tr.comp-cs td {
  background-color: #bcd3db;
}

/* その他 */
tr.comp-other td {
  background-color: #f2f2f2;
}



/* =========================
   Result Badge
========================= */

td.res-win,
td.res-draw,
td.res-lose {
  vertical-align: middle;
  line-height: 0;
  color: #fff;

}

/* WIN */
td.res-win {
  font-weight: 700;
  background-color: #b46f6f  !important;
}

/* DRAW */
td.res-draw {
  background-color: #777777 !important; 
}

/* LOSE */
td.res-lose {
  background-color: #4b4b4b  !important;
}



.filters {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.filter-pill {
  display: flex;
  align-items: center;
  gap: 8px;

  padding: 8px 14px;
  border-radius: 999px;

}

/* =========================
   Pagination (Pill Style)
========================= */

.pagination button {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid #ddd;

  background: #f5f5f5;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}

.pagination button:hover {
  background: #eee;
}

.pagination button:disabled {
  opacity: 0.4;
  cursor: default;
}

/* Page indicator */
#page-indicator {
  padding: 8px 14px;
  border-radius: 999px;
  background: #fff;

  border: 1px solid #ddd;
  font-size: 14px;
  font-weight: 500;
}


.all-games-pagination {
  display: flex;
  justify-content: center;   /* ← センター */
  align-items: center;
  gap: 12px;

  margin-top: 32px;
}

.all-games-pagination button {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid #ddd;

  background: #f5f5f5;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  color: #000;
}

.all-games-pagination button:hover {
  background: #eee;
}

.all-games-pagination button:disabled {
  opacity: 0.4;
  cursor: default;
}

#page-indicator {
  padding: 8px 14px;
  border-radius: 999px;

  background: #fff;
  border: 1px solid #ddd;

  font-size: 14px;
  font-weight: 500;
}

.all-games-table thead th.col-date,
.all-games-table thead th.col-opponent {
  background-color: #703030; 
}

.col-scorers {
  white-space: nowrap; 
  min-width: 150px;
}


.col-stadium {
  white-space: nowrap;
  min-width: 90px;
  max-width: 120px;
}

/* Res（結果）列 */
.col-result {
  white-space: nowrap;
  min-width: 80px;
}








.table-scroll {
  overflow-x: auto;
  position: relative;
  background: #e2bebe;
}

.agd-filter-box select {
  border: none !important;
  outline: none;
  box-shadow: none;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}


.agd-secret-link {
  text-align: center;
  margin: 30px 0 0;
}

.agd-secret-link a {
  font-size: 12px;
  color: #777;
  text-decoration: none;
}

.agd-secret-link a:hover {
  color: #000;
}




/* =========================
   FORCE: Card View on ALL devices
========================= */
.all-games-table{
  display: none !important;
}

.all-games-cards{
  display: block !important;
  max-width: 572px;
  margin: 0 auto;
}

/* =========================
   Card View (ALL devices)
========================= */


.all-games-cards{
  display: block;
}

.agd-cards{
  display: flex;
  flex-direction: column;
  gap: 0px;
}

.agd-card{
  overflow: hidden;
  cursor: pointer;
}

.agd-card.ha-home { background: #fff; } /* 赤系 */
.agd-card.ha-away { background: #d7d7d7; } 
.agd-card.ha-none { background: #d7d7d7; }

/* -------------------------
   Header (Row 1)
------------------------- */

.agd-card__head{
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(255,255,255,.65);
  border-bottom: 1px solid rgba(0,0,0,.06);
}

/* 日付左のカテゴリ箱 */
.agd-compbox{
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
  padding: 4px 10px;
  background: rgba(255,255,255,.55);
  color: rgba(0,0,0,.75);
  white-space: nowrap;
}

/* カテゴリ色 */
.agd-compbox.comp-j1    { background:#e2bebe; }
.agd-compbox.comp-ec    { background:#c8d6c8; }
.agd-compbox.comp-lc    { background:#dfdec8; }
.agd-compbox.comp-acl   { background:#c3b8cb; }
.agd-compbox.comp-psm   { background:#d5e5e7; }
.agd-compbox.comp-cwc   { background:#ece2c5; }
.agd-compbox.comp-tm    { background:#e0e0e0; }
.agd-compbox.comp-cs    { background:#bcd3db; }
.agd-compbox.comp-other { background:#f2f2f2; }

.agd-date{
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .02em;
  white-space: nowrap;
  margin-left: 10px;
}

.agd-time{
  font-size: 13px;
  font-weight: 800;
  opacity: .85;
  white-space: nowrap;
}

.agd-sta{
  margin-left: 0;
  font-size: 12px;
  font-weight: 900;
  opacity: .75;
  white-space: nowrap;
}

.agd-att{
  margin-left: 0;
  font-size: 12px;
  font-weight: 900;
  opacity: .75;
  white-space: nowrap;
}

/* -------------------------
   Main (Row 2)
------------------------- */

.agd-card__main{
  padding: 12px 12px 14px;
  background: rgba(255,255,255,.65);
}

.agd-line2{
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
  margin-left: 50px;
}

.agd-vs{
  font-size: 15px;
  font-weight: 900;
  line-height: 1.2;
}

.agd-ha{
  font-size: 12px;
  font-weight: 900;
  opacity: .75;
  margin-left: -2px;
  white-space: nowrap;
}

.agd-score{
  font-size: 18px;
  font-weight: 900;
  letter-spacing: .06em;
  white-space: nowrap;
}

.agd-res{
  font-size: 10px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #fff;
  font-weight: 900;
  white-space: nowrap;

  position: relative;
  top: -3px; 
}
.agd-res.win  { background:#b46f6f; }
.agd-res.draw { background:#777; }
.agd-res.lose { background:#4b4b4b; }
.agd-res.none { background:rgba(0,0,0,.35); }

/* -------------------------
   Expand
------------------------- */

.agd-expand{
  display: none;
  padding: 14px 14px 16px;
  border-top: 1px solid rgba(0,0,0,.08);
  background: rgba(255,255,255,.75);
  font-size: 12px;
  line-height: 1.6;
  word-break: break-word;
}

.agd-card.is-open .agd-expand{
  display: block;
}

.agd-meta{
  position: relative;
  padding-left: 12px;
  margin: 0 0 14px;
}
.agd-meta:last-child{ margin-bottom: 0; }

.agd-meta__title{
  font-weight: 900;
  font-size: 13px;
  letter-spacing: .06em;
}

.agd-meta__body{
  font-size: 14px;
  line-height: 1.8;
  word-break: break-word;
  white-space: pre-line; 
}

/* 縦長バー */
.agd-meta::before{
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 4px;
  height: 18px;
  background: #999;
}

/* 色指定 */
.agd-meta--goal::before{  background: #b46f6f; }
.agd-meta--topic::before{ background: #749674; }
.agd-meta--ref::before{   background: #62dce1; }

/* タイトル：小さめ + センター */
.all-games-header h1{
  font-size: 28px;
  margin: 0 0 16px;
  line-height: 1.15;
  text-align: center;
}

/* ヘッダー内を中央 */
.all-games-header{
  display: flex;
  flex-direction: column;
  align-items: center;
}

.filters{
  width: 100%;
  max-width: 520px;
  margin: 0 auto 14px;
  gap: 0px;
  flex-direction: column;
}

/* pill統一 */
.filter-pill{
  width: 100%;
  padding: 4px 24px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.filter-label{
  min-width: 84px;
  font-size: 12px;
  font-weight: 800;
  opacity: .85;
}

.filter-pill select{
  flex: 1;
  min-width: 0;
  font-size: 13px;
  height: 36px;
  padding: 0 10px;
  border-radius: 12px;
  background: #fff;
}

