/*
Theme Name: 外国人材 生活支援ガイド
Author: 不動産のイブキ（伊吹株式会社）
Author URI: https://okamotojusetsu.com/
Description: 登録支援機関・派遣会社の支援担当者向け実務ガイドのオリジナルテーマ。受入れの段階（カテゴリー）ごとに記事をたどれる構成で、住まいの確保の段階から外国籍スタッフの住まい手配へつなぎます。
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: seikatsu-shien
*/

:root {
	--ink: #1f2a37;
	--ink-sub: #55606d;
	--teal: #0f5a5c;
	--teal-dark: #0a4244;
	--mint: #eef5f3;
	--line: #cbd8d5;
	--white: #ffffff;
	--sun: #e8a317;
	--sun-pale: #fdf3dc;
	--font: "BIZ UDPGothic", "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic UI", "Meiryo", sans-serif;
	--wrap: 1120px;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--white); font-size: 16px; line-height: 1.85; letter-spacing: .02em; }
img { max-width: 100%; height: auto; }
a { color: var(--teal); text-underline-offset: .2em; }
a:hover { color: var(--teal-dark); }
:focus-visible { outline: 3px solid var(--sun); outline-offset: 2px; }
[id] { scroll-margin-top: 16px; }
.wrap { width: min(100% - 40px, var(--wrap)); margin-inline: auto; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 100; background: var(--ink); color: #fff; padding: 8px 14px; }
.skip-link:focus { left: 12px; top: 12px; color: #fff; }
.empty { color: var(--ink-sub); }

/* ---------- header ---------- */
.site-header { background: var(--white); border-bottom: 1px solid var(--line); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 0 24px; min-height: 68px; }
.brand { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; padding: 10px 0; line-height: 1.35; color: var(--ink); text-decoration: none; }
.brand:hover { color: var(--ink); }
.brand__name { font-size: 1.2rem; font-weight: 700; letter-spacing: .04em; }
.brand__tag { font-size: .75rem; color: var(--ink-sub); }
.site-nav__list { display: flex; flex-wrap: wrap; gap: 0 22px; margin: 0; padding: 0; list-style: none; }
.site-nav__list a { display: block; padding: 8px 0; border-bottom: 2px solid transparent; color: var(--ink); font-size: .92rem; font-weight: 700; text-decoration: none; }
.site-nav__list a:hover,
.site-nav__list .current-menu-item > a { border-bottom-color: var(--teal); color: var(--teal); }
.nav-toggle { display: none; }

@media (max-width: 860px) {
	.js .nav-toggle { display: inline-flex; align-items: center; padding: 8px 14px; border: 1px solid var(--line); border-radius: 4px; background: var(--white); color: var(--ink); font: inherit; font-size: .88rem; font-weight: 700; cursor: pointer; }
	.site-nav { width: 100%; padding-bottom: 12px; }
	.js .site-nav { display: none; }
	.js .site-nav.is-open { display: block; }
	.site-nav__list { flex-direction: column; }
	.site-nav__list a { padding: 12px 0; border-bottom: 1px solid var(--line); }
}

/* ---------- front: hero + stages ---------- */
.front-top { padding: 56px 0 64px; background: var(--mint); border-bottom: 1px solid var(--line); }
.hero__title { margin: 0 0 16px; font-size: clamp(1.7rem, 4.2vw, 2.75rem); line-height: 1.4; letter-spacing: .03em; }
.hero__lead { max-width: 36em; margin: 0 0 48px; color: var(--ink-sub); font-size: 1.02rem; }
.stages-title { margin: 0 0 20px; font-size: 1.1rem; }

.stages { position: relative; display: grid; grid-template-columns: repeat(6, 1fr); margin: 0; padding: 0; list-style: none; }
.stages::before { content: ""; position: absolute; top: 20px; left: 21px; right: calc(100% / 6 - 21px); height: 3px; background: var(--teal); opacity: .35; }
.stage { position: relative; }
.stage__link { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; height: 100%; padding: 0 16px 0 0; color: var(--ink); text-decoration: none; }
.stage__num { position: relative; z-index: 1; display: grid; place-items: center; width: 42px; height: 42px; margin-bottom: 8px; border: 3px solid var(--teal); border-radius: 50%; background: var(--white); color: var(--teal); font-size: 1.05rem; font-weight: 700; }
.stage__title { font-size: 1rem; font-weight: 700; line-height: 1.5; }
.stage__desc { color: var(--ink-sub); font-size: .85rem; line-height: 1.6; }
.stage__count { color: var(--teal); font-size: .78rem; font-weight: 700; }
.stage__link:hover { color: var(--ink); }
.stage__link:hover .stage__title { color: var(--teal); text-decoration: underline; }
.stage--key .stage__num { border-color: var(--sun); background: var(--sun); color: var(--ink); }
.stage__note { display: inline-block; margin-top: 4px; padding: 2px 8px; border: 1px solid var(--sun); border-radius: 3px; background: var(--white); color: #7a5200; font-size: .75rem; font-weight: 700; line-height: 1.6; }

@media (max-width: 860px) {
	.stages { grid-template-columns: 1fr; }
	.stages::before { display: none; }
	.stage:not(:last-child)::after { content: ""; position: absolute; top: 21px; bottom: -21px; left: 20px; width: 3px; background: var(--teal); opacity: .35; }
	.stage__link { display: grid; grid-template-columns: 42px 1fr; column-gap: 16px; align-items: start; padding: 0 0 22px; }
	.stage__num { grid-row: 1 / span 4; margin: 0; }
	.stage__link > :not(.stage__num) { grid-column: 2; justify-self: start; }
}

/* ---------- sections ---------- */
.section { padding: 56px 0; }
.section + .section { border-top: 1px solid var(--line); }
.section-title { margin: 0 0 20px; font-size: 1.35rem; line-height: 1.5; }

.post-list { margin: 0; padding: 0; border-top: 1px solid var(--line); list-style: none; }
.post-row { border-bottom: 1px solid var(--line); }
.post-row__link { display: grid; grid-template-columns: 220px 1fr; gap: 4px 24px; padding: 16px 4px; color: var(--ink); text-decoration: none; }
.post-row__link:hover { color: var(--ink); }
.post-row__link:hover .post-row__title { color: var(--teal); text-decoration: underline; }
.post-row__meta { display: flex; flex-direction: column; gap: 0; color: var(--ink-sub); font-size: .8rem; }
.post-row__cat { color: var(--teal); font-weight: 700; }
.post-row__title { font-weight: 700; line-height: 1.6; }
@media (max-width: 640px) {
	.post-row__link { grid-template-columns: 1fr; }
	.post-row__meta { flex-direction: row; flex-wrap: wrap; gap: 2px 12px; }
}

.cat-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 32px 48px; }
.cat-item__title { margin: 0 0 6px; font-size: 1.2rem; }
.cat-item__title a { color: var(--ink); text-decoration: none; border-bottom: 3px solid var(--teal); }
.cat-item__title a:hover { color: var(--teal); }
.cat-item__desc { margin: 12px 0 10px; color: var(--ink-sub); font-size: .92rem; }
.cat-item__list { margin: 0; padding-left: 1.2em; font-size: .95rem; }
.cat-item__list li { margin-bottom: 4px; }
@media (max-width: 760px) { .cat-pair { grid-template-columns: 1fr; } }

/* ---------- buttons & CTA ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; padding: 12px 18px; border-radius: 4px; font-size: .93rem; font-weight: 700; line-height: 1.4; text-align: center; text-decoration: none; }
.btn--sun { background: var(--sun); color: var(--ink); }
.btn--sun:hover { background: #f2b632; color: var(--ink); }
.btn--line { border: 2px solid rgba(255, 255, 255, .75); color: #fff; }
.btn--line:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.btn--teal { background: var(--teal); color: #fff; }
.btn--teal:hover { background: var(--teal-dark); color: #fff; }
.btn--outline { border: 2px solid var(--teal); background: var(--white); color: var(--teal); }

.cta-band { padding-bottom: 64px; }
.cta-sumai { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 20px 36px; margin: 48px 0; padding: 30px; border-radius: 6px; background: var(--teal-dark); color: #fff; }
.cta-sumai__title { margin: 0 0 8px; font-size: 1.25rem; font-weight: 700; line-height: 1.5; }
.cta-sumai__text { margin: 0; font-size: .93rem; opacity: .92; }
.cta-sumai__actions { display: flex; flex-direction: column; gap: 10px; min-width: 270px; }
.cta-sumai__tel { color: #fff; font-size: .85rem; text-align: center; }
.cta-sumai__tel:hover { color: #fff; }
.cta-sumai__tel strong { font-size: 1.1rem; letter-spacing: .05em; }
@media (max-width: 760px) {
	.cta-sumai { grid-template-columns: 1fr; padding: 24px 20px; }
	.cta-sumai__actions { min-width: 0; }
}

/* ---------- layout (single / archive) ---------- */
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 56px; padding: 32px 0 72px; }
@media (max-width: 960px) { .layout { grid-template-columns: 1fr; gap: 24px; } }
.page-body { max-width: 760px; padding: 32px 0 72px; }

.breadcrumb ol { display: flex; flex-wrap: wrap; margin: 0; padding: 14px 0 0; color: var(--ink-sub); font-size: .8rem; list-style: none; }
.breadcrumb li + li::before { content: "/"; margin: 0 8px; color: #9fb0ad; }
.breadcrumb a { color: var(--ink-sub); }

.archive-head { padding: 0 0 36px; background: var(--mint); border-bottom: 1px solid var(--line); }
.archive-head .breadcrumb { margin-bottom: 24px; }
.archive-head__stage { margin: 0 0 4px; color: var(--teal); font-size: .88rem; font-weight: 700; }
.archive-head h1 { margin: 0 0 8px; font-size: clamp(1.5rem, 3vw, 2rem); line-height: 1.4; }
.archive-head__desc { max-width: 40em; color: var(--ink-sub); }
.archive-head__desc p { margin: 0; }
.stage-nav { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-top: 32px; font-size: .92rem; font-weight: 700; }

/* ---------- entry ---------- */
.entry { max-width: 740px; }
.entry-cat { display: inline-block; margin-top: 8px; padding: 2px 10px; border: 1px solid var(--teal); border-radius: 3px; color: var(--teal); font-size: .8rem; font-weight: 700; text-decoration: none; }
.entry-title { margin: 12px 0; font-size: clamp(1.5rem, 3.4vw, 2rem); line-height: 1.5; }
.entry-dates { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 0 0 24px; color: var(--ink-sub); font-size: .82rem; }
.entry-thumb { margin: 0 0 32px; }
.entry-thumb img { display: block; border-radius: 6px; }

.entry-content { font-size: 1.0625rem; }
.entry-content > * { margin-top: 0; margin-bottom: 1.4em; }
.entry-content h2 { margin: 2.6em 0 1em; padding-bottom: 10px; border-bottom: 3px solid var(--teal); font-size: 1.4rem; line-height: 1.5; }
.entry-content h3 { margin: 2em 0 .8em; padding-left: 12px; border-left: 4px solid var(--sun); font-size: 1.15rem; line-height: 1.5; }
.entry-content h4 { margin: 1.6em 0 .6em; font-size: 1.02rem; }
.entry-content ul, .entry-content ol { padding-left: 1.4em; }
.entry-content li { margin-bottom: .4em; }
.entry-content strong { background: linear-gradient(transparent 62%, var(--sun-pale) 62%); }
.entry-content .wp-block-table { overflow-x: auto; margin-inline: 0; }
.entry-content table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.entry-content th, .entry-content td { padding: 10px 12px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
.entry-content th { background: var(--mint); white-space: nowrap; }
.entry-content blockquote { margin-inline: 0; padding: 12px 18px; border-left: 4px solid var(--line); background: #f7f9f8; color: var(--ink-sub); }
.entry-content figure { margin-inline: 0; }

.toc { margin: 0 0 2.2em; border: 1px solid var(--line); border-radius: 6px; background: #fafcfb; }
.toc summary { padding: 12px 18px; font-weight: 700; cursor: pointer; }
.toc-list { margin: 0; padding: 0 18px 16px 2.6em; font-size: .93rem; }
.toc-list ol { margin: .3em 0; padding-left: 1.4em; list-style: lower-alpha; }
.toc-list li { margin-bottom: .3em; }
.toc-list a { color: var(--ink); text-decoration: none; }
.toc-list a:hover { color: var(--teal); text-decoration: underline; }

.box { margin: 1.8em 0; padding: 16px 20px; border: 2px solid var(--teal); border-radius: 6px; }
.box__title { margin: 0 0 6px; color: var(--teal); font-weight: 700; }
.box__body > :last-child { margin-bottom: 0; }
.box--warn { border-color: #b45309; }
.box--warn .box__title { color: #b45309; }
.box--memo { border-color: var(--line); background: #fafcfb; }
.box--memo .box__title { color: var(--ink-sub); }

.cta-inline { margin: 2em 0; padding: 16px 20px; border-left: 5px solid var(--sun); border-radius: 0 6px 6px 0; background: var(--sun-pale); }
.cta-inline__text { margin: 0 0 8px; font-size: .95rem; }
.cta-inline__link { font-weight: 700; }

.next-stage { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin: 40px 0 0; padding: 16px 20px; border: 1px solid var(--line); border-radius: 6px; color: var(--ink); text-decoration: none; }
.next-stage:hover { border-color: var(--teal); color: var(--ink); }
.next-stage__label { color: var(--teal); font-size: .82rem; font-weight: 700; }
.next-stage__title { font-weight: 700; }

.author-box { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line); color: var(--ink-sub); font-size: .9rem; }
.author-box p { margin: 0; }
.author-box__name { margin-bottom: 4px !important; color: var(--ink); font-weight: 700; }

.related { max-width: 740px; margin-top: 48px; }
.related__title { margin: 0 0 12px; font-size: 1.15rem; }

/* ---------- sidebar ---------- */
.sidebar { font-size: .92rem; }
@media (min-width: 961px) { .sidebar__sticky { position: sticky; top: 24px; } }
.side-block { margin-bottom: 32px; }
.side-title { margin: 0 0 10px; padding-bottom: 6px; border-bottom: 2px solid var(--teal); font-size: .95rem; }
.side-cta { padding: 20px; border-radius: 6px; background: var(--mint); }
.side-cta p { margin: 0 0 12px; }
.side-cta__title { font-size: 1rem; font-weight: 700; }
.side-cta .btn { width: 100%; margin-bottom: 8px; }
.side-stages { margin: 0; padding: 0; list-style: none; }
.side-stages li { border-bottom: 1px solid var(--line); }
.side-stages a { display: flex; gap: 10px; padding: 10px 2px; color: var(--ink); text-decoration: none; }
.side-stages a:hover { color: var(--teal); }
.side-stages .n { width: 1.2em; color: var(--teal); font-weight: 700; }

.search-form { display: flex; }
.search-form input[type="search"] { flex: 1; min-width: 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 4px 0 0 4px; font: inherit; font-size: .92rem; }
.search-form button { padding: 10px 16px; border: 0; border-radius: 0 4px 4px 0; background: var(--teal); color: #fff; font: inherit; font-weight: 700; cursor: pointer; }

/* ---------- pagination ---------- */
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 32px; }
.pagination .page-numbers { display: inline-grid; place-items: center; min-width: 40px; height: 40px; padding: 0 12px; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); text-decoration: none; }
.pagination .current { border-color: var(--teal); background: var(--teal); color: #fff; }

/* ---------- footer ---------- */
.site-footer { padding: 44px 0 24px; background: var(--ink); color: #d9e1e7; font-size: .85rem; }
.site-footer a { color: #fff; }
.site-footer__inner { display: grid; grid-template-columns: 1fr auto; gap: 24px 48px; }
.site-footer__name { margin: 0 0 8px; color: #fff; font-size: 1.05rem; font-weight: 700; }
.site-footer__about p:last-child { margin: 0; }
.site-footer__menu { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.site-footer__copy { margin: 32px 0 0; color: #9aa7b2; font-size: .75rem; text-align: center; }
@media (max-width: 700px) { .site-footer__inner { grid-template-columns: 1fr; } }

/* ---------- WordPress core ---------- */
.alignleft { float: left; margin: 0 1.5em 1em 0; }
.alignright { float: right; margin: 0 0 1em 1.5em; }
.aligncenter { display: block; margin-inline: auto; }
.wp-caption-text, figcaption { color: var(--ink-sub); font-size: .82rem; }

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
