/* トップページ UX：内容は維持しつつ視認性・導線を最適化 */

/* --- ページ全体を少し明るく --- */
.i3-lang-root[data-i3-lang="ja"] #main {
  background: linear-gradient(180deg, #f6fcf9 0%, #ffffff 280px, #fafdfb 100%);
}

.i3-lang-root[data-i3-lang="ja"] .i3-chat-hub__title,
.i3-lang-root[data-i3-lang="ja"] .i3-chat-campaign__title {
  color: #1a5538 !important;
}

.i3-lang-root[data-i3-lang="ja"] .i3-chat-hub__lead,
.i3-lang-root[data-i3-lang="ja"] .i3-decision-routes__lead {
  color: #475569 !important;
}

/* --- トップ：主要サービス入口（ファーストビュー） --- */
.i3-top-intent-strip {
  max-width: 1080px;
  margin: 0.65rem auto 0.35rem;
  padding: 0.65rem 0.75rem 0.75rem;
  border-radius: 14px;
  border: 1px solid rgba(47, 122, 77, 0.22);
  background: linear-gradient(135deg, #f8fffb 0%, #ffffff 100%);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
}

.i3-top-intent-strip__lead {
  margin: 0 0 0.55rem;
  text-align: center;
  font-size: 0.92rem;
  line-height: 1.55;
  color: #334155;
  font-weight: 600;
}

.i3-top-intent-strip__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: center;
}

.i3-top-intent-strip__nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.42rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(47, 122, 77, 0.35);
  background: #ffffff;
  color: #166534 !important;
  font-size: 0.86rem;
  font-weight: 700;
  text-decoration: none !important;
}

.i3-top-intent-strip__nav a:hover,
.i3-top-intent-strip__nav a:focus-visible {
  background: #ecfdf3;
  border-color: rgba(47, 122, 77, 0.65);
  outline: 2px solid rgba(31, 111, 67, 0.2);
  outline-offset: 2px;
}

@media (max-width: 480px) {
  .i3-top-intent-strip__lead {
    font-size: 0.82rem;
  }
  .i3-top-intent-strip__nav a {
    font-size: 0.8rem;
    padding: 0.38rem 0.72rem;
  }
}

/* --- セクションジャンプ（意思決定ルート） --- */
.i3-section-jump {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: center;
  margin: 0.5rem auto 1.25rem;
  max-width: 1080px;
  padding: 0 0.5rem;
}

.i3-section-jump a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.38rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(47, 122, 77, 0.28);
  background: #ffffff;
  color: #1d7a3a !important;
  font-size: 0.84rem;
  font-weight: 700;
  text-decoration: none !important;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.04);
}

.i3-section-jump a:hover,
.i3-section-jump a:focus-visible {
  background: #f2fbf6;
  border-color: rgba(47, 122, 77, 0.55);
  outline: 2px solid rgba(31, 111, 67, 0.22);
  outline-offset: 2px;
}

.i3-section-jump__icon {
  font-size: 1rem;
  line-height: 1;
}

/* --- AI概算フロー図 --- */
.i3-flow-diagram {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  align-items: stretch;
  gap: 0.35rem;
  margin: 0.75rem 0 1rem;
}

.i3-flow-diagram__step {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 0.85rem 0.75rem;
  border: 1px solid rgba(72, 160, 110, 0.22);
  border-radius: 16px;
  background: linear-gradient(165deg, #ffffff 0%, #f8fdf9 100%);
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.04);
  min-height: 100%;
}

.i3-flow-diagram__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 12px;
  background: #eef9f2;
  font-size: 1.25rem;
  line-height: 1;
}

.i3-flow-diagram__badge {
  display: inline-block;
  width: fit-content;
  padding: 0.12rem 0.55rem;
  border-radius: 999px;
  background: #28a062;
  color: #fff !important;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.i3-flow-diagram__title {
  margin: 0;
  color: #1a5538;
  font-size: 0.98rem;
  font-weight: 800;
  line-height: 1.35;
}

.i3-flow-diagram__text {
  margin: 0;
  color: #5a7260;
  font-size: 0.84rem;
  line-height: 1.55;
}

.i3-flow-diagram__arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #28a062;
  font-size: 1.35rem;
  font-weight: 800;
  padding: 0 0.15rem;
}

/* テーマ別必要情報（アイコン付きチップ） */
.i3-theme-pills {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
  margin-top: 0.5rem;
}

.i3-theme-pill {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.75rem;
  border: 1px solid rgba(47, 122, 77, 0.2);
  border-radius: 14px;
  background: #fff;
}

.i3-theme-pill__head {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  color: #1a5538;
  font-weight: 800;
  font-size: 0.92rem;
}

