/*
 * 1 million d’amis · Le grand comptoir
 *
 * One section per component, in this order. Inside a section: base rules, then
 * hover-capable devices, then breakpoints from wide to narrow, then reduced motion.
 * When two components style the same element, the later section wins.
 *
 *   1. Fonts
 *   2. Design tokens and base elements
 *   3. Page layout, panels and shared cards
 *   4. Buttons and links
 *   5. Header and navigation
 *   6. Footer
 *   7. Banners, dialogs and feedback states
 *   8. Charts and tooltips
 *   9. Day diary
 *  10. Home: hero and collective goal
 *  11. Home: dashboard grid, feed and records
 *  12. Classement
 *  13. Les chiffres and chart grids
 *  14. Les légendes
 *  15. Voyages
 *  16. Profile
 *  17. Passports and stamps
 *  18. Personal medals
 *  19. Face à face
 *  20. TV mode
 *  21. Coca-Zero
 *  22. Theme-aware emphasis
 *  23. Print
 */

/* ==== Fonts ==== */
@font-face {
  font-family: "DejaVu Sans";
  src: url("/fonts/dejavu-sans.ttf") format("truetype");
  font-weight: 400 500;
  font-display: swap;
}
@font-face {
  font-family: "DejaVu Sans";
  src: url("/fonts/dejavu-sans-bold.ttf") format("truetype");
  font-weight: 600 900;
  font-display: swap;
}
@font-face {
  font-family: Bricolage;
  src: url("/fonts/bricolage-grotesque.ttf") format("truetype");
  font-weight: 200 800;
  font-display: swap;
}
/* ==== Design tokens and base elements ==== */
:root {
  --font-body: "DejaVu Sans", sans-serif;
  --bg: #11140f;
  --panel: #1a1e17;
  --panel-light: #20251c;
  --line: #30362a;
  --text: #f2f2e8;
  --muted: #a4ab99;
  --lime: #d3f56b;
  --lilac: #bfa4ed;
  --peach: #edb78b;
  --font: Bricolage, "DejaVu Sans", sans-serif;
  color-scheme: dark;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  font-synthesis: none;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background:
    radial-gradient(ellipse at 84% 8%, #2a332014, transparent 42%), var(--bg);
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}
button,
input,
select {
  font: inherit;
}
button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}
button,
a {
  touch-action: manipulation;
}
button {
  cursor: pointer;
  color: inherit;
  transition:
    background 160ms ease,
    color 160ms ease,
    transform 160ms var(--ease);
}
button:disabled {
  opacity: 0.3;
  cursor: default;
}
a {
  color: inherit;
  text-decoration: none;
}
button:active:not(:disabled) {
  transform: scale(0.97);
}
:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 5px;
}
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline-offset: 3px;
}
main:focus {
  outline: none;
}
::selection {
  background: var(--lime);
  color: var(--bg);
}
svg {
  display: block;
}
svg text {
  font-family: var(--font-body);
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1,
h2,
h3 {
  font-family: var(--font);
  font-weight: 700;
}
button svg,
.beer-count svg,
.goal-details svg,
.podium svg,
.feed-beer svg,
.legend-card svg {
  width: 19px;
  height: 19px;
  display: inline-block;
  vertical-align: middle;
}
button svg {
  fill: currentColor;
}
em {
  font-style: normal;
}
small {
  font-size: 12px;
}
b,
strong {
  font-weight: 700;
}
.muted {
  color: var(--muted);
}
.lilac {
  color: var(--secondary-ink, var(--lilac));
}
.peach {
  color: var(--secondary-ink, var(--peach));
}
.skip-link {
  position: fixed;
  top: -60px;
  left: 20px;
  z-index: 100;
  background: var(--lime);
  color: var(--on-accent, #15190f);
  padding: 12px;
  border-radius: 5px;
}
.skip-link:focus {
  top: 10px;
}
main,
.footer,
.source-banner {
  max-width: 1384px;
  margin-left: auto;
  margin-right: auto;
}
main {
  margin-top: 0;
  margin-bottom: 0;
  padding: 0 0 64px;
  min-height: 75vh;
}
.live-label {
  font-size: 10px;
  letter-spacing: 1.2px;
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  white-space: nowrap;
}
.live-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 9px color-mix(in srgb, var(--lime) 20%, transparent);
}
.eyebrow {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 1.5px;
  color: var(--muted);
  display: block;
  margin-bottom: 10px;
}
.tag {
  border: 1px solid var(--theme-line, #3a4232);
  color: var(--theme-muted, #b4bca7);
  background: var(--theme-surface, #242b1e);
  padding: 6px 8px;
  border-radius: 4px;
  font-size: 10px;
  white-space: nowrap;
}
.small-symbol {
  font-size: 24px;
  color: var(--muted);
}
dialog {
  background: var(--panel);
  color: var(--text);
  border: 1px solid var(--theme-line, #48543a);
  border-radius: 17px;
  padding: 40px;
  max-width: 510px;
  width: calc(100% - 32px);
  box-shadow: 0 25px 90px #0007;
}
dialog::backdrop {
  background: #060a05c9;
  backdrop-filter: blur(4px);
}
[aria-busy="true"] {
  opacity: 0.5;
  pointer-events: none;
}
@keyframes loading {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: translateX(100%);
  }
}
@keyframes bubbles {
  0%,
  100% {
    transform: translateY(0);
    opacity: 0.65;
  }
  50% {
    transform: translateY(-16px);
    opacity: 0.35;
  }
}
/* Fixed vector symbols preserve the site's monochrome artwork on iOS Safari. */
.ui-symbol {
  display: inline-block;
  width: 1em;
  height: 1em;
  flex-shrink: 0;
  vertical-align: -0.12em;
}
@media (min-width: 1513px) {
  main,
  .footer,
  .source-banner {
    max-width: 1300px;
  }
}
@media (max-width: 1512px) {
  main,
  .footer,
  .source-banner {
    margin-left: 64px;
    margin-right: 64px;
  }
}
@media (max-width: 1200px) {
  main,
  .footer,
  .source-banner {
    margin-left: 36px;
    margin-right: 36px;
  }
  .tag {
    font-size: 10px;
  }
}
@media (max-width: 980px) {
  main,
  .footer,
  .source-banner {
    margin-left: 27px;
    margin-right: 27px;
  }
}
@media (max-width: 700px) {
  main,
  .footer,
  .source-banner {
    margin-left: 20px;
    margin-right: 20px;
  }
  .live-dot {
    width: 5px;
    height: 5px;
  }
  main {
    padding-bottom: 38px;
  }
  dialog {
    padding: 32px 24px;
  }
}
@media (max-width: 370px) {
  main,
  .footer,
  .source-banner {
    margin-left: 14px;
    margin-right: 14px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
/* ==== Page layout, panels and shared cards ==== */
.page-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 10px;
  letter-spacing: 1.4px;
  font-weight: 600;
  color: var(--muted);
  padding: 30px 0 8px;
}
.page-topline > span > .muted {
  margin: 0 10px;
  opacity: 0.5;
}
.avatar-stack {
  display: flex;
  padding-left: 5px;
}
.avatar-stack a {
  margin-left: -5px;
}
.avatar-stack .avatar {
  border: 3px solid var(--bg);
}
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 15px;
  margin: 7px 0 48px;
}
.stat-card {
  padding: 21px 23px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: linear-gradient(125deg, var(--panel-light), var(--panel));
}
.stat-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  color: var(--muted);
  font-size: 11px;
  margin-bottom: 14px;
}
.stat-label > span {
  font-size: 16px;
  color: var(--accent-ink, var(--lime));
  line-height: 1;
}
.stat-label svg {
  width: 20px;
  height: 20px;
}
.stat-card > strong {
  display: block;
  font-family: var(--font);
  font-size: 33px;
  letter-spacing: -1px;
  font-weight: 600;
  line-height: 1;
}
.stat-card > strong em {
  font-family: var(--font-body);
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0;
  margin-left: 4px;
  font-weight: 400;
}
.stat-card > small {
  display: block;
  color: var(--theme-muted, #969f89);
  font-size: 11px;
  margin-top: 12px;
  line-height: 1.5;
}
.section-intro {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin: 40px 0 22px;
  gap: 20px;
}
.section-intro h2 {
  font-size: 29px;
  letter-spacing: -1px;
  font-weight: 600;
  line-height: 1.12;
}
.section-intro > .text-link {
  margin-bottom: 2px;
}
.panel {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  padding: 24px;
  overflow: hidden;
  min-width: 0;
}
.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 24px;
}
.panel-heading .eyebrow {
  font-size: 10px;
  letter-spacing: 1.4px;
  margin-bottom: 9px;
}
.panel-heading h2 {
  font-size: 23px;
  letter-spacing: -0.8px;
  font-weight: 600;
  line-height: 1.1;
}
.avatar {
  position: relative;
  display: inline-flex;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid color-mix(in srgb, var(--user-color) 45%, transparent);
  background: color-mix(
    in srgb,
    var(--user-color) 20%,
    var(--theme-surface, #20251b)
  );
  vertical-align: middle;
}
.avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}
.avatar-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--user-color);
  font-size: 13px;
  font-weight: 700;
  font-family: var(--font);
}
.avatar-xs {
  width: 23px;
  height: 23px;
  border-radius: 50%;
}
.avatar-xs .avatar-fallback {
  font-size: 11px;
}
.avatar-sm {
  width: 31px;
  height: 31px;
  border-radius: 9px;
}
.avatar-sm .avatar-fallback {
  font-size: 11px;
}
.avatar-lg {
  width: 59px;
  height: 59px;
  border-radius: 50%;
}
.avatar-xl {
  width: 77px;
  height: 77px;
  border-radius: 50%;
}
.avatar-hero {
  width: 140px;
  height: 140px;
  border-radius: 30px;
}
.avatar-hero .avatar-fallback {
  font-size: 40px;
}
.avatar-lg .avatar-fallback {
  font-size: 20px;
}
.avatar-xl .avatar-fallback {
  font-size: 26px;
}
.identity {
  display: inline-flex;
  gap: 11px;
  align-items: center;
  min-width: 0;
  position: relative;
  z-index: 2;
}
.identity-text {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}
.identity strong {
  font-size: 11px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 600;
}
.identity small {
  font-size: 11px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 160px;
}
.panel-bottom-link {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  font-size: 11px;
  color: var(--accent-ink, var(--lime));
  padding: 20px 0;
  margin-top: auto;
}
.panel-bottom-link > span {
  font-size: 15px;
  line-height: 0.8;
}
.page-heading {
  padding: 64px 0 35px;
}
.page-heading > .eyebrow {
  color: var(--accent-ink, var(--lime));
  font-size: 10px;
  margin-bottom: 22px;
}
.page-heading h1 {
  font-size: 60px;
  letter-spacing: -2.8px;
  line-height: 1.04;
  font-weight: 800;
}
.page-heading em {
  color: var(--accent-ink, var(--lime));
}
.page-heading p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
  margin-top: 23px;
}
.trends-grid .activity-panel,
.trends-grid .race-panel,
.span-two {
  grid-column: 1/-1;
}
.page-note {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.8;
  margin-top: 17px;
}
@media (hover: hover) and (pointer: fine) {
  .text-link:hover,
  .panel-bottom-link:hover {
    color: var(--accent-ink, #e4ffac);
  }
  .identity:hover strong {
    color: var(--user-color);
  }
}
@media (max-width: 1512px) {
  .panel-heading h2 {
    font-size: 21px;
  }
  .panel-heading .eyebrow {
    font-size: 10px;
  }
  .panel-heading {
    margin-bottom: 22px;
  }
}
@media (max-width: 1200px) {
  .stat-card {
    padding: 19px;
  }
  .stat-card > small {
    font-size: 11px;
  }
  .panel {
    padding: 21px;
  }
  .panel-heading h2 {
    font-size: 19px;
  }
  .panel-heading .eyebrow {
    font-size: 10px;
    letter-spacing: 1px;
  }
  .page-heading h1 {
    font-size: 53px;
  }
}
@media (max-width: 980px) {
  .stat-grid {
    gap: 10px;
  }
  .stat-card {
    padding: 17px 14px;
  }
  .stat-label {
    font-size: 11px;
  }
  .stat-card > strong {
    font-size: 29px;
  }
  .stat-card > small {
    font-size: 11px;
  }
  .section-intro h2 {
    font-size: 25px;
  }
  .section-intro .eyebrow {
    font-size: 10px;
  }
  .panel-heading h2 {
    font-size: 20px;
  }
  .panel-heading .eyebrow {
    font-size: 10px;
  }
}
@media (max-width: 700px) {
  .page-topline {
    padding-top: 24px;
    font-size: 10px;
    letter-spacing: 0.8px;
  }
  .page-topline .live-label {
    font-size: 10px;
    letter-spacing: 0.7px;
  }
  .page-topline > span > .muted {
    margin: 0 5px;
  }
  .stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 2px;
    margin-bottom: 31px;
  }
  .stat-card {
    padding: 18px 16px;
  }
  .stat-label {
    font-size: 11px;
    margin-bottom: 13px;
  }
  .stat-label > span {
    font-size: 17px;
  }
  .stat-card > strong {
    font-size: 31px;
  }
  .stat-card > small {
    font-size: 11px;
    margin-top: 10px;
  }
  .stat-card > strong em {
    font-size: 11px;
  }
  .section-intro {
    margin: 31px 0 20px;
    gap: 10px;
  }
  .section-intro h2 {
    font-size: 23px;
    line-height: 1.1;
    max-width: 245px;
  }
  .section-intro .eyebrow {
    font-size: 10px;
    letter-spacing: 0.8px;
    line-height: 1.6;
    margin-bottom: 8px;
  }
  .section-intro .text-link {
    font-size: 0;
    gap: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line);
    border-radius: 50%;
  }
  /* The label stays for screen readers; the arrow is sized independently of it. */
  .section-intro .text-link svg {
    width: 14px;
    height: 14px;
  }
  .panel {
    padding: 22px 19px;
    border-radius: 11px;
  }
  .panel-heading h2 {
    font-size: 22px;
  }
  .panel-heading .eyebrow {
    font-size: 10px;
    letter-spacing: 1.2px;
  }
  .panel-heading {
    gap: 12px;
    margin-bottom: 24px;
  }
  .panel-bottom-link {
    font-size: 11px;
    padding: 20px 0;
  }
  .page-heading {
    padding: 40px 0 30px;
  }
  .page-heading > .eyebrow {
    font-size: 10px;
    letter-spacing: 1px;
    line-height: 1.7;
    margin-bottom: 18px;
  }
  .page-heading h1 {
    font-size: 41px;
    letter-spacing: -1.8px;
    overflow-wrap: anywhere;
  }
  .page-heading p {
    font-size: 12px;
    margin-top: 18px;
  }
  .page-note {
    font-size: 11px;
  }
  .avatar-hero {
    width: 115px;
    height: 115px;
    border-radius: 27px;
  }
}
@media (max-width: 370px) {
  /* The decorative breadcrumb gives its line to the live label. */
  .page-topline > span:first-child {
    display: none;
  }
  .panel {
    padding-left: 15px;
    padding-right: 15px;
  }
  .panel-heading h2 {
    font-size: 20px;
  }
  .page-heading h1 {
    font-size: 36px;
  }
  .stat-card {
    padding: 17px 12px;
  }
  .stat-label {
    font-size: 11px;
  }
  .section-intro h2 {
    font-size: 22px;
  }
}
/* ==== Buttons and links ==== */
.button {
  border: 1px solid var(--lime);
  background: var(--lime);
  color: var(--on-accent, #202617);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  min-height: 48px;
  border-radius: 8px;
  padding: 13px 22px;
  font-weight: 700;
  font-size: 13px;
  white-space: nowrap;
}
.button-small {
  min-height: 40px;
  padding: 10px 14px;
  gap: 10px;
}
.button-small svg {
  width: 19px;
  height: 19px;
}
.button-outline {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
}
.icon-button {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  background: var(--panel-light);
  border-radius: 7px;
  font-size: 18px;
  flex-shrink: 0;
}
.text-link {
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  gap: 20px;
  color: var(--accent-ink, var(--lime));
  font-weight: 600;
}
.segmented {
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 6px;
  display: inline-flex;
  gap: 2px;
  white-space: nowrap;
  background: var(--theme-inset, #151911);
}
.segmented button {
  border: none;
  background: none;
  border-radius: 4px;
  color: var(--muted);
  padding: 6px 9px;
  font-size: 11px;
  min-height: 27px;
}
.segmented button[aria-pressed="true"] {
  color: var(--text);
  background: var(--theme-track, #363e2c);
}
.back-link {
  display: inline-block;
  font-size: 11px;
  color: var(--muted);
  margin: 34px 0;
}
.close-dialog {
  position: absolute;
  right: 15px;
  top: 15px;
  font-size: 23px;
  border: 0;
  background: transparent;
}
/* Profile pickers ("Je suis", "Comparer avec", the duel sides) match the journal filters. */
.me-picker select,
.duel-picker select,
.duel-pickers select {
  min-width: 0;
  max-width: 100%;
  min-height: 40px;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 28px 8px 10px;
  font-size: 12px;
}
.link-button {
  border: 0;
  padding: 0;
  background: none;
  color: var(--muted);
  font-size: 12px;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
@media (hover: hover) and (pointer: fine) {
  .button:hover {
    background: var(--accent-hover, #e1ff89);
  }
  .button-outline:hover {
    background: var(--panel-light);
  }
  .icon-button:hover:not(:disabled) {
    background: var(--theme-surface, #35422a);
  }
}
@media (max-width: 980px) {
  .discord-button {
    font-size: 11px;
    gap: 8px;
    padding: 10px;
  }
  .discord-button > span:last-child {
    display: none;
  }
}
@media (max-width: 700px) {
  .discord-button {
    margin-left: auto;
    min-height: 34px;
    padding: 7px 10px;
    font-size: 11px;
  }
  .discord-button svg {
    width: 16px;
    height: 16px;
  }
  .text-link {
    font-size: 11px;
    gap: 9px;
    white-space: nowrap;
  }
  .segmented button {
    font-size: 11px;
    padding: 6px 7px;
    min-height: 26px;
  }
  .back-link {
    margin: 27px 0;
    font-size: 11px;
  }
  .close-dialog {
    top: 10px;
    right: 10px;
  }
}
/* ==== Header and navigation ==== */
.header {
  max-width: 1512px;
  margin: auto;
  min-height: 100px;
  padding: 0 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  border-bottom: 1px solid var(--line);
}
.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.1;
  font-weight: 600;
  flex-shrink: 0;
}
.brand > span:last-child {
  max-width: 110px;
}
.brand > span:last-child b {
  display: block;
}
.brand-mark {
  width: 43px;
  height: 44px;
  background: var(--lime);
  color: var(--on-accent, #15190e);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font);
  font-weight: 800;
  font-size: 36px;
  letter-spacing: -4px;
  transform: rotate(-7deg);
  padding-right: 5px;
  padding-bottom: 5px;
}
.brand-mark > span {
  font-size: 30px;
  transform: rotate(8deg);
}
.navigation {
  display: flex;
  align-items: center;
  gap: 30px;
  align-self: stretch;
}
.navigation a {
  font-size: 13px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 7px;
  position: relative;
  white-space: nowrap;
}
.navigation a[aria-current] {
  color: var(--accent-ink, var(--lime));
}
.navigation a[aria-current]::after {
  content: "";
  height: 2px;
  background: var(--lime);
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
}
.navigation a span {
  font-size: 13px;
  opacity: 0.6;
}
.navigation .coca-nav {
  color: #ff929b;
}

#tv-toggle {
  white-space: nowrap;
  gap: 8px;
  flex-shrink: 0;
}

.header-actions {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  margin-left: auto;
  padding-block: 8px;
}
.header-actions > .button {
  justify-content: center;
  margin-left: 0;
}
.mobile-footer-actions {
  display: none;
}

.header-streak {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 4px;
  color: var(--peach);
  flex-shrink: 0;
}
.header-streak[hidden] {
  display: none;
}
.header-streak svg {
  width: 21px;
  height: 25px;
}
.header-streak strong {
  font-family: var(--font);
  font-size: 18px;
  font-variant-numeric: tabular-nums;
}
.header-me {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 10px 6px 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
}
.header-me[hidden] {
  display: none;
}
@media (hover: hover) and (pointer: fine) {
  .navigation a:hover {
    color: var(--text);
  }
}
@media (min-width: 1513px) {
  .header {
    max-width: 1428px;
  }
}
@media (max-width: 1200px) {
  .header {
    padding: 0 36px;
    gap: 20px;
    min-height: 87px;
  }
  .navigation {
    gap: 22px;
  }
  .navigation a {
    font-size: 12px;
  }
}
@media (max-width: 980px) {
  .header {
    padding: 0 27px;
    min-height: 80px;
    gap: 15px;
  }
  .navigation {
    gap: 18px;
  }
}

/* Coca-Zero: a self-contained, red-lit annex to the site. */
.navigation {
  gap: clamp(10px, 1.6vw, 24px);
}
@media (max-width: 980px) {
  .navigation a {
    font-size: 11px;
  }
  .brand {
    font-size: 15px;
    gap: 9px;
  }
  .brand-mark {
    width: 36px;
    height: 38px;
    font-size: 31px;
    border-radius: 10px;
  }
  .brand-mark > span {
    font-size: 25px;
  }
}
@media (max-width: 700px) {
  .header {
    padding: 17px 20px 0;
    flex-wrap: wrap;
    gap: 18px;
    min-height: 110px;
  }
  .brand {
    font-size: 15px;
  }
  .brand > span:last-child {
    max-width: 145px;
  }
  .brand > span:last-child b {
    display: inline;
  }
  .brand-mark {
    width: 34px;
    height: 35px;
    font-size: 29px;
    border-radius: 9px;
  }
  .brand-mark > span {
    font-size: 24px;
  }
  .navigation {
    width: 100%;
    order: 3;
    justify-content: space-between;
    gap: 12px;
    height: 39px;
    gap: 8px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    height: auto;
    gap: 0 10px;
    padding-top: 7px;
  }
  .navigation a {
    font-size: 11px;
    padding-bottom: 12px;
    justify-content: center;
    padding: 10px 0;
  }
  .navigation a span {
    font-size: 11px;
    display: none;
  }
  .header .navigation a[aria-current]::after {
    bottom: 0;
  }
  .header > .header-actions {
    display: none;
  }
  .mobile-footer-actions {
    display: flex;
    width: 100%;
    justify-content: center;
  }
  .mobile-footer-actions .header-actions {
    margin: 0;
    flex-wrap: wrap;
    flex-shrink: 1;
    max-width: 100%;
    justify-content: center;
  }
}
@media (max-width: 600px) {
  #tv-toggle {
    padding: 9px 12px;
    font-size: 11px;
  }
}
@media (max-width: 370px) {
  .header {
    padding-left: 14px;
    padding-right: 14px;
  }
  .navigation a {
    font-size: 11px;
  }
}
/* ==== Footer ==== */
.footer {
  margin-top: auto;
  margin-bottom: auto;
  border-top: 1px solid var(--line);
  padding: 25px 0 35px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  color: var(--muted);
  font-size: 11px;
}
.footer-brand {
  font-family: var(--font);
  font-size: 16px;
  letter-spacing: -0.6px;
  color: var(--text);
  font-weight: 600;
}
.footer-brand > span {
  font-size: 11px;
  vertical-align: super;
  margin-left: 3px;
}

/* A discreet, readable notice that remains visible on small screens. */
.footer > .alcohol-disclaimer {
  max-width: 360px;
  font-size: 11px;
  line-height: 1.5;
}
@media (max-width: 980px) {
  .footer p {
    display: none;
  }
}
@media (max-width: 700px) {
  .footer {
    padding: 23px 0 28px;
    gap: 10px;
    flex-wrap: wrap;
  }
  .footer-brand {
    font-size: 15px;
  }
  .footer > span {
    font-size: 11px;
  }
}
/* ==== Banners, dialogs and feedback states ==== */
.source-banner {
  margin-top: 14px;
  margin-bottom: 0;
  border: 1px solid var(--line);
  background: var(--theme-surface, #1d2518);
  border-radius: 7px;
  display: flex;
  gap: 20px;
  justify-content: space-between;
  align-items: center;
  padding: 10px 16px;
  font-size: 12px;
  color: var(--theme-muted, #c3cdb5);
  line-height: 1.5;
}
.source-banner a,
.source-banner button {
  color: var(--accent-ink, var(--lime));
  white-space: nowrap;
  background: none;
  border: none;
  font-weight: 700;
  padding: 0;
}
.source-banner b {
  font-size: 11px;
  letter-spacing: 1px;
  margin-right: 12px;
}
.error-banner {
  border-color: #775a45;
  color: #f1c39f;
  background: #2a211b;
}
.demo-banner {
  background: var(--theme-surface, #22241a);
  border-color: var(--theme-line, #414b2d);
}
.dialog-note {
  border: 1px solid var(--line);
  background: var(--theme-surface, #20271a);
  padding: 16px;
  border-radius: 8px;
  margin: 20px 0;
}
.dialog-note b {
  font-size: 12px;
}
#dialog-content > h2 {
  font-size: 37px;
  letter-spacing: -1.4px;
  line-height: 1.1;
  margin: 20px 0;
}
#dialog-content p {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.8;
}
#dialog-content > small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.7;
  margin-top: 20px;
}
.command-example {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
  background: var(--theme-inset, #11160d);
  border: 1px solid var(--line);
  border-radius: 8px;
  margin: 20px 0;
}
.command-example > code {
  font-size: 22px;
  color: var(--accent-ink, var(--lime));
}
.command-example > span {
  font-size: 11px;
  color: var(--muted);
}
.dialog-note p {
  margin-top: 5px;
}
#toast {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translate(-50%, 15px);
  background: var(--lime);
  color: var(--on-accent, #27351a);
  padding: 15px 24px;
  font-size: 12px;
  line-height: 1.5;
  font-weight: 600;
  border: 1px solid var(--theme-line, #e2ffa1);
  border-radius: 9px;
  opacity: 0;
  pointer-events: none;
  z-index: 200;
  transition:
    transform 200ms var(--ease),
    opacity 200ms ease;
  box-shadow: 0 5px 30px #0005;
  max-width: calc(100vw - 30px);
  text-align: center;
}
#toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}
.loading-state,
.error-state {
  min-height: 65vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 23px;
  padding: 60px 20px;
}
.loading-state p,
.error-state p {
  color: var(--muted);
  line-height: 1.7;
  max-width: 480px;
}
.loading-glass,
.error-state > span {
  color: var(--accent-ink, var(--lime));
  font-size: 50px;
}
.loading-state .skeleton {
  width: 200px;
  height: 5px;
  background: var(--line);
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}
.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent,
    color-mix(in srgb, var(--lime) 37.65%, transparent),
    transparent
  );
  animation: loading 1.3s ease-in-out infinite;
}
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 190px;
  padding: 20px;
  gap: 12px;
  color: var(--muted);
}
.empty-state > span {
  color: var(--accent-ink, var(--lime));
  font-size: 37px;
}
.empty-state h3 {
  font-size: 17px;
  color: var(--text);
}
.empty-state p {
  font-size: 11px;
  line-height: 1.7;
  max-width: 300px;
}
.confetti {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 300;
  overflow: hidden;
}
.confetti i {
  position: absolute;
  left: var(--x);
  top: -20px;
  width: 7px;
  height: 15px;
  background: var(--lime);
  animation: confetti 2s var(--delay) ease-in forwards;
}
.confetti i:nth-child(3n) {
  background: var(--lilac);
}
.confetti i:nth-child(3n + 1) {
  background: var(--peach);
}
@keyframes confetti {
  to {
    transform: translateY(105vh) rotate(var(--rotation));
    opacity: 0.2;
  }
}
@media (max-width: 700px) {
  .source-banner {
    font-size: 11px;
    padding: 10px 12px;
    gap: 8px;
    align-items: flex-start;
    flex-direction: column;
  }
  .source-banner b {
    font-size: 11px;
  }
  #dialog-content > h2 {
    font-size: 33px;
  }
  .error-state h1 {
    font-size: 31px;
    letter-spacing: -1px;
  }
  #toast {
    font-size: 11px;
    width: max-content;
    padding: 13px 18px;
  }
}
/* ==== Charts and tooltips ==== */
.activity-panel {
  grid-column: 1 / span 2;
}
.race-panel {
  grid-column: 1 / span 2;
}
.chart-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 0 0 23px;
  gap: 15px;
}
.chart-summary > div:first-child {
  display: flex;
  align-items: baseline;
  gap: 10px;
}
.chart-summary strong {
  font-family: var(--font);
  font-size: 30px;
  letter-spacing: -1px;
  font-weight: 600;
}
.chart-summary span {
  font-size: 11px;
  color: var(--muted);
}
.chart-ranges {
  display: flex;
  gap: 2px;
  white-space: nowrap;
}
.chart-ranges button {
  background: none;
  border: 1px solid transparent;
  padding: 5px 8px;
  border-radius: 4px;
  font-size: 11px;
  color: var(--muted);
  min-height: 29px;
}
.chart-ranges button[aria-pressed="true"] {
  color: var(--accent-ink, var(--lime));
  background: color-mix(in srgb, var(--lime) 5.1%, transparent);
  border-color: color-mix(in srgb, var(--lime) 13.33%, transparent);
}
.chart-svg {
  width: 100%;
  height: auto;
  overflow: visible;
}
.axis-label {
  font-size: 10px;
  fill: var(--theme-muted, #a0a992);
}
.grid-line {
  stroke: var(--theme-line, #353d2c);
  stroke-dasharray: 3 5;
  stroke-width: 0.6;
}
.chart-svg [data-tip] {
  cursor: crosshair;
  outline: none;
  transition: opacity 150ms ease;
}
.chart-svg [data-tip]:focus-visible {
  stroke: var(--text);
  stroke-width: 2;
  opacity: 1;
}
.chart-point {
  opacity: 0;
}
.chart-point:focus,
.chart-point:hover {
  opacity: 1;
}
.chart-tooltip {
  position: fixed;
  z-index: 100;
  pointer-events: none;
  background: var(--theme-surface, #292f22);
  border: 1px solid var(--theme-line, #525e40);
  border-radius: 9px;
  padding: 14px;
  min-width: 155px;
  max-width: 280px;
  box-shadow: 0 12px 35px #0008;
}
.chart-tooltip > small {
  font-size: 11px;
  color: var(--muted);
  display: block;
  margin-bottom: 8px;
}
.chart-tooltip > strong {
  font-family: var(--font);
  font-size: 23px;
  display: block;
  font-weight: 600;
}
.chart-tooltip > strong > span {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 400;
  color: var(--muted);
}
.chart-tooltip .identity {
  margin-bottom: 10px;
}
.chart-tooltip .identity strong {
  font-size: 12px;
}
.chart-tooltip .identity small {
  font-size: 11px;
}
.race-legend {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 17px;
}
.race-legend > a {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--user-color);
  font-size: 11px;
}
.race-controls {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.race-controls .icon-button {
  width: 27px;
  height: 27px;
  font-size: 11px;
  min-height: 27px;
}
.race-controls input {
  height: 4px;
  accent-color: var(--lime);
  width: 35%;
  min-width: 80px;
  cursor: pointer;
}
.race-controls > span {
  font-size: 11px;
  white-space: nowrap;
}
.race-controls > .muted {
  margin-left: auto;
}
.race-svg g {
  cursor: pointer;
}
.race-svg g image {
  transition: opacity 150ms ease;
}
.chart-footnote {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 11px;
  gap: 16px;
  margin-top: 17px;
  line-height: 1.6;
}
.chart-footnote > span:last-child {
  display: flex;
  align-items: center;
  gap: 7px;
}
.heat-key {
  display: inline-block;
  width: 40px;
  height: 7px;
  background: linear-gradient(90deg, var(--theme-track, #29341d), var(--lime));
  border-radius: 2px;
}
.hour-heatmap {
  display: grid;
  grid-template-columns: 25px repeat(24, minmax(0, 1fr));
  gap: 4px;
  min-width: 325px;
  align-items: center;
}
.hour-heatmap > small {
  font-size: 11px;
  color: var(--muted);
  min-height: 16px;
  display: flex;
  align-items: center;
}
.heat-cell {
  display: block;
  aspect-ratio: 1.4;
  border-radius: 2px;
  background: color-mix(
    in srgb,
    var(--lime) calc(var(--intensity) * 100%),
    var(--theme-track, #272e21)
  );
  min-height: 8px;
  cursor: crosshair;
}
.heat-cell:focus-visible,
.calendar-cell:focus-visible {
  outline-offset: 1px;
}
.heatmap-scroll {
  overflow-x: auto;
  padding: 2px;
}
.calendar-scroll {
  overflow-x: auto;
  padding: 3px;
}
.calendar {
  display: grid;
  grid-template-rows: repeat(7, 12px);
  grid-auto-columns: minmax(9px, 1fr);
  grid-auto-flow: column;
  gap: 4px;
  min-width: 690px;
}
.calendar-cell {
  background: color-mix(
    in srgb,
    var(--user-color) calc(var(--intensity) * 100%),
    var(--theme-track, #293022)
  );
  border-radius: 2px;
  cursor: crosshair;
}
.calendar-months {
  display: flex;
  justify-content: space-around;
  min-width: 690px;
  margin-bottom: 10px;
  font-size: 11px;
  color: var(--muted);
}
.contribution-layout {
  display: flex;
  align-items: center;
  gap: 25px;
  justify-content: space-evenly;
}
.donut {
  position: relative;
  width: 180px;
  flex-shrink: 0;
}
.donut-label {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  pointer-events: none;
}
.donut-label strong {
  font-family: var(--font);
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -1px;
}
.donut-label small {
  font-size: 10px;
  letter-spacing: 1.1px;
  color: var(--muted);
  margin-top: 7px;
}
.contribution-legend {
  flex: 1;
  max-width: 300px;
  min-width: 0;
}
.contribution-legend > a {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 12px 0;
  font-size: 11px;
}
.contribution-legend > a > span:not(.avatar) {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.contribution-legend b {
  margin-left: auto;
  color: var(--user-color);
  font-size: 11px;
  white-space: nowrap;
  font-weight: 500;
}
.contribution-legend b small {
  font-size: 11px;
}
.contribution-legend .others {
  display: flex;
  gap: 10px;
  font-size: 11px;
  color: var(--muted);
  margin-top: 17px;
}
.others > span {
  color: var(--theme-muted, #505747);
  font-size: 14px;
}
.contribution-legend .others b {
  color: var(--muted);
  font-size: 11px;
}
.monthly-chart {
  height: 220px;
  display: flex;
  align-items: stretch;
  gap: 14px;
  padding-top: 12px;
}
.month-column {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.month-value {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}
.month-track {
  height: 100%;
  width: 100%;
  display: flex;
  align-items: flex-end;
  border-bottom: 1px solid var(--line);
}
.month-track > div {
  background: var(--lime);
  width: 100%;
  min-height: 2px;
  border-radius: 4px 4px 0 0;
}
.month-column > small {
  font-size: 11px;
  color: var(--muted);
}
.weekday-chart {
  display: grid;
  gap: 15px;
  margin: 32px 0 12px;
}
.weekday-chart > div {
  display: flex;
  align-items: center;
  gap: 15px;
  font-size: 11px;
}
.weekday-chart > div > span {
  width: 34px;
  color: var(--muted);
}
.weekday-chart b {
  width: 40px;
  text-align: right;
  font-weight: 500;
  font-size: 11px;
}
.weekday-track {
  flex: 1;
  height: 11px;
  background: var(--theme-track, #262e20);
  border-radius: 3px;
  overflow: hidden;
}
.weekday-track i {
  display: block;
  background: var(--lime);
  height: 100%;
  transform-origin: left;
  border-radius: 3px;
}

#activity-chart [data-day] {
  cursor: pointer;
}
#activity-chart [data-day]:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 2px;
}
.calendar [data-diary-user] {
  cursor: pointer;
}
.calendar [data-diary-user]:focus-visible {
  outline: 2px solid var(--user-color);
  outline-offset: 2px;
}
@media (hover: hover) and (pointer: fine) {
  .chart-svg rect[data-tip]:hover {
    opacity: 1;
  }
  .heat-cell:hover,
  .calendar-cell:hover {
    outline: 1px solid var(--text);
    outline-offset: 1px;
  }
  .race-legend a:hover {
    color: var(--text);
  }
}
@media (max-width: 1200px) {
  .chart-summary > div:first-child {
    gap: 8px;
  }
  .chart-summary span {
    font-size: 11px;
  }
  .chart-ranges button {
    font-size: 11px;
    padding: 5px;
  }
}
@media (max-width: 980px) {
  .activity-panel {
    grid-column: 1;
  }
  .race-panel {
    grid-column: 1;
  }
  .activity-panel .panel-heading {
    flex-wrap: wrap;
    gap: 13px;
  }
  .activity-panel .panel-heading .segmented {
    margin-left: auto;
  }
  .chart-summary {
    gap: 8px;
    flex-wrap: wrap;
  }
  .chart-summary > div:first-child {
    gap: 8px;
  }
  .chart-summary strong {
    font-size: 25px;
  }
  .chart-summary span {
    font-size: 11px;
  }
  .chart-ranges {
    margin-left: auto;
  }
  .race-controls {
    gap: 8px;
  }
  .race-controls > .muted {
    display: none;
  }
  .race-controls input {
    flex: 1;
  }
  .contribution-layout {
    gap: 6px;
  }
  .donut {
    width: 125px;
  }
  .donut-label strong {
    font-size: 20px;
  }
  .donut-label small {
    font-size: 10px;
  }
  .contribution-legend > a {
    font-size: 11px;
    gap: 6px;
  }
  .contribution-legend .avatar-xs {
    width: 19px;
    height: 19px;
  }
  .contribution-legend b {
    font-size: 11px;
  }
  .contribution-legend .others {
    font-size: 11px;
    gap: 5px;
    align-items: center;
  }
  .contribution-legend .others b {
    font-size: 11px;
  }
  .chart-footnote {
    font-size: 11px;
    gap: 7px;
  }
}
@media (max-width: 700px) {
  .activity-panel {
    order: 1;
  }
  .race-panel {
    order: 2;
  }


  .activity-panel .panel-heading {
    flex-wrap: nowrap;
    gap: 9px;
  }
  .activity-panel .panel-heading h2 {
    font-size: 21px;
  }
  .activity-panel .panel-heading .eyebrow {
    font-size: 10px;
    letter-spacing: 0.7px;
  }
  .chart-summary {
    margin-bottom: 17px;
    flex-wrap: nowrap;
  }
  .chart-summary strong {
    font-size: 25px;
  }
  .chart-summary > div:first-child {
    flex-direction: column;
    gap: 5px;
  }
  .chart-summary span {
    font-size: 11px;
  }
  .chart-ranges button {
    font-size: 11px;
    padding: 6px;
  }
  .race-controls {
    gap: 12px;
  }
  .race-controls input {
    height: 6px;
  }
  .race-controls > span {
    font-size: 11px;
  }
  .race-controls .icon-button {
    width: 32px;
    height: 32px;
    font-size: 12px;
  }
  .chart-footnote {
    font-size: 11px;
  }
  .heatmap-scroll {
    margin-right: -5px;
  }
  .hour-heatmap {
    gap: 3px;
    min-width: 285px;
  }
  .hour-heatmap > small {
    font-size: 11px;
  }
  .heat-cell {
    min-height: 9px;
    aspect-ratio: 1;
  }
  .contribution-layout {
    gap: 15px;
  }
  .donut {
    width: 145px;
  }
  .donut-label strong {
    font-size: 23px;
  }
  .donut-label small {
    font-size: 10px;
  }
  .contribution-legend > a {
    font-size: 11px;
    gap: 6px;
  }
  .contribution-legend .avatar-xs {
    width: 23px;
    height: 23px;
  }
  .contribution-legend b {
    font-size: 11px;
  }
  .contribution-legend .others {
    font-size: 11px;
    gap: 6px;
    flex-wrap: wrap;
  }
  .monthly-chart {
    gap: 7px;
  }
  /* Twelve columns are too narrow for every label: name every other month. */
  .month-column > small {
    font-size: 10px;
  }
  .month-column:nth-last-child(even) > small {
    visibility: hidden;
  }
  .month-value {
    font-size: 10px;
    letter-spacing: -0.3px;
  }
  .month-column {
    gap: 8px;
  }
  .chart-tooltip {
    max-width: 240px;
    padding: 12px;
  }
  .chart-tooltip > strong {
    font-size: 21px;
  }
  .chart-tooltip .identity {
    gap: 9px;
  }
  .chart-tooltip .identity .avatar {
    width: 33px;
    height: 33px;
  }
  .chart-tooltip .identity strong {
    font-size: 11px;
  }
}
@media (max-width: 370px) {
  .donut {
    width: 125px;
  }
  .contribution-layout {
    gap: 10px;
  }
  .contribution-legend > a {
    font-size: 11px;
  }
  .contribution-legend .avatar-xs {
    width: 20px;
    height: 20px;
  }
}
/* ==== Day diary ==== */
.day-diary {
  max-width: 700px;
  max-height: 88dvh;
  overflow-y: auto;
}
.day-diary h2 {
  font-family: var(--font);
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  margin: 12px 0 24px;
}
.day-picker {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.day-summary strong {
  display: block;
  color: var(--lime);
  font-size: 2.2rem;
}
.day-summary small {
  font-size: 1rem;
}
.day-leaders {
  display: grid;
  gap: 12px;
  margin: 24px 0;
}
.day-leaders > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.day-leaders small {
  font-weight: 400;
}
.day-beers article {
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.day-beers article p {
  margin: 10px 0;
}
.day-beers article > small {
  color: var(--muted);
}
.day-pages {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 24px;
}
.day-pages button {
  padding: 10px 14px;
}
.day-pages button:disabled {
  opacity: 0.4;
  cursor: default;
}
.day-empty {
  padding: 24px 0;
}
/* ==== Home: hero and collective goal ==== */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  padding-top: 36px;
}
.hero-copy {
  z-index: 1;
  padding: 16px 0 22px;
}
.hero-eyebrow {
  font-size: 10px;
  letter-spacing: 1.3px;
  color: var(--accent-ink, var(--lime));
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(44px, 4.35vw, 67px);
  letter-spacing: -2.7px;
  line-height: 1.03;
  font-weight: 800;
  font-variation-settings: "wdth" 92;
}
.hero h1 em {
  color: var(--accent-ink, var(--lime));
}
.hero-copy > p {
  font-size: 14px;
  line-height: 1.75;
  color: var(--muted);
  margin-top: 22px;
}
.hero-total {
  display: flex;
  align-items: center;
  gap: 25px;
  margin-top: 29px;
}
.hero-total > strong {
  font-family: var(--font);
  font-size: clamp(54px, 6.9vw, 106px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -5px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.hero-total > span {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
  line-height: 1.7;
  color: var(--text);
  padding-top: 8px;
}
.hero-total > span > svg {
  width: 25px;
  height: 25px;
  color: var(--accent-ink, var(--lime));
}
.hero-total b {
  font-weight: 400;
  color: var(--muted);
}
.community-proof {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 15px;
  font-size: 11px;
  color: var(--muted);
}
.community-proof b {
  color: var(--text);
  font-weight: 400;
}
.hero-art {
  position: relative;
  min-height: 418px;
  isolation: isolate;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -32px;
  background: radial-gradient(
    ellipse at center,
    color-mix(in srgb, var(--lime) 3.53%, transparent),
    transparent 66%
  );
}
.beer-glass {
  width: 310px;
  max-width: 74%;
  transform: rotate(-12deg) translate(-16px, -2px);
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 17px 22px #06090344);
}
.orbit {
  position: absolute;
  width: 340px;
  height: 340px;
  border: 1px solid #9eaf6d16;
  border-radius: 50%;
  transform: rotate(-25deg);
  z-index: -1;
}
.orbit-two {
  width: 420px;
  height: 245px;
  transform: rotate(-28deg);
  border-color: #9eaf6d1c;
}
.art-star {
  position: absolute;
  color: var(--accent-ink, var(--lime));
  font-size: 50px;
  line-height: 1;
}
.star-one {
  top: 24px;
  left: 70px;
  transform: rotate(-14deg);
}
.star-two {
  bottom: 57px;
  left: 29px;
  font-size: 37px;
  color: var(--secondary-ink, var(--peach));
}
.art-dot {
  position: absolute;
  width: 7px;
  height: 7px;
  background: var(--lime);
  border-radius: 50%;
}
.dot-one {
  top: 90px;
  right: 58px;
}
.dot-two {
  bottom: 74px;
  right: 84px;
  width: 4px;
  height: 4px;
}
.art-sticker {
  position: absolute;
  right: 5px;
  top: 55%;
  z-index: 3;
  background: var(--lime);
  color: var(--on-accent, #273218);
  border-radius: 50%;
  height: 127px;
  width: 127px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transform: rotate(12deg);
  box-shadow: 0 0 0 5px var(--bg);
  outline: 1px dashed color-mix(in srgb, var(--lime) 46.67%, transparent);
  outline-offset: 9px;
  text-align: center;
  gap: 4px;
  padding: 8px;
  transform: rotate(6deg);
}
.art-caption {
  position: absolute;
  bottom: 2px;
  left: 36%;
  font-family: var(--font);
  font-size: 12px;
  transform: rotate(-7deg);
  color: var(--muted);
}
.art-caption > span {
  font-size: 28px;
  margin-right: 10px;
  color: var(--accent-ink, var(--lime));
}
.beer-bubbles {
  animation: bubbles 5s ease-in-out 3;
}
.goal-block {
  grid-column: 1/-1;
  border-top: 1px solid var(--line);
  margin-top: 31px;
  padding: 23px 0 27px;
}
.goal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 17px;
  gap: 15px;
}
.goal-header > span {
  font-size: 10px;
  letter-spacing: 1.2px;
  color: var(--muted);
}
.goal-header i {
  display: inline-block;
  color: var(--accent-ink, var(--lime));
  font-size: 16px;
  margin-right: 8px;
  font-style: normal;
}
.goal-header b {
  color: var(--text);
  font-weight: 500;
}
.goal-header > strong {
  font-family: var(--font);
  white-space: nowrap;
  font-size: 23px;
  color: var(--accent-ink, var(--lime));
  letter-spacing: -0.8px;
}
.goal-header > strong > span {
  font-size: 14px;
  color: var(--muted);
  font-weight: 400;
}
.goal-track {
  height: 9px;
  border-radius: 3px;
  background: repeating-linear-gradient(
    90deg,
    var(--theme-track, #293022) 0,
    var(--theme-track, #293022) calc(10% - 2px),
    var(--bg) calc(10% - 2px),
    var(--bg) 10%
  );
  overflow: hidden;
}
.goal-track > div {
  height: 100%;
  background: var(--lime);
  border-radius: 3px;
  transform-origin: left;
  transition: transform 800ms var(--ease);
  box-shadow: 0 0 20px color-mix(in srgb, var(--lime) 20%, transparent);
}
.goal-details {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--muted);
  font-size: 11px;
  padding-top: 13px;
  gap: 15px;
}
.goal-details b {
  font-weight: 500;
  color: var(--text);
  margin-left: 8px;
}
.goal-details svg {
  height: 13px;
  width: 13px;
  color: var(--accent-ink, var(--lime));
  margin-left: 3px;
}
.art-star .ui-symbol,
.record-icon .ui-symbol,
.closing-star .ui-symbol {
  width: 1em;
  height: 1em;
  vertical-align: baseline;
}
.art-sticker > strong {
  font-family: var(--font);
  font-size: 30px;
  line-height: 1;
  letter-spacing: -1px;
  white-space: nowrap;
}
.art-sticker > span {
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
}

.rewind-announcement {
  padding: clamp(24px, 4vw, 48px);
  border: 1px solid var(--lime);
  background: linear-gradient(120deg, var(--panel-light), var(--panel));
  border-radius: 20px;
  margin: 24px 0 36px;
}
.rewind-announcement > span {
  color: var(--lime);
  font-size: 12px;
  letter-spacing: 2px;
}
.rewind-announcement h2 {
  font-size: clamp(32px, 5vw, 64px);
  margin: 16px 0;
}
.rewind-announcement p {
  max-width: 700px;
  line-height: 1.7;
  margin-bottom: 24px;
}

.event-announcement {
  border: 1px solid var(--lime);
  border-radius: 18px;
  padding: clamp(22px, 4vw, 40px);
  background: var(--panel);
  margin: 24px 0;
}
.event-announcement h2 {
  font-family: var(--font);
  color: var(--lime);
  font-size: clamp(24px, 4vw, 42px);
  margin: 12px 0;
  overflow-wrap: anywhere;
}
.event-announcement p {
  color: var(--muted);
  white-space: pre-line;
  max-width: 70ch;
  overflow-wrap: anywhere;
}

.hero-copy h1,
.hero-eyebrow {
  overflow-wrap: anywhere;
}

@media (min-width: 1513px) {
  .hero h1 {
    font-size: 65px;
  }
  .hero-total > strong {
    font-size: 100px;
  }
  .hero-art {
    min-height: 450px;
  }
  .beer-glass {
    width: 330px;
  }
  .hero-copy {
    padding-top: 24px;
  }
  .hero-total {
    margin-top: 32px;
  }
  .goal-block {
    margin-top: 25px;
  }
}

@media (max-width: 1512px) {
  .hero h1 {
    font-size: clamp(43px, 4.7vw, 67px);
  }
  .hero-total > strong {
    font-size: clamp(60px, 7vw, 100px);
  }
  .hero-art {
    min-height: 390px;
  }
  .beer-glass {
    width: 290px;
  }
  .art-sticker {
    height: 112px;
    width: 112px;
    right: 0;
  }
  .orbit {
    width: 300px;
    height: 300px;
  }
  .orbit-two {
    width: 360px;
    height: 220px;
  }
  .hero-copy {
    padding-top: 0;
  }
  .hero-total {
    gap: 20px;
  }
  .hero-total > span {
    gap: 10px;
    font-size: 11px;
  }
  .hero-total > span > svg {
    width: 22px;
  }
  .art-caption {
    left: 29%;
    font-size: 11px;
  }
  .hero-eyebrow {
    font-size: 10px;
  }
  .hero-copy > p {
    font-size: 13px;
  }
  .goal-block {
    margin-top: 15px;
  }
}

@media (max-width: 1200px) {
  .hero h1 {
    font-size: 54px;
  }
  .hero-total > strong {
    font-size: 79px;
  }
  .hero-total > span {
    font-size: 11px;
    gap: 7px;
  }
  .hero-total {
    gap: 18px;
  }
  .hero-total > span > svg {
    display: none;
  }
  .hero-art {
    min-height: 375px;
  }
  .hero-copy > p {
    font-size: 12px;
  }
  .hero-art .star-one {
    left: 32px;
  }
  .hero-art .star-two {
    left: 12px;
  }
  .beer-glass {
    width: 275px;
  }
  .art-sticker {
    width: 95px;
    height: 95px;
    right: 4px;
    outline-offset: 6px;
  }
  .orbit-two {
    width: 310px;
    height: 215px;
  }
  .art-sticker > strong {
    font-size: 24px;
  }
  .art-sticker > span {
    font-size: 11px;
  }
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1.35fr 1fr;
  }
  .hero h1 {
    font-size: 46px;
    letter-spacing: -2px;
  }
  .hero-eyebrow {
    font-size: 10px;
    letter-spacing: 1px;
  }
  .hero-total > strong {
    font-size: 67px;
    letter-spacing: -3px;
  }
  .hero-total > span {
    font-size: 11px;
  }
  .hero-total {
    gap: 15px;
  }
  .hero-art {
    min-height: 333px;
  }
  .beer-glass {
    width: 240px;
    max-width: 80%;
  }
  .orbit {
    width: 235px;
    height: 235px;
  }
  .orbit-two {
    width: 260px;
    height: 185px;
  }
  .hero-art .star-one {
    left: 8px;
    top: 13px;
    font-size: 36px;
  }
  .hero-art .star-two {
    font-size: 29px;
    left: 0;
  }
  .art-sticker {
    right: 0;
    width: 83px;
    height: 83px;
  }
  .art-caption {
    font-size: 9px;
    left: 24%;
    bottom: -4px;
  }
  .art-caption > span {
    font-size: 23px;
    margin-right: 5px;
  }
  .community-proof {
    font-size: 11px;
  }
  .hero-copy > p {
    font-size: 11px;
  }
}

@media (max-width: 700px) {
  .hero {
    padding-top: 27px;
    grid-template-columns: 1fr;
    overflow: hidden;
  }
  .hero-copy {
    padding: 0;
  }
  .hero-eyebrow {
    font-size: 10px;
    letter-spacing: 0.9px;
    margin-bottom: 19px;
  }
  .hero h1 {
    font-size: clamp(37px, 8.8vw, 59px);
    line-height: 1.06;
    letter-spacing: -1.8px;
    position: relative;
    z-index: 3;
    max-width: 95%;
  }
  .hero-copy > p {
    font-size: 11px;
    line-height: 1.7;
    margin-top: 18px;
  }
  /* The glass shares the copy's grid cell, anchored beside the total, so it
     never covers the intro text whatever its length. */
  .hero-copy {
    grid-row: 1;
    grid-column: 1;
  }
  .hero-art {
    position: relative;
    grid-row: 1;
    grid-column: 1;
    align-self: end;
    justify-self: end;
    width: 150px;
    height: 176px;
    min-height: 0;
    top: auto;
    right: auto;
    margin: 0 -10px 0 0;
    opacity: 0.94;
    z-index: 0;
    pointer-events: none;
  }
  .goal-block {
    grid-row: 2;
  }
  .beer-glass {
    width: 124px;
    max-width: none;
    transform: rotate(-12deg) translate(-5px, -3px);
  }
  .orbit {
    width: 165px;
    height: 165px;
  }
  .orbit-two {
    width: 185px;
    height: 116px;
  }
  .hero-art .star-one {
    font-size: 25px;
    left: 20px;
    top: 6px;
  }
  .hero-art .star-two {
    font-size: 20px;
    left: 10px;
    bottom: 12px;
  }
  .art-sticker {
    width: 64px;
    height: 64px;
    right: 12px;
    top: 58%;
    outline-offset: 4px;
    box-shadow: 0 0 0 3px var(--bg);
    gap: 3px;
  }
  .art-caption {
    display: none;
  }
  .art-dot {
    display: none;
  }
  .hero-total {
    margin-top: 33px;
    gap: 10px;
    flex-direction: column;
    align-items: flex-start;
    position: relative;
    z-index: 3;
    width: calc(100% - 110px);
  }
  .hero-total > strong {
    font-size: clamp(52px, 12.5vw, 84px);
    letter-spacing: -3px;
  }
  .hero-total > span {
    font-size: 11px;
    padding: 0;
    line-height: 1.7;
    gap: 7px;
  }
  .hero-total > span > svg {
    display: block;
    width: 17px;
    height: 17px;
  }
  .hero-total > span > span > br {
    display: none;
  }
  .hero-total > span b {
    display: none;
  }
  .community-proof {
    font-size: 11px;
    margin-top: 21px;
    gap: 9px;
    position: relative;
    z-index: 3;
    /* Leave the glass and its sticker their corner. */
    max-width: calc(100% - 118px);
  }
  .community-proof .avatar-sm {
    width: 26px;
    height: 26px;
    border-width: 2px;
  }
  .goal-block {
    margin-top: 26px;
    padding-top: 18px;
    padding-bottom: 23px;
    z-index: 2;
    position: relative;
  }
  .goal-header {
    margin-bottom: 12px;
    gap: 10px;
  }
  .goal-header > span {
    font-size: 10px;
    letter-spacing: 0.65px;
  }
  .goal-header i {
    font-size: 12px;
    margin-right: 3px;
  }
  .goal-header b {
    font-size: 10px;
  }
  .goal-header > strong {
    font-size: 18px;
    letter-spacing: -0.5px;
  }
  .goal-header > strong > span {
    font-size: 10px;
  }
  .goal-track {
    height: 7px;
  }
  .goal-details {
    font-size: 11px;
    gap: 10px;
    padding-top: 11px;
  }
  .goal-details > span:last-child {
    font-size: 0;
  }
  .goal-details b {
    font-size: 11px;
    white-space: nowrap;
  }
  .hero-art .art-star {
    display: none;
  }
  .art-sticker > strong {
    font-size: 19px;
    letter-spacing: -0.5px;
  }
  .art-sticker > span {
    font-size: 10px;
  }
}

@media (max-width: 370px) {
  .hero h1 {
    font-size: 37px;
  }
  .hero-art {
    width: 130px;
    height: 156px;
    margin-right: -6px;
  }
  .beer-glass {
    width: 108px;
  }
  .hero-total > strong {
    font-size: 52px;
  }
  .hero-eyebrow {
    font-size: 10px;
  }
  .hero-total {
    width: calc(100% - 105px);
  }
  .goal-header > span {
    font-size: 10px;
  }
  .goal-header b {
    font-size: 10px;
  }
  .goal-header > strong {
    font-size: 16px;
  }
  .goal-details {
    font-size: 11px;
  }
  .hero-copy > p {
    font-size: 11px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .beer-bubbles {
    transform: none;
  }
}

/* ==== Home: dashboard grid, feed and records ==== */
.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 0.95fr);
  gap: 20px;
  align-items: start;
}
.feed-panel {
  grid-column: 1 / -1;
  grid-row: auto;
}
.dashboard-grid > .feed-panel .feed-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr));
  column-gap: 32px;
}
.feed-item {
  display: flex;
  gap: 13px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}
.feed-item:first-child {
  padding-top: 0;
}
.feed-item:last-child {
  border: 0;
}
.feed-item > .avatar {
  width: 35px;
  height: 35px;
  border-radius: 10px;
}
.feed-item > div {
  min-width: 0;
  flex: 1;
}
.feed-item > div > div {
  display: flex;
  gap: 8px;
  align-items: baseline;
  justify-content: space-between;
}
.feed-item strong {
  font-size: 11px;
  overflow-wrap: anywhere;
}
.feed-item time {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}
.feed-item p {
  font-size: 11px;
  color: var(--theme-muted, #afb6a4);
  margin-top: 8px;
  line-height: 1.65;
  overflow-wrap: anywhere;
}
.feed-beer {
  font-size: 11px;
  color: var(--accent-ink, var(--lime));
  display: inline-flex;
  gap: 5px;
  align-items: center;
  background: color-mix(in srgb, var(--lime) 3.14%, transparent);
  padding: 5px 7px;
  border-radius: 4px;
  margin-top: 8px;
}
.feed-beer svg {
  width: 11px;
  height: 11px;
}
.feed-note {
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
  padding-top: 15px;
  border-top: 1px solid var(--line);
  margin-top: 8px;
}
.record-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.record-card {
  padding: 25px 26px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--panel);
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 240px;
}
.record-card .eyebrow {
  font-size: 10px;
  letter-spacing: 1.3px;
}
.record-icon {
  position: absolute;
  right: 24px;
  top: 49px;
  font-size: 39px;
  font-family: var(--font);
  line-height: 1;
}
.record-card > strong {
  font-family: var(--font);
  font-size: 57px;
  line-height: 1;
  margin: 22px 0 12px;
  letter-spacing: -2px;
  font-weight: 600;
}
.record-card > strong > small {
  font-size: 19px;
  letter-spacing: -0.5px;
  font-weight: 400;
}
.record-card h3 {
  font-size: 16px;
  letter-spacing: -0.3px;
  font-weight: 600;
  margin-bottom: 10px;
}
.record-card p {
  font-size: 11px;
  line-height: 1.8;
  color: var(--muted);
  max-width: 290px;
}
.record-bottom {
  font-size: 11px;
  color: var(--muted);
  display: block;
  margin-top: auto;
  padding-top: 20px;
}
.record-lime {
  background: var(--lime);
  color: var(--on-accent, #253316);
  border-color: var(--lime);
}
.record-lime .eyebrow,
.record-lime p,
.record-lime .record-bottom {
  color: var(--on-accent, #4d6035);
}
.record-lime .record-icon {
  color: var(--on-accent, #405624);
}
.record-owner {
  margin-top: auto;
  padding-top: 5px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.record-owner > small {
  font-size: 11px;
  color: var(--muted);
}
.closing-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  background: var(--theme-surface, #20281a);
  border: 1px solid var(--theme-line, #38452b);
  border-radius: 12px;
  margin-top: 42px;
  padding: 37px 39px;
  gap: 30px;
}
.closing-banner h2 {
  font-size: 29px;
  line-height: 1.15;
  letter-spacing: -1px;
  font-weight: 600;
}
.closing-banner > .button {
  position: relative;
  z-index: 1;
}
.closing-star {
  position: absolute;
  left: 64%;
  top: -37px;
  transform: rotate(9deg);
  font-size: 200px;
  color: color-mix(in srgb, var(--lime) 2.75%, transparent);
  line-height: 1;
}

/* A podium-only homepage panel needs one row, not the full ranking's two. */
.dashboard-grid.compact-pantheon > .leaderboard-panel {
  align-self: start;
}
.dashboard-grid.compact-pantheon > .leaderboard-panel .podium {
  margin-top: 16px;
  min-height: 0;
}
.see-more {
  margin: 18px 0 0;
  text-align: center;
}
.see-more .text-link {
  white-space: normal;
}

/* "Ta place": the visitor's own rank, or the picker to choose a profile. */
.me-card {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 18px 32px;
  margin: 0 0 30px;
  padding: 22px 26px;
  border: 1px solid color-mix(in srgb, var(--user-color, var(--lime)) 35%, var(--line));
  border-radius: 12px;
  background:
    radial-gradient(ellipse at left, color-mix(in srgb, var(--user-color, var(--lime)) 10%, transparent), transparent 70%),
    var(--panel);
}
.me-card-identity {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}
.me-card-identity h2 {
  font-family: var(--font);
  font-size: 24px;
  letter-spacing: -0.6px;
  margin: 4px 0 2px;
  overflow-wrap: anywhere;
}
.me-card-identity small {
  color: var(--muted);
  font-size: 12px;
}
.me-card-stats {
  display: flex;
  gap: 24px;
  margin: 0;
}
.me-card-stats dt {
  color: var(--muted);
  font-size: 11px;
}
.me-card-stats dd {
  margin: 4px 0 0;
  font-family: var(--font);
  font-size: 26px;
  color: var(--accent-ink, var(--lime));
}
.me-card-chase {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
}
.me-card-chase .identity {
  display: inline-flex;
  vertical-align: middle;
}
.me-card-actions {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.me-hint {
  grid-template-columns: minmax(0, 1fr) auto;
}
.me-hint p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.me-picker {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
}
.me-picker select {
  max-width: 260px;
}
@media (min-width: 701px) {
  .dashboard-grid.compact-pantheon > .leaderboard-panel {
    grid-row: 1;
  }
  /* With a podium only, the feed fills the space under it instead. */
  .dashboard-grid.compact-pantheon > .feed-panel {
    grid-column: -2;
    grid-row: 2;
    align-self: start;
  }
  .dashboard-grid.compact-pantheon > .feed-panel .feed-list {
    display: block;
  }
}
@media (max-width: 1512px) {
  .record-icon {
    right: 22px;
  }
}
@media (max-width: 1200px) {
  .dashboard-grid {
    gap: 17px;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.08fr);
  }
  .feed-item {
    gap: 9px;
  }
  .feed-item > .avatar {
    width: 29px;
    height: 29px;
    border-radius: 8px;
  }
  .feed-item strong {
    font-size: 11px;
  }
  .feed-item time {
    font-size: 11px;
  }
  .feed-item p {
    font-size: 11px;
  }
  .record-card {
    padding: 23px;
  }
  .record-card h3 {
    font-size: 14px;
  }
  .record-card .eyebrow {
    font-size: 10px;
  }
  .record-card > strong {
    font-size: 48px;
  }
  .record-icon {
    font-size: 32px;
    right: 20px;
  }
  .record-card p {
    font-size: 11px;
  }
  .record-owner .identity strong {
    font-size: 11px;
  }
  .record-owner .identity small {
    font-size: 11px;
  }
  .record-owner {
    gap: 6px;
  }
  .record-owner > small {
    font-size: 11px;
  }
  .closing-banner h2 {
    font-size: 26px;
  }
}
@media (min-width: 701px) and (max-width: 1200px) {
  .feed-panel {
    padding: 21px 17px;
  }
}
@media (max-width: 980px) {
  .dashboard-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
  .feed-panel {
    grid-column: 1 / -1;
    grid-row: auto;
  }
  .dashboard-grid .chart-svg {
    min-height: 135px;
  }
  .dashboard-grid .chart-svg text {
    font-size: 14px;
  }
  .dashboard-grid .race-legend {
    gap: 8px;
  }
  .dashboard-grid .race-legend > a {
    font-size: 11px;
  }
  .dashboard-grid .race-legend .avatar-xs {
    width: 19px;
    height: 19px;
  }
  .feed-item > .avatar {
    width: 36px;
    height: 36px;
  }
  .feed-item strong {
    font-size: 11px;
  }
  .feed-item time {
    font-size: 11px;
  }
  .feed-item p {
    font-size: 11px;
  }
  .record-grid {
    gap: 13px;
  }
  .record-card {
    padding: 21px 18px;
    min-height: 230px;
  }
  .record-card > strong {
    font-size: 43px;
  }
  .record-card h3 {
    font-size: 14px;
    line-height: 1.25;
  }
  .record-icon {
    font-size: 29px;
    right: 17px;
    top: 50px;
  }
  .record-card > strong > small {
    font-size: 15px;
  }
  .record-owner > .identity {
    gap: 6px;
  }
  .record-owner > small {
    display: none;
  }
  .record-bottom {
    font-size: 11px;
  }
  .closing-banner {
    padding: 29px;
    gap: 20px;
  }
  .closing-banner h2 {
    font-size: 23px;
  }
  .closing-banner .button {
    font-size: 11px;
    padding: 12px 17px;
  }
}
@media (max-width: 700px) {
  .dashboard-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 15px;
  }
  .dashboard-grid > .panel {
    grid-column: 1;
    grid-row: auto;
  }
  .feed-panel {
    order: 5;
  }
  .dashboard-grid .chart-svg {
    min-height: 140px;
  }
  .dashboard-grid .chart-svg text {
    font-size: 15px;
  }
  .dashboard-grid .race-legend {
    gap: 10px;
    margin-bottom: 20px;
  }
  .dashboard-grid .race-legend > a {
    font-size: 11px;
  }
  .dashboard-grid .race-legend .avatar-xs {
    width: 23px;
    height: 23px;
  }
  .feed-item {
    padding: 19px 0;
    gap: 13px;
  }
  .feed-item > .avatar {
    width: 37px;
    height: 37px;
    border-radius: 11px;
  }
  .feed-item strong {
    font-size: 12px;
  }
  .feed-item time {
    font-size: 11px;
  }
  .feed-item p {
    font-size: 11px;
  }
  .feed-beer {
    font-size: 11px;
  }
  .feed-note {
    font-size: 11px;
  }
  .record-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .record-card {
    padding: 24px;
    min-height: 227px;
  }
  .record-card .eyebrow {
    font-size: 10px;
  }
  .record-card > strong {
    font-size: 58px;
    margin-top: 20px;
  }
  .record-card > strong > small {
    font-size: 20px;
  }
  .record-card h3 {
    font-size: 18px;
  }
  .record-card p {
    font-size: 11px;
  }
  .record-icon {
    font-size: 42px;
    right: 28px;
    top: 47px;
  }
  .record-bottom {
    font-size: 11px;
    padding-top: 18px;
  }
  .record-owner {
    margin-top: 7px;
  }
  .record-owner > .identity {
    gap: 10px;
  }
  .record-owner .identity strong {
    font-size: 12px;
  }
  .record-owner .identity small {
    font-size: 11px;
  }
  .record-owner > small {
    display: block;
    font-size: 11px;
  }
  .closing-banner {
    padding: 25px;
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
    margin-top: 26px;
  }
  .closing-banner h2 {
    font-size: 25px;
    line-height: 1.12;
  }
  .closing-banner .button {
    font-size: 11px;
    min-height: 43px;
  }
  .closing-star {
    left: auto;
    right: -28px;
    top: 70px;
    font-size: 190px;
  }
}
@media (max-width: 980px) {
  .me-card {
    grid-template-columns: minmax(0, 1fr) auto;
  }
  .me-card-chase {
    grid-column: 1 / -1;
  }
}
@media (max-width: 700px) {
  .me-card,
  .me-hint {
    grid-template-columns: minmax(0, 1fr);
    padding: 18px;
  }
  .me-card-stats {
    justify-content: space-between;
  }
  .me-picker {
    min-width: 0;
  }
  .me-picker select {
    flex: 1;
  }
}

/* ==== Classement ==== */
.leaderboard-panel {
  grid-column: 3;
  grid-row: 1 / span 2;
  align-self: stretch;
  display: flex;
  flex-direction: column;
}
.podium {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 6px;
  margin: 30px 0 20px;
  padding: 0 2px;
  min-height: 252px;
}
.podium-person {
  width: 33.33%;
  min-width: 0;
  display: flex;
  align-items: center;
  flex-direction: column;
  position: relative;
  text-align: center;
}
.podium-avatar {
  position: relative;
  margin-bottom: 14px;
}
.podium-avatar > .avatar {
  box-shadow:
    0 0 0 4px var(--panel),
    0 0 0 5px color-mix(in srgb, var(--user-color) 40%, transparent),
    0 0 25px color-mix(in srgb, var(--user-color) 10%, transparent);
}
.medal {
  display: grid;
  place-items: center;
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 3px solid var(--panel);
  font-size: 11px;
  font-weight: 700;
  background: var(--user-color);
  color: #19210f;
  z-index: 3;
}
.crown {
  position: absolute;
  left: 50%;
  top: -38px;
  transform: translateX(-50%) rotate(-8deg);
  font-size: 31px;
  color: var(--accent-ink, var(--lime));
  z-index: 3;
}
.podium-person > strong {
  font-family: var(--font);
  font-size: 12px;
  letter-spacing: -0.3px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.podium-person > small {
  font-size: 11px;
  color: var(--muted);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-top: 4px;
}
.podium-person > b {
  font-family: var(--font);
  color: var(--user-color);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.6px;
  margin-top: 12px;
}
.podium-person > b svg {
  width: 13px;
  height: 13px;
  margin-left: 2px;
}
.podium-title {
  font-size: 10px;
  color: var(--muted);
  margin-top: 6px;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.podium-plinth {
  width: 100%;
  height: 48px;
  background: linear-gradient(
    180deg,
    color-mix(in srgb, var(--user-color) 8%, var(--panel)),
    transparent
  );
  border-top: 1px solid color-mix(in srgb, var(--user-color) 30%, var(--panel));
  border-radius: 6px 6px 0 0;
  margin-top: 14px;
  font-family: var(--font);
  font-size: 32px;
  color: color-mix(in srgb, var(--user-color) 25%, var(--panel));
  padding-top: 4px;
}
.podium-1 .podium-plinth {
  height: 70px;
}
.podium-3 .podium-plinth {
  height: 35px;
}
.leaderboard-table {
  position: relative;
}
.leaderboard-row {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 35px 64px;
  align-items: center;
  gap: 13px;
  min-height: 76px;
  border-bottom: 1px solid var(--line);
  position: relative;
  padding: 12px 0;
}
.leaderboard-row:last-child {
  border: 0;
}
.rank-number {
  font-family: var(--font);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}
.rank-change {
  font-size: 11px;
  text-align: center;
  color: var(--theme-muted, #737e64);
  white-space: nowrap;
}
.rank-change.up {
  color: var(--accent-ink, var(--lime));
}
.rank-change.down {
  color: var(--secondary-ink, var(--peach));
}
.beer-count {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  font-family: var(--font);
  font-size: 16px;
  white-space: nowrap;
  font-weight: 600;
}
.beer-count small {
  font-size: 11px;
  color: var(--muted);
  font-family: var(--font-body);
  font-weight: 400;
}
.beer-count svg {
  color: var(--theme-muted, #9ca78b);
  width: 15px;
  height: 15px;
}
.row-link {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 6px;
}
.compact .leaderboard-row {
  grid-template-columns: 16px minmax(0, 1fr) 25px 52px;
  gap: 9px;
  min-height: 65px;
  padding: 14px 0;
}
.compact .identity {
  gap: 8px;
}
.compact .identity strong {
  font-size: 11px;
}
.compact .identity small {
  font-size: 11px;
  max-width: 110px;
}
.compact .beer-count {
  font-size: 13px;
  gap: 5px;
}
.compact .beer-count svg {
  width: 12px;
  height: 12px;
}
.compact .rank-number {
  font-size: 11px;
}
.compact .rank-change {
  font-size: 11px;
}
.leaderboard-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 23px;
}
.period-tabs {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}
.period-tabs button {
  border: 1px solid transparent;
  background: transparent;
  border-radius: 6px;
  padding: 9px 13px;
  color: var(--muted);
  font-size: 11px;
  min-height: 38px;
}
.period-tabs button[aria-pressed="true"] {
  color: var(--accent-ink, var(--lime));
  border-color: var(--theme-line, #45532f);
  background: var(--theme-surface, #2e3823);
}
.search-field {
  background: var(--theme-inset, #13170f);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 13px;
  border-radius: 7px;
  color: var(--muted);
  min-width: 200px;
}
.search-field > span {
  font-size: 23px;
  line-height: 1;
}
.search-field input {
  width: 170px;
  border: 0;
  outline: none;
  background: none;
  color: var(--text);
  font-size: 11px;
  min-height: 22px;
}
.search-field:focus-within {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
}
.search-field kbd {
  padding: 2px 5px;
  font-size: 11px;
  border: 1px solid var(--line);
  border-radius: 3px;
}
.leaderboard-subbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 15px 0 25px;
  color: var(--muted);
  font-size: 11px;
}
.leaderboard-subbar > label {
  display: flex;
  gap: 10px;
  align-items: center;
}
.leaderboard-subbar select {
  background: var(--panel-light);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 8px;
  font-size: 11px;
  max-width: 200px;
}
.leaderboard-table-header {
  display: grid;
  grid-template-columns: 45px minmax(0, 1fr) 75px 110px;
  gap: 20px;
  padding: 14px 10px;
  font-size: 10px;
  letter-spacing: 1px;
  color: var(--muted);
  border-block: 1px solid var(--line);
}
.leaderboard-table-header > span:nth-last-child(-n + 2) {
  text-align: right;
}
.full-leaderboard .leaderboard-row {
  grid-template-columns: 45px minmax(0, 1fr) 75px 110px;
  padding: 16px 10px;
  gap: 20px;
  min-height: 83px;
}
.full-leaderboard .identity strong {
  font-size: 14px;
}
.full-leaderboard .identity small {
  font-size: 11px;
}
.full-leaderboard .rank-number {
  font-size: 15px;
}
.full-leaderboard .rank-change {
  text-align: right;
}
.full-leaderboard .top-rank .rank-number {
  color: var(--user-color);
}
.full-leaderboard .beer-count {
  font-size: 22px;
}
.pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  color: var(--muted);
}
.pagination > div {
  display: flex;
  gap: 8px;
}
#leaderboard-podium {
  max-width: 750px;
  margin: 0 auto 25px;
}
#leaderboard-podium:empty {
  display: none;
}
#leaderboard-podium .podium {
  margin-top: 30px;
}
#leaderboard-podium .podium-person {
  padding: 0 12px;
}
#leaderboard-podium .avatar-lg {
  width: 80px;
  height: 80px;
}
#leaderboard-podium .avatar-xl {
  width: 100px;
  height: 100px;
}
#leaderboard-podium .podium-person > strong {
  font-size: 20px;
}
#leaderboard-podium .podium-person > small {
  font-size: 11px;
}
#leaderboard-podium .podium-person > b {
  font-size: 27px;
}
#leaderboard-podium .podium-title {
  font-size: 10px;
}
#leaderboard-podium .podium-plinth {
  height: 60px;
  font-size: 45px;
}
#leaderboard-podium .podium-1 .podium-plinth {
  height: 90px;
}
#leaderboard-podium .podium-3 .podium-plinth {
  height: 40px;
}

/* The ranking is the landing experience; the collective story follows it. */
.leaderboard-heading {
  padding: 32px 0 26px;
}
.leaderboard-heading .eyebrow {
  margin-bottom: 12px;
}
.leaderboard-heading h1 {
  font-size: clamp(32px, 3.6vw, 52px);
  letter-spacing: -1.8px;
}
.leaderboard-heading p {
  margin-top: 12px;
  font-size: 13px;
}
.leaderboard-stage {
  display: grid;
  grid-template-columns: minmax(300px, 0.8fr) minmax(0, 1.7fr);
  align-items: start;
  gap: 24px;
}
.podium-panel {
  padding: 28px 20px 22px;
  background:
    radial-gradient(
      ellipse at top,
      color-mix(in srgb, var(--lime) 3.92%, transparent),
      transparent 70%
    ),
    var(--panel);
}
.podium-panel .panel-heading {
  margin-bottom: 14px;
}
.podium-panel #leaderboard-podium {
  margin: 48px 0 0;
}
.podium-panel #leaderboard-podium .podium {
  margin: 0;
  min-height: 260px;
}
.podium-panel #leaderboard-podium .podium-person {
  padding: 0 4px;
}
.podium-panel #leaderboard-podium .avatar-lg {
  width: 62px;
  height: 62px;
}
.podium-panel #leaderboard-podium .avatar-xl {
  width: 82px;
  height: 82px;
}
.podium-panel #leaderboard-podium .podium-person > strong {
  font-size: 14px;
}
.podium-panel #leaderboard-podium .podium-person > small {
  font-size: 11px;
}
.podium-panel #leaderboard-podium .podium-person > b {
  font-size: 23px;
}
.podium-panel #leaderboard-podium .podium-title {
  font-size: 10px;
}
.podium-note {
  border-top: 1px solid var(--line);
  padding-top: 19px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.8;
}
.leaderboard-stage .full-leaderboard {
  padding: 22px;
  border-color: var(--theme-line, #485533);
}
.leaderboard-stage .leaderboard-toolbar {
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 12px;
}
/* The tabs keep their natural width; the search takes what is left, or wraps below. */
.leaderboard-stage .period-tabs {
  flex: 0 1 auto;
  flex-wrap: nowrap;
}
.leaderboard-stage .period-tabs button {
  padding: 8px 10px;
  white-space: nowrap;
}
.leaderboard-stage .search-field {
  flex: 1 1 220px;
}
.leaderboard-stage .search-field input {
  width: 100%;
}
.leaderboard-stage .leaderboard-subbar {
  padding: 8px 0 18px;
}
.leaderboard-stage .leaderboard-table-header,
.leaderboard-stage .leaderboard-row {
  grid-template-columns: 35px minmax(0, 1fr) 60px 90px;
  gap: 15px;
}
.leaderboard-goal {
  margin-top: 32px;
  padding: 25px 28px;
  background: var(--theme-surface, #20281a);
  border: 1px solid var(--theme-line, #38452b);
  border-radius: 12px;
}
.collective-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
}
.collective-summary h2 {
  font-size: 32px;
  letter-spacing: -1px;
}
.collective-summary h2 strong {
  color: var(--accent-ink, var(--lime));
}
.collective-summary h2 > span {
  font-size: 17px;
  color: var(--muted);
  font-weight: 400;
  letter-spacing: -0.4px;
}
.leaderboard-goal .goal-details b {
  color: var(--accent-ink, var(--lime));
  white-space: nowrap;
}

/* Keep the current community streak in the homepage's opening view. */
.leaderboard-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.leaderboard-intro {
  min-width: 0;
}
.leaderboard-intro > .eyebrow {
  color: var(--accent-ink, var(--lime));
}
/* "C'est moi": the visitor's own row and podium place. */
.leaderboard-row.is-me {
  background: color-mix(in srgb, var(--user-color) 9%, transparent);
  box-shadow: inset 3px 0 0 var(--user-color);
}
.podium-person.is-me > strong::after {
  content: " · toi";
  color: var(--user-color);
  font-weight: 500;
}
@media (hover: hover) and (pointer: fine) {
  .leaderboard-row:hover {
    background: #ffffff03;
  }
  .podium-person:hover .avatar {
    transform: translateY(-3px);
  }
  .podium-person .avatar {
    transition: transform 180ms var(--ease);
  }
  .period-tabs button:hover {
    color: var(--text);
  }
}
@media (min-width: 1201px) {
  .leaderboard-panel {
    padding: 24px 20px 0;
  }
  .full-leaderboard {
    padding: 24px 30px;
  }
}
@media (max-width: 1512px) {
  .leaderboard-panel .panel-heading {
    gap: 8px;
  }
  .leaderboard-panel .panel-heading .tag {
    font-size: 10px;
    padding: 5px;
  }
  .podium-title {
    font-size: 10px;
  }
}
@media (max-width: 1200px) {
  .leaderboard-panel {
    padding: 21px 15px 0;
  }
  .leaderboard-panel .tag {
    display: none;
  }
  .podium {
    gap: 5px;
    padding: 0;
  }
  .podium .avatar-lg {
    width: 46px;
    height: 46px;
  }
  .podium .avatar-xl {
    width: 61px;
    height: 61px;
  }
  .podium-person > strong {
    font-size: 11px;
  }
  .podium-person > small {
    font-size: 11px;
  }
  .podium-person > b {
    font-size: 16px;
  }
  .podium-title {
    font-size: 10px;
  }
  .compact .leaderboard-row {
    grid-template-columns: 14px minmax(0, 1fr) 20px 49px;
    gap: 7px;
  }
  .compact .identity strong {
    font-size: 11px;
  }
  .compact .identity small {
    font-size: 11px;
  }
  .compact .avatar-sm {
    width: 27px;
    height: 27px;
    border-radius: 7px;
  }
  .compact .beer-count {
    font-size: 12px;
  }
  .compact .rank-change {
    font-size: 11px;
  }
}
@media (max-width: 1100px) {
  .leaderboard-stage {
    grid-template-columns: minmax(260px, 0.8fr) minmax(0, 1.4fr);
    gap: 17px;
  }
  .leaderboard-stage .leaderboard-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  .leaderboard-stage .search-field {
    margin: 0;
    flex: none;
  }
  /* Two tabs per row on phones, one row as soon as they fit. */
  .leaderboard-stage .period-tabs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
    gap: 4px;
  }
  .leaderboard-stage .period-tabs button {
    font-size: 11px;
    padding: 7px;
  }
  .leaderboard-stage .leaderboard-subbar > label {
    font-size: 0;
    gap: 0;
  }
  .podium-panel {
    padding: 22px 14px;
  }
  .podium-panel #leaderboard-podium .podium-person > strong {
    font-size: 11px;
  }
  .podium-panel #leaderboard-podium .podium-title {
    font-size: 10px;
  }
  .podium-panel #leaderboard-podium .avatar-lg {
    width: 51px;
    height: 51px;
  }
  .podium-panel #leaderboard-podium .avatar-xl {
    width: 68px;
    height: 68px;
  }
}
@media (max-width: 980px) {
  .leaderboard-panel {
    grid-column: 2;
    grid-row: 1 / span 2;
    padding-left: 20px;
    padding-right: 20px;
  }
  .leaderboard-panel .podium {
    margin-top: 45px;
    margin-bottom: 15px;
  }
  .podium .avatar-lg {
    width: 55px;
    height: 55px;
  }
  .podium .avatar-xl {
    width: 73px;
    height: 73px;
  }
  .podium-person > strong {
    font-size: 12px;
  }
  .podium-person > small {
    font-size: 11px;
  }
  .podium-title {
    font-size: 10px;
  }
  .podium-person > b {
    font-size: 20px;
  }
  .compact .identity strong {
    font-size: 11px;
  }
  .compact .identity small {
    font-size: 11px;
  }
  .compact .avatar-sm {
    width: 33px;
    height: 33px;
  }
  .compact .beer-count {
    font-size: 15px;
  }
  .compact .leaderboard-row {
    grid-template-columns: 16px minmax(0, 1fr) 20px 60px;
    min-height: 73px;
    gap: 9px;
  }
  .compact .rank-number {
    font-size: 11px;
  }
  .compact .rank-change {
    font-size: 11px;
  }
  .leaderboard-toolbar {
    flex-wrap: wrap;
  }
  .search-field {
    margin-left: auto;
  }
  .compact .leaderboard-row:nth-child(n + 5) {
    display: none;
  }
  .leaderboard-heading {
    flex-wrap: wrap;
    gap: 16px;
  }
}
@media (max-width: 760px) {
  .leaderboard-heading {
    padding: 25px 0 20px;
  }
  .leaderboard-heading .eyebrow {
    font-size: 10px;
    margin-bottom: 10px;
  }
  .leaderboard-heading h1 {
    font-size: 32px;
    letter-spacing: -1.4px;
  }
  .leaderboard-heading p {
    font-size: 11px;
    line-height: 1.6;
    margin-top: 10px;
  }
  .leaderboard-stage {
    grid-template-columns: minmax(0, 1fr);
    gap: 15px;
  }
  .podium-panel {
    padding: 15px 14px 0;
  }
  .podium-panel .panel-heading,
  .podium-note {
    display: none;
  }
  .podium-panel #leaderboard-podium {
    margin: 28px 0 0;
  }
  .podium-panel #leaderboard-podium .podium {
    min-height: 195px;
  }
  .podium-panel #leaderboard-podium .podium-1 .podium-plinth {
    height: 45px;
  }
  .podium-panel #leaderboard-podium .podium-3 .podium-plinth {
    height: 20px;
  }
  .podium-panel #leaderboard-podium .podium-person > strong {
    font-size: 12px;
  }
  .podium-panel #leaderboard-podium .podium-person > b {
    font-size: 20px;
    margin-top: 8px;
  }
  .leaderboard-stage .full-leaderboard {
    padding: 16px 14px;
  }
  .leaderboard-stage .period-tabs button {
    min-height: 34px;
    font-size: 11px;
    padding: 7px;
  }
  .leaderboard-stage .leaderboard-toolbar {
    gap: 10px;
    margin-bottom: 10px;
  }
  .leaderboard-stage .leaderboard-subbar {
    padding-bottom: 12px;
  }
  .leaderboard-goal {
    padding: 21px;
  }
  .collective-summary {
    flex-wrap: wrap;
    gap: 15px;
  }
  .collective-summary h2 {
    font-size: 30px;
  }
  .collective-summary h2 > span {
    font-size: 13px;
  }
}
@media (max-width: 700px) {
  .leaderboard-panel {
    order: 0;
    padding: 22px 20px 0;
  }
  .leaderboard-panel .tag {
    display: block;
    font-size: 10px;
  }
  .leaderboard-panel .podium {
    margin-top: 45px;
  }
  .podium .avatar-lg {
    width: 63px;
    height: 63px;
  }
  .podium .avatar-xl {
    width: 81px;
    height: 81px;
  }
  .podium-person > strong {
    font-size: 13px;
  }
  .podium-person > small {
    font-size: 11px;
  }
  .podium-person > b {
    font-size: 21px;
  }
  .podium-title {
    font-size: 10px;
  }
  .compact .leaderboard-row {
    min-height: 69px;
    grid-template-columns: 20px minmax(0, 1fr) 25px 66px;
    gap: 10px;
  }
  .compact .identity strong {
    font-size: 11px;
  }
  .compact .beer-count {
    font-size: 15px;
  }
  .compact .rank-number {
    font-size: 11px;
  }
  .compact .rank-change {
    font-size: 11px;
  }
  .compact .avatar-sm {
    width: 33px;
    height: 33px;
  }
  .leaderboard-toolbar {
    gap: 15px;
    margin-bottom: 13px;
  }
  .period-tabs {
    gap: 0;
    justify-content: space-between;
    width: 100%;
  }
  .period-tabs button {
    font-size: 11px;
    padding: 8px 9px;
    min-height: 34px;
  }
  .search-field {
    width: 100%;
    margin: 0;
  }
  .search-field input {
    width: 100%;
    font-size: 12px;
    min-height: 24px;
  }
  .leaderboard-subbar {
    font-size: 11px;
    gap: 12px;
    padding-bottom: 20px;
  }
  .leaderboard-subbar label {
    font-size: 0;
    gap: 0;
  }
  .leaderboard-subbar select {
    font-size: 11px;
    max-width: 135px;
  }
  .full-leaderboard {
    padding: 19px 15px;
  }
  .leaderboard-table-header {
    grid-template-columns: 24px minmax(0, 1fr) 35px 58px;
    gap: 8px;
    font-size: 10px;
    padding: 13px 0;
    letter-spacing: 0.5px;
  }
  /* "RANG" does not fit the rank column: show "#", keep the word for screen readers. */
  .leaderboard-table-header > span:first-child {
    font-size: 0;
  }
  .leaderboard-table-header > span:first-child::after {
    content: "#";
    font-size: 10px;
  }
  .full-leaderboard .leaderboard-row {
    grid-template-columns: 24px minmax(0, 1fr) 35px 58px;
    gap: 8px;
    padding: 16px 0;
    min-height: 76px;
  }
}
.leaderboard-stage .leaderboard-row {
  min-height: 74px;
  padding: 12px 10px;
}
@media (max-width: 1100px) {
  .leaderboard-stage .leaderboard-table-header,
  .leaderboard-stage .leaderboard-row {
    grid-template-columns: 24px minmax(0, 1fr) 33px 65px;
    gap: 8px;
  }
}
@media (max-width: 760px) {
  .leaderboard-stage .leaderboard-row,
  .leaderboard-stage .leaderboard-table-header {
    padding-left: 0;
    padding-right: 0;
  }
}
@media (max-width: 700px) {
  .full-leaderboard .identity {
    gap: 8px;
  }
  .full-leaderboard .identity strong {
    font-size: 11px;
  }
  .full-leaderboard .identity small {
    font-size: 11px;
    max-width: 130px;
  }
}
@media (max-width: 1100px) {
  .leaderboard-stage .identity small {
    font-size: 11px;
  }
}
@media (max-width: 700px) {
  .full-leaderboard .avatar {
    width: 33px;
    height: 33px;
    border-radius: 9px;
  }
  .full-leaderboard .rank-number {
    font-size: 11px;
  }
  .full-leaderboard .rank-change {
    font-size: 11px;
  }
  .full-leaderboard .beer-count {
    font-size: 16px;
    gap: 4px;
  }
  .full-leaderboard .beer-count svg {
    width: 12px;
    height: 12px;
  }
  .full-leaderboard .beer-count small {
    font-size: 11px;
  }
  .pagination {
    font-size: 11px;
  }
  #leaderboard-podium {
    margin-bottom: 20px;
  }
  #leaderboard-podium .podium {
    margin-top: 37px;
  }
  #leaderboard-podium .podium-person {
    padding: 0 3px;
  }
  #leaderboard-podium .avatar-lg {
    width: 61px;
    height: 61px;
  }
  #leaderboard-podium .avatar-xl {
    width: 79px;
    height: 79px;
  }
  #leaderboard-podium .podium-person > strong {
    font-size: 13px;
  }
  #leaderboard-podium .podium-person > small {
    font-size: 11px;
  }
  #leaderboard-podium .podium-person > b {
    font-size: 21px;
  }
  #leaderboard-podium .podium-title {
    font-size: 10px;
  }
  #leaderboard-podium .podium-plinth {
    font-size: 36px;
  }
  #leaderboard-podium .podium-1 .podium-plinth {
    height: 73px;
  }
}
@media (max-width: 760px) {
  .podium-panel #leaderboard-podium .podium-plinth {
    height: 30px;
    font-size: 25px;
  }
}
@media (max-width: 370px) {
  .leaderboard-panel {
    padding-bottom: 0;
    padding-left: 15px;
    padding-right: 15px;
  }
  .full-leaderboard .identity strong {
    font-size: 11px;
  }
}
@media (max-width: 1100px) {
  .leaderboard-stage .identity strong {
    font-size: 12px;
  }
}
@media (max-width: 760px) {
  .leaderboard-stage .identity strong {
    font-size: 11px;
  }
}
@media (max-width: 370px) {
  .full-leaderboard .identity small {
    max-width: 95px;
  }
  .full-leaderboard .avatar {
    width: 28px;
    height: 28px;
  }
  .full-leaderboard .beer-count {
    font-size: 14px;
  }
}
@media (max-width: 1100px) {
  .leaderboard-stage .beer-count {
    font-size: 18px;
  }
}
@media (max-width: 760px) {
  .leaderboard-stage .beer-count {
    font-size: 16px;
  }
}
@media (max-width: 370px) {
  .period-tabs button {
    padding: 8px 6px;
  }
  .leaderboard-heading h1 {
    font-size: 28px;
  }
  .leaderboard-stage .leaderboard-row,
  .leaderboard-stage .leaderboard-table-header {
    grid-template-columns: 20px minmax(0, 1fr) 27px 56px;
    gap: 7px;
  }
  .leaderboard-stage .period-tabs button {
    font-size: 11px;
    padding: 7px 5px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .podium-person:hover .avatar {
    transform: none;
  }
}
/* ==== Les chiffres and chart grids ==== */
.trends-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}
.trends-grid .activity-panel .chart-svg {
  max-height: 310px;
}
.trends-grid .race-panel .chart-svg {
  max-height: 330px;
}
.trends-grid .race-legend {
  gap: 25px;
}
.trends-grid .race-legend > a {
  font-size: 12px;
}
.forecast {
  display: flex;
  align-items: center;
  gap: 25px;
  margin: 28px 0 0;
  padding: 25px 30px;
  background: var(--theme-surface, #20271a);
  border: 1px solid var(--theme-line, #39452b);
  border-radius: 11px;
}
.forecast > span {
  font-size: 40px;
  color: var(--accent-ink, var(--lime));
}
.forecast h3 {
  font-size: 20px;
  margin-bottom: 8px;
}
.forecast p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}
@media (max-width: 980px) {
  .trends-grid {
    gap: 17px;
  }
  .trends-grid .panel-heading h2 {
    font-size: 20px;
  }
}
@media (max-width: 700px) {
  .trends-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }
  .trends-grid > .panel {
    grid-column: 1;
  }
  .trends-grid .panel-heading h2 {
    font-size: 22px;
  }
  .trends-grid .panel-heading .identity-text {
    display: none;
  }
  .trends-grid .chart-svg text {
    font-size: 14px;
  }
  .trends-grid .race-legend {
    gap: 12px;
  }
  .trends-grid .race-legend > a {
    font-size: 11px;
  }
  .forecast {
    padding: 22px;
    gap: 16px;
  }
  .forecast > span {
    font-size: 30px;
  }
  .forecast h3 {
    font-size: 18px;
  }
  .forecast p {
    font-size: 11px;
  }
}
/* ==== Les légendes ==== */
.milestone-panel {
  margin-top: 25px;
}
.milestone-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 15px;
}
.milestone {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  padding: 20px 5px;
  border: 1px dashed var(--theme-line, #3c4434);
  border-radius: 9px;
  color: var(--theme-muted, #8b9580);
}
.milestone > span {
  font-size: 30px;
}
.milestone > strong {
  font-family: var(--font);
  font-size: 21px;
  font-weight: 600;
}
.milestone > small {
  font-size: 10px;
}
.milestone.earned {
  background: color-mix(in srgb, var(--lime) 3.92%, transparent);
  border: 1px solid var(--theme-line, #6d8345);
  color: var(--accent-ink, var(--lime));
}
.legend-cards {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 18px;
}
.legend-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  background:
    radial-gradient(
      ellipse at top,
      color-mix(in srgb, var(--user-color) 12%, transparent),
      transparent 65%
    ),
    var(--panel);
  border: 1px solid color-mix(in srgb, var(--user-color) 20%, var(--line));
  border-radius: 12px;
  padding: 25px 12px;
  min-width: 0;
  text-align: center;
}
.legend-card > .eyebrow {
  color: var(--user-color);
  font-size: 10px;
  margin-bottom: 25px;
}
.legend-card h3 {
  font-size: 19px;
  margin: 16px 0 6px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.legend-card > span:not(.avatar):not(.eyebrow) {
  color: var(--muted);
  font-size: 10px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.legend-card > strong {
  font-family: var(--font);
  font-size: 30px;
  color: var(--user-color);
  margin: 25px 0;
}
.legend-card > small {
  font-size: 11px;
  color: var(--muted);
}
.current-streak {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
  padding: 18px 22px;
  border: 1px solid #614c32;
  border-radius: 12px;
  background: linear-gradient(120deg, #edb78b0e, var(--panel));
}
.current-streak > svg {
  width: 30px;
  height: 36px;
  color: var(--secondary-ink, var(--peach));
}
.current-streak .eyebrow {
  color: var(--secondary-ink, var(--peach));
  font-size: 10px;
  letter-spacing: 1.2px;
  margin-bottom: 6px;
}
.current-streak strong {
  display: block;
  font-family: var(--font);
  font-size: 30px;
  font-weight: 600;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.current-streak strong > span {
  font-size: 16px;
  font-weight: 400;
  color: var(--muted);
}
.current-streak small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  margin-top: 7px;
}

.medal-leaders {
  margin: 24px 0;
}
.medal-leaders-note {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
  margin: 0 0 22px;
}
.medal-leaders-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
.medal-ranking {
  min-width: 0;
  border: 1px solid #756039;
  background: #29261c;
  color: #f5edcf;
  border-radius: 10px;
  padding: 20px;
}
.medal-ranking-bad {
  border-color: #bd535d;
  background: #571922;
  color: #ffe4df;
}
.medal-ranking h3 {
  margin: 0 0 8px;
  font-size: 18px;
  color: inherit;
}
.medal-ranking > p {
  margin: 0 0 20px;
  font-size: 12px;
  color: inherit;
}
.medal-ranking ol {
  list-style: none;
  padding: 0;
  margin: 0;
}
.medal-ranking li + li {
  border-top: 1px solid #ffffff20;
}
.medal-ranking a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 0;
  color: inherit;
}
.medal-ranking a:hover .medal-ranking-name {
  text-decoration: underline;
}
.medal-ranking-position {
  font-size: 12px;
  flex-shrink: 0;
}
.medal-ranking-name {
  min-width: 0;
  flex: 1;
  overflow-wrap: anywhere;
  font-size: 14px;
}
.medal-ranking small {
  display: block;
  font-size: 11px;
  margin-top: 4px;
  font-weight: 400;
}
.medal-ranking strong {
  text-align: right;
  font-size: 22px;
  flex-shrink: 0;
}
.medal-ranking-empty {
  padding: 24px 0;
  font-size: 13px;
  line-height: 1.7;
}
.records-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
@media (hover: hover) and (pointer: fine) {
  .legend-card:hover {
    border-color: var(--user-color);
  }
}
@media (max-width: 1200px) {
  .legend-cards {
    gap: 12px;
  }
  .legend-card h3 {
    font-size: 16px;
  }
  .milestone-grid {
    gap: 10px;
  }
  .milestone > strong {
    font-size: 17px;
  }
  .milestone > small {
    font-size: 10px;
  }
}
@media (max-width: 980px) {
  .legend-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .milestone-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .milestone > strong {
    font-size: 21px;
  }
  .milestone > small {
    font-size: 10px;
  }
  .current-streak {
    padding: 12px 17px;
    gap: 13px;
  }
  .current-streak > div {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    column-gap: 20px;
  }
  .current-streak .eyebrow {
    margin-bottom: 0;
  }
  .current-streak strong {
    grid-column: 2;
    grid-row: 1 / span 2;
    font-size: 26px;
  }
  .current-streak small {
    grid-column: 1;
    font-size: 11px;
    line-height: 1.5;
    margin-top: 4px;
  }
}
@media (max-width: 800px) {
  .medal-leaders-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 760px) {
  .current-streak {
    width: 100%;
    padding: 12px 14px;
    gap: 10px;
  }
  .current-streak > div {
    flex: 1;
    column-gap: 10px;
  }
  .current-streak > svg {
    width: 23px;
    height: 28px;
  }
  .current-streak strong > span {
    font-size: 13px;
  }
}
@media (max-width: 700px) {
  .milestone-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
  .milestone {
    padding: 23px 7px;
  }
  .milestone:last-child {
    grid-column: 1/-1;
  }
  .milestone > strong {
    font-size: 24px;
  }
  .milestone > small {
    font-size: 10px;
  }
  .legend-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 13px;
  }
  .legend-card {
    padding: 23px 12px;
  }
  .legend-card .avatar-xl {
    width: 67px;
    height: 67px;
  }
  .legend-card > .eyebrow {
    font-size: 10px;
    letter-spacing: 0.9px;
  }
  .legend-card h3 {
    font-size: 16px;
  }
  .legend-card > span:not(.avatar):not(.eyebrow) {
    font-size: 10px;
  }
  .legend-card > strong {
    font-size: 27px;
    margin: 20px 0;
  }
  .legend-card > small {
    font-size: 11px;
  }
  .records-heading {
    flex-direction: column;
    align-items: stretch;
  }
}
/* ==== Voyages ==== */

/* Dedicated community travel page. */
.travel-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 22px;
}
.travel-grid h2 {
  font: 650 clamp(23px, 2.6vw, 32px)/1.15 var(--font);
  letter-spacing: -0.7px;
  margin: 12px 0 22px;
}
.travel-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}
.travel-chart-note {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
  margin: 22px 0;
}
.destination-bars,
.discovery-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.destination-bars {
  display: grid;
  gap: 22px;
}
.destination-bar-label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  font-size: 13px;
  margin-bottom: 9px;
}
.destination-bar-label .country-label {
  white-space: normal;
  overflow-wrap: anywhere;
}
.destination-bar-label strong {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.destination-bar-label small {
  font-size: 11px;
  font-weight: 400;
  color: var(--muted);
}
.destination-bar-track {
  height: 9px;
  background: var(--line);
  border-radius: 3px;
  overflow: hidden;
}
.destination-bar-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--lime);
}
.discovery-list li {
  display: flex;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px dashed var(--line);
}
.discovery-list li:last-child {
  border-bottom: 0;
}
.discovery-flag {
  font-size: 29px;
}
.discovery-list li > div {
  display: grid;
  gap: 8px;
  min-width: 0;
}
.discovery-list strong {
  font: 600 18px var(--font);
  overflow-wrap: anywhere;
}
.discovery-list time {
  font-size: 12px;
  color: var(--secondary-ink, var(--lilac));
}
.discovery-list small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}

