/* ==== guest lobby / public ladder ==== */
.guest-lobby-content{max-width:1040px;}
.guest-lobby-shell{width:100%;min-width:0;}
.guest-lobby-topbar{
  display:flex;align-items:center;justify-content:space-between;gap:12px;
  width:100%;margin:4px 0 12px;
}
.guest-mode-label{font-size:11px;color:var(--metal-dim);letter-spacing:1px;}
.guest-tabs{
  width:100%;display:flex;gap:4px;padding:4px;
  background:rgba(20,21,23,.86);border:1px solid var(--border);border-radius:10px;
  margin-bottom:14px;
}
.guest-tab{
  flex:1;border:none;background:transparent;color:var(--metal);
  padding:10px 14px;border-radius:7px;font-family:var(--font-d);font-weight:700;font-size:14px;
  transition:.2s ease;
}
.guest-tab.active{background:rgba(217,185,92,.12);color:var(--gold);box-shadow:inset 0 0 0 1px var(--gold-dim);}
.guest-tab-content{width:100%;min-width:0;}
.guest-ladder-head{
  display:flex;justify-content:space-between;align-items:flex-end;gap:12px;
  padding:18px 20px;margin-bottom:12px;
  border:1px solid var(--gold-dim);border-radius:12px;
  background:linear-gradient(135deg,rgba(217,185,92,.12),rgba(10,10,10,.72));
}
.guest-ladder-kicker{font-family:var(--font-d);font-size:11px;letter-spacing:3px;color:var(--gold-dim);}
.guest-ladder-title{font-family:var(--font-d);font-size:27px;font-weight:800;color:var(--ivory);letter-spacing:1px;}
.guest-ladder-sub{font-size:12px;color:var(--metal);margin-top:3px;}
.guest-ladder-search-wrap{position:relative;width:100%;margin-bottom:12px;}
.guest-ladder-search-wrap input{
  width:100%;height:44px;padding:0 44px;
  background:var(--panel);border:1px solid var(--border);border-radius:10px;color:var(--white);
  outline:none;font-size:14px;
}
.guest-ladder-search-wrap input:focus{border-color:var(--gold-dim);box-shadow:0 0 0 3px rgba(217,185,92,.08);}
.guest-search-icon{position:absolute;left:15px;top:50%;transform:translateY(-50%);color:var(--gold);font-size:20px;pointer-events:none;}
.guest-search-clear{
  position:absolute;right:10px;top:50%;transform:translateY(-50%);
  width:28px;height:28px;border:none;border-radius:50%;background:var(--panel-3);color:var(--metal);font-size:18px;
}
.guest-ladder-board{overflow:hidden;border:1px solid var(--border);border-radius:12px;background:rgba(15,16,18,.88);}
.guest-ladder-columns,.guest-ladder-row{
  display:grid;grid-template-columns:76px minmax(160px,1.7fr) 110px 110px 110px 72px 72px;
  align-items:center;column-gap:8px;
}
.guest-ladder-columns{
  padding:9px 14px;background:#111214;color:var(--gold);font-size:11px;font-weight:700;border-bottom:1px solid var(--gold-dim);
}
.guest-ladder-row{
  min-height:50px;padding:8px 14px;border-bottom:1px solid var(--border-soft);
  transition:background .15s ease;
}
.guest-ladder-row:last-child{border-bottom:none;}
.guest-ladder-row.guest-ladder-collapsed{display:none;}
.guest-ladder-row:hover{background:rgba(217,185,92,.045);}
.guest-ladder-row:nth-child(-n+3){background:linear-gradient(90deg,rgba(217,185,92,.055),transparent 48%);}
.guest-rank{font-family:var(--font-d);font-weight:800;color:var(--gold);font-size:15px;}
.guest-player-name{font-weight:700;color:var(--white);font-size:14px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.guest-player-mobile-meta{display:none;}
.guest-tier .ladder-tier-display{gap:2px;}
.guest-tier .ladder-tier-emblem{width:54px;height:54px;flex-basis:54px;}
.guest-ladder-row{min-height:82px;}
.guest-player-mobile-badge{display:none;}
.profile-tier-badge .ladder-tier-display{gap:3px;}
.profile-tier-badge .ladder-tier-emblem{width:66px;height:66px;flex-basis:66px;}
.guest-pts strong{font-family:var(--font-d);color:var(--neon);font-size:17px;margin-right:3px;}
.guest-pts span,.guest-career,.guest-events,.guest-champs{font-size:12px;color:var(--metal);}
.guest-ladder-more{padding:12px;text-align:center;border-top:1px solid var(--border);}
.guest-ladder-note{font-size:11px;color:var(--metal-dim);text-align:center;margin-top:10px;line-height:1.5;}

@media (max-width:720px){
  .guest-lobby-content{max-width:100%;}
  .guest-lobby-topbar{align-items:center;}
  .guest-mode-label{font-size:9.5px;}
  .guest-ladder-head{padding:14px 15px;align-items:center;}
  .guest-ladder-title{font-size:22px;}
  .guest-ladder-columns{
    grid-template-columns:58px minmax(0,1fr) 78px;
  }
  .guest-ladder-columns > div:nth-child(3),
  .guest-ladder-columns > div:nth-child(5),
  .guest-ladder-columns > div:nth-child(6),
  .guest-ladder-columns > div:nth-child(7){display:none;}
  .guest-ladder-row{
    grid-template-columns:58px minmax(0,1fr) 78px;
    padding:9px 10px;column-gap:5px;
  }
  .guest-tier,.guest-career,.guest-events,.guest-champs{display:none;}
  .guest-player-mobile-meta{display:block;font-size:10px;color:var(--metal-dim);margin-top:2px;}
  .guest-player-mobile-badge{display:block;float:left;margin-right:8px;}
  .guest-player-mobile-badge .ladder-tier-emblem{width:48px;height:48px;flex-basis:48px;}
  .guest-player-mobile-badge .ladder-tier-name{display:none;}
  .guest-ladder-row{min-height:70px;}
  .guest-pts{text-align:right;}
  .guest-player-name{font-size:13px;}
  .guest-rank{font-size:13px;}
}

/* ==== v13.20.0 settings workflow integration ==== */
.settings-toolbar{
  display:flex;align-items:flex-end;justify-content:space-between;gap:14px;
  margin:0 0 18px;padding:0 2px;
}

.ai-create-assist-btn{
  border-color:rgba(217,185,92,.52)!important;
  background:linear-gradient(135deg,rgba(217,185,92,.12),rgba(255,255,255,.025))!important;
  color:var(--ivory)!important;
}
.ai-create-assist-btn:hover{border-color:var(--gold)!important;box-shadow:0 0 18px rgba(217,185,92,.10);}
.ai-create-overlay{
  position:fixed;inset:0;z-index:4200;
  display:flex;align-items:center;justify-content:center;
  padding:20px;background:rgba(0,0,0,.72);
  backdrop-filter:blur(7px);-webkit-backdrop-filter:blur(7px);
}
.ai-create-dialog{
  width:min(760px,100%);max-height:min(88vh,860px);overflow:auto;
  border:1px solid rgba(217,185,92,.42);border-radius:16px;
  background:linear-gradient(180deg,rgba(25,25,27,.99),rgba(12,12,14,.99));
  box-shadow:0 24px 80px rgba(0,0,0,.62),0 0 32px rgba(217,185,92,.06);
}
.ai-create-head{
  display:flex;align-items:flex-start;justify-content:space-between;gap:14px;
  padding:18px 18px 14px;border-bottom:1px solid rgba(255,255,255,.08);
}
.ai-create-kicker{font:800 11px var(--font-d);letter-spacing:1.4px;color:var(--gold);text-transform:uppercase;}
.ai-create-title{margin-top:3px;font:800 22px var(--font-d);color:var(--white);}
.ai-create-sub{margin-top:5px;font-size:12px;line-height:1.6;color:var(--metal-dim);}
.ai-create-close{
  flex:0 0 auto;width:38px;height:38px;border:1px solid rgba(255,255,255,.12);
  border-radius:10px;background:rgba(255,255,255,.03);color:var(--metal);
  font-size:18px;cursor:pointer;
}
.ai-create-body{padding:18px;}
.ai-create-source{
  width:100%;min-height:250px;resize:vertical;
  padding:14px;border:1px solid var(--border);border-radius:12px;
  background:rgba(0,0,0,.28);color:var(--white);
  font:500 14px/1.7 "Noto Sans TC",sans-serif;outline:none;
}
.ai-create-source:focus{border-color:var(--gold-dim);box-shadow:0 0 0 2px rgba(217,185,92,.07);}
.ai-create-meta{display:flex;justify-content:space-between;gap:12px;margin-top:7px;color:var(--metal-dim);font-size:10.5px;}
.ai-create-fields{display:flex;flex-wrap:wrap;gap:7px;margin-top:14px;}
.ai-create-chip{
  padding:5px 9px;border:1px solid rgba(255,255,255,.1);border-radius:999px;
  background:rgba(255,255,255,.025);color:var(--metal);font-size:10.5px;
}
.ai-create-safety{
  margin-top:16px;padding:11px 12px;border:1px solid rgba(217,185,92,.18);
  border-radius:10px;background:rgba(217,185,92,.045);color:var(--metal);
  font-size:11px;line-height:1.65;
}
.ai-create-notice{
  margin-top:12px;padding:10px 12px;border:1px solid rgba(102,180,255,.28);
  border-radius:10px;background:rgba(102,180,255,.055);color:#cfe6ff;
  font-size:11px;line-height:1.6;
}
.ai-create-result{
  margin-top:16px;border:1px solid rgba(255,255,255,.10);border-radius:12px;
  overflow:hidden;background:rgba(255,255,255,.018);
}
.ai-create-result-head{
  display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:12px 13px;border-bottom:1px solid rgba(255,255,255,.08);
}
.ai-create-result-head strong{color:var(--ivory);font-size:13px;}
.ai-create-schema-badge{
  flex:0 0 auto;padding:4px 8px;border:1px solid rgba(85,184,255,.34);
  border-radius:999px;background:rgba(85,184,255,.07);color:#9ed8ff;
  font:800 9.5px var(--font-d);letter-spacing:.45px;
}
.ai-create-result-body{padding:13px;}
.ai-create-shared-grid{
  display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;
}
.ai-create-data-box{
  min-width:0;padding:9px 10px;border:1px solid rgba(255,255,255,.075);
  border-radius:9px;background:rgba(0,0,0,.16);
}
.ai-create-data-box span{display:block;color:var(--metal-dim);font-size:9.5px;margin-bottom:3px;}
.ai-create-data-box strong{
  display:block;color:var(--white);font-size:12px;line-height:1.45;
  overflow-wrap:anywhere;
}
.ai-create-event-list{display:grid;gap:9px;margin-top:12px;}
.ai-create-event-card{
  padding:11px;border:1px solid rgba(217,185,92,.18);border-radius:10px;
  background:rgba(217,185,92,.025);
}
button.ai-create-event-card{
  width:100%;text-align:left;color:inherit;cursor:pointer;font:inherit;
  transition:border-color .16s ease,background .16s ease,box-shadow .16s ease,transform .16s ease;
}
button.ai-create-event-card:hover{
  border-color:rgba(217,185,92,.46);background:rgba(217,185,92,.055);transform:translateY(-1px);
}
button.ai-create-event-card.is-selected{
  border-color:var(--gold);background:rgba(217,185,92,.085);
  box-shadow:0 0 0 1px rgba(217,185,92,.12),0 0 20px rgba(217,185,92,.07);
}
.ai-create-selected-mark{
  display:inline-flex;align-items:center;gap:5px;margin-left:auto;
  color:var(--gold);font-size:9.5px;font-weight:800;
}
.ai-create-event-title{
  display:flex;align-items:center;justify-content:space-between;gap:10px;
  margin-bottom:8px;color:var(--ivory);font:800 13px var(--font-d);
}
.ai-create-event-tag{
  padding:3px 7px;border-radius:999px;border:1px solid rgba(255,255,255,.10);
  color:var(--metal-dim);font-size:9px;font-weight:700;
}
.ai-create-event-meta{
  display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;
}
.ai-create-event-meta div{
  padding:7px 8px;border-radius:8px;background:rgba(0,0,0,.14);
  color:var(--metal);font-size:10.5px;line-height:1.45;
}
.ai-create-warning-list{display:grid;gap:7px;margin-top:12px;}
.ai-create-warning{
  padding:9px 10px;border-radius:9px;font-size:10.5px;line-height:1.55;
  border:1px solid rgba(255,255,255,.08);background:rgba(255,255,255,.02);
}
.ai-create-warning.warning{border-color:rgba(255,193,85,.34);color:#ffd58a;background:rgba(255,193,85,.055);}
.ai-create-warning.info{border-color:rgba(102,180,255,.24);color:#cfe6ff;background:rgba(102,180,255,.045);}
.ai-create-schema-errors{
  margin-top:12px;padding:10px 12px;border:1px solid rgba(255,105,105,.35);
  border-radius:10px;background:rgba(255,80,80,.05);color:#ffb3b3;
  font-size:10.5px;line-height:1.6;
}
.ai-create-draft-lock{
  margin-top:12px;padding:9px 10px;border:1px dashed rgba(255,255,255,.13);
  border-radius:9px;color:var(--metal-dim);font-size:10.5px;line-height:1.55;
}
.ai-create-map-preview{
  margin-top:12px;padding:11px;border:1px solid rgba(95,215,147,.22);
  border-radius:10px;background:rgba(95,215,147,.035);
}
.ai-create-map-preview>strong{display:block;color:#b9f0cd;font-size:11.5px;margin-bottom:8px;}
.ai-create-map-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;}
.ai-create-map-grid div{
  min-width:0;padding:7px 8px;border-radius:8px;background:rgba(0,0,0,.14);
  color:var(--metal);font-size:10px;line-height:1.45;overflow-wrap:anywhere;
}
.ai-create-map-grid b{color:var(--white);font-weight:750;}
.ai-create-unmapped{margin-top:8px;color:#ffd58a;font-size:10px;line-height:1.55;}
.ai-create-applied-banner{
  margin:0 0 16px;padding:12px 14px;border:1px solid rgba(95,215,147,.30);
  border-radius:11px;background:rgba(95,215,147,.05);color:#d8f7e4;
  font-size:11px;line-height:1.65;
}
.ai-create-applied-banner strong{display:block;color:#b9f0cd;font-size:12.5px;margin-bottom:3px;}
.ai-create-applied-warnings{margin-top:7px;color:#ffd58a;}
.ai-create-review-panel{
  margin:0 0 18px;padding:14px;border:1px solid rgba(255,255,255,.10);
  border-radius:12px;background:rgba(255,255,255,.018);
}
.ai-create-review-head{
  display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:10px;
}
.ai-create-review-head strong{display:block;color:var(--ivory);font-size:13px;}
.ai-create-review-head span{display:block;color:var(--metal-dim);font-size:10px;margin-top:3px;line-height:1.5;}
.ai-create-review-status{
  flex:0 0 auto;padding:5px 9px;border-radius:999px;font:800 9.5px var(--font-d);letter-spacing:.35px;
  border:1px solid rgba(255,255,255,.12);color:var(--metal);
}
.ai-create-review-status.blocked{border-color:rgba(255,105,105,.40);background:rgba(255,80,80,.07);color:#ffb3b3;}
.ai-create-review-status.pending{border-color:rgba(255,193,85,.40);background:rgba(255,193,85,.065);color:#ffd58a;}
.ai-create-review-status.ready{border-color:rgba(95,215,147,.36);background:rgba(95,215,147,.06);color:#b9f0cd;}
.ai-create-review-list{display:grid;gap:7px;}
.ai-create-review-item{
  display:grid;grid-template-columns:22px minmax(0,1fr);gap:8px;
  padding:9px 10px;border-radius:9px;border:1px solid rgba(255,255,255,.075);background:rgba(0,0,0,.14);
}
.ai-create-review-item .icon{font-size:13px;line-height:1.4;}
.ai-create-review-item b{display:block;color:var(--white);font-size:10.5px;margin-bottom:2px;}
.ai-create-review-item p{margin:0;color:var(--metal);font-size:10px;line-height:1.55;}
.ai-create-review-item.blocker{border-color:rgba(255,105,105,.28);background:rgba(255,80,80,.035);}
.ai-create-review-item.warning{border-color:rgba(255,193,85,.25);background:rgba(255,193,85,.035);}
.ai-create-review-item.info{opacity:.86;}
.ai-create-review-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;margin-top:11px;flex-wrap:wrap;}
.ai-create-review-confirmed{color:#b9f0cd;font-size:10.5px;font-weight:800;}
.ai-create-suggestion-panel{
  margin:0 0 14px;padding:14px;border:1px solid rgba(102,180,255,.26);
  border-radius:12px;background:rgba(102,180,255,.035);
}
.ai-create-suggestion-head{
  display:flex;align-items:flex-start;justify-content:space-between;gap:10px;margin-bottom:10px;
}
.ai-create-suggestion-head strong{display:block;color:#d9edff;font-size:13px;}
.ai-create-suggestion-head span{display:block;color:var(--metal-dim);font-size:10px;line-height:1.55;margin-top:3px;}
.ai-create-suggestion-count{
  flex:0 0 auto;padding:4px 8px;border:1px solid rgba(102,180,255,.28);
  border-radius:999px;color:#a9d9ff;font:800 9.5px var(--font-d);
}
.ai-create-suggestion-list{display:grid;gap:8px;}
.ai-create-suggestion-card{
  display:grid;grid-template-columns:24px minmax(0,1fr);gap:8px;align-items:flex-start;
  padding:10px;border:1px solid rgba(255,255,255,.085);border-radius:9px;background:rgba(0,0,0,.15);
}
.ai-create-suggestion-card input{margin-top:2px;width:16px;height:16px;}
.ai-create-suggestion-title{display:flex;align-items:center;gap:7px;flex-wrap:wrap;color:var(--white);font-size:11px;font-weight:800;}
.ai-create-suggestion-badge{
  padding:2px 6px;border-radius:999px;font:800 8.5px var(--font-d);letter-spacing:.25px;
  border:1px solid rgba(255,255,255,.12);color:var(--metal);
}
.ai-create-suggestion-badge.source{border-color:rgba(95,215,147,.30);color:#b9f0cd;background:rgba(95,215,147,.05);}
.ai-create-suggestion-badge.recommended{border-color:rgba(255,193,85,.34);color:#ffd58a;background:rgba(255,193,85,.055);}
.ai-create-suggestion-card p{margin:4px 0 0;color:var(--metal);font-size:10px;line-height:1.55;}
.ai-create-suggestion-value{margin-top:5px;color:#d9edff;font-size:10.5px;font-weight:750;}
.ai-create-suggestion-actions{display:flex;justify-content:flex-end;gap:8px;flex-wrap:wrap;margin-top:10px;}
.venue-settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;}
.venue-settings-grid .venue-map-field{grid-column:1/-1;}
.venue-nav-toggle{margin-top:2px;}
.venue-detail-value{display:flex;flex-direction:column;gap:3px;min-width:0;}
.venue-detail-name{font-weight:800;color:var(--white);overflow-wrap:anywhere;}
.venue-detail-address-row{display:flex;align-items:center;gap:7px;flex-wrap:wrap;}
.venue-detail-address{color:var(--metal);font-size:10px;line-height:1.45;overflow-wrap:anywhere;}
.venue-nav-menu{position:relative;display:inline-block;}
.venue-nav-menu>summary{
  list-style:none;display:inline-flex;align-items:center;gap:4px;cursor:pointer;
  min-height:26px;padding:3px 8px;border:1px solid rgba(95,215,147,.30);border-radius:999px;
  color:#b9f0cd;background:rgba(95,215,147,.055);font-size:9.5px;font-weight:800;white-space:nowrap;
}
.venue-nav-menu>summary::-webkit-details-marker{display:none;}
.venue-nav-menu[open]>summary{border-color:rgba(95,215,147,.55);background:rgba(95,215,147,.10);}
.venue-nav-options{
  position:absolute;z-index:80;right:0;top:calc(100% + 5px);min-width:148px;
  padding:6px;border:1px solid rgba(255,255,255,.12);border-radius:10px;
  background:#17181b;box-shadow:0 12px 30px rgba(0,0,0,.42);
}
.venue-nav-options a{
  display:block;padding:8px 9px;border-radius:7px;color:var(--white);font-size:10.5px;
  text-decoration:none;white-space:nowrap;
}
.venue-nav-options a:hover{background:rgba(255,255,255,.06);}
@media(max-width:600px){.venue-settings-grid{grid-template-columns:1fr}.venue-settings-grid .venue-map-field{grid-column:auto}.venue-nav-options{left:0;right:auto;}}
.ai-create-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:18px;}
.ai-create-apply-btn{border-color:rgba(95,215,147,.44)!important;}
.ai-create-apply-btn:not(:disabled){background:rgba(95,215,147,.10)!important;color:#d8f7e4!important;}
@media(max-width:720px){
  .settings-toolbar .btn-row{display:grid;grid-template-columns:1fr 1fr;grid-auto-flow:row dense;width:100%;}
  .settings-toolbar .btn-row .ai-create-assist-btn{grid-column:1/-1;grid-row:2;}
  .ai-create-overlay{align-items:flex-end;padding:10px;}
  .ai-create-dialog{width:100%;max-height:92vh;border-radius:16px 16px 12px 12px;}
  .ai-create-head{padding:16px 14px 12px;}
  .ai-create-body{padding:14px;}
  .ai-create-source{min-height:230px;font-size:16px;}
  .ai-create-meta{flex-direction:column;gap:3px;}
  .ai-create-actions{display:grid;grid-template-columns:1fr 1fr;}
  .ai-create-actions .btn{width:100%;}
  .ai-create-actions .ai-create-apply-btn{grid-column:1/-1;grid-row:1;}
  .ai-create-shared-grid,.ai-create-event-meta,.ai-create-map-grid{grid-template-columns:1fr;}
}
.settings-page-title{font-family:var(--font-d);font-size:24px;font-weight:800;color:var(--white);}
.settings-page-sub{font-size:12px;color:var(--metal-dim);margin-top:4px;line-height:1.5;}
.settings-flow-panel{padding:18px;}
.settings-basic-stack{display:grid;grid-template-columns:1fr;gap:12px;margin-top:16px;max-width:760px;}
.settings-mini-title{
  font-family:var(--font-d);font-weight:800;font-size:14px;color:var(--ivory);
  margin-bottom:10px;padding-bottom:8px;border-bottom:1px solid var(--border-soft);
}
.settings-time-flow{max-width:480px;margin:0 auto;}
.settings-time-row{
  display:grid;grid-template-columns:34px minmax(0,1fr);gap:12px;align-items:center;
  padding:13px 14px;border:1px solid var(--border);border-radius:10px;background:rgba(255,255,255,.018);
}
.settings-time-index{
  width:30px;height:30px;border-radius:50%;display:flex;align-items:center;justify-content:center;
  font-family:var(--font-d);font-size:11px;font-weight:800;color:var(--gold);
  border:1px solid var(--gold-dim);background:rgba(217,185,92,.06);
}
.settings-time-row .field{margin:0;}
.settings-time-connector{height:32px;display:flex;align-items:center;justify-content:flex-start;padding-left:28px;position:relative;}
.settings-time-connector span{position:absolute;left:28px;top:0;bottom:0;width:1px;background:var(--gold-dim);}
.settings-time-connector b{
  position:relative;left:-6px;top:1px;background:var(--panel);color:var(--gold-dim);
  padding:2px 4px;font-size:13px;font-weight:700;
}
.settings-match-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:18px;}
.settings-check-row{
  display:flex;align-items:flex-start;gap:10px;margin-top:10px;
  color:var(--metal);font-size:12px;line-height:1.5;
}
.settings-check-row input{width:19px;height:19px;flex:0 0 auto;margin-top:1px;}
.settings-scoring-choice{margin-top:0;}
.settings-lead-field{margin-top:14px;max-width:320px;}
.settings-save-bar{
  position:sticky;bottom:10px;z-index:18;
  display:flex;align-items:center;justify-content:space-between;gap:14px;
  margin:22px 0;padding:14px 16px;border:1px solid var(--gold-dim);border-radius:12px;
  background:rgba(15,16,14,.94);backdrop-filter:blur(10px);box-shadow:0 8px 28px rgba(0,0,0,.34);
}
.settings-save-bar strong{display:block;color:var(--ivory);font-size:13px;}
.settings-save-bar span{display:block;color:var(--metal-dim);font-size:11px;margin-top:2px;}
@media(max-width:720px){
  .settings-toolbar{align-items:flex-start;flex-direction:column;}
  .settings-toolbar .btn-row{width:100%;}
  .settings-toolbar .btn-row .btn{flex:1;}
  .settings-match-grid{grid-template-columns:1fr;}
  .settings-time-flow{max-width:100%;}
  .settings-time-row{grid-template-columns:30px minmax(0,1fr);padding:12px 10px;}
  .settings-save-bar{bottom:6px;flex-direction:column;align-items:stretch;}
  .settings-save-bar .btn{width:100%;}
}

/* ==== v13.20.3 integrated activity basic data ==== */
.settings-inner-divider{height:1px;background:var(--border-soft);margin:22px 0 16px;}
.settings-time-flow-left{margin-left:0;margin-right:0;}
.settings-integrated-registration > .panel{margin:0;padding:0;border:none;background:transparent;box-shadow:none;}
.settings-integrated-registration > .panel > .panel-title{display:none;}
.settings-integrated-registration .banner.warn{margin-top:0;}

/* ==== v13.20.5 QR / referee / activity-time refinements ==== */
.registration-publish-actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap;margin-top:14px;}
.publish-preview-card{display:grid;gap:0;border:1px solid var(--line);border-radius:16px;overflow:hidden;background:rgba(255,255,255,.02);}
.publish-preview-row{display:grid;grid-template-columns:minmax(92px,32%) minmax(0,1fr);gap:14px;padding:13px 15px;border-bottom:1px solid rgba(255,255,255,.07);align-items:start;}
.publish-preview-row:last-child{border-bottom:0;}
.publish-preview-label{font-size:13px;color:var(--muted);font-weight:700;letter-spacing:.02em;}
.publish-preview-value{font-size:15px;color:var(--text);font-weight:650;line-height:1.55;min-width:0;overflow-wrap:anywhere;}
@media(max-width:520px){.publish-preview-row{grid-template-columns:1fr;gap:5px;padding:12px 14px}.publish-preview-label{font-size:12px}.publish-preview-value{font-size:15px}}
.registration-publish-actions .btn{min-width:150px;}
.settings-time-checkin-rules{max-width:480px;margin:16px 0 0;padding-top:16px;border-top:1px dashed var(--border-soft);}
.settings-match-grid-single{grid-template-columns:minmax(0,760px);}
.referee-scoring-settings{margin-bottom:14px;}
@media(max-width:640px){
  .registration-publish-actions{flex-direction:column;align-items:stretch;}
  .registration-publish-actions .btn{width:100%;}
}

/* ==== v13.20.7 automatic registration share ==== */
.registration-share-inline{margin-top:18px;padding-top:18px;border-top:1px solid var(--border-soft);}
.registration-url-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;align-items:center;}
.registration-url-row input{min-width:0;}
.registration-inline-qr-copy{display:flex;flex-direction:column;align-items:center;gap:8px;margin:14px auto 0;padding:12px;border:1px solid var(--border);border-radius:12px;background:rgba(255,255,255,.02);color:var(--metal);cursor:pointer;transition:.18s ease;}
.registration-inline-qr-copy:hover{border-color:var(--gold-dim);transform:translateY(-1px);}
.registration-inline-qr-copy span{font-size:11px;color:var(--metal-dim);}
.registration-inline-qr-box{width:216px;min-height:216px;padding:10px;background:#fff;border-radius:10px;display:flex;align-items:center;justify-content:center;}
.registration-inline-qr-box img,.registration-inline-qr-box canvas{display:block;max-width:196px!important;max-height:196px!important;}
@media(max-width:640px){.registration-url-row{grid-template-columns:1fr}.registration-url-row .btn{width:100%}}

/* ==== v13.23.7 mobile community loading hardening ==== */
.community-host-loading{min-height:180px;display:flex;flex-direction:column;justify-content:center;}
.community-host-loading .empty-state{padding:24px 12px;}
.community-host-loading .empty-state .big{font-family:var(--font-d);font-weight:800;color:var(--ivory);font-size:17px;margin-bottom:7px;}

/* ==== v13.21.0 player community tournaments ==== */
.community-host-hero{border-color:rgba(120,170,255,.28)}
.community-policy-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-top:14px}
.community-event-card,.community-history-card{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:13px 0;border-bottom:1px solid var(--border-soft)}
.community-event-card:last-child,.community-history-card:last-child{border-bottom:none}.community-event-name{font-family:var(--font-d);font-weight:800;color:var(--ivory)}
.community-room-notice{padding:8px 16px;background:rgba(89,140,255,.08);border-bottom:1px solid rgba(89,140,255,.18);font-size:12px;color:var(--metal)}
.community-create-card{max-width:620px}.community-create-card .banner{margin-bottom:14px}
.auth-shell.community-create-shell{
  top:0;right:0;bottom:0;left:0;
  height:100vh;height:100dvh;max-height:100dvh;
  box-sizing:border-box;overflow:hidden;
}
.community-create-shell .auth-scroll{
  align-items:stretch;
  overflow-x:hidden;overflow-y:auto;
  -webkit-overflow-scrolling:touch;touch-action:pan-y;overscroll-behavior-y:auto;
}
.community-create-shell .auth-content.community-create-content{
  display:block;flex:0 0 auto;width:100%;max-width:640px;min-height:max-content;
  margin:0 auto;padding-bottom:max(24px,env(safe-area-inset-bottom));
}
.community-create-shell .community-create-card{width:100%;margin-left:auto;margin-right:auto;box-sizing:border-box}
.community-create-topbar{position:sticky;top:0;z-index:20;width:100%;max-width:620px;margin:0 auto 8px;padding:4px 0 8px;background:linear-gradient(180deg,#0d0e0a 68%,rgba(13,14,10,0));}
.community-create-topbar .btn{min-height:42px}
@media(max-width:720px){.community-policy-grid{grid-template-columns:1fr}.community-event-card,.community-history-card{align-items:flex-start;flex-direction:column}.community-event-card .btn-row{width:100%}.community-event-card .btn-row .btn{flex:1}}

/* ==== v13.22.0 lobby / lifecycle / referee workstation ==== */
.room-status{display:inline-flex;align-items:center;gap:7px;font-size:12px;font-weight:800;white-space:nowrap}.room-status-dot{width:9px;height:9px;border-radius:50%;display:inline-block;box-shadow:0 0 9px currentColor}.room-status-dot.green{background:#42e69b;color:#42e69b}.room-status-dot.yellow{background:#f5d85f;color:#f5d85f}.room-status-dot.orange{background:#ff9d45;color:#ff9d45}.room-status-dot.gray{background:#a7adb6;color:#a7adb6}.room-status-dot.red{background:#ff5568;color:#ff5568}.room-status-registration{color:#7cebb8}.room-status-live{color:#ffe078}.room-status-settling{color:#ffb268}.room-status-failed{color:#ff6c7c}.room-status-done{color:#c0c5cc}.room-status-prestart{color:#c9cdd4}.room-status-cancelled{color:#ff6c7c}
.lobby-page-head{display:flex;justify-content:space-between;align-items:flex-end;gap:12px;margin-bottom:14px;padding:14px 16px;border:1px solid rgba(217,185,92,.18);border-radius:14px;background:linear-gradient(135deg,rgba(217,185,92,.10),rgba(11,13,16,.88) 45%,rgba(11,13,16,.95));box-shadow:0 10px 24px rgba(0,0,0,.18)}.lobby-search-panel{margin-bottom:14px!important;padding:12px 14px}.lobby-search-row{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:8px;align-items:center}.lobby-search-input{position:relative;min-width:0}.lobby-search-input span{position:absolute;left:13px;top:50%;transform:translateY(-50%);font-size:19px;color:var(--gold);pointer-events:none}.lobby-search-input input{width:100%;height:42px;padding-left:40px;background:rgba(5,7,10,.72);border:1px solid var(--border);border-radius:9px;color:var(--white)}.lobby-filter-expanded .btn-row{margin-top:10px}.lobby-filter-summary{display:flex;align-items:center;justify-content:flex-end;gap:8px;font-size:11px;color:var(--metal-dim);margin:-4px 2px 10px}.lobby-filter-summary .link-btn{font-size:11px}.lobby-section .panel-title{margin-bottom:8px}.lobby-compact-card{border:1px solid rgba(255,255,255,.11);border-radius:12px;background:rgba(9,11,15,.72);margin:8px 0;overflow:hidden}.lobby-compact-card[open]{border-color:rgba(217,178,73,.35)}.lobby-compact-card summary{list-style:none;cursor:pointer;padding:12px 14px}.lobby-compact-card summary::-webkit-details-marker{display:none}.lobby-card-main{display:flex;justify-content:space-between;gap:14px;align-items:flex-start}.lobby-room-name{font-weight:900;font-size:15px;color:#f3f5f8;line-height:1.25}.lobby-host{font-size:11px;color:var(--metal-dim);margin-top:3px}.lobby-card-right{display:flex;align-items:center;gap:10px;flex-wrap:wrap;justify-content:flex-end}.lobby-authority{font-size:9px;font-weight:900;letter-spacing:.12em;padding:4px 7px;border-radius:999px;border:1px solid rgba(255,255,255,.14)}.lobby-authority.official{color:#f0cf71;border-color:rgba(240,207,113,.38)}.lobby-authority.community{color:#8db7ff;border-color:rgba(141,183,255,.35)}.lobby-time-row{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-top:8px}.lobby-time{font-size:12px;color:#d7dbe2}.lobby-expand-label{font-size:10px;color:var(--metal-dim)}.lobby-card-detail{padding:0 14px 14px;border-top:1px solid rgba(255,255,255,.07)}.lobby-detail-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px 14px;padding-top:12px;font-size:12px;color:#c7ccd4}.lobby-description{margin-top:10px;padding:9px 10px;background:rgba(255,255,255,.025);border-radius:8px;font-size:12px;color:#aeb4bd}.lobby-card-actions{display:flex;gap:8px;justify-content:flex-end;align-items:center;margin-top:12px}

/* Whole-card hover filters over backdrop blur stalled card expansion in WebKit CI.
   Keep the existing background, border, shadow and focus feedback. */
[data-lobby-root] .lobby-compact-card:hover{filter:none!important}

/* ==== v14.2.5 compact lobby toolbar ==== */
.lobby-page-head-compact{
  min-height:46px;
  align-items:center!important;
  margin-bottom:8px!important;
  padding:6px 4px!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
}
.lobby-page-head-compact .settings-page-title{margin:0!important}
.lobby-head-tools{display:flex;align-items:center;gap:6px;margin-left:auto}
.lobby-tool-btn{
  position:relative;
  width:32px!important;
  height:32px!important;
  min-height:32px!important;
  padding:0!important;
  border-radius:9px!important;
  font-size:17px!important;
  line-height:1!important;
  color:#c8cdd3!important;
}
.lobby-tool-btn:hover,.lobby-tool-btn:focus-visible{color:#f0cf71!important;border-color:rgba(240,207,113,.38)!important}
.lobby-tool-btn.is-active::after{
  content:"";
  position:absolute;
  top:4px;
  right:4px;
  width:6px;
  height:6px;
  border-radius:50%;
  background:#efff6a;
  box-shadow:0 0 7px rgba(239,255,106,.65);
}
.lobby-tool-btn.is-busy{animation:lobby-tool-spin .72s linear infinite}
@keyframes lobby-tool-spin{to{transform:rotate(360deg)}}
.lobby-search-panel-compact{
  margin:0 0 8px!important;
  padding:10px 11px!important;
  border-radius:12px!important;
}
.lobby-filter-title-row{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:8px}
.lobby-filter-title-row strong{font-size:13px;color:#f1f2ee}
.lobby-filter-active-chip{padding:3px 7px;border:1px solid rgba(239,255,106,.22);border-radius:999px;background:rgba(239,255,106,.055);color:#efff6a;font-size:9px;font-weight:800}
.lobby-search-panel-compact .field{margin-bottom:8px}
.lobby-filter-actions{margin-top:3px!important;justify-content:flex-end}
.lobby-filter-summary{margin:0 2px 7px!important}
@media(max-width:640px){
  .lobby-page-head-compact{min-height:42px;padding:4px 2px!important}
  .lobby-page-head-compact .settings-page-title{font-size:24px!important}
  .lobby-tool-btn{width:30px!important;height:30px!important;min-height:30px!important;font-size:16px!important}
  .lobby-search-panel-compact{padding:9px!important}
  .lobby-search-panel-compact .grid-2{grid-template-columns:1fr 1fr!important;gap:7px!important}
  .lobby-search-panel-compact .field label{font-size:10px!important}
  .lobby-search-panel-compact .field input,.lobby-search-panel-compact .field select{min-height:38px!important;padding:8px 9px!important;font-size:12px!important}
  .lobby-filter-actions .btn{min-height:36px!important;padding:7px 10px!important;font-size:11px!important}
}
@media(max-width:390px){.lobby-search-panel-compact .grid-2{grid-template-columns:1fr!important}}
@media(prefers-reduced-motion:reduce){.lobby-tool-btn.is-busy{animation:none!important}}

/* ==== 2026-09-22 lobby public roster polish ==== */
.lobby-roster-block{margin-top:14px;border:1px solid rgba(240,207,113,.18);border-radius:12px;background:linear-gradient(180deg,rgba(8,10,14,.34),rgba(8,10,14,.18));overflow:hidden}
.lobby-roster-head{display:flex;align-items:center;gap:10px;padding:11px 13px;cursor:pointer;list-style:none;user-select:none}
.lobby-roster-head::-webkit-details-marker{display:none}
.lobby-roster-head>span:first-child{font-size:13px;font-weight:900;letter-spacing:.02em;color:#f4f1e8}
.lobby-roster-count{margin-left:auto;display:inline-flex;align-items:center;justify-content:center;min-height:24px;padding:3px 9px;border:1px solid rgba(240,207,113,.25);border-radius:999px;background:rgba(240,207,113,.08);font-size:10px;font-weight:900;color:#f0cf71;white-space:nowrap}
.lobby-roster-head::after{content:"⌄";font-size:13px;line-height:1;color:#b9a35f;transition:transform .18s ease}
.lobby-roster-block[open] .lobby-roster-head::after{transform:rotate(180deg)}
.lobby-roster-block[open] .lobby-roster-head{border-bottom:1px solid rgba(255,255,255,.07)}
.lobby-roster-list{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;padding:12px 13px 10px}
.lobby-roster-player{min-width:0;display:grid;grid-template-columns:30px minmax(0,1fr) auto;align-items:center;gap:6px;min-height:36px;padding:4px 6px 4px 4px;border:1px solid rgba(255,255,255,.07);border-radius:9px;background:rgba(4,6,10,.42)}
.lobby-roster-index{display:inline-flex;align-items:center;justify-content:center;width:30px;height:28px;border:1px solid rgba(240,207,113,.30);border-radius:7px;background:linear-gradient(180deg,rgba(27,28,31,.96),rgba(10,11,14,.96));font-size:10px;font-weight:900;font-variant-numeric:tabular-nums;letter-spacing:.04em;color:#f0cf71}
.lobby-roster-name{min-width:0;border:0!important;background:transparent!important;box-shadow:none!important;padding:5px 2px!important;text-align:left;font:inherit;font-size:12px;font-weight:800;color:#f1f2f4;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;cursor:pointer}
.lobby-roster-name:hover,.lobby-roster-name:focus-visible{color:#f0cf71;text-decoration:none;outline:none}
.lobby-roster-player .badge{padding:2px 5px;font-size:8px;line-height:1.2;white-space:nowrap}
.lobby-roster-note{margin:0 13px 12px;padding:8px 10px;border-radius:8px;background:rgba(255,255,255,.025);font-size:10px;line-height:1.55;color:#9ea5af}
.lobby-roster-empty{margin:0 13px 12px;padding:12px;border:1px dashed rgba(255,255,255,.10);border-radius:9px;text-align:center;font-size:11px;color:#9ea5af}
@media(max-width:720px){
  .lobby-roster-list{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;padding:10px 10px 8px}
  .lobby-roster-player{grid-template-columns:28px minmax(0,1fr) auto;min-height:34px;padding-right:5px}
  .lobby-roster-index{width:28px;height:26px;font-size:9px}
  .lobby-roster-name{font-size:11px}
  .lobby-roster-note{margin:0 10px 10px;font-size:9.5px}
}
.referee-workstation{padding:0!important;overflow:hidden}.ref-workstation-head{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:14px 16px;border-bottom:1px solid rgba(255,255,255,.09);background:linear-gradient(90deg,var(--court-glow-soft),rgba(255,255,255,.01))}.ref-workstation-identity{display:flex;align-items:center;gap:10px}.ref-workstation-identity div{display:flex;flex-direction:column}.ref-workstation-identity b{font-size:14px}.ref-workstation-identity div > span{font-size:10px;color:var(--metal-dim)}.ref-workstation-meta{text-align:right;display:flex;flex-direction:column;font-size:12px;font-weight:800}.ref-workstation-meta small{font-size:10px;color:var(--metal-dim);font-weight:500;margin-top:2px}.ref-match-toolbar{margin:12px 16px 0!important}.ref-vs-arena{display:grid;grid-template-columns:minmax(0,1fr) 64px minmax(0,1fr);gap:12px;align-items:stretch;padding:16px}.ref-vs-mark{display:flex;align-items:center;justify-content:center;font-family:var(--font-d);font-size:18px;font-weight:900;color:#fff}.ref-player-side{min-height:190px;border-radius:18px;border:1px solid var(--court-accent);background:rgba(6,10,16,.74);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;color:#fff;cursor:pointer;transition:.18s}.ref-player-side:hover:not(:disabled){transform:translateY(-2px);box-shadow:0 0 24px var(--court-glow)}.ref-player-side:disabled{opacity:.58;cursor:not-allowed}.ref-player-side strong{font-size:26px;line-height:1.2;text-align:center}.ref-player-label{font-size:10px;letter-spacing:.13em;color:var(--metal-dim)}.ref-win-call{font-weight:900;border:1px solid var(--court-accent);border-radius:999px;padding:8px 18px;color:var(--court-accent)}.ref-vs-arena.standard .side-panel{border-radius:18px;min-height:220px;min-width:0;width:100%}.ref-vs-arena.standard .side-score{font-size:52px}.ref-vs-arena.standard .score-btns button{white-space:nowrap;min-width:0}.ref-next-box{margin:0 16px 16px;padding:10px 12px;border-radius:10px;background:rgba(255,255,255,.025);font-size:11px;color:var(--metal-dim)}.ref-next-box>span{font-weight:900;color:#e8ebef;margin-right:8px}.ref-previous-correction{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:10px 16px 0;padding:9px 10px;border:1px solid color-mix(in srgb,var(--court-accent,var(--gold)) 34%,transparent);border-radius:10px;background:linear-gradient(90deg,var(--court-glow-soft,rgba(255,255,255,.025)),rgba(255,255,255,.018))}.ref-previous-correction-main{display:flex;flex-direction:column;min-width:0;gap:2px}.ref-previous-correction-main b{font-size:11px;color:#f1f3f5;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ref-previous-correction-main span{font-size:9.5px;color:var(--metal-dim);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ref-previous-correction-actions{display:flex;gap:6px;flex:0 0 auto}.ref-previous-correction-actions .btn{min-height:30px;padding:4px 8px;font-size:10px;white-space:nowrap}@media(max-width:720px){.ref-previous-correction{align-items:stretch;flex-direction:column}.ref-previous-correction-actions{display:grid;grid-template-columns:1fr 1fr}.ref-previous-correction-actions .btn{width:100%}}.duty-list{display:flex;flex-direction:column;gap:8px}.duty-row{padding:12px 13px;border:1px solid rgba(255,255,255,.09);border-radius:10px;background:rgba(255,255,255,.02)}.duty-row-main{display:flex;justify-content:space-between;gap:12px}.duty-row-main span{color:#cdd2da}.duty-row-meta{display:flex;gap:12px;flex-wrap:wrap;margin-top:7px;font-size:11px;color:var(--metal-dim)}
@media(max-width:720px){.lobby-page-head{flex-direction:column;align-items:stretch;padding:14px}.lobby-search-row{grid-template-columns:minmax(0,1fr) auto}.lobby-search-row .btn:last-child{grid-column:1 / -1;width:100%}.lobby-filter-summary{justify-content:space-between}.lobby-page-head .btn{width:100%}.lobby-card-main{flex-direction:column;gap:10px}.lobby-card-right{justify-content:flex-start}.lobby-time-row{flex-direction:column;align-items:flex-start;gap:6px}.lobby-card-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch}.lobby-card-actions .btn{width:100%}.lobby-card-actions>.btn:only-child,.lobby-card-actions>.fe-status-chip,.lobby-card-actions>.lobby-registration-action-stack{grid-column:1 / -1}.lobby-detail-grid{grid-template-columns:1fr}.ref-vs-arena{grid-template-columns:1fr;gap:8px}.ref-vs-mark{min-height:30px}.ref-player-side{min-height:150px}.ref-player-side strong{font-size:22px}.ref-workstation-head{align-items:flex-start}.duty-row-main{flex-direction:column;gap:4px}}


/* ==== v13.28.1 mobile navigation / referee station clarity ==== */
.ref-station-status{display:inline-flex;align-items:center;justify-content:center;align-self:flex-end;border:1px solid rgba(255,255,255,.16);border-radius:999px;padding:4px 9px;font-size:10px;line-height:1;white-space:nowrap}
.ref-station-status.waiting{color:#b9bec6}.ref-station-status.ready{color:#f5d85f;border-color:rgba(245,216,95,.45)}.ref-station-status.live{color:#ff6b79;border-color:rgba(255,85,104,.52);box-shadow:0 0 12px rgba(255,85,104,.18)}.ref-station-status.paused{color:#ffb268;border-color:rgba(255,178,104,.42)}.ref-station-status.done{color:#7cebb8;border-color:rgba(124,235,184,.38)}
@media(max-width:720px){.ref-workstation-identity{min-width:0}.ref-workstation-identity div{min-width:0}.ref-workstation-identity b{max-width:190px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ref-workstation-meta{flex:0 0 auto}}

/* ==== v14.2.4 live dashboard summary ==== */
.live-dashboard-panel{padding:12px!important;overflow:hidden}
.live-summary-strip{padding:2px 2px 11px;border-bottom:1px solid rgba(255,255,255,.065)}
.live-summary-line{display:flex;align-items:center;gap:8px;min-width:0}
.live-summary-name{flex:1 1 auto;min-width:80px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--white);font-family:var(--font-d);font-size:18px;font-weight:900;line-height:1.2}
.live-summary-chip{flex:0 0 auto;padding:4px 7px;border:1px solid rgba(255,255,255,.09);border-radius:999px;background:rgba(255,255,255,.025);color:#d9dde2;font-size:9.5px;font-weight:800;white-space:nowrap}
.live-summary-refresh{flex:0 0 30px!important;width:30px!important;height:30px!important;min-height:30px!important;padding:0!important;border-radius:50%!important;font-size:16px!important;line-height:1!important}
.live-summary-refresh.is-busy{animation:live-refresh-spin .72s linear infinite}
@keyframes live-refresh-spin{to{transform:rotate(360deg)}}
.live-energy-row{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:9px;margin-top:9px}
.live-energy-track{position:relative;height:8px;border:1px solid rgba(217,185,92,.22);border-radius:999px;background:rgba(255,255,255,.045);overflow:hidden;box-shadow:inset 0 0 9px rgba(0,0,0,.5)}
.live-energy-fill{position:absolute;inset:0 auto 0 0;width:var(--live-progress,0%);border-radius:inherit;background:linear-gradient(90deg,rgba(137,103,25,.82),rgba(217,185,92,.96) 58%,rgba(238,255,92,.98));box-shadow:0 0 13px rgba(223,255,27,.32);transition:width .35s ease}
.live-energy-fill::after{content:"";position:absolute;inset:0;background:linear-gradient(110deg,transparent 12%,rgba(255,255,255,.34) 47%,transparent 68%);transform:translateX(-100%);animation:live-energy-flow 1.8s linear infinite}
.live-energy-tip{position:absolute;top:50%;left:var(--live-progress,0%);width:8px;height:8px;border-radius:50%;background:#efff6a;box-shadow:0 0 9px rgba(239,255,106,.82);transform:translate(-50%,-50%);transition:left .35s ease}
@keyframes live-energy-flow{to{transform:translateX(180%)}}
.live-energy-percent{color:var(--neon);font-family:var(--font-d);font-size:15px;font-weight:900;white-space:nowrap}
.live-stage-nodes{display:flex;justify-content:space-between;gap:4px;margin-top:6px;padding-right:42px}
.live-stage-node{min-width:0;color:#676d75;font-size:8.5px;font-weight:700;white-space:nowrap}
.live-stage-node.is-done{color:#aaa87d}.live-stage-node.is-current{color:#efff6a;text-shadow:0 0 7px rgba(239,255,106,.25)}
.live-dashboard-courts{padding-top:11px}
@media(max-width:600px){
  .live-dashboard-panel{padding:10px!important}
  .live-summary-line{gap:6px;flex-wrap:wrap}
  .live-summary-name{font-size:16.5px}
  .live-summary-chip{font-size:9px;padding:3px 6px}
  .live-summary-refresh{flex-basis:28px!important;width:28px!important;height:28px!important;min-height:28px!important}
  .live-energy-row{margin-top:8px;gap:7px}
  .live-energy-percent{font-size:14px}
  .live-stage-nodes{padding-right:38px}
  .live-stage-node{font-size:8px}
}
@media(prefers-reduced-motion:reduce){.live-energy-fill::after,.live-summary-refresh.is-busy{animation:none!important}}

/* ==== v13.28.6 court-scoped live view / unclipped referee desktop ==== */
.live-court-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.live-court-grid-1{grid-template-columns:minmax(0,760px);justify-content:center}
.live-court-card{position:relative;overflow:hidden;border:1px solid var(--court-accent,var(--border));border-radius:12px;background:linear-gradient(135deg,var(--court-glow-soft,rgba(255,255,255,.03)),rgba(8,10,14,.94) 52%);box-shadow:inset 0 1px 0 var(--court-glow-soft,transparent)}
.live-court-card::before{content:"";position:absolute;inset:0 0 auto;height:3px;background:var(--court-accent,var(--gold));box-shadow:0 0 14px var(--court-glow,transparent)}
.live-court-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;padding:13px 14px 10px;border-bottom:1px solid rgba(255,255,255,.07)}
.live-court-identity{display:flex;align-items:center;gap:9px;min-width:0}.live-court-identity>div{min-width:0}.live-court-identity small{display:block;color:var(--metal-dim);font-size:10px}.live-court-identity b{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:14px}
.live-court-meta{text-align:right;min-width:0}.live-court-meta small{display:block;margin-top:4px;color:var(--metal-dim);font-size:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.live-court-match{display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);align-items:center;gap:12px;padding:18px 14px}
.live-court-player{min-width:0;font-family:var(--font-d);font-weight:800;font-size:18px;color:var(--white);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.live-court-player:last-child{text-align:right}
.live-court-score{font-family:var(--font-d);font-size:32px;font-weight:900;color:var(--neon);white-space:nowrap}
.live-court-next{position:relative;margin:0 14px 13px;padding:10px 11px 11px 13px;border:1px solid color-mix(in srgb,var(--court-accent,var(--gold)) 58%,rgba(255,255,255,.12));border-radius:10px;background:linear-gradient(100deg,color-mix(in srgb,var(--court-accent,var(--gold)) 14%,rgba(10,12,16,.95)),rgba(255,255,255,.035));box-shadow:0 0 14px color-mix(in srgb,var(--court-accent,var(--gold)) 18%,transparent),inset 3px 0 0 var(--court-accent,var(--gold));overflow:hidden}.live-court-next-head{display:flex;align-items:center;justify-content:space-between;gap:8px;min-width:0}.live-court-next-badge{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;padding:4px 8px;border-radius:999px;background:var(--court-accent,var(--gold));color:#090a0b;font-size:10.5px;font-weight:900;line-height:1;letter-spacing:.04em;box-shadow:0 0 10px var(--court-glow,transparent)}.live-court-next-meta{min-width:0;color:#e8ebef;font-size:11.5px;font-weight:800;text-align:right;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.live-court-next-players{display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);align-items:center;gap:8px;margin-top:8px}.live-court-next-player{min-width:0;color:#fff;font-family:var(--font-d);font-size:15px;font-weight:800;line-height:1.2;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.live-court-next-player:last-child{text-align:right}.live-court-next-vs{color:var(--court-accent,var(--gold));font-family:var(--font-d);font-size:11px;font-weight:900;letter-spacing:.08em;text-shadow:0 0 8px var(--court-glow,transparent)}.live-court-next-status{margin-top:7px;color:#d8dce3;font-size:12px;font-weight:700;line-height:1.35}.live-court-next-note{display:block;margin-top:2px;color:#9ea5af;font-size:10px;font-weight:500}.referee-workstation .live-court-next{margin:0 16px 16px;padding:12px 13px 13px 15px;border-width:1.5px;box-shadow:0 0 18px color-mix(in srgb,var(--court-accent,var(--gold)) 26%,transparent),inset 4px 0 0 var(--court-accent,var(--gold))}.referee-workstation .live-court-next-badge{font-size:11.5px;padding:5px 10px}.referee-workstation .live-court-next-meta{font-size:12.5px;color:#f0f2f5}.referee-workstation .live-court-next-player{font-size:17px;font-weight:900;color:#fff}.referee-workstation .live-court-next-vs{font-size:12px}.referee-workstation .live-court-next-status{font-size:13px;color:#f0f2f5}
.live-court-empty{padding:25px 14px;text-align:center;color:var(--metal-dim)}.live-court-empty b{display:block;color:#d7dbe2;font-size:14px;margin-bottom:4px}
.live-ranking-panel>summary{list-style:none;cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:10px;font-family:var(--font-d);font-weight:800;color:var(--white)}.live-ranking-panel>summary::-webkit-details-marker{display:none}.live-ranking-panel>summary::after{content:"展開";font-family:var(--font);font-size:11px;color:var(--gold)}.live-ranking-panel[open]>summary::after{content:"收合"}.live-ranking-body{margin-top:14px}
@media(min-width:641px){.live-ranking-panel>summary{pointer-events:none}.live-ranking-panel>summary::after{display:none}.live-ranking-panel:not([open])>.live-ranking-body{display:block!important}}
@media(max-width:640px){.live-court-grid{grid-template-columns:1fr}.live-court-match{gap:7px;padding:15px 11px}.live-court-player{font-size:15px}.live-court-score{font-size:27px}.live-court-next{margin:0 11px 12px;padding:10px 10px 11px 12px}.live-court-next-badge{font-size:10.5px;padding:5px 9px}.live-court-next-meta{font-size:11px}.live-court-next-player{font-size:14.5px}.live-court-next-players{gap:6px;margin-top:8px}.live-court-next-status{font-size:12px}.referee-workstation .live-court-next{margin:0 12px 13px;padding:11px 11px 12px 13px}.referee-workstation .live-court-next-badge{font-size:11px}.referee-workstation .live-court-next-meta{font-size:11.5px}.referee-workstation .live-court-next-player{font-size:16.5px}.referee-workstation .live-court-next-vs{font-size:11.5px}.referee-workstation .live-court-next-status{font-size:12.5px}.live-ranking-panel{padding:14px}.live-ranking-body{margin-top:12px}}

/* ==== v14.2.4 live court hierarchy / score roll ==== */
.live-dashboard-panel .live-court-grid{gap:9px}
.live-dashboard-panel .live-court-card{border-color:color-mix(in srgb,var(--court-accent,var(--gold)) 45%,rgba(255,255,255,.08));box-shadow:inset 0 1px 0 var(--court-glow-soft,transparent)}
.live-dashboard-panel .live-court-head{align-items:center;padding:10px 11px 8px}
.live-court-titleline{display:flex;align-items:center;gap:7px;min-width:0}
.live-dashboard-panel .court-badge{padding:4px 8px;font-size:11px}
.live-court-ref{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#c9ced4;font-size:10.5px;font-weight:700}
.live-dashboard-panel .live-court-match{padding:14px 12px 8px;gap:8px}
.live-dashboard-panel .live-court-player{font-size:18px;font-weight:900}
.live-dashboard-panel .live-court-score{display:flex;align-items:center;justify-content:center;gap:5px;min-width:76px;font-size:34px;color:#f6f7f2;text-shadow:0 0 10px color-mix(in srgb,var(--court-accent,var(--gold)) 34%,transparent)}
.live-score-slot{position:relative;display:inline-grid;place-items:center;width:.72em;height:1.05em;overflow:hidden;line-height:1}
.live-score-current,.live-score-old,.live-score-new{grid-area:1/1}
.live-score-old,.live-score-new{position:absolute;inset:0;display:grid;place-items:center}
.live-score-slot.is-roll .live-score-old{animation:live-score-old-down .42s cubic-bezier(.2,.75,.3,1) both}
.live-score-slot.is-roll .live-score-new{animation:live-score-new-down .42s cubic-bezier(.2,.75,.3,1) both}
@keyframes live-score-old-down{0%{transform:translateY(0);opacity:1}100%{transform:translateY(105%);opacity:0}}
@keyframes live-score-new-down{0%{transform:translateY(-105%);opacity:.1}65%{opacity:1}100%{transform:translateY(0);opacity:1}}
.live-score-separator{opacity:.72;font-size:.7em}
.live-court-stage{padding:0 12px 9px;text-align:center;color:#9097a0;font-size:9.5px;font-weight:700}
.live-dashboard-panel .live-court-next{margin:0 10px 9px;padding:7px 8px;border-color:rgba(255,255,255,.075);border-radius:8px;background:rgba(255,255,255,.018);box-shadow:none}
.live-next-line{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:7px;min-width:0}
.live-next-label{color:#9da4ad;font-size:9.5px;font-weight:800;white-space:nowrap}
.live-next-players{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#d2d6dc;font-size:11.5px;font-weight:750;text-align:center}
.live-next-players .live-next-vs{margin:0 4px;color:#7f8790;font-size:9px;font-weight:800}
.live-next-eta{color:#c7caa2;font-size:10px;font-weight:800;white-space:nowrap}
.live-next-muted{color:#858c95}
.live-dashboard-panel .live-court-empty{padding:16px 12px}
.ref-workstation-meta .ref-court-exit-btn{align-self:flex-end;margin-top:7px;padding:8px 14px;border:1px solid #ff8282;border-radius:9px;background:#6f202b;color:#fff;font-size:13px;font-weight:900;box-shadow:0 0 0 1px rgba(255,100,100,.16)}
.ref-workstation-meta .ref-court-exit-btn:hover:not(:disabled),.ref-workstation-meta .ref-court-exit-btn:focus-visible{background:#9c2835;border-color:#ffb2b2;outline:2px solid #ffd0d0;outline-offset:2px}
.ref-workstation-meta .ref-court-exit-btn:disabled{opacity:.5;cursor:wait}
.live-court-switch{display:none}
@media(max-width:640px){
  .live-court-switch{display:block;margin:0 0 10px;overflow:hidden}
  .live-court-switch-track{display:flex;gap:7px;overflow-x:auto;overscroll-behavior-x:contain;scroll-snap-type:x proximity;-webkit-overflow-scrolling:touch;padding:2px 2px 8px;scrollbar-width:thin}
  .live-court-switch-btn{flex:0 0 76px;min-height:52px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;border:1px solid color-mix(in srgb,var(--court-accent,var(--gold)) 50%,rgba(255,255,255,.12));border-radius:10px;background:rgba(255,255,255,.04);color:#f4f5f7;scroll-snap-align:center;cursor:pointer}
  .live-court-switch-btn strong{font-size:13px;line-height:1.1}.live-court-switch-btn span{font-size:10px;color:#bfc5cd;white-space:nowrap}
  .live-court-switch-btn.is-selected{border-color:var(--court-accent,var(--gold));background:color-mix(in srgb,var(--court-accent,var(--gold)) 18%,#101019);box-shadow:0 0 0 2px color-mix(in srgb,var(--court-accent,var(--gold)) 25%,transparent)}
  .live-court-switch-all{border-color:#d6b268;background:rgba(214,178,104,.1)}
  .live-court-switch-all.is-selected{border-color:#f5d982;background:rgba(214,178,104,.25);box-shadow:0 0 0 2px rgba(245,217,130,.22)}
  .live-court-switch-btn:focus-visible{outline:2px solid #fff;outline-offset:2px}
  .live-dashboard-panel .live-court-grid[data-mobile-switcher="true"] .live-court-card:not([data-selected="true"]){display:none}
}
@media(max-width:640px){
  .live-dashboard-panel .live-court-match{padding:13px 9px 7px;gap:5px}
  .live-dashboard-panel .live-court-player{font-size:16.5px}
  .live-dashboard-panel .live-court-score{font-size:31px;min-width:68px}
  .live-dashboard-panel .live-court-head{padding:9px 9px 7px}
  .live-dashboard-panel .court-badge{font-size:10.5px}
  .live-court-ref{font-size:10px}
  .live-court-stage{padding:0 9px 8px;font-size:9px}
  .live-dashboard-panel .live-court-next{margin:0 8px 8px;padding:6px 7px}
  .live-next-line{gap:5px}
  .live-next-label{font-size:9px}
  .live-next-players{font-size:10.8px}
  .live-next-eta{font-size:9.5px}
}
@media(prefers-reduced-motion:reduce){.live-score-slot.is-roll .live-score-old,.live-score-slot.is-roll .live-score-new{animation:none!important}.live-score-slot.is-roll .live-score-old{display:none}}

/* ==== v13.23.9 beta stability hardening ==== */
.account-menu-wrap,.account-badge,.account-menu{pointer-events:auto;}
.account-menu-wrap{isolation:isolate;}
.account-menu{max-height:min(70vh,520px);overflow-y:auto;-webkit-overflow-scrolling:touch;}
.panel,.stat-box,.grid>*,.btn-row>*,.lobby-card-main>*,.lobby-card-detail>*{min-width:0;}
.panel,.stat-box{max-width:100%;}
.panel-title,.hint,.lobby-room-name,.lobby-description,.duty-row,.settings-page-sub{overflow-wrap:anywhere;word-break:break-word;}
@media(max-width:640px){
  nav.tabs,.player-tabs,.guest-tabs{overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch;scroll-behavior:auto;}
  nav.tabs button,.player-tab-btn,.guest-tab{flex:0 0 auto;}
  .stickytop .player-tabs:not(.player-tabs-bottom){overflow-x:auto;overflow-y:hidden;}
  .account-menu-wrap{z-index:1500;}
  header.topbar .account-menu{z-index:1800;}
}

/* ==== v13.22.3 iPhone viewport / registration table hardening ==== */
html,body{width:100%;max-width:100%;overflow-x:hidden;}
#app{width:100%;max-width:100vw;min-width:0;overflow-x:hidden;}
.stickytop{width:100%;max-width:100vw;min-width:0;overflow:hidden;box-sizing:border-box;}
header.topbar,.role-indicator,.cloud-status-bar,nav.tabs{max-width:100vw;min-width:0;box-sizing:border-box;}
nav.tabs{width:100%;overflow-x:auto;overflow-y:hidden;}
main{min-width:0;max-width:100vw;overflow-x:hidden;box-sizing:border-box;}
.panel{min-width:0;max-width:100%;box-sizing:border-box;}
.table-scroll{display:block;width:100%;max-width:100%;min-width:0;overflow-x:auto;overflow-y:hidden;-webkit-overflow-scrolling:touch;overscroll-behavior-x:contain;}
.admin-registration-table{border-collapse:collapse;min-width:760px;width:760px;max-width:none;table-layout:auto;}
.admin-registration-table th,.admin-registration-table td{white-space:nowrap;word-break:normal;overflow-wrap:normal;vertical-align:middle;}
.admin-registration-table td:nth-child(4){max-width:260px;overflow:hidden;text-overflow:ellipsis;}
.mobile-table-hint{display:none;font-size:11px;color:var(--metal-dim);margin:0 0 8px;text-align:right;}
.public-watch-return{display:flex;align-items:center;gap:10px;padding:8px 12px;background:rgba(233,255,46,.045);border-bottom:1px solid var(--border);}
.public-watch-return span{font-size:11px;color:var(--metal-dim);}
@media(max-width:640px){
  .stickytop{position:sticky;left:0;right:0;}
  header.topbar{width:100%;max-width:100vw;overflow:hidden;}
  .admin-registration-scroll{border:1px solid var(--border-soft);border-radius:8px;}
  .mobile-table-hint{display:block;}
  .public-watch-return{position:relative;z-index:2;justify-content:space-between;}
  .public-watch-return .btn{min-height:38px;padding:8px 12px;}
}


.profile-edit-modal{max-width:620px;width:min(92vw,620px);max-height:88vh;overflow:auto}
.profile-edit-modal .grid{align-items:start}
@media(max-width:640px){.profile-edit-modal .grid-2{grid-template-columns:1fr}}

/* ==== v13.24.0 player navigation / logout hardening ==== */
.player-tabs{overflow-x:auto;overflow-y:hidden;scrollbar-width:none;-webkit-overflow-scrolling:touch;overscroll-behavior-x:contain;}
.player-tabs::-webkit-scrollbar{display:none;}
.player-tabs .player-tab-btn{flex:1 0 auto;min-width:92px;}
@media(max-width:640px){
  .player-tabs .player-tab-btn{min-width:84px;padding-left:8px;padding-right:8px;}
  .player-mobile-session-strip{padding-left:10px;padding-right:10px;}
  .player-session-actions .btn{min-height:34px!important;padding:6px 10px!important;}
}


/* ==== 2026-09-20 player top-nav narrow desktop/tablet fit ==== */
@media (min-width:560px) and (max-width:900px){
  .stickytop .player-tabs:not(.player-tabs-bottom){
    display:grid!important;
    grid-template-columns:repeat(8,minmax(0,1fr));
    width:100%;
    max-width:100vw;
    overflow-x:hidden!important;
    gap:0;
  }
  .stickytop .player-tabs:not(.player-tabs-bottom) .player-tab-btn{
    min-width:0!important;
    width:auto!important;
    flex:none!important;
    padding-left:5px!important;
    padding-right:5px!important;
    font-size:12px;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:clip;
  }
}
@media (max-width:559px){
  .stickytop .player-tabs:not(.player-tabs-bottom){
    overflow-x:auto!important;
    overflow-y:hidden!important;
    touch-action:pan-x;
  }
  .stickytop .player-tabs:not(.player-tabs-bottom) .player-tab-btn{
    flex:0 0 auto!important;
  }
}

/* ==== v13.24.8 account dropdown top-layer hotfix ==== */
/* 子選單再高的 z-index 都無法逃出父層 stacking context / overflow clipping；
   因此直接把 sticky header 升層並解除父層裁切。 */
.stickytop{
  position:sticky;
  top:0;
  z-index:90!important;
  overflow:visible!important;
}
header.topbar{overflow:visible!important;}
header.topbar .account-menu-wrap{position:relative;z-index:91!important;isolation:isolate;}
header.topbar .account-menu{z-index:92!important;}
/* 各橫向導覽自己處理 overflow，不再靠 stickytop 裁切整個 header。 */
nav.tabs,.player-tabs,.guest-tabs{overflow-x:auto;overflow-y:hidden;}


/* v13.25.0 — global account overlay / registration readability */
.account-menu-overlay{
  position:fixed;
  inset:0;
  z-index:1000;
  pointer-events:none;
}
.account-menu-overlay .account-menu{
  position:fixed!important;
  top:0;
  right:auto;
  left:0;
  z-index:1001!important;
  pointer-events:auto;
  min-width:190px;
  max-width:min(300px,calc(100vw - 24px));
  max-height:min(70dvh,520px);
  overflow-y:auto;
  -webkit-overflow-scrolling:touch;
  box-shadow:0 18px 44px rgba(0,0,0,.66);
}
.account-menu-overlay .account-menu button{min-height:44px;}
.data-table.admin-registration-table tbody tr{border-bottom:1px solid rgba(255,255,255,.10);}
.data-table.admin-registration-table tbody tr:last-child{border-bottom:0;}
.data-table.admin-registration-table tbody tr:hover{background:rgba(217,185,92,.045);}
.registration-mobile-card{border-color:rgba(255,255,255,.10);box-shadow:0 1px 0 rgba(255,255,255,.025);}
.registration-mobile-card + .registration-mobile-card{margin-top:8px;}
.registration-mobile-details{border-top:1px solid rgba(255,255,255,.09);}
.registration-mobile-detail-row + .registration-mobile-detail-row{border-top:1px dashed rgba(255,255,255,.065);}
.registration-list-panel .panel-title{padding-bottom:10px;border-bottom:1px solid rgba(255,255,255,.08);}
.publish-preview-card{box-shadow:inset 0 0 0 1px rgba(217,185,92,.035);}
/* global overlay hierarchy: content < sticky nav < account menu < dialogs < celebration */
body .modal-overlay{z-index:2000!important;}
body .modal-backdrop{z-index:2000!important;}
body .celebration-overlay{z-index:3000!important;}


/* v13.24.9 — mobile registration cards + unified player identity chip */
.registration-mobile-list{display:none;}
.registration-desktop-table{display:block;}
.registration-mobile-card{border:1px solid var(--line);border-radius:14px;background:rgba(255,255,255,.018);overflow:hidden;margin-top:10px;}
.registration-mobile-card summary{list-style:none;cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 15px;min-width:0;}
.registration-mobile-card summary::-webkit-details-marker{display:none;}
.registration-mobile-main{display:flex;flex-direction:column;gap:1px;min-width:0;}
.registration-mobile-main strong{font-size:16px;color:var(--ivory);overflow-wrap:anywhere;}
.registration-mobile-main small{font-size:12px;color:var(--metal-dim);overflow-wrap:anywhere;}
.registration-mobile-more{font-size:11px;color:var(--gold);white-space:nowrap;flex:0 0 auto;}
.registration-mobile-card[open] .registration-mobile-more::after{content:" ▲";}
.registration-mobile-card:not([open]) .registration-mobile-more::after{content:" ▼";}
.registration-mobile-details{border-top:1px solid var(--line);padding:10px 15px 14px;display:grid;gap:0;}
.registration-mobile-details>div:not(.registration-mobile-actions){display:grid;grid-template-columns:78px minmax(0,1fr);gap:10px;padding:9px 0;border-bottom:1px solid rgba(255,255,255,.055);align-items:start;}
.registration-mobile-details>div:last-of-type{border-bottom:none;}
.registration-mobile-details span{font-size:11px;color:var(--metal-dim);}
.registration-mobile-details b{font-size:13px;font-weight:600;color:var(--ivory);min-width:0;overflow-wrap:anywhere;}
.registration-mobile-actions{padding-top:12px;display:flex;justify-content:flex-end;}
.registration-mobile-empty{margin-top:10px;border:1px dashed var(--line);border-radius:14px;padding:22px 14px;text-align:center;color:var(--metal-dim);font-size:13px;}
.break-anywhere{overflow-wrap:anywhere;word-break:break-word;}
@media(max-width:767px){
  .registration-desktop-table{display:none!important;}
  .registration-mobile-list{display:block;}
  .registration-list-panel{padding:16px!important;}
  .registration-promote-row{margin:8px 0 2px!important;}
  .registration-promote-row .btn{width:100%;}
  .player-shell header.topbar .account-menu-wrap{margin-left:auto;flex:0 0 auto;}
  .player-shell header.topbar .account-badge{max-width:min(58vw,250px);}
  .player-shell header.topbar .account-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:110px;}
}



/* Activity poster management and full-size A4 viewing */
.lobby-event-intro-head{display:flex;align-items:center;justify-content:space-between;gap:.65rem;margin:1rem 0 .5rem}
.lobby-event-intro-head h3{font-size:1rem;margin:0;color:#f5e9cf}
.lobby-poster-manage{flex:0 0 auto;color:#e7d5b2;border-color:rgba(231,213,178,.35);background:rgba(255,255,255,.045)}
.lobby-poster-manage:hover{background:rgba(255,255,255,.1)}
[data-poster-manage][hidden]{display:none!important}
.lobby-poster-slot:empty{display:none}
.lobby-poster-figure{position:relative;width:min(100%,560px);margin:.75rem auto 1rem;text-align:center}
.lobby-poster-open{display:block;width:100%;padding:0;border:0;background:transparent;cursor:zoom-in}
.lobby-poster-image{display:block;width:auto;height:auto;max-width:100%;max-height:80vh;object-fit:contain;margin:auto;border-radius:10px;box-shadow:0 8px 28px #0008}
.lobby-poster-zoom{position:absolute;right:.65rem;bottom:.65rem;padding:.45rem .8rem;border:1px solid #ffffff55;border-radius:999px;background:#171717dd;color:#fff;font-weight:700;cursor:pointer}
.lobby-poster-legacy{width:min(100%,260px);margin:.75rem auto 1rem;text-align:center}
.lobby-poster-legacy img{display:block;width:auto;height:auto;max-width:240px;max-height:240px;object-fit:contain;margin:auto}
.lobby-poster-legacy figcaption{margin-top:.4rem;color:#b8b2a5;font-size:.78rem}
.lobby-poster-manager{position:fixed;inset:0;z-index:10030;display:grid;place-items:center;padding:1rem}
.lobby-poster-manager[hidden]{display:none}
.lobby-poster-manager-backdrop{position:absolute;inset:0;background:#000c}
.lobby-poster-manager-panel{position:relative;z-index:1;width:min(100%,560px);max-height:92vh;overflow:auto;padding:1.1rem;border:1px solid #b78d45;border-radius:18px;background:#171717;color:#f8f2e7;box-shadow:0 18px 70px #000b}
.lobby-poster-manager-panel h2{margin:.15rem 2.5rem .5rem 0}
.lobby-poster-modal-close{position:absolute;right:.7rem;top:.6rem;width:2.5rem;height:2.5rem;border:0;border-radius:50%;background:#ffffff18;color:#fff;font-size:1.5rem}
.lobby-poster-manager-help{color:#c7beae;font-size:.9rem}
.lobby-poster-file-label{display:flex;align-items:center;gap:.75rem;flex-wrap:wrap;margin:1rem 0;padding:.8rem;border:1px dashed #b78d45;border-radius:12px}
.lobby-poster-file-label input{max-width:100%}
.lobby-poster-preview{max-height:52vh;overflow:auto;text-align:center;background:#080808;border-radius:12px}
.lobby-poster-preview img{max-width:100%;max-height:52vh;object-fit:contain}
.lobby-poster-error{min-height:1.4em;margin:.5rem 0;color:#ffaaa1;font-size:.9rem}
.lobby-poster-manager-actions{display:flex;justify-content:flex-end;gap:.6rem;margin-top:.8rem}
.lobby-poster-viewer{position:fixed;inset:0;z-index:10040;display:grid;grid-template-rows:auto 1fr auto;background:#050505f5;color:#fff}
.lobby-poster-viewer-toolbar{display:flex;justify-content:space-between;align-items:center;padding:max(.6rem,env(safe-area-inset-top)) .8rem .4rem}
.lobby-poster-viewer-toolbar button{min-width:2.7rem;min-height:2.7rem;border:1px solid #ffffff50;border-radius:999px;background:#171717;color:#fff;font-size:1rem}
.lobby-poster-viewer-toolbar [data-viewer-close]{font-size:1.5rem}
.lobby-poster-viewer-stage{position:relative;display:grid;place-items:center;overflow:hidden;touch-action:none}
.lobby-poster-viewer-image{max-width:100vw;max-height:calc(100vh - 7rem);width:auto;height:auto;object-fit:contain;transform-origin:center center;touch-action:none;user-select:none;-webkit-user-drag:none}
.lobby-poster-viewer-hint{text-align:center;padding:.35rem .6rem max(.55rem,env(safe-area-inset-bottom));color:#d6d0c5;font-size:.82rem}
.lobby-poster-modal-open{overscroll-behavior:none}
@media(max-width:600px){.lobby-event-intro-head{align-items:center}.lobby-poster-figure{width:100%}.lobby-poster-image{max-height:70vh}.lobby-poster-manager-panel{padding:1rem}}

/* Keep the court number distinct from the smaller referee label. */
.referee-workstation .ref-workstation-identity > .court-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  box-sizing:border-box;
  min-width:64px;
  min-height:44px;
  padding:8px 12px;
  background:var(--court-accent,var(--gold));
  color:#090a0b;
  font-size:24px;
  font-weight:900;
  line-height:1.15;
  letter-spacing:.02em;
  white-space:nowrap;
  text-shadow:none;
  flex:0 0 auto;
}
@media(max-width:640px){
  .referee-workstation .ref-workstation-identity > .court-badge{
    min-width:56px;
    min-height:40px;
    padding:7px 10px;
    font-size:20px;
  }
}

/* Quick-room hosting */
.community-room-overview h1{
  font-size:clamp(20px,4vw,28px);
  margin:4px 0 14px;
  overflow-wrap:anywhere;
}
.community-room-code{
  display:flex;
  align-items:baseline;
  flex-wrap:wrap;
  gap:4px 12px;
  color:var(--metal);
  font-size:13px;
}
.community-room-code strong{color:var(--white);font-size:18px;letter-spacing:.06em}
.community-room-actions{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
  margin-top:10px;
}
.community-room-overview>.btn-primary{margin-top:10px}
.community-room-actions .btn,.community-room-overview>.btn-primary{min-height:44px}

.community-create-card .settings-check-row,.community-settings .settings-check-row{margin-bottom:12px}
.community-create-card .settings-check-row small,.community-settings .settings-check-row small{display:block}
.community-create-card>.hint{margin:0 0 16px}
.community-settings-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  column-gap:12px;
  align-items:start;
}
.community-settings-fieldset{border:0;padding:0;margin:0;min-inline-size:0}
.community-settings-fieldset:disabled{opacity:.6}
.community-settings .field,.community-create-card .field{min-width:0}
.community-settings .field input,.community-settings .field select,
.community-create-card .field input,.community-create-card .field select{
  box-sizing:border-box;
  width:100%;
  min-width:0;
  max-width:100%;
  min-height:44px;
  border:1px solid var(--border);
  border-radius:8px;
  padding:9px 10px;
  background:var(--panel-2);
  color:var(--white);
  font-size:16px;
}
.community-settings .field input:focus,.community-settings .field select:focus,
.community-create-card .field input:focus,.community-create-card .field select:focus{
  border-color:var(--neon-dim);
}
.community-settings-access:not(:has(#cset-access-mode option[value="password"]:checked)) .community-settings-password{display:none}
.community-settings-save{display:flex;justify-content:flex-end;padding-top:6px}
@media(max-width:640px){
  nav.tabs.community-room-tabs{
    display:grid;
    grid-template-columns:repeat(5,minmax(0,1fr));
    gap:2px;
    padding-inline:6px;
    touch-action:pan-y;
  }
  nav.tabs.community-room-tabs button{
    min-width:0;
    min-height:44px;
    padding-inline:2px;
    font-size:clamp(11px,3.1vw,14px);
    white-space:normal;
  }
  .community-settings-grid:not(.community-settings-pair){grid-template-columns:minmax(0,1fr)}
  main:has(>.community-settings){
    padding-bottom:calc(52px + max(8px,env(safe-area-inset-bottom)));
  }
  .community-settings-save{
    position:fixed;
    inset-inline:0;
    bottom:0;
    z-index:4;
    padding:8px 16px max(8px,env(safe-area-inset-bottom));
    background:var(--panel-2);
  }
  .community-settings-save>.btn{width:100%;min-height:44px}
}
