/* Teamilo complete design neon-graphite | bundle-v4 | light + dark */
/* source: /static/app.css */
:root{font-size:18px;font-family:'DM Sans',system-ui,sans-serif;color:var(--tm-ink);background:var(--tm-surface);font-synthesis:none}*{box-sizing:border-box}body{margin:0}button,input,textarea,select{font:inherit}button{cursor:pointer}button:disabled{opacity:.55;cursor:not-allowed}h1,h2,h3,p{margin:0}h1,h2,h3,.brand{font-family:Outfit,'DM Sans',sans-serif}h1{font-size:32px;letter-spacing:-1px}h2{font-size:24px;letter-spacing:-.5px}h3{font-size:19px}small,.muted{color:var(--tm-muted)}.app{min-height:100vh}.frame{max-width:1180px;margin:auto;display:grid;grid-template-columns:250px minmax(0,1fr);min-height:100vh}.sidebar{background:var(--tm-ink);color:var(--tm-surface);padding:30px 20px;display:flex;flex-direction:column;gap:10px;position:sticky;top:0;height:100vh}.brand{font-size:25px;font-weight:800;letter-spacing:-.8px;margin:0 0 33px 7px}.brand b{color:var(--tm-ice)}.sidebar button{background:transparent;color:var(--tm-ice);border:0;text-align:left;padding:14px;border-radius:12px;font-weight:700}.sidebar button.active,.sidebar button:hover{background:var(--tm-blue);color:var(--tm-surface)}.sidebar .foot{margin-top:auto;color:var(--tm-ice);font-size:14px;padding:10px}.main{padding:35px 46px 120px;min-width:0}.top{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:30px}.eyebrow{font-size:14px;font-weight:800;color:var(--tm-blue);letter-spacing:1.6px;text-transform:uppercase}.team-pill{background:var(--tm-surface);border:1px solid var(--tm-line);padding:11px 13px;border-radius:15px;color:var(--tm-blue);font-weight:800;max-width:260px}.hero{background:var(--tm-ink);color:var(--tm-surface);border-radius:24px;padding:30px;position:relative;overflow:hidden;display:grid;grid-template-columns:1fr auto;gap:20px;margin-bottom:25px}.hero:after{content:'';position:absolute;width:260px;height:260px;border:50px solid var(--tm-line);border-radius:50%;right:-110px;top:-150px;pointer-events:none}.hero h1{max-width:470px;line-height:1.1;margin:8px 0}.hero p{color:var(--tm-ice);max-width:440px;font-size:16px}.hero-mark{font-size:77px;opacity:.8;align-self:center;z-index:1}.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin-bottom:25px}.stat{background:var(--tm-surface);padding:20px;border:1px solid var(--tm-line);border-radius:18px}.stat .num{font-family:Outfit;font-weight:800;font-size:31px;color:var(--tm-blue)}.sectionhead{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:26px 0 16px}.sectionhead small{display:block;margin-top:4px}.grid2{display:grid;grid-template-columns:1.3fr 1fr;gap:17px}.card{background:var(--tm-surface);border:1px solid var(--tm-line);border-radius:20px;padding:20px;margin-bottom:13px;box-shadow:0 2px 8px rgba(0,0,0,0.0235)}.cardheader{display:flex;align-items:center;gap:13px}.datebox{min-width:58px;background:var(--tm-ice);color:var(--tm-blue);border-radius:13px;padding:9px;text-align:center}.datebox strong{font:800 26px Outfit;display:block}.datebox small{font-weight:800;color:var(--tm-blue)}.grow{flex:1;min-width:0}.sub{font-size:15px;color:var(--tm-muted);margin-top:4px}.pill{border-radius:40px;background:var(--tm-surface);color:var(--tm-blue);font-size:13px;font-weight:800;padding:6px 10px;white-space:nowrap}.pill.match{background:var(--tm-ice);color:var(--tm-blue)}.btn{border:0;background:var(--tm-blue);color:var(--tm-surface);padding:12px 17px;border-radius:12px;font-weight:800}.btn:hover{background:var(--tm-blue)}.btn.light{background:var(--tm-surface);color:var(--tm-blue)}.btn.outline{border:1px solid var(--tm-line);background:var(--tm-surface);color:var(--tm-blue)}.btn.small{padding:8px 12px;font-size:14px}.btn.accent{background:var(--tm-ice);color:var(--tm-blue)}.actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:16px}.choices{display:flex;gap:7px;margin-top:14px;flex-wrap:wrap}.choice{border:1px solid var(--tm-line);border-radius:9px;background:var(--tm-surface);color:var(--tm-muted);padding:8px 12px;font-size:14px;font-weight:800}.choice.selected.yes{background:var(--tm-ice);border-color:var(--tm-line);color:var(--tm-blue)}.choice.selected.no{background:var(--tm-ice);border-color:var(--tm-coral);color:var(--tm-ink)}.choice.selected.maybe{background:var(--tm-ice);border-color:var(--tm-coral);color:var(--tm-ink)}.list{display:grid;gap:10px}.person{display:flex;align-items:center;gap:12px;padding:10px 0;border-bottom:1px solid var(--tm-line)}.avatar{width:42px;height:42px;background:var(--tm-ice);color:var(--tm-blue);border-radius:50%;display:grid;place-items:center;font-weight:800;flex-shrink:0}.chat-layout{display:grid;grid-template-columns:230px 1fr;gap:15px}.channel{display:block;width:100%;background:var(--tm-surface);border:1px solid var(--tm-line);text-align:left;padding:14px;border-radius:13px;margin-bottom:8px;color:var(--tm-muted);font-weight:800}.channel.active{background:var(--tm-ice);color:var(--tm-blue);border-color:var(--tm-line)}.chatpanel{height:min(65vh,640px);min-height:420px;background:var(--tm-surface);border:1px solid var(--tm-line);border-radius:19px;display:flex;flex-direction:column;overflow:hidden}.chat-title{padding:16px 20px;border-bottom:1px solid var(--tm-line);font-weight:800}.chatlog{padding:18px;overflow-y:auto;flex:1;display:flex;flex-direction:column;gap:10px}.bubble{max-width:82%;background:var(--tm-surface);border-radius:13px 13px 13px 3px;padding:11px 15px;align-self:flex-start;font-size:16px;white-space:pre-wrap;overflow-wrap:anywhere}.bubble.mine{background:var(--tm-ice);border-radius:13px 13px 3px 13px;align-self:flex-end}.bubble.system{background:var(--tm-ice);align-self:center;border-radius:12px;text-align:center}.bubble .who{font-size:13px;font-weight:800;color:var(--tm-blue);margin-bottom:5px}.chatcompose{display:flex;gap:8px;padding:12px;border-top:1px solid var(--tm-line)}.chatcompose input{flex:1;min-width:0}.field,input,select,textarea{border:1px solid var(--tm-line);border-radius:11px;background:var(--tm-surface);padding:12px 13px;color:var(--tm-blue);width:100%;outline:none}input:focus,select:focus,textarea:focus{border-color:var(--tm-blue);box-shadow:0 0 0 3px rgba(0,0,0,0.1686)}.fieldwrap{display:grid;gap:6px;margin-bottom:14px}.fieldwrap label{font-size:15px;font-weight:800;color:var(--tm-blue)}.modalback{position:fixed;inset:0;background:color-mix(in srgb,var(--tm-ink) 65.8800%,transparent);display:grid;place-items:center;z-index:50;padding:20px}.modal{background:var(--tm-surface);border-radius:22px;width:min(100%,500px);padding:26px;max-height:90vh;overflow:auto;box-shadow:0 30px 60px rgba(0,0,0,0.1333)}.modal h2{margin-bottom:18px}.modal .row{display:flex;gap:10px;justify-content:flex-end;margin-top:14px}.authwrap{display:grid;place-items:center;min-height:100vh;padding:24px;background:radial-gradient(circle at 70% 20%,var(--tm-blue),var(--tm-ink) 65%)}.authcard{background:var(--tm-surface);width:min(100%,440px);padding:34px;border-radius:26px;box-shadow:0 30px 100px rgba(0,0,0,0.2667)}.authcard .brand{color:var(--tm-blue);margin-bottom:20px}.authcard p{color:var(--tm-muted);font-size:16px;margin:10px 0 25px}.notice{padding:15px;background:var(--tm-canvas);border-radius:12px;border:1px solid var(--tm-line);margin-bottom:10px}.toast{position:fixed;bottom:91px;left:50%;transform:translateX(-50%);z-index:80;background:var(--tm-ink);color:var(--tm-surface);padding:12px 21px;border-radius:13px;box-shadow:0 15px 30px rgba(0,0,0,0.2000);max-width:90vw}.empty{text-align:center;padding:35px;color:var(--tm-muted)}.bottom{display:none}.testtag{font-size:12px;letter-spacing:1px;font-weight:800;background:var(--tm-ice);color:var(--tm-blue);padding:6px 9px;border-radius:8px;display:inline-block}.soft{background:var(--tm-surface);padding:14px;border-radius:14px}.right{text-align:right}.link{border:0;background:none;text-decoration:underline;color:var(--tm-blue);font-weight:700;padding:8px}.div{height:1px;background:var(--tm-canvas);margin:16px 0}@media(max-width:780px){.frame{display:block}.sidebar{display:none}.main{padding:23px 17px 110px}.hero{padding:24px;grid-template-columns:1fr}.hero-mark{display:none}.hero h1{font-size:29px}.stats{gap:8px}.stat{padding:13px}.stat .num{font-size:24px}.grid2,.chat-layout{grid-template-columns:1fr}.channel-list{display:flex;overflow-x:auto;gap:7px}.channel{width:auto;white-space:nowrap;font-size:14px}.chatpanel{height:55vh}.bottom{display:flex;position:fixed;bottom:0;left:0;right:0;background:var(--tm-surface);border-top:1px solid var(--tm-line);padding:7px 3px max(7px,env(safe-area-inset-bottom));justify-content:space-around;z-index:30;box-shadow:0 -5px 20px rgba(0,0,0,0.0667)}.bottom button{background:transparent;border:0;color:var(--tm-muted);display:flex;flex-direction:column;align-items:center;gap:3px;font-size:12px;font-weight:800;padding:7px 4px;min-width:55px}.bottom button.active{color:var(--tm-blue)}.bottom button span{font-size:25px}.top{margin-bottom:22px}.team-pill{max-width:172px;font-size:14px}.sectionhead h2{font-size:21px}}

/* Teamilo: role editor and revocable invitation view. */
.member-actions{display:flex;gap:7px;flex-wrap:wrap;max-width:230px}.member-actions select{width:auto;max-width:145px;font-size:14px;padding:8px}.invite-row{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px 0;border-bottom:1px solid var(--tm-line);overflow-wrap:anywhere}.invite-row span{font-size:14px}@media(max-width:520px){.person{flex-wrap:wrap}.member-actions{width:100%;max-width:none;margin-left:50px}.member-actions select{flex:1;max-width:none}}

/* Language controls: mobile and desktop. */
.top-controls{display:flex;align-items:center;gap:10px;flex-wrap:wrap;justify-content:flex-end}.auth-tools{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap}.lang-select{font:inherit;font-size:15px;max-width:220px;min-height:36px;padding:6px 9px;border:1px solid var(--tm-line);border-radius:9px;color:var(--tm-blue);background:var(--tm-surface)}.language-setting{display:flex;align-items:flex-start;flex-direction:column;gap:10px;padding:12px 0}.language-setting .lang-select{max-width:100%;width:260px}@media(max-width:620px){.top-controls{gap:6px}.top-controls .lang-select{max-width:115px;font-size:14px}.top-controls .team-pill{max-width:125px;font-size:14px}.auth-tools .lang-select{max-width:180px}}

/* Full event snapshot displayed directly in the event chat. */
.bubble.event-summary{width:min(100%,530px);max-width:100%;align-self:center;text-align:left;background:var(--tm-ice);border:1px solid var(--tm-line);border-left:4px solid var(--tm-blue);padding:15px 17px;white-space:normal}
.event-summary-eyebrow{font-size:13px;font-weight:800;text-transform:uppercase;letter-spacing:.7px;color:var(--tm-blue);margin:10px 0 6px}
.event-summary-title{font-size:19px;font-weight:800;color:var(--tm-blue);overflow-wrap:anywhere;margin-bottom:12px}
.event-summary dl{display:grid;gap:9px;margin:0}
.event-summary-row{display:grid;grid-template-columns:minmax(90px,31%) minmax(0,1fr);gap:8px;border-top:1px solid var(--tm-line);padding-top:8px}
.event-summary dt{color:var(--tm-blue);font-size:14px;font-weight:750}
.event-summary dd{margin:0;color:var(--tm-blue);font-weight:600;white-space:pre-wrap;overflow-wrap:anywhere}
@media(max-width:480px){.bubble.event-summary{padding:12px}.event-summary-row{grid-template-columns:minmax(74px,34%) minmax(0,1fr)}}

/* Teamilo: private parent-player assignment and account display names */
.player-entry{border-bottom:1px solid var(--tm-line);padding:6px 0 12px}
.player-entry:last-of-type{border-bottom:0}
.guardian-controls{padding:4px 0 8px 54px}
.guardian-chip{display:inline-flex;gap:5px;align-items:center;background:var(--tm-canvas);padding:5px 8px;border-radius:10px;margin:3px 3px 3px 0;font-size:14px;color:var(--tm-blue)}
.guardian-chip button{border:0;background:transparent;color:var(--tm-ink);font-weight:800;padding:1px 4px;cursor:pointer}
.guardian-form{display:flex;gap:8px;margin:9px 0 4px;align-items:center;flex-wrap:wrap}
.guardian-form select{width: min(100%,250px);min-width:0;flex:1 1 170px;font-size:15px}
.guardian-form button{flex:0 0 auto}
.display-name-form{margin-top:18px;max-width:450px;padding:16px;border-radius:14px;background:var(--tm-surface)}
.display-name-form .sub{margin-top:10px}
.rsvp-hint{margin-top:12px;font-size:15px}
@media(max-width:520px){.guardian-controls{padding-left:0}.guardian-form{flex-direction:column;align-items:stretch}.guardian-form select{width:100%;flex:auto}}

