.result {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}

/* 見出し */
.result th {
  background: #222;
  color: #fff;
  padding: 14px;
  text-align: center;
  font-weight: bold;
}

/* 通常行 */
.result td {
  padding: 12px;
  text-align: center;
  border-bottom: 1px solid #eee;
}

/* ストライプ */
.result tr:nth-child(even) {
  background: #f9f9f9;
}

/* ホバー */
.result tr:hover {
  background: #f1f7ff;
}

/* 上位3チーム */
.result tr:nth-child(2) {
  background: linear-gradient(90deg,#fff8dc,#ffe066);
  font-weight: bold;
}

.result tr:nth-child(3) {
  background: linear-gradient(90deg,#f0f0f0,#dcdcdc);
  font-weight: bold;
}

.result tr:nth-child(4),
.result tr:nth-child(5) {
  /*background: linear-gradient(90deg,#fff5e6,#ffcc80);*/
  font-weight: bold;
}

/* 順位を目立たせる */
.result td:first-child {
  font-weight: bold;
  font-size: 16px;
}


.cycle_result p{
	text-align: center;
	font-weight: bold;
	font-size: small;
}

.top3 {
  display: flex;
  gap: 20px;
  margin-bottom: 40px;
}

.rank {
  flex: 1;
  padding: 20px;
  border-radius: 15px;
  color: #fff;
  font-weight: bold;
}

.gold { background: linear-gradient(45deg,#f9d423,#ff4e50); }
.silver { background: linear-gradient(45deg,#bdc3c7,#2c3e50); }
.bronze { background: linear-gradient(45deg,#d1913c,#ffd194); color:#000; }

/*==追加==*/
.event-accordion details {
  margin-bottom: 10px;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.event-accordion summary {
  cursor: pointer;
  padding: 14px 16px;
  font-weight: bold;
  position: relative;
  list-style: none;
}

/* ▶マーク消す（Safari対策含む） */
.event-accordion summary::-webkit-details-marker {
  display: none;
}

/* カスタム矢印 */
.event-accordion summary::after {
  content: "＋";
  position: absolute;
  right: 16px;
  transition: 0.3s;
}

/*-------------------------------------
　　大会結果発表一覧変更（Flexbox崩れ防止版）
-------------------------------------*/
/* セクション共通の見出し（既存維持） */
h2.cycle, h2.roge, h2.shimano {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 80px;
    padding: 0 15px;
    line-height: 1.2; 
    overflow: hidden;
    padding-left: 35px;
    font-weight: bold;
    border-left: 6px solid #0056b3;
    margin-bottom: 20px;
}
h2.roge { border-color: #28a745; }
h2.shimano { border-color: #f39c12; }

h2.cycle::before, 
h2.roge::before, 
h2.shimano::before {
    content: attr(data-en);
    position: absolute;
    left: 10px;
    top: 50%; 
    transform: translateY(-50%);
    font-size: 3rem;
    font-weight: 900;
    color: rgba(0, 0, 0, 0.05);
    white-space: nowrap;
    z-index: 1;
    pointer-events: none;
}

/* 画像とリストを包む全体のコンテナ（新設・崩れを根本防止） */
.past-section-wrap {
    display: flex;
    flex-direction: column; /* スマホでは縦並び */
    gap: 20px;
    margin-bottom: 50px;
    width: 100%;
    box-sizing: border-box;
}

/* --- PC・タブレット（幅768px以上）で7:3の横並びをカチッと固定 --- */
@media (min-width: 768px) {
    .past-section-wrap {
        flex-direction: row; /* 横並びに変更 */
        align-items: flex-start; /* 上揃え */
        gap: 4%; /* 画像と右側の間の隙間を4%に設定 */
    }

    /* 左側（7割エリア）：画像と注釈の幅 */
    .past-left-img {
        width: 66%; /* ほぼ7割に設定 */
        flex-shrink: 0;
    }

    /* 右側（3割エリア）：アコーディオンや説明文の幅 */
    .past-right-list {
        width: 30%; /* 3割に設定 */
        flex-grow: 1;
    }

    /* 2番目のロゲイニングセクションだけ左右を入れ替える */
    .past-section-wrap.reverse-layout {
        flex-direction: row; 
    }
}

/* 画像の共通装飾（既存維持） */
.past-left-img img {
    width: 100% !important;
    height: auto !important;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
    display: block;
}
.past-left-img img:hover {
    transform: scale(1.01);
}

/* 注釈テキスト */
.past-left-img p {
    font-size: 0.8rem;
    color: #666;
    margin-top: 10px;
    text-align: center;
}

/* しまのわの説明文テキスト（3割枠内用） */
.shima-text {
    font-size: 0.9rem;
    line-height: 1.6;
    color: #333;
    margin-top: 0;
    margin-bottom: 20px;
    text-align: left;
}

/* アコーディオンのデザインを一新（既存維持） */
.event-accordion details {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    margin-bottom: 10px;
    overflow: hidden;
    transition: 0.3s;
    width: 100%;
    box-sizing: border-box;
}
.event-accordion summary {
    padding: 12px 15px;
    background: #f8f9fa;
    font-weight: bold;
    cursor: pointer;
    list-style: none;
    position: relative;
    outline: none;
}
.event-accordion summary::-webkit-details-marker { display: none; }
.event-accordion summary::after {
    content: '+';
    position: absolute;
    right: 15px;
    color: #999;
}
.event-accordion details[open] summary::after { content: '-'; }

.event-accordion ul {
    margin: 0;
    padding: 0;
    list-style: none;
    border-top: 1px solid #eee;
}
.event-accordion li a {
    display: block;
    padding: 15px;
    text-decoration: none;
    color: #333;
    line-height: 1.4;
    transition: background 0.2s;
}
.event-accordion li a:hover {
    background: #f0f7ff;
    color: #0056b3;
}

/* しまのわセクションのリンクカード（背景に興居島を薄く配置） */
.past-events a {
    display: flex;
    align-items: center;
    background: #fff;
    border: 1px solid #f39c12;
    padding: 12px;
    margin-bottom: 12px;
    border-radius: 8px;
    text-decoration: none;
    transition: 0.3s;
    width: 100%;
    box-sizing: border-box;
    
    /* ↓背景画像をはみ出させないために追加 */
    position: relative;
    overflow: hidden;
}

.past-events a:hover {
    background: #fff9f0;
    transform: translateX(5px);
}

.past-events .year {
    font-size: 1.4rem;
    font-weight: bold;
    color: #f39c12;
    margin-right: 15px;
    border-right: 2px solid #f39c12;
    padding-right: 15px;
    flex-shrink: 0;
    /* 文字が画像の下に隠れないように前面に出す */
    position: relative;
    z-index: 2;
}

.past-events .shima-content {
    /* 文字が画像の下に隠れないように前面に出す */
    position: relative;
    z-index: 2;
}

.past-events .main {
    font-weight: bold;
    color: #333;
    font-size: 0.9rem;
}

.past-events .sub {
    font-size: 0.7rem;
    color: #999;
}

/* 【新設】カードの背景に興居島をうっすら浮かび上がらせる設定 */
.past-events a::after {
    content: "";
    position: absolute;
    right: 25px;  /* 右端に少しはみ出すくらいの位置 */
    bottom: 5px; /* 下側に少しはみ出すくらいの位置 */
    width: 100px;  /* カードの3割枠に収まるサイズに調整 */
    height: 100px;
    
    /* ご指定の興居島画像を設定 */
    background: url("https://www.ehime-rogaining.jp/wp-content/uploads/2026/04/gogoshima.png") no-repeat center/contain;
    
    opacity: 0.08; /* 薄さ（0.08 = 8%の濃さ）。文字の邪魔をしない絶妙な薄さです */
    transform: rotate(-10deg); /* 少し斜めにしてデザイン性をアップ */
    pointer-events: none; /* マウスイベントを邪魔しない設定 */
    z-index: 1;
}

/* スマホ対応（既存維持） */
@media (max-width: 768px) {
    .past-events a { flex-direction: column; align-items: flex-start; }
    .past-events .year { border-right: none; border-bottom: 2px solid #f39c12; margin-bottom: 10px; padding-bottom: 5px; }
}