/* Universitetni Sindir — public board.
   Layout, spacing and type scale follow sindr.uz one-to-one. Light is the
   only automatic theme; dark is opt-in through `data-theme="dark"`. */

@font-face {
  font-family: "DM Sans";
  src: url(/static/fonts/dm-sans-latin.woff2) format("woff2");
  font-style: normal;
  font-weight: 100 1000;
  font-display: swap;
}

:root {
  color: #031633;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  /* Brand: #1AA4FF on #031633. Everything else is a tint or shade of those
     two, so the palette stays one family rather than a set of guesses. */
  --background: #f7fbff;
  --foreground: #031633;
  --card: #ffffff;
  --primary: #1aa4ff;
  --primary-strong: #0b5f9e;
  --primary-action: #1aa4ff;
  --primary-action-foreground: #fff;
  --primary-shadow: #0d7ac9;
  --primary-soft: #dbeeff;
  --muted: #eef4fb;
  --muted-foreground: #5a6b80;
  --border: #d9e4f0;
  --live: #0f7a35;
  --focus: #0b5f9e;
  --error: #b42318;
  --shadow: 0 12px 50px #03163314;
  background: #f7fbff;
  font-family: "DM Sans", Arial, sans-serif;
}

:root[data-theme="dark"] {
  color: #eaf2fb;
  /* The dark ground is the brand navy itself. */
  --background: #031633;
  --foreground: #eaf2fb;
  --card: #08213f;
  --primary-strong: #6cc4ff;
  --primary-soft: #0c3560;
  --muted: #0c2748;
  --muted-foreground: #93a7bf;
  --border: #ffffff1f;
  --live: #50c05f;
  --focus: #8bc4ff;
  --error: #ff9b8f;
  --shadow: 0 12px 50px #0000005c;
  background: #031633;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; min-width: 320px; min-height: 100%; }

body {
  background: var(--background);
  min-width: 320px;
  min-height: 100vh;
  color: var(--foreground);
  -webkit-font-smoothing: antialiased;
  margin: 0;
}

a { color: inherit; text-decoration: none; }
button { color: inherit; font-family: inherit; }

:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 8px; }

.sr-only {
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  position: absolute;
  overflow: hidden;
}

.app-shell { min-height: 100vh; }

/* --- header --- */

.site-header { height: 69px; }

.header-inner {
  justify-content: space-between;
  align-items: center;
  width: min(100% - 32px, 864px);
  height: 69px;
  margin: 0 auto;
  display: flex;
}

.header-brand-group { align-items: center; gap: 12px; min-width: 0; display: flex; }
.brand-lockup { align-items: center; gap: 7px; display: inline-flex; }
.brand-mark { flex: none; place-items: center; width: 32px; height: 32px; display: grid; }
.brand-mark img { object-fit: contain; width: 100%; height: 100%; display: block; }
.brand-link { letter-spacing: -0.035em; align-items: center; font-size: 20px; font-weight: 600; display: inline-flex; }

.board-period-switch {
  border: 1px solid var(--border);
  background: var(--muted);
  border-radius: 999px;
  align-items: center;
  gap: 2px;
  padding: 3px;
  display: inline-flex;
}

.board-period-switch a {
  min-height: 28px;
  color: var(--muted-foreground);
  white-space: nowrap;
  border-radius: 999px;
  justify-content: center;
  align-items: center;
  gap: 4px;
  padding: 0 9px;
  font-size: 11px;
  font-weight: 650;
  transition: background-color 0.14s, color 0.14s, box-shadow 0.14s;
  display: inline-flex;
}

.board-period-switch a:hover { color: var(--foreground); }
.board-period-switch a.selected { background: var(--card); color: var(--primary-strong); box-shadow: 0 1px 4px #03163314; }

.header-actions { align-items: center; gap: 15px; display: flex; }
.header-actions nav { align-items: center; gap: 28px; font-size: 14px; display: flex; }
.header-actions nav a {
  min-height: 40px;
  color: var(--muted-foreground);
  align-items: center;
  transition: color 0.16s;
  display: inline-flex;
}
.header-actions nav a:hover, .header-actions nav a.active { color: var(--foreground); }
.header-actions nav a.active { font-weight: 600; }

.language-picker { z-index: 30; position: relative; }

.language-trigger {
  min-width: 58px;
  min-height: 38px;
  color: var(--foreground);
  cursor: pointer;
  background: none;
  border: 1px solid transparent;
  border-radius: 12px;
  justify-content: center;
  align-items: center;
  gap: 6px;
  padding: 0 9px;
  font-size: 13px;
  font-weight: 650;
  transition: border-color 0.14s, background-color 0.14s;
  display: inline-flex;
}

.language-trigger:hover, .language-trigger[aria-expanded="true"] { border-color: var(--border); background: var(--card); }
.language-trigger svg { color: var(--muted-foreground); transition: transform 0.14s; }
.language-trigger[aria-expanded="true"] svg { transform: rotate(180deg); }

.language-menu {
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 14px;
  padding: 5px;
  position: absolute;
  top: calc(100% + 6px);
  inset-inline-end: 0;
  min-width: 148px;
  box-shadow: 0 18px 42px #03163314;
  display: none;
}

.language-menu.open { display: grid; }

.language-menu a {
  border-radius: 10px;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 0 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted-foreground);
  display: flex;
}

.language-menu a:hover { background: var(--muted); color: var(--foreground); }
.language-menu a.selected { color: var(--primary-strong); background: color-mix(in srgb, var(--primary) 8%, transparent); }

/* --- shell --- */

.page-container { width: min(100%, 896px); margin: 0 auto; padding: 16px 16px 0; }

.live-wrap { text-align: center; min-height: 68px; }

.live-pill {
  background: var(--muted);
  max-width: 100%;
  color: var(--muted-foreground);
  white-space: nowrap;
  border-radius: 999px;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  font-size: 14px;
  line-height: 20px;
  display: inline-flex;
}

.live-pill strong { color: var(--live); font-weight: 500; }

.live-dot {
  background: var(--live);
  width: 8px;
  height: 8px;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--live) 12%, transparent);
  border-radius: 50%;
  flex: none;
  position: relative;
}

.tiny-dot { background: var(--primary); border-radius: 50%; flex: none; width: 6px; height: 6px; position: relative; }

.live-dot:after, .tiny-dot:after {
  content: "";
  border-radius: inherit;
  pointer-events: none;
  position: absolute;
  inset: 0;
  will-change: transform, opacity;
  animation: 1.8s cubic-bezier(0.2, 0, 0, 1) infinite signal-pulse;
}

.live-dot:after { background: var(--live); }
.tiny-dot:after { background: var(--primary); }

@keyframes signal-pulse {
  0% { opacity: 0.55; transform: scale(1); }
  70% { opacity: 0; transform: scale(2.4); }
  100% { opacity: 0; transform: scale(2.4); }
}

@media (prefers-reduced-motion: reduce) {
  .live-dot:after, .tiny-dot:after { animation: none; }
  html { scroll-behavior: auto; }
}

