/* ===============================
   scholarship.css（最終版：モバイルで“中のカード”廃止）
   =============================== */

/* ── Fallback tokens ── */
:root{
  --brand:#2D8CFF;
  --brand-ink:#1a6edc;
  --ink:#222;
  --ink-2:#3a3a3a;
  --paper:#fff;
  --card:#fff;
  --shadow:0 4px 12px rgba(0,0,0,.05);
  --shadow-lg:0 8px 24px rgba(0,0,0,.12);
  --accent-green:#2e8c2a;

  /* thresholds (mobile) */
  --card-bg:#fff;
  --card-bd:#e6e9ef;
  --card-shadow:0 4px 14px rgba(0,0,0,.06);
  --ink-strong:#2e5b8c;
  --ink-sub:#5b6b7b;
  --ink-head:#124a94;
  --head-bg:#f2f7ff;
  --divider:#eef1f6;
}

/* ── ベース/可読性強化 ── */
.container, main.container{
  max-width:1100px;
  margin:0 auto;
  padding:0 1rem 3rem;
  font-family:"Hiragino Kaku Gothic ProN","Yu Gothic","Meiryo",system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
  letter-spacing:.01em;
  color:var(--ink);
}

/* HERO 見出し */
.hero .hero-text h1{
  font-size:clamp(1.6rem, 2.2vw, 2rem);
  letter-spacing:.04em;
  font-weight:800;
}

/* ── 奨学金テーブル（PC表示）── */
.scholarship-table{
  width:100%;
  border-collapse:collapse;
  background:var(--card);
  border-radius:14px;
  box-shadow:0 6px 24px rgba(45,140,255,.06);
  overflow:hidden;
  font-size:1rem;
  line-height:1.75;
}
.scholarship-table th,
.scholarship-table td{
  padding:.8rem 1rem;
  border-bottom:1px solid #e7e7e7;
  vertical-align:top;
  text-align:left;
}
.scholarship-table th{
  width:12rem;
  color:var(--accent-green);
  font-weight:800;
  letter-spacing:.06em;
  white-space:nowrap;
}
.scholarship-table td{
  color:var(--ink);
  font-weight:600;
}
.scholarship-table tr:last-child th,
.scholarship-table tr:last-child td{ border-bottom:none; }
.scholarship-table a{
  color:var(--brand);
  text-decoration:underline;
  word-break:break-all;
  font-weight:700;
}

