:root {
  --paper: #fbf8f1;
  --paper-deep: #f3ecdd;
  --card: rgba(255, 253, 248, 0.96);
  --ink: #2f5d42;
  --ink-deep: #1f4434;
  --text: #2f2a24;
  --muted: #7d7161;
  --gold: #b9852b;
  --gold-soft: #f4e5c7;
  --sage: #e6eee1;
  --line: rgba(224, 205, 175, 0.62);
  --shadow: 0 12px 28px rgba(115, 90, 52, 0.08);
}

* { box-sizing: border-box; }
html { background: var(--paper); }
body {
  margin: 0;
  color: var(--text);
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(205, 171, 118, 0.16), transparent 24%),
    radial-gradient(circle at 92% 18%, rgba(95, 127, 96, 0.10), transparent 20%),
    linear-gradient(180deg, #f7f3ec 0%, #fbf9f4 44%, #f6f2ea 100%);
}

a { color: inherit; text-decoration: none; }
button, input { font: inherit; }

.page {
  min-height: 100vh;
  padding: 11px 12px 28px;
}

.page-title {
  margin: 2px 0 9px;
  text-align: center;
  font-size: 23px;
  line-height: 1.25;
  font-weight: 800;
  color: #325f43;
  letter-spacing: 1px;
}

.hero-panel,
.card,
.soft-card {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
  background: rgba(255, 253, 248, 0.96);
  box-shadow: 0 6px 14px rgba(115, 90, 52, 0.08);
}

.hero-panel {
  margin-bottom: 12px;
  padding: 14px 14px 15px;
  border: 1px solid rgba(224, 205, 175, 0.48);
  background:
    linear-gradient(180deg, rgba(255, 252, 245, 0.98), rgba(251, 247, 239, 0.96)),
    radial-gradient(circle at bottom right, rgba(118, 146, 119, 0.08), transparent 24%);
}

.hero-panel::before,
.card::before,
.soft-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(229, 214, 189, 0.10) 1px, transparent 1px),
    linear-gradient(90deg, rgba(229, 214, 189, 0.10) 1px, transparent 1px);
  background-size: 12px 12px;
  opacity: 0.42;
}

.hero-panel::after {
  content: "";
  position: absolute;
  right: -12px;
  bottom: -9px;
  width: 130px;
  height: 80px;
  background:
    radial-gradient(circle at 65% 20%, rgba(86, 110, 84, 0.12), transparent 52%),
    linear-gradient(180deg, rgba(181, 195, 173, 0.15), rgba(255,255,255,0));
  border-radius: 50%;
}

.card {
  margin-bottom: 12px;
  padding: 13px;
  border: 1px solid rgba(224, 205, 175, 0.52);
}

.soft-card {
  padding: 11px;
  border: 1px solid rgba(225, 211, 186, 0.52);
}

.panel-corner::before,
.panel-corner::after,
.panel-corner-bottom::before,
.panel-corner-bottom::after {
  content: "";
  position: absolute;
  width: 11px;
  height: 11px;
  border-color: #d9c09a;
  border-style: solid;
  pointer-events: none;
  z-index: 2;
}

.panel-corner::before {
  top: 7px;
  left: 7px;
  border-width: 2px 0 0 2px;
}

.panel-corner::after {
  top: 7px;
  right: 7px;
  border-width: 2px 2px 0 0;
}

.panel-corner-bottom::before {
  bottom: 7px;
  left: 7px;
  border-width: 0 0 2px 2px;
}

.panel-corner-bottom::after {
  bottom: 7px;
  right: 7px;
  border-width: 0 2px 2px 0;
}

.section-title {
  position: relative;
  z-index: 1;
  color: #2f5d42;
  font-size: 19px;
  font-weight: 800;
  line-height: 1.35;
}

.section-desc {
  position: relative;
  z-index: 1;
  margin-top: 4px;
  color: #7d7161;
  line-height: 1.7;
  font-size: 13px;
}

.section-header {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 9px;
}

.section-link {
  color: #81715a;
  font-size: 13px;
}

.m-title-small {
  font-size: 17px;
}

.record-card,
.action-card,
.metric-card {
  position: relative;
  z-index: 1;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(228, 214, 189, 0.74);
}

.record-card {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 10px;
}

.m-flat-card {
  padding: 0;
  border: none;
  background: transparent;
}

.record-body {
  flex: 1;
  min-width: 0;
}

