/* Huisstijl van gentfestival.be */
:root {
  --color-primary: #a72a18;
  --color-secondary: #ffe6e2;
  --color-tertiary: #e94d43;
  --color-white: #eaf6fe;
  --color-gray: #9f9f9f;
  --surface: #f8fcff;
  --muted: #86392d;
  --line: #e9c4bb;
  /* Stipkleuren: bewust los van de huisstijl. */
  --dot-free: #8f9490;
  --dot-busy: #e6860b;
  --dot-full: #cf2e2e;
  --dot-mine: #16a34a;
  --close-bg: #ffe3b8;
  --close-text: #6f3a00;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  margin: 0;
  background: var(--color-white);
  color: var(--color-primary);
  font: 17px/1.6 Helvetica, Arial, sans-serif;
}

h1, h2, h3, h4 { font-weight: 400; }
h1 { margin: 0 0 1rem; font-size: clamp(2.25rem, 7vw, 3.25rem); line-height: 1.1; text-align: center; }
h2 { margin: 0 0 .5rem; font-size: 1.5rem; font-weight: 700; line-height: 1.2; }
h3 { margin: 0 0 .15rem; font-size: 1.35rem; font-weight: 700; line-height: 1.25; }
button, input, select { font: inherit; }
:focus-visible { outline: 3px solid var(--color-tertiary); outline-offset: 2px; }

.logo { display: block; width: auto; height: 3.25rem; }

/* Aanmelden */
.login { max-width: 26rem; margin: 0 auto; padding: 8vh 1.25rem 2rem; }
.login .logo { height: 5rem; margin: 0 auto 1.5rem; }
.login h1 { font-size: clamp(2rem, 8vw, 2.5rem); }
.login p { text-align: center; }
.eyebrow { margin: 0 0 .25rem; font-size: .95rem; }
.login form { margin-top: 1.5rem; }
.login label { display: block; margin-bottom: .35rem; font-weight: 700; }
.login input {
  width: 100%;
  min-height: 3.1rem;
  padding: .5rem .75rem;
  border: 1px solid var(--color-gray);
  border-radius: 4px;
  background: #fff;
  color: var(--color-primary);
  letter-spacing: .08em;
  text-align: center;
  text-transform: uppercase;
}
.login input:focus { border-color: var(--color-primary); }
.login button, .link-row button, .route-apply {
  border: 0;
  border-radius: 2.6rem;
  background: var(--color-primary);
  color: var(--color-white);
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: background-color .2s ease;
}
.login button { width: 100%; min-height: 3.1rem; }
.login button:hover, .link-row button:hover, .route-apply:hover:not(:disabled) { background: var(--color-tertiary); color: #fff; }
.error { min-height: 1.5rem; margin: .4rem 0 .6rem; color: var(--color-primary); font-size: .95rem; font-weight: 700; }

/* Balk */
.bar { position: sticky; top: 0; z-index: 2; background: var(--color-white); border-bottom: 1px solid var(--line); }
.bar-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  max-width: 68rem;
  margin: 0 auto;
  padding: .45rem 1.25rem;
}
.brand { margin-right: auto; font-weight: 700; line-height: 1.2; }
.my-dots { display: inline-flex; gap: .3rem; }
.my-dots .dot { width: 14px; height: 14px; }
.my-dots .dot-empty { background: transparent; border: 2px solid var(--color-primary); }
.link {
  min-height: 2.75rem;
  padding: 0 .25rem;
  border: 0;
  background: none;
  color: inherit;
  text-decoration: underline;
  cursor: pointer;
}
.link:hover { color: var(--color-tertiary); }

@media (max-width: 30rem) {
  .bar-inner { gap: .5rem; padding-inline: .75rem; }
  .bar .logo { height: 2.75rem; }
  .brand { min-width: 0; font-size: .9rem; }
}

@media (max-width: 22rem) {
  .brand { visibility: hidden; flex: 1; width: 0; }
}

/* Inhoud */
.content { max-width: 68rem; margin: 0 auto; padding: 2.5rem 1.25rem 4rem; }
.intro p { max-width: 42rem; margin: 0 auto 1.25rem; text-align: center; }
.legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .4rem 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: .94rem;
}
.legend li { display: flex; align-items: center; gap: .45rem; }