.department-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 28px;
  color: var(--muted);
  font-size: 12px;
  padding: 0 0 20px;
  line-height: 1.7;
}
.department-summary b {
  color: var(--text);
}
.department-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--secondary-ink, var(--lilac));
  font: 600 17px var(--font);
}
.community-departments {
  margin: 28px 0;
}
.department-stops {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.department-stop {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 16px 16px;
  min-width: 0;
}
.department-stop .profile-location {
  border-top: 0;
}
.department-visitors {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: var(--muted);
}

.travel-map-panel {
  margin-bottom: 24px;
}
.travel-map-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: start;
}
.travel-map-heading h2 {
  font-size: clamp(21px, 3vw, 30px);
  margin: 10px 0;
}
.travel-map-intro,
.travel-map-note {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}
.travel-map-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 20px 0 12px;
}
.travel-map-toolbar > div {
  display: flex;
  gap: 8px;
}
.travel-map-toolbar button,
.travel-map-canvas > button {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel-light);
  color: var(--text);
  padding: 10px 14px;
  min-height: 44px;
  cursor: pointer;
}
.travel-map-toolbar button:disabled {
  opacity: 0.4;
  cursor: default;
}
.travel-map-canvas {
  height: 500px;
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  border: 1px solid #414946;
  background: radial-gradient(ellipse at 45% 50%, #263c3d, #172529);
  touch-action: none;
  cursor: grab;
}
.travel-map-canvas:active {
  cursor: grabbing;
}
.travel-map-canvas > p {
  padding: 30px;
  color: #d1ddda;
}
.travel-map-svg {
  width: 100%;
  height: 100%;
  display: block;
}
.map-area {
  fill: #384845;
  stroke: #72827a;
  stroke-width: 0.65px;
  vector-effect: non-scaling-stroke;
  cursor: pointer;
}
.map-area.is-unlocked {
  fill: #d8b866;
  stroke: #ffdf93;
  stroke-width: 1.1px;
}
.map-area:hover,
.map-area:focus,
.map-area.is-selected {
  fill: #859c8d;
  stroke: #fff;
  stroke-width: 2px;
  outline: none;
}
.map-area.is-unlocked:hover,
.map-area.is-unlocked:focus,
.map-area.is-unlocked.is-selected {
  fill: #ffe3a0;
}
.map-departments {
  display: none;
}
.map-close .map-departments {
  display: block;
}
.map-markers {
  pointer-events: none;
  fill: #fff2c6;
  stroke: #906722;
  stroke-width: 1.5px;
}
.map-markers circle {
  vector-effect: non-scaling-stroke;
}
.travel-map-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  margin: 16px 0 22px;
  color: var(--muted);
  font-size: 11px;
}
.travel-map-legend span {
  display: flex;
  align-items: center;
  gap: 7px;
}
.travel-map-legend i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #384845;
  border: 1px solid #72827a;
}
.travel-map-legend .map-key-unlocked {
  background: #d8b866;
  border-color: #ffdf93;
}
.travel-map-bottom {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 24px;
  align-items: center;
}
.travel-map-bottom select {
  width: 100%;
  min-width: 0;
}
.travel-map-detail {
  display: grid;
  gap: 8px;
  min-width: 0;
  overflow-wrap: anywhere;
}
.travel-map-detail strong {
  font-size: 20px;
}
.travel-map-detail span,
.travel-map-detail small {
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}
.travel-map-note {
  margin-top: 22px;
}
.travel-map-credit {
  display: block;
  margin-top: 10px;
  font-size: 11px;
  color: var(--muted);
}
.travel-map-credit a {
  text-decoration: underline;
}
@media (max-width: 800px) {
  .travel-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 700px) {
  .travel-controls .history-filter {
    flex: 1 1 140px;
  }
  .department-stops {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 600px) {
  .travel-map-canvas {
    height: 390px;
  }
  .travel-map-heading {
    flex-direction: column;
    gap: 6px;
  }
  .travel-map-bottom {
    grid-template-columns: 1fr;
    gap: 18px;
  }
}
/* ==== Profile ==== */
.profile-hero {
  display: flex;
  align-items: center;
  gap: 35px;
  padding: 40px;
  border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--user-color) 25%, var(--line));
  background:
    radial-gradient(
      ellipse at top right,
      color-mix(in srgb, var(--user-color) 13%, transparent),
      transparent 70%
    ),
    var(--panel);
  margin-bottom: 25px;
}
.profile-big-avatar {
  position: relative;
  padding-bottom: 14px;
}
.profile-rank {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  background: var(--user-color);
  color: #1d2415;
  padding: 8px 10px;
  border-radius: 5px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  border: 3px solid var(--panel);
}
.profile-heading {
  min-width: 0;
}
.profile-heading > .eyebrow {
  color: var(--user-color);
  font-size: 10px;
  margin-bottom: 12px;
}
.profile-heading h1 {
  font-size: 49px;
  font-weight: 800;
  letter-spacing: -1.8px;
  overflow-wrap: anywhere;
  line-height: 1.1;
}
.profile-heading > p {
  color: var(--muted);
  font-size: 14px;
  margin-top: 8px;
  overflow-wrap: anywhere;
}
.profile-tags {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 20px;
}
.profile-tags > span {
  font-size: 11px;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 7px 10px;
}
.profile-tags > span:first-child {
  color: var(--user-color);
  border-color: color-mix(in srgb, var(--user-color) 30%, var(--line));
}
.profile-actions {
  margin-left: auto;
  align-self: flex-start;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  min-width: 190px;
}
.profile-actions .button {
  justify-content: center;
  font-size: 11px;
  padding: 10px 13px;
  min-height: 38px;
}
.me-toggle[aria-pressed="true"] {
  color: var(--accent-ink, var(--lime));
  border-color: color-mix(in srgb, var(--user-color) 60%, var(--line));
}
.duel-picker {
  display: grid;
  gap: 5px;
  font-size: 11px;
  color: var(--muted);
}
.profile-stats .stat-label > span {
  color: var(--user-color);
}
.profile-quote {
  text-align: center;
  font-family: var(--font);
  font-size: 23px;
  color: var(--muted);
  line-height: 1.5;
  margin: 35px auto;
  max-width: 800px;
}
.profile-quote strong {
  color: var(--text);
  font-weight: 500;
}
.personal-records dl {
  margin: 5px 0;
}
.personal-records dl > div {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.personal-records dl > div:last-child {
  border: 0;
}
.personal-records dt {
  color: var(--muted);
  font-size: 12px;
}
.personal-records dd {
  font-size: 13px;
  margin: 0;
  text-align: right;
}
.personal-records dd small {
  font-size: 11px;
  color: var(--muted);
}
.badges {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 9px;
  text-align: center;
  border: 1px dashed var(--theme-line, #3b4233);
  border-radius: 8px;
  min-height: 128px;
  padding: 14px 8px;
  color: var(--theme-muted, #909a84);
}
.badge > span {
  font-size: 28px;
}
.badge > strong {
  font-family: var(--font);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.3;
}
.badge > small {
  font-size: 11px;
  line-height: 1.5;
}
.badge.earned {
  border: 1px solid var(--theme-line, #56663c);
  color: var(--accent-ink, var(--lime));
  background: color-mix(in srgb, var(--lime) 1.96%, transparent);
}
.badge.earned > small {
  color: var(--muted);
}

/* Keep the rank badge above the avatar image's own stacking layer. */
.profile-rank {
  z-index: 2;
}
.passport-heading,
.journal-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
.passport h2,
.beer-journal h2 {
  margin: 12px 0;
  font: 650 clamp(25px, 3vw, 38px)/1.08 var(--font);
  letter-spacing: -1px;
}
.passport p,
.journal-heading p {
  color: var(--muted);
  line-height: 1.6;
  margin: 8px 0;
}
.country-label {
  white-space: nowrap;
}
.beer-journal {
  margin-top: 28px;
  scroll-margin-top: 100px;
}
.journal-heading {
  align-items: flex-end;
  margin-bottom: 24px;
}
.history-filter {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  flex-shrink: 0;
  max-width: 100%;
}
.history-filter select {
  max-width: 100%;
  min-height: 44px;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 30px 10px 12px;
}
.beer-memory {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px 0;
  border-top: 1px solid var(--line);
}
.memory-flag {
  flex-shrink: 0;
  font-size: 25px;
  line-height: 1.5;
}
.memory-body {
  min-width: 0;
  flex: 1;
}
.memory-meta {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 7px 16px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}
.memory-meta > span {
  color: var(--secondary-ink, var(--lilac));
}
.memory-body p {
  margin: 10px 0 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  line-height: 1.7;
}
#beer-history[aria-busy="true"] {
  opacity: 0.6;
}
#beer-history .pagination {
  gap: 16px;
}

/* Secondary profile geography, grouped independently from stats and achievements. */
.profile-locations {
  display: grid;
  gap: 20px;
  margin: 24px 0;
}
.profile-location-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}
.profile-location-heading h2 {
  font: 600 23px/1.2 var(--font);
  letter-spacing: -0.4px;
  margin: 8px 0 0;
}
.profile-location-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 24px;
}
.profile-location {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 0;
  min-width: 0;
  border: 0;
  border-top: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  text-align: left;
}
.profile-location-name {
  display: grid;
  gap: 6px;
  min-width: 0;
}
.profile-location-name strong {
  font-size: 13px;
  font-weight: 500;
  overflow-wrap: anywhere;
}
.profile-location-name small {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.5;
}
.profile-location-count {
  margin-left: auto;
  font-size: 11px;
  white-space: nowrap;
  color: var(--muted);
}
.profile-location-count > span {
  color: var(--secondary-ink, var(--lilac));
  margin-left: 4px;
}
.profile-location-note {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
  margin: 16px 0 0;
}
.journal-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  max-width: 100%;
}
.journal-filters .history-filter {
  min-width: 0;
  flex: 1 1 160px;
}
.journal-filters select {
  width: 100%;
}