.record-title {
  color: #2f2a24;
  font-size: 16px;
  line-height: 1.4;
  font-weight: 700;
}

.record-meta,
.record-submeta {
  margin-top: 4px;
  color: #7d7161;
  font-size: 12px;
  line-height: 1.55;
}

.record-submeta {
  color: #4f7c5a;
}

.primary-btn,
.secondary-btn,
.ghost-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 45px;
  padding: 0 15px;
  border-radius: 11px;
  font-size: 17px;
  font-weight: 700;
  position: relative;
  z-index: 1;
  border: none;
}

.primary-btn {
  color: #fff8ef;
  background: linear-gradient(180deg, #4f765a 0%, #325f43 100%);
  box-shadow: 0 5px 9px rgba(50, 95, 67, 0.22);
}

.secondary-btn {
  color: #325f43;
  background: linear-gradient(180deg, #fffdfa 0%, #f8f1e4 100%);
  border: 1px solid rgba(220, 197, 154, 0.74);
}

.icon-grid {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  position: relative;
  z-index: 1;
}

.icon-grid-item {
  flex: 1;
  text-align: center;
  padding: 6px 4px;
  position: relative;
}

.icon-grid-item + .icon-grid-item::before {
  content: "";
  position: absolute;
  left: -3px;
  top: 10px;
  width: 1px;
  height: 60px;
  background: rgba(223, 210, 190, 0.8);
}

.round-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 7px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 800;
}

.round-green {
  background: #e6eee1;
  color: #325f43;
}

.round-gold {
  background: #f7ecd1;
  color: #bb8220;
}

.item-title {
  display: block;
  font-size: 13px;
  color: #2d2a25;
}

.item-desc {
  display: block;
  margin-top: 3px;
  font-size: 11px;
  color: #8a7f72;
  line-height: 1.5;
}

.ornament-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin: 9px 0 12px;
  color: #325f43;
  font-size: 16px;
  font-weight: 700;
}

.ornament-line::before,
.ornament-line::after {
  content: "";
  width: 82px;
  height: 1px;
  background: linear-gradient(90deg, rgba(215, 194, 159, 0), rgba(215, 194, 159, 0.95), rgba(215, 194, 159, 0));
}

.card-grid {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 9px;
}

.card-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card-grid-item {
  flex: 1;
  min-width: 0;
}

.action-card {
  padding: 11px 10px;
}

.action-card .round-icon {
  margin-left: 0;
}

.step-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 3px;
  margin-bottom: 12px;
  position: relative;
  z-index: 1;
}

.m-step-row-compact {
  margin: 4px 0 0;
}

.step-item {
  flex: 1;
  text-align: center;
}

.step-dot {
  width: 36px;
  height: 36px;
  margin: 0 auto 6px;
  border-radius: 50%;
  border: 1px solid #d3c3aa;
  color: #9b8c77;
  background: #fffefb;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.step-dot.active {
  background: #325f43;
  border-color: #325f43;
  color: #fffdf8;
}

.step-label {
  color: #5c5448;
  font-size: 12px;
}

.step-link {
  flex: 0 0 36px;
  height: 1px;
  background: #496c52;
  margin-bottom: 21px;
}

.image-stage {
  padding: 9px;
  border-radius: 12px;
  background: rgba(255, 253, 248, 0.95);
  border: 1px solid rgba(224, 205, 175, 0.75);
  position: relative;
}

.m-upload-stage {
  min-height: 320px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  cursor: pointer;
  background:
    linear-gradient(rgba(229, 214, 189, 0.14) 1px, transparent 1px),
    linear-gradient(90deg, rgba(229, 214, 189, 0.14) 1px, transparent 1px),
    rgba(255, 253, 248, 0.95);
  background-size: 13px 13px;
}

