/* ===== TB Hero Slider：ファーストビューの写真スライダー =====
   写真はフェード＋ズームインで切り替え。黒いオーバーレイの上に白い文字。 */
.tb-hero{
  position: relative; overflow: hidden;
  height: var(--tb-hero-h, 100vh);
  background: #111;
  color: #fff;
  margin-left: auto; margin-right: auto;
}
.tb-hero, .tb-hero *{ box-sizing: border-box; }

/* 幅：標準（1000px）／広（1100px）／全幅（本文エリアいっぱい）
   値は子テーマの base.css の変数（--w-std / --w-wide / --main-w）。ない場合は右の値。
   置いたブロックの幅（ふつうは1000px）に関係なく、その中央を基準に指定の幅で表示する
   （2026-10-28 修正：以前は置いたブロックの幅で止まり、wide が std と同じになっていた）。
   画面が狭いときは、本文エリアの幅まで。 */
.tb-hero{ --tb-hero-w: var(--main-w, 100vw); }
.tb-hero--std { --tb-hero-w: min(var(--w-std, 1000px),  var(--main-w, 100vw)); }
.tb-hero--wide{ --tb-hero-w: min(var(--w-wide, 1100px), var(--main-w, 100vw)); }
.tb-hero--std,
.tb-hero--wide,
.tb-hero--full{
  width: var(--tb-hero-w); max-width: none;
  margin-left: calc(50% - var(--tb-hero-w) / 2);
  margin-right: 0;
}

/* 写真（2枚を重ねて、交互に使う） */
.tb-hero__stage{ position: absolute; inset: 0; }
.tb-hero__slide{
  position: absolute; inset: 0; overflow: hidden;
  opacity: 0;
  transition: opacity var(--tb-hero-fade, 2s) ease-in-out;
}
.tb-hero__slide.is-active{ opacity: 1; z-index: 1; }
.tb-hero__img{
  display: block; width: 100%; height: 100%;
  object-fit: cover;
  transform: scale(1);
  transform-origin: 50% 50%;
  will-change: transform;
}
/* ズームイン：表示している間（表示秒数＋フェード秒数）、ゆっくり拡大する。JS がその秒数を設定する */
.tb-hero__slide.is-zoom .tb-hero__img{
  transform: scale(var(--tb-hero-zoom, 1.12));
  transition: transform var(--tb-hero-run, 8s) linear;
}

/* 黒いオーバーレイ */
.tb-hero__ov{
  position: absolute; inset: 0; z-index: 2;
  background: #000; opacity: var(--tb-hero-ov, .35);
  pointer-events: none;
}

/* 文字：タテ位置は上から10段階（--tb-hero-top） */
.tb-hero__text{
  position: absolute; z-index: 3;
  left: 0; right: 0;
  top: var(--tb-hero-top, 55%);
  transform: translateY(-50%);
  margin: 0 !important; padding: 0 6%;
  color: #fff !important;
  font-family: var(--serif-jp, 'Shippori Mincho', 'Hiragino Mincho ProN', 'Yu Mincho', serif);
  font-weight: 500;
  line-height: 1.6; letter-spacing: .08em;
  text-shadow: 0 1px 12px rgba(0,0,0,.25);
  --tb-hero-scale: 1;
}
.tb-hero--center .tb-hero__text{ text-align: center; }
.tb-hero--left .tb-hero__text{ text-align: left; }
.tb-hero__line{ display: block; }
.tb-hero__line + .tb-hero__line{ margin-top: .5em; }
.tb-hero__seg{
  font-size: calc(var(--fs, 24) * var(--tb-hero-scale) * 1px);
}
/* 同じ行で大きさを変えた2つ目以降の部分（例：Antoni Gaudí）は、少し間をあける */
.tb-hero__seg + .tb-hero__seg{ margin-left: .8em; }

/* ===== 矢印（arrows="1"〜"4"）2026-10-30 =====
   1・2：左右の端。タテの位置は、文字の1行目の高さ（JSが測って合わせる。測る前は文字の位置 --tb-hero-top）
   3・4：右下に固定（文字の位置に関係なく、上から91%の高さ）
   白い細線で控えめに。 */
.tb-hero__nav{ position: absolute; z-index: 4; left: 0; right: 0; top: var(--tb-hero-top, 55%); height: 0; pointer-events: none; }
.tb-hero__nav button{
  all: unset; box-sizing: border-box; pointer-events: auto; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: #fff; -webkit-tap-highlight-color: transparent;
}
.tb-hero__nav button:focus-visible{ outline: 1px solid rgba(255,255,255,.8); outline-offset: 3px; }
.tb-hero__nav svg{ display: block; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; }

