@charset "UTF-8";
/* ==========================================================================
   GCCE 2027 common.css
   色は colors.css で定義した変数（var(--…)）だけを使う。値を直接書かない。
   書き方のルールは documents ではなく、共有フォルダの html-rules.md を参照。
   ========================================================================== */

/* ---- 文字 ---------------------------------------------------------------
   英文サイトなので英数字フォントを先に並べ、和文は後ろで受ける。
   本文 16px を基準に、見出しは 1.6 / 1.3 / 1.1 倍の3段階だけ。      */
/* バッジの「GCCE 2027」と帯の正式名称（h1）に使うフォント（Figtree Bold、SIL OFL。CTSoc の文字に近い形）
   lib/fonts/ に置いたファイルを読む。読めないときは --font-sans で表示される */
@font-face {
  font-family: "GCCE Title";
  src: url(../fonts/figtree-700.woff2) format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --font-title: "GCCE Title", var(--font-sans);   /* バッジの「GCCE 2027」と帯の正式名称 h1 */
  --font-sans: "Segoe UI", "Helvetica Neue", Helvetica, Arial,
               "Hiragino Sans", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  --fs-body:  1rem;      /* 16px 本文 */
  --fs-small: 0.875rem;  /* 14px 補足・表の注記・フッター */
  --fs-h2:    1.6rem;    /* 約26px ページの題名（各ページ1つ） */
  --fs-h3:    1.3rem;    /* 約21px 節の見出し */
  --fs-h4:    1.1rem;    /* 約18px 小見出し */
  --content-width: 1000px;
  --side-width: 256px;
  --content-pad: 36px;   /* 本文の左右の余白。帯の h1 もこの位置から始める */
}

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

html { min-height: 100%; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  line-height: 1.65;
  color: var(--color-text);
  background-color: var(--color-page-bg);
}

#container {
  max-width: var(--content-width);
  margin: 0 auto;
  background-color: var(--color-bg);
  box-shadow: 0 0 0 1px var(--color-border);
}

/* ---- ヘッダー（2024 型：上に写真の帯、その下に会議名の帯） -------------- */
.site-header { display: block; }

.site-photos {
  display: block;
  width: 100%;
  height: auto;
}

.site-title {
  display: flex;
  align-items: center;
  gap: var(--content-pad);
  padding: 10px 20px;
  background-color: var(--color-header-bg);
  color: var(--color-on-header);
  position: relative;
}
/* 五色の細い縞 */
.site-title::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -6px;
  height: 6px;
  background: var(--stripe);
}

/* CTSoc｜IEEE ロゴ（一体のブランドロゴ。縦線は画像に含まれる）
   ロゴの枠をメニューの幅にそろえ、h1 の書き出しを本文の左端にそろえる */
.site-logos { display: block; flex: none; width: calc(var(--side-width) - 20px); line-height: 0; }
.site-logos img { height: 48px; width: auto; }

/* h1 は会議の正式名称（全ページ共通、1ページに1つ。2025 型） */
h1 {
  margin: 0;
  font-family: var(--font-title);
  font-size: 1.5rem;   /* 24px。PC で1行に収まる上限 */
  font-weight: bold;
  line-height: 1.3;
  letter-spacing: 0.01em;
}
h1 a { color: inherit; text-decoration: none; }

/* ---- 本体（左メニュー＋本文） ------------------------------------------- */
.site-body {
  display: flex;
  align-items: flex-start;
  padding-top: 6px; /* 縞の分 */
}

#left-content {
  flex: none;
  width: var(--side-width);
  align-self: stretch;
  border-right: 1px solid var(--color-border);
}

#sidemenu-wrap { background-color: var(--color-menu-bg); }

/* ---- 開催地バッジ（2025 の leftimage にあたる） ---------------------------
   紺の帯から下がる半円。略称・開催地・会期を載せる（帯の h1 は正式名称）。
   文字と CSS だけで作る（写真は使わない）。年度替わりは HTML の2行を書き換えるだけ。 */
