:root {
  font-family: Arial, Helvetica, sans-serif;
  color: #f5f5f7;
  background: #080911;
  font-synthesis: none;
  --lime: #d9f36b;
  --line: #ffffff29;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  isolation: isolate;
}

/* Full-page video: adjust overlay opacity here to change readability. */
.page-background {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: #080911;
}

.page-background video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.page-background::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(5, 7, 16, 0.58);
}

.background-toggle {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 4;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 14px;
  color: white;
  background: rgba(8, 9, 17, 0.85);
  font-size: 12px;
}
button,
input,
a {
  -webkit-tap-highlight-color: transparent;
}
button,
a,
input {
  outline-offset: 5px;
}
button {
  font: inherit;
  cursor: pointer;
}
a {
  color: inherit;
  text-decoration: none;
}
header,
main,
footer {
  max-width: 1240px;
  margin: auto;
}
header {
  height: 104px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  gap: 24px;
}
.brand {
  display: flex;
  align-items: center;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -1px;
  gap: 6px;
}
.brand-icon {
  background: #222;
  color: var(--lime);
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  margin-right: 6px;
}
.light {
  font-weight: 400;
}
nav {
  display: flex;
  gap: 32px;
  font-size: 14px;
}
nav a {
  padding: 14px 0;
  color: #696962;
}
nav .active {
  color: #202020;
  border-bottom: 2px solid #222;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  padding: 14px 21px;
  border: 0;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
}
.dark {
  background: #222;
  color: white;
}
.button:hover {
  filter: brightness(1.15);
}
.hero {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 50px;
  padding: 60px 0 50px;
  align-items: center;
}
.eyebrow {
  font-size: 12px;
  letter-spacing: 1.7px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 9px;
}
.dot {
  width: 8px;
  height: 8px;
  background: #628225;
  border-radius: 50%;
}
h1 {
  font-size: clamp(40px, 5vw, 64px);
  line-height: 1.13;
  letter-spacing: -2.8px;
  margin: 25px 0 20px;
  color: rgb(197, 151, 97);
  font-family: Bodoni Moda;
}
h1 > span {
  color: #78854a;
}
.intro {
  color: #686861;
  font-size: 26px;
  line-height: 1.7;
}
.hero-link {
  margin-top: 12px;
}
.hero-art {
  position: relative;
  background: var(--lime);
  min-height: 330px;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
}
.orbit {
  position: absolute;
  width: 370px;
  height: 370px;
  border: 1px solid #a8be52;
  border-radius: 50%;
  transform: scaleY(0.68) rotate(-28deg);
}
.orbit:after {
  content: "";
  position: absolute;
  inset: 22px;
  border: 1px solid #a8be52;
  border-radius: 50%;
}
.art-small {
  position: absolute;
  top: 26px;
  left: 26px;
  font-size: 11px;
  line-height: 1.4;
  font-weight: bold;
  letter-spacing: 1px;
}
.art-big {
  font-weight: 900;
  font-size: 112px;
  letter-spacing: -9px;
  transform: rotate(-9deg);
  z-index: 1;
}
.art-big span {
  font-size: 74px;
  position: absolute;
  right: -34px;
  top: -35px;
  letter-spacing: 0;
}
.art-bottom {
  position: absolute;
  bottom: 28px;
  right: 26px;
  font-size: 11px;
  letter-spacing: 2px;
  font-weight: bold;
}
.stats {
  display: grid;
  grid-template-columns: 1fr 1fr 1.4fr 1.8fr;
  padding: 27px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.stats > div {
  padding: 0 30px;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.stats > div:first-child {
  padding-left: 0;
}
.stats > div:last-child {
  border: 0;
}
.stats strong {
  font-size: 30px;
  letter-spacing: -1px;
}
.stats span {
  font-size: 13px;
  color: #707067;
}
.stats .quota {
  justify-content: center;
  padding-right: 0;
}
.quota b {
  font-size: 15px;
}
.workspace {
  padding: 60px 0;
}
.section-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
h2 {
  font-size: 30px;
  letter-spacing: -0.8px;
  margin: 12px 0 22px;
}
.search {
  display: flex;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  padding: 12px 16px;
  border-radius: 8px;
  background: white;
  min-width: 310px;
}
.search span {
  font-size: 24px;
}
.search input {
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 14px;
  min-width: 0;
  width: 100%;
}
.filters {
  display: flex;
  gap: 9px;
  margin: 10px 0 30px;
  flex-wrap: wrap;
}
.chip {
  border: 1px solid var(--line);
  border-radius: 30px;
  padding: 10px 18px;
  background: transparent;
  font-size: 13px;
}
.chip.active {
  background: #222;
  color: white;
  border-color: #222;
}
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.card {
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}
.portrait {
  height: 210px;
  background: var(--card-color);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.initials {
  font-size: 85px;
  font-weight: 800;
  letter-spacing: -7px;
  color: #27272a;
  opacity: 0.8;
}
.portrait .badge {
  position: absolute;
  top: 16px;
  left: 16px;
  font-size: 11px;
  letter-spacing: 1px;
  background: #ffffffc9;
  border-radius: 5px;
  padding: 7px 9px;
}
.portrait .decor {
  position: absolute;
  right: 16px;
  bottom: 4px;
  font-size: 75px;
  opacity: 0.18;
}
.card-body {
  padding: 22px;
}
.team {
  font-size: 12px;
  color: #707069;
  margin: 0 0 9px;
}
.card h3 {
  font-size: 20px;
  margin: 0 0 18px;
  letter-spacing: -0.5px;
}
.card-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.vote-total {
  font-size: 13px;
  color: #777;
}
.vote-total b {
  font-size: 18px;
  color: #222;
  margin-right: 5px;
}
.vote-button {
  background: var(--lime);
  padding: 11px 16px;
  border: 0;
  border-radius: 6px;
  font-size: 13px;
  font-weight: bold;
}
.profile-link {
  background: transparent;
  border: 0;
  padding: 0;
  text-align: left;
}
.profile-link:hover {
  text-decoration: underline;
}
.how {
  border-top: 1px solid var(--line);
  padding: 38px 0 45px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
}
.how p {
  font-size: 15px;
  color: #6e6e66;
  line-height: 1.8;
}
.how h2 {
  font-size: 27px;
}
footer {
  border-top: 1px solid var(--line);
  padding: 28px 0 35px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
footer p,
footer > span {
  font-size: 12px;
  color: #777;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 36px;
  max-width: 470px;
  width: calc(100% - 32px);
  max-height: 90vh;
  color: #222;
  background: #faf9f6;
}
dialog::backdrop {
  background: #1118;
  backdrop-filter: blur(4px);
}
.close {
  position: absolute;
  top: 10px;
  right: 14px;
  border: 0;
  background: none;
  font-size: 28px;
}
.modal-title {
  font-size: 26px;
  margin: 8px 0 12px;
}
.muted {
  color: #6e6e66;
  line-height: 1.7;
  font-size: 14px;
}
.form {
  display: grid;
  gap: 15px;
  margin-top: 24px;
}
.form label {
  font-size: 14px;
  display: grid;
  gap: 8px;
}
.form input {
  border: 1px solid #c9c9c1;
  border-radius: 7px;
  padding: 12px;
  font: inherit;
  width: 100%;
  background: white;
}
.form .button {
  margin-top: 5px;
}
.text-button {
  background: none;
  border: 0;
  text-decoration: underline;
  font-size: 14px;
  padding: 12px 0;
}
.error {
  font-size: 14px;
  color: #a32626;
  line-height: 1.5;
}
.error:empty {
  display: none;
}
#toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  max-width: calc(100% - 32px);
  background: #222;
  color: white;
  border-radius: 10px;
  padding: 16px 24px;
  font-size: 14px;
  box-shadow: 0 10px 30px #0002;
  display: none;
  z-index: 5;
}
.rank-row,
.history-row {
  display: flex;
  align-items: center;
  gap: 20px;
  background: white;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line);
}
.rank-number {
  font-size: 23px;
  min-width: 35px;
  color: #888;
}
.rank-row:first-child {
  background: #edf5d5;
  border-radius: 12px 12px 0 0;
}
.mini-avatar {
  background: var(--card-color);
  width: 50px;
  height: 50px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-weight: bold;
}
.row-name {
  flex: 1;
}
.row-name h3 {
  font-size: 17px;
  margin: 0 0 5px;
}
.row-name p {
  font-size: 13px;
  color: #777;
  margin: 0;
}
.empty {
  padding: 55px 20px;
  text-align: center;
  background: #f0f0e9;
  border-radius: 12px;
  color: #666;
}
.empty .button {
  margin-top: 12px;
}
.profile-portrait {
  height: 150px;
  border-radius: 9px;
  margin-top: 12px;
}
.profile-portrait .initials {
  font-size: 70px;
}
.full {
  width: 100%;
  margin-top: 18px;
}
button:disabled {
  opacity: 0.55;
  cursor: wait;
}
[hidden] {
  display: none !important;
}
@media (max-width: 1300px) {
  header,
  main,
  footer {
    margin-left: 40px;
    margin-right: 40px;
  }
}
@media (max-width: 900px) {
  header,
  main,
  footer {
    margin-left: 24px;
    margin-right: 24px;
  }
  nav {
    gap: 18px;
  }
  .hero {
    gap: 25px;
  }
  .art-big {
    font-size: 88px;
  }
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .stats > div {
    padding: 0 16px;
  }
  .stats {
    grid-template-columns: 1fr 1fr 1.2fr;
  }
  .stats .quota {
    grid-column: 1/-1;
    padding: 20px 0 0;
    margin-top: 20px;
    border-top: 1px solid var(--line);
  }
  .stats > div:nth-child(3) {
    border: 0;
  }
  .section-top {
    align-items: flex-start;
  }
  .search {
    min-width: 250px;
  }
  .how {
    gap: 25px;
  }
  footer > span {
    display: none;
  }
}
@media (max-width: 620px) {
  header,
  main,
  footer {
    margin-left: 18px;
    margin-right: 18px;
  }
  header {
    height: auto;
    padding: 18px 0;
    flex-wrap: wrap;
    gap: 18px;
  }
  .brand {
    font-size: 23px;
  }
  .brand-icon {
    width: 34px;
    height: 34px;
  }
  header .button {
    padding: 11px 14px;
  }
  nav {
    order: 3;
    width: 100%;
    justify-content: space-between;
    font-size: 13px;
    gap: 8px;
  }
  nav a {
    padding: 8px 0;
  }
  .hero {
    grid-template-columns: 1fr;
    padding: 30px 0;
    gap: 26px;
  }
  h1 {
    font-size: 46px;
    letter-spacing: -2px;
  }
  .hero-art {
    min-height: 230px;
  }
  .art-big {
    font-size: 100px;
  }
  .intro {
    font-size: 15px;
  }
  .stats span {
    font-size: 11px;
  }
  .stats strong {
    font-size: 26px;
  }
  .stats > div {
    padding: 0 10px;
  }
  .workspace {
    padding: 34px 0;
  }
  .section-top {
    display: block;
  }
  h2 {
    font-size: 26px;
  }
  .search {
    margin-bottom: 20px;
  }
  .filters {
    gap: 6px;
  }
  .chip {
    font-size: 12px;
    padding: 9px 12px;
  }
  .grid {
    gap: 14px;
    grid-template-columns: 1fr;
  }
  .portrait {
    height: 230px;
  }
  .card-body {
    padding: 20px;
  }
  .how {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 28px 0;
  }
  .how h2 {
    margin-bottom: 5px;
  }
  footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }
  footer p {
    line-height: 1.6;
  }
  .rank-row,
  .history-row {
    padding: 16px 10px;
    gap: 12px;
  }
  .rank-row .vote-button {
    padding: 10px;
  }
  .rank-number {
    min-width: 20px;
    font-size: 18px;
  }
  .row-name h3 {
    font-size: 15px;
  }
  .row-name p {
    font-size: 12px;
  }
  dialog {
    padding: 30px 24px;
  }
}

/* Translucent surfaces let the shared video remain visible throughout. */
.hero-art,
.card,
.rank-row,
.history-row,
.empty,
.search {
  background: rgba(10, 12, 23, 0.76);
  color: #f5f5f7;
}

.hero-art {
  border: 1px solid var(--line);
  color: var(--lime);
}

.rank-row:first-child {
  background: rgba(94, 113, 41, 0.55);
}

nav a,
.intro,
.stats span,
.team,
.vote-total,
.how p,
footer p,
footer > span,
.row-name p,
.rank-number,
.workspace > .muted {
  color: #c5c7d2;
}

nav .active,
.vote-total b,
.profile-link {
  color: #f5f5f7;
}

nav .active {
  border-bottom-color: var(--lime);
}

h1 > span {
  color: var(--lime);
}

.search input,
.chip {
  color: inherit;
}

.search input::placeholder {
  color: #bfc1cb;
}

.chip.active,
.vote-button {
  color: #202020;
  background: var(--lime);
  border-color: var(--lime);
}

/* Portrait colors identify candidates; dialogs retain a readable solid surface. */
dialog .profile-link,
dialog .close,
dialog .text-button {
  color: #202020;
}