.i3-theme-pill__head span:first-child {
  font-size: 1.15rem;
}

.i3-theme-pill p {
  margin: 0;
  color: #5a7260;
  font-size: 0.82rem;
  line-height: 1.55;
}

/* --- Why I-S3 比較カード --- */
.i3-compare-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.i3-compare-card {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 0.85rem 0.9rem;
  border-radius: 16px;
  border: 1px solid rgba(47, 122, 77, 0.22);
  background: #fff;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.04);
}

.i3-compare-card__icon {
  font-size: 1.35rem;
  line-height: 1;
}

.i3-compare-card__label {
  margin: 0;
  color: #6b8574;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.i3-compare-card__title {
  margin: 0;
  color: #1a5538;
  font-size: 0.95rem;
  font-weight: 800;
  line-height: 1.4;
}

.i3-compare-card__body {
  margin: 0;
  color: #445a4c;
  font-size: 0.86rem;
  line-height: 1.6;
}

.i3-compare-table-fold {
  margin-top: 0.5rem;
}

.i3-compare-table-fold summary {
  cursor: pointer;
  color: #28a062;
  font-weight: 700;
  font-size: 0.9rem;
}

/* --- 4資料チェックリスト（業種別） --- */
.i3-doc-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.55rem;
  margin: 0.75rem 0 1rem;
}

.i3-doc-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.35rem;
  padding: 0.65rem 0.45rem;
  border-radius: 14px;
  border: 1px dashed rgba(47, 122, 77, 0.35);
  background: #fafcfb;
}

.i3-doc-item__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.65rem;
  height: 1.65rem;
  border-radius: 50%;
  background: #28a062;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 800;
}

.i3-doc-item__icon {
  font-size: 1.4rem;
  line-height: 1;
}

.i3-doc-item strong {
  color: #1a5538;
  font-size: 0.82rem;
  line-height: 1.35;
}

.i3-doc-item span {
  color: #6b8574;
  font-size: 0.74rem;
  line-height: 1.45;
}

/* --- 地域ルート：カードにアイコン --- */
.i3-decision-routes__card {
  position: relative;
}

.i3-decision-routes__card-icon {
  display: block;
  font-size: 1.25rem;
  margin-bottom: 0.25rem;
  line-height: 1;
}

/* --- YouTube 後続導線 --- */
.i3-youtube-routes-primary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.i3-youtube-routes-primary a {
  flex: 1 1 160px;
}

.i3-youtube-routes-more summary {
  cursor: pointer;
  color: #28a062;
  font-weight: 700;
  font-size: 0.88rem;
  margin-top: 0.5rem;
}

.i3-youtube-routes-more .i3-journal__links {
  margin-top: 0.45rem;
}

/* --- キャッチフレーズ・メタリック --- */
#catchphrase {
  max-width: 960px;
  margin: 0.75rem auto !important;
  padding: 0.65rem 1rem;
  border-radius: 14px;
  background: linear-gradient(135deg, #fafffc 0%, #eef9f2 100%);
  border: 1px solid rgba(72, 160, 110, 0.16);
  color: #1d7a3a !important;
  font-size: clamp(0.95rem, 2.5vw, 1.15rem) !important;
  font-weight: 700;
  text-align: center;
  line-height: 1.5;
  transition: opacity 0.5s ease;
}

.metallic-text {
  font-size: clamp(0.72rem, 1.8vw, 0.88rem);
  opacity: 0.85;
}

.i3-top-summary__cards a::before {
  display: block;
  font-size: 1.35rem;
  margin-bottom: 0.25rem;
  line-height: 1;
}

.i3-top-summary__cards a[href*="ev-charger"]::before { content: "⚡"; }
.i3-top-summary__cards a[href*="selfconsumption"]::before { content: "☀️"; }
.i3-top-summary__cards a[href*="food-coldstorage"]::before { content: "🏭"; }
.i3-top-summary__cards a[href*="repowering"]::before { content: "🔄"; }
.i3-top-summary__cards a[href*="renewable-ev"]::before { content: "🌐"; }

/* --- チャットキャンペーン：コンパクト化 --- */
.i3-chat-campaign__grid {
  grid-template-columns: repeat(2, 1fr);
}

.i3-chat-campaign__card strong::before {
  margin-right: 0.35rem;
}

.i3-chat-campaign__card:nth-child(1) strong::before { content: "📷"; }
.i3-chat-campaign__card:nth-child(2) strong::before { content: "📊"; }
.i3-chat-campaign__card:nth-child(3) strong::before { content: "🔔"; }
.i3-chat-campaign__card:nth-child(4) strong::before { content: "💼"; }

