/* ============ 上饶莱卡摄影 — 样式表（白底 · 军绿点缀） ============ */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

:root {
  --bg: #ffffff;
  --bg-soft: #f6f6f3;
  --surface: #ffffff;
  --surface-2: #f2f2ee;
  --border: #e7e7e1;
  --text: #1c1c1e;
  --text-dim: #8b8b85;
  --accent: #5f6b26;
  --accent-soft: #8a9a3f;
  --accent-bg: #f1f3e4;
  --radius: 14px;
  --tabbar-h: 60px;
}

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
  background: #efefe9;
  color: var(--text);
  line-height: 1.6;
}

/* 手机壳式容器：桌面居中，宽度如手机 */
.app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  box-shadow: 0 0 40px rgba(0,0,0,.12);
}

/* ============ 页面容器 ============ */
.pages { padding-bottom: calc(var(--tabbar-h) + 16px); }
.page { display: none; padding-bottom: 8px; }
.page.active { display: block; animation: pageIn .28s ease; }
@keyframes pageIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.page-head { padding: 22px 18px 6px; }
.page-head h1 { font-size: 24px; font-weight: 700; letter-spacing: 1px; }
.page-head p { color: var(--text-dim); font-size: 13px; margin-top: 4px; }

/* ============ 主页：大照片 + 店名 ============ */
.home-hero { width: 100%; overflow: hidden; background: var(--bg-soft); }
.home-hero-img { width: 100%; height: 46vh; object-fit: cover; display: block; }
.home-brand { padding: 24px 18px 6px; text-align: center; }
.home-name { font-size: 27px; font-weight: 800; letter-spacing: 3px; line-height: 1.3; }
.home-en { font-size: 11px; letter-spacing: 3px; color: var(--text-dim); text-transform: uppercase; margin-top: 5px; }
.home-slogan { font-size: 13px; color: var(--text-dim); margin-top: 10px; }

