/**
 * Guide Page Styles
 * 初めての方へ（Guide）ページのスタイル
 * モバイルファースト: デフォルト = SP, @media (min-width: 768px) = PC
 *
 * @package KNOT_For_Dogs
 */

/* SP: l-container の左右余白を16pxに縮小（Figma SP: px-16px）
   l-container のデフォルト --sp-lg:2rem (32px) をguideページのみ上書き */
@media (max-width: 767px) {
  .p-guide .l-container {
    width: min(var(--content-width), 100% - 16px * 2);
  }
}

/* ============================================================
   パンくずリスト
   ============================================================ */
.p-guide__breadcrumb-wrap {
  border-top: 1px solid var(--color-subtle);
  padding-block: 8px;
}

/* SP: パンくずリスト非表示 */
@media (max-width: 767px) {
  .p-guide__breadcrumb-wrap {
    display: none;
  }
}

/* パンくずリスト コンポーネント（guideページ用） */
.p-guide .c-breadcrumb__list {
  display: flex;
  gap: 8px;
  padding-left: 0;
  list-style: none;
  max-width: 1080px;
  margin-inline: auto;
}

.p-guide .c-breadcrumb__link {
  font-size: 11px;
  font-weight: 500;
  color: #80746A;
}

.p-guide .c-breadcrumb__separator {
  font-size: 11px;
  color: #EAE4DE;
}

/* PC-2/3: パンくずリスト現在ページ */
.p-guide .c-breadcrumb__current {
  font-size: 11px;
  color: #69645A;
}

/* ============================================================
   セクション見出し（.c-heading）guideページ用上書き
   ============================================================ */
.p-guide .c-heading {
  font-size: 16px;
  font-weight: 500;
  color: #80746A;
  text-align: left;
}

.p-guide .c-heading__sub {
  font-size: 24px;
  font-weight: 700;
  color: #4A4844;
}

/* ============================================================
   Section 1: ヒーロー
   ============================================================ */
.p-guide__hero {
  border-top: 1px solid var(--color-subtle);
  padding-top: 32px;
  padding-bottom: 32px; /* SP-2: Figma SP padding-bottom 32px */
}

.p-guide__hero-inner {
  display: flex;
  flex-direction: column;
  gap: 48px;
  /* l-container が 100% - 64px で横幅制御しているため padding-inline は不要 */
  padding-inline: 0;
}

@media (min-width: 768px) {
  .p-guide__hero {
    border-top: none;
    padding-bottom: 48px;
  }

  .p-guide__hero-inner {
    flex-direction: row;
    align-items: center;
    gap: 48px;
    max-width: 1080px;
  }
}

.p-guide__hero-image {
  width: 100%;
}

@media (min-width: 768px) {
  .p-guide__hero-image {
    flex: 0 0 auto;
    width: 642px;
  }
}

.p-guide__hero-image img {
  width: 100%;
  height: auto;
  aspect-ratio: 642 / 388;
  display: block;
}

.p-guide__hero-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

@media (min-width: 768px) {
  .p-guide__hero-content {
    flex: 1;
    gap: 24px;
  }
}

.p-guide__hero-label {
  font-family: var(--font-en);
  font-size: 16px;
  font-weight: 500;
  color: var(--color-accent);
  margin: 0;
  line-height: 1.4;
  /* ラベルとタイトルの間のgapを4pxに（Figma: header gap 4px）
     hero-content gap:16px(SP)/24px(PC) → ラベル下のマージンで詰める */
  margin-bottom: -12px; /* SP: gap16px を実質4pxにするため12px引く */
}

@media (min-width: 768px) {
  .p-guide__hero-label {
    margin-bottom: -20px; /* PC: gap24px を実質4pxにするため20px引く */
  }
}

.p-guide__hero-title {
  font-family: var(--font-ja);
  font-size: 32px; /* SP-1: Figma SP font-size 32px */
  font-weight: 700;
  color: var(--color-text-sub);
  line-height: var(--lh-tight);
  margin: 0;
}

