/* ページ種別「review」専用スタイル（旧HTMLのインライン<style>を統合・重複除去） */

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 30px;
  max-width: 1240px;
  margin: 0 auto;
  padding: 20px;
}

/* サービス概要ボックス */
.service-hero {
  background: transparent;
  border-radius: 0;
  padding: 28px 24px;
  margin: 24px 0 32px;
  border: none;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  position: relative;
}

.service-hero-grid {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 30px;
  align-items: center;
}

.service-logo-area {
  aspect-ratio: 300/250;
  border-radius: 0;
  overflow: hidden;
  border: 0;
  background: transparent;
}

.service-info h1 {
  font-size: 26px;
  margin-bottom: 10px;
}

.service-catch {
  color: var(--accent-dark);
  font-weight: 700;
  font-size: 15px;
  margin-bottom: 14px;
}

.rating-big {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

.rating-big .num {
  font-family: inherit;
  font-size: 40px;
  font-weight: 700;
  color: var(--primary-dark);
  line-height: 1;
}

.rating-big .max { font-size: 14px; color: var(--muted); }

.rating-details {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 16px 0;
}

.rating-detail {
  background: transparent;
  border-radius: 0;
  padding: 10px 0;
  text-align: center;
  border: none;
  border-right: 1px solid var(--border);
}

.rating-detail:last-child { border-right: none; }

.rating-detail .l { font-size: 10px; color: var(--muted); }

.rating-detail .v { font-weight: 700; color: var(--primary-dark); font-size: 16px; font-family: inherit; }

.service-cta-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 18px;
}

/* PR タグ */
.pr-badge {
  display: inline-block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 400;
  margin-right: 8px;
  vertical-align: middle;
}

.pr-badge::before { content: "["; }

.pr-badge::after { content: "]"; }

/* メリット・デメリット */
.pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin: 24px 0;
}

.pros-box, .cons-box {
  border-radius: 0;
  padding: 4px 0 0;
  background: transparent;
  border: none;
}

.pros-box h4, .cons-box h4 {
  font-size: 16px;
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1px dashed var(--border);
}

.pros-box h4 { color: var(--success); }

.cons-box h4 { color: var(--accent-dark); }

.pros-box ul, .cons-box ul {
  padding-left: 0;
  list-style: none;
  margin: 0;
}

.pros-box li, .cons-box li {
  padding: 6px 0 6px 26px;
  position: relative;
  font-size: 14px;
  line-height: 1.7;
}

.pros-box li::before {
  content: "○";
  position: absolute;
  left: 0;
  color: var(--success);
  font-weight: 700;
}

.cons-box li::before {
  content: "△";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}

/* サイドバー（ranking.htmlと共通） */
.side {
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: sticky;
  top: 100px;
  align-self: start;
}

.side-block {
  background: transparent;
  border: none;
  padding: 0 0 24px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.side-block h4 {
  font-size: 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--primary);
  margin-bottom: 14px;
  color: var(--primary-dark);
}

/* 記事タイトルブロック（共通） */
.article-title-block {
  background: transparent;
  padding: 20px 0 20px;
  border-radius: 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
}

.article-title-block .cat-tag {
  display: inline-block;
  color: var(--accent-dark);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 10px;
}

.article-title-block h1 {
  font-family: inherit;
  font-size: 26px;
  line-height: 1.6;
  margin-bottom: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.article-meta-line {
  display: flex;
  gap: 20px;
  font-size: 12px;
  color: var(--muted);
}

.article-main {
  background: transparent;
  padding: 0;
  border-radius: 0;
}

/* 口コミボックス */
.review-item {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  padding: 22px 20px;
  margin-bottom: 0;
}

.review-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.review-avatar { display: none; }

.review-user { font-weight: 700; font-size: 13px; }

.review-meta { font-size: 11px; color: var(--muted); }

.review-title { font-weight: 700; margin-bottom: 6px; font-size: 15px; }

.review-body { font-size: 13px; color: var(--text-sub); line-height: 1.8; }

.review-item.negative { background: transparent; }

/* 手順ステップ */
.step-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 24px 0;
}

.step-item {
  background: white;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 20px 16px;
  text-align: center;
  position: relative;
}

.step-num {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  width: 28px;
  height: 28px;
  background: var(--primary);
  color: white;
  border-radius: 50%;
  font-weight: 700;
  display: grid;
  place-items: center;
  font-size: 13px;
}

.step-item h5 {
  font-size: 14px;
  margin: 8px 0 6px;
  color: var(--text);
}

