/*
Theme Name: 拓法律事務所（HIRAKU LAW OFFICE）
Theme URI: https://hiraku.lawyer/
Description: 拓法律事務所（HIRAKU LAW OFFICE）専用の子テーマです。ブランドカラー（深紺 #0F2747 / ゴールド #B8985E）とタイポグラフィを theme.json で定義し、ヘッダー・フッター・トップページの各セクションを WordPress 標準ブロックとパターンで構成しています。文章・画像はすべて管理画面（サイトエディター／ブロックエディター）から編集できます。
Author: 拓法律事務所
Template: twentytwentyfive
Version: 1.0.0
Requires at least: 6.7
Tested up to: 7.1
Requires PHP: 7.4
Text Domain: hiraku
*/

/* -------------------------------------------------------------
   このファイルには「ブロックの設定だけでは表現できない部分」のみを
   最小限記述しています。色・文字サイズ・余白などの基本設定は
   theme.json 側にまとめてあります。
   ------------------------------------------------------------- */

/* ===== 余白の調整 =====
   セクション間・ブロック間の余白を全体的に詰めています。
   数値を変えれば、サイト全体の間隔が一括で変わります。
   ------------------------------------------------------------- */

:root {
	--wp--preset--spacing--30: 1.25rem;   /* 標準（もとは 1.5rem） */
	--wp--preset--spacing--40: 1.75rem;   /* やや大（もとは 2.25rem） */
	--wp--preset--spacing--50: 2.5rem;    /* 大（もとは 3.5rem） */
	--wp--preset--spacing--60: clamp(2.25rem, 4vw, 3.25rem);  /* 特大 */
	--wp--preset--spacing--70: clamp(2.75rem, 5vw, 4rem);     /* セクション間 */
}

/* 本文の行間もわずかに詰める */
:root body {
	line-height: 1.8;
}

/* ブロック間の既定の間隔 */
:root body {
	--wp--style--block-gap: 1.25rem;
}

/* ===== 共通 ===== */

body {
	text-underline-offset: 0.25em;
}

/* 明朝見出しの字間 */
.hiraku-mincho,
h1, h2, h3 {
	letter-spacing: 0.04em;
}

/* ===== ヘッダー ===== */

/* 上部ユーティリティバー：スマートフォンではキャッチ文を省略 */
@media (max-width: 781px) {
	.hiraku-utilitybar__lead {
		display: none;
	}
}

/* ロゴ画像の最大高さ */
.hiraku-header .wp-block-site-logo img {
	height: auto;
	max-height: 68px;
	width: auto;
}

@media (max-width: 781px) {
	.hiraku-header .wp-block-site-logo img {
		max-height: 44px;
	}
}

/* グローバルナビ：日本語ラベルの下に英語表記を小さく表示 */
.hiraku-nav .wp-block-navigation-item__label {
	display: block;
	line-height: 1.4;
	text-align: center;
}

.hiraku-nav .nav-en {
	display: block;
	font-size: 0.6875rem;
	letter-spacing: 0.12em;
	color: var(--wp--preset--color--gold);
	margin-top: 0.15em;
	font-weight: 400;
}

.hiraku-nav .wp-block-navigation-item {
	position: relative;
}

/* グローバルナビ：項目の幅をそろえ、等間隔に並べる */
@media (min-width: 782px) {
	.hiraku-nav .wp-block-navigation__container {
		width: 100%;
	}

	.hiraku-nav .wp-block-navigation__container > .wp-block-navigation-item {
		flex: 1 1 0;
		justify-content: center;
		min-width: 0;
	}
}

/* PC では項目間に細い区切り線 */
@media (min-width: 782px) {
	.hiraku-nav .wp-block-navigation__container > .wp-block-navigation-item + .wp-block-navigation-item::before {
		content: "";
		position: absolute;
		left: calc(var(--wp--style--block-gap, 1.5rem) * -0.5);
		top: 50%;
		transform: translateY(-50%);
		width: 1px;
		height: 2.2em;
		background: var(--wp--preset--color--gray-light);
	}
}

/* ドロワー（モバイルメニュー）内では英語表記を右に寄せない */
.hiraku-nav .wp-block-navigation__responsive-container.is-menu-open .nav-en {
	color: var(--wp--preset--color--gold-light);
}

/* ===== ヒーロー ===== */

.hiraku-hero {
	position: relative;
	overflow: hidden;
}

