:root {
  --sea: #0f7fa6;
  --sea-dark: #0a5f7d;
  --sea-light: #e6f3f8;
  --accent: #f08c2e;
  --accent-dark: #d97614;
  --sand: #f6f4ef;
  --ink: #22333f;
  --muted: #6b7c88;
  --line: #e2e8ec;
  --card: #ffffff;
  --ok: #2e9e5b;
  --warn: #e6a23c;
  --danger: #d64545;
  --radius: 12px;
  --shadow: 0 2px 10px rgba(20, 60, 80, .08);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--sand);
  font-size: 15px;
  line-height: 1.7;
}
a { color: var(--sea); text-decoration: none; }
a:hover { color: var(--sea-dark); }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { line-height: 1.35; margin: 0 0 .6em; }
.container { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.main { padding: 20px 16px 48px; min-height: 60vh; }

.topbar { background: var(--sea-dark); color: #fff; font-size: 13px; }
.topbar .container { padding: 6px 16px; }

.site-header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.header-in { display: flex; align-items: center; gap: 14px; min-height: 58px; position: relative; }
.logo { font-size: 20px; font-weight: 700; color: var(--sea-dark); white-space: nowrap; }
.nav { display: flex; align-items: center; gap: 2px; flex: 1; flex-wrap: wrap; }
.nav > a { padding: 6px 9px; border-radius: 8px; color: var(--ink); font-size: 14.5px; white-space: nowrap; }
.nav > a:hover { background: var(--sea-light); color: var(--sea-dark); }
.nav > a.active { background: var(--sea); color: #fff; }
.nav-user { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.nav-toggle { display: none; background: none; border: 1px solid var(--line); border-radius: 8px; font-size: 18px; padding: 2px 10px; cursor: pointer; }
.search-mini { display: flex; margin-left: 8px; }
.search-mini input { border: 1px solid var(--line); border-right: 0; border-radius: 8px 0 0 8px; padding: 5px 10px; font-size: 13.5px; width: 130px; outline: none; }
.search-mini input:focus { border-color: var(--sea); }
.search-mini button { border: 1px solid var(--line); background: var(--sea-light); border-radius: 0 8px 8px 0; cursor: pointer; padding: 0 10px; }
.inline { display: inline; }
.linklike { background: none; border: 0; color: var(--sea); cursor: pointer; padding: 0; font-size: 14px; }
.linklike:hover { text-decoration: underline; }

.flash { margin: 12px 0; padding: 10px 14px; border-radius: 10px; font-size: 14px; }
.flash-ok { background: #e8f6ee; color: #1d7a43; border: 1px solid #bfe6cf; }
.flash-warn { background: #fdf6e7; color: #96660f; border: 1px solid #f0dcae; }
.flash-err { background: #fdecec; color: #a33; border: 1px solid #f3c4c4; }
.admin-main > .flash { margin: 12px 20px 0; }

.btn { display: inline-block; border: 1px solid transparent; border-radius: 9px; padding: 8px 18px; font-size: 14.5px; cursor: pointer; background: #eef2f4; color: var(--ink); }
.btn:hover { filter: brightness(.97); }
.btn-primary { background: var(--sea); color: #fff; }
.btn-accent { background: var(--accent); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-sm { padding: 4px 12px; font-size: 13px; border-radius: 7px; }
.btn-ghost { background: #fff; border-color: var(--line); }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 26px 0 12px; }
.section-head h2 { font-size: 20px; margin: 0; }
.section-head .more { font-size: 13.5px; }

.hero { position: relative; border-radius: 16px; overflow: hidden; height: 320px; box-shadow: var(--shadow); }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .8s; background-size: cover; background-position: center; display: flex; align-items: flex-end; }
.hero-slide.on { opacity: 1; }
.hero-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(6, 40, 56, 0) 30%, rgba(6, 40, 56, .72)); }
.hero-text { position: relative; z-index: 2; color: #fff; padding: 26px 30px; }
.hero-text h2 { font-size: 26px; margin: 0 0 6px; text-shadow: 0 1px 6px rgba(0,0,0,.4); }
.hero-text p { margin: 0; opacity: .92; }
.hero-dots { position: absolute; right: 18px; bottom: 16px; z-index: 3; display: flex; gap: 6px; }
.hero-dots button { width: 9px; height: 9px; border-radius: 50%; border: 0; background: rgba(255,255,255,.5); cursor: pointer; padding: 0; }
.hero-dots button.on { background: #fff; }

.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 18px 0; }
.stat { text-align: center; padding: 14px 6px; }
.stat b { display: block; font-size: 22px; color: var(--sea-dark); }
.stat span { font-size: 13px; color: var(--muted); }

.grid { display: grid; gap: 14px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.tile { padding: 16px; display: block; color: var(--ink); transition: transform .15s; }
.tile:hover { transform: translateY(-2px); color: var(--ink); }
.tile .ico { font-size: 26px; }
.tile h3 { font-size: 16px; margin: 8px 0 4px; }
.tile p { margin: 0; font-size: 13px; color: var(--muted); }

.list-card { padding: 0; overflow: hidden; }
.list-item { display: flex; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); align-items: center; }
.list-item:last-child { border-bottom: 0; }
.list-item .t { flex: 1; min-width: 0; }
.list-item .t a { color: var(--ink); font-size: 14.5px; }
.list-item .t a:hover { color: var(--sea); }
.list-item .d { color: var(--muted); font-size: 12.5px; white-space: nowrap; }
.list-item .thumb { width: 84px; height: 58px; object-fit: cover; border-radius: 8px; flex: none; }

.badge { display: inline-block; padding: 1px 8px; border-radius: 20px; font-size: 12px; background: var(--sea-light); color: var(--sea-dark); white-space: nowrap; }
.badge-accent { background: #fdeedd; color: var(--accent-dark); }
.badge-ok { background: #e8f6ee; color: #1d7a43; }
.badge-warn { background: #fdf6e7; color: #96660f; }
.badge-err { background: #fdecec; color: #a33; }
.badge-gray { background: #eef1f3; color: var(--muted); }

.price { color: var(--accent-dark); font-weight: 700; }

.page-head { margin: 6px 0 16px; }
.page-head h1 { font-size: 24px; margin: 0 0 4px; }
.page-head p { margin: 0; color: var(--muted); font-size: 14px; }

.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 12px 0 18px; }
.tabs a { padding: 6px 14px; border-radius: 20px; background: #fff; border: 1px solid var(--line); color: var(--ink); font-size: 14px; }
.tabs a.active { background: var(--sea); border-color: var(--sea); color: #fff; }

.filter-bar { display: flex; gap: 10px; flex-wrap: wrap; margin: 0 0 16px; }
.filter-bar input[type=search], .filter-bar select { padding: 8px 12px; border: 1px solid var(--line); border-radius: 9px; font-size: 14px; background: #fff; outline: none; }

.article-body { font-size: 15.5px; line-height: 1.95; }
.article-body img { border-radius: 10px; margin: 10px 0; }
.article-meta { color: var(--muted); font-size: 13px; margin: 6px 0 16px; display: flex; gap: 14px; flex-wrap: wrap; }

.gallery-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.gallery-grid a { position: relative; border-radius: 10px; overflow: hidden; aspect-ratio: 4/3; }
.gallery-grid img { width: 100%; height: 100%; object-fit: cover; transition: transform .25s; }
.gallery-grid a:hover img { transform: scale(1.05); }
.gallery-grid .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 10px 6px; color: #fff; font-size: 12.5px; background: linear-gradient(transparent, rgba(0,0,0,.6)); }

.merchant-card { padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.merchant-card .cover { height: 130px; object-fit: cover; border-radius: 10px; background: var(--sea-light); }
.merchant-card h3 { font-size: 15.5px; margin: 0; }
.merchant-card .meta { font-size: 12.5px; color: var(--muted); }

.post-card { padding: 14px 16px; margin-bottom: 12px; }
.post-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.avatar { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; background: var(--sea-light); }
.post-head .who b { font-size: 14px; }
.post-head .who span { display: block; font-size: 12px; color: var(--muted); }
.post-content { white-space: pre-wrap; font-size: 14.5px; }
.post-img { margin-top: 8px; border-radius: 10px; max-height: 320px; object-fit: cover; }
.post-actions { margin-top: 10px; display: flex; gap: 14px; font-size: 13px; }
.replies { margin-top: 12px; border-top: 1px dashed var(--line); padding-top: 10px; }
.reply { padding: 7px 0; font-size: 13.5px; border-bottom: 1px dashed var(--line); }
.reply:last-child { border-bottom: 0; }
.reply b { color: var(--sea-dark); }

.form-row { margin-bottom: 14px; }
.form-row label { display: block; font-size: 13.5px; color: var(--muted); margin-bottom: 5px; }
.form-row input[type=text], .form-row input[type=password], .form-row input[type=number], .form-row input[type=search],
.form-row input[type=email], .form-row input[type=tel], .form-row select, .form-row textarea {
  width: 100%; padding: 9px 12px; border: 1px solid var(--line); border-radius: 9px; font-size: 14.5px; font-family: inherit; outline: none; background: #fff;
}
.form-row textarea { min-height: 110px; resize: vertical; }
.form-row input:focus, .form-row textarea:focus, .form-row select:focus { border-color: var(--sea); }
.form-card { max-width: 420px; margin: 30px auto; padding: 26px; }
.form-card.wide { max-width: 720px; }
.form-card h1 { font-size: 20px; text-align: center; }
.form-hint { font-size: 12.5px; color: var(--muted); }

.pagination { display: flex; gap: 6px; justify-content: center; margin: 22px 0 6px; flex-wrap: wrap; }
.pagination a, .pagination span { padding: 5px 11px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font-size: 13.5px; color: var(--ink); }
.pagination span.current { background: var(--sea); border-color: var(--sea); color: #fff; }
.pagination span:not(.current):not([class]) { border: 0; background: none; }

.empty { text-align: center; color: var(--muted); padding: 44px 10px; font-size: 14px; }
.empty .big { font-size: 34px; display: block; margin-bottom: 8px; }

.two-col { display: grid; grid-template-columns: 1fr 320px; gap: 18px; align-items: start; }
.side-box { padding: 14px 16px; margin-bottom: 14px; }
.side-box h3 { font-size: 15px; margin-bottom: 10px; }
.side-box .list-item { padding: 8px 0; border-bottom: 1px dashed var(--line); }
.side-box .list-item:last-child { border-bottom: 0; }

.weather-card { padding: 14px 16px; margin-bottom: 14px; background: linear-gradient(135deg, var(--sea), var(--sea-dark)); color: #fff; border-radius: var(--radius); }
.weather-card .temp { font-size: 30px; font-weight: 700; }
.weather-card .cond { font-size: 14px; opacity: .92; }
.weather-card a { color: #fff; text-decoration: underline; font-size: 12.5px; }

.phone-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.phone-card { padding: 14px; text-align: center; }
.phone-card .num { font-size: 21px; font-weight: 700; color: var(--sea-dark); letter-spacing: .5px; }
.phone-card .nm { font-size: 14px; margin-top: 2px; }
.phone-card .rk { font-size: 12px; color: var(--muted); }

.guide-card { padding: 16px; margin-bottom: 12px; }
.guide-card h3 { font-size: 16px; margin-bottom: 8px; }
.guide-card .kv { font-size: 13.5px; margin: 4px 0; }
.guide-card .kv b { color: var(--muted); font-weight: 600; margin-right: 6px; }
.guide-card pre { white-space: pre-wrap; font-family: inherit; font-size: 13.5px; margin: 4px 0; background: var(--sea-light); padding: 8px 12px; border-radius: 8px; }

.match-card { padding: 14px; text-align: center; }
.match-card .photo { width: 92px; height: 92px; border-radius: 50%; object-fit: cover; margin: 0 auto 8px; background: var(--sea-light); }
.match-card h3 { font-size: 15px; margin: 0 0 4px; }
.match-card .tags { display: flex; gap: 5px; justify-content: center; flex-wrap: wrap; }

.detail-head { padding: 20px 22px 6px; }
.detail-body { padding: 0 22px 20px; }
.contact-box { background: var(--sea-light); border: 1px dashed var(--sea); border-radius: 10px; padding: 12px 16px; margin: 14px 0; font-size: 14.5px; }

.site-footer { background: #17323e; color: #cfdde3; margin-top: 40px; font-size: 13.5px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 22px; padding: 30px 16px; }
.footer-grid h4 { color: #fff; font-size: 15px; }
.footer-grid a { display: block; color: #a9c2cc; padding: 3px 0; }
.footer-grid a:hover { color: #fff; }
.footer-bar { border-top: 1px solid rgba(255,255,255,.12); padding: 12px 0; font-size: 12.5px; color: #8fa8b2; }

.admin-body { background: #eef2f4; }
.admin-wrap { display: flex; min-height: 100vh; }
.admin-side { width: 210px; background: #17323e; color: #cfdde3; flex: none; }
.admin-logo { padding: 16px; font-weight: 700; color: #fff; font-size: 15px; border-bottom: 1px solid rgba(255,255,255,.1); }
.admin-side nav { padding: 8px 0 30px; }
.side-group { padding: 12px 16px 4px; font-size: 12px; color: #7d99a4; letter-spacing: 1px; }
.admin-side nav a, .admin-side nav button { display: block; width: 100%; text-align: left; padding: 7px 16px; color: #cfdde3; font-size: 14px; background: none; border: 0; cursor: pointer; }
.admin-side nav a:hover, .admin-side nav button:hover { background: rgba(255,255,255,.08); color: #fff; }
.admin-side nav a.active { background: var(--sea); color: #fff; }
.admin-main { flex: 1; min-width: 0; }
.admin-top { display: flex; align-items: center; gap: 12px; background: #fff; border-bottom: 1px solid var(--line); padding: 12px 20px; position: sticky; top: 0; z-index: 10; }
.admin-top h1 { font-size: 17px; margin: 0; flex: 1; }
.admin-top .nav-toggle { display: none; }
.admin-who { font-size: 13px; color: var(--muted); }
.admin-content { padding: 20px; }

.dash-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 18px; }
.dash-card { padding: 16px; }
.dash-card b { font-size: 24px; color: var(--sea-dark); display: block; }
.dash-card span { font-size: 13px; color: var(--muted); }

.table-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; background: #fff; border-radius: 10px; overflow: hidden; font-size: 13.5px; }
table.tbl th, table.tbl td { padding: 9px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
table.tbl th { background: #f4f7f9; font-weight: 600; color: var(--muted); white-space: nowrap; }
table.tbl tr:last-child td { border-bottom: 0; }
table.tbl .ops { white-space: nowrap; }
table.tbl .ops a, table.tbl .ops button { margin-right: 8px; font-size: 13px; }
.tbl-title { max-width: 300px; }

.toolbar { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; align-items: center; }
.toolbar .spacer { flex: 1; }

.review-item { padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: 13.5px; }
.review-item:last-child { border-bottom: 0; }
.stars { color: var(--accent); letter-spacing: 1px; }

@media (max-width: 960px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .two-col { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .phone-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .dash-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .nav-toggle { display: block; margin-left: auto; }
  .nav { display: none; position: absolute; top: 58px; left: 0; right: 0; background: #fff; flex-direction: column; align-items: stretch; padding: 10px 14px 16px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
  .nav.open { display: flex; }
  .nav > a { padding: 10px; }
  .nav-user { margin: 8px 0 0; justify-content: flex-start; }
  .search-mini { margin: 8px 0 0; }
  .search-mini input { flex: 1; width: auto; }
  .hero { height: 220px; }
  .hero-text h2 { font-size: 19px; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr; }
  .admin-side { position: fixed; left: 0; top: 0; bottom: 0; transform: translateX(-100%); transition: transform .2s; z-index: 60; overflow-y: auto; }
  .admin-side.open { transform: none; }
  .admin-top .nav-toggle { display: block; }
}
