/* Open Free Agency — human-light theme (v6)
   Warm paper, soft ink, generous space. Same class contract as v1–v5. */
:root {
  --bg: #fcfcfa;
  --bg2: #f3f5f1;
  --ink: #1a1d1a;
  --muted: #5f665f;
  --line: #e6e9e2;
  --acc: #14532d;          /* deep green — brand */
  --acc2: #166534;         /* readable link green */
  --warn: #b45309;
  --good: #15803d;
  --bad: #b91c1c;
  --card: #ffffff;
  --radius: 12px;
  --font: "Segoe UI", system-ui, -apple-system, sans-serif;
  --shadow: 0 1px 2px rgba(26,29,26,.04), 0 4px 14px rgba(26,29,26,.045);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
}
a { color: var(--acc2); }
a:hover { color: var(--acc); }
.wrap { max-width: 960px; margin: 0 auto; padding: 24px 18px 64px; }
.nav {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
  justify-content: space-between; margin-bottom: 28px;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 800; letter-spacing: -0.03em; font-size: 1.05rem;
  text-decoration: none; color: var(--ink);
}
.brand-mark {
  width: 36px; height: 36px; object-fit: contain; display: block;
}
.brand-text span { color: var(--acc); font-weight: 600; margin-left: 6px; font-size: .78rem; }
.brand span { color: var(--acc); font-weight: 600; margin-left: 6px; font-size: .78rem; }
.nav-links { display: flex; flex-wrap: wrap; gap: 8px; }
.btn, button.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--card); color: var(--ink); padding: 11px 16px;
  font-weight: 650; text-decoration: none; cursor: pointer; font: inherit;
  box-shadow: 0 1px 2px rgba(38,34,28,.04);
}
.btn:hover { border-color: #cfc4ac; }
.btn.primary { background: var(--acc); color: #fff8f2; border-color: transparent; }
.btn.primary:hover { background: #a83708; }
.btn.ghost { background: transparent; box-shadow: none; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.hero {
  position: relative;
  border: 1px solid var(--line); border-radius: 18px; padding: 30px 26px;
  background: var(--card);
  margin-bottom: 22px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.hero-with-img { min-height: 280px; padding: 0; }
.hero-bg {
  position: absolute; inset: 0;
  background: #2a241c center/cover no-repeat;
  filter: brightness(0.5) saturate(0.95);
}
.hero-bg::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(100deg, rgba(30,24,16,.88) 28%, rgba(30,24,16,.45) 100%);
}
.hero-copy { position: relative; z-index: 1; padding: 30px 26px; color: #f4f7f2; }
.hero-copy .lead { color: #dde6dc; }
.hero-with-img h1, .hero-with-img .pill { color: #f4f7f2; }
.hero-with-img .pill { border-color: #ffffff44; color: #bfe3c8; }
.hero h1 {
  margin: 0 0 12px; font-size: clamp(1.7rem, 4vw, 2.35rem);
  letter-spacing: -0.04em; line-height: 1.15;
}
.hero h1 .acc { color: var(--acc); }
.hero-with-img h1 .acc { color: #a7d7b5; }
.hero .lead { color: var(--muted); font-size: 1.05rem; max-width: 42rem; }
.pill {
  display: inline-block; font-size: .72rem; letter-spacing: .08em;
  text-transform: uppercase; border: 1px solid #cfe0d3; color: var(--acc);
  background: #eef5ef; padding: 4px 10px; border-radius: 999px; margin-bottom: 12px;
  font-weight: 700;
}
.grid { display: grid; gap: 14px; }
@media (min-width: 760px) {
  .grid.two { grid-template-columns: 1fr 1fr; }
  .grid.three { grid-template-columns: 1fr 1fr 1fr; }
}
.card {
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--card); padding: 18px; box-shadow: var(--shadow);
}
.card h2, .card h3 { margin: 0 0 8px; letter-spacing: -0.02em; }
.card p { margin: 0; color: var(--muted); }
.card ol, .card ul { margin: 8px 0 0; color: var(--muted); padding-left: 1.2rem; }
.muted { color: var(--muted); }
.small { font-size: .88rem; }
.hr { height: 1px; background: var(--line); margin: 18px 0; border: 0; }
label { display: block; font-size: .85rem; color: var(--muted); margin: 10px 0 4px; font-weight: 600; }
input, textarea, select {
  width: 100%; border-radius: 12px; border: 1px solid var(--line);
  background: #fff; color: var(--ink); padding: 12px 13px; font: inherit;
}
input:focus, textarea:focus, select:focus {
  outline: 2px solid #14532d33; border-color: var(--acc);
}
textarea { min-height: 120px; resize: vertical; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 12px; }
.tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.tab {
  border: 1px solid var(--line); background: var(--card); color: var(--muted);
  border-radius: 999px; padding: 8px 14px; cursor: pointer; font: inherit; font-weight: 600;
}
.tab:hover { border-color: #cfc4ac; color: var(--ink); }
.tab.on { background: var(--acc); color: #fff8f2; border-color: transparent; }
.list { display: grid; gap: 10px; }
.item {
  border: 1px solid var(--line); border-radius: 14px; padding: 14px;
  background: #fff; cursor: pointer;
}
.item:hover { border-color: var(--acc); }
.item h4 { margin: 0 0 4px; }
.badge {
  display: inline-block; font-size: .72rem; padding: 2px 8px; border-radius: 999px;
  border: 1px solid var(--line); color: var(--muted); margin-right: 6px; font-weight: 600;
}
.badge.signed { color: var(--good); border-color: #b7dcc4; background: #eef7f0; }
.badge.public { color: var(--acc2); border-color: #bcd7ea; background: #eef5fa; }
.badge.draft { color: var(--warn); border-color: #ead3ae; background: #fdf6ea; }
#msg {
  position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%);
  background: #2b2620; border: 1px solid #4a4238; color: #f7f2e8;
  padding: 11px 16px; border-radius: 12px; display: none; z-index: 50;
  max-width: min(92vw, 420px); text-align: center; box-shadow: 0 8px 24px rgba(0,0,0,.2);
}
#msg.show { display: block; }
#msg.err { border-color: #8a3a3a; color: #ffd7d0; }
.sig-wrap {
  border: 1px dashed #cfc4ac; border-radius: 12px; background: #fff;
  touch-action: none;
}
.sig-wrap canvas { width: 100%; height: 160px; display: block; cursor: crosshair; }
.hash {
  font-family: ui-monospace, Consolas, monospace; font-size: .75rem;
  word-break: break-all; color: var(--acc);
}
.hash-copy { cursor: pointer; }
.hash-copy:hover { text-decoration: underline dotted; }
.footer {
  margin-top: 36px; color: var(--muted); font-size: .85rem; text-align: center;
}
.not-for {
  border-color: var(--line); opacity: .92; background: #faf6ee;
}
.not-for h3 { color: var(--muted); font-weight: 600; font-size: .95rem; }
.hidden { display: none !important; }
.stack > * + * { margin-top: 12px; }
pre.package {
  white-space: pre-wrap; word-break: break-word; font-size: .75rem;
  background: #faf6ee; border: 1px solid var(--line); border-radius: 12px;
  padding: 12px; max-height: 240px; overflow: auto; color: var(--muted);
}

/* ---- v2 public surfaces (seals, revocation, pages, shop, connect) ---- */
.badge.revoked { color: var(--bad); border-color: #eec5c0; background: #fdeeee; }
.badge.contested { color: var(--warn); border-color: #ead3ae; background: #fdf6ea; }
.notice {
  border: 1px solid #ead3ae; background: #fdf6ea; color: var(--warn);
  border-radius: 12px; padding: 12px 14px; font-size: .9rem;
}
.notice.bad { border-color: #eec5c0; background: #fdeeee; color: var(--bad); }
.notice.good { border-color: #b7dcc4; background: #eef7f0; color: var(--good); }
.notice a { color: var(--acc2); }
.shop-grid { display: grid; gap: 14px; }
@media (min-width: 760px) {
  .shop-grid { grid-template-columns: 1fr 1fr; }
}
.product-img {
  width: 100%; height: 160px; object-fit: cover; display: block;
  border-radius: 10px; border: 1px solid var(--line); background: var(--bg2);
}
.price { color: var(--good); font-weight: 700; }
.page-link {
  display: flex; justify-content: space-between; align-items: center;
  gap: 10px; text-decoration: none; color: var(--ink);
}
.page-link:hover { border-color: var(--acc); }
.order-out { margin-top: 10px; font-size: .9rem; color: var(--muted); }
.order-out p { margin: 6px 0 0; }
