/* --- 基本設定 --- */
:root {
    --primary-color: #6a4a3a; /* 温かみのある茶色 */
    --accent-color: #e59a53;  /* アクセントのオレンジ */
    --bg-color: #fcfaf6;      /* 背景のベージュ */
    --text-color: #555;       /* 基本テキスト色 */
    --light-bg-color: #fff;   /* 白背景 */
    --footer-bg-color: #f0eade;/* フッターの背景色 */
    --content-max-width: 1200px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.8;
    color: var(--text-color);
    background-color: var(--bg-color);
    margin: 0;
}

.container,
.wp-block-group.container {
    max-width: var(--content-max-width);
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--primary-color);
    font-weight: 600;
}

a {
    text-decoration: none;
    color: var(--accent-color);
    transition: opacity 0.3s;
}

a:hover {
    opacity: 0.8;
}

img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

.section {
    padding: 80px 0;
}

.section-title {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--accent-color);
}

/* --- ヘッダー --- */
.header {
    background-color: var(--light-bg-color);
    padding: 15px 0;
    border-bottom: 2px solid var(--accent-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.header-logo {
    display: flex;
    align-items: center;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    flex: 1;
    min-width: 0;
}
.logo-image {
    height: 40px;
    width: auto;
    margin-right: 15px;
    flex-shrink: 0;
}
.header-logo-text {
    line-height: 1.3;
}

/* ハンバーガーボタン（デスクトップでは非表示） */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 6px;
    width: 44px;
    height: 44px;
    padding: 0;
    margin-left: 12px;
    border: 2px solid var(--accent-color);
    border-radius: 6px;
    background-color: var(--light-bg-color);
    cursor: pointer;
    flex-shrink: 0;
    transition: background-color 0.3s;
}

.menu-toggle:hover {
    background-color: var(--footer-bg-color);
}

.menu-toggle-bar {
    display: block;
    width: 22px;
    height: 2px;
    background-color: var(--primary-color);
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}

.menu-toggle.is-active .menu-toggle-bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.menu-toggle.is-active .menu-toggle-bar:nth-child(2) {
    opacity: 0;
}

.menu-toggle.is-active .menu-toggle-bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.header-nav ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
}

.header-nav li {
    margin-left: 35px;
}

.header-nav a {
    font-weight: bold;
    font-size: 1rem;
    padding-bottom: 5px;
    border-bottom: 2px solid transparent;
}

.header-nav a.current,
.header-nav a:hover,
.header-nav .current-menu-item > a,
.header-nav .current_page_item > a,
.header-nav .current-menu-ancestor > a {
    color: var(--primary-color);
    border-bottom-color: var(--accent-color);
}

body.nav-open {
    overflow: hidden;
}

/* --- フッター --- */
.footer {
    background-color: var(--footer-bg-color);
    color: var(--primary-color);
    padding: 30px 0;
    text-align: center;
    font-size: 0.9rem;
    margin-top: 80px;
}
.footer p {
    margin: 5px 0;
}

/* --- 汎用コンポーネント --- */
.button {
    display: inline-block;
    background-color: var(--accent-color);
    color: #fff;
    padding: 15px 40px;
    border-radius: 50px;
    font-weight: bold;
    font-size: 1.1rem;
    transition: background-color 0.3s, transform 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    border: none;
    cursor: pointer;
}
.button:hover {
    background-color: #d98c43;
    opacity: 1;
    transform: translateY(-2px);
}