.dot {
  display: inline-block;
  flex: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
}
.dot-free { background: var(--dot-free); }
.dot-busy { background: var(--dot-busy); }
.dot-full { background: var(--dot-full); }
.dot-mine { background: var(--dot-mine); }

.picks { margin: 1.75rem 0; padding: 1rem 0; border-block: 1px solid var(--line); }
.picks ol { margin: 0; padding: 0; list-style: none; }
.picks li { display: flex; align-items: baseline; gap: .55rem; padding: .15rem .5rem; margin-inline: -.5rem; border-radius: 4px; }
.picks li .dot { width: 12px; height: 12px; align-self: center; }
.picks time { font-variant-numeric: tabular-nums; font-weight: 700; margin-right: .5rem; }
.picks .where { color: var(--muted); }
.picks li.is-close { background: var(--close-bg); }
.picks li.is-close, .picks li.is-close .where { color: var(--close-text); }
.picks li.is-close + li.is-close { margin-top: 2px; }
.picks-close {
  margin: 0 0 .5rem;
  padding: .35rem .5rem;
  margin-inline: -.5rem;
  border-radius: 4px;
  background: var(--close-bg);
  color: var(--close-text);
  font-weight: 700;
}
#picks-empty { margin: 0; color: var(--muted); }

/* Dashboard */
.updated { margin: 0 0 1rem; color: var(--muted); font-size: .94rem; min-height: 0; }
.totals { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr)); margin: 0; }
.total { padding: .9rem 1rem; background: var(--color-secondary); border-radius: 8px; }
.total dt { font-size: .94rem; }
.total dd { margin: 0; }
.total strong { font-size: 2rem; font-weight: 400; }
.admin-section { margin-top: 2rem; }
.admin-note { margin: 0 0 .5rem; color: var(--muted); font-size: .94rem; }
.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { padding: .55rem .75rem; text-align: left; vertical-align: top; }
th { font-size: .85rem; font-weight: 700; white-space: nowrap; }
tbody tr { border-top: 1px solid var(--line); }
td.count { white-space: nowrap; font-variant-numeric: tabular-nums; }
td.count .dot { width: 12px; height: 12px; margin-right: .45rem; vertical-align: -1px; }

/* Hulp bij het kiezen */
.helpers { display: grid; gap: .6rem; margin-bottom: 2rem; }
.helper { background: var(--color-secondary); border-radius: 8px; }
.helper > summary {
  padding: .8rem 1rem;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
}
.helper-body { padding: 0 1rem 1rem; }
.helper-body p { margin: 0 0 .6rem; }
.helper-step { margin: 0 0 .15rem; color: var(--muted); font-size: .94rem; }
.helper-question { font-weight: 700; }
.helper-options { display: grid; gap: .5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); margin-bottom: .6rem; }
.helper-options button {
  min-height: 2.75rem;
  padding: .35rem 1rem;
  border: 1px solid var(--color-primary);
  border-radius: 2.6rem;
  background: transparent;
  color: var(--color-primary);
  line-height: 1.2;
  cursor: pointer;
  transition: background-color .2s ease, color .2s ease;
}
.helper-options button:hover { background: var(--color-primary); color: var(--color-white); }
.route-apply, .link-row button { min-height: 2.75rem; padding: .4rem 1.25rem; }
.route-apply:disabled { background: transparent; border: 1px solid var(--color-gray); color: var(--muted); cursor: not-allowed; }
.route { margin: 0 0 .75rem; padding: 0; list-style: none; }
.route li { display: flex; align-items: baseline; gap: .55rem; padding: .15rem 0; }
.route li .dot { width: 12px; height: 12px; align-self: center; }
.route time { font-variant-numeric: tabular-nums; font-weight: 700; margin-right: .5rem; }
.route .where { color: var(--muted); }
.route-note { color: var(--muted); font-size: .94rem; }
.team-person + .team-person { margin-top: 1.25rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
.team-head { display: flex; align-items: center; gap: .85rem; }
.team-photo { flex: none; width: 72px; height: 72px; border-radius: 50%; object-fit: cover; object-position: center 20%; background: var(--line); }
.team-person h3 { margin-bottom: 0; }
.helper-body .team-role { margin: 0; font-size: .94rem; }
.team-routes { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr)); margin-top: .5rem; }
.team-routes h4 { margin: 0 0 .25rem; font-size: 1rem; font-weight: 700; }
.link-form label { display: block; margin-bottom: .25rem; font-weight: 700; }
.link-row { display: flex; gap: .5rem; }
.link-row input {
  flex: 1;
  min-width: 0;
  min-height: 2.75rem;
  padding: 0 .75rem;
  border: 1px solid var(--color-gray);
  border-radius: 4px;
  background: #fff;
  color: var(--color-primary);
  letter-spacing: .08em;
  text-transform: uppercase;
}

