/* Soudés — shared stylesheet. Tokens taken from the Claude Design mockups. */
@font-face { font-family: "DM Sans"; src: url("fonts/dm-sans.woff2") format("woff2"); font-weight: 100 1000; font-display: swap; }
@font-face { font-family: "DM Mono"; src: url("fonts/dm-mono.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --green: #2D5A3D;
  --green-dark: #1F4030;
  --green-mid: #3D7251;
  --green-light: #5EA366;
  --green-tint: #E2EBD5;
  --orange: #E8833A;
  --orange-dark: #B8541A;
  --orange-tint: #FDF4EC;
  --cream: #F5EFE6;
  --paper: #FDFBF7;
  --sand: #F0ECE2;
  --line: #E6DFD1;
  --ink: #2C2C2C;
  --muted: #5B5B5B;
  --faint: #9A968E;
  --red: #CF4E3C;
  --red-dark: #9F2A23;
  --yellow: #E9C04A;
  --yellow-tint: #FFF8E8;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(31, 64, 48, .06), 0 4px 16px rgba(31, 64, 48, .06);
  --sans: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "DM Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.55 var(--sans); color: var(--ink); background: var(--cream); }
a { color: var(--green); }
a:hover { color: var(--green-dark); }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 700; }
h2 { font-size: 1.45rem; font-weight: 700; }
h3 { font-size: 1.1rem; font-weight: 650; }
p { margin: 0 0 1em; }
img { max-width: 100%; }
.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: .88rem; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.stack > * + * { margin-top: 1rem; }
.row { display: flex; gap: .75rem; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }
.grow { flex: 1; }
.hidden-field { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 640px; margin: 0 auto; padding: 0 20px; }

/* Top bars */
.topbar { background: var(--paper); border-bottom: 1px solid var(--line); }
.topbar .wrap { display: flex; align-items: center; gap: 1rem; min-height: 64px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: .6rem; font-weight: 700; color: var(--green-dark); text-decoration: none; }
.brand-mark { width: 34px; height: 34px; border-radius: 10px; background: var(--green); color: var(--cream); display: grid; place-items: center; font-weight: 800; font-size: .95rem; }
.brand small { display: block; font-weight: 500; color: var(--muted); font-size: .78rem; }
.topnav { display: flex; gap: .3rem; flex-wrap: wrap; margin-left: auto; align-items: center; }
.topnav a { padding: .45rem .8rem; border-radius: 999px; text-decoration: none; color: var(--muted); font-weight: 550; font-size: .95rem; }
.topnav a:hover { background: var(--sand); color: var(--ink); }
.topnav a.active { background: var(--green-tint); color: var(--green-dark); }
.topnav form { margin: 0; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; padding: .7rem 1.2rem; border-radius: 999px;
  border: 1px solid transparent; font: inherit; font-weight: 650; text-decoration: none; cursor: pointer; line-height: 1.2; }
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-dark); color: #fff; }
.btn-accent { background: var(--orange); color: #fff; }
.btn-accent:hover { background: var(--orange-dark); color: #fff; }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { background: var(--sand); color: var(--ink); }
.btn-danger { background: transparent; border-color: #f0c9c3; color: var(--red-dark); }
.btn-danger:hover { background: #fbeceA; }
.btn-sm { padding: .4rem .8rem; font-size: .88rem; }
.btn-lg { padding: .95rem 1.6rem; font-size: 1.08rem; }
.btn-block { width: 100%; }
.btn-link { background: none; border: 0; padding: 0; color: var(--green); font: inherit; cursor: pointer; text-decoration: underline; }

/* Cards, badges */
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.4rem; box-shadow: var(--shadow); }
.card-flat { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.2rem; }
.card h2:first-child, .card h3:first-child { margin-top: 0; }
.grid { display: grid; gap: 1rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.badge { display: inline-flex; align-items: center; gap: .35rem; padding: .2rem .65rem; border-radius: 999px; font-size: .8rem; font-weight: 650; background: var(--sand); color: var(--muted); white-space: nowrap; }
.badge-green { background: var(--green-tint); color: var(--green-dark); }
.badge-orange { background: var(--orange-tint); color: var(--orange-dark); }
.badge-yellow { background: var(--yellow-tint); color: #8a6a10; }
.badge-red { background: #fbe9e6; color: var(--red-dark); }
.dot { width: .55rem; height: .55rem; border-radius: 50%; background: currentColor; display: inline-block; }

.stat { display: flex; flex-direction: column; gap: .15rem; }
.stat .value { font-size: 2rem; font-weight: 750; color: var(--green-dark); line-height: 1.1; }
.stat .label { color: var(--muted); font-size: .9rem; }
.bar { height: 8px; border-radius: 999px; background: var(--sand); overflow: hidden; }
.bar > span { display: block; height: 100%; background: var(--green-light); border-radius: 999px; }

.flash { padding: .85rem 1.1rem; border-radius: var(--radius-sm); margin: 1rem 0; font-weight: 550; }
.flash-ok { background: var(--green-tint); color: var(--green-dark); }
.flash-error { background: #fbe9e6; color: var(--red-dark); }
.notice { background: var(--yellow-tint); border: 1px solid #f0e3b8; border-radius: var(--radius-sm); padding: .9rem 1.1rem; }

/* Forms */
form.stack > * + * { margin-top: 1rem; }
label { display: block; font-weight: 600; font-size: .95rem; margin-bottom: .3rem; }
.hint { font-weight: 400; color: var(--muted); font-size: .85rem; }
input[type=text], input[type=email], input[type=tel], input[type=date], input[type=number], input[type=search], input[type=time], select, textarea {
  width: 100%; padding: .7rem .85rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; font: inherit; color: var(--ink); }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--green-light); outline-offset: 1px; border-color: var(--green-light); }
textarea { min-height: 6rem; resize: vertical; }
.field-row { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.check { display: flex; gap: .6rem; align-items: flex-start; font-weight: 450; }
.check input { margin-top: .3rem; width: 1.1rem; height: 1.1rem; accent-color: var(--green); }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.2rem 1.2rem; margin: 0; }
legend { font-weight: 700; padding: 0 .4rem; }

.choice { display: block; position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; }
.choice .choice-body { display: block; border: 2px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; background: #fff; }
.choice input:checked + .choice-body { border-color: var(--green); background: var(--green-tint); }
.choice input:focus-visible + .choice-body { outline: 2px solid var(--orange); outline-offset: 2px; }

/* Tables */
.table-wrap { overflow-x: auto; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: .94rem; }
th, td { text-align: left; padding: .7rem .9rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 650; background: var(--sand); }
tr:last-child td { border-bottom: 0; }
td form { margin: 0; display: inline; }
tr.cancelled td { color: var(--faint); text-decoration: line-through; }
.filters { display: flex; gap: .6rem; flex-wrap: wrap; align-items: end; margin: 1rem 0; }
.filters > * { flex: 1 1 160px; }
.filters .btn { flex: 0 0 auto; }

/* Page sections */
main { padding: 2rem 0 4rem; }
.page-head { display: flex; gap: 1rem; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; margin-bottom: 1.5rem; }
.page-head h1 { margin: 0; font-size: 1.9rem; }
.page-head p { margin: .3rem 0 0; color: var(--muted); }
.breadcrumb { font-size: .9rem; color: var(--muted); margin-bottom: .4rem; }
.breadcrumb a { color: var(--muted); }
.section { margin-top: 2.2rem; }
.empty { text-align: center; padding: 2.5rem 1rem; color: var(--muted); }

/* Public event site */
.hero { background: var(--green-dark); color: var(--cream); padding: 3.5rem 0 3rem; position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; right: -120px; top: -120px; width: 380px; height: 380px; border-radius: 50%; background: radial-gradient(circle, rgba(94,163,102,.35), transparent 70%); }
.hero h1 { color: #fff; max-width: 18ch; }
.hero .lead { font-size: 1.15rem; max-width: 60ch; color: #e7e2d6; }
.hero .facts { display: flex; gap: .6rem; flex-wrap: wrap; margin: 1.3rem 0 1.6rem; }
.hero .fact { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); color: #fff; border-radius: 999px; padding: .4rem .9rem; font-weight: 550; font-size: .95rem; }
.hero .eyebrow { display: inline-block; background: var(--orange); color: #fff; padding: .25rem .75rem; border-radius: 999px; font-weight: 700; font-size: .85rem; margin-bottom: 1rem; }
.public-nav { background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.public-nav .wrap { display: flex; align-items: center; gap: 1rem; min-height: 60px; }
.course { display: flex; flex-direction: column; gap: .6rem; }
.course .course-top { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem; }
.course .distance { font-size: 2.1rem; font-weight: 800; color: var(--green-dark); line-height: 1; }
.course .distance small { font-size: 1rem; font-weight: 600; color: var(--muted); }
.course .price { font-size: 1.3rem; font-weight: 750; color: var(--orange-dark); }
.course .meta { display: flex; gap: .4rem; flex-wrap: wrap; }
.course .meta span { background: var(--sand); border-radius: 999px; padding: .15rem .6rem; font-size: .85rem; color: var(--muted); }
.course .btn { margin-top: auto; }
.footer { border-top: 1px solid var(--line); padding: 2rem 0; color: var(--muted); font-size: .9rem; background: var(--paper); }
.footer .wrap { display: flex; gap: 1rem; justify-content: space-between; flex-wrap: wrap; }

/* Confirmation ticket */
.ticket { background: var(--paper); border: 2px dashed var(--green-mid); border-radius: 20px; padding: 1.6rem; text-align: center; }
.ticket .bib { font-family: var(--mono); font-size: 4rem; font-weight: 500; color: var(--green-dark); line-height: 1; margin: .4rem 0; }
.ticket .ref { font-family: var(--mono); letter-spacing: .08em; color: var(--muted); }

@media (max-width: 640px) {
  main { padding-top: 1.2rem; }
  .card { padding: 1.1rem; }
  .hide-sm { display: none; }
  .hero { padding: 2.4rem 0 2.2rem; }
}
@media print {
  .topbar, .public-nav, .footer, .btn, form { display: none !important; }
  body { background: #fff; }
}

/* Spacing utilities (no inline styles: the CSP forbids them) */
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 1rem; } .mt-2 { margin-top: 2rem; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: 1rem; }

/* Bar widths, by steps of 5 % */
.w-0 { width: 0%; }
.w-5 { width: 5%; }
.w-10 { width: 10%; }
.w-15 { width: 15%; }
.w-20 { width: 20%; }
.w-25 { width: 25%; }
.w-30 { width: 30%; }
.w-35 { width: 35%; }
.w-40 { width: 40%; }
.w-45 { width: 45%; }
.w-50 { width: 50%; }
.w-55 { width: 55%; }
.w-60 { width: 60%; }
.w-65 { width: 65%; }
.w-70 { width: 70%; }
.w-75 { width: 75%; }
.w-80 { width: 80%; }
.w-85 { width: 85%; }
.w-90 { width: 90%; }
.w-95 { width: 95%; }
.w-100 { width: 100%; }
.break { overflow-wrap: anywhere; }

/* One walker of a group registration */
.walker { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 1rem; background: #fff; }
.walker > * + * { margin-top: .8rem; }
.walker h3 { font-size: 1rem; }
.tickets { display: grid; gap: .8rem; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.ticket-sm { padding: 1rem; }
.ticket-sm .bib { font-size: 2.6rem; }

/* Plain lists of rows (members, requests) */
ul.list { list-style: none; padding: 0; margin: 0 0 1rem; }
ul.list > li { padding: .6rem 0; border-bottom: 1px solid var(--line); }
ul.list > li:last-child { border-bottom: 0; }
ul.list form { margin: 0; }
.console-bar { background: var(--green-dark); color: var(--cream); }
.console-bar .brand, .console-bar .brand small { color: var(--cream); }
.console-bar .brand-mark { background: var(--orange); }
.console-bar .topnav a { color: #dfe7dc; }
.console-bar .topnav a:hover, .console-bar .topnav a.active { background: rgba(255,255,255,.12); color: #fff; }
.console-bar .btn-ghost { color: #fff; border-color: rgba(255,255,255,.3); }
.console-bar .btn-ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.count { display: inline-grid; place-items: center; min-width: 1.4rem; height: 1.4rem; padding: 0 .35rem; border-radius: 999px; background: var(--orange); color: #fff; font-size: .78rem; font-weight: 700; }
