:root {
  --ink: #09100d;
  --night: #07130f;
  --night-soft: #0d2119;
  --felt: #0f4c39;
  --felt-light: #17624b;
  --ivory: #f3ead6;
  --muted: #a9b4ad;
  --line: rgba(243, 234, 214, 0.16);
  --wine: #8e2635;
  --wine-bright: #b83b4e;
  --copper: #b88551;
  --gold: #d6a866;
  --shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
  --header-h: 82px;
  --app-content-safe-top: 0px;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--night);
  color-scheme: dark;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow-x: clip;
  color: var(--ivory);
  background:
    radial-gradient(circle at 8% 10%, rgba(142, 38, 53, 0.16), transparent 28rem),
    radial-gradient(circle at 90% 18%, rgba(31, 93, 69, 0.2), transparent 30rem),
    var(--night);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.telegram-mini-app body {
  min-height: var(--tg-viewport-stable-height, 100vh);
  padding-bottom: max(0px, env(safe-area-inset-bottom));
}

button,
input {
  font: inherit;
}

button,
a,
.event-card {
  -webkit-tap-highlight-color: transparent;
}

button {
  color: inherit;
}

.grain {
  position: fixed;
  inset: 0;
  opacity: 0.08;
  pointer-events: none;
  z-index: 20;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.35'/%3E%3C/svg%3E");
}

.site-header {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(20px, 5vw, 72px);
  position: relative;
  z-index: 10;
  border-bottom: 1px solid var(--line);
}

.telegram-mini-app .site-header {
  height: calc(var(--header-h) + var(--app-content-safe-top));
  padding-top: var(--app-content-safe-top);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ivory);
  text-decoration: none;
  font-size: 14px;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.brand i {
  color: var(--muted);
  font-style: normal;
  font-weight: 500;
}

.brand-mark {
  width: 34px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 168, 102, 0.55);
  border-radius: 50%;
  color: var(--gold);
  font-family: Georgia, serif;
  font-size: 18px;
  font-weight: 400;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
  position: relative;
  z-index: 2;
}

.ghost-button,
.back-button,
.text-button {
  appearance: none;
  border: 0;
  background: none;
  cursor: pointer;
}

.ghost-button {
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 100px;
  color: var(--muted);
  font-size: 13px;
}

.dealer-nav-button {
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid rgba(214, 168, 102, 0.46);
  border-radius: 100px;
  background: rgba(214, 168, 102, 0.08);
  color: var(--gold);
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
}

.user-pill {
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  color: var(--ivory);
}

main {
  min-height: calc(100vh - var(--header-h));
}

.view {
  width: min(1320px, 100%);
  margin: 0 auto;
  padding: clamp(46px, 7vw, 96px) clamp(20px, 5vw, 72px) 80px;
}

.eyebrow,
.modal-kicker,
.event-type {
  color: var(--gold);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.18em;
  line-height: 1.4;
  text-transform: uppercase;
}

.events-heading {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(260px, 0.7fr);
  align-items: end;
  gap: 40px;
  margin: 18px 0 48px;
}

.events-heading h1,
.poker-copy h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(50px, 8vw, 112px);
  font-weight: 400;
  letter-spacing: -0.055em;
  line-height: 0.88;
}

.events-heading p,
.poker-copy p {
  max-width: 460px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(15px, 2vw, 18px);
  line-height: 1.65;
}

.event-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.event-card {
  min-height: 500px;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 26px;
}

