/* R55: shared component corrections and the personal workspace landing page. */
/* Teal frames use yellow actions; neutral menus and readable status chips stay neutral. */
body.crm-unified .app-main>header#crm-topbar.topbar :is(.home-link,.topbar-attendance a.button,.topbar-punch-form>button,.personal-workspace-button,.bell-button),
body.crm-unified .app-main #main-content :is(.executive-header,.page-head) .head-actions>details>summary,
body.crm-workbooks .desk-top nav>.btn,body.crm-workbooks .desk-welcome>#new-sheet{
 background:linear-gradient(180deg,#ffe379,#f4cb32)!important;color:#153d43!important;border:1px solid #d9b325!important;box-shadow:inset 0 1px #fff9c4,0 2px 4px #123c4820!important;text-shadow:none!important;
}
body.crm-unified .app-main>header#crm-topbar.topbar :is(.home-link,.personal-workspace-button,.bell-button){border-radius:8px!important;min-height:32px!important;min-width:32px}
body.crm-unified .app-main>header#crm-topbar.topbar .topbar-attendance :is(a.button,button){min-height:32px!important;padding:5px 9px!important;white-space:nowrap}
body.crm-unified .app-main>header#crm-topbar.topbar .top-actions :is(.crm-icon-accent,svg){stroke:currentColor!important}
body.crm-unified .app-main>header#crm-topbar.topbar .user-menu>summary{border-radius:20px!important;background:#ffffff12!important;color:white!important;box-shadow:none!important;border:1px solid #ffffff30!important;gap:7px!important;padding:3px 9px 3px 4px!important;min-height:34px!important}
body.crm-unified .app-main>header#crm-topbar.topbar .user-menu>summary .avatar{width:27px!important;height:27px!important;min-width:27px;border-radius:50%!important;background:#ecf5f2!important;color:#23535a!important;box-shadow:none!important;font-size:13px}
body.crm-unified #main-content :is(.executive-header,.page-head) .header-actions-menu>div :is(a,button),
body.crm-unified #main-content :is(.executive-header,.page-head) .head-actions details>div :is(a,button){background:#fff!important;color:#24545b!important;border-color:#d5e3df!important;box-shadow:none!important}
body.crm-unified #main-content .dashboard-header .header-copy{display:flex;flex-direction:column;align-items:flex-start;gap:3px;flex-basis:auto}
body.crm-unified #main-content .dashboard-header .header-copy>small{font-size:11px;line-height:1.25;margin:0}
body.crm-unified .crm-heading-icon{display:inline-flex;vertical-align:middle;width:22px;height:22px;margin-right:8px;flex:none;color:inherit}
body.crm-unified .crm-heading-icon svg{width:100%;height:100%}
body.crm-unified .module-nav-icon{flex:0 0 25px;opacity:1!important;visibility:visible!important}
body.crm-unified .module-nav-icon svg{width:19px!important;height:19px!important}

/* One group per row. Search stays visible irrespective of the old sidebar state. */
body.crm-unified .app-main>header#crm-topbar.topbar #workspace-modules .module-primary{display:block;grid-template-columns:none;width:100%;min-width:0}
body.crm-unified .app-main>header#crm-topbar.topbar #workspace-modules .nav-search{display:flex!important;position:sticky;top:-10px;width:auto;min-width:0;margin:0;visibility:visible;opacity:1;transform:none}
body.crm-unified .app-main>header#crm-topbar.topbar #workspace-modules .nav-search input{display:block!important;width:100%;height:34px;min-height:34px;visibility:visible;opacity:1}
body.crm-unified .module-primary>.module-group{width:100%;min-width:0}
body.crm-unified .module-primary .module-group-links{grid-template-columns:minmax(0,1fr)}
body.crm-unified .module-primary .module-group-links>a{min-width:0;min-height:33px}
body.crm-unified .module-primary .nav-label{white-space:normal;overflow-wrap:normal;word-break:normal;line-height:1.3}

