/* Kaart: the template is shell/panel.css; here the list of rides beside the map. */
.rides { display: flex; flex-direction: column; gap: 6px; }
/* The tools above the years (Per jaar, what was found or ticked) a little apart, so they do not stack into one block. */
#rides-tools { padding-bottom: 12px; }
.rides > .list-tools, .rides > .group-switch, .rides > .selection-bar { margin-bottom: 4px; }
.year-head { display: flex; align-items: center; gap: 10px; padding: 8px 4px 2px; }
.year-toggle {
  flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 8px; padding: 0; border: 0; background: none; color: inherit;
  font: inherit; text-align: left; cursor: pointer;
}
.year { font-weight: 700; font-size: 15px; }
.year.folder { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Per jaar or per map, with Nieuwe map beside it per map; what is ticked can move together. */
.list-tools { display: flex; gap: 8px; align-items: center; }
.list-tools .group-switch { flex: 1; }
.new-folder, .found-bar button {
  height: 34px; padding: 0 12px; border: 1px solid var(--shell-quiet-line); border-radius: var(--radius-sm); background: var(--shell-panel);
  color: inherit; font: inherit; font-weight: 600; font-size: 13px; cursor: pointer; white-space: nowrap;
}
.new-folder:hover, .found-bar button:hover { background: var(--shell-hover); }
/* What is ticked floats at the bottom of the list, over the rides as they scroll (9 Nov 2026). */
.selection-dock {
  position: sticky; bottom: 0; z-index: 2; margin-top: auto; padding: 12px 14px 14px; border-radius: var(--radius-md);
  background: var(--shell-panel); box-shadow: var(--shadow-card); outline: 1px solid var(--line); outline-offset: -1px;
}
.selection-dock[hidden] { display: none; }
.selection-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; font-size: 14px; font-weight: 700; }
.selection-close {
  display: grid; place-items: center; width: 30px; height: 30px; margin: -6px -6px -6px 0; padding: 0; border: 0; border-radius: 50%;
  background: transparent; color: var(--shell-muted); cursor: pointer;
}
.selection-close:hover { background: var(--shell-hover); color: inherit; }
.selection-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.selection-actions .rm-btn { min-width: 0; padding: 0 8px; gap: 5px; font-size: 13px; }
.selection-actions .rm-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.selection-note { margin: 10px 0 0; font-size: 13px; color: var(--shell-muted); }
.selection-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 8px 8px 12px; border-radius: var(--radius-sm); background: var(--shell-fill); font-size: 13.5px; font-weight: 600; }
.group-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; padding: 2px; border-radius: var(--radius-sm); background: var(--shell-fill); }
.group-switch button { height: 30px; border: 0; border-radius: var(--radius-sm); background: transparent; color: inherit; font: inherit; font-weight: 600; font-size: 12.5px; cursor: pointer; }
.group-switch button.on { background: var(--shell-panel); outline: 1px solid var(--ink-muted); outline-offset: -1px; }
.year-meta { font-size: 12.5px; color: var(--shell-muted); font-variant-numeric: tabular-nums; }
.chev { margin-left: auto; color: var(--shell-muted); }
.chev, .area-fold svg, .area-more svg { transition: transform 0.15s; }
.chev.closed { transform: rotate(-90deg); }
/* A card of rows: the rides of a group, and the tree of Gebieden. */
.ride-rows, .areas { display: flex; flex-direction: column; border-radius: var(--radius-md); background: var(--shell-panel); box-shadow: none; outline: 1px solid var(--line); outline-offset: -1px; overflow: hidden; }
.ride { display: flex; align-items: center; gap: 10px; padding: 8px 12px 8px 10px; border-top: 1px solid var(--shell-hairline); }
.ride:first-child { border-top: 0; }
.ride.hot { background: var(--surface-muted); }
.ride.focused .ride-name { color: var(--shell-link); }
.ride.waiting { color: var(--shell-muted); }
.ride input, .year-head input { width: 16px; height: 16px; margin: 0; accent-color: #D55E00; /* Protected map-selection colour (SPEC §5). */ flex-shrink: 0; cursor: pointer; }
.ride-text {
  flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; padding: 0; border: 0; background: none;
  color: inherit; font: inherit; text-align: left; cursor: pointer;
}
.ride-text:disabled { cursor: default; }
/* A name of its own may take two lines; the whole of it is in the tooltip. */
.ride-name { font-weight: 600; font-size: 14px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow-wrap: anywhere; }
.ride-meta { font-size: 12.5px; color: var(--shell-muted); }
.ride-km { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
/* The new km of a ride as a small tag under its km: a light orange tint, the text a dark orange that reads on it (5:1). */
.ride-new { padding: 0 7px; border-radius: var(--radius-pill); background: #E8F0FC; color: #2457B0; font-size: 11.5px; font-weight: 700; }
:root[data-theme="night"] .ride-new { background: rgb(91 147 240 / .18); color: #9EC0F7; }
.under .ride-rows { outline: 2px solid var(--ink); outline-offset: -2px; }
.under-head {
  display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 28px; padding: 0 4px 6px;
  font-size: 12px; font-weight: 600; letter-spacing: 0.3px; text-transform: uppercase; color: var(--shell-muted);
}
.under-tip { font-weight: 500; letter-spacing: 0; text-transform: none; }
.under-head button {
  width: 28px; height: 28px; padding: 0; border: 0; border-radius: var(--radius-lg); background: transparent; color: inherit;
  font-size: 18px; cursor: pointer;
}
.under-head button:hover { background: var(--shell-hover); color: var(--shell-fg); }
/* The colour of a group of ticked rides, or of the rides at a place, as on the map. */
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--c); flex-shrink: 0; }
.year-toggle .dot { align-self: center; }
.under-title { display: flex; align-items: center; gap: 7px; }
.pill-text .dot { margin: 0 4px 1px 2px; vertical-align: middle; box-shadow: 0 0 0 1.5px var(--shell-on-dark); }
/* The chevrons of the riding direction in the legend, as on the map. */
.swatch.chevron {
  display: flex; align-items: center; justify-content: center; letter-spacing: -1px;
  /* Protected white direction arrows, matching the map. */
  color: #FFFFFF; font: 700 9px/1 var(--font-sans);
}
/* Held with a click: the name of the road there, as written. */
.under-title.named { font-size: 14px; letter-spacing: 0; text-transform: none; color: var(--shell-fg); }
.ride-kind { display: flex; flex-shrink: 0; color: var(--shell-muted); }
.ride .sketch-holder { display: flex; flex-shrink: 0; border-radius: 8px; overflow: hidden; }

/* Gebieden (docs/gebieden.md): the country, its provincies and their gemeenten as one tree in a card. Nederland and
   the best provincie start open; a provincie shows its best three gemeenten and the rest on request. */
.areas { flex-shrink: 0; }
.area-line { display: flex; align-items: center; border-top: 1px solid var(--shell-hairline); }
.area-line:first-child { border-top: 0; }
.area-line.chosen { background: var(--surface-muted); }
.area-pick {
  flex: 1; min-width: 0; display: flex; padding: 10px 4px 10px 12px; border: 0; background: transparent;
  color: inherit; font: inherit; text-align: left;
}
.area-line:hover { background: var(--shell-hover); }
.area-line.chosen:hover { background: var(--surface-muted); }
.area-pick:hover .area-name { text-decoration: underline; }
.area-pick .area { flex: 1; }
.area-fold {
  flex: 0 0 44px; align-self: stretch; display: flex; align-items: center; justify-content: center; border: 0;
  background: transparent; color: var(--shell-muted);
}
.area-fold:hover { color: var(--shell-fg); }
.area-fold:hover, .area-more:hover { background: var(--shell-hover); }
.area-fold[aria-expanded="false"] svg { transform: rotate(-90deg); }
.area-fold-gap { flex: 0 0 44px; }
.area-line.land .area-name { font-weight: 700; font-size: 16px; }
.area-line.provincie .area-pick { padding-left: 24px; }
.area-line.provincie .area-name { font-weight: 600; }
.area-line.gemeente .area-pick { padding-left: 40px; }
.area-line.gemeente .area-name { font-size: 14.5px; }
/* Toon nog 9 gemeenten: quiet, under the three, in line with the gemeenten. */
.area-more {
  display: flex; align-items: center; gap: 6px; width: 100%; min-height: 40px; padding: 0 12px 0 40px; border: 0;
  border-top: 1px solid var(--shell-hairline); background: transparent; color: var(--shell-link); font: 600 13.5px "Plus Jakarta Sans", sans-serif; text-align: left;
}
.area-more[aria-expanded="true"] svg { transform: rotate(180deg); }
.area-rest { margin: 0; padding: 0 12px 10px 40px; font-size: 12.5px; color: var(--shell-muted); }

.layers-head { font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--shell-muted); }

/* ---------- One ride or one favourite opened beside the map ---------- */
.detail { display: flex; flex-direction: column; gap: 18px; }
#fav-detail { padding-bottom: 8px; }
.detail .back { align-self: flex-start; display: inline-flex; align-items: center; gap: 4px; min-height: 36px; padding: 0 8px 0 2px; border: 0;
  border-radius: var(--radius-sm); background: none; font: 600 14px var(--font-sans); color: var(--ink); }
.detail .back:hover { background: var(--surface-muted); }
.detail-title { margin: 0; font: 800 26px/1.2 var(--font-sans); letter-spacing: -0.01em; overflow-wrap: anywhere; }
/* The pencil after a ride's title, and the title as a text field while it is renamed. */
.title-edit { display: inline-flex; vertical-align: 0.1em; margin-left: 8px; padding: 4px; border: 0; border-radius: var(--radius-sm);
  background: none; color: var(--shell-muted); cursor: pointer; }
.title-edit:hover, .title-edit:focus-visible { color: var(--ink); background: var(--surface-muted); }
.detail-title-input { width: 100%; box-sizing: border-box; margin: 0; padding: 2px 6px; font: 800 26px/1.2 var(--font-sans); letter-spacing: -0.01em;
  color: var(--ink); background: var(--surface-muted); border: 1.5px solid var(--ink); border-radius: var(--radius-sm); }
.detail-title-input:focus { outline: none; }
.detail-meta { margin: 4px 0 0; font-size: 14px; color: var(--shell-muted); }
.detail-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.detail-stats div { display: flex; flex-direction: column; }
.detail-stats strong { font: 800 26px/1.15 var(--font-sans); font-variant-numeric: tabular-nums; }
/* The new km in the blue of the new road on the map. */
.detail-stats strong.fresh { color: #2F6FD6; }
:root[data-theme="night"] .detail-stats strong.fresh { color: #5B93F0; }
.detail-stats span { font-size: 13px; color: var(--shell-muted); }
/* The ride from start to end (rit.js): its stretches in the map's colours, with Snelweg markeren the motorway thick. */
.detail-route { display: flex; flex-direction: column; gap: 8px; }
.ride-route { display: flex; align-items: center; height: 12px; border-radius: 3px; overflow: hidden; }
.ride-route span { flex: 1 1 0; min-width: 0; height: 8px; }
.ride-route.marked span { height: 4px; }
.ride-route.marked span.motorway { height: 12px; }
.detail-block { display: flex; flex-direction: column; gap: 10px; padding-top: 16px; border-top: 1px solid var(--line); }
.detail-badge { display: flex; align-items: center; gap: 12px; }
.detail-actions { display: flex; flex-wrap: wrap; gap: 10px; padding-top: 16px; border-top: 1px solid var(--line); }
.detail .view-note { margin: 0; }
.linkish { align-self: flex-start; padding: 0; margin-top: 4px; border: 0; background: none; font: 600 13px var(--font-sans); color: var(--ink);
  text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Favorieten: the list as in the app (FavoritesView), rows in white cards ---------- */
.favs { display: flex; flex-direction: column; gap: 12px; }
.fav-tools { display: flex; flex-direction: column; gap: 12px; }
.fav-tools .view-note { margin: 0; }
.fav-group { margin: 6px 0 -4px; }
.fav-card { border-radius: var(--radius-md); box-shadow: inset 0 0 0 1px var(--line); background: var(--surface-raised); overflow: hidden; }
.fav-row { display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 12px 14px; border: 0; background: none; text-align: left;
  font: inherit; color: var(--ink); cursor: pointer; }
.fav-row + .fav-row { border-top: 1px solid var(--line); }
.fav-row:hover { background: var(--surface-muted); }
.fav-icon { flex: none; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; color: var(--ink); }
.fav-icon.big { width: 40px; height: 40px; }
.fav-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.fav-title { font-weight: 700; font-size: 15px; overflow-wrap: anywhere; }
.fav-meta { font-size: 13px; color: var(--shell-muted); }
.fav-note { font-size: 13px; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fav-date { flex: none; font-size: 13px; color: var(--shell-muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.fav-head { display: flex; gap: 12px; align-items: flex-start; }
.fav-head-icon { flex: none; width: 48px; height: 48px; display: flex; align-items: center; justify-content: center; border-radius: var(--radius-md);
  background: var(--surface-muted); color: var(--ink); }
.fav-head-main { flex: 1; min-width: 0; }
.fav-head .detail-title { font-size: 24px; }
.fav-head .detail-meta { font-size: 13px; }
.fav-head-actions { flex: none; display: flex; gap: 8px; }
.fav-round { width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; padding: 0; border: 1px solid var(--line);
  border-radius: var(--radius-sm); background: var(--surface-raised); color: var(--ink); cursor: pointer; }
.fav-round:hover { background: var(--surface-muted); }
.fav-h { margin: 0; font: 700 15px var(--font-sans); color: var(--ink); }
.fav-soort { display: flex; flex-direction: column; gap: 10px; }
.fav-marks { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.fav-mark { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-md);
  background: var(--surface-raised); font: inherit; color: var(--ink); text-align: left; cursor: pointer; }
.fav-mark:hover { background: var(--surface-muted); }
.fav-mark[aria-pressed="true"] { border: 2px solid var(--ink); padding: 11px 13px; }
.fav-mark svg { flex: none; }
.fav-mark > span { display: flex; flex-direction: column; gap: 2px; }
.fav-mark strong { font-size: 15px; }
.fav-mark > span > span { font-size: 13px; line-height: 1.3; color: var(--shell-muted); }
body.shell .rm-btn.fav-remove { width: 100%; min-height: 44px; gap: 8px; border-radius: var(--radius-sm); }
.fav-rename { display: flex; gap: 8px; }
.fav-rename input { flex: 1; min-width: 0; padding: 8px 10px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-muted);
  font: 400 15px var(--font-sans); color: var(--ink); }
.fav-length { display: flex; align-items: center; gap: 10px; padding-top: 16px; border-top: 1px solid var(--line); }
.fav-length .stat { flex: 1; display: flex; flex-direction: column; }
.fav-length strong { font: 800 22px/1.15 var(--font-sans); }
.fav-length span { font-size: 13px; color: var(--shell-muted); }
.detail-links { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.fav-link { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 0; border: 0; border-bottom: 1px solid var(--line); background: none;
  font: 500 15px var(--font-sans); color: var(--ink); text-decoration: none; text-align: left; cursor: pointer; }
.fav-link span:nth-child(2) { flex: 1; }
.fav-link .chev { display: flex; color: var(--shell-muted); }

/* The pins on the map, as the design system's MapPin: white with a thin ink edge by day, the inverse at night. */
.fav-pin { --pin-fill: #fff; --pin-ink: #1f2933; position: relative; display: inline-flex; align-items: center; gap: 4px; height: 30px; padding: 0 9px 0 5px;
  box-sizing: border-box; background: var(--pin-fill); color: var(--pin-ink); border-radius: 999px; cursor: pointer;
  box-shadow: 0 0 0 1px var(--pin-ink), 0 1px 3px rgba(0,0,0,.3); margin-bottom: 6px; transition: transform .12s; }
[data-theme="night"] .fav-pin { --pin-fill: #1f2933; --pin-ink: #fff; }
.fav-pin::after { content: ""; position: absolute; left: 50%; bottom: -5px; width: 10px; height: 10px; margin-left: -5px; box-sizing: border-box;
  background: var(--pin-fill); border: solid var(--pin-ink); border-width: 0 1px 1px 0; transform: rotate(45deg); border-radius: 1px; }
.fav-pin.bare { padding: 0 5px; }
.fav-pin svg { display: block; }
.fav-score { font: 700 15px var(--font-sans); font-variant-numeric: tabular-nums; }
.fav-pin.warning { height: auto; padding: 0; margin: 0; background: none; box-shadow: none; }
.fav-pin.warning::after { display: none; }
.fav-pin.hot, .fav-pin:hover { transform: scale(1.12); }
.fav-pin.picked { transform: scale(1.2); }
.fav-marker { cursor: pointer; }
[data-theme="night"] .rm-warn { --pin-fill: #1f2933; --pin-ink: #fff; }
