:root{font-family:ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#172e29;background:#f8f9f4;font-synthesis:none;font-size:14px;--accent:#173b31;--line:#e1e6dc;--muted:#738077}
*{box-sizing:border-box}
body{margin:0}
button,input{font:inherit}
button{cursor:pointer;touch-action:manipulation}
button:disabled{cursor:not-allowed;opacity:.5}
button,input{-webkit-tap-highlight-color:transparent}
button:focus-visible,input:focus-visible{outline:3px solid #729d40;outline-offset:3px}
header{height:64px;display:flex;align-items:center;justify-content:space-between;gap:16px;padding:0 28px;background:#fff;border-bottom:1px solid var(--line)}
.app-title{font-size:15px;font-weight:650}
#identity{display:flex;align-items:center;gap:20px;min-width:0}
.header-note{font-size:13px;color:var(--muted);overflow-wrap:anywhere}
main{max-width:1100px;margin:auto;padding:0 28px 32px}
h1,h2,p{margin-top:0}
h1{font-size:24px;letter-spacing:-.6px;font-weight:650}
h2{font-size:17px;letter-spacing:-.3px;font-weight:600;margin-bottom:12px}
p{line-height:1.6}
.signed-out header{display:none}
.signed-out main{padding:24px;max-width:none}
.login-layout{min-height:calc(100svh - 48px);display:grid;place-items:center}
.login-card{width:100%;max-width:380px;background:#fff;border:1px solid var(--line);border-radius:14px;padding:30px;box-shadow:0 8px 30px #213c2606}
.login-card h1{font-size:22px;margin-bottom:24px}
.segmented{display:flex;background:#f2f4ed;padding:4px;border-radius:8px;margin-bottom:24px;gap:4px}
.segmented button{width:50%;min-height:42px;border:0;background:none;border-radius:6px;color:var(--muted);font-weight:550}
.segmented button.active{color:#173b31;background:#fff;box-shadow:0 1px 4px #172e2914}
label{display:block;font-size:13px;font-weight:550}
input{min-width:0;min-height:44px;padding:10px 12px;border:1px solid #dce2d6;border-radius:7px;background:#fff;color:#172e29;font-size:16px}
input:disabled{background:#f8f9f4}
#password,#login-name{width:100%;display:block;margin:8px 0 20px}
.primary,.secondary{display:inline-flex;align-items:center;justify-content:center;gap:10px;min-height:42px;padding:10px 16px;border-radius:7px;font-size:13px;font-weight:550}
.primary{background:var(--accent);color:#d6f19b;border:1px solid var(--accent)}
.primary:hover{background:#28513d}
.secondary{background:#fff;border:1px solid #dce2d6;color:#173b31}
.secondary:hover{background:#f8f9f4}
.full{width:100%}
.text-button{border:0;background:transparent;color:var(--accent);font-size:12px;min-height:40px;padding:8px 0}
.text-button:hover{text-decoration:underline}
.danger{color:#c03636}
.error{color:#b42318;font-size:13px;line-height:1.5}
.error:empty{display:none}
.muted{color:var(--muted)}
.small{font-size:12px;line-height:1.6}
.eyebrow{font-size:11px;font-weight:550;color:var(--muted)}
.page-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:24px 0 20px}
.page-heading h1{margin:0}
.page-heading p{margin:5px 0 0;color:var(--muted)}
.pill{display:inline-flex;align-items:center;gap:5px;font-size:11px;line-height:1.4;white-space:nowrap;border-radius:6px;padding:5px 8px;background:#f2f4ed;color:#738077}
.pill.green{background:#e9f1d9;color:#4b702f}
.live-dot{display:inline-block;width:6px;height:6px;background:#78a843;border-radius:50%}
.panel{background:#fff;border:1px solid var(--line);border-radius:10px;padding:22px;min-width:0}
.judge-workspace{max-width:720px;margin:16px auto 0}
.team-picker{margin-bottom:14px;padding:14px 20px;border-radius:12px}
.team-picker-status{display:flex;align-items:center;gap:10px}
.team-picker-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.team-picker-heading label{font-size:12px}
.counter{font-size:12px;color:var(--muted);font-variant-numeric:tabular-nums}
.counter b{color:#173b31}
.team-picker-controls{display:flex;gap:8px}
.team-picker-controls select{flex:1;min-width:0;width:100%;min-height:46px;padding:10px 12px;background:#fbfcf8;border:1px solid #dce2d6;border-radius:8px;color:#173b31;font:inherit;font-size:16px;font-weight:550;text-overflow:ellipsis}
select:focus-visible{outline:3px solid #729d40;outline-offset:3px}
.team-progress{display:block;width:100%;height:4px;margin-top:14px;border:0;border-radius:4px;overflow:hidden;accent-color:#729d40;background:#edf0e5}
.team-progress::-webkit-progress-bar{background:#edf0e5}
.team-progress::-webkit-progress-value{background:#729d40}
.team-progress::-moz-progress-bar{background:#729d40}
.judge-workspace .score-panel{padding:0;border-radius:14px;box-shadow:0 4px 20px #173b3105}
.judge-team-header{display:flex;align-items:center;justify-content:space-between;gap:14px;background:#173b31;color:#fff;padding:24px;border-radius:13px 13px 0 0}
.judge-team-header .team-identification{margin:0;gap:16px;min-width:0}
.judge-team-header .team-photo{width:88px;height:78px;border:1px solid #ffffff20;border-radius:9px}
.team-initial{display:flex;align-items:center;justify-content:center;width:64px;height:64px;border-radius:12px;background:#d6f19b;color:#173b31;font-size:28px;font-weight:600;flex-shrink:0}
.judge-team-label{display:block;font-size:9px;letter-spacing:1.2px;color:#c0d1bb;margin-bottom:7px}
.judge-team-header h2{font-size:21px;line-height:1.25;letter-spacing:-.4px}
.judge-team-header .project-title{color:#d0ddc9;font-size:13px;line-height:1.5}
.judge-save-status{font-size:10px;white-space:nowrap;border:1px solid #ffffff30;color:#d6f19b;padding:6px 9px;border-radius:20px;align-self:flex-start}
.scorecard-instructions{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:18px 24px;font-size:12px;color:var(--muted);background:#fbfcf8;border-bottom:1px solid var(--line)}
.scorecard-instructions b{color:#173b31;font-weight:600}
#criteria-count{font-size:11px;white-space:nowrap;font-variant-numeric:tabular-nums}
.rating-criterion{min-width:0;border:0;border-bottom:1px solid var(--line);padding:20px 24px;margin:0}
.criterion-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:6px}
.criterion-name{display:flex;align-items:center;gap:9px}
.criterion-name h3{font-size:14px;font-weight:600;margin:0}
.criterion-index{font-size:10px;font-variant-numeric:tabular-nums;color:#95a28d}
.weight{font-size:10px;color:#617451;background:#f0f5e6;border-radius:4px;padding:3px 6px;font-weight:500}
.criterion-value{color:#9aa58f;font-size:12px;font-weight:550;font-variant-numeric:tabular-nums}
.answered .criterion-value{color:#37633a}
.rating-criterion p{font-size:12px;color:var(--muted);margin:0 0 16px}
.rating-options{display:grid;grid-template-columns:repeat(10,minmax(0,1fr));gap:5px;max-width:440px}
.rating-option{position:relative;cursor:pointer;display:flex;align-items:center;justify-content:center;padding:3px 0}
.rating-option input{position:absolute;opacity:0;width:1px;height:1px;min-height:0;padding:0;margin:0}
.rating-option span{display:flex;align-items:center;justify-content:center;width:100%;max-width:34px;aspect-ratio:1;border:1px solid #dce2d6;border-radius:50%;background:#fff;color:#53634d;font-size:12px;font-weight:550;transition:background .12s,border-color .12s,box-shadow .12s}
.rating-option:hover span{background:#f0f5e6;border-color:#a8bf84}
.rating-option input:checked+span{background:#173b31;border-color:#173b31;color:#d6f19b;box-shadow:0 0 0 3px #e9f1d9}
.rating-option input:focus-visible+span{outline:3px solid #729d40;outline-offset:3px}
.rating-option input:disabled+span{cursor:not-allowed;opacity:.65}
.judge-save-bar{position:sticky;bottom:0;background:#fff;padding:18px 24px calc(16px + env(safe-area-inset-bottom));border-top:1px solid var(--line);border-radius:0 0 14px 14px;box-shadow:0 -5px 16px #173b3105;z-index:2}
.score-bottom{display:flex;align-items:center;justify-content:space-between;gap:15px}
.score-bottom strong{display:block;font-size:27px;font-weight:600;margin-top:4px;letter-spacing:-.7px;font-variant-numeric:tabular-nums}
.score-bottom small{font-size:13px;font-weight:400;color:var(--muted);letter-spacing:0}
.score-bottom .primary{min-height:46px;min-width:156px;justify-content:space-between;background:#173b31;border-color:#173b31;border-radius:9px}
.score-bottom .primary:hover{background:#28513d}
#score-progress{font-size:11px;margin:9px 0 0}
#save-status:empty{display:none}
.visually-hidden{position:absolute;width:1px;height:1px;margin:-1px;padding:0;border:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.judge-workspace .notice{margin:16px 24px}
.stats{display:grid;grid-template-columns:repeat(4,1fr);border:1px solid var(--line);background:#fff;border-radius:9px;margin-bottom:22px}
.stats>div{padding:16px 20px;border-right:1px solid var(--line)}
.stats>div:last-child{border:0}
.stats>div>span{font-size:12px;color:var(--muted)}
.stats strong{display:block;font-size:23px;font-weight:600;margin-top:6px;font-variant-numeric:tabular-nums}
.stats strong small{font-size:13px;color:var(--muted);font-weight:400}
.stats .status-label{display:flex;align-items:center;gap:8px;font-size:18px;min-height:28px}
.tabs{display:flex;gap:24px;border-bottom:1px solid var(--line);margin-bottom:22px;overflow:auto}
.tabs button{background:none;border:0;border-bottom:2px solid transparent;padding:12px 0;font-size:13px;color:var(--muted);white-space:nowrap;min-height:44px}
.tabs .active{color:var(--accent);border-bottom-color:var(--accent);font-weight:550}
.section-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:16px}
.section-heading h2{margin:0 0 5px}
.section-heading p{font-size:12px;margin:0}
.table-scroll{padding:0;overflow-x:auto}
table{border-collapse:collapse;width:100%;text-align:left;white-space:nowrap;font-size:13px}
th{font-size:11px;font-weight:550;color:var(--muted);background:#fbfcf8}
th,td{padding:14px 18px}
td{border-top:1px solid var(--line)}
td:nth-child(2){white-space:normal;overflow-wrap:anywhere;min-width:130px}
td b{font-weight:550}
.rank{display:inline-flex;align-items:center;justify-content:center;min-width:25px;height:25px;color:var(--muted)}
.rank.first{background:#d6f19b;color:var(--accent);border-radius:5px}
.result-score{font-size:18px;font-weight:600;font-variant-numeric:tabular-nums}
.setup-grid{display:grid;grid-template-columns:1fr 1fr;gap:20px;align-items:start}
.setup-grid .panel>p{font-size:12px}
.setup-grid .panel>p:empty{display:none}
.inline-form{display:flex;gap:8px;margin:16px 0}
.inline-form input{flex:1;width:100%}
.inline-form button{white-space:nowrap}
#team-form,#judge-form{display:grid;grid-template-columns:minmax(0,1fr);gap:12px}
#team-form>.primary,#judge-form>.primary{width:100%;margin-top:4px;justify-content:center}
.simple-list>div{display:flex;align-items:center;justify-content:space-between;gap:12px;border-top:1px solid var(--line);padding:12px 0;font-size:13px}
.simple-list>div>div{display:grid;gap:4px;min-width:0}
.simple-list b{font-weight:550;overflow-wrap:anywhere}
.simple-list .muted{overflow-wrap:anywhere}
.judge-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:0 12px;max-width:210px}
.judge-actions .text-button{white-space:nowrap}
.weight-row{display:flex;align-items:center;justify-content:space-between;padding:10px 0;border-bottom:1px solid var(--line)}
.weight-row input{width:80px;text-align:center}
.formula{border-top:1px solid var(--line);margin-top:22px;padding-top:18px;color:var(--muted);font-size:12px;line-height:1.6}
.formula p{margin:8px 0}
.code-box{background:#f0f5e6;border:1px solid #dbe5cb;border-radius:7px;padding:16px;display:grid;gap:10px;font-size:13px;margin-bottom:14px}
.code-box code{font-size:21px;letter-spacing:2px;overflow-wrap:anywhere}
.notice{background:#fff8e6;color:#8a6418;border-radius:6px;padding:12px;font-size:12px;margin-bottom:14px}
.empty{padding:35px 18px;text-align:center;color:var(--muted);font-size:13px}
.loading{padding:60px;text-align:center;color:var(--muted)}
#toast{position:fixed;bottom:22px;left:50%;transform:translate(-50%,12px);opacity:0;pointer-events:none;z-index:20;max-width:calc(100% - 32px);width:max-content;background:#172e29;color:#fff;border-radius:8px;padding:13px 18px;font-size:13px;box-shadow:0 4px 18px #172e2920;transition:opacity .15s,transform .15s}
#toast.visible{opacity:1;transform:translate(-50%,0)}
@media(max-width:760px){
 header{height:58px;padding:0 18px}
 main{padding:0 16px 24px}
 .page-heading{padding:20px 0 16px}
 .setup-grid{grid-template-columns:minmax(0,1fr);gap:16px}
 .stats>div{padding:14px}
 .inline-form{flex-wrap:wrap}
 .inline-form button{width:100%}
}
@media(max-width:480px){
 .signed-out main{padding:20px}
 .login-layout{min-height:calc(100svh - 40px)}
 .login-card{padding:24px}
 h1{font-size:22px}
 #identity{gap:12px}
 .header-note{font-size:12px;max-width:130px}
 .app-title{font-size:14px}
 .panel{padding:18px}
 .table-scroll{padding:0}
 .stats{grid-template-columns:1fr 1fr}
 .stats>div{border-bottom:1px solid var(--line)}
 .stats>div:nth-child(2){border-right:0}
 .stats>div:nth-child(3){border-bottom:0}
 .tabs{gap:20px}
 .tabs button{font-size:12px}
 .rating-options{gap:3px}
 .rating-option span{font-size:11px}
 .team-picker{padding:12px 16px}
 .section-heading{align-items:flex-start}
 .section-heading .secondary{padding:10px 12px;white-space:nowrap}
 th,td{padding:12px}
 .judge-actions{max-width:155px;gap:0 10px}
 .judge-actions .text-button{font-size:11px}
}
@media(prefers-reduced-motion:reduce){*{transition:none!important}}

.team-identification{display:flex;align-items:center;gap:16px;margin-bottom:14px}
.team-identification-text{min-width:0}
.team-identification h2{margin:0;overflow-wrap:anywhere}
.team-photo{width:120px;height:90px;object-fit:cover;border-radius:9px;border:1px solid var(--line);flex-shrink:0}
.project-title{margin:6px 0 0;color:var(--muted);font-size:14px;overflow-wrap:anywhere}
.team-thumbnail{width:52px;height:44px;object-fit:cover;border-radius:6px;flex-shrink:0}
.file-label{font-size:12px;display:grid;gap:7px;width:100%;color:var(--muted)}
.file-label input{width:100%;font-size:12px;padding:8px;background:#fbfcf8}
.simple-list>.team-management{display:block}
.team-management>.team-management-summary{display:flex;align-items:center;gap:12px}
.team-management-summary>div{min-width:0;flex:1}
.team-actions{display:flex;align-items:center;gap:14px;flex-shrink:0}
.team-actions .text-button{white-space:nowrap}
.team-edit-form[hidden]{display:none}
.team-edit-form{display:grid;gap:12px;margin-top:10px}
.team-edit-form label{display:grid;gap:7px}
@media(max-width:480px){.team-photo{width:88px;height:74px}.team-identification{gap:12px}.project-title{font-size:13px}}

.submission-matrix th,.submission-matrix td{text-align:center;min-width:76px;padding:8px 10px}
.submission-matrix thead th{max-width:140px;white-space:normal;font-size:11px}
.submission-matrix th:first-child{position:sticky;left:0;z-index:1;text-align:left;min-width:130px;max-width:190px;white-space:normal;overflow-wrap:anywhere;border-right:1px solid var(--line)}
.submission-matrix tbody th{background:#fff;color:#173b31;font-size:13px;font-weight:550;border-top:1px solid var(--line)}
.submission-matrix tbody th .small{display:block;font-weight:400;font-size:11px;margin-top:2px}
.submission-matrix td:nth-child(2){white-space:nowrap;min-width:76px}
.submission-icon{display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;border-radius:50%;font-size:14px;font-weight:700}
.submission-icon.submitted{background:#e9f1d9;color:#4b702f}
.submission-icon.pending{background:#fee8e7;color:#c62828}
.submission-legend.pending{color:#c62828}
.submission-legend.submitted{color:#4b702f}

@media(max-width:480px){
 .judge-team-header{padding:18px;gap:8px;flex-wrap:wrap}
 .judge-team-header .team-identification{gap:12px;flex:1}
 .judge-team-header .team-photo{width:66px;height:66px}
 .team-initial{width:56px;height:56px;font-size:24px}
 .judge-team-header h2{font-size:19px}
 .judge-save-status{font-size:9px;padding:5px 7px}
 .scorecard-instructions{padding:15px 18px;font-size:11px}
 .rating-criterion{padding:18px}
 .criterion-name{gap:6px}
 .criterion-name h3{font-size:13px}
 .criterion-index{font-size:9px}
 .rating-criterion p{font-size:11px;margin-bottom:12px}
 .rating-options{gap:3px}
 .rating-option span{font-size:11px}
 .judge-save-bar{padding:16px 18px calc(12px + env(safe-area-inset-bottom))}
 .score-bottom .primary{min-width:140px}
 .judge-workspace .notice{margin:14px 18px}
}

.switch-dialog{width:calc(100% - 36px);max-width:360px;border:1px solid #dce2d6;border-radius:14px;padding:22px;color:#173b31;background:#fff;box-shadow:0 24px 80px #122c2830}
.switch-dialog::backdrop{background:#122c2866;backdrop-filter:blur(4px)}
.switch-dialog h2{font-size:17px;letter-spacing:-.3px;margin:14px 0 9px}
.switch-dialog p{font-size:12px;line-height:1.5;color:var(--muted);margin:0 0 14px}
.switch-dialog b{color:#173b31;font-weight:600}
.switch-icon{display:flex;align-items:center;justify-content:center;width:34px;height:34px;border-radius:50%;background:#e9f1d9;color:#4b702f;font-size:18px;font-weight:600}
.switch-missing{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:16px}
.switch-missing span{background:#f2f4ed;border-radius:5px;padding:5px 8px;font-size:11px}
.switch-dialog .switch-draft-note{font-size:11px;background:#f8f9f4;border:1px solid var(--line);border-radius:8px;padding:11px 12px}
.switch-dialog .error{color:#b42318}
.switch-actions{display:grid;gap:7px;margin-top:14px}
.switch-actions .primary{justify-content:center;min-height:40px;font-size:12px}
.switch-actions .text-button{color:#738077}
@media(max-width:480px){.switch-dialog{padding:22px}}

.judge-feedback{min-width:0;border:0;border-bottom:1px solid var(--line);padding:20px 24px;margin:12px 0 0}
.judge-feedback legend{padding:0;font-size:14px;font-weight:600}
.optional-label{font-size:10px;font-weight:400;color:var(--muted);margin-left:8px}
.judge-feedback>label{font-size:12px;margin-bottom:7px}
.judge-feedback textarea{display:block;width:100%;resize:vertical;min-height:68px;padding:11px 12px;font:inherit;font-size:14px;line-height:1.5;border:1px solid #dce2d6;border-radius:8px;background:#fbfcf8;color:#173b31;margin-bottom:16px}
.judge-feedback textarea:last-child{margin-bottom:0}
.judge-feedback textarea::placeholder{color:#95a28d;font-size:12px}
.judge-feedback textarea:focus-visible{outline:3px solid #729d40;outline-offset:2px}
.overall-feedback{padding-top:12px;padding-bottom:14px}
.overall-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}
.overall-option{position:relative;cursor:pointer;min-width:0}
.overall-option input{position:absolute;opacity:0;width:1px;height:1px;min-height:0;padding:0;margin:0}
.overall-option span{display:flex;align-items:center;justify-content:center;min-height:34px;border:1px solid #dce2d6;border-radius:6px;background:#fbfcf8;color:#53634d;font-size:11px;white-space:normal;text-align:center;line-height:1.25;padding:6px 4px}
.overall-option input:checked+span{background:#173b31;border-color:#173b31;color:#d6f19b}
.overall-option input:focus-visible+span{outline:3px solid #729d40;outline-offset:3px}
.overall-option input:disabled+span{cursor:not-allowed;opacity:.65}
@media(max-width:480px){.judge-feedback{padding:18px}.judge-feedback textarea{font-size:16px}.judge-feedback.overall-feedback{padding-top:10px;padding-bottom:12px}.overall-option span{font-size:10px}}
