/* ===== ベース ===== */
:root {
  --text: #f3f1fa;          /* 基本テキスト（白に近い） */
  --text-dim: #c9c2e0;      /* 補助テキスト */
  --accent: #a855f7;        /* メインの紫 */
  --grad: linear-gradient(100deg, #ec4899 0%, #a855f7 50%, #6366f1 100%);
  --maxw: 1120px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: #120720; /* 回転層読み込み前のフォールバック下地 */
  color: var(--text);
  font-family: "Inter", "Noto Sans JP", system-ui, sans-serif;
  line-height: 1.7;
  overflow-x: hidden;
}

/* 回転するグラデ背景: 青紫→マゼンタ→濃い紫の線形グラデを10秒で1回転 */
body::before {
  content: "";
  position: fixed;
  top: 50%;
  left: 50%;
  width: 220vmax;
  height: 220vmax;
  margin: -110vmax 0 0 -110vmax; /* 画面より大きい正方形を中央に配置（回転で隅が空かない） */
  z-index: -2;
  /* スクショ準拠の色合い: 青紫〜マゼンタ寄りの一様な紫 */
  background: linear-gradient(
    120deg,
    #4f27a6 0%,
    #5b27a0 18%,
    #6e2399 38%,
    #88208f 55%,
    #6e2399 72%,
    #4d2080 88%,
    #371860 100%
  );
  animation: bg-spin 10s linear infinite;
  will-change: transform;
}
@keyframes bg-spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* 全体のトーンダウン用の固定オーバーレイ */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(rgba(10, 5, 24, 0.12), rgba(10, 5, 24, 0.12)),                         /* 全面を軽くトーンダウン */
    radial-gradient(120% 90% at 50% 0%, rgba(0, 0, 0, 0) 45%, rgba(20, 8, 40, 0.35) 100%); /* 縁・下部を軽く締める */
  pointer-events: none;
}

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

/* ===== ヒーロー（フルブリード / 1440基準） ===== */
.hero {
  position: relative;
  width: 100%;
  max-width: var(--maxw);                 /* 他セクションと同じ1120pxに揃える */
  margin: 0 auto;                         /* 中央寄せ */
  height: calc(100svh - 70px);
  display: flex;
  align-items: center;
}
/* 左上の装飾ライン: 左上の角に元サイズで配置 */
.hero-lines {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 0;
  width: auto;            /* 横いっぱいに伸ばさず元サイズ */
  max-width: 75%;         /* 大きすぎる場合の上限（必要なら調整） */
  height: auto;
  opacity: 1;
  pointer-events: none;
}
/* あやとり: スクロールしても固定。右端に寄せて画面外へブリード */
.hero-deco {
  position: fixed;
  z-index: -1;
  top: 50%;                /* Y軸中央 */
  left: 50%;               /* X軸中央 */
  transform: translate(-40%, -35%);
  width: calc(var(--maxw) * 1.15);   /* 1120px から約15%拡大 */
  max-width: none;                   /* img の max-width:100% を解除して指定幅を効かせる */
  pointer-events: none;
}
/* タイトル: コンテンツと左端を揃える中央寄せコンテナ内に配置 */
.hero-title-wrap {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 0 0 15vh;
  /* transform: translateY(-10vh);   /* 縦中央から少し上へ */
}
.hero-title {
  width: min(610px, 60%);
}

/* about + main をまとめる背景パネル: 横幅いっぱい + 背景ぼかし */
.content-panel {
  position: relative;
  width: 100vw;
  margin-left: calc(50% - 50vw);   /* 中央寄せの親から全幅へブリード */
}
/* 背景ぼかし層: 上から徐々にぼかしが効くようにマスクでグラデ */
.content-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;                     /* テキストより背面 */
  background: transparent;
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  /* 上端は透明→下へ不透明: ぼかしと色を徐々に効かせる */
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 160px);
  mask-image: linear-gradient(to bottom, transparent 0, #000 160px);
  pointer-events: none;
}

/* ===== 概要 ===== */
.about {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 40px 32px 80px;
}
.about-text {
  font-size: 19px;
  font-weight: 600;
  color: var(--text);
  margin: 12rem auto;
  width: 79%;
}

/* ===== メイン（2カラム） ===== */
.main {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 20px 32px 100px;
}

/* col-left / col-right をまとめるラッパー（2カラムグリッド） */
.main-inner {
  width: 79%;
  margin: 0 auto 10rem;
  display: grid;
  grid-template-columns: 9fr 10fr;
  gap: 60px;
  align-items: start;
}