@media (min-width: 768px) {
  .p-guide__hero-title {
    font-size: 32px;
  }
}

.p-guide__hero-desc {
  font-family: var(--font-ja);
  font-weight: 500;
  font-size: 14px;
  color: var(--color-text-sub);
  line-height: 1.6;
  margin: 0;
}

/* ============================================================
   Section 2: 施設写真
   ============================================================ */
.p-guide__facility {
  position: relative;
  height: 320px;
  overflow: hidden;
}

@media (min-width: 768px) {
  .p-guide__facility {
    height: 480px;
  }
}

.p-guide__facility-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.4;
}

.p-guide__facility-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.p-guide__facility-text {
  font-family: var(--font-ja);
  font-size: 32px;
  font-weight: 700;
  color: var(--color-accent);
}

/* ============================================================
   Section 3: 体験の1日の流れ
   ============================================================ */
.p-guide__flow {
  background-color: var(--color-base);
  padding-block: 48px;
}

.p-guide__flow-inner {
  max-width: 1080px;
  /* l-container が 100% - 64px で横幅制御しているため padding-inline は不要 */
  padding-inline: 0;
}

/* ステップ群コンテナ — 縦線（PC）のアンカー */
.p-guide__steps {
  display: flex;
  flex-direction: column;
  gap: 64px;
  margin-top: 48px;
  position: relative;
}

/* 縦の点線（SP・PC共通） */
.p-guide__steps::before {
  content: '';
  position: absolute;
  left: 22px; /* バッジ中心(24px) - ドット幅(4px)/2 */
  top: 0;
  bottom: 0;
  width: 4px;
  background-image: url('../../images/guide/step-wave.svg');
  background-repeat: repeat-y;
  background-size: 4px 10px; /* SVG実寸(10px)に合わせる: ドット2px + ギャップ8px */
  background-position: center top;
  z-index: 0;
}

@media (min-width: 768px) {
  .p-guide__steps {
    margin-top: 24px;
  }

  .p-guide__steps::before {
    top: 74px;    /* Step 01 番号円中心 */
    bottom: 168px; /* Step 04 番号円中心 */
  }
}

/* ===== 各ステップ ===== */
.p-guide__step {
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
  z-index: 1;
}

@media (min-width: 768px) {
  .p-guide__step {
    flex-direction: row;
    align-items: flex-start;
    gap: 48px;
  }
}

/* SP: ヘッダー行（番号 + イラスト）*/
.p-guide__step-head {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 16px;
}

@media (min-width: 768px) {
  /* PCではrow方向に（Figmaと同じ: 円→イラスト→コンテンツ の横並び） */
  /* こうすることで番号円が常に左端に位置し、::beforeの left:24px と一致する */
  .p-guide__step-head {
    flex-direction: row;
    align-items: center;
    gap: 48px;
    flex-shrink: 0;
  }
}

/* 番号円 */
.p-guide__step-num {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  border-radius: 50%;
  background-color: var(--color-accent);
  font-family: 'Lora', serif;
  font-size: 24px;
  font-weight: 400;
  color: var(--color-on-dark);
  line-height: 0.7;
}

/* ===== SP: step-head内のラベル+タイトル ===== */
.p-guide__step-head-text {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}

.p-guide__step-head-text .p-guide__step-label {
  font-family: var(--font-en);
  font-size: 16px;
  font-weight: 500;
  color: var(--color-accent);
  margin: 0;
  line-height: 1.4;
}

.p-guide__step-head-text .p-guide__step-title {
  font-family: var(--font-ja);
  font-size: 20px;
  font-weight: 700;
  color: var(--color-text-main);
  line-height: 1.6;
  margin: 0;
}

/* ステップイラスト（SP: head内, PC: head内の縦並び） */
.p-guide__step-illust {
  flex-shrink: 0;
}

.p-guide__step-illust img {
  display: block;
  max-width: 160px;
  height: auto;
}

