/*!
 * 908 頂讓網 — 站台樣式（便利貼市集風）
 * 建立在 Bootstrap 5.3 之上（public/vendor/bootstrap）。由舊站 site.css + preview.css + preview9.css
 * 整理成單一檔案：只保留「便利貼」主題，已移除預覽用的主題切換與其他 9 種版面。
 * 色彩與字型都從 :root 變數取用；新增元件請沿用這些變數，不要寫死色碼。
 */

:root {
  /* -- 品牌色票 -- */
  --brand: #ff7a45;
  --brand-deep: #e35a22;
  --brand-tint: #fff0e6;
  --sell: #2fb589;
  --build: #4a8fe7;
  --amber: #ffd23f;
  --paper: #fffaf0;
  --surface-warm: #f5ecd9;
  --ink: #2d2619;
  --ink-soft: #5d5242;
  --muted: #968a76;
  --rule: #d8c79e;
  --rule-soft: #eadfc6;
  --note-yellow: #fff3a8;
  --note-pink: #ffd9e4;
  --note-blue: #d3ebff;
  --note-green: #d6f5d8;
  --red: #e5382a;

  --font-lat: "Archivo", "Noto Sans TC", system-ui, sans-serif;
  --hand: "LXGW WenKai TC", "Noto Sans TC", cursive;

  /* -- Bootstrap 變數覆寫 -- */
  --bs-body-font-family: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", system-ui, sans-serif;
  --bs-body-bg: var(--paper);
  --bs-body-color: var(--ink);
  --bs-primary: var(--brand);
  --bs-primary-rgb: 255, 122, 69;
  --bs-link-color: var(--brand-deep);
  --bs-link-color-rgb: 227, 90, 34;
  --bs-link-hover-color: var(--brand-deep);
  --bs-border-color: #e6d9bc;
  --bs-border-radius: .4rem;
  --bs-border-radius-lg: .5rem;
  --bs-border-radius-xl: .8rem;
  --bs-border-radius-pill: 999px;
}

body { -webkit-font-smoothing: antialiased; background: var(--paper); }
a { text-decoration: none; }
::selection { background: var(--amber); }
.font-lat { font-family: var(--font-lat); }
.brand-logo { height: 38px; width: auto; display: block; }
.en { display: block; font-family: var(--font-lat); font-size: .72rem; letter-spacing: .22em; text-transform: uppercase; color: var(--brand-deep); font-weight: 700; }

/* ---------- buttons ---------- */
.btn { font-weight: 700; }
.btn-primary { --bs-btn-bg: var(--brand); --bs-btn-border-color: var(--brand); --bs-btn-color: var(--ink); --bs-btn-hover-bg: var(--brand-deep); --bs-btn-hover-border-color: var(--brand-deep); --bs-btn-hover-color: var(--ink); --bs-btn-active-bg: var(--brand-deep); --bs-btn-active-border-color: var(--brand-deep); --bs-btn-active-color: var(--ink); --bs-btn-disabled-bg: var(--brand); --bs-btn-disabled-border-color: var(--brand); }
.btn-outline-dark { --bs-btn-color: var(--ink); --bs-btn-border-color: var(--ink); --bs-btn-hover-bg: var(--ink); --bs-btn-hover-border-color: var(--ink); --bs-btn-active-bg: var(--ink); }
.btn-search { background: var(--brand); border: 2px solid var(--ink); color: var(--ink); box-shadow: 3px 3px 0 var(--ink); }
.btn-search:hover { background: var(--amber); border-color: var(--ink); color: var(--ink); }
.btn-post { background: var(--brand); color: var(--ink); font-weight: 900; border: 2px solid var(--ink); border-radius: .5rem; box-shadow: 3px 3px 0 var(--ink); transform: rotate(-1.5deg); transition: .12s; }
.btn-post:hover { transform: rotate(0) translate(-1px, -1px); box-shadow: 5px 5px 0 var(--ink); background: var(--amber); color: var(--ink); }
/* 表單送出鈕（登入、註冊、儲存…）不要歪：只有導覽列這類連結型的刊登鈕保留便利貼的傾斜 */
button.btn-post { transform: none; }
button.btn-post:hover { transform: translate(-1px, -1px); }
.form-label.req::after { content: " *"; color: var(--brand-deep); }
.captcha-refresh { cursor: pointer; border: 1px solid var(--bs-border-color); border-radius: .6rem; height: 44px; }