.live-desktop { display: inline; }
.live-mobile { display: none; }

@media (max-width: 900px) {
  .live-desktop { display: none; }
  .live-mobile { display: inline; }
}


 .claim-url-field { position: relative; }
.url-field__results {
  position: absolute;
  top: calc(100% + 8px);
  inset-inline: 0;
  z-index: 30;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: 0 18px 50px #03163322;
  overflow: hidden;
  display: none;
}
.url-field__results.open { display: block; }

.search-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 14px;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: none;
  width: 100%;
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: inherit;
}
.search-item:hover { background: var(--muted); }
.search-item:last-child { border-bottom: 0; }
.search-item__logo {
  width: 36px; height: 36px; border-radius: 9px; object-fit: cover;
  background: var(--muted); flex: none;
  display: grid; place-items: center; font-weight: 700; color: var(--muted-foreground);
}
.search-item__body { min-width: 0; flex: 1; }
.search-item__name { font-weight: 650; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-item__meta { font-size: 12px; color: var(--muted-foreground); display: flex; gap: 8px; align-items: center; }
.search-item__place { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-item__badge { color: var(--primary-strong); font-weight: 650; }
.search-item__badge--web {
  color: var(--muted-foreground);
  background: var(--muted);
  border-radius: 999px;
  padding: 1px 8px;
  font-weight: 600;
}

/* --- intro --- */

.intro-copy { text-align: center; max-width: 720px; margin: 0 auto 24px; }
.intro-copy p { color: var(--muted-foreground); text-wrap: pretty; margin: 0; font-size: 17px; line-height: 1.5; }
.intro-copy p > span { display: block; }
.intro-copy strong {
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--muted);
  color: var(--primary);
  font-weight: 500;
  font-size: 13px;
  line-height: 18px;
  border-radius: 999px;
  padding: 5px 12px;
  white-space: nowrap;
}
.intro-copy .intro-lead { color: var(--foreground); margin: 0 0 8px; font-weight: 700; }
.intro-copy.today-intro .intro-lead { margin-bottom: 0; }

/* --- bid section --- */

.bid-section { text-align: center; scroll-margin-top: 24px; }

.bid-heading-row {
  color: var(--foreground);
  letter-spacing: -0.04em;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px;
  font-size: 40px;
  font-weight: 700;
  line-height: 60px;
  display: flex;
}

.bid-section h1 { font: inherit; letter-spacing: inherit; white-space: nowrap; margin: 0; }

.amount-control { color: var(--primary-strong); justify-content: center; align-items: center; gap: 8px; display: inline-flex; }

.amount-control > button {
  border: 1px solid var(--primary-shadow);
  background: var(--primary-action);
  width: 24px;
  height: 24px;
  color: var(--primary-action-foreground);
  box-shadow: 0 3px 0 var(--primary-shadow);
  cursor: pointer;
  border-radius: 50%;
  place-items: center;
  padding: 0;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  transition: transform 0.12s, box-shadow 0.12s, opacity 0.12s;
  display: grid;
  position: relative;
  overflow: visible;
}

.amount-control > button:after { content: ""; position: absolute; inset: -9px; }
.amount-control > button:hover:not(:disabled) { box-shadow: 0 4px 0 var(--primary-shadow); transform: translateY(-1px); }
.amount-control > button:active:not(:disabled) { box-shadow: 0 1px 0 var(--primary-shadow); transform: translateY(2px) scale(0.96); }
.amount-control > button:disabled { opacity: 0.45; cursor: not-allowed; }

.currency-field { align-items: baseline; gap: 6px; display: inline-flex; }

.amount-value {
  border-bottom: 2px dashed color-mix(in srgb, var(--primary-strong) 65%, transparent);
  min-width: 3ch;
  display: inline-grid;
  position: relative;
}

.amount-sizer { visibility: hidden; white-space: nowrap; grid-area: 1 / 1; padding-inline: 2px; }
.amount-editor { align-items: baseline; display: flex; position: absolute; inset: 0; }

.currency-field input {
  width: 100%;
  min-width: 0;
  color: inherit;
  font: inherit;
  line-height: inherit;
  letter-spacing: inherit;
  text-align: center;
  caret-color: var(--primary-strong);
  appearance: textfield;
  background: none;
  border: 0;
  outline: none;
  padding: 0 2px;
}

.amount-value:focus-within { border-bottom-style: solid; }
.amount-value input:focus-visible { box-shadow: none; outline: none; }
.currency-code { letter-spacing: -0.02em; font-size: 0.48em; font-weight: 600; }

.bid-rule { color: var(--muted-foreground); margin: 4px 0 0; font-size: 12px; line-height: 1.45; }

.bid-section form {
  grid-template-columns: minmax(0, 1fr) minmax(210px, 0.48fr) auto;
  align-items: start;
  gap: 7px 9px;
  margin-top: 22px;
  padding-bottom: 6px;
  display: grid;
}

.url-field { grid-area: 1 / 1; align-items: center; min-width: 0; display: flex; position: relative; }
.url-field svg { color: var(--muted-foreground); pointer-events: none; position: absolute; left: 14px; }

.url-field input {
  border: 1px solid var(--border);
  width: 100%;
  height: 44px;
  color: var(--foreground);
  background: none;
  border-radius: 20px;
  padding: 4px 14px 4px 42px;
  font-size: 16px;
  font-family: inherit;
  transition: border-color 0.16s, box-shadow 0.16s;
}

.url-field input::placeholder { color: var(--muted-foreground); opacity: 0.88; }
.url-field input:focus {
  border-color: color-mix(in srgb, var(--primary) 65%, var(--border));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 12%, transparent);
  outline: none;
}
.url-field input[aria-invalid="true"] { border-color: var(--error); }

.category-select-field { grid-area: 1 / 2; min-width: 0; position: relative; }

.category-select-trigger {
  border: 1px solid var(--border);
  width: 100%;
  min-width: 0;
  height: 44px;
  color: var(--foreground);
  text-align: left;
  cursor: pointer;
  background: none;
  border-radius: 20px;
  grid-template-columns: 18px minmax(0, 1fr) 16px;
  align-items: center;
  gap: 9px;
  padding: 4px 12px;
  font-size: 14px;
  transition: border-color 0.16s, box-shadow 0.16s, background-color 0.16s;
  display: grid;
}

.category-select-trigger > svg { color: var(--muted-foreground); }
.category-select-trigger > svg:last-child { transition: transform 0.14s; }
.category-select-trigger[aria-expanded="true"] {
  border-color: color-mix(in srgb, var(--primary) 65%, var(--border));
  background: var(--card);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 12%, transparent);
}
.category-select-trigger[aria-expanded="true"] > svg:last-child { transform: rotate(180deg); }
.category-select-trigger[aria-invalid="true"] { border-color: var(--error); }
.category-select-value { text-overflow: ellipsis; white-space: nowrap; overflow: hidden; }

