:root {
  color-scheme: light;
  --ink: #183039;
  --muted: #4c666e;
  --faint: #6e8388;
  --base: #f3f7f6;
  --surface: #fff;
  --line: #dce6e4;
  --line-dark: #c8d8d4;
  --nav: #142a36;
  --nav-ink: #e3f0ee;
  --nav-muted: #b6cbca;
  --green: #17654d;
  --green-deep: #0f5340;
  --mint: #dff3e9;
  --amber: #855212;
  --shadow: 0 13px 34px rgba(19, 44, 46, .07);
  --radius: 14px;
  font-family: "Public Sans", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: var(--base); color: var(--ink); font-size: 1rem; line-height: 1.55; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .65; }
input, textarea, select { width: 100%; min-width: 0; color: var(--ink); }
a { color: var(--green); }
a, button, input, textarea, select, [tabindex] { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid #168463; outline-offset: 3px; }
::selection { color: #073c2a; background: #b9e9d1; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { line-height: 1.25; letter-spacing: -.03em; }
h1 { font-size: clamp(1.75rem, 4vw, 2.55rem); font-weight: 750; }
h2 { font-size: 1.325rem; }
h3 { font-size: 1.075rem; }
.icon { width: 1.15rem; height: 1.15rem; flex: 0 0 auto; vertical-align: -.18em; }
.boot { min-height: 100svh; display: grid; place-content: center; justify-items: center; gap: 1rem; color: var(--muted); }
.brand { display: flex; align-items: center; gap: .7rem; font-weight: 720; font-size: 1.0625rem; letter-spacing: .015em; }
.brand-mark { display: grid; place-content: center; width: 2.5rem; height: 2.5rem; border-radius: .75rem; color: #113f35; background: #a7edcb; font-size: .95rem; font-weight: 800; flex: none; }
.brand-mark .icon { width: 1.55rem; height: 1.55rem; }
.brand-caption { display: block; font-size: .75rem; font-weight: 450; color: var(--nav-muted); letter-spacing: .04em; }
.btn { text-decoration: none; border: 1px solid transparent; min-height: 2.45rem; padding: .45rem .9rem; border-radius: .55rem; display: inline-flex; justify-content: center; align-items: center; gap: .45rem; font-weight: 630; font-size: .875rem; white-space: nowrap; }
.btn-primary { color: #fff; background: var(--green); border-color: var(--green); }
.btn-primary:hover { background: var(--green-deep); }
.btn-secondary { color: var(--ink); border-color: var(--line-dark); background: var(--surface); }
.btn-secondary:hover { border-color: #a4bbb3; background: #f7faf9; }
.btn-quiet { color: var(--muted); background: transparent; border-color: transparent; }
.btn-quiet:hover { color: var(--green); background: #edf4f1; }
.btn-error { color: #9d3a32; background: #fff9f8; border-color: #f0d8d3; }
.icon-button { min-height: 2.35rem; min-width: 2.35rem; border: 1px solid var(--line); border-radius: .55rem; background: #fff; color: var(--ink); display: inline-grid; place-content: center; padding: .35rem; }
.icon-button:hover { border-color: var(--line-dark); background: var(--base); }
.login-layout { display: grid; grid-template-columns: minmax(18rem, 1fr) minmax(22rem, 1fr); min-height: 100svh; background: var(--surface); }
.login-banner { position: relative; display: flex; flex-direction: column; justify-content: space-between; gap: 3rem; padding: clamp(2rem, 6vw, 5rem); color: var(--nav-ink); background: var(--nav); overflow: hidden; }
.login-banner::before { content: ""; position: absolute; inset: 36% -10% -22% 12%; border: 1px solid #88cab840; border-radius: 50%; transform: scaleY(.66) rotate(-25deg); box-shadow: 0 0 0 2rem #88cab819, 0 0 0 4rem #88cab812, 0 0 0 6rem #88cab80e, 0 0 0 8rem #88cab80b; pointer-events: none; }
.banner-content { position: relative; max-width: 29rem; margin: 5vh 0; }
.banner-content h1 { color: #fff; font-size: clamp(2.25rem, 4.4vw, 4.25rem); line-height: 1.11; }
.banner-content p { color: var(--nav-muted); margin-top: 1.2rem; font-size: 1.0625rem; }
.banner-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; max-width: 30rem; }
.banner-step { position: relative; border-top: 2px solid #6cb79e; padding-top: .65rem; color: var(--nav-muted); font-size: .875rem; }
.login-content { display: grid; place-items: center; padding: 2rem; }
.login-card { width: min(100%, 22rem); }
.login-card > p { margin: .55rem 0 1.7rem; color: var(--muted); }
.login-card form { display: grid; gap: .95rem; }
.login-card .btn { min-height: 2.75rem; margin-top: .35rem; }
.shell { display: grid; grid-template-columns: 15.75rem minmax(0, 1fr); height: 100svh; }
.sidebar { display: flex; flex-direction: column; gap: .83rem; background: var(--nav); color: var(--nav-ink); min-height: 0; padding: 1.15rem .9rem .75rem; }
.sidebar .brand { padding: 0 .35rem; }
.side-project { display: block; min-width: 0; margin: 0 .15rem; padding: .75rem .8rem; color: #fff; text-decoration: none; border: 1px solid #355563; background: #213a46; border-radius: .7rem; }
.side-project small { display: block; color: var(--nav-muted); margin-bottom: .08rem; font-size: .75rem; }
.side-project strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .875rem; }
.side-scroll { flex: 1; min-height: 0; overflow: auto; scrollbar-color: #47636e transparent; }
.side-label { color: var(--nav-muted); font-weight: 600; margin: .72rem .55rem .27rem; font-size: .75rem; letter-spacing: .025em; }
.side-label:first-child { margin-top: .1rem; }
.side-link { display: flex; align-items: center; gap: .7rem; width: 100%; min-height: 2.3rem; color: var(--nav-ink); padding: .38rem .6rem; text-decoration: none; border-radius: .52rem; font-size: .875rem; margin-bottom: .11rem; }
.side-link:hover { background: #26454e; }
.side-link[aria-current] { background: #315549; color: #c3f2d9; font-weight: 670; }
.side-link span { min-width: 0; }
.side-footer { border-top: 1px solid #38545d; padding: .65rem .2rem 0; }
.side-footer button { color: var(--nav-muted); }
.side-footer button:hover { color: #fff; background: #26454e; }
.workspace { min-width: 0; height: 100%; display: flex; flex-direction: column; }
.topbar { flex: none; background: var(--surface); border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; min-height: 4.15rem; padding: .55rem clamp(1rem, 3vw, 2rem); gap: 1rem; }
.topbar-left, .topbar-right { display: flex; align-items: center; gap: .75rem; min-width: 0; }
.breadcrumbs { display: flex; align-items: center; gap: .55rem; min-width: 0; font-size: .875rem; color: var(--muted); }
.breadcrumbs a { text-decoration: none; white-space: nowrap; }
.breadcrumbs .current { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); font-weight: 630; }
.switcher { min-width: 7rem; width: auto; max-width: 13rem; background: var(--base); }
.identity { display: grid; place-items: center; border-radius: 50%; background: var(--mint); width: 2rem; height: 2rem; font-size: .8125rem; font-weight: 700; color: var(--green-deep); flex: none; }
.mobile-nav { display: none; }
.workspace-content { min-height: 0; flex: 1; overflow: auto; scroll-behavior: smooth; }
.content { max-width: 91rem; min-width: 0; margin: 0 auto; padding: clamp(1rem, 3vw, 2.2rem) clamp(1rem, 3.4vw, 2.5rem) 3rem; }
.page-head { margin-bottom: 1.3rem; }
.page-kicker { color: var(--green); font-size: .8125rem; font-weight: 680; margin-bottom: .25rem; }
.page-title-row { display: flex; justify-content: space-between; align-items: start; gap: .95rem; }
.page-title-row h1 { overflow-wrap: anywhere; }
.page-head p:not(.page-kicker) { color: var(--muted); margin-top: .55rem; max-width: 48rem; }
.actions { display: flex; align-items: center; flex-wrap: wrap; gap: .5rem; }
.panel { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: clamp(.9rem, 2vw, 1.3rem); min-width: 0; }
.panel + .panel { margin-top: 1rem; }
.panel-head { display: flex; justify-content: space-between; align-items: flex-start; gap: .75rem; margin-bottom: .95rem; }
.panel-head p { font-size: .875rem; color: var(--muted); margin-top: .25rem; }
.grid { display: grid; gap: .9rem; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.eyebrow { color: var(--faint); font-size: .8125rem; }
.stat { min-height: 6.3rem; padding: .9rem; background: #fff; border: 1px solid var(--line); border-radius: .8rem; }
.stat-value { display: block; font-size: 1.6rem; font-weight: 720; line-height: 1.2; margin: .3rem 0; overflow-wrap: anywhere; }
.stat-value.small { font-size: 1.15rem; }
.dashboard-hero { margin-bottom: 1rem; background: #e5f3ed; border-color: #cbe7da; }
.dashboard-hero .eyebrow { color: var(--green); margin-bottom: .4rem; font-weight: 660; }
.dashboard-hero h2 { font-size: clamp(1.25rem, 2.2vw, 1.72rem); }
.dashboard-hero p:last-child { color: var(--muted); margin-top: .56rem; max-width: 46rem; }
.project-card { display: flex; flex-direction: column; height: 100%; gap: .55rem; color: var(--ink); text-decoration: none; background: #fff; border: 1px solid var(--line); border-radius: .8rem; min-height: 9.6rem; padding: 1rem; overflow: hidden; }
.project-card:hover { box-shadow: var(--shadow); border-color: #9ebcaf; }
.project-card h2 { font-size: 1.15rem; overflow-wrap: anywhere; }
.project-card p { font-size: .875rem; color: var(--muted); overflow-wrap: anywhere; }
.project-card .card-icon { color: var(--green); margin-bottom: .15rem; }
.project-card .tag { margin-top: auto; align-self: flex-start; }
.card-icon { display: inline-grid; place-items: center; width: 2.15rem; height: 2.15rem; border-radius: .58rem; background: var(--mint); color: var(--green-deep); }
.tag { display: inline-flex; align-items: center; border-radius: .42rem; color: #4d6366; background: #edf2f2; border: 1px solid #dbe5e4; padding: .13rem .46rem; font-size: .75rem; font-weight: 620; white-space: nowrap; vertical-align: middle; }
.tag-green { background: #e4f5e9; color: #24603e; border-color: #d1ead8; }
.tag-amber { background: #fff3df; color: #795319; border-color: #efdfbf; }
.tag-red { background: #fceae7; color: #963e35; border-color: #f4d6ce; }
.tabs { display: flex; gap: .3rem; padding: .3rem; border: 1px solid var(--line); background: #e9f0ee; border-radius: .65rem; overflow-x: auto; margin-bottom: .9rem; }
.tab { border-radius: .4rem; text-decoration: none; padding: .45rem .62rem; color: var(--muted); line-height: 1.4; flex: 0 0 auto; font-size: .875rem; white-space: nowrap; }
.tab[aria-current] { background: var(--surface); color: var(--green-deep); font-weight: 720; box-shadow: 0 1px 2px #19343220; }
.flow { display: flex; flex-wrap: wrap; gap: .38rem; padding: 0; margin: .8rem 0 0; list-style: none; }
.flow li { color: #23564a; background: #f0f8f4; border: 1px solid #d4e9e1; border-radius: .4rem; padding: .24rem .5rem; font-size: .8125rem; }
.empty { text-align: center; display: grid; gap: .35rem; justify-items: center; padding: 2.7rem .7rem; border: 1px dashed #d5e1de; background: #f8fbfa; border-radius: .65rem; }
.empty .card-icon { margin-bottom: .3rem; }
.empty h3 { font-size: 1rem; }
.empty p { color: var(--muted); font-size: .875rem; max-width: 24rem; }
.empty .btn { margin-top: .6rem; }
.record-list { display: grid; }
.record-row { display: flex; justify-content: space-between; align-items: center; gap: .85rem; padding: .73rem 0; border-bottom: 1px solid var(--line); min-width: 0; }
.record-row:first-child { padding-top: .1rem; }
.record-row:last-child { border-bottom: 0; padding-bottom: .15rem; }
.record-main { min-width: 0; display: flex; align-items: center; gap: .6rem; }
.record-main button, .plain-link { color: var(--ink); border: 0; background: transparent; padding: 0; text-align: left; font-weight: 670; overflow-wrap: anywhere; }
.record-main button:hover, .plain-link:hover { color: var(--green); text-decoration: underline; }
.record-main small { display: block; color: var(--faint); font-weight: 400; font-size: .8125rem; }
.record-end { display: flex; align-items: center; gap: .5rem; flex-shrink: 0; }
.record-row .card-icon { flex: none; }
.skill-card { display: flex; flex-direction: column; align-items: flex-start; gap: .6rem; border: 1px solid var(--line); background: #fff; border-radius: .8rem; padding: .9rem; min-width: 0; }
.skill-card h3 { font-size: 1.03rem; }
.skill-card p { font-size: .875rem; color: var(--muted); }
.skill-card .btn { margin-top: auto; }
.skill-card .card-icon { margin-bottom: .15rem; }
.skill-grid { margin-bottom: 1rem; }
.section-gap { margin-top: 1rem; }
.notice { border-left: 3px solid #88bfa8; background: #eef6f3; padding: .65rem .8rem; border-radius: .3rem; margin-bottom: .95rem; font-size: .875rem; color: #345f55; }
.notice-warning { border-color: #bf873f; background: #fff6e8; color: #744b1b; }
.guide { padding-left: 1.2rem; }
.guide li { margin: .35rem 0; }
.screen-error { margin: 2rem auto; max-width: 32rem; }
.record-fields { display: grid; gap: .75rem; margin: 0; }
.record-fields > div { min-width: 0; border-bottom: 1px solid var(--line); padding-bottom: .55rem; }
.record-fields > div:last-child { border-bottom: 0; }
.record-fields dt { color: var(--faint); font-size: .8125rem; margin-bottom: .2rem; }
.record-fields dd { margin: 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.record-fields dd ul { margin: .3rem 0; padding-left: 1.2rem; }
.record-fields dd ul li { padding: .14rem 0; white-space: pre-wrap; }
.json-data { margin: 0; white-space: pre-wrap; border-radius: .45rem; background: #f3f7f6; padding: .65rem .75rem; font-size: .82rem; line-height: 1.45; }
.input-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .8rem; }
.input-grid .wide { grid-column: 1 / -1; }
.field { display: grid; gap: .28rem; font-size: .875rem; font-weight: 620; min-width: 0; }
.field small { font-weight: 400; color: var(--muted); font-size: .8125rem; }
.field-caption { margin-top: .1rem; }
input:not([type=checkbox]), textarea, select { border: 1px solid var(--line-dark); border-radius: .5rem; background: var(--surface); padding: .5rem .58rem; font-size: .9rem; min-height: 2.55rem; }
input:not([type=checkbox]):hover, textarea:hover, select:hover { border-color: #93aea6; }
input[type=checkbox] { width: 1.1rem; height: 1.1rem; accent-color: var(--green); }
.field input[type=checkbox] { justify-self: start; }
textarea { min-height: 5.9rem; resize: vertical; }
input::placeholder, textarea::placeholder { color: #718682; }
select { padding-right: 1.55rem; }
.inline-form { display: flex; gap: .55rem; align-items: end; flex-wrap: wrap; }
.inline-form .field { flex: 1 1 12rem; }
.form-error { color: #9d3a32; font-size: .875rem; padding: .58rem .66rem; background: #fff4f1; border: 1px solid #f4dbd3; border-radius: .55rem; margin-top: .75rem; }
.form-error:empty, .form-error[hidden] { display: none; }
.data-table { width: 100%; border-collapse: collapse; text-align: left; font-size: .875rem; }
.data-table th { color: var(--muted); font-weight: 650; white-space: nowrap; }
.data-table th, .data-table td { padding: .54rem .42rem; border-bottom: 1px solid var(--line); }
.data-table tr:last-child td { border-bottom: 0; }
.table-scroll { overflow-x: auto; min-width: 0; }
.dialog-content { display: grid; gap: 1rem; }
dialog { border: 1px solid var(--line-dark); border-radius: 1rem; padding: 0; color: var(--ink); width: min(43rem, calc(100vw - 1.5rem)); max-width: unset; max-height: calc(100svh - 1.5rem); overflow: auto; box-shadow: 0 16px 58px #15343538; }
dialog::backdrop { background: #0f2b36a1; }
.dialog-head { display: flex; align-items: start; justify-content: space-between; gap: .85rem; background: #fff; padding: 1.05rem 1.1rem .8rem; border-bottom: 1px solid var(--line); }
.dialog-head p { color: var(--muted); margin-top: .35rem; font-size: .875rem; }
.dialog-body { background: #fff; padding: 1rem 1.1rem; }
.dialog-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: .45rem; padding-top: .95rem; }
.dialog-card { border: 1px solid var(--line); border-radius: .56rem; padding: .7rem; }
.dialog-card h3 { margin: .35rem 0 .6rem; }
.timeline-row > summary { cursor: pointer; font-weight: 650; }
.timeline-row > summary .tag { margin-left: .25rem; }
.filter-label { min-width: 11rem; }
.website-prefill { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; }
.notice.section-gap { margin: .75rem 0 0; }
.dialog-body video { display: block; width: 100%; max-height: 45vh; background: var(--nav); border-radius: .6rem; }
.toasts { position: fixed; z-index: 8; right: .8rem; bottom: .8rem; display: grid; gap: .45rem; width: min(23rem, calc(100vw - 1.6rem)); pointer-events: none; }
.toast { background: #163c35; color: #fff; border-radius: .62rem; box-shadow: var(--shadow); padding: .7rem .85rem; font-size: .875rem; overflow-wrap: anywhere; }
.toast-error { background: #813e38; }
.sr-only { position: absolute; overflow: hidden; width: 1px; height: 1px; padding: 0; margin: -1px; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media (max-width: 1050px) {
  .shell { grid-template-columns: 13rem minmax(0,1fr); }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 830px) {
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .login-banner { padding: 2rem; }
  .topbar { padding-inline: .8rem; }
  .switcher { max-width: 10rem; }
}
@media (max-width: 680px) {
  .shell { grid-template-columns: minmax(0,1fr); }
  .sidebar { display: none; position: fixed; z-index: 5; inset: 0 auto 0 0; width: min(17rem, 83vw); box-shadow: 0 0 0 100vmax #0f2c34a1; }
  .sidebar.is-open { display: flex; }
  .mobile-nav { display: inline-grid; }
  .login-layout { grid-template-columns: minmax(0,1fr); }
  .login-banner { padding: 1.2rem; gap: 1.2rem; }
  .banner-content { margin: .5rem 0; }
  .banner-content p { margin-top: .55rem; font-size: .95rem; }
  .banner-steps { display: none; }
  .login-content { padding: 1.75rem 1.15rem; align-items: start; }
  .topbar .identity { display: none; }
  .page-title-row { flex-direction: column; }
  .page-title-row .actions { width: 100%; }
}
@media (max-width: 450px) {
  .grid-2, .grid-3, .input-grid { grid-template-columns: minmax(0,1fr); }
  .input-grid .wide { grid-column: auto; }
  .topbar { gap: .55rem; }
  .topbar-left, .topbar-right, .breadcrumbs { gap: .35rem; }
  .switcher { max-width: 7.2rem; min-width: 4.4rem; }
  .projects-crumb { display: none; }
  .record-row { align-items: flex-start; gap: .5rem; }
  .record-end { flex-wrap: wrap; justify-content: flex-end; max-width: 38%; }
  .panel-head { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; } }
