#careerDialog{width:min(620px,calc(100% - 20px));max-width:620px;padding:18px;overflow:hidden}
#closeCareer{position:absolute;right:8px;top:6px;border:0;background:none;font-size:23px;padding:2px 6px}
#careerContent h2{font-size:24px;margin:0 22px 5px 0}
#careerContent p{font-size:12px;line-height:1.35;margin:5px 0}
#careerContent h3{font-size:15px}
.career-muted{color:#a8c4b9}
.specialty-options{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.specialty-options small{display:block;font-size:10px;margin-top:5px;font-weight:400;color:#c1d1b6}
.worker-live{padding:7px;background:#28514b;border-radius:5px}
.specialty-options button{text-align:left;padding:9px;font-size:12px}
.worker-actions{display:flex;gap:5px;margin:10px 0}
.worker-actions button{flex:1;font-size:11px}
.field-dialog-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:12px 0}
.field-dialog-grid button{font-size:11px}
.field-dialog-grid small{display:block;color:#b6cbb5;font-size:10px;margin-top:4px}
#fieldDialog{overflow:hidden}
#fieldDialog h2{margin:0 0 7px}
.mission{bottom:94px!important;min-height:30px;max-width:290px}
.mission-copy .eyebrow,.mission-icon{display:none}
.mission-copy strong{font-size:11px}
@media(max-width:600px){.mission{max-width:calc(100% - 28px)}}

.business-heading{display:flex;gap:12px;align-items:baseline;justify-content:space-between;margin:0 25px 13px 0}
#careerContent .business-heading h2{margin:0}
.business-heading>span{font-size:11px;color:#edca80;text-align:right}
.business-layout{display:grid;grid-template-columns:1fr 1.1fr;gap:17px}
.business-finances,.business-improvements{min-width:0}
.business-profit{padding:12px;background:#264740;border:1px solid #47695b;border-radius:8px}
.business-profit>span{display:block;font-size:11px;color:#cfdbca}
.business-profit>strong{display:block;margin:4px 0;color:#f0d18d;font-size:28px;line-height:1.1;font-variant-numeric:tabular-nums}
.business-profit>strong.negative{color:#f0a88e}
.business-profit>small{display:block;font-size:10px;line-height:1.3;color:#b4cdbf}
.business-stats{display:grid;grid-template-columns:1fr 1fr;gap:10px 12px;margin:12px 0 0}
.business-stats div{min-width:0}
.business-stats dt{font-size:10px;color:#aac4b6}
.business-stats dd{margin:3px 0 0;font-size:16px;font-weight:600;font-variant-numeric:tabular-nums}
#careerContent .business-note{font-size:10px;line-height:1.3;margin:10px 0 0}
#careerContent .business-improvements h3{font-size:12px;margin:0 0 8px;font-weight:600}
.business-improvements>button{display:flex;align-items:center;justify-content:space-between;gap:9px;width:100%;padding:9px;text-align:left;margin-bottom:7px}
.business-improvements>button:last-child{margin-bottom:0}
.business-improvements>button>span{min-width:0}
.business-improvements strong{font-size:11px;line-height:1.2;display:block}
.business-improvements small{display:block;font-size:10px;line-height:1.25;font-weight:400;color:#bfd0bd;margin-top:4px}
.business-improvements b{flex-shrink:0;color:#e9c679;font-size:11px;white-space:nowrap;font-weight:600}
.business-improvements>button:disabled{opacity:.65}
.business-footer{display:flex;justify-content:space-between;gap:10px;margin-top:14px;padding-top:9px;border-top:1px solid #446256;color:#aec8b9;font-size:10px}
.business-debt{color:#edbe91}
.business-advance{display:flex;align-items:center;gap:10px;margin-top:10px}
.business-advance button{font-size:11px;padding:7px 9px;white-space:nowrap}
.business-advance small{font-size:10px;line-height:1.3;color:#b6caba}
@media(max-width:480px){
 #careerDialog.business-mode{padding:14px}
 .business-heading{margin-bottom:10px}
 .business-layout{grid-template-columns:1fr;gap:13px}
 .business-profit{padding:10px}
 .business-profit>strong{font-size:27px;margin:3px 0}
 .business-stats{gap:8px 12px;margin-top:10px}
 .business-stats dd{font-size:15px}
 #careerContent .business-note{margin-top:8px}
 .business-improvements>button{padding:8px;margin-bottom:6px}
 .business-improvements small{font-size:10px}
 .business-footer{margin-top:10px;padding-top:8px}
 .business-advance{margin-top:8px}
}
@media(max-height:540px){
 #careerDialog.business-mode{padding:11px}
 .business-heading{margin-bottom:8px}
 #careerContent .business-heading h2{font-size:21px}
 .business-layout{gap:12px}
 .business-profit{padding:9px}
 .business-profit>strong{font-size:24px;margin:3px 0}
 .business-stats{gap:7px 10px;margin-top:8px}
 .business-stats dd{font-size:14px}
 #careerContent .business-note{font-size:9px;margin-top:7px}
 #careerContent .business-improvements h3{font-size:11px;margin-bottom:6px}
 .business-improvements>button{padding:7px;margin-bottom:5px}
 .business-improvements strong,.business-improvements b{font-size:10px}
 .business-improvements small{font-size:9px;margin-top:3px}
 .business-footer{margin-top:9px;padding-top:7px}
 .business-advance{margin-top:7px}
 .business-advance button{padding:6px 8px}
}
@media(max-height:540px) and (max-width:480px){
 .business-improvements small{display:none}
 .business-improvements>button{min-height:32px}
 .business-layout{gap:10px}
}
@media(max-height:540px) and (min-width:600px){
 #fieldDialog{width:min(700px,calc(100% - 20px));max-width:700px;padding:16px}
 #fieldDialog h2{font-size:21px;margin-bottom:4px}
 #fieldDialog p{font-size:11px;margin:4px 0}
 .field-dialog-grid{grid-template-columns:repeat(3,1fr);gap:6px;margin:9px 0}
 .field-dialog-grid button{padding:8px 5px;min-height:49px}
 .field-dialog-grid small{font-size:9px}
}

/* One crew view: hiring and a bounded roster stay beside the selected worker. */
#careerDialog.crew-mode{width:min(660px,calc(100% - 20px));max-width:660px;padding:17px;overflow:hidden}
.crew-heading{display:flex;align-items:baseline;gap:12px;margin:0 25px 12px 0}
#careerContent .crew-heading h2{margin:0;font-size:25px}
.crew-heading>span{font-size:11px;color:#b4cdbf}
.crew-hire{display:grid;grid-template-columns:1fr 1.05fr auto;align-items:end;gap:8px}
.crew-hire label{font-size:10px;color:#b4cdbf;min-width:0}
.crew-hire select{display:block;width:100%;min-width:0;height:33px;margin-top:4px;padding:5px 7px;border:1px solid #527167;border-radius:6px;background:#25443f;color:#f3f2dd;font:600 12px var(--font)}
.crew-hire select:focus-visible,.crew-development summary:focus-visible{outline:2px solid var(--gold);outline-offset:2px}
.crew-hire>button{height:33px;padding:5px 10px;font-size:12px;white-space:nowrap}
#careerContent .crew-hire-note{font-size:10px;line-height:1.35;min-height:14px;margin:6px 0 12px}
.crew-workspace{display:grid;grid-template-columns:minmax(155px,.8fr) minmax(0,1.2fr);gap:14px;align-items:start}
.crew-roster{min-width:0}
.crew-roster-heading{display:flex;align-items:center;justify-content:space-between;gap:4px;min-height:25px;margin-bottom:4px;color:#a8c4b9;font-size:10px}
.crew-page-controls{display:flex;gap:3px}
.crew-page-controls button{width:25px;height:24px;padding:0;font-size:18px;line-height:1}
.crew-roster-list{display:grid;gap:5px}
.crew-member{display:flex;gap:9px;align-items:center;width:100%;min-width:0;text-align:left;padding:8px;font-size:12px}
.crew-member[aria-pressed=true]{border-color:#ecc775;background:#365449}
.crew-role-dot{width:9px;height:15px;flex-shrink:0;border-radius:5px 5px 3px 3px;background:var(--role-color);box-shadow:0 -4px 0 -1px #f6d4ac}
.crew-member>span:last-child{min-width:0}
.crew-member strong{display:block;font-size:12px;font-weight:600}
.crew-member small{display:block;color:#b4cdbf;font-size:10px;font-weight:400;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.crew-member strong small{display:inline;margin-left:3px;color:#ecc775}
.crew-detail{min-width:0;padding:11px;background:#203f3b;border:1px solid #456159;border-radius:8px}
.crew-detail-heading{display:flex;gap:8px;align-items:baseline;justify-content:space-between}
#careerContent .crew-detail-heading h3{margin:0;font-size:18px}
.crew-detail-heading>span{font-size:10px;color:#e8c379;white-space:nowrap}
#careerContent .crew-role{font-size:11px;margin:4px 0 8px;color:#b4cdbf}
#careerContent .crew-detail .worker-live{display:flex;align-items:center;min-height:31px;margin:0 0 8px;padding:6px 8px;font-size:11px;line-height:1.25}
#careerContent .crew-assignment{display:flex;justify-content:space-between;gap:7px;font-size:11px}
.crew-assignment>span{color:#a8c4b9}
.crew-assignment strong{text-align:right;font-weight:600}
#careerContent .crew-xp{font-size:10px;margin:6px 0}
.crew-detail .worker-actions{gap:6px;margin:9px 0 5px}
.crew-detail .worker-actions button{padding:8px 5px;font-size:11px}
.crew-detail .worker-actions .primary{flex:1.4}
.crew-development{margin-top:9px;border-top:1px solid #456159;padding-top:7px}
.crew-development summary{cursor:pointer;font-size:11px;color:#d3dec9;list-style-position:inside}
.crew-development .specialty-options{gap:5px;margin-top:8px}
.crew-development .specialty-options button{padding:7px;font-size:11px}
.crew-development .specialty-options small{font-size:10px;line-height:1.2;margin-top:5px}
.crew-training{display:block;width:100%;padding:7px;margin-top:7px;font-size:11px;text-align:left}
.crew-training small{display:block;color:#b4cdbf;font-size:10px;font-weight:400;margin-top:3px}
.crew-foreman{display:flex;gap:6px;align-items:center;margin-top:8px;font-size:11px;color:#c3d4c3}
.crew-foreman input{accent-color:#ecc775;margin:0}
.crew-empty{padding:15px 4px;font-size:13px;line-height:1.4}
.crew-detail:has(.crew-development[open]) .worker-live,.crew-detail:has(.crew-development[open]) .crew-assignment,.crew-detail:has(.crew-development[open]) .crew-xp,.crew-detail:has(.crew-development[open]) .worker-actions{display:none!important}
.crew-detail:has(.crew-development[open]) .crew-development{margin-top:5px;padding-top:5px}
@media(max-width:480px){
 #careerDialog.crew-mode{padding:13px}
 .crew-heading{margin-bottom:9px;gap:10px}
 #careerContent .crew-heading h2{font-size:23px}
 .crew-heading>span{font-size:10px}
 .crew-hire{grid-template-columns:1fr 1.12fr auto;gap:5px}
 .crew-hire select{font-size:10px;padding:4px;height:31px}
 .crew-hire>button{font-size:10px;padding:5px;height:31px}
 #careerContent .crew-hire-note{min-height:26px;margin:5px 0 7px}
 .crew-workspace{grid-template-columns:1fr;gap:9px}
 .crew-roster-list{grid-template-columns:1fr 1fr;gap:4px}
 .crew-member{padding:6px 7px;gap:7px}
 .crew-member strong{font-size:11px}
 .crew-member small{font-size:9px}
 .crew-detail{padding:10px}
 #careerContent .crew-detail .worker-live{min-height:29px;margin-bottom:5px}
 .crew-detail .worker-actions{margin-top:6px}
 .crew-development{margin-top:6px;padding-top:6px}
 .crew-empty{padding:8px 4px}
}
@media(max-height:540px) and (min-width:481px){
 #careerDialog.crew-mode{padding:11px}
 .crew-heading{margin-bottom:5px}
 #careerContent .crew-heading h2{font-size:20px}
 .crew-hire select,.crew-hire>button{height:28px;font-size:11px;margin-top:2px}
 #careerContent .crew-hire-note{margin:4px 0 6px}
 .crew-workspace{gap:10px;grid-template-columns:minmax(150px,.85fr) minmax(0,1.15fr)}
 .crew-roster-heading{min-height:20px;margin-bottom:3px}
 .crew-member{padding:6px 8px}
 .crew-detail{padding:8px}
 #careerContent .crew-detail-heading h3{font-size:16px}
 #careerContent .crew-role{margin:3px 0 5px;font-size:10px}
 #careerContent .crew-detail .worker-live{min-height:27px;margin-bottom:5px;font-size:10px;padding:5px}
 #careerContent .crew-assignment,#careerContent .crew-xp{font-size:10px;margin:4px 0}
 .crew-detail .worker-actions{margin:6px 0 3px}
 .crew-detail .worker-actions button{padding:6px}
 .crew-development{padding-top:5px;margin-top:5px}
 .crew-development .specialty-options{margin-top:5px}
 .crew-development .specialty-options button{padding:5px;font-size:10px}
 .crew-development .specialty-options small{font-size:9px;margin-top:3px}
 .crew-training{padding:5px;margin-top:5px;font-size:10px}
 .crew-training small{font-size:9px;margin-top:2px}
 .crew-foreman{font-size:10px;margin-top:5px}
}