/* Teamilo: coaching roster status and manual up/down ordering. */
.player-entry.inactive{opacity:.75;background:var(--tm-surface);border-radius:12px}
.player-controls{display:flex;flex-wrap:wrap;align-items:center;gap:7px;margin-left:auto}
.player-state{display:inline-block;padding:5px 8px;border-radius:10px;font-size:13px;font-weight:700}
.player-state.on{color:var(--tm-blue);background:var(--tm-ice)}
.player-state.off{color:var(--tm-ink);background:var(--tm-ice)}
.player-arrows{display:inline-flex;align-items:center;gap:4px}
.player-arrows button{min-width:35px;min-height:36px;font-size:22px;font-weight:700;background:var(--tm-canvas);border:1px solid var(--tm-line);border-radius:8px;color:var(--tm-blue);cursor:pointer}
.player-arrows button:disabled{opacity:.35;cursor:not-allowed}
@media(max-width:580px){.player-controls{width:100%;margin-left:0;justify-content:flex-end}.player-entry>.person{gap:8px}.player-arrows button{min-width:38px;min-height:40px}}

/* Teamilo player invitations and guardian requests */
.player-invite{margin:10px 0 8px 0;padding:12px;border:1px solid var(--line,var(--tm-line));border-radius:12px;background:color-mix(in srgb,var(--tm-surface) 50.0000%,transparent)}
.player-invite summary{font-weight:650;cursor:pointer;user-select:none;list-style-position:inside}
.invite-link-box{display:flex;flex-direction:column;gap:9px;margin-top:10px;min-width:0}
.invite-link-box input{width:100%;max-width:100%;min-width:0;box-sizing:border-box;overflow:hidden;text-overflow:ellipsis}
.claim-area{border-top:1px solid var(--tm-line);margin-top:15px;padding-top:12px}
.claim-area form{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-top:10px}
.claim-area select{min-width:155px;max-width:100%;flex:1}
@media(max-width:600px){.claim-area form{flex-direction:column;align-items:stretch}.claim-area select{width:100%}.player-invite{margin-left:0;margin-right:0}}

/* v0.7.8: Adult player role is opt-in; checkbox has a reliable mobile tap target. */
.adult-check{display:flex;align-items:center;gap:10px;margin-top:13px;line-height:1.45;font-size:15px}
.adult-check input{width:18px;height:18px;flex:0 0 18px}

/* Teamilo 0.8.1: actionable event and notice cards. */
.event-preview{display:block;width:100%;text-align:left;color:inherit;font:inherit;cursor:pointer;transition:box-shadow .15s,border-color .15s;background:var(--tm-surface)}
.event-preview:hover,.event-preview:focus-visible{border-color:var(--tm-blue);box-shadow:0 4px 16px rgba(0,0,0,0.1255);outline:none}
.event-open-hint{margin-top:12px;color:var(--tm-blue);font-weight:800;font-size:14px}
.event-target{border-color:var(--tm-blue);box-shadow:0 0 0 3px rgba(0,0,0,0.3333)}
.notice-link{display:block;width:100%;text-align:left;color:inherit;cursor:pointer;font:inherit;transition:opacity .18s ease,border-color .18s ease}
.notice-link:hover,.notice-link:focus-visible{border-color:var(--tm-line);outline:2px solid var(--tm-blue);outline-offset:2px}
.notice-read{opacity:.50}
.notice-read:hover,.notice-read:focus-visible{opacity:.75}
.notice-hint{display:block;margin-top:10px;font-size:14px;font-weight:800;color:var(--tm-blue)}

/* Teamilo 0.8.2: clearly labelled fictional sponsorship creative and full-width chat CTA. */
.home-demo-ad{position:relative;display:flex;align-items:center;min-height:207px;margin-bottom:12px;padding:26px 31px;border-radius:23px;background:linear-gradient(118deg,var(--tm-ink) 0%,var(--tm-ink) 64%,var(--tm-ink) 100%);color:var(--tm-surface);text-decoration:none;overflow:hidden;isolation:isolate;transition:transform .15s ease,box-shadow .15s ease}
.home-demo-ad::before{content:'';position:absolute;width:290px;height:290px;border:54px solid var(--tm-line);border-radius:50%;right:-96px;top:-112px;pointer-events:none;z-index:-1}
.home-demo-ad:hover{transform:translateY(-1px);box-shadow:0 7px 24px rgba(0,0,0,0.1882)}
.home-demo-ad:focus-visible{outline:3px solid var(--tm-blue);outline-offset:3px}
.home-demo-ad-content{display:flex;flex-direction:column;align-items:flex-start;gap:7px;max-width:calc(100% - 38px)}
.home-demo-ad-label{padding:4px 8px;border:1px solid var(--tm-line);border-radius:7px;font-size:12px;font-weight:800;letter-spacing:.8px;color:var(--tm-surface)}
.home-demo-ad-brand{font-family:Outfit,'DM Sans',sans-serif;font-size:43px;letter-spacing:-1.5px;font-weight:900;line-height:1.05;margin-top:2px}
.home-demo-ad-headline{font-size:21px;font-weight:800;line-height:1.3}
.home-demo-ad-copy{font-size:16px;line-height:1.45;color:var(--tm-ice)}
.home-demo-ad-disclosure{font-size:12px;color:var(--tm-ice);margin-top:4px}
.home-demo-ad-arrow{position:absolute;right:24px;top:22px;font-size:26px;line-height:1}
.home-chat-cta{display:flex;align-items:center;width:100%;min-height:94px;padding:19px 23px;margin:0 0 25px;border:1px solid var(--tm-line);border-radius:18px;background:var(--tm-ice);color:var(--tm-blue);cursor:pointer;text-align:left;gap:17px;transition:background .15s ease,box-shadow .15s ease}
.home-chat-cta:hover{background:var(--tm-ice);box-shadow:0 5px 17px rgba(0,0,0,0.0902)}
.home-chat-cta:focus-visible{outline:3px solid var(--tm-blue);outline-offset:3px}
.home-chat-cta-icon{display:grid;place-items:center;width:50px;height:50px;flex:0 0 50px;background:var(--tm-ice);color:var(--tm-blue);border-radius:14px;font-size:27px}
.home-chat-cta-content{display:flex;flex:1;flex-direction:column;gap:4px;min-width:0}
.home-chat-cta-content strong{font-size:20px;line-height:1.25}
.home-chat-cta-content>span{font-size:16px;line-height:1.4;color:var(--tm-blue)}
.home-chat-cta-arrow{font-size:25px;line-height:1;flex:0 0 auto}
@media(max-width:780px){.home-demo-ad{padding:23px;min-height:184px}.home-demo-ad-brand{font-size:36px}.home-demo-ad-headline{font-size:19px}.home-chat-cta{padding:17px 14px;gap:11px}.home-chat-cta-icon{width:42px;height:42px;flex-basis:42px;font-size:22px}.home-chat-cta-content strong{font-size:18px}.home-chat-cta-content>span{font-size:15px}}
@media(max-width:380px){.home-demo-ad{padding:19px}.home-demo-ad-arrow{right:15px;top:14px}.home-chat-cta-icon{display:none}.home-chat-cta-arrow{font-size:19px}}


/* Teamilo 0.8.10: responsive player and team-member cards.
   Controls occupy their own row instead of competing with long names and emails. */
.team-roster-layout{grid-template-columns:minmax(0,1.3fr) minmax(0,1fr)}
.team-roster-layout>section,
.team-roster-layout .card,
.team-roster-layout .player-entry,
.team-roster-layout .guardian-controls,
.team-roster-layout .player-invite{min-width:0;max-width:100%}
.team-roster-layout .player-entry>.person,
.team-roster-layout .card>.person{
 display:grid;
 grid-template-columns:42px minmax(0,1fr);
 grid-template-rows:auto auto;
 column-gap:12px;
 row-gap:9px;
 align-items:start;
}
.team-roster-layout .player-entry>.person>.avatar,
.team-roster-layout .card>.person>.avatar{grid-column:1;grid-row:1}
.team-roster-layout .player-entry>.person>.grow,
.team-roster-layout .card>.person>.grow{
 grid-column:2;
 grid-row:1;
 min-width:0;
 max-width:100%;
 overflow-wrap:anywhere;
 line-height:1.4;
}
.team-roster-layout .person>.grow strong,
.team-roster-layout .person>.grow .sub{
 display:block;
 max-width:100%;
 overflow-wrap:anywhere;
 word-break:normal;
}
.team-roster-layout .card>.person>.member-actions,
.team-roster-layout .player-entry>.person>.player-controls,
.team-roster-layout .player-entry>.person>.player-state{
 grid-column:2;
 grid-row:2;
 margin:0;
 max-width:100%;
 min-width:0;
 width:100%;
 justify-content:flex-start;
}
.team-roster-layout .member-actions,
.team-roster-layout .player-controls,
.team-roster-layout .guardian-form{
 display:flex;
 gap:8px;
 flex-wrap:wrap;
 align-items:center;
 min-width:0;
}
.team-roster-layout .member-actions select,
.team-roster-layout .guardian-form select{
 flex:1 1 130px;
 width:auto;
 min-width:0;
 max-width:100%;
}
.team-roster-layout .member-actions>.btn,
.team-roster-layout .player-controls>.btn,
.team-roster-layout .guardian-form>.btn{
 max-width:100%;
 min-width:0;
 white-space:normal;
 overflow-wrap:anywhere;
 text-align:center;
}
.team-roster-layout .player-arrows{display:inline-flex;flex-shrink:0;gap:5px}
.team-roster-layout .player-invite select,
.team-roster-layout .player-invite input{min-width:0;max-width:100%}
@media (min-width:781px) and (max-width:1150px){
 .team-roster-layout{grid-template-columns:minmax(0,1fr)}
}
@media (max-width:520px){
 .team-roster-layout .guardian-controls{padding-left:0}
 .team-roster-layout .member-actions{margin:0}
 .team-roster-layout .member-actions select{flex:1 1 100%}
 .team-roster-layout .guardian-form{align-items:stretch}
 .team-roster-layout .guardian-form select,
 .team-roster-layout .guardian-form>.btn{width:100%;flex:1 1 100%}
}
@media (max-width:780px){
 .team-roster-layout{grid-template-columns:minmax(0,1fr)}
}


/* 0.8.13: compact player list; expandable account links; readable member assignments. */
.team-roster-layout .player-entry{padding:8px 0 10px}
.team-roster-layout .player-entry>.person{row-gap:5px}
.team-roster-layout .player-entry>.person .avatar{width:38px;height:38px}
.team-roster-layout .player-entry>.person .grow{line-height:1.3}
.team-roster-layout .player-entry>.person .grow .sub{margin-top:3px}
.team-roster-layout .player-links,
.team-roster-layout .player-invite{margin:6px 0 0;padding:8px 11px;background:var(--tm-surface);border:1px solid var(--tm-line);border-radius:10px;min-width:0}
.team-roster-layout .player-links>summary,
.team-roster-layout .player-invite>summary{font-size:15px;font-weight:700;cursor:pointer;overflow-wrap:anywhere;list-style-position:inside;padding:2px 0}
.team-roster-layout .player-links[open],
.team-roster-layout .player-invite[open]{background:var(--tm-surface)}
.team-roster-layout .player-links .guardian-controls{padding:10px 0 2px}
.team-roster-layout .member-role-line{display:flex!important;gap:6px;flex-wrap:wrap;align-items:baseline;line-height:1.5}
.team-roster-layout .member-player-links{display:inline-flex;gap:5px;align-items:baseline;flex-wrap:wrap;min-width:0;max-width:100%;overflow-wrap:anywhere;color:var(--tm-blue);font-weight:650}
.team-roster-layout .member-player-arrow{font-weight:900;color:var(--tm-blue);margin:0 2px}
@media(max-width:520px){
 .team-roster-layout .player-links,.team-roster-layout .player-invite{padding:8px}
 .team-roster-layout .player-entry>.person .grow{min-width:0}
 .team-roster-layout .member-role-line{gap:5px}
}

/* Teamilo 0.8.14: all team members see attendance; only authorised accounts can reply. */
.attendance-heading{font-size:16px;font-weight:800;color:var(--tm-blue);margin-bottom:4px}
.attendance-hint{margin:0 0 12px}
.attendance-person{min-width:0;flex-wrap:wrap;column-gap:12px}
.attendance-person .choices{margin:0 0 0 auto;max-width:100%;flex-wrap:nowrap}
.attendance-person .choice{min-width:37px;min-height:38px}
.attendance-person .choice:disabled{cursor:not-allowed;opacity:.7}
.attendance-person .choice.selected:disabled{opacity:1}
@media(max-width:480px){.attendance-person .choices{width:100%;justify-content:flex-end;margin:4px 0 0}.attendance-person .choice{flex:0 0 auto}}

/* RSVP private reason, shown only to coach/assistant/helper via role-scoped API. */
.attendance-reason{font-size:14px;line-height:1.5;margin-top:5px;overflow-wrap:anywhere;white-space:pre-wrap;color:var(--tm-blue)}
.attendance-reason strong{font-weight:800;color:var(--tm-blue)}
#rsvp-reason-form textarea{width:100%;max-width:100%;min-height:96px;resize:vertical;box-sizing:border-box}

/* Teamilo 0.8.17: chat polls */
.poll-create{margin:12px 16px;padding:13px;border-radius:13px;background:var(--tm-surface);border:1px solid var(--tm-line)}
.poll-create summary{cursor:pointer;font-weight:800;list-style:revert}
.poll-create form{display:grid;gap:9px;margin-top:14px}
.poll-create input{width:100%;min-width:0}
.poll-option-editor{display:grid;gap:5px;min-width:0}
.poll-option-input{display:flex;gap:8px;align-items:center}.poll-option-input input{flex:1}
.poll-card{min-width:0;max-width:min(100%,580px);width:100%;text-align:left;background:var(--tm-surface);border:1px solid var(--tm-line)}
.poll-card h3{margin:8px 0 15px;font-size:20px;overflow-wrap:anywhere;line-height:1.35}
.poll-eyebrow{font-size:12px;font-weight:800;letter-spacing:.3px;color:var(--tm-blue);margin:8px 0}
.poll-vote-form{display:grid;gap:10px}.poll-options{display:grid;gap:9px}
.poll-option{display:grid;gap:4px;padding:9px 11px;border:1px solid var(--tm-line);border-radius:9px;cursor:pointer;background:var(--tm-surface);min-width:0}
.poll-option.chosen{border-color:var(--tm-blue);background:var(--tm-canvas)}
.poll-option-head{display:flex;gap:9px;align-items:center;min-width:0}.poll-option-head input{flex:0 0 auto;width:auto}.poll-option-head span{flex:1;min-width:0;overflow-wrap:anywhere}
.poll-option-head strong{font-size:13px;flex:0 0 auto}
.poll-option small{font-size:12px;color:var(--tm-muted)}.poll-result-track{height:5px;border-radius:10px;background:var(--tm-canvas);overflow:hidden}
.poll-result-track span{display:block;height:100%;background:var(--tm-blue);transition:width .25s}
.poll-card .actions{display:flex;flex-wrap:wrap;gap:8px}
@media(max-width:530px){.poll-create{margin:10px 8px}.poll-card{padding:14px}.poll-card h3{font-size:18px}}

