/* Menus courts avec défilement tactile immédiat. */
.compact-select-panel.open,.smart-entry-panel.open{display:flex;flex-direction:column;gap:6px;overflow:hidden;box-sizing:border-box;z-index:2200;padding:10px;}
.compact-menu-head,.compact-select-search,.compact-scroll-hint,.compact-select-done{flex-shrink:0;}
.compact-select-search[hidden]{display:none!important;}
.compact-select-list-all,.smart-entry-compact{display:flex!important;flex-direction:column;gap:4px;min-height:0;max-height:116px!important;overflow-y:auto!important;overscroll-behavior:contain;touch-action:pan-y;-webkit-overflow-scrolling:touch;scrollbar-width:thin;}
.compact-select-option,.smart-entry-chip{flex-shrink:0;min-height:44px;white-space:normal;text-align:left;touch-action:pan-y;}
.compact-menu-close{min-width:40px;min-height:36px;}
.compact-scroll-hint{font-size:11px;line-height:1.4;margin:2px 0 0;}
.compact-select-trigger{min-height:44px;}
button:focus-visible,input:focus-visible{outline:2px solid var(--cyan,#007b91);outline-offset:2px;}
.quick-time-source{display:none!important;}
.quick-time-wrap{min-width:0;}
.quick-time-input{width:100%;box-sizing:border-box;min-height:46px;font-size:16px!important;font-variant-numeric:tabular-nums;letter-spacing:0;}
.quick-time-help{display:block;font-size:11px;line-height:1.4;margin-top:5px;color:var(--txt2);}
.quick-time-input[aria-invalid="true"]{outline:2px solid #d44343;}
.mbg{align-items:flex-start!important;padding:env(safe-area-inset-top,0px) 8px 8px;box-sizing:border-box;}
.msh{margin:0 auto!important;max-height:calc(100dvh - env(safe-area-inset-top,0px) - 8px)!important;overscroll-behavior:contain;scroll-padding-top:70px;border-radius:16px!important;}
.modal-top{display:flex;align-items:center;justify-content:space-between;gap:10px;position:sticky;top:-18px;z-index:3;background:var(--bg);padding:12px 0;border-bottom:1px solid var(--brd);}
.modal-top .mtit{margin:0;}
.modal-close{min-width:44px;min-height:44px;flex-shrink:0;}
#calendarShiftForm{margin-top:12px;margin-bottom:20px;}
@media(max-width:600px){.mbg{padding-left:0;padding-right:0;padding-bottom:0;}.msh{width:100%;max-height:calc(100dvh - env(safe-area-inset-top,0px))!important;border-radius:0!important;padding-bottom:calc(18px + env(safe-area-inset-bottom,0px));}input,select,textarea{font-size:16px;} }

/* La saisie reste visible au-dessus des propositions. */
[hidden]{display:none!important;}
.smart-entry-panel .compact-menu-head,.compact-select-panel .compact-menu-head,.compact-select-panel .compact-scroll-hint{display:none!important;}
.smart-entry-panel.open,.compact-select-panel.open{margin:5px 0 8px;box-shadow:none;}
.smart-entry-compact{max-height:64px!important;}
.compact-select-list-all{max-height:108px!important;}
.compact-select-trigger.single-choice{opacity:1;cursor:default;background:var(--card2);}
.compact-select-trigger.single-choice::after{display:none!important;}

#calendarShiftForm .frow2:has(> [hidden]){grid-template-columns:1fr;}

/* Uniform field sizes, including start/end times and compact choices. */
#page-add input,#page-add textarea,#calendarShiftForm input,#calendarShiftForm textarea,.day-sheet input,.day-sheet select,.day-sheet textarea,.day-sheet .compact-select-trigger{font-family:system-ui,sans-serif;font-size:16px!important;line-height:1.4;letter-spacing:0}
.day-sheet label,.day-sheet .flbl{font-family:system-ui,sans-serif;font-size:12px;letter-spacing:.04em}

/* Choices are outside the form stacking context and above the mobile keyboard. */
#choiceSheet{box-sizing:border-box;position:fixed;inset:auto 0 0;margin:0 auto;width:100%;max-width:640px;height:72dvh;max-height:calc(100dvh - 20px);padding:0 0 env(safe-area-inset-bottom);border:1px solid var(--brd);border-radius:22px 22px 0 0;background:var(--bg);color:var(--txt);box-shadow:0 -12px 50px #0005;overflow:hidden}
#choiceSheet::backdrop{background:rgba(10,15,30,.5)}
#choiceSheet[open]{display:flex;flex-direction:column}
#choiceSheet header{display:flex;align-items:center;gap:16px;padding:16px;border-bottom:1px solid var(--brd);flex-shrink:0;font-family:system-ui,sans-serif}
.choice-back,.choice-suggestions{font:600 14px system-ui,sans-serif;min-height:44px;border:1px solid var(--brd);border-radius:10px;background:var(--card2);color:var(--txt);padding:10px 14px;cursor:pointer}
.choice-suggestions{margin-top:6px}
#choiceSheet .choice-body{flex:1;min-height:0;display:flex;overflow:hidden}
#choiceSheet .choice-panel.open{display:flex!important;position:static!important;inset:auto!important;width:100%!important;max-width:none!important;max-height:none!important;margin:0!important;border:0;box-shadow:none;padding:14px;flex:1;min-height:0;background:var(--bg)}
#choiceSheet .compact-menu-head,#choiceSheet .compact-scroll-hint{display:none!important}
#choiceSheet .compact-select-list-all,#choiceSheet .smart-entry-compact{max-height:none!important;flex:1;min-height:0;overflow-y:auto!important;gap:8px;padding-bottom:8px}
#choiceSheet .compact-select-option,#choiceSheet .smart-entry-chip{min-height:50px;font:500 16px/1.4 system-ui,sans-serif;padding:13px 16px;border-radius:12px}
#choiceSheet .compact-select-option.selected{border-width:2px;font-weight:700}
.compact-select-trigger:not(.single-choice){border-width:2px;padding-right:34px;position:relative}
.compact-select-trigger:not(.single-choice)::after{content:'▾';position:absolute;right:12px;font-size:18px}
@media(min-width:700px){#choiceSheet{inset:0;margin:auto;height:min(650px,80dvh);border-radius:20px}}

/* Shared typography across employee/employer screens and dialogs. */
body{font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;line-height:1.45}
.page :where(p,span,div,label,button,input,textarea,select),.msh :where(p,span,div,label,button,input,textarea,select),#onboard :where(p,span,div,label,button,input,textarea,select),.bnav button{font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;letter-spacing:normal}
.page input,.page textarea,.page select,.page .compact-select-trigger,.msh input,.msh textarea,.msh select,#onboard input,#onboard select{font-family:system-ui,sans-serif;font-size:16px!important;line-height:1.4;letter-spacing:0;min-width:0}
.page label,.flbl,.slbl,.cilbl,.rhero-k{font-size:12px;line-height:1.45;font-weight:600;letter-spacing:.025em}
.page .ctit,.page .stit,.msh .mtit,.quickfill-title,.rname{font-family:system-ui,sans-serif;font-weight:700;letter-spacing:.015em;line-height:1.35;font-size:16px}
.page .stit,.msh .mtit{font-size:20px}
.page .sval,.page .rhero-t{font-family:system-ui,sans-serif;font-size:28px;font-weight:750;letter-spacing:-.035em;font-variant-numeric:tabular-nums;line-height:1.2}
.page .ssub,.smart-hint,.rdesc,.rstatus,.rhero-p{font-size:13px;line-height:1.5;letter-spacing:0}
.page .bpri,.page .bout,.msh .bpri,.msh .bout,#onboard .bpri{font-family:system-ui,sans-serif;font-size:14px;font-weight:650;letter-spacing:.015em;line-height:1.35;min-height:44px;white-space:normal;border-radius:10px}
.bnav .ni{font-family:system-ui,sans-serif;font-size:10px;font-weight:600;letter-spacing:0;line-height:1.3;min-width:0}
.bnav .nicon{font-size:19px}.page button{max-width:100%}
.page [style*="font-family"],.msh [style*="font-family"]{font-family:system-ui,sans-serif!important;letter-spacing:normal!important}
body .bout{background:var(--surf)!important;border-color:var(--brd)!important;color:var(--txt)!important}

/* Distinct choice controls, consistently themed and without duplicate lists. */
body{--choice-accent:var(--acc2);--choice-bg:color-mix(in srgb,var(--acc2) 10%,var(--card));--choice-selected:color-mix(in srgb,var(--acc2) 20%,var(--card))}
.compact-select-trigger:not(.single-choice),.choice-suggestions{background:var(--choice-bg)!important;color:var(--txt)!important;border:2px solid var(--choice-accent)!important;border-radius:12px;min-height:46px}
.compact-select-trigger.open{background:var(--choice-selected)!important;box-shadow:0 0 0 3px color-mix(in srgb,var(--choice-accent) 20%,transparent)}
#choiceSheet .compact-select-option.selected{background:var(--choice-selected)!important;border-color:var(--choice-accent)!important;color:var(--txt)!important}
#choiceSheet .compact-select-option.selected::after{color:var(--choice-accent)}
.smart-entry-panel:not(.choice-panel){display:none!important}
.stats-clickable{cursor:pointer;border:1px solid var(--brd);border-radius:10px;padding:12px;margin-bottom:8px}
.stats-clickable:hover,.stats-clickable:focus-visible{background:var(--choice-bg);outline:2px solid var(--choice-accent);outline-offset:2px}
.stats-mission{display:block;width:100%;padding:14px;margin:10px 0;text-align:left;border:1px solid var(--choice-accent);border-radius:12px;background:var(--choice-bg);color:var(--txt);font:500 15px/1.5 system-ui;cursor:pointer}
.stats-edit-help{font:14px/1.5 system-ui;margin-bottom:16px;color:var(--txt2)}
.stats-clickable::after{content:'Voir les missions →';display:block;margin-top:7px;color:var(--choice-accent);font:600 12px/1.4 system-ui}

/* Balanced density: natural-size text, native fonts, no page scaling. */
html{-webkit-text-size-adjust:100%;text-size-adjust:100%}
body{font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:14px;line-height:1.4}
.page{padding:12px 12px calc(12px + var(--sb))}
.page .card,.page .sbox,.page .cicard{box-shadow:0 2px 6px rgba(0,0,0,.08)}
.page .card,.page .sgrid,.page .cicard{margin-bottom:10px}
.page .chdr{padding:9px 12px}.page .cbody{padding:10px 12px}
.page .sgrid{gap:8px}.page .sbox{padding:10px 12px}
.page .cicard{padding:12px}.page .ctit,.quickfill-title,.rname{font-size:14px;font-weight:600;line-height:1.35;letter-spacing:0}
.page .stit,.msh .mtit{font-size:18px;font-weight:700;letter-spacing:0;line-height:1.3}
.page .sval,.page .rhero-t{font-size:24px;font-weight:700;letter-spacing:-.015em;line-height:1.2}
.page .cit{font-family:system-ui,sans-serif;font-size:28px;font-weight:600;letter-spacing:0;font-variant-numeric:tabular-nums;line-height:1.2}
.page .ssub,.page .smart-hint,.page .rdesc,.page .rstatus,.page .rhero-p{font-size:12px;line-height:1.4}
.page label,.day-sheet label{font-size:12px;font-weight:500;letter-spacing:0;margin-bottom:4px}
.page .bpri,.page .bout,.msh .bpri,.msh .bout,.choice-suggestions,.choice-back{font-size:13px;font-weight:600;letter-spacing:0;padding:9px 12px;min-height:44px;line-height:1.35}
.page input,.page select,.msh input,.msh select,.quick-time-input{min-height:44px;padding:8px 10px;font-size:16px!important;font-weight:400}
.compact-select-trigger:not(.single-choice),.choice-suggestions{min-height:44px;border-width:1px!important;border-radius:10px}
.compact-select-trigger{padding:8px 32px 8px 10px!important;font-size:16px!important;font-weight:500;line-height:1.35}
.choice-suggestions{margin-top:5px}.quick-time-help{margin-top:3px;font-size:11px;line-height:1.4}
#choiceSheet header{padding:12px;gap:12px}#choiceSheet .choice-panel.open{padding:12px}
#choiceSheet .compact-select-list-all,#choiceSheet .smart-entry-compact{gap:6px}
#choiceSheet .compact-select-option,#choiceSheet .smart-entry-chip{min-height:46px;font-size:15px;line-height:1.4;padding:10px 12px}
.marker-add{min-height:44px;font-size:13px;font-weight:600;padding:10px 12px}
.stats-clickable{padding:9px 10px;margin-bottom:7px}.stats-clickable::after{margin-top:4px;font-size:11px}
.stats-mission{font-size:14px;padding:12px;min-height:44px}
.page .srdt,.page .srh,.page .jobname{font-size:14px;font-weight:600;line-height:1.35}
.page .srtm,.page .jobmeta,.page .srow .srnt{font-size:12px;line-height:1.4;opacity:1}
.page :is(.ctit,.stit,.sval,.cit,.jobname,.srdt,.srh),.msh .mtit{text-shadow:none;filter:none}
@media(min-width:900px){.page{padding:18px 24px}.page .sgrid{grid-template-columns:repeat(4,minmax(0,1fr))}}

/* Job folders: accessible selection, with a persistent action inside the section. */
.stats-classify-bar{position:sticky;bottom:12px;z-index:5;display:flex;flex-wrap:wrap;align-items:center;gap:8px;padding:12px;margin:12px 0;background:var(--surf);border:1px solid var(--brd);border-radius:12px;box-shadow:0 4px 16px #0001}
.stats-classify-bar span{flex:1 1 100%;font-size:13px;color:var(--txt2)}
.stats-classify-bar button{flex:1;font-size:13px;min-height:44px}
.stats-classify-bar button:disabled{opacity:.5;cursor:default}
.stats-folder-choice{display:flex;align-items:center;gap:10px;min-height:44px;padding:8px 10px;margin:3px 0;border-radius:8px;cursor:pointer;font-size:13px;color:var(--txt);line-height:1.5}
.stats-folder-choice:has(input:checked){background:var(--menu-surface);color:var(--menu-ink)}
.stats-folder-choice input{appearance:auto!important;width:20px!important;height:20px!important;flex:0 0 20px;accent-color:var(--menu-ink);margin:0}
.stats-folder-choice span{overflow-wrap:anywhere}
.stats-classify-bar{top:72px;bottom:auto}

/* One consistent edit sheet, regardless of entry point. */
#modal .msh{width:100%;max-width:680px;box-sizing:border-box}
#modal .mission-editor #calendarShiftForm{padding-top:0}
#modal #calendarShiftForm label{font:500 13px/1.4 system-ui;letter-spacing:0;text-transform:none;color:var(--txt2)}
#modal #modalShiftFormTitle{font:600 14px/1.4 system-ui!important;letter-spacing:0!important;text-transform:none!important;color:var(--txt)!important;margin-bottom:14px!important}
#modal .mission-editor .frow2:has(>div[hidden]){grid-template-columns:1fr}
#modal .mission-editor .frow2>div{min-width:0}
#modal .mission-editor input,#modal .mission-editor select{box-sizing:border-box;width:100%}
#modal .mission-editor #modalShiftSubmit{margin-top:14px!important;min-height:46px}

/* A single bottom sheet for browsing, with the original field available for typing. */
#choiceSheet .choice-edit-input{box-sizing:border-box;width:calc(100% - 24px);flex-shrink:0;margin:10px 12px;padding:12px;font:16px/1.4 system-ui;border:1px solid var(--brd);border-radius:10px;background:var(--card);color:var(--txt)}
#choiceSheet .profession-entry-list.choice-panel.open{display:block!important;overflow-y:auto!important;padding:0 12px!important;border-radius:0}
#choiceSheet .profession-entry-list button{min-height:48px}
.profession-entry-list[hidden]{display:none!important}
