@font-face { font-family: "Montserrat"; src: url("/fonte/0.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
:root {
  --primary: #a86200;
  --primary-subtle: color-mix(in srgb, #a86200 10%, #ffffff);
  --accent: #ff8700;
  --header-background: #ffffff;
  --header-text: #2b2b2b;
  --radius: 8px;
  --text-font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --heading-font: "Montserrat", var(--text-font);
  --background: #ffffff;
  --foreground: #0e1014;
  --page: #f4f5f7;
  --muted: #f7f8fa;
  --muted-foreground: #5b6370;
  --border: #e1e4e9;
  --input: #b7bec8;
  --destructive: #b3372e;
  --destructive-subtle: #fdf0ef;
  --success: #257d4a;
  --success-subtle: #ecf8f1;
  --warning: #8a5a00;
  --warning-subtle: #fdf6e7;
  --shadow: 0 1px 2px rgb(16 24 40 / 0.06), 0 1px 3px rgb(16 24 40 / 0.08);
  color-scheme: light;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 96px; }
body { margin: 0; font: 15px/1.55 var(--text-font); color: var(--foreground); background: var(--page); -webkit-font-smoothing: antialiased; }
a { color: var(--primary); }
h1, h2, th, label, button, .button, summary { font-family: var(--heading-font); }
h1 { font-size: 1.6rem; line-height: 1.25; margin: 0; letter-spacing: -0.01em; }
h2 { font-size: 1.05rem; margin: 0 0 16px; }
p { margin: 0 0 12px; }
.muted, .hint, .sub, .sub-inline { color: var(--muted-foreground); }
.hint { font-size: 0.85rem; margin: 6px 0 0; }
.sub { display: block; font-size: 0.85rem; }
.sub-inline { font-size: 0.85rem; margin: 0 6px; }
.lead { font-size: 1.02rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Header: fixed at the top while the page scrolls. */
.site-header { position: sticky; top: 0; z-index: 20; background: var(--header-background); color: var(--header-text); border-top: 5px solid var(--accent); box-shadow: 0 1px 0 var(--border), 0 2px 8px rgb(16 24 40 / 0.04); }
.bar { max-width: 1120px; margin: 0 auto; padding: 10px 24px; display: flex; align-items: center; gap: 24px; }
.brand { display: flex; align-items: center; gap: 14px; color: var(--header-text); text-decoration: none; margin-right: auto; min-width: 0; }
.brand img { height: 56px; width: auto; display: block; }
.brand-title { font-family: var(--heading-font); font-weight: 700; font-size: 1.05rem; padding-left: 14px; border-left: 1px solid var(--border); white-space: nowrap; }
nav { display: flex; align-items: center; gap: 4px; }
nav a, nav button { color: var(--header-text); text-decoration: none; font-weight: 600; font-size: 0.95rem; padding: 8px 12px; border-radius: var(--radius); }
nav a:hover, nav button:hover { background: var(--muted); }
nav a.current { background: var(--primary-subtle); color: var(--primary); }
nav form { margin: 0 0 0 8px; padding-left: 12px; border-left: 1px solid var(--border); }

/* Layout. */
main { max-width: 1120px; margin: 28px auto 64px; padding: 0 24px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head .muted, .page-head .meta { margin: 6px 0 0; }
.meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 0.9rem; }
.back { display: inline-block; margin-bottom: 12px; font-size: 0.9rem; text-decoration: none; font-weight: 600; }
.back:hover { text-decoration: underline; }
.card { background: var(--background); border: 1px solid var(--border); border-radius: calc(var(--radius) * 1.5); padding: 24px; margin-bottom: 20px; box-shadow: var(--shadow); }
.card.flush { padding: 0; overflow: hidden; }
.card.flush .pad { padding: 20px 24px 0; }
.narrow { max-width: 440px; margin: 48px auto; }
.narrow h1 { margin-bottom: 12px; }
.narrow-form { max-width: 620px; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; }
.grid .card { margin-bottom: 0; }
.grid + .card { margin-top: 20px; }
.form-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 0 20px; }
.form-grid .field:last-child { grid-column: 1 / -1; }

/* Forms. */
.field { margin-bottom: 16px; }
label { display: block; font-weight: 600; font-size: 0.9rem; margin-bottom: 6px; }
input[type="email"], input[type="text"], input[type="search"], input[type="date"], input[type="file"] {
  width: 100%; height: 42px; padding: 0 12px; border: 1px solid var(--input); border-radius: var(--radius); font: inherit; color: inherit; background: var(--background);
}
input[type="file"] { padding: 6px; }
input::file-selector-button { font: inherit; font-weight: 600; margin-right: 12px; padding: 5px 12px; border: 1px solid var(--border); border-radius: calc(var(--radius) * 0.75); background: var(--muted); cursor: pointer; }
input:focus-visible, button:focus-visible, .button:focus-visible, summary:focus-visible, a:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
input[type="checkbox"] { width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--primary); flex: none; }
label.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-family: var(--text-font); font-size: 0.95rem; margin: 10px 0; cursor: pointer; }
.actions { display: flex; gap: 10px; align-items: center; margin-top: 20px; }
.confirm-box { background: var(--muted); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; }
.confirm-box p { margin-bottom: 4px; font-size: 0.9rem; }
.add-row { display: flex; gap: 8px; margin-top: 16px; }
.add-row input { flex: 1; min-width: 0; }
.toolbar { display: flex; gap: 8px; padding: 16px 20px; border-bottom: 1px solid var(--border); background: var(--muted); }
.toolbar input { flex: 1; min-width: 0; }

/* Buttons. */
button, .button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 42px; padding: 0 18px; border: 1px solid transparent; border-radius: var(--radius); background: var(--primary); color: #ffffff; font-size: 0.95rem; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; }
button:hover, .button:hover { filter: brightness(0.93); }
.secondary { background: var(--background); color: var(--foreground); border-color: var(--input); }
.secondary:hover { background: var(--muted); filter: none; }
.ghost { background: transparent; color: inherit; border-color: transparent; height: auto; }
.ghost:hover { background: var(--muted); filter: none; }
button:disabled { opacity: 0.45; cursor: not-allowed; filter: none; }
.danger { background: var(--destructive); color: #ffffff; }
.danger-text { color: var(--destructive); }
.small { height: 34px; padding: 0 12px; font-size: 0.875rem; }
.block { width: 100%; }

/* Alerts and tags. */
.alert { padding: 12px 16px; border-radius: var(--radius); margin-bottom: 20px; border: 1px solid transparent; }
.alert ul { margin: 8px 0 0; padding-left: 20px; }
.alert li { margin: 4px 0; }
.alert.success { background: var(--success-subtle); color: var(--success); border-color: color-mix(in srgb, var(--success) 25%, #ffffff); }
.alert.error { background: var(--destructive-subtle); color: var(--destructive); border-color: color-mix(in srgb, var(--destructive) 25%, #ffffff); }
.alert.warning { background: var(--warning-subtle); color: var(--warning); border-color: color-mix(in srgb, var(--warning) 25%, #ffffff); }
.alert p { margin: 0; }
.alert.banner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.alert.banner a { color: inherit; font-weight: 600; }
.tag { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 0.8rem; font-weight: 600; line-height: 1.6; white-space: nowrap; }
.tag.ok { background: var(--success-subtle); color: var(--success); }
.tag.bad { background: var(--destructive-subtle); color: var(--destructive); }
.tag.off { background: var(--muted); color: var(--muted-foreground); border: 1px solid var(--border); }

/* Tables and lists. */
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 14px 20px; border-bottom: 1px solid var(--border); vertical-align: middle; }
th { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted-foreground); font-weight: 600; background: var(--background); }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: var(--muted); }
.right { text-align: right; }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.strong { font-weight: 600; }
.nowrap { white-space: nowrap; }
.row-link { font-weight: 600; text-decoration: none; color: var(--foreground); }
.row-link:hover { color: var(--primary); text-decoration: underline; }
.empty { padding: 32px 24px; margin: 0; text-align: center; color: var(--muted-foreground); }
.list { list-style: none; padding: 0; margin: 0; border: 1px solid var(--border); border-radius: var(--radius); }
.list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 8px 8px 8px 14px; border-bottom: 1px solid var(--border); }
.list li:last-child { border-bottom: 0; }
.list form { margin: 0; }
.choices { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.choices a { display: block; padding: 12px 16px; border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; font-weight: 600; color: var(--foreground); }
.choices a:hover { border-color: var(--primary); color: var(--primary); }
.pager { display: flex; justify-content: space-between; align-items: center; padding: 12px 20px; border-top: 1px solid var(--border); }

/* Row actions: the less common ones folded in a menu. */
.row-actions { display: inline-flex; gap: 8px; align-items: center; justify-content: flex-end; }
.menu { position: relative; }
.menu summary { list-style: none; }
.menu summary::-webkit-details-marker { display: none; }
.menu-body { position: absolute; right: 0; top: calc(100% + 6px); z-index: 10; width: 280px; text-align: left; background: var(--background); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 8px 24px rgb(16 24 40 / 0.14); padding: 16px; }
.menu-body form { margin: 0; }
.menu-body hr { border: 0; border-top: 1px solid var(--border); margin: 14px 0; }
.danger-zone { border-color: color-mix(in srgb, var(--destructive) 30%, #ffffff); box-shadow: none; }
.danger-zone summary { cursor: pointer; font-weight: 600; color: var(--destructive); }
.danger-zone[open] summary { margin-bottom: 12px; }

@media (max-width: 860px) {
  .grid, .form-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .bar { padding: 8px 16px; gap: 12px; flex-wrap: wrap; }
  .brand img { height: 44px; }
  .brand-title { display: none; }
  nav { width: 100%; justify-content: space-between; }
  main { padding: 0 16px; margin-top: 20px; }
  .card { padding: 18px; }
  table, thead, tbody, tr, td { display: block; }
  thead { display: none; }
  tr { padding: 12px 16px; border-bottom: 1px solid var(--border); }
  td { border: 0; padding: 3px 0; text-align: left; }
  td[data-label]::before { content: attr(data-label) ": "; color: var(--muted-foreground); font-size: 0.85rem; }
  .right, .num { text-align: left; }
  .row-actions { justify-content: flex-start; margin-top: 8px; }
  .menu-body { right: auto; left: 0; }
}