/* ヒーロー右下の斜めの深紺の面（ゴールドの細い線を挟む）
   ロゴを載せる場合は、白抜き版のロゴをご用意ください。 */
.hiraku-hero::after {
	content: "";
	position: absolute;
	right: 0;
	bottom: 0;
	width: 46%;
	height: 56%;
	pointer-events: none;
	z-index: 0;
	background:
		url("/wp-content/uploads/2026/09/logo-white-stacked.png") no-repeat right 14% bottom 13% / 34% auto,
		linear-gradient(
			to top left,
			var(--wp--preset--color--navy) 0 calc(50% - 1.5px),
			var(--wp--preset--color--gold) calc(50% - 1.5px) calc(50% + 1.5px),
			transparent calc(50% + 1.5px) 100%
		);
}

.hiraku-hero > .wp-block-cover__inner-container {
	position: relative;
	z-index: 1;
}

/* スマートフォンでは装飾を控えめに */
@media (max-width: 781px) {
	.hiraku-hero::after {
		width: 62%;
		height: 34%;
	}
}

/* 白パネル：左寄せで配置する */
.wp-block-cover.hiraku-hero > .wp-block-cover__inner-container {
	max-width: 1240px;
	margin-inline: auto;
}

.wp-block-group.hiraku-hero__panel {
	background: rgba(255, 255, 255, 0.95);
	max-width: 500px;
	margin-left: 0 !important;
	margin-right: auto !important;
	padding: 2.25rem 2.25rem 2.5rem !important;
}

/* キャッチコピーの文字サイズと行間（白パネルを大きくしすぎない） */
.hiraku-hero__panel h1 {
	font-size: clamp(1.375rem, 2.6vw, 2.125rem) !important;
	line-height: 1.55;
}

/* パネル内の要素間 */
.hiraku-hero__panel > * + * {
	margin-top: 1.1rem;
}

@media (max-width: 781px) {
	.wp-block-group.hiraku-hero__panel {
		background: rgba(255, 255, 255, 0.94);
		max-width: 100%;
	}
}

/* 背景写真の表示位置：画面幅に応じて主要な建物が切れないよう調整 */
.hiraku-hero .wp-block-cover__image-background {
	object-position: 50% 50% !important;
}

/* ノートPC幅：横方向が切り取られるため、都庁とコクーンタワーが
   白パネルの右側に収まる位置へ寄せる */
@media (max-width: 1439px) {
	.hiraku-hero .wp-block-cover__image-background {
		object-position: 42% 50% !important;
	}
}

/* スマートフォン：高さを押さえ、都庁・コクーンタワーが見える位置へ */
@media (max-width: 781px) {
	/* 写真の帯を上に見せ、白パネルを下に下げる */
	.wp-block-cover.hiraku-hero {
		min-height: 460px !important;
		padding-top: 150px !important;
	}

	.hiraku-hero .wp-block-cover__image-background {
		object-position: 78% 45% !important;
	}
}

/* ===== 取扱業務カード ===== */

.hiraku-card {
	transition: box-shadow 0.25s ease, transform 0.25s ease;
	height: 100%;
}

.hiraku-card:hover {
	box-shadow: 0 10px 30px rgba(15, 39, 71, 0.10);
	transform: translateY(-2px);
}

/* カード内の「詳しく見る」を下端でそろえる */
.wp-block-group.hiraku-card {
	display: flex;
	flex-direction: column;
}

.wp-block-group.hiraku-card > p:last-of-type {
	margin-top: auto;
	padding-top: 0.5rem;
}

/* カード見出しの高さをそろえる（1行でも2行でも本文の開始位置を統一） */
.hiraku-card > .wp-block-heading {
	min-height: 3em;              /* 2行分（行間1.5×2行） */
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 0;
}

/* 説明文の開始位置をそろえる */
.hiraku-card > .wp-block-heading + p {
	margin-top: 0.75rem;
}

.hiraku-card__icon {
	margin-bottom: 0;
	flex-shrink: 0;
}

.hiraku-card__icon img {
	width: 56px;
	height: 56px;
	object-fit: contain;
}

/* 箇条書きのマーカーを消すスタイル（フッターのリンク一覧などで使用） */
.is-style-none {
	list-style: none;
	padding-left: 0;
}

/* ===== セクション見出し（和文＋欧文） ===== */

.hiraku-sectiontitle {
	text-align: center;
}

.hiraku-sectiontitle__en {
	color: var(--wp--preset--color--gold);
	letter-spacing: 0.22em;
	text-transform: uppercase;
}

