/* All management controls float over the same full-screen 3D factory. */
.strategy .hud-top{max-width:440px}.strategy .hud-bottom{max-width:700px;gap:6px}
.strategy .contract-card{display:flex;flex-direction:column;gap:5px;width:100%;padding:10px 13px;border:1px solid #ffffff30;background:#193a43e8;color:#fff4db;border-radius:16px;text-align:left;backdrop-filter:blur(12px);box-shadow:0 6px 24px #173b3922;pointer-events:auto}
.contract-card .eyebrow{font-size:10px;color:#d1dbcd;letter-spacing:.04em}.contract-card strong{font-size:16px;display:flex;align-items:center;gap:6px}.contract-card strong small{margin-left:auto;font-size:10px;color:#d3dcd1;white-space:nowrap}.contract-meta{font-size:10px;color:#c4d7d2}
.strategy .forecast{display:flex;gap:6px;justify-content:space-between;padding:7px 11px;margin-top:5px;background:#f1f4e8ed;color:#345754;font-size:11px;border-radius:13px;box-shadow:0 3px 10px #173b3920}.forecast span{display:flex;align-items:center;gap:4px}.forecast .icon{width:14px;height:14px}.forecast b{font-weight:700}
.production-flow{display:flex;gap:4px;align-items:center;border:1px solid #e8f0d63b;background:#1c3e48e8;padding:5px;border-radius:16px;backdrop-filter:blur(10px);pointer-events:auto}.production-flow button{flex:1;min-width:0;display:grid;grid-template-columns:auto auto;justify-content:center;align-items:center;gap:3px 4px;padding:7px 2px;min-height:48px;border:0;background:#ffffff0d;color:#f6e9cb;border-radius:11px}.production-flow button strong{font-size:11px}.production-flow button span{grid-column:1/-1;color:#c1d6d0;font-size:9px}.production-flow .flow-arrow{color:#dec08b;font-size:16px}.production-flow button:last-child:nth-child(6){border-left:1px solid #d1ddd24d}
.day-navigation{display:flex;gap:4px;align-items:stretch;background:#183a45df;border:1px solid #ffffff30;border-radius:14px;padding:3px;pointer-events:auto}.day-navigation button{background:transparent;border:0;color:#eef4e6;min-height:36px;padding:5px 10px;min-width:38px;font-size:20px}.day-navigation #calendar{flex:1;font-size:13px}.day-navigation small{font-size:10px;color:#bfcec5}.day-navigation #copy{font-size:11px;border-left:1px solid #ffffff25;border-radius:0}.day-navigation .icon{width:15px;height:15px}
.roster-caption{display:flex;align-items:center;justify-content:space-between;color:#e9f5e8;font-size:10px;padding:0 5px;text-shadow:0 1px 4px #102c33;pointer-events:auto}.roster-caption span{background:#173c467d;padding:4px 7px;border-radius:9px}.roster-caption button{font-size:10px;min-height:30px;padding:4px 8px;border:1px solid #fff3;background:#23444bd9;color:#ffe2a1;border-radius:11px}.roster-caption .icon{width:12px;height:12px}
.strategy-roster{display:flex;gap:5px;padding:5px;background:#1e414be8;border:1px solid #ffffff35;border-radius:16px;overflow-x:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#b2c9bb #284b51;pointer-events:auto;backdrop-filter:blur(14px)}
.strategy .worker-card{display:grid;grid-template-columns:31px 1fr;align-items:center;gap:2px 5px;flex:0 0 108px;padding:6px;background:#f6f6df09;color:#f0f7e8;border:1px solid #ffffff18;border-radius:12px;text-align:left;min-height:69px}.worker-card>.portrait{width:31px;height:31px;grid-row:1/3}.worker-card strong{font-size:11px;font-weight:650}.worker-card .worker-rates{display:flex;gap:3px;flex-wrap:wrap;font-size:9px}.worker-card small{font-size:9px;grid-column:1/-1;text-align:center;color:#c1d6d1;line-height:1.2}.strategy .worker-card.assigned{border-color:#d3cd956e;background:#f4df9e17}.worker-card .role-P{color:#ffd284}.worker-card .role-Q{color:#abdfbf}.worker-card .role-D{color:#b6d5fa}.rate{display:inline-flex;align-items:center;gap:1px;white-space:nowrap}.rate .icon{width:12px;height:12px}.rate.P{color:#d4a650}.rate.Q{color:#67a887}.rate.D{color:#80a5c5}.rate.R{color:#ae9cd0}.strategy .rate.P{color:#f3cd81}.strategy .rate.Q{color:#a1dbc0}.strategy .rate.R{color:#cab7f2}
.strategy .footer #run{flex:1}.strategy .footer #analysis{font-size:12px}.strategy-toast{margin:0;padding:7px 10px;font-size:11px;text-align:center;background:#244b46ed;color:#f7efd5;border-radius:12px}.storage-warning{font-size:11px;background:#725538;color:white;padding:7px;border-radius:9px;margin:5px 0}
#panel .muted{font-size:12px;color:#6d827a;line-height:1.6;margin:0 0 12px}.notice{background:#e6ead9;border-left:3px solid #bfa364;border-radius:8px;font-size:12px;padding:11px;line-height:1.6}.station-summary{display:flex;align-items:center;gap:10px;background:#e3eadd;padding:12px;border-radius:13px}.station-summary>.icon{width:25px;height:25px}.station-summary span{margin-left:auto;font-size:12px}.station-workers{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px;margin:14px 0}.station-workers button{display:flex;flex-direction:column;align-items:center;padding:9px 3px;gap:4px;background:#fffef7;border:1px solid #cedacf;color:#34544d}.station-workers .portrait{width:38px;height:38px}.station-workers strong{font-size:12px}.station-workers span,.station-workers small{font-size:10px}.station-workers [aria-pressed=true]{background:#e0ead2;border-color:#5f9471;box-shadow:inset 0 0 0 1px #649474}.station-workers button:disabled{opacity:.38}
.worker-profile{display:flex;align-items:center;gap:12px;margin-bottom:16px}.worker-profile .portrait{width:58px;height:58px}.worker-profile p{font-size:12px;margin:5px 0}.role-choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.role-choices button{display:grid;grid-template-columns:30px 1fr;text-align:left;align-items:center;gap:4px;background:#fffef8;border:1px solid #cfdbd0;padding:13px 10px;min-height:65px}.role-choices .icon{width:25px;height:25px;grid-row:1/3}.role-choices small{font-size:10px;color:#6b8074}.role-choices .chosen,.calendar-grid .chosen{background:#dfebd3;border-color:#5b926f;box-shadow:inset 0 0 0 1px #5b926f}
.team-table>div{display:grid;grid-template-columns:32px 1fr 130px;align-items:center;gap:9px;border-bottom:1px solid #d4dfd3;padding:8px 0}.team-table .portrait{width:32px;height:32px}.team-table label{display:flex;flex-direction:column;gap:4px;min-width:0}.team-table label small{font-size:10px;color:#748476;display:flex;align-items:center;gap:3px;flex-wrap:wrap}.team-table select{max-width:100%;min-height:44px;background:#fffef6;border:1px solid #c3d3c6;border-radius:10px;color:#3c6056;font:inherit;font-size:12px;padding:4px}
.calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:5px}.calendar-grid button{display:flex;flex-direction:column;align-items:center;gap:4px;padding:7px 0;background:#fffef7;border:1px solid #d1ddcd;min-height:69px}.calendar-grid button strong{font-size:15px}.calendar-grid button span{height:14px;display:flex;gap:1px}.calendar-grid .icon{width:12px;height:12px}.calendar-grid button small{font-size:8px;color:#819380}.calendar-events p{font-size:11px;margin:7px 0;color:#607b6b}
.copy-options{display:flex;flex-direction:column;gap:8px}.copy-options button{min-height:48px;text-align:left;padding:10px 12px;background:#fffef7;border:1px solid #cfdbc9;color:#436351;font-size:13px}
.contract-milestones{display:flex;flex-direction:column;gap:8px;margin-bottom:12px}.contract-milestones>div{display:grid;grid-template-columns:24px 66px 1fr auto;gap:7px;align-items:center;background:#e5ebdc;border:1px solid #cfdbc9;padding:11px;border-radius:12px;font-size:12px}.contract-milestones .met{background:#dfeeda;color:#3e704f}.contract-milestones .missed{background:#f3e5d4;color:#83613f}.contract-milestones b{font-size:13px}
.rules-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:8px;margin:14px 0}.rules-grid>div{display:flex;flex-direction:column;gap:8px;padding:12px;background:#fffef6;border-radius:12px;border:1px solid #d5ddcb}.rules-grid .icon{color:#72917d}.rules-grid strong{font-size:13px}.rules-grid small{font-size:11px;color:#7e8c78;line-height:1.5}#panel details{padding:10px 0;border-top:1px solid #d4dece}#panel summary{cursor:pointer;font-size:12px}#panel details p{font-size:12px;line-height:1.7}
.result-numbers{display:flex;justify-content:space-around;gap:8px;padding:12px;background:#fffef6;border-radius:12px;font-size:11px}.result-numbers b{display:block;font-size:19px;margin-top:6px}.report-scroll{max-height:50dvh;overflow:auto;border:1px solid #d7e1d2;border-radius:12px}.report-table{width:100%;border-collapse:collapse;font-size:11px}.report-table th{position:sticky;top:0;background:#3e6459;color:#f0f6df;padding:10px 5px;white-space:nowrap}.report-table td{padding:6px 5px;border-bottom:1px solid #dce4d6;text-align:center}.report-table td:last-child{text-align:left;min-width:90px;max-width:180px;line-height:1.45}.report-table button{min-width:32px;min-height:40px;padding:3px;background:#e1e9d8;border:1px solid #c1d1bc}.report-table tr.has-issue{background:#f2e6d4}.hint-line{font-size:12px;line-height:1.7;color:#708067}.result-hero{text-align:center;padding:16px 0}.result-hero>.icon{width:54px;height:54px;padding:12px;border-radius:50%;color:#8d7342;background:#f2db9e}.result-hero h2{font-size:20px;margin:14px 0 8px}.result-hero p{font-size:12px;line-height:1.6}.result-actions{display:flex;flex-direction:column;gap:8px}.result-actions button{min-height:46px}
.strategy-levels{display:grid;grid-template-columns:repeat(2,1fr);gap:7px}.strategy-levels button{display:flex;flex-direction:column;align-items:flex-start;gap:5px;padding:11px;background:#fffef6;border:1px solid #d0ddc8;color:#426451;text-align:left}.strategy-levels span{font-size:10px;color:#b19459}.strategy-levels strong{font-size:13px}.strategy-levels small{font-size:10px;color:#82947a}#panel h4{margin:16px 0 9px;font-size:12px;color:#7f8f76}
.strategy-guide .guide-scene{display:flex;flex-direction:column;align-items:center;background:radial-gradient(ellipse at 50% 0,#f6ebbf,#dde8d7);border:1px solid #d2dcc9;border-radius:15px;padding:15px;gap:5px}.guide-scene span{display:flex;gap:20px}.guide-scene .portrait{width:48px;height:48px}.guide-scene .icon{width:48px;height:35px;color:#65866b}.guide-scene b{font-size:20px;color:#a58e53}.strategy-guide .guide-step{display:flex;gap:12px;padding:16px 0;border-bottom:1px solid #d5dfcc}.guide-step>b{display:grid;place-items:center;width:26px;height:26px;flex:none;background:#c7d7b8;color:#476544;border-radius:50%;font-size:12px}.guide-step strong{font-size:15px}.guide-step p{font-size:12px;line-height:1.7;margin:7px 0 0;color:#708168}.guide-step .icon{width:15px;height:15px;vertical-align:middle}.guide-flow{display:flex;align-items:center;justify-content:center;gap:10px;padding:18px 0;font-size:12px;color:#6b835e}.guide-flow span{display:flex;align-items:center;gap:4px}.guide-flow .icon{width:16px;height:16px}#panel .wide{width:100%;margin-top:12px;min-height:44px}#panel [data-kind=guide]{padding-bottom:10px}#guideDone{position:sticky;bottom:0;box-shadow:0 -6px 18px #f2f4ec}
@media(max-width:420px){.strategy .hud-bottom{width:calc(100% - 16px);bottom:max(8px,env(safe-area-inset-bottom));gap:4px}.strategy .hud-top{left:8px;right:8px}.strategy .contract-card{padding:8px 10px}.contract-card strong{font-size:14px}.contract-meta{font-size:9px}.strategy .worker-card{flex-basis:99px;padding:5px;min-height:66px}.strategy .footer button{padding:6px 10px;font-size:12px}.calendar-grid{gap:3px}.team-table>div{grid-template-columns:29px 1fr 117px;gap:6px}.station-workers{gap:5px}.contract-milestones>div{grid-template-columns:20px 56px 1fr auto;font-size:11px;padding:9px 7px;gap:4px}}
@media(max-height:520px) and (min-width:601px){.strategy .hud-top{width:255px;max-width:255px;left:10px;top:8px}.strategy .hud-bottom{left:auto;right:10px;bottom:10px;transform:none;width:340px;max-width:44%;gap:3px}.strategy .worker-card{min-height:60px}.strategy .production-flow button{min-height:40px;padding:3px}.strategy .camera-tools{right:calc(44% + 18px)}}

.strategy-roster::-webkit-scrollbar{height:4px}.strategy-roster::-webkit-scrollbar-thumb{background:#96b3a5;border-radius:4px}
@media(max-height:650px) and (max-width:600px){.strategy .hud-bottom{gap:3px}.strategy .worker-card{min-height:52px;padding:4px;grid-template-columns:24px 1fr}.strategy .worker-card>.portrait{width:24px;height:24px}.strategy-roster{padding:3px}.production-flow{padding:3px}.production-flow button{min-height:42px;padding:4px 2px}.strategy .contract-card{gap:3px;padding:6px 10px}.strategy .forecast{padding:5px 9px}.strategy .roster-caption button{min-height:26px}.day-navigation button{min-height:32px}.strategy .hud-top .top{min-height:40px}}
@media(max-height:520px) and (min-width:601px){
 .game-screen.strategy.play-screen .hud-bottom{display:flex;flex-direction:column;left:auto;right:10px;bottom:10px;transform:none;width:340px;max-width:44%;gap:3px;align-items:stretch}
 .game-screen.strategy .camera-tools{left:auto;right:calc(44% + 18px);top:auto;bottom:12px;transform:none;flex-direction:row}
 .game-screen.strategy.play-screen .footer{align-items:center}
}
