/* Trilemma Grappling - shared styles
   Brand colours: green #2DB553 (~70%), orange #E8792B (~20%), purple #8B5CF6 (~10%)
   Deliberately minimal — replace with brand-skinned styles before launch. */

:root {
  --green: #2DB553;
  --orange: #E8792B;
  --purple: #8B5CF6;
  --ink: #111;
  --muted: #666;
  --bg: #fff;
  --line: #e5e5e5;
  --soft: #fafafa;
  --danger: #c93838;
  --radius: 4px;
  --space: 16px;
  --max-width: 960px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.5;
}

a { color: var(--green); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { line-height: 1.2; margin: 0 0 12px 0; }
h1 { font-size: 2rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.1rem; }

p { margin: 0 0 12px 0; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

header.site {
  border-bottom: 1px solid var(--line);
  padding: 16px 0;
  position: sticky;
  top: 0;
  background: var(--bg);
  z-index: 10;
}

header.site .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--ink);
  font-size: 1.05rem;
}

.brand .stripe { display: inline-block; width: 8px; height: 16px; vertical-align: -2px; margin-right: 2px; }
.brand .stripe.green { background: var(--green); }
.brand .stripe.orange { background: var(--orange); }
.brand .stripe.purple { background: var(--purple); }

nav.site a {
  color: var(--ink);
  margin-left: 20px;
  font-size: 0.95rem;
}
nav.site a:hover { color: var(--green); text-decoration: none; }

main {
  padding: 48px 0;
}

.hero {
  padding: 64px 0 48px 0;
}

.hero h1 {
  font-size: 2.6rem;
  margin-bottom: 8px;
}

.hero .lede {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 580px;
}

button, .btn {
  display: inline-block;
  background: var(--green);
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  font-family: inherit;
}
button:hover, .btn:hover { filter: brightness(0.95); text-decoration: none; }
button:disabled { background: #bbb; cursor: not-allowed; }

.btn.secondary { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.btn.secondary:hover { border-color: var(--ink); }

.btn.danger { background: var(--danger); }

label { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 4px; }

input, select, textarea {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-family: inherit;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--green); outline-offset: -1px; }

.field { margin-bottom: 14px; }

.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  background: #fff;
}

.grid {
  display: grid;
  gap: 16px;
}
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 700px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

.plan {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  flex-direction: column;
}
.plan h3 { margin-bottom: 4px; }
.plan .price { font-size: 1.5rem; font-weight: 700; margin: 6px 0; }
.plan .price small { font-size: 0.85rem; font-weight: 400; color: var(--muted); }
.plan .desc { color: var(--muted); font-size: 0.9rem; min-height: 36px; }
.plan button { margin-top: auto; }

table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); }
th { background: var(--soft); font-weight: 600; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.04em; }

.belt-pill {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
  background: #f0f0f0;
  border: 1px solid var(--line);
}
.belt-pill.white { background: #fff; }
.belt-pill.blue { background: #1e63d6; color: #fff; }
.belt-pill.purple { background: #8B5CF6; color: #fff; }
.belt-pill.brown { background: #6b3510; color: #fff; }
.belt-pill.black { background: #111; color: #fff; }
.belt-pill.green { background: var(--green); color: #fff; }
.belt-pill.grey, .belt-pill.grey_white, .belt-pill.grey_black { background: #888; color: #fff; }
.belt-pill.yellow, .belt-pill.yellow_white, .belt-pill.yellow_black { background: #f5c518; }
.belt-pill.orange, .belt-pill.orange_white, .belt-pill.orange_black { background: var(--orange); color: #fff; }

.muted { color: var(--muted); font-size: 0.9rem; }
.error { color: var(--danger); font-size: 0.9rem; margin-top: 8px; }
.success { color: var(--green); font-size: 0.9rem; margin-top: 8px; }

.empty {
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  color: var(--muted);
}

footer.site {
  border-top: 1px solid var(--line);
  padding: 24px 0;
  margin-top: 64px;
  font-size: 0.85rem;
  color: var(--muted);
}

.row-flex {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.athlete-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}

.athlete-card .header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  background: var(--soft);
  border: 1px solid var(--line);
  margin-right: 4px;
}

.hidden { display: none !important; }