/* セクション見出しの下に深紺の細い罫を引く（区画の切れ目を示す） */
.hiraku-sectiontitle {
	position: relative;
	padding-bottom: 1.5rem;
}

.hiraku-sectiontitle::after {
	content: "";
	position: absolute;
	left: 50%;
	bottom: 0;
	transform: translateX(-50%);
	width: 56px;
	height: 2px;
	background: var(--wp--preset--color--navy);
}

/* 深紺の面に置かれた見出しでは、罫をゴールドにする */
.has-navy-background-color .hiraku-sectiontitle::after,
.hiraku-pagehead .hiraku-sectiontitle::after {
	background: var(--wp--preset--color--gold);
}

/* 見出し下の金色の短い罫 */
.hiraku-sectiontitle__rule {
	width: 40px;
	border: 0;
	border-top: 2px solid var(--wp--preset--color--gold);
	margin-inline: auto;
}

/* ===== お知らせ・コラム一覧 ===== */

.hiraku-list .wp-block-post-title a:hover {
	color: var(--wp--preset--color--gold);
}

.hiraku-badge {
	display: inline-block;
	padding: 0.15em 0.9em;
	font-size: 0.75rem;
	line-height: 1.8;
	background: var(--wp--preset--color--navy);
	color: #fff;
}

/* 投稿一覧の日付とカテゴリーを横並びに */
.hiraku-meta {
	color: var(--wp--preset--color--gray);
	font-size: 0.8125rem;
	letter-spacing: 0.04em;
}

.hiraku-meta .wp-block-post-terms a {
	color: var(--wp--preset--color--navy);
	text-decoration: none;
}

/* ===== フッター ===== */

.hiraku-footer a {
	text-decoration: none;
}

.hiraku-footer a:hover {
	text-decoration: underline;
}

/* ===== スマートフォン向けの微調整 ===== */

@media (max-width: 781px) {
	.wp-block-group.hiraku-hero__panel {
		padding: 2rem 1.5rem !important;
	}

	.hiraku-hero__panel h1 {
		line-height: 1.5;
	}

	.wp-block-button__link {
		padding-left: 1.5rem;
		padding-right: 1.5rem;
	}

	.hiraku-footer .wp-block-columns {
		gap: 2rem;
	}
}


/* ===== お問い合わせフォーム（Contact Form 7） ===== */

.wpcf7 form > p {
	margin-bottom: 1.75rem;
}

.wpcf7 label {
	display: block;
	font-weight: 600;
	letter-spacing: 0.04em;
	color: var(--wp--preset--color--navy);
}

.wpcf7 .req {
	display: inline-block;
	margin-left: 0.5em;
	padding: 0.1em 0.7em;
	font-size: 0.6875rem;
	font-weight: 600;
	letter-spacing: 0.08em;
	background: var(--wp--preset--color--gold);
	color: #fff;
	vertical-align: 0.15em;
}

.wpcf7 .hint {
	display: block;
	margin: 0.35rem 0 0.5rem;
	font-size: 0.8125rem;
	font-weight: 400;
	line-height: 1.8;
	color: #5a6270;
}

