/* Invitation workspace: warm brand accent, neutral surfaces, clear navigation. */
:root {
  color-scheme: light;
  --paper: #f6f7f9; --card: #fff; --ink: #242a35; --muted: #626c7b;
  --line: #e3e6eb; --accent: #a64828; --accent-soft: #fff1e9;
  --danger: #b42318; --success: #247553;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; color: var(--ink); background: var(--paper); font-size: 14px; line-height: 1.65; -webkit-text-size-adjust: 100%; }
a { color: var(--accent); text-underline-offset: 4px; }
button, input, select { font: inherit; }
button, a, input, select, summary { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid #a6482870; outline-offset: 4px; }
.page { max-width: 1184px; padding: 0 40px 24px; margin: 0 auto; }
.header { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--line); }
.brand { font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif; display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brandMark { display: block; flex: 0 0 auto; width: 40px; height: 40px; }
.brand strong { display: block; color: #173f35; font-size: 22px; font-weight: 700; line-height: 1.2; letter-spacing: .02em; }
.brand small { display: block; margin-top: 4px; color: #62786f; font-size: 11px; font-weight: 400; line-height: 1.4; letter-spacing: .02em; }
.languageSwitch { display: flex; padding: 3px; background: #eaecef; border-radius: 8px; gap: 2px; }
.languageSwitch button { border: 0; border-radius: 5px; background: transparent; color: var(--muted); min-height: 32px; padding: 3px 12px; cursor: pointer; font-size: 12px; }
.languageSwitch button[aria-pressed="true"] { background: #fff; color: var(--ink); box-shadow: 0 1px 3px #20273312; }
.hero { padding: 36px 0 26px; }
.eyebrow { color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: .12em; margin: 0 0 8px; }
h1 { font-size: clamp(26px, 3vw, 34px); line-height: 1.35; letter-spacing: -.03em; margin: 0 0 12px; font-weight: 650; }
.lead { max-width: 720px; color: var(--muted); margin: 0; font-size: 14px; }
h2 { font-size: 17px; line-height: 1.5; margin: 0; font-weight: 650; }
.sectionNav { display: flex; gap: 26px; border-bottom: 1px solid var(--line); margin-bottom: 24px; }
.sectionNav a { min-height: 46px; display: flex; align-items: center; gap: 7px; padding: 8px 2px 12px; border-bottom: 2px solid transparent; text-decoration: none; font-weight: 550; color: var(--muted); }
.sectionNav a:hover { color: var(--ink); }
.sectionNav a[aria-current="page"] { color: var(--accent); border-color: var(--accent); }
.navDot { width: 6px; height: 6px; background: var(--accent); border-radius: 50%; }
.workspace { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 24px; align-items: start; }
.mainColumn, [data-panel] { min-width: 0; }
[data-panel] { display: grid; gap: 16px; }
.card { padding: 26px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); box-shadow: 0 2px 5px #172b4d03; }
.cardHeading { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.subtleLabel { font-size: 11px; color: var(--muted); }
.stateBadge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border-radius: 6px; color: var(--muted); background: #f0f2f5; font-size: 12px; font-weight: 550; margin: 0; }
.stateBadge::before { content: ""; width: 6px; height: 6px; background: currentColor; border-radius: 50%; }
.stateBadge[data-status="open"], .stateBadge[data-status="allocated"] { color: var(--success); background: #eaf5ef; }
.stateBadge[data-status="unavailable"] { color: var(--danger); background: #fef0ee; }
.stateMessage { color: var(--muted); margin: 0 0 22px; font-size: 13px; }
.roundFacts { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.roundFacts > div { min-width: 0; border-top: 1px solid var(--line); padding-top: 16px; }
.roundFacts dt { color: var(--muted); font-size: 12px; margin-bottom: 6px; }
.roundFacts dd { margin: 0; font-size: 14px; font-weight: 550; overflow-wrap: anywhere; }
#roundFacts > div:first-child, #roundFacts > div:nth-child(4), #roundFacts > div:last-child { grid-column: 1 / -1; }
#factQuota, #factQueue { font-size: 26px; line-height: 1.3; font-variant-numeric: tabular-nums; letter-spacing: -.025em; }
#applicationCard .roundFacts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.actions, .overviewActions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.actions { margin-top: 18px; }
button, .primaryButton, .secondaryButton { transition: background .15s, border-color .15s; }
.primaryButton, .secondaryButton { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid transparent; border-radius: 7px; min-height: 40px; padding: 9px 16px; font-weight: 550; font-size: 13px; line-height: 1.5; text-decoration: none; cursor: pointer; text-align: center; }
.primaryButton { color: #fff; background: var(--accent); border-color: var(--accent); }
.primaryButton:hover { background: #893b21; border-color: #893b21; }
.secondaryButton { background: #fff; color: var(--ink); border-color: #d7dce3; }
.secondaryButton:hover { background: #f7f8fa; border-color: #afb8c5; }
button:disabled { cursor: wait; opacity: .55; }
button[aria-busy="true"]::before { content: ""; width: 12px; height: 12px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.guide { padding: 24px; background: #fbfcfd; box-shadow: none; }
.guide h2 { font-size: 15px; }
.journey { list-style: none; margin: 26px 0; padding: 0; }
.journey li { position: relative; display: flex; gap: 12px; padding-bottom: 24px; }
.journey li:last-child { padding-bottom: 0; }
.journey li:not(:last-child)::after { content: ""; position: absolute; top: 29px; bottom: 4px; left: 13px; width: 1px; background: var(--line); }
.stepNumber { display: grid; place-items: center; width: 28px; height: 28px; flex-shrink: 0; border: 1px solid #d7dce3; border-radius: 50%; font-size: 11px; color: var(--muted); background: #fff; }
.journey li[aria-current="step"] .stepNumber { background: var(--accent-soft); color: var(--accent); border-color: #eacbbd; }
.journey strong { font-size: 13px; font-weight: 550; }
.journey p, .guideNote p { color: var(--muted); font-size: 12px; margin: 5px 0 0; }
.guideNote { border-top: 1px solid var(--line); padding-top: 20px; font-size: 12px; }
.guideNote strong { font-weight: 550; }
.guideNote a { display: inline-block; margin-top: 12px; font-weight: 550; }
form { display: grid; gap: 20px; }
.formFields { min-width: 0; margin: 0; padding: 18px 0 0; border: 0; border-top: 1px solid var(--line); }
.formFields legend { padding: 0 10px 0 0; font-size: 12px; font-weight: 600; }
.formFields > .hint { margin-top: 0; }
.fieldGrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
label:not(.checkboxRow) { display: grid; gap: 7px; min-width: 0; }
label strong { display: block; font-size: 13px; font-weight: 550; }
label small { display: block; color: var(--muted); font-size: 11px; margin-top: 2px; }
input:not([type="checkbox"]), select { min-width: 0; width: 100%; min-height: 42px; padding: 10px 12px; color: var(--ink); background: #fff; border: 1px solid #cdd3dc; border-radius: 7px; line-height: 1.4; }
input:focus, select:focus { border-color: var(--accent); }
input[aria-invalid="true"] { border-color: var(--danger); }
.checkboxRow { display: flex; align-items: flex-start; gap: 10px; color: var(--muted); font-size: 12px; }
input[type="checkbox"] { width: 16px; height: 16px; flex-shrink: 0; margin: 3px 0 0; accent-color: var(--accent); }
.privacyRow { background: #f7f8fa; border-radius: 8px; padding: 14px; }
.monthFallback { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
#registerSubmit, #lookupSubmit { justify-self: start; }
.hint { color: var(--muted); font-size: 12px; }
.formError { margin: 0; padding: 12px 14px; background: #fff2f0; color: var(--danger); border: 1px solid #f8d4cc; border-radius: 8px; font-size: 13px; }
.statusHint { margin: 22px 0 0; padding: 14px 16px; border: 1px solid #eee2d7; border-radius: 8px; background: #fffbf6; font-size: 13px; }
code { display: inline-block; padding: 5px 9px; border-radius: 5px; background: #f0f2f5; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; overflow-wrap: anywhere; }
.credentialBox { margin-top: 24px; padding-top: 22px; border-top: 1px solid var(--line); }
.credentialLead { font-size: 13px; font-weight: 550; margin: 0 0 14px; }
.credentialFacts { display: grid; gap: 10px; margin: 0; }
.credentialFacts > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.credentialFacts dt { font-size: 12px; color: var(--muted); }
.credentialFacts dd { margin: 0; }
.credentialFacts code { font-size: 15px; letter-spacing: .04em; }
.credentialBox .checkboxRow { margin-top: 18px; }
.credentialImageBox { margin: 16px 0 0; }
.credentialImageBox img { display: block; width: 100%; max-width: 380px; border: 1px solid var(--line); border-radius: 8px; }
.credentialImageBox figcaption { display: flex; flex-wrap: wrap; gap: 10px; font-size: 12px; margin-top: 8px; color: var(--muted); }
.lookupCard > summary { cursor: pointer; font-weight: 550; font-size: 14px; list-style: none; }
.lookupCard > summary::-webkit-details-marker { display: none; }
.lookupCard > summary::after { content: "+"; float: right; color: var(--muted); padding-left: 12px; }
.lookupCard[open] > summary::after { content: "−"; }
.lookupCard > p { color: var(--muted); font-size: 12px; }
.lookupCard form { margin-top: 20px; }
.warning { color: var(--accent); background: var(--accent-soft); padding: 10px 14px; font-size: 13px; border-radius: 7px; }
#issuedCode { font-size: 19px; padding: 16px; width: 100%; border: 1px dashed #d7b7a8; color: var(--accent); background: #fffaf7; letter-spacing: .03em; user-select: all; }
#wechatQr { display: block; width: 180px; max-width: 100%; border-radius: 8px; margin-top: 18px; }
#overviewWechatQr { display: block; width: 240px; max-width: 100%; height: auto; margin-top: 18px; }
.emptyState { padding: 36px 28px; text-align: center; }
.emptyIcon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: #f0f2f5; color: var(--muted); font-size: 23px; margin: 0 auto 16px; }
.emptyState p { color: var(--muted); font-size: 13px; margin: 12px auto 22px; max-width: 400px; }
.emptyState a { margin: 4px; }
.footer { display: flex; justify-content: space-between; gap: 16px; border-top: 1px solid var(--line); margin-top: 36px; padding-top: 18px; color: var(--muted); font-size: 11px; }
.footer p { margin: 0; }
.skipLink { position: fixed; left: 16px; top: -100px; padding: 12px 16px; background: #fff; z-index: 10; }
.skipLink:focus { top: 12px; }
@media (max-width: 900px) { .page { padding-inline: 24px; } .workspace { grid-template-columns: minmax(0, 1fr) 240px; gap: 18px; } .card { padding: 22px; } .fieldGrid { grid-template-columns: 1fr; } }
@media (max-width: 680px) {
  .page { padding: 0 16px 24px; } .header { min-height: 76px; } .hero { padding-top: 28px; } .lead { font-size: 13px; }
  .sectionNav { gap: 20px; } .sectionNav a { font-size: 13px; }
  .workspace { grid-template-columns: minmax(0, 1fr); } .card { padding: 20px; } .guide { margin-top: 4px; }
  .roundFacts, #applicationCard .roundFacts { gap: 16px; } #applicationCard .roundFacts { grid-template-columns: 1fr; }
  .credentialFacts > div { align-items: flex-start; flex-direction: column; gap: 4px; }
  .actions > *, .overviewActions > * { flex: 1 1 auto; } .footer { flex-direction: column; gap: 8px; }
  input:not([type="checkbox"]), select { font-size: 16px; } .languageSwitch button { min-height: 36px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
