.photo-editor{width:min(820px,calc(100% - 24px));max-height:calc(100dvh - 28px);overflow:auto;border:1px solid #4c8c97;border-radius:24px;background:#052832;color:#f5fafb;padding:30px;box-shadow:0 24px 100px #0008}.photo-editor::backdrop{background:#01171ccc;backdrop-filter:blur(7px)}.photo-editor-head{display:flex;justify-content:space-between;align-items:start;gap:18px}.photo-editor-head h2{font-size:30px;line-height:1.15;margin:10px 0}.photo-editor-head>button{border:1px solid #487780;background:#0b3f4b;color:#fff;border-radius:50%;width:38px;height:38px;font-size:24px;flex-shrink:0}.photo-editor-layout{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(190px,1fr);gap:26px}.photo-crop-stage{position:relative;width:100%;aspect-ratio:1;overflow:hidden;border-radius:16px;background:#031a22;touch-action:none;cursor:grab;border:1px solid #477a85}.photo-crop-stage:active{cursor:grabbing}.photo-crop-stage canvas{display:block;width:100%;height:100%}.photo-crop-mask{position:absolute;inset:4%;border-radius:50%;border:2px dashed #00f0df;box-shadow:0 0 0 120px #001319a8;pointer-events:none}.photo-crop-mask{inset:0;border-width:3px}.photo-crop-help,.photo-crop-controls p{font-size:12px;line-height:1.6;color:#c1dbe0}.photo-crop-controls{display:flex;flex-direction:column;gap:16px}.photo-crop-controls label{display:block;font-size:13px;font-weight:700;color:#f5fafb}.photo-crop-controls input[type=range]{width:100%;accent-color:#00f0df;margin-top:12px}.photo-crop-controls output{float:right;color:#00f0df}.photo-crop-file input{display:block;width:100%;font-size:11px;margin-top:9px;padding:8px;background:#0b414b;border-radius:8px;color:white}.photo-crop-arrows{display:flex;gap:8px}.photo-crop-arrows button{flex:1;padding:8px;border:1px solid #57848e;background:#0b414b;border-radius:10px;color:#fff;font-size:22px}.photo-small-preview{display:flex;align-items:center;gap:12px;font-size:12px;color:#c1dbe0}.photo-small-preview canvas{width:64px;height:64px;border-radius:50%;border:2px solid #a9c52a}.photo-editor-actions{display:flex;justify-content:flex-end;gap:12px;flex-wrap:wrap;border-top:1px solid #3a626d;padding-top:20px}.photo-editor #photo-editor-status{min-height:22px;font-size:13px;color:#b9ece8}.photo-editor #photo-editor-status.is-error{color:#ffc3b0}.photo-editor button:disabled{opacity:.5;cursor:wait}.club-admin-portraits{display:grid;grid-template-columns:repeat(auto-fill,minmax(190px,1fr));gap:12px;margin:20px 0}.club-admin-portrait{display:flex;gap:12px;align-items:center;border:1px solid #40616b;border-radius:12px;background:#082e3b;padding:12px;color:#f5fafb;text-align:left}.club-admin-portrait:hover{border-color:#00f0df}.club-admin-portrait span>small{display:block;font-size:11px;color:#b8d2da}.club-admin-portrait .ttc-photo{width:52px}.club-member-identity{display:flex;align-items:center;gap:12px}.club-member-identity .ttc-photo{width:44px}.club-player-portrait .ttc-photo img{object-position:center!important}.club-photo-settings #club-own-photo .ttc-photo{width:104px;border:3px solid #00d1c7}@media(max-width:600px){.photo-editor{padding:20px}.photo-editor-head h2{font-size:24px}.photo-editor-layout{grid-template-columns:1fr;gap:14px}.photo-crop-stage{max-width:320px;margin:auto}.photo-crop-controls{gap:12px}.photo-small-preview{display:none}.photo-editor-actions .btn{flex:1;padding:12px}}

.ttc-photo>img,.ttc-photo>.ttc-photo-fallback{grid-area:1/1;min-width:0;min-height:0}.ttc-photo>img{position:relative;z-index:1}.club-session-identity{display:inline-flex;align-items:center;gap:12px}.club-session-identity .ttc-photo{width:38px;height:38px}.club-check>.ttc-photo{width:38px;height:38px;flex:none}.scoreboard-logo .ttc-photo{width:100%;height:100%;border-radius:inherit}.scoreboard-logo .ttc-photo img{width:100%;height:100%;object-fit:cover;transform:none}.scoreboard-logo:has(.ttc-photo){padding:0;overflow:hidden}

.club-player-wrap{position:relative;min-width:0}.club-player-wrap .club-player-card{height:100%}.club-card-photo-edit{position:absolute;top:62px;left:15px;z-index:3;border:1px solid #00f0df;border-radius:9px;background:#052832eb;color:#fff;padding:8px 10px;font-size:11px;font-weight:700}.club-card-photo-edit[hidden]{display:none!important}.club-card-photo-edit:hover{background:#00f0df;color:#052832}.club-photo-tools{display:flex;flex-wrap:wrap;align-items:end;gap:20px;margin-bottom:22px}.club-photo-tools label{flex:1;min-width:190px}.club-photo-tools p{flex:1;margin:0 0 8px}.club-photo-bulk{margin-top:28px;border-top:1px solid #47727e;padding-top:20px}.club-photo-bulk summary{font-weight:700;color:#00f0df;cursor:pointer}.club-admin-portrait{flex-direction:column;align-items:stretch;text-align:center;padding:18px}.club-admin-portrait>.ttc-photo{width:128px;height:128px;align-self:center;border-radius:20px;border:2px solid #00d1c7;margin-bottom:8px}.club-admin-portrait>span>strong{display:block;color:#00f0df;font-size:12px;margin-top:12px}.club-admin-portrait>span>b{font-size:15px}.club-admin-portrait>span>small{margin-top:8px}@media(max-width:600px){.club-card-photo-edit{left:10px;top:48px;font-size:10px;padding:6px}.club-admin-portraits{grid-template-columns:repeat(2,minmax(0,1fr))}.club-admin-portrait{padding:12px}.club-admin-portrait>.ttc-photo{width:100px;height:100px}}
.club-player-wrap:nth-child(3n+2) .club-player-portrait{background:radial-gradient(ellipse at 50% 30%,#234f61,#092b3a 65%)}.club-player-wrap:nth-child(3n) .club-player-portrait{background:radial-gradient(ellipse at 50% 30%,#185d65,#052832 65%)}.club-player-wrap:nth-child(even) .club-player-ranking{background:#00f0df}

#player-profile .club-photo-settings{display:grid;grid-template-columns:285px minmax(0,1fr);gap:30px;align-items:center;padding:28px;background:linear-gradient(135deg,#052832,#0b3c48);border-radius:20px;border-color:#3c7986}.club-photo-previews{display:grid;grid-template-columns:82px minmax(0,1fr);gap:16px;align-items:center}.club-photo-round-preview{text-align:center}.club-photo-round-preview #club-own-photo .ttc-photo{width:76px;height:76px;border:3px solid #00f0df}.club-photo-round-preview small{display:block;font-size:10px;color:#c1dde1;margin-top:12px}.club-photo-preview-label{display:block;color:#00f0df;font-size:10px;font-weight:800;text-transform:uppercase;letter-spacing:.8px;margin-bottom:9px}.club-own-card{border:1px solid #92b7bf;border-radius:15px;overflow:hidden;background:#f5fafb;color:#052832;box-shadow:0 10px 28px #00131940}.club-own-card-portrait{aspect-ratio:4/4.3;position:relative;background:#083e49}.club-own-card-portrait>.ttc-photo{position:absolute;inset:0;width:100%;height:100%;border-radius:0}.club-own-card-caption{padding:14px;border-top:3px solid #00d1c7}.club-own-card-caption>small{display:block;color:#426670;font-size:11px}.club-own-card-caption>strong{display:block;color:#052832;font-size:21px;line-height:1.1;margin:5px 0 12px;overflow-wrap:anywhere}.club-own-card-caption>span{display:block;color:#426670;font-size:10px}.club-own-card-caption>span>b{color:#052832}.club-own-card-caption>a{display:block;margin-top:13px;padding-top:10px;border-top:1px solid #bbd1d7;color:#006b73;font-weight:800;font-size:10px}.club-own-card-empty{padding:22px 16px;border:1px dashed #578591;border-radius:15px;font-size:12px;color:#c1dbe0}.club-photo-settings-controls h3{font-size:26px;margin-top:13px}.club-photo-settings-controls .club-photo-format{font-size:11px;line-height:1.7;margin:17px 0 12px}.club-photo-settings-controls .club-photo-upload{align-items:stretch}.club-photo-settings-controls .club-photo-upload>label{width:100%;font-size:12px}.club-photo-settings-controls .club-photo-upload>label input{display:block;width:100%;margin-top:8px;border-radius:8px}.club-photo-settings-controls .club-photo-upload>.btn{padding:12px 16px;border-radius:8px;font-size:11px}@media(max-width:1100px){#player-profile .club-photo-settings{grid-template-columns:1fr}.club-photo-previews{max-width:285px;width:100%;margin:auto}}@media(max-width:600px){#player-profile .club-photo-settings{padding:22px 18px;gap:24px}.club-photo-settings-controls h3{font-size:24px}.club-photo-settings-controls .club-photo-upload>.btn{width:100%}}

#player-profile .club-own-card-edit{display:flex;align-items:center;justify-content:center;width:100%;margin-top:12px;padding:13px 10px;border-radius:10px;background:#00f0df;color:#052832;border:1px solid #00f0df;font-size:12px;font-weight:800;line-height:1.4;white-space:normal;text-align:center;cursor:pointer}#player-profile .club-own-card-edit:hover{background:#91fff2;border-color:#91fff2}#player-profile .club-own-card-edit:focus-visible{outline:3px solid #fff;outline-offset:3px}

.photo-crop-views{display:flex;flex-wrap:wrap;gap:8px;margin:16px 0 22px}.photo-crop-views button{border:1px solid #57848e;background:#0b414b;color:#fff;border-radius:9px;padding:10px 12px;font-size:12px;font-weight:700}.photo-crop-views button[aria-pressed=true]{background:#00f0df;border-color:#00f0df;color:#052832}.photo-crop-views button:focus-visible{outline:3px solid #fff;outline-offset:3px}.photo-editor[data-photo-view=card] .photo-crop-mask{border-radius:0;border:3px dashed #00f0df;box-shadow:none}.photo-editor[data-photo-view=card] .photo-crop-stage{border-radius:0}.photo-editor[data-photo-view=card] .photo-small-preview canvas{width:64px;height:auto;aspect-ratio:40/43;border-radius:0}.photo-editor[data-photo-view=profile] .photo-small-preview canvas{width:64px;height:64px;border-radius:50%}

/* Complete official directory in both administrative views. */
.admin-directory-shortcuts{margin:18px 0}.club-admin-portraits{grid-template-columns:repeat(auto-fill,minmax(290px,1fr))}.club-admin-portrait{align-items:flex-start}.club-admin-portrait .ttc-photo{width:64px;height:64px;flex:none}.admin-player-info{min-width:0;flex:1}.admin-player-info>small{display:block;color:#b8d2da;font-size:12px;margin:5px 0}.admin-player-actions{display:flex;flex-wrap:wrap;gap:9px;margin-top:10px}.admin-player-actions a{font-size:12px;color:#00f0df}.admin-player-actions button{font-size:12px;text-align:left}.admin-player-actions button:disabled{opacity:.55;cursor:not-allowed}#admin-member-directory{margin-bottom:24px}#admin-member-directory label{display:grid;gap:8px}#admin-member-directory input{width:100%}@media(max-width:600px){.club-admin-portraits{grid-template-columns:1fr}.admin-directory-shortcuts .btn{width:100%}}

/* Action remains accessible and requests authenticated administration. */
.admin-player-actions [data-photo-edit]{background:#00d1c7;color:#052832;border:1px solid #00f0df;cursor:pointer;font-weight:800;opacity:1}.admin-player-actions [data-photo-edit]:hover{background:#00f0df}.admin-player-actions [data-photo-edit]:focus-visible{outline:3px solid #fff;outline-offset:3px}
.admin-photo-login{width:min(520px,calc(100vw - 32px));max-height:calc(100dvh - 40px);overflow:auto;padding:28px;border:1px solid #00d1c7;border-radius:20px;background:#052832;color:#f5fafb;box-shadow:0 24px 80px #0008}.admin-photo-login::backdrop{background:#00141dc9}.admin-photo-login h2{margin:0 0 16px;font-size:25px}.admin-photo-login p{line-height:1.6}.admin-photo-login [data-photo-login-person]{color:#00f0df;font-weight:800}.admin-photo-login .club-button-row{display:flex;gap:12px;flex-wrap:wrap;margin:24px 0}.admin-photo-login .btn{white-space:normal;text-align:center}.admin-photo-login-help{font-size:12px;color:#c0dce0}.admin-photo-login [data-photo-login-cancel]{margin-top:12px;color:#f5fafb;cursor:pointer}

/* Dedicated portrait library; sports records live in the member directory. */
.photo-library-intro{margin-bottom:22px}.photo-library-intro h2{margin:10px 0;font-size:clamp(25px,3vw,36px)}.photo-library-intro p{color:#c0dce0;max-width:660px;line-height:1.6}.photo-library-counts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:26px}.photo-library-counts>div{padding:18px;border:1px solid #47727e;border-radius:14px;background:#083e49}.photo-library-counts b{display:block;font-size:30px;color:#00f0df}.photo-library-counts span{display:block;color:#f5fafb;font-size:12px;margin-top:5px}.photo-library-counts>div:last-child{background:#a9c52a;border-color:#a9c52a}.photo-library-counts>div:last-child b,.photo-library-counts>div:last-child span{color:#052832}.photo-library-filters{display:flex;flex-wrap:wrap;gap:9px;margin:20px 0}.photo-library-filters button{padding:11px 16px;border:1px solid #517e89;border-radius:30px;background:#083e49;color:#f5fafb;cursor:pointer;font-weight:700}.photo-library-filters button[aria-pressed=true]{background:#00f0df;border-color:#00f0df;color:#052832}.photo-library-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:18px}.photo-library-item{overflow:hidden;background:#f5fafb;border:1px solid #779da5;border-radius:18px;color:#052832;text-align:left}.photo-library-preview{position:relative;padding:16px 16px 0;background:linear-gradient(135deg,#083e49,#052832)}.photo-library-rectangle{aspect-ratio:40/43;overflow:hidden;border:1px dashed #77a6af;border-radius:10px;background:#0b3945}.photo-library-rectangle>.ttc-photo{display:grid;width:100%;height:100%;border-radius:0}.photo-library-rectangle .ttc-photo-fallback{display:grid;place-items:center;font-size:38px}.photo-library-rectangle img{width:100%;height:100%;object-fit:cover}.photo-library-badge{position:absolute;top:26px;left:26px;padding:6px 9px;border-radius:7px;background:#052832e8;color:#f5fafb;font-size:10px;font-weight:800}.photo-library-badge.needs-photo{background:#a9c52a;color:#052832}.photo-library-caption{padding:18px}.photo-library-caption h3{margin:0 0 6px;font-size:16px;line-height:1.4;color:#052832;overflow-wrap:anywhere}.photo-library-caption>small{font-size:11px;color:#426670}.photo-library-actions{display:flex;gap:8px;margin-top:16px;flex-wrap:wrap}.photo-library-actions .btn{flex:1;min-width:80px;padding:11px 9px;font-size:11px;border-radius:9px;white-space:normal;text-align:center;background:#00d1c7;color:#052832;border:1px solid #00d1c7;cursor:pointer;font-weight:800}.photo-library-actions .btn.secondary{background:#fff;border-color:#517e89;color:#083e49}.photo-library-actions .btn:hover{background:#00f0df;border-color:#00f0df;color:#052832}.photo-library-actions button:focus-visible,.photo-library-filters button:focus-visible{outline:3px solid #a9c52a;outline-offset:3px}.photo-library-empty{padding:24px;color:#c0dce0}.photo-library-item .ttc-photo[hidden],.photo-library-item .ttc-photo img[hidden],.photo-library-item .ttc-photo-fallback[hidden]{display:none!important}@media(max-width:600px){.photo-library-counts{gap:7px}.photo-library-counts>div{padding:12px 9px}.photo-library-counts b{font-size:24px}.photo-library-counts span{font-size:10px}.photo-library-grid{grid-template-columns:repeat(auto-fill,minmax(190px,1fr))}}

/* Override the legacy important button colors on the light photo-library cards. */
#admin .photo-library-actions .btn,#admin .photo-library-actions .btn.secondary,#admin .photo-library-actions .btn:hover{color:#052832!important;opacity:1}

/* Portraits and member cards: clear hierarchy, larger photos, aligned actions. */
#admin .club-admin-portraits{grid-template-columns:repeat(auto-fit,minmax(min(100%,290px),1fr));gap:18px;align-items:stretch}
#admin .club-admin-portrait{display:flex;flex-direction:column;align-items:stretch;padding:0;gap:0;overflow:hidden;text-align:left;border:1px solid #527d86;border-radius:18px;background:#f5fafb;color:#052832;box-shadow:0 8px 22px #00141b25}
#admin .admin-player-heading{display:flex;align-items:center;gap:18px;padding:22px;flex:1;border-top:4px solid #00d1c7;min-width:0}
#admin .club-admin-portrait:nth-child(3n+2) .admin-player-heading{border-top-color:#a9c52a}
#admin .admin-player-photo{display:block;width:106px;aspect-ratio:40/43;flex:none;padding:0;border:1px solid #588d96;border-radius:12px;overflow:hidden;cursor:pointer;background:#083e49}
#admin .admin-player-photo>.ttc-photo{display:grid;width:100%;height:100%;aspect-ratio:auto;border:0;border-radius:0;margin:0;background:radial-gradient(ellipse at 40% 25%,#216773,#052832)}
#admin .admin-player-photo .ttc-photo-fallback{font-size:28px;color:#dcf9f7}
#admin .admin-player-info{min-width:0;flex:1}
#admin .admin-player-kicker{display:block;font-size:9px;font-weight:800;letter-spacing:1px;color:#426670;margin-bottom:8px}
#admin .admin-player-info h3{color:#052832;font-size:19px;line-height:1.25;margin:0 0 9px;letter-spacing:0;overflow-wrap:anywhere}
#admin .admin-player-info>small{color:#426670;font-size:11px;margin:0}
#admin .admin-player-rank{display:inline-flex;align-items:center;gap:8px;margin-top:12px;padding:5px 9px;border-radius:7px;background:#d8eeed;color:#052832}
#admin .admin-player-rank small{font-size:10px;color:#31545d}
#admin .admin-player-rank b{font-size:15px;line-height:1.2}
#admin .admin-player-actions{display:grid;gap:11px;margin:0;padding:16px 22px 20px;border-top:1px solid #c9dcdf;background:#edf5f6}
#admin .admin-player-actions .link{display:block;font-size:12px;font-weight:800;color:#006b73;text-align:left}
#admin .admin-player-actions [data-photo-edit]{display:flex;justify-content:center;align-items:center;width:100%;min-height:43px;margin:0;padding:11px 12px;border-radius:9px;white-space:normal;text-align:center;font-size:12px;line-height:1.4;background:#00d1c7;border-color:#00d1c7;color:#052832!important}
#admin .admin-player-actions [data-photo-edit]:hover{background:#00f0df;border-color:#00f0df}
#admin .admin-player-photo:focus-visible,#admin .admin-player-actions a:focus-visible,#admin .admin-player-actions button:focus-visible{outline:3px solid #006b73;outline-offset:3px}
#admin .photo-library-grid{grid-template-columns:repeat(auto-fill,minmax(min(100%,250px),1fr));gap:22px;align-items:stretch}
#admin .photo-library-item{display:flex;flex-direction:column;border:1px solid #527d86;border-radius:18px;box-shadow:0 8px 22px #00141b25;background:#f5fafb}
#admin .photo-library-preview{display:block;position:relative;width:100%;padding:0;margin:0;border:0;border-radius:0;text-align:left;color:#f5fafb;cursor:pointer;background:#083e49;overflow:hidden}
#admin .photo-library-rectangle{display:block;width:100%;aspect-ratio:40/43;border:0;border-radius:0;overflow:hidden;background:radial-gradient(ellipse at 35% 20%,#21707a,#052832 75%)}
#admin .photo-library-rectangle>.ttc-photo{width:100%;height:100%;background:transparent;aspect-ratio:auto;border:0;border-radius:0}
#admin .photo-library-rectangle .ttc-photo-fallback{position:relative;font-size:58px;letter-spacing:2px;color:#d7f6f3}
#admin .photo-library-item.needs-photo .ttc-photo-fallback:before{content:'';position:absolute;inset:18%;border:1px solid #73b6bc44;border-radius:16px;transform:rotate(-9deg);pointer-events:none}
#admin .photo-library-badge{top:14px;left:14px;display:inline-flex;gap:6px;align-items:center;padding:7px 10px;border:1px solid #ffffff40;border-radius:7px;font-size:10px;line-height:1.2;box-shadow:0 3px 10px #00141b25}
#admin .photo-library-badge:before{content:'';width:5px;height:5px;background:#00f0df;border-radius:2px}
#admin .photo-library-badge.needs-photo:before{background:#052832}
#admin .photo-library-preview-hint{position:absolute;bottom:0;left:0;right:0;display:block;padding:26px 15px 12px;background:linear-gradient(transparent,#031d2be8);color:#f5fafb;font-weight:700;font-size:11px;text-align:right;pointer-events:none}
#admin .photo-library-preview:focus-visible{outline:3px solid #00f0df;outline-offset:-4px}
#admin .photo-library-preview:hover .photo-library-preview-hint{color:#00f0df}
#admin .photo-library-caption{display:flex;flex-direction:column;flex:1;padding:20px;border-top:3px solid #00d1c7}
#admin .photo-library-item.needs-photo .photo-library-caption{border-top-color:#a9c52a}
#admin .photo-library-caption h3{font-size:19px;line-height:1.25;letter-spacing:0;margin:0 0 8px;color:#052832;overflow-wrap:anywhere}
#admin .photo-library-caption>small{display:block;font-size:11px;line-height:1.5;letter-spacing:.3px;color:#426670;margin-bottom:20px}
#admin .photo-library-actions{display:flex;gap:9px;flex-wrap:wrap;margin: auto 0 0;padding-top:15px;border-top:1px solid #c9dcdf}
#admin .photo-library-actions .btn{flex:1 1 90px;min-width:0;min-height:43px;display:flex;justify-content:center;align-items:center;font-size:12px;line-height:1.35;padding:11px 10px;border-radius:9px}
#admin .photo-library-actions .btn.secondary{background:#fff;border-color:#93b1b8}
#admin .photo-library-actions .btn.secondary:hover{background:#e0f5f3;border-color:#00a79f}
#admin .photo-library-actions button:focus-visible{outline-color:#006b73}
@media(max-width:600px){
 #admin .club-admin-portraits{grid-template-columns:1fr;gap:14px}
 #admin .admin-player-heading{gap:16px;padding:18px}
 #admin .admin-player-photo{width:94px}
 #admin .admin-player-info h3{font-size:18px}
 #admin .admin-player-actions{padding:14px 18px 18px}
 #admin .photo-library-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
 #admin .photo-library-caption{padding:13px}
 #admin .photo-library-caption h3{font-size:15px}
 #admin .photo-library-caption>small{font-size:10px;margin-bottom:13px}
 #admin .photo-library-badge{top:9px;left:9px;padding:5px 7px;font-size:9px}
 #admin .photo-library-preview-hint{font-size:9px;padding:20px 10px 10px}
 #admin .photo-library-actions{flex-direction:column;gap:7px;padding-top:12px}
 #admin .photo-library-actions .btn{flex:auto;width:100%;font-size:11px}
 #admin .photo-library-rectangle .ttc-photo-fallback{font-size:38px}
}
@media(max-width:380px){#admin .photo-library-grid{grid-template-columns:1fr}}