/* Teamilo 0.8.19: separate poll channel and persistent poll selection. */
.poll-chooser{padding:12px 18px 0;min-width:0}
.poll-chooser label{display:block;font-size:14px;font-weight:800;color:var(--tm-muted);margin-bottom:7px}
.poll-chooser select{max-width:100%;min-width:0;overflow-wrap:anywhere}
.poll-board{min-height:0}
.poll-board .poll-card{align-self:stretch;max-width:100%;margin:0}
.poll-delete-actions{border-top:1px solid var(--tm-line);padding-top:12px;margin-top:12px}
@media(max-width:780px){.poll-chooser{padding:10px 12px 0}.poll-board{padding:12px}.channel-list .channel{flex:0 0 auto}}

.poll-create-shortcut{border-style:dashed;background:var(--tm-ice);color:var(--tm-blue);text-align:left;font-weight:800}
.poll-create-shortcut:hover,.poll-create-shortcut:focus-visible{background:var(--tm-ice);border-color:var(--tm-blue)}

.poll-create-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.poll-create[hidden]{display:none}

/* Poll create action belongs above the poll content, never inside the channel list. */
.poll-toolbar{display:flex;justify-content:flex-start;align-items:center;gap:10px;padding:12px 18px 0;flex-shrink:0}
.poll-create-top{min-height:42px}
@media(max-width:530px){.poll-toolbar{padding:10px 12px 0}.poll-create-top{width:100%}}

/* Teamilo 0.8.21: event-linked task lists and user confirmations. */
.task-card{width:100%;max-width:100%;min-width:0}
.task-rows{display:grid;gap:9px;margin-top:14px}
.task-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:11px;border:1px solid var(--tm-line);border-radius:11px;background:var(--tm-surface);min-width:0}
.task-row strong{overflow-wrap:anywhere}
.task-row .sub{overflow-wrap:anywhere;white-space:normal}
.task-row button{flex:0 0 auto;max-width:100%}
#taskCreateForm{display:grid;gap:10px}
#taskCreateForm select,#taskCreateForm input{width:100%;min-width:0}
@media(max-width:520px){.task-row{align-items:stretch}.task-row button{width:100%}}

