@charset "utf-8";
:root {
  --espresso: #34261f;
  --coffee: #725342;
  --latte: #e7d8c8;
  --cream: #f8f4ee;
  --paper: #fffdf9;
  --ink: #2b2521;
  --muted: #776d65;
  --line: #e6ded4;
  --green: #28734d;
  --red: #b23838;
  --shadow: 0 16px 42px rgba(52, 38, 31, .12);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { background: linear-gradient(135deg, #e5d4c3 0%, #f8f3ec 44%, #eae2da 100%); color: var(--ink); font-family: "Noto Sans TC", "Microsoft JhengHei", Arial, sans-serif; font-size: 15px; line-height: 1.55; }
.site-shell { min-height: 100vh; display: flex; flex-direction: column; }
.topbar { min-height: 82px; padding: 0 7vw; display: flex; align-items: center; justify-content: space-between; gap: 20px; background: rgba(52, 38, 31, .96); color: #fff; box-shadow: 0 2px 18px rgba(41, 29, 22, .22); }
.brand { color: #fff; text-decoration: none; font-size: clamp(27px, 3.1vw, 36px); line-height: 1; font-weight: 800; letter-spacing: .08em; text-shadow: 0 2px 12px rgba(0, 0, 0, .2); }
.admin-nav { display: flex; align-items: center; gap: 8px; margin-right: auto; }
.admin-nav a { display: inline-flex; align-items: center; min-height: 34px; padding: 7px 10px; border-radius: 7px; color: #eadfd5; font-size: 13px; font-weight: 800; text-decoration: none; }
.admin-nav a:hover { color: #fff; background: rgba(255,255,255,.12); }
.topbar-meta { display: flex; align-items: center; gap: 15px; color: #eadfd5; font-size: 14px; }
.frontend-link { display: inline-flex; align-items: center; min-height: 34px; padding: 7px 11px; border: 1px solid #dcb28d; border-radius: 7px; color: #fff; background: #725342; font-size: 13px; font-weight: 800; line-height: 1; text-decoration: none; box-shadow: 0 2px 8px rgba(0,0,0,.18); transition: background .16s, border-color .16s, transform .16s; }
.frontend-link:hover { color: #fff; border-color: #f2cfad; background: #9a684a; transform: translateY(-1px); }
.frontend-link:focus-visible { color: #fff; outline: 3px solid #f8ddbd; outline-offset: 2px; }
.welcome { padding-left: 15px; border-left: 1px solid rgba(255,255,255,.25); color: #fff; font-weight: 700; }
.logout-link { color: #fff; text-underline-offset: 3px; }
.content { width: min(1180px, calc(100% - 42px)); margin: 0 auto; flex: 1; padding: 58px 0 46px; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; margin-bottom: 28px; }
.compact-heading { margin-bottom: 24px; }
.eyebrow { margin: 0 0 6px; color: var(--coffee); font-size: 12px; letter-spacing: .18em; font-weight: 800; }
h1, h2 { color: var(--espresso); line-height: 1.25; }
h1 { margin: 0; font-size: clamp(28px, 4vw, 42px); letter-spacing: .02em; }
h2 { margin: 0; font-size: 19px; }
.lead { max-width: 720px; margin: 11px 0 0; color: var(--muted); }
.panel { margin-top: 26px; background: rgba(255,253,249,.98); border: 1px solid rgba(125, 91, 68, .12); border-radius: 16px; box-shadow: var(--shadow); overflow: hidden; }
.panel-heading { min-height: 68px; padding: 17px 25px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line); }
.form-panel { padding-bottom: 6px; }
.admin-form { padding: 25px; }
.form-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
label { display: block; margin-bottom: 8px; color: var(--espresso); font-size: 14px; font-weight: 700; }
input, select { width: 100%; min-height: 44px; padding: 9px 12px; border: 1px solid #d8cbbd; border-radius: 8px; outline: none; background: #fff; color: var(--ink); font: inherit; transition: border-color .16s, box-shadow .16s; }
input:focus, select:focus { border-color: var(--coffee); box-shadow: 0 0 0 3px rgba(114,83,66,.15); }
.hint { margin: 6px 0 0; color: var(--muted); font-size: 12px; }
.form-actions { display: flex; align-items: center; gap: 12px; margin-top: 24px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 9px 16px; border: 1px solid transparent; border-radius: 8px; cursor: pointer; font: inherit; font-weight: 700; line-height: 1; text-decoration: none; transition: transform .16s, background .16s, border .16s; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--espresso); color: #fff; box-shadow: 0 5px 12px rgba(52,38,31,.2); }
.btn-primary:hover { background: #48342a; }
.btn-secondary { background: rgba(255,253,249,.72); border-color: #cfbba7; color: var(--espresso); }
.btn-secondary:hover { background: #fff; }
.btn-ghost { background: transparent; border-color: #dacdbf; color: var(--espresso); }
.btn-block { width: 100%; margin-top: 22px; }
.alert { margin: 0 0 22px; padding: 12px 16px; border-radius: 9px; font-weight: 600; }
.alert-success { border: 1px solid #a9d4bc; background: #ecf8f0; color: #17623d; }
.alert-error { border: 1px solid #f0c1bc; background: #fff2f0; color: #99342e; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 880px; }
th, td { padding: 15px 18px; text-align: left; vertical-align: middle; border-bottom: 1px solid var(--line); }
th { background: #f5eee6; color: #5d4636; font-size: 13px; letter-spacing: .04em; white-space: nowrap; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fffaf5; }
.account-name { color: var(--espresso); font-weight: 800; }
.badge, .status { display: inline-flex; align-items: center; white-space: nowrap; border-radius: 999px; padding: 4px 9px; font-size: 12px; line-height: 1.2; font-weight: 800; }
.badge-root { background: #452f24; color: #fff; }
.badge-standard { background: #eee5dc; color: #6a4d3b; }
.status-active { background: #e8f6ed; color: var(--green); }
.status-inactive { background: #f6e8e6; color: var(--red); }
.record-note { color: var(--muted); font-size: 12px; }
.actions { white-space: nowrap; }
.text-link { display: inline-block; margin-right: 10px; border: 0; padding: 0; color: #725342; background: transparent; cursor: pointer; font: inherit; font-size: 13px; font-weight: 800; text-decoration: underline; text-underline-offset: 3px; }
.text-link:hover { color: var(--espresso); }
.text-danger { color: var(--red); }
.inline-form { display: inline; }
.login-summary { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 22px; padding: 13px 15px; border-radius: 8px; background: #f8f2eb; color: var(--muted); font-size: 13px; }
.login-summary strong { color: var(--espresso); }
.empty-state { padding: 32px; color: var(--muted); text-align: center; }
.login-wrap { min-height: calc(100vh - 224px); display: grid; place-items: center; }
.login-card { width: min(450px, 100%); padding: 40px; border: 1px solid rgba(125,91,68,.14); border-radius: 16px; background: rgba(255,253,249,.98); box-shadow: var(--shadow); }
.login-card h1 { font-size: 31px; }
.login-card form { margin-top: 25px; }
.login-card label:not(:first-child) { margin-top: 17px; }
.textarea { width: 100%; min-height: 112px; padding: 10px 12px; resize: vertical; border: 1px solid #d8cbbd; border-radius: 8px; outline: none; background: #fff; color: var(--ink); font: inherit; transition: border-color .16s, box-shadow .16s; }
.textarea:focus { border-color: var(--coffee); box-shadow: 0 0 0 3px rgba(114,83,66,.15); }
.coffee-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.coffee-form-grid .span-two { grid-column: 1 / -1; }
.check-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 11px; margin-top: 8px; }
.check-option { display: flex; align-items: center; gap: 8px; min-height: 42px; padding: 9px 10px; border: 1px solid #e0d4c7; border-radius: 8px; color: #5c4637; background: #fffaf5; font-size: 13px; font-weight: 700; }
.check-option input { width: 16px; min-height: 16px; margin: 0; accent-color: var(--coffee); }
.input-with-action { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; }
.place-candidates { display: grid; gap: 7px; margin-top: 10px; padding: 10px; border: 1px solid #d9cbbd; border-radius: 9px; background: #fffaf5; }
.place-candidate { width: 100%; min-height: 42px; padding: 9px 11px; border: 1px solid #e3d7cb; border-radius: 7px; color: var(--espresso); background: #fff; cursor: pointer; font: inherit; font-size: 13px; font-weight: 700; line-height: 1.4; text-align: left; }
.place-candidate:hover, .place-candidate:focus { border-color: var(--coffee); background: #fff7ef; outline: none; }
.geocode-preview { overflow: hidden; min-height: 230px; border: 1px solid #decdbd; border-radius: 10px; background: #f7f2ec; }
#geocodeMap { width: 100%; height: 230px; }
.footer { padding: 21px; color: #775f50; font-size: 13px; text-align: center; }
@media (max-width: 900px) { .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .topbar { min-height: 74px; padding: 12px 22px; flex-wrap: wrap; }.brand { font-size: 26px; }.admin-nav { order: 3; flex-basis: 100%; }.topbar-meta > span:first-child { display: none; }.welcome { padding-left: 0; border: 0; }.content { width: min(100% - 28px, 1180px); padding-top: 37px; }.page-heading { align-items: flex-start; flex-direction: column; gap: 16px; }.panel-heading { padding: 15px 17px; }.admin-form { padding: 20px 17px; }.form-grid, .coffee-form-grid, .check-grid { grid-template-columns: 1fr; gap: 16px; }.input-with-action { grid-template-columns: 1fr; }.login-card { padding: 30px 24px; }.record-note { display: none; } }