.step-item p {
  font-size: 12px;
  color: var(--muted);
  margin: 0;
  line-height: 1.6;
}

.step-icon { display: none; }

@media (max-width: 900px) {
  .article-layout { grid-template-columns: 1fr; padding: 12px; }
  .article-title-block, .article-main { padding: 24px 20px; }
  .article-title-block h1 { font-size: 20px; }
  .side { position: static; }
  .service-hero-grid { grid-template-columns: 1fr; }
  .rating-details { grid-template-columns: repeat(2, 1fr); }
  .pros-cons { grid-template-columns: 1fr; }
  .service-cta-row { grid-template-columns: 1fr; }
  .step-list { grid-template-columns: repeat(2, 1fr); }
}

/* 300x250 のクリエイティブを切り取らず、比率を保ったまま枠内に縮小して収める。
   枠のサイズ・レイアウト（240px / 4:3）は変更しない。
   styles.css 側の `object-fit: cover` を確実に打ち消すため body を付けて特異度を上げる。 */
body .service-logo-area { background: transparent; }
/* v1 で画像を <a class="service-logo-link"> の中に入れたため、直下セレクタ（> img）が
   届かなくなり、幅・高さ・object-fit の指定がすべて外れていた（＝比率が崩れる）。
   リンクを挟んだ img にも同じ寸法・同じ contain を当てる。 */
body .service-logo-area > .service-logo-link {
  position: absolute; inset: 0; z-index: 3; display: block;
}
body .service-logo-area > img,
body .service-logo-area > .service-logo-link > img {
  position: absolute; inset: 0; z-index: 2;
  width: 100%; height: 100%;
  object-fit: contain; object-position: center; display: block;
}

/* ==========================================================================
   ① レスポンシブ対応（レビューページ）
   レビューページは page-ranking.css を読み込まないため、
   .company-info-table / .company-actions の定義がどこにも無く、
   ブラウザ既定の表レイアウトになっていた（＝左列が見出しごとに潰れて縦積み改行）。
   ランキングページと同じ見た目をここに持たせて揃える。
   ========================================================================== */
.company-info-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin-bottom: 0;
  background: #fff;
  border: 1px solid var(--border);
  overflow: hidden;
}

.company-info-table th,
.company-info-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
  line-height: 1.7;
}

.company-info-table tr:last-child th,
.company-info-table tr:last-child td { border-bottom: none; }

.company-info-table th {
  background: #fff;
  color: var(--text-sub);
  font-weight: 700;
  width: 30%;
}

/* 下部CTA（他社と比較する／公式サイトを見る）を等幅2列に並べる。
   定義が無いとインライン要素として並び、幅がバラバラのまま折り返していた。 */
.company-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 10px;
}

.company-actions > .btn-cta,
.company-actions > .btn-secondary {
  width: 100%;
  padding-left: 16px;
  padding-right: 16px;
  text-align: center;
}