.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 input[type="url"],
.wpcf7 select,
.wpcf7 textarea {
	display: block;
	width: 100%;
	max-width: 100%;
	margin-top: 0.5rem;
	padding: 0.85rem 1rem;
	font-family: inherit;
	font-size: 1rem;
	font-weight: 400;
	line-height: 1.7;
	color: var(--wp--preset--color--ink);
	background: #fff;
	border: 1px solid var(--wp--preset--color--gray-light);
	border-radius: 0;
	box-sizing: border-box;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.wpcf7 textarea {
	resize: vertical;
}

.wpcf7 input:focus,
.wpcf7 select:focus,
.wpcf7 textarea:focus {
	outline: none;
	border-color: var(--wp--preset--color--gold);
	box-shadow: 0 0 0 3px rgba(184, 152, 94, 0.16);
}

/* 同意チェックボックス */
.wpcf7 .wpcf7-acceptance .wpcf7-list-item {
	margin: 0;
}

.wpcf7 .wpcf7-acceptance label {
	display: flex;
	align-items: flex-start;
	gap: 0.7rem;
	font-weight: 400;
	color: var(--wp--preset--color--ink);
	line-height: 1.8;
	cursor: pointer;
}

.wpcf7 .wpcf7-acceptance input[type="checkbox"] {
	flex-shrink: 0;
	width: 1.15rem;
	height: 1.15rem;
	margin-top: 0.25rem;
	accent-color: var(--wp--preset--color--navy);
}

/* 送信ボタン */
.wpcf7 input[type="submit"] {
	display: inline-block;
	width: auto;
	min-width: 260px;
	margin-top: 0.5rem;
	padding: 1.05rem 2.5rem;
	font-family: inherit;
	font-size: 0.875rem;
	font-weight: 600;
	letter-spacing: 0.08em;
	color: #fff;
	background: var(--wp--preset--color--gold);
	border: 0;
	border-radius: 0;
	cursor: pointer;
	transition: background 0.2s ease;
}

.wpcf7 input[type="submit"]:hover,
.wpcf7 input[type="submit"]:focus {
	background: var(--wp--preset--color--navy);
}

/* 検証メッセージ */
.wpcf7 .wpcf7-not-valid-tip {
	margin-top: 0.4rem;
	font-size: 0.8125rem;
	color: #b3261e;
}

.wpcf7 .wpcf7-response-output {
	margin: 1.5rem 0 0;
	padding: 1rem 1.25rem;
	font-size: 0.9375rem;
	line-height: 1.9;
	border-width: 1px;
}

@media (max-width: 781px) {
	.wpcf7 input[type="submit"] {
		width: 100%;
		min-width: 0;
	}
}

/* ===== 印刷 ===== */

@media print {
	.hiraku-utilitybar,
	.hiraku-nav,
	.hiraku-footer {
		display: none !important;
	}
}


/* =========================================================
   スマートフォン表示（幅781px以下）：深紺ベース
   - ヘッダーを深紺の1行に（ロゴ白抜き／メニューを右上に）
   - ヒーローを深紺のグラデーション＋白文字に
   - 取扱業務（トップページ）を深紺のリストに
   - CTA「法律相談のお申し込み」を画面下部の固定バーに
   PC表示（782px以上）には一切影響しません。
   ========================================================= */

@media (max-width: 781px) {

	/* ---------- ヘッダー：深紺の1行 ---------- */

	.hiraku-header,
	.hiraku-header.has-white-background-color {
		background-color: var(--wp--preset--color--navy) !important;
	}

	.hiraku-navbar,
	.hiraku-navbar.has-white-background-color {
		background-color: var(--wp--preset--color--navy) !important;
		border-top-color: rgba(255, 255, 255, 0.18) !important;
		border-bottom: 0 !important;
		padding-top: 0 !important;
		padding-bottom: 0 !important;
		position: relative;
	}

	.hiraku-navbar .wp-block-navigation {
		padding-top: 0 !important;
		padding-bottom: 0 !important;
	}

	.hiraku-header .wp-block-site-logo .custom-logo-link {
		display: block;
		background: url("/wp-content/uploads/2026/09/logo-white.png") left center / contain no-repeat;
	}

	.hiraku-header .wp-block-site-logo img {
		visibility: hidden;
	}

	.hiraku-nav .wp-block-navigation__responsive-container-open {
		position: absolute;
		right: 2px;
		bottom: 14px;
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		gap: 3px;
		width: 58px;
		height: 52px;
		padding: 0;
		color: #fff;
		background: transparent;
		border: 1px solid rgba(255, 255, 255, 0.45);
		border-radius: 4px;
	}

	.hiraku-nav .wp-block-navigation__responsive-container-open svg {
		width: 26px;
		height: 26px;
		fill: currentColor;
	}

	.hiraku-nav .wp-block-navigation__responsive-container-open::after {
		content: "メニュー";
		font-size: 0.5625rem;
		line-height: 1;
		letter-spacing: 0.04em;
	}

	/* ---------- ヒーロー：深紺のグラデーション ---------- */

	.wp-block-cover.hiraku-hero {
		min-height: 440px !important;
		padding-top: 2.5rem !important;
		padding-bottom: 2.5rem !important;
	}

	.hiraku-hero::before {
		content: "";
		position: absolute;
		inset: 0;
		z-index: 1;
		background: linear-gradient(180deg, rgba(15, 39, 71, 0.80) 0%, rgba(15, 39, 71, 0.96) 100%);
	}

	.hiraku-hero > .wp-block-cover__inner-container {
		position: relative;
		z-index: 2;
	}

	.hiraku-hero::after {
		display: none;
	}

	.wp-block-group.hiraku-hero__panel {
		background: transparent !important;
		max-width: 100%;
		padding: 0 !important;
	}

	.hiraku-hero__panel h1 {
		color: #fff !important;
		font-size: 1.375rem !important;
		line-height: 1.65;
	}

	.hiraku-hero__panel p {
		color: rgba(255, 255, 255, 0.86) !important;
	}

	.hiraku-hero__panel h1::after {
		content: "";
		display: block;
		width: 44px;
		height: 2px;
		background: var(--wp--preset--color--gold);
		margin-top: 1rem;
	}

	.hiraku-hero__panel .wp-block-button__link {
		background-color: transparent !important;
		border: 1px solid var(--wp--preset--color--gold-light);
		color: #fff !important;
	}

	/* ---------- 取扱業務（トップページ）：深紺のリスト ---------- */

	body.home .wp-block-group:has(> .wp-block-group > .hiraku-card) {
		background-color: var(--wp--preset--color--navy);
		padding-left: 0 !important;
		padding-right: 0 !important;
	}

	body.home .wp-block-group:has(> .wp-block-group > .hiraku-card) .hiraku-sectiontitle .wp-block-heading {
		color: #fff;
	}

	body.home .wp-block-group:has(> .wp-block-group > .hiraku-card) .hiraku-sectiontitle__en {
		color: var(--wp--preset--color--gold-light);
	}

	body.home .wp-block-group:has(> .wp-block-group > .hiraku-card) .hiraku-sectiontitle::after {
		background: var(--wp--preset--color--gold);
	}

	body.home .wp-block-group:has(> .hiraku-card) {
		gap: 0 !important;
		grid-template-columns: 1fr !important;
	}

	body.home .hiraku-card {
		position: relative;
		display: grid !important;
		grid-template-columns: 30px 1fr;
		grid-template-areas: "ic ttl" "ic txt";
		column-gap: 0.75rem;
		align-items: center;
		background: transparent !important;
		border: 0 !important;
		border-top: 1px solid rgba(255, 255, 255, 0.14) !important;
		border-radius: 0 !important;
		padding: 0.95rem 2.2rem 0.95rem 1.1rem !important;
	}

	body.home .hiraku-card:last-child {
		border-bottom: 1px solid rgba(255, 255, 255, 0.14) !important;
	}

	body.home .hiraku-card:hover {
		box-shadow: none;
		transform: none;
	}

	body.home .hiraku-card > .hiraku-card__icon {
		grid-area: ic;
		margin: 0;
	}

	body.home .hiraku-card > .hiraku-card__icon img {
		width: 30px;
		height: 30px;
	}

	body.home .hiraku-card > .wp-block-heading {
		grid-area: ttl;
		display: block !important;
		min-height: 0 !important;
		margin: 0 !important;
		text-align: left !important;
		color: #fff;
		font-size: 0.95rem !important;
		letter-spacing: 0.04em;
	}

	body.home .hiraku-card > p:not(:last-of-type) {
		grid-area: txt;
		margin: 0.35rem 0 0 !important;
		padding: 0 !important;
		text-align: left !important;
		color: rgba(255, 255, 255, 0.72);
		font-size: 0.75rem !important;
		line-height: 1.75 !important;
	}

	body.home .hiraku-card > p:last-of-type {
		margin: 0 !important;
		padding: 0 !important;
	}

	body.home .hiraku-card > p:last-of-type a {
		position: absolute;
		inset: 0;
		display: flex;
		align-items: center;
		justify-content: flex-end;
		padding-right: 1.1rem;
		font-size: 0;
		color: transparent;
		text-decoration: none;
	}

	body.home .hiraku-card > p:last-of-type a::after {
		content: "›";
		font-size: 1.5rem;
		line-height: 1;
		color: var(--wp--preset--color--gold-light);
	}

	/* ---------- CTA を画面下部に固定 ---------- */

	.hiraku-header .wp-block-buttons {
		position: fixed;
		left: 0;
		right: 0;
		bottom: 0;
		z-index: 90;
		margin: 0;
		padding: 0.6rem 1rem calc(0.6rem + env(safe-area-inset-bottom, 0px));
		background: var(--wp--preset--color--navy);
		border-top: 1px solid rgba(255, 255, 255, 0.18);
	}

	.hiraku-header .wp-block-buttons .wp-block-button {
		width: 100%;
	}

	.hiraku-header .wp-block-buttons .wp-block-button__link {
		display: block;
		width: 100%;
		text-align: center;
		padding-top: 0.95rem;
		padding-bottom: 0.95rem;
		font-size: 0.95rem;
	}

	/* 固定バーの下の余白は、深紺のフッターを伸ばして確保する
	   （body に余白を付けると白い帯が出るため） */
	.hiraku-footer {
		padding-bottom: 6rem !important;
	}

	body.page-id-15 .hiraku-header .wp-block-buttons {
		display: none;
	}


	/* ---------- 弁護士紹介 ／ お知らせ・コラム：深紺 ---------- */

	body.home .entry-content > .wp-block-group:has(#about),
	body.home .entry-content > .wp-block-group:last-child {
		background-color: var(--wp--preset--color--navy) !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) .wp-block-group.has-white-background-color,
	body.home .entry-content > .wp-block-group:last-child .wp-block-column.has-white-background-color {
		background-color: transparent !important;
		border-color: rgba(255, 255, 255, 0.18) !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) .wp-block-heading,
	body.home .entry-content > .wp-block-group:last-child .wp-block-heading {
		color: #fff !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) p,
	body.home .entry-content > .wp-block-group:has(#about) li,
	body.home .entry-content > .wp-block-group:last-child p,
	body.home .entry-content > .wp-block-group:last-child li {
		color: rgba(255, 255, 255, 0.82);
	}

	body.home .entry-content > .wp-block-group:has(#about) a,
	body.home .entry-content > .wp-block-group:last-child a {
		color: #fff;
	}

	body.home .entry-content > .wp-block-group:has(#about) .hiraku-sectiontitle__en,
	body.home .entry-content > .wp-block-group:last-child .hiraku-sectiontitle__en {
		color: var(--wp--preset--color--gold-light) !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) .hiraku-sectiontitle::after {
		background: var(--wp--preset--color--gold);
	}

	body.home .entry-content > .wp-block-group:last-child .hiraku-meta,
	body.home .entry-content > .wp-block-group:last-child .hiraku-meta a,
	body.home .entry-content > .wp-block-group:last-child .hiraku-meta .wp-block-post-terms a {
		color: rgba(255, 255, 255, 0.70) !important;
	}

	body.home .entry-content > .wp-block-group:last-child .hiraku-badge {
		background: var(--wp--preset--color--gold);
		color: var(--wp--preset--color--navy);
	}

	body.home .entry-content > .wp-block-group:has(#about) .wp-block-button.is-style-outline .wp-block-button__link,
	body.home .entry-content > .wp-block-group:last-child .wp-block-button.is-style-outline .wp-block-button__link {
		color: #fff !important;
		background-color: transparent !important;
		border-color: var(--wp--preset--color--gold-light) !important;
	}

	/* 区切りを見せるための細い金の罫 */
	body.home .entry-content > .wp-block-group:has(#about),
	body.home .entry-content > .wp-block-group:last-child {
		border-top: 1px solid rgba(184, 152, 94, 0.35);
	}


	/* 深紺セクション同士のすき間（白帯）をなくす */
	body.home .entry-content > .wp-block-group:has(> .wp-block-group > .hiraku-card),
	body.home .entry-content > .wp-block-group:has(#about),
	body.home .entry-content > .wp-block-group:last-child {
		margin-block-start: 0 !important;
	}

	body.page-id-15 .hiraku-footer {
		padding-bottom: var(--wp--preset--spacing--30) !important;
	}
}


/* =========================================================
   PC表示（幅782px以上）：モノトーンの反転（案E）
   取扱業務  ＝ 白地に深紺のカード
   弁護士紹介 ＝ 深紺地に白のカード
   お知らせ・コラム ＝ 従来どおり白
   ヘッダー・ヒーロー・フッターは従来のまま
   ========================================================= */

@media (min-width: 782px) {

	/* ---- 取扱業務：白地・深紺のカード ---- */

	body.home .entry-content > .wp-block-group:has(> .wp-block-group > .hiraku-card) {
		margin-block-start: 0 !important;
	}

	body.home .hiraku-card {
		background-color: var(--wp--preset--color--navy) !important;
		border-color: var(--wp--preset--color--navy) !important;
	}

	body.home .hiraku-card .wp-block-heading {
		color: #fff !important;
	}

	body.home .hiraku-card p {
		color: rgba(255, 255, 255, 0.80);
	}

	body.home .hiraku-card p:last-of-type a {
		color: var(--wp--preset--color--gold-light);
	}

	body.home .hiraku-card .hiraku-card__icon img {
		filter: brightness(1.18);
	}

	body.home .hiraku-card:hover {
		box-shadow: 0 10px 30px rgba(15, 39, 71, 0.28);
	}

	/* ---- 弁護士紹介：深紺地・白のカード ---- */

	body.home .entry-content > .wp-block-group:has(#about) {
		background-color: var(--wp--preset--color--navy) !important;
		margin-block-start: 0 !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) .hiraku-sectiontitle .wp-block-heading {
		color: #fff !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) .hiraku-sectiontitle__en {
		color: var(--wp--preset--color--gold-light) !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) .hiraku-sectiontitle::after {
		background: var(--wp--preset--color--gold);
	}

	body.home .entry-content > .wp-block-group:has(#about) .wp-block-group.has-white-background-color {
		background-color: #fff !important;
		border-color: var(--wp--preset--color--gray-light) !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) .wp-block-group.has-white-background-color .wp-block-heading {
		color: var(--wp--preset--color--navy) !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) .wp-block-group.has-white-background-color p,
	body.home .entry-content > .wp-block-group:has(#about) .wp-block-group.has-white-background-color li {
		color: var(--wp--preset--color--ink, #2b3038) !important;
	}

	body.home .entry-content > .wp-block-group:has(#about) .wp-block-group.has-white-background-color a {
		color: var(--wp--preset--color--navy) !important;
	}
}

/* トップページ：最終セクション（深紺）とフッターの間の白い帯をなくす */
body.home footer.wp-block-template-part {
	margin-block-start: 0 !important;
}


/* =========================================================
   下層ページを深紺ベースに
   対象：取扱業務一覧／各取扱業務6ページ／弁護士紹介／アクセス／お問い合わせ
   除外：弁護士費用・プライバシーポリシー（長文・表が多く可読性を優先）
   ========================================================= */

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main {
	background-color: var(--wp--preset--color--navy);
	margin-block-start: 0 !important;
}

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main p,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main li,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main dt,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main dd,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main td,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main th,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main figcaption {
	color: rgba(255, 255, 255, 0.86);
}

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main h1,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main h2,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main h3,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main h4,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main strong {
	color: #fff;
}

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main a {
	color: var(--wp--preset--color--gold-light);
}

/* 白・オフホワイトの面 */
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .has-off-white-background-color {
	background-color: rgba(255, 255, 255, 0.06) !important;
}

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .has-white-background-color {
	background-color: transparent !important;
	border-color: rgba(255, 255, 255, 0.22) !important;
}

/* 見出し帯の中の色指定を打ち消す */
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .hiraku-sectiontitle .wp-block-heading,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .has-navy-color {
	color: #fff !important;
}

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .hiraku-sectiontitle__en {
	color: var(--wp--preset--color--gold-light) !important;
}

/* 取扱業務カード */
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .hiraku-card {
	background-color: transparent !important;
	border-color: rgba(255, 255, 255, 0.22) !important;
}

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .hiraku-card .wp-block-heading {
	color: #fff !important;
}

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .hiraku-card p {
	color: rgba(255, 255, 255, 0.78);
}

/* 表 */
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main table th,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main table td {
	border-color: rgba(255, 255, 255, 0.20) !important;
}

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .is-style-stripes tbody tr:nth-child(odd) {
	background-color: rgba(255, 255, 255, 0.06);
}

/* 区切り線 */
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .wp-block-separator {
	border-color: rgba(255, 255, 255, 0.20);
	color: rgba(255, 255, 255, 0.20);
}

/* 枠線ボタン */
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .wp-block-button.is-style-outline .wp-block-button__link {
	color: #fff !important;
	background-color: transparent !important;
	border-color: var(--wp--preset--color--gold-light) !important;
}

/* もともと深紺のCTA欄は、金の細い罫で面を分ける */
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) main .has-navy-background-color {
	border-top: 1px solid rgba(184, 152, 94, 0.35);
}

/* お問い合わせフォームの入力欄は白地・濃色文字のまま */
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) .wpcf7 input,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) .wpcf7 select,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) .wpcf7 textarea {
	background-color: #fff;
	color: #2b3038;
}

body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) .wpcf7 label,
body:is(.page-id-12,.page-id-14,.page-id-15,.page-id-16,.page-id-17,.page-id-18,.page-id-19,.page-id-20,.page-id-21,.page-id-22) .wpcf7 .wpcf7-list-item-label {
	color: rgba(255, 255, 255, 0.90);
}


/* =========================================================
   PC表示（幅782px以上）：取扱業務ページ・弁護士紹介ページも
   トップページと同じモノトーンの反転にする
   取扱業務  ＝ 白地に深紺のカード
   弁護士紹介 ＝ 深紺地に白のカード
   （スマホ表示は全面深紺のまま）
   ========================================================= */

@media (min-width: 782px) {

	/* ---- 取扱業務ページ：白地・深紺のカード ---- */

	body.page-id-16 main {
		background-color: #fff !important;
	}

	body.page-id-16 main .has-off-white-background-color {
		background-color: var(--wp--preset--color--off-white) !important;
	}

	body.page-id-16 main,
	body.page-id-16 main p,
	body.page-id-16 main li,
	body.page-id-16 main td,
	body.page-id-16 main th {
		color: #2b3038 !important;
	}

	body.page-id-16 main h1,
	body.page-id-16 main h2,
	body.page-id-16 main h3,
	body.page-id-16 main h4,
	body.page-id-16 main strong {
		color: var(--wp--preset--color--navy) !important;
	}

	body.page-id-16 main a {
		color: var(--wp--preset--color--navy) !important;
	}

	body.page-id-16 main .hiraku-card {
		background-color: var(--wp--preset--color--navy) !important;
		border-color: var(--wp--preset--color--navy) !important;
	}

	body.page-id-16 main .hiraku-card .wp-block-heading {
		color: #fff !important;
	}

	body.page-id-16 main .hiraku-card p {
		color: rgba(255, 255, 255, 0.80) !important;
	}

	body.page-id-16 main .hiraku-card p:last-of-type a {
		color: var(--wp--preset--color--gold-light) !important;
	}

	body.page-id-16 main .hiraku-card .hiraku-card__icon img {
		filter: brightness(1.18);
	}

	/* 下部のCTA欄は深紺のまま白文字 */
	body.page-id-16 main .has-navy-background-color,
	body.page-id-16 main .has-navy-background-color p,
	body.page-id-16 main .has-navy-background-color li,
	body.page-id-16 main .has-navy-background-color .wp-block-heading,
	body.page-id-16 main .has-navy-background-color a {
		color: #fff !important;
	}

	/* ---- 弁護士紹介ページ：深紺地・白のカード ---- */

	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) {
		background-color: #fff !important;
		border: 1px solid var(--wp--preset--color--gray-light);
		padding: var(--wp--preset--spacing--50) var(--wp--preset--spacing--40) !important;
	}

	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color),
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) p,
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) li,
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) dt,
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) dd,
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) td,
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) th {
		color: #2b3038 !important;
	}

	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) h2,
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) h3,
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) h4,
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) strong {
		color: var(--wp--preset--color--navy) !important;
	}

	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) a {
		color: var(--wp--preset--color--navy) !important;
	}

	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) .hiraku-sectiontitle__en {
		color: var(--wp--preset--color--gold) !important;
	}

	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) table th,
	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) table td {
		border-color: var(--wp--preset--color--gray-light) !important;
	}

	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) .is-style-stripes tbody tr:nth-child(odd) {
		background-color: var(--wp--preset--color--off-white);
	}

	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) .wp-block-separator {
		border-color: var(--wp--preset--color--gray-light);
		color: var(--wp--preset--color--gray-light);
	}

	body.page-id-12 .entry-content > .wp-block-group:not(.hiraku-pagehead):not(.has-navy-background-color) .wp-block-button.is-style-outline .wp-block-button__link {
		color: var(--wp--preset--color--navy) !important;
		border-color: var(--wp--preset--color--gold) !important;
	}
}


/* =========================================================
   ルビ（振り仮名）：ブランドカラーのゴールドで表示する
   例）<ruby>拓く<rp>（</rp><rt>ひらく</rt><rp>）</rp></ruby>
   ========================================================= */

ruby {
	ruby-position: over;
}

ruby rt {
	color: var(--wp--preset--color--gold);
	font-size: max(10px, 0.40em);
	font-weight: 400;
	letter-spacing: 0.18em;
	line-height: 1.2;
	text-indent: 0;
}

/* 深紺の面の上ではやや明るい金に（スマホのヒーローは深紺のため対象） */
.has-navy-background-color ruby rt {
	color: var(--wp--preset--color--gold-light);
}

@media (max-width: 781px) {
	.hiraku-hero ruby rt {
		color: var(--wp--preset--color--gold-light);
	}
}

/* ルビ非対応ブラウザ用の括弧は表示しない（対応ブラウザでは自動的に隠れます） */
ruby rp {
	display: none;
}