.site-badge {
  padding: 0 0 8px;
  background-color: var(--color-menu-bg);
}
.site-badge-circle {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 236px; height: 90px;
  margin: 0 auto;
  padding-bottom: 8px;
  border: 4px solid var(--ki);
  border-top: 0;
  border-radius: 0 0 118px 118px / 0 0 90px 90px;
  background-color: var(--kon);
  color: var(--white);
  text-align: center;
  line-height: 1.25;
  overflow: hidden;
}
/* 半円の中に献上柄をうっすら敷く */
.site-badge-circle::before {
  content: "";
  position: absolute;
  inset: 0;
  background-color: var(--kenjo-on-kon);
  -webkit-mask: url(image/kenjo.svg) center top / 56px 40px repeat;
          mask: url(image/kenjo.svg) center top / 56px 40px repeat;
  opacity: 0.55;
}
.site-badge-circle span { position: relative; }
.site-badge .b-name  { display: block; font-family: var(--font-title); font-size: 1.8rem; font-weight: bold; line-height: 1.1; }
.site-badge .b-place { display: block; font-size: 0.95rem; }
.site-badge .b-date  { font-weight: bold; color: var(--ki); }
.site-badge-circle span { text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6); }

/* ---- ページ下の献上柄の帯（2025 の街並みの背景にあたる） ------------------ */
.kenjo-band {
  height: 96px;
  background-color: var(--kenjo-bg);
  position: relative;
}
.kenjo-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background-color: var(--kenjo-motif);
  -webkit-mask: url(image/kenjo.svg) left top / 84px 60px repeat;
          mask: url(image/kenjo.svg) left top / 84px 60px repeat;
}

#sidemenu { padding: 12px 10px 20px; }

#banners-wrap {
  margin: 0;
  padding: 16px 10px;
  background-color: var(--color-bg);
}
.banners-title {
  margin: 0 0 8px;
  font-size: var(--fs-small);
  font-weight: bold;
  color: var(--color-heading);
  text-align: center;
}
/* 「申請予定を含む」の注記。見出しの下に小さく出す */
.banners-note {
  display: block;
  font-weight: normal;
  color: var(--color-text-muted);
}

#content {
  flex: 1 1 auto;
  min-width: 0;
  padding: 16px var(--content-pad) 48px;
}

.menu-toggle { display: none; }

/* ---- パンくず ------------------------------------------------------------ */
.breadcrumb-list {
  margin: 0 0 12px;
  padding: 0;
  font-size: var(--fs-small);
  color: var(--color-text-muted);
}
.breadcrumb-list li { display: inline; list-style: none; }
.breadcrumb-list li + li::before { content: "\203A"; margin: 0 0.5em; }

/* ---- 見出し --------------------------------------------------------------
   h1 = 会議名（ヘッダーのみ） / h2 = ページの題名（1ページに1つ）
   h3 = 節 / h4 = 小見出し。h5 以下は使わない。                        */
h2, h3, h4 { color: var(--color-heading); font-weight: bold; line-height: 1.35; }

h2 {
  margin: 0 0 20px;
  padding: 10px 14px 12px;
  font-size: var(--fs-h2);
  background-color: var(--color-heading-bg);
  border-left: 6px solid var(--kon);
  position: relative;
}
h2::after {
  content: "";
  position: absolute;
  left: -6px; right: 0; bottom: 0;
  height: 3px;
  background: var(--stripe);
}

h3 {
  margin: 32px 0 12px;
  padding: 0 0 4px 12px;
  font-size: var(--fs-h3);
  border-left: 4px solid var(--ao);
  border-bottom: 1px solid var(--color-border);
}

h4 {
  margin: 22px 0 8px;
  font-size: var(--fs-h4);
}
h4::before {
  content: "";
  display: inline-block;
  width: 0.5em; height: 0.5em;
  margin-right: 0.5em;
  vertical-align: 0.12em;
  background-color: var(--murasaki);
}

h2 + h3 { margin-top: 8px; }

/* ---- 本文・リンク -------------------------------------------------------- */
p { margin: 0 0 14px; }

a { color: var(--color-link); }
a:hover { color: var(--color-link-hover); text-decoration: none; }
a:focus-visible { outline: 3px solid var(--color-focus); outline-offset: 2px; }

img { max-width: 100%; height: auto; border: 0; }

/* 強調のルール
   <strong> … 大事な語句（太字。色は変えない）
   <em>     … 語の強め（斜体）
   class="alert" … 締切・重要な注意（赤の太字）。使いすぎない
   <mark>   … 一時的に目立たせたい語句（黄の淡い背景）               */
strong, b { font-weight: bold; color: inherit; }
em { font-style: italic; color: inherit; }
.alert { color: var(--color-alert); font-weight: bold; }
mark { background-color: var(--color-mark-bg); color: inherit; padding: 0 2px; }

small, .small { font-size: var(--fs-small); }
.muted { color: var(--color-text-muted); }
.center { text-align: center; }

hr { border: 0; border-top: 1px solid var(--color-border); margin: 24px 0; }

