/* IN or OUT — shared tokens and components used by the site, admin and app */
:root {
  --ink: #0f1d17;
  --ink-2: #24342c;
  --paper: #f5f6f1;
  --card: #ffffff;
  --line: #dde3dd;
  --muted: #5d6c64;
  --pitch: #0b6e4f;
  --pitch-dark: #08553d;
  --in: #1c9a55;
  --in-soft: #e3f5ea;
  --out: #d9443a;
  --out-soft: #fbe7e5;
  --maybe: #c98a0b;
  --maybe-soft: #fbf0d6;
  --none: #8a978f;
  --none-soft: #eef1ee;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(15, 29, 23, .06), 0 4px 16px rgba(15, 29, 23, .05);
  --font: "Barlow", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: "Barlow Condensed", "Barlow", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.5; color: var(--ink); background: var(--paper); }
img { max-width: 100%; display: block; }
a { color: var(--pitch); }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.1; margin: 0 0 .5em; letter-spacing: .01em; }
h1 { font-size: 2rem; font-weight: 700; }
h2 { font-size: 1.5rem; font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 600; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.hidden, [hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Wordmark */
.wordmark { font-family: var(--font-display); font-weight: 800; font-size: 1.5rem; letter-spacing: .02em; text-decoration: none; color: inherit; display: inline-flex; align-items: center; gap: .3em; white-space: nowrap; }
.wordmark .w-in { background: var(--in); color: #fff; padding: 0 .3em; border-radius: 6px; }
.wordmark .w-or { font-weight: 500; font-size: .75em; opacity: .75; }
.wordmark .w-out { background: var(--out); color: #fff; padding: 0 .3em; border-radius: 6px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4em; padding: .65em 1.15em; border-radius: 10px; border: 1px solid transparent;
  font: 600 1rem/1.2 var(--font); text-decoration: none; cursor: pointer; background: var(--pitch); color: #fff; transition: background .15s, transform .05s; }
.btn:hover { background: var(--pitch-dark); }
.btn:active { transform: translateY(1px); }
.btn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 3px solid #9ad7b5; outline-offset: 2px; }
.btn-secondary { background: var(--card); color: var(--ink); border-color: var(--line); }
.btn-secondary:hover { background: #eef1ec; }
.btn-danger { background: var(--out); }
.btn-danger:hover { background: #b9352c; }
.btn-ghost { background: transparent; color: var(--pitch); padding-left: .5em; padding-right: .5em; }
.btn-ghost:hover { background: rgba(11, 110, 79, .08); }
.btn-sm { padding: .4em .8em; font-size: .875rem; border-radius: 8px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* Forms */
.field { margin-bottom: 1rem; }
.field label, .label { display: block; font-weight: 600; margin-bottom: .3rem; font-size: .95rem; }
.field .hint { font-size: .85rem; color: var(--muted); margin-top: .25rem; }
input[type=text], input[type=email], input[type=password], input[type=tel], input[type=date], input[type=time], input[type=url], input[type=number], input[type=search], select, textarea {
  width: 100%; padding: .65em .75em; border: 1px solid #c9d1ca; border-radius: 10px; font: inherit; background: #fff; color: var(--ink); }
textarea { min-height: 6rem; resize: vertical; }
.row { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.check { display: flex; align-items: center; gap: .5rem; font-weight: 500; }
.check input { width: 1.1rem; height: 1.1rem; accent-color: var(--pitch); }

/* Cards */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.25rem; }
.card + .card { margin-top: 1rem; }

/* Flash */
.flash { padding: .8rem 1rem; border-radius: 10px; margin-bottom: 1rem; font-weight: 500; border: 1px solid; }
.flash-success { background: var(--in-soft); border-color: #b4e2c5; color: #11502e; }
.flash-error { background: var(--out-soft); border-color: #f1c0bb; color: #8a241c; }
.flash-info { background: #e8f1fb; border-color: #c3d8f0; color: #1f4570; }

/* Status pills */
.pill { display: inline-flex; align-items: center; gap: .3em; padding: .15em .6em; border-radius: 999px; font-size: .8rem; font-weight: 700; letter-spacing: .02em; white-space: nowrap; }
.pill-available { background: var(--in-soft); color: #11663a; }
.pill-unavailable { background: var(--out-soft); color: #9d2b22; }
.pill-maybe { background: var(--maybe-soft); color: #7d5604; }
.pill-none { background: var(--none-soft); color: #4f5c55; }
.pill-home { background: #e6eefb; color: #1f4570; }
.pill-away { background: #f3e8fb; color: #5b2a7c; }
.pill-neutral, .pill-training, .pill-social { background: #eef1ee; color: #4f5c55; }
.pill-cancelled { background: var(--out); color: #fff; }

.avatar { width: 2.25rem; height: 2.25rem; border-radius: 50%; background: var(--pitch); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: .85rem; flex: none; }

/* Tables */
.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; }
.table th, .table td { text-align: left; padding: .7rem .75rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 600; }
.table tr:last-child td { border-bottom: 0; }

.empty { text-align: center; padding: 2rem 1rem; color: var(--muted); }
.empty h3 { color: var(--ink); }
