:root {
  --tone: #00799d;
  --wash: #e0f3fa;
  --background: #f1f8fc;
  --ink: #18213a;
  --muted: #53617a;
  --line: #dce4ee;
  font: 13px/1.5 "Segoe UI", system-ui, sans-serif;
  color: var(--ink);
  background: var(--background);
}
* { box-sizing: border-box; }
body { margin: 0; }
a { color: #006688; text-underline-offset: .18em; }
button, input, select, textarea { font: inherit; color: inherit; }
button, .button {
  display: inline-flex; align-items: center; justify-content: center; white-space: nowrap;
  padding: 7px 12px; background: white; color: var(--ink); border: 1px solid #cad6e5;
  border-radius: 6px; cursor: pointer; font-weight: 600; text-decoration: none;
}
button:hover, .button:hover { background: var(--wash); }
.primary { background: var(--tone); color: white; border-color: var(--tone); }
.primary:hover { background: #006481; }
:focus-visible { outline: 3px solid #a55d12; outline-offset: 3px; }
.top {
  background: white; padding: 14px 22px; display: flex; align-items: center; gap: 16px;
  flex-wrap: wrap; border-bottom: 1px solid var(--line); min-height: 60px;
}
.brand { color: var(--ink); font-size: 18px; font-weight: 750; letter-spacing: -.5px; text-decoration: none; }
.brand b { color: var(--tone); margin-right: 3px; }
.account { margin-left: auto; display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 12px; }
.account form { margin-left: 8px; }
.layout { display: grid; grid-template-columns: 174px minmax(0, 1fr); min-height: calc(100vh - 60px); }
.side { background: var(--tone); color: white; padding: 24px 12px; }
.side a { display: block; padding: 9px 10px; border-radius: 7px; margin: 4px 0; color: white; text-decoration: none; }
.side a:hover, .side a[aria-current] { background: #ffffff26; }
.side a[aria-current] { font-weight: 700; }
.side small { margin: 24px 10px 6px; display: block; text-transform: uppercase; letter-spacing: .07em; }
.main { min-width: 0; width: 100%; max-width: 1460px; padding: 26px; }
.guest { max-width: 465px; margin: 42px auto; padding: 0 16px; }
h1, h2, h3, p { overflow-wrap: anywhere; }
h1 { font-size: 28px; line-height: 1.2; margin: 5px 0 14px; font-weight: 650; letter-spacing: -.8px; }
h2 { font-size: 17px; margin: 0 0 14px; }
h3 { font-size: 14px; margin: 0 0 7px; }
p { margin: 0 0 12px; }
.eyebrow { font-size: 11px; text-transform: uppercase; letter-spacing: 1.6px; font-weight: 700; }
.muted, .helptext { color: var(--muted); }
.helptext { display: block; font-size: 12px; }
.metricrow { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 20px 0; }
.metric {
  display: block; padding: 15px; background: var(--wash); border-top: 3px solid var(--tone);
  border-radius: 9px; color: var(--ink); text-decoration: none;
}
.metric strong { display: block; font-size: 27px; line-height: 1.3; }
.cols { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(210px, 1fr); gap: 18px; }
.panel { background: white; border: 1px solid var(--line); border-radius: 10px; padding: 20px; margin-bottom: 18px; min-width: 0; }
.history { align-self: start; }
.hero { background: var(--tone); color: white; padding: 24px; border-radius: 12px; margin-bottom: 18px; }
.hero h2, .hero .eyebrow + p { margin-top: 10px; }
.hero a { color: white; }
.row { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; overflow-wrap: anywhere; }
.row:last-child { border-bottom: 0; }
.trailing { margin-left: auto; }
.date { padding: 7px 12px; min-width: 52px; background: var(--wash); color: #006688; border-radius: 8px; text-align: center; font-weight: 700; }
.date strong { display: block; font-size: 19px; }
.actions, .heading, .filters { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.actions { margin-top: 15px; }
.heading { justify-content: space-between; margin-bottom: 12px; }
.heading h1 { margin-bottom: 5px; }
.filters { margin-bottom: 14px; align-items: flex-end; }
.row + .filters { margin-top: 14px; }
label { display: block; font-weight: 600; }
input:not([type="checkbox"]), select, textarea {
  display: block; margin-top: 4px; padding: 6px 8px; background: white; border: 1px solid #bfcddd;
  border-radius: 5px; max-width: 100%;
}
.fields input:not([type="checkbox"]), .fields select, .fields textarea { width: 100%; }
.fields > label { margin-bottom: 12px; }
.fields + p { margin-top: 12px; }
.form-panel { max-width: 680px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { background: var(--wash); font-size: 12px; }
th, td { padding: 9px 10px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
dl { display: grid; grid-template-columns: minmax(110px, 1fr) minmax(0, 1.5fr); gap: 7px 12px; margin: 0 0 16px; }
dt { color: var(--muted); }
dd { margin: 0; overflow-wrap: anywhere; }
.notice, .errorlist { background: var(--wash); border-left: 4px solid var(--tone); padding: 10px 14px; }
.errorlist { list-style-position: inside; color: #853918; }
.notes, code { overflow-wrap: anywhere; }
.preview img, .guest img { display: block; max-width: 100%; height: auto; }
.guest details { margin: 8px 0 12px; }
@media (max-width: 760px) {
  .layout, .cols { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .side { display: flex; flex-wrap: wrap; gap: 3px; padding: 7px 10px; }
  .side a { padding: 7px; margin: 0; }
  .side small { display: none; }
  .main, .top, .panel { padding: 14px; }
  .metricrow { gap: 6px; }
  .metric { padding: 9px; }
  .metric strong { font-size: 23px; }
  .account { margin-left: 0; }
}