/* Weergave en filters */
.browse-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .5rem 1rem;
  margin-bottom: 1rem;
}
.browse-head h2 { margin: 0; }
.views { display: inline-flex; border: 1px solid var(--color-primary); border-radius: 2.6rem; overflow: hidden; }
.views button {
  min-height: 2.75rem;
  padding: 0 1.1rem;
  border: 0;
  background: transparent;
  color: var(--color-primary);
  cursor: pointer;
}
.views button[aria-pressed="true"] { background: var(--color-primary); color: var(--color-white); font-weight: 700; }

.filters { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); }
.filters label { display: block; margin-bottom: .25rem; font-weight: 700; font-size: .94rem; }
.filters select {
  width: 100%;
  min-height: 2.75rem;
  padding: 0 .5rem;
  border: 1px solid var(--color-gray);
  border-radius: 4px;
  background: #fff;
  color: var(--color-primary);
}
.filter-result { display: flex; align-items: center; gap: 1rem; min-height: 2.75rem; margin: .4rem 0 .6rem; color: var(--muted); font-size: .94rem; }
.clear {
  min-height: 2.75rem;
  padding: 0 .25rem;
  border: 0;
  background: none;
  color: var(--color-primary);
  font-size: inherit;
  text-decoration: underline;
  cursor: pointer;
}
.clear:hover { color: var(--color-tertiary); }
.no-results { padding: 2rem 0; color: var(--muted); text-align: center; }

/* Per uur */
.hour-group + .hour-group { margin-top: 1.5rem; }
.hour-group h3 { margin-bottom: .5rem; }
.hour-group ul {
  margin: 0;
  padding: 0;
  list-style: none;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}
.hour-row { display: grid; grid-template-columns: 6.25rem minmax(0, 1fr); align-items: center; gap: .85rem; padding: .6rem .75rem; }
.hour-row:not(:last-child) { border-bottom: 1px solid var(--line); }
.hour-artist { display: block; font-weight: 700; }
.hour-garden { display: block; color: var(--muted); font-size: .94rem; }

/* Artiesten */
.artists { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr)); }
.artist {
  display: flex;
  flex-direction: column;
  padding: 1.15rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}
.garden { margin: 0 0 .6rem; color: var(--muted); font-size: .94rem; }
.bio { margin: 0 0 1rem; }

.slots {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .5rem;
  margin-top: auto;
}
.slot {
  display: flex;
  flex-wrap: wrap;
  align-content: center;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  min-height: 3rem;
  padding: .25rem;
  border: 1px solid var(--color-primary);
  border-radius: 2.6rem;
  background: #fff;
  color: var(--color-primary);
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}
.slot:hover:not(:disabled) { background: var(--color-secondary); }
.slot.is-mine { border: 2px solid var(--dot-mine); background: #e8f7ed; color: #14532d; font-weight: 700; }
.slot:disabled { border-color: var(--line); background: #f6ecea; color: var(--muted); cursor: not-allowed; }
.slot:disabled .slot-time { text-decoration: line-through; }
.slot-friend { flex-basis: 100%; font-size: .72rem; line-height: 1; text-align: center; }

.more { margin-top: .85rem; font-size: .94rem; }
.more summary { min-height: 1.75rem; cursor: pointer; }
.more p { margin: .35rem 0 0; }

.toast {
  position: fixed;
  left: 50%;
  bottom: 1.25rem;
  z-index: 3;
  width: max-content;
  max-width: calc(100% - 2rem);
  margin: 0;
  padding: .65rem 1.25rem;
  transform: translateX(-50%);
  border-radius: 2.6rem;
  background: var(--color-primary);
  color: var(--color-white);
}
