/* ============================================================
   style.css
   ------------------------------------------------------------
   このファイルはプロトタイプ（骨組み）用のスタイルです。
   実際の運用に合わせて、まず :root の変数（色・フォント）を
   調整してから、各セクションの微調整をしてください。
   ============================================================ */

/* ---------- 1. テーマ変数 ---------- */
:root {
  --color-bg: #fafafa;
  /* ページ背景（紙色） */
  --color-surface: #ffffff;
  /* カード等の背景 */
  --color-ink: #1c2430;
  /* 本文・見出しの基本色 */
  --color-ink-soft: #5b6472;
  /* 補助テキスト */
  --color-accent: #FA7E7D;
  /* アクセント（実績・強調） */
  --color-accent-soft: #ffefef;
  /* アクセントの薄色背景 */
  --color-line: #d2b7b7;
  /* 罫線・区切り線 */
  --color-line-strong: #a58989;

  /* タイポグラフィ */
  --font-heading: "Shippori Mincho", "Noto Serif JP", serif;
  --font-body: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;

  /* レイアウト */
  --content-width: 760px;
  /* 本文の最大幅（可読性のため） */
  --wide-width: 1100px;
  /* セクション全体の最大幅 */
  --gap: clamp(2.5rem, 6vw, 5rem);

  --radius: 4px;
  --transition: 0.25s ease;

  --container-margin-bottom: 3rem;
  --container-wrap-bottom: 1.5rem;
}

/* ---------- 2. リセット ---------- */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
}

ul, ol {
  padding-left: 1.2em;
}

table {
  border-collapse: collapse;
  width: 100%;
}

h1, h2, h3, h4, h5 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.5;
  margin: 0 0 0.6em;
}

:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ---------- 3. 共通レイアウト ---------- */
h2 {
  font-size: clamp(1.5rem, 1.227rem + 1.36vw, 2.25rem);
  padding: 4rem 0 1.4rem;
  text-align: center;
}

img {
  margin: auto;
}

.wrap {
  max-width: var(--wide-width);
  margin: 0 auto var(--container-wrap-bottom);
}

.page-block {
  border-top: 1px solid var(--color-line);
}

.page-block:first-of-type {
  border-top: none;
}

.flex-container {
  display: flex;
  justify-content: space-between;
  flex-wrap: var(--flex-wrap, auto);
  gap: var(--flex-gap, 1.5rem);
}

.flex-item {
  flex-basis: var(--item-width, auto);
}

.video-wrapper {
  aspect-ratio: 16 / 9;
  /* YouTubeの標準比率 */
  width: 100%;
}

.video-wrapper iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

@media (max-width: 640px) {
  .flex-container {
    flex-direction: column;
    gap: var(--flex-gap, 1.5rem);
  }
}

/* ---------- 4. ヘッダー / ナビ ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgb(255 255 255 / 87%);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--color-line);
}

.site-header__inner {
  max-width: var(--wide-width);
  margin: 0 auto;
  padding: 0.9rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-header__controls {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.site-header__logo {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  text-decoration: none;
  width: 170px;
}

.site-nav__list {
  display: flex;
  gap: 1.6rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav__list a {
  text-decoration: none;
  font-size: 0.92rem;
  color: var(--color-ink-soft);
  transition: color var(--transition);
}

.site-nav__list a:hover {
  color: var(--color-accent);
}

.nav-toggle {
  display: none;
}

@media (max-width: 720px) {
  .site-nav__list {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    flex-direction: column;
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-line);
    padding: 1rem 1.5rem 1.5rem;
    gap: 1rem;
    display: none;
  }

  .site-nav__list.is-open {
    display: flex;
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: none;
    border: 1px solid var(--color-line-strong);
    border-radius: var(--radius);
    cursor: pointer;
  }

  .nav-toggle span,
  .nav-toggle span::before,
  .nav-toggle span::after {
    content: "";
    display: block;
    width: 18px;
    height: 1px;
    background: var(--color-ink);
    position: relative;
  }

  .nav-toggle span::before {
    position: absolute;
    top: -6px;
  }

  .nav-toggle span::after {
    position: absolute;
    top: 6px;
  }
}

/* ---------- 5. アイキャッチ（ヒーロー） ---------- */
.hero {
  padding: clamp(4rem, 12vw, 7rem) 1.5rem clamp(3rem, 8vw, 5rem);
  text-align: center;
  background-image: url("images/hero_bgimg.jpg");
  background-size: cover;
  background-position: center;
  margin-bottom: var(--container-margin-bottom);
}