/* 0.8.22: long task forms scroll inside their own panel, not beyond chat viewport. */
.chatpanel #taskCreator,.chatpanel #taskEditPanel{flex:0 1 auto;min-height:0;max-height:min(44vh,410px);overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-gutter:stable;}
.chatpanel #taskCreator:not([hidden]),.chatpanel #taskEditPanel:not([hidden]){display:block;}
.chatpanel:has(#taskCreator:not([hidden])) #taskBoard,.chatpanel:has(#taskEditPanel:not([hidden])) #taskBoard{min-height:75px;}
#taskEditItems{display:grid;gap:9px;min-width:0;}
.task-edit-row{min-width:0;}
@media(max-width:780px){.chatpanel #taskCreator,.chatpanel #taskEditPanel{max-height:min(34vh,350px);}}
@media(max-height:550px){.chatpanel #taskCreator,.chatpanel #taskEditPanel{max-height:45%;}}

/* Teamilo 0.8.23: per-user red unread navigation counters. */
.unread-badge{display:inline-flex;flex:0 0 auto;align-items:center;justify-content:center;min-width:26px;height:21px;padding:0 6px;border-radius:7px;background:var(--tm-coral);color:var(--tm-ink)!important;font-size:12px!important;font-weight:850;line-height:1;box-sizing:border-box;white-space:nowrap;box-shadow:0 1px 2px rgba(0,0,0,0.1333);vertical-align:middle;margin-left:auto}
.unread-badge[hidden]{display:none!important}
.sidebar button[data-nav],.channel-list button[data-channel]{display:flex;align-items:center;gap:6px;min-width:0;justify-content:flex-start}
.bottom button[data-nav]{position:relative;gap:3px}
.bottom button .unread-badge{position:absolute;right:calc(50% - 33px);top:1px;margin:0;min-width:24px;height:19px;border-radius:6px;font-size:11px!important;z-index:1}
.channel-list .channel .unread-badge{margin-left:auto}
@media(max-width:760px){.channel-list button[data-channel]{flex:0 0 auto}.channel-list .channel .unread-badge{margin-left:4px}}

/* TEAMilo 0.8.25: official wordmark in navigation and login; original symbol for browser/app icons. */
.brand-logo-wrap{display:block;box-sizing:border-box;max-width:100%;margin:0 0 27px;padding:9px 10px;background:var(--tm-surface);border-radius:14px;line-height:0;box-shadow:0 3px 10px rgba(0,0,0,0.1020)}
.brand-logo{display:block;width:100%;height:auto;object-fit:contain;max-height:75px}
.authcard .brand-logo-wrap{background:transparent;box-shadow:none;padding:0;margin:0 0 22px;max-width:260px}
.mobile-top-logo{display:none}
@media(max-width:780px){.mobile-top-logo{display:block;width:clamp(100px,35vw,150px);max-height:48px;height:auto;object-fit:contain;object-position:left center;margin-bottom:5px}.top .desktop-pilot{display:none}.top .top-controls{min-width:0;max-width:52%}.top .team-pill{width:100%;max-width:100%}}
@media(max-width:380px){.mobile-top-logo{width:110px}.top .top-controls{max-width:53%}}

/* 0.10.6: Team is a read-only two-column roster */
.team-overview-only{align-items:start}
.team-overview-only>.card,.team-overview-only>section{height:100%;min-width:0}
.team-overview-only .team-overview-list{list-style:none;padding:0;margin:12px 0 0}
.team-overview-only .team-overview-person{padding:11px 0;border-bottom:1px solid var(--tm-line);overflow-wrap:anywhere}
.team-overview-only .team-overview-person:last-child{border-bottom:0}
.team-overview-only .team-overview-person strong{display:block;font-weight:700}
.team-overview-only .team-overview-linked{display:block;color:var(--tm-muted);font-size:.89rem;margin-top:5px}
.team-overview-only .team-overview-empty{color:var(--tm-muted);padding:12px 0}

/* 0.10.9 – one notification design for actionable work on Home and Organisation. */
.teamilo-open-notification{display:block;box-sizing:border-box;width:100%;background:var(--tm-ice);border:2px solid var(--tm-coral);border-radius:13px;color:var(--tm-ink);padding:14px 16px;margin:0 0 11px;text-align:left;line-height:1.45;overflow-wrap:anywhere}
.teamilo-open-notification strong{display:block;font-size:1rem;font-weight:800;color:var(--tm-ink)}
.teamilo-open-notification .teamilo-open-notification-detail{display:block;color:var(--tm-ink);font-size:.92rem;margin-top:5px}
.teamilo-open-notification-link{font:inherit;cursor:pointer;appearance:none;-webkit-appearance:none}
.teamilo-open-notification-link:hover{background:var(--tm-ice);border-color:var(--tm-coral)}
.teamilo-open-notification-link:focus-visible{outline:3px solid var(--tm-blue);outline-offset:3px}
@media(max-width:650px){.teamilo-open-notification{padding:12px 13px}}

/* 0.10.10: account-wide home overview. Other screens retain their team context. */
.home-all-teams-indicator{display:inline-flex;padding:8px 13px;border:1px solid var(--tm-line);border-radius:99px;background:var(--tm-ice);color:var(--tm-blue);font-weight:800;font-size:13px}
.team-pill[hidden]{display:none!important}
.home-all-teams-header{margin:0 0 17px}.home-all-teams-header h1{font-size:27px;margin:4px 0 6px}.home-all-teams-header p{margin:0;color:var(--tm-muted)}
.home-account-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:12px 0 23px}
.home-priority-block{margin-bottom:20px}.home-global-alert{text-align:left;width:100%;display:flex;flex-direction:column;gap:6px;margin:0 0 9px}
.home-team-tag{display:inline-flex;align-self:flex-start;max-width:100%;padding:4px 9px;border-radius:8px;background:var(--tm-canvas);color:var(--tm-blue);font-size:12px;font-weight:800;overflow-wrap:anywhere}
.home-global-alert .home-team-tag{background:var(--tm-ice);color:var(--tm-ink)}
.home-global-event{display:block;width:100%;text-align:left;margin:0 0 9px;padding:13px 16px;cursor:pointer;border:1px solid var(--tm-line)}
.home-global-event:hover{background:var(--tm-surface);border-color:var(--tm-line)}.home-global-event:focus-visible,.home-show-more:focus-visible{outline:3px solid var(--tm-blue);outline-offset:2px}
.home-global-event-body{display:flex;align-items:center;gap:11px;margin-top:8px}
.home-global-date{display:flex;flex-direction:column;align-items:center;min-width:64px;padding:7px;border-radius:8px;background:var(--tm-canvas);font-size:12px}
.home-global-date strong{font-size:14px}.home-global-details{min-width:0;flex:1;display:flex;flex-direction:column;gap:5px}.home-global-details>strong{overflow-wrap:anywhere}.home-global-details>span{font-size:13px;color:var(--tm-muted)}.home-global-arrow{font-size:22px;color:var(--tm-blue)}
.home-global-notice{width:100%;text-align:left;margin-bottom:9px;display:flex;flex-direction:column;align-items:flex-start;gap:6px}.home-global-notice .sub{overflow-wrap:anywhere}
.home-show-more{width:100%;margin:10px 0 18px}.home-data-warning{border:1px solid var(--tm-coral);background:var(--tm-ice);margin:12px 0;display:flex;align-items:center;justify-content:space-between;gap:10px}.home-context-note{font-size:12px;color:var(--tm-muted);margin-top:20px}
@media(max-width:650px){.home-account-stats{gap:6px}.home-account-stats .stat{padding:11px 7px}.home-account-stats .stat .num{font-size:22px}.home-account-stats small{font-size:11px}.home-data-warning{display:block}.home-global-date{min-width:54px}.home-all-teams-header h1{font-size:23px}}


/* 0.10.15: fixed-format rounded sponsorship slot directly below overview introduction.
   Desktop creative: 728 x 90, phone creative: 320 x 100.
   At exceptionally narrow widths, max-width prevents horizontal scrolling. */
.home-ad-slot{
  box-sizing:border-box;width:728px;max-width:100%;height:90px;
  margin:12px auto 21px;border:1px solid var(--tm-line);border-radius:16px;
  background:var(--tm-ink);overflow:hidden;box-shadow:0 3px 12px rgba(0,0,0,0.1098);
}
.home-ad-slot .home-demo-ad{
  box-sizing:border-box;display:flex;align-items:center;width:100%;height:100%;min-height:0;
  padding:8px 32px 8px 16px;margin:0;border-radius:0;
}
.home-ad-slot .home-demo-ad::before{
  width:160px;height:160px;border-width:25px;right:-47px;top:-60px;
}
.home-ad-slot .home-demo-ad-content{
  display:grid;grid-template-columns:auto minmax(0,1fr);grid-template-rows:18px 22px 16px;
  column-gap:17px;row-gap:3px;align-items:center;width:100%;max-width:100%;min-width:0;
}
.home-ad-slot .home-demo-ad-brand{
  grid-column:1;grid-row:1 / 4;font-size:34px;letter-spacing:-1px;
  line-height:1;margin:0;align-self:center;
}
.home-ad-slot .home-demo-ad-label{
  grid-column:2;grid-row:1;justify-self:start;padding:1px 6px;
  font-size:10px;line-height:1.2;letter-spacing:0;
}
.home-ad-slot .home-demo-ad-headline{
  grid-column:2;grid-row:2;min-width:0;font-size:16px;line-height:1.18;
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.home-ad-slot .home-demo-ad-copy{display:none}
.home-ad-slot .home-demo-ad-disclosure{
  grid-column:2;grid-row:3;min-width:0;font-size:10px;line-height:1.25;
  margin:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.home-ad-slot .home-demo-ad-arrow{
  top:50%;right:11px;transform:translateY(-50%);font-size:17px;
}
@media(max-width:780px){
  .home-ad-slot{width:320px;height:100px;margin:12px auto 18px;border-radius:15px}
  .home-ad-slot .home-demo-ad{padding:9px 18px 9px 11px}
  .home-ad-slot .home-demo-ad-content{
    grid-template-columns:58px minmax(0,1fr);grid-template-rows:16px 35px 21px;
    column-gap:8px;row-gap:1px;max-width:100%;
  }
  .home-ad-slot .home-demo-ad-brand{font-size:27px;letter-spacing:-.8px}
  .home-ad-slot .home-demo-ad-label{font-size:9px;padding:1px 4px}
  .home-ad-slot .home-demo-ad-headline{
    font-size:12.5px;line-height:1.2;white-space:normal;
    display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;
  }
  .home-ad-slot .home-demo-ad-disclosure{
    font-size:9px;line-height:1.13;white-space:normal;max-height:21px;
  }
  .home-ad-slot .home-demo-ad-arrow{right:6px;top:7px;transform:none;font-size:13px}
  .home-ad-slot .home-demo-ad::before{width:112px;height:112px;border-width:19px;right:-45px;top:-42px}
}

/* 0.10.18: archive and large bold date in the home calendar tile. */
.home-global-date .home-global-date-label{font-size:14px;font-weight:800;line-height:1.25;color:var(--tm-blue);white-space:nowrap}
.event-archive-section{margin-top:24px;padding-top:14px;border-top:1px solid var(--tm-line)}
.event-archive-toggle{margin-bottom:12px;width:auto}
.event-archive-content h2{font-size:20px;margin:10px 0 14px}
.event-archive-content .card{background:var(--tm-surface);border-color:var(--tm-line)}
@media(max-width:650px){.event-archive-toggle{width:100%;text-align:center}}

/* TEAMilo 0.10.20: Accessible one-off calendar confirmation. */
.calendar-offer{max-width:480px;width:min(94vw,480px);max-height:90vh;overflow-y:auto}
.calendar-offer-actions{display:grid;grid-template-columns:1fr 1fr;gap:9px;margin:16px 0}
.calendar-offer-actions .btn{text-align:center;white-space:normal;min-height:45px}
.calendar-offer>[data-calendar-close]{width:100%}
@media(max-width:420px){.calendar-offer-actions{grid-template-columns:1fr}}

/* TEAMilo 0.10.21: confirmed attendance on each personal-home event card. */
/* TEAMilo 0.10.22: the team and RSVP labels share shape, font and padding. */
.home-global-event-tags{display:flex;flex-wrap:wrap;align-items:center;gap:8px;max-width:100%;min-width:0}
.home-global-event-tags .home-team-tag{align-self:auto}
.home-global-event-tags .home-global-rsvp{background:var(--tm-ice);color:var(--tm-blue)}

/* 0.10.23 - same pale-red notification design for events with an outstanding
   personal RSVP. No change to ordinary/answered cards or archived events. */
.home-global-event.teamilo-event-unanswered,
.card.teamilo-event-unanswered{
 background:var(--tm-ice);
 border:2px solid var(--tm-coral);
 color:var(--tm-ink);
}
.home-global-event.teamilo-event-unanswered:hover{background:var(--tm-ice);border-color:var(--tm-coral)}
.teamilo-unanswered-label{display:inline-flex;align-items:center;margin-top:8px;padding:4px 9px;border-radius:8px;
 background:var(--tm-ice);color:var(--tm-ink);font-size:12px;font-weight:800;line-height:1.4}
.home-global-event-tags .teamilo-unanswered-label{margin-top:0}

/* TEAMILO_01030_TYPEFIX: identical typography for all profile headings. */
.teamilo-profile-section-title{font-family:Outfit,'DM Sans',sans-serif;font-size:19px;font-weight:700;line-height:normal;letter-spacing:normal;margin:0}

/* source: /static/chat-navigation.css */
/* Teamilo v0.8.27: chat overview then full-screen conversation */
.chat-layout.tm-chat-overview {
  display: block !important;
  width: 100%;
  max-width: 100%;
}
.tm-chat-overview .channel-list {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 12px !important;
  overflow: visible !important;
  width: 100%;
}
.tm-chat-overview .channel-list .channel {
  width: 100% !important;
  white-space: normal !important;
  min-height: 80px;
  display: flex !important;
  align-items: center;
  text-align: left;
  margin: 0 !important;
  padding: 18px !important;
  font-size: 15px !important;
}
.tm-chat-overview .chatpanel,
.tm-chat-overview [hidden] { display: none !important; }

/* Deliberately take over the viewport, not a second scrolling application card. */
.chat-layout.tm-chat-detail {
  position: fixed !important;
  inset: 0 !important;
  z-index: 5000 !important;
  width: 100vw !important;
  height: 100vh !important;
  height: 100dvh !important;
  max-width: none !important;
  max-height: none !important;
  padding: 0 !important;
  margin: 0 !important;
  background: var(--tm-surface);
  display: flex !important;
  flex-direction: column !important;
  gap: 0 !important;
  overflow: hidden !important;
}
.tm-chat-detail .channel-list,
.tm-chat-detail [hidden] { display: none !important; }
.tm-chat-navigation-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: max(11px, env(safe-area-inset-top)) 20px 11px;
  flex: 0 0 auto;
  background: var(--tm-surface);
  border-bottom: 1px solid var(--tm-line);
}
.tm-chat-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--tm-line);
  border-radius: 12px;
  background: var(--tm-surface);
  color: var(--tm-blue);
  padding: 10px 14px;
  font-weight: 800;
  cursor: pointer;
  width: auto;
  white-space: nowrap;
}
.tm-chat-back:hover { background: var(--tm-ice); }
.tm-chat-back:focus-visible { outline: 3px solid var(--tm-blue); outline-offset: 3px; }
.tm-chat-current-title {
  font-size: 19px;
  line-height: 1.35;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.tm-chat-detail .chatpanel {
  display: flex !important;
  flex-direction: column !important;
  flex: 1 1 auto !important;
  width: 100% !important;
  min-width: 0 !important;
  min-height: 0 !important;
  height: auto !important;
  max-height: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  overflow: hidden !important;
  background: var(--tm-surface);
}
.tm-chat-detail .chat-title { flex: 0 0 auto; }
.tm-chat-detail .chatlog,
.tm-chat-detail .tm-chat-scroll {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  max-height: none !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
.tm-chat-detail .chatcompose,
.tm-chat-detail #chatform {
  flex: 0 0 auto !important;
  margin: 0;
  padding-bottom: max(12px, env(safe-area-inset-bottom)) !important;
  background: var(--tm-surface);
}
.tm-chat-body-locked,
body:has(.tm-chat-detail) {
  overflow: hidden !important;
}
/* The modal must remain above a fullscreen chat. */
body:has(.tm-chat-detail) .modalback { z-index: 5500 !important; }
@media (max-width: 780px) {
  .tm-chat-overview .channel-list {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  .tm-chat-overview .channel-list .channel { min-height: 66px; }
  .tm-chat-navigation-bar { padding-left: 12px; padding-right: 12px; }
  .tm-chat-current-title { font-size: 16px; }
  .tm-chat-detail .chatlog { padding: 12px !important; }
}

/* source: /static/chat-input-width.css */
/* TEAMilo 0.8.28 - center chat composer and cap its desktop width.
   Messages continue to use the full available chat width; only the input row is limited.
   Applies only to the fullscreen conversation introduced in 0.8.27. */
.tm-chat-detail .chatpanel > #chatform,
.tm-chat-detail .chatpanel > .chatcompose {
  width: 100% !important;
  max-width: 700px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  align-self: center !important;
  box-sizing: border-box !important;
  min-width: 0 !important;
}

/* Prevent an input's intrinsic width from pushing the send button off screen. */
.tm-chat-detail .chatpanel > #chatform input[name="body"],
.tm-chat-detail .chatpanel > .chatcompose input[name="body"] {
  min-width: 0 !important;
  flex: 1 1 0% !important;
}

/* Mobile keeps the entire available width and safe-area padding from 0.8.27. */
@media (max-width: 780px) {
  .tm-chat-detail .chatpanel > #chatform,
  .tm-chat-detail .chatpanel > .chatcompose {
    max-width: 100% !important;
  }
}

/* source: /static/chat-window-width.css */
/* TEAMilo 0.8.29 – max. 700px for the WHOLE chat UI, not only the composer.
   The outer viewport layer remains full-screen to prevent the document from
   scrolling in parallel with the messages. The visible chat surface is centered.
   This comes after chat-navigation.css (0.8.27) and optionally
   chat-input-width.css (0.8.28) in the HTML head. */

/* Also keep the initial six-channel overview comfortably readable on desktop. */
.chat-layout.tm-chat-overview {
  width: 100% !important;
  max-width: 700px !important;
  margin-inline: auto !important;
  box-sizing: border-box !important;
}

/* The fullscreen layer stays fixed, but its visible contents do not stretch. */
.chat-layout.tm-chat-detail {
  align-items: center !important;
  background: var(--tm-surface) !important;
}

/* Header, conversation and input now share the SAME horizontal constraint. */
.tm-chat-detail > .tm-chat-navigation-bar,
.tm-chat-detail > .chatpanel {
  width: 100% !important;
  max-width: 700px !important;
  min-width: 0 !important;
  align-self: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
  box-sizing: border-box !important;
}

.tm-chat-detail > .chatpanel {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow: hidden !important;
  box-shadow: 0 10px 36px rgba(0,0,0,0.0700);
}

/* No nested horizontal scrollbar or oversized message content. */
.tm-chat-detail .chatlog,
.tm-chat-detail .tm-chat-scroll {
  width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
}
.tm-chat-detail .chatcompose,
.tm-chat-detail #chatform {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
}

/* Phones and narrow browser windows always use available screen width. */
@media (max-width: 780px) {
  .chat-layout.tm-chat-detail { background: var(--tm-surface) !important; }
  .tm-chat-detail > .tm-chat-navigation-bar,
  .tm-chat-detail > .chatpanel {
    max-width: 100% !important;
    box-shadow: none !important;
  }
}

/* source: /static/chat-activity-order.css */
/* Teamilo v0.8.34: chronologically ordered areas, without visible timestamps. */
.chat-layout.tm-chat-overview .channel-list {
  display: flex !important;
  flex-direction: column !important;
  gap: 8px !important;
  width: 100% !important;
}
.chat-layout.tm-chat-overview .channel-list > .channel {
  width: 100% !important;
  min-height: 54px !important;
  flex: 0 0 auto !important;
  display: flex !important;
  flex-wrap: wrap !important;
  align-content: center !important;
  align-items: center !important;
  justify-content: flex-start !important;
  column-gap: 10px !important;
  row-gap: 2px !important;
  box-sizing: border-box !important;
}
/* Defensive: no old hint should be visible if the browser reuses existing DOM. */
.tm-chat-overview .channel-list .tm-activity-hint { display: none !important; }

/* source: /static/message-actions.css */
/* Teamilo 0.8.39: contextual menu on hover/long press, author-only delete X */
#chatlog .bubble.tm-message-card{
  position:relative;max-width:min(90%,620px);white-space:pre-wrap;
  overflow-wrap:anywhere;box-sizing:border-box;overflow:visible;
}
#chatlog .tm-message-card .who{padding-inline-end:65px}
#chatlog .tm-message-controls{
  position:absolute;inset-block-start:5px;inset-inline-end:5px;
  display:flex;gap:3px;align-items:center;opacity:0;pointer-events:none;
  transition:opacity .12s ease;z-index:2;
}
#chatlog .tm-message-controls button{
  display:grid;place-items:center;width:27px;height:27px;min-width:27px;
  border:1px solid var(--tm-line);border-radius:8px;background:var(--tm-surface);color:var(--tm-blue);
  font-size:20px;line-height:1;cursor:pointer;padding:0;
}
#chatlog .tm-message-controls .tm-message-delete-trigger{font-size:19px}
#chatlog .tm-message-card:hover>.tm-message-controls,
#chatlog .tm-message-card:focus-within>.tm-message-controls,
#chatlog .tm-message-card[data-tm-menu-open="true"]>.tm-message-controls{
  opacity:1;pointer-events:auto;
}
#chatlog .tm-message-menu{
  position:absolute;inset-block-start:34px;inset-inline-end:5px;
  display:flex;flex-direction:column;min-width:145px;z-index:20;
  border:1px solid var(--tm-line);background:var(--tm-surface);color:var(--tm-blue);
  padding:5px;border-radius:12px;box-shadow:0 6px 20px rgba(0,0,0,0.2000);
  white-space:normal;
}
#chatlog .tm-message-card:not(.mine) .tm-message-menu{inset-inline-start:5px;inset-inline-end:auto}
#chatlog .tm-message-menu[hidden]{display:none!important}
#chatlog .tm-message-menu button{
  display:block;text-align:start;border:0;border-radius:7px;
  padding:9px 12px;min-height:38px;font:inherit;font-size:14px;
  color:inherit;background:transparent;cursor:pointer;
}
#chatlog .tm-message-menu button:hover,
#chatlog .tm-message-menu button:focus-visible{background:var(--tm-canvas)}
#chatlog .tm-message-controls button:focus-visible,
#chatlog .tm-message-menu button:focus-visible{outline:3px solid var(--tm-blue);outline-offset:2px}
#chatlog .tm-forwarded-hint{display:block;font-size:11px;opacity:.75;margin-bottom:5px}
#tm-forward-dialog,#tm-delete-dialog{
  box-sizing:border-box;width:min(95vw,420px);max-height:min(85vh,720px);
  overflow-y:auto;border:1px solid var(--tm-line);border-radius:18px;padding:22px;
  background:var(--tm-surface);color:var(--tm-blue);box-shadow:0 12px 40px rgba(0,0,0,0.2000);
}
#tm-forward-dialog::backdrop,#tm-delete-dialog::backdrop{background:color-mix(in srgb,var(--tm-ink) 46.6700%,transparent)}
#tm-forward-dialog form,#tm-delete-dialog form{display:grid;gap:12px}
#tm-forward-dialog label{font-weight:600}
#tm-forward-dialog select{width:100%;padding:11px;border:1px solid var(--tm-line);border-radius:10px;min-height:45px}
#tm-forward-dialog .tm-dialog-buttons,#tm-delete-dialog .tm-dialog-buttons{
  display:flex;gap:10px;justify-content:flex-end;flex-wrap:wrap;
}
#tm-forward-dialog button,#tm-delete-dialog button{
  padding:10px 15px;border-radius:10px;border:1px solid var(--tm-blue);cursor:pointer;
}
#tm-forward-dialog button[type=submit]{background:var(--tm-blue);color:var(--tm-surface)}
#tm-delete-dialog .tm-delete-confirm{background:var(--tm-coral);color:var(--tm-ink);border-color:var(--tm-coral)}
@media(hover:none){
  #chatlog .bubble.tm-message-card{-webkit-touch-callout:none}
  #chatlog .tm-message-controls{opacity:0;pointer-events:none}
  #chatlog .tm-message-card[data-tm-menu-open="true"]>.tm-message-controls,
  #chatlog .tm-message-card:focus-within>.tm-message-controls{opacity:1;pointer-events:auto}
  #chatlog .tm-message-controls button{width:36px;height:36px;min-width:36px}
  #chatlog .tm-message-menu{inset-block-start:40px}
}
@media(max-width:640px){#chatlog .bubble.tm-message-card{max-width:96%}}
@media(prefers-reduced-motion:reduce){#chatlog .tm-message-controls{transition:none}}

/* source: /static/org-core.css */
#teamilo-org-root{display:block;width:100%;min-height:50vh}
#teamilo-org-root *{box-sizing:border-box}
.org-page{max-width:1130px;margin:0 auto;padding:22px 12px 100px;font-family:inherit;color:inherit}
.org-head,.org-toolbar,.org-line{display:flex;align-items:center;justify-content:space-between;gap:14px;flex-wrap:wrap}
.org-head h1{font-size:1.6rem;margin:3px 0 12px}
.org-head small{color:var(--tm-blue);font-weight:700}
.org-toolbar{margin:12px 0 16px}.org-toolbar label{display:flex;gap:8px;align-items:center}
.org-entry{border:1px solid var(--tm-line);border-radius:10px;padding:8px;background:var(--tm-ice);color:var(--tm-blue);font-weight:700;cursor:pointer}
.org-tabs{display:flex;gap:7px;overflow-x:auto;max-width:100%;padding:6px 0 14px}
.org-tabs button,.org-toolbar button,#teamilo-org-root button{cursor:pointer}
.org-tabs button{flex:0 0 auto;padding:10px 13px;border:1px solid var(--tm-line);border-radius:12px;background:var(--tm-surface);color:var(--tm-blue);font-weight:600}
.org-tabs button.chosen{background:var(--tm-blue);border-color:var(--tm-blue);color:var(--tm-surface)}
.org-cols{display:grid;grid-template-columns:1.15fr 1fr;gap:16px}.org-panel{background:var(--tm-surface);border:1px solid var(--tm-line);border-radius:14px;padding:18px;min-width:0;margin:10px 0}
.org-panel h3{margin:0 0 14px;font-size:1.09rem}.org-panel p{line-height:1.5;margin:9px 0;border-bottom:1px solid var(--tm-line);padding-bottom:8px}
.org-stats{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}.org-stats article{border:1px solid var(--tm-line);border-radius:14px;background:var(--tm-surface);padding:18px;display:grid;gap:5px}.org-stats b{font-size:2rem;color:var(--tm-blue)}
.org-page label{display:grid;gap:7px;font-size:.91rem;font-weight:600;margin:11px 0}
.org-page input,.org-page select,.org-page textarea{max-width:100%;min-width:0;border:1px solid var(--tm-line);border-radius:8px;padding:10px 11px;background:var(--tm-surface);font:inherit;color:var(--tm-blue)}
.org-page form{display:grid;gap:5px}.org-page button{border:1px solid var(--tm-line);border-radius:9px;padding:8px 11px;background:var(--tm-surface);color:var(--tm-blue)}
.org-page button.org-primary{background:var(--tm-blue);color:var(--tm-surface);border-color:var(--tm-blue);padding:11px 16px;font-weight:700}
.org-page button:disabled{opacity:.45;cursor:not-allowed}
.org-line{padding:9px 0;border-bottom:1px solid var(--tm-line)}.org-line small{display:block;color:var(--tm-muted);margin-top:4px;font-size:.82rem}
.org-message-list{max-height:330px;overflow-y:auto;overscroll-behavior:contain;background:var(--tm-surface);padding:14px;border-radius:12px}
.org-msg{background:var(--tm-surface);border-radius:10px;padding:10px 13px;max-width:85%;margin:7px 0;box-shadow:0 1px 3px rgba(0,0,0,1.0000)}
.org-msg small{color:var(--tm-muted)}.org-msg p{white-space:pre-wrap;overflow-wrap:anywhere;border:0!important}
.org-check{display:flex!important;flex-direction:row;align-items:center;font-weight:400!important}.org-check input{width:auto}
.org-hint{font-size:.85rem;color:var(--tm-muted)}.org-error{color:var(--tm-ink);background:var(--tm-ice);padding:10px;border-radius:9px}
.org-dot{display:inline-block;width:8px;height:8px;background:var(--tm-coral);border-radius:50%;margin-right:6px}
.org-poll{border-bottom:1px solid var(--tm-line);padding:10px 0}
@media(max-width:850px){.org-cols{grid-template-columns:1fr}.org-page{padding:13px 4px 96px}.org-stats article{padding:12px}.org-stats b{font-size:1.3rem}.org-head h1{font-size:1.3rem}}

.org-msg-actions{display:none;gap:6px;flex-wrap:wrap;margin-top:7px}
.org-msg:hover .org-msg-actions,.org-msg:focus-within .org-msg-actions,.org-msg.open-actions .org-msg-actions{display:flex}
.org-msg-actions button{font-size:.79rem;padding:5px 8px;border-radius:7px}
.org-msg-actions .org-delete{padding:4px 9px;color:var(--tm-ink);background:var(--tm-ice);border-color:var(--tm-line)}
.org-msg{user-select:text;-webkit-user-select:text;touch-action:pan-y}

/* Organisation 0.9.2 – section-based navigation */
.org-section-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(195px,1fr));gap:13px;margin:20px 0}
#teamilo-org-root .org-section-choice{display:flex;align-items:center;justify-content:flex-start;min-height:68px;background:var(--tm-surface);border:1px solid var(--tm-line);border-radius:13px;padding:16px 18px;text-align:start;font-size:1rem;font-weight:650;color:var(--tm-blue);box-shadow:0 1px 2px rgba(0,0,0,1.0000)}
#teamilo-org-root .org-section-choice:hover,#teamilo-org-root .org-section-choice:focus-visible{border-color:var(--tm-blue);background:var(--tm-ice);outline-offset:2px}
.org-section-head{display:flex;flex-direction:column;align-items:flex-start;gap:10px;margin:14px 0}
.org-section-head h2{font-size:1.2rem;margin:0}
#teamilo-org-root .org-back{background:var(--tm-surface);border-color:var(--tm-line)}
#teamilo-org-root [data-org-error][hidden]{display:none}
@media(max-width:650px){.org-section-list{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}#teamilo-org-root .org-section-choice{padding:12px;min-height:60px;font-size:.92rem}}
@media(max-width:360px){.org-section-list{grid-template-columns:1fr}}

/* 0.10.6: unified membership and roles administration */
.org-member-card{display:flex;flex-direction:column;gap:8px;padding:12px 0;border-bottom:1px solid var(--tm-line)}
.org-member-card small,.org-role-entry small{display:block;color:var(--tm-muted);margin-top:5px;font-size:.87rem}
.org-member-edit{margin-top:5px}.org-member-edit summary{cursor:pointer;color:var(--tm-blue);font-weight:650}
.org-admin-fields{display:flex;flex-direction:column;align-items:stretch;gap:8px;padding:10px 0}
.org-role-entry{margin-bottom:13px;padding-bottom:10px;border-bottom:1px solid var(--tm-line)}
.org-player-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:12px}
.org-request{padding:12px 0;border-bottom:1px solid var(--tm-line);display:flex;gap:8px;flex-wrap:wrap;justify-content:space-between}
.org-request button+button{margin-left:7px}
.org-editor-form{margin:15px 0;padding-top:12px;border-top:1px solid var(--tm-line)}