/* --- 信頼ストリップ：横スクロール --- */
.i3-chat-trust-strip {
  overflow-x: auto;
  flex-wrap: nowrap;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  padding-bottom: 0.25rem;
}

.i3-chat-trust-strip span {
  flex-shrink: 0;
}

/* --- 固定ミニCTA（スクロール後） --- */
.i3-sticky-cta {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  z-index: 1040;
  display: flex;
  gap: 0.45rem;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.i3-sticky-cta.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.i3-sticky-cta a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 800;
  text-decoration: none !important;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.18);
}

.i3-sticky-cta__chat {
  background: linear-gradient(145deg, #34c978 0%, #28a062 100%);
  color: #fff !important;
}

.i3-sticky-cta__phone {
  background: #fff;
  color: #1d7a3a !important;
  border: 1px solid rgba(72, 160, 110, 0.28);
}

@media (max-width: 991px) {
  .i3-flow-diagram {
    grid-template-columns: 1fr;
  }

  .i3-flow-diagram__arrow {
    transform: rotate(90deg);
    padding: 0.15rem 0;
  }

  .i3-theme-pills {
    grid-template-columns: 1fr;
  }

  .i3-doc-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .i3-chat-campaign__grid {
    grid-template-columns: 1fr;
  }

  .metallic-text {
    display: none;
  }
}

.i3-chat-campaign-fold {
  margin-top: 0.75rem;
}

.i3-chat-campaign-fold > summary {
  font-weight: 800;
  color: #28a062;
}

.i3-chat-campaign-fold .i3-chat-campaign {
  margin-top: 0.65rem;
}

.i3-chat-campaign-fold .i3-chat-campaign__head .i3-chat-campaign__title {
  font-size: 1rem;
}

/* ご家庭ルート：カードアイコン */
.i3-everyday .i3-decision-routes__card strong::before {
  display: block;
  font-size: 1.25rem;
  margin-bottom: 0.2rem;
  line-height: 1;
}

.i3-everyday .i3-decision-routes__card:nth-child(1) strong::before { content: "🏠"; }
.i3-everyday .i3-decision-routes__card:nth-child(2) strong::before { content: "🔌"; }
.i3-everyday .i3-decision-routes__card:nth-child(3) strong::before { content: "🔋"; }
.i3-everyday .i3-decision-routes__card:nth-child(4) strong::before { content: "💬"; }

@media (prefers-reduced-motion: reduce) {
  #catchphrase {
    transition: none;
  }

  .i3-sticky-cta {
    transition: none;
  }
}

@media (max-width: 575px) {
  .i3-sticky-cta {
    left: 0.75rem;
    right: 0.75rem;
    justify-content: center;
  }

  .i3-sticky-cta a {
    flex: 1;
    justify-content: center;
  }
}

/* --- トップ：任意コンテンツの開閉グループ --- */
.i3-home-fold {
  max-width: 1080px;
  margin: 0.65rem auto 0.85rem;
  padding: 0 0.5rem;
  border: 1px solid rgba(47, 122, 77, 0.2);
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.04);
}

.i3-home-fold > summary.i3-home-fold__summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem 0.75rem;
  padding: 0.85rem 1rem;
  cursor: pointer;
  list-style: none;
  font-weight: 800;
  color: #1a5538;
}

.i3-home-fold > summary.i3-home-fold__summary::-webkit-details-marker {
  display: none;
}

.i3-home-fold > summary.i3-home-fold__summary::after {
  content: "＋";
  flex-shrink: 0;
  color: #28a062;
  font-size: 1.1rem;
  font-weight: 800;
  line-height: 1;
}

.i3-home-fold[open] > summary.i3-home-fold__summary::after {
  content: "－";
}

.i3-home-fold > summary.i3-home-fold__summary:hover,
.i3-home-fold > summary.i3-home-fold__summary:focus-visible {
  background: #f6fcf9;
  outline: 2px solid rgba(31, 111, 67, 0.18);
  outline-offset: -2px;
  border-radius: 16px;
}

.i3-home-fold__title {
  font-size: 0.98rem;
}

.i3-home-fold__hint {
  flex: 1 1 220px;
  color: #5a7260;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.45;
}

.i3-home-fold__body {
  padding: 0 0.85rem 1rem;
  border-top: 1px solid rgba(47, 122, 77, 0.12);
}

.i3-home-fold__body > .i3-decision-routes,
.i3-home-fold__body > section.i3-decision-routes {
  margin-top: 0.75rem;
}

.i3-home-fold--deep {
  margin-top: 1rem;
}

.i3-home-fold--compact {
  max-width: 960px;
}

.i3-home-fold--compact .panel {
  margin-bottom: 0;
  border: none;
  box-shadow: none;
  background: transparent;
}