/* --- トップページ --- */
.hero,
.wp-block-cover.hero {
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    padding: 150px 20px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}
.hero::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(0, 0, 0, 0.4);
}
.wp-block-cover.hero::before {
    content: none;
}
.hero-content,
.wp-block-cover.hero .wp-block-cover__inner-container {
    position: relative;
    z-index: 1;
    width: 100%;
}
.hero h1,
.wp-block-cover.hero h1 {
    font-size: 2.8rem;
    color: #fff;
    margin-bottom: 20px;
    text-shadow: 2px 2px 5px rgba(0,0,0,0.7);
}
.hero p,
.wp-block-cover.hero p {
    font-size: 1.2rem;
    font-weight: 500;
    color: #fff;
}
.concept {
    background-color: var(--light-bg-color);
}
.concept-message {
    font-size: 1.2rem;
    font-weight: 500;
    text-align: center;
}
.services-grid,
.services-grid.wp-block-columns {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    align-items: stretch;
}
.services-grid > .wp-block-column {
    display: flex;
    flex-direction: column;
}
.services-grid .service-card {
    flex: 1;
    height: 100%;
    box-sizing: border-box;
}
.service-card {
    background-color: var(--light-bg-color);
    padding: 40px 30px;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    border-top: 5px solid var(--accent-color);
    transition: transform 0.3s, box-shadow 0.3s;
}
.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}
.service-card h3 {
    font-size: 1.5rem;
    margin-top: 0;
    margin-bottom: 20px;
}
.service-card ul,
.service-card .wp-block-list {
    list-style: none;
    padding: 0;
}
.service-card li,
.service-card .wp-block-list li {
    margin-bottom: 1.2em;
}
.service-card li strong {
    display: block;
    color: var(--primary-color);
    font-size: 1.1rem;
    margin-bottom: 5px;
}
.cta {
    background-color: var(--primary-color);
    color: #fff;
    text-align: center;
}
.cta h2 {
    color: #fff;
}
.cta p {
    margin-bottom: 30px;
}
.cta .wp-block-button__link {
    background-color: var(--accent-color);
    color: #fff;
    padding: 15px 40px;
    border-radius: 50px;
    font-weight: bold;
    font-size: 1.1rem;
    border: none;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: background-color 0.3s, transform 0.3s;
}
.cta .wp-block-button__link:hover {
    background-color: #d98c43;
    opacity: 1;
    transform: translateY(-2px);
    color: #fff;
}

/* --- 事務所情報・スタッフ紹介 共通 --- */
.page-title {
    background-color: var(--footer-bg-color);
    padding: 60px 0;
    text-align: center;
    margin-bottom: 40px;
}
.page-title h1 {
    font-size: 2.5rem;
    margin: 0;
}

.post-meta {
    margin: 15px 0 0;
    font-size: 0.95rem;
    color: var(--text-color);
}

.post-meta-categories {
    margin-left: 15px;
}

.post-meta-categories a {
    margin-right: 8px;
}

.archive-description {
    margin-top: 15px;
    font-size: 1rem;
}

