:root { color-scheme: light; font-family: "Microsoft YaHei UI", "Segoe UI", sans-serif; background: #f4f6f8; color: #18212b; }
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; }
.app-header { min-height: 72px; padding: 14px 28px; display: flex; align-items: center; justify-content: space-between; background: #17212b; color: #fff; }
.brand { font-size: 19px; font-weight: 700; }
.subtitle { margin-top: 3px; color: #b9c5d0; font-size: 13px; }
.header-actions { display: flex; align-items: center; gap: 14px; }
.header-actions a { color: #dfe7ed; text-decoration: none; font-size: 13px; }
.header-actions form { margin: 0; }
.page-shell { width: min(1500px, 100%); margin: 0 auto; padding: 24px; }
.login-panel, .generated-panel { width: min(440px, 100%); margin: 8vh auto 0; background: #fff; border: 1px solid #dce2e7; padding: 28px; border-radius: 6px; }
h1, h2 { margin: 0; font-size: 20px; letter-spacing: 0; }
.form-stack { display: grid; gap: 16px; margin-top: 24px; }
label { display: grid; gap: 7px; color: #4a5968; font-size: 13px; }
input, select, textarea { width: 100%; border: 1px solid #bdc8d2; border-radius: 4px; padding: 10px 11px; background: #fff; color: #17212b; font: inherit; }
input:focus, select:focus, textarea:focus { outline: 2px solid #1f77d0; outline-offset: 0; border-color: #1f77d0; }
.button, button { min-height: 36px; border: 1px solid #aeb9c4; border-radius: 4px; padding: 8px 14px; background: #fff; color: #1d2b38; cursor: pointer; text-decoration: none; font: inherit; }
.button.primary { border-color: #1769b5; background: #1769b5; color: #fff; }
.button.secondary { background: transparent; color: inherit; }
.alert { margin-top: 18px; padding: 10px 12px; border-radius: 4px; }
.alert.error { background: #fff0f0; color: #a22b2b; border: 1px solid #ecc0c0; }
.stats-bar { display: grid; grid-template-columns: repeat(4, minmax(120px, 1fr)); background: #fff; border: 1px solid #dce2e7; }
.stats-bar div { padding: 18px 20px; border-right: 1px solid #e3e8ec; }
.stats-bar div:last-child { border-right: 0; }
.stats-bar span { display: block; color: #627181; font-size: 13px; }
.stats-bar strong { display: block; margin-top: 6px; font-size: 24px; }
.section-band { margin-top: 20px; background: #fff; border: 1px solid #dce2e7; padding: 20px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.generate-form { display: grid; grid-template-columns: 150px 110px minmax(240px, 1fr) auto; gap: 12px; align-items: end; }
.table-band { padding: 0; }
.table-band .section-heading { padding: 20px 20px 0; }
.table-scroll { overflow: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { padding: 12px 14px; border-top: 1px solid #e3e8ec; text-align: left; vertical-align: middle; white-space: nowrap; }
th { color: #566575; background: #f8fafb; font-weight: 600; }
.mono { font-family: Consolas, monospace; }
.status { display: inline-block; padding: 3px 7px; border-radius: 3px; background: #edf1f4; }
.status.active { background: #e8f6ed; color: #176d39; }
.status.disabled, .status.expired { background: #fdecec; color: #9d2e2e; }
.actions { display: flex; gap: 6px; }
.actions form { margin: 0; }
.actions button { min-height: 30px; padding: 4px 8px; font-size: 12px; }
.extend-form { display: flex; gap: 4px; }
.extend-form input { width: 72px; min-height: 30px; padding: 4px 6px; }
.empty { padding: 30px; color: #71808e; text-align: center; }
.generated-panel textarea { height: 260px; margin-top: 18px; font-family: Consolas, monospace; line-height: 1.7; }
.button-row { display: flex; gap: 10px; margin-top: 16px; }
@media (max-width: 800px) { .page-shell { padding: 12px; } .app-header { padding: 12px 16px; } .stats-bar { grid-template-columns: repeat(2, 1fr); } .stats-bar div:nth-child(2) { border-right: 0; } .generate-form { grid-template-columns: 1fr 1fr; } .note-field { grid-column: 1 / -1; } }