/* 0.10.8: actionable Organisation items before stable regular content. */
.org-open-first{display:block;clear:both;margin:8px 0 16px}
.org-open-first .org-action-queue,.org-open-first>[data-org-open-claims]{border:1px solid var(--tm-line);border-inline-start:4px solid var(--tm-blue)}
.org-open-first .org-request small{display:block;color:var(--tm-muted);margin-top:4px}

/* 0.10.9 – notification first, existing action rows stay below. */
.org-open-first>.org-open-notification{margin-bottom:9px}
.org-open-first>.org-panel{margin-top:11px}
.org-open-first .org-request{align-items:center}
.org-open-first .org-request>div{min-width:0}

/* 0.10.13: role editing and removal inside Organisation > Mitglieder und Rollen. */
.org-role-entry{display:flex;flex-direction:column;gap:9px}
.org-role-actions{display:flex;flex-wrap:wrap;gap:9px}
#teamilo-org-root .org-role-actions button{min-width:105px}
#teamilo-org-root .org-role-entry form[data-form="role-edit"]{width:100%;max-width:650px}
#teamilo-org-root .org-role-entry form[data-form="role-edit"]>button{margin:5px 8px 0 0}

/* source: /static/profile-privacy.css */
/* TEAMilo 0.9.7: personal profile settings */
.teamilo-profile-privacy .teamilo-privacy-field{display:flex;flex-direction:column;gap:5px;margin:12px 0;max-width:520px}
.teamilo-profile-privacy .teamilo-privacy-field input,.teamilo-profile-privacy .teamilo-privacy-field select{max-width:100%;width:100%;box-sizing:border-box}
.teamilo-profile-privacy .teamilo-privacy-choice{display:flex;align-items:center;gap:10px;margin:10px 0}
.teamilo-profile-privacy .teamilo-privacy-choice input{width:auto;flex:0 0 auto}
.teamilo-profile-privacy .teamilo-privacy-status{min-height:1.4em;margin-top:8px}
.teamilo-profile-privacy[dir="rtl"] .teamilo-privacy-choice{flex-direction:row}

/* source: /static/modules-onboarding.css */
/* Teamilo v0.10.1 integration: no changes to original navigation or organization UI */
.teamilo-module-overlay{position:fixed;inset:0;z-index:2000;background:color-mix(in srgb,var(--tm-ink) 71.7600%,transparent);display:flex;justify-content:center;align-items:center;padding:12px;overflow:auto}
.teamilo-module-dialog{width:min(100%,700px);max-height:calc(100vh - 24px);overflow:auto;background:var(--tm-surface);color:var(--tm-blue);border-radius:18px;box-shadow:0 24px 60px rgba(0,0,0,0.4392);padding:22px}
.teamilo-module-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;border-bottom:1px solid var(--tm-line);padding-bottom:14px;margin-bottom:15px}
.teamilo-module-head h2{font-size:24px;line-height:1.2;margin:10px 0 0}.teamilo-module-content{font-size:15px}
.teamilo-module-content p{margin:8px 0 16px}.module-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:13px}
.module-field{display:flex;flex-direction:column;gap:6px;margin:0 0 14px;font-weight:600}
.module-field input,.module-field select{width:100%;max-width:100%;min-height:42px;font:inherit;padding:8px 10px;background:var(--tm-surface);color:var(--tm-blue);border:1px solid var(--tm-line);border-radius:10px}
.module-field input[type=color]{min-height:48px}.module-footer{display:flex;gap:12px;justify-content:space-between;padding-top:17px;border-top:1px solid var(--tm-line);margin-top:12px}
.module-footer button[type=submit]{margin-left:auto}.module-error{padding:12px;margin:10px 0;color:var(--tm-ink);background:var(--tm-ice);border-radius:8px}
.module-hint,.module-stepnote{font-size:14px;color:var(--tm-muted);line-height:1.5}.module-review{display:grid;grid-template-columns:1fr 2fr;gap:12px;background:var(--tm-surface);padding:15px;border-radius:11px}
.module-review dt{color:var(--tm-muted)}.module-review dd{font-weight:700;margin:0;word-break:break-word}.module-item{display:flex;justify-content:space-between;gap:14px;padding:10px 12px;border-bottom:1px solid var(--tm-line)}.module-item.muted{opacity:.65}.module-item span:last-child{font-size:13px}
.module-links{display:flex;flex-wrap:wrap;gap:7px;margin:18px 0}.module-progress{list-style:none;padding:12px 15px;background:var(--tm-surface);border-radius:12px;line-height:2}
.top-controls #teamilo-modules-open,.top-controls #teamilo-extra-team{font-size:13px;min-width:auto;padding:8px 11px}
@media(max-width:620px){.teamilo-module-overlay{padding:0}.teamilo-module-dialog{border-radius:0;max-height:100vh;min-height:100vh;padding:18px}.module-form-grid{grid-template-columns:1fr}.teamilo-module-head h2{font-size:20px}.module-links{flex-direction:column}.top-controls #teamilo-modules-open,.top-controls #teamilo-extra-team{font-size:12px;padding:6px}}

/* source: /static/teamilo-photos.css */
/* TEAMilo round photo previews, rectangular large image. */
.teamilo-with-photo{display:flex;align-items:center;gap:10px;min-width:0}
.teamilo-with-photo>.teamilo-avatar-trigger{flex:none}
.teamilo-person-text{display:flex;flex-direction:column;min-width:0;gap:2px}
.teamilo-avatar-trigger{width:46px;height:46px;flex-shrink:0;display:inline-flex;align-items:center;justify-content:center;overflow:hidden;border-radius:50%;border:2px solid var(--tm-line);background:var(--tm-ice);color:var(--tm-blue);position:relative;padding:0;font-size:13px;font-weight:700;cursor:zoom-in}
.teamilo-avatar-trigger:disabled{cursor:default;opacity:1}
.teamilo-avatar-trigger img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center;border-radius:50%}
.teamilo-avatar-trigger:focus-visible{outline:3px solid var(--tm-blue);outline-offset:3px}
.teamilo-avatar-large{width:90px;height:90px;font-size:22px}
.teamilo-profile-header{display:flex;align-items:center;gap:12px;margin:5px 0 12px}
.teamilo-profile-photo-actions{margin:6px 0 16px}
.teamilo-photo-editor{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:8px 0}
.teamilo-photo-select{position:relative;cursor:pointer}
.teamilo-photo-select input[type=file]{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer;font-size:0}
.teamilo-photo-select:focus-within{outline:2px solid var(--tm-blue);outline-offset:2px}
.teamilo-photo-child{display:flex;align-items:flex-start;gap:12px;margin:13px 0;padding:12px;background:var(--tm-surface);border-radius:12px}
.teamilo-photo-child>div{min-width:0}
.teamilo-photo-dialog{border:0;border-radius:12px;padding:0;max-width:min(94vw,680px);max-height:90vh;box-shadow:0 24px 70px rgba(0,0,0,0.4000);background:var(--tm-surface);color:var(--tm-ink)}
.teamilo-photo-dialog::backdrop{background:color-mix(in srgb,var(--tm-ink) 72.0000%,transparent)}
.teamilo-photo-popup{position:relative;min-width:min(85vw,280px);max-width:680px;padding:12px}
.teamilo-photo-popup>img{display:block;width:100%;max-height:72vh;object-fit:contain;border-radius:3px}
.teamilo-photo-popup p{font-weight:650;text-align:center;margin:10px 28px 2px}
.teamilo-photo-close{position:absolute;right:14px;top:14px;border:0;border-radius:4px;background:var(--tm-surface);color:var(--tm-ink);font-weight:700;font-size:26px;width:37px;height:37px;cursor:pointer;box-shadow:0 1px 7px rgba(0,0,0,0.2000)}
.teamilo-photo-close:focus-visible{outline:3px solid var(--tm-blue)}
@media(max-width:480px){.teamilo-avatar-trigger{width:40px;height:40px}.teamilo-avatar-large{width:80px;height:80px}.teamilo-photo-popup{min-width:0}}