.score-modifier-note {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}
.score-modifier-note strong {
  font-weight: 500;
}

.profile-locations-passport {
  grid-template-columns: minmax(0, 1fr);
}
.profile-heading .profile-biography {
  max-width: 620px;
  margin: 16px 0;
  color: var(--text);
  font-size: 15px;
  line-height: 1.7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.badge-progress {
  display: block;
  width: 70%;
  height: 4px;
  border-radius: 2px;
  background: var(--theme-track, #293022);
  overflow: hidden;
}
.badge-progress i {
  display: block;
  height: 100%;
  background: var(--accent-ink, var(--lime));
  transform-origin: left;
}
.badge-count {
  font-variant-numeric: tabular-nums;
  color: var(--text);
}
@media (hover: hover) and (pointer: fine) {
  .profile-location:hover .profile-location-name strong {
    color: var(--accent-ink, var(--lime));
  }
}
@media (min-width: 701px) {
  .profile-stats {
    margin-bottom: 0;
  }
}
@media (max-width: 1200px) {
  .profile-hero {
    padding: 30px;
    gap: 25px;
  }
  .profile-heading h1 {
    font-size: 39px;
  }
  .profile-actions .button {
    font-size: 11px;
  }
  .badges {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 7px;
  }
  .badge {
    padding: 12px 5px;
  }
  .badge > strong {
    font-size: 11px;
  }
}
@media (max-width: 980px) {
  .profile-hero {
    flex-wrap: wrap;
    padding: 30px;
  }
  .profile-actions {
    margin-left: auto;
    align-self: auto;
  }
  .profile-heading {
    flex: 1;
  }
  .profile-heading h1 {
    font-size: 44px;
  }
  .badges {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 800px) {
  .journal-heading {
    align-items: flex-start;
    flex-direction: column;
  }
}
@media (max-width: 700px) {
  .profile-hero {
    padding: 25px;
    gap: 23px;
    flex-direction: column;
    text-align: center;
  }
  .profile-actions {
    margin: 0;
    align-self: stretch;
    min-width: 0;
  }
  .profile-heading h1 {
    font-size: 36px;
    letter-spacing: -1px;
  }
  .profile-heading > p {
    font-size: 12px;
  }
  .profile-heading > .eyebrow {
    font-size: 10px;
    letter-spacing: 1px;
  }
  .profile-tags {
    justify-content: center;
    gap: 8px;
    margin-top: 17px;
  }
  .profile-tags > span {
    font-size: 11px;
    padding: 7px;
  }
  .profile-hero .profile-heading {
    width: 100%;
  }
  .profile-quote {
    font-size: 20px;
    margin: 26px auto;
  }
  .profile-stats .stat-card > strong {
    font-size: 29px;
  }
  .profile-stats .stat-card > small {
    font-size: 11px;
  }
  .personal-records dt {
    font-size: 11px;
  }
  .personal-records dd {
    font-size: 12px;
  }
  .badges {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
  .badge > strong {
    font-size: 13px;
  }
  .badge > small {
    font-size: 11px;
  }
  .badge {
    min-height: 135px;
  }
  .profile-location-list {
    grid-template-columns: minmax(0, 1fr);
  }
  .profile-location-heading h2 {
    font-size: 21px;
  }
  .journal-filters {
    width: 100%;
  }
}
@media (max-width: 480px) {
  .beer-memory {
    gap: 10px;
    flex-wrap: wrap;
  }
  .memory-meta {
    flex-direction: column;
  }
  .history-filter {
    width: 100%;
  }
}
/* ==== Passports and stamps ==== */

/* The travel passport and complete personal beer journal. */
.passport {
  margin: 32px 0;
  padding: clamp(20px, 3vw, 38px);
  border: 1px solid #48523c;
  border-radius: 22px;
  background:
    radial-gradient(
      ellipse at top right,
      color-mix(in srgb, var(--lime) 5.1%, transparent),
      transparent 60%
    ),
    var(--panel);
}
.passport-seal {
  flex: 0 0 144px;
  height: 144px;
  border: 1px dashed var(--lime);
  outline: 1px solid color-mix(in srgb, var(--lime) 20%, transparent);
  outline-offset: -9px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--accent-ink, var(--lime));
  transform: rotate(8deg);
}
.passport-seal strong {
  font: 700 56px/1 var(--font);
}
.passport-seal span {
  margin-top: 6px;
  font-size: 11px;
}
.passport-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  padding: 20px 0;
  margin: 8px 0 16px;
  border-bottom: 1px dashed var(--line);
  color: var(--muted);
  line-height: 1.6;
}
.passport-summary b {
  color: var(--text);
}
.country-stamps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.country-stamp {
  min-width: 0;
  padding: 18px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg);
  text-align: left;
  color: var(--text);
}
.stamp-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.stamp-flag {
  font-size: 30px;
  line-height: 1.3;
}
.stamp-code {
  border: 1px dashed #bfa4ed66;
  padding: 5px 8px;
  color: var(--secondary-ink, var(--lilac));
  font: 600 11px var(--font);
  letter-spacing: 2px;
}
.country-stamp > strong {
  font: 650 21px/1.2 var(--font);
  overflow-wrap: anywhere;
}
.stamp-count {
  font-size: 13px;
}
.country-stamp small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}
.stamp-track {
  height: 3px;
  background: var(--line);
  border-radius: 3px;
  margin: 2px 0 4px;
  overflow: hidden;
}
.stamp-track > span {
  display: block;
  background: var(--lime);
  height: 100%;
}
.stamp-ambassador {
  border-top: 1px dashed var(--line);
  padding-top: 12px;
  margin-top: auto;
  min-width: 0;
}
.stamp-ambassador > small {
  display: block;
  font-size: 11px;
  letter-spacing: 1px;
  margin-bottom: 8px;
}
.stamp-ambassador .identity {
  min-width: 0;
  max-width: 100%;
}
.passport .passport-note {
  font-size: 11px;
  margin: 20px 0 0;
}
.passport-more summary {
  cursor: pointer;
  padding: 20px 0;
  color: var(--accent-ink, var(--lime));
}
.passport-document {
  min-width: 0;
  margin: 12px 0 0;
}
.passport-document-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}
.passport-document-heading h2 {
  font-size: clamp(25px, 3vw, 38px);
  letter-spacing: -1px;
  margin: 10px 0 0;
}
.passport-document-count {
  color: #dbc68e;
  font-size: 12px;
  white-space: nowrap;
}
.passport-book {
  display: grid;
  grid-template-columns: minmax(240px, 0.7fr) minmax(0, 1.6fr);
  padding: 7px;
  background: #590f22;
  border-radius: 8px 19px 19px 8px;
  box-shadow:
    0 18px 40px #0005,
    0 2px 3px #0007;
}
.passport-cover {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 35px 24px 28px;
  color: #e5ca88;
  text-align: center;
  border-radius: 3px 9px 9px 3px;
  background:
    radial-gradient(ellipse at 35% 10%, #a62b43aa, transparent 65%),
    repeating-linear-gradient(25deg, #ffffff04 0 1px, transparent 1px 3px),
    linear-gradient(100deg, #520d21, #851c35 8%, #75132c 90%, #4b0d1f);
  box-shadow:
    inset 2px 0 3px #ffc6ab20,
    inset -5px 0 9px #21000c80;
  text-shadow: 0 1px 1px #240009;
}
.passport-cover::before {
  content: "";
  position: absolute;
  inset: 12px;
  border: 1px solid #d8b87145;
  border-radius: 2px 6px 6px 2px;
  pointer-events: none;
}
.passport-cover-republic {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 13px;
  line-height: 1.8;
  letter-spacing: 2.5px;
}
.passport-cover-rule {
  width: 40px;
  height: 1px;
  background: #d8b87188;
  margin: 18px 0;
}
.passport-cover h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(25px, 3vw, 38px);
  font-weight: 400;
  letter-spacing: 3px;
  margin: 0 0 9px;
  color: #f0d99d;
}
.passport-cover-translation {
  font-size: 8px;
  letter-spacing: 1.8px;
}
.passport-crest {
  width: 170px;
  height: 170px;
  stroke: currentColor;
  stroke-width: 1.4;
  margin: 13px 0 7px;
}
.passport-cover-brand {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 12px;
  letter-spacing: 2px;
}
.passport-holder {
  width: 100%;
  border-top: 1px solid #d8b87145;
  padding-top: 20px;
  margin-top: 25px;
}
.passport-holder > span {
  display: block;
  font-size: 11px;
  letter-spacing: 2px;
  margin-bottom: 9px;
}
.passport-holder strong {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 23px;
  line-height: 1.3;
  overflow-wrap: anywhere;
}
.passport-chip {
  width: 29px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  margin-top: 22px;
}
.passport-paper {
  position: relative;
  min-width: 0;
  padding: 28px 34px 22px;
  color: #403b30;
  border-radius: 2px 11px 11px 2px;
  background:
    repeating-radial-gradient(
      ellipse at 30% 35%,
      transparent 0 12px,
      #b4966120 13px,
      transparent 14px 20px
    ),
    linear-gradient(
      90deg,
      #ad9870 0,
      #e3d5b6 2%,
      #f5ecd6 7%,
      #f5edda 96%,
      #e1d2b0
    );
  box-shadow:
    3px 0 #d7c7a5,
    5px 0 #f0e5cb;
  display: flex;
  flex-direction: column;
}
.passport-page-heading {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid #a894705c;
  padding-bottom: 16px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 10px;
  letter-spacing: 1.8px;
  position: relative;
  z-index: 1;
}
.passport-watermark {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #987b4520;
  pointer-events: none;
  overflow: hidden;
}
.passport-watermark .passport-crest {
  width: 80%;
  height: auto;
}
.passport-stamp-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 26px 22px;
  padding: 32px 3px;
  z-index: 1;
}
.visa-stamp {
  --stamp-ink: #294a68;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: stretch;
  gap: 10px;
  padding: 12px 10px;
  border: 2px solid currentColor;
  outline: 1px solid currentColor;
  outline-offset: -6px;
  border-radius: 5px;
  color: var(--stamp-ink);
  background: transparent;
  font-family: "Courier New", monospace;
  text-align: center;
  cursor: pointer;
  transform: rotate(-5deg);
  box-shadow: 1px 1px 0 #294a6810;
  min-height: 152px;
}
.visa-stamp-1 {
  --stamp-ink: #893b43;
  transform: rotate(4deg);
  border-radius: 45% 45% 8px 8px;
}
.visa-stamp-2 {
  --stamp-ink: #38604d;
  transform: rotate(-2deg);
  border-style: dashed;
}
.visa-stamp-3 {
  --stamp-ink: #624369;
  transform: rotate(3deg);
  border-radius: 14px 3px;
}
.visa-stamp-top {
  font-size: 8px;
  font-weight: bold;
  letter-spacing: 0.7px;
}
.visa-stamp strong {
  display: block;
  text-transform: uppercase;
  font-size: clamp(13px, 1.4vw, 19px);
  line-height: 1.2;
  letter-spacing: 0.8px;
  overflow-wrap: anywhere;
}
.visa-stamp-date {
  font-size: 10px;
  font-weight: bold;
  padding: 6px 0;
  border-block: 1px solid currentColor;
  text-transform: uppercase;
}
.visa-stamp-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 5px;
  font-size: 9px;
}
.visa-stamp-bottom b {
  font-size: 13px;
}
.visa-stamp:focus-visible {
  outline: 3px solid #231d18;
  outline-offset: 4px;
}
.visa-stamp:active {
  background: #d7c49b66;
}
.passport-page-footer {
  position: relative;
  margin-top: auto;
  border-top: 1px solid #a894705c;
  padding-top: 17px;
  display: flex;
  gap: 20px;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  line-height: 1.7;
  color: #655840;
}
.passport-page-footer > span:last-child {
  font-size: 23px;
}
.passport-extra {
  position: relative;
  z-index: 1;
}
.passport-extra summary {
  cursor: pointer;
  font-size: 12px;
  padding: 12px 0 20px;
  color: #6f2638;
}
.passport-extra summary span {
  float: right;
}
.passport-blank {
  grid-column: 1/-1;
  text-align: center;
  padding: 40px 10px;
  color: #776447;
}
.passport-blank > span {
  display: block;
  font-size: 50px;
  margin-bottom: 15px;
}
.passport-blank strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 28px;
  font-weight: 400;
}
.passport-blank p {
  font-size: 12px;
  line-height: 1.7;
}
.passport-document-note {
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
  margin: 17px 0 0;
}
.visa-stamp-placeholder {
  color: #9b8b6a;
  opacity: 0.45;
  border-style: dashed;
  outline-style: dashed;
  cursor: default;
  transform: rotate(3deg);
}
.visa-stamp-placeholder strong {
  font-size: 30px;
}
@media (hover: hover) and (pointer: fine) {
  .visa-stamp:hover {
    background: #d7c49b55;
  }
}
@media (max-width: 1050px) {
  .passport-stamp-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .passport-paper {
    padding: 24px;
  }
}
@media (max-width: 800px) {
  .country-stamps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 650px) {
  .passport-book {
    grid-template-columns: minmax(0, 1fr);
    border-radius: 10px;
  }
  .passport-cover {
    padding: 32px 24px 26px;
  }
  .passport-cover h3 {
    font-size: 34px;
  }
  .passport-cover .passport-crest {
    width: 130px;
    height: 130px;
    margin: 10px 0;
  }
  .passport-holder {
    margin-top: 18px;
    padding-top: 16px;
  }
  .passport-paper {
    margin-top: 6px;
    padding: 22px 20px;
    border-radius: 2px 2px 8px 8px;
    box-shadow: 0 2px #d7c7a5;
  }
  .passport-document-heading {
    align-items: start;
    flex-direction: column;
    gap: 12px;
  }
  .passport-stamp-grid {
    gap: 24px 18px;
    padding: 28px 0;
  }
  .visa-stamp {
    padding: 12px 8px;
  }
  .visa-stamp strong {
    font-size: 15px;
  }
}
@media (max-width: 480px) {
  .passport {
    padding: 18px;
    border-radius: 16px;
  }
  .passport-heading {
    align-items: flex-start;
    gap: 12px;
  }
  .passport-heading .eyebrow {
    font-size: 10px;
    line-height: 1.7;
  }
  .passport h2 {
    font-size: 25px;
  }
  .passport-seal {
    flex-basis: 80px;
    height: 80px;
    outline-offset: -5px;
    margin-top: 6px;
  }
  .passport-seal strong {
    font-size: 32px;
  }
  .passport-seal span {
    font-size: 11px;
    max-width: 60px;
    text-align: center;
  }
  .country-stamps {
    gap: 10px;
  }
  .country-stamp {
    padding: 12px;
  }
  .country-stamp > strong {
    font-size: 18px;
  }
  .stamp-count small {
    display: block;
  }
}
@media (max-width: 360px) {
  .passport-stamp-grid {
    grid-template-columns: minmax(0, 1fr);
    padding-inline: 18px;
  }
}
/* ==== Personal medals ==== */