/* ---- リスト -------------------------------------------------------------- */
ul, ol { margin: 0 0 14px; padding-left: 1.6em; }
li { margin-bottom: 4px; }
li > ul, li > ol { margin: 4px 0 0; }

dl { margin: 0 0 14px; }
dt { font-weight: bold; margin-top: 10px; }
dd { margin: 2px 0 0 1.2em; }

/* ---- 表 ------------------------------------------------------------------
   表は <div class="table-wrap"> で囲む（スマホで横にスクロールできる）。 */
.table-wrap { overflow-x: auto; margin: 0 0 16px; }

table {
  border-collapse: collapse;
  width: 100%;
  font-size: var(--fs-body);
}
th, td {
  padding: 8px 12px;
  border: 1px solid var(--color-border);
  text-align: left;
  vertical-align: top;
}
thead th, th[scope="col"] { background-color: var(--color-heading-bg); color: var(--color-heading); }
tbody th[scope="row"] { background-color: var(--surface); font-weight: bold; width: 40%; }
table.info tbody th[scope="row"] { width: 22%; }
td.date { white-space: nowrap; font-weight: bold; }
/* Important Dates の右端「Details →」（詳細ページへのリンク） */
td.more { white-space: nowrap; width: 1%; text-align: right; }
/* 広い画面では項目名を1行に収める（狭い画面では折り返す。スマホは下の @media で2段組み） */
@media (min-width: 960px) {
  table.dates tbody th[scope="row"] { white-space: nowrap; width: auto; }
}
td.more a { font-weight: bold; }
/* スマホでは1行を「項目名」の下に「日付 ＋ Details →」を並べる形にして、横にはみ出さないようにする */
@media (max-width: 820px) {
  table.dates, table.dates tbody { display: block; }
  table.dates tr {
    display: grid;
    grid-template-columns: 1fr auto;
    border: 1px solid var(--color-border);
    margin-top: -1px;
  }
  table.dates th, table.dates td { border: 0; }
  table.dates tbody th[scope="row"] { grid-column: 1 / -1; width: auto; padding-bottom: 4px; white-space: normal; }
  table.dates td { padding-top: 4px; }
  tr.conference { background-color: var(--color-heading-bg); }
}
tr.conference td, tr.conference th { background-color: var(--color-heading-bg); }
/* 参加費の表（registration.html）。左端は区分のまとまり */
table.fees th[scope="rowgroup"] { background-color: var(--surface); vertical-align: middle; width: 18%; }

/* ---- 部品 ---------------------------------------------------------------- */
/* 囲み（注記） */
.note {
  margin: 0 0 16px;
  padding: 12px 16px;
  background-color: var(--color-note-bg);
  border-left: 4px solid var(--ao);
}
.note.important {
  background-color: var(--color-alert-bg);
  border-left-color: var(--color-alert);
}
.note > :last-child { margin-bottom: 0; }

/* ボタン風リンク（CFP のダウンロードなど） */
.button {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 4px;
  background-color: var(--kon);
  color: var(--white);
  font-weight: bold;
  text-decoration: none;
}
.button:hover { background-color: var(--kon-mid); color: var(--white); }

/* お知らせ（index.html の News）。1件 = h3 + 1〜2行 + リンク */
.news h3 { font-size: var(--fs-h4); margin-top: 20px; }
.news .date { color: var(--color-text-muted); font-size: var(--fs-small); font-weight: normal; margin-left: 0.5em; }

/* トピック一覧 */
.topics { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 4px 24px; }
.topics h3 { font-size: var(--fs-h4); margin-top: 18px; }
.topics p { font-size: var(--fs-small); color: var(--color-text-muted); margin: 0; }

/* 地図 */
.map iframe { width: 100%; height: 400px; border: 0; }

/* ページ内の「↑ Back to top」 */
.back-to-top { text-align: right; font-size: var(--fs-small); margin: 8px 0 0; }

/* scrolltopcontrol.js のボタン */
.button-totop {
  display: inline-block;
  width: 120px; height: 100px;
  background: url(image/totop.png) right bottom no-repeat;
}

/* ---- フッター ------------------------------------------------------------ */
.site-footer {
  position: relative;
  padding: 16px 20px;
  background-color: var(--kon-dark);
  color: var(--color-menu-text);
  font-size: var(--fs-small);
  text-align: center;
}
.site-footer::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 4px;
  background: var(--stripe);
}
.site-footer a { color: var(--ao-light); }