.category-select-menu {
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 18px;
  padding: 6px;
  position: absolute;
  top: calc(100% + 6px);
  inset-inline: 0;
  z-index: 25;
  max-height: 288px;
  overflow-y: auto;
  box-shadow: 0 18px 42px #03163318;
  display: none;
}

.category-select-menu.open { display: grid; }

.category-select-option {
  border: 0;
  background: none;
  text-align: left;
  cursor: pointer;
  border-radius: 12px;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted-foreground);
  display: flex;
}

.category-select-option:hover { background: var(--muted); color: var(--foreground); }
.category-select-option-check { margin-inline-start: auto; color: var(--primary); }

.url-supported {
  color: var(--muted-foreground);
  text-align: left;
  grid-area: 2 / 1 / auto / 3;
  margin: 0 0 0 3px;
  font-size: 12px;
  line-height: 1.4;
}

.primary-button {
  border: 1px solid var(--primary-shadow);
  background: var(--primary-action);
  min-width: 174px;
  height: 44px;
  color: var(--primary-action-foreground);
  box-shadow: 0 6px 0 var(--primary-shadow);
  cursor: pointer;
  border-radius: 18px;
  grid-area: 1 / 3;
  padding: 0 20px;
  font-size: 14px;
  font-weight: 750;
  transition: transform 0.12s, box-shadow 0.12s, filter 0.12s, opacity 0.12s;
}

.primary-button:hover:not(:disabled) { filter: brightness(1.03); box-shadow: 0 7px 0 var(--primary-shadow); transform: translateY(-1px); }
.primary-button:active:not(:disabled) { box-shadow: 0 1px 0 var(--primary-shadow); transform: translateY(5px) scale(0.96); }
.primary-button:disabled { opacity: 0.5; box-shadow: 0 3px 0 var(--primary-shadow); cursor: not-allowed; }

.bid-section .bid-helper { max-width: none; margin: 12px 0 0; font-size: 12px; color: var(--muted-foreground); }
.bid-helper.error { color: var(--error); font-weight: 650; }