/* Personal IRL distinctions: an enamel medal or an old wanted poster. */
.profile-medals {
  margin: 32px 0;
}
.profile-medals .section-intro p {
  max-width: 650px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--muted);
  margin-top: 12px;
}
.personal-medal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
  gap: 18px;
}
.personal-medal {
  min-width: 0;
  padding: 24px;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  overflow-wrap: anywhere;
}
.medal-honor {
  border: 1px solid #756039;
  background: linear-gradient(145deg, #302b1e, #1c2018 80%);
  color: #f5edcf;
}
.medal-emblem {
  display: flex;
  align-items: center;
  flex-direction: column;
  margin-bottom: 20px;
  text-align: center;
}
.medal-emblem svg {
  width: 68px;
  height: 82px;
}
.medal-kind {
  margin-top: 11px;
  color: #d8bd7e;
  letter-spacing: 1.7px;
  font-size: 9px;
  font-weight: 700;
}
.medal-story {
  flex: 1;
}
.medal-story h3 {
  font-size: 20px;
  line-height: 1.3;
  letter-spacing: -0.5px;
  margin: 0 0 12px;
  color: inherit;
}
.medal-story p {
  font-size: 14px;
  line-height: 1.7;
  margin: 0;
  white-space: pre-wrap;
  color: inherit;
}
.medal-untitled .medal-story p {
  font-size: 19px;
  line-height: 1.6;
  font-weight: 500;
}
.medal-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-top: 1px solid #756039;
  margin-top: 24px;
  padding-top: 14px;
  font-size: 11px;
}
.medal-footer strong {
  font-weight: 650;
}
.medal-footer time {
  font-size: 11px;
}
.medal-wanted {
  color: #ffe4df;
  background: linear-gradient(125deg, #741f28, #571922 60%, #3e151c);
  border: 1px solid #d66068;
  border-radius: 2px;
  outline: 1px solid #bd535d;
  outline-offset: -8px;
}
.wanted-heading {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 38px;
  font-weight: 900;
  letter-spacing: 4px;
  line-height: 1.1;
}
.wanted-subheading {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 2px;
  padding: 8px 0;
  margin-top: 7px;
  border-block: 2px solid #d66068;
}
.medal-wanted .medal-story h3 {
  font-family: Georgia, "Times New Roman", serif;
}
.medal-wanted .medal-footer {
  border-color: #bd535d;
}
.medals-more {
  margin-top: 16px;
}
.medals-more summary {
  cursor: pointer;
  font-size: 12px;
  color: var(--muted);
  padding: 12px 0;
}
@media (max-width: 600px) {
  .personal-medal {
    padding: 22px;
  }
  .medal-untitled .medal-story p {
    font-size: 18px;
  }
}
/* ==== Face à face ==== */
.duel-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 24px;
  margin-bottom: 22px;
}
.duel-side {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 26px 18px;
  text-align: center;
  border: 1px solid color-mix(in srgb, var(--user-color) 35%, var(--line));
  border-radius: 14px;
  background:
    radial-gradient(ellipse at top, color-mix(in srgb, var(--user-color) 14%, transparent), transparent 70%),
    var(--panel);
}
.duel-side strong {
  font-family: var(--font);
  font-size: 26px;
  letter-spacing: -0.6px;
  margin-top: 8px;
  overflow-wrap: anywhere;
}
.duel-side small {
  color: var(--muted);
  font-size: 12px;
}
.duel-side b {
  font-family: var(--font);
  font-size: 30px;
  color: var(--user-color);
}
.duel-side b span {
  font-size: 12px;
  color: var(--muted);
  font-weight: 400;
}
.duel-vs {
  max-width: 190px;
  text-align: center;
}
.duel-vs span {
  font-family: var(--font);
  font-size: 40px;
  color: var(--accent-ink, var(--lime));
}
.duel-vs p {
  margin: 8px 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}