/* --- 事務所情報ページ --- */
.office-info-grid,
.office-info-grid.wp-block-columns {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 50px;
    align-items: center;
    margin-bottom: 80px;
}
.office-image img {
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.office-info-table dl {
    margin: 0;
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 15px;
}
.office-info-table table {
    border: none;
    width: 100%;
    border-collapse: collapse;
}
.office-info-table td {
    border: none;
    padding: 8px 0;
    vertical-align: top;
    background: transparent;
}
.office-info-table td:first-child {
    font-weight: bold;
    color: var(--primary-color);
    width: 1%;
    white-space: nowrap;
    padding-right: 48px;
}
.office-info-table td:last-child {
    padding-left: 0;
}
.office-info-table dt {
    font-weight: bold;
    color: var(--primary-color);
}
.office-info-table dd {
    margin: 0;
}
.message-box {
    background-color: var(--light-bg-color);
    padding: 50px;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    margin-bottom: 60px;
}
.message-box-title {
    text-align: center;
    font-size: 1.8rem;
    margin-top: 0;
    margin-bottom: 40px;
}
.message-content,
.message-content.wp-block-columns {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}
.message-text { flex: 1; }
.message-image,
.message-image.wp-block-column {
    flex: 0 0 250px;
    max-width: 250px;
}
.message-image img,
.message-image .wp-block-image img {
    width: 250px;
    max-width: 250px;
    height: auto;
    border-radius: 50%;
}

.map-container iframe,
.map-container .wp-block-embed iframe {
    width: 100%;
    height: 450px;
    border: 0;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

/* --- スタッフ紹介ページ --- */
.staff-card {
    background-color: var(--light-bg-color);
    padding: 50px;
    border-radius: 8px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
    display: flex;
    gap: 50px;
    align-items: flex-start;
}
.staff-card > .wp-block-columns {
    gap: 50px;
    align-items: flex-start;
}
.staff-image,
.staff-image.wp-block-column {
    flex: 0 0 220px;
    max-width: 220px;
}
.staff-image img,
.staff-image .wp-block-image img {
    width: 220px;
    max-width: 220px;
    height: auto;
    border-radius: 50%;
    border: 6px solid var(--accent-color);
}
.staff-details { flex: 1; }
.staff-title {
    color: var(--accent-color);
    font-weight: bold;
}
.staff-details h2 {
    font-size: 2.2rem;
    margin: 5px 0 30px 0;
}
.staff-section-title {
    font-size: 1.4rem;
    color: var(--primary-color);
    border-bottom: 2px solid var(--footer-bg-color);
    padding-bottom: 10px;
    margin-top: 30px;
    margin-bottom: 20px;
}
.qualification-list,
.qualification-list.wp-block-list {
    list-style: none;
    padding: 0;
}
.qualification-list li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 10px;
}
.qualification-list li::before {
    content: '✓';
    color: var(--accent-color);
    font-weight: bold;
    position: absolute;
    left: 0;
    top: 0;
}

/* 保有資格・所属 + ねこちゃん写真 */
.qualification-with-cats,
.qualification-with-cats.wp-block-columns {
    display: grid;
    grid-template-columns: 1fr minmax(200px, 38%);
    gap: 20px 30px;
    align-items: flex-start;
    margin-bottom: 0;
}
.qualification-with-cats .qualification-list-col {
    min-width: 0;
}
.qualification-with-cats .qualification-list {
    margin-bottom: 0;
}
.staff-cat-images,
.staff-cat-images.wp-block-column {
    flex: 1 1 auto;
    max-width: none;
}
.staff-cat-images .wp-block-image {
    margin-bottom: 16px;
}
.staff-cat-images .wp-block-image:last-child {
    margin-bottom: 0;
}
.staff-cat-image img {
    width: 100%;
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}

/* --- お問合せページ --- */
.form-wrapper {
    max-width: 800px;
    margin: 0 auto;
    background-color: var(--light-bg-color);
    padding: 40px 60px;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
}
.form-intro {
    text-align: center;
    margin-bottom: 40px;
}
.form-intro h2 {
    font-size: 1.8rem;
    margin-top: 0;
}
.form-group {
    margin-bottom: 30px;
}
.form-group label {
    display: block;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 10px;
}
.form-group label .required {
    display: inline-block;
    background-color: var(--accent-color);
    color: #fff;
    font-size: 0.75rem;
    padding: 3px 8px;
    border-radius: 4px;
    margin-left: 8px;
    vertical-align: middle;
}
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group select,
.form-group textarea,
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 select,
.wpcf7 textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    box-sizing: border-box;
    transition: border-color 0.3s, box-shadow 0.3s;
}
.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group input[type="tel"]:focus,
.form-group select:focus,
.form-group textarea:focus,
.wpcf7 input:focus,
.wpcf7 select:focus,
.wpcf7 textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(229, 154, 83, 0.2);
}
.form-group textarea,
.wpcf7 textarea {
    resize: vertical;
    min-height: 150px;
}
.privacy-policy {
    margin: 30px 0;
    text-align: center;
}
.privacy-policy label {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
}
.privacy-policy input[type="checkbox"] {
    margin-right: 10px;
    transform: scale(1.2);
}
.form-wrapper .button,
.wpcf7 input[type="submit"] {
    width: 100%;
    padding: 18px;
}
.wpcf7 input[type="submit"] {
    display: inline-block;
    background-color: var(--accent-color);
    color: #fff;
    border-radius: 50px;
    font-weight: bold;
    font-size: 1.1rem;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}
.wpcf7-form p {
    margin-bottom: 30px;
}
.wpcf7-form label {
    display: block;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 10px;
}

/* CF7: form-group 内の余分な p タグをリセット */
.form-wrapper .form-group p {
    margin: 0;
}

.form-wrapper .form-group .wpcf7-form-control-wrap {
    display: block;
}

.form-wrapper .wpcf7-not-valid-tip {
    font-size: 0.85rem;
    color: #c0392b;
    margin-top: 8px;
}

.form-wrapper .wpcf7-response-output {
    margin: 30px 0 0;
    padding: 15px 20px;
    border-radius: 8px;
    text-align: center;
}

.form-wrapper .wpcf7 form.invalid .wpcf7-response-output,
.form-wrapper .wpcf7 form.unaccepted .wpcf7-response-output {
    border-color: #c0392b;
    background-color: #fdf2f2;
}

.form-wrapper .wpcf7 form.sent .wpcf7-response-output {
    border-color: var(--accent-color);
    background-color: var(--footer-bg-color);
}

.privacy-policy .wpcf7-form-control-wrap {
    display: inline;
}

.privacy-policy .wpcf7-list-item {
    margin: 0;
}