.m-upload-stage input {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.m-upload-stage strong {
  color: #325f43;
  font-size: 22px;
}

.m-upload-stage small {
  color: #7d7161;
  font-size: 13px;
}

.m-upload-cloud {
  width: 76px;
  height: 76px;
  border-radius: 24px;
  display: grid;
  place-items: center;
  color: #fff8ef;
  background: linear-gradient(180deg, #668968, #325f43);
  font-size: 28px;
  font-weight: 800;
}

.bottom-actions {
  display: flex;
  gap: 9px;
  margin-top: 12px;
}

.bottom-actions > * {
  flex: 1;
}

.mountain-strip {
  position: relative;
  z-index: 1;
  height: 60px;
  margin-top: 9px;
  border-radius: 9px;
  background:
    linear-gradient(180deg, rgba(163, 184, 158, 0.04), rgba(163, 184, 158, 0.14)),
    radial-gradient(circle at 16% 82%, rgba(123, 142, 120, 0.16), transparent 18%),
    radial-gradient(circle at 38% 88%, rgba(123, 142, 120, 0.14), transparent 20%),
    radial-gradient(circle at 72% 84%, rgba(123, 142, 120, 0.14), transparent 18%);
}

.m-home-main {
  margin-top: 12px;
  padding: 11px 12px;
}

.m-home-main .primary-btn {
  margin-top: 9px;
}

.m-mini-program-card {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 13px;
  margin-top: 12px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(224, 205, 175, 0.68);
  background:
    linear-gradient(135deg, rgba(255, 253, 248, 0.95), rgba(239, 247, 241, 0.92)),
    radial-gradient(circle at 92% 18%, rgba(185, 133, 43, 0.13), transparent 36%);
  box-shadow: 0 10px 22px rgba(115, 90, 52, 0.10);
}
.m-mini-program-card img {
  width: 96px;
  height: 96px;
  flex: 0 0 auto;
  object-fit: cover;
  border-radius: 14px;
  border: 4px solid rgba(255, 255, 255, 0.92);
  background: #fff;
  box-shadow: 0 8px 18px rgba(115, 90, 52, 0.12);
}
.m-mini-program-card strong {
  display: block;
  color: var(--ink);
  font-size: 17px;
  line-height: 1.4;
}
.m-mini-program-card span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.m-report-preview {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 12px;
  align-items: stretch;
}

.m-auth-page {
  min-height: calc(100vh - 58px);
  padding-top: 22px;
  background:
    radial-gradient(circle at 12% 22%, rgba(185, 133, 43, 0.08), transparent 24%),
    radial-gradient(circle at 88% 8%, rgba(95, 127, 96, 0.08), transparent 28%);
}

.m-login-header {
  background: rgba(251, 248, 241, 0.70);
  border-bottom: none;
}

.m-login-visual {
  display: flex;
  justify-content: center;
  margin: 26px 0 22px;
}

.m-cloud-house {
  position: relative;
  width: 190px;
  height: 190px;
  border: 1px solid rgba(185, 133, 43, 0.58);
  border-radius: 45% 45% 40% 40%;
  background:
    radial-gradient(circle at 28% 38%, rgba(147, 166, 139, 0.16), transparent 28%),
    radial-gradient(circle at 58% 66%, rgba(185, 133, 43, 0.10), transparent 32%),
    linear-gradient(180deg, rgba(255, 253, 248, 0.64), rgba(246, 239, 225, 0.34));
  box-shadow: 0 12px 28px rgba(115, 90, 52, 0.06);
}

.m-sun {
  position: absolute;
  left: 82px;
  top: 44px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(180deg, #ead19d, #d3a950);
}

.m-roof {
  position: absolute;
  left: 48px;
  top: 92px;
  width: 96px;
  height: 54px;
  border-left: 4px solid #4d6b5b;
  border-right: 4px solid #4d6b5b;
  border-bottom: 4px solid #4d6b5b;
}

.m-roof::before {
  content: "";
  position: absolute;
  left: 4px;
  top: -35px;
  width: 76px;
  height: 76px;
  border-left: 4px solid #4d6b5b;
  border-top: 4px solid #4d6b5b;
  transform: rotate(45deg);
  transform-origin: center;
}

.m-bamboo {
  position: absolute;
  right: 45px;
  top: 55px;
  width: 4px;
  height: 90px;
  background: rgba(76, 112, 80, 0.58);
  box-shadow: 18px -8px 0 rgba(76, 112, 80, 0.48);
}

.m-bamboo::before,
.m-bamboo::after {
  content: "";
  position: absolute;
  width: 38px;
  height: 1px;
  background: rgba(76, 112, 80, 0.46);
  transform: rotate(-24deg);
}

.m-bamboo::before {
  top: 18px;
  right: -24px;
}

.m-bamboo::after {
  top: 48px;
  right: -28px;
}

.m-auth-copy {
  text-align: center;
  margin-bottom: 22px;
}

.m-auth-copy h1 {
  margin: 0;
  color: #1f4434;
  font-size: 31px;
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: 2px;
}

.m-title-line {
  width: 138px;
  height: 1px;
  margin: 18px auto 14px;
  background: linear-gradient(90deg, transparent, #be9d69, transparent);
}

.m-auth-copy p {
  margin: 0;
  color: #6f6659;
  font-size: 15px;
  line-height: 1.7;
}

.m-login-form-card {
  padding: 18px 16px;
}

.m-google-btn {
  margin-top: 12px;
}

.m-wechat-btn {
  margin-bottom: 12px;
}

.m-wechat-btn::before {
  content: "微";
  width: 26px;
  height: 26px;
  margin-right: 8px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  color: #325f43;
  background: #fff8ef;
  font-size: 14px;
}

.m-login-divider {
  width: 100%;
  margin: 10px auto 14px;
}

.m-login-skip {
  position: relative;
  z-index: 1;
  display: block;
  margin-top: 16px;
  text-align: center;
  color: #6f6659;
  font-size: 15px;
}

.m-policy-line {
  margin: 20px 16px 0;
  color: #6f6659;
  text-align: center;
  font-size: 13px;
  line-height: 1.7;
}

.m-app {
  min-height: 100vh;
  padding-bottom: calc(86px + env(safe-area-inset-bottom));
}

.m-page {
  min-height: 100vh;
  padding: 14px 12px 28px;
}

.m-topbar,
.m-header {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 58px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(251, 248, 241, 0.88);
  border-bottom: 1px solid rgba(224, 205, 175, 0.42);
  backdrop-filter: blur(12px);
}

.m-header a,
.m-header span,
.m-topbar a {
  min-width: 48px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

.m-header strong {
  color: var(--ink);
  font-size: 20px;
  letter-spacing: 1px;
}

.m-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-weight: 800;
  letter-spacing: 1px;
}

.m-brand img {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  object-fit: cover;
  box-shadow: 0 6px 12px rgba(88, 71, 42, 0.10);
}

.m-hero,
.m-card,
.m-auth-card,
.m-loading-card {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255, 252, 245, 0.98), rgba(251, 247, 239, 0.96)),
    radial-gradient(circle at bottom right, rgba(118, 146, 119, 0.08), transparent 24%);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.m-hero::before,
.m-card::before,
.m-auth-card::before,
.m-loading-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(229, 214, 189, 0.10) 1px, transparent 1px),
    linear-gradient(90deg, rgba(229, 214, 189, 0.10) 1px, transparent 1px);
  background-size: 12px 12px;
  opacity: 0.38;
}

.m-panel-corner::after,
.m-hero::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 14px;
  width: 20px;
  height: 20px;
  border-top: 2px solid #d9c09a;
  border-right: 2px solid #d9c09a;
  opacity: 0.78;
}

