* { box-sizing: border-box; }
body { margin: 0; font-family: "Microsoft YaHei", "PingFang SC", sans-serif; background: #f5f7fb; color: #222; }
.container { width: min(1180px, 92%); margin: 0 auto; }
.topbar { background: #234; color: #fff; padding: 14px 0; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; }
.brand { font-size: 20px; font-weight: 700; }
.nav a { color: #fff; text-decoration: none; margin-left: 18px; }
.main-content { padding: 24px 0 40px; }
.card { background: #fff; border-radius: 14px; padding: 22px; box-shadow: 0 6px 18px rgba(20, 30, 60, 0.08); margin-bottom: 20px; }
label { display: block; margin: 14px 0 8px; font-weight: 600; }
input[type="text"], input[type="file"], select, textarea { width: 100%; padding: 10px 12px; border: 1px solid #d7deea; border-radius: 10px; background: #fff; }
textarea { resize: vertical; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.btn { display: inline-block; padding: 10px 16px; border-radius: 10px; border: none; background: #e5ecf6; color: #223; text-decoration: none; cursor: pointer; }
.btn.primary { background: #315efb; color: #fff; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { border-bottom: 1px solid #e6ebf2; padding: 10px 8px; text-align: left; }
.flash { padding: 12px 14px; border-radius: 10px; margin-bottom: 14px; }
.flash.success { background: #e7f7ee; color: #20633b; }
.flash.error { background: #fdecec; color: #9e2f2f; }
.flash.info { background: #eef4ff; color: #3058a6; }
.student-card { border: 1px solid #e6ebf2; border-radius: 12px; padding: 14px; margin-bottom: 14px; }
.results-layout { display: grid; grid-template-columns: 280px 1fr; gap: 20px; }
.student-list { list-style: none; padding: 0; margin: 0; }
.student-list li { border-radius: 10px; margin-bottom: 8px; }
.student-list li a { display: block; padding: 10px 12px; text-decoration: none; color: #223; background: #f2f5fb; border-radius: 10px; }
.student-list li.active a { background: #315efb; color: #fff; }
.info-panel { background: #f2f7ff; border-radius: 12px; padding: 12px 14px; }
.steps { line-height: 1.9; }
.preview-wrap { display: flex; gap: 14px; flex-wrap: wrap; margin: 18px 0; }
.preview-item { width: 220px; background: #f7f9fd; border: 1px solid #e6ebf2; border-radius: 12px; padding: 10px; }
.preview-title { font-size: 13px; color: #556; margin-bottom: 8px; word-break: break-all; }
.preview-item img { width: 100%; border-radius: 8px; display: block; }
.muted { color: #667; }
@media (max-width: 900px) { .grid-2, .results-layout { grid-template-columns: 1fr; } }
.notice-box {
  background: #eef6ff;
  border: 1px solid #cfe2ff;
  color: #234;
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 18px;
}

.student-card-warning {
  border: 2px solid #f0a3a3 !important;
  background: #fff7f7;
}

.card-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.warning-badge {
  display: inline-block;
  margin-left: 10px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #ffe1e1;
  color: #b42318;
  font-size: 13px;
  font-weight: 600;
}

.warning-tip {
  background: #fff1f1;
  border-left: 4px solid #e66;
  color: #8a1f1f;
  padding: 10px 12px;
  border-radius: 8px;
  margin-bottom: 14px;
}
.summary-bar {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 14px;
  margin-bottom: 10px;
}

.summary-item {
  min-width: 150px;
  background: #f4f7fb;
  border: 1px solid #dce6f2;
  border-radius: 12px;
  padding: 14px 18px;
}

.summary-item-warning {
  background: #fff3f3;
  border: 1px solid #f0b5b5;
}

.summary-label {
  display: block;
  font-size: 14px;
  color: #556;
  margin-bottom: 6px;
}

.summary-value {
  display: block;
  font-size: 26px;
  font-weight: 700;
  color: #223;
}
.student-card-warning {
  animation: pendingGlow 1.2s ease-in-out 2;
}

@keyframes pendingGlow {
  0% {
    box-shadow: 0 0 0 rgba(230, 102, 102, 0);
  }
  50% {
    box-shadow: 0 0 18px rgba(230, 102, 102, 0.45);
  }
  100% {
    box-shadow: 0 0 0 rgba(230, 102, 102, 0);
  }
}

.summary-item-success {
  background: #eefaf1;
  border: 1px solid #b7e4c7;
}

.summary-value-small {
  display: block;
  font-size: 18px;
  font-weight: 700;
  color: #223;
}
 .progress-wrap {
  margin-top: 8px;
}

.progress-bar {
  width: 100%;
  height: 18px;
  background: #e9eef5;
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: #4a67f5;
  border-radius: 999px;
  transition: width 0.3s ease;
}

.progress-fill-green {
  background: #2bb673;
}

.progress-text {
  margin-top: 6px;
  font-size: 14px;
  color: #445;
}

.progress-wrap {
  margin-top: 8px;
}

.progress-bar {
  width: 100%;
  height: 18px;
  background: #e9eef5;
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: #4a67f5;
  border-radius: 999px;
  transition: width 0.3s ease;
}

.progress-fill-green {
  background: #2bb673;
}

.progress-text {
  margin-top: 6px;
  font-size: 14px;
  color: #445;
}
.narrow-card{max-width:520px;margin:0 auto;}
.subtle-card{background:#fbfcff;}
.link-btn{background:none;border:none;color:#2457d6;cursor:pointer;padding:0;font:inherit;}
.roster-board{margin:18px 0;}
.roster-grid{align-items:start;}
.name-chip-wrap{display:flex;flex-wrap:wrap;gap:10px;min-height:44px;}
.name-chip{display:inline-flex;align-items:center;justify-content:center;padding:8px 12px;border-radius:999px;border:1px solid #d6dff1;background:#f4f7fb;color:#234;cursor:pointer;font-size:14px;}
.pending-roster-chip:hover{background:#eaf1ff;border-color:#9bb4ff;}
.matched-chip{background:#eefaf1;border-color:#b7e4c7;color:#135e2b;cursor:default;}
.locked-chip{opacity:.9;}
.matched-inline-tag{font-size:13px;color:#135e2b;background:#eefaf1;border:1px solid #b7e4c7;border-radius:999px;padding:4px 10px;}
.matchable-name-input.drop-active{border-color:#4a67f5;box-shadow:0 0 0 3px rgba(74,103,245,.15);}
.matched-input-highlight{background:#eefaf1 !important;transition:background .3s ease;}
.info-panel{background:#f7f9fc;border:1px solid #e0e6f0;border-radius:12px;padding:12px 16px;margin:14px 0;}
.steps li{margin:8px 0;}

.group-preview-wrap{display:flex;gap:12px;flex-wrap:wrap;margin:10px 0 16px;}
.group-preview-item{width:180px;border:1px solid #e2e8f3;border-radius:12px;padding:8px;background:#fafcff;}
.group-preview-title{font-size:12px;color:#667;word-break:break-all;margin-bottom:6px;line-height:1.4;}
.group-preview-item img{width:100%;height:220px;object-fit:cover;border-radius:8px;display:block;}
.small-tip{font-size:12px;margin-top:6px;display:block;}
.match-status-box{display:flex;align-items:center;gap:8px;}

/* Sprint 2 commercial UI */
.commercial-hero,.account-hero{display:flex;align-items:center;justify-content:space-between;gap:20px;flex-wrap:wrap;}
.price-line{display:flex;align-items:baseline;gap:10px;margin:12px 0;}
.price-main{font-size:42px;font-weight:800;color:#e34d36;}
.muted{color:#718096;}
.payment-grid{grid-template-columns:repeat(2,minmax(0,1fr));}
.payment-card{text-align:center;}
.payment-qr{width:min(420px,100%);height:auto;object-fit:contain;border:1px solid #e5eaf2;border-radius:16px;background:#fff;display:block;margin:0 auto;}
.qr-placeholder{min-height:280px;display:flex;flex-direction:column;align-items:center;justify-content:center;border:2px dashed #cfd8e6;border-radius:16px;color:#6b778c;background:#f8fafc;padding:20px;}
.form-stack{display:flex;flex-direction:column;gap:10px;}
.form-stack input[type="text"],.form-stack input[type="number"],.form-stack input[type="datetime-local"],.form-stack input[type="file"]{width:100%;box-sizing:border-box;padding:10px;border:1px solid #ccd6e4;border-radius:8px;}
.radio-row{display:flex;gap:24px;}
.order-offer-box{display:flex;justify-content:space-between;gap:12px;padding:12px 14px;border-radius:10px;background:#f5f8ff;margin-bottom:12px;}
.status-badge{display:inline-block;padding:4px 10px;border-radius:999px;background:#edf2f7;color:#475569;font-size:13px;font-weight:700;}
.status-badge.success{background:#e8f7ee;color:#167344;}.status-badge.warning{background:#fff4d6;color:#8a5a00;}.status-badge.danger{background:#ffe8e8;color:#a52828;}
.admin-stats{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:12px;margin:16px 0;}.stat-card{text-align:center;}.stat-card span{display:block;color:#68768a;font-size:13px;}.stat-card strong{display:block;font-size:26px;margin-top:8px;}
.section-head{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;}.simple-table{width:100%;border-collapse:collapse;}.simple-table th,.simple-table td{border-bottom:1px solid #e5eaf2;padding:10px 8px;text-align:left;font-size:14px;}.simple-table th{color:#59677a;background:#f8fafc;}
.filter-tabs{display:flex;gap:8px;margin:12px 0;}.chip{display:inline-block;padding:7px 12px;border-radius:999px;background:#eef3fb;text-decoration:none;}.admin-review-actions{display:grid;gap:14px;margin-top:18px;}.admin-review-actions form{display:flex;gap:8px;align-items:center;}.admin-review-actions input{flex:1;padding:10px;border:1px solid #ccd6e4;border-radius:8px;}.danger-btn{background:#c94343 !important;}.account-grid{grid-template-columns:repeat(2,minmax(0,1fr));}.seed-offer{padding:10px;border-radius:10px;background:#fff7e6;color:#7a4a00;}
@media(max-width:800px){.payment-grid,.account-grid{grid-template-columns:1fr}.admin-stats{grid-template-columns:repeat(2,minmax(0,1fr));}.simple-table{display:block;overflow-x:auto;}.order-offer-box{flex-direction:column;}}

/* Sprint 3 referral */
.referral-hero { display:flex; justify-content:space-between; gap:18px; align-items:center; }
.referral-stats { grid-template-columns:repeat(4, minmax(0,1fr)); }
.stat-card { text-align:center; }
.stat-card strong { display:block; font-size:30px; margin-bottom:6px; }
.stat-card span { color:#667085; }
.referral-code { display:inline-block; padding:10px 16px; border-radius:10px; background:#f2f6ff; font-size:26px; font-weight:800; letter-spacing:4px; margin:4px 0 16px; }
.copy-row { display:flex; gap:10px; align-items:center; flex-wrap:wrap; }
.copy-row input { flex:1 1 360px; min-width:220px; }
.reward-steps { display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.reward-steps > div { padding:16px; border:1px solid #e5eaf2; border-radius:12px; }
.reward-num { display:inline-block; margin-right:8px; color:#315efb; font-size:22px; font-weight:800; }
.invite-notice { padding:12px 14px; border-radius:10px; background:#eefbf3; color:#177245; margin:12px 0; }
.result-referral-card { margin-top:18px; }
@media (max-width: 760px) {
  .referral-stats, .reward-steps { grid-template-columns:1fr 1fr; }
  .referral-hero { align-items:flex-start; flex-direction:column; }
}

/* Sprint 4: seed-teacher operations admin */
.admin-page-head{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;margin-bottom:18px}.admin-page-head h1{margin-bottom:6px}.admin-quick-links{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}.ops-kpi-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:12px;margin-bottom:16px}.ops-kpi{padding:16px}.ops-kpi span{display:block;color:#667085;font-size:13px}.ops-kpi strong{display:block;font-size:28px;line-height:1.25;margin:6px 0}.ops-kpi small{color:#98a2b3}.ops-funnel-grid,.ops-two-col{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-bottom:16px}.funnel-row{display:grid;grid-template-columns:1fr 70px 70px;gap:10px;padding:10px 0;border-bottom:1px solid #eef1f5}.funnel-row b,.funnel-row em{text-align:right}.funnel-row em{font-style:normal;color:#315efb}.ops-progress{height:14px;border-radius:999px;background:#edf1f7;overflow:hidden;margin:16px 0}.ops-progress>div{height:100%;background:linear-gradient(90deg,#315efb,#66a2ff);border-radius:999px}.seed-numbers{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.seed-numbers div{text-align:center;padding:12px;background:#f8fafc;border-radius:10px}.seed-numbers strong{display:block;font-size:24px}.seed-numbers span{font-size:12px;color:#667085}.table-scroll{overflow-x:auto}.ops-table{min-width:780px}.admin-filter-card{margin-bottom:14px}.admin-filter-form{display:flex;align-items:end;gap:12px;flex-wrap:wrap}.admin-filter-form label{display:flex;flex-direction:column;gap:6px}.admin-filter-form input,.admin-filter-form select{min-width:180px}.log-detail{max-width:420px;word-break:break-all;font-size:12px;color:#667085}.small{font-size:12px}
@media (max-width:1100px){.ops-kpi-grid{grid-template-columns:repeat(3,1fr)}}
@media (max-width:760px){.admin-page-head{flex-direction:column}.admin-quick-links{justify-content:flex-start}.ops-kpi-grid{grid-template-columns:repeat(2,1fr)}.ops-funnel-grid,.ops-two-col{grid-template-columns:1fr}}