.poker-card {
  padding: clamp(24px, 4vw, 42px);
  cursor: pointer;
  background:
    radial-gradient(circle at 73% 36%, rgba(56, 126, 94, 0.38), transparent 34%),
    linear-gradient(135deg, #13281f, #0a1712 70%);
  box-shadow: var(--shadow);
  transition: transform 220ms ease, border-color 220ms ease;
}

.poker-card:hover,
.poker-card:focus-visible,
.beach-card:hover,
.beach-card:focus-visible,
.cinema-card:hover,
.cinema-card:focus-visible {
  transform: translateY(-4px);
  border-color: rgba(214, 168, 102, 0.48);
  outline: none;
}

.beach-card {
  padding: clamp(24px, 4vw, 42px);
  cursor: pointer;
  background:
    radial-gradient(circle at 78% 20%, rgba(255, 219, 121, 0.52), transparent 20%),
    linear-gradient(165deg, #128fa5 0 34%, #77c8c5 34% 43%, #e4c184 43% 100%);
  box-shadow: var(--shadow);
  transition: transform 220ms ease, border-color 220ms ease;
}

.beach-card .card-topline,
.beach-card .event-date span,
.beach-card .event-name p,
.beach-card .event-time small,
.beach-card .seats-mini {
  color: rgba(8, 38, 40, 0.7);
}

.beach-card .event-type {
  color: #7d3f20;
}

.beach-card .event-date,
.beach-card .event-name,
.beach-card .event-time {
  color: #102f2d;
}

.beach-card .card-footer {
  border-color: rgba(16, 47, 45, 0.24);
}

.beach-card .round-arrow {
  background: #123d38;
  color: #fff1ce;
}

.beach-card-art {
  position: absolute;
  inset: 45px 0 0 36%;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}

.beach-sun {
  width: 96px;
  height: 96px;
  position: absolute;
  right: 11%;
  top: 8%;
  border-radius: 50%;
  background: #ffd46f;
  box-shadow: 0 0 55px rgba(255, 212, 111, 0.8);
}

.beach-water {
  position: absolute;
  inset: 0;
  background:
    repeating-radial-gradient(ellipse at 60% -10%, transparent 0 34px, rgba(255, 255, 255, 0.2) 35px 37px, transparent 38px 57px);
  opacity: 0.6;
}

.beach-mini-table {
  width: min(310px, 62vw);
  aspect-ratio: 1.75;
  position: absolute;
  left: 48%;
  top: 47%;
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%) rotate(-7deg);
  border: 12px solid #694328;
  border-radius: 50%;
  background: radial-gradient(circle, #1f8a68, #0b5746);
  box-shadow: 0 24px 35px rgba(68, 49, 26, 0.34), inset 0 0 0 2px #eac57e;
  color: rgba(255, 244, 207, 0.45);
  font-family: Georgia, serif;
  font-size: 27px;
  letter-spacing: 0.18em;
}

.mini-lounger {
  width: 38px;
  height: 78px;
  position: absolute;
  z-index: 2;
  border: 4px solid #7a4d2c;
  border-radius: 12px;
  background: repeating-linear-gradient(90deg, #fff0c5 0 9px, #e98058 9px 18px);
  box-shadow: 0 10px 16px rgba(80, 52, 25, 0.28);
}

.lounger-a { left: 22%; top: 24%; transform: rotate(-28deg); }
.lounger-b { right: 12%; top: 41%; transform: rotate(26deg); }
.lounger-c { left: 25%; bottom: 8%; transform: rotate(35deg); }

.cinema-card {
  grid-column: 1 / -1;
  padding: clamp(24px, 4vw, 42px);
  cursor: pointer;
  background:
    radial-gradient(circle at 73% 13%, rgba(105, 137, 195, .28), transparent 22%),
    linear-gradient(155deg, #101b27 0 42%, #18252b 42% 58%, #6f6048 58% 100%);
  box-shadow: var(--shadow);
  transition: transform 220ms ease, border-color 220ms ease;
}

.cinema-card-art {
  position: absolute;
  inset: 56px 3% 84px 43%;
  overflow: hidden;
  pointer-events: none;
}

.cinema-moon {
  width: 52px;
  height: 52px;
  position: absolute;
  right: 7%;
  top: 2%;
  border-radius: 50%;
  background: #f6e8ba;
  box-shadow: 0 0 45px rgba(246, 232, 186, .42);
}

.cinema-screen-mini {
  width: 58%;
  height: 46%;
  position: absolute;
  left: 50%;
  top: 11%;
  display: grid;
  place-items: center;
  transform: translateX(-50%);
  border: 7px solid #090b0d;
  border-radius: 7px;
  background: radial-gradient(circle at 50% 44%, #e6e4d7, #8494a7 72%, #42505d);
  box-shadow: 0 20px 40px rgba(0, 0, 0, .48);
  color: rgba(14, 24, 33, .62);
  font: 600 clamp(10px, 1.4vw, 18px)/1 Georgia, serif;
  letter-spacing: .18em;
}

.cinema-speaker {
  width: 8%;
  height: 44%;
  position: absolute;
  top: 14%;
  border: 3px solid #060708;
  border-radius: 5px;
  background:
    radial-gradient(circle at 50% 27%, #111 0 15%, #34383b 16% 18%, #070809 19% 26%, transparent 27%),
    radial-gradient(circle at 50% 72%, #111 0 19%, #34383b 20% 22%, #070809 23% 31%, transparent 32%),
    #171a1c;
  box-shadow: 0 14px 25px rgba(0, 0, 0, .5);
}

.speaker-left { left: 10%; }
.speaker-right { right: 10%; }

.cinema-mini-lounger {
  width: 17%;
  height: 20%;
  position: absolute;
  bottom: 4%;
  border: 2px solid #3f4143;
  border-radius: 18px 18px 9px 9px;
  background: linear-gradient(155deg, #292b2e, #070809 72%);
  box-shadow: 0 12px 18px rgba(0, 0, 0, .46), inset 0 1px rgba(255, 255, 255, .08);
}

.cinema-lounger-a { left: 18%; transform: rotate(-5deg); }
.cinema-lounger-b { left: 42%; }
.cinema-lounger-c { right: 17%; transform: rotate(5deg); }

.card-shine {
  position: absolute;
  width: 480px;
  height: 480px;
  top: -300px;
  right: -120px;
  border-radius: 50%;
  background: rgba(214, 168, 102, 0.13);
  filter: blur(65px);
}

.card-topline,
.card-footer,
.card-content {
  display: flex;
  align-items: center;
  position: relative;
  z-index: 2;
}

.card-topline {
  gap: 10px;
  color: #b8c4bc;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #68c69c;
  box-shadow: 0 0 0 5px rgba(104, 198, 156, 0.11);
}

.seats-mini {
  margin-left: auto;
  color: var(--muted);
}

.seats-mini b {
  color: var(--ivory);
}

.card-art {
  position: absolute;
  inset: 44px 0 0 45%;
  display: grid;
  place-items: center;
  opacity: 0.92;
}

.mini-table {
  width: min(400px, 70vw);
  aspect-ratio: 1.65;
  position: relative;
  transform: rotate(-12deg);
  border: 13px solid #111916;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 40%, rgba(255, 255, 255, 0.04), transparent 46%),
    #15513e;
  box-shadow:
    0 28px 40px rgba(0, 0, 0, 0.42),
    inset 0 0 0 2px rgba(214, 168, 102, 0.38);
}

.mini-table::after {
  content: "";
  position: absolute;
  inset: 14px;
  border: 1px solid rgba(214, 168, 102, 0.35);
  border-radius: inherit;
}

.mini-card {
  width: 52px;
  height: 72px;
  position: absolute;
  left: 42%;
  top: 35%;
  display: flex;
  flex-direction: column;
  padding: 7px;
  border-radius: 7px;
  background: var(--ivory);
  color: #111b16;
  font-family: Georgia, serif;
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.3);
}

.mini-card + .mini-card {
  left: 51%;
  transform: rotate(7deg);
}

.mini-card span {
  font-size: 17px;
}

.mini-card.red {
  color: var(--wine);
}

.mini-chip {
  width: 44px;
  height: 44px;
  position: absolute;
  z-index: 3;
  border: 5px dashed rgba(255, 255, 255, 0.65);
  border-radius: 50%;
  background: var(--wine);
  box-shadow: 0 5px 10px rgba(0, 0, 0, 0.35);
}

.chip-a {
  right: 16%;
  bottom: 19%;
}

.chip-b {
  right: 9%;
  bottom: 26%;
  background: #d9bc82;
}

.chip-c {
  left: 17%;
  top: 18%;
}

.card-content {
  min-height: 345px;
  align-items: end;
  gap: clamp(22px, 4vw, 58px);
}

.event-date {
  display: flex;
  align-items: end;
  gap: 13px;
  padding-bottom: 9px;
}

.event-date strong {
  font-family: Georgia, serif;
  font-size: clamp(62px, 9vw, 106px);
  font-weight: 400;
  letter-spacing: -0.08em;
  line-height: 0.75;
}

.event-date span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
  text-transform: uppercase;
}

.event-name h2,
.placeholder-card h2 {
  margin: 5px 0 3px;
  font-family: Georgia, serif;
  font-size: clamp(36px, 5vw, 66px);
  font-weight: 400;
  letter-spacing: -0.04em;
}

.event-name p,
.placeholder-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.card-footer {
  justify-content: space-between;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.event-time {
  font-size: 22px;
  font-weight: 650;
  letter-spacing: -0.03em;
}

.event-time small {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.1em;
}

.round-arrow {
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: var(--ivory);
  color: var(--ink);
  font-size: 21px;
}

.placeholder-card {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 38px;
  background:
    linear-gradient(rgba(255, 255, 255, 0.025), rgba(255, 255, 255, 0.025)),
    repeating-linear-gradient(135deg, transparent, transparent 9px, rgba(255, 255, 255, 0.018) 9px, rgba(255, 255, 255, 0.018) 10px);
}

.placeholder-card h2 {
  color: #6c7771;
}

.thin-line {
  width: 40px;
  height: 1px;
  margin-top: 30px;
  background: var(--line);
}

/* Poker table */
.poker-view {
  max-width: 1500px;
  padding-top: clamp(28px, 4vw, 56px);
}

.poker-intro {
  display: grid;
  grid-template-columns: 170px 1fr 150px;
  align-items: end;
  gap: 30px;
  margin-bottom: 38px;
}

.back-button {
  align-self: start;
  justify-self: start;
  padding: 10px 0;
  color: var(--muted);
  font-size: 13px;
}

.back-button:hover {
  color: var(--ivory);
}

.poker-copy h1 {
  margin: 11px 0 20px;
  font-size: clamp(52px, 7vw, 96px);
}

.availability {
  padding: 18px 0 5px 24px;
  border-left: 1px solid var(--line);
}

.availability span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.availability strong {
  font-family: Georgia, serif;
  font-size: 30px;
  font-weight: 400;
}

.table-stage {
  width: min(1080px, calc(100% - 140px));
  aspect-ratio: 1.95;
  position: relative;
  margin: 80px auto 60px;
}

.ambient {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
}

.ambient-one {
  width: 42%;
  height: 34%;
  left: -12%;
  top: 26%;
  background: rgba(142, 38, 53, 0.16);
}

.ambient-two {
  width: 45%;
  height: 36%;
  right: -12%;
  top: 22%;
  background: rgba(24, 104, 73, 0.22);
}

.poker-table {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 50%;
  background: #050a08;
  box-shadow:
    0 60px 100px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(214, 168, 102, 0.25);
}

.table-rail {
  position: absolute;
  inset: 3.8%;
  border: clamp(12px, 2vw, 25px) solid #15201c;
  border-radius: inherit;
  box-shadow:
    inset 0 0 0 2px rgba(214, 168, 102, 0.24),
    inset 0 0 24px rgba(0, 0, 0, 0.55),
    0 0 0 1px #000;
}

.felt {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
  background:
    radial-gradient(circle at 50% 32%, rgba(53, 134, 98, 0.28), transparent 42%),
    linear-gradient(145deg, #0f4f3b, #0a392a);
}

.felt::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.2;
  background-image: repeating-linear-gradient(70deg, transparent 0, transparent 3px, rgba(255, 255, 255, 0.025) 4px);
}

.felt-line {
  position: absolute;
  inset: 12%;
  border: 1px solid rgba(214, 168, 102, 0.38);
  border-radius: 50%;
}

.table-monogram {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform: translate(-50%, -50%);
  color: rgba(243, 234, 214, 0.18);
  font-family: Georgia, serif;
  font-size: clamp(22px, 4vw, 52px);
  letter-spacing: 0.18em;
}

.table-monogram small {
  margin-top: 4px;
  font-family: Inter, sans-serif;
  font-size: 9px;
  letter-spacing: 0.24em;
}

.community-cards {
  position: absolute;
  left: 50%;
  top: 70%;
  z-index: 2;
  display: flex;
  gap: 6px;
  transform: translateX(-50%);
}

.community-cards span {
  width: clamp(20px, 3vw, 35px);
  aspect-ratio: 0.72;
  display: grid;
  place-items: center;
  border-radius: 4px;
  background: rgba(243, 234, 214, 0.82);
  color: #142018;
  font-size: clamp(10px, 1.5vw, 18px);
  box-shadow: 0 5px 10px rgba(0, 0, 0, 0.24);
}

.community-cards .red-suit {
  color: var(--wine);
}

.dealer {
  appearance: none;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  position: absolute;
  left: 50%;
  top: -67px;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  transform: translateX(-50%);
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.dealer-chip {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 2px solid #c8b78e;
  border-radius: 50%;
  background: #e7dcc1;
  color: #172019;
  font-family: Georgia, serif;
  font-size: 17px;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.38);
  overflow: hidden;
}

.dealer-chip img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.seats {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
}

.seat {
  width: clamp(58px, 6vw, 74px);
  height: clamp(58px, 6vw, 74px);
  min-height: 0;
  position: absolute;
  display: grid;
  place-items: center;
  padding: 5px;
  border: 1px solid rgba(243, 234, 214, 0.22);
  border-radius: 50%;
  background: rgba(8, 18, 14, 0.96);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.38);
  cursor: pointer;
  pointer-events: auto;
  transition: transform 170ms ease, border-color 170ms ease, background 170ms ease;
}

.seat:hover,
.seat:focus-visible {
  border-color: rgba(214, 168, 102, 0.65);
  background: #14251e;
  outline: none;
}

.seat:active {
  transform: translate(-50%, -50%) scale(0.97);
}

.seat::after {
  content: "№" attr(data-seat);
  position: absolute;
  top: calc(100% + 5px);
  left: 50%;
  transform: translateX(-50%);
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

.seat-number {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  border: 1px solid rgba(243, 234, 214, 0.28);
  border-radius: 50%;
  color: var(--ivory);
  background: rgba(255, 255, 255, 0.025);
  font-family: Georgia, serif;
  font-size: 18px;
  overflow: hidden;
}

.seat-number img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.empty-player-icon {
  width: 27px;
  height: 29px;
  position: relative;
  display: block;
  opacity: 0.78;
}

.empty-player-icon::before {
  content: "";
  width: 10px;
  height: 10px;
  position: absolute;
  top: 2px;
  left: 50%;
  border: 1px solid #8ac9aa;
  border-radius: 50%;
  transform: translateX(-50%);
}

.empty-player-icon i {
  width: 24px;
  height: 12px;
  position: absolute;
  left: 50%;
  bottom: 2px;
  border: 1px solid #8ac9aa;
  border-radius: 14px 14px 7px 7px;
  transform: translateX(-50%);
}

.empty-player-icon::after {
  content: "+";
  width: 13px;
  height: 13px;
  position: absolute;
  right: -3px;
  bottom: -1px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #68c69c;
  color: #07130f;
  font: 800 10px/1 Arial, sans-serif;
}

.seat-copy {
  display: none;
}

.seat-copy strong,
.seat-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.seat-copy strong {
  font-size: 11px;
  font-weight: 650;
}

.seat-copy small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 9px;
}

.seat.is-busy {
  border-color: rgba(142, 38, 53, 0.35);
  background: rgba(50, 17, 23, 0.95);
}

.seat.is-busy .seat-number {
  border-color: rgba(184, 59, 78, 0.5);
  background: rgba(142, 38, 53, 0.42);
}

.seat.is-mine {
  border-color: rgba(214, 168, 102, 0.6);
  background: rgba(69, 49, 22, 0.9);
}

.seat.is-mine::after {
  content: "Вы · №" attr(data-seat);
  color: var(--gold);
}

.seat.is-closed {
  cursor: not-allowed;
  opacity: .38;
  filter: grayscale(.7);
}

.seat.is-closed:hover {
  border-color: rgba(243, 234, 214, .22);
  background: rgba(8, 18, 14, .96);
}

.seat-1 { left: 16%; top: 2%; transform: translate(-50%, -50%); }
.seat-2 { left: 84%; top: 2%; transform: translate(-50%, -50%); }
.seat-3 { left: 99%; top: 26%; transform: translate(-50%, -50%); }
.seat-4 { left: 99%; top: 74%; transform: translate(-50%, -50%); }
.seat-5 { left: 84%; top: 98%; transform: translate(-50%, -50%); }
.seat-6 { left: 16%; top: 98%; transform: translate(-50%, -50%); }
.seat-7 { left: 1%; top: 74%; transform: translate(-50%, -50%); }
.seat-8 { left: 1%; top: 26%; transform: translate(-50%, -50%); }

/* Beach poker table */
.beach-theme .poker-copy .eyebrow {
  color: #ffd478;
}

.beach-theme .table-stage {
  isolation: isolate;
}

.beach-theme .table-stage::before {
  content: "";
  position: absolute;
  inset: -18% -12%;
  z-index: -2;
  border-radius: 42%;
  background:
    radial-gradient(circle at 18% 72%, rgba(255, 255, 255, 0.4) 0 2px, transparent 3px),
    radial-gradient(circle at 82% 82%, rgba(125, 74, 39, 0.2) 0 3px, transparent 4px),
    linear-gradient(165deg, #50b7c7 0 24%, #9ee0d5 24% 34%, #dabb7c 34% 100%);
  background-size: auto, 48px 48px, auto;
  box-shadow: 0 38px 95px rgba(0, 0, 0, 0.42);
}

.beach-theme .ambient-one {
  background: rgba(255, 185, 75, 0.3);
}

.beach-theme .ambient-two {
  background: rgba(48, 187, 198, 0.35);
}

.beach-theme .poker-table {
  background: #53361f;
  box-shadow: 0 45px 75px rgba(71, 45, 20, 0.5), 0 0 0 1px rgba(255, 224, 154, 0.55);
}

.beach-theme .table-rail {
  border-color: #70482b;
  box-shadow: inset 0 0 0 2px rgba(255, 221, 145, 0.6), inset 0 0 24px rgba(0, 0, 0, 0.4), 0 0 0 1px #3e2819;
}

.beach-theme .felt {
  background:
    radial-gradient(circle at 50% 28%, rgba(114, 230, 189, 0.28), transparent 43%),
    linear-gradient(145deg, #168268, #075243);
}

.beach-theme .felt-line {
  border-color: rgba(255, 221, 145, 0.58);
}

.beach-theme .seat {
  width: clamp(62px, 6vw, 76px);
  height: clamp(78px, 8vw, 96px);
  padding: 8px;
  border: 4px solid #7b4e2e;
  border-radius: 18px;
  background: repeating-linear-gradient(90deg, #f9e8b8 0 11px, #df7757 11px 22px);
  box-shadow: 0 15px 27px rgba(82, 53, 25, 0.38);
}

.beach-theme .seat-number {
  width: 100%;
  aspect-ratio: 1;
  height: auto;
  align-self: start;
  border: 3px solid rgba(255, 247, 217, 0.92);
  background: #123d38;
}

.beach-theme .seat::after {
  top: calc(100% + 6px);
  color: #fff2cf;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.7);
}

.beach-theme .seat-1 { left: 17%; top: 3%; }
.beach-theme .seat-2 { left: 83%; top: 3%; }
.beach-theme .seat-3 { left: 100%; top: 50%; }
.beach-theme .seat-4 { left: 83%; top: 97%; }
.beach-theme .seat-5 { left: 17%; top: 97%; }
.beach-theme .seat-6 { left: 0%; top: 50%; }

/* Beach cinema: screen, two speaker columns and nine soft loungers */
.cinema-theme .poker-copy .eyebrow {
  color: #f0bd69;
}

.cinema-theme .table-stage {
  width: min(900px, calc(100% - 100px));
  aspect-ratio: 1.18;
  margin-top: 45px;
  margin-bottom: 100px;
  isolation: isolate;
}

.cinema-theme .table-stage::before {
  content: "";
  position: absolute;
  inset: -5% -8% -8%;
  z-index: -2;
  border-radius: 36px;
  background:
    radial-gradient(circle at 50% 4%, rgba(223, 226, 210, .12), transparent 25%),
    repeating-radial-gradient(ellipse at 50% 108%, transparent 0 45px, rgba(255, 255, 255, .025) 46px 48px),
    linear-gradient(#0b1720 0 46%, #655943 46% 100%);
  box-shadow: 0 42px 100px rgba(0, 0, 0, .52);
}

.cinema-theme .ambient-one {
  background: rgba(76, 112, 177, .25);
}

.cinema-theme .ambient-two {
  background: rgba(214, 168, 102, .18);
}

.cinema-theme .poker-table {
  inset: 1% 13% auto;
  height: 37%;
  border-radius: 12px;
  background: #050607;
  box-shadow: 0 32px 55px rgba(0, 0, 0, .62), 0 0 0 1px rgba(214, 168, 102, .25);
}

.cinema-theme .poker-table::before,
.cinema-theme .poker-table::after {
  content: "";
  width: 9%;
  height: 84%;
  position: absolute;
  top: 9%;
  z-index: 3;
  border: 4px solid #030405;
  border-radius: 7px;
  background:
    radial-gradient(circle at 50% 27%, #0b0c0d 0 15%, #3a3e41 16% 18%, #070809 19% 27%, transparent 28%),
    radial-gradient(circle at 50% 72%, #0b0c0d 0 19%, #3a3e41 20% 22%, #070809 23% 32%, transparent 33%),
    #171a1c;
  box-shadow: 0 17px 30px rgba(0, 0, 0, .58);
}

.cinema-theme .poker-table::before { left: -13%; }
.cinema-theme .poker-table::after { right: -13%; }

.cinema-theme .table-rail {
  inset: 3%;
  border-width: 10px;
  border-color: #16191b;
  border-radius: 7px;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .08), 0 0 0 1px #000;
}

.cinema-theme .felt {
  border-radius: 3px;
  background:
    radial-gradient(circle at 50% 43%, rgba(255, 255, 255, .7), transparent 36%),
    linear-gradient(145deg, #8096ab, #d7d8ca 52%, #566879);
}

.cinema-theme .felt-line,
.cinema-theme .community-cards {
  display: none;
}

.cinema-theme .table-monogram {
  width: 100%;
  color: rgba(10, 20, 29, .55);
  font-size: clamp(17px, 3vw, 34px);
  text-align: center;
}

.cinema-theme .seat {
  width: clamp(82px, 10vw, 112px);
  height: clamp(62px, 7.5vw, 82px);
  padding: 9px 10px 8px;
  border: 2px solid #3a3d3f;
  border-radius: 28px 28px 15px 15px;
  background:
    linear-gradient(155deg, rgba(255, 255, 255, .09), transparent 36%),
    linear-gradient(145deg, #242629, #08090a 72%);
  box-shadow: 0 17px 24px rgba(0, 0, 0, .5), inset 0 2px rgba(255, 255, 255, .06);
}

.cinema-theme .seat-number {
  width: clamp(44px, 5vw, 58px);
  height: clamp(44px, 5vw, 58px);
  align-self: start;
  border: 2px solid rgba(214, 168, 102, .48);
  background: #111719;
}

.cinema-theme .seat::before {
  content: "";
  position: absolute;
  inset: 9px 8px 7px;
  z-index: -1;
  border-radius: 22px 22px 11px 11px;
  box-shadow: inset 0 -12px 18px rgba(0, 0, 0, .5);
}

.cinema-theme .seat::after {
  top: calc(100% + 5px);
  color: #f0e6d5;
  text-shadow: 0 2px 5px #000;
}

.cinema-theme .seat.is-busy {
  border-color: rgba(142, 38, 53, .72);
  background: linear-gradient(145deg, #352126, #09090a 72%);
}

.cinema-theme .seat.is-mine {
  border-color: rgba(214, 168, 102, .9);
}

.cinema-theme .seat-1 { left: 17%; top: 50%; }
.cinema-theme .seat-2 { left: 50%; top: 50%; }
.cinema-theme .seat-3 { left: 83%; top: 50%; }
.cinema-theme .seat-4 { left: 17%; top: 72%; }
.cinema-theme .seat-5 { left: 50%; top: 72%; }
.cinema-theme .seat-6 { left: 83%; top: 72%; }
.cinema-theme .seat-7 { left: 17%; top: 94%; }
.cinema-theme .seat-8 { left: 50%; top: 94%; }
.cinema-theme .seat-9 { left: 83%; top: 94%; transform: translate(-50%, -50%); }

.table-legend {
  display: flex;
  justify-content: center;
  gap: 22px;
  color: var(--muted);
  font-size: 11px;
}

.legend-dot {
  width: 7px;
  height: 7px;
  display: inline-block;
  margin-right: 6px;
  border-radius: 50%;
}

.legend-dot.free { background: #68c69c; }
.legend-dot.busy { background: var(--wine-bright); }

/* Dealer dashboard */
.dealer-view {
  max-width: 1180px;
}

.dealer-page-head {
  display: grid;
  grid-template-columns: 1fr 180px;
  align-items: end;
  gap: 40px;
  margin-bottom: 48px;
}

.dealer-page-head h1 {
  margin: 14px 0 22px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(52px, 8vw, 100px);
  font-weight: 400;
  letter-spacing: -0.055em;
  line-height: 0.88;
}

.dealer-page-head p {
  max-width: 570px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
}

.dealer-count-card {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.025);
}

.dealer-count-card span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.dealer-count-card strong {
  font-family: Georgia, serif;
  font-size: 34px;
  font-weight: 400;
}

.dealer-access-card,
.dealer-content {
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid var(--line);
  border-radius: 22px;
  background:
    radial-gradient(circle at 100% 0, rgba(142, 38, 53, 0.12), transparent 36%),
    rgba(14, 30, 23, 0.78);
  box-shadow: var(--shadow);
}

.dealer-access-card {
  max-width: 620px;
}

.dealer-access-card h2 {
  margin: 8px 0 12px;
  font-family: Georgia, serif;
  font-size: clamp(34px, 6vw, 52px);
  font-weight: 400;
  letter-spacing: -0.04em;
}

.dealer-access-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.dealer-access-card .telegram-box {
  margin-bottom: 0;
}

.dealer-denied code {
  padding: 2px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--ivory);
}

.admin-event-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(4, 14, 10, 0.45);
}

.admin-event-tab {
  min-height: 50px;
  padding: 10px 14px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-weight: 700;
}

.admin-event-tab.is-active {
  border-color: rgba(214, 168, 102, 0.48);
  background: rgba(214, 168, 102, 0.14);
  color: var(--ivory);
}

.dealer-event-controls {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 190px 105px;
  align-items: end;
  gap: 14px;
  margin-bottom: 32px;
  padding: 20px;
  border: 1px solid rgba(214, 168, 102, 0.24);
  border-radius: 16px;
  background: rgba(214, 168, 102, 0.055);
}

.dealer-event-controls > div:first-child {
  grid-row: 1 / span 2;
}

.event-location-field {
  grid-column: 2 / 4;
}

.event-description-field,
.dealer-event-actions {
  grid-column: 1 / -1;
}

.dealer-event-controls h2 {
  margin: 5px 0;
  font-family: Georgia, serif;
  font-size: 28px;
  font-weight: 400;
}

.dealer-event-controls p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.dealer-event-controls label span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.dealer-event-controls input,
.dealer-event-controls textarea {
  width: 100%;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #0b1712;
  color: var(--ivory);
  outline: none;
}

.dealer-event-controls input {
  height: 44px;
}

.dealer-event-controls textarea {
  min-height: 92px;
  padding-block: 11px;
  resize: vertical;
  line-height: 1.45;
}

.dealer-event-controls input:focus,
.dealer-event-controls textarea:focus {
  border-color: rgba(214, 168, 102, .6);
}

.dealer-event-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.publish-button {
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid rgba(104, 198, 156, .45);
  border-radius: 11px;
  background: rgba(104, 198, 156, .14);
  color: #9ce0bb;
  cursor: pointer;
  font-weight: 720;
}

.publish-button:hover,
.publish-button:focus-visible {
  background: rgba(104, 198, 156, .24);
  outline: none;
}

.dealer-list-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.dealer-list {
  display: grid;
  gap: 10px;
}

.dealer-person-card {
  display: grid;
  grid-template-columns: 52px 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  min-height: 78px;
  padding: 12px 16px;
  border: 1px solid rgba(243, 234, 214, 0.12);
  border-radius: 15px;
  background: rgba(4, 12, 8, 0.42);
}

.dealer-seat-badge {
  width: 43px;
  height: 43px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(214, 168, 102, 0.48);
  border-radius: 50%;
  color: var(--gold);
  font-family: Georgia, serif;
}

.dealer-avatar {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(243, 234, 214, 0.2);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: var(--ivory);
  font-family: Georgia, serif;
  font-size: 13px;
}

.dealer-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.dealer-person-main,
.dealer-person-meta {
  min-width: 0;
}

.dealer-person-main strong,
.dealer-person-main span,
.dealer-person-meta small,
.dealer-person-meta time {
  display: block;
}

.dealer-person-main strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 15px;
}

.dealer-person-main span {
  margin-top: 5px;
  color: var(--gold);
  font-size: 12px;
}

.dealer-person-meta {
  text-align: right;
}

.dealer-person-meta small {
  color: #77847d;
  font-size: 10px;
}

.dealer-person-meta time {
  margin-top: 6px;
  color: var(--muted);
  font-size: 11px;
}

.dealer-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid rgba(243, 234, 214, 0.08);
}

.dealer-action-button {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 11px;
}

.dealer-action-button.no-show {
  border-color: rgba(184, 59, 78, 0.42);
  color: #e1939f;
}

.no-show-badge {
  display: inline-flex !important;
  width: fit-content;
  margin-top: 6px !important;
  padding: 3px 7px;
  border-radius: 100px;
  background: rgba(184, 59, 78, 0.13);
  color: #e1939f !important;
  font-size: 9px !important;
}

.dealer-empty {
  padding: 50px 20px;
  color: var(--muted);
  text-align: center;
}

.participants-history {
  margin-top: 42px;
  padding-top: 36px;
  border-top: 1px solid var(--line);
}

.participants-history-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: end;
}

.participants-history-head h2 {
  margin: 7px 0 8px;
  font-family: Georgia, serif;
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 400;
  letter-spacing: -0.04em;
}

.participants-history-head p {
  max-width: 650px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.participants-total {
  min-width: 88px;
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  text-align: center;
}

.participants-total span,
.participants-total strong {
  display: block;
}

.participants-total span {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.participants-total strong {
  color: var(--gold);
  font-family: Georgia, serif;
  font-size: 24px;
}

.participants-search {
  display: block;
  margin-top: 22px;
}

.participants-search span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.participants-search input {
  width: 100%;
  min-width: 0;
  height: 46px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #0b1712;
  color: var(--ivory);
  outline: none;
}

.participants-search input:focus {
  border-color: rgba(214, 168, 102, .6);
}

.participants-filters {
  display: flex;
  gap: 8px;
  margin: 14px 0 18px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
}

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

.participant-filter {
  min-height: 34px;
  flex: 0 0 auto;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 100px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 10px;
  white-space: nowrap;
}

.participant-filter.is-active {
  border-color: rgba(214, 168, 102, .55);
  background: rgba(214, 168, 102, .12);
  color: var(--gold);
}

.participants-list {
  display: grid;
  gap: 12px;
}

.participant-card {
  padding: 15px;
  border: 1px solid rgba(243, 234, 214, .12);
  border-radius: 16px;
  background: rgba(4, 12, 8, .42);
}

.participant-card-main {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.participant-identity {
  min-width: 0;
}

.participant-identity strong,
.participant-identity span,
.participant-identity small,
.participant-last-seen small,
.participant-last-seen time {
  display: block;
}

.participant-identity strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.participant-identity span {
  margin-top: 3px;
  color: var(--gold);
  font-size: 12px;
}

.participant-identity small,
.participant-last-seen small {
  margin-top: 5px;
  color: #77847d;
  font-size: 9px;
}

.participant-last-seen {
  text-align: right;
}

.participant-last-seen time {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
}

.participant-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 13px;
}

.participant-badge {
  padding: 5px 8px;
  border-radius: 100px;
  background: rgba(255, 255, 255, .055);
  color: var(--muted);
  font-size: 9px;
}

.participant-badge.is-warning,
.participant-badge.is-unpaid,
.participant-badge.is-blocked {
  background: rgba(142, 38, 53, .18);
  color: #e7a2ac;
}

.participant-badge.is-paid,
.participant-badge.is-active-seat {
  background: rgba(104, 198, 156, .12);
  color: #85d6af;
}

.participant-penalties {
  display: grid;
  gap: 7px;
  margin-top: 13px;
  padding-top: 12px;
  border-top: 1px solid rgba(243, 234, 214, .08);
}

.penalty-row {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  padding: 9px 10px;
  border-radius: 10px;
  background: rgba(142, 38, 53, .09);
}

.penalty-row.is-paid {
  background: rgba(104, 198, 156, .07);
}

.penalty-row strong,
.penalty-row small {
  display: block;
}

.penalty-row strong {
  font-size: 12px;
}

.penalty-row small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 9px;
}

.penalty-status-button {
  min-height: 32px;
  flex: 0 0 auto;
  padding: 0 10px;
  border: 1px solid rgba(214, 168, 102, .38);
  border-radius: 8px;
  background: rgba(214, 168, 102, .08);
  color: var(--gold);
  cursor: pointer;
  font-size: 9px;
}

.penalty-row.is-paid .penalty-status-button {
  border-color: rgba(104, 198, 156, .3);
  background: rgba(104, 198, 156, .08);
  color: #85d6af;
}

.participants-empty {
  padding: 38px 16px;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
}

/* Modal */
.modal-shell {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
}

.modal-shell[hidden],
[hidden] {
  display: none !important;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(2, 8, 5, 0.78);
  backdrop-filter: blur(12px);
}

.modal {
  width: min(520px, 100%);
  position: relative;
  z-index: 1;
  padding: clamp(28px, 5vw, 48px);
  border: 1px solid rgba(214, 168, 102, 0.34);
  border-radius: 24px;
  background:
    radial-gradient(circle at 100% 0, rgba(142, 38, 53, 0.14), transparent 42%),
    #101d17;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.62);
}

.modal-close {
  width: 38px;
  height: 38px;
  position: absolute;
  top: 14px;
  right: 14px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  cursor: pointer;
  font-size: 23px;
}

.modal h2 {
  margin: 8px 0;
  font-family: Georgia, serif;
  font-size: clamp(38px, 7vw, 56px);
  font-weight: 400;
  letter-spacing: -0.04em;
}

.modal-lead {
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.notice {
  display: flex;
  gap: 13px;
  margin: 24px 0 18px;
  padding: 17px;
  border: 1px solid rgba(184, 59, 78, 0.35);
  border-radius: 14px;
  background: rgba(142, 38, 53, 0.12);
}

.notice-icon {
  width: 26px;
  height: 26px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--wine);
  font-weight: 800;
}

.notice p {
  margin: 0;
  color: #d8cec0;
  font-size: 13px;
  line-height: 1.55;
}

.accept-row {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 10px;
  align-items: start;
  margin: 18px 0 24px;
  color: #c6cec8;
  cursor: pointer;
  font-size: 12px;
  line-height: 1.45;
}

.accept-row input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.custom-check {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(243, 234, 214, 0.35);
  border-radius: 6px;
}

.accept-row input:checked + .custom-check {
  border-color: var(--gold);
  background: var(--gold);
}

.accept-row input:checked + .custom-check::after {
  content: "✓";
  color: var(--ink);
  font-weight: 800;
}

.accept-row input:focus-visible + .custom-check {
  outline: 2px solid var(--ivory);
  outline-offset: 2px;
}

.primary-button {
  width: 100%;
  min-height: 54px;
  border: 0;
  border-radius: 13px;
  background: var(--ivory);
  color: var(--ink);
  cursor: pointer;
  font-weight: 760;
}

.danger-button {
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid rgba(184, 59, 78, 0.5);
  border-radius: 11px;
  background: rgba(142, 38, 53, 0.22);
  color: #f2c7cd;
  cursor: pointer;
  font-weight: 720;
}

.danger-button:hover,
.danger-button:focus-visible {
  background: rgba(142, 38, 53, 0.4);
  outline: none;
}

.full-button {
  width: 100%;
}

.player-modal {
  text-align: center;
}

.player-profile-avatar {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  margin: 0 auto 20px;
  overflow: hidden;
  border: 2px solid rgba(214, 168, 102, 0.55);
  border-radius: 50%;
  background: rgba(214, 168, 102, 0.1);
  color: var(--ivory);
  font-family: Georgia, serif;
  font-size: 25px;
}

.player-profile-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.cancellation-notice.is-free {
  border-color: rgba(104, 198, 156, 0.36);
  background: rgba(104, 198, 156, 0.1);
}

.cancellation-notice.is-free .notice-icon {
  background: #287454;
}

.telegram-open-button {
  width: 100%;
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  border-radius: 13px;
  background: #2aabee;
  color: #fff;
  font-weight: 760;
  text-decoration: none;
  transition: filter 180ms ease, transform 180ms ease;
}

.telegram-open-button:hover,
.telegram-open-button:focus-visible {
  filter: brightness(1.08);
  outline: 2px solid rgba(255, 255, 255, 0.72);
  outline-offset: 3px;
}

.telegram-open-button:active {
  transform: translateY(1px);
}

.primary-button:disabled {
  cursor: not-allowed;
  opacity: 0.32;
}

.telegram-box {
  min-height: 84px;
  display: grid;
  place-items: center;
  margin: 20px 0;
  padding: 18px;
  border: 1px dashed rgba(243, 234, 214, 0.22);
  border-radius: 14px;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
  line-height: 1.5;
}

.text-button {
  width: 100%;
  padding: 10px;
  color: var(--muted);
  font-size: 12px;
}

.success-mark {
  width: 62px;
  height: 62px;
  display: grid;
  place-items: center;
  margin-bottom: 22px;
  border: 1px solid rgba(104, 198, 156, 0.5);
  border-radius: 50%;
  background: rgba(104, 198, 156, 0.12);
  color: #85d6af;
  font-size: 27px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: max(24px, env(safe-area-inset-bottom));
  z-index: 150;
  min-width: min(360px, calc(100% - 32px));
  padding: 14px 18px;
  transform: translateX(-50%);
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #17231e;
  box-shadow: var(--shadow);
  color: var(--ivory);
  text-align: center;
  font-size: 13px;
}

@media (max-width: 900px) {
  .events-heading,
  .event-grid {
    grid-template-columns: 1fr;
  }

  .events-heading {
    align-items: start;
    gap: 24px;
  }

  .placeholder-card {
    min-height: 260px;
  }

  .poker-intro {
    grid-template-columns: 1fr auto;
  }

  .back-button {
    grid-column: 1 / -1;
  }

  .table-stage {
    width: calc(100% - 100px);
    margin-top: 70px;
  }
}

@media (max-width: 640px) {
  :root {
    --header-h: 66px;
  }

  .site-header {
    padding-inline: max(16px, env(safe-area-inset-left)) max(16px, env(safe-area-inset-right));
  }

  .brand {
    min-width: 0;
    font-size: 12px;
  }

  .brand i,
  .ghost-button,
  .user-pill {
    display: none;
  }

  .view {
    width: 100%;
    max-width: 100%;
    padding: 35px 16px 60px;
  }

  .dealer-nav-button {
    min-width: 128px;
    min-height: 46px;
    padding: 0 16px;
    border-color: rgba(214, 168, 102, 0.7);
    background: rgba(214, 168, 102, 0.18);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.24);
    color: var(--ivory);
    font-size: 12px;
    letter-spacing: .02em;
    touch-action: manipulation;
  }

  .dealer-nav-button::before {
    content: "⚙";
    margin-right: 7px;
    color: var(--gold);
    font-size: 15px;
  }

  .dealer-page-head {
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
    gap: 16px;
    margin-bottom: 30px;
  }

  .dealer-page-head h1 {
    margin-bottom: 17px;
    font-size: clamp(43px, 13.5vw, 60px);
    letter-spacing: -0.065em;
  }

  .dealer-page-head p {
    max-width: 100%;
    font-size: 14px;
  }

  .dealer-count-card {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 14px;
  }

  .dealer-count-card span {
    margin: 0;
  }

  .dealer-count-card strong {
    font-size: 23px;
  }

  .dealer-content,
  .dealer-access-card {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    padding: 20px 14px;
    border-radius: 18px;
  }

  .admin-event-tabs {
    grid-template-columns: 1fr;
  }

  .dealer-event-controls {
    grid-template-columns: minmax(0, 1.05fr) minmax(96px, .95fr);
    gap: 8px;
    padding: 14px;
  }

  .dealer-event-controls label,
  .dealer-event-controls input,
  .dealer-event-controls textarea {
    min-width: 0;
    max-width: 100%;
  }

  .dealer-event-controls input {
    padding-inline: 8px;
    font-size: 15px;
  }

  .dealer-event-controls > div,
  .dealer-event-controls .danger-button,
  .event-location-field,
  .event-description-field {
    grid-column: 1 / -1;
  }

  .dealer-event-controls > div:first-child {
    grid-row: auto;
  }

  .dealer-event-actions {
    flex-direction: column;
  }

  .dealer-event-actions button {
    width: 100%;
  }

  .dealer-person-card {
    grid-template-columns: 40px 40px minmax(0, 1fr);
    gap: 10px;
    padding: 10px;
  }

  .dealer-person-meta {
    grid-column: 3;
    text-align: left;
  }

  .participants-history {
    margin-top: 34px;
    padding-top: 28px;
  }

  .participants-history-head {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
  }

  .participants-history-head h2 {
    font-size: 37px;
  }

  .participants-history-head p {
    grid-column: 1 / -1;
  }

  .participants-total {
    min-width: 70px;
    padding: 10px;
  }

  .participant-card {
    padding: 12px;
  }

  .participant-card-main {
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 10px;
  }

  .participant-last-seen {
    grid-column: 2;
    text-align: left;
  }

  .penalty-row {
    align-items: stretch;
    flex-direction: column;
  }

  .penalty-status-button {
    width: 100%;
    min-height: 38px;
  }

  .events-heading {
    margin-bottom: 30px;
  }

  .events-heading h1 {
    font-size: clamp(48px, 16vw, 72px);
  }

  .event-card {
    min-height: 520px;
    border-radius: 22px;
  }

  .poker-card,
  .beach-card,
  .cinema-card {
    padding: 22px;
  }

  .beach-card-art {
    inset: 62px -55px auto 23%;
    height: 265px;
  }

  .beach-mini-table {
    width: 275px;
  }

  .cinema-card-art {
    inset: 62px -24px auto 22%;
    height: 270px;
  }

  .card-art {
    inset: 66px -90px auto 30%;
    height: 245px;
  }

  .mini-table {
    width: 320px;
  }

  .card-content {
    min-height: 390px;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
    gap: 22px;
  }

  .event-date strong {
    font-size: 84px;
  }

  .event-name h2 {
    font-size: 50px;
  }

  .placeholder-card {
    min-height: 230px;
  }

  .poker-view {
    overflow: hidden;
    padding-inline: 14px;
  }

  .poker-intro {
    grid-template-columns: 1fr auto;
    gap: 12px;
  }

  .poker-copy h1 {
    font-size: clamp(47px, 15vw, 68px);
  }

  .poker-copy p {
    max-width: 290px;
    font-size: 14px;
  }

  .availability {
    padding-left: 14px;
  }

  .availability strong {
    font-size: 24px;
  }

  .table-stage {
    width: calc(100% - 74px);
    max-width: 420px;
    aspect-ratio: 0.78;
    margin-top: 86px;
    margin-bottom: 84px;
  }

  .poker-table,
  .table-rail,
  .felt,
  .felt-line {
    border-radius: 46%;
  }

  .table-rail {
    inset: 3%;
    border-width: 15px;
  }

  .felt-line {
    inset: 9%;
  }

  .community-cards {
    top: 68%;
  }

  .dealer {
    top: -75px;
  }

  .seat {
    width: 56px;
    height: 56px;
    min-height: 0;
    position: absolute;
    padding: 4px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
  }

  .seat-number {
    width: 100%;
    height: 100%;
    font-size: 15px;
  }

  .seats {
    inset: 0;
    display: block;
    pointer-events: none;
  }

  .seat-1 { left: 19%; top: 2%; }
  .seat-2 { left: 81%; top: 2%; }
  .seat-3 { left: 100%; top: 28%; }
  .seat-4 { left: 100%; top: 72%; }
  .seat-5 { left: 81%; top: 98%; }
  .seat-6 { left: 19%; top: 98%; }
  .seat-7 { left: 0%; top: 72%; }
  .seat-8 { left: 0%; top: 28%; }

  .beach-theme .table-stage::before {
    inset: -9% -13%;
    border-radius: 32%;
  }

  .beach-theme .seat {
    width: 54px;
    height: 72px;
    padding: 5px;
    border-width: 3px;
    border-radius: 15px;
  }

  .beach-theme .seat-number {
    border-width: 2px;
  }

  .beach-theme .seat-1 { left: 18%; top: 3%; }
  .beach-theme .seat-2 { left: 82%; top: 3%; }
  .beach-theme .seat-3 { left: 100%; top: 50%; }
  .beach-theme .seat-4 { left: 82%; top: 97%; }
  .beach-theme .seat-5 { left: 18%; top: 97%; }
  .beach-theme .seat-6 { left: 0%; top: 50%; }

  .cinema-theme .table-stage {
    width: calc(100% - 26px);
    max-width: 430px;
    aspect-ratio: .66;
    margin-top: 34px;
    margin-bottom: 100px;
  }

  .cinema-theme .table-stage::before {
    inset: -3% -5% -6%;
    border-radius: 26px;
  }

  .cinema-theme .poker-table {
    inset: 2% 14% auto;
    height: 29%;
    border-radius: 9px;
  }

  .cinema-theme .table-rail,
  .cinema-theme .felt {
    border-radius: 5px;
  }

  .cinema-theme .table-rail {
    border-width: 7px;
  }

  .cinema-theme .poker-table::before,
  .cinema-theme .poker-table::after {
    width: 10%;
    border-width: 3px;
  }

  .cinema-theme .poker-table::before { left: -15%; }
  .cinema-theme .poker-table::after { right: -15%; }

  .cinema-theme .seat {
    width: 78px;
    height: 62px;
    padding: 7px;
    border-radius: 22px 22px 12px 12px;
  }

  .cinema-theme .seat-number {
    width: 43px;
    height: 43px;
  }

  .cinema-theme .seat-1 { left: 15%; top: 43%; }
  .cinema-theme .seat-2 { left: 50%; top: 43%; }
  .cinema-theme .seat-3 { left: 85%; top: 43%; }
  .cinema-theme .seat-4 { left: 15%; top: 65%; }
  .cinema-theme .seat-5 { left: 50%; top: 65%; }
  .cinema-theme .seat-6 { left: 85%; top: 65%; }
  .cinema-theme .seat-7 { left: 15%; top: 87%; }
  .cinema-theme .seat-8 { left: 50%; top: 87%; }
  .cinema-theme .seat-9 { left: 85%; top: 87%; }

  .seat:hover,
  .seat:focus-visible {
    transform: translate(-50%, -50%) scale(1.04);
  }

  .seat:active {
    transform: translate(-50%, -50%) scale(0.96);
  }

  .table-legend {
    flex-wrap: wrap;
    gap: 10px 18px;
  }

  .table-legend span:last-child {
    flex-basis: 100%;
    text-align: center;
  }

  .modal-shell {
    align-items: end;
    padding: 0;
  }

  .modal {
    max-height: calc(100vh - 18px);
    overflow-y: auto;
    border-radius: 24px 24px 0 0;
    padding: 32px 22px calc(24px + env(safe-area-inset-bottom));
  }
}

@media (max-width: 410px) {
  .dealer-event-controls {
    grid-template-columns: minmax(0, 1.02fr) minmax(94px, .98fr);
  }

  .dealer-event-controls > div,
  .event-location-field,
  .event-description-field,
  .dealer-event-controls .danger-button {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
