/* The connection at a game's table (tables/tablenet.js), in the majlis's warm night colours. The line's colour everywhere:
   4 ممتاز green, 3 جيد lime, 2 متوسط amber, 1 ضعيف red, 0 منقطع red and crossed, n measuring. */
.tn-chip, .tn-sheet, .tn-banner { --tn-ink: #FFF6E6; --tn-mut: #C9B59A; --tn-line: rgba(232, 184, 74, .26); --tn-row: rgba(255, 236, 200, .06); --tn-gold: #FFE3A0; font-family: "Readex Pro", system-ui, sans-serif; }
.tn-nb { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; flex: none; position: relative; }
.tn-nb u { width: 3px; border-radius: 1.5px; background: rgba(255, 236, 200, .2); transition: background .25s; }
.tn-nb u:nth-child(1) { height: 28%; } .tn-nb u:nth-child(2) { height: 52%; } .tn-nb u:nth-child(3) { height: 76%; } .tn-nb u:nth-child(4) { height: 100%; }
[data-q="4"] > .tn-nb u, [data-q="4"] .tn-ps .tn-nb u { background: #2BD46A; }
[data-q="3"] > .tn-nb u:nth-child(-n+3), [data-q="3"] .tn-ps .tn-nb u:nth-child(-n+3) { background: #9BE15D; }
[data-q="2"] > .tn-nb u:nth-child(-n+2), [data-q="2"] .tn-ps .tn-nb u:nth-child(-n+2) { background: #F5B93A; }
[data-q="1"] > .tn-nb u:nth-child(1), [data-q="1"] .tn-ps .tn-nb u:nth-child(1) { background: #FF5A5F; }
[data-q="0"] > .tn-nb u, [data-q="0"] .tn-ps .tn-nb u { background: rgba(255, 90, 95, .38); }
[data-q="0"] > .tn-nb::after { content: ""; position: absolute; left: -3px; right: -3px; top: 50%; height: 2px; border-radius: 1px; background: #FF5A5F; transform: rotate(-40deg); }
[data-q="n"] > .tn-nb u { animation: tnWait 1.2s ease-in-out infinite; } [data-q="n"] > .tn-nb u:nth-child(2) { animation-delay: .15s; } [data-q="n"] > .tn-nb u:nth-child(3) { animation-delay: .3s; } [data-q="n"] > .tn-nb u:nth-child(4) { animation-delay: .45s; }
@keyframes tnWait { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }
/* the chip in the top bar */
.tn-chip { flex: none; display: inline-flex; align-items: center; gap: 5px; height: 34px; padding: 0 10px; border-radius: 12px; border: 1px solid rgba(232, 184, 74, .38); background: rgba(20, 11, 8, .6); color: var(--tn-ink);
  font: 700 12.5px/1 "Readex Pro", sans-serif; font-variant-numeric: tabular-nums; cursor: pointer; transition: border-color .2s, background .2s; }
.tn-chip[hidden] { display: none !important; }
.tn-chip small { display: none; font-size: 9.5px; font-weight: 700; color: var(--tn-mut); }
.tn-chip.ms small { display: inline; }
.tn-chip b:empty { display: none; }
.tn-chip[data-q="0"] { border-color: rgba(255, 90, 95, .6); background: rgba(255, 90, 95, .14); }
.tn-chip[data-q="1"] { border-color: rgba(255, 90, 95, .5); } .tn-chip[data-q="2"] { border-color: rgba(245, 185, 58, .5); }
.tn-chip:focus-visible, .tn-sheet button:focus-visible, .tn-re:focus-visible { outline: 3px solid var(--tn-gold); outline-offset: 2px; }
/* a phone: the bar is full already (music, sound, the voice): the bars only, the ping in «الاتصال» */
@media (max-width: 440px) { .tn-chip b, .tn-chip.ms small { display: none; } .tn-chip { padding: 0 9px; } }
/* a seat whose line is weak or cut off */
.tn-q { position: absolute; z-index: 6; top: -4px; right: -6px; width: clamp(20px, 38%, 28px); aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center;
  color: #F5B93A; background: rgba(20, 11, 8, .94); border: 1.5px solid currentColor; box-shadow: 0 2px 8px rgba(0, 0, 0, .5); pointer-events: none; animation: tnIn .25s; }
.tn-q svg { width: 62%; height: 62%; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; }
.tn-q[data-q="1"], .tn-q[data-q="0"] { color: #FF5A5F; }
.tn-q[data-q="0"] { background: #3A0D12; animation: tnPulse 1.4s ease-in-out infinite; }
@keyframes tnPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(255, 90, 95, .55); } 50% { box-shadow: 0 0 0 6px rgba(255, 90, 95, 0); } }
@keyframes tnIn { from { opacity: 0; transform: scale(.6); } }
/* «الاتصال» */
.tn-sheet { position: fixed; inset: 0; z-index: 80; display: flex; align-items: flex-end; justify-content: center; background: rgba(8, 4, 2, .62); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); direction: rtl; color: var(--tn-ink); animation: tnFade .2s; }
.tn-sheet[hidden] { display: none !important; }
@keyframes tnFade { from { opacity: 0; } }
.tn-card { width: min(520px, 100%); max-height: min(84vh, 760px); overflow-y: auto; overscroll-behavior: contain; display: flex; flex-direction: column; padding: 10px 16px calc(16px + env(safe-area-inset-bottom, 0px));
  border-radius: 26px 26px 0 0; background: linear-gradient(170deg, #2A170C, #170C07); border: 1px solid var(--tn-line); border-bottom: 0; box-shadow: 0 -18px 50px rgba(0, 0, 0, .5); animation: tnUp .3s cubic-bezier(.2, .9, .25, 1); }
.tn-card::before { content: ""; display: block; flex: none; width: 42px; height: 5px; margin: 0 auto 6px; border-radius: 999px; background: rgba(255, 236, 200, .2); }
@keyframes tnUp { from { transform: translateY(40px); opacity: 0; } }
@media (min-width: 760px) { .tn-sheet { align-items: center; padding: 24px; } .tn-card { border-radius: 26px; border-bottom: 1px solid var(--tn-line); } .tn-card::before { display: none; } }
.tn-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 2px 0 8px; flex: none; }
.tn-head h2 { margin: 0; font: 800 20px/1.3 "Readex Pro", sans-serif; color: var(--tn-gold); }
.tn-x { flex: none; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--tn-line); background: var(--tn-row); color: var(--tn-ink); cursor: pointer; }
.tn-x svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }
.tn-hero { display: flex; align-items: center; gap: 14px; padding: 4px 2px 14px; flex: none; }
.tn-hero > .tn-nb { height: 30px; gap: 4px; } .tn-hero > .tn-nb u { width: 7px; border-radius: 3px; }
.tn-big { display: flex; align-items: baseline; gap: 5px; font-variant-numeric: tabular-nums; }
.tn-big b { font: 800 34px/1 "Readex Pro", sans-serif; } .tn-big small { color: var(--tn-mut); font-size: 13px; font-weight: 700; }
.tn-hl { min-width: 0; display: flex; flex-direction: column; gap: 3px; margin-inline-start: auto; text-align: end; }
.tn-hl b { font-size: 16px; font-weight: 800; } .tn-hl small { color: var(--tn-mut); font-size: 12px; line-height: 1.45; }
.tn-hero[data-q="4"] .tn-hl b { color: #2BD46A; } .tn-hero[data-q="3"] .tn-hl b { color: #9BE15D; } .tn-hero[data-q="2"] .tn-hl b { color: #F5B93A; } .tn-hero[data-q="1"] .tn-hl b, .tn-hero[data-q="0"] .tn-hl b { color: #FF5A5F; }
.tn-graph { --gc: #C9B59A; position: relative; flex: none; height: 124px; border-radius: 16px; background: var(--tn-row); border: 1px solid var(--tn-line); overflow: hidden; }
.tn-graph[data-q="4"] { --gc: #2BD46A; } .tn-graph[data-q="3"] { --gc: #9BE15D; } .tn-graph[data-q="2"] { --gc: #F5B93A; } .tn-graph[data-q="1"], .tn-graph[data-q="0"] { --gc: #FF5A5F; }
.tn-graph svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.tn-graph .gl { stroke: var(--tn-line); stroke-width: 1; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.tn-graph .ln { fill: none; stroke: var(--gc); stroke-width: 2; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.tn-graph .ar { fill: var(--gc); opacity: .14; } .tn-graph .dt { fill: var(--gc); } .tn-graph .ls { fill: rgba(255, 90, 95, .28); }
.tn-ax { position: absolute; inset-inline-start: 8px; transform: translateY(-115%); color: var(--tn-mut); font-size: 10px; font-weight: 600; font-variant-numeric: tabular-nums; pointer-events: none; }
.tn-wait { position: absolute; inset: 0; display: grid; place-items: center; color: var(--tn-mut); font-size: 12.5px; }
.tn-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 12px 0 2px; flex: none; }
.tn-tiles > div { min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 10px 6px; border-radius: 14px; background: var(--tn-row); border: 1px solid var(--tn-line); text-align: center; }
.tn-tiles small { color: var(--tn-mut); font-size: 11.5px; }
.tn-tiles b { max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14.5px; font-variant-numeric: tabular-nums; }
.tn-tiles .tn-tt { font-size: 10px; line-height: 1.3; }
@media (max-width: 380px) { .tn-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tn-h { margin: 16px 2px 8px; font-size: 13px; font-weight: 700; color: var(--tn-mut); flex: none; }
.tn-h[hidden] { display: none; }
.tn-seats { display: flex; flex-direction: column; gap: 6px; flex: none; }
.tn-p { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 14px; background: var(--tn-row); border: 1px solid var(--tn-line); }
.tn-pv { flex: none; width: 34px; height: 34px; border-radius: 50%; overflow: hidden; position: relative; }
.tn-pv > * { width: 100% !important; height: 100% !important; border-radius: 50%; }
.tn-pv > img, .tn-pv > svg { display: block; object-fit: cover; } .tn-pv > .ini { font-size: 15px; }
.tn-pn { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.35; }
.tn-pn b { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 13.5px; } .tn-pn small { color: var(--tn-mut); font-size: 11px; }
.tn-pn small:empty { display: none; }
.tn-ps { flex: none; display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
.tn-ps em { font-style: normal; }
.tn-p[data-q="0"] .tn-ps em, .tn-p[data-q="1"] .tn-ps em { color: #FF5A5F; } .tn-p[data-q="2"] .tn-ps em { color: #F5B93A; } .tn-p[data-q="r"] .tn-ps em, .tn-p[data-q="n"] .tn-ps em { color: var(--tn-mut); font-weight: 600; }
.tn-test { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; flex: none; }
.tn-go { height: 48px; border: 0; border-radius: 14px; background: linear-gradient(180deg, #FFE3A0, #E8B84A); color: #2A1608; font: 800 15px "Readex Pro", sans-serif; cursor: pointer; box-shadow: 0 6px 16px rgba(232, 184, 74, .25); }
.tn-go:disabled { opacity: .7; cursor: default; }
.tn-out { padding: 12px 14px; border-radius: 14px; background: var(--tn-row); border: 1px solid var(--tn-line); border-inline-start: 4px solid #C9B59A; font-size: 13px; line-height: 1.6; animation: tnFade .2s; }
.tn-out[hidden] { display: none; }
.tn-out[data-q="4"] { border-inline-start-color: #2BD46A; } .tn-out[data-q="3"] { border-inline-start-color: #9BE15D; } .tn-out[data-q="2"] { border-inline-start-color: #F5B93A; } .tn-out[data-q="1"], .tn-out[data-q="0"] { border-inline-start-color: #FF5A5F; }
.tn-out b { display: block; font-size: 14.5px; } .tn-out small { display: block; color: var(--tn-mut); font-variant-numeric: tabular-nums; }
.tn-out ul { margin: 6px 0 0; padding-inline-start: 18px; }
.tn-sets { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; flex: none; }
.tn-row { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: 13px; border: 1px solid var(--tn-line); background: var(--tn-row); color: var(--tn-ink); text-align: start; font-family: inherit; cursor: pointer; }
.tn-row span { display: flex; flex-direction: column; gap: 2px; } .tn-row b { font-size: 14px; } .tn-row small { font-size: 12px; color: var(--tn-mut); }
.tn-sw { flex: none; position: relative; width: 42px; height: 24px; border-radius: 12px; background: rgba(255, 236, 200, .16); transition: background .15s; }
.tn-sw::after { content: ""; position: absolute; top: 2px; right: 2px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .3); transition: transform .15s; }
.tn-row[aria-checked="true"] .tn-sw { background: linear-gradient(180deg, #F2CE7C, #D9A847); }
.tn-row[aria-checked="true"] .tn-sw::after { transform: translateX(-18px); }
.tn-note { margin: 12px 2px 0; color: var(--tn-mut); font-size: 12px; line-height: 1.6; flex: none; }
/* the table's line lost */
.tn-banner { position: fixed; top: calc(env(safe-area-inset-top, 0px) + 62px); left: 50%; transform: translateX(-50%); z-index: 70; width: max-content; max-width: calc(100% - 32px); display: flex; align-items: center; gap: 10px; padding: 9px 12px;
  border-radius: 14px; color: #fff; background: rgba(60, 14, 12, .96); border: 1px solid rgba(255, 90, 90, .7); box-shadow: 0 10px 24px rgba(0, 0, 0, .45); direction: rtl; animation: tnFade .2s; }
.tn-banner[hidden] { display: none !important; }
.tn-spin { flex: none; width: 16px; height: 16px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .25); border-top-color: #fff; animation: tnSpin .8s linear infinite; }
@keyframes tnSpin { to { transform: rotate(360deg); } }
.tn-bt { min-width: 0; display: flex; flex-direction: column; line-height: 1.35; } .tn-bt b { font-size: 13px; } .tn-bt small { font-size: 11.5px; opacity: .85; font-variant-numeric: tabular-nums; }
.tn-re { flex: none; height: 30px; padding: 0 12px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, .3); background: rgba(255, 255, 255, .12); color: #fff; font: 700 12px "Readex Pro", sans-serif; cursor: pointer; }
@media (prefers-reduced-motion: reduce) { .tn-nb u, .tn-q, .tn-spin, .tn-card, .tn-sheet { animation: none !important; } }