@media (max-width: 900px) {
  .company-actions { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .info-box { padding: 0 14px 14px; }
  .info-box .label { margin: 0 -14px 12px; padding: 9px 12px; }
  /* 左列（項目名）を潰さない。文字と余白を落として2〜3行に収める */
  .company-info-table { font-size: 12.5px; }
  .company-info-table th { width: 36%; padding: 9px 10px; }
  .company-info-table td { padding: 9px 10px; }
}

/* ==========================================================================
   締めのCTA
   .article-layout の最後の要素として置く。2カラム（PC）では本文カラムの下に収まり、
   1カラム（スマホ）ではサイドバーの後ろ＝ページの最後に来る。
   ＝どの幅でも「CTAで締める」形になる。
   ========================================================================== */
.closing-cta {
  grid-column: 1;
  padding: 22px 20px;
  background: #fff;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
}
.closing-cta-lead {
  margin: 0 0 14px;
  font-size: 14px;
  line-height: 1.85;
  color: var(--text-sub);
}
.closing-cta .company-actions { margin-top: 0; }

/* ==========================================================================
   中間CTA（1回だけ）
   本文の見出しの中間地点に差し込む。末尾CTA・追従CTAと役割を分け、
   ここは「誘導文＋ボタン1つ」に絞って広告過多に見せない。
   ========================================================================== */
.mid-cta {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 14px;
  margin: 34px 0;
  padding: 18px 20px;
  background: var(--primary-pale);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.mid-cta-lead { margin: 0; flex: 1 1 240px; font-size: 14px; line-height: 1.8; color: var(--text); }
.mid-cta .btn-cta { flex: 0 0 auto; padding: 12px 22px; min-height: 46px; font-size: 14px; }

.mid-cta-lead strong { font-weight: 700; }

/* .article-body p { margin-bottom: 26px } に負けて下側だけ余白が付き、
   テキストが枠の中央より上に見えていた。特異度を上げて打ち消す。 */
.article-body .mid-cta > .mid-cta-lead,
.mid-cta > .mid-cta-lead,
.mid-cta > .btn-cta { margin: 0; }

/* ④ レビュー本文内のCTAセクション: 企業名の表記 */
.cta-box-head { margin-bottom: 8px; line-height: 1.6; }
.cta-box-head .c { font-size: 13px; font-weight: 700; color: var(--muted); letter-spacing: .02em; }
.cta-box-head .n { font-size: 20px; font-weight: 700; }
.cta-box-head .n:hover { color: var(--link); }

@media (max-width: 480px) {
  .mid-cta { flex-direction: column; align-items: stretch; }
  .mid-cta .btn-cta { width: 100%; }
  .cta-box-head .c { display: block; font-size: 12px; }
  .cta-box-head .n { font-size: 18px; }
}

/* ==========================================================================
   東京ガス用：LP型レビューページのパーツ
   ・hero-note / lp-lead：結論を早く伝える導入
   ・camp-*：キャンペーン3枚（クリック想起のため本文中に独立配置）
   ・flow-list：注文の流れ
   ========================================================================== */
.hero-note { margin: 10px 0 0; font-size: 12.5px; color: var(--muted); line-height: 1.6; }
.lp-lead { font-size: 15.5px; line-height: 2; }

.price-cell { color: var(--accent-dark); font-weight: 700; }
.save-cell { color: var(--success); font-weight: 700; }

.camp { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 26px 0 12px; }
.camp-card {
  display: flex; flex-direction: column;
  padding: 0 0 12px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}
.camp-title {
  padding: 9px 12px 8px;
  margin-bottom: 10px;
  background-color: #D8201F;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12'%3E%3Cpath d='M-2 12L12 -2M4 18L18 4' stroke='%23ffffff' stroke-opacity='0.10' stroke-width='3.5'/%3E%3C/svg%3E");
  border-bottom: 0;
  border-radius: calc(var(--radius-sm) - 1px) calc(var(--radius-sm) - 1px) 0 0;
  font-size: 14.5px; font-weight: 800; line-height: 1.32;
  letter-spacing: .01em;
  color: #FFEF00;
  text-shadow: 0 1px 0 rgba(120, 0, 0, .45);
  min-height: 3.2em;
  display: flex; align-items: center;
}
.camp-menu,
.camp-period,
.camp-coupon,
.camp-cta { margin-left: 13px; margin-right: 13px; }
.camp-menu { flex: 1 0 auto; margin-bottom: 10px; padding: 0; list-style: none; font-size: 13px; line-height: 1.5; color: var(--text); }
.camp-menu li { padding: 4px 0; border-bottom: 1px dotted var(--border); }
.camp-menu li:first-child { padding-top: 0; }
.camp-menu b { color: var(--accent-dark); white-space: nowrap; }
.camp-period {
  margin-bottom: 8px;
  padding: 8px 9px;
  background: #FAF8F3;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.cp-row { display: flex; flex-wrap: nowrap; align-items: baseline; gap: 6px; }
.cp-row + .cp-row { margin-top: 1px; }
.cp-k {
  flex: none;
  padding: 1px 6px;
  background: var(--primary-pale, #EEF3F1); color: var(--primary-dark);
  border-radius: 3px;
  font-size: 12.5px; font-weight: 700; letter-spacing: .02em;
}
.cp-v { font-size: 14px; font-weight: 600; color: var(--text); line-height: 1.4; }
.camp-cta {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  margin-top: auto;
  min-height: 42px; padding: 9px 10px;
  background: var(--accent); color: #fff !important;
  border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 700; line-height: 1.4;
  text-decoration: none !important;
  transition: background .2s var(--ease);
}
.camp-cta:hover { background: var(--accent-hover); }
.camp-cta .arw { font-size: 15px; line-height: 1; }

.flow-list { margin: 20px 0 0; padding: 0; list-style: none; counter-reset: flow; }
.flow-list li { position: relative; padding: 0 0 18px 42px; margin: 0; }
.flow-list li::before {
  counter-increment: flow; content: counter(flow);
  position: absolute; left: 0; top: 0;
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--primary); color: #fff;
  font-size: 12px; font-weight: 700; display: flex; align-items: center; justify-content: center;
}
.flow-list li::after {
  content: ""; position: absolute; left: 13px; top: 28px; bottom: 2px;
  border-left: 1px dotted var(--border-strong);
}
.flow-list li:last-child::after { display: none; }
.flow-list b { display: block; font-size: 14px; }
.flow-list span { display: block; margin-top: 3px; font-size: 12.5px; color: var(--text-sub); line-height: 1.7; }

.closing-cta-sub { margin-top: 10px; font-size: 12px; color: var(--muted); }
.disclaimer { font-size: 12px; color: var(--muted); border-top: 1px dotted var(--border); padding-top: 20px; margin-top: 34px; }

@media (max-width: 860px) {
  .camp { grid-template-columns: 1fr; }
  .camp-card.is-main::before { top: -11px; }
  .camp-price { font-size: 26px; }
}

.camp-coupon {
  display: flex; flex-wrap: nowrap; align-items: baseline; justify-content: center;
  gap: 0 9px;
  margin: 14px 0 6px;
  padding: 11px 12px 10px;
  background: #241F1C;
  border: 0;
  border-radius: 4px;
}
.camp-coupon .cp-label {
  flex: none;
  color: #C9C0B8;
  font-size: 12px; font-weight: 500; letter-spacing: .06em;
  line-height: 1.4; white-space: nowrap;
}
.camp-coupon code {
  font-family: ui-monospace, SFMono-Regular, Menlo, "Roboto Mono", monospace;
  font-size: 22px; font-weight: 800; line-height: 1.1;
  color: #FFFFFF;
  letter-spacing: .03em;
  text-align: center;
  white-space: nowrap;
}
.camp-coupon-note {
  display: block;
  margin-top: 6px;
  font-size: 11.5px; line-height: 1.45; color: var(--muted);
  letter-spacing: .01em; text-align: center;
}
@media (max-width: 860px) {
  .camp-coupon code { font-size: 24px; }
  .camp-coupon .cp-label { font-size: 12.5px; }
}
}
}
/* カード3枚は内容量を揃えて高さを自然に一致させる（min-heightでの空白埋めは廃止） */
.camp { align-items: stretch; }
.camp-card { height: 100%; }

@media (max-width: 860px) {
  .camp-card.is-main { margin-top: 12px; }
  .camp-cta { min-height: 44px; font-size: 13px; }
}

/* ==========================================================================
   東京ガス 中段バナー（960×318 の実画像 /images/ads/tokyogas_oosouji.webp）
   ・列幅に合わせて縮小。アスペクト比 960:318 は width/height 指定で確保
   ・リンクは画像全体。ホバーで僅かに反応させる
   ========================================================================== */
.tg-banner { margin: 40px 0; }
.banner-period {
  max-width: 960px; margin: 8px auto 0;
  padding: 10px 14px;
  background: #FAF8F3;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.banner-period .cp-k { font-size: 12.5px; }
.banner-period .cp-v { font-size: 14px; }
.banner-period .bp-title { margin-bottom: 7px; font-size: 13.5px; font-weight: 700; color: var(--text); letter-spacing: .02em; }
.tg-banner-link {
  display: block;
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  border-radius: var(--radius-sm);
  overflow: hidden;
  line-height: 0;
  box-shadow: var(--shadow-md);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.tg-banner-link:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.tg-banner-link img { display: block; width: 100%; height: auto; }

@media (max-width: 620px) {
  .tg-banner { margin: 28px 0; }
  .tg-banner-link:hover { transform: none; }
}

/* ============ 料金表（レビュー記事用） ============
   page-ranking.css の .price-table と同じ見た目を、
   レビューページでも使えるように読み込み対象へ追加したもの。
   追加理由：レビュー記事は page-review.css しか読まないため、
   .price-table を書いても罫線・ヘッダー色が当たらず「表に見えない」状態だった。 */
.price-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid var(--border);
  margin: 20px 0;
  font-size: 14px;
}
.price-table th, .price-table td {
  padding: 14px;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
  text-align: center;
}
.price-table th:last-child, .price-table td:last-child { border-right: none; }
.price-table thead th { background: var(--primary); color: white; }
.price-table tbody th {
  background: #fff; color: var(--text); text-align: left; font-weight: 700;
}
.price-table .price-cell { font-weight: 700; color: var(--accent-dark); }
@media (max-width: 640px) {
  .price-table { font-size: 12.5px; }
  .price-table th, .price-table td { padding: 9px 8px; }
}
