@charset "UTF-8";
/* Shared responsive corrections. Loaded after the original theme and WP styles. */
#header .head-left h1 { margin: 0; }
#g-nav:not(.panelactive) { visibility: hidden; }
@media (min-width: 769px) {
  #g-nav, #header .openbtn { display: none; }
}
@media (max-width: 768px) {
  html { font-size: 8px; scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
  body { width: 100%; max-width: none; padding-bottom: calc(64px + env(safe-area-inset-bottom)); font-size: 16px; line-height: 1.8; }
  main *, #header *, #footer * { box-sizing: border-box; }
  .flex > * { min-width: 0; }
  img { height: auto; }
  p, h2, h3, li, dd, th, td { overflow-wrap: break-word; }
  .g-nav, .g-nav.fixed { display: none; }
  .pc-only { display: none; }
  .sp-only { display: block; }
  #header { top: 12px; z-index: 1000; }
  .head-top { width: calc(100% - 32px); }
  .head-left { width: min(60vw, 250px); max-width: none; }
  .head-left img { display: block; width: 100%; }
  .head-right { display: none; }
  #header .openbtn {
    display: block; position: fixed; top: 12px; right: 12px; z-index: 1002;
    width: 48px; height: 48px; padding: 0; border: 1px solid #0d8672;
    border-radius: 6px; background: #fff; cursor: pointer;
  }
  .openbtn span { display: block; position: absolute; left: 11px; width: 24px; height: 2px; border-radius: 2px; background: #0d8672; transition: transform .2s, opacity .2s; }
  .openbtn span:nth-of-type(1) { top: 15px; }
  .openbtn span:nth-of-type(2) { top: 23px; }
  .openbtn span:nth-of-type(3) { top: 31px; }
  .openbtn.active span:nth-of-type(1) { top: 23px; left: 11px; width: 24px; transform: rotate(45deg); }
  .openbtn.active span:nth-of-type(2) { opacity: 0; }
  .openbtn.active span:nth-of-type(3) { top: 23px; left: 11px; width: 24px; transform: rotate(-45deg); }
  #g-nav { display: block; position: fixed; inset: 0; z-index: 1001; width: 100%; height: 100vh; height: 100dvh; background: #0d7464; transform: translateX(100%); transition: transform .25s; }
  #g-nav.panelactive { right: 0; visibility: visible; transform: translateX(0); }
  #g-nav #g-nav-list, #g-nav.panelactive #g-nav-list { position: static; width: 100%; height: 100%; overflow-y: auto; overscroll-behavior: contain; padding: 80px 24px calc(32px + env(safe-area-inset-bottom)); }
  #g-nav .sp-nav { position: static; width: 100%; margin: 0 !important; padding: 0; transform: none; }
  #g-nav .sp-nav li { text-align: left; }
  #g-nav .sp-nav a, #g-nav summary { display: block; padding: 14px 8px; font: 500 16px/1.6 sans-serif; color: #fff; text-align: left; letter-spacing: .03em; border-bottom: 1px solid #ffffff55; }
  #g-nav .accordion-004 { max-width: none; margin: 0; border: 0; }
  #g-nav summary { display: flex; justify-content: space-between; align-items: center; cursor: pointer; }
  #g-nav summary::after { content: '+'; border: 0; width: auto; height: auto; transform: none; }
  #g-nav details[open] summary::after { content: '−'; }
  #g-nav .accordion-004 ul, #g-nav .accordion-004[open] ul { position: static; width: 100%; padding: 0 0 12px 16px; opacity: 1; transform: none; }
  #g-nav .accordion-004 a { font-size: 15px; }
  body.mobile-menu-open { overflow: hidden; }
  body.mobile-menu-open .sp-footer { visibility: hidden; }
  .openbtn:focus-visible, #g-nav a:focus-visible, #g-nav summary:focus-visible { outline: 3px solid #f7ed93; outline-offset: 2px; }
  body.admin-bar #header .openbtn { top: 58px; }
  body.admin-bar #g-nav #g-nav-list { padding-top: 126px; }

  /* Let the hero grow with text, including short landscape screens. */
  #mainvisual { display: flex; align-items: center; min-height: 540px; min-height: max(540px, 76svh); height: auto; padding: 120px 20px 56px; background-size: cover; background-position: center; }
  #mainvisual .catch-copy { position: static; width: 100%; top: auto; left: auto; transform: none; }
  #mainvisual .catch-copy h2 { font-size: clamp(22px, 4.5vw, 32px); line-height: 1.7; margin: 0; letter-spacing: 0; }
  #mainvisual .catch-copy .h2bg { font-size: clamp(22px, 5.4vw, 38px); }
  #mainvisual .catch-copy p { font-size: clamp(15px, 2.5vw, 18px); line-height: 1.9; margin: 20px 0 0; }
  #mainvisual .catch-copy p br { display: none; }
  #s-mainvisual { height: auto; min-height: 280px; display: flex; align-items: center; justify-content: center; padding: 110px 20px 48px; }
  #s-mainvisual .catch-copy { position: static; width: 100%; transform: none; }
  #s-mainvisual .catch-copy h2 { font-size: clamp(25px, 5.5vw, 36px); line-height: 1.5; letter-spacing: .08em; margin: 0; }
  #s-mainvisual .catch-copy p { font-size: 16px; letter-spacing: .15em; margin-top: 12px; }
  .mini-title p { font-size: clamp(22px, 5vw, 28px); letter-spacing: .08em; }
  #features, #greeting, #medical, #policy, #doctor, #time, #access { padding-top: 48px; padding-bottom: 48px; }
  .info, .news { height: auto; padding: 32px 0; }
  .info-title img, .news-title img { width: min(45%, 200px); }
  .info-wrap, .news-wrap, .news-inner { width: 90%; }
  .news-inner { height: 300px; }
  .info-wrap .addres, .news-box p, .news-box span, .table-memo { font-size: 16px; }
  .news-sec-title { font-size: 22px; }
  .accordion-001 { max-width: calc(100% - 32px); }
  .accordion-001 summary { padding: 28px 16px; font-size: clamp(19px, 4.5vw, 28px); line-height: 1.7; background-size: 100% 100%; }
  .accordion-open { padding: 16px; }
  .covid19-list { width: 48%; padding: 16px 0; }
  .covid19-list span { font-size: 15px; }
  .features-title, .medical-title { width: min(75%, 360px); }
  .w60, .feature-img, .feature-txt, .feature-txt-bg, .fbg-img-wrap { width: 90%; }
  .f-bgtxt, .greeting-txt-bg, .medical-title-ja { font-size: clamp(20px, 4.8vw, 28px); line-height: 1.7; }
  .f-txtbox p, .greeting-txt, .bgindex-txtbox p, .recruit-txt-sm p { font-size: 16px; line-height: 1.9; text-align: left; }
  .f02-wrap-title { width: 100%; padding: 12px; }
  .f02-wrap-title p { font-size: 17px; white-space: normal; }
  .ftxt-icon, .ftxt-icon-bg { width: 72px; top: -48px; }
  .feature-txt, .feature-txt-bg { padding-top: 48px; margin-top: 64px; }
  .feature-txt-bg { margin-bottom: 40px; }
  .detail-btn, .recruit-txt .detail-btn { width: min(100%, 280px); }
  .detail-btn a { font-size: 16px; }
  .doc-img-bg { display: none; }
  .doc-img, .doctor-inner-img { position: relative; width: min(100%, 380px); height: auto; margin: auto; }
  .doc-img img, .doctor-inner-img img { height: auto; }
  .doc-greeting-left, .doc-greeting-right { width: 90%; }
  .doc-name { width: min(90%, 280px); }
  .doc-name p { font-size: 23px; line-height: 1.4; }
  .doc-title { font-size: 16px; }
  .doc-name .en { font-size: 14px; }
  .greeting-title-ja { width: 90%; font-size: 24px; }
  .greeting-title-ja::after { width: auto; min-width: 0; flex: 1; }
  .clinic-img-wrap { width: 90%; flex-direction: column; gap: 16px; }
  .clinic-img-wrap img { width: 100%; }
  .medical-inner { width: 90%; gap: 24px; margin: 32px auto; }
  .medical-item { width: min(100%, 320px); }
  .medical-txt p { font-size: 16px; }
  .medical-bgindex { flex-direction: column; }
  .medical-bgindex-txt, .medical-bgindex-img { width: 100%; }
  .bgindex-title, .bgindex-title-ja { font-size: 27px; line-height: 1.6; letter-spacing: .08em; }
  .bgindex-title-en { font-size: clamp(26px, 7vw, 44px); letter-spacing: .08em; line-height: 1.6; }
  .bgindex-title-ja { margin-top: 0; }
  .bgindex-txtbox { width: 88%; }
  .consul-title p { font-size: clamp(21px, 5vw, 30px); }
  .consul-title::after { font-size: 25px; top: 100%; }
  .consul-box { width: 92%; padding: 32px 24px; outline-offset: -10px; }
  .consul-box p { font-size: 16px; line-height: 1.9; text-align: left; }
  .consul-box p br, .greeting-txt br, .recruit-txt-sm br { display: none; }
  .contact-link { width: 90%; flex-direction: column; gap: 16px; }
  .consul-telbnr, .consul-webbnr { width: 100%; }
  .recruit-inner { flex-direction: column; gap: 24px; width: 90%; }
  .recruit-img, .recruit-txt { width: 100%; height: auto; }
  .recruit-img img { position: static; transform: none; width: min(100%, 380px); display: block; margin: auto; }
  .recruit-title-ja { font-size: 27px; }
  .recruit-txt-sm { width: 100%; }

  .policy-tabimg { width: 90%; margin: 32px auto; }
  .policy-tabbox { padding: 20px 12px; }
  .policy-tabbox p { font-size: 20px; }
  .policy-tabbox p .bold { font-size: clamp(20px, 5vw, 27px); }
  .policy-index { padding: 32px 0; margin-top: 32px; }
  .policy-deco { display: none; }
  .policy-txt { position: static; transform: none; width: 90%; margin: auto; flex-direction: column; gap: 24px; }
  .policy-title { width: min(45%, 160px); margin: auto; }
  .policy-txtbox { width: 100%; margin: 0; }
  .policy-txtbox p { font-size: 16px; line-height: 1.9; text-align: left; }
  #intro { margin-top: 0; }
  .intro-main { width: 90%; }
  .doctor-inner { width: 90%; gap: 32px; }
  .doctor-inner-txt { width: 100%; }
  .doctor-inner-txt h2 { font-size: 25px; }
  .doctor-inner-txt p { font-size: 16px; text-align: left; line-height: 1.9; }
  .name-box { width: 100%; }
  .career { width: 90%; }
  .career-title { font-size: 23px; }
  .career-inner dl { font-size: 15px; align-items: stretch; }
  .career-inner dl dt { width: 28%; }
  .career-inner dl dd { width: 72%; margin-left: 0; padding-left: 12px; }
  .time-main-img, .main-timetabel, .access-memo-title, .access-memo-txt { width: 90%; }
  .time-logo { width: min(70%, 320px); }
  .time-adress, .main-timetabel-memo, .access-memo-txt p { font-size: 16px; }
  .access-memo-title p { font-size: 21px; }
  .med-inner, .mini-index { width: 90%; margin: 32px auto; }
  .med-inner { padding: 0; gap: 24px; }
  .med-inner-txt h2 { font-size: 26px; line-height: 1.5; }
  .med-inner-txt p, .topic-txt p { font-size: 16px; line-height: 1.9; text-align: left; }
  .med-inner-img { position: static; height: auto; width: 100%; }
  .med-img { position: static; width: 100%; }
  .inner-title p { font-size: 23px; }
  .meritdemerit { flex-direction: column; gap: 32px; padding: 0; }
  .merit, .demerit { width: 100%; }
  .merit ul li, .demerit ul li, .flow-txt, .implant-note ul li { font-size: 16px; }
  .flow-title { font-size: 21px; }
  .implant-flow dl { align-items: flex-start; }
  .implant-flow dl dt { width: 20%; }
  .implant-flow dl dd { width: 80%; margin-left: 0; padding-left: 12px; }
  .implant-note { width: 100%; padding: 24px 16px; }
  .implant-note p { font-size: 19px; }
  .implant-note ul { width: 100%; }
  .topic-title p { font-size: 23px; }
  .topic-txt { width: 100%; }
  .partnership-link { width: 100%; padding: 12px; }
  .partnership-link a { font-size: 18px; }
  .comingsoon { width: 85%; padding: 64px 0; }
  .contact-form { width: 90%; }
  .contact-table, .contact-table tbody, .contact-table tr, .contact-table th, .contact-table td { display: block; width: 100%; }
  .contact-form th, .contact-form td, .contact-form input, .contact-form select, .contact-form textarea { font-size: 16px; }
  .form-text, .form-textarea, .form-select { width: 100%; max-width: 100%; }
  .footer-index-left, .footer-index-right { width: 100%; }
  .footer-logo { width: min(85%, 320px); }
  .footer-adress { font-size: 16px; }
  .footer-tel { font-size: clamp(25px, 6vw, 34px); }
  .footer-webbnr { width: min(80%, 280px); }
  .footer-timetabel-memo { font-size: 14px; }
  #footer .footer-map-box.pc-only { display: block; }
  .footer-map-box { width: 90%; }
  .footer-map-box iframe { width: 100%; height: 280px; }
  .copy { font-size: 13px; }
  #page-top { bottom: 80px; }
  .sp-footer { position: fixed; inset: auto 0 0; z-index: 999; width: 100%; background: #fff; padding-bottom: env(safe-area-inset-bottom); }
  .sp-footer ul { display: flex; flex-wrap: nowrap; width: 100%; padding: 0; }
  .spf-tel, .spf-web { width: 40%; }
  .spf-top { width: 20%; }
  .sp-footer a { display: flex; height: 56px; align-items: center; justify-content: center; }
  .sp-footer img { width: 100%; max-height: 56px; object-fit: contain; }
  /* Avoid blank content when an animation/CDN fails on a mobile connection. */
  .fadeUpTrigger, .fadeDownTrigger, .fadeLeftTrigger, .fadeRightTrigger, .delayScroll > *, .box { opacity: 1; animation: none; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  #g-nav, .openbtn span { transition: none; }
}

/* Greeting follow-up: keep the photograph and caption in normal document flow. */
@media (max-width: 768px) {
  #greeting .doc-greeting { gap: 32px; }
  #greeting .greeting-txt-bg { width: 100%; margin: 24px auto; font-size: clamp(16px, 4.2vw, 20px); line-height: 1.9; text-align: center; letter-spacing: 0; }
  #greeting .greeting-txt-bg br { display: none; }
  #greeting .greeting-phrase { display: inline-block; white-space: nowrap; max-width: 100%; }
  #greeting .doc-greeting-left { display: flex; flex-direction: column; align-items: center; gap: 0; }
  #greeting .doc-img { position: static; inset: auto; transform: none; width: 100%; max-width: 380px; margin: 0 auto; }
  #greeting .doc-img img { display: block; width: 100%; max-width: 100%; height: auto; }
  #greeting .doc-name { position: static; inset: auto; transform: none; width: 100%; max-width: 380px; margin: 0 auto; padding: 20px 16px; background: #0d8672; }
  #greeting .doc-name p { margin: 0; font-size: 23px; line-height: 1.6; }
  #greeting .doc-title { font-size: 16px; margin-right: 12px; }
  #greeting .doc-name .en { font-size: 14px; }
  #greeting .docpage-link { width: min(100%, 240px); margin: 16px auto 0; }
  #greeting .docpage-link img { display: block; width: 100%; height: auto; }
}

/* Keep the desktop navigation white, including WordPress visited-link styling. */
.g-nav nav a,
.g-nav nav a:link,
.g-nav nav a:visited,
.g-nav nav a:hover,
.g-nav nav a:focus,
.g-nav nav a:active,
.g-nav nav a span { color: #fff !important; }

/* The base theme's ul margin reset is !important, so explicitly override it here. */
@media (min-width: 769px) {
  #greeting .clinic-img-wrap {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    width: 90%;
    max-width: 1440px;
    gap: clamp(16px, 2vw, 30px);
    margin: 100px auto 0 !important;
    padding: 0;
    list-style: none;
  }
  #greeting .clinic-img-wrap > li { width: 100%; min-width: 0; margin: 0; padding: 0; }
  #greeting .clinic-img-wrap img { display: block; width: 100%; height: auto; }
}

/* Shared HTML timetable: top page, access page, and footer. */
.clinic-hours {
  width: 100%; max-width: 100%; table-layout: fixed; border-collapse: collapse;
  margin: 0; border: 0; color: #555; font-family: "Hiragino Sans", Meiryo, sans-serif;
  font-size: clamp(14px, 1.35vw, 20px); line-height: 1.5; background: transparent;
}
.clinic-hours caption { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.clinic-hours th, .clinic-hours td { text-align: center; vertical-align: middle; border: 0; padding: 16px 0; font-weight: 400; background: transparent; letter-spacing: 0; white-space: nowrap; }
.clinic-hours th:first-child { width: 31%; }
.clinic-hours thead { border-top: 1px solid currentColor; border-bottom: 1px solid currentColor; }
.clinic-hours thead th { padding-top: 24px; padding-bottom: 24px; }
.clinic-hours tbody { border-bottom: 1px solid currentColor; }
.clinic-hours tbody tr:first-child th, .clinic-hours tbody tr:first-child td { padding-top: 24px; padding-bottom: 8px; }
.clinic-hours tbody tr:last-child th, .clinic-hours tbody tr:last-child td { padding-top: 8px; padding-bottom: 24px; }
.clinic-hours .hours-open, .clinic-hours .hours-closed { color: #77b04c; font-size: 1.12em; }
#footer .clinic-hours, .footer-timetabel .clinic-hours { color: #fff; }
#footer .clinic-hours .hours-open, #footer .clinic-hours .hours-closed,
.footer-timetabel .clinic-hours .hours-open, .footer-timetabel .clinic-hours .hours-closed { color: #fff; }
@media (max-width: 768px) {
  .clinic-hours { font-size: clamp(12px, 3.2vw, 18px); }
  .clinic-hours thead th { padding-top: 18px; padding-bottom: 18px; }
  .clinic-hours th:first-child { width: 33%; }
  .clinic-hours tbody tr:first-child th, .clinic-hours tbody tr:first-child td { padding-top: 18px; padding-bottom: 6px; }
  .clinic-hours tbody tr:last-child th, .clinic-hours tbody tr:last-child td { padding-top: 6px; padding-bottom: 18px; }
}

/* Real text links replace the image buttons, with a shared size. */
#clinic-link .clinic-link-bnr, #greeting .docpage-link { width: 240px; max-width: 100%; }
#clinic-link .clinic-link-bnr { margin: 32px auto; }
#greeting .docpage-link { margin: 16px auto 0; }
.clinic-text-button, .clinic-text-button:link, .clinic-text-button:visited {
  display: flex; align-items: center; justify-content: center; gap: 20px;
  box-sizing: border-box; width: 100%; min-height: 60px; padding: 12px 20px;
  border: 1px solid #333; background: #fff; color: #333 !important;
  font-family: "Yu Mincho", YuMincho, serif; font-size: 24px; line-height: 1.4;
  text-decoration: none; letter-spacing: .08em;
}
.clinic-text-button:hover { background: #edf5ec; }
.clinic-text-button:focus-visible { outline: 3px solid #0d8672; outline-offset: 3px; }
.clinic-text-button .button-arrow { font-family: sans-serif; font-size: 20px; }
@media (max-width: 768px) {
  /* Keep one page-top action on mobile: the right-hand fixed button. */
  #page-top { display: none !important; }
  body { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
  #footer .sp-footer { position: fixed; bottom: 0; left: 0; right: 0; width: 100%; padding: 0 0 env(safe-area-inset-bottom); background: #fff; border-top: 1px solid #ddd; box-shadow: 0 -2px 8px #00000012; }
  #footer .sp-footer ul { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 64px; width: 100%; gap: 0; padding: 0; margin: 0 !important; }
  #footer .sp-footer li { width: auto; min-width: 0; margin: 0; padding: 0; }
  #footer .sp-footer a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; height: 72px; width: 100%; padding: 8px 4px; box-sizing: border-box; font-family: sans-serif; font-weight: 500; line-height: 1.5; letter-spacing: 0; text-align: center; text-decoration: none; white-space: nowrap; }
  #footer .spf-tel a, #footer .spf-tel a:visited { background: #70695f; color: #fff; }
  #footer .spf-web a, #footer .spf-web a:visited { background: #3b837e; color: #fff; }
  #footer .spf-top a, #footer .spf-top a:visited { background: #fff; color: #333; border-left: 1px solid #ddd; }
  #footer .sp-footer .floating-label { font-size: clamp(10px, 2.8vw, 13px); }
  #footer .sp-footer .floating-detail { font-size: clamp(10px, 2.9vw, 14px); }
  #footer .sp-footer .floating-top-arrow { font-size: 23px; line-height: 1; }
  #footer .sp-footer .floating-top-label { font-size: 11px; }
  #footer .sp-footer a:focus-visible { outline: 3px solid #e4ec12; outline-offset: -4px; }
}

/* Doctor profile: balanced name card and a stable date/description layout. */
#doctor .doctor-inner-txt .name-box {
  box-sizing: border-box; width: 100%; max-width: 360px;
  margin: 28px auto; padding: 24px 20px; background: #0d8672;
}
#doctor .doctor-inner-txt .name-box p {
  margin: 0 !important; padding: 0; color: #fff; text-align: center;
  font-size: 24px; line-height: 1.6; letter-spacing: .04em;
}
#doctor .name-box p > span:first-child { display: block; margin-bottom: 8px; font-size: 16px; line-height: 1.5; letter-spacing: .06em; }
#doctor .name-box p > span:nth-of-type(2) { font-size: 16px; }
#doctor .name-box p > br { display: none; }
#doctor .career { box-sizing: border-box; padding: 40px 0; }
#doctor .career-inner { width: 90%; }
#doctor .career-title { margin: 0 0 20px !important; }
#doctor .career-inner dl {
  display: grid; grid-template-columns: 150px minmax(0, 1fr);
  align-items: stretch; width: 100%; margin: 0; padding: 0; gap: 0;
  font-size: 16px; line-height: 1.8;
}
#doctor .career-inner dl dt, #doctor .career-inner dl dd {
  box-sizing: border-box; width: auto; min-width: 0; margin: 0;
  padding: 16px 12px; border: 0; border-bottom: 1px solid #ccd7d5;
}
#doctor .career-inner dl dt { font-weight: 600; white-space: nowrap; }
#doctor .career-inner dl dd { overflow-wrap: anywhere; }
@media (max-width: 599px) {
  #doctor .doctor-inner-txt .name-box { padding: 24px 16px; }
  #doctor .career { width: 90%; padding: 28px 0; }
  #doctor .career-inner dl { grid-template-columns: minmax(0, 1fr); font-size: 15px; }
  #doctor .career-inner dl dt { padding: 18px 0 4px; border-bottom: 0; }
  #doctor .career-inner dl dd { padding: 0 0 18px; }
  #doctor .career-inner dl dt:first-child { padding-top: 0; }
}

/* Header contact information as scalable text instead of bitmap banners. */
@media (min-width: 769px) {
  #header .head-top { align-items: flex-start; gap: 24px; }
  #header .head-left { flex: 0 0 auto; width: clamp(200px, 20vw, 280px); }
  #header .head-right { display: flex; align-items: stretch; flex: 0 0 auto; width: auto; max-width: none; gap: 8px; margin-top: 12px; }
  #header .header-contact-info { box-sizing: border-box; width: 310px; padding: 14px 16px; background: #655f55; color: #fff; }
  #header .header-phone-link, #header .header-phone-link:link, #header .header-phone-link:visited { display: block; color: #fff; font-size: 30px; font-family: Georgia, "Times New Roman", serif; line-height: 1.3; white-space: nowrap; letter-spacing: 0; text-decoration: none; }
  #header .header-phone-prefix { font-size: 19px; margin-right: 4px; }
  #header .header-clinic-hours, #header .header-clinic-closed { margin: 8px 0 0 !important; padding: 0; color: #fff; font: 400 14px/1.65 "Hiragino Sans", Meiryo, sans-serif; letter-spacing: 0; }
  #header .header-clinic-hours { padding-top: 8px; border-top: 1px solid #ffffff88; }
  #header .head-webbnr { width: 160px; }
  #header .header-contact-link, #header .header-contact-link:link, #header .header-contact-link:visited { display: flex; flex-direction: column; align-items: center; justify-content: center; box-sizing: border-box; height: 100%; min-height: 140px; padding: 16px 12px; background: #3b837e; color: #fff; border: 1px solid #fff; outline: 5px solid #3b837e; outline-offset: -6px; font: 500 19px/1.6 "Hiragino Sans", Meiryo, sans-serif; text-align: center; letter-spacing: .04em; text-decoration: none; }
  #header .header-contact-arrow { margin-top: 4px; font-size: 22px; line-height: 1; }
  #header .header-contact-link:hover { background: #2c6d68; }
  #header .header-phone-link:focus-visible, #header .header-contact-link:focus-visible { outline: 3px solid #e4ec12; outline-offset: 2px; }
}
@media (min-width: 769px) and (max-width: 1100px) {
  #header .head-top { gap: 16px; }
  #header .header-contact-info { width: 270px; padding: 12px; }
  #header .header-phone-link { font-size: 27px; }
  #header .head-webbnr { width: 136px; }
  #header .header-contact-link { font-size: 17px; }
}

/* Compact header contact panel without reducing the 14px supporting text. */
@media (min-width: 769px) {
  #header .head-right { margin-top: 8px; }
  #header .header-contact-info { padding: 10px 16px; }
  #header .header-phone-link { font-size: 28px; line-height: 1.2; }
  #header .header-clinic-hours, #header .header-clinic-closed { margin-top: 5px !important; line-height: 1.5; }
  #header .header-clinic-hours { padding-top: 5px; }
  #header .header-clinic-closed br { display: none; }
  #header .header-contact-link { min-height: 0; padding: 10px 12px; font-size: 18px; line-height: 1.4; }
  #header .header-contact-arrow { margin-top: 2px; font-size: 18px; }
}
@media (min-width: 769px) and (max-width: 1100px) {
  #header .header-contact-info { padding: 10px 12px; }
  #header .header-phone-link { font-size: 27px; }
  #header .header-contact-link { font-size: 17px; }
}

/* Further reduce the header panel's height, keeping supporting text at 14px. */
@media (min-width: 769px) {
  #header .header-contact-info { padding: 6px 12px; }
  #header .header-phone-link { font-size: 27px; line-height: 1.1; }
  #header .header-clinic-hours, #header .header-clinic-closed { margin-top: 3px !important; line-height: 1.35; }
  #header .header-clinic-hours { padding-top: 3px; }
  #header .header-contact-link { padding: 6px 10px; font-size: 17px; line-height: 1.25; }
  #header .header-contact-arrow { margin-top: 0; font-size: 16px; }
}

/* Override the original :link/:visited rules at matching specificity. */
@media (min-width: 769px) {
  #header .head-right .header-contact-link {
    min-height: 0; height: auto; padding: 6px 10px;
    font-size: 17px; line-height: 1.25;
  }
  #header .head-right .head-webbnr { display: flex; }
  #header .head-right .head-webbnr > a { flex: 1; }
  #header .head-right .header-phone-link { font-size: 27px; line-height: 1.1; }
}

/* Layout audit follow-up: remove inherited WP spacing and repeated titles. */
body.page-id-12 .site-main > article > .entry-header { display: none; }
body.page-id-12 .site-main > article > .entry-content { margin-top: 0; }
body.page-id-12 .entry-content > p:empty,
body.page-id-12 .entry-content > main > p:empty { display: none; }
#doctor .name-box p > span { text-align: center; }
.implant-flow dl {
  display: grid; grid-template-columns: 80px minmax(0, 1fr);
  width: 100%; align-items: stretch; gap: 0;
}
.implant-flow dl dt, .implant-flow dl dd {
  box-sizing: border-box; width: auto; min-width: 0; margin: 0;
  padding: 24px 0; border: 0; border-bottom: 1px solid #ccc;
}
.implant-flow dl dt img { width: 56px; max-width: 100%; display: block; }
.implant-flow dl dd { padding-left: 16px; }
.implant-flow .flow-title { line-height: 1.6; }
.implant-flow .flow-txt { line-height: 1.9; }
.contact-link { align-items: stretch; gap: 16px; }
.contact-link > div { min-width: 0; }
.contact-link .consul-telbnr, .contact-link .consul-webbnr { flex: 1; }
.consultation-phone-text, .consultation-phone-text:link, .consultation-phone-text:visited {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  box-sizing: border-box; width: 100%; min-height: 88px; padding: 12px;
  color: #fff; background: #70695f; text-decoration: none; font-family: sans-serif;
}
.consultation-phone-text span { font-size: 14px; line-height: 1.5; }
.consultation-phone-text strong { font-size: clamp(23px, 2.2vw, 30px); line-height: 1.5; font-weight: 500; white-space: nowrap; }
.contact-link .consultation-contact-text { min-height: 88px; height: 100%; font-size: 20px; }
#footer .footer-webbnr { width: 240px; max-width: 100%; }
#footer .footer-contact-text { font-size: 20px; }
@media (max-width: 768px) {
  .implant-flow dl { grid-template-columns: 50px minmax(0, 1fr); }
  .implant-flow dl dt, .implant-flow dl dd { width: auto; margin: 0; padding-top: 20px; padding-bottom: 20px; }
  .implant-flow dl dt img { width: 40px; }
  .implant-flow dl dd { padding-left: 12px; }
  .implant-flow .flow-title { font-size: 19px; }
  .inner-title { padding: 12px; }
  .inner-title p { font-size: clamp(18px, 4.8vw, 22px); line-height: 1.6; text-wrap: balance; }
  #doctor .doctor-inner-txt h2 { font-size: clamp(18px, 4.8vw, 23px); line-height: 1.7; }
  #doctor .doctor-heading-phrase { display: inline-block; }
  #doctor .doctor-inner-txt h2 br { display: none; }
  .contact-link .consul-telbnr, .contact-link .consul-webbnr { flex: auto; width: 100%; }
  .contact-link .consultation-contact-text { min-height: 60px; height: auto; }
}

/* Button design system, based on the original theme's image assets. */
body .clinic-text-button {
  position: relative; isolation: isolate; overflow: hidden; box-sizing: border-box;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; width: 100%; min-height: 80px; padding: 14px 24px;
  border: 1px solid #333; border-radius: 0; background: #fff;
  font-family: "Yu Mincho", YuMincho, serif; font-size: 24px; line-height: 1.4;
  letter-spacing: .08em; text-align: center; text-decoration: none;
}
body .clinic-text-button::after {
  content: ''; position: absolute; right: 0; bottom: 0; width: 0; height: 0;
  border-bottom: 24px solid #333; border-left: 24px solid transparent; pointer-events: none;
}
body .clinic-text-button .button-title { display: block; }
body .clinic-text-button .button-subtitle { color: #77b04c; font: 600 17px/1.3 Georgia, serif; letter-spacing: .04em; }
body .clinic-text-button .button-arrow { display: none; }
body .clinic-text-button:hover { background: #f4f7f1; }
body .clinic-text-button[href="/contact/"],
body .clinic-text-button[href="/contact/"]:link,
body .clinic-text-button[href="/contact/"]:visited {
  border: 0; background: #447d77; color: #fff !important;
  font-family: "Hiragino Sans", Meiryo, sans-serif;
  font-size: 18px; letter-spacing: .03em;
}
body .clinic-text-button[href="/contact/"]::before {
  content: ''; position: absolute; inset: 7px; border: 1px solid #fff;
  pointer-events: none;
}
body .clinic-text-button[href="/contact/"]::after {
  right: 7px; bottom: 7px; border-bottom-color: #fff;
}
body .clinic-text-button[href="/contact/"]:hover { background: #366c68; }
body .contact-link .clinic-text-button { min-height: 80px; }
body .consultation-phone-text, body .consultation-phone-text:link, body .consultation-phone-text:visited {
  position: relative; min-height: 80px; background: #70695f; color: #fff;
}
body .consultation-phone-text::before { content: ''; position: absolute; inset: 7px; border: 1px solid #ffffff99; pointer-events: none; }
#footer .footer-contact-text { font-size: 18px; }
@media (min-width: 769px) {
  #header .head-right .header-contact-link {
    position: relative; isolation: isolate; overflow: hidden; border: 0; outline: 0;
    background: #447d77; padding: 10px 14px; font-size: 17px;
  }
  #header .head-right .header-contact-link::before { content: ''; position: absolute; inset: 7px; border: 1px solid #fff; pointer-events: none; }
  #header .head-right .header-contact-link::after { content: ''; position: absolute; right: 7px; bottom: 7px; border-bottom: 18px solid #fff; border-left: 18px solid transparent; pointer-events: none; }
  #header .head-right .header-contact-arrow { display: none; }
}
@media (max-width: 768px) {
  #footer .sp-footer .spf-web a { position: relative; background: #447d77; }
  #footer .sp-footer .spf-tel a { position: relative; background: #70695f; }
  #footer .sp-footer .spf-tel a::before,
  #footer .sp-footer .spf-web a::before { content: ''; position: absolute; inset: 5px; border: 1px solid #ffffff99; pointer-events: none; }
  #footer .sp-footer .spf-top a { border: 1px solid #bbb; }
  body .clinic-text-button { padding: 14px 20px; font-size: 23px; }
  body .clinic-text-button[href="/contact/"] { font-size: 17px; }
}
/* Existing text CTAs use the same white panel and dark corner treatment. */
.detail-btn, .recruit-txt .detail-btn, .medical-bgindex-txt .detail-btn, .partnership-link {
  position: relative; border: 1px solid #333; border-radius: 0; background: #fff;
}
.detail-btn::after, .partnership-link::after { content: ''; position: absolute; right: 0; bottom: 0; border-bottom: 18px solid #333; border-left: 18px solid transparent; pointer-events: none; }
.detail-btn a, .detail-btn a:visited, .medical-bgindex-txt .detail-btn a, .medical-bgindex-txt .detail-btn:hover a, .partnership-link a { color: #333; }
.detail-btn:hover, .recruit-txt .detail-btn:hover, .medical-bgindex-txt .detail-btn:hover, .partnership-link:hover { background: #f4f7f1; }

/* WordPress news: latest posts on the homepage and a dedicated detail page. */
.news .news-inner { box-sizing: border-box; padding-right: 12px; }
.news .news-box { margin: 0; padding: 16px 0; border-bottom: 1px solid #ddd; }
.news .news-box time { display: block; margin-bottom: 6px; font: 400 15px/1.5 sans-serif; color: #555; }
.news .news-list-title { margin: 0; font: 500 18px/1.7 "Hiragino Sans", Meiryo, sans-serif; overflow-wrap: anywhere; }
.news .news-list-title a, .news .news-list-title a:visited { display: block; color: #333; text-decoration: none; }
.news .news-list-title a:hover { color: #0d7464; text-decoration: underline; }
.news .news-list-title a:focus-visible { outline: 2px solid #0d7464; outline-offset: 3px; }
.news .news-empty { margin: 16px 0 !important; font: 400 16px/1.8 sans-serif; }
#news { scroll-margin-top: 110px; }
.news-detail-container { box-sizing: border-box; width: 90%; max-width: 1000px; margin: 64px auto; }
.news-post-header { padding-bottom: 24px; border-bottom: 2px solid #77b04c; margin-bottom: 32px; }
.news-post-header time { font: 400 16px/1.6 sans-serif; color: #666; }
.news-post-title { font-size: clamp(24px, 3vw, 34px); line-height: 1.6; margin: 12px 0 0; overflow-wrap: anywhere; }
.news-post-thumbnail { max-width: 760px; margin: 0 auto 32px; }
.news-post-thumbnail img { display: block; width: auto; max-width: 100%; height: auto; margin: auto; }
.news-post-content { font: 400 16px/1.9 "Hiragino Sans", Meiryo, sans-serif; overflow-wrap: anywhere; }
.news-post-content p { margin: 0 0 1.5em !important; }
.news-post-content h2, .news-post-content h3, .news-post-content h4 { line-height: 1.6; margin: 1.5em 0 .7em; }
.news-post-content h2 { font-size: 25px; }
.news-post-content h3 { font-size: 21px; }
.news-post-content h4 { font-size: 18px; }
.news-post-content ul, .news-post-content ol { padding-left: 1.5em; margin: 0 0 1.5em !important; }
.news-post-content ul li { list-style: disc; }
.news-post-content ol li { list-style: decimal; }
.news-post-content img, .news-post-content video { max-width: 100%; height: auto; }
.news-post-content figure, .news-post-content .wp-caption, .news-post-content .alignwide, .news-post-content .alignfull { max-width: 100%; margin-left: 0; margin-right: 0; }
.news-post-content iframe { max-width: 100%; }
.news-post-content .wp-block-embed iframe { width: 100%; aspect-ratio: 16 / 9; height: auto; }
.news-post-content table { display: block; max-width: 100%; overflow-x: auto; }
.news-post-content pre { white-space: pre-wrap; overflow-wrap: anywhere; }
.news-post-content blockquote { margin: 24px 0; padding: 16px 20px; border-left: 4px solid #77b04c; background: #f3f6ef; }
.news-post-navigation { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; margin-top: 40px; padding-top: 24px; border-top: 1px solid #ddd; }
.news-post-navigation a, .news-post-navigation a:visited { display: block; color: #333; font: 400 15px/1.7 sans-serif; overflow-wrap: anywhere; }
.news-post-navigation strong { display: block; margin-top: 6px; font-weight: 500; }
.news-post-navigation > div:last-child { text-align: right; }
.news-back { width: min(100%, 320px); margin: 40px auto 0; }
body .news-back .clinic-text-button { font-size: 18px; }
.news-content-pages { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
@media (max-width: 768px) {
  .news .news-list-title { font-size: 16px; }
  .news-detail-container { width: 90%; margin: 32px auto 48px; }
  .news-post-header { padding-bottom: 20px; margin-bottom: 24px; }
  .news-post-title { font-size: 24px; }
  .news-post-navigation { gap: 16px; }
}