/* 0.10.25 – participant portraits use the same round player avatar as Team/Organisation. */
.attendance-person>.teamilo-avatar-trigger{flex:0 0 46px}
.teamilo-child-photo-label{font-weight:650;font-size:13px;margin-top:7px}
@media(max-width:480px){.attendance-person>.teamilo-avatar-trigger{flex-basis:40px}}

/* 0.10.26 - visible picture controls for every authorized linked player. */
.teamilo-photo-hidden-input{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip-path:inset(50%)!important;white-space:nowrap!important;border:0!important;opacity:0!important;pointer-events:none!important}
.teamilo-photo-editor>[data-photo-open]{display:inline-flex;align-items:center;justify-content:center;min-height:40px}

/* source: /static/teamilo-logos.css */
/* Teamilo 0.10.31 – team logos proportional, with private authenticated loading. */
.teamilo-logo-panel{margin-top:18px;border:1px solid var(--tm-line);border-radius:17px;padding:16px;background:var(--tm-surface);display:flex;flex-direction:column;gap:10px}
.teamilo-logo-panel h3{font-family:Outfit,'DM Sans',sans-serif;font-size:19px;font-weight:700;margin:0}
.teamilo-logo-panel .teamilo-logo-preview{min-height:92px;display:flex;align-items:center;justify-content:center;background:var(--tm-surface);border:1px solid var(--tm-line);border-radius:12px;padding:10px}
.teamilo-logo-panel .teamilo-logo-preview img{display:block;max-height:110px;max-width:100%;width:auto;height:auto;object-fit:contain}
.teamilo-logo-panel .teamilo-logo-controls{display:flex;gap:8px;flex-wrap:wrap}
.teamilo-logo-panel .teamilo-logo-controls button{border-radius:10px;padding:9px 12px;background:var(--tm-surface);border:1px solid var(--tm-line);color:var(--tm-blue);font-weight:750}
.teamilo-logo-panel .teamilo-logo-message{font-size:13px;color:var(--tm-muted);line-height:1.5}
.teamilo-logo-panel input[type=file]{display:none}
.home-global-event.teamilo-has-logo{position:relative;padding-right:clamp(92px,26%,154px)}
/* The logo frame remains exactly 76px high, for short and multiline event cards alike. */
.home-global-event .teamilo-event-logo{position:absolute;top:50%;bottom:auto;transform:translateY(-50%);right:8px;height:76px;width:clamp(74px,24%,142px);display:flex;align-items:center;justify-content:center;pointer-events:none}
.home-global-event .teamilo-event-logo img{display:block;width:100%;height:76px;max-height:76px;max-width:100%;object-fit:contain;border-radius:5px}
/* The existing initial is retained as a fallback while a private image loads. */
.person > .avatar.teamilo-profile-logo-avatar{position:relative;overflow:hidden;flex-shrink:0}
.person > .avatar.teamilo-profile-logo-avatar > .teamilo-profile-team-logo{position:absolute;inset:0;display:block;width:100%;height:100%;object-fit:contain;background:var(--tm-surface);border-radius:inherit}
.home-global-event.teamilo-has-logo .home-global-arrow{display:none}
.cardheader .teamilo-event-logo{width:clamp(67px,13vw,114px);height:90px;flex:0 0 auto;display:flex;justify-content:flex-end;align-items:center;margin-left:auto}
.cardheader .teamilo-event-logo img{max-width:100%;max-height:100%;height:auto;width:auto;object-fit:contain;border-radius:5px}
.cardheader.teamilo-has-logo > .pill{display:none}
.teamilo-home-header-logo{display:flex;align-items:center;justify-content:center;max-width:126px;max-height:88px;position:absolute;right:0;top:0}
.teamilo-home-header-logo img{max-width:100%;max-height:88px;object-fit:contain}
.home-all-teams-header.teamilo-has-logo{position:relative;padding-right:clamp(88px,24%,135px)}
@media(max-width:410px){.home-global-event.teamilo-has-logo{padding-right:82px}.home-global-event .teamilo-event-logo{width:68px;height:76px}.cardheader .teamilo-event-logo{width:68px;height:70px}}

/* source: /static/teamilo-profile-layout.css */
/* TEAMilo 0.10.33: unified profile cards and actions, mobile-first. */
.teamilo-profile-page{display:grid;grid-template-columns:minmax(0,1fr);gap:14px;margin-top:20px;min-width:0}
.teamilo-profile-page>.card,
.teamilo-profile-page>.teamilo-profile-section{margin:0!important;width:100%;min-width:0;padding:20px;border:1px solid var(--tm-line);border-radius:18px;background:var(--tm-surface);box-shadow:0 2px 8px rgba(0,0,0,0.0350)}
.teamilo-profile-page .teamilo-profile-section-title,
.teamilo-profile-page>.card>h3{font-family:Outfit,'DM Sans',system-ui,sans-serif;font-size:19px;line-height:1.3;font-weight:700;letter-spacing:0;margin:0 0 16px;color:var(--tm-ink)}
.teamilo-profile-page .teamilo-profile-header{margin:0 0 12px;display:flex;align-items:center;gap:14px}
.teamilo-profile-page .teamilo-profile-header h3{font-size:18px;font-weight:700;overflow-wrap:anywhere}
.teamilo-profile-page .teamilo-profile-photo-actions{margin:8px 0 12px}
.teamilo-profile-page .display-name-form{margin-top:18px}
.teamilo-profile-page .display-name-form .sub{margin-top:10px}
.teamilo-profile-page .fieldwrap{max-width:560px}
.teamilo-profile-page .teamilo-photo-child,
.teamilo-profile-page .person{display:flex;gap:12px;align-items:center;min-width:0;padding:13px 14px;margin:8px 0;background:var(--tm-surface);border:1px solid var(--tm-line);border-radius:13px}
.teamilo-profile-page .teamilo-photo-child>div,
.teamilo-profile-page .person .grow{min-width:0;flex:1}
.teamilo-profile-page .person:last-of-type{border-bottom:1px solid var(--tm-line)}
.teamilo-profile-page .teamilo-photo-child .sub,
.teamilo-profile-page .person .sub{overflow-wrap:anywhere}
.teamilo-profile-page .teamilo-profile-empty{padding:8px 0 4px}
/* Consistent 42px interactive controls; neutral secondary actions, dark-green primary actions. */
.teamilo-profile-page button.btn,
.teamilo-profile-page label.teamilo-photo-select,
.teamilo-profile-page button[data-team],
.teamilo-profile-page .teamilo-profile-privacy button.btn{
 min-height:42px;min-width:96px;border-radius:11px;padding:10px 15px;
 display:inline-flex;justify-content:center;align-items:center;gap:7px;
 font-family:'DM Sans',system-ui,sans-serif;font-size:14px;line-height:1.2;font-weight:750;
 text-align:center;white-space:normal;box-sizing:border-box;
}
.teamilo-profile-page button.btn:not(.light):not(.outline){background:var(--tm-blue);color:var(--tm-surface);border:1px solid var(--tm-blue)}
.teamilo-profile-page button.btn.light,
.teamilo-profile-page label.teamilo-photo-select,
.teamilo-profile-page button.btn.outline{background:var(--tm-surface);color:var(--tm-blue);border:1px solid var(--tm-line)}
.teamilo-profile-page button.btn:focus-visible,
.teamilo-profile-page label.teamilo-photo-select:focus-within{outline:3px solid var(--tm-blue);outline-offset:2px}
.teamilo-profile-page .teamilo-photo-editor,
.teamilo-profile-page .actions{display:flex;gap:9px;flex-wrap:wrap;margin-top:12px}
.teamilo-profile-page .teamilo-photo-editor .teamilo-photo-select{margin:0}
.teamilo-profile-page .teamilo-profile-photo-actions+.sub{margin-top:8px}
.teamilo-profile-page input:not([type='checkbox']):not([type='file']),
.teamilo-profile-page select{max-width:560px;min-height:42px}
.teamilo-profile-page .language-setting{padding:0;gap:12px}
.teamilo-profile-page .language-setting .lang-select{max-width:100%;width:min(100%,380px);min-height:42px}
.teamilo-profile-page .teamilo-privacy-field{max-width:560px}
.teamilo-profile-page .teamilo-privacy-choice{padding:6px 0}
.teamilo-profile-page .teamilo-profile-privacy .teamilo-privacy-choice input{accent-color:var(--tm-blue)}
.teamilo-profile-page .teamilo-privacy-status:empty{display:none}
.teamilo-profile-page .pending-requests,.teamilo-profile-page .club-pending{margin-top:18px}
.teamilo-profile-page .pending-requests h3,.teamilo-profile-page .club-pending h3{font-size:16px;margin:0 0 8px}
@media(max-width:560px){
 .teamilo-profile-page{gap:11px;margin-top:15px}
 .teamilo-profile-page>.card,.teamilo-profile-page>.teamilo-profile-section{padding:16px;border-radius:16px}
 .teamilo-profile-page .teamilo-photo-child,.teamilo-profile-page .person{padding:12px;flex-wrap:wrap}
 .teamilo-profile-page .person .grow{flex-basis:calc(100% - 70px)}
 .teamilo-profile-page .person button[data-team]{margin-left:54px}
 .teamilo-profile-page .teamilo-photo-editor{width:100%}
 .teamilo-profile-page .teamilo-photo-editor>*{flex:1 1 140px}
 .teamilo-profile-page .actions>.btn{flex:1 1 180px}
}
@media(prefers-reduced-motion:no-preference){.teamilo-profile-page button.btn{transition:background-color .14s ease}}

/* TEAMilo 0.10.34: member and privacy form controls use the compact
   dimensions of the language selector. Scoped to avoid affecting other cards. */
.teamilo-profile-page #displayNameForm .fieldwrap {
  width: min(100%, 380px);
  max-width: 380px;
}
.teamilo-profile-page #displayNameForm input[name="name"],
.teamilo-profile-page #teamilo-profile-privacy .teamilo-privacy-field input:not([type="checkbox"]):not([type="file"]),
.teamilo-profile-page #teamilo-profile-privacy .teamilo-privacy-field select {
  box-sizing: border-box;
  width: min(100%, 380px);
  max-width: 380px;
  min-width: 0;
  height: 42px;
  min-height: 42px;
  padding: 6px 9px;
  border-radius: 9px;
  font-size: 15px;
  line-height: normal;
}

/* source: /static/teamilo-event-accordion.css */
/* TEAMilo 0.10.35: calendar event cards, collapsed until selected */
[data-upcoming-events] .teamilo-event-accordion,
.event-archive-content .teamilo-event-accordion,
[data-event-archive] .teamilo-event-accordion {
  cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.teamilo-event-accordion:hover { border-color: var(--tm-line); }
.teamilo-event-accordion:focus-visible { outline: 3px solid var(--tm-blue); outline-offset: 2px; }
.teamilo-event-accordion .cardheader { flex-wrap: wrap; }
.teamilo-event-accordion-count { display: inline-block; margin-top: 7px; padding: 5px 9px; border-radius: 999px; background: var(--tm-ice); color: var(--tm-blue); font-size: 13px; font-weight: 800; line-height: 1.2; }
.teamilo-event-accordion-toggle {
  flex: 0 0 auto;
  border: 1px solid var(--tm-line);
  border-radius: 11px;
  background: var(--tm-surface);
  color: var(--tm-blue);
  font-size: 13px;
  font-weight: 800;
  padding: 8px 10px;
  min-height: 36px;
  line-height: 1.2;
  white-space: normal;
  max-width: 100%;
}
.teamilo-event-accordion-toggle:hover,
.teamilo-event-accordion-toggle:focus-visible { background: var(--tm-ice); }
.teamilo-event-accordion-open .teamilo-event-accordion-toggle { background: var(--tm-ice); }
.teamilo-event-accordion-content { margin-top: 12px; cursor: default; }
.teamilo-event-accordion-content[hidden] { display: none !important; }
.teamilo-event-accordion-content button,
.teamilo-event-accordion-content a,
.teamilo-event-accordion-content input,
.teamilo-event-accordion-content select { cursor: pointer; }
@media (max-width: 480px) {
  .teamilo-event-accordion-toggle { font-size: 12px; }
  .teamilo-event-accordion .cardheader { gap: 9px; }
}

/* source: /static/teamilo-desktop-banner-spacing.css */
/* TEAMilo 0.10.37 – desktop-only spacing between introduction, team logo and ad.
   Smartphone layout, banner creatives and event-card logos remain unchanged. */
@media (min-width: 781px) {
  /* Align the 728×90 advertisement with the left edge of the introduction.
     This moves it away from the team logo on the right. */
  .home-ad-slot {
    margin-left: 0;
    margin-right: auto;
    width: 728px;
    max-width: 100%;
  }

  /* A selected team's logo is 88px high while its title is often shorter.
     Reserve its actual height so it cannot visually run into the ad. */
  .home-all-teams-header.teamilo-has-logo {
    box-sizing: border-box;
    min-height: 100px;
    padding-right: clamp(112px, 20%, 150px);
    margin-bottom: 16px;
  }
}

/* source: /static/teamilo-event-card-layout.css */
/* TEAMilo 0.10.38 — tidy event summaries; preserves existing folding and RSVP. */
[data-upcoming-events] .teamilo-event-accordion > .cardheader,
.event-archive-content .teamilo-event-accordion > .cardheader,
[data-event-archive] .teamilo-event-accordion > .cardheader {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) max-content;
  align-items: start;
  column-gap: 12px;
  row-gap: 8px;
  min-width: 0;
}
.teamilo-event-accordion > .cardheader > .datebox { flex: 0 0 58px; align-self: flex-start; }
.teamilo-event-accordion > .cardheader > .grow {
  grid-column: 2;
  grid-row: 1;
  min-width: 0;
  overflow-wrap: anywhere;
  align-self: center;
}
.teamilo-event-accordion > .cardheader > .grow h3 { line-height: 1.25; margin: 0; overflow-wrap: anywhere; }
.teamilo-event-accordion .teamilo-event-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  margin-top: 7px;
  line-height: 1.4;
  min-width: 0;
  white-space: normal;
}
.teamilo-event-accordion .teamilo-event-time { font-size: 15px; font-weight: 750; color: var(--tm-blue); white-space: normal; }
.teamilo-event-accordion .teamilo-event-place { font-size: 14px; color: var(--tm-muted); overflow-wrap: anywhere; max-width: 100%; }
.teamilo-event-accordion > .cardheader > .teamilo-event-logo {
  grid-column: 3;
  grid-row: 1;
  justify-self: end;
  margin-left: 0;
  max-width: 100px;
}
.teamilo-event-accordion > .cardheader > .pill {
  grid-column: 3;
  grid-row: 1;
  justify-self: end;
}
.teamilo-event-accordion > .cardheader.teamilo-has-logo > .pill { display: none; }
/* Important: details action has its own row, so it can never cover location/time. */
.teamilo-event-accordion > .teamilo-event-accordion-toggle {
  display: block;
  position: static;
  clear: both;
  float: none;
  width: auto;
  max-width: 100%;
  margin: 14px 0 0 auto;
  padding: 9px 14px;
  min-height: 40px;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
}
.teamilo-event-accordion > .teamilo-event-accordion-content { clear: both; }
@media (max-width: 480px) {
  .teamilo-event-accordion > .cardheader { column-gap: 10px; row-gap: 8px; grid-template-columns: 58px minmax(0, 1fr) minmax(58px, 68px); }
  .teamilo-event-accordion > .cardheader > .teamilo-event-logo { max-width: 68px; }
  .teamilo-event-accordion > .teamilo-event-accordion-toggle { margin-top: 12px; width: 100%; }
}

