/* =========================
   23rd Saitama Pedsurg — Unified CSS (Solid + Anti-Drift + 2x2 Meta + Content Centering Fix)
   - Background: solid
   - Hero meta chips: ALWAYS 2 columns on >=760px (2 rows when 4 items)
   - Fix: .content centered even if not wrapped by .container (prevents left drift)
   - Anti-drift: robust centering, reset list defaults, prevent overflow push
========================= */

:root{
  /* base */
  --bg: #f5f7f6;
  --surface: rgba(255,255,255,.84);
  --surface-strong: #ffffff;
  --text: #0f1a14;
  --muted: rgba(15,26,20,.72);
  --border: rgba(15,26,20,.10);

  /* accent */
  --brand: #167a3f;
  --brand-ink: #0f4f2a;

  /* layout */
  --radius: 18px;
  --radius-lg: 22px;
  --shadow: 0 18px 50px rgba(0,0,0,.08);
  --shadow-soft: 0 12px 30px rgba(0,0,0,.06);
  --max: 1120px;

  /* type */
  --t-xs: 12px;
  --t-sm: 14px;
  --t-md: 16px;
}

*{ box-sizing: border-box; }
html, body{ height: 100%; }

body{
  margin: 0;
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", "Noto Sans JP",
    "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  line-height: 1.75;
  letter-spacing: .01em;
  background: var(--bg);
  overflow-x: hidden; /* 横はみ出しでレイアウトがズレる事故を抑止 */
}

a{ color: inherit; }
a:hover{ text-decoration: none; }
img{ max-width: 100%; height: auto; display: block; }

.container{
  width: min(var(--max), calc(100% - 32px));
  margin: 0 auto;
}

/* =========================
   Accessibility
========================= */
.skip-link{
  position: absolute;
  left: 12px;
  top: 12px;
  padding: 10px 12px;
  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-soft);
  transform: translateY(-220%);
  transition: transform .2s ease;
  z-index: 999;
}
.skip-link:focus{ transform: translateY(0); }

/* =========================
   Hero
========================= */
.hero{
  position: relative;
  background: var(--surface-strong);
  border-bottom: 1px solid rgba(0,0,0,.06);
}

.hero--top{ padding-top: 6px; }
.hero-inner{ padding: 54px 0 26px; }

.hero-kicker{
  margin: 0 0 10px;
  color: var(--muted);
  font-size: var(--t-xs);
  letter-spacing: .12em;
  text-transform: uppercase;
  text-align: center;
}

.hero-head{
  display: grid;
  gap: 12px;
  justify-items: center;
  align-items: center;
  text-align: center;
}

.hero-title{
  margin: 0;
  text-align: center;
  font-size: clamp(28px, 3.8vw, 46px);
  line-height: 1.12;
  letter-spacing: .01em;
}

/* =========================
   Nav
========================= */
.hero-nav{
  width: 100%;
  max-width: 980px;
  margin: 6px auto 0;
  padding: 10px 0 8px;
  border-top: 1px solid rgba(15,26,20,.10);
  border-bottom: 1px solid rgba(15,26,20,.10);
}