/* Short structured forms: compact basics in one row, prose in a useful wide field. */
body.crm-unified #main-content .attendance-original{padding:10px 12px!important;display:flex;align-items:center;gap:12px;flex-wrap:wrap}
body.crm-unified #main-content .attendance-original .toolbar{padding:0;margin:0;display:flex;align-items:end;gap:8px;flex:0 0 auto;box-shadow:none;border:0;background:transparent}
body.crm-unified #main-content .attendance-original label{width:180px;flex:none;min-width:0}
body.crm-unified #main-content .attendance-original p{flex:1 1 300px;margin:0;font-size:12px;line-height:1.45}
body.crm-unified #main-content #attendance-correction{padding:12px!important}
body.crm-unified #main-content #attendance-correction .section-head{display:flex;align-items:center;flex-wrap:wrap;gap:5px 10px;margin-bottom:10px}
body.crm-unified #main-content #attendance-correction .section-head .eyebrow{display:none}
body.crm-unified #main-content #attendance-correction .section-head h2{font-size:17px;margin:0}
body.crm-unified #main-content #attendance-correction .section-head>p:not(.eyebrow){flex-basis:100%;font-size:12px;line-height:1.4;margin:0;max-width:100%}
body.crm-unified #main-content #attendance-correction .form-grid{display:grid;grid-template-columns:160px minmax(190px,1fr) minmax(190px,1fr) minmax(180px,1fr)!important;gap:9px 12px!important;align-items:start}
body.crm-unified #main-content #attendance-correction [data-field="reason"],body.crm-unified #main-content #attendance-correction [data-field="correction_reason"]{grid-column:1/4;grid-row:2}
body.crm-unified #main-content #attendance-correction label:has(input[type=file]){grid-column:4;grid-row:1/3}
body.crm-unified #main-content #attendance-correction :is(input:not([type=checkbox]):not([type=hidden]),select){min-height:34px!important;padding:6px 9px!important;width:100%;max-width:100%;font-size:13px}
body.crm-unified #main-content #attendance-correction textarea{height:38px;min-height:38px!important;max-height:180px;padding:8px!important;resize:vertical}
body.crm-unified #main-content #attendance-correction input[type=file]{white-space:normal;overflow:hidden;font-size:11px}
body.crm-unified #main-content .compact-period-form .form-grid{grid-template-columns:minmax(140px,1fr) minmax(110px,.7fr) 150px 150px minmax(200px,1.5fr)!important;gap:10px!important;align-items:start}
body.crm-unified #main-content .compact-period-form [data-field="reason"]{grid-column:auto!important}
body.crm-unified #main-content .compact-period-form textarea{min-height:34px!important;height:34px;resize:vertical;padding:6px 9px!important}
body.crm-unified #main-content :is(.workforce-config-form,.compact-period-form) :is(input:not([type=checkbox]):not([type=hidden]),select:not([multiple])){min-height:34px!important;padding:6px 9px!important}
body.crm-unified #main-content .workforce-config-form .form-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:10px 12px!important;align-items:start}
body.crm-unified #main-content .workforce-config-form [data-field="reason"]{grid-column:span 2}
body.crm-unified #main-content .workforce-config-form textarea{min-height:38px!important;height:38px;resize:vertical}
body.crm-unified #main-content .workforce-config-form label[hidden]{display:none!important}
body.crm-unified #main-content .workforce-config-form label>small{font-size:11px;line-height:1.3}
body.crm-unified .workforce-heading{display:block!important}
body.crm-unified #main-content .workforce-form-section{overflow:visible}
body.crm-unified #main-content .workforce-picker-field{display:grid;align-content:start;gap:4px;font-size:13px;line-height:1.4}
body.crm-unified #main-content .workforce-picker-field>small{font-size:11px;line-height:1.3;color:#48665d}
body.crm-unified .app-main #main-content .executive-header .head-actions .crm-action-popover :is(a,button){background:#fff!important;color:#24545b!important;border-color:#d5e3df!important;box-shadow:none!important}
body.crm-unified .app-main #main-content .executive-header .head-actions .crm-action-popover .crm-icon-accent{stroke:#287078!important}
body.crm-unified .workforce-heading>p{margin:4px 0!important}
body.crm-unified .employee-picker{position:relative;padding:0;border:0;box-shadow:none;background:transparent;margin:0}
body.crm-unified .employee-picker>summary{display:flex;justify-content:space-between;min-height:34px;padding:7px 9px;cursor:pointer;border:1px solid #bccfc9;border-radius:7px;background:#fff;color:#214d52;font-size:13px;list-style:none;gap:7px}
body.crm-unified .employee-picker>summary::after{content:'⌄'}
body.crm-unified .employee-picker-panel{position:absolute;top:calc(100% + 4px);left:0;z-index:35;min-width:250px;width:100%;max-width:calc(100vw - 40px);background:white;border:1px solid #bccfc9;border-radius:9px;padding:9px;box-shadow:0 8px 24px #173b4026}
body.crm-unified .employee-picker-panel input[type=search]{width:100%;margin-bottom:6px}
body.crm-unified .employee-picker-options{max-height:170px;overflow:auto;display:grid;gap:3px}
body.crm-unified .employee-picker-options label{display:flex!important;align-items:center;gap:8px;padding:5px;cursor:pointer;font-size:12px}
body.crm-unified .employee-picker-options input{width:16px!important;height:16px;min-height:0;flex:none}
body.crm-unified .employee-picker-options label[hidden]{display:none!important}
body.crm-unified .employee-picker-select[hidden]{display:none!important}
body.crm-unified .employee-picker-done{margin-top:6px;font-size:12px;padding:4px 8px}
body.crm-unified .sticky-hanger .hanger-add{white-space:normal!important;font-size:10px!important;line-height:1.2;min-height:30px!important}
body.crm-unified .sticky-hanger .hanger-all{display:block;width:50px;white-space:normal;overflow-wrap:normal}
body.crm-unified .chat-launcher{width:44px!important;height:44px!important;min-height:44px!important;box-shadow:0 4px 12px #173b4030!important}

/* Sculpted home cards, two sections across, retaining the teal brand frame. */
#workspace-home.dh-app{border-radius:22px;box-shadow:0 18px 48px #163e4717,inset 0 1px #fff;border:1px solid #fff9;background:linear-gradient(130deg,#e5f1ef,#f8fbf9 45%,#deeeeb)}
#workspace-home .dh-banner,#workspace-home .dh-banner:nth-child(even){position:relative;border:1px solid #d0e3de!important;border-radius:18px!important;background:linear-gradient(125deg,#fff 10%,#f7fcfa 70%,#e1efeb)!important;box-shadow:5px 7px 14px #17494b16,-3px -3px 9px #fff!important;isolation:isolate;transition:box-shadow .2s,translate .2s}
#workspace-home .dh-banner::before{content:'';position:absolute;left:-25px;bottom:-55px;width:200px;height:140px;border-radius:40% 62% 36% 65%;background:linear-gradient(140deg,#c1ded7aa,#e5f3ee66);transform:rotate(-16deg);z-index:-1;pointer-events:none}
#workspace-home .dh-banner:nth-child(even)::before{left:auto;right:-25px;transform:rotate(16deg)}
#workspace-home .dh-banner .dh-copy h2{background:linear-gradient(110deg,#14515b,#1c6972)!important;min-height:35px;padding:7px 13px;border-radius:16px 16px 0 0;font-size:16px;box-shadow:inset 0 1px #ffffff30}
#workspace-home .dh-banner .dh-link{background:linear-gradient(135deg,#fff,#edf6f2)!important;border:1px solid #cfdfd9!important;box-shadow:2px 3px 5px #173b4010,inset 0 1px #fff!important;color:#204d54!important;border-radius:9px!important}
#workspace-home .dh-banner .dh-link:hover{background:#fff!important;box-shadow:0 3px 9px #17494b25!important}
#workspace-home .dh-banner .dh-button-icon{background:#fae6a0!important;border:1px solid #ecd077;border-radius:6px;color:#23545a!important}
#workspace-home .dh-banner .dh-art::before{border-radius:42% 58% 60% 40%;background:linear-gradient(135deg,#c6e3db,#f8fffb);box-shadow:inset 2px 2px 5px #fff,3px 4px 9px #26584c24}
#workspace-home .dh-profile-menu>summary.dh-profile{border:1px solid #ffffff40;border-radius:24px;padding:4px 9px 4px 4px;gap:8px;min-height:36px;box-shadow:none;background:#ffffff12}
#workspace-home .dh-avatar{width:28px;height:28px;border-radius:50%;box-shadow:none;background:#edf7f3;color:#24545b;font-size:13px}
#workspace-home .dh-profile strong{font-size:12px}
#workspace-home .dh-profile>span>span{font-size:10px}

/* Personal workspace home: designed independently from the spreadsheet editor. */
body.crm-workbooks #home{max-width:1480px;margin:0 auto;font-family:Calibri,'Segoe UI',sans-serif}
body.crm-workbooks .desk-top{height:52px;min-height:52px;background:linear-gradient(110deg,#123c46,#1b6570)!important}
body.crm-workbooks .desk-welcome{position:relative;display:flex;align-items:center;justify-content:space-between;gap:18px;padding:18px 22px;border-radius:18px;background:linear-gradient(110deg,#153f49,#206977);color:#fff;box-shadow:0 6px 18px #163e471c;overflow:hidden}
body.crm-workbooks .desk-welcome::after{content:'';position:absolute;right:190px;top:-55px;width:180px;height:180px;border:25px solid #ffffff08;border-radius:44% 56% 61% 39%;pointer-events:none}
body.crm-workbooks .desk-welcome h1{font-size:25px;font-style:italic;line-height:1.2;margin:3px 0 6px;letter-spacing:-.4px}
body.crm-workbooks .desk-welcome p{font-size:13px;color:#dceee9;margin:0}
body.crm-workbooks .desk-eyebrow{font-size:10px;letter-spacing:.12em;color:#d8eae5}
body.crm-workbooks .desk-welcome #new-sheet{flex:none;min-height:36px}
body.crm-workbooks .desk-overview{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:12px 0}
body.crm-workbooks .desk-overview>button{justify-content:flex-start;text-align:left;padding:10px 14px;gap:12px;background:linear-gradient(135deg,#fff,#f4f9f6);border:1px solid #d6e5df;border-radius:12px;box-shadow:2px 3px 7px #244e4010;color:#30585d;white-space:normal;font-weight:400}
body.crm-workbooks .desk-overview>button[aria-pressed=true]{border-color:#74a7a4;box-shadow:inset 3px 0 #277d7e,2px 3px 7px #244e4010;background:#eaf4f0}
body.crm-workbooks .desk-overview strong{display:block;font-size:23px;line-height:1.1;color:#173f48;font-weight:600;margin-top:3px}
body.crm-workbooks [data-desk-icon]{display:inline-flex;flex:none;width:21px;height:21px;color:#387b7c}
body.crm-workbooks .desk-overview [data-desk-icon]{width:30px;height:30px;padding:5px;background:#e4efeb;border-radius:9px}
body.crm-workbooks [data-desk-icon] svg{width:100%;height:100%}
body.crm-workbooks .desk-layout{display:grid;grid-template-columns:minmax(0,1fr) 290px;gap:14px;align-items:start}
body.crm-workbooks .desk-main,body.crm-workbooks .desk-aside{display:grid;gap:14px;min-width:0}
body.crm-workbooks .desk-panel{padding:14px;border:1px solid #d5e3de;border-radius:15px;background:#fff;box-shadow:0 3px 10px #183e3d08;min-width:0}
body.crm-workbooks .desk-panel h2{font-size:17px;display:flex;align-items:center;gap:8px;font-style:italic;margin:0;line-height:1.3}
body.crm-workbooks #home .section-head{margin:0 0 12px;gap:10px;align-items:center}
body.crm-workbooks #home .section-head>button{background:#f1f7f4!important;color:#28575d!important;border:1px solid #cbddd5;box-shadow:none;font-size:12px;min-height:30px}
body.crm-workbooks #sheet-count{font-size:12px;color:#6b8482;font-style:normal}
body.crm-workbooks #home .shortcuts{display:grid;grid-template-columns:repeat(auto-fill,minmax(130px,1fr));gap:10px;margin:0;min-height:0}
body.crm-workbooks #home .shortcut{position:relative;display:flex;width:auto;text-align:left;align-items:center;padding:10px 28px 10px 10px;border:1px solid #d8e6df;border-radius:11px;background:linear-gradient(120deg,#f7faf8,#eef5f1);min-width:0}
body.crm-workbooks #home .shortcut>a{display:flex;gap:8px;align-items:center;font-size:13px;line-height:1.3;min-width:0;overflow-wrap:anywhere}
body.crm-workbooks #home .shortcut .icon{display:grid;place-items:center;flex:0 0 32px;width:32px;height:32px;border-radius:9px;background:#e1eee8;color:#337376}
body.crm-workbooks #home .shortcut .icon svg{width:23px;height:23px}
body.crm-workbooks .shortcut-menu{position:absolute;top:5px;right:3px}
body.crm-workbooks .shortcut-menu>summary{cursor:pointer;list-style:none;font-size:19px;padding:1px 5px;line-height:1.2;border-radius:5px;color:#3e6567}
body.crm-workbooks .shortcut-menu>div{position:absolute;right:0;top:25px;z-index:5;background:#fff;padding:6px;border:1px solid #d2e1da;border-radius:8px;box-shadow:0 7px 20px #163e4720;min-width:120px;display:grid;gap:4px}
body.crm-workbooks #home .shortcut-menu .mini{margin:0;text-align:left;justify-content:flex-start;min-height:28px;font-size:12px}
body.crm-workbooks #home .workbook-toolbar{display:grid;grid-template-columns:minmax(180px,1fr) 140px 150px;gap:10px;align-items:end;padding:0 0 12px;margin:0;min-width:0;border:0;background:transparent}
body.crm-workbooks #home .workbook-toolbar label{display:grid;gap:4px;font-size:11px;color:#53716f;min-width:0;margin:0}
body.crm-workbooks #home .workbook-toolbar :is(input,select){width:100%;min-width:0;height:34px;padding:6px 9px;font-size:13px;border:1px solid #cbdcd4;border-radius:8px;background:#f9fcfa;color:#234e54}
body.crm-workbooks #home .sheets{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:12px;min-height:0;overflow:visible}
body.crm-workbooks #home .sheet-card{min-width:0;padding:14px;gap:12px;border:1px solid #d2e3db;border-radius:12px;box-shadow:2px 3px 8px #143a3a0a;background:linear-gradient(145deg,#fff,#f7fbf8)}
body.crm-workbooks #home .sheet-card>a{display:flex;align-items:center;gap:8px;line-height:1.4;overflow-wrap:anywhere;font-size:16px;color:#245b60}
body.crm-workbooks .workbook-card-icon{display:inline-flex;flex:0 0 27px;width:27px;height:27px;border-radius:7px;background:#e4f0ea;color:#26777a;padding:4px}
body.crm-workbooks #home .workbook-meta{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:0;font-size:12px}
body.crm-workbooks #home .workbook-meta dt{font-size:10px;color:#6b8580;margin-bottom:3px}
body.crm-workbooks #home .workbook-meta dd{margin:0;color:#234e54;overflow-wrap:anywhere}
body.crm-workbooks #home .workbook-footer{display:flex;justify-content:space-between;align-items:center;gap:6px;border-top:1px solid #dfebe5;padding-top:9px}
body.crm-workbooks #home .workbook-footer .btn{background:#eaf4ef;color:#23595d;border:1px solid #c4d9ce;font-size:12px;min-height:30px}
body.crm-workbooks #home .workbook-actions{min-width:0;font-size:12px}
body.crm-workbooks #home .workbook-actions>div{position:absolute;right:0;top:100%;z-index:6;background:white;border:1px solid #cbded4;border-radius:8px;padding:6px;min-width:135px}
body.crm-workbooks #home .empty{grid-column:1/-1;padding:22px;text-align:center;font-size:13px;line-height:1.6;background:#f7fbf8}
body.crm-workbooks .desk-recent,.desk-suggestions{display:grid;gap:6px;margin-top:11px}
body.crm-workbooks .desk-recent>a,.desk-suggestions>a{display:flex;gap:8px;align-items:center;text-decoration:none;color:#345e62;font-size:13px;line-height:1.35;padding:8px;border-radius:8px;min-width:0;overflow-wrap:anywhere;background:#f4f9f6}
body.crm-workbooks .desk-recent>a:hover,.desk-suggestions>a:hover{background:#e6f1eb}
body.crm-workbooks .desk-hint{font-size:12px;line-height:1.4;margin:7px 0;color:#63807a}
body.crm-workbooks .desk-tip{display:flex;align-items:start;gap:10px;padding:14px;border:1px solid #d2e1d9;border-radius:14px;background:linear-gradient(130deg,#e8f2ed,#f4f9f6);font-size:12px}
body.crm-workbooks .desk-tip h2{font-size:14px;margin:0 0 7px;line-height:1.3}
body.crm-workbooks .desk-tip p{font-size:12px;line-height:1.6;margin:0 0 8px;color:#4d726d}
@media(prefers-reduced-motion:no-preference){#workspace-home .dh-banner:hover{translate:0 -2px;box-shadow:4px 10px 20px #17494b22,-3px -3px 9px #fff!important}body.crm-workbooks #home .desk-overview [data-desk-icon] svg{animation:desk-icon-wave 4s ease-in-out infinite}body.crm-workbooks #home :is(button,a){transition:background .15s,box-shadow .15s}}
@media(prefers-reduced-motion:reduce){#workspace-home .dh-banner{transition:none}body.crm-workbooks #home *{animation:none!important;transition:none!important}}
@media(max-width:1200px){body.crm-unified #main-content .compact-period-form .form-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important}body.crm-unified #main-content .compact-period-form [data-field="reason"]{grid-column:1/-1!important}body.crm-workbooks .desk-layout{grid-template-columns:minmax(0,1fr) 250px}body.crm-unified #main-content #attendance-correction .form-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}body.crm-unified #main-content #attendance-correction label:has(input[type=file]){grid-column:auto;grid-row:auto}}
@media(max-width:1000px){body.crm-workbooks .desk-layout{grid-template-columns:minmax(0,1fr)}body.crm-workbooks .desk-aside{grid-template-columns:repeat(2,minmax(0,1fr))}body.crm-workbooks .desk-tip{grid-column:1/-1}body.crm-unified #main-content .workforce-config-form .form-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}}
@media(max-width:760px){body.crm-unified #main-content :is(#attendance-correction,.compact-period-form,.workforce-config-form) .form-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}body.crm-unified #main-content #attendance-correction [data-field="reason"],body.crm-unified #main-content #attendance-correction [data-field="correction_reason"]{grid-column:1/-1;grid-row:auto}body.crm-workbooks .desk-welcome{padding:15px;flex-wrap:wrap;gap:12px}body.crm-workbooks .desk-welcome h1{font-size:22px}body.crm-workbooks .desk-overview{grid-template-columns:repeat(2,minmax(0,1fr))}body.crm-workbooks #home .workbook-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))}body.crm-workbooks #home .workbook-toolbar>label:first-child{grid-column:1/-1}}
@media(max-width:500px){body.crm-unified #main-content :is(#attendance-correction,.compact-period-form,.workforce-config-form) .form-grid{grid-template-columns:minmax(0,1fr)!important}body.crm-unified #main-content .workforce-config-form [data-field="reason"]{grid-column:auto}body.crm-workbooks .desk-aside{grid-template-columns:minmax(0,1fr)}body.crm-workbooks .desk-overview>button{padding:10px;gap:8px}body.crm-workbooks #home .sheets{grid-template-columns:minmax(0,1fr)}}
@media(pointer:coarse){body.crm-unified .employee-picker-options label,body.crm-workbooks #home :is(button,.btn),body.crm-unified .employee-picker>summary{min-height:44px!important}}