.m-hero {
  margin: 12px;
  padding: 22px 18px 24px;
}

.m-hero-art {
  position: absolute;
  right: -18px;
  bottom: -22px;
  width: 190px;
  height: 132px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 62% 22%, rgba(86, 110, 84, 0.18), transparent 45%),
    radial-gradient(circle at 35% 70%, rgba(185, 133, 43, 0.10), transparent 38%);
}

.m-kicker,
.m-hero-tag {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 0 12px;
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(239, 229, 207, 0.74);
  color: #9a6b26;
  font-size: 12px;
  letter-spacing: 1px;
}

.m-hero h1,
.m-page-title {
  position: relative;
  z-index: 1;
  margin: 0;
  color: var(--ink);
  font-size: 31px;
  line-height: 1.28;
  font-weight: 800;
  letter-spacing: 1px;
}

.m-hero p,
.m-muted {
  position: relative;
  z-index: 1;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.75;
}

.m-hero p { margin: 12px 0 18px; max-width: 72%; }

.m-card,
.m-auth-card,
.m-loading-card {
  padding: 18px;
  margin-bottom: 14px;
}

.m-section-title {
  position: relative;
  z-index: 1;
  color: var(--ink);
  font-size: 22px;
  font-weight: 800;
  line-height: 1.35;
  margin-bottom: 14px;
}

.m-section-row {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.m-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 18px 0 14px;
  color: var(--ink);
  font-weight: 800;
  letter-spacing: 2px;
}

.m-ornament::before,
.m-ornament::after {
  content: "";
  flex: 1;
  max-width: 108px;
  height: 1px;
  background: linear-gradient(90deg, rgba(215, 194, 159, 0), rgba(215, 194, 159, 0.95), rgba(215, 194, 159, 0));
}

