/* Calendar and tracks (Categories & calendar), podium passes */
/* ===== Calendar (in Categories & calendar) ===== */
.cv-wrap { display: flex; flex-direction: column; gap: 16px; }
.cv-month { padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.cv-day.off > b { color: var(--muted); }
.cv-month h2 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0; font-family: var(--display); font-style: italic; font-weight: 800; font-size: 30px; text-transform: uppercase; }
.cv-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cv-grid .wd { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); text-align: center; padding-bottom: 2px; }
.cv-day { min-height: 74px; border-radius: 4px; padding: 5px 6px; display: flex; flex-direction: column; gap: 3px; background: color-mix(in srgb, var(--ph) 16%, transparent); border-top: 3px solid var(--ph); min-width: 0; }
.cv-day.blank { background: none; border: 0; }
.cv-day.past { opacity: .5; }
.cv-day.today { outline: 2px solid var(--fg); outline-offset: 1px; }
.cv-day > b { font-family: var(--display); font-weight: 700; font-size: 18px; line-height: 1; }
.cv-day .tg { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--ph); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cv-day .mine { display: flex; gap: 2px; flex-wrap: wrap; }
.cv-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 14px; }
.cv-legend span { display: inline-flex; align-items: center; gap: 6px; }
.cv-legend i { width: 14px; height: 14px; border-radius: 3px; background: var(--ph); }
.cv-year { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.cv-mini { text-transform: none; letter-spacing: 0; font-family: var(--body); font-weight: 400; display: flex; flex-direction: column; gap: 6px; padding: 10px; text-align: left; }
.cv-mini[aria-pressed="true"] { border-color: var(--flag); }
.cv-mini b { font-family: var(--display); font-weight: 700; font-size: 16px; text-transform: uppercase; }
.cv-mini .mg { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.cv-mini .mg i { aspect-ratio: 1; border-radius: 1px; background: var(--ph); opacity: .85; }
.cv-mini .mg i.blank { background: none; }
.cv-mini .mg i.today { outline: 1px solid var(--fg); }
.cv-next { display: flex; gap: 10px; flex-wrap: wrap; }
.cv-next div { padding: 8px 12px; border: 1px solid var(--line); border-left: 4px solid var(--ph); border-radius: 3px; display: flex; flex-direction: column; font-size: 14px; }
.cv-next div span { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; }
@media (max-width: 600px) { .cv-day { min-height: 54px; padding: 3px; } .cv-day .tg { display: none; } .cv-day > b { font-size: 15px; } }

/* ===== Tracks (in Categories & calendar) ===== */
.tk-detail { display: flex; flex-direction: column; gap: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.tk-detail > .back { align-self: flex-start; }
.tk-detail .track-card { margin-bottom: 0; }
.tk-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 12px; }
.tk-box { padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.tk-rainwrap { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px; padding: 18px 0 22px; }
.tk-axis { display: flex; flex-direction: column; justify-content: space-between; height: 150px; margin: -7px 0; font-size: 10px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.tk-rain { position: relative; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 4px; align-items: end; height: 150px; border-bottom: 1px solid var(--line); }
.tk-rain em { position: absolute; left: 0; right: 0; border-top: 1px dashed rgba(255, 255, 255, .1); }
.tk-rain div { position: relative; display: flex; justify-content: center; align-items: flex-end; height: 100%; min-width: 0; }
.tk-rain i { position: relative; width: 100%; max-width: 26px; border-radius: 2px 2px 0 0; }
.tk-rain b { position: absolute; bottom: calc(var(--h, 0%) + 2px); font-size: 11px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tk-rain span { position: absolute; bottom: -20px; font-size: 10px; text-transform: uppercase; color: var(--muted); }
.tk-rain .now span { color: var(--fg); font-weight: 800; } .tk-rain .now i { outline: 2px solid #fff; outline-offset: 1px; }
.tk-rain .now::after { content: ""; position: absolute; bottom: -26px; width: 16px; height: 2px; background: var(--flag); }
.lv-low { background: #7f8ea3; } .lv-mid { background: #8fb8ff; } .lv-high { background: #2b5ce6; }
.tk-lv { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12px; color: var(--muted); }
.tk-lv span { display: inline-flex; align-items: center; gap: 6px; } .tk-lv i { width: 12px; height: 12px; border-radius: 2px; }
@media (max-width: 520px) { .tk-rain b { font-size: 9px; } .tk-rain div:not(.now):not(.top) b { display: none; } }
.tk-rainsay { margin: 0; font-size: 15px; line-height: 1.45; }
.tk-type { display: grid; grid-template-columns: 90px minmax(0, 1fr) 30px; gap: 8px; align-items: center; font-size: 14px; }
.tk-type .bar { height: 10px; border-radius: 5px; background: var(--line); overflow: hidden; }
.tk-type .bar i { display: block; height: 100%; }
.tk-type b { font-family: var(--display); text-align: right; font-variant-numeric: tabular-nums; }
@media (max-width: 600px) { .tk-detail .track-card { grid-template-columns: 1fr; } }
/* Tracks list: small rows on phones, big map tiles on wider screens */
.tk-grid .tg-map .thumb { width: 54px; height: 54px; }
@media (min-width: 700px) {
  .tk-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
  .tk-grid button { flex-direction: column; align-items: stretch; gap: 10px; padding: 14px; }
  .tk-grid .tg-map { display: flex; justify-content: center; align-items: center; aspect-ratio: 4 / 3; border-radius: 4px; background: radial-gradient(ellipse at center, rgba(255, 255, 255, .06), transparent 70%); }
  .tk-grid .tg-map .thumb { width: 82%; height: 82%; }
  .tk-grid .tg-txt { width: 100%; align-items: flex-start; text-align: left; }
  .tk-grid .tg-txt b { font-size: 17px; }
  .tk-detail .track-card { grid-template-columns: minmax(300px, 1.25fr) 1fr; gap: 28px; padding: 20px 24px; }
}

/* Podium passes: polished metal, tricolor medal ribbon, a medal with the place instead of the holo seal */
.pass-face.metal-gold { background: linear-gradient(150deg, #fff3b0 0%, #f2c230 22%, #b07d0c 48%, #f7d65c 70%, #8a5e05 100%); color: #2a1c00; }
.pass-face.metal-silver { background: linear-gradient(150deg, #ffffff 0%, #d7dde5 22%, #8d98a8 48%, #e9edf2 70%, #6b7584 100%); color: #1a1f28; }
.pass-face.metal-gold .pass-sub, .pass-face.metal-silver .pass-sub { color: rgba(0, 0, 0, .6); }
.pass-face.metal-gold .pass-logo { color: #1a1205; text-shadow: 0 1cqw 0 rgba(255, 255, 255, .45); }
.pass-face.metal-silver .pass-logo { color: #1a1f28; text-shadow: 0 1cqw 0 rgba(255, 255, 255, .45); }
.pass-face .pass-medal { width: 26cqw; height: 26cqw; font-family: var(--display, inherit); font-weight: 800; font-style: italic; font-size: 11cqw; color: #3b2700; animation: none;
  background: radial-gradient(circle at 35% 30%, #fff8d6, #e8b21c 45%, #8a5e05); box-shadow: 0 0 0 1.2cqw rgba(255, 255, 255, .75), 0 0 0 2.2cqw rgba(0, 0, 0, .25), 0 2cqw 5cqw rgba(0, 0, 0, .4); }
.pass-face .pass-medal.silver { background: radial-gradient(circle at 35% 30%, #ffffff, #b9c2ce 45%, #5f6977); color: #20262f; }
.pass-strap.ribbon::before, .pass-strap.ribbon::after { background: linear-gradient(90deg, #c8102e 0 33%, #fff 33% 66%, #1f4bd8 66%); }

