/* トップページの撮影前イラスト。写真に交換するときはこのCSSの読込を外せます。 */
.hero-photo.ph:has(.ph-img) { position: absolute; }
.hero-photo .ph-img { object-position: 65% center; }
.staff-lead-photo .illustration-team { object-position: center 30%; }
.svc-photo .illustration-visit { object-position: center 42%; }
.story-card .illustration-visit { object-position: center 38%; }
.illustration-note { margin: 24px 0 0; text-align: center; font-size: 12px; color: var(--ink-soft); line-height: 1.8; }
.staff-card .staff-photo:has(.ph-img) .role { z-index: 2; }
.page-hero-photo .ph-img { object-position: center; }
.message-photos .ph-img,
.team-photo .ph-img { object-position: center 25%; }
.voice-card .ph-img,
.staff-card .ph-img { object-position: center 20%; }
.access2-photo .ph-img { object-position: center; }
@media (max-width: 600px) {
  .hero-photo .ph-img { object-position: 76% center; }
  .hero-copy { top: auto; bottom: 32px; transform: none; }
  .hero-copy .quote { display: none; }
  .hero-copy .copy-line { box-shadow: 0 3px 16px rgba(31,92,66,.08); }
}

/* トップのメッセージ写真は、人物が重複しないよう1枚で見せる */
.msg-photos.is-single {
  grid-template-columns: minmax(0, 1fr);
  width: min(100%, 590px);
  max-width: none;
  justify-self: stretch;
}
.msg-photos.is-single .ph:nth-child(1) {
  width: 100%;
  aspect-ratio: 10 / 13;
}

.iv-photo-yamashita .ph-img {
  object-position: center 24%;
}
/* 採用ページ「代表からの一言」の丸写真（2026-09-14 小谷さんに変更）。縦長写真なので顔が中央に来るよう上寄りで切り抜く */
.rq-photo .ph-img {
  object-position: center 30%;
}

/* 共同代表：本文と低めの人物カードを分け、縦長に見えすぎない構成にする */
.greet2 {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(420px, .82fr);
  gap: clamp(24px, 4vw, 54px);
  align-items: center;
  padding: 0;
}
.greet2-band {
  min-height: 0;
  padding: clamp(36px, 5vw, 64px);
  border-radius: 18px;
}
.greet2-photo.is-duo {
  position: relative;
  inset: auto;
  width: auto;
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  overflow: visible;
  border-radius: 0;
  background: none;
  box-shadow: none;
  z-index: 2;
}
.representative-photo {
  margin: 0;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(46, 125, 91, .16);
  border-radius: 16px;
  box-shadow: 0 16px 34px rgba(31, 92, 66, .13);
}
.representative-photo img {
  display: block;
  width: 100%;
  height: clamp(230px, 22vw, 300px);
  object-fit: cover;
  object-position: center 20%;
}
.representative-photo figcaption {
  display: grid;
  gap: 2px;
  padding: 12px 14px 14px;
  color: var(--green-dark);
  font-family: var(--font-round);
  text-align: center;
}
.representative-photo figcaption strong {
  font-size: 15px;
  letter-spacing: .05em;
}
.representative-photo figcaption span {
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .08em;
}

/* 共同代表の写真が1人のとき（2026-09-14〜 小谷さんのみ）。
   2人並びと同じ枠の設定を使い、1枚だけ縦長の人物カードとして中央に置く */
.greet2-photo.is-solo {
  position: relative;
  inset: auto;
  width: auto;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 320px);
  justify-content: center;
  overflow: visible;
  border-radius: 0;
  background: none;
  box-shadow: none;
  z-index: 2;
}
.greet2-photo.is-solo .representative-photo img {
  height: auto;
  aspect-ratio: 4 / 5;   /* 横長に切り抜くと顔が大きく欠けるため、縦長にする */
}

/* 代表あいさつ B＋C案（2026-09-14）：スマホは「写真 → 見出し → 1段落目 → 続きを読む → 署名」。
   PCはボタンを出さず全文表示。隠すのは .js（JSが動いている）ときだけなので、JSが止まっても全文が読める */
.greet2-toggle,
.greet2-sign-br { display: none; }
@media (max-width: 900px) {
  .greet2-photo.is-solo { order: -1; }   /* 写真を文章の上へ */
  .js .greet2-more:not(.is-open) { display: none; }
  .js .greet2-toggle {
    display: inline-block;
    margin: -4px 0 18px;
    padding: 6px 0;
    border: 0;
    background: none;
    color: var(--green);
    font-family: var(--font-round);
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
  }
  .greet2-sign-br { display: inline; }
  .greet2-sign-sp { display: none; }   /* 改行したあとの行頭に全角スペースを残さない */
}

@media (max-width: 900px) {
  .greet2 {
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 0;
  }
  .greet2-photo.is-solo {
    margin-top: 0;
    aspect-ratio: auto;
    grid-template-columns: minmax(0, 280px);
  }
  .greet2-photo.is-duo {
    margin-top: 0;
    aspect-ratio: auto;
  }
  .representative-photo img {
    height: clamp(180px, 52vw, 280px);
  }
}

@media (max-width: 480px) {
  .greet2-photo.is-duo { gap: 8px; }
  .representative-photo { border-radius: 12px; }
  .representative-photo img { height: 180px; }
  .representative-photo figcaption { padding: 9px 6px 10px; }
  .representative-photo figcaption strong { font-size: 13px; }
  .representative-photo figcaption span { font-size: 9px; letter-spacing: .04em; }
}
