/* Theme s1: inner page parts added after the review (timetable fees, Facebook lists, board, contact).
   Loaded after theme.css. */

/* Fees: one card per group, the whole card signs up on Abler. */
.s1-feesec { display: flex; flex-direction: column; gap: 20px; }
.s1-feecards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.s1-feecards--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.s1-feecards > li { display: flex; }
.s1-feecard { flex: 1; display: flex; flex-direction: column; gap: 6px; padding: 22px 24px; border: 1px solid var(--s1-line); border-radius: 14px; background: #fff; color: var(--s1-ink); text-decoration: none; }
.s1-feecard__group { font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--s1-blue-ink); }
.s1-feecard__fee { font-size: clamp(28px, 3.4vw, 34px); font-weight: 700; line-height: 1.1; color: var(--s1-navy); }
.s1-feecard small { font-size: 14px; color: var(--s1-muted); }
.s1-feecard__go { margin-top: auto; padding-top: 12px; font-size: 14px; font-weight: 600; color: var(--s1-blue-ink); }
.s1-feecard--link { transition: border-color .15s, box-shadow .15s, transform .15s; }
.s1-feecard--link:hover, .s1-feecard--link:focus-visible { border-color: var(--s1-blue); box-shadow: 0 8px 24px rgba(0, 51, 117, .1); transform: translateY(-2px); color: var(--s1-ink); }
.s1-feecard--link:hover .s1-feecard__go { color: var(--s1-navy); text-decoration: underline; }
.s1-feenote { max-width: none; }
.s1-feenote .rich > :first-child { margin-top: 0; }

/* Facebook pages as icon rows */
.s1-fb__title { margin: 0 0 4px !important; font-size: 20px !important; letter-spacing: 0 !important; text-transform: none !important; color: var(--s1-navy) !important; }
.s1-fb__text { margin: 0 0 8px; font-size: 14px; color: var(--s1-soft); }
.s1-fb__list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); column-gap: 24px; }
.s1-fb__list a { display: flex; align-items: center; gap: 12px; min-height: 44px; font-weight: 600; text-decoration: none; color: var(--s1-navy); }
.s1-fb__list a svg { flex-shrink: 0; color: var(--s1-blue); }
.s1-fb__list a:hover { text-decoration: underline; }

