/* WristLog Micro at Micro Praha, the public showcase and stats.
   Always dark: the blue sunburst dial of the booth's showcase screen. */

@font-face {
  font-family: "DM Sans";
  font-weight: 400 700;
  font-display: swap;
  src: url("fonts/dm-sans-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "DM Sans";
  font-weight: 400 700;
  font-display: swap;
  src: url("fonts/dm-sans-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "JetBrains Mono";
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/jetbrains-mono-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "JetBrains Mono";
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/jetbrains-mono-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  color-scheme: dark;
  --sans: "DM Sans", ui-sans-serif, system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;

  --dial-1: #1b4a7e;
  --dial-2: #0d2849;
  --dial-3: #050f1e;
  --lume: #eef2e4;
  --steel: #a9b9cc;
  --steel-2: #6f86a2;
  --hand: #f5b544;

  /* Stats cards and chart chrome */
  --surface: #0c1e38;
  --line: #1c3354;
  --grid: #172c4b;
  --axis: #2a4469;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--dial-3);
  color: var(--lume);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p {
  margin: 0;
}

a {
  color: inherit;
}

img {
  display: block;
}

:focus-visible {
  outline: 2px solid var(--hand);
  outline-offset: 2px;
}

[hidden] {
  display: none !important;
}

/* The plate: a sunburst centred on its box. */
.dial::before {
  content: "";
  position: absolute;
  inset: -100vmax;
  z-index: -1;
  background:
    conic-gradient(from 300deg, transparent, rgb(255 255 255 / 0.07) 30deg, transparent 70deg 180deg, rgb(255 255 255 / 0.05) 210deg, transparent 250deg),
    repeating-conic-gradient(rgb(255 255 255 / 0.018) 0 0.4deg, transparent 0.4deg 1.2deg),
    radial-gradient(circle closest-side, var(--dial-1), var(--dial-2) 14%, var(--dial-3) 42%);
}

.brandmark {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--steel);
  text-decoration: none;
}

.brandmark img {
  width: 1.9em;
  height: 1.9em;
}

.brandmark b {
  font-weight: 700;
  color: var(--lume);
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 14px;
  border-radius: 99px;
  background: rgb(255 255 255 / 0.1);
  color: var(--lume);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.15s ease;
}

.nav-link:hover {
  background: rgb(255 255 255 / 0.16);
}

/* ------------------------------------------------------------------ */
/* Showcase: every watch floating on the dial, one at a time in the spotlight. */

.sc-body {
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
}

[data-idle],
[data-idle] * {
  cursor: none;
}

.sc-screen {
  display: grid;
  grid-template-columns: clamp(340px, 27vw, 560px) minmax(0, 1fr);
  height: 100%;
}

.sc-field {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  touch-action: manipulation;
}

/* One watch. Laid out at its own size; scaled on the way to and from the
   spotlight. */
.sc-watch {
  position: absolute;
  top: 0;
  left: 0;
  overflow: hidden;
  border-radius: 50%;
  background: var(--dial-2);
  /* A ring only: a soft shadow on every watch is costly to draw. The watch in
     the spotlight gets one. */
  box-shadow: 0 0 0 0.35vmin var(--steel);
  transform-origin: 0 0;
  will-change: transform;
  cursor: pointer;
}

.sc-watch img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  user-select: none;
  -webkit-user-drag: none;
}

.sc-watch.is-featured {
  z-index: 1;
  box-shadow: 0 0 0 0.45vmin var(--hand), 0 2vmin 6vmin rgb(0 0 0 / 0.6);
}

.sc-panel {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 4vh;
  min-width: 0;
  padding: 7vh 1.5vw 6vh 4vw;
  background: linear-gradient(90deg, rgb(5 15 30 / 0.85), rgb(5 15 30 / 0.55) 75%, transparent);
}

.sc-panel .brandmark {
  font-size: 2vh;
}

.sc-caption {
  margin-block: auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  transition: opacity 0.4s ease, translate 0.4s ease;
}

.sc-caption.is-leaving {
  opacity: 0;
  translate: 0 1.5vh;
}

.sc-highlight {
  font-size: 2.1vh;
  color: var(--hand);
  text-wrap: balance;
}

/* --fit shrinks a long one-word brand so it doesn't break mid-word. */
.sc-name {
  margin-top: 0.6vh;
  font-size: calc(clamp(2.5rem, 8.5vh, 7.5rem) * var(--fit, 1));
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.035em;
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.sc-model {
  margin-top: 1.4vh;
  font-size: 4vh;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--steel);
  text-wrap: balance;
}

.sc-reference {
  margin-top: 1.2vh;
  font-family: var(--mono);
  font-size: 2.4vh;
  color: var(--steel-2);
}

.sc-movement {
  display: flex;
  align-items: center;
  gap: 1.1vh;
  margin-top: 3vh;
  font-size: 2.3vh;
  font-weight: 500;
}

.sc-dot {
  flex-shrink: 0;
  width: 1.3vh;
  height: 1.3vh;
  border-radius: 50%;
  box-shadow: 0 0 0 0.25vh rgb(255 255 255 / 0.15);
}

.sc-calibre {
  font-family: var(--mono);
  font-weight: 400;
  color: var(--steel);
}

.sc-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  font-size: 14px;
  color: var(--steel);
}