/* 按钮 */
.btn {
  border: 1px solid var(--border); background: transparent; color: var(--text);
  padding: 10px 18px; border-radius: 999px; font-size: 14px; cursor: pointer;
  transition: .2s; font-family: inherit;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: linear-gradient(135deg, var(--accent), #76843a); color: #fff; font-weight: 700; border: none; }
.btn-ghost { background: var(--surface); border-color: var(--border); color: var(--text); }
.btn-block { width: 100%; padding: 13px; font-size: 15px; }
.btn-small { padding: 6px 14px; font-size: 12px; border-color: var(--accent); color: var(--accent); }

/* 区块 */
.section { padding: 6px 18px 10px; }
.section-title { font-size: 18px; font-weight: 700; margin: 16px 0 8px; letter-spacing: 1px; }
.section-title::before { content: "— "; color: var(--accent); }
.section-desc { color: var(--text-dim); font-size: 13px; }
.section-head { display: flex; align-items: center; justify-content: space-between; }
.link-more { background: none; border: none; color: var(--accent); font-size: 13px; cursor: pointer; }

/* 横向滚动作品 */
.hscroll { display: flex; gap: 12px; overflow-x: auto; padding: 8px 2px 14px; scroll-snap-type: x mandatory; }
.hscroll::-webkit-scrollbar { display: none; }
.hscroll .card { flex: 0 0 42%; scroll-snap-align: start; }
.card { border-radius: var(--radius); overflow: hidden; background: var(--surface); border: 1px solid var(--border); position: relative; }
.card img { width: 100%; display: block; aspect-ratio: 4 / 5; object-fit: cover; }
.card .card-tag { position: absolute; top: 8px; left: 8px; background: rgba(0,0,0,.5); color: #fff; font-size: 11px; padding: 2px 8px; border-radius: 999px; }
.card .card-title { position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 10px 8px; background: linear-gradient(180deg, transparent, rgba(0,0,0,.65)); font-size: 13px; color: #fff; }

/* 热门套系预览 */
.pkg-preview { display: flex; gap: 12px; overflow-x: auto; padding: 8px 2px 14px; scroll-snap-type: x mandatory; }
.pkg-preview::-webkit-scrollbar { display: none; }
.pkg-card { flex: 0 0 68%; scroll-snap-align: start; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; }
.pkg-card .pkg-name { font-size: 15px; font-weight: 700; }
.pkg-card .pkg-price { color: var(--accent); font-weight: 800; font-size: 16px; margin-top: 4px; }
.pkg-card .pkg-items { font-size: 12px; color: var(--text-dim); margin-top: 8px; line-height: 1.7; }

/* 特色 */
.feature-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.feature { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 12px; }
.feature-icon { font-size: 22px; }
.feature h3 { font-size: 14px; margin: 6px 0 4px; }
.feature p { font-size: 12px; color: var(--text-dim); }

/* CTA 横幅 */
.cta-banner { margin: 16px 18px; padding: 22px 18px; text-align: center; border-radius: var(--radius); background: linear-gradient(135deg, #f1f3e4, #e4e8cf); border: 1px solid #d5dcb4; }
.cta-banner h3 { font-size: 17px; letter-spacing: 1px; color: var(--text); }
.cta-banner p { color: var(--text-dim); font-size: 12px; margin: 6px 0 14px; }

/* ============ 作品集 ============ */
.chips { display: flex; gap: 8px; padding: 14px 18px; overflow-x: auto; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: 0 0 auto; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text-dim); font-size: 13px; cursor: pointer; transition: .2s; }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 700; }

.work-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 4px 18px 20px; }
.work-item { position: relative; border-radius: var(--radius); overflow: hidden; cursor: pointer; border: 1px solid var(--border); }
.work-item img { width: 100%; display: block; aspect-ratio: 4 / 5; object-fit: cover; transition: transform .35s ease; }
.work-item .work-tag { position: absolute; top: 8px; left: 8px; background: rgba(0,0,0,.5); color: #fff; font-size: 10px; padding: 2px 8px; border-radius: 999px; }
.work-item .work-title { position: absolute; left: 0; right: 0; bottom: 0; padding: 20px 10px 8px; background: linear-gradient(180deg, transparent, rgba(0,0,0,.65)); font-size: 12px; color: #fff; }

/* ============ 套系 ============ */
.price-list { display: flex; flex-direction: column; gap: 12px; padding: 14px 18px 8px; }
.price-card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 16px; }
.price-card.hot { border-color: var(--accent); }
.price-card .hot-badge { position: absolute; top: 0; right: 16px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 0 0 8px 8px; }
.price-head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 10px; }
.price-head h3 { font-size: 17px; font-weight: 700; }
.price { color: var(--accent); font-size: 20px; font-weight: 800; }
.price small { font-size: 12px; font-weight: 400; color: var(--text-dim); }
.price-items { list-style: none; display: grid; gap: 5px; margin-bottom: 14px; }
.price-items li { font-size: 13px; color: var(--text); position: relative; padding-left: 16px; }
.price-items li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-size: 12px; top: 1px; }
.price-note { font-size: 11px; color: var(--text-dim); text-align: center; padding: 4px 18px 16px; }

/* ============ 关于 ============ */
.about-card { margin: 16px 18px 4px; text-align: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px 18px; }
.about-logo { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 18px; background: var(--accent-bg); border: 1px solid #d5dcb4; display: flex; align-items: center; justify-content: center; font-size: 30px; }
.about-card h2 { font-size: 21px; letter-spacing: 2px; }
.about-en { font-size: 11px; letter-spacing: 3px; color: var(--text-dim); margin-top: 4px; text-transform: uppercase; }
.about-text { font-size: 13px; color: var(--text-dim); margin-top: 12px; line-height: 1.8; }

/* ============ 联系卡片 ============ */
.contact-card { margin: 16px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.contact-row { display: flex; align-items: center; gap: 12px; padding: 14px 16px; }
.contact-row + .contact-row { border-top: 1px solid var(--border); }
.contact-icon { font-size: 20px; flex-shrink: 0; }
.contact-info { flex: 1; min-width: 0; }
.contact-info span { display: block; font-size: 11px; color: var(--text-dim); }
.contact-info b { font-size: 14px; font-weight: 600; word-break: break-all; }

/* ============ 我的 ============ */
.mine-head { display: flex; align-items: center; gap: 14px; padding: 26px 18px 14px; }
.mine-avatar { width: 60px; height: 60px; border-radius: 50%; background: var(--accent-bg); border: 1px solid #d5dcb4; display: flex; align-items: center; justify-content: center; font-size: 28px; }
.mine-title h2 { font-size: 20px; font-weight: 700; }
.mine-title p { font-size: 12px; color: var(--text-dim); margin-top: 3px; }
.mine-menu { margin: 10px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.mine-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 15px 16px; background: none; border: none; border-bottom: 1px solid var(--border); color: var(--text); font-size: 14px; cursor: pointer; font-family: inherit; text-align: left; }
.mine-item:last-child { border-bottom: none; }
.mine-item span { font-size: 18px; }
.mine-item b { flex: 1; font-weight: 500; }
.mine-item i { font-style: normal; color: var(--text-dim); font-size: 18px; }
.mine-item:active { background: var(--bg-soft); }
.mine-info { margin: 6px 18px 10px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; }
.mine-info p { font-size: 12px; color: var(--text-dim); line-height: 1.8; }
.mine-info b { color: var(--text); font-weight: 600; }

/* ============ 预约表单 ============ */
.booking-form { padding: 14px 18px; display: grid; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field span { font-size: 13px; color: var(--text-dim); }
.field input, .field select, .field textarea {
  background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
  padding: 12px 14px; color: var(--text); font-size: 14px; outline: none; font-family: inherit;
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); }
.field input::placeholder, .field textarea::placeholder { color: #b0b0a8; }
.form-tip { font-size: 11px; color: var(--text-dim); text-align: center; }

.booking-success { padding: 30px 24px; text-align: center; }
.success-icon { width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), #76843a); color: #fff; font-size: 32px; line-height: 64px; font-weight: 800; }
.booking-success h3 { font-size: 19px; margin-bottom: 8px; }
.booking-success p { font-size: 13px; color: var(--text-dim); margin-bottom: 18px; }

/* ============ 底部 Tab 栏 ============ */
.tabbar {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: 0;
  width: 100%; max-width: 480px; height: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
  display: flex; background: rgba(255,255,255,.96); backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border); z-index: 80;
  padding-bottom: env(safe-area-inset-bottom);
}
.tab {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; background: none; border: none; color: var(--text-dim); cursor: pointer; font-family: inherit;
}
.tab-ico { font-size: 20px; line-height: 1; }
.tab span { font-size: 11px; }
.tab.active { color: var(--accent); }
.tab.active span { font-weight: 700; }

/* ============ 灯箱 ============ */
.lightbox { position: fixed; inset: 0; background: rgba(0,0,0,.94); display: none; align-items: center; justify-content: center; z-index: 100; }
.lightbox.open { display: flex; }
.lightbox img { max-width: 92%; max-height: 78vh; border-radius: 10px; box-shadow: 0 10px 40px rgba(0,0,0,.6); }
.lb-close { position: absolute; top: 14px; right: 16px; font-size: 30px; background: none; border: none; color: #fff; cursor: pointer; z-index: 2; }
.lb-caption { position: absolute; bottom: 22px; left: 0; right: 0; text-align: center; color: #ddd; font-size: 14px; }
.lb-prev, .lb-next { position: absolute; top: 50%; transform: translateY(-50%); font-size: 40px; background: rgba(255,255,255,.08); border: none; color: #fff; width: 44px; height: 64px; border-radius: 10px; cursor: pointer; }
.lb-prev { left: 8px; } .lb-next { right: 8px; }

/* ============ Toast ============ */
.toast {
  position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + 24px); transform: translateX(-50%) translateY(20px);
  background: rgba(30,30,36,.96); color: #fff; padding: 10px 20px; border-radius: 999px;
  font-size: 13px; opacity: 0; pointer-events: none; transition: .25s; z-index: 200;
  white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* 桌面端提示外壳 */
@media (min-width: 520px) {
  body::after {
    content: "📱 手机端 H5 · 建议在手机或 DevTools 手机模式下查看";
    position: fixed; top: 12px; left: 50%; transform: translateX(-50%);
    font-size: 12px; color: #888; letter-spacing: 1px; z-index: 300;
  }
}

/* 通用隐藏 */
.hidden { display: none !important; }


/* ============ 内容管理后台 ============ */
.admin-fab {
  position: fixed; right: 16px; bottom: calc(var(--tabbar-h) + 18px);
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(30,30,36,.88); border: 1px solid rgba(255,255,255,.15);
  color: #ddd; font-size: 20px; cursor: pointer;
  z-index: 90; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 14px rgba(0,0,0,.25);
}
.admin-fab:active { transform: scale(.95); }

.admin-panel {
  position: fixed; left: 50%; bottom: 0; transform: translateX(-50%);
  width: 100%; max-width: 480px; max-height: 82vh; overflow-y: auto;
  background: #ffffff; border-radius: 20px 20px 0 0;
  border: 1px solid var(--border); border-bottom: none;
  z-index: 120; padding-bottom: env(safe-area-inset-bottom);
}
.admin-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 18px; border-bottom: 1px solid var(--border);
  position: sticky; top: 0; background: #ffffff;
}
.admin-head b { font-size: 16px; letter-spacing: 1px; }
.admin-close { background: none; border: none; color: var(--text-dim); font-size: 24px; cursor: pointer; }
.admin-body { padding: 14px 18px 6px; }
.admin-hint { font-size: 12px; color: var(--text-dim); margin-bottom: 12px; }
.admin-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.admin-field span { font-size: 12px; color: var(--text-dim); }
.admin-field input {
  background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px;
  padding: 11px 14px; color: var(--text); font-size: 14px; outline: none;
}
.admin-field input:focus { border-color: var(--accent); }
.admin-note { font-size: 11px; color: #8b8b85; line-height: 1.6; margin: 6px 0 10px; }
.admin-foot { display: flex; gap: 10px; padding: 8px 18px 20px; }
.admin-foot .btn { flex: 1; }
/* ================= 作品管理（后台） ================= */
.admin-sep { height: 1px; background: var(--border); margin: 8px 0 14px; }
.works-admin-list { max-height: 220px; overflow-y: auto; margin-bottom: 12px; border: 1px solid var(--border); border-radius: 8px; padding: 8px; }
.work-admin-row { display: flex; align-items: center; gap: 8px; padding: 6px; border-radius: 6px; }
.work-admin-row + .work-admin-row { border-top: 1px solid var(--border); }
.work-admin-row img { width: 44px; height: 44px; object-fit: cover; border-radius: 6px; flex-shrink: 0; }
.work-admin-row .wa-title { flex: 1; font-size: 12px; color: var(--text); line-height: 1.4; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wk-del { background: none; border: none; color: #e05353; font-size: 12px; cursor: pointer; flex-shrink: 0; padding: 4px 6px; }
.wk-del:hover { text-decoration: underline; }
.admin-field select { padding: 10px; border: 1px solid var(--border); border-radius: 8px; background: #fff; color: var(--text); font-size: 14px; }