.privacy-policy .wpcf7-list-item label {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    font-weight: normal;
    margin-bottom: 0;
}

.privacy-policy input[type="checkbox"] {
    margin-right: 10px;
    transform: scale(1.2);
}

/* --- 料金案内ページ --- */
.price-notes {
    max-width: 900px;
    margin: 0 auto 60px;
    background-color: var(--light-bg-color);
    padding: 20px 30px;
    border-left: 5px solid var(--accent-color);
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    border-radius: 8px;
    text-align: left;
}
.price-notes h3 {
    margin-top: 10px;
}
.price-notes ul {
    list-style: '♬ ';
    padding-left: 20px;
}
.price-category {
    max-width: 900px;
    margin: 0 auto 40px;
    background-color: var(--light-bg-color);
    padding: 40px 20px 40px 50px;
    border-radius: 8px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
}
.price-category h3 {
    font-size: 1.6rem;
    margin-top: 0;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--footer-bg-color);
    text-align: center;
}
.price-items {
    margin: 0;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 20px 30px;
    align-items: center;
}
.price-items dt {
    font-weight: bold;
    color: var(--primary-color);
}
.price-items dd {
    margin: 0;
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
    white-space: nowrap;
}
.price-items .note {
    grid-column: 1 / -1;
    font-size: 0.9rem;
    font-weight: normal;
    color: var(--text-color);
    margin-top: -10px;
    padding-left: 1em;
}
.price-items .note + dd {
    display: none;
}
.price-items .indent {
    padding-left: 2em;
}

/* Gutenberg 料金表（1fr + auto：価格列を右端に、先頭は揃える） */
.entry-content .price-category .price-items-grid,
.entry-content .price-category .wp-block-group.price-items-grid,
.entry-content .price-category .price-items-grid .wp-block-group__inner-container {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    column-gap: 60px !important;
    row-gap: 20px !important;
    align-items: center !important;
    width: 100% !important;
    max-width: 100% !important;
    padding-right: 0 !important;
    margin-right: -15px !important;
}

.entry-content .price-items-grid.is-layout-grid {
    grid-template-columns: minmax(0, 1fr) auto !important;
}

.entry-content .price-items-grid.is-layout-flow > *,
.entry-content .price-items-grid > .price-label,
.entry-content .price-items-grid > .price-value,
.entry-content .price-items-grid > .price-note,
.entry-content .price-items-grid .wp-block-group__inner-container > .price-label,
.entry-content .price-items-grid .wp-block-group__inner-container > .price-value,
.entry-content .price-items-grid .wp-block-group__inner-container > .price-note {
    margin: 0 !important;
}

.entry-content .price-items-grid > .price-label,
.entry-content .price-items-grid .wp-block-group__inner-container > .price-label {
    grid-column: 1;
    font-weight: bold;
    color: var(--primary-color);
}

.entry-content .price-items-grid > .price-label.indent,
.entry-content .price-items-grid .wp-block-group__inner-container > .price-label.indent {
    padding-left: 2em;
}

.entry-content .price-items-grid > .price-value,
.entry-content .price-items-grid .wp-block-group__inner-container > .price-value {
    grid-column: 2;
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
    white-space: nowrap;
    text-align: left;
    font-variant-numeric: tabular-nums;
    padding: 0;
}

.entry-content .price-items-grid > .price-note,
.entry-content .price-items-grid .wp-block-group__inner-container > .price-note {
    grid-column: 1 / -1;
    font-size: 0.9rem;
    font-weight: normal;
    color: var(--text-color);
    margin-top: -6px !important;
    padding-left: 1em;
}

.entry-content .price-items-grid > .price-note.indent,
.entry-content .price-items-grid .wp-block-group__inner-container > .price-note.indent {
    padding-left: 2em;
}

/* 旧カラム形式（再インポート前のページ用フォールバック） */
.price-category .price-row {
    display: contents;
}
.price-category .price-row .wp-block-column:first-child p {
    font-weight: bold;
    color: var(--primary-color);
    margin: 0;
}
.price-category .price-row .price-value-col p,
.price-category .price-row .wp-block-column:last-child p {
    margin: 0;
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
    white-space: nowrap;
    text-align: right;
    font-variant-numeric: tabular-nums;
}
.price-category .price-row.indent .wp-block-column:first-child p {
    padding-left: 2em;
}