@media (min-width: 768px) {
  .p-guide__step-illust img {
    max-width: 160px;
  }
}

/* SP: step直下の独立イラスト（中央配置） */
.p-guide__step > .p-guide__step-illust {
  align-self: center;
}

/* ステップ本文 */
.p-guide__step-body {
  display: flex;
  flex-direction: column;
  gap: 16px; /* Figma: step body gap 16px */
  flex: 1;
}

.p-guide__step-label {
  font-family: var(--font-en);
  font-size: 16px;
  font-weight: 500;
  color: var(--color-accent);
  margin: 0;
  line-height: 1.4;
}

.p-guide__step-title {
  font-family: var(--font-ja);
  font-size: 20px;
  font-weight: 700;
  color: var(--color-text-main);
  line-height: 1.6;
  margin: 0;
}

.p-guide__step-time {
  font-family: var(--font-ja);
  font-size: 14px;
  font-weight: 500;
  color: var(--color-accent);
  margin: 0;
}

.p-guide__step-desc {
  font-family: var(--font-ja);
  font-size: 16px;
  font-weight: 500;
  color: var(--color-text-muted);
  line-height: 1.6;
  margin: 0;
}

/* bullet リスト */
.p-guide__step-bullets {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.p-guide__step-bullet {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-ja);
  font-size: 16px;
  font-weight: 500;
  color: #4A4844; /* PC-6: Figma bullet text color #4A4844 */
  line-height: 1.6;
}

.p-guide__step-bullet::before {
  content: '';
  display: inline-block;
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--color-illust);
}

/* Step 01: QRボックス（PC） */
.p-guide__step-qr {
  border: 1px solid var(--color-accent, #80746A);
  border-radius: var(--radius-md);
  padding: 12px;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
}

@media (min-width: 768px) {
  .p-guide__step-qr {
    display: flex !important; /* u-pc-only の display:block !important を上書き */
  }
}

/* Step 01: step-content wrapper（SP/PC共通の縦積み） */
.p-guide__step-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Step 01: bodyの中で content と QR を横並びに（PC） */
@media (min-width: 768px) {
  .p-guide__step--01 .p-guide__step-body {
    flex-direction: row;
    align-items: flex-start;
    gap: 32px;
  }

  .p-guide__step-content {
    flex: 1;
  }

  /* Step01: content は自然幅（whitespace-nowrap）、QR は残りを埋める */
  .p-guide__step--01 .p-guide__step-content {
    flex: 0 0 auto;
  }
  .p-guide__step--01 .p-guide__step-qr {
    flex: 1 0 0;
    min-width: 0;
  }

  /* PC-5: Step 02 body の gap を 8px に */
  .p-guide__step--02 .p-guide__step-body {
    gap: 8px;
  }
}

.p-guide__step-qr-label {
  font-family: var(--font-ja);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-text-muted);
  text-align: center;
  margin: 0;
}

/* Step 01: CTAボタン（SP） */
.p-guide__step-cta-btn {
  display: flex; /* inline-flex → flex (block-level) でwidth:100%を確実に適用 */
  width: 100%;
  text-align: center;
  margin-top: 4px;
  white-space: nowrap; /* Figma SP: テキスト折り返し禁止 */
}

/* Step 03: PC版でdesc折り返し禁止（Figma: whitespace-nowrap） */
@media (min-width: 768px) {
  .p-guide__step--03 .p-guide__step-desc {
    white-space: nowrap;
  }
}