.m-btn {
  position: relative;
  z-index: 1;
  min-height: 50px;
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid rgba(220, 197, 154, 0.74);
  border-radius: 16px;
  background: linear-gradient(180deg, #fffdfa 0%, #f8f1e4 100%);
  color: var(--ink);
  font-size: 17px;
  font-weight: 800;
  box-shadow: none;
}

.m-btn-primary {
  color: #fff8ef;
  background: linear-gradient(180deg, #4f765a 0%, #325f43 100%);
  border-color: #325f43;
  box-shadow: 0 10px 18px rgba(50, 95, 67, 0.22);
}

.m-btn-ghost {
  color: #6c614f;
  background: rgba(250, 246, 238, 0.8);
  border-color: rgba(221, 205, 178, 0.72);
}

.m-icon-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

.m-icon-item {
  position: relative;
  text-align: center;
  padding: 8px 4px;
}

.m-icon-item + .m-icon-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 18px;
  width: 1px;
  height: 64px;
  background: rgba(223, 210, 190, 0.8);
}

.m-round-icon {
  width: 54px;
  height: 54px;
  margin: 0 auto 10px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--ink);
  background: var(--sage);
  font-weight: 900;
}

.m-round-icon.gold {
  color: #ad741d;
  background: #f7ecd1;
}

.m-icon-item b {
  display: block;
  color: #2d2a25;
  font-size: 14px;
  line-height: 1.35;
}

.m-icon-item span {
  display: block;
  margin-top: 5px;
  color: #8a7f72;
  font-size: 11px;
}

.m-cap-grid,
.m-step-grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 12px;
}

.m-cap-card,
.m-step-card,
.m-issue,
.m-kv-card {
  position: relative;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(228, 214, 189, 0.74);
  padding: 15px;
}

.m-cap-card {
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: center;
  gap: 12px;
}

.m-cap-card h3,
.m-step-card h3,
.m-issue h3 {
  margin: 0 0 6px;
  color: var(--text);
  font-size: 17px;
}

.m-cap-card p,
.m-step-card p,
.m-issue p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.m-step-card {
  display: grid;
  grid-template-columns: 44px 1fr;
  align-items: center;
  gap: 12px;
}

.m-step-no {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fffdf8;
  background: #325f43;
  font-size: 20px;
  font-weight: 800;
}

.m-preview {
  position: relative;
  z-index: 1;
}

.m-score-row,
.m-score-big {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 16px;
  align-items: center;
}

.m-score-row h3,
.m-score-big h2 {
  margin: 0 0 8px;
  color: #4f7c5a;
  font-size: 24px;
}

.m-score-ring {
  width: 108px;
  height: 108px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  align-content: center;
  color: #8a5b24;
  background:
    radial-gradient(circle at center, #fffdf8 0 52%, transparent 53%),
    conic-gradient(#d8a24a 0 var(--score), #f1dfbd var(--score) 100%);
  border: 13px solid #f7ecd1;
}

.m-score-ring strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 36px;
  line-height: 1;
}

.m-score-ring span {
  margin-top: 2px;
  color: #8a6a35;
  font-size: 11px;
}

.m-mini-plan {
  position: relative;
  z-index: 1;
  margin-top: 16px;
  min-height: 220px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid rgba(189, 138, 63, 0.34);
  border-radius: 18px;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 50%, rgba(185, 133, 43, 0.10), transparent 38%),
    rgba(255, 250, 240, 0.62);
}

.m-mini-plan span {
  display: grid;
  place-items: center;
  color: var(--ink);
  font-size: 17px;
  font-weight: 900;
  border-right: 1px solid rgba(198, 173, 134, 0.50);
  border-bottom: 1px solid rgba(198, 173, 134, 0.50);
  backdrop-filter: blur(4px);
}

.m-mini-plan span:nth-child(3n) { border-right: none; }
.m-mini-plan span:nth-last-child(-n+3) { border-bottom: none; }

.m-upload-card h1,
.m-login-card h1,
.m-empty h1,
.m-loading-card h1 {
  position: relative;
  z-index: 1;
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 27px;
  line-height: 1.28;
}

.m-upload-box {
  position: relative;
  z-index: 1;
  min-height: 164px;
  margin: 18px 0 14px;
  border: 1px dashed rgba(86, 120, 92, 0.42);
  border-radius: 20px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 7px;
  background: rgba(255, 253, 248, 0.74);
  color: var(--ink);
  font-weight: 800;
}