.hero__title {
  font-size: clamp(2rem, 5vw, 3.2rem);
  letter-spacing: 0.02em;
}

.hero__copy {
  margin: 0 auto;
}

.hero__copy p {
  font-size: clamp(1.125rem, 0.852rem + 1.36vw, 1.875rem);
  margin: 0.4em 0;
  font-family: var(--font-heading);
}

/* ---------- 6. 外部リンクバナー ---------- */
.banner-link {
  max-width: var(--wide-width);
  margin: 0 auto;
  padding: 0 1.5rem 2rem;
}

.banner-link__link {
  display: block;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--color-line);
  transition: opacity var(--transition);
}

.banner-link__link:hover {
  opacity: 0.85;
}

.banner-link__link img {
  width: 100%;
}

/* ---------- 7. コンテンツセクション（見出し＋テキスト貼り付け用） ---------- */
.content-section {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 2.6rem 1.5rem;
}

.content-section__title {
  font-size: clamp(1.35rem, 3vw, 1.7rem);
  padding-bottom: 0.6em;
  border-bottom: 2px solid var(--color-accent);
  display: inline-block;
}

.text-block {
  margin: 0 0 2rem;
}

.text-block p {
  margin: 0 0 1.3rem;
}



.text-block h3, .text-block h4 {
  margin-top: 1.6em;
}

.text-block h4 {
  font-size: clamp(1.125rem, 1.08rem + 0.23vw, 1.25rem);
}

.text-block a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.text-block blockquote {
  margin: 1.5em 0;
  padding: 0.2em 1.4em;
  border-left: 3px solid var(--color-accent);
  color: var(--color-ink-soft);
}

.text-block ul, .text-block ol {
  margin: 0 0 1.3em;
}

.text-block table {
  margin-top: 0;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: var(--table-margin-bottom, 4rem);
  font-size: 0.95rem;
}

.text-block table th, .text-block table td {
  border: 1px solid var(--color-line);
  padding: 0.5em 0.8em;
}

.content-section--wide {
  max-width: var(--wide-width);
}

/* ---------- 8. 実績エリア ---------- */
.achievements {
  max-width: var(--wide-width);
  margin: 2.4rem auto 0;
  padding: 2.4rem 1.5rem;
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
}

.achievements__subtitle {
  font-size: 1.3rem;
  margin-bottom: 1.2em;
  text-align: center;
}

/* 過去実績ハイライト：3要素／PC横並び・SP縦並び */
.achievements__highlights {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--color-line);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  overflow: hidden;
}

@media (min-width: 640px) {
  .achievements__highlights {
    flex-direction: row;
  }
}

.achievements__highlight {
  flex: 1;
  background: var(--color-surface);
  padding: 1.6rem 1.2rem;
  text-align: center;
}

.achievements__highlight-number {
  display: block;
  font-family: var(--font-heading);
  font-size: 2.1rem;
  line-height: 1.2;
}

.achievements__highlight-label {
  display: block;
  margin-top: 0.4em;
  font-size: 0.88rem;
  color: var(--color-ink-soft);
}

/* 詳細実績：国別参加者数グラフ */
.achievements__detail h5 {
  font-size: 1rem;
  margin-bottom: 1.2em;
}

.participant-chart {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  padding: 0 0 0.5rem;
  border-bottom: 1px solid var(--color-line);
}

