/*
Theme Name: RWN Native
Theme URI: https://www.rwn.com.tw/
Description: 創意數位科技為 rwn.com.tw 手刻的輕量原生佈景（乾淨醫療風）。取代 Soledad + Elementor，保留文章與診所目錄，主打效能與在地 SEO。
Author: 創意數位科技
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: rwn-native
*/

:root {
  --brand:        #0a7ea4;
  --brand-dark:   #075c78;
  --accent:       #d32f2f;
  --ink:          #1a2b33;
  --muted:        #5b6b73;
  --line:         #e6edf0;
  --bg:           #ffffff;
  --bg-soft:      #f5f8fa;
  --radius:       14px;
  --maxw:         1080px;
  --maxw-read:    720px;
  --font: -apple-system, BlinkMacSystemFont, "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
  font-size: 17px;
}

img { max-width: 100%; height: auto; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 1rem; }
.container--read { max-width: var(--maxw-read); }

/* Skip link */
.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 1rem; top: 1rem; background: #fff; padding: .5rem 1rem; z-index: 1000; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.95);
  backdrop-filter: saturate(1.2) blur(6px);
  border-bottom: 1px solid var(--line);
}
.site-header__bar { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.site-logo { font-size: 1.25rem; font-weight: 800; color: var(--ink); letter-spacing: .02em; }
.site-logo:hover { text-decoration: none; color: var(--brand); }
.main-nav > div > ul, .main-nav > ul { display: flex; gap: 1.1rem; list-style: none; margin: 0; padding: 0; }
.main-nav li { position: relative; }
.main-nav a { color: var(--ink); font-weight: 600; font-size: .96rem; display: block; padding: .35rem 0; }
.main-nav a:hover { color: var(--brand); text-decoration: none; }
.main-nav .menu-item-has-children > a::after { content: "▾"; font-size: .75em; color: var(--muted); margin-left: .25em; }

/* 下拉子選單 */
.main-nav .sub-menu {
  position: absolute; top: 100%; left: 0; min-width: 180px;
  list-style: none; margin: 0; padding: .4rem 0;
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
  box-shadow: 0 10px 28px rgba(0,0,0,.10); z-index: 200;
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: .15s;
}
.main-nav li:hover > .sub-menu, .main-nav li:focus-within > .sub-menu {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.main-nav .sub-menu a { padding: .5rem 1rem; white-space: nowrap; font-weight: 500; }
.main-nav .sub-menu a:hover { background: var(--bg-soft); color: var(--brand); }
.nav-toggle { display: none; background: none; border: 0; font-size: 1.5rem; cursor: pointer; color: var(--ink); }

/* 雲端燈號 mega 雙欄下拉 */
.main-nav .mega-clinic { position: relative; }
.main-nav .mega-clinic > a::after { content: "▾"; font-size: .75em; color: var(--muted); margin-left: .25em; }
.mega-panel {
  position: absolute; top: 100%; right: 0; width: min(540px, 92vw);
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 12px 32px rgba(0,0,0,.12); padding: 1.2rem 1.4rem; z-index: 200;
  display: grid; grid-template-columns: 1fr 1.5fr; gap: .5rem 1.6rem;
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: .15s;
}
.main-nav .mega-clinic:hover > .mega-panel,
.main-nav .mega-clinic:focus-within > .mega-panel { opacity: 1; visibility: visible; transform: translateY(0); }
.mega-col__head { display: block; font-weight: 800; color: var(--brand-dark); font-size: .85rem; margin-bottom: .5rem; padding-bottom: .35rem; border-bottom: 2px solid var(--brand); }
.mega-col ul { list-style: none; margin: 0; padding: 0; }
.mega-col a { display: block; padding: .28rem .2rem; font-size: .9rem; color: var(--ink); font-weight: 500; }
.mega-col a:hover { color: var(--brand); text-decoration: none; }
.mega-col--areas ul { columns: 2; column-gap: 1rem; }
.mega-all { grid-column: 1 / -1; text-align: center; font-weight: 700; color: #fff; background: var(--brand); padding: .55rem; border-radius: 8px; margin-top: .4rem; }
.mega-all:hover { background: var(--brand-dark); color: #fff; text-decoration: none; }

/* Layout */
.site-main { padding: 2rem 0 3rem; }
.page-title { font-size: 1.9rem; line-height: 1.3; margin: 0 0 1.5rem; }

/* Cards grid (post/clinic listing) */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.25rem; }
.card {
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  background: var(--bg); transition: box-shadow .15s, transform .15s;
}
.card:hover { box-shadow: 0 6px 20px rgba(10,126,164,.10); transform: translateY(-2px); }
.card__thumb { display: block; aspect-ratio: 16/10; background: var(--bg-soft); overflow: hidden; }
.card__thumb img { width: 100%; height: 100%; object-fit: cover; }
.card__body { padding: 1rem 1.1rem 1.2rem; }
.card__title { font-size: 1.05rem; font-weight: 700; margin: 0 0 .4rem; line-height: 1.45; }
.card__title a { color: var(--ink); }
.card__title a:hover { color: var(--brand); }
.card__meta { font-size: .82rem; color: var(--muted); }

/* Single article */
.entry__header { margin-bottom: 1.25rem; }
.entry__cats { margin-bottom: .6rem; }
.entry__cats a { display: inline-block; font-size: .8rem; font-weight: 700; color: var(--brand-dark); background: var(--bg-soft); padding: .2rem .7rem; border-radius: 100px; }
.entry__cats a:hover { background: #e3eef3; text-decoration: none; }
.entry__title { font-size: 2.1rem; line-height: 1.35; margin: 0 0 .7rem; letter-spacing: -.01em; }
.entry__meta { color: var(--muted); font-size: .9rem; }

.entry__featured { margin: 0 0 1.75rem; }
.entry__featured img { width: 100%; border-radius: var(--radius); display: block; }

/* Reading typography */
.entry__content { font-size: 1.1rem; line-height: 1.85; }
.entry__content > p { margin: 0 0 1.4rem; }
.entry__content a { text-decoration: underline; text-underline-offset: 2px; text-decoration-thickness: 1px; }
.entry__content strong { color: var(--ink); font-weight: 700; }

.entry__content h2,
.entry__content h3,
.entry__content h4 { scroll-margin-top: 80px; line-height: 1.4; }
.entry__content h2 {
  font-size: 1.55rem; margin: 2.4rem 0 1rem; padding-left: .7rem;
  border-left: 5px solid var(--brand); font-weight: 800;
}
.entry__content h3 { font-size: 1.28rem; margin: 1.9rem 0 .7rem; font-weight: 700; color: var(--brand-dark); }
.entry__content h4 { font-size: 1.1rem; margin: 1.5rem 0 .6rem; font-weight: 700; }

.entry__content img { max-width: 100%; height: auto; border-radius: 12px; }
/* 舊 [caption] 會寫死 style="width:800px"，用 !important 蓋掉避免溢出側欄 */
.entry__content figure,
.entry__content .wp-caption { width: auto !important; max-width: 100% !important; margin: 1.75rem auto; text-align: center; }
.entry__content figure img,
.entry__content .wp-caption img { display: inline-block; max-width: 100%; height: auto; }
.entry__content .alignnone,
.entry__content .aligncenter,
.entry__content .alignleft,
.entry__content .alignright,
.entry__content .alignwide,
.entry__content .alignfull { max-width: 100% !important; }
.entry__content figcaption,
.entry__content .wp-caption-text { font-size: .85rem; color: var(--muted); margin-top: .5rem; }

.entry__content ul, .entry__content ol { margin: 0 0 1.4rem; padding-left: 1.4rem; }
.entry__content li { margin: .35rem 0; }

.entry__content blockquote {
  margin: 1.75rem 0; padding: .8rem 1.2rem; border-left: 4px solid var(--brand);
  background: var(--bg-soft); border-radius: 0 10px 10px 0; color: var(--ink);
}
.entry__content blockquote p:last-child { margin-bottom: 0; }

.entry__content hr { border: 0; border-top: 1px solid var(--line); margin: 2.5rem 0; }

.entry__content table { width: 100%; border-collapse: collapse; margin: 1.5rem 0; font-size: .98rem; }
.entry__content th, .entry__content td { border: 1px solid var(--line); padding: .6rem .8rem; text-align: left; }
.entry__content th { background: var(--bg-soft); }

/* 原生文章目錄 (TOC) */
html { scroll-behavior: smooth; }
.rwn-toc {
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1rem 1.25rem; margin: 1.75rem 0; font-size: .96rem;
}
.rwn-toc__head { font-weight: 800; color: var(--brand-dark); margin: 0 0 .5rem; }
.rwn-toc ul { list-style: none; margin: 0; padding: 0; }
.rwn-toc li { margin: .3rem 0; }
.rwn-toc a { color: var(--ink); }
.rwn-toc a:hover { color: var(--brand); }
.rwn-toc__sub { padding-left: 1.2rem; font-size: .92rem; }
.rwn-toc__sub a { color: var(--muted); }

/* Tags + footer */
.entry__footer { margin-top: 2rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.entry__tags { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; margin: 0; padding: 0; }
.entry__tags li a { font-size: .82rem; color: var(--muted); background: var(--bg-soft); padding: .25rem .75rem; border-radius: 100px; }
.entry__tags li a:hover { color: var(--brand); text-decoration: none; }

/* Clinic single */
.clinic-hero { text-align: center; padding: 1rem 0 1.5rem; border-bottom: 1px solid var(--line); margin-bottom: 1.5rem; }
.clinic-hero__name { font-size: 1.8rem; font-weight: 800; margin: 0 0 .3rem; }
.clinic-hero__tag { color: var(--muted); font-size: 1rem; }
.clinic-info { display: grid; gap: .75rem; max-width: var(--maxw-read); margin: 1.5rem auto; }
.clinic-info__row { display: flex; gap: .6rem; align-items: baseline; padding: .9rem 1.1rem; background: var(--bg-soft); border-radius: var(--radius); }
.clinic-info__label { flex: 0 0 4.5em; font-weight: 700; color: var(--brand-dark); }
.clinic-info__value { font-size: 1.1rem; }
.clinic-info__value a { font-weight: 700; }
.clinic-note { max-width: var(--maxw-read); margin: 1rem auto; padding: .8rem 1rem; border-left: 4px solid var(--accent); background: #fff5f5; color: #8a1f1f; font-size: .92rem; border-radius: 0 8px 8px 0; }

/* 今日看診摘要 */
.clinic-today { max-width: var(--maxw-read); margin: 1rem auto; display: flex; align-items: center; gap: .55rem; padding: .7rem 1rem; border-radius: 10px; font-size: .95rem; }
.clinic-today.is-open { background: #eafaf1; color: #1b7a44; border: 1px solid #c3ecd3; }
.clinic-today.is-closed { background: var(--bg-soft); color: var(--muted); border: 1px solid var(--line); }
.clinic-today strong { font-weight: 800; }
.clinic-today__off { font-size: .85em; opacity: .8; }
.clinic-today__dot { flex: none; width: 9px; height: 9px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 4px rgba(35,178,109,.18); }
.clinic-today.is-closed .clinic-today__dot { box-shadow: none; }

/* 常見問題 FAQ */
.clinic-faq { max-width: var(--maxw-read); margin: 2.25rem auto 0; }
.clinic-faq__title { font-size: 1.2rem; margin: 0 0 .8rem; }
.clinic-faq__item { border: 1px solid var(--line); border-radius: 10px; padding: .3rem .9rem; margin-bottom: .6rem; background: #fff; }
.clinic-faq__item summary { cursor: pointer; font-weight: 700; color: var(--brand-dark); padding: .55rem 0; list-style-position: inside; }
.clinic-faq__item[open] summary { border-bottom: 1px solid var(--line); margin-bottom: .5rem; }
.clinic-faq__item p { margin: 0 0 .6rem; color: var(--ink); font-size: .95rem; line-height: 1.75; }

/* 附近同科別診所 */
.clinic-nearby { max-width: var(--maxw-read); margin: 2.25rem auto 0; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.clinic-nearby__title { font-size: 1.2rem; margin: 0 0 .35rem; }
.clinic-nearby__lead { font-size: .9rem; color: var(--muted); margin: 0 0 1rem; }

/* 看診時段表 */
.clinic-hours { max-width: var(--maxw-read); margin: 1.75rem auto 0; }
.clinic-hours__title { font-size: 1.2rem; margin: 0 0 .75rem; }
.clinic-hours__table { width: 100%; border-collapse: collapse; text-align: center; font-size: .95rem; }
.clinic-hours__table th, .clinic-hours__table td { border: 1px solid var(--line); padding: .5rem; }
.clinic-hours__table thead th { background: var(--bg-soft); font-weight: 700; }
.clinic-hours__table tbody th { background: var(--bg-soft); font-weight: 700; width: 3.5em; }
.clinic-hours__table .is-on { color: #2e7d32; font-weight: 700; }
.clinic-hours__table .is-off { color: var(--muted); }
.clinic-hours__table .is-na { color: #ccc; }
.clinic-hours__src { font-size: .78rem; color: var(--muted); margin: .6rem 0 0; }

/* Ad slots */
.ad-slot { margin: 1.5rem auto; min-height: 90px; display: flex; align-items: center; justify-content: center; }
.ad-slot__ph { width: 100%; text-align: center; font-size: .78rem; color: #9aa9b0; border: 2px dashed #cdd8de; background: #f8fbfc; border-radius: 8px; padding: 1rem; }
/* in-feed 廣告：在卡片網格中佔整列 */
.card-grid .ad-feed { grid-column: 1 / -1; }
.card-grid .ad-feed .ad-slot { margin: .5rem 0; }

/* Two-column single layout */
.single-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 2.5rem; align-items: start; }
.single-layout .main { min-width: 0; }

/* Sidebar */
.sidebar { position: sticky; top: 80px; display: grid; gap: 1.25rem; }
.sidebar__box { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.2rem; }
.sidebar__title { font-size: 1rem; font-weight: 800; margin: 0 0 .8rem; padding-bottom: .5rem; border-bottom: 2px solid var(--brand); color: var(--brand-dark); }
.sidebar__pills { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .8rem; }
.sidebar__pills a { font-size: .8rem; font-weight: 700; color: var(--brand-dark); background: var(--bg-soft); padding: .2rem .7rem; border-radius: 100px; }
.sidebar__cats { list-style: none; margin: 0; padding: 0; }
.sidebar__cats li { padding: .35rem 0; border-bottom: 1px solid var(--line); font-size: .92rem; }
.sidebar__cats li:last-child { border-bottom: 0; }
.sidebar__cats a { color: var(--ink); }
.sidebar__posts { list-style: none; margin: 0; padding: 0; }
.sidebar__posts li { margin-bottom: .85rem; }
.sidebar__posts a { display: flex; gap: .6rem; align-items: center; color: var(--ink); }
.sidebar__posts a:hover { text-decoration: none; color: var(--brand); }
.sidebar__thumb { flex: 0 0 56px; }
.sidebar__thumb img { width: 56px; height: 56px; object-fit: cover; border-radius: 8px; display: block; }
.sidebar__ptitle { font-size: .9rem; line-height: 1.45; font-weight: 600; }

@media (max-width: 900px) {
  .single-layout { grid-template-columns: 1fr; gap: 2rem; }
  .sidebar { position: static; }
}

/* GEO hub 頁 */
.breadcrumb { font-size: .85rem; color: var(--muted); margin: .5rem 0 1rem; }
.breadcrumb a { color: var(--brand); }
.breadcrumb span { margin: 0 .35rem; }
.hub-intro, .archive-desc { background: var(--bg-soft); border-left: 4px solid var(--brand); border-radius: 0 10px 10px 0; padding: 1rem 1.2rem; color: var(--ink); line-height: 1.8; margin: 0 0 1.5rem; }
.archive-desc p:last-child { margin-bottom: 0; }
.archive-guide { margin: 0 0 2rem; }
.archive-guide h2:first-child, .archive-guide > :first-child { margin-top: 0; }

.clinic-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; }
.clinic-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; transition: box-shadow .15s, transform .15s; }
.clinic-card:hover { box-shadow: 0 6px 18px rgba(10,126,164,.10); transform: translateY(-2px); }
.clinic-card__name { font-size: 1.05rem; margin: 0 0 .4rem; line-height: 1.45; }
.clinic-card__name a { color: var(--ink); }
.clinic-card__name a:hover { color: var(--brand); }
.clinic-card__spec { display: inline-block; font-size: .76rem; font-weight: 700; color: var(--brand-dark); background: var(--bg-soft); padding: .15rem .6rem; border-radius: 100px; margin-bottom: .4rem; }
.clinic-card__addr { font-size: .88rem; color: var(--muted); margin: .3rem 0 0; }

.hub-links { margin: 2.5rem 0 0; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.hub-links__title { font-size: 1.1rem; margin: 0 0 .8rem; }
.hub-links__chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.hub-links__chips a { font-size: .88rem; color: var(--ink); background: var(--bg-soft); border: 1px solid var(--line); padding: .35rem .8rem; border-radius: 100px; }
.hub-links__chips a:hover { background: #e3eef3; color: var(--brand); text-decoration: none; }

/* 診所目錄總覽頁 */
.dir-section { margin: 2rem 0; }
.dir-section__title { font-size: 1.3rem; margin: 0 0 1rem; padding-bottom: .5rem; border-bottom: 2px solid var(--brand); }
.dir-areas { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1.25rem; }
.dir-county { border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; }
.dir-county__name { font-size: 1.05rem; margin: 0 0 .6rem; }
.dir-county__name a { color: var(--ink); }
.dir-county__name a:hover { color: var(--brand); }
.dir-county__name span { font-size: .78rem; color: var(--muted); font-weight: 400; }
.dir-county__districts { display: flex; flex-wrap: wrap; gap: .4rem; }
.dir-county__districts a { font-size: .85rem; color: var(--brand-dark); background: var(--bg-soft); padding: .2rem .6rem; border-radius: 100px; }
.dir-county__districts a:hover { background: #e3eef3; text-decoration: none; }

/* 診所單篇：同區/同科連結 */
.clinic-more { max-width: var(--maxw-read); margin: 1.25rem auto 0; display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.clinic-more__label { font-size: .9rem; color: var(--muted); }
.clinic-more a { font-size: .88rem; font-weight: 600; color: var(--brand-dark); background: var(--bg-soft); padding: .35rem .8rem; border-radius: 100px; }
.clinic-more a:hover { background: #e3eef3; text-decoration: none; }

/* 全站電腦版左右摩天樓廣告（固定於內容兩側留白） */
.site-rail { display: none; }
@media (min-width: 1440px) {
  .site-rail { display: block; position: fixed; top: 90px; width: 160px; z-index: 50; }
  .site-rail--left  { left: calc(50% - 540px - 176px); }
  .site-rail--right { right: calc(50% - 540px - 176px); }
  .site-rail .ad-slot { margin: 0; }
}

/* Pagination */
.pagination { display: flex; gap: .5rem; justify-content: center; margin: 2.5rem 0 0; flex-wrap: wrap; }
.pagination a, .pagination span { padding: .5rem .9rem; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); }
.pagination .current { background: var(--brand); color: #fff; border-color: var(--brand); }

/* Footer */
.site-footer { background: var(--ink); color: rgba(255,255,255,.72); margin-top: 3.5rem; }
.footer-ad { margin: 2rem auto 0; }
.site-footer__grid { display: grid; grid-template-columns: 1.6fr 1.5fr 1fr 1fr; gap: 2rem; padding: 2.75rem 1rem 2.25rem; }
.site-footer__about { font-size: .85rem; line-height: 1.7; margin: 0 0 .75rem; color: rgba(255,255,255,.66); }
.site-footer__about strong { color: rgba(255,255,255,.9); font-weight: 600; }
.site-footer__name { font-size: 1.25rem; font-weight: 800; color: #fff; }
.site-footer__desc { margin: .6rem 0 1rem; font-size: .9rem; line-height: 1.7; max-width: 34ch; }
.site-footer__social a { color: rgba(255,255,255,.8); display: inline-flex; align-items: center; }
.site-footer__social a:hover { color: #fff; }
.site-footer__title { font-size: 1rem; color: #fff; margin: 0 0 .85rem; font-weight: 700; }
.site-footer__col ul { list-style: none; margin: 0; padding: 0; }
.site-footer__col li { margin: .45rem 0; }
.site-footer__col a { color: rgba(255,255,255,.72); font-size: .92rem; }
.site-footer__col a:hover { color: #fff; text-decoration: none; }
.site-footer__bar { border-top: 1px solid rgba(255,255,255,.12); font-size: .82rem; color: rgba(255,255,255,.55); }
.site-footer__bar .container { padding-top: 1rem; padding-bottom: 1rem; }
@media (max-width: 768px) { .site-footer__grid { grid-template-columns: 1fr; gap: 1.75rem; } }

/* Mobile */
@media (max-width: 768px) {
  body { font-size: 16px; }
  .nav-toggle { display: block; }
  .main-nav {
    position: absolute; top: 64px; left: 0; right: 0;
    background: #fff; border-bottom: 1px solid var(--line);
    transform: translateY(-120%); transition: transform .2s; padding: .5rem 0;
  }
  .main-nav[data-open="true"] { transform: translateY(0); max-height: 80vh; overflow-y: auto; }
  .main-nav > div > ul, .main-nav > ul { flex-direction: column; gap: 0; }
  .main-nav li { border-top: 1px solid var(--line); }
  .main-nav a { display: block; padding: .9rem 1rem; }
  /* 手機：子選單直接展開、縮排 */
  .main-nav .sub-menu {
    position: static; opacity: 1; visibility: visible; transform: none;
    box-shadow: none; border: 0; border-radius: 0; padding: 0;
    background: var(--bg-soft);
  }
  .main-nav .sub-menu a { padding-left: 2rem; }
  .main-nav .menu-item-has-children > a::after { content: ""; }
  /* mega 面板：手機展開為單欄 */
  .mega-panel { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; border-radius: 0; width: auto; padding: .5rem 1rem 1rem; grid-template-columns: 1fr; gap: .5rem; background: var(--bg-soft); }
  .mega-col--areas ul { columns: 2; }
  .main-nav .mega-clinic > a::after { content: ""; }
  .mega-all { margin-top: .6rem; }
  .entry__title, .clinic-hero__name { font-size: 1.5rem; }
}

/* 診所介紹（燈號診所豐富內容） */
.clinic-about { max-width: var(--maxw-read); margin: 1.75rem auto 0; }
.clinic-about h2 { font-size: 1.2rem; margin: 0 0 .6rem; }
.clinic-about h3 { font-size: 1.05rem; }

/* 延伸閱讀（文章結尾相關文） */
.related-posts { margin: 2.5rem 0 0; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.related-posts__title { font-size: 1.3rem; margin: 0 0 1rem; }
.related-posts__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 1rem; }
.related-posts__item { display: block; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.related-posts__item:hover { box-shadow: 0 6px 18px rgba(10,126,164,.10); text-decoration: none; }
.related-posts__thumb img { width: 100%; aspect-ratio: 16/10; object-fit: cover; display: block; }
.related-posts__name { display: block; padding: .7rem .8rem; font-size: .92rem; font-weight: 600; color: var(--ink); line-height: 1.45; }
.related-posts__item:hover .related-posts__name { color: var(--brand); }

/* 店家資訊卡（食記/景點） */
.place-info { max-width: var(--maxw-read); margin: 2rem auto 0; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.3rem; background: var(--bg-soft); }
.place-info__title { font-size: 1.15rem; margin: 0 0 .7rem; color: var(--brand-dark); }
.place-info__table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.place-info__table th { text-align: left; width: 5.5em; color: var(--muted); font-weight: 700; padding: .4rem .5rem .4rem 0; vertical-align: top; }
.place-info__table td { padding: .4rem 0; }

/* 文章 FAQ */
.post-faq { max-width: var(--maxw-read); margin: 2rem auto 0; }
.post-faq__title { font-size: 1.3rem; margin: 0 0 .8rem; }
.post-faq__item { border: 1px solid var(--line); border-radius: 10px; padding: .2rem .9rem; margin-bottom: .6rem; }
.post-faq__item summary { cursor: pointer; font-weight: 600; padding: .7rem 0; }
.post-faq__a { padding: 0 0 .8rem; color: var(--muted); line-height: 1.8; }

/* 首頁（診所搜尋入口） */
.home-hero { background: linear-gradient(160deg, #eaf4f8, #f5f8fa); border-bottom: 1px solid var(--line); padding: 2.6rem 0; margin-bottom: 2rem; }
.home-hero__inner { display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: 2rem; }
.home-hero__title { font-size: 2.1rem; line-height: 1.32; margin: 0 0 .8rem; color: var(--ink); }
.home-hero__sub { max-width: 560px; margin: 0 0 1.4rem; color: var(--muted); line-height: 1.8; }
.home-search { display: flex; max-width: 520px; gap: .5rem; }
.home-search input[type=search] { flex: 1; padding: .7rem 1rem; border: 1px solid var(--line); border-radius: 100px; font-size: 1rem; background: #fff; }
.home-search button { padding: .7rem 1.5rem; border: 0; border-radius: 100px; background: var(--brand); color: #fff; font-weight: 700; font-size: 1rem; cursor: pointer; white-space: nowrap; }
.home-search button:hover { background: var(--brand-dark); }
.home-stats { display: flex; flex-wrap: wrap; gap: 1.6rem; list-style: none; margin: 1.5rem 0 0; padding: 0; }
.home-stats li { display: flex; flex-direction: column; line-height: 1.2; }
.home-stats strong { font-size: 1.5rem; color: var(--brand-dark); }
.home-stats span { font-size: .8rem; color: var(--muted); }
.home-hero__art { display: flex; justify-content: center; }
.home-hero__art svg { width: 100%; max-width: 380px; height: auto; filter: drop-shadow(0 10px 24px rgba(10,126,164,.16)); }

/* 行內圖示 */
.rwn-ico { width: 1.05em; height: 1.05em; vertical-align: -.16em; margin-right: .4em; flex: none; }

/* 怎麼用（3 步驟） */
.home-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin: 0 0 2.4rem; }
.home-step { display: flex; gap: .9rem; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.2rem; }
.home-step__icon { flex: none; width: 46px; height: 46px; border-radius: 12px; background: var(--bg-soft); color: var(--brand); display: flex; align-items: center; justify-content: center; }
.home-step__icon .rwn-ico { width: 26px; height: 26px; margin: 0; vertical-align: 0; }
.home-step__title { font-size: 1.05rem; margin: 0 0 .35rem; display: flex; align-items: center; gap: .5rem; }
.home-step__num { flex: none; width: 22px; height: 22px; border-radius: 50%; background: var(--brand); color: #fff; font-size: .8rem; display: inline-flex; align-items: center; justify-content: center; }
.home-step__desc { margin: 0; font-size: .9rem; color: var(--muted); line-height: 1.7; }

.home-block { margin: 2.2rem 0; }
.home-block__title { font-size: 1.4rem; margin: 0 0 1rem; padding-left: .7rem; border-left: 5px solid var(--brand); display: flex; align-items: center; }
.home-block__title .rwn-ico { color: var(--brand); width: 1.2rem; height: 1.2rem; }
.home-block__more { margin: 1rem 0 0; text-align: right; font-weight: 600; }
@media (max-width:860px){
  .home-hero__inner { grid-template-columns: 1fr; text-align: center; }
  .home-hero__sub { margin-left: auto; margin-right: auto; }
  .home-search { margin: 0 auto; }
  .home-stats { justify-content: center; }
  .home-hero__art { order: -1; }
  .home-hero__art svg { max-width: 260px; }
  .home-steps { grid-template-columns: 1fr; }
}
@media (max-width:768px){ .home-hero__title { font-size: 1.6rem; } }