/* --- ブログ --- */
.blog-section {
    padding-top: 40px;
    padding-bottom: 60px;
}

.blog-container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 40px;
    align-items: start;
}

.blog-main {
    min-width: 0;
}

/* パンくず */
.breadcrumbs {
    font-size: 0.9rem;
    margin-bottom: 28px;
    color: var(--text-color);
    line-height: 1.6;
}

.breadcrumbs a {
    color: var(--accent-color);
    text-decoration: none;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

.breadcrumbs-current {
    color: var(--primary-color);
}

.breadcrumbs-sep {
    color: var(--text-color);
}

/* 一覧リスト */
.blog-list {
    margin-bottom: 20px;
}

.blog-list-item {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 24px;
    padding-bottom: 32px;
    margin-bottom: 32px;
    border-bottom: 1px solid #ddd;
}

.blog-list-item:last-child {
    margin-bottom: 0;
}

.blog-list-thumb {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 4px;
    line-height: 0;
}

.blog-list-thumb img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.blog-list-thumb:hover img {
    transform: scale(1.03);
}

.blog-list-thumb-placeholder {
    display: block;
    width: 100%;
    height: 180px;
    background-color: var(--light-bg-color);
}

.blog-list-cat {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.65);
    color: #fff;
    font-size: 0.75rem;
    padding: 4px 10px;
    line-height: 1.4;
}

.blog-list-body {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.blog-list-title {
    font-size: 1.35rem;
    margin: 0 0 8px;
    line-height: 1.4;
}

.blog-list-title a {
    color: var(--primary-color);
    text-decoration: none;
}

.blog-list-title a:hover {
    color: var(--accent-color);
}

.blog-list-date {
    font-size: 0.9rem;
    color: var(--text-color);
    margin: 0 0 12px;
}

.blog-list-excerpt {
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 16px;
    color: var(--text-color);
}

.blog-list-excerpt p {
    margin: 0;
}

.blog-read-more {
    align-self: flex-end;
    border-radius: 4px;
    padding: 10px 28px;
    font-size: 0.95rem;
    margin-top: auto;
}

/* サイドバー */
.blog-sidebar {
    min-width: 0;
}

.sidebar-widget {
    margin-bottom: 32px;
}

.sidebar-widget-title {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--primary-color);
    margin: 0 0 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid #ddd;
}

.sidebar-recent-posts {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-recent-item {
    display: grid;
    grid-template-columns: 70px minmax(0, 1fr);
    gap: 12px;
    margin-bottom: 16px;
    align-items: start;
}

.sidebar-recent-item:last-child {
    margin-bottom: 0;
}

.sidebar-recent-thumb {
    display: block;
    line-height: 0;
    overflow: hidden;
    border-radius: 4px;
}

.sidebar-recent-thumb img {
    width: 70px;
    height: 70px;
    object-fit: cover;
    display: block;
}

.sidebar-recent-thumb-placeholder {
    display: block;
    width: 70px;
    height: 70px;
    background-color: var(--light-bg-color);
}

.sidebar-recent-title {
    display: block;
    font-size: 0.9rem;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
    line-height: 1.4;
    margin-bottom: 4px;
}

.sidebar-recent-title:hover {
    color: var(--accent-color);
}

.sidebar-recent-date {
    font-size: 0.8rem;
    color: var(--text-color);
}

.sidebar-link-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-link-list li {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    font-size: 0.9rem;
    line-height: 1.5;
}

.sidebar-link-list li:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.sidebar-link-list a {
    color: var(--primary-color);
    text-decoration: none;
}

.sidebar-link-list a:hover {
    color: var(--accent-color);
}

/* ウィジェットエリア利用時のリスト */
.blog-sidebar .widget ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.blog-sidebar .widget ul li {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    font-size: 0.9rem;
    line-height: 1.5;
}

.blog-sidebar .widget ul li:last-child {
    border-bottom: none;
}

.blog-sidebar .widget ul a {
    color: var(--primary-color);
    text-decoration: none;
}

.blog-sidebar .widget ul a:hover {
    color: var(--accent-color);
}

/* 記事ページ */
.single-post-title {
    font-size: 1.75rem;
    color: var(--primary-color);
    margin: 0 0 16px;
    line-height: 1.4;
}

.single-post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px 24px;
    font-size: 0.9rem;
    color: var(--text-color);
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #eee;
}