/* source: /static/teamilo-event-count-dedupe.css */
/* TEAMilo 0.10.39: hide only the repeated confirmation total in expanded event details.
   The confirmation count in the compact card remains visible. Meeting details,
   chat/edit buttons and attendance controls remain unchanged. */
[data-upcoming-events] .teamilo-event-accordion:has(> .cardheader .teamilo-event-accordion-count)
  > .teamilo-event-accordion-content > .actions > span.pill:first-child,
.event-archive-content .teamilo-event-accordion:has(> .cardheader .teamilo-event-accordion-count)
  > .teamilo-event-accordion-content > .actions > span.pill:first-child,
[data-event-archive] .teamilo-event-accordion:has(> .cardheader .teamilo-event-accordion-count)
  > .teamilo-event-accordion-content > .actions > span.pill:first-child {
  display: none !important;
}

/* source: /static/teamilo-event-pending-near-count.css */
/* TEAMilo 0.10.41: one shared line for confirmations and pending personal RSVP. */
[data-upcoming-events] .teamilo-event-accordion .teamilo-event-status-inline {
  display: flex;
  flex-flow: row wrap;
  align-items: center;
  justify-content: flex-start;
  column-gap: 9px;
  row-gap: 5px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin-top: 8px;
  line-height: 1.35;
}
[data-upcoming-events] .teamilo-event-accordion .teamilo-event-status-inline > .teamilo-event-accordion-count,
[data-upcoming-events] .teamilo-event-accordion .teamilo-event-status-inline > .teamilo-event-pending-inline {
  position: static !important;
  float: none !important;
  inset: auto !important;
  margin: 0 !important;
  min-width: 0;
  max-width: 100%;
  height: auto;
  line-height: 1.35;
  white-space: normal;
  overflow-wrap: anywhere;
}

