:root {
    color-scheme: light;
    --ink: #17211b;
    --muted: #66736c;
    --line: #dfe7e2;
    --paper: #ffffff;
    --canvas: #f4f7f5;
    --brand: #194f38;
    --brand-dark: #103c2a;
    --accent: #d8efe3;
    --danger: #9f2f2f;
}

* { box-sizing: border-box; }
body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--canvas);
    color: var(--ink);
}
button, input, textarea, select { font: inherit; }
a { color: var(--brand); }
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 3px solid #83c9a5;
    outline-offset: 3px;
}
.topbar {
    min-height: 64px;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--brand-dark);
    color: white;
}
.topbar > div { display: flex; align-items: center; gap: 18px; }
.brand { color: white; font-weight: 800; text-decoration: none; letter-spacing: .01em; }
.inline-form { display: inline; }
.link-button {
    min-height: 44px;
    padding: 8px;
    border: 0;
    background: none;
    color: #cde4d8;
    cursor: pointer;
}
.auth-shell { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.page-shell { width: min(1040px, calc(100% - 40px)); margin: 0 auto; padding: 54px 0 80px; }
.card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 28px;
    box-shadow: 0 12px 35px rgba(20, 52, 37, .06);
}
.auth-card { width: min(440px, 100%); padding: 38px; }
.eyebrow {
    margin: 0 0 8px;
    color: var(--brand);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}
h1 { margin: 0; font-size: clamp(30px, 4vw, 44px); line-height: 1.1; }
h2 { margin: 0 0 18px; font-size: 19px; }
.muted { color: var(--muted); }
.page-heading { margin-bottom: 28px; }
.form-stack, .form-grid { display: grid; gap: 20px; margin-top: 26px; }
.form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.full { grid-column: 1 / -1; }
label { display: grid; gap: 8px; font-weight: 700; }
label span { color: var(--muted); font-size: 12px; font-weight: 500; }
input, textarea, select {
    width: 100%;
    border: 1px solid #bdc9c2;
    border-radius: 9px;
    padding: 12px 13px;
    background: white;
    color: var(--ink);
}
input:focus, textarea:focus, select:focus { border-color: var(--brand); }
button {
    min-height: 44px;
    border: 0;
    border-radius: 9px;
    padding: 12px 20px;
    background: var(--brand);
    color: white;
    font-weight: 800;
    cursor: pointer;
}
button:hover { background: var(--brand-dark); }
.actions { display: flex; justify-content: flex-end; gap: 12px; flex-wrap: wrap; }
.alert { margin-top: 18px; padding: 12px 14px; border-radius: 8px; background: #fde8e8; color: var(--danger); }
.workspace-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.workspace-grid .full { grid-column: 1 / -1; }
.back-link { display: inline-block; margin-bottom: 24px; text-decoration: none; font-weight: 700; }
dl { margin: 0; }
dl div { padding: 12px 0; border-top: 1px solid var(--line); }
dt { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
dd { margin: 5px 0 0; font-weight: 700; }
.clean-list { margin: 0; padding: 0; list-style: none; }
.clean-list li { padding: 12px 0; border-top: 1px solid var(--line); overflow-wrap: anywhere; }
.timeline { margin: 0; padding-left: 22px; }
.timeline li { padding: 0 0 24px 10px; }
.timeline time { display: block; color: var(--muted); font-size: 12px; margin-bottom: 5px; }
.contact-lines { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 8px; color: var(--muted); font-size: 14px; }
.follow-up-heading { margin-top: 42px; }
.attention-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.count-badge { display: inline-grid; place-items: center; min-width: 28px; min-height: 28px; padding: 2px 8px; border-radius: 999px; background: var(--accent); color: var(--brand-dark); font-size: 14px; }
@media (max-width: 700px) {
    .topbar { padding: 10px 18px; gap: 12px; flex-wrap: wrap; }
    .topbar > div { gap: 8px; flex-wrap: wrap; }
    .page-shell { width: min(100% - 28px, 1040px); padding-top: 36px; }
    .form-grid, .workspace-grid { grid-template-columns: 1fr; }
    .attention-grid { grid-template-columns: 1fr; }
    .workspace-grid .full { grid-column: auto; }
    .card { padding: 22px; }
    .actions { justify-content: stretch; }
    .actions button { flex: 1 1 auto; }
}