.provider-switch { margin-top: 12px; }
.provider-switch button {
  min-height: 28px;
  color: var(--muted-foreground);
  white-space: nowrap;
  border: 0;
  border-radius: 999px;
  background: none;
  cursor: pointer;
  padding: 0 11px;
  font-size: 11px;
  font-weight: 650;
  transition: background-color 0.14s, color 0.14s, box-shadow 0.14s;
}
.provider-switch button.selected { background: var(--card); color: var(--primary-strong); box-shadow: 0 1px 4px #03163314; }

/* --- brand preview --- */

.brand-preview {
  border: 1px solid var(--border);
  background: var(--card);
  text-align: left;
  border-radius: 18px;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  padding: 13px 15px;
  display: none;
  box-shadow: 0 8px 30px #0316330d;
}

.brand-preview.visible { display: grid; }
.brand-preview-copy { flex-direction: column; gap: 2px; min-width: 0; display: flex; }
.brand-preview-copy > strong { text-overflow: ellipsis; white-space: nowrap; font-size: 14px; line-height: 19px; overflow: hidden; }
.brand-preview-copy > span:last-child {
  -webkit-line-clamp: 2;
  color: var(--muted-foreground);
  -webkit-box-orient: vertical;
  font-size: 12px;
  line-height: 1.4;
  display: -webkit-box;
  overflow: hidden;
}
.brand-preview-source { color: var(--primary-strong); align-items: center; gap: 5px; font-size: 11px; font-weight: 650; display: flex; }
.brand-preview-bid { white-space: nowrap; flex-direction: column; align-items: flex-end; gap: 1px; display: flex; }
.brand-preview-bid small, .brand-preview-bid span { color: var(--muted-foreground); font-size: 11px; }
.brand-preview-bid strong { color: var(--primary-strong); font-size: 14px; }

/* --- avatars --- */

.brand-avatar { object-fit: cover; background: none; border-radius: 20%; flex: none; width: 19px; height: 19px; }
.brand-avatar.large { width: 56px; height: 56px; }
.brand-preview > .brand-avatar.large, .brand-preview > .mini-avatar.large { width: 48px; height: 48px; }

.mini-avatar {
  color: #fff;
  border-radius: 6px;
  flex: none;
  place-items: center;
  width: 19px;
  height: 19px;
  font-size: 10px;
  font-weight: 700;
  display: grid;
  box-shadow: inset 0 0 0 1px #ffffff40;
}

.mini-avatar.large { border-radius: 14px; width: 56px; height: 56px; font-size: 18px; }
.mini-avatar.coral { background: linear-gradient(145deg, #f5a48e, #d9664c); }
.mini-avatar.violet { background: linear-gradient(145deg, #a98cf7, #7144de); }
.mini-avatar.teal { background: linear-gradient(145deg, #58c9bd, #248d82); }
.mini-avatar.gold { background: linear-gradient(145deg, #f2c66d, #c8932f); }
.mini-avatar.blue { background: linear-gradient(145deg, #73aef4, #3975c4); }

.source-monogram {
  letter-spacing: 0;
  border: 1px solid;
  border-radius: 4px;
  place-items: center;
  min-width: 18px;
  height: 16px;
  padding: 0 2px;
  font-size: 8px;
  line-height: 1;
  display: inline-grid;
}

/* --- category filters --- */

.category-filters {
  overscroll-behavior-inline: contain;
  scrollbar-width: none;
  align-items: center;
  gap: 7px;
  width: 100%;
  padding: 2px 2px 5px;
  display: flex;
  overflow-x: auto;
}

.category-filters::-webkit-scrollbar { display: none; }

.category-filters a {
  min-height: 38px;
  color: var(--muted-foreground);
  font: inherit;
  white-space: nowrap;
  cursor: pointer;
  background: none;
  border: 1px solid transparent;
  border-radius: 999px;
  flex: none;
  justify-content: center;
  align-items: center;
  gap: 7px;
  padding: 0 13px;
  font-size: 13px;
  font-weight: 650;
  transition: color 0.14s, background-color 0.14s, border-color 0.14s;
  display: inline-flex;
}

.category-filters a:hover, .category-filters a:focus-visible { color: var(--foreground); background: var(--muted); }
.category-filters a.selected { border-color: var(--primary); background: var(--primary); color: #fff; }

/* --- leaderboard --- */

.leaderboard-list { flex-direction: column; margin-top: 2px; scroll-margin-top: 20px; display: flex; }

.leaderboard-empty {
  border: 1px dashed color-mix(in srgb, var(--primary) 42%, var(--border));
  background: color-mix(in srgb, var(--primary) 4%, var(--card));
  text-align: center;
  border-radius: 24px;
  place-content: center;
  justify-items: center;
  gap: 7px;
  min-height: 220px;
  padding: 34px;
  display: grid;
}

.leaderboard-empty strong { letter-spacing: -0.03em; font-size: 22px; }
.leaderboard-empty p { max-width: 430px; color: var(--muted-foreground); margin: 0; font-size: 14px; line-height: 1.5; }

.listing-card { transition: border-color 0.16s, background-color 0.16s; position: relative; overflow: hidden; }

.listing-card.top-three {
  border: 2px solid color-mix(in srgb, var(--primary) 26%, var(--border));
  background: color-mix(in srgb, var(--primary) 3%, var(--card));
  border-radius: 28px;
  margin-top: 12px;
}

.listing-card.top-three:first-child { margin-top: 0; }
.listing-card.top-three[data-rank="1"] {
  border-color: color-mix(in srgb, var(--primary) 92%, var(--primary-strong));
  background: color-mix(in srgb, var(--primary) 17%, var(--card));
}
.listing-card.top-three[data-rank="2"] {
  border-color: color-mix(in srgb, var(--primary) 56%, var(--border));
  background: color-mix(in srgb, var(--primary) 8%, var(--card));
}
.listing-card.top-three[data-rank="1"]:hover { border-color: var(--primary-strong); background: color-mix(in srgb, var(--primary) 19%, var(--card)); }
.listing-card.top-three[data-rank="2"]:hover { border-color: color-mix(in srgb, var(--primary) 68%, var(--border)); background: color-mix(in srgb, var(--primary) 10%, var(--card)); }
.listing-card.top-three[data-rank="3"]:hover { border-color: color-mix(in srgb, var(--primary) 40%, var(--border)); background: color-mix(in srgb, var(--primary) 5%, var(--card)); }

.listing-card.standard-row { border-bottom: 1px solid var(--border); background: none; overflow: visible; }
.listing-card.standard-row.section-end, .listing-card.standard-row:last-of-type { border-bottom-color: transparent; }

.listing-main {
  grid-template-columns: 42px 56px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 112px;
  padding: 17px 22px 17px 12px;
  display: grid;
}

.top-three .listing-main { min-height: 118px; padding: 14px 24px 14px 16px; }
.standard-row .listing-main { grid-template-columns: 26px 56px minmax(0, 1fr) auto; min-height: 112px; padding-inline: 24px 18px; }

.rank-badge {
  background: var(--muted);
  width: 40px;
  min-height: 30px;
  color: var(--muted-foreground);
  border-radius: 999px;
  place-items: center;
  font-size: 14px;
  font-weight: 650;
  display: grid;
}

.top-three .rank-badge { background: var(--primary); color: #fff; width: 42px; min-height: 30px; font-size: 16px; font-weight: 750; }
.standard-row .rank-badge { width: 26px; min-height: auto; color: var(--muted-foreground); background: none; justify-content: start; font-size: 16px; }

.listing-copy { flex-direction: column; align-items: flex-start; min-width: 0; display: flex; }
.listing-title {
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: min(680px, 100%);
  font-size: 17px;
  font-weight: 700;
  line-height: 22px;
  overflow: hidden;
}
.listing-title:hover { color: var(--primary-strong); }

.listing-description {
  -webkit-line-clamp: 2;
  max-width: 610px;
  color: var(--muted-foreground);
  -webkit-box-orient: vertical;
  margin: 2px 0 0;
  font-size: 16px;
  line-height: 1.45;
  display: -webkit-box;
  overflow: hidden;
}

.listing-stats { color: var(--muted-foreground); align-items: center; gap: 6px; margin-top: 5px; font-size: 12px; display: flex; }
.listing-stats strong { color: var(--foreground); font-weight: 650; }
.listing-identity { text-overflow: ellipsis; white-space: nowrap; max-width: 180px; overflow: hidden; }
.listing-category { text-overflow: ellipsis; white-space: nowrap; align-items: center; gap: 4px; min-width: 0; display: inline-flex; overflow: hidden; }
.listing-category svg { flex: none; }

.listing-price {
  min-width: 240px;
  color: var(--primary-strong);
  text-align: end;
  white-space: nowrap;
  align-self: start;
  margin: 2px 0 0 12px;
  font-size: 17px;
  font-weight: 700;
}

.listing-actions { top: 43px; flex-direction: column; align-items: flex-end; gap: 5px; display: flex; position: absolute; inset-inline-end: 22px; }
.top-three .listing-actions { top: 42px; inset-inline-end: 24px; }
.standard-row .listing-actions { top: 44px; inset-inline-end: 18px; }

.listing-action {
  white-space: nowrap;
  cursor: pointer;
  border-radius: 999px;
  min-height: 26px;
  padding: 3px 11px;
  font-size: 11px;
  font-weight: 750;
  line-height: 18px;
  transition: transform 0.12s, box-shadow 0.12s, filter 0.12s, background-color 0.12s;
}

.claim-rank {
  border: 1px solid var(--primary-shadow);
  background: var(--primary-action);
  color: var(--primary-action-foreground);
  box-shadow: 0 2px 0 var(--primary-shadow);
}

.increase-bid {
  border: 1px solid color-mix(in srgb, var(--primary) 58%, var(--border));
  background: var(--card);
  color: var(--primary-strong);
  box-shadow: 0 2px 0 color-mix(in srgb, var(--primary) 35%, var(--border));
}

.claim-rank-compact { display: none; }
.listing-action:hover, .listing-action:focus-visible { filter: brightness(1.03); }
.listing-action:active { box-shadow: 0 1px 0 var(--primary-shadow); transform: translateY(2px) scale(0.96); }

.rank-divider {
  color: var(--primary);
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 18px;
  margin: 28px 32px 26px;
  display: grid;
}

.rank-divider:before, .rank-divider:after { content: ""; background: color-mix(in srgb, var(--primary) 28%, transparent); height: 1px; }
.rank-divider span {
  border: 1px solid color-mix(in srgb, var(--primary) 36%, transparent);
  text-align: center;
  letter-spacing: 0.02em;
  border-radius: 999px;
  min-width: 78px;
  padding: 7px 18px;
  font-size: 13px;
  line-height: 18px;
}

.amount-value, .listing-stats, .listing-price, .rank-badge { font-variant-numeric: tabular-nums; }

/* --- pagination --- */

.pagination { flex-direction: column; align-items: center; gap: 8px; padding-top: 5px; display: flex; }
.pagination-buttons { gap: 5px; display: flex; }
.pagination a, .pagination span.pagination-current {
  min-width: 34px;
  height: 34px;
  color: var(--muted-foreground);
  cursor: pointer;
  background: none;
  border: 1px solid transparent;
  border-radius: 10px;
  place-items: center;
  padding: 0 9px;
  display: grid;
  font-size: 14px;
}
.pagination a:hover { background: var(--muted); color: var(--foreground); }
.pagination span.pagination-current {
  border-color: var(--border);
  background: var(--card);
  color: var(--foreground);
  font-weight: 650;
  box-shadow: 0 4px 16px #0316330f;
}
.pagination p { color: var(--muted-foreground); margin: 0; font-size: 12px; }

/* --- content pages --- */

.content-page { max-width: 720px; margin: 0 auto; padding-top: 8px; }
.content-page h1 { letter-spacing: -0.035em; font-size: 34px; line-height: 1.15; margin: 0; }
.content-page h2 { letter-spacing: -0.02em; font-size: 19px; margin: 38px 0 12px; }
.content-page .eyebrow { color: var(--primary-strong); letter-spacing: 0.1em; text-transform: uppercase; margin: 0 0 7px; font-size: 12px; font-weight: 700; }
.content-page .lead { color: var(--muted-foreground); margin: 20px 0 43px; font-size: 20px; line-height: 1.55; }
.content-page > p:not(.eyebrow):not(.lead) { color: var(--muted-foreground); margin: 0 0 14px; font-size: 16px; line-height: 1.7; }
.content-page ul { color: var(--muted-foreground); margin: 0 0 14px; padding-inline-start: 20px; font-size: 16px; line-height: 1.7; }
.content-page li { margin-bottom: 6px; }
.back-link { color: var(--muted-foreground); align-items: center; gap: 6px; margin-bottom: 34px; font-size: 13px; display: inline-flex; }
.back-link:hover { color: var(--primary-strong); }

.launch-stats { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 26px 0 34px; display: grid; }
.launch-stats > div {
  border: 1px solid color-mix(in srgb, var(--primary) 11%, var(--border));
  background: var(--card);
  border-radius: 20px;
  padding: 16px 18px;
  box-shadow: 0 18px 42px #03163310;
}
.launch-stats strong { letter-spacing: -0.03em; font-size: 24px; display: block; font-variant-numeric: tabular-nums; }
.launch-stats span { color: var(--muted-foreground); font-size: 12px; }

/* --- footer --- */

.site-footer { text-align: center; margin-top: 64px; padding: 0 0 32px; }
.site-footer p { color: var(--muted-foreground); text-wrap: balance; margin: 0; font-size: 13px; line-height: 1.6; }
.site-footer nav { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; margin-bottom: 6px; }
.site-footer a {
  min-height: 36px;
  color: var(--primary-strong);
  text-underline-offset: 3px;
  align-items: center;
  font-weight: 600;
  transition: color 0.14s;
  display: inline-flex;
}
.site-footer .footer-revenue {
  margin-bottom: 6px;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.site-footer .footer-revenue b { color: var(--primary-strong); }
.site-footer .footer-credit { margin-top: 2px; font-size: 12px; }
/* Deliberately quiet: a signature, not a slogan. */
.site-footer .footer-credit a { min-height: 28px; }
.site-footer a:hover, .site-footer a:focus-visible { color: var(--primary-shadow); text-decoration: underline; }

.payment-note {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 16px;
  padding: 12px 18px 12px 14px;
  margin: 4px 0 8px;
  font-weight: 650;
}

.payment-note img { flex: none; }
.payment-note span { font-size: 15px; }


/* --- increase-bid dialog ------------------------------------------------- */

.increase-bid-dialog {
  width: min(430px, 100% - 24px);
  max-width: none;
  color: var(--foreground);
  background: none;
  border: 0;
  padding: 0;
  overflow: visible;
}

.increase-bid-dialog::backdrop {
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  background: #03163370;
}

/* Fallback for browsers without showModal()/top-layer (older iOS Safari):
   centre the panel over the page and paint a backdrop ourselves. */
.increase-bid-dialog[open] {
  position: fixed;
  inset: 0;
  margin: auto;
  height: max-content;
  max-height: calc(100% - 24px);
  z-index: 1200;
}
body.modal-open { overflow: hidden; }
body.modal-open::before {
  content: "";
  position: fixed;
  inset: 0;
  background: #03163370;
  z-index: 1100;
}

.increase-bid-panel {
  border: 1px solid color-mix(in srgb, var(--primary) 28%, var(--border));
  background: var(--card);
  text-align: left;
  border-radius: 26px;
  padding: 22px;
  box-shadow: 0 28px 80px #03163340, 0 6px 20px #0316331f;
}

.increase-bid-header { justify-content: space-between; align-items: flex-start; gap: 16px; display: flex; }
.increase-bid-header > div { min-width: 0; }
.increase-bid-header span {
  color: var(--primary-strong);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 700;
  display: block;
  overflow: hidden;
}
.increase-bid-header h2 { letter-spacing: -0.035em; margin: 3px 0 0; font-size: 25px; line-height: 1.18; }

.increase-bid-close {
  border: 1px solid var(--border);
  background: var(--muted);
  width: 40px;
  height: 40px;
  color: var(--muted-foreground);
  cursor: pointer;
  border-radius: 50%;
  flex: none;
  place-items: center;
  padding: 0;
  transition: color 0.12s, background-color 0.12s, transform 0.12s;
  display: grid;
}
.increase-bid-close:hover { background: color-mix(in srgb, var(--primary) 7%, var(--muted)); color: var(--foreground); }
.increase-bid-close:active { transform: scale(0.96); }

.increase-bid-panel > p { color: var(--muted-foreground); margin: 15px 0 0; font-size: 14px; line-height: 1.5; }

.increase-bid-field { gap: 7px; margin-top: 19px; display: grid; }
.increase-bid-field > span:first-child { font-size: 13px; font-weight: 700; }

.increase-bid-input {
  border: 1px solid var(--border);
  background: var(--background);
  border-radius: 17px;
  align-items: center;
  gap: 9px;
  height: 50px;
  padding: 0 14px;
  transition: border-color 0.14s, box-shadow 0.14s;
  display: flex;
}
.increase-bid-input:focus-within {
  border-color: color-mix(in srgb, var(--primary) 70%, var(--border));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 12%, transparent);
}
.increase-bid-input:has(input[aria-invalid="true"]) { border-color: var(--error); }
.increase-bid-input input {
  width: 100%;
  min-width: 0;
  color: var(--foreground);
  font: inherit;
  font-variant-numeric: tabular-nums;
  background: none;
  border: 0;
  outline: 0;
  padding: 0;
  font-size: 20px;
  font-weight: 700;
}
.increase-bid-input strong { color: var(--muted-foreground); flex: none; font-size: 13px; }

.claim-select {
  border: 1px solid var(--border);
  background: var(--background);
  color: var(--foreground);
  border-radius: 17px;
  height: 50px;
  padding: 0 14px;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  width: 100%;
  cursor: pointer;
  transition: border-color 0.14s, box-shadow 0.14s;
}
.claim-select:focus {
  outline: none;
  border-color: color-mix(in srgb, var(--primary) 70%, var(--border));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 12%, transparent);
}
.claim-select[aria-invalid="true"] { border-color: var(--error); }

.increase-bid-summary {
  color: var(--muted-foreground);
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  font-size: 12px;
  display: flex;
}
.increase-bid-summary strong { color: var(--primary-strong); text-align: right; }

.increase-bid-panel .increase-bid-error { min-height: 18px; color: var(--error); margin-top: 8px; font-size: 12px; font-weight: 650; }

.increase-bid-submit {
  border: 1px solid var(--primary-shadow);
  background: var(--primary-action);
  width: 100%;
  min-height: 46px;
  color: var(--primary-action-foreground);
  box-shadow: 0 5px 0 var(--primary-shadow);
  cursor: pointer;
  border-radius: 17px;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  font-size: 14px;
  font-weight: 750;
  transition: transform 0.12s, box-shadow 0.12s, filter 0.12s, opacity 0.12s;
  display: inline-flex;
}
.increase-bid-submit:hover:not(:disabled) { filter: brightness(1.03); }
.increase-bid-submit:active:not(:disabled) { box-shadow: 0 1px 0 var(--primary-shadow); transform: translateY(4px) scale(0.96); }
.increase-bid-submit:disabled { opacity: 0.55; cursor: wait; }

@media (max-width: 719px) {
  .increase-bid-dialog { width: calc(100% - 24px); }
  .increase-bid-panel { border-radius: 22px; padding: 18px; }
  .increase-bid-header h2 { font-size: 23px; }
  .increase-bid-close { width: 44px; height: 44px; }
  .increase-bid-panel > p { margin-top: 12px; font-size: 13px; }
  .increase-bid-field { margin-top: 16px; }
  .increase-bid-input input { font-size: 18px; }
  .increase-bid-summary { flex-direction: column; align-items: flex-start; gap: 3px; }
  .increase-bid-summary strong { text-align: left; }
  .increase-bid-submit { min-height: 48px; }
}

/* --- student choice ------------------------------------------------------ */

.poll-list { display: flex; flex-direction: column; gap: 16px; margin-top: 8px; }

.poll-card {
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 20px;
  padding: 18px;
  box-shadow: 0 8px 30px #0316330d;
}
.poll-card__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.poll-card__title { font-size: 18px; font-weight: 700; letter-spacing: -0.02em; }
.poll-card__title:hover { color: var(--primary-strong); }
.poll-card__q { color: var(--muted-foreground); font-size: 14px; margin: 4px 0 0; }

.poll-badge { font-size: 11px; font-weight: 800; padding: 4px 10px; border-radius: 999px; text-transform: uppercase; letter-spacing: 0.04em; flex: none; }
.poll-badge--battle { background: color-mix(in srgb, var(--error) 14%, transparent); color: var(--error); }

.poll-options { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.poll-option {
  position: relative;
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  background: var(--background);
}
.poll-option--lead { border-color: color-mix(in srgb, var(--primary) 55%, var(--border)); }
.poll-option__bar {
  position: absolute;
  inset: 0 auto 0 0;
  background: color-mix(in srgb, var(--primary) 12%, transparent);
  transition: width 0.6s cubic-bezier(0.2, 0, 0, 1);
  z-index: 0;
}
.poll-option--lead .poll-option__bar { background: color-mix(in srgb, var(--primary) 20%, transparent); }
.poll-option__row {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 13px;
}
.poll-option__rank { font-size: 15px; font-weight: 700; min-width: 22px; text-align: center; }
.poll-option__logo { border-radius: 8px; object-fit: cover; flex: none; background: var(--muted); }
.poll-option__label { font-weight: 600; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.poll-option__votes { font-weight: 700; font-variant-numeric: tabular-nums; color: var(--primary-strong); white-space: nowrap; }
.poll-option__vote {
  flex: none;
  border: 1px solid var(--primary-shadow);
  background: var(--primary-action);
  color: var(--primary-action-foreground);
  box-shadow: 0 2px 0 var(--primary-shadow);
  border-radius: 999px;
  padding: 5px 14px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.poll-option__vote:hover { filter: brightness(1.04); }

.poll-card__foot { display: flex; justify-content: space-between; align-items: center; margin-top: 14px; font-size: 13px; }
.poll-total b { font-variant-numeric: tabular-nums; }
.poll-status { display: inline-flex; align-items: center; gap: 6px; color: var(--muted-foreground); font-weight: 600; font-size: 12px; }
.poll-status--open { color: var(--live); }

.poll-hint { color: var(--muted-foreground); font-size: 12px; margin: 10px 0 0; }

.poll-past { display: flex; flex-direction: column; gap: 8px; }
.poll-past__item {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px; text-decoration: none;
}
.poll-past__item:hover { border-color: var(--primary); }
.poll-past__title { font-weight: 600; }
.poll-past__winner { color: var(--primary-strong); font-size: 13px; font-weight: 650; white-space: nowrap; }

.poll-winner-banner {
  margin-top: 16px; padding: 14px 18px; border-radius: 14px;
  background: var(--primary-soft); color: var(--primary-strong); font-size: 15px;
}

/* --- students fund ------------------------------------------------------- */

.fund-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin: 22px 0 28px;
}
.fund-tile {
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 16px;
  padding: 16px 18px;
}
.fund-tile--accent { border-color: var(--primary); background: var(--primary-soft); }
.fund-tile__value { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.fund-tile--accent .fund-tile__value { color: var(--primary-strong); }
.fund-tile__label { font-size: 12px; color: var(--muted-foreground); margin-top: 3px; }

@media (max-width: 719px) {
  .poll-option__vote { padding: 5px 11px; }
  .poll-option__label { font-size: 14px; }
}

/* --- toast --- */


.toast {
  z-index: 40;
  background: var(--foreground);
  max-width: calc(100% - 32px);
  min-height: 34px;
  color: var(--background);
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  border-radius: 999px;
  align-items: center;
  gap: 6px;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 600;
  transition: opacity 0.16s, transform 0.16s, visibility 0.16s;
  display: flex;
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translate(-50%, 8px);
  box-shadow: 0 8px 24px #0000002e;
}

.toast.visible { opacity: 1; visibility: visible; transform: translate(-50%); }

/* --- narrow --- */

@media (max-width: 719px) {
  .site-header, .header-inner { height: 60px; }
  .header-inner { width: calc(100% - 24px); }
  .brand-mark { width: 27px; height: 27px; }
  .brand-link { font-size: 16px; }
  .header-brand-group { gap: 7px; }
  .board-period-switch { padding: 3px; }
  .board-period-switch a { min-height: 34px; padding-inline: 11px; font-size: 12px; }
  .header-actions { gap: 8px; }
  .header-actions > nav { display: none; }
  .language-trigger { min-width: 50px; min-height: 40px; padding-inline: 7px; font-size: 12px; }
  .page-container { padding: 8px 12px 0; }
  .live-wrap { min-height: 52px; }
  .live-pill { justify-content: center; gap: 4px; padding: 7px 10px; font-size: 11px; line-height: 16px; }
  .live-dot { width: 7px; height: 7px; }
  /* Keep only the fund pill above the fold on phones; drop the prose. */
  .intro-copy { display: block; margin: 0 0 12px; }
  .intro-copy .intro-lead, .intro-copy p > span { display: none; }
  .intro-copy p { margin: 0; }
  .intro-copy.today-intro { display: none; }
  .intro-copy strong { margin-top: 0; font-size: 12px; }
  .bid-heading-row { flex-wrap: nowrap; gap: 4px; font-size: clamp(21px, 6.2vw, 24px); line-height: 34px; }
  .today-board .bid-heading-row { gap: 3px; font-size: clamp(18px, 5.1vw, 20px); line-height: 30px; }
  .amount-control { gap: 4px; }
  .amount-control > button { width: 22px; height: 22px; box-shadow: 0 2px 0 var(--primary-shadow); font-size: 12px; }
  .currency-field { gap: 3px; }
  .bid-rule { max-width: 320px; margin: 3px auto 0; font-size: 11px; }
  .bid-section form { grid-template-columns: 1fr; gap: 8px; margin-top: 14px; }
  .url-field input { height: 46px; }
  .category-select-field { grid-area: 2 / 1; }
  .category-select-trigger { height: 46px; }
  .url-supported { grid-area: 3 / 1; margin-inline: 3px; font-size: 11px; }
  .primary-button { width: 100%; height: 44px; box-shadow: 0 4px 0 var(--primary-shadow); border-radius: 16px; grid-area: 4 / 1; }
  .bid-section .bid-helper { max-width: 350px; margin: 9px auto 0; font-size: 11px; line-height: 1.45; }
  .brand-preview { grid-template-columns: 42px minmax(0, 1fr); gap: 9px; padding: 12px; }
  .brand-preview > .brand-avatar.large, .brand-preview > .mini-avatar.large { width: 42px; height: 42px; }
  .brand-preview-bid {
    border-top: 1px solid var(--border);
    grid-column: 1 / -1;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 2px 12px;
    padding-top: 8px;
    display: grid;
  }
  .brand-preview-bid small { grid-row: 1; }
  .brand-preview-bid strong { grid-area: 1 / 2; }
  .brand-preview-bid span { grid-column: 1 / -1; }
  .category-filters {
    gap: 5px;
    width: calc(100% + 24px);
    margin-inline: -12px;
    padding: 2px 30px 4px 12px;
    -webkit-mask-image: linear-gradient(90deg, #000 0 calc(100% - 28px), #0000 100%);
    mask-image: linear-gradient(90deg, #000 0 calc(100% - 28px), #0000 100%);
  }
  .category-filters a { min-height: 34px; padding-inline: 10px; font-size: 11px; }
  .leaderboard-empty { border-radius: 18px; min-height: 164px; padding: 24px 18px; }
  .leaderboard-empty strong { font-size: 19px; }
  .leaderboard-empty p { font-size: 12px; }
  .listing-card.top-three { border-radius: 18px; margin-top: 6px; }
  .listing-main { grid-template-columns: 28px 40px minmax(0, 1fr) auto; gap: 7px; min-height: 78px; padding: 8px 4px; }
  .top-three .listing-main { grid-template-columns: 30px 42px minmax(0, 1fr) auto; gap: 7px; min-height: 98px; padding: 9px 10px 9px 8px; }
  .standard-row .listing-main { min-height: 84px; padding-inline: 4px; }
  .rank-badge { width: 31px; min-height: 26px; font-size: 11px; }
  .top-three .rank-badge { width: 30px; min-height: 23px; font-size: 11px; }
  .standard-row .rank-badge { width: 28px; font-size: 12px; }
  .brand-avatar.large { width: 40px; height: 40px; }
  .mini-avatar.large { border-radius: 11px; width: 40px; height: 40px; font-size: 14px; }
  .top-three .brand-avatar.large, .top-three .mini-avatar.large { width: 42px; height: 42px; }
  .listing-title { max-width: 100%; font-size: 13px; line-height: 16px; }
  .listing-description { margin-top: 1px; font-size: 11px; line-height: 1.28; }
  .listing-stats { gap: 5px; margin-top: 2px; font-size: 10px; }
  .listing-identity { max-width: 92px; }
  .listing-category { display: none; }
  .listing-price { place-self: start end; min-width: 0; margin: 0; font-size: 12px; line-height: 16px; display: block; }
  .listing-actions, .top-three .listing-actions, .standard-row .listing-actions {
    top: 31px;
    align-items: stretch;
    gap: 3px;
    width: 84px;
    inset-inline-end: 4px;
  }
  .top-three .listing-actions { inset-inline-end: 9px; }
  .listing-action { width: 84px; max-width: 84px; min-height: 24px; padding: 2px 4px; font-size: 8.5px; line-height: 16px; }
  .claim-rank-full { display: none; }
  .claim-rank-compact { display: inline; }
  .rank-divider { gap: 10px; margin: 20px 8px 18px; }
  .rank-divider span { min-width: 62px; padding: 4px 10px; font-size: 10px; line-height: 16px; }
  .content-page h1 { font-size: 27px; }
  .content-page .lead { margin: 17px 0 35px; font-size: 17px; }
  .back-link { margin-bottom: 28px; }
  .site-footer { margin-top: 52px; }
  .pagination a, .pagination span.pagination-current { min-width: 31px; height: 31px; }
}

@media (max-width: 419px) {
  .header-inner { width: calc(100% - 20px); }
  .header-actions { gap: 3px; }
  .language-trigger { gap: 3px; min-width: 38px; padding-inline: 6px; }
  .language-trigger > span:nth-child(2) { display: none; }
  .brand-lockup { gap: 5px; }
  .brand-mark { width: 24px; height: 24px; }
  .brand-link { font-size: 14px; }
  .board-period-switch a { padding-inline: 6px; }
  .live-pill { gap: 4px; padding-inline: 9px; font-size: 11px; }
  .bid-heading-row { flex-direction: column; font-size: 23px; line-height: 34px; }
}

/* ===================== Student Choice — knockout ===================== */
.sc-hero { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; margin: 8px 0 20px; }
.sc-hero__title { font-size: 34px; font-weight: 800; letter-spacing: -.02em; margin: 0 0 6px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.sc-badge { font-size: 13px; font-weight: 700; color: var(--primary-strong); background: var(--muted); border: 1px solid var(--border); border-radius: 999px; padding: 3px 12px; }
.sc-hero__sub { color: var(--muted-foreground); font-size: 15px; margin: 0 0 16px; }
.sc-stats { display: flex; gap: 10px; flex-wrap: wrap; }
.sc-stat { display: inline-flex; align-items: center; gap: 7px; background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 9px 14px; font-size: 13px; color: var(--muted-foreground); }
.sc-stat b { color: var(--foreground); font-weight: 800; }
.sc-hero__how { background: var(--card); border: 1px solid var(--border); border-radius: 18px; padding: 18px 20px; }
.sc-hero__how h3 { margin: 0 0 12px; font-size: 16px; }
.sc-hero__how ol { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.sc-hero__how li { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; color: var(--muted-foreground); }
.sc-hero__how li span { flex: none; width: 22px; height: 22px; border-radius: 50%; background: var(--primary); color: #fff; font-size: 12px; font-weight: 700; display: grid; place-items: center; }

.sc-stages { display: flex; gap: 10px; overflow-x: auto; padding: 6px 0 14px; }
.sc-stage { flex: 1 0 auto; min-width: 130px; border: 1px solid var(--border); border-radius: 14px; padding: 12px 16px; background: var(--card); }
.sc-stage.is-current { border-color: var(--primary); box-shadow: 0 0 0 3px #1aa4ff22; }
.sc-stage.is-done { opacity: .7; }
.sc-stage__name { font-weight: 700; font-size: 14px; }
.sc-stage__meta { font-size: 12px; color: var(--muted-foreground); margin-top: 2px; }
.sc-stage.is-current .sc-stage__meta { color: var(--primary-strong); font-weight: 600; }

.sc-grid { display: grid; grid-template-columns: 1fr 320px; gap: 18px; align-items: start; }
.sc-main { display: flex; flex-direction: column; gap: 16px; }
.sc-main__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.sc-main__head h2 { margin: 0; font-size: 20px; }
.sc-countdown { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.sc-count__label { font-size: 12px; color: var(--muted-foreground); margin-right: 4px; }
.sc-count__box { background: var(--card); border: 1px solid var(--border); border-radius: 9px; padding: 6px 9px; font-size: 11px; color: var(--muted-foreground); text-align: center; min-width: 42px; }
.sc-count__box b { display: block; font-size: 17px; color: var(--foreground); font-variant-numeric: tabular-nums; }

.sc-matches { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.sc-match { border: 1px solid var(--border); border-radius: 16px; background: var(--card); padding: 14px; }
.sc-match__head { display: flex; justify-content: space-between; margin-bottom: 10px; }
.sc-match__no { font-size: 12px; font-weight: 700; color: var(--primary-strong); background: var(--muted); border-radius: 8px; padding: 3px 9px; }
.sc-match__body { display: flex; align-items: center; gap: 10px; }
.sc-side { display: flex; align-items: center; gap: 9px; flex: 1; min-width: 0; }
.sc-side__logo { width: 44px; height: 44px; border-radius: 11px; object-fit: cover; background: var(--muted); flex: none; display: grid; place-items: center; font-weight: 800; color: var(--muted-foreground); }
.sc-side__body { min-width: 0; }
.sc-side__name { font-weight: 700; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-side__votes { font-size: 12px; color: var(--muted-foreground); }
.sc-vs { flex: none; font-size: 12px; font-weight: 800; color: var(--muted-foreground); }
.sc-match__vote { display: flex; gap: 8px; margin-top: 12px; }
.sc-vote { flex: 1; font-size: 12.5px; padding: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.sc-bracket { display: flex; gap: 14px; overflow-x: auto; padding: 6px 0; }
.sc-bracket__round { flex: none; min-width: 165px; display: flex; flex-direction: column; justify-content: space-around; gap: 10px; }
.sc-bracket__label { font-size: 12px; font-weight: 700; color: var(--muted-foreground); text-transform: uppercase; letter-spacing: .03em; }
.sc-bracket__match { border: 1px solid var(--border); border-radius: 11px; background: var(--card); overflow: hidden; }
.sc-bracket__side { display: flex; justify-content: space-between; gap: 8px; padding: 7px 10px; font-size: 12.5px; }
.sc-bracket__side + .sc-bracket__side { border-top: 1px solid var(--border); }
.sc-bracket__side span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-bracket__side.win { color: var(--primary-strong); font-weight: 700; background: #1aa4ff10; }
.sc-bracket__side b { font-variant-numeric: tabular-nums; }
.sc-bracket__champion { justify-content: flex-start; }
.sc-bracket__trophy { border: 2px solid #f5c518; border-radius: 14px; background: #fff8e1; color: #7a5c00; padding: 18px 14px; text-align: center; font-size: 22px; }
:root:not([data-theme="light"]) .sc-bracket__trophy { background: #2a2410; color: #f5c518; }

.sc-side-col { display: flex; flex-direction: column; gap: 16px; position: sticky; top: 16px; }
.sc-side-col .card h3 { margin: 0 0 12px; font-size: 15px; }
.sc-top { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.sc-top li { display: flex; align-items: center; gap: 9px; font-size: 13px; }
.sc-top__rank { flex: none; width: 22px; height: 22px; border-radius: 6px; background: var(--muted); display: grid; place-items: center; font-weight: 800; font-size: 12px; color: var(--muted-foreground); }
.sc-top li:nth-child(1) .sc-top__rank { background: #fff3cd; color: #9a7400; }
.sc-top li:nth-child(2) .sc-top__rank { background: #e9edf2; color: #5a6b80; }
.sc-top li:nth-child(3) .sc-top__rank { background: #fbe4d0; color: #a5642a; }
.sc-top img { border-radius: 6px; object-fit: cover; flex: none; }
.sc-top__name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.sc-top__votes { font-weight: 700; color: var(--primary-strong); font-variant-numeric: tabular-nums; }

.sc-donut { position: relative; width: 160px; height: 160px; margin: 4px auto 12px; }
.sc-donut__ring { width: 100%; height: 100%; border-radius: 50%; background: var(--muted); -webkit-mask: radial-gradient(circle 46px at center, transparent 98%, #000 100%); mask: radial-gradient(circle 46px at center, transparent 98%, #000 100%); }
.sc-donut__center { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; }
.sc-donut__center b { font-size: 20px; font-weight: 800; }
.sc-donut__center span { font-size: 11px; color: var(--muted-foreground); }
.sc-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.sc-legend li { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.sc-legend b { margin-left: auto; font-variant-numeric: tabular-nums; }
.sc-legend__dot { width: 11px; height: 11px; border-radius: 3px; flex: none; }
.sc-legend__dot[data-i="0"] { background: #1aa4ff; }
.sc-legend__dot[data-i="1"] { background: #8b5cf6; }
.sc-legend__dot[data-i="2"] { background: #22c55e; }
.sc-legend__dot[data-i="3"] { background: #f59e0b; }
.sc-invite .btn { margin-top: 10px; width: 100%; }

.sc-features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 22px 0 8px; background: var(--muted); border-radius: 18px; padding: 18px; }
.sc-feat { display: flex; gap: 11px; align-items: flex-start; }
.sc-feat > span { font-size: 22px; }
.sc-feat b { font-size: 13.5px; }
.sc-feat p { margin: 3px 0 0; font-size: 12px; color: var(--muted-foreground); }
.sc-note { text-align: center; color: var(--muted-foreground); font-size: 13px; background: var(--muted); border-radius: 12px; padding: 12px; }
.sc-poll-link { display: flex; justify-content: space-between; margin-bottom: 10px; }

@media (max-width: 960px) {
  .sc-hero, .sc-grid { grid-template-columns: 1fr; }
  .sc-side-col { position: static; }
  .sc-features { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .sc-features { grid-template-columns: 1fr; }
  .sc-hero__title { font-size: 26px; }
}

/* payment method row inside the claim pop-up */
.claim-pay-methods { display: flex; flex-wrap: wrap; gap: 8px; }
.claim-pay-method {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--primary); background: color-mix(in srgb, var(--primary) 8%, var(--card));
  border-radius: 12px; padding: 9px 14px; font-weight: 650; font-size: 13px;
}
.claim-pay-method img { display: block; }