.participant-bar {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.participant-bar__label {
  flex: 0 0 auto;
  width: 6.5em;
  font-size: 0.88rem;
  color: var(--color-ink-soft);
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.participant-bar__track {
  flex: 1 1 auto;
  min-width: 0;
  height: 12px;
  background: none;
  position: relative;
}

.participant-bar__column {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 0;
  /* JS が実行後に幅をアニメーションで伸ばします */
  background: var(--color-accent);
  border-radius: 999px;
  transition: width 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.participant-bar__value {
  flex: 0 0 auto;
  width: 2.6em;
  font-size: 0.88rem;
  color: var(--color-ink-soft);
  text-align: left;
}

@media (max-width: 480px) {
  .participant-bar__label {
    width: 5em;
    font-size: 0.82rem;
  }
}

.participant-list-small {
  list-style: none;
  margin: 1.4rem 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: var(--color-ink-soft);
}

.participant-list-small li:not(:last-child)::after {
  content: " / ";
  padding: 0 0.3em;
}

.participant-list-small li span {
  margin-left: 0.35em;
}

/* 実績テーブル */
.achievements__table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  /* 横スクロールできることが分かるよう、右端をわずかにフェード */
  background:
    linear-gradient(to right, var(--color-surface) 30%, rgba(255, 255, 255, 0)),
    linear-gradient(to right, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0)) right / 6px 100% no-repeat;
  background-attachment: local, scroll;
}

.achievements__table {
  min-width: 480px;
  font-size: 0.94rem;
}

.achievements__table th,
.achievements__table td {
  border: 1px solid var(--color-line);
  padding: 0.7em 1em;
  text-align: left;
  white-space: nowrap;
}

.achievements__table thead th {
  background: var(--color-accent-soft);
  font-weight: 600;
}

.achievements__table tbody tr:nth-child(even) {
  background: rgba(0, 0, 0, 0.02);
}

/*審査員セクション*/

.face_circle {
  border-radius: 100px;
}

.judges-container h3 {
  text-align: center;
}

.judges-container h3 span {
  font-size: 0.9rem;
  color: var(--color-ink-soft);
}

.judges-container .profile {
  font-size: 0.8rem;
  color: var(--color-ink-soft);
  text-align: center;
}


/*会社案内セクション*/

.googlemap-wrapper {
  position: relative;
  padding-bottom: 3rem;
  overflow: hidden;
}

/* ---------- 9. ギャラリー（FooGallery代替） ---------- */
.gallery-block {}

.gallery-block__title {
  text-align: center;
  margin-bottom: 1.6rem;
}

.js-gallery {
  max-width: var(--wide-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.8rem;
}

.js-gallery+.js-gallery {
  margin-top: 2.5rem;
}

.js-gallery-item {
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--radius);
  cursor: zoom-in;
  border: 1px solid var(--color-line);
}

.js-gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition);
}

.js-gallery-item:hover img {
  transform: scale(1.05);
}

.gallery-block p {
  margin-top: 0;
  color: var(--color-ink-soft);
}

/* ライトボックス */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(15, 15, 15, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 2rem;
}

.lightbox[hidden] {
  display: none;
}

.lightbox__image {
  max-width: min(90vw, 1100px);
  max-height: 80vh;
  width: auto;
  border-radius: 2px;
}

.lightbox__caption {
  position: absolute;
  bottom: 1.6rem;
  left: 0;
  right: 0;
  text-align: center;
  color: #f2f0ea;
  font-size: 0.9rem;
}

.lightbox__close,
.lightbox__prev,
.lightbox__next {
  position: absolute;
  background: none;
  border: none;
  color: #f2f0ea;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.5rem;
}

.lightbox__close {
  top: 1.2rem;
  right: 1.5rem;
}

.lightbox__prev {
  left: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox__next {
  right: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
}

@media (max-width: 640px) {
  .lightbox__prev, .lightbox__next {
    font-size: 1.6rem;
  }
}

/* ---------- 10. フッター ---------- */
.site-footer {
  padding: 2.6rem 1.5rem;
  text-align: center;
  color: var(--color-ink-soft);
  font-size: 0.85rem;
  border-top: 1px solid var(--color-line);
}

.site-footer__contact {
  margin-bottom: 1.4rem;
}

.site-footer__label {
  font-weight: 600;
  color: var(--color-ink);
  margin: 0 0 0.5em;
}

.site-footer__tel,
.site-footer__mail {
  margin: 0.3em 0;
}

.site-footer__tel a,
.site-footer__mail a {
  color: var(--color-ink-soft);
  text-decoration: none;
}

.site-footer__tel a:hover,
.site-footer__mail a:hover {
  color: var(--color-accent);
}

.site-footer__copyright {
  margin: 0;
  font-size: 12px;
}