:root {
  color-scheme: light;
  --green: #087a55;
  --green-dark: #075640;
  --green-soft: #e9f7f1;
  --gold: #d79b37;
  --ink: #17352c;
  --muted: #65766f;
  --line: #dce8e2;
  --surface: #ffffff;
  --bg: #f5f8f6;
  font-family: "Microsoft YaHei UI", "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); }
button, input, select, textarea { font: inherit; }
.main-nav { display: flex; align-items: center; gap: 15px; }
.main-nav a { color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 700; }
.main-nav a:hover { color: var(--green); }
.account-area { display: flex; align-items: center; gap: 10px; }
.helper-state { padding: 7px 10px; border-radius: 999px; background: #f1f5f3; color: var(--muted); font-size: 12px; }
.account-button { min-height: 42px; padding: 0 15px; border: 1px solid var(--line); border-radius: 12px; background: white; color: var(--green-dark); cursor: pointer; font-weight: 800; }
.topbar { position: sticky; z-index: 10; top: 0; display: flex; align-items: center; justify-content: space-between; min-height: 72px; padding: 12px max(24px, calc((100vw - 1180px) / 2)); background: rgba(255,255,255,.96); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 16px; color: var(--ink); text-decoration: none; font-size: 20px; font-weight: 800; }
.brand img { width: 170px; height: 46px; object-fit: contain; object-position: left center; }
main { max-width: 1180px; margin: 0 auto; padding: 34px 24px 70px; }
.hero { display: grid; grid-template-columns: 1.35fr .8fr; gap: 48px; align-items: center; padding: 54px; background: linear-gradient(135deg, #075640 0%, #0b8660 74%, #28a778 100%); color: white; border-radius: 28px; box-shadow: 0 18px 46px rgba(7,86,64,.2); }
.eyebrow, .kicker { display: block; margin-bottom: 8px; font-weight: 800; letter-spacing: .08em; font-size: 13px; }
.hero h1 { max-width: 700px; margin: 0 0 18px; font-size: clamp(34px, 5vw, 58px); line-height: 1.1; }
.hero p { margin: 0; font-size: 17px; line-height: 1.8; color: rgba(255,255,255,.86); }
.hero-search { padding: 24px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25); border-radius: 20px; backdrop-filter: blur(8px); }
.hero-search label { display: block; margin-bottom: 10px; font-weight: 800; }
.hero-search input { width: 100%; height: 52px; padding: 0 16px; border: 0; border-radius: 12px; outline: none; box-shadow: 0 0 0 0 rgba(255,255,255,0); transition: .2s; }
.hero-search input:focus { box-shadow: 0 0 0 4px rgba(255,255,255,.22); }
.result-count { margin-top: 12px; color: rgba(255,255,255,.8); font-size: 14px; }
.status-strip { display: grid; grid-template-columns: repeat(4, 1fr) auto; gap: 1px; margin-top: 20px; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: var(--line); }
.status-strip > div { padding: 14px 18px; background: white; }
.status-strip span { display: block; margin-bottom: 4px; color: var(--muted); font-size: 12px; }
.status-strip strong { font-size: 15px; }
.status-strip button { padding: 0 18px; border: 0; background: #fff4dc; color: #8a5b10; cursor: pointer; font-weight: 800; }
.section { padding-top: 52px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.section-heading h2, .download-panel h2 { margin: 0; font-size: 30px; }
.kicker { color: var(--green); }
.text-button { border: 0; background: transparent; color: var(--green); cursor: pointer; font-weight: 800; }
.categories { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.category { min-height: 80px; padding: 14px; border: 1px solid var(--line); border-radius: 16px; background: white; color: var(--ink); text-align: left; cursor: pointer; transition: .18s ease; }
.category span { display: block; margin-bottom: 7px; font-size: 22px; }
.category:hover, .category.active { transform: translateY(-2px); border-color: var(--green); background: var(--green-soft); box-shadow: 0 8px 22px rgba(7,86,64,.1); }
.featured-toggle { display: flex; gap: 8px; align-items: center; color: var(--muted); }
.skill-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 18px; }
.skill-card { display: flex; min-height: 245px; flex-direction: column; padding: 22px; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); cursor: pointer; transition: .18s ease; }
.skill-card:hover, .skill-card:focus { transform: translateY(-4px); border-color: #9bcbb7; box-shadow: 0 16px 34px rgba(23,53,44,.11); outline: none; }
.skill-meta { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; }
.skill-meta span { font-size: 22px; }
.skill-meta em { font-style: normal; }
.skill-meta b { margin-left: auto; padding: 4px 8px; border-radius: 999px; background: #fff4dc; color: #9a6412; font-size: 12px; }
.skill-meta b.unlocked { background: var(--green-soft); color: var(--green-dark); }
.skill-card h3 { margin: 18px 0 10px; font-size: 20px; }
.skill-card p { flex: 1; margin: 0; color: var(--muted); line-height: 1.7; font-size: 14px; }
.skill-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 20px; }
.skill-footer code { max-width: 68%; overflow: hidden; color: #789087; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.skill-footer button { border: 0; background: transparent; color: var(--green); cursor: pointer; font-weight: 800; }
.empty { padding: 50px; border: 1px dashed #baccc4; border-radius: 18px; text-align: center; color: var(--muted); }
.download-panel { display: flex; align-items: center; justify-content: space-between; gap: 36px; margin-top: 60px; padding: 38px; border-radius: 24px; background: #fff; border: 1px solid var(--line); }
.download-panel p { max-width: 720px; margin: 14px 0 0; color: var(--muted); line-height: 1.8; }
.button { display: inline-flex; min-height: 44px; align-items: center; justify-content: center; padding: 0 20px; border: 1px solid transparent; border-radius: 12px; text-decoration: none; cursor: pointer; font-weight: 800; }
.button.primary { background: var(--green); color: white; }
.button.primary:hover { background: var(--green-dark); }
.button.secondary { border-color: var(--line); background: white; color: var(--green-dark); }
.button.full { width: 100%; min-height: 52px; }
footer { padding: 30px 20px 40px; text-align: center; color: #789087; font-size: 13px; }
.service-statement { margin-top: 30px; padding: 28px 32px; border: 1px solid #ead8b9; border-radius: 22px; background: #fffaf0; }
.service-statement h2 { margin: 0 0 12px; font-size: 22px; }
.service-statement p { margin: 8px 0 0; color: #6e624f; line-height: 1.75; font-size: 14px; }
.miki-float { position: fixed; right: 20px; bottom: 20px; z-index: 30; display: flex; align-items: center; gap: 10px; padding: 9px 14px 9px 9px; border: 0; border-radius: 999px; background: var(--green-dark); color: white; box-shadow: 0 12px 30px rgba(7,86,64,.28); cursor: pointer; text-align: left; font-weight: 800; }
.miki-float img { width: 44px; height: 44px; border: 2px solid white; border-radius: 50%; object-fit: cover; }
.dialog { width: min(840px, calc(100vw - 32px)); max-height: min(86vh, 850px); padding: 34px; border: 0; border-radius: 24px; color: var(--ink); box-shadow: 0 28px 80px rgba(0,0,0,.26); }
.dialog::backdrop { background: rgba(7,31,23,.6); backdrop-filter: blur(3px); }
.dialog-close { position: absolute; top: 14px; right: 16px; width: 38px; height: 38px; border: 0; border-radius: 50%; background: #edf3f0; color: var(--ink); cursor: pointer; font-size: 24px; }
.detail-category { color: var(--green); font-weight: 800; }
.dialog h2 { margin: 10px 0; padding-right: 42px; font-size: 30px; }
.detail-id { color: #789087; }
.detail-description { margin: 18px 0 24px; color: var(--muted); line-height: 1.8; }
.detail-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.detail-grid section { padding: 16px; border-radius: 14px; background: var(--bg); }
.detail-grid h3 { margin: 0 0 10px; font-size: 15px; }
.detail-grid ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 13px; line-height: 1.75; }
.safe-note { margin: 20px 0; padding: 14px; border-left: 4px solid var(--green); background: var(--green-soft); color: #315e4e; font-size: 13px; line-height: 1.7; }
.small-dialog { width: min(480px, calc(100vw - 32px)); text-align: center; }
.small-dialog p { color: var(--muted); line-height: 1.8; }
.install-icon { font-size: 50px; }
.skill-dialog { width: min(1080px, calc(100vw - 32px)); }
.skill-layout { display: grid; grid-template-columns: minmax(0,1.35fr) minmax(290px,.65fr); gap: 22px; }
.skill-actions { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; margin-top: 18px; }
.skill-actions .full-row { grid-column: 1 / -1; }
.price-note { margin: 12px 0; color: #8a5b10; font-size: 13px; }
.preview-box, .chat-box, .portal-card { padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: white; }
.preview-box { margin-top: 16px; background: #f8fbf9; }
.preview-box h3, .chat-box h3, .portal-card h3 { margin: 0 0 10px; }
.preview-box p, .chat-box p, .portal-card p { color: var(--muted); line-height: 1.65; }
.chat-box { position: sticky; top: 0; align-self: start; background: var(--bg); }
.chat-modes { display: grid; grid-template-columns: repeat(3,1fr); gap: 6px; margin-bottom: 10px; }
.chat-modes button { padding: 8px 4px; border: 1px solid var(--line); border-radius: 9px; background: white; cursor: pointer; font-size: 12px; }
.chat-modes button.active { border-color: var(--green); background: var(--green-soft); color: var(--green-dark); font-weight: 800; }
textarea, .field { width: 100%; padding: 11px 12px; border: 1px solid #cbdad3; border-radius: 10px; background: white; outline: none; }
textarea:focus, .field:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgba(8,122,85,.1); }
textarea { min-height: 96px; resize: vertical; }
.chat-answer { min-height: 76px; margin: 10px 0; padding: 12px; border-radius: 10px; background: white; color: #315e4e; font-size: 13px; line-height: 1.7; }
.auth-dialog { width: min(760px, calc(100vw - 32px)); }
.auth-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 20px; }
.auth-grid form { padding: 20px; border: 1px solid var(--line); border-radius: 16px; }
.auth-grid label, .form-grid label { display: grid; gap: 6px; margin: 10px 0; color: var(--muted); font-size: 13px; }
.page-dialog { width: min(1040px, calc(100vw - 32px)); }
.page-heading { margin-bottom: 20px; }
.page-heading h2 { margin: 0 0 8px; }
.page-heading p { margin: 0; color: var(--muted); line-height: 1.7; }
.portal-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 14px; }
.portal-card .card-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.mini-button { min-height: 36px; padding: 0 12px; border: 1px solid var(--line); border-radius: 9px; background: white; color: var(--green-dark); cursor: pointer; font-weight: 700; }
.mini-button.primary { border-color: var(--green); background: var(--green); color: white; }
.mini-button.danger { color: #aa3232; }
.qr-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
.qr-card { padding: 16px; border: 1px solid var(--line); border-radius: 16px; text-align: center; }
.qr-card img { width: 100%; max-height: 240px; object-fit: contain; border-radius: 10px; }
.admin-user { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.admin-user .wide { grid-column: 1 / -1; }
.admin-user select, .admin-user input { width: 100%; padding: 9px; border: 1px solid var(--line); border-radius: 8px; }
.check-list { display: grid; grid-template-columns: repeat(2,1fr); gap: 8px; padding: 0; list-style: none; }
.check-list li { padding: 11px 12px; border-radius: 10px; background: var(--bg); color: var(--muted); }
.badge { display: inline-block; padding: 4px 8px; border-radius: 999px; background: var(--green-soft); color: var(--green-dark); font-size: 12px; font-weight: 800; }
.warning { padding: 12px; border-radius: 10px; background: #fff4dc; color: #7b581e; font-size: 13px; line-height: 1.6; }
.toast { position: fixed; left: 50%; bottom: 28px; z-index: 40; transform: translate(-50%, 20px); padding: 12px 18px; border-radius: 10px; background: #17352c; color: white; opacity: 0; pointer-events: none; transition: .2s; }
.toast.show { transform: translate(-50%, 0); opacity: 1; }
@media (max-width: 900px) {
  .main-nav { display: none; }
  .hero { grid-template-columns: 1fr; padding: 36px; }
  .status-strip { grid-template-columns: repeat(2,1fr); }
  .status-strip button { min-height: 54px; grid-column: 1 / -1; }
  .categories { grid-template-columns: repeat(3, 1fr); }
  .skill-grid { grid-template-columns: repeat(2, 1fr); }
  .detail-grid { grid-template-columns: 1fr; }
  .skill-layout, .portal-grid { grid-template-columns: 1fr; }
  .chat-box { position: static; }
}
@media (max-width: 620px) {
  .topbar { min-height: 62px; padding: 9px 14px; }
  .brand img { width: 118px; height: 38px; }
  .brand span { display: none; }
  .topbar .button { min-height: 38px; padding: 0 12px; font-size: 12px; }
  .helper-state { display: none; }
  .account-button { max-width: 132px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  main { padding: 18px 14px 48px; }
  .hero { padding: 28px 22px; border-radius: 20px; }
  .hero h1 { font-size: 34px; }
  .categories { grid-template-columns: repeat(2, 1fr); }
  .skill-grid { grid-template-columns: 1fr; }
  .download-panel { align-items: stretch; flex-direction: column; padding: 26px 22px; }
  .dialog { padding: 26px 20px; }
  .auth-grid, .qr-grid, .check-list, .admin-user { grid-template-columns: 1fr; }
  .admin-user .wide { grid-column: auto; }
  .miki-float { right: 10px; bottom: 10px; }
  .miki-float span { display: none; }
}