.sc-narrow {
  display: none;
}

.sc-hint {
  position: fixed;
  right: 2vh;
  bottom: 2vh;
  z-index: 2;
  display: flex;
  gap: 8px;
  transition: opacity 0.6s ease;
}

.sc-hint .nav-link {
  height: 32px;
  font-size: 13px;
  color: var(--steel);
  border: 0;
  font-family: inherit;
  cursor: pointer;
}

.sc-hint .nav-link:hover {
  color: var(--lume);
}

kbd {
  padding: 1px 6px;
  border-radius: 5px;
  background: rgb(255 255 255 / 0.12);
  font-family: var(--mono);
  font-size: 11px;
}

:fullscreen .sc-hint,
[data-idle] .sc-hint {
  opacity: 0;
  pointer-events: none;
}

/* Phones and portrait screens: the caption above, the dial below. */
@media (max-aspect-ratio: 1/1) {
  .sc-screen {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
  }

  .sc-panel {
    height: clamp(220px, 36vh, 400px);
    gap: 2vh;
    padding: 4vw 5vw 2vh;
    background: linear-gradient(180deg, rgb(5 15 30 / 0.9), rgb(5 15 30 / 0.6) 80%, transparent);
  }

  .sc-panel .brandmark {
    font-size: 14px;
  }

  .sc-caption {
    margin-block: auto 0;
  }

  .sc-highlight {
    font-size: 14px;
  }

  .sc-name {
    font-size: calc(clamp(2rem, 9vw, 4.5rem) * var(--fit, 1));
  }

  .sc-model {
    margin-top: 0.8vh;
    font-size: clamp(1.1rem, 4.6vw, 2.2rem);
  }

  .sc-reference {
    font-size: 13px;
  }

  .sc-movement {
    margin-top: 1.4vh;
    gap: 8px;
    font-size: 14px;
  }

  .sc-dot {
    width: 9px;
    height: 9px;
  }

  .sc-footer {
    position: absolute;
    top: 4vw;
    right: 5vw;
  }

  .sc-footer .sc-count,
  .sc-wide {
    display: none;
  }

  .sc-hint {
    display: none;
  }

  .sc-narrow {
    display: inline;
  }
}

@media (prefers-reduced-motion: reduce) {
  .sc-caption {
    transition-duration: 0.01s;
  }
}

/* ------------------------------------------------------------------ */
/* Stats */

.st-body {
  position: relative;
  isolation: isolate;
  overflow-x: hidden;
  min-height: 100vh;
}

/* The dial peeks out from behind the top of the page. */
.st-body::before {
  content: "";
  position: absolute;
  top: -60vmax;
  left: 50%;
  width: 140vmax;
  height: 140vmax;
  translate: -50% 0;
  z-index: -1;
  background:
    repeating-conic-gradient(rgb(255 255 255 / 0.018) 0 0.4deg, transparent 0.4deg 1.2deg),
    radial-gradient(circle closest-side, var(--dial-1), var(--dial-2) 30%, var(--dial-3) 70%);
  mask-image: radial-gradient(circle closest-side, black 40%, transparent);
}

.st-page {
  max-width: 1120px;
  margin: 0 auto;
  padding: 28px 24px 64px;
}

.st-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 15px;
}

.st-hero {
  padding: 72px 0 48px;
}

.st-hero-figure {
  font-size: clamp(5rem, 16vw, 10rem);
  font-weight: 700;
  line-height: 0.85;
  letter-spacing: -0.05em;
}

.st-hero-text {
  max-width: 34ch;
  margin-top: 20px;
  font-size: clamp(1.25rem, 2.6vw, 1.75rem);
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--steel);
  text-wrap: balance;
}

.st-hero-text b {
  color: var(--lume);
  font-weight: 600;
}

.st-tiles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 40px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
}

.st-tile {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 18px 20px;
}

.st-tile + .st-tile {
  border-left: 1px solid var(--line);
}

.st-tile-value {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.st-tile-label {
  font-size: 13px;
  line-height: 1.35;
  color: var(--steel);
}

.st-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 24px;
}

.st-card {
  grid-column: span 6;
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
}

.st-card.is-wide {
  grid-column: 1 / -1;
}

.st-card.is-tall {
  grid-row: span 2;
}

.st-card-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.st-card-sub {
  margin-top: 6px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--steel);
  text-wrap: pretty;
}

/* Ranked horizontal bars: name, bar, value at the tip. */
.st-bars {
  display: flex;
  flex-direction: column;
}