.duel-pickers {
  display: flex;
  align-items: end;
  justify-content: center;
  gap: 12px;
  margin-bottom: 22px;
}
.duel-pickers label {
  display: grid;
  gap: 5px;
  font-size: 11px;
  color: var(--muted);
}
.duel-table,
.duel-race,
.duel-places {
  margin-bottom: 20px;
}
.duel-row {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr) 90px;
  align-items: center;
  gap: 18px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.duel-row:last-child {
  border-bottom: 0;
}
.duel-value {
  font-family: var(--font);
  font-size: 20px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.duel-row > .duel-value:last-child {
  text-align: right;
}
.duel-row > .duel-value.wins:first-child {
  color: var(--left);
}
.duel-row > .duel-value.wins:last-child {
  color: var(--right);
}
.duel-label {
  display: grid;
  gap: 7px;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}
/* A tug of war: each side's share of the line, in its own colour. */
.duel-bar {
  display: flex;
  height: 6px;
  border-radius: 3px;
  background: var(--right);
  overflow: hidden;
}
.duel-bar i {
  display: block;
  height: 100%;
  width: calc(var(--share) * 100%);
  background: var(--left);
  border-right: 2px solid var(--panel);
}
.duel-flags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.duel-flags li {
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 12px;
}
.duel-note {
  margin: 14px 0 0;
  font-size: 12px;
  color: var(--muted);
}
@media (max-width: 700px) {
  .duel-hero {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 12px;
  }
  .duel-vs {
    grid-column: 1 / -1;
    grid-row: 2;
    max-width: none;
  }
  .duel-side {
    padding: 18px 10px;
  }
  .duel-side strong {
    font-size: 19px;
  }
  .duel-side b {
    font-size: 22px;
  }
  .duel-pickers {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 8px;
  }
  .duel-pickers select {
    width: 100%;
  }
  .duel-row {
    grid-template-columns: 62px minmax(0, 1fr) 62px;
    gap: 10px;
  }
  .duel-value {
    font-size: 16px;
  }
}

/* ==== TV mode ==== */
.tv-mode .header {
  max-width: none;
  padding: 12px 24px;
  min-height: 64px;
  display: flex;
  justify-content: space-between;
}
.tv-mode .header .navigation,
.tv-mode .header .discord-button,
.tv-mode .footer {
  display: none;
}
.tv-mode #main {
  max-width: none;
  width: 100%;
  padding: 12px 24px 24px;
  margin: 0;
}
.tv-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(340px, 1fr);
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 20px;
  height: calc(100dvh - 150px);
  min-height: 650px;
}
.tv-grid > .panel {
  min-width: 0;
  min-height: 0;
  padding: 22px;
  margin: 0;
  grid-column: auto;
  grid-row: auto;
  overflow: auto;
}
.tv-grid .race-panel {
  grid-column: 1;
  grid-row: 2;
  display: flex;
  flex-direction: column;
}
.tv-grid .tv-leaders {
  grid-column: 2;
  grid-row: 1/3;
}
.tv-grid .panel-heading {
  margin-bottom: 12px;
}
.tv-grid .panel-heading h2 {
  font-size: clamp(20px, 1.7vw, 34px);
}
.tv-grid #race-chart {
  flex: 1;
  min-height: 100px;
}
.tv-grid .chart-svg {
  width: 100%;
  height: 100%;
  max-height: none;
}
.tv-grid .podium {
  margin-top: 20px;
}
.tv-grid .podium-person > strong {
  font-size: clamp(16px, 1.3vw, 26px);
}
.tv-grid .leaderboard-row {
  min-height: 64px;
}
.tv-grid .identity-text strong {
  font-size: clamp(14px, 1.1vw, 22px);
}
.tv-mode #source-banner:has(.source-banner) + #main .tv-grid {
  height: calc(100dvh - 195px);
}
/* TV arena: no navigation chrome, one large score and a dedicated arrival feed. */
body.tv-mode .header {
  display: none;
}
.tv-arena-score {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-shrink: 0;
  padding: 12px 0 24px;
  margin-bottom: 22px;
}
.tv-score-caption {
  display: grid;
  gap: 12px;
  color: var(--accent-ink, var(--lime));
  font-size: 11px;
  letter-spacing: 1px;
}
.tv-score-center {
  display: flex;
  align-items: center;
  gap: 24px;
  min-width: 0;
}
.tv-score-digits {
  font-family: var(--font);
  font-size: clamp(56px, 6.8vw, 132px);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.065em;
  line-height: 1;
  color: var(--accent-ink, #e8ffa8);
  text-shadow:
    0 0 45px color-mix(in srgb, var(--lime) 21%, transparent),
    0 3px 0 color-mix(in srgb, var(--lime) 45%, var(--bg));
  transform-origin: center;
}
.tv-score-target {
  display: grid;
  gap: 8px;
  font-size: clamp(14px, 1.3vw, 24px);
  color: var(--theme-muted, #a3af8c);
  letter-spacing: 1px;
}
.tv-score-target > span {
  font-size: 11px;
  letter-spacing: 3px;
}
.tv-score-tools {
  display: grid;
  gap: 10px;
  justify-items: end;
  font-size: 11px;
  color: var(--muted);
}
.tv-exit {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  padding: 10px 14px;
  cursor: pointer;
  min-height: 40px;
}
.tv-score-progress {
  position: absolute;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: var(--theme-track, #374227);
  overflow: hidden;
}
.tv-score-progress i {
  display: block;
  height: 100%;
  width: 100%;
  background: var(--lime);
  transform-origin: left;
}
.tv-score-announcement {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
.tv-grid .tv-live-panel {
  grid-column: 1;
  grid-row: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.tv-live-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}
.tv-live-heading h2 {
  font-size: clamp(23px, 1.8vw, 35px);
  margin: 8px 0 0;
  letter-spacing: -0.8px;
}
.tv-live-tag {
  color: var(--accent-ink, var(--lime));
  font-size: 11px;
  letter-spacing: 2px;
}
.tv-entry-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: auto;
  min-height: 0;
  padding: 3px;
}
.tv-entry {
  position: relative;
  display: flex;
  align-items: center;
  gap: 15px;
  border-radius: 10px;
  border: 1px solid color-mix(in srgb, var(--user-color) 12%, var(--line));
  padding: 12px 16px;
  --tv-entry-tint: 6%;
  color: var(--tv-entry-ink, var(--text));
  background-color: var(--theme-surface, #171c15);
  background-image: linear-gradient(
    110deg,
    color-mix(
      in srgb,
      var(--user-color) var(--tv-entry-tint),
      var(--theme-surface, #171c15)
    ),
    var(--theme-surface, #171c15)
  );
  flex-shrink: 0;
}
.tv-entry-content {
  flex: 1;
  min-width: 0;
}
.tv-entry-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.tv-entry-top > strong {
  font-family: var(--font);
  font-size: clamp(17px, 1.4vw, 26px);
  font-weight: 750;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tv-entry-top > span {
  font-size: 11px;
  color: var(--tv-entry-muted, var(--muted));
  flex-shrink: 0;
  letter-spacing: 0.8px;
}
.tv-entry-content p {
  font-size: 13px;
  margin: 5px 0;
  color: var(--tv-entry-ink, #d1d6c6);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tv-entry-content small {
  font-size: 11px;
  color: var(--tv-entry-muted, var(--muted));
}
.tv-entry-point {
  font-family: var(--font);
  font-size: 30px;
  font-weight: 800;
  color: inherit;
}
.tv-entry-featured {
  padding: 18px 16px;
  --tv-entry-tint: 10%;
  padding-block: 14px;
}
.tv-entry-featured .tv-entry-top > strong {
  font-family: var(--font);
  font-size: clamp(21px, 1.8vw, 34px);
}
.tv-entry-featured .tv-entry-point {
  font-size: 42px;
}
.tv-feed-empty {
  padding: 35px 10px;
  color: var(--muted);
}
.tv-feed-empty strong {
  font-size: 25px;
  color: var(--text);
}
.tv-entry-avatar .avatar {
  width: 38px;
  height: 38px;
}
.tv-entry-featured .tv-entry-avatar .avatar {
  width: 60px;
  height: 60px;
}
.tv-grid .tv-race-panel #race-chart {
  height: 100%;
  min-height: 0;
  display: flex;
}
.tv-grid .tv-race-panel .chart-svg {
  flex: 1;
  width: 100%;
  height: 100%;
}
@media (min-width: 901px) {
  body.tv-mode {
    height: 100dvh;
    display: flex;
    flex-direction: column;
  }
  .tv-mode .header {
    width: 100%;
    flex-shrink: 0;
  }
  .tv-mode #source-banner {
    flex-shrink: 0;
  }
  .tv-mode #main {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
  }
  .tv-mode #main .tv-grid {
    flex: 1;
    height: auto;
    min-height: 0;
  }
  .tv-mode .tv-grid {
    grid-template-rows: minmax(0, 1.2fr) minmax(0, 1fr);
  }
}
@media (min-width: 1800px) {
  .tv-grid {
    gap: 28px;
  }
  .tv-grid > .panel {
    padding: 30px;
  }
}

.tv-grid > .tv-race-panel {
  padding: 14px;
  overflow: hidden;
}

@media (min-width: 701px) and (max-width: 1200px) {
  body:not(.tv-mode) .header {
    flex-wrap: wrap;
    padding-block: 16px;
    gap: 16px;
  }
  body:not(.tv-mode) .header .navigation {
    order: 3;
    flex-basis: 100%;
    min-width: 0;
    justify-content: center;
  }
}

@media (max-width: 900px) {
  .tv-grid {
    height: auto;
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto;
  }
  .tv-grid .race-panel,
  .tv-grid .tv-leaders {
    grid-column: 1;
    grid-row: auto;
  }
  .tv-grid #race-chart {
    min-height: 240px;
  }
  .tv-mode #main {
    padding: 12px;
  }
  .tv-grid .tv-live-panel {
    grid-column: 1;
    grid-row: auto;
    max-height: 570px;
  }
  .tv-arena-score {
    flex-wrap: wrap;
    gap: 16px;
  }
  .tv-score-caption {
    order: 0;
  }
  .tv-score-tools {
    order: 1;
    margin-left: auto;
  }
  .tv-score-center {
    order: 2;
    width: 100%;
    justify-content: center;
  }
  .tv-entry-top {
    align-items: start;
    flex-direction: column;
    gap: 4px;
  }
  .tv-entry-top > strong {
    max-width: 100%;
  }
  .tv-grid .tv-race-panel #race-chart {
    min-height: 270px;
  }
}

@media (max-width: 600px) {
  .tv-mode .header {
    padding: 12px;
    gap: 10px;
  }
  .tv-mode .header .brand {
    font-size: 13px;
  }
  .tv-mode #tv-toggle {
    max-width: 160px;
    white-space: normal;
  }
}