:root{--ap-canvas:#f0f0f0;--ap-surface:#ffffff;--ap-text:#151515;--ap-muted:#525252;--ap-line:#15151530;--ap-soft:#e5e5e5;--ap-primary:#eaff00;--ap-on-primary:#101010;--ap-link:#2e2e2e;--ap-highlight:#eaff00;--ap-on-highlight:#101010;--ap-nav:#101010;color-scheme:light}
:root[data-tm-mode="dark"]{--ap-canvas:#171717;--ap-surface:#252525;--ap-text:#f4f4f4;--ap-muted:#c2c2c2;--ap-line:#88888855;--ap-soft:#343434;--ap-primary:#eaff00;--ap-on-primary:#101010;--ap-link:#eaff00;--ap-highlight:#eaff00;--ap-on-highlight:#101010;--ap-nav:#101010;color-scheme:dark}
@media(prefers-color-scheme:dark){:root:not([data-tm-mode]){--ap-canvas:#171717;--ap-surface:#252525;--ap-text:#f4f4f4;--ap-muted:#c2c2c2;--ap-line:#88888855;--ap-soft:#343434;--ap-primary:#eaff00;--ap-on-primary:#101010;--ap-link:#eaff00;--ap-highlight:#eaff00;--ap-on-highlight:#101010;--ap-nav:#101010;color-scheme:dark}}
/* Teamilo personal appearance v1. Semantic tokens: four palettes, two modes. */








html[data-tm-design]{
 --tm-blue:var(--ap-link);--tm-ink:var(--ap-text);--tm-canvas:var(--ap-canvas);--tm-ice:var(--ap-soft);
 --tm-coral:var(--ap-highlight);--tm-surface:var(--ap-surface);--tm-muted:var(--ap-muted);--tm-line:var(--ap-line);--tm-coral-soft:var(--ap-soft);
 --teamilo-blue:var(--ap-link);--teamilo-navy:var(--ap-text);--teamilo-white:var(--ap-surface);--teamilo-ice:var(--ap-soft);
 --teamilo-coral:var(--ap-highlight);--teamilo-muted:var(--ap-muted);--teamilo-border:var(--ap-line);
 --primary:var(--ap-primary);--accent:var(--ap-highlight);--line:var(--ap-line);
 background:var(--ap-canvas);color:var(--ap-text);accent-color:var(--ap-link);
}
html[data-tm-design] body,html[data-tm-design] #app :is(.app,.main,.frame){background:var(--ap-canvas);color:var(--ap-text)}
html[data-tm-design] #app :is(.card,.stat,.modal,.authcard,.channel,.chatpanel,.bottom,.team-pill,.teamilo-profile-section,.org-card,.org-panel,.poll-option){background:var(--ap-surface);color:var(--ap-text);border-color:var(--ap-line)}
html[data-tm-design] #app :is(h1,h2,h3,.teamilo-profile-section-title){color:inherit}
html[data-tm-design] #app :is(small,.muted,.sub,.empty,.fieldwrap label,.teamilo-logo-message,.teamilo-privacy-status,.teamilo-profile-empty){color:var(--ap-muted)}
html[data-tm-design] #app :is(.soft,.notice,.datebox,.avatar,.pill,.pill.match,.guardian-chip,.player-state,.channel.active,.bubble.mine,.bubble.system,.display-name-form,.teamilo-logo-panel,.teamilo-photo-child,.teamilo-profile-page .person,.home-chat-cta,.home-chat-cta:hover,.home-chat-cta-icon,.poll-card,.poll-create,.poll-create-shortcut,.poll-option.chosen,.player-links,.player-invite,.teamilo-event-pending-inline){background:var(--ap-soft);color:var(--ap-text);border-color:var(--ap-line)}
html[data-tm-design] #app :is(.eyebrow,.link,a:not(.home-demo-ad),.datebox small,.stat .num,.bubble .who,.event-open-hint,.notice-hint,.event-summary-eyebrow,.member-player-links,.member-player-arrow){color:var(--ap-link)}
html[data-tm-design] #app :is(.home-chat-cta-content>span,.event-summary dt,.poll-option small){color:var(--ap-muted)}
html[data-tm-design] #app :is(.bubble,.event-summary,.event-summary dd,.event-summary-title){background:var(--ap-soft);color:var(--ap-text);border-color:var(--ap-line)}
html[data-tm-design] #app :is(.sidebar,.hero,.toast,.home-demo-ad){background:var(--ap-nav);color:#f8f9ff}
html[data-tm-design] #app .authwrap{background:var(--ap-nav)}
html[data-tm-design] #app :is(.hero p,.sidebar .foot,.sidebar button,.home-demo-ad-copy,.home-demo-ad-disclosure,.home-demo-ad-label){color:#e0e5ee}
html[data-tm-design] #app :is(.hero .eyebrow,.sidebar .brand b){color:var(--ap-highlight)}
html[data-tm-design] #app :is(.sidebar button.active,.sidebar button:hover){background:var(--ap-primary);color:var(--ap-on-primary)}
/* Logo contrast follows its actual surface, including the always-dark sidebar. */
html[data-tm-design] #app :is(.brand-logo,.mobile-top-logo){filter:brightness(0)}
html[data-tm-design][data-tm-mode="dark"] #app :is(.brand-logo,.mobile-top-logo){filter:brightness(0) invert(1)}
html[data-tm-design] #app .sidebar .brand-logo-wrap{background:transparent;box-shadow:none}
html[data-tm-design] #app .sidebar .brand-logo{filter:brightness(0) invert(1)}
html[data-tm-design] #app :is(input,textarea,select,.field){background:var(--ap-surface);color:var(--ap-text);border-color:var(--ap-line);min-width:0}
html[data-tm-design] #app :is(input,textarea)::placeholder{color:var(--ap-muted);opacity:1}
html[data-tm-design] #app :is(input,select,textarea):focus{border-color:var(--ap-link);box-shadow:none}
html[data-tm-design] #app :is(button,a,input,select,textarea,summary):focus-visible{outline:3px solid var(--ap-link);outline-offset:3px}
html[data-tm-design] #app .btn,html[data-tm-design] #app .teamilo-profile-page button.btn:not(.light):not(.outline),html[data-tm-design] #app .choice.selected.yes{background:var(--ap-primary);color:var(--ap-on-primary);border-color:var(--ap-primary)}
html[data-tm-design] #app :is(.btn.light,.btn.outline,.teamilo-photo-select,.teamilo-logo-controls button,.player-arrows button,.choice:not(.selected)){background:var(--ap-soft);color:var(--ap-link);border-color:var(--ap-line)}
html[data-tm-design] #app :is(.btn.accent,.testtag,.choice.selected.no){background:var(--ap-highlight);color:var(--ap-on-highlight);border-color:var(--ap-highlight)}
html[data-tm-design] #app .choice.selected.maybe{background:var(--ap-soft);color:var(--ap-text);border:1px dashed var(--ap-link)}
html[data-tm-design] #app .unread-badge{background:var(--ap-highlight)!important;color:var(--ap-on-highlight)!important}
html[data-tm-design] #app .bottom button{color:var(--ap-muted);min-width:0;flex:1}
html[data-tm-design] #app .bottom button.active{color:var(--ap-link)}
html[data-tm-design] #app .bottom button.active::after{content:'';height:3px;width:18px;background:currentColor;border-radius:2px}
html[data-tm-design] #app :is(.teamilo-open-notification,.home-global-event,.home-global-event.teamilo-event-unanswered,.home-data-warning){background:var(--ap-surface);color:var(--ap-text);border-color:var(--ap-line)}
html[data-tm-design] #app :is(.teamilo-open-notification strong,.teamilo-open-notification-detail,.home-global-event-title){color:var(--ap-text)}
html[data-tm-design] #app :is(.teamilo-unanswered-label,.home-global-alert .home-team-tag){background:var(--ap-soft);color:var(--ap-text);border-color:var(--ap-highlight)}
html[data-tm-design] #app .modalback{background:rgba(5,8,18,.72)}
html[data-tm-design] #app :is(.person,.chat-title,.chatcompose,.event-summary-row,.invite-row){border-color:var(--ap-line)}
html[data-tm-design] #app .div{background:var(--ap-line)}
html[data-tm-design] #app .poll-result-track span{background:var(--ap-primary)}
html[data-tm-design] #app .teamilo-profile-page .teamilo-privacy-choice input{accent-color:var(--ap-link)}
html[data-tm-design] #app .tm-appearance{border-top:4px solid var(--ap-primary);min-width:0;overflow-wrap:anywhere}
.tm-appearance-intro{font-size:16px;line-height:1.6;color:var(--ap-muted);margin:0 0 22px;max-width:60ch}
.tm-design-field{border:0;padding:0;margin:0 0 22px;min-width:0}
.tm-design-field legend,.tm-mode-label{font-size:16px;font-weight:750;margin-bottom:10px;display:block}
.tm-design-options{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.tm-design-option{position:relative;display:grid;grid-template-columns:22px minmax(0,1fr);align-items:center;gap:10px;padding:14px;border:2px solid var(--ap-line);border-radius:15px;cursor:pointer;font-size:16px;line-height:1.4;min-width:0;background:var(--ap-surface)}
.tm-design-option:has(input:checked){border-color:var(--ap-link);background:var(--ap-soft)}
.tm-design-option:has(input:focus-visible){outline:3px solid var(--ap-link);outline-offset:3px}
html[data-tm-design] #app .tm-design-option input{width:20px;height:20px;margin:0;grid-column:1;grid-row:2;accent-color:var(--ap-link)}
.tm-design-option>span:last-child{grid-column:2;grid-row:2;font-weight:750}
.tm-design-preview{grid-column:1/-1;display:flex;align-items:center;gap:7px;height:66px;border-radius:9px;padding:13px;background:#0c120b}
.tm-design-preview i{display:block;height:100%;border-radius:4px;flex:1;background:#b8ff36}
.tm-design-preview i:nth-child(2){background:#edf5e7;flex:.48}.tm-design-preview i:nth-child(3){background:#47643a;flex:.28}
.tm-design-preview[data-preview="electric-blue"]{background:#171033}.tm-design-preview[data-preview="electric-blue"] i{background:#2348ff}.tm-design-preview[data-preview="electric-blue"] i:nth-child(2){background:#efff50}.tm-design-preview[data-preview="electric-blue"] i:nth-child(3){background:#e8ecff}
.tm-design-preview[data-preview="red-rally"]{background:#281a16}.tm-design-preview[data-preview="red-rally"] i{background:#ff4335}.tm-design-preview[data-preview="red-rally"] i:nth-child(2){background:#fff5e9}.tm-design-preview[data-preview="red-rally"] i:nth-child(3){background:#ffb19b}
.tm-design-preview[data-preview="luminous-orange"]{background:#15172e}.tm-design-preview[data-preview="luminous-orange"] i{background:#3046c8}.tm-design-preview[data-preview="luminous-orange"] i:nth-child(2){background:#ff8b4d}.tm-design-preview[data-preview="luminous-orange"] i:nth-child(3){background:#f7f2ee}
#tm-appearance-mode{width:100%;max-width:380px;min-height:48px}
.tm-appearance-status{font-size:15px;line-height:1.5;color:var(--ap-muted);margin-top:16px;min-height:23px}
.tm-appearance[data-error="true"] .tm-appearance-status{color:var(--ap-text);font-weight:700}
.tm-appearance-retry{margin-top:10px}.tm-appearance [hidden]{display:none!important}
@media(max-width:380px){.tm-design-options{grid-template-columns:minmax(0,1fr)}.tm-design-preview{height:50px}.tm-design-option{padding:12px}}
@media(prefers-reduced-motion:reduce){.tm-appearance *{transition:none!important;animation:none!important}}
@media(forced-colors:active){.tm-design-option:has(input:checked){outline:3px solid Highlight}.tm-design-preview{forced-color-adjust:none}.bottom button.active{border-bottom:3px solid Highlight}}
/* Keep existing dashboard statistics inside narrow viewports. */
html[data-tm-design] #app .stats{grid-template-columns:repeat(3,minmax(0,1fr))}
html[data-tm-design] #app .stat{min-width:0;overflow-wrap:anywhere}

/* Teamilo logo repair v3: actual transparent asset, explicit surface contrast. */
html body #app .brand-logo-wrap,
html body #app .tm-logo-wrapper-v3{
 background:transparent!important;background-image:none!important;
 border-color:transparent!important;box-shadow:none!important;
}
html body #app img.tm-logo-v3{
 background:transparent!important;background-image:none!important;
 opacity:1!important;mix-blend-mode:normal!important;
 filter:brightness(0)!important;object-fit:contain;
}
html[data-tm-mode="dark"] body #app img.tm-logo-v3{
 filter:brightness(0) invert(1)!important;
}
/* The navigation sidebar has a dark surface in both light and dark mode. */
html body #app .sidebar img.tm-logo-v3{
 filter:brightness(0) invert(1)!important;
}

/* System mode before the personal preference has loaded. */
@media(prefers-color-scheme:dark){html:not([data-tm-mode]) body #app img.tm-logo-v3{filter:brightness(0) invert(1)!important}}

/* Teamilo pending-work highlight 4.2 */
:root{--ap-task-bg:#efff80;--ap-task-text:#202400;--ap-task-chip:#f5ffb0;}
:root[data-tm-mode="dark"]{--ap-task-bg:#efff80;--ap-task-text:#202400;--ap-task-chip:#f5ffb0;}
@media(prefers-color-scheme:dark){:root:not([data-tm-mode]){--ap-task-bg:#efff80;--ap-task-text:#202400;--ap-task-chip:#f5ffb0;}}
/* Filled surfaces identify pending work independently of hover or focus. */
html[data-tm-design] #app :is(.card.teamilo-event-unanswered,.teamilo-event-accordion:has(.teamilo-unanswered-label),.teamilo-open-notification,.home-priority-block .home-global-alert){
 background:var(--ap-task-bg);color:var(--ap-task-text);--ap-link:var(--ap-task-text);opacity:1;
 /* Match ordinary cards; replace the legacy 2px pending-state border too. */
 border:1px solid var(--ap-line);
}
html[data-tm-design] #app :is(.card.teamilo-event-unanswered,.teamilo-event-accordion:has(.teamilo-unanswered-label),.teamilo-open-notification,.home-priority-block .home-global-alert):hover{
 background:var(--ap-task-bg);
}
html[data-tm-design] #app :is(.card.teamilo-event-unanswered,.teamilo-event-accordion:has(.teamilo-unanswered-label),.teamilo-open-notification,.home-priority-block .home-global-alert) :is(h3,strong,small,.sub,.muted,.home-global-event-title,.home-global-details>span,.home-global-arrow,.event-open-hint,.teamilo-open-notification-detail,.attendance-heading,.teamilo-event-time,.teamilo-event-place){color:var(--ap-task-text)}
html[data-tm-design] #app :is(.card.teamilo-event-unanswered,.teamilo-event-accordion:has(.teamilo-unanswered-label),.teamilo-open-notification,.home-priority-block .home-global-alert) :is(.datebox,.home-global-date,.home-team-tag,.pill,.teamilo-event-accordion-count,.teamilo-unanswered-label,.teamilo-event-pending-inline,.teamilo-event-accordion-toggle){
 background:var(--ap-task-chip);color:var(--ap-task-text);
}
html[data-tm-design] #app :is(.card.teamilo-event-unanswered,.teamilo-event-accordion:has(.teamilo-unanswered-label)) :is(.btn.light,.btn.outline,.choice:not(.selected)){
 background:var(--ap-surface);color:var(--ap-text);border-color:var(--ap-line);
}

/* Teamilo unified action buttons 4.3 */
/* One semantic action colour in all four palettes, in light and dark mode.
   Keep this in the active complete design file. These narrow colour overrides
   also beat component and pending-card variants, including their hover states.
   Clickable event/notification cards and navigation retain their own surfaces. */
html[data-tm-design] :is(#app,.modalback,.teamilo-photo-dialog,#teamilo-module-overlay) :is(.btn,.choice,.teamilo-photo-select,.teamilo-logo-controls button,.player-arrows button,.teamilo-event-accordion-toggle,.teamilo-photo-close,:where(#teamilo-org-root) button){
 background:var(--ap-primary)!important;
 color:var(--ap-on-primary)!important;
 border-color:var(--ap-primary)!important;
}
html[data-tm-design] :is(#app,.modalback,.teamilo-photo-dialog,#teamilo-module-overlay) :is(.btn,.choice,.teamilo-photo-select,.teamilo-logo-controls button,.player-arrows button,.teamilo-event-accordion-toggle,.teamilo-photo-close,:where(#teamilo-org-root) button) :where(strong,small,.sub,.muted,.eyebrow,svg){color:inherit!important}
/* A saved response remains recognisable without a second button colour. */
html[data-tm-design] :is(#app,.modalback,#teamilo-module-overlay) :is(.choice.selected,.btn[aria-pressed="true"]){
 box-shadow:inset 0 0 0 2px var(--ap-on-primary);
 text-decoration:underline;
 text-decoration-thickness:2px;
 text-underline-offset:3px;
}
html[data-tm-design] :is(#app,.modalback,.teamilo-photo-dialog,#teamilo-module-overlay) .teamilo-photo-select:focus-within{outline:3px solid var(--ap-link);outline-offset:3px}
@media(forced-colors:active){
 html[data-tm-design] :is(#app,.modalback,#teamilo-module-overlay) :is(.choice.selected,.btn[aria-pressed="true"]){outline:2px solid Highlight;outline-offset:2px}
}

/* Teamilo complete surfaces 4.4 */
/* Semantic surfaces apply to all application pages, including body-mounted dialogs. */
html[data-tm-design]{--ap-shadow:0 2px 8px color-mix(in srgb,var(--ap-text) 4%,transparent)}
html[data-tm-design] body,html[data-tm-design] :is(.app,.main,.frame,.org-page,.chat-layout.tm-chat-detail,.chatlog,.tm-chat-scroll,.org-message-list){background:var(--ap-canvas)!important;color:var(--ap-text)!important}
html[data-tm-design] :is(.card,.stat,.channel,.chatpanel,.team-pill,.authcard,.modal,.teamilo-profile-section,.org-panel,.org-stats article,.org-section-choice,.org-msg,.teamilo-module-dialog,.teamilo-photo-dialog,.tm-message-menu,:where(#tm-forward-dialog,#tm-delete-dialog),.event-preview,.home-global-event,.teamilo-open-notification,.home-global-alert,.notice,.home-data-warning){
 background:var(--ap-surface)!important;color:var(--ap-text)!important;border-color:var(--ap-line)!important;box-shadow:var(--ap-shadow);
}
html[data-tm-design] #app #teamilo-org-root .org-section-choice{background:var(--ap-surface)!important;color:var(--ap-text)!important;border-color:var(--ap-line)!important}
html[data-tm-design] :is(.bottom,.tm-chat-navigation-bar,.chat-title,.chatcompose,#chatform){background:var(--ap-surface)!important;color:var(--ap-text)!important;border-color:var(--ap-line)!important}
html[data-tm-design] :is(.soft,.datebox,.home-global-date,.avatar,.pill,.guardian-chip,.player-state,.display-name-form,.teamilo-logo-panel,.teamilo-photo-child,.teamilo-profile-page .person,.home-chat-cta,.home-chat-cta-icon,.poll-card,.poll-create,.poll-create-shortcut,.task-card,.task-create,.task-row,.task-count,.task-count-badge,.player-links,.player-invite,.teamilo-event-pending-inline,.teamilo-unanswered-label,.home-team-tag,.module-review,.module-progress,.bubble,.bubble.system,.event-summary,.event-summary dd,.event-summary-title){background:var(--ap-soft)!important;color:var(--ap-text)!important;border-color:var(--ap-line)!important}
html[data-tm-design] :is(.poll-option,.bubble.mine){background:var(--ap-surface)!important;color:var(--ap-text)!important;border-color:var(--ap-line)!important}
html[data-tm-design] :is(.channel.active,.poll-option.chosen){background:var(--ap-soft)!important;color:var(--ap-text)!important;border-color:var(--ap-primary)!important}
html[data-tm-design] :is(.card.teamilo-event-unanswered,.teamilo-event-accordion:has(.teamilo-unanswered-label),.teamilo-open-notification,.home-priority-block .home-global-alert,.org-action-queue:has(.org-request),.org-open-first>[data-org-open-claims]:has(.org-request),.org-open-notification){
 --ap-surface:var(--ap-task-bg);--ap-soft:var(--ap-task-chip);--ap-text:var(--ap-task-text);--ap-muted:var(--ap-task-text);--ap-link:var(--ap-task-text);opacity:1;
 background:var(--ap-task-bg)!important;color:var(--ap-task-text)!important;border:1px solid var(--ap-line)!important;box-shadow:var(--ap-shadow);
}
html[data-tm-design] :is(#app,.modalback,.teamilo-module-dialog,.teamilo-photo-dialog,#tm-forward-dialog,#tm-delete-dialog) :is(h1,h2,h3,h4,strong,dt,dd,.event-summary-title,.teamilo-profile-section-title,.home-global-event-title,.home-global-details>span,.teamilo-open-notification-detail,.teamilo-event-time,.teamilo-event-place,.attendance-heading,.org-page,.module-review dd){color:inherit}
html[data-tm-design] :is(#app,.modalback,.teamilo-module-dialog,.teamilo-photo-dialog,#tm-forward-dialog,#tm-delete-dialog) :is(small,.sub,.muted,.empty,.org-hint,.org-head small,.org-line small,.org-member-card small,.org-role-entry small,.module-hint,.module-stepnote,.module-review dt,.teamilo-logo-message,.teamilo-privacy-status,.teamilo-profile-empty,.fieldwrap label,.home-chat-cta-content>span,.poll-option small){color:var(--ap-muted)!important}
html[data-tm-design] :is(#app,.modalback,.teamilo-module-dialog,.teamilo-photo-dialog,#tm-forward-dialog,#tm-delete-dialog) :is(input,select,textarea){background:var(--ap-surface)!important;color:var(--ap-text)!important;border-color:var(--ap-line)!important;accent-color:var(--ap-link)}
html[data-tm-design] :is(input,select,textarea)::placeholder{color:var(--ap-muted)!important;opacity:1}
html[data-tm-design] :is(.person,.invite-row,.org-line,.org-member-card,.org-role-entry,.org-request,.org-editor-form,.org-panel p,.teamilo-module-head,.module-footer,.module-item,.event-summary-row,.task-row,.poll-card,.poll-option,.chat-title,.chatcompose,.teamilo-profile-page .person:last-of-type){border-color:var(--ap-line)!important}
html[data-tm-design] :is(.org-error,.module-error){background:var(--ap-soft)!important;color:var(--ap-text)!important;border:1px solid var(--ap-line)}
html[data-tm-design] :is(.sidebar,.hero,.toast,.home-demo-ad){--ap-text:#f8f9ff;--ap-muted:#e0e5ee;background:var(--ap-nav)!important;color:var(--ap-text)!important}
html[data-tm-design] :is(.modalback,.teamilo-module-overlay){background:color-mix(in srgb,var(--ap-nav) 72%,transparent)!important}
html[data-tm-design] :is(.teamilo-photo-dialog,#tm-forward-dialog,#tm-delete-dialog)::backdrop{background:color-mix(in srgb,var(--ap-nav) 72%,transparent)}
html[data-tm-design] :is(.tm-chat-back,.tm-message-controls button,.tm-message-menu button,#tm-forward-dialog button,#tm-delete-dialog button,.org-entry){background:var(--ap-primary)!important;color:var(--ap-on-primary)!important;border-color:var(--ap-primary)!important}
html[data-tm-design] :is(.tm-message-menu button:hover,.tm-message-menu button:focus-visible){text-decoration:underline}
html[data-tm-design] :is(.teamilo-event-accordion-count,.teamilo-unanswered-label,.teamilo-event-pending-inline){color:var(--ap-text)!important;border-color:var(--ap-line)!important}
html[data-tm-design] :is(.link,.event-open-hint,.member-player-links,.member-player-arrow,.org-member-edit summary,.bubble .who,.org-stats b){color:var(--ap-link)!important}
html[data-tm-design] :is(.org-open-first .org-action-queue,.org-open-first>[data-org-open-claims]){border:1px solid var(--ap-line)!important}
html[data-tm-design] :is(.teamilo-avatar-trigger,.teamilo-logo-preview){background:var(--ap-soft)!important;color:var(--ap-text)!important;border-color:var(--ap-line)!important}
html[data-tm-design] :is(.attendance-reason,.poll-eyebrow,.poll-chooser label){color:var(--ap-text)!important}
html[data-tm-design] fieldset{border-color:var(--ap-line)}
html[data-tm-design] :is(.poll-result-track,.task-progress){background:var(--ap-soft)!important}
html[data-tm-design] :is(.poll-result-track span,.task-progress span){background:var(--ap-primary)!important}
html[data-tm-design] :is(button,a,input,select,textarea,summary):focus-visible{outline:3px solid var(--ap-link);outline-offset:3px}
/* Keep controls and input text readable inside highlighted cards. */
html[data-tm-design] :is(.btn,.choice,.tm-chat-back,.tm-message-controls button,.tm-message-menu button) :where(small,strong,.sub,.muted){color:inherit!important}

/* Teamilo fifth design preview 5.0 */
.tm-design-preview[data-preview="neon-graphite"]{background:#101010}.tm-design-preview[data-preview="neon-graphite"] i{background:#eaff00}.tm-design-preview[data-preview="neon-graphite"] i:nth-child(2){background:#777777}.tm-design-preview[data-preview="neon-graphite"] i:nth-child(3){background:#eeeeee}