/* Step 03 / 04: 右側イラスト（PC） */
.p-guide__step-illust-right {
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

/* Step 04: 右側SVGをテキスト下端に揃える */
@media (min-width: 768px) {
  .p-guide__step--04 .p-guide__step-illust-right {
    align-self: flex-end;
  }
}

.p-guide__step-illust-right img {
  display: block;
  height: auto;
  max-width: 360px;
}

/* Step 04: フィードバック + 人物のグループ */
.p-guide__step04-illust-group {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.p-guide__step04-illust-group img {
  display: block;
  height: auto;
}

/* 注記テキスト */
.p-guide__flow-note {
  font-family: "Zen Old Mincho", serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-accent);
  margin-top: 24px;
  margin-bottom: 0;
}

/* ===== 特典バナー ===== */
.p-guide__benefit {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-start;
  outline: 2px solid var(--color-illust);
  outline-offset: -2px;
  border: 2px solid #c2bdb8;
  border-radius: var(--radius-md);
  padding: 16px;
  background-color: var(--color-base);
  margin-top: 48px;
}

@media (min-width: 768px) {
  .p-guide__benefit {
    flex-direction: row;
    align-items: center;
    gap: 12px;
    padding: 16px 32px;
  }
}

/* メダルアイコン: Figmaの絶対座標配置を再現 */
.p-guide__benefit-icon-group {
  position: relative;
  width: 30px;
  height: 41px;
  flex-shrink: 0;
}

.p-guide__benefit-icon-group img {
  position: absolute;
  display: block;
}

.p-guide__benefit-icon--star {
  left: 0;
  top: 0;
  width: 29.968px;
  height: 29.551px;
  z-index: 1;
}

.p-guide__benefit-icon--circle {
  left: 3.34px;
  top: 3.45px;
  width: 23.394px;
  height: 23.394px;
  z-index: 2;
}

.p-guide__benefit-icon--ribbon {
  left: 3.22px;
  top: 16.86px;
  width: 23.413px;
  height: 23.248px;
  z-index: 3;
}

.p-guide__benefit-icon--stamp {
  left: 8px;
  top: 7.89px;
  width: 14px;
  height: 14px;
  z-index: 4;
}

.p-guide__benefit-text {
  font-family: var(--font-ja);
  font-weight: 500;
  font-size: 16px;
  color: var(--color-text-sub);
  line-height: 1.6;
  margin: 0;
}

/* ============================================================
   Section 4: 体験でできること
   ============================================================ */
.p-guide__what {
  background-color: var(--color-surface-soft);
  padding-block: 48px;
}

.p-guide__what-inner {
  max-width: 1080px;
  /* l-container が 100% - 64px で横幅制御しているため padding-inline は不要 */
  padding-inline: 0;
  display: flex;
  flex-direction: column;
  gap: 48px;
}

@media (min-width: 768px) {
  .p-guide__what-inner {
    flex-direction: row;
    align-items: center;
    gap: 48px;
  }
}

.p-guide__what-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

@media (min-width: 768px) {
  .p-guide__what-content {
    flex: 1;
  }
}

.p-guide__what-lead,
.p-guide__what-closing {
  font-family: var(--font-ja);
  font-weight: 500;
  font-size: 16px;
  color: var(--color-text-sub);
  line-height: 1.6;
  margin: 0;
}

/* アイテムカード */
.p-guide__what-cards {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.p-guide__what-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  background-color: var(--color-base);
  padding: 12px 32px 12px 16px;
  width: 100%;
}

.p-guide__what-dot {
  display: inline-block;
  flex-shrink: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: var(--color-illust);
}

.p-guide__what-card-text {
  font-family: var(--font-ja);
  font-weight: 500;
  font-size: 16px;
  color: var(--color-text-sub);
}

/* 右側画像 */
.p-guide__what-image {
  width: 100%;
}

@media (min-width: 768px) {
  .p-guide__what-image {
    flex-shrink: 0;
    width: 533px;
  }
}

.p-guide__what-image img {
  display: block;
  width: 100%;
  height: auto;
}

/* ============================================================
   Section 5: 体験当日の持ち物
   ============================================================ */
.p-guide__items {
  background-color: var(--color-base);
  padding-block: 48px;
}

.p-guide__items-inner {
  max-width: 1080px;
  /* l-container が 100% - 64px で横幅制御しているため padding-inline は不要 */
  padding-inline: 0;
}

/* カードグリッド */
.p-guide__item-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-top: 48px;
}