/* ==== Coca-Zero ==== */
body.coca-mode {
  --lime: #ff858d;
  --lilac: #ffb6bc;
  background: #130e10;
}
.coca-mode .discord-button {
  display: none;
}
.coca-mode .brand-mark {
  background: #eb2738;
  color: #fff;
}
.coca-mode .header {
  background: #130e10ee;
}
.coca-mode .navigation a[aria-current] {
  color: #ff929b;
}
.coca-mode .footer {
  border-color: #492229;
}
.cz-demo-banner {
  border-color: #59242c;
  background: #281418;
}
.cz-page {
  --cz-red: #e6293b;
  --cz-muted: #caa5ac;
  padding-top: 28px;
  color: #fff4f3;
}
.cz-topline {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--cz-muted);
  font-size: 10px;
  letter-spacing: 1.5px;
  padding: 0 0 22px;
  border-bottom: 1px solid #482129;
}
.cz-hero {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 32px;
  align-items: center;
  padding: 62px 0 52px;
}
.cz-kicker {
  display: block;
  color: #ff9fa9;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1.8px;
  line-height: 1.6;
}
.cz-hero h1 {
  margin: 22px 0;
  font: 750 clamp(52px, 6.5vw, 92px)/0.98 var(--font);
  letter-spacing: -4px;
}
.cz-hero h1 em {
  color: #ff5265;
  font-style: normal;
}
.cz-hero-copy > p {
  max-width: 390px;
  line-height: 1.8;
  font-size: 15px;
  color: var(--cz-muted);
}
.cz-owner {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 28px 0;
}
.cz-owner > div {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.cz-owner small {
  font-size: 11px;
  letter-spacing: 1.3px;
  color: var(--cz-muted);
}
.cz-owner strong {
  font: 650 18px var(--font);
  overflow-wrap: anywhere;
}
.cz-owner span {
  font-size: 11px;
  color: var(--cz-muted);
}
.cz-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 15px 20px;
  border: 1px solid #ff5265;
  border-radius: 9px;
  background: #d92032;
  color: #fff;
  font-weight: 600;
  min-height: 48px;
}
.cz-access-note {
  display: block;
  color: var(--cz-muted);
  max-width: 360px;
  font-size: 11px;
  line-height: 1.7;
  margin-top: 14px;
}
.cz-can-scene {
  position: relative;
  min-height: 480px;
  display: flex;
  align-items: center;
  justify-content: center;
  isolation: isolate;
  background: radial-gradient(ellipse, #b514293b 0, transparent 66%);
}
.cz-orbit {
  position: absolute;
  width: 92%;
  aspect-ratio: 1;
  border: 1px dashed #e54a5a44;
  border-radius: 50%;
  transform: rotate(-18deg) scaleY(0.72);
}
.cz-can {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 216px;
  height: 350px;
  background: linear-gradient(
    90deg,
    #801322,
    #e72337 18%,
    #f53447 35%,
    #c61529 76%,
    #7f101d
  );
  border-radius: 34px 34px 32px 32px / 15px 15px 18px 18px;
  transform: rotate(10deg);
  box-shadow:
    22px 40px 38px #0007,
    inset -7px 0 10px #0004;
  padding-top: 45px;
}
.cz-can-top {
  position: absolute;
  top: -9px;
  left: 8px;
  right: 8px;
  height: 30px;
  background: linear-gradient(#e4dadd, #6f6267 40%, #afa2a5 70%, #eedfe2);
  border-radius: 50%;
  border: 3px solid #e7d6db;
  box-shadow: inset 0 0 0 4px #8d7b81;
}
.cz-can-top i {
  position: absolute;
  width: 46px;
  height: 16px;
  background: #393035;
  border: 4px solid #d1bfc5;
  border-radius: 50%;
  top: 4px;
  left: 72px;
}
.cz-can-small {
  font-size: 9px;
  letter-spacing: 2px;
  margin-top: 16px;
}
.cz-can > strong {
  font:
    italic 800 62px/1.3 Georgia,
    serif;
  letter-spacing: -4px;
  transform: rotate(-12deg);
  margin: 12px 0 25px;
}
.cz-can-zero {
  font: 800 38px/0.88 var(--font);
  letter-spacing: -1.5px;
  text-align: center;
}
.cz-can-bottom {
  font-size: 7px;
  text-align: center;
  letter-spacing: 1.5px;
  line-height: 1.6;
  margin-top: 29px;
}
.cz-can-base {
  position: absolute;
  bottom: -4px;
  height: 15px;
  left: 8px;
  right: 8px;
  border-bottom: 7px solid #c5b6bb;
  border-radius: 50%;
}
.cz-sticker {
  position: absolute;
  right: 1%;
  bottom: 44px;
  width: 122px;
  height: 122px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #fff0e7;
  color: #52101a;
  text-align: center;
  font: 750 18px/1.1 var(--font);
  transform: rotate(-12deg);
  z-index: 2;
  box-shadow: 3px 5px 0 #73162a;
}
.cz-pschitt {
  position: absolute;
  bottom: -3px;
  background: transparent;
  border: 0;
  color: #ffb5bc;
  padding: 12px;
  font-size: 13px;
}
.cz-pop {
  position: absolute;
  top: 5px;
  right: 8%;
  color: #fff;
  font: 800 32px var(--font);
  opacity: 0;
  pointer-events: none;
  transform: rotate(-10deg);
}
.cz-can-scene.is-open .cz-pop {
  animation: cz-pop 800ms ease-out both;
}
@keyframes cz-pop {
  0% {
    opacity: 0;
    transform: translateY(8px) rotate(-10deg);
  }
  20%,
  65% {
    opacity: 1;
    transform: translateY(0) rotate(-10deg);
  }
  100% {
    opacity: 0;
    transform: translateY(-6px) rotate(-10deg);
  }
}
.cz-counter-panel {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 40px;
  padding: 34px 40px;
  background: #a91124;
  border: 1px solid #d53849;
  border-radius: 18px;
  margin: 20px 0 24px;
}
.cz-counter-panel .cz-kicker {
  color: #ffd3d6;
}
#coca-total {
  display: inline-block;
  font: 750 clamp(70px, 8vw, 116px)/1.1 var(--font);
  letter-spacing: -4px;
  margin: 12px 20px 0 0;
}
.cz-counter-unit {
  display: block;
  color: #ffced4;
  margin-top: 5px;
}
.cz-side-stats {
  display: grid;
  gap: 20px;
  border-left: 1px solid #ed778566;
  padding-left: 40px;
}
.cz-side-stats > div {
  display: flex;
  gap: 18px;
  align-items: baseline;
}
.cz-side-stats strong {
  font: 700 26px var(--font);
}
.cz-side-stats span {
  font-size: 12px;
  color: #ffd4d9;
}
.cz-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.cz-panel {
  padding: 30px;
  background: #221318;
  border: 1px solid #48232e;
  border-radius: 15px;
  min-width: 0;
}
.cz-panel h2 {
  font: 650 clamp(23px, 2.5vw, 30px)/1.2 var(--font);
  letter-spacing: -0.7px;
  margin: 12px 0;
}
.cz-panel p {
  color: var(--cz-muted);
  font-size: 13px;
  line-height: 1.7;
}
.cz-stamps {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 24px;
}
.cz-stamp {
  display: grid;
  gap: 9px;
  border: 1px dashed #65404b;
  border-radius: 9px;
  padding: 15px;
  color: #bc9ca6;
}
.cz-stamp.earned {
  color: #ffe9ec;
  border-color: #e84a60;
  background: #4d1a29;
}
.cz-stamp > span {
  font-size: 24px;
}
.cz-stamp strong {
  font: 600 14px/1.3 var(--font);
}
.cz-stamp small {
  font-size: 11px;
  color: #c8a5af;
}
.cz-bars {
  display: grid;
  grid-template-columns: repeat(14, minmax(0, 1fr));
  gap: 5px;
  padding: 24px 0 0;
  margin: 0;
  list-style: none;
}
.cz-bars li {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  gap: 10px;
}
.cz-bar-track {
  width: 100%;
  height: 160px;
  display: flex;
  align-items: end;
}
.cz-bar-track i {
  width: 100%;
  background: #ef4960;
  border-radius: 4px 4px 0 0;
}
.cz-bar-value {
  min-height: 14px;
  font-size: 11px;
  color: #ffcbd4;
}
.cz-bars small {
  font-size: 11px;
  color: #c7a1ac;
}
.cz-panel .cz-chart-note {
  font-size: 11px;
  margin-top: 16px;
}
.cz-diary {
  margin-top: 24px;
  scroll-margin-top: 100px;
}
.cz-diary-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 20px;
}
.cz-file-tag {
  font-size: 10px;
  letter-spacing: 1px;
  color: #ffa1b1;
  border: 1px dashed #9b4859;
  padding: 10px;
  transform: rotate(-4deg);
}
.cz-entry {
  display: flex;
  gap: 22px;
  padding: 20px 0;
  align-items: baseline;
  border-top: 1px solid #452630;
}
.cz-entry > div {
  flex: 1;
  min-width: 0;
}
.cz-entry-id {
  flex-shrink: 0;
  color: #e68095;
  font: 600 11px var(--font);
}
.cz-entry p {
  color: #fff0f3;
  margin: 0 0 9px;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}