.m-upload-box input {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.m-upload-box small,
.m-status,
.m-link {
  color: var(--muted);
  font-size: 13px;
}

.m-status {
  position: relative;
  z-index: 1;
  min-height: 24px;
  margin: 10px 0 0;
}

.m-status.ok { color: #4f7c5a; }
.m-status.err { color: #ad4b3f; }

.m-list {
  position: relative;
  z-index: 1;
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
}

.m-form {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 13px;
  margin-top: 16px;
}

.m-form label {
  display: grid;
  gap: 8px;
  color: var(--ink);
  font-weight: 800;
}

.m-form input {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.86);
  outline: none;
}

.m-alert {
  position: relative;
  z-index: 1;
  padding: 10px 12px;
  border-radius: 14px;
  color: #ad4b3f;
  background: #fff0ed;
}

.m-alert.ok {
  color: #4f7c5a;
  background: #edf8f0;
}

.m-center-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
}

.m-loading-card {
  width: 100%;
  text-align: center;
  display: grid;
  justify-items: center;
  gap: 12px;
}

.m-spinner {
  position: relative;
  z-index: 1;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  border: 5px solid rgba(189, 138, 63, 0.18);
  border-top-color: #325f43;
  animation: mspin 0.9s linear infinite;
}

@keyframes mspin { to { transform: rotate(360deg); } }

.m-report-image {
  position: relative;
  z-index: 1;
  width: 100%;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(220, 203, 177, 0.38);
}

.m-kv {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.m-kv span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.m-kv b {
  display: block;
  margin-top: 5px;
  color: var(--gold);
  font-size: 18px;
}

.m-issue {
  position: relative;
  z-index: 1;
  margin-top: 10px;
  display: grid;
  gap: 7px;
}

.m-list-card {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 58px;
  align-items: center;
  gap: 12px;
  color: inherit;
}

.m-list-card b {
  color: var(--text);
  font-size: 16px;
}

.m-list-card p,
.m-list-card span,
.m-order-card p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.m-list-card span {
  display: grid;
  place-items: center;
  height: 38px;
  border-radius: 999px;
  background: var(--sage);
  color: var(--ink);
  font-weight: 800;
}

.m-order-card {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
}

.m-order-card b,
.m-order-card strong {
  color: var(--text);
}

.m-order-side {
  text-align: right;
  display: grid;
  gap: 6px;
}

.m-order-side span {
  display: inline-flex;
  justify-content: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--sage);
  color: var(--ink);
  font-size: 12px;
}

.m-order-side a {
  color: var(--gold);
  font-size: 13px;
  font-weight: 800;
}

.m-article-page {
  padding-top: 14px;
}

.m-article-nav .m-brand {
  gap: 8px;
  font-size: 20px;
  letter-spacing: 0.08em;
}

.m-search-pill {
  position: relative;
  margin: 0 4px 16px;
  padding: 12px 16px 12px 42px;
  border: 1px solid rgba(33, 74, 56, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: rgba(37, 51, 44, 0.52);
  font-size: 14px;
  box-shadow: 0 8px 22px rgba(39, 71, 54, 0.06);
}

.m-search-pill::before {
  content: "";
  position: absolute;
  left: 17px;
  top: 50%;
  width: 13px;
  height: 13px;
  border: 2px solid rgba(37, 51, 44, 0.45);
  border-radius: 50%;
  transform: translateY(-55%);
}

.m-search-pill::after {
  content: "";
  position: absolute;
  left: 30px;
  top: 27px;
  width: 8px;
  height: 2px;
  border-radius: 999px;
  background: rgba(37, 51, 44, 0.45);
  transform: rotate(45deg);
}

.m-category-tabs {
  display: flex;
  gap: 18px;
  margin: 0 -14px 14px;
  padding: 0 18px 8px;
  overflow-x: auto;
  color: var(--ink);
  scrollbar-width: none;
}

.m-category-tabs::-webkit-scrollbar {
  display: none;
}

.m-category-tabs a {
  flex: 0 0 auto;
  position: relative;
  color: var(--ink);
  font-size: 17px;
  line-height: 32px;
  text-decoration: none;
  white-space: nowrap;
}

.m-category-tabs a.active {
  color: var(--green);
  font-weight: 700;
}

.m-category-tabs a.active::after {
  content: "";
  position: absolute;
  left: 2px;
  right: 2px;
  bottom: 0;
  height: 3px;
  border-radius: 999px;
  background: var(--green);
}

.m-knowledge-list {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 11px;
}

.m-knowledge-card {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 116px 1fr;
  gap: 12px;
  align-items: stretch;
  min-height: 98px;
  padding: 9px;
  border-radius: 15px;
  border: 1px solid rgba(228, 214, 189, 0.7);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(253, 248, 238, 0.86)),
    var(--paper);
  box-shadow: 0 10px 24px rgba(68, 49, 29, 0.06);
  text-decoration: none;
}

.m-knowledge-card > img {
  width: 116px;
  height: 98px;
  border-radius: 12px;
  object-fit: cover;
  background: var(--paper-deep);
}

.m-knowledge-card.no-cover {
  grid-template-columns: 1fr;
}

.m-knowledge-body {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 4px;
  padding: 1px 0;
}

.m-knowledge-body .record-title {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  color: var(--ink);
  font-size: 17px;
  line-height: 1.35;
}

.m-knowledge-body .record-meta {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  margin: 0;
  color: rgba(37, 51, 44, 0.62);
  font-size: 12px;
  line-height: 1.55;
}

.m-article-meta,
.m-detail-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 9px;
  color: rgba(37, 51, 44, 0.54);
  font-size: 11px;
  line-height: 1.2;
}

