/*
 * AOW MASTERS VISUAL SYSTEM — V10
 * Design-only skin inspired by the user's AOW Masters '26 Summer reference.
 * Bracket geometry, JS hooks, control state and server behaviour are untouched.
 * All selectors are scoped to body.aow-masters-theme. Removing the stylesheet
 * and theme body class restores the V9.5 visual appearance.
 *
 * The Google Fonts request is optional: system-font fallbacks still work.
 */
@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@400;500;600;700;800;900&family=Roboto+Condensed:wght@400;500;600;700;800;900&display=swap');

body.aow-masters-theme {
  --bg:#061013;
  --panel:#0b171a;
  --panel2:#11232a;
  --text:#e7efed;
  --muted:#9aacae;
  --line:#2c494e;
  --accent:#4babb3;
  --good:#80c9a7;
  --warn:#f0c34c;
  --bad:#e67679;
  --conf:#3b8ca9;
  --res:#bf555b;
  --aow-surface:#071317;
  --aow-surface-2:#0e1c20;
  --aow-surface-3:#13282e;
  --aow-border:#304b50;
  --aow-border-bright:#4c7b80;
  --aow-ink:#e4edeb;
  --aow-dim:#a0b0b2;
  --aow-gold:#e5bd4d;
  --aow-teal:#74cbd1;
  --aow-danger:#d36c70;
  --aow-heading:'Barlow Condensed','Roboto Condensed','Arial Narrow',sans-serif;
  --aow-body:'Roboto Condensed','Arial Narrow',Arial,sans-serif;
  font-family:var(--aow-body);
  font-size:18px;
  background:#061013;
  color:var(--aow-ink);
  text-rendering:optimizeLegibility;
}
body.aow-masters-theme :is(button,input,select,textarea){font-family:var(--aow-body)}
body.aow-masters-theme .page-backdrop {
  background:linear-gradient(180deg,rgba(3,12,14,.84) 0%,rgba(3,13,15,.82) 35%,rgba(3,13,16,.9) 100%) !important;
}
body.aow-masters-theme .mobile-battlefield{opacity:.42}
body.aow-masters-theme .wrap {position:relative}
body.aow-masters-theme h1,
body.aow-masters-theme h2,
body.aow-masters-theme h3,
body.aow-masters-theme h4,
body.aow-masters-theme .metric,
body.aow-masters-theme .stat-value,
body.aow-masters-theme .brand,
body.aow-masters-theme .round-heading span,
body.aow-masters-theme .tournament-match .team-identity,
body.aow-masters-theme .team-info-heading,
body.aow-masters-theme .ms-bulk-settings strong {
  font-family:var(--aow-heading);
  font-weight:700;
  letter-spacing:.035em;
  color:var(--aow-ink);
}
body.aow-masters-theme h1{font-size:clamp(38px,5vw,70px);line-height:1.05;letter-spacing:.052em}
body.aow-masters-theme h2{font-size:clamp(29px,3vw,41px);line-height:1.13}
body.aow-masters-theme h3{font-size:clamp(23px,2.2vw,30px);line-height:1.15}
body.aow-masters-theme .eyebrow,
body.aow-masters-theme .ms-field-label,
body.aow-masters-theme .field>label,
body.aow-masters-theme .public-setup-label {
  font-family:var(--aow-heading);
  font-weight:800;
  letter-spacing:.13em;
  text-transform:uppercase;
  color:var(--aow-teal) !important;
}
body.aow-masters-theme :is(.muted,.small,.footer,.field small){color:var(--aow-dim)}
body.aow-masters-theme :is(a,button){-webkit-tap-highlight-color:transparent}
body.aow-masters-theme :focus-visible{outline:2px solid var(--aow-teal);outline-offset:2px}
body.aow-masters-theme ::selection{background:rgba(76,168,171,.44);color:#fff}

/* PORTAL NAVIGATION — compact command-bar style */
body.aow-masters-theme .portal-nav {
  min-height:70px;
  padding:12px 18px;
  margin:0 0 22px;
  background:rgba(5,16,18,.96) !important;
  border:1px solid var(--aow-border);
  border-bottom-color:#42666b;
  box-shadow:0 12px 32px rgba(0,0,0,.22);
}
body.aow-masters-theme .portal-nav .brand{
  font-family:var(--aow-heading);
  font-size:clamp(19px,2.4vw,27px);
  line-height:1.08;
  letter-spacing:.105em;
  text-transform:uppercase;
  text-shadow:none;
}
body.aow-masters-theme .portal-nav .brand span{color:var(--aow-teal);letter-spacing:.08em}
body.aow-masters-theme :is(.menu-toggle,.menu-close,.portal-menu-account .btn){
  background:rgba(9,24,27,.95) !important;
  border:1px solid var(--aow-border) !important;
  border-radius:3px !important;
  color:var(--aow-ink) !important;
  box-shadow:none !important;
}
body.aow-masters-theme .menu-toggle:hover{border-color:var(--aow-teal) !important;background:#173037 !important}
body.aow-masters-theme .menu-icon i{background:var(--aow-teal)}
body.aow-masters-theme .portal-menu-panel{
  background:linear-gradient(170deg,#12252a,#050e11) !important;
  border-left:1px solid var(--aow-border-bright);
}
body.aow-masters-theme .portal-menu-links a{
  color:var(--aow-ink);
  border-bottom-color:rgba(89,134,140,.22);
  font-family:var(--aow-heading);
  font-size:21px;
  font-weight:600;
  letter-spacing:.035em;
}
body.aow-masters-theme .portal-menu-links a:hover{color:var(--aow-teal);background:rgba(70,164,171,.1)}
body.aow-masters-theme .portal-menu-number{color:var(--aow-gold)}

/* SHARED PANEL SYSTEM — no geometry changes to grids or forms */
body.aow-masters-theme :is(.card,.match-setup-panel,.ms-rule-card,.private-admin-card,.ms-bulk-panel,
  .ms-bulk-launch-entry,.admin-control-card,.admin-content-editor,.portal-modal-card,
  .modal-panel,.v9-auth-card,.team-info-card,.ms-bulk-dialog,
  .notification-channel,.notification-team-option,.ms-bulk-mode,
  .chat-message-modal-panel,.chat-history-revision,
  .notification-status-card,.admin-tool,
  .info-launch,.ms-picker-history) {
  background:linear-gradient(155deg,rgba(15,30,34,.97),rgba(5,15,18,.96)) !important;
  border:1px solid var(--aow-border) !important;
  border-radius:4px !important;
  box-shadow:0 8px 22px rgba(0,0,0,.16) !important;
}
body.aow-masters-theme :is(.ms-switch-row,.ms-rule-game,.ms-bo-default-heading,
  .ms-bo-round-card,.ms-bo-round-editor,.ms-bo-round-overrides,
  .ms-bulk-game,.ms-bulk-picker-progress,.ms-bulk-progress-match,
  .ms-bulk-progress-totals>div,.ms-bulk-match,.ms-bulk-settings,
  .ms-full-series-info,.ms-bulk-match-label,.team-era-history-row,
  .public-match-setup-summary,.team-info-section,.team-info-roster,
  .public-ban-history-row,.ms-history-row,.v9-account-grid .card,
  .admin-team-current-row,.notification-team-option,
  .ms-history-previous,.picker-timer-row) {
  border-color:rgba(73,117,121,.40) !important;
  border-radius:3px !important;
  background-color:rgba(5,18,21,.62) !important;
  box-shadow:none !important;
}
body.aow-masters-theme .section{color:var(--aow-ink)}
body.aow-masters-theme .section>.eyebrow:first-child{margin-bottom:7px}
body.aow-masters-theme :is(.admin-page-head,.ms-bulk-settings,.ms-library-title){border-color:var(--aow-border)}
body.aow-masters-theme .footer{letter-spacing:.11em;text-transform:uppercase;color:#869da0}

/* BUTTONS / COMMANDS — squared-off military UI */
body.aow-masters-theme :is(.btn,.admin-back-btn,.admin-back-topright,
  .ms-action,.ms-bulk-filter,.ms-bulk-mode,.ms-ui-select-trigger,
  .ms-custom-select-trigger,.portal-select-trigger,
  .bracket-team-picker-trigger,.match-chat-button,
  .picker-action,.menu-account-btn) {
  border-radius:3px !important;
  font-family:var(--aow-heading) !important;
  font-weight:750 !important;
  letter-spacing:.065em;
  text-transform:uppercase;
  box-shadow:none !important;
}
body.aow-masters-theme :is(.btn,.admin-back-btn,.admin-back-topright,
  .ms-action,.ms-bulk-filter,.match-chat-button,.picker-action){
  border:1px solid #426168 !important;
  background:#10242a !important;
  color:#dce8e6 !important;
}
body.aow-masters-theme :is(.btn,.admin-back-btn,.admin-back-topright,
  .ms-action,.ms-bulk-filter,.match-chat-button,.picker-action):hover:not(:disabled){
  background:#1b3b42 !important;
  border-color:#75b8bf !important;
  color:#fff !important;
  transform:none !important;
}
body.aow-masters-theme :is(.btn.primary,button.primary,a.btn.primary,
  .ms-action.primary,.ms-action.ms-primary){
  background:#246674 !important;
  border-color:#4ba1aa !important;
  color:#f5faf8 !important;
  text-shadow:none !important;
}
body.aow-masters-theme :is(.btn.primary,button.primary,a.btn.primary):hover:not(:disabled){
  background:#347f88 !important;
  border-color:#8cd7d7 !important;
}
body.aow-masters-theme :is(.btn.danger,.btn.bad,.ms-action.danger,.danger-action,
  .ms-bulk-progress-badge.stopped){
  background:rgba(103,35,41,.43) !important;
  border-color:#90474f !important;
  color:#f6b1b2 !important;
}
body.aow-masters-theme :is(button,input[type='button'],input[type='submit']){cursor:pointer}
body.aow-masters-theme :is(button,input,select,textarea):disabled{cursor:not-allowed}
body.aow-masters-theme :is(input[type='text'],input[type='number'],input[type='email'],
  input[type='password'],input[type='search'],input[type='date'],input[type='time'],
  input[type='datetime-local'],textarea,select,.ms-input,.ms-select,.field input,.field select,
  .field textarea,.ms-ui-select-trigger,.ms-custom-select-trigger,
  .portal-select-trigger,.bracket-team-picker-trigger) {
  border:1px solid #3c565c !important;
  border-radius:3px !important;
  background:#07151a !important;
  color:#e8f1ef !important;
  box-shadow:none !important;
}
body.aow-masters-theme :is(input,textarea)::placeholder{color:#8da1a3}
body.aow-masters-theme :is(input,textarea,select,.ms-ui-select-trigger):focus-visible{
  outline:2px solid rgba(120,196,196,.58);outline-offset:1px;border-color:#84bdbf !important;
}
body.aow-masters-theme :is(input[type='checkbox'],input[type='radio']){accent-color:#3f9ba7}
body.aow-masters-theme :is(.ms-ui-select-menu,.ms-custom-select-options,
  .portal-select-menu,.bracket-team-picker-menu){
  background:#0a1a1f !important;border:1px solid #4a787c !important;
  border-radius:3px !important;box-shadow:0 16px 40px rgba(0,0,0,.5) !important;
}
body.aow-masters-theme :is(.ms-ui-select-option:hover,.ms-custom-select-option:hover,
  .portal-select-option:hover,.bracket-team-picker-option:hover){background:rgba(60,145,153,.21) !important}
body.aow-masters-theme :is(.ms-ui-select-option.is-selected,.ms-bulk-filter.active,
  .portal-select-option.is-selected){background:rgba(53,126,136,.3) !important;color:#d6f3f0 !important;border-color:#5e9fa5 !important}
body.aow-masters-theme .ms-switch input:checked + .ms-switch-track{background:#276b72 !important}
body.aow-masters-theme .ms-switch-track{border-color:#477277 !important}

/* LABELS / BADGES / STATES */
body.aow-masters-theme :is(.eyebrow,.tag,.pill,.bo-chip,.ms-status,
  .ms-reason-pill,.ms-bulk-progress-badge,.ms-bulk-status,
  .public-setup-label,.ms-bulk-filter,.picker-state-pill){
  font-family:var(--aow-heading);
  letter-spacing:.07em;
}
body.aow-masters-theme :is(.tag,.pill,.bo-chip,.ms-bulk-progress-badge,
  .ms-bulk-status,.ms-status,.ms-reason-pill,.picker-state-pill){border-radius:2px !important}
body.aow-masters-theme .eyebrow{color:var(--aow-teal) !important;font-size:clamp(16px,1.35vw,16px)}
body.aow-masters-theme :is(.ms-reason-pill,.team-era-history-reason,.public-ban-reason){
  color:#d5c396 !important;background:rgba(139,110,48,.13) !important;
  border:1px solid rgba(196,151,67,.46) !important;border-radius:2px !important;
}
body.aow-masters-theme :is(.ms-status-finished,.ms-bulk-status.complete,
  .ms-bulk-progress-badge.completed,.tag.good){color:#9addb1 !important;border-color:#47836a !important;background:rgba(37,90,65,.28) !important}
body.aow-masters-theme :is(.ms-status-running,.ms-bulk-status.running,
  .ms-bulk-progress-badge.running){color:#9adbe2 !important;background:rgba(41,112,124,.22) !important;border-color:#417b84 !important}
body.aow-masters-theme :is(.ms-bulk-game-top>strong,.era-history-game,.team-era-history-game,
  .ms-history-row .era-history-game,.public-setup-label){color:var(--aow-gold) !important}
body.aow-masters-theme .flash{border-color:#4b787b;background:#0a2024;color:#cce2e1;border-radius:3px}

/* MAIN LANDING — battlefield hero, same existing art */
body.aow-masters-theme .hero {
  padding:clamp(46px,7vw,94px) 28px !important;
  border-top:1px solid #526e71;
  border-bottom:3px solid #56afba;
  border-radius:0 !important;
  background:linear-gradient(90deg,rgba(4,16,18,.93),rgba(4,16,18,.59) 63%,rgba(4,16,18,.44)),url('/static/tournament-background.jpg') center 48% / cover no-repeat !important;
  box-shadow:0 20px 50px rgba(0,0,0,.26);
}
body.aow-masters-theme .hero h1{max-width:980px;line-height:1.02;text-shadow:0 2px 9px #050e11}
body.aow-masters-theme .hero p{color:#bed0cf;max-width:840px}
body.aow-masters-theme :is(.metric,.stat-value){color:var(--aow-gold);font-family:var(--aow-heading);font-size:clamp(23px,2.8vw,38px)!important}
body.aow-masters-theme .info-launch h3{letter-spacing:.05em}

/* BRACKET — visual skin ONLY. Do not change dimensions, spacing, positioning,
   connector geometry or JS layout selectors. */
body.aow-masters-theme :is(.round-heading,.bracket-round>h3){border-bottom-color:#416264 !important}
body.aow-masters-theme .round-heading span{font-family:var(--aow-heading);font-size:23px;letter-spacing:.055em}
body.aow-masters-theme .round-heading small{color:var(--aow-teal);font-family:var(--aow-heading);font-size:16px}
body.aow-masters-theme .tournament-match{
  background:linear-gradient(155deg,rgba(8,25,29,.98),rgba(5,14,17,.99)) !important;
  border-color:#3c585a !important;
  border-radius:3px !important;
  box-shadow:0 7px 23px rgba(0,0,0,.23) !important;
  /* No width, padding, height or position changes here. */
}
body.aow-masters-theme .tournament-match-head{
  color:#97a9aa;
  font-family:var(--aow-heading);
  font-size:16px;
  letter-spacing:.08em;
}
body.aow-masters-theme .bo-chip{background:#09191d !important;border-color:#3d656b !important;color:#a4d0d3 !important;font-size:16px}
body.aow-masters-theme .tournament-match .team-identity{font-size:16px;font-weight:650;letter-spacing:.012em;line-height:1.15}
body.aow-masters-theme .tournament-match .team-slot{border-radius:2px !important}
body.aow-masters-theme .tournament-match .team-slot.faction-conf{
  background:linear-gradient(90deg,#17343d,rgba(16,40,47,.96)) !important;
  border-color:rgba(66,130,151,.42) !important;
  color:#d8eeee !important;
}
body.aow-masters-theme .tournament-match .team-slot.faction-res{
  background:linear-gradient(90deg,#392127,rgba(40,22,27,.97)) !important;
  border-color:rgba(164,87,91,.4) !important;
  color:#f2dfdf !important;
}
body.aow-masters-theme .tournament-match .team-slot.team-tbd{
  background:#0b1a1e !important;border-color:rgba(71,105,109,.34) !important;color:#8fa5a8 !important;
}
body.aow-masters-theme .team-slot.team-winner{filter:brightness(1.1)}
body.aow-masters-theme .tournament-match .team-slot.team-loser{filter:grayscale(.65);opacity:.68}
body.aow-masters-theme .tournament-match .team-score{
  border:0 !important;background:transparent !important;
  box-shadow:none !important;color:var(--aow-gold) !important;
  font:700 21px/1 var(--aow-heading);font-variant-numeric:tabular-nums;
}
body.aow-masters-theme :is(.dynamic-bracket-connectors path,.dynamic-bracket-connectors path.winner-feed){stroke:#517b7d !important}
body.aow-masters-theme :is(.public-match-setup-summary,.public-era-game,.public-setup-value){border-radius:2px !important}
body.aow-masters-theme .public-era-game{background:rgba(37,81,89,.22) !important;border-color:#477a80 !important}
body.aow-masters-theme :is(.public-era-game strong,.public-setup-value){color:#9ad7df !important}
body.aow-masters-theme .bracket-match{border-radius:3px;background:#091b1e;border-color:#3d5d63}

/* TEAM / PARTICIPANTS / CLANS */
body.aow-masters-theme :is(.team-info-card,.team-card,.participant-card,
  .admin-team-card,.team-result,.bracket-team){border-color:var(--aow-border) !important}
body.aow-masters-theme :is(.team-info-heading,.team-identity,.team-info-leader,
  .team-result h3){font-family:var(--aow-heading);letter-spacing:.024em}
body.aow-masters-theme :is(.team-info-label,.team-info-roster-title,
  .chat-team-roster-title,.ms-library-title strong){color:var(--aow-teal) !important}
body.aow-masters-theme .bracket-team.winner{color:#a0dfb7}
body.aow-masters-theme :is(.team-info-modal,.content-modal){backdrop-filter:blur(5px)}

/* MATCH SETUP / ERA / MAP */
body.aow-masters-theme .match-setup-panel h3{font-family:var(--aow-heading);letter-spacing:.055em}
body.aow-masters-theme :is(.ms-bo-default-heading,.ms-rule-card,.ms-bo-round-card,
  .ms-bo-round-editor,.ms-full-series-inline,.ms-bulk-launch-entry){border-color:var(--aow-border) !important}
body.aow-masters-theme .ms-bo-round-editor{background:rgba(18,44,48,.38) !important}
body.aow-masters-theme .ms-bo-round-token{color:#94d3df;background:rgba(40,104,112,.21);border-color:#487e84}
body.aow-masters-theme .ms-series-rules .ms-ui-select-trigger{font-family:var(--aow-body)!important;letter-spacing:0;text-transform:none}
body.aow-masters-theme :is(.ms-ui-select-caret,.ms-history-time){color:#87b4bc !important}
body.aow-masters-theme .ms-full-series-info[data-state='active']{background:rgba(34,99,107,.18)!important;border-color:#4a8489!important}
body.aow-masters-theme .ms-full-series-info[data-state='completed']{border-color:#3f795f !important}
body.aow-masters-theme .ms-bulk-progress-track>span{background:linear-gradient(90deg,#2b7179,#6fc0c3) !important}
body.aow-masters-theme :is(.ms-bulk-progress-match.is-open,.ms-bulk-game.running){border-color:#51878c!important;background:rgba(29,69,77,.18)!important}
body.aow-masters-theme :is(.ms-bulk-match:hover,.ms-bulk-mode:has(input:checked),
  .ms-bulk-match:not(.disabled):has(input:checked)){border-color:#5ca6ae!important;background:rgba(26,91,101,.24)!important}
body.aow-masters-theme .ms-bulk-launch-details summary{color:#91d4dc}
body.aow-masters-theme .ms-bulk-chevron{color:#a0d4d5}

/* SCHEDULE / RESULT / CHAT / NOTIFICATIONS */
body.aow-masters-theme :is(.scheduler-form-section-title,.notification-channel strong,
  .notification-status-card strong,.chat-message-modal-panel h2,
  .tournament-chat-page h2){font-family:var(--aow-heading);letter-spacing:.04em}
body.aow-masters-theme :is(.notification-channel,.notification-team-option,
  .chat-message-modal-panel,.chat-message-bubble,.chat-history-revision,
  .scheduler-status-badge){border-radius:3px !important}
body.aow-masters-theme .notification-channel:has(input:checked){border-color:#5fa2a9!important;background:rgba(37,102,110,.25)!important}
body.aow-masters-theme .notification-channel input{accent-color:#3f9ba7}
body.aow-masters-theme :is(.portal-modal-icon,.portal-toast-mark){border-radius:3px;background:#15373a;border-color:#426f76;color:#a1e0e2}
body.aow-masters-theme .portal-toast{background:#0b2025;border-color:#416166;border-radius:3px}
body.aow-masters-theme .ms-bulk-dialog{background:#0b2024!important}

/* AUTHENTICATION / USER ACCOUNTS */
body.aow-masters-theme .v9-auth-card{background:linear-gradient(150deg,#10262c,#061316)!important}
body.aow-masters-theme .v9-auth-card h1{font-size:50px}
body.aow-masters-theme .v9-auth-actions .btn{font-size:18px;min-height:55px}
/* Keep provider brand recognition on the actual sign-in buttons. */
body.aow-masters-theme .v9-auth-actions .discord-login-btn{background:#435d8b!important;border-color:#6484be!important}
body.aow-masters-theme .v9-auth-actions .v9-telegram-btn{background:#206b87!important;border-color:#3c9cba!important}
body.aow-masters-theme .v9-connected{color:#a3ddb9}

/* Responsive readability, no structural bracket changes. */
@media(max-width:760px){
  body.aow-masters-theme .portal-nav{min-height:60px;padding:10px 12px;margin-bottom:12px}
  body.aow-masters-theme .portal-nav .brand{font-size:19px;letter-spacing:.045em}
  body.aow-masters-theme .hero{padding:42px 16px!important}
  body.aow-masters-theme .hero h1{font-size:clamp(34px,9vw,51px)}
  body.aow-masters-theme .eyebrow{font-size:16px}
  body.aow-masters-theme :is(.ms-bulk-progress-toggle,.ms-bulk-match){overflow-wrap:anywhere}
  body.aow-masters-theme .menu-toggle{padding:9px 11px}
}
@media(prefers-reduced-motion:reduce){
  body.aow-masters-theme :is(.btn,.ms-action,.tournament-match,.menu-toggle){transition:none !important}
}

/* PUBLIC PARTICIPANTS / ROSTER / RESULTS */
body.aow-masters-theme :is(.participants-faction,.participant-team-card,
  .participants-faction-head,.participants-count,.participants-empty,
  .team-info-section,.team-info-header,.team-info-roster,
  .result-roster,.result-card,.result-team-row,
  .admin-team-card,.team-management-card){
  border-color:#38565b !important;
  border-radius:3px !important;
}
body.aow-masters-theme :is(.participant-team-card,.participants-faction,.participants-empty,
  .team-management-card,.result-card){background:linear-gradient(150deg,rgba(13,33,37,.96),rgba(6,19,22,.94)) !important}
body.aow-masters-theme .participant-team-card:hover{border-color:#6ba7ad !important;background:#15343b !important}
body.aow-masters-theme .participants-faction-label{font-family:var(--aow-heading);color:var(--aow-teal)!important;letter-spacing:.10em}
body.aow-masters-theme .participants-faction h2,
body.aow-masters-theme .participant-team-main strong,
body.aow-masters-theme .participants-count{font-family:var(--aow-heading);letter-spacing:.035em}
body.aow-masters-theme .participants-conf{border-top:3px solid #3e8ea5 !important}
body.aow-masters-theme .participants-res{border-top:3px solid #a94f57 !important}
body.aow-masters-theme .participant-team-arrow{color:var(--aow-gold)}
body.aow-masters-theme .participants-faction-title img{filter:drop-shadow(0 0 7px rgba(107,191,200,.18))}

/* EXTENDED MODALS AND ADMIN WORKFLOWS */
body.aow-masters-theme :is(.admin-page-head,.admin-edit-review-head,.admin-editor-head,
  .admin-team-card-head,.admin-team-edit-history,.admin-result-card,
  .scheduler-form-section,.scheduler-panel,.schedule-card,
  .portal-modal-card,.content-modal .modal-panel){border-color:#36585c !important}
body.aow-masters-theme :is(.admin-page-head h2,.admin-page-head h1,
  .ms-picker-history-title,.admin-edit-review-head h3,
  .scheduler-form-section-title){font-family:var(--aow-heading);letter-spacing:.045em}
body.aow-masters-theme :is(.admin-edit-old,.admin-edit-new,.admin-edit-decision,
  .admin-team-current-row,.admin-team-edit-history,
  .scheduler-panel,.schedule-card){background:rgba(9,25,29,.71)!important;border-radius:3px!important}
body.aow-masters-theme .admin-tool:hover{border-color:#53878c !important;background:#163039 !important}
body.aow-masters-theme :is(.ms-history-row .era-history-name,
  .ms-bo-round-token,.team-era-history-name){border-radius:2px !important}
body.aow-masters-theme .ms-history-time{border-radius:2px!important}
body.aow-masters-theme .ms-bulk-progress-toggle:hover{background:rgba(54,119,128,.13)!important}
body.aow-masters-theme .ms-bulk-filter.active{border-color:#82bcc1 !important}
body.aow-masters-theme .ms-bulk-progress-overall{color:var(--aow-gold)}
body.aow-masters-theme .ms-bulk-launch-icon{border-radius:2px;color:#97d9b1;background:rgba(47,117,82,.22)}

/* CHAT MESSAGE / USER-FACING NOTIFICATION POLISH */
body.aow-masters-theme :is(.tournament-chat-card,.chat-message-bubble,
  .chat-message-modal-panel,.chat-message-attachment,
  .chat-history-message,.chat-history-revision,
  .notification-status-card,.notification-team-option,
  .notification-channel,.notification-detail-card){
  border-radius:3px !important;border-color:rgba(66,106,111,.53)!important;
}
body.aow-masters-theme :is(.tournament-chat-card,.chat-message-modal-panel,
  .chat-message-bubble,.notification-status-card){background:#0b1e23 !important}
body.aow-masters-theme :is(.chat-message-action:hover,.notification-team-option:hover){
  background:rgba(47,109,117,.21) !important;border-color:#639ea5 !important;
}
body.aow-masters-theme :is(.chat-history-revision-head time,.portal-toast strong){font-family:var(--aow-heading)}

/* Scrollbars for long admin lists and chat histories */
body.aow-masters-theme :is(.ms-bulk-list,.ms-bulk-result-list,.ms-ui-select-menu,
  .portal-menu-panel,.chat-history-content,.modal-panel){scrollbar-color:#426f74 #081619}
body.aow-masters-theme :is(.ms-bulk-list,.ms-bulk-result-list,.ms-ui-select-menu,
  .portal-menu-panel,.chat-history-content,.modal-panel)::-webkit-scrollbar{width:8px;height:8px}
body.aow-masters-theme :is(.ms-bulk-list,.ms-bulk-result-list,.ms-ui-select-menu,
  .portal-menu-panel,.chat-history-content,.modal-panel)::-webkit-scrollbar-thumb{
  background:#406e73;border:2px solid #081619;border-radius:1px;
}

/* Long tournament titles must wrap within the existing hero on desktop too. */
body.aow-masters-theme .hero h1 {
  width:100%;
  max-width:100%;
  white-space:normal !important;
  overflow-wrap:normal;
  text-wrap:balance;
  font-size:clamp(39px,5vw,68px);
}
@media(max-width:600px){
  body.aow-masters-theme .hero h1{font-size:clamp(32px,8vw,48px)}
}

/* =============================================================
   V10.1 — CHAT CONSISTENCY, MOBILE SCROLL & SHARED DROPDOWNS
   No server actions or chat message exchange logic are modified.
   ============================================================= */
/* AOW custom selects: the real select remains in the form for all JS hooks. */
body.aow-masters-theme select.aow-native-select-enhanced {
  position:absolute!important;width:1px!important;height:1px!important;
  min-width:1px!important;max-width:1px!important;padding:0!important;
  margin:0!important;opacity:0!important;pointer-events:none!important;
  clip-path:inset(50%);overflow:hidden!important;
}
body.aow-masters-theme .aow-select {
  display:inline-flex;position:relative;min-width:0;max-width:100%;width:100%;
  flex:1 1 auto;vertical-align:middle;
}
body.aow-masters-theme .aow-select-trigger {
  display:flex;align-items:center;justify-content:space-between;gap:10px;
  width:100%;min-height:44px;padding:10px 12px;
  border:1px solid #49676c;border-radius:3px;
  background:#08181c;color:#e2efeb;text-align:left;
  font:600 16px/1.25 var(--aow-body);cursor:pointer;
  box-shadow:none;transition:background .15s,border-color .15s;
}
body.aow-masters-theme .aow-select-trigger:hover,
body.aow-masters-theme .aow-select.open .aow-select-trigger{
  background:#132b31;border-color:#75b8bc;
}
body.aow-masters-theme .aow-select-trigger:focus-visible{outline:2px solid #80cbd1;outline-offset:1px}
body.aow-masters-theme .aow-select-value{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
body.aow-masters-theme .aow-select-chevron{font-size:22px;color:#85bdc1;line-height:1}
body.aow-masters-theme .aow-select.disabled .aow-select-trigger{opacity:.48;cursor:not-allowed}
body.aow-masters-theme .aow-select.invalid .aow-select-trigger{border-color:#bd6a6a}
.aow-select-global-menu[hidden]{display:none!important}
.aow-select-global-menu {
  position:fixed;z-index:2147482000;overflow:auto;overscroll-behavior:contain;
  min-width:130px;padding:5px;border:1px solid #527b80;border-radius:3px;
  background:#0a1b20;color:#e9f3f0;box-shadow:0 18px 45px rgba(0,0,0,.63);
  scrollbar-width:thin;scrollbar-color:#4d8d92 #0a1b20;
}
.aow-select-global-menu .aow-select-option{
  display:flex;width:100%;align-items:center;justify-content:space-between;gap:8px;
  min-height:34px;padding:8px 11px;text-align:left;border:1px solid transparent;
  border-radius:2px;background:transparent;color:#e1ecea;cursor:pointer;
  font:600 16px/1.25 'Roboto Condensed','Arial Narrow',Arial,sans-serif;
}
.aow-select-global-menu .aow-select-option:hover:not(:disabled),.aow-select-global-menu .aow-select-option:focus-visible{
  background:#173941;border-color:#477c84;outline:none;
}
.aow-select-global-menu .aow-select-option.selected{background:rgba(40,104,109,.4);color:#a6e3e5}
.aow-select-global-menu .aow-select-option:disabled{opacity:.42;cursor:not-allowed}
.aow-select-global-menu .aow-select-tick{color:#b4d9af;font-weight:900}
.aow-select-global-menu .aow-select-group{padding:8px 9px 4px;color:#d4b65b;font:800 16px/1.25 'Barlow Condensed',Arial,sans-serif;letter-spacing:.1em}

/* CHAT: maintain distinct conversations; match both to the teal/gold visual system. */
body.aow-masters-theme :is(.match-chat-panel,.tournament-chat-shell){
  background:linear-gradient(160deg,rgba(12,28,32,.99),rgba(5,15,18,.99))!important;
  border:1px solid #385b61!important;border-radius:4px!important;
  box-shadow:0 25px 65px rgba(0,0,0,.52)!important;
}
body.aow-masters-theme :is(.match-chat-header,.match-chat-security,.tournament-chat-notice){
  border-color:rgba(68,112,117,.45)!important;background:rgba(11,37,42,.7)!important;
}
body.aow-masters-theme :is(.match-chat-kicker,.match-chat-security,.tournament-chat-notice-text){color:#9bd0d4!important}
body.aow-masters-theme .match-chat-header h2{font-size:clamp(26px,3vw,37px);letter-spacing:.07em}
body.aow-masters-theme .match-chat-close{border-color:#49676c!important;border-radius:3px!important;background:#10262b!important;color:#e5efed!important}
body.aow-masters-theme .match-chat-empty-icon{color:#70b8be!important}
body.aow-masters-theme :is(.match-chat-empty,.tournament-chat-empty){color:#91a8aa!important}
body.aow-masters-theme .match-chat-empty strong{color:#c3d9d8!important}
body.aow-masters-theme :is(.match-chat-messages,.tournament-chat-messages){
  background:rgba(4,14,18,.38)!important;scrollbar-width:thin;
  scrollbar-color:#3f8388 #071619!important;
  -webkit-overflow-scrolling:touch;touch-action:pan-y;
}
body.aow-masters-theme :is(.match-chat-messages,.tournament-chat-messages)::-webkit-scrollbar-thumb{
  background:#437c82!important;border-color:#0a1a1e!important;box-shadow:none!important;
}
body.aow-masters-theme :is(.match-chat-bubble,.tournament-chat-bubble){
  border-radius:3px!important;border-color:#36585d!important;
  background:#10282d!important;box-shadow:none!important;
}
body.aow-masters-theme :is(.match-chat-row.mine .match-chat-bubble,
  .tournament-chat-row.mine .tournament-chat-bubble){
  background:#183740!important;border-color:#4a929c!important;
}
body.aow-masters-theme :is(.match-chat-row.confederation .match-chat-bubble,
  .tournament-chat-row.confederation .tournament-chat-bubble){
  border-color:#3b8196!important;background:#132a35!important;
}
body.aow-masters-theme :is(.match-chat-row.resistance .match-chat-bubble,
  .tournament-chat-row.resistance .tournament-chat-bubble){
  border-color:#925157!important;background:#2e1f26!important;
}
body.aow-masters-theme :is(.match-chat-row.staff .match-chat-bubble,
  .tournament-chat-row.staff .tournament-chat-bubble){
  border-color:#9b813c!important;background:#2c281c!important;
  box-shadow:inset 3px 0 0 #d4ae4a!important;
}
body.aow-masters-theme :is(.match-chat-row.staff .match-chat-meta strong,
  .tournament-chat-row.staff .tournament-chat-meta strong){color:#e4c269!important}
body.aow-masters-theme :is(.match-chat-text,.tournament-chat-text){color:#e0e9e6!important}
body.aow-masters-theme :is(.match-chat-compose,.tournament-chat-compose,
  .match-chat-compose-foot,.tournament-chat-compose-foot){
  background:#0b1b20!important;border-color:#35565d!important;
}
body.aow-masters-theme :is(.match-chat-compose textarea,.tournament-chat-compose textarea){
  background:#07171b!important;border-color:#47787e!important;color:#e8f3f1!important;
  border-radius:3px!important;
}
body.aow-masters-theme :is(.match-chat-compose textarea,.tournament-chat-compose textarea):focus{
  border-color:#8cd2d4!important;box-shadow:0 0 0 2px rgba(92,162,169,.17)!important;
}
body.aow-masters-theme :is(.match-chat-compose button,.tournament-chat-compose button,
  .tournament-chat-attach,.chat-emoji-button,.match-chat-attach-button){
  background:#123039!important;color:#d9eeeb!important;border:1px solid #4c8086!important;
  border-radius:3px!important;box-shadow:none!important;
}
body.aow-masters-theme :is(.match-chat-compose button,.tournament-chat-compose button,
  .tournament-chat-attach,.chat-emoji-button,.match-chat-attach-button):hover:not(:disabled){
  background:#24545b!important;border-color:#91d0d0!important;
}
body.aow-masters-theme :is(.chat-message-action,.chat-message-modal-panel,.chat-emoji-picker,
  .chat-mention-item,.tournament-chat-mentions,.match-chat-mentions){border-color:#446b71!important}

/* Phone chat viewport: make the history the scrollable area, keep composer visible.
   This is limited to the two chat views; regular page/bracket scrolling is untouched. */
@media(max-width:760px){
  body.aow-masters-theme.tournament-chat-view > .wrap{
    height:100dvh!important;max-height:100dvh!important;min-height:0!important;
    display:flex!important;flex-direction:column!important;overflow:hidden!important;
    position:relative!important;
  }
  body.aow-masters-theme.tournament-chat-view .portal-nav{flex:0 0 auto!important}
  body.aow-masters-theme.tournament-chat-view .tournament-chat-page{
    display:flex!important;flex-direction:column!important;flex:1 1 0!important;
    min-height:0!important;max-height:100%!important;overflow:hidden!important;
    padding-top:0!important;padding-bottom:0!important;
  }
  body.aow-masters-theme.tournament-chat-view .tournament-chat-heading{flex:0 0 auto!important}
  body.aow-masters-theme.tournament-chat-view .tournament-chat-shell{
    flex:1 1 0!important;min-height:0!important;
    height:auto!important;max-height:none!important;
    display:flex!important;flex-direction:column!important;
  }
  body.aow-masters-theme.tournament-chat-view .tournament-chat-body{
    flex:1 1 0!important;min-height:0!important;overflow:hidden!important;
  }
  body.aow-masters-theme.tournament-chat-view .tournament-chat-messages{
    min-height:0!important;overflow-y:auto!important;overflow-x:hidden!important;
    touch-action:pan-y!important;overscroll-behavior:contain;
  }
  body.aow-masters-theme.tournament-chat-view :is(.tournament-chat-compose,
    .tournament-chat-compose-foot,.tournament-chat-file-preview){flex-shrink:0}
  body.aow-masters-theme.tournament-chat-view .footer{display:none!important}
  body.aow-masters-theme.match-chat-open .match-chat-panel{
    max-height:100dvh!important;height:min(720px,100dvh)!important;
    min-height:0!important;display:flex;flex-direction:column;
  }
  body.aow-masters-theme.match-chat-open .match-chat-messages{
    flex:1 1 0!important;min-height:0!important;
    overflow-y:auto!important;touch-action:pan-y!important;
  }
}
/* Compact, game-like chat headings without distorting the existing toolbar. */
body.aow-masters-theme.tournament-chat-view .tournament-chat-heading h1{
  font-size:clamp(28px,3.3vw,44px)!important;line-height:1.05!important;
  letter-spacing:.07em!important;
}


/* =============================================================
   V10.2 — ONE CONTROL PER SELECT + CONSISTENT AOW CONTROLS
   Scope the generic popup to its own body-level menu. Respect
   existing portal/private-admin/scheduler dropdown implementations.
   ============================================================= */
/* Most portal fields already have a custom selector; their hidden sources
   must never reappear as a second visible select. */
body.aow-masters-theme :is(.portal-select,.aow-select-wrap,.ms-ui-select,.ms-custom-select) > select,
body.aow-masters-theme select:is(.portal-native-select,.ms-backed-select,[data-ms-custom-native]) {
  position:absolute!important;width:1px!important;height:1px!important;
  min-width:1px!important;max-width:1px!important;min-height:0!important;
  opacity:0!important;pointer-events:none!important;
  padding:0!important;margin:0!important;overflow:hidden!important;
  clip-path:inset(50%)!important;
}
/* Existing page-specific dropdowns get the same military teal surface. */
body.aow-masters-theme :is(.portal-select-trigger,.aow-select-wrap .aow-select-trigger,
  .ms-ui-select-trigger,.ms-custom-select-trigger,.bracket-bo-portal-select .portal-select-trigger) {
  background:#08191c!important;color:#e4f0ed!important;
  border:1px solid #456e73!important;border-radius:3px!important;
  box-shadow:none!important;
  font-family:var(--aow-heading)!important;font-weight:750!important;
  letter-spacing:.035em;
}
body.aow-masters-theme :is(.portal-select-trigger,.aow-select-wrap .aow-select-trigger,
  .ms-ui-select-trigger,.ms-custom-select-trigger):hover,
body.aow-masters-theme :is(.portal-select.open .portal-select-trigger,
  .aow-select-wrap.open .aow-select-trigger,.ms-ui-select.is-open .ms-ui-select-trigger,
  .ms-custom-select.open .ms-custom-select-trigger) {
  background:#17343b!important;border-color:#75b7bd!important;
  box-shadow:0 0 0 1px rgba(107,183,189,.18)!important;
}
body.aow-masters-theme :is(.portal-select-arrow,.aow-select-wrap .aow-select-chevron,
  .ms-ui-select-caret,.ms-custom-select-caret){color:#90c9cc!important;border-color:#90c9cc!important}
body.aow-masters-theme :is(.portal-select-menu,.aow-select-wrap .aow-select-menu,
  .ms-ui-select-menu,.ms-custom-select-options) {
  background:#0a1b20!important;color:#e4f0ed!important;
  border:1px solid #456e73!important;border-radius:3px!important;
  box-shadow:0 15px 40px rgba(0,0,0,.58)!important;
}
/* The private tournament editor defines purple styles inline. Override them
   without modifying its working keyboard and change event logic. */
body.aow-masters-theme .aow-select-wrap .aow-select-menu{position:absolute!important}
body.aow-masters-theme .aow-select-wrap .aow-select-option,
body.aow-masters-theme .portal-select .portal-select-option{
  color:#e4f0ed!important;border-radius:2px!important;
  font-family:var(--aow-body)!important;
}
body.aow-masters-theme .aow-select-wrap .aow-select-option:hover,
body.aow-masters-theme .aow-select-wrap .aow-select-option:focus-visible,
body.aow-masters-theme .portal-select .portal-select-option:hover,
body.aow-masters-theme .portal-select .portal-select-option:focus-visible{
  background:#173b42!important;color:#e9fbf7!important;
}
body.aow-masters-theme .aow-select-wrap .aow-select-option.selected,
body.aow-masters-theme .portal-select .portal-select-option.selected{
  background:rgba(53,132,140,.30)!important;color:#b2e3e4!important;
  border-color:#497d83!important;
}
/* Several account and staff forms omit type=text; restyle those as well. */
body.aow-masters-theme :is(input:not([type]),input[type='url'],input[type='tel']) {
  background:#07151a!important;color:#e8f1ef!important;
  border:1px solid #3c565c!important;border-radius:3px!important;
  box-shadow:none!important;font-family:var(--aow-body)!important;
}
body.aow-masters-theme :is(input:not([type]),input[type='url'],input[type='tel'])::placeholder{color:#8da1a3!important}

/* ================================================================
   V10.3 — MOBILE SCROLL RECOVERY + AOW MASTERS STYLE CONSISTENCY
   The pre-V10 mobile shell intentionally scrolls body > .wrap while
   html/body are overflow:hidden. V10's general .wrap position:relative
   unintentionally overrode that scroll viewport on mobile.
   No picker, bracket, scheduling or backend behavior is modified.
   ================================================================ */
@media (max-width:760px) {
  /* Page scrolling: restore the original bounded content scrollport.
     Keep the separate Tournament Chat flex viewport unchanged. */
  body.aow-masters-theme:not(.tournament-chat-view) > .wrap {
    position:absolute !important;
    top:0 !important;
    right:0 !important;
    bottom:0 !important;
    left:0 !important;
    width:100% !important;
    max-width:100% !important;
    height:100% !important;
    max-height:100dvh !important;
    margin:0 !important;
    overflow-x:hidden !important;
    overflow-y:auto !important;
    -webkit-overflow-scrolling:touch;
    overscroll-behavior-y:auto;
  }
  body.aow-masters-theme:not(.tournament-chat-view) > .wrap::-webkit-scrollbar-thumb {
    background:#487d82 !important;
  }
  /* Preserve the chat's intentionally independent scrolling region. */
  body.aow-masters-theme.tournament-chat-view > .wrap {
    position:relative !important;
  }
}

/* Bracket timeline and administration match-hold: page-local styles in
   admin_bracket.html used the old blue surfaces after the main theme. */
body.aow-masters-theme .p6e-timeline,
body.aow-masters-theme .p6f-editor-hold-panel {
  background:linear-gradient(155deg,#102227,#071519) !important;
  border:1px solid #39595e !important;
  border-radius:4px !important;
  color:var(--aow-ink) !important;
  box-shadow:none !important;
}
body.aow-masters-theme .p6e-timeline {--p6e-accent:#79c5c9;--p6e-border:#37565b;--p6e-muted:#9cb4b7}
body.aow-masters-theme .p6e-head-icon,
body.aow-masters-theme .p6e-count {
  background:rgba(37,91,98,.19) !important;
  border-color:#416c72 !important;
  color:#8ed0d2 !important;
  border-radius:3px !important;
}
body.aow-masters-theme .p6e-heading,
body.aow-masters-theme .p6f-editor-hold-title strong {
  color:#e6f1ee !important;
  font-family:var(--aow-heading) !important;
  letter-spacing:.04em;
}
body.aow-masters-theme .p6e-info strong,
body.aow-masters-theme .p6e-match-title {color:#c4e7e5 !important}
body.aow-masters-theme .p6e-empty,
body.aow-masters-theme .p6e-match,
body.aow-masters-theme .p6f-editor-hold-reason-box {
  border-color:#36565b !important;
  background:rgba(9,28,32,.76) !important;
  border-radius:3px !important;
}
body.aow-masters-theme .p6e-match:hover {border-color:#71aaa9 !important;background:#183237 !important}
body.aow-masters-theme .p6e-match-marker,
body.aow-masters-theme .p6e-connector-line {background:#629ca1 !important}
body.aow-masters-theme .p6e-time-arrow,
body.aow-masters-theme .p6f-editor-hold-kicker {color:#76c3c6 !important}
body.aow-masters-theme .p6f-editor-hold-summary {color:#b3c5c3 !important}
body.aow-masters-theme .p6f-editor-hold-panel textarea {background:#07171b !important;border-color:#456e72 !important;color:#e5f0ed !important;border-radius:3px !important}
body.aow-masters-theme .p6e-list {scrollbar-color:#487d82 #081619 !important}

/* One AOW look for the round filters across bracket, scheduler and Full
   Series launcher. Gold means ACTIVE ROUND; teal is for ordinary actions. */
body.aow-masters-theme :is(.brn-round-navigator,.brn-tab,.sat-filter,
  #bulk-round-filters .ms-bulk-filter,#bulk-progress-filters .ms-bulk-filter) {
  background:#0b1c20 !important;
  border-color:#406368 !important;
  color:#c8dad9 !important;
  border-radius:3px !important;
  box-shadow:none !important;
  font-family:var(--aow-heading) !important;
  font-weight:750 !important;
  letter-spacing:.055em;
}
body.aow-masters-theme .brn-round-navigator {background:linear-gradient(135deg,#102429,#081518)!important}
body.aow-masters-theme :is(.brn-tab,.sat-filter,.ms-bulk-filter):hover:not(:disabled) {
  border-color:#7ab7b8 !important;
  color:#fff !important;
  background:#16353a !important;
}
body.aow-masters-theme :is(.brn-tab.active,.sat-filter.active,
  .sat-filter[aria-pressed='true'],#bulk-round-filters .ms-bulk-filter.active,
  #bulk-progress-filters .ms-bulk-filter.active) {
  color:#f3d891 !important;
  background:rgba(183,140,45,.19) !important;
  border-color:#bd9a4d !important;
  box-shadow:inset 0 -2px 0 #d6b355 !important;
}
body.aow-masters-theme :is(.brn-current,.brn-round-number){color:#f1d18a!important}
body.aow-masters-theme .brn-caption{color:#b7cccc!important}

/* Bulk matcher: preserve green for eligible, red for stopped and amber
   for warnings. Only selection controls and panel chrome are restyled. */
body.aow-masters-theme .ms-bulk-mode:has(input:checked) {
  background:rgba(25,76,80,.26) !important;
  border-color:#5c9da3 !important;
}
body.aow-masters-theme .ms-bulk-mode input,
body.aow-masters-theme .ms-bulk-match-label input {accent-color:#4ca7af !important}
body.aow-masters-theme .ms-bulk-mode b{color:#e8f1ef !important}
body.aow-masters-theme .ms-bulk-progress-match,
body.aow-masters-theme .ms-bulk-match {border-radius:3px !important}
body.aow-masters-theme .ms-bulk-progress-totals>div {background:#0b1c21!important}

/* Map selection cards, BO accordions and round overrides keep original
   geometry while removing purple borders and roundness. */
body.aow-masters-theme :is(.ms-selection-card,.ms-rule-card,.ms-bo-round-card,
  .ms-bo-round-overrides,.ms-bo-round-editor) {
  border-color:#37565c !important;
  border-radius:3px !important;
  box-shadow:none !important;
}
body.aow-masters-theme .ms-bo-default-heading {
  background:rgba(40,92,97,.14) !important;
  border-color:#36585d !important;
}
body.aow-masters-theme .ms-bo-default-heading strong{color:#9bd4d6 !important}
body.aow-masters-theme .ms-bo-round-editor{background:#10282b!important}
body.aow-masters-theme .ms-bo-round-card-main>strong {color:#f1d28a !important}

/* Registration, scheduling and native date/time controls used a mixture
   of purple focus states. Keep the browser date picker functional. */
body.aow-masters-theme :is(input[type='date'],input[type='datetime-local'],input[type='time']) {
  color-scheme:dark;
  background:#08191d !important;
  border-color:#486b6f !important;
  color:#e4efec !important;
}
body.aow-masters-theme :is(input[type='date'],input[type='datetime-local'],input[type='time']):focus {
  border-color:#83bdbe !important;
  box-shadow:0 0 0 2px rgba(88,172,178,.2)!important;
}
body.aow-masters-theme :is(.scheduler-form-section,.scheduler-panel,.sat-panel,
  .sat-card,.sat-match-card,.sat-row) {border-color:#38595e!important;border-radius:3px!important}
body.aow-masters-theme :is(.sat-round-label,.scheduler-form-section-title){color:#84c9cf!important}

/* Explicitly preserve warning/error/disabled semantics on switches and
   controls, while replacing purple focus rings on legacy local components. */
body.aow-masters-theme :is(.aow-select-trigger,.portal-select-trigger,
  .ms-ui-select-trigger,.ms-custom-select-trigger):focus-visible {
  outline:2px solid #76c2c6 !important;
  outline-offset:1px !important;
}
body.aow-masters-theme :is(.ms-bulk-mode,.ms-bulk-match,.brn-tab,
  .sat-filter):focus-within{outline-color:#76c2c6!important}

/* Match editor's own BO menu is not the shared portal dropdown. Apply the
   same AOW controls, without modifying its menu open/selection handlers. */
body.aow-masters-theme .bracket-format-trigger {
  border:1px solid #456e73 !important;
  border-radius:3px !important;
  background:#0a1a1f !important;
  box-shadow:none !important;
  color:#e5efed !important;
}
body.aow-masters-theme .bracket-format-trigger:hover,
body.aow-masters-theme .bracket-format-picker.open .bracket-format-trigger {
  border-color:#79b6bc !important;
  background:#17343b !important;
  box-shadow:0 0 0 1px rgba(112,178,186,.14)!important;
}
body.aow-masters-theme .bracket-format-trigger strong,
body.aow-masters-theme .bracket-format-option strong {color:#e3edeb !important}
body.aow-masters-theme .bracket-format-trigger small,
body.aow-masters-theme .bracket-format-option small{color:#8ea9ae !important}
body.aow-masters-theme .bracket-format-menu {
  background:#091a1e !important;
  border:1px solid #4b767b !important;
  border-radius:3px !important;
  box-shadow:0 17px 38px rgba(0,0,0,.5) !important;
}
body.aow-masters-theme .bracket-format-option {border-radius:2px !important;color:#e4efed!important}
body.aow-masters-theme .bracket-format-option:hover,
body.aow-masters-theme .bracket-format-option.selected {
  background:rgba(49,117,126,.26) !important;
}
body.aow-masters-theme .format-chevron,
body.aow-masters-theme .format-check{color:#86c6c8 !important}


/* V11.22 — use the wide bracket shell across the full portal on desktop.
   This aligns the shared top bar / page frame with the bracket layout,
   while preserving mobile behavior and Tournament Chat's dedicated viewport. */
@media (min-width:761px) {
  body.aow-masters-theme:not(.tournament-chat-view) > .wrap {
    width:min(1800px,calc(100% - 48px)) !important;
    max-width:none !important;
    margin-inline:auto !important;
  }
}