.st-bar-row {
  display: grid;
  grid-template-columns: var(--label-width, 11rem) minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 34px;
  border-radius: 8px;
  outline-offset: 0;
}

.st-bar-row:hover .st-bar,
.st-bar-row:focus-visible .st-bar {
  filter: brightness(1.15);
}

.st-bar-name {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-size: 14px;
  font-weight: 500;
}

.st-bar-name span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.st-bar-name img {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 0 1.5px var(--steel-2);
}

.st-bar-track {
  display: flex;
  align-items: center;
  gap: 8px;
}

.st-bar {
  height: 14px;
  min-width: 2px;
  border-radius: 0 4px 4px 0;
  background: var(--hand);
}

.st-bar-value {
  font-size: 13px;
  white-space: nowrap;
  color: var(--steel);
  font-variant-numeric: tabular-nums;
}

.st-bar-value b {
  font-weight: 600;
  color: var(--lume);
}

/* Columns with a y axis. */
.st-columns {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  grid-template-rows: var(--plot-height, 200px) auto;
}

.st-y-axis {
  position: relative;
}

.st-y-axis span,
.st-x-axis span {
  font-size: 12px;
  color: var(--steel);
  font-variant-numeric: tabular-nums;
}

.st-y-axis span {
  position: absolute;
  right: 8px;
  translate: 0 50%;
}

.st-plot {
  position: relative;
  display: flex;
  align-items: flex-end;
  border-bottom: 1px solid var(--axis);
}

.st-gridline {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px solid var(--grid);
}

.st-col {
  position: relative;
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  height: 100%;
  border-radius: 4px 4px 0 0;
  outline-offset: -2px;
}

.st-col-bar {
  width: min(24px, 70%);
  border-radius: 4px 4px 0 0;
  background: var(--hand);
}

.st-col.is-muted .st-col-bar {
  background: var(--steel-2);
}

.st-col:hover .st-col-bar,
.st-col:focus-visible .st-col-bar {
  filter: brightness(1.15);
}

.st-col-label {
  margin-bottom: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--lume);
}

.st-x-axis {
  grid-column: 2;
  display: flex;
  padding-top: 8px;
}

.st-x-axis span {
  flex: 1 1 0;
  text-align: center;
  white-space: nowrap;
}

.st-days {
  display: grid;
  grid-template-columns: var(--days, repeat(2, minmax(0, 1fr)));
  gap: 32px;
}

.st-day-title {
  margin-bottom: 14px;
  font-size: 14px;
  font-weight: 600;
}

.st-day-title span {
  font-weight: 400;
  color: var(--steel);
}

/* The tall segmented bar for movement types. */
.st-split {
  display: flex;
  gap: 2px;
  height: 28px;
}

.st-split-part {
  display: flex;
  align-items: center;
  min-width: 0;
  padding-left: 8px;
  border-radius: 4px;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

.st-split-part:hover,
.st-split-part:focus-visible {
  filter: brightness(1.15);
}

.st-legend {
  display: flex;
  flex-direction: column;
}

.st-legend-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  border-top: 1px solid var(--line);
  font-size: 14px;
  font-weight: 500;
}

.st-legend-row .st-bar-value {
  margin-left: auto;
}

.st-swatch {
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-radius: 3px;
}

/* Watches logged more than once. */
.st-twins {
  display: flex;
  flex-direction: column;
}

.st-twin {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 4px 16px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.st-twin:first-child {
  border-top: 0;
  padding-top: 0;
}

.st-twin-name {
  font-size: 15px;
  font-weight: 600;
}

.st-twin-name span {
  font-weight: 400;
  color: var(--steel);
}

.st-twin-count {
  font-size: 13px;
  color: var(--steel);
}

.st-twin-count b {
  color: var(--lume);
}

.st-twin-photos {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.st-twin-photos img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 0 2px var(--steel-2);
}

.st-tooltip {
  position: fixed;
  z-index: 10;
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-width: 260px;
  padding: 8px 12px;
  border: 1px solid var(--axis);
  border-radius: 10px;
  background: #081629;
  box-shadow: 0 8px 24px rgb(0 0 0 / 0.4);
  font-size: 13px;
  color: var(--steel);
  pointer-events: none;
}

.st-tooltip b {
  font-size: 15px;
  font-weight: 600;
  color: var(--lume);
}

.st-footer {
  margin-top: 48px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--steel);
}

@media (max-width: 860px) {
  .st-card,
  .st-card.is-tall {
    grid-column: 1 / -1;
    grid-row: auto;
  }
}

@media (max-width: 560px) {
  .st-page {
    padding-inline: 16px;
  }

  .st-hero {
    padding-top: 48px;
  }

  .st-card {
    padding: 18px;
  }

  .st-days {
    grid-template-columns: none;
  }

  .st-tiles {
    grid-template-columns: none;
  }

  .st-tile + .st-tile {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .st-bar-row {
    --label-width: 7.5rem;
  }
}