/* 1・2：左右の端 */
.tb-hero__nav--side button{ position: absolute; top: 0; transform: translateY(-50%); }
.tb-hero__nav--side .tb-hero__prev{ left: 0; }
.tb-hero__nav--side .tb-hero__next{ right: 0; }
/* 1（A案）：細い「く」の字だけ。押せる範囲は広めに */
.tb-hero--arrows-1 .tb-hero__nav button{ width: 56px; height: 72px; opacity: .8; transition: opacity .3s; }
.tb-hero--arrows-1 .tb-hero__nav button:hover{ opacity: 1; }
.tb-hero--arrows-1 .tb-hero__nav svg{ width: 16px; height: 34px; stroke-width: 1.1; filter: drop-shadow(0 0 3px rgba(0,0,0,.45)); }
/* 2（C案）：すりガラスの小さな四角 */
.tb-hero--arrows-2 .tb-hero__nav button{
  width: 36px; height: 56px;
  background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.18);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  transition: background .3s;
}
.tb-hero--arrows-2 .tb-hero__nav .tb-hero__prev{ border-left: 0; }
.tb-hero--arrows-2 .tb-hero__nav .tb-hero__next{ border-right: 0; }
.tb-hero--arrows-2 .tb-hero__nav button:hover{ background: rgba(255,255,255,.22); }
.tb-hero--arrows-2 .tb-hero__nav svg{ width: 10px; height: 20px; stroke-width: 1.3; }

/* 3（D案）・4（E案）：右下にまとめて置く（文字の位置に関係なく、上から91%） */
.tb-hero__nav--d,
.tb-hero__nav--e{ display: flex; justify-content: flex-end; align-items: center; top: 91%; }
.tb-hero__nav--d > *,
.tb-hero__nav--e > *{ pointer-events: auto; }
.tb-hero__nav--d{ gap: 14px; padding-right: 4%; }
.tb-hero__nav--e{ gap: 12px; padding-right: 4%; }
.tb-hero__nav--d,
.tb-hero__nav--e{ transform: translateY(-50%); height: 44px; }
.tb-hero__nav--d button{ width: 48px; height: 44px; opacity: .85; transition: opacity .3s; }
.tb-hero__nav--d button:hover{ opacity: 1; }
.tb-hero__nav--d svg{ width: 40px; height: 12px; stroke-width: 1; }
.tb-hero__count{
  color: #fff; font-family: 'Cormorant Garamond', 'Times New Roman', serif;
  font-size: 14px; letter-spacing: .12em; white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.tb-hero__count b{ font-weight: 400; }
.tb-hero__count i{ font-style: normal; opacity: .6; margin: 0 .35em; }
.tb-hero__nav--e button{ width: 32px; height: 44px; opacity: .85; transition: opacity .3s; }
.tb-hero__nav--e button:hover{ opacity: 1; }
.tb-hero__nav--e svg{ width: 8px; height: 16px; stroke-width: 1.4; }
.tb-hero__bar{ display: block; width: 72px; height: 1px; background: rgba(255,255,255,.35); overflow: hidden; }
.tb-hero__bar i{ display: block; width: 100%; height: 1px; background: #fff; transform-origin: 0 50%; transform: scaleX(0); }
.tb-hero__bar i.is-run{ transform: scaleX(1); transition: transform var(--tb-hero-bar, 6s) linear; }

/* 画面が狭いときは、文字を小さく */
@media (max-width: 1199.98px){ .tb-hero__text{ --tb-hero-scale: .85; } }
@media (max-width: 767.98px){
  .tb-hero{ height: var(--tb-hero-sp-h, 70vh); }
  .tb-hero__text{ --tb-hero-scale: .62; letter-spacing: .04em; padding: 0 20px; }
  .tb-hero__seg + .tb-hero__seg{ margin-left: .5em; }
  /* スマートフォン：3・4 は下部の中央 */
  .tb-hero__nav--d,
  .tb-hero__nav--e{ top: auto; bottom: 14px; transform: none; justify-content: center; padding-right: 0; }
  .tb-hero--arrows-1 .tb-hero__nav button{ width: 44px; }
  .tb-hero--arrows-1 .tb-hero__nav svg{ width: 12px; height: 26px; }
}

/* 動きを減らす設定の端末：ズームしない（フェードだけ） */
@media (prefers-reduced-motion: reduce){
  .tb-hero__slide.is-zoom .tb-hero__img{ transform: none; transition: none; }
}