.single-post-meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.meta-icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    background-color: var(--accent-color);
    mask-size: contain;
    mask-repeat: no-repeat;
    mask-position: center;
    -webkit-mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-position: center;
}

.meta-icon-date {
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M19 4h-1V2h-2v2H8V2H6v2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2zm0 16H5V9h14v11z'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M19 4h-1V2h-2v2H8V2H6v2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2zm0 16H5V9h14v11z'/%3E%3C/svg%3E");
}

.meta-icon-update {
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M12 6V3L8 7l4 4V8c2.76 0 5 2.24 5 5 0 1.01-.3 1.95-.82 2.73l1.46 1.46A6.97 6.97 0 0 0 19 13c0-3.87-3.13-7-7-7zm-5 5c0-1.01.3-1.95.82-2.73L4.34 6.79A6.97 6.97 0 0 0 5 13c0 3.87 3.13 7 7 7v3l4-4-4-4v3c-2.76 0-5-2.24-5-5z'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M12 6V3L8 7l4 4V8c2.76 0 5 2.24 5 5 0 1.01-.3 1.95-.82 2.73l1.46 1.46A6.97 6.97 0 0 0 19 13c0-3.87-3.13-7-7-7zm-5 5c0-1.01.3-1.95.82-2.73L4.34 6.79A6.97 6.97 0 0 0 5 13c0 3.87 3.13 7 7 7v3l4-4-4-4v3c-2.76 0-5-2.24-5-5z'/%3E%3C/svg%3E");
}

.meta-icon-author {
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z'/%3E%3C/svg%3E");
}

.single-post-thumbnail {
    margin-bottom: 32px;
}

.single-post-thumbnail img {
    width: 100%;
    height: auto;
    max-height: 500px;
    object-fit: cover;
    display: block;
    border-radius: 4px;
}

.post-taxonomy {
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid #eee;
}

.post-categories,
.post-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
}

.post-tags {
    margin-top: 14px;
}

.post-categories-label,
.post-tags-label {
    font-size: 0.85rem;
    color: #fff;
    background-color: #555;
    padding: 5px 14px;
    border-radius: 4px;
    line-height: 1.4;
}

.post-category-link {
    font-size: 0.9rem;
    color: var(--primary-color);
    text-decoration: none;
}

.post-category-link:hover {
    color: var(--accent-color);
}

.post-tags-list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 16px;
}

.post-tag-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9rem;
    color: var(--primary-color);
    text-decoration: none;
}

.post-tag-link:hover {
    color: var(--accent-color);
}

.post-tag-icon {
    display: inline-block;
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    background-color: var(--primary-color);
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M21.41 11.58l-9-9C12.05 2.22 11.55 2 11 2H4c-1.1 0-2 .9-2 2v7c0 .55.22 1.05.59 1.42l9 9c.36.36.86.58 1.41.58s1.05-.22 1.41-.59l7-7c.37-.36.59-.86.59-1.41 0-.55-.23-1.06-.59-1.42zM5.5 7C4.67 7 4 6.33 4 5.5S4.67 4 5.5 4 7 4.67 7 5.5 6.33 7 5.5 7z'/%3E%3C/svg%3E");
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M21.41 11.58l-9-9C12.05 2.22 11.55 2 11 2H4c-1.1 0-2 .9-2 2v7c0 .55.22 1.05.59 1.42l9 9c.36.36.86.58 1.41.58s1.05-.22 1.41-.59l7-7c.37-.36.59-.86.59-1.41 0-.55-.23-1.06-.59-1.42zM5.5 7C4.67 7 4 6.33 4 5.5S4.67 4 5.5 4 7 4.67 7 5.5 6.33 7 5.5 7z'/%3E%3C/svg%3E");
    mask-size: contain;
    mask-repeat: no-repeat;
    mask-position: center;
    -webkit-mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-position: center;
}

.post-tag-link:hover .post-tag-icon {
    background-color: var(--accent-color);
}

/* 前後記事ナビ */
.post-navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 40px;
}

.post-nav-card {
    position: relative;
    display: block;
    height: 200px;
    overflow: hidden;
    border-radius: 8px;
    text-decoration: none;
    background-color: var(--light-bg-color);
}

.post-nav-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.post-nav-thumb-placeholder {
    display: block;
    width: 100%;
    height: 100%;
    background-color: #d8c4b0;
}

.post-nav-card:hover img {
    transform: scale(1.05);
}

