/* Le Mie Ore — Build 61 TEST · pannelli più corti e leggibili.
   Solo presentazione, stessi controlli originali, compatibile con temi. */
@media screen and (max-width:760px){
 /* Compact panel content, preserve iPhone safe area and internal scroll when needed. */
 #calendarPage #v52Panel .v52-content{padding:7px 10px calc(16px + env(safe-area-inset-bottom,0px))!important}
 #calendarPage #v52Panel .v52-content #v16AdditionalCard{
   margin:0!important;padding:0!important;border:0!important;border-radius:0!important;
   background:transparent!important;box-shadow:none!important;
 }
 #calendarPage #v52Panel #v16AdditionalCard>p,
 #calendarPage #v52Panel #v16AdditionalCard .v16-status{
   margin:3px 3px 5px!important;font-size:11px!important;line-height:1.3!important;
   overflow-wrap:anywhere;
 }
 #calendarPage #v52Panel #v16AdditionalCard #v16MainWork{
   padding:5px 8px!important;margin:2px 0 5px!important;
   border-radius:9px!important;background:var(--v24-secondary,#fff1f7)!important;
   color:var(--v24-card-text,#613d52)!important;
 }
 #calendarPage #v52Panel #v16AdditionalCard .v16-actions{
   margin:5px 0!important;gap:6px!important;
 }
 #calendarPage #v52Panel #v16AdditionalCard #v16NewEntry{
   width:100%!important;min-height:41px!important;padding:7px 10px!important;
   border-radius:10px!important;font-size:13px!important;
 }
 #calendarPage #v52Panel #v16AdditionalCard #v16ExtraList .v16-entry{
   padding:7px 9px!important;margin:5px 0!important;gap:3px!important;
   border-radius:10px!important;
 }
 #calendarPage #v52Panel #v16AdditionalCard #v16ExtraList .v16-entry strong{font-size:12px!important;line-height:1.2!important}
 #calendarPage #v52Panel #v16AdditionalCard #v16ExtraList .v16-entry span{font-size:11px!important;line-height:1.25!important}
 #calendarPage #v52Panel #v16AdditionalCard #v16ExtraList .v16-actions button{
   min-height:34px!important;padding:5px 11px!important;font-size:11px!important;
 }
 #calendarPage #v52Panel #v16WorkForm.f61-extra-form{
   box-sizing:border-box!important;margin:5px 0!important;padding:9px!important;
   gap:6px!important;border-radius:12px!important;
   border:1px solid var(--v24-primary,#e8c3d6)!important;
   background:var(--v24-cards,var(--v24-card,#fff9fc))!important;
 }
 #calendarPage #v52Panel #v16WorkForm>h3{
   margin:0 0 2px!important;font-size:14px!important;line-height:1.25!important;
   color:var(--v24-card-text,#6b4158)!important;
 }
 #calendarPage #v52Panel #v16WorkForm .v16-grid{
   display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;
   gap:7px!important;margin:0!important;
 }
 #calendarPage #v52Panel #v16WorkForm .v16-grid.f61-no-category{grid-template-columns:minmax(0,1fr)!important}
 #calendarPage #v52Panel #v16WorkForm .v16-grid>div{min-width:0!important;max-width:100%!important}
 #calendarPage #v52Panel #v16WorkForm label:not(.v16-check){
   display:block!important;margin:0 0 3px!important;font-size:11px!important;
   line-height:1.22!important;font-weight:700!important;
 }
 #calendarPage #v52Panel #v16WorkForm :is(input:not([type='checkbox']),select){
   box-sizing:border-box!important;width:100%!important;min-width:0!important;max-width:100%!important;
   min-height:42px!important;height:42px!important;padding:5px 6px!important;
   font-size:16px!important;line-height:1.2!important;border-radius:10px!important;
   border:1px solid var(--v24-primary,#dfbace)!important;
   background:var(--v24-card,#fff9fc)!important;color:var(--v24-card-text,#5e3b51)!important;
 }
 #calendarPage #v52Panel #v16WorkForm #v16WorkTimes{display:flex;flex-direction:column;gap:6px}
 #calendarPage #v52Panel #v16WorkForm #v16WorkTimes[hidden],
 #calendarPage #v52Panel #v16WorkForm [hidden]{display:none!important}
 #calendarPage #v52Panel #v16WorkForm .v16-check{
   display:flex!important;align-items:center!important;gap:7px!important;
   padding:4px 2px!important;min-height:34px!important;margin:0!important;
   font-size:12px!important;line-height:1.2!important;
 }
 #calendarPage #v52Panel #v16WorkForm .v16-check input{height:18px!important;width:18px!important;min-width:18px!important;margin:0!important}
 #calendarPage #v52Panel #v16WorkForm>.v16-actions{
   display:grid!important;grid-template-columns:minmax(0,1.15fr) minmax(0,.85fr)!important;
   gap:6px!important;margin:1px 0 0!important;
 }
 #calendarPage #v52Panel #v16WorkForm>.v16-actions button{
   min-width:0!important;min-height:42px!important;padding:7px 5px!important;
   font-size:12px!important;line-height:1.2!important;border-radius:10px!important;
 }
 #calendarPage #v52Panel .f61-notes,
 #calendarPage #v52Panel .f61-extra-help{
   box-sizing:border-box;min-width:0;width:100%;margin:3px 0!important;
   border:1px solid color-mix(in srgb,var(--v24-primary,#b64f7b) 28%,transparent);
   background:var(--v24-secondary,#fff3f8);border-radius:10px;
 }
 #calendarPage #v52Panel :is(.f61-notes,.f61-extra-help)>summary{
   list-style:none;cursor:pointer;min-height:36px;padding:8px 10px;
   color:var(--v24-card-text,#6b4158);font-size:12px;font-weight:750;line-height:1.35;
 }
 #calendarPage #v52Panel :is(.f61-notes,.f61-extra-help)>summary::-webkit-details-marker{display:none}
 #calendarPage #v52Panel :is(.f61-notes,.f61-extra-help)>summary::after{content:'⌄';float:right}
 #calendarPage #v52Panel :is(.f61-notes,.f61-extra-help)[open]>summary::after{content:'⌃'}
 #calendarPage #v52Panel .f61-notes textarea{
   width:calc(100% - 16px)!important;max-width:calc(100% - 16px)!important;
   min-height:54px!important;max-height:110px!important;margin:0 8px 8px!important;
   padding:8px;font-size:16px;line-height:1.25;
 }
 #calendarPage #v52Panel .f61-extra-help>p{padding:0 10px 8px;margin:0!important;font-size:11px;line-height:1.4}
 #calendarPage #v52Panel .f61-visually-hidden{
   position:absolute!important;width:1px!important;height:1px!important;overflow:hidden!important;
   clip-path:inset(50%);white-space:nowrap!important;
 }
 /* Advanced copy: one obvious shortcut, then a separate optional date. */
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details{
   margin:6px 0!important;overflow:hidden!important;
   background:var(--v24-secondary,#fff2f7)!important;
 }
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details>summary{
   display:block!important;min-height:39px!important;padding:9px 12px!important;
   font-size:12px!important;font-weight:750!important;
 }
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details>.hint{
   padding:6px 9px 10px!important;margin:0!important;
   display:flex;flex-direction:column;gap:7px;
 }
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details .hint strong{
   display:block;font-size:11px!important;line-height:1.25;margin:0 0 1px!important;
 }
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details #copyPrevious{
   display:block;width:100%!important;min-height:39px!important;padding:8px!important;
   border-radius:10px!important;font-size:12px!important;
   background:var(--v24-card,#fff9fc)!important;
   color:var(--v24-card-text,#633b55)!important;
   border:1px solid var(--v24-primary,#dfbed0)!important;
 }
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details .copy-row{
   display:grid!important;grid-template-columns:minmax(0,1fr) 93px!important;
   gap:6px!important;align-items:end!important;min-width:0!important;
 }
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details .copy-row>div{min-width:0!important}
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details .copy-row label{margin:0 0 3px!important;font-size:11px!important}
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details #copyDate{
   width:100%!important;min-width:0!important;max-width:100%!important;
   height:42px!important;min-height:42px!important;padding:6px 4px!important;
   font-size:16px!important;border-radius:9px!important;
 }
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details #copyShift{
   min-height:42px!important;height:42px!important;padding:6px 5px!important;
   font-size:11px!important;line-height:1.1!important;border-radius:9px!important;
 }
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details #copyNotice{
   font-size:11px!important;line-height:1.3;margin:0!important;overflow-wrap:anywhere;
 }
}
@media screen and (max-width:345px){
 #calendarPage #v52Panel #v16WorkForm .v16-grid{gap:5px!important}
 #calendarPage #v52Panel #v16WorkForm :is(input:not([type='checkbox']),select){padding:4px 3px!important}
 #calendarPage #dayEditorCard #f55CopyDetails.f61-copy-details .copy-row{grid-template-columns:minmax(0,1fr) 82px!important;gap:4px!important}
}
@media print{#f61ExtraHelp,#f61ExtraNotes{display:none!important}}
/* Keep pause controls baseline-aligned even when one label wraps on narrow phones. */
@media screen and (max-width:760px){
 #calendarPage #v52Panel #v16WorkForm .f61-pause-grid>div{
   display:flex!important;flex-direction:column!important;justify-content:flex-end!important;
   min-width:0!important;
 }
 /* Hide redundant navigation only WHILE the existing editor form is open. */
 #calendarPage #v52Panel #v16AdditionalCard:has(#v16WorkForm:not([hidden])) #v16NewEntry,
 #calendarPage #v52Panel #v16AdditionalCard:has(#v16WorkForm:not([hidden])) #f61ExtraHelp,
 #calendarPage #v52Panel #v16AdditionalCard:has(#v16WorkForm:not([hidden])) #v16MainWork,
 #calendarPage #v52Panel #v16AdditionalCard:has(#v16WorkForm:not([hidden])) #v16ExtraList:has(>p.muted):not(:has(.v16-entry)){
   display:none!important;
 }
}
@media screen and (max-width:760px){
 /* Native date/time picker shells were still 52px despite 42px fields. */
 #appShell #calendarPage #v52Panel #v16WorkForm .picker-shell{
   box-sizing:border-box!important;height:42px!important;min-height:42px!important;
   max-height:42px!important;padding:0 5px!important;border-radius:10px!important;
   background:var(--v24-card,#fff9fc)!important;
   border:1px solid var(--v24-primary,#dfbace)!important;
 }
 #appShell #calendarPage #v52Panel #v16WorkForm .picker-shell .picker-readable{
   font-size:12px!important;padding-left:0!important;
 }
 #appShell #calendarPage #v52Panel #v16WorkForm .picker-shell .picker-symbol{
   font-size:13px!important;flex-basis:16px!important;
 }
}