/* reset UL/LI to avoid env differences */
.hero-nav ul{
  list-style: none;
  margin: 0;
  padding: 0;

  display: flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
  flex-wrap: nowrap;

  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.hero-nav ul::-webkit-scrollbar{ display: none; }
.hero-nav li{ margin: 0; padding: 0; }

.hero-nav a{
  position: relative;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  padding: 10px 2px;
  text-decoration: none;
  color: rgba(15,26,20,.82);
  font-size: var(--t-sm);
  font-weight: 650;
  letter-spacing: .02em;
}

.hero-nav a::after{
  content:"";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 4px;
  height: 2px;
  border-radius: 999px;
  background: transparent;
  transform: scaleX(.65);
  transform-origin: center;
  transition: background .16s ease, transform .16s ease;
}

.hero-nav a:hover::after{
  background: rgba(22,122,63,.22);
  transform: scaleX(1);
}

.hero-nav a[aria-current="page"]{
  color: var(--brand-ink);
  font-weight: 850;
}
.hero-nav a[aria-current="page"]::after{
  background: var(--brand);
  transform: scaleX(1);
}

/* =========================
   Meta chips (ALWAYS 2 columns on >=760px)
========================= */
.hero-meta{
  margin-top: 14px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  justify-items: stretch;
}

@media (min-width: 760px){
  .hero-meta{
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1040px){
  .hero-meta{
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.meta-chip{
  background: rgba(255,255,255,.90);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
  box-shadow: 0 10px 22px rgba(0,0,0,.03);
  max-width: 100%;
}

.meta-label{
  display: block;
  font-size: var(--t-xs);
  color: var(--muted);
  letter-spacing: .10em;
}
.meta-value{
  display: block;
  margin-top: 4px;
  font-size: var(--t-md);
  font-weight: 750;
}

/* Organizer highlight */
.meta-chip--host{
  border-color: rgba(22,122,63,.35);
  background: rgba(22,122,63,.06);
  box-shadow: 0 14px 34px rgba(22,122,63,.10);
}
.meta-chip--host .meta-label{
  color: rgba(15,79,42,.95);
  font-weight: 900;
  letter-spacing: .12em;
}
.meta-chip--host .meta-value{
  font-size: 18px;
  font-weight: 900;
  color: rgba(15,79,42,.98);
}

/* =========================
   Sections
========================= */
.section{ padding: 34px 0; }

.section-muted{
  background: transparent;
  border: 0;
}

.section-head{
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.section-title{
  margin: 0 0 14px;
  font-size: 20px;
  letter-spacing: .02em;
}

.section-note{
  margin: 0 0 12px;
  color: var(--muted);
  font-size: var(--t-sm);
}

/* =========================
   Key visual
========================= */
.hero-image{
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid rgba(0,0,0,.08);
  background: var(--surface-strong);
  box-shadow: var(--shadow);
  max-width: 100%;
}

.hero-image img{
  width: 100%;
  height: min(440px, 46vw);
  object-fit: cover;
  object-position: center 40%;
  transform: scale(1.01);
  max-width: 100%;
}

.hero-image-placeholder{
  display: grid;
  place-items: center;
  padding: 70px 16px;
  color: var(--muted);
  background: #ffffff;
}

/* =========================
   News
========================= */
.news{
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.news li{
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 12px;
  align-items: baseline;

  padding: 14px 16px;
  background: rgba(255,255,255,.90);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 10px 22px rgba(0,0,0,.03);
  max-width: 100%;
}

@media (max-width: 520px){
  .news li{
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

.news time{
  font-size: var(--t-xs);
  color: var(--muted);
  letter-spacing: .06em;
}

.news a{
  color: var(--brand-ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.news a:hover{ text-decoration: none; }

/* =========================
   Contact
========================= */
.contact{
  background: rgba(255,255,255,.92);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
  box-shadow: 0 16px 40px rgba(0,0,0,.06);
  max-width: 100%;
}

.contact-title{
  margin: 0 0 10px;
  font-weight: 900;
  letter-spacing: .02em;
}

.contact-body{
  margin: 0;
  color: rgba(15,26,20,.78);
}

/* =========================
   Content helpers (★content centering fix)
========================= */

/* ★重要：containerで包まれていない .content でも必ず中央寄せにする */
.content{
  width: min(980px, calc(100% - 32px));
  margin-left: auto;
  margin-right: auto;
}

/* もし <div class="container content"> の場合でも自然に整う */
.container.content{
  width: min(980px, calc(100% - 32px));
}

.panel{
  background: rgba(255,255,255,.92);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: 0 16px 40px rgba(0,0,0,.05);
  max-width: 100%;
}

.lead{
  margin: 0 0 10px;
  color: rgba(15,26,20,.80);
}

.note{
  margin: 10px 0 0;
  color: var(--muted);
  font-size: var(--t-sm);
}

.list{
  margin: 0;
  padding-left: 1.2em;
}

/* bullet-less list helper */
.plain-list{
  list-style: none;
  padding-left: 0;
  margin: 0;
  display: grid;
  gap: 6px;
}
.plain-list > li{ padding: 0; margin: 0; }
.plain-list > li:empty{ display: none; }

.mono{
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
    "Liberation Mono", "Courier New", monospace;
  letter-spacing: 0;
}

/* info grid */
.info{
  background: rgba(255,255,255,.92);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 10px 14px;
  box-shadow: 0 16px 40px rgba(0,0,0,.05);
  margin-bottom: 14px;
  max-width: 100%;
}

.info-row{
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid rgba(15,26,20,.08);
}
.info-row:first-child{ border-top: 0; }

.info-k{
  color: var(--muted);
  font-size: var(--t-sm);
  letter-spacing: .04em;
}
.info-v{ font-weight: 650; }

/* table */
.table-wrap{
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 14px;
  border: 1px solid rgba(15,26,20,.08);
  background: rgba(255,255,255,.94);
  max-width: 100%;
}

.table{
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}

.table th,
.table td{
  padding: 12px 12px;
  border-bottom: 1px solid rgba(15,26,20,.08);
  vertical-align: top;
}

.table thead th{
  font-size: var(--t-sm);
  color: rgba(15,26,20,.82);
  text-align: left;
  background: rgba(22,122,63,.06);
}

.table tbody tr:hover{
  background: rgba(22,122,63,.05);
}

/* Link list */
.link-list{
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.link-item{
  border: 1px solid rgba(15,26,20,.08);
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255,255,255,.92);
}

.link-a{
  display: block;
  padding: 14px 16px;
  text-decoration: none;
  position: relative;
}

.link-a::after{
  content: "↗";
  position: absolute;
  right: 14px;
  top: 14px;
  color: rgba(15,26,20,.45);
  font-size: 14px;
}

.link-title{
  display: block;
  font-weight: 850;
  letter-spacing: .01em;
}

.link-desc{
  display: block;
  margin-top: 4px;
  color: rgba(15,26,20,.72);
  font-size: 14px;
}

.link-a:hover{
  background: rgba(22,122,63,.06);
}

/* =========================
   Footer
========================= */
.site-footer{
  margin-top: 14px;
  padding: 18px 0;
  color: rgba(255,255,255,.92);
  background: linear-gradient(180deg, var(--brand), #0f5a30);
}

.footer-inner{
  font-size: var(--t-xs);
  opacity: .95;
}

/* =========================
   Mobile refinements
========================= */
@media (max-width: 520px){
  .info-row{ grid-template-columns: 1fr; gap: 4px; }
}

@media (max-width: 420px){
  .hero-inner{ padding: 46px 0 22px; }
  .hero-nav{ padding: 8px 0 6px; }
}

/* =========================
   Reduced motion
========================= */
@media (prefers-reduced-motion: reduce){
  *{ scroll-behavior: auto !important; transition: none !important; }
}
