/* OficinaFlow Design System — Base */
*, *::before, *::after { box-sizing: border-box; }

html {
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: var(--font-size-body);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: var(--font-size-body);
  font-weight: var(--font-weight-regular);
  line-height: var(--line-height-normal);
}

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, [role="button"], a { -webkit-tap-highlight-color: transparent; }
img, svg { display: block; max-width: 100%; }

h1, h2, h3, h4, p { margin-top: 0; }
h1, h2, h3, h4 { color: var(--text); font-weight: var(--font-weight-semibold); }
h1 { font-size: var(--font-size-page-title); line-height: var(--line-height-tight); }
h2 { font-size: var(--font-size-emphasis); line-height: var(--line-height-tight); }
h3 { font-size: var(--font-size-body); line-height: var(--line-height-tight); }

::selection { background: var(--amber-bg); color: var(--text); }
:focus-visible { outline: none; box-shadow: var(--focus-ring); }

.of-icon {
  width: 1em;
  height: 1em;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.of-page {
  width: min(100%, var(--content-max-width));
  margin-inline: auto;
}

.of-page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-5);
}

.of-page-header__eyebrow {
  display: block;
  margin-bottom: var(--space-1);
  color: var(--text-muted);
  font-size: var(--font-size-caption);
  font-weight: var(--font-weight-semibold);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.of-page-header__title {
  margin: 0;
  font-size: var(--font-size-page-title);
  font-weight: var(--font-weight-semibold);
}

.of-page-header__description {
  max-width: 760px;
  margin: var(--space-1) 0 0;
  color: var(--text-secondary);
  font-size: var(--font-size-secondary);
}

.of-page-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-2);
  flex-wrap: wrap;
}

.of-divider { width: 100%; height: 1px; border: 0; background: var(--border); }

.of-empty-state {
  display: grid;
  place-items: center;
  min-height: 160px;
  padding: var(--space-6);
  border: 1px dashed var(--border);
  border-radius: var(--radius-card);
  color: var(--text-muted);
  text-align: center;
}

@media (max-width: 900px) {
  .of-page-header { flex-direction: column; }
  .of-page-actions { width: 100%; justify-content: flex-start; }
}