@media (min-width: 768px) {
  .p-guide__item-cards {
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
  }
}

/* 個別カード */
.p-guide__item-card {
  position: relative;
  outline: 1px solid var(--color-accent);
  outline-offset: -1px;
  border-radius: 12px;
  padding: 48px 16px 24px;
  background-color: var(--color-base);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

/* バッジ（絶対配置） */
.p-guide__item-badge {
  position: absolute;
  top: -16px;
  left: 50%;
  transform: translateX(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-en);
  font-size: 28px;
  font-weight: 500;
  color: var(--color-on-dark);
  line-height: 1;
  padding-top: 3px; /* Loraフォントのベースライン視覚補正 */
}

/* イラストエリア */
.p-guide__item-illust {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  min-height: 80px;
}

.p-guide__item-illust img {
  display: block;
  height: auto;
}

/* カードタイトル */
.p-guide__item-title {
  font-family: var(--font-ja);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-text-sub);
  text-align: center;
  line-height: 1.6;
  margin: 0;
}

@media (min-width: 768px) {
  .p-guide__item-title {
    font-size: 20px;
  }
}

/* カードサブテキスト */
.p-guide__item-sub {
  font-family: "Zen Old Mincho", serif;
  font-size: 14px;
  color: var(--color-accent);
  text-align: center;
  margin: 0;
  /* Figma: titleとsubは直接隣接（gap 0）。カードgap 12pxを打ち消す */
  margin-top: -12px;
}

/* 注記テキスト */
.p-guide__items-note {
  font-family: "Zen Old Mincho", serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-accent);
  margin-top: 16px;
  margin-bottom: 0;
}

/* ===== FAQバナー ===== */
.p-guide__faq-banner {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: flex-start;
  background-color: var(--color-surface-gray);
  border: 2px solid #c2bdb8;
  border-radius: var(--radius-md);
  padding: 24px 16px;
  margin-top: 48px;
}

@media (min-width: 768px) {
  .p-guide__faq-banner {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0px;
    border-radius: 0px;
    padding: 24px 32px;
  }
}

.p-guide__faq-banner-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.p-guide__faq-stamp {
  display: block;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.p-guide__faq-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.p-guide__faq-label {
  font-family: var(--font-en);
  font-size: 20px;
  font-weight: 600;
  color: var(--color-accent);
  line-height: 1;
  letter-spacing: 0.6px;
}

.p-guide__faq-title {
  font-family: var(--font-ja);
  font-size: 24px;
  font-weight: 700;
  color: var(--color-text-main);
  line-height: 1.6;
}

.p-guide__faq-link {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-ja);
  font-size: 16px;
  color: #69645a;
  text-decoration: none;
}

@media (max-width: 767px) {
  .p-guide__faq-link {
    align-self: flex-end;
  }

  /* 番号円: SP用padding追加（中央配置はflexboxで維持） */
  .p-guide__step-num {
    padding: 12px;
  }

  /* SP-3: Step 02/03/04: body内のgapをFigma SP値12pxに調整 */
  .p-guide__step--02 .p-guide__step-body,
  .p-guide__step--03 .p-guide__step-body,
  .p-guide__step--04 .p-guide__step-body {
    gap: 12px;
  }

  /* SP-11: benefit バナーをflex row（メダル左・テキスト右）に */
  .p-guide__benefit {
    flex-direction: row;
    align-items: center;
  }

  /* FAQバナー: SPでborder-radiusを0に */
  .p-guide__faq-banner {
    border-radius: 0px;
  }
}

.p-guide__faq-link:hover {
  opacity: 0.7;
  transition: opacity var(--duration-fast) var(--ease-out);
}

.p-guide__faq-link img {
  display: block;
  width: 20px;
  height: 20px;
}

/* ============================================================
   フッターCTA
   ============================================================ */
.p-guide__contact {
  /* section-contact-cta コンポーネントの p-contact クラスが適用される */
}