/* Board: cards (at most three per row) or a list in columns per group */
/* The Spjöld/Listi switch itself is styled in theme.css (shared with the race table). */
.s1-stack > .s1-viewswitch { align-self: flex-end; margin-bottom: -16px; }
.s1-board { display: flex; flex-direction: column; gap: 40px; }
.s1-board__title { margin: 0 0 14px; font-size: 20px; font-weight: 600; color: var(--s1-navy); }
.s1-board .s1-people { list-style: none; margin: 0; padding: 0; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.s1-board .s1-person a { overflow-wrap: anywhere; }

.s1-board[data-view="list"] { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 36px; }
.s1-board[data-view="list"] .s1-board__title { margin: 0; padding-bottom: 10px; border-bottom: 2px solid var(--s1-navy); }
.s1-board[data-view="list"] .s1-people { display: block; }
.s1-board[data-view="list"] .s1-person { border: 0; border-bottom: 1px solid var(--s1-line); border-radius: 0; padding: 12px 0; background: none; }
.s1-board[data-view="list"] .s1-person span { font-size: 11.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }

@media (max-width: 860px) {
  .s1-board .s1-people { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .s1-board[data-view="list"] { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .s1-feecards--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .s1-board .s1-people, .s1-feecards, .s1-feecards--3 { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .s1-feecard--link { transition: none; }
  .s1-feecard--link:hover, .s1-feecard--link:focus-visible { transform: none; }
}

/* Runs of a race series (Themes/RaceDates.cs, parts/RaceDays): the "Hlaupdagar" block, or the race page's own
   list above the text. One markup, two views. List (default): one row per run, date tile left, name with a tag,
   date, time and place with icons, the short text, links, and a fold-out "Nánar um hlaupið" with the run's own
   text and course image (the next run starts open, on mist; past runs muted, still 5:1 or better).
   Cards (.is-cards): the same rows as a grid of white cards, the next one framed in blue with a navy tile.
   The header (eyebrow, heading, season line, shared note) is optional; --bare is the list with only the switch. */
.s1-runs__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.s1-runs__head .s1-h2 { margin-top: 2px; }
.s1-runs--bare .s1-runs__head { justify-content: flex-end; margin-bottom: 12px; }
.s1-runs__season { margin: 6px 0 0; font-size: 14px; font-weight: 600; color: var(--s1-muted); }
.s1-runs__note { margin: -4px 0 18px; font-size: 15px; line-height: 1.6; color: var(--s1-soft); max-width: 68ch; }
.s1-runs__list { list-style: none; margin: 0; padding: 0; }
.s1-run { display: flex; align-items: flex-start; gap: 20px; padding: 18px 0; border-top: 1px solid var(--s1-line); }
.s1-runs__list > li:last-child { border-bottom: 1px solid var(--s1-line); }
.s1-run--next { background: var(--s1-mist); border-radius: 14px; padding: 18px 18px 20px; border-top: 0; }
.s1-runs__list > li:has(+ .s1-run--next), .s1-run--next + li { border-top: 0; }
.s1-run__date { width: 64px; flex-shrink: 0; text-align: center; background: #e6effa; border-radius: 12px; padding: 9px 0 8px; }
.s1-run__date b { display: block; font-size: 23px; font-weight: 700; line-height: 1; color: var(--s1-navy); }
.s1-run__date span { display: block; margin-top: 3px; font-size: 11.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--s1-blue-ink); }
.s1-run--next .s1-run__date { background: var(--s1-navy); }
.s1-run--next .s1-run__date b, .s1-run--next .s1-run__date span { color: #fff; }
.s1-run--past .s1-run__date { background: #e4e8ee; }
.s1-run--past .s1-run__date b { color: var(--s1-soft); }
.s1-run--past .s1-run__date span { color: var(--s1-muted); }
.s1-run__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.s1-run__name { margin: 0; font-size: 19px; font-weight: 600; line-height: 1.25; color: var(--s1-navy); display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.s1-run--past .s1-run__name { color: var(--s1-soft); }
.s1-run__tag { display: inline-block; padding: 2px 8px; border-radius: 4px; background: var(--s1-navy); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.s1-run__tag--past { background: #e6effa; color: var(--s1-blue-ink); }
.s1-run__facts { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 14px; font-weight: 500; color: var(--s1-ink); }
.s1-run__facts li { display: flex; align-items: flex-start; gap: 7px; line-height: 1.4; }
.s1-run__facts svg { flex-shrink: 0; color: var(--s1-blue); margin-top: 2px; }
.s1-run--past .s1-run__facts { color: var(--s1-soft); }
.s1-run--past .s1-run__facts svg { color: var(--s1-muted); }
.s1-run__desc { margin: 0; font-size: 15px; line-height: 1.55; color: var(--s1-soft); max-width: 66ch; }
.s1-run__links { margin: 0; display: flex; gap: 18px; flex-wrap: wrap; font-size: 14px; font-weight: 600; }
.s1-run__links a { color: var(--s1-blue-ink); text-decoration: none; }
.s1-run__links a:hover { text-decoration: underline; text-underline-offset: 3px; }
/* The fold-out: a plain details, not the mist box the theme gives details in text. */
.theme-s1 details.s1-run__more { background: none; border-radius: 0; padding: 0; margin-top: 2px; }
.s1-run__more > summary { list-style: none; display: inline-flex; align-items: center; gap: 6px; min-height: 32px; font-size: 14px; font-weight: 600; color: var(--s1-blue-ink); cursor: pointer; }
.s1-run__more > summary::-webkit-details-marker { display: none; }
.s1-run__more > summary:hover { text-decoration: underline; text-underline-offset: 3px; }
.s1-run__more > summary svg { transition: transform .15s ease; }
.s1-run__more[open] > summary svg { transform: rotate(180deg); }
.s1-run__more-close, .s1-run__more[open] .s1-run__more-open { display: none; }
.s1-run__more[open] .s1-run__more-close { display: inline; }
.s1-run__body { margin-top: 8px; display: flex; flex-direction: column; gap: 16px; max-width: 72ch; }
.s1-run__body .rich { font-size: 15.5px; line-height: 1.7; }
.s1-run--next .s1-run__body { padding: 16px 18px; background: #fff; border-radius: 12px; }
.s1-run__map { margin: 0; }
.s1-run__map a { display: block; }
.s1-run__map img { display: block; width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--s1-line); }
.s1-run__map figcaption { margin-top: 8px; font-size: 13.5px; color: var(--s1-muted); }
.s1-run__map figcaption a { color: var(--s1-blue-ink); font-weight: 600; }
/* Cards view */
.s1-runs.is-cards .s1-runs__list { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 18px; align-items: start; }
.s1-runs.is-cards .s1-run, .s1-runs.is-cards .s1-runs__list > li { display: grid; grid-template-columns: 60px minmax(0, 1fr); gap: 12px 14px; padding: 18px 18px 20px; background: #fff; border: 1px solid var(--s1-line); border-radius: 16px; }
.s1-runs.is-cards .s1-run--next { border: 2px solid var(--s1-blue); box-shadow: 0 10px 24px rgba(0, 51, 117, .10); padding: 17px 17px 19px; }
.s1-runs.is-cards .s1-run--past { background: var(--s1-mist); border-color: transparent; }
.s1-runs.is-cards .s1-run__date { width: 60px; grid-row: 1; }
/* The card is a grid of the row's parts: tile and name side by side, the rest full width. */
.s1-runs.is-cards .s1-run__main { display: contents; }
.s1-runs.is-cards .s1-run__name { grid-row: 1; grid-column: 2; align-self: center; font-size: 18px; }
.s1-runs.is-cards .s1-run__facts, .s1-runs.is-cards .s1-run__desc, .s1-runs.is-cards .s1-run__links, .s1-runs.is-cards .s1-run__more { grid-column: 1 / -1; }
.s1-runs.is-cards .s1-run__facts { flex-direction: column; gap: 5px; }
.s1-runs.is-cards .s1-run__desc { font-size: 14.5px; }
.s1-runs.is-cards .s1-run--next .s1-run__body { padding: 0; background: none; }
@media (max-width: 640px) {
  .s1-runs__head { align-items: flex-start; }
  .s1-run { gap: 14px; padding: 16px 0; }
  .s1-run--next { padding: 14px 12px 16px; }
  .s1-run__date { width: 58px; }
  .s1-run--next .s1-run__body { padding: 12px 14px; }
  .s1-runs.is-cards .s1-runs__list { grid-template-columns: minmax(0, 1fr); gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .s1-run__more > summary svg { transition: none; }
}
