:root {
  --green-950: #073e2b;
  --green-900: #075b3a;
  --green-800: #0a6b45;
  --green-700: #16805a;
  --green-100: #e5f1e9;
  --green-50: #f1f7f3;
  --gold: #b99454;
  --gold-soft: #e4c58f;
  --ink: #18251f;
  --muted: #6f7c75;
  --line: #e1e8e3;
  --paper: #ffffff;
  --canvas: #f4f6f2;
  --red: #b4483e;
  --shadow: 0 24px 70px rgba(18, 55, 37, .1);
}
* { box-sizing: border-box; }
html { min-height: 100%; }
body { margin: 0; color: var(--ink); font-family: "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif; -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; }
.hidden { display: none !important; }
.muted { color: var(--muted); }

/* 校友签到移动端 */
.attendee-body { min-height: 100vh; background: radial-gradient(circle at 15% 8%, #fff 0, var(--canvas) 48%, #e9f1ec 100%); position: relative; overflow-x: hidden; }
.attendee-hero { position: relative; overflow: hidden; padding: 58px 24px 96px; background: linear-gradient(150deg, #053524 0%, #075b3a 58%, #0d7550 100%); color: #fff; border-radius: 0 0 46px 46px; }
.hero-grid { position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px); background-size: 44px 44px; mask-image: linear-gradient(#000 0, transparent 86%); pointer-events: none; }
.hero-orb { position: absolute; border-radius: 50%; pointer-events: none; }
.hero-orb-one { width: 280px; height: 280px; border: 1px solid rgba(228,197,143,.35); top: -120px; right: -95px; }
.hero-orb-two { width: 190px; height: 190px; background: rgba(228,197,143,.1); bottom: -100px; left: -70px; }
.hero-inner { width: min(100%, 620px); margin: 0 auto; position: relative; }
.event-brand { display: flex; gap: 17px; align-items: center; }
.school-mark { width: 54px; height: 54px; flex: 0 0 auto; border-radius: 50%; background: rgba(255,255,255,.1); color: #fff; border: 1px solid rgba(255,255,255,.28); display: grid; place-items: center; font-family: "STSong", "SimSun", serif; font-size: 17px; font-weight: 700; letter-spacing: 1px; backdrop-filter: blur(8px); }
.school-mark.image-mark { width: 86px; height: 86px; background: transparent; border: 0; outline: 0; backdrop-filter: none; filter: drop-shadow(0 8px 18px rgba(0,0,0,.24)); }
.school-mark.image-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
.event-brand h1 { font-family: "STSong", "SimSun", serif; font-size: 27px; letter-spacing: 2px; margin: 5px 0 0; }
.event-brand p { margin: 0; font-size: 11px; color: rgba(255,255,255,.7); letter-spacing: 2px; }
.brand-eyebrow { font-size: 10px !important; letter-spacing: 2px !important; color: var(--gold-soft) !important; font-weight: 700; }
.hero-subtitle { margin: 23px 0 0 4px; color: rgba(255,255,255,.72); font-size: 13px; letter-spacing: 1px; }
.attendee-shell { width: min(100%, 620px); margin: -56px auto 0; padding: 0 20px 30px; position: relative; }
.attendee-card { background: rgba(255,255,255,.97); border: 1px solid rgba(255,255,255,.8); border-radius: 27px; padding: 31px; box-shadow: var(--shadow); }
.card-kicker { color: var(--green-700); font-size: 10px; font-weight: 800; letter-spacing: 1.8px; margin: 0 0 9px; }
.kicker-dot { display: inline-block; width: 17px; height: 2px; background: var(--gold); vertical-align: middle; margin-right: 6px; }
.attendee-card h2 { font-family: "STSong", "SimSun", serif; font-size: 29px; margin: 8px 0 9px; letter-spacing: 1px; }
.attendee-card > .muted { font-size: 14px; margin: 0 0 27px; }
.lookup-form label, .login-card label, .import-form > label { display: block; font-size: 13px; font-weight: 650; margin: 0 0 9px; }
input, select { width: 100%; border: 1px solid #d8e1da; border-radius: 13px; background: #fff; color: var(--ink); padding: 14px 16px; outline: none; transition: border-color .2s, box-shadow .2s; }
input:focus, select:focus { border-color: var(--green-700); box-shadow: 0 0 0 4px rgba(22,128,90,.1); }
.input-wrap { position: relative; }
.input-wrap input { padding-right: 48px; font-size: 16px; }
.input-icon { position: absolute; right: 17px; top: 50%; transform: translateY(-50%); color: var(--green-700); font-size: 23px; }
.primary-button { width: 100%; border: 0; border-radius: 14px; padding: 15px 20px; background: linear-gradient(135deg, var(--green-900), var(--green-700)); color: #fff; font-weight: 650; display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 18px; box-shadow: 0 10px 24px rgba(7,91,58,.2); transition: transform .16s ease, filter .16s ease; }
.primary-button:hover { filter: brightness(1.05); transform: translateY(-1px); }
.primary-button:disabled { opacity: .62; cursor: wait; transform: none; }
.form-message { min-height: 20px; margin: 12px 0 0; color: var(--red); font-size: 13px; line-height: 1.65; }
.privacy-note { border-top: 1px solid var(--line); margin-top: 27px; padding-top: 19px; display: flex; align-items: flex-start; gap: 10px; color: #8a948e; }
.note-mark { width: 8px; height: 8px; border-radius: 50%; background: var(--green-100); border: 2px solid var(--green-700); flex: 0 0 auto; margin-top: 4px; }
.privacy-note p { font-size: 11px; line-height: 1.8; margin: 0; }
.candidate-panel { margin-top: 18px; }
.candidate-title { font-size: 13px; color: var(--muted); margin: 0 0 10px; }
.candidate-button { width: 100%; text-align: left; border: 1px solid var(--line); background: #fbfdfb; border-radius: 15px; padding: 15px; margin-top: 9px; color: var(--ink); display: flex; align-items: center; justify-content: space-between; gap: 10px; transition: border-color .2s, background .2s; }
.candidate-button:hover { border-color: var(--green-700); background: var(--green-50); }
.candidate-button strong { display: block; font-size: 16px; }
.candidate-button small { display: block; color: var(--muted); margin-top: 4px; }
.candidate-button b { color: #fff; background: var(--green-900); border-radius: 20px; padding: 7px 12px; white-space: nowrap; font-size: 12px; }
.attendee-footer { display: flex; justify-content: center; align-items: center; padding: 27px 4px 4px; color: #89958e; font-size: 11px; letter-spacing: 1px; }
.success-card { padding: 28px; }
.success-header { display: flex; align-items: center; gap: 18px; margin-bottom: 23px; }
.success-badge { width: 52px; height: 52px; flex: 0 0 auto; border-radius: 50%; display: grid; place-items: center; background: var(--green-100); color: var(--green-900); font-size: 25px; box-shadow: 0 0 0 8px rgba(22,128,90,.06); }
.success-label { color: var(--green-700); font-size: 11px; font-weight: 800; letter-spacing: 2px; margin: 0 0 5px; }
.success-header h2 { margin: 0 0 5px; font-size: 26px; }
.success-header .muted { margin: 0; font-size: 13px; }
.seat-ticket { position: relative; overflow: hidden; background: linear-gradient(135deg, #063f29, #0a6b45); color: #fff; border-radius: 20px; padding: 23px; }
.seat-ticket::after { content: ""; position: absolute; width: 150px; height: 150px; border: 1px solid rgba(255,255,255,.1); border-radius: 50%; right: -55px; bottom: -75px; }
.seat-ticket > span { display: block; font-size: 11px; color: #bfd6c9; letter-spacing: 2px; }
.seat-ticket strong { display: block; font-family: "STSong", "SimSun", serif; font-size: 27px; font-weight: 500; margin: 7px 0; }
.seat-ticket strong b { font-size: 48px; color: var(--gold-soft); padding: 0 6px; }
.seat-ticket small { color: #a8c2b4; font-size: 11px; }
.search-card { margin-top: 16px; padding: 25px; }
.search-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 17px; }
.search-heading h3 { margin: 0; font-size: 19px; font-family: "STSong", "SimSun", serif; letter-spacing: 1px; }
.search-input-wrap { display: flex; gap: 10px; }
.search-input-wrap input { flex: 1; min-width: 0; font-size: 15px; }
#alumni-search-button { border: 0; border-radius: 13px; background: var(--green-900); color: #fff; padding: 0 21px; font-size: 14px; font-weight: 650; flex: 0 0 auto; }
#alumni-search-button:disabled { opacity: .62; cursor: wait; }
.search-results { margin-top: 6px; max-height: 324px; overflow-y: auto; border: 1px solid var(--line); border-radius: 14px; background: #fbfdfb; padding: 8px; }
.search-result { display: flex; align-items: center; gap: 12px; padding: 12px 9px; border-radius: 10px; }
.search-result.same-table { background: #fff; box-shadow: 0 1px 0 var(--line); }
.search-info { min-width: 0; flex: 1; }
.search-info strong { display: block; font-size: 14px; }
.search-info small { display: block; color: var(--muted); font-size: 11px; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-table-tag { font-size: 11px; color: var(--green-800); background: var(--green-50); border-radius: 20px; padding: 5px 9px; white-space: nowrap; }
.search-result.same-table .search-table-tag { background: var(--green-100); }
.roster-card { margin-top: 16px; padding: 20px; }
.roster-tabs { display: flex; background: #eff4ef; padding: 4px; border-radius: 13px; margin-bottom: 22px; }
.roster-tab { flex: 1; border: 0; background: transparent; color: var(--muted); padding: 11px; border-radius: 10px; font-size: 13px; transition: background .2s, color .2s; }
.roster-tab.active { background: #fff; color: var(--green-900); font-weight: 750; box-shadow: 0 3px 10px rgba(20,50,35,.08); }
.roster-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 15px; }
.roster-heading h3 { margin: 0; font-size: 18px; }
.soft-tag { display: inline-block; background: var(--green-50); color: var(--green-700); border-radius: 20px; padding: 5px 10px; font-size: 10px; white-space: nowrap; }
.person-row { display: flex; align-items: center; gap: 12px; padding: 13px 3px; border-bottom: 1px solid var(--line); }
.person-row:last-child { border: 0; }
.person-avatar { width: 35px; height: 35px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; background: #edf2ed; color: var(--green-800); font-family: "STSong", "SimSun", serif; font-weight: 700; }
.person-info { min-width: 0; flex: 1; }
.person-info strong { display: block; font-size: 14px; }
.person-info small { display: block; color: var(--muted); font-size: 11px; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.person-status { font-size: 10px; color: #9ca59f; }
.person-status.signed { color: var(--green-700); }
.me-tag { font-size: 9px; color: var(--gold); margin-left: 5px; }
.table-group { border: 1px solid var(--line); border-radius: 13px; margin-top: 9px; overflow: hidden; }
.table-group summary { cursor: pointer; list-style: none; padding: 13px 14px; display: flex; justify-content: space-between; font-size: 13px; background: #fafbf9; }
.table-group summary::-webkit-details-marker { display: none; }
.table-group summary span { color: var(--muted); font-size: 11px; }
.table-names { padding: 13px 14px; display: flex; flex-wrap: wrap; gap: 8px; }
.table-names span { background: var(--green-50); color: #385447; padding: 5px 9px; border-radius: 7px; font-size: 12px; }
.empty-state { text-align: center; padding: 30px 10px; color: var(--muted); font-size: 13px; }

/* 管理后台 */
.admin-body { background: var(--canvas); min-height: 100vh; }
.section-kicker { color: var(--green-700); font-size: 10px; font-weight: 800; letter-spacing: 1.5px; margin: 0 0 8px; }
.section-kicker span { display: inline-block; width: 18px; height: 2px; background: var(--gold); vertical-align: middle; margin-right: 5px; }
.login-page { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: radial-gradient(circle at 50% 20%, #fff 0, #eef3ee 65%); }
.login-card { width: min(100%, 400px); background: #fff; padding: 40px; border-radius: 22px; box-shadow: var(--shadow); }
.login-card .school-mark { margin-bottom: 22px; background: var(--green-900); border-width: 3px; border-color: rgba(255,255,255,.7); outline: 1px solid var(--green-900); }
.login-card h1 { font-family: "STSong", "SimSun", serif; margin: 7px 0; font-size: 27px; }
.login-card > .muted { margin: 0 0 27px; font-size: 13px; }
.back-link { display: block; text-align: center; margin-top: 20px; color: var(--muted); font-size: 12px; text-decoration: none; }
.admin-layout { min-height: 100vh; }
.admin-sidebar { position: fixed; inset: 0 auto 0 0; width: 224px; background: var(--green-950); color: #fff; padding: 29px 17px 20px; display: flex; flex-direction: column; z-index: 5; }
.admin-brand { display: flex; align-items: center; gap: 13px; padding: 0 9px 30px; }
.admin-brand .school-mark { width: 40px; height: 40px; font-size: 12px; background: rgba(255,255,255,.1); border-width: 1px; border-color: rgba(255,255,255,.2); outline: 0; }
.admin-brand strong { display: block; font-size: 15px; letter-spacing: 1px; }
.admin-brand span { display: block; color: #9eb8aa; font-size: 10px; margin-top: 4px; }
.admin-nav { display: grid; gap: 7px; }
.admin-nav button { border: 0; border-radius: 9px; padding: 13px 14px; background: transparent; color: #aac1b4; text-align: left; font-size: 13px; }
.admin-nav button span { display: inline-block; width: 26px; font-size: 17px; vertical-align: middle; }
.admin-nav button.active, .admin-nav button:hover { background: rgba(255,255,255,.1); color: #fff; }
.sidebar-bottom { margin-top: auto; padding: 17px 10px 0; border-top: 1px solid rgba(255,255,255,.1); color: #8fab9b; font-size: 10px; }
.system-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #75c79e; margin-right: 5px; }
.sidebar-bottom button { display: block; border: 0; background: none; color: #d3e0d8; padding: 12px 0 0; font-size: 11px; }
.admin-main { margin-left: 224px; padding: 31px 36px 45px; max-width: 1600px; }
.admin-topbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 27px; gap: 20px; }
.admin-topbar h1 { font-size: 25px; margin: 4px 0 0; }
.admin-topbar p { margin: 0; }
.topbar-actions { display: flex; align-items: center; gap: 18px; }
#current-time { font-size: 11px; color: var(--muted); }
.outline-button, .primary-small { border: 1px solid #d7e0d9; background: #fff; color: var(--green-900); border-radius: 8px; padding: 9px 13px; font-size: 12px; text-decoration: none; display: inline-block; }
.metric-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 15px; margin-bottom: 17px; }
.metric-card { background: #fff; border: 1px solid #e6ebe6; border-radius: 14px; padding: 21px; position: relative; overflow: hidden; }
.metric-card::after { content: ""; position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--green-700); }
.metric-card.gold::after { background: var(--gold); }
.metric-card p { color: var(--muted); margin: 0 0 10px; font-size: 12px; }
.metric-card strong { font-family: Georgia, serif; font-size: 34px; font-weight: 500; }
.metric-card strong small { font-family: inherit; font-size: 16px; color: var(--muted); margin-left: 4px; }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(260px, .85fr); gap: 17px; }
.panel { background: #fff; border: 1px solid #e4eae5; border-radius: 14px; padding: 23px; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-bottom: 20px; }
.panel-heading h2 { font-size: 17px; margin: 0; }
.live-pill { font-size: 10px; color: var(--green-700); }
.live-pill::before { content: ""; display: inline-block; width: 6px; height: 6px; background: var(--green-700); border-radius: 50%; margin-right: 5px; }
.table-progress { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px 22px; }
.table-progress-item { min-width: 0; }
.table-progress-label { display: flex; justify-content: space-between; font-size: 11px; margin-bottom: 7px; }
.table-progress-label span { color: var(--muted); }
.progress-track { height: 6px; border-radius: 5px; background: #edf1ed; overflow: hidden; }
.progress-track i { display: block; height: 100%; background: var(--green-700); border-radius: 5px; }
.recent-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.recent-row:last-child { border: 0; }
.recent-row .person-avatar { width: 31px; height: 31px; font-size: 12px; }
.recent-row strong { display: block; font-size: 12px; }
.recent-row small { color: var(--muted); font-size: 10px; }
.recent-row time { margin-left: auto; color: var(--muted); font-size: 9px; white-space: nowrap; }
.list-heading { margin-bottom: 17px; }
.filter-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.filter-bar input { max-width: 300px; padding: 10px 12px; font-size: 12px; }
.filter-bar select { width: 145px; padding: 10px; font-size: 12px; }
.filter-count { margin-left: auto; color: var(--muted); font-size: 11px; white-space: nowrap; }
.data-table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.data-table th { text-align: left; color: #76837b; font-size: 10px; font-weight: 600; background: #f7f9f6; padding: 11px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.data-table td { padding: 12px; border-bottom: 1px solid #edf0ed; white-space: nowrap; }
.data-table td.position-cell { max-width: 190px; overflow: hidden; text-overflow: ellipsis; }
.data-table tr:hover td { background: #fbfcfa; }
.status-badge { display: inline-block; border-radius: 12px; padding: 4px 8px; font-size: 10px; background: #f1f2f0; color: #7d8580; }
.status-badge.signed { background: var(--green-100); color: var(--green-700); }
.row-action { border: 0; background: none; color: var(--red); padding: 0; font-size: 11px; }
.action-badge { font-size: 10px; padding: 3px 7px; border-radius: 4px; background: #f0f2ef; color: #56675d; }
.action-success { background: var(--green-100); color: var(--green-700); }
.action-not_found { background: #faeeec; color: var(--red); }
.settings-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 17px; }
.panel-description { color: var(--muted); font-size: 12px; line-height: 1.8; margin: -4px 0 17px; }
.download-template { color: var(--green-700); font-size: 12px; text-underline-offset: 3px; }
.import-form { margin-top: 22px; }
.file-picker { border: 1px dashed #b9cabe; border-radius: 11px; background: var(--green-50); padding: 27px !important; text-align: center; color: var(--green-700); cursor: pointer; margin-bottom: 18px !important; }
.file-picker input { display: none; }
.import-form select { margin-bottom: 13px; }
.confirm-check { font-size: 11px !important; color: var(--red); font-weight: 400 !important; }
.confirm-check input { width: auto; vertical-align: middle; }
.qr-panel { text-align: center; }
.qr-panel .panel-heading { text-align: left; }
.qr-frame { background: #fff; border: 1px solid var(--line); padding: 12px; width: 220px; height: 220px; margin: 20px auto 13px; }
.qr-frame img { width: 100%; height: 100%; }
.signin-url { color: var(--muted); font-size: 10px; word-break: break-all; }
.warning-note { color: #96753e; background: #fbf6ec; font-size: 10px; line-height: 1.6; padding: 10px; border-radius: 7px; margin-top: 18px; }
.toast { position: fixed; right: 28px; bottom: 28px; background: var(--green-950); color: #fff; border-radius: 10px; padding: 13px 20px; box-shadow: var(--shadow); font-size: 12px; z-index: 20; }
@media (max-width: 1000px) {
  .admin-main { padding: 25px 22px; margin-left: 190px; }
  .admin-sidebar { width: 190px; }
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid, .settings-grid { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .attendee-hero { padding: 43px 20px 86px; border-radius: 0 0 34px 34px; }
  .hero-inner { width: 100%; }
  .event-brand { gap: 14px; }
  .school-mark.image-mark { width: 76px; height: 76px; }
  .event-brand h1 { font-size: 22px; letter-spacing: 1px; }
  .hero-subtitle { margin-top: 18px; font-size: 12px; }
  .attendee-shell { margin-top: -50px; padding: 0 14px 22px; }
  .attendee-card { padding: 24px 20px; border-radius: 22px; }
  .attendee-card h2 { font-size: 25px; }
  .success-header { gap: 14px; margin-bottom: 19px; }
  .success-badge { width: 46px; height: 46px; box-shadow: 0 0 0 6px rgba(22,128,90,.06); }
  .success-header h2 { font-size: 23px; }
  .seat-ticket strong b { font-size: 42px; }
  .search-card { padding: 20px; }
  .search-heading h3 { font-size: 17px; }
  .search-input-wrap { flex-direction: column; }
  #alumni-search-button { width: 100%; padding: 14px; }
  .admin-sidebar { position: static; width: 100%; padding: 15px; }
  .admin-brand { padding: 0 5px 13px; }
  .admin-nav { display: flex; overflow-x: auto; }
  .admin-nav button { white-space: nowrap; padding: 10px; }
  .sidebar-bottom { display: none; }
  .admin-main { margin-left: 0; padding: 20px 13px; }
  .admin-topbar { align-items: flex-start; }
  #current-time { display: none; }
  .metric-card { padding: 16px; }
  .metric-card strong { font-size: 28px; }
  .table-progress { grid-template-columns: repeat(2, 1fr); }
  .filter-bar { flex-wrap: wrap; }
  .filter-bar input { max-width: none; }
  .filter-count { width: 100%; text-align: right; }
  .login-card { padding: 30px 24px; }
}