.cz-entry time {
  color: #c39ca7;
  font-size: 11px;
}
.cz-entry-seal {
  font: 600 9px var(--font);
  color: #a88391;
  letter-spacing: 1px;
}
.cz-pagination {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  border-top: 1px solid #452630;
  padding-top: 20px;
  color: #caa5af;
  font-size: 11px;
}
.cz-pagination > div {
  display: flex;
  gap: 8px;
}
.cz-page-button {
  min-width: 42px;
  min-height: 42px;
  border: 1px solid #874052;
  background: #3e1d28;
  color: #fff;
  border-radius: 8px;
}
.cz-empty {
  padding: 45px 10px;
  text-align: center;
  color: #eaaab8;
}
.cz-empty > span {
  font-size: 45px;
}
.cz-empty code {
  color: #ffe1e8;
}
.cz-colophon {
  text-align: center;
  color: #ac8190;
  padding: 30px 0 0;
  font-size: 11px;
}
.cz-button:active,
.cz-page-button:active {
  transform: translateY(1px);
}
@media (hover: hover) and (pointer: fine) {
  .cz-button:hover {
    background: #ea2940;
  }
  .cz-page-button:hover {
    border-color: #e8849b;
  }
}
@media (max-width: 980px) {
  .cz-can {
    width: 184px;
    height: 315px;
  }
  .cz-can-top i {
    left: 56px;
  }
  .cz-can-small {
    font-size: 8px;
  }
  .cz-can > strong {
    font-size: 54px;
    margin-bottom: 20px;
  }
  .cz-can-bottom {
    margin-top: 20px;
  }
  .cz-sticker {
    width: 96px;
    height: 96px;
    font-size: 14px;
    right: 0;
  }
}
@media (max-width: 700px) {
  .cz-topline {
    font-size: 10px;
    letter-spacing: 0.8px;
  }
  .cz-hero {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 36px 0;
  }
  .cz-hero h1 {
    font-size: 62px;
    letter-spacing: -3px;
  }
  .cz-hero-copy > p {
    font-size: 14px;
  }
  .cz-can-scene {
    min-height: 370px;
  }
  .cz-can {
    width: 184px;
    height: 315px;
  }
  .cz-sticker {
    right: 9%;
    bottom: 28px;
  }
  .cz-counter-panel {
    grid-template-columns: 1fr;
    gap: 25px;
    padding: 25px;
  }
  .cz-side-stats {
    border-left: 0;
    border-top: 1px solid #ed778566;
    padding: 22px 0 0;
    gap: 14px;
  }
  .cz-side-stats > div {
    justify-content: space-between;
  }
  .cz-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }
  .cz-panel {
    padding: 22px 18px;
  }
  .cz-diary-heading {
    flex-direction: column;
    align-items: start;
  }
  .cz-entry {
    flex-wrap: wrap;
    gap: 10px;
  }
  .cz-entry-id {
    width: 100%;
  }
  .cz-entry-seal {
    display: none;
  }
  .cz-bar-track {
    height: 120px;
  }
}
@media (max-width: 370px) {
  .cz-hero h1 {
    font-size: 54px;
  }
  .cz-side-stats span {
    font-size: 11px;
  }
  .cz-stamps {
    gap: 9px;
  }
  .cz-stamp {
    padding: 11px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .cz-can-scene.is-open .cz-pop {
    animation: none;
    opacity: 1;
  }
  .cz-button:active,
  .cz-page-button:active {
    transform: none;
  }
}
/* ==== Theme-aware emphasis ==== */
.closing-banner .eyebrow {
  font-size: 10px;
  color: var(--accent-ink, var(--lime));
  margin-bottom: 14px;
  color: var(--banner-accent, var(--lime));
}
.day-picker input {
  font: inherit;
  color: inherit;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  color-scheme: dark;
  color-scheme: var(--theme-scheme, dark);
}

/* Theme-aware emphasis surfaces keep their text independent of the accent fill. */
.closing-banner,
.leaderboard-goal,
.forecast,
.dialog-note,
.chart-tooltip {
  color: var(--banner-ink, var(--text));
}
.event-announcement h2,
.rewind-announcement > span,
.day-summary strong {
  color: var(--accent-ink, var(--lime));
}
@media (max-width: 980px) {
  .closing-banner .eyebrow {
    font-size: 10px;
  }
}
@media (max-width: 700px) {
  .closing-banner .eyebrow {
    font-size: 10px;
    letter-spacing: 0.8px;
  }
}
/* ==== Print ==== */
@media print {
  .header,
  .footer,
  .source-banner,
  .button,
  .race-controls,
  .chart-ranges,
  .segmented {
    display: none;
  }
  body {
    background: #fff;
    color: #111;
  }
  main {
    margin: 0;
    max-width: none;
  }
  .panel,
  .record-card {
    break-inside: avoid;
  }
  .profile-hero {
    break-after: avoid;
  }
}