/* ---- スマホ・狭い画面（820px 以下） --------------------------------------- */
/* ---- サイト内検索（lib/js/sitesearch.js が作る） ------------------------- */
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.site-search { position: relative; margin: 0; padding: 14px 16px 4px; }
.site-search input {
  width: 100%;
  padding: 8px 10px 8px 34px;
  border: 1px solid var(--color-menu-muted);
  border-radius: 6px;
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23555D6E' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='M16 16l4.5 4.5'/%3E%3C/svg%3E") 10px center / 16px no-repeat;
  color: var(--color-text);
  font: inherit;
  font-size: var(--fs-small);
}
.site-search input:focus { outline: 3px solid var(--color-focus); outline-offset: 1px; }
.site-search-results {
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
  max-height: 60vh;
  overflow-y: auto;
  background: var(--white);
  border-radius: 6px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
}
.site-search-results li + li { border-top: 1px solid var(--color-border); }
.site-search-results a { display: block; padding: 10px 12px; color: var(--color-text); text-decoration: none; }
.site-search-results a:hover, .site-search-results a:focus-visible { background: var(--color-note-bg); }
.site-search-title { display: block; color: var(--color-link); font-weight: bold; text-decoration: underline; }
.site-search-snippet { display: block; margin-top: 2px; color: var(--color-text-muted); font-size: var(--fs-small); line-height: 1.5; }
.site-search-results mark { padding: 0; background: var(--color-mark-bg); color: inherit; font-weight: bold; }
.site-search-soon { padding: 10px 12px; border-left: 3px dashed var(--color-border); }
.site-search-soon .site-search-title { color: var(--color-text-muted); text-decoration: none; }
.site-search-none { padding: 10px 12px; color: var(--color-text-muted); font-size: var(--fs-small); }

@media (max-width: 820px) {
  .site-title { flex-wrap: wrap; gap: 8px 12px; padding: 8px 12px; }
  .site-logos { width: auto; }
  .site-logos img { height: 36px; }
  h1 { flex-basis: 100%; font-size: 1.25rem; }

  .site-body { flex-direction: column; }
  #left-content { display: contents; border: 0; }          /* メニューとバナーを並べ替えるため */
  #sidemenu-wrap { order: 1; width: 100%; background-color: var(--color-menu-bg); }
  #content { order: 2; width: 100%; padding: 12px 16px 32px; }
  #banners-wrap { order: 3; width: 100%; border-top: 1px solid var(--color-border); }
  #banners .banners-container { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 16px; }
  #banners .banners-container li.banners-spacer { display: none; }

  /* スマホ：半円を小さくして、帯のすぐ下（Menu ボタンの上）に置く */
  .site-badge { order: 0; width: 100%; padding-bottom: 6px; }
  .site-badge-circle { width: 240px; height: 72px; border-radius: 0 0 120px 120px / 0 0 72px 72px; padding-bottom: 6px; }
  .site-badge .b-name { font-size: 1.6rem; }
  .site-badge .b-place { font-size: 0.85rem; }
  .kenjo-band { height: 56px; }
  .kenjo-band::before { -webkit-mask-size: 56px 40px; mask-size: 56px 40px; }

  .menu-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px 16px;
    border: 0;
    background-color: var(--color-menu-bg);
    color: var(--color-menu-text);
    font: bold var(--fs-body) var(--font-sans);
    cursor: pointer;
  }
  .menu-toggle .bars { font-size: 1.4rem; line-height: 1; }
  #sidemenu { display: none; padding: 0 10px 14px; }
  body.menu-open #sidemenu { display: block; }

  h2 { font-size: 1.35rem; }
  h3 { font-size: 1.15rem; }
  tbody th[scope="row"] { width: auto; }
  .map iframe { height: 300px; }
}

/* CFP の縮小画像 */
.cfp-thumb { max-width: 420px; width: 100%; border: 1px solid var(--color-border); }

/* ---- ページ内リンク（長いページの先頭に置く <nav class="page-toc">）---- */
.page-toc {
  margin: 0 0 20px;
  padding: 10px 16px;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  background-color: var(--surface);
}
.page-toc-title { margin: 0 0 4px; font-size: var(--fs-small); font-weight: bold; color: var(--color-text-muted); }
.page-toc ul { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 4px 20px; }
.page-toc li { margin: 0; }
h3[id] { scroll-margin-top: 12px; }
/* Topic List の目次は14項目あるので、1行に1分野ずつ並べる（PC は2列） */
.page-toc-list ul { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 20px; }
@media (max-width: 820px) { .page-toc-list ul { grid-template-columns: 1fr; } }
