:root {
  --font-primary: "Manrope", "Segoe UI", sans-serif;
  --color-bg: #f5f7fb;
  --color-surface: #ffffff;
  --color-text: #1f2937;
  --color-muted: #667085;
  --color-line: #e3e8ef;
  --color-primary: #0f766e;
  --radius-md: 12px;
  --radius-lg: 18px;
  --shadow-soft: 0 12px 40px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  font-family: var(--font-primary);
  color: var(--color-text);
  background: var(--color-bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  width: 100%;
}

/* ── screen-reader only ── */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── skip link ── */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  padding: 0.75rem 1.25rem;
  background: var(--color-primary);
  color: #fff;
  font-weight: 700;
  border-radius: 0 0 var(--radius-md) 0;
  text-decoration: none;
}

.skip-link:focus {
  left: 0;
}

/* ── focus styles ── */

:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}

/* ── links ── */

a {
  color: var(--color-primary);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}

a:hover {
  text-decoration-thickness: 2px;
}

/* ── buttons ── */

button {
  font-family: inherit;
  cursor: pointer;
}

input,
button {
  font-size: 1rem;
}

/* ── shared layout ── */

.page-shell {
  max-width: 1040px;
  margin: 0 auto;
  padding: 1.2rem 1rem 2rem;
}

.page-shell--wide {
  max-width: 1320px;
}

/* ── shared surfaces ── */

.surface-card {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  padding: 1rem;
}

.text-muted {
  color: var(--color-muted);
}

.text-pre-line {
  white-space: pre-line;
}

/* ── shared buttons ── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  padding: 0.62rem 0.9rem;
  font-weight: 700;
  text-decoration: none;
  transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease;
}

.btn:hover {
  text-decoration: none;
}

.btn--primary {
  background: var(--color-primary);
  color: #fff;
}

.btn--primary:hover {
  background: #0d665f;
}

.btn--ghost {
  background: #fff;
  color: var(--color-text);
  border-color: var(--color-line);
}

.btn--ghost:hover {
  background: #f8fafc;
}

.btn--sm {
  padding: 0.45rem 0.68rem;
  font-size: 0.86rem;
}

.btn--danger {
  color: #9a3412;
  border-color: #fdba74;
  background: #fff7ed;
}

.btn--danger:hover {
  background: #ffedd5;
}

/* ── shared alerts ── */

.alert {
  margin: 0 0 0.8rem;
  padding: 0.65rem 0.8rem;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
}

.alert--error {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

.alert--success {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

/* ── shared status pill ── */

.status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.2;
  border: 1px solid transparent;
  white-space: nowrap;
}

.status-pill--draft {
  background: #fef3c7;
  color: #92400e;
  border-color: #fcd34d;
}

.status-pill--published {
  background: #d1fae5;
  color: #065f46;
  border-color: #86efac;
}

.status-pill--closed {
  background: #e5e7eb;
  color: #374151;
  border-color: #d1d5db;
}

.status-pill--pending {
  background: #ffedd5;
  color: #9a3412;
  border-color: #fdba74;
}

.status-pill--resolved {
  background: #dbeafe;
  color: #1e40af;
  border-color: #93c5fd;
}

.status-pill--neutral {
  background: #f8fafc;
  color: #475569;
  border-color: #cbd5e1;
}
