/* =============================================
   flow-a.css : お問い合わせから施工完了までの流れ
   ============================================= */

/* ── ベース ─────────────────────────────── */
.flow-a {
  padding: var(--sp-xl) 0;
  background-color: var(--clr-bg);
  position: relative;
  overflow: hidden;
}

/* ── Inner ──────────────────────────────── */
.flow-a__inner {
  max-width: var(--inner-width);
  margin: 0 auto;
  padding: 0 var(--inner-padding);
}

/* ── セクションヘッダー ──────────────────── */
.flow-a__header {
  text-align: center;
  margin-bottom: var(--sp-lg);
}

.flow-a__section-label {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-en);
  font-size: var(--fz-2xs);
  font-weight: 400;
  letter-spacing: 0.35em;
  color: var(--clr-gold);
  line-height: 1;
}

.flow-a__section-label::before,
.flow-a__section-label::after {
  content: '';
  display: block;
  width: 24px;
  height: 1px;
  background-color: var(--clr-gold);
  flex-shrink: 0;
}

.flow-a__section-title {
  font-family: var(--font-ja);
  font-size: var(--fz-xl);
  font-weight: 300;
  letter-spacing: 0.14em;
  color: var(--clr-white);
  line-height: 1.4;
  margin-top: var(--sp-sm);
}

.flow-a__section-desc {
  font-family: var(--font-ja);
  font-size: var(--fz-sm);
  font-weight: 300;
  letter-spacing: 0.08em;
  color: var(--clr-text-sub);
  line-height: 1.9;
  margin-top: var(--sp-sm);
}

/* ── ステップリスト（PC: 横並び）────────── */
.flow-a__list {
  display: flex;
  align-items: flex-start;
  gap: 0;
}

/* ── コネクター（ステップ間の矢印ライン）── */
.flow-a__connector {
  flex-shrink: 0;
  width: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 28px; /* ステップ番号の中央に合わせる */
}

.flow-a__connector::before {
  content: '';
  display: block;
  width: 100%;
  height: 1px;
  background: linear-gradient(
    90deg,
    var(--clr-gold) 0%,
    transparent 100%
  );
  opacity: 0.4;
}

/* ── ステップ ────────────────────────────── */
.flow-a__step {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: var(--sp-md) var(--sp-sm);
  background-color: var(--clr-bg-card);
  border: 1px solid var(--clr-border);
  position: relative;
  /* アニメーション初期状態 */
  opacity: 0;
  transform: translateY(20px);
}

.flow-a__step.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

/* ── ステップ番号 ─────────────────────────── */
.flow-a__step-number {
  font-family: var(--font-en);
  font-size: var(--fz-xl);
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--clr-gold);
  line-height: 1;
  margin-bottom: var(--sp-sm);
}

/* ── アイコンエリア（CSSのみ）────────────── */
.flow-a__step-icon {
  width: 48px;
  height: 48px;
  position: relative;
  border: 1px solid var(--clr-border);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--sp-sm);
  flex-shrink: 0;
}

.flow-a__step-icon::before {
  content: '';
  position: absolute;
  inset: 6px;
  border: 1px solid var(--clr-gold);
  opacity: 0.5;
}

.flow-a__step-icon-inner {
  width: 16px;
  height: 16px;
  background-color: var(--clr-gold);
  opacity: 0.5;
}

/* ── ステップタイトル ─────────────────────── */
.flow-a__step-title {
  font-family: var(--font-ja);
  font-size: var(--fz-sm);
  font-weight: 400;
  letter-spacing: 0.1em;
  color: var(--clr-white);
  line-height: 1.5;
  margin-bottom: var(--sp-xs);
}

/* ── ステップ説明文 ──────────────────────── */
.flow-a__step-desc {
  font-family: var(--font-ja);
  font-size: var(--fz-2xs);
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--clr-text-sub);
  line-height: 1.8;
}

/* ステップにホバー時のボーダーアクセント */
.flow-a__step::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--clr-gold);
  opacity: 0;
  transition: opacity var(--t-base);
}

.flow-a__step.is-visible:hover::before {
  opacity: 1;
}

/* ── Responsive ─────────────────────────── */
@media (max-width: 1024px) {
  .flow-a__list {
    flex-wrap: wrap;
    gap: var(--sp-sm);
  }

  .flow-a__step {
    flex: 1 1 calc(50% - var(--sp-sm));
  }

  .flow-a__connector {
    display: none;
  }
}

@media (max-width: 640px) {
  .flow-a__inner {
    padding: 0 var(--inner-padding-sp);
  }

  .flow-a__section-title {
    font-size: var(--fz-lg);
  }

  .flow-a__list {
    flex-direction: column;
    gap: 0;
  }

  .flow-a__connector {
    display: none;
  }

  .flow-a__step {
    flex: none;
    flex-direction: row;
    align-items: flex-start;
    text-align: left;
    padding: var(--sp-md);
    gap: var(--sp-md);
    border-bottom: none;
    border-left: none;
    border-right: none;
    position: relative;
  }

  /* SP: 左側ボーダーライン */
  .flow-a__step::after {
    content: '';
    position: absolute;
    left: 32px;
    bottom: -1px;
    top: auto;
    width: 1px;
    height: var(--sp-md);
    background-color: var(--clr-border);
  }

  .flow-a__step:last-child::after {
    display: none;
  }

  /* SP: 最初と最後のボーダー調整 */
  .flow-a__step:first-child {
    border-top: 1px solid var(--clr-border);
  }

  .flow-a__step + .flow-a__step {
    border-top: 1px solid var(--clr-border-dim);
  }

  /* SP: アイコンを左固定 */
  .flow-a__step-number {
    flex-shrink: 0;
    width: 40px;
    text-align: center;
    margin-bottom: 0;
    padding-top: 2px;
    font-size: var(--fz-md);
  }

  .flow-a__step-icon {
    display: none; /* SP では非表示 */
  }

  .flow-a__step-body {
    flex: 1;
    min-width: 0;
  }
}