.m-article-meta em,
.m-detail-meta em {
  margin-left: auto;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(213, 231, 208, 0.84);
  color: var(--green);
  font-style: normal;
  white-space: nowrap;
}

.m-home-knowledge .m-knowledge-card {
  grid-template-columns: 96px 1fr;
  min-height: 86px;
}

.m-home-knowledge .m-knowledge-card > img {
  width: 96px;
  height: 86px;
}

.m-home-knowledge .m-knowledge-body .record-meta {
  -webkit-line-clamp: 1;
}

.m-pagination-card {
  margin-top: 14px;
}

.m-pagination {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.m-pagination .secondary-btn {
  min-height: 36px;
  padding: 0 13px;
  font-size: 14px;
}

.m-article h1 {
  position: relative;
  z-index: 1;
  margin: 0 0 12px;
  color: var(--ink-deep);
  font-size: 24px;
  line-height: 1.35;
}

.m-article-hero-cover {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 188px;
  object-fit: cover;
  border-radius: 0 0 22px 22px;
  margin: -14px 0 14px;
  box-shadow: 0 12px 28px rgba(68, 49, 29, 0.1);
}

.m-article-summary {
  position: relative;
  z-index: 1;
  margin: 14px 0;
  padding: 12px 14px;
  border: 1px solid rgba(218, 196, 158, 0.56);
  border-radius: 13px;
  background: rgba(248, 239, 219, 0.55);
  color: rgba(37, 51, 44, 0.72);
  line-height: 1.75;
  font-size: 14px;
}

.m-article-body {
  position: relative;
  z-index: 1;
  color: #3b332b;
  line-height: 1.85;
  font-size: 15px;
}

.m-article-body img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
}

.m-article-body p {
  margin: 0 0 13px;
}

.m-article-body h2,
.m-article-body h3 {
  margin: 18px 0 9px;
  color: var(--ink-deep);
}

.m-article-cta {
  position: sticky;
  bottom: 78px;
  z-index: 4;
  display: flex;
  margin: 16px 18px 0;
  box-shadow: 0 12px 24px rgba(30, 94, 67, 0.24);
}

.m-empty {
  text-align: center;
  display: grid;
  gap: 12px;
}

.m-tabbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 7px 12px calc(8px + env(safe-area-inset-bottom));
  background: rgba(255, 253, 248, 0.96);
  border-top: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.m-tabbar a {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 3px;
  color: #6f6659;
  font-size: 12px;
  font-weight: 700;
  padding: 7px 0;
}

.m-tabbar a::before {
  content: attr(data-icon);
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-size: 15px;
}

.m-tabbar a.active {
  color: var(--ink);
}

.m-tabbar a.active::before {
  color: #fffdf8;
  background: #325f43;
}

@media (min-width: 520px) {
  .m-app {
    max-width: 480px;
    margin: 0 auto;
    box-shadow: 0 0 0 1px rgba(224, 205, 175, 0.36);
  }
  .m-tabbar {
    left: 50%;
    right: auto;
    width: 480px;
    transform: translateX(-50%);
  }
}