/* ── 内部の補助表（基準表：PC表示）── */
.criteria-table{
  width:100%;
  border-collapse:collapse;
  margin:.5rem 0 0;
  font-size:1rem;
  line-height:1.65;
  background:#fff;
}
.criteria-table th,
.criteria-table td{
  padding:.65rem .9rem;
  border:1px solid #e7e7e7;
  text-align:center;
}
.criteria-table thead th{ background:#f6f9ff; font-weight:800; }
.criteria-table tbody th{ font-weight:700; }
.criteria-table td{ font-weight:600; }

/* セクション見出し */
.section-title,h2.section-title{
  font-size:clamp(1.55rem,1.9vw,1.9rem);
  font-weight:650;
  letter-spacing:.04em;
  margin:2rem auto 1rem;
}

/* ── 世帯人数テーブル（PC表示：通常の表）── */
.thresholds-table{
  width:100%;
  border-collapse:collapse;
  table-layout:auto;
  font-size:1rem;
  line-height:1.7;
  background:#fff;
}
.thresholds-table th,
.thresholds-table td{
  border:1px solid #e6e9ef;
  padding:.75rem 1rem;
  text-align:center;
  vertical-align:middle;
}
.thresholds-table thead th{
  background:#f0f6ff;
  color:#124a94;
  font-weight:800;
}

/* ── 「その他」：自動番号を消す（文章内で1. 2. 3. を書く前提）── */
.other-card ol, .other-card ul,
.sch-other  ol, .sch-other  ul{
  list-style:none;
  padding-left:0;
  margin-left:0;
}
.other-card li, .sch-other li{
  padding-left:0;
  text-indent:0;
  margin:.25em 0;
}

/* ==== 右端で文字が切れる保険（全端末） ==== */
.scholarship-table,
.scholarship-table * { box-sizing: border-box; }
.scholarship-table td,
.criteria-table td,
.thresholds-table td {
  word-break: break-word;
  overflow-wrap: anywhere;
}
.scholarship-table img{ max-width:100%; height:auto; }

/* ========= スマホ最適化 (〜767px) ========= */
@media (max-width: 767px){

  html,body{overflow-x:hidden}
  .floating-nav{display:none !important}
  main.container{ padding:1.25rem 1rem 2rem; }

  /* ── 奨学金テーブル：フラット表示（“中のカード”廃止） ── */
  .scholarship-table{
    display:block;
    width:100%;
    background:#fff;
    border:1px solid #e6e9ef;   /* 外枠のみ */
    border-radius:12px;
    box-shadow:none;
    padding:0;
  }
  .scholarship-table table{
    display:block;
    width:100%;
    border-collapse:collapse;
  }
  .scholarship-table tr{
    display:block;
    width:100%;
    margin:0;
    padding:12px 14px;          /* 行内の余白だけ */
    border-bottom:1px solid #e6e9ef;
    border-radius:0;
    box-shadow:none;
    background:transparent;
  }
  .scholarship-table tr:last-child{ border-bottom:none; }
  .scholarship-table th{
    display:block;
    border:0;
    padding:0 0 6px;
    color:#124a94;
    font-weight:800;
    line-height:1.4;
    white-space:normal;
  }
  .scholarship-table td{
    display:block;
    border:0;
    padding:0;
    font-weight:600;
    word-break:break-word;
    overflow-wrap:anywhere;
  }

  /* ── 基準表：カード化（theadを隠し、1行=1カード） ── */
  .criteria-table thead{ display:none; }
  .criteria-table,
  .criteria-table tbody,
  .criteria-table tr,
  .criteria-table td{ display:block; width:100%; }
  .criteria-table tbody tr{
    background:#fff;
    border:1px solid #e6e9ef;
    border-radius:14px;
    box-shadow:0 4px 14px rgba(0,0,0,.06);
    padding:12px 16px;
    margin:12px 0;
  }
  .criteria-table tbody td{
    border:0;
    padding:10px 0;
    text-align:left;
    line-height:1.7;
    word-break:break-word;
    overflow-wrap:anywhere;
    -webkit-font-smoothing:antialiased;
    text-rendering:optimizeLegibility;
  }
  .criteria-table tbody td:nth-child(1){
    display:inline-block;
    padding:.45rem .75rem;
    margin-bottom:.25rem;
    background:#f2f7ff;
    color:#124a94;
    font-weight:800;
    border-radius:999px;
  }
  .criteria-table tbody td:nth-child(2){
    display:flex; justify-content:space-between; gap:.75rem;
    font-weight:800; font-variant-numeric:tabular-nums; border-top:1px solid #eef1f6;
  }
  .criteria-table tbody td:nth-child(2)::before{
    content:"給与所得者（支払金額）"; color:#5b6b7b; font-weight:700; margin-right:.5rem;
  }
  .criteria-table tbody td:nth-child(3){
    display:flex; justify-content:space-between; gap:.75rem;
    font-weight:800; font-variant-numeric:tabular-nums; border-top:1px solid #eef1f6;
  }
  .criteria-table tbody td:nth-child(3)::before{
    content:"給与所得者以外（所得金額）"; color:#5b6b7b; font-weight:700; margin-right:.5rem;
  }

  /* ── 世帯人数テーブル：カード化 ── */
  .thresholds-table { width:100%; border-collapse:separate; border-spacing:0; background:transparent; font-size:.95rem; }
  .thresholds-table thead{ display:none; }
  .thresholds-table tbody, .thresholds-table tr, .thresholds-table td{ display:block; width:100%; }
  .thresholds-table tbody tr{
    background:#fff; border:1px solid #e6e9ef; border-radius:14px;
    box-shadow:0 4px 14px rgba(0,0,0,.06); padding:12px 16px; margin:12px 0;
  }
  .thresholds-table tbody td{
    border:0; padding:10px 0; text-align:left; line-height:1.7;
    word-break:break-word; overflow-wrap:anywhere; -webkit-font-smoothing:antialiased; text-rendering:optimizeLegibility;
  }
  .thresholds-table tbody td:nth-child(1){
    display:inline-block; padding:.45rem .75rem; margin-bottom:.25rem;
    background:var(--head-bg); color:var(--ink-head); font-weight:800; border-radius:999px;
  }
  .thresholds-table tbody td:nth-child(2){
    display:flex; justify-content:space-between; gap:.75rem; font-weight:800; font-variant-numeric:tabular-nums; border-top:1px solid var(--divider);
  }
  .thresholds-table tbody td:nth-child(2)::before{
    content:"給与所得者（支払金額）"; color:var(--ink-sub); font-weight:700; margin-right:.5rem;
  }
  .thresholds-table tbody td:nth-child(3){
    display:flex; justify-content:space-between; gap:.75rem; font-weight:800; font-variant-numeric:tabular-nums; border-top:1px solid var(--divider);
  }
  .thresholds-table tbody td:nth-child(3)::before{
    content:"給与所得者以外（所得金額）"; color:var(--ink-sub); font-weight:700; margin-right:.5rem;
  }
}

/* ========= スマホ小画面 (〜480px) ========= */
@media (max-width: 480px){
  .scholarship-table,.criteria-table{ font-size:.92rem; }
  .hero .hero-text h1{ font-size:1.25rem; }
}

/* ========= 汎用：箇条書きのマーカーを消す ========= */
.list-plain{ list-style:none; margin:0; padding:0; }
.list-plain li{ margin:.25em 0; }

/* ==== 左右対称 2 カラム（応募資格／選考方法など） ==== */
.sch-row{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:16px;
  align-items:stretch;
}
.sch-card{
  background:#fff;
  border:1px solid #e6e9ef;
  border-radius:14px;
  box-shadow:0 4px 14px rgba(0,0,0,.06);
  padding:16px;
  display:flex;
  flex-direction:column;
  min-height:100%;
}
.sch-card__title{
  font-weight:800;
  color:#124a94;
  margin-bottom:8px;
  line-height:1.4;
}
.sch-card__body{ flex:1; }
@media (max-width:767px){
  .sch-row{ grid-template-columns:1fr; }
}