.post-nav-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: var(--accent-color);
    color: #fff;
    padding: 4px 12px;
    font-size: 0.8rem;
    font-weight: bold;
    line-height: 1.4;
    z-index: 1;
}

.post-nav-title {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.65);
    color: #fff;
    padding: 12px 14px;
    font-size: 0.9rem;
    line-height: 1.4;
}

.post-nav-card:only-child {
    max-width: 100%;
}

.post-nav-next:only-child {
    grid-column: 2;
}

@media (max-width: 768px) {
    .post-nav-next:only-child {
        grid-column: 1;
    }
}

/* ページネーション */
.blog-pagination {
    margin-top: 40px;
}

.pagination .nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border-radius: 4px;
    background-color: var(--light-bg-color);
    color: var(--primary-color);
    font-weight: bold;
    text-decoration: none;
    border: 1px solid #ddd;
}

.pagination a:hover {
    background-color: #eee;
}

.pagination .current {
    background-color: var(--accent-color);
    color: #fff;
    border-color: var(--accent-color);
}

.no-posts {
    text-align: center;
    font-size: 1.1rem;
}

/* 旧カード型（互換用） */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.blog-card {
    background-color: var(--light-bg-color);
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.blog-card-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 0;
    display: block;
}

.blog-card-body {
    padding: 25px;
}

.blog-card-date {
    font-size: 0.85rem;
    color: var(--text-color);
    margin: 0 0 10px;
}

.blog-card-title {
    font-size: 1.25rem;
    margin: 0 0 15px;
}

.blog-card-title a {
    color: var(--primary-color);
}