/* ---------- ticker ---------- */
.ticker { background: var(--ink); color: #ffe9a8; overflow: hidden; font-size: .8rem; font-weight: 700; padding: .4rem 0; }
.ticker .track { display: inline-flex; gap: 3rem; white-space: nowrap; animation: tk 28s linear infinite; padding-left: 100%; }
@keyframes tk { to { transform: translateX(-100%); } }
@media (prefers-reduced-motion: reduce) { .ticker .track { animation: none; padding-left: 1rem; } }

/* ---------- nav ---------- */
.topbar { background: var(--paper); border-bottom: 2px dashed var(--rule); position: sticky; top: 0; z-index: 10; }
.folder-tabs { list-style: none; margin: 0 auto 0 2rem; padding: 0; gap: .3rem; align-items: flex-end; }
.folder-tabs a { display: block; padding: .5rem 1.1rem; font-weight: 700; color: var(--ink-soft); border-radius: .7rem .7rem 0 0; background: var(--surface-warm); border: 2px solid var(--bs-border-color); border-bottom: 0; transition: .15s; }
.folder-tabs li.on a, .folder-tabs a:hover { background: var(--note-yellow); color: var(--ink); transform: translateY(-3px); }
.mobile-tabs { list-style: none; margin: 0; padding: .4rem 1rem; display: flex; gap: .5rem; overflow-x: auto; border-top: 1px dashed var(--rule); }
.mobile-tabs a { display: block; white-space: nowrap; padding: .25rem .9rem; font-weight: 700; color: var(--ink-soft); border: 2px solid var(--bs-border-color); border-radius: 999px; background: var(--surface-warm); }
.mobile-tabs li.on a { background: var(--note-yellow); color: var(--ink); border-color: var(--ink); }

/* ---------- 便利貼小零件 ---------- */
.stamp { display: inline-block; border: 2.5px solid var(--brand-deep); color: var(--brand-deep); font-weight: 900; padding: .25rem 1rem; transform: rotate(-3deg); border-radius: .3rem; letter-spacing: .08em; }
.stamp.sm { font-size: .8rem; padding: .15rem .7rem; }
.tape { position: absolute; top: -12px; left: 50%; width: 74px; height: 22px; margin-left: -37px; background: rgba(255, 230, 140, .75); border: 1px solid rgba(0, 0, 0, .06); transform: rotate(-3deg); }
.pin { position: absolute; top: -10px; left: 50%; margin-left: -9px; width: 18px; height: 18px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #ff9b8a, var(--red) 60%); box-shadow: 0 3px 4px rgba(0, 0, 0, .3); z-index: 2; }
.hl { background: linear-gradient(transparent 58%, var(--amber) 58%); padding: 0 .15em; font-family: var(--hand); }

/* ---------- hero ---------- */
.hero9 { padding: 4rem 0 3rem; background: radial-gradient(circle, rgba(160, 120, 60, .14) 1.4px, transparent 1.6px) 0 0 / 20px 20px, var(--surface-warm); border-bottom: 2px dashed var(--rule); overflow: hidden; }
.hero9 h1 { font-weight: 900; font-size: clamp(2rem, 4vw, 3.6rem); line-height: 1.25; margin: 1.2rem 0 .8rem; }
.hero9 .lead { font-size: 1.05rem; color: var(--ink-soft); max-width: 30em; }
.finder { position: relative; background: #fff; border: 2px solid var(--ink); border-radius: .6rem; padding: 1.3rem 1.2rem 1.1rem; margin-top: 1.6rem; max-width: 460px; box-shadow: 6px 6px 0 var(--ink); transform: rotate(-.6deg); }
.finder > b { display: block; font-family: var(--hand); font-size: 1.15rem; margin-bottom: .6rem; }
.collage { position: relative; height: 430px; }
.collage .shot { position: absolute; background-size: cover; background-position: center; border: 8px solid #fff; border-bottom-width: 30px; box-shadow: 0 14px 26px -10px rgba(60, 40, 10, .5); }
.collage .shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.c1 { width: 62%; height: 58%; left: 2%; top: 4%; transform: rotate(-5deg); }
.c2 { width: 52%; height: 50%; right: 0; top: 0; transform: rotate(4deg); }
.c3 { width: 58%; height: 50%; left: 28%; bottom: 0; transform: rotate(-1.5deg); z-index: 2; }
.sticker { position: absolute; z-index: 3; width: 96px; height: 96px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; border: 2.5px solid var(--ink); box-shadow: 3px 3px 0 var(--ink); }
.sticker b { font-size: 1.5rem; line-height: 1; } .sticker small { font-size: .7rem; font-weight: 700; }
.s1 { background: var(--amber); left: -6px; bottom: 16%; transform: rotate(-10deg); } .s2 { background: #ffb3cc; right: 4px; bottom: 6%; transform: rotate(9deg); }
.doodle { position: absolute; z-index: 3; right: 6%; top: 52%; font-family: var(--hand); font-weight: 700; font-size: 1.05rem; color: var(--brand-deep); transform: rotate(-6deg); background: #fff; padding: .15rem .6rem; border-radius: .4rem; }

/* ---------- chips ---------- */
.chips { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; padding: 1.6rem 0 .4rem; }
.chips .lbl { font-family: var(--hand); font-weight: 700; font-size: 1.1rem; margin-right: .4rem; }
.chip { display: inline-flex; align-items: center; gap: .4rem; padding: .45rem 1rem .45rem .8rem; background: #fff; border: 2px solid var(--ink); border-radius: .5rem 999px 999px .5rem; font-weight: 700; color: var(--ink); box-shadow: 2px 2px 0 var(--ink); transition: .12s; }
.chip i { color: var(--brand-deep); }
.chip:hover { background: var(--note-yellow); color: var(--ink); transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--ink); }

/* ---------- section headers ---------- */
.sec-hd { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; margin-bottom: 1.6rem; }
.sec-hd.center { justify-content: center; text-align: center; }
.sec-hd h2 { font-weight: 900; font-size: 1.9rem; margin: .1rem 0 0; position: relative; display: inline-block; }
.sec-hd p { margin: .3rem 0 0; color: var(--muted); }
.squig { display: block; width: 100%; height: 10px; color: var(--amber); margin-top: 2px; }
.more { font-weight: 800; color: var(--ink); border-bottom: 3px solid var(--amber); white-space: nowrap; }
.more:hover { color: var(--brand-deep); }

/* ---------- 便利貼看板與卡片 ---------- */
.board { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-flow: dense; gap: 2rem 1.4rem; padding: 1.4rem 1rem 1rem; border-radius: .8rem; background: radial-gradient(circle, rgba(160, 120, 60, .1) 1.2px, transparent 1.4px) 0 0 / 18px 18px, #fff7e1; border: 2px dashed #e0cf9f; }
.note { position: relative; display: block; padding: 1rem 1rem 1.1rem; color: var(--ink); transform: rotate(var(--r, 0deg)); box-shadow: 0 10px 18px -10px rgba(90, 60, 10, .5); transition: transform .18s, box-shadow .18s; }
.note:hover { transform: rotate(0) translateY(-8px) scale(1.02); box-shadow: 0 22px 28px -14px rgba(90, 60, 10, .55); color: var(--ink); z-index: 3; }
.note::after { content: ""; position: absolute; right: 0; bottom: 0; width: 26px; height: 26px; background: linear-gradient(135deg, transparent 50%, rgba(0, 0, 0, .09) 50%); }
.note .shot { aspect-ratio: 16 / 10; border: 3px solid #fff; position: relative; overflow: hidden; background: var(--surface-warm); }
.note .shot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.note .kind { position: absolute; top: 6px; left: 6px; font-size: .68rem; font-weight: 900; padding: 1px 9px; border-radius: 999px; background: var(--brand); color: var(--ink); border: 1.5px solid var(--ink); }
.k-sell .kind { background: #7ee0b8; } .k-build .kind { background: #b9a8ff; } .k-rent .kind { background: var(--amber); }
.note h3 { font-size: 1rem; font-weight: 800; margin: .8rem 0 .3rem; line-height: 1.4; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.note small { color: var(--ink-soft); display: block; }
.price { display: inline-block; margin-top: .7rem; background: #fff; border: 2px dashed var(--brand-deep); color: var(--brand-deep); font-family: var(--hand); font-weight: 700; font-size: 1.05rem; padding: .1rem .8rem; border-radius: .3rem; transform: rotate(-2deg); }
.n-y { background: var(--note-yellow); } .n-p { background: var(--note-pink); } .n-b { background: var(--note-blue); } .n-g { background: var(--note-green); }
.note.big { grid-column: span 2; grid-row: span 2; padding: 1.3rem; }
.note.big .shot { aspect-ratio: 16 / 11; } .note.big h3 { font-size: 1.35rem; } .note.big .price { font-size: 1.35rem; }
.hot { position: absolute; top: -10px; right: -12px; z-index: 3; background: var(--red); color: #fff; font-family: var(--font-lat); font-weight: 800; font-size: .8rem; padding: .25rem .7rem; transform: rotate(8deg); box-shadow: 2px 2px 0 var(--ink); }
@media (max-width: 991.98px) { .board { grid-template-columns: repeat(2, 1fr); } .collage { height: 340px; } }
@media (max-width: 575.98px) { .board { grid-template-columns: 1fr; } .note.big { grid-column: auto; grid-row: auto; } }
@media (prefers-reduced-motion: reduce) { .note, .note:hover { transition: none; } }

/* ---------- 分頁 ---------- */
.pager ul { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem; padding: 0; margin: 2rem 0 0; }
.pager a, .pager .gap { display: block; min-width: 2.4rem; padding: .35rem .8rem; text-align: center; font-weight: 800; color: var(--ink); background: #fff; border: 2px solid var(--ink); border-radius: .4rem; box-shadow: 2px 2px 0 var(--ink); }
.pager .gap { border-color: transparent; box-shadow: none; background: none; }
.pager a:hover { background: var(--note-yellow); }
.pager li.on a { background: var(--amber); }

/* ---------- why: 吊牌 ---------- */
.tagcard { position: relative; border: 2px solid var(--ink); border-radius: .5rem; padding: 2.4rem 1.4rem 1.4rem; height: 100%; box-shadow: 5px 5px 0 var(--ink); }
.tagcard .hole { position: absolute; top: 12px; left: 50%; margin-left: -9px; width: 18px; height: 18px; border-radius: 50%; background: var(--paper); border: 2px solid var(--ink); }
.tagcard .ico { font-size: 2rem; font-weight: 900; color: var(--brand-deep); line-height: 1; margin-bottom: .6rem; }
.tagcard h3 { font-size: 1.15rem; font-weight: 900; } .tagcard p { margin: 0; font-size: .9rem; color: var(--ink-soft); }

/* ---------- steps ---------- */
.steps-wrap { background: var(--surface-warm); border-block: 2px dashed var(--rule); }
.step { text-align: center; padding: 1rem; position: relative; }
.step .no { width: 64px; height: 64px; border-radius: 50%; background: var(--amber); border: 2.5px solid var(--ink); display: inline-flex; align-items: center; justify-content: center; font-family: var(--hand); font-size: 1.8rem; font-weight: 700; box-shadow: 3px 3px 0 var(--ink); }
.step h3 { margin: .9rem 0 .3rem; font-weight: 900; font-size: 1.15rem; } .step p { color: var(--ink-soft); margin: 0; }
@media (min-width: 768px) { .steps-wrap .col-md-4:not(:last-child) .step::after { content: ""; position: absolute; top: 48px; left: calc(50% + 50px); width: calc(100% - 100px); border-top: 3px dashed #c9b27a; } }

/* ---------- checklist ---------- */
.checklist { position: relative; background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: 2rem 1.6rem 1.4rem; box-shadow: 6px 6px 0 var(--ink); transform: rotate(-1deg); background-image: linear-gradient(#e8f0fb 1px, transparent 1px); background-size: 100% 2.4rem; background-position: 0 3.6rem; }
.checklist h3 { font-family: var(--hand); font-weight: 700; font-size: 1.5rem; } .checklist ul { list-style: none; padding: 0; margin: 0 0 .6rem; }
.checklist li a { display: flex; align-items: center; gap: .6rem; height: 2.4rem; color: var(--ink); font-weight: 500; }
.checklist li a i { color: var(--sell); font-size: 1.1rem; }
.checklist li a:hover { color: var(--brand-deep); text-decoration: underline wavy var(--amber); }

/* ---------- postcard ---------- */
.postcard { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; padding: 2.2rem; background: #fff; border: 2px solid var(--ink); border-radius: .4rem; position: relative; box-shadow: 6px 6px 0 var(--ink);
  background-image: repeating-linear-gradient(135deg, var(--brand) 0 14px, #fff 14px 24px, var(--build) 24px 38px, #fff 38px 48px); background-size: 100% 10px; background-repeat: no-repeat; background-position: 0 0; }
.postcard::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 10px; background: repeating-linear-gradient(135deg, var(--brand) 0 14px, #fff 14px 24px, var(--build) 24px 38px, #fff 38px 48px); }
.postcard h2 { font-weight: 900; margin: .2rem 0; } .postcard p { margin: 0; color: var(--ink-soft); }
.pc-r { text-align: center; } .pc-r small { display: block; margin-top: .7rem; }

/* ---------- footer：鋸齒撕邊 + 便利貼 CTA ---------- */
.foot9 { position: relative; background: #fff3d2; margin-top: 3.2rem; padding: 3.4rem 0 1.4rem; color: var(--ink-soft);
  background-image: radial-gradient(circle, rgba(160, 120, 60, .13) 1.2px, transparent 1.4px); background-size: 18px 18px; }
.foot9::before { content: ""; position: absolute; left: 0; right: 0; top: -14px; height: 14px;
  background: linear-gradient(135deg, #fff3d2 50%, transparent 50%) 0 0 / 22px 14px, linear-gradient(225deg, #fff3d2 50%, transparent 50%) 0 0 / 22px 14px; }
.foot9 .slogan { margin: .9rem 0 1rem; font-family: var(--hand); font-size: 1.05rem; line-height: 1.8; color: var(--ink); }
.foot9 h4 { font-size: .95rem; font-weight: 900; color: var(--ink); margin-bottom: .8rem; display: inline-block; background: linear-gradient(transparent 62%, var(--amber) 62%); }
.foot9 ul { list-style: none; margin: 0; padding: 0; }
.foot9 li a { display: inline-block; padding: .25rem 0; color: var(--ink-soft); font-weight: 500; }
.foot9 li a::before { content: "›"; margin-right: .4rem; color: var(--brand-deep); font-weight: 900; }
.foot9 li a:hover { color: var(--brand-deep); text-decoration: underline wavy var(--amber); text-underline-offset: 4px; }
.foot-note { position: relative; background: var(--note-yellow); padding: 1.5rem 1.3rem 1.2rem; transform: rotate(1.5deg); box-shadow: 0 12px 20px -10px rgba(90, 60, 10, .5); color: var(--ink); }
.foot-note b { font-family: var(--hand); font-size: 1.3rem; } .foot-note p { margin: .3rem 0 .9rem; font-size: .9rem; }
.foot-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .8rem; margin-top: 2.4rem; padding-top: 1rem; border-top: 2px dashed var(--rule); font-size: .82rem; color: var(--muted); }
.totop { font-weight: 800; color: var(--ink); background: #fff; border: 2px solid var(--ink); border-radius: 999px; padding: .2rem .9rem; box-shadow: 2px 2px 0 var(--ink); }
.totop:hover { background: var(--amber); color: var(--ink); }

/* ---------- 提示訊息（表單錯誤、成功） ---------- */
.flash { border: 2px solid var(--ink); border-radius: .5rem; padding: .7rem 1rem; background: #fff; box-shadow: 3px 3px 0 var(--ink); margin-bottom: 1rem; }
.flash.ok { background: var(--note-green); } .flash.err { background: var(--note-pink); }

/* ---------- 列表與詳情頁 ---------- */
.crumbs { font-size: .85rem; color: var(--muted); margin-bottom: 1rem; }
.crumbs a { color: var(--ink-soft); font-weight: 700; }
.crumbs span { color: var(--ink); }
.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .8rem 1rem; background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: .9rem 1rem; box-shadow: 4px 4px 0 var(--ink); margin-bottom: 1.6rem; }
.filters label { display: flex; flex-direction: column; gap: .2rem; font-size: .78rem; font-weight: 800; color: var(--ink-soft); min-width: 9rem; }
.empty-note { position: relative; background: var(--note-yellow); padding: 2rem 1.5rem 1.4rem; max-width: 26rem; margin: 2rem auto; text-align: center; transform: rotate(-1deg); box-shadow: 0 12px 20px -10px rgba(90, 60, 10, .5); }
.empty-note b { font-family: var(--hand); font-size: 1.3rem; }
.empty-note .error-title { font-family: var(--hand); font-size: 1.3rem; font-weight: 700; margin: 0; }
.gallery { display: grid; gap: 1rem; }
.gallery-item { margin: 0; background: #fff; border: 8px solid #fff; box-shadow: 0 14px 26px -12px rgba(60, 40, 10, .5); }
.gallery-item img { display: block; width: 100%; height: auto; }
.gallery-item figcaption { padding: .4rem .2rem 0; font-size: .85rem; color: var(--ink-soft); }
.detail-note { position: relative; padding: 1.8rem 1.5rem 1.4rem; box-shadow: 0 14px 24px -12px rgba(90, 60, 10, .5); }
.detail-note h1 { font-size: 1.5rem; font-weight: 900; line-height: 1.4; margin: .6rem 0 .4rem; }
.kind-tag { display: inline-block; font-size: .72rem; font-weight: 900; padding: 1px 10px; border-radius: 999px; background: var(--brand); border: 1.5px solid var(--ink); }
.facts { display: grid; grid-template-columns: auto 1fr; gap: .35rem 1rem; margin: 1rem 0; }
.facts dt { font-weight: 800; color: var(--ink-soft); } .facts dd { margin: 0; }
.contact { border-top: 2px dashed var(--rule); padding-top: .8rem; margin-bottom: .8rem; }
.desc-card { margin-top: 2rem; background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: 1.4rem 1.6rem; box-shadow: 5px 5px 0 var(--ink); }
.desc-body { overflow-wrap: anywhere; }
.closed-note { background: var(--note-pink); }

/* ---------- 提示、表單 ---------- */
.flash-bar { margin-top: 1rem; }
.owner-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; background: var(--note-yellow); border: 2px dashed var(--ink); border-radius: .5rem; padding: .6rem 1rem; margin-bottom: 1.2rem; }
.owner-bar form { margin: 0; } .owner-tip { font-weight: 800; color: var(--brand-deep); }
.form-page { max-width: 880px; }
.form-card { background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: 1.2rem 1.4rem 1.4rem; box-shadow: 5px 5px 0 var(--ink); margin-bottom: 1.6rem; }
.form-card > legend { float: none; width: auto; font-family: var(--hand); font-weight: 700; font-size: 1.25rem; padding: 0 .4rem; background: var(--note-yellow); }
.field-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem 1.4rem; }
.field label, .field legend { display: block; font-weight: 800; font-size: .9rem; margin-bottom: .25rem; float: none; width: auto; }
.field label.req::after { content: " *"; color: var(--brand-deep); }
.field .hint { display: block; color: var(--muted); margin-top: .2rem; }
.field .error { display: block; color: var(--red); font-weight: 700; margin-top: .2rem; }
.field.has-error .form-control, .field.has-error .form-select { border-color: var(--red); }
.input-unit { display: flex; align-items: center; gap: .5rem; } .input-unit .unit { white-space: nowrap; color: var(--ink-soft); font-weight: 700; }
.choices { display: flex; flex-wrap: wrap; gap: .4rem 1rem; } .choice { font-weight: 500 !important; display: inline-flex !important; align-items: center; gap: .3rem; margin: 0 !important; }
.field:has(textarea), .field:has(.choices) { grid-column: 1 / -1; }
.form-actions { display: flex; align-items: center; gap: 1.2rem; margin: 1.4rem 0 2rem; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; margin: 1rem 0; }
.photo-tile { margin: 0; background: #fff; border: 4px solid #fff; box-shadow: 0 8px 16px -8px rgba(60, 40, 10, .5); }
.photo-tile img { display: block; width: 100%; height: 120px; object-fit: cover; }
.photo-tile figcaption { display: flex; flex-wrap: wrap; gap: .3rem; padding: .4rem 0 0; } .photo-tile form { margin: 0; }
.cover-badge { background: var(--amber); border: 1.5px solid var(--ink); border-radius: 999px; padding: 0 .6rem; font-size: .75rem; font-weight: 900; }
.upload-form { border-top: 2px dashed var(--rule); padding-top: 1rem; margin-top: 1rem; } .upload-form label { font-weight: 700; display: block; margin-bottom: .4rem; }
@media (max-width: 767.98px) { .field-grid { grid-template-columns: 1fr; } }

/* ---------- 登入註冊與會員中心 ---------- */
.auth-page { max-width: 520px; }
.auth-card { position: relative; background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: 2.2rem 1.8rem 1.6rem; box-shadow: 6px 6px 0 var(--ink); }
.auth-card h1 { font-size: 1.6rem; font-weight: 900; margin-bottom: .4rem; }
.auth-card .field { margin-bottom: 1rem; }
.auth-links { text-align: center; margin: 1.2rem 0 0; color: var(--ink-soft); }
.captcha-row { display: flex; gap: .6rem; align-items: center; }
.captcha-row img { cursor: pointer; border: 1px solid var(--bs-border-color); border-radius: .4rem; background: #fff; }
.member-page { max-width: 960px; }
.member-tabs { display: flex; flex-wrap: wrap; gap: .4rem; border-bottom: 2px dashed var(--rule); margin: 1rem 0 1.4rem; }
.member-tabs a { padding: .45rem 1.1rem; font-weight: 800; color: var(--ink-soft); background: var(--surface-warm); border: 2px solid var(--bs-border-color); border-bottom: 0; border-radius: .6rem .6rem 0 0; }
.member-tabs a.on, .member-tabs a:hover { background: var(--note-yellow); color: var(--ink); }
.member-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .8rem; margin-bottom: 1rem; } .member-head p { margin: 0; color: var(--muted); }
.my-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .8rem; background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: .8rem 1rem; margin-bottom: .8rem; box-shadow: 3px 3px 0 var(--ink); }
.my-main { display: flex; flex-direction: column; gap: .2rem; min-width: 0; flex: 1 1 18rem; }
.my-tags { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
.my-main small { color: var(--muted); }
.my-title { font-weight: 800; color: var(--ink); overflow-wrap: anywhere; } .my-title.is-muted { color: var(--muted); }
.my-actions { display: flex; flex-wrap: wrap; gap: .4rem; } .my-actions form { margin: 0; }
.status-badge { display: inline-block; font-size: .72rem; font-weight: 900; padding: 1px 10px; border-radius: 999px; border: 1.5px solid var(--ink); background: #fff; }
.status-badge.is-open { background: var(--note-green); } .status-badge.is-closed { background: var(--note-pink); }
.inquiry { background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: 1rem 1.2rem; margin-bottom: 1rem; box-shadow: 3px 3px 0 var(--ink); }
.inquiry header { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; } .inquiry header small { color: var(--muted); margin-left: auto; }
.inquiry-body { margin: .6rem 0 0; overflow-wrap: anywhere; }
.inquiry-reply { margin-top: .8rem; background: var(--note-yellow); padding: .7rem 1rem; border-radius: .4rem; } .inquiry-reply p { margin: .3rem 0 0; overflow-wrap: anywhere; }
.profile-form { max-width: 720px; } .profile-form > legend { float: none; width: auto; font-family: var(--hand); font-weight: 700; font-size: 1.25rem; padding: 0 .4rem; background: var(--note-yellow); }
.form-card.inner { box-shadow: none; margin: 1rem 0 0; padding: 1rem; }

/* ---------- 教學文章 ---------- */
.article-list { display: grid; gap: 1rem; }
.article-card { display: block; background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: 1rem 1.2rem; box-shadow: 4px 4px 0 var(--ink); color: var(--ink); transition: .12s; }
.article-card:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); background: var(--note-yellow); color: var(--ink); }
.article-card h2 { font-size: 1.15rem; font-weight: 900; margin: 0 0 .3rem; } .article-card time { color: var(--muted); font-size: .82rem; } .article-card p { margin: .4rem 0 0; color: var(--ink-soft); }
.article-body { background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: 1.6rem 1.8rem; box-shadow: 5px 5px 0 var(--ink); line-height: 1.9; overflow-wrap: anywhere; max-width: 820px; }
.article-head { max-width: 820px; } .article-head h1 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); font-weight: 900; line-height: 1.4; } .article-head time { color: var(--muted); }

/* ---------- 靜態頁與錯誤頁 ---------- */
.legal-page { max-width: 860px; }
.legal-text { background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: 1.4rem 1.8rem; box-shadow: 5px 5px 0 var(--ink); margin-bottom: 1.6rem; white-space: pre-line; line-height: 1.9; overflow-wrap: anywhere; }
.legal-text h2 { font-size: 1.2rem; font-weight: 900; white-space: normal; background: linear-gradient(transparent 62%, var(--amber) 62%); display: inline-block; }
.error-page { padding-top: 5rem; padding-bottom: 5rem; }
.error-code { font-size: 4rem; font-weight: 800; line-height: 1; color: var(--brand-deep); }
.error-links { display: flex; flex-wrap: wrap; gap: .8rem; justify-content: center; }

/* ---------- 詳情頁互動 ---------- */
.action-bar { display: flex; flex-wrap: wrap; align-items: flex-start; gap: .6rem; margin-top: 1rem; } .action-bar form { margin: 0; }
.report-box summary { list-style: none; cursor: pointer; } .report-box summary::-webkit-details-marker { display: none; }
.report-form { background: #fff; border: 2px solid var(--ink); border-radius: .5rem; padding: 1rem; margin-top: .6rem; box-shadow: 3px 3px 0 var(--ink); min-width: min(100%, 22rem); }
.report-form .choices { flex-direction: column; gap: .3rem; } .report-form .error { display: block; color: var(--red); font-weight: 700; }

/* ---------- 響應式修正（瀏覽器截圖檢查後） ---------- */
.btn { white-space: nowrap; }
.hero9 h1, .sec-hd h2, .article-head h1, .detail-note h1 { text-wrap: balance; }
.finder .form-select { min-width: 0; }

/* ---------- 頁尾友站連結 ---------- */
.partners-row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .7rem; margin-top: 2rem; padding-top: 1rem; border-top: 2px dashed var(--rule); }
.partners-row b { font-size: .9rem; font-weight: 900; background: linear-gradient(transparent 62%, var(--amber) 62%); }
.partners-row a { font-size: .85rem; padding: .15rem .8rem; background: #fff; border: 2px solid var(--ink); border-radius: 999px; color: var(--ink-soft); font-weight: 500; }
.partners-row a:hover { background: var(--note-yellow); color: var(--ink); }

/* 手機：輸入欄位字級至少 16px，否則 iPhone Safari 一點進欄位就會自動放大頁面 */
@media (max-width: 767.98px) {
    .field input:not([type="checkbox"]):not([type="radio"]),
    .field select,
    .field textarea,
    .form-control,
    .form-select { font-size: 16px; }
}

/* 手機：會員中心與照片區的小按鈕加高到 40px，手指才點得準（原本 31px） */
@media (max-width: 767.98px) {
    .my-actions .btn, .photo-tile .btn { min-height: 40px; padding-inline: .9rem; }
    .my-actions, .photo-tile figcaption { gap: .5rem; }
}

/* 連結型（<a>）與按鈕型（<button>）的小按鈕文字要一樣置中，否則 <a> 的字會貼在上緣 */
.my-actions .btn, .photo-tile .btn { display: inline-flex; align-items: center; justify-content: center; line-height: 1.2; }
.my-actions { align-items: center; }
.my-actions form { display: flex; }

/* 照片區：「封面」標籤跟旁邊的按鈕同高、文字置中（原本被拉高成一個黃色圓塊） */
.photo-tile figcaption { align-items: center; }
.cover-badge { display: inline-flex; align-items: center; justify-content: center; min-height: 31px; padding: 0 .75rem; border-radius: .375rem; font-size: .85rem; line-height: 1; }
@media (max-width: 767.98px) {
    .cover-badge { min-height: 40px; }
}

/* Google AdSense 區塊（只在正式環境的可收錄頁面輸出） */
.ad-banner { margin: 2rem 0 0; text-align: center; min-height: 0; overflow: hidden; }
.ad-side { margin-top: 1.5rem; }
.ad-cell { margin: 0; align-self: stretch; display: flex; flex-direction: column; justify-content: center; padding: .6rem; background: #fff; border: 1px dashed #d8c48e; border-radius: .5rem; }
.ad-cell .ad-label { color: #9a8a5a; font-size: .75rem; margin-bottom: .3rem; }
.ad-banner[hidden], .ad-banner:has(ins[data-ad-status="unfilled"]) { display: none; }
.ad-banner:not(:has(ins[data-ad-status="filled"])) .ad-label { visibility: hidden; }
.ad-cell { align-self: start; }

/* 刊登表單的照片選擇 */
.photo-previews { list-style: none; margin: .8rem 0 0; padding: 0; display: grid; gap: .5rem; }
.photo-previews li { display: flex; align-items: center; gap: .6rem; background: #fff; border: 1px solid var(--rule); border-radius: .4rem; padding: .3rem .5rem; }
.photo-previews img { width: 64px; height: 48px; object-fit: cover; border-radius: .25rem; flex: none; }
.photo-previews span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