/* --- 左: スピーカーカード --- */
.col-left {
  align-self: stretch;   /* 行いっぱいに伸ばして sticky の追従余地を作る */
}
.speaker-card {
  position: sticky;
  top: 20vh;             /* スクロール時、上から20%の位置で固定（中央寄り） */
  background: rgba(40, 20, 70, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 22px;
  padding: 20px 20px 24px;
  backdrop-filter: blur(10px);
  text-align: center;
}
.speaker-card-title {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin-bottom: 16px;
}

/* カルーセル */
.carousel {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 25 / 21;
  touch-action: pan-y;
  cursor: grab;
  user-select: none;
}
.carousel:active { cursor: grabbing; }
.carousel-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.carousel-img[hidden] { display: none; }
.carousel-nav {
  display: none;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: rgba(10, 5, 20, 0.55);
  color: #fff;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}
.carousel-nav:hover { background: rgba(168, 85, 247, 0.8); }
.carousel-nav.prev { left: 8px; }
.carousel-nav.next { right: 8px; }

/* ドット */
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 7px;
  margin: 14px 0 18px;
}
.carousel-dots button {
  width: 7px;
  height: 7px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}
.carousel-dots button.active {
  background: #fff;
  transform: scale(1.3);
}

/* ピルボタン */
.pill {
  display: inline-block;
  margin: 10px 6px 0;
  padding: .5rem 2.4rem;
  font-size: 16px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.06));
  border: 1px solid rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.25),
    inset 0 1px 1px rgba(255, 255, 255, 0.55),
    inset 0 -3px 8px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}
.pill-fill {
  color: #fff;
  margin: 0.6rem auto;
}
.pill-outline {
  color: var(--text);
}
/* hover: 明るいラベンダーに浮き上がる */
.pill:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.48), rgba(255, 255, 255, 0.30));
  border-color: rgba(255, 255, 255, 0.7);
  transform: translateY(-2px);
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.30),
    inset 0 1px 1px rgba(255, 255, 255, 0.7),
    inset 0 -3px 8px rgba(0, 0, 0, 0.15);
}

/* --- 右: 開催情報 --- */
.details {
  margin-bottom: 56px;
}
.detail-item {
  padding-bottom: 130px;
}
.detail-item:last-child { padding-bottom: 160px; }
.detail-item dt {
  font-size: 19px;
  font-weight: 700;
  padding-bottom: 15px;
  margin-bottom: 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
}
.detail-item dd {
  font-size: 19px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.9;
}

/* --- 右: 写真ギャラリー --- */
.gallery {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}
.gallery-item {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

/* ===== フッター ===== */
.site-footer {
  text-align: center;
  padding: 40px 24px;
  font-size: 13px;
  color: var(--text-dim);
}

/* モバイル用CTA（通常は非表示） */
.mobile-cta { display: none; }

/* ===== レスポンシブ ===== */
@media (max-width: 800px) {
  /* 1カラムに積み替え */
  .main-inner {
    display: flex;
    flex-direction: column;
    width: 88%;
    max-width: 420px;
    gap: 150px;
  }
  /* 並び順: 開催情報+ギャラリー → スピーカーカード */
  .col-right { order: 1; }
  .col-left  { order: 2; align-self: auto; }
  /* スピーカーカードの sticky を解除 */
  .speaker-card {
    position: static;
    top: auto;
  }
  .gallery { max-width: none; }
  .about-text {
    font-size: 15px;
    margin: 10rem auto;
    width: 90%;
    line-height: 2;
  }
  /* SPでは19px系を16pxに */
  .speaker-card-title,
  .detail-item dt,
  .detail-item dd { font-size: 16px; }
  .detail-item { padding-bottom: 80px; }

  /* ===== ファーストビュー: タイトル上・あやとり中央・CTA下 ===== */
  .hero {
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-start;
    padding: 9vh 24px 7vh;
  }
  /* hero-lines: 箱に cover で拡大表示して左上を切り出す */
  .hero-lines {
    width: 100%;
    height: 60vh;
    max-width: none;
    object-fit: inherit;
    object-position: bottom right;
  }
  .hero-title-wrap {
    padding: 0;
    margin: 2.5rem 0 0;   /* 上から下げる */
    transform: none;
    width: 100%;
    max-width: none;
  }
  .hero-title { width: min(440px, 80%); }
  /* CTA: ヒーロー下部に中央寄せ・コンテンツ幅 */
  .mobile-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    width: 100%;
  }
  .mobile-cta .pill { margin: 0; }
  /* あやとり: 幅150vw・右を画面外へブリード・中央付近 */
  .hero-deco {
    width: 150vw;
    left: auto;
    right: -50vw;
    top: 25vh;
    transform: none;
  }
}
@media (max-width: 520px) {
  .hero { min-height: 360px; }
  .hero-title-wrap { padding: 0 1rem; }
  .hero-title { width: 85%; }
  .about, .main { padding-left: 20px; padding-right: 20px; }
}