.blog-card-excerpt {
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.blog-card-link {
    font-weight: bold;
}

/* --- Gutenberg / エントリーコンテンツ --- */
.entry-content {
    max-width: 100%;
}

.entry-content > *:first-child {
    margin-top: 0;
}

.entry-content .alignwide {
    max-width: var(--content-max-width);
    margin-left: auto;
    margin-right: auto;
}

.entry-content .alignfull {
    max-width: none;
    width: 100%;
}

.entry-content img {
    height: auto;
}

/* page.php 内の entry-content で section を使う場合の余白調整 */
.section > .container > .entry-content > .section:first-child {
    padding-top: 0;
}

.section > .container > .entry-content > .section:last-child {
    padding-bottom: 0;
}

/* --- レスポンシブ対応 --- */
@media (max-width: 900px) {
    .services-grid,
    .services-grid.wp-block-columns {
        grid-template-columns: 1fr 1fr;
    }
    .blog-container {
        grid-template-columns: 1fr;
    }
    .blog-sidebar {
        margin-top: 40px;
    }
    .blog-list-item {
        grid-template-columns: 220px minmax(0, 1fr);
    }
    .blog-grid {
        grid-template-columns: 1fr 1fr;
    }
    .office-info-grid,
    .office-info-grid.wp-block-columns {
        grid-template-columns: 1fr;
    }
    .staff-card,
    .staff-card > .wp-block-columns {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .staff-image,
    .staff-image.wp-block-column {
        width: 180px;
        max-width: 180px;
        flex: 0 0 180px;
    }
    .staff-image img,
    .staff-image .wp-block-image img {
        width: 180px;
        max-width: 180px;
    }
    .staff-section-title {
        text-align: left;
    }
    .qualification-with-cats,
    .qualification-with-cats.wp-block-columns {
        grid-template-columns: 1fr;
    }
    .staff-cat-images {
        max-width: 280px;
        margin: 0 auto;
    }
    .qualification-list li {
        text-align: left;
    }
    .message-content,
    .message-content.wp-block-columns {
        flex-direction: column-reverse;
        align-items: center;
    }
    .message-image,
    .message-image.wp-block-column {
        margin-bottom: 30px;
        width: 200px;
        max-width: 200px;
        flex: 0 0 200px;
    }
    .message-image img,
    .message-image .wp-block-image img {
        width: 200px;
        max-width: 200px;
    }
}

@media (max-width: 900px) {
    .menu-toggle {
        display: flex;
    }

    .header-nav {
        position: absolute;
        top: calc(100% + 2px);
        left: 0;
        right: 0;
        background-color: var(--light-bg-color);
        border-bottom: 2px solid var(--accent-color);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        visibility: hidden;
        transition: max-height 0.35s ease, opacity 0.25s ease, visibility 0.25s ease;
    }

    .header-nav.is-open {
        max-height: 500px;
        opacity: 1;
        visibility: visible;
    }

    .header-nav ul {
        flex-direction: column;
        padding: 10px 0;
    }

    .header-nav li {
        margin: 0;
        border-bottom: 1px solid var(--footer-bg-color);
    }

    .header-nav li:last-child {
        border-bottom: none;
    }

    .header-nav a {
        display: block;
        padding: 14px 20px;
        border-bottom: none;
    }

    .header-nav .current-menu-item > a,
    .header-nav .current_page_item > a,
    .header-nav .current-menu-ancestor > a {
        background-color: var(--footer-bg-color);
    }

    .header-logo {
        font-size: 1.1rem;
    }

    .logo-image {
        height: 36px;
        margin-right: 10px;
    }
}

@media (max-width: 480px) {
    .header-logo-text {
        font-size: 0.95rem;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 60px 0;
    }
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 40px;
    }
    .hero {
        padding: 100px 20px;
    }
    .services-grid,
    .services-grid.wp-block-columns {
        grid-template-columns: 1fr;
    }
    .blog-list-item {
        grid-template-columns: 1fr;
    }
    .blog-list-thumb img,
    .blog-list-thumb-placeholder {
        height: 200px;
    }
    .post-navigation {
        grid-template-columns: 1fr;
    }
    .blog-grid {
        grid-template-columns: 1fr;
    }
    .hero h1,
    .wp-block-cover.hero h1 {
        font-size: 2rem;
    }
    .hero p,
    .wp-block-cover.hero p {
        font-size: 1rem;
    }
    .form-wrapper {
        padding: 30px 25px;
    }
    .form-intro h2 {
        font-size: 1.5rem;
    }
    .price-category {
        padding: 30px 25px;
    }
    .price-items {
        grid-template-columns: 1fr;
        gap: 5px;
    }
    .price-items dd {
        text-align: left;
        margin-bottom: 20px;
        padding-bottom: 10px;
        border-bottom: 1px dashed #ddd;
    }
    .price-items dt:last-of-type + dd,
    .price-items dd:last-of-type,
    .price-items .note + dd + dt + dd {
        border-bottom: none;
    }
    .price-items .note {
       text-align: left;
       margin-bottom: 15px;
    }
    .price-items .note + dd {
        display: none;
    }
    .entry-content .price-category .price-items-grid,
    .entry-content .price-category .price-items-grid .wp-block-group__inner-container {
        grid-template-columns: 1fr !important;
        row-gap: 5px !important;
        margin-right: 0 !important;
    }
    .entry-content .price-items-grid > .price-value,
    .entry-content .price-items-grid .wp-block-group__inner-container > .price-value {
        text-align: right;
        margin-bottom: 20px !important;
        padding-bottom: 10px;
        border-bottom: 1px dashed #ddd;
    }
    .entry-content .price-items-grid > .price-note,
    .entry-content .price-items-grid .wp-block-group__inner-container > .price-note {
        margin-bottom: 15px !important;
    }
    .price-category .price-row.wp-block-columns {
        display: flex;
        flex-direction: column;
        gap: 5px;
    }
    .price-category .price-row .price-value-col p,
    .price-category .price-row .wp-block-column:last-child p {
        text-align: right;
        margin-bottom: 20px;
        padding-bottom: 10px;
        border-bottom: 1px dashed #ddd;
    }
}

/* --- ページトップへ戻るボタン --- */
.page-top-btn {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    width: 56px;
    height: 56px;
    padding: 8px 6px;
    border: none;
    border-radius: 4px;
    background-color: var(--accent-color);
    color: #fff;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, background-color 0.2s ease;
}

.page-top-btn.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.page-top-btn:hover {
    background-color: var(--primary-color);
}

.page-top-btn-icon {
    display: block;
    width: 14px;
    height: 14px;
    border-left: 3px solid #fff;
    border-top: 3px solid #fff;
    transform: rotate(45deg);
    margin-top: 4px;
}

.page-top-btn-text {
    font-size: 0.55rem;
    font-weight: bold;
    line-height: 1;
    letter-spacing: 0.02em;
}

/* reCAPTCHA はお問合せページ以外で非表示 */
body:not(.is-contact-page) .grecaptcha-badge {
    display: none !important;
    visibility: hidden !important;
}

@media (max-width: 768px) {
    .page-top-btn {
        right: 14px;
        bottom: 14px;
        width: 50px;
        height: 50px;
    }
}
