:root{color-scheme:light;--bg:#f4f6f9;--card:#fff;--ink:#233247;--muted:#687588;--line:#e2e7ee;--green:#304e72;--green-dark:#243d5b;--pale:#eef3f9;--red:#9d3932;--amber:#916026;--shadow:0 5px 24px #263d3505;font:14px Inter,"Segoe UI",Arial,sans-serif}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink)}button,input,select,textarea{font:inherit}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.5}button,a{touch-action:manipulation}a{color:var(--green)}[hidden]{display:none!important}button:focus-visible,a:focus-visible,summary:focus-visible{outline:3px solid #6289c2;outline-offset:3px}svg{width:18px;height:18px;stroke:currentColor;stroke-width:1.7;fill:none;stroke-linecap:round;stroke-linejoin:round;flex:none}.icon-defs{position:absolute;width:0;height:0;overflow:hidden}.sr-only{position:absolute;width:1px;height:1px;margin:-1px;clip:rect(0,0,0,0);overflow:hidden;white-space:nowrap}h1,h2,h3,h4,p{margin-top:0}h2{font-size:19px;letter-spacing:-.4px;margin-bottom:7px}h3{font-size:15px;margin-bottom:6px}hr{border:0;border-top:1px solid var(--line);margin:20px 0}
.topbar{background:#fafbf8;border-bottom:1px solid var(--line)}.top-inner{max-width:1390px;margin:auto;padding:18px 35px;display:flex;justify-content:space-between;align-items:center;gap:18px}.brand{display:flex;align-items:center;gap:11px}.brand-symbol{background:#e8f0e6;border:1px solid #ceddce;color:var(--green);width:41px;height:43px;border-radius:11px;display:grid;place-items:center}.brand-symbol svg{width:23px;height:23px}.brand strong{font-size:17px;font-weight:650;letter-spacing:-.4px;display:block}.brand span:not(.brand-symbol){display:block;color:var(--muted);font-size:10px;letter-spacing:.6px;margin-top:5px}.top-right{display:flex;gap:16px;align-items:center}.private-label{font-size:11px;color:var(--muted);display:flex;align-items:center;gap:6px}.private-label svg{width:14px;height:14px}.btn{border:1px solid #cfd9cf;background:white;border-radius:8px;color:var(--ink);display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:11px 15px;min-height:40px;font-size:12px;font-weight:600;line-height:1.4;text-decoration:none}.btn:hover{background:#f4f7f1;border-color:#9fb59f}.btn.primary{background:var(--green);color:white;border-color:var(--green)}.btn.primary:hover{background:var(--green-dark)}.btn.small{padding:9px 12px;min-height:35px;font-size:11px}.btn.full{width:100%}.btn.quiet{background:transparent;border-color:transparent;color:var(--muted)}.btn.danger{background:#9c4035;border-color:#9c4035;color:white}.icon-button{border:1px solid var(--line);width:34px;height:34px;border-radius:8px;background:transparent;display:grid;place-items:center;color:var(--muted);font-size:23px}.text-btn{border:0;background:none;color:var(--green);font-size:12px;font-weight:600;padding:5px 0}.text-btn:hover{text-decoration:underline}.text-btn.danger{color:var(--red)}.button-row{display:flex;align-items:center;gap:9px;flex-wrap:wrap}.chip-button{border:1px solid #d6dfd1;border-radius:6px;background:#fff;color:#516a58;font-size:10px;padding:7px 9px}.chip-button:hover{background:var(--pale)}
.shell{max-width:1390px;margin:auto;padding:30px 35px 20px}.intro{display:flex;justify-content:space-between;align-items:center;gap:20px;margin-bottom:24px}.eyebrow{font-size:10px;text-transform:uppercase;font-weight:650;letter-spacing:1.5px;color:var(--green);margin-bottom:9px}h1{font-size:28px;letter-spacing:-.8px;font-weight:620;margin-bottom:10px;line-height:1.25}.subline{font-size:13px;color:var(--muted);margin-bottom:0;line-height:1.6}.year-switch{display:flex;align-items:center;background:white;border:1px solid var(--line);border-radius:9px;height:42px;padding:3px;gap:3px}.year-switch button{border:0;background:transparent;color:var(--muted);font-size:24px;width:27px;height:33px;line-height:1}.year-switch input{border:0;width:65px;font-weight:650;text-align:center;padding:7px 0;-moz-appearance:textfield;appearance:textfield;color:var(--ink);background:transparent}.year-switch input::-webkit-inner-spin-button{appearance:none}.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:15px;margin-bottom:18px}.stat{position:relative;background:white;border:1px solid var(--line);border-radius:12px;padding:20px 23px;min-height:126px;box-shadow:var(--shadow)}.stat-label{font-size:12px;font-weight:550;color:#66776b}.stat-value{display:flex;align-items:baseline;gap:7px;margin:10px 0 7px}.stat-value strong{font-size:33px;font-weight:600;letter-spacing:-1.2px;line-height:1}.stat-value>span{font-size:12px;color:var(--muted)}.stat small{font-size:10px;color:var(--muted);line-height:1.6;display:block;max-width:90%}.stat-icon{position:absolute;right:22px;top:23px;color:#8b9c8c}.stat-icon svg{width:22px;height:22px}.stat.available{background:#e7efe5;border-color:#c9dbca}.available .stat-value strong{color:var(--green)}.available .stat-icon{color:var(--green)}.storage-strip{display:flex;align-items:center;justify-content:space-between;padding:12px 15px;border:1px solid #dce3d5;border-radius:9px;background:#eef2e9;gap:16px}.storage-strip>div{display:flex;gap:11px;align-items:center;min-width:0}.storage-strip svg{color:#74916f}.storage-strip strong{font-size:11px;font-weight:650;display:block}.storage-strip small{font-size:10px;color:var(--muted);line-height:1.5;display:block;margin-top:3px;overflow-wrap:anywhere}.storage-strip .btn{white-space:nowrap;background:transparent}.tabs{display:flex;border-bottom:1px solid #d8e1d4;gap:25px;margin:25px 0}.tab{position:relative;display:flex;align-items:center;gap:8px;border:0;background:none;padding:0 3px 14px;font-size:12px;color:var(--muted);font-weight:600;min-height:36px}.tab svg{width:16px;height:16px}.tab.active{color:var(--green)}.tab.active:after{content:'';position:absolute;left:0;right:0;bottom:-1px;height:3px;background:var(--green);border-radius:4px 4px 0 0}.count-badge{padding:2px 6px;border-radius:5px;background:#e8ede3;font-size:10px;font-weight:500}.dirty-dot{width:6px;height:6px;border-radius:50%;background:#b68031}.view{animation:appear .15s ease-out}@keyframes appear{from{opacity:.3;transform:translateY(4px)}to{opacity:1;transform:translateY(0)}}.card{background:#fff;border:1px solid var(--line);border-radius:12px;padding:23px;box-shadow:var(--shadow)}.section-head{display:flex;align-items:center;justify-content:space-between;gap:15px;margin-bottom:19px}.section-head h2{font-size:16px;margin:0}.section-head h3{margin:0}.section-head p{font-size:11px;color:var(--muted);line-height:1.6;margin:5px 0 0}.view-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:20px;margin-bottom:22px}.view-heading h2{font-size:21px;letter-spacing:-.6px;margin-bottom:8px}.view-heading p{font-size:12px;line-height:1.7;color:var(--muted);margin:0}.request-layout{display:grid;grid-template-columns:365px minmax(0,1fr);gap:28px;align-items:start}.request-controls{display:grid;gap:16px}.profile-card{padding:20px 23px}.profile-card .section-head{margin-bottom:14px}.profile-card>strong{font-size:14px}.profile-card>p{font-size:11px;line-height:1.6;color:var(--muted);margin:6px 0 0;overflow-wrap:anywhere}.field{margin-bottom:17px}.field:last-child{margin-bottom:0}.field label{font-weight:600;font-size:11px;display:block;margin-bottom:7px}.field input,.search-field input,select,.template-piece{border:1px solid #ccd7c9;border-radius:7px;background:#fff;color:var(--ink);width:100%;height:41px;padding:10px 11px;min-width:0;font-size:13px}.field input::placeholder,.search-field input::placeholder{color:#9ca69e}.field input:focus,select:focus,.template-piece:focus,.search-field input:focus{outline:2px solid #9bb8df;outline-offset:0;border-color:#6289c2}.field input[type=date]{font-size:12px;padding:10px 9px}.two-fields{display:grid;grid-template-columns:1fr 1fr;gap:12px}.hint{font-size:10px;line-height:1.7;color:var(--muted);margin:7px 0 0}.hint.center{text-align:center}.label-row{display:flex;justify-content:space-between;align-items:center;margin-bottom:7px}.label-row label{margin:0}.label-row button{font-size:10px;padding:0}.input-prefix{display:flex;align-items:center;border:1px solid #ccd7c9;border-radius:7px;overflow:hidden}.input-prefix>span{padding:11px;font-size:12px;color:var(--muted);background:#f1f5ed;border-right:1px solid var(--line)}.input-prefix input{border:0;border-radius:0}.input-prefix:focus-within{outline:2px solid #9bb8df}.input-prefix input:focus{outline:0}.optional{color:var(--muted);font-size:10px;font-weight:400}.segmented{display:flex;padding:4px;gap:4px;border:1px solid #e0e7db;background:#f0f4ec;border-radius:9px;margin-bottom:18px}.segmented label{flex:1;position:relative;cursor:pointer}.segmented input{position:absolute;opacity:0;width:1px;height:1px}.segmented span{display:block;text-align:center;font-size:12px;font-weight:600;padding:10px 8px;color:#778371;border-radius:6px}.segmented input:checked+span{background:white;box-shadow:0 1px 4px #233d3510;color:var(--green)}.segmented input:focus-visible+span{outline:2px solid #91b495}.selection-box{background:#f8faf5;border:1px solid #e0e7da;border-radius:9px;padding:13px}.selection-heading{display:flex;justify-content:space-between;align-items:center;gap:8px}.selection-heading strong{font-size:11px}.selection-heading span{font-size:10px;color:var(--green);white-space:nowrap}.selection-heading span.mismatch{color:var(--amber)}.selection-actions{display:flex;gap:5px;flex-wrap:wrap;margin:12px 0}.selection-days{max-height:290px;overflow:auto}.selection-month-title{font-size:11px;font-weight:650;margin:12px 0 8px;text-transform:capitalize}.selection-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:4px}.selection-weekday{text-align:center;color:#8b9588;font-size:9px;padding:3px 0}.date-chip{display:block;text-align:center;padding:6px 2px;font-size:11px;background:white;border:1px solid #dae3d4;border-radius:5px;color:var(--ink);position:relative;cursor:pointer}.date-chip input{position:absolute;opacity:0;width:1px;height:1px}.date-chip.selected{background:var(--green);border-color:var(--green);color:white}.date-chip.weekend:not(.selected){background:#eff2e9;color:#879281}.date-chip:focus-within{outline:2px solid #9bc3a8;outline-offset:2px}.charge-summary{font-size:11px;line-height:1.65;color:var(--muted);background:#f5f7f1;padding:10px 12px;border-radius:7px;margin:16px 0}.charge-summary strong{color:var(--green)}.charge-summary.insufficient{color:var(--red);background:#fdf0e9}.preview-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:14px;gap:15px}.preview-header h2{font-size:13px;margin:0}.preview-header p{font-size:10px;color:var(--muted);margin:5px 0 0}.preview-header button{font-size:11px}.paper-stage{background:#e9ede4;border:1px solid #dce3d5;border-radius:12px;padding:24px}.paper{aspect-ratio:210/297;background:#fff;border:1px solid #e4e8df;box-shadow:0 3px 12px #243c3510;color:#111;font-family:Arial,Helvetica,sans-serif;padding:58px 48px;line-height:1.85;font-size:13px;overflow-wrap:anywhere;min-height:650px}.paper h2{font-size:13px;letter-spacing:0;margin:0 0 30px;line-height:1.5}.paper>p{white-space:pre-wrap;margin:0}.paper .doc-date{margin-top:28px}.signature{display:flex;flex-wrap:wrap;gap:5px;align-items:baseline;margin-top:30px!important;line-height:2}.signature i{display:inline-block;min-width:90px;max-width:200px;flex:1;border-bottom:1px solid #333;height:16px}.administrator{margin-top:29px!important;display:flex;gap:8px;align-items:baseline;flex-wrap:wrap}.administrator i{display:inline-block;width:220px;border-bottom:1px solid #333;height:16px}.preview-foot{display:flex;justify-content:space-between;align-items:center;gap:20px;margin-top:12px;font-size:10px;color:var(--muted)}.preview-foot span:last-child{white-space:nowrap}
.legend{display:flex;gap:15px;font-size:11px;color:var(--muted);padding-top:4px}.legend span{display:flex;gap:6px;align-items:center;white-space:nowrap}.legend i{width:10px;height:10px;border-radius:3px;display:block}.legend-leave{background:var(--green)}.legend-today{border:1px solid var(--green);background:transparent}.year-calendar{display:grid;grid-template-columns:repeat(4,1fr);gap:15px}.month-card{background:white;border:1px solid var(--line);border-radius:11px;padding:17px}.month-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:13px}.month-header h3{font-size:12px;margin:0;text-transform:capitalize;font-weight:650}.month-header span{font-size:9px;color:#65805f;background:#eff5e9;border-radius:5px;padding:3px 5px}.month-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:3px}.month-weekday{text-align:center;font-size:9px;color:#98a08f;padding-bottom:8px}.calendar-day{height:29px;display:grid;place-items:center;border:1px solid transparent;background:transparent;color:#4f6657;border-radius:6px;font-size:11px;padding:2px;position:relative}.calendar-day.weekend{color:#acb3a4}.calendar-day.today{border-color:#739780;font-weight:700}.calendar-day.leave{background:var(--green);color:white;font-weight:600}.calendar-day.leave:hover{background:var(--green-dark)}.calendar-day:not(.leave):hover{background:#f0f5eb}.footnote{font-size:11px;line-height:1.75;color:var(--muted);margin:20px 0 0}.history-filters{display:flex;gap:12px;justify-content:space-between;margin-bottom:15px}.search-field{width:365px;max-width:100%}.history-filters select{font-size:12px;min-width:160px}.history-table-wrap{border:1px solid var(--line);border-radius:12px;background:white;overflow-x:auto}.history-table{border-collapse:collapse;width:100%;min-width:660px;text-align:left}.history-table th{font-size:10px;color:#7a887b;font-weight:600;text-transform:uppercase;letter-spacing:.7px;padding:15px 20px;border-bottom:1px solid var(--line);background:#f9fbf6;white-space:nowrap}.history-table td{padding:17px 20px;font-size:12px;vertical-align:middle;border-bottom:1px solid #e9eee3}.history-table tr:last-child td{border-bottom:0}.history-table td strong{font-weight:600;line-height:1.7}.history-table td small{display:block;font-size:9px;color:var(--muted);margin-top:4px}.table-actions{display:flex;justify-content:flex-end;align-items:center;gap:13px}.table-actions .text-btn{font-size:11px}.align-right{text-align:right}.badge{display:inline-block;border-radius:5px;font-size:10px;padding:5px 8px;line-height:1.2;background:#edf5e7;color:#477349;white-space:nowrap}.badge.cancelled{background:#f2eeea;color:#927867}.badge.pending{background:#fff2da;color:#986f29}.empty-state{text-align:center;padding:48px 20px 44px}.empty-icon{display:grid;place-items:center;width:48px;height:48px;background:#edf3e8;color:#87a17b;border:1px solid #dfe8d7;border-radius:12px;margin:0 auto 16px}.empty-icon svg{width:24px;height:24px}.empty-state h3{font-size:16px;font-weight:600;margin:0 0 9px}.empty-state p{font-size:12px;color:var(--muted);max-width:400px;line-height:1.8;margin:0 auto 18px}.history-footer{display:flex;justify-content:space-between;gap:15px;align-items:center;font-size:11px;color:var(--muted);padding-top:14px}
.settings-layout{display:grid;grid-template-columns:390px minmax(0,1fr);gap:20px;align-items:start}.settings-left{display:grid;gap:18px}.templates-card{padding:24px}.template-note{background:#f3f7ee;border:1px solid #e0e9d8;border-radius:7px;padding:11px;margin:0 0 20px}.template-section{border-top:1px solid #e5eade;padding:14px 0}.template-section>summary{font-size:12px;font-weight:600;cursor:pointer;color:#45644e;padding:3px 0}.template-section[open]>summary{margin-bottom:13px}.template-flow{display:flex;flex-wrap:wrap;gap:8px;align-items:center;padding:11px;border-radius:8px;background:#fafbf7;border:1px solid #e5ebde}.template-piece{resize:vertical;height:auto;min-height:36px;font-size:12px;line-height:1.6;padding:8px 10px;width:auto;max-width:100%;flex:0 1 auto;min-width:65px}.template-token{font-size:10px;line-height:1.5;background:#e8f2e5;border:1px solid #c9dfc5;color:#42714a;border-radius:5px;padding:8px 10px;white-space:nowrap;display:inline-flex;gap:5px;align-items:center}.template-token svg{width:11px;height:11px}.account-hint{margin:-4px 0 17px}.adjustment-details{border-top:1px solid var(--line);padding-top:14px;font-size:11px}.adjustment-details summary{cursor:pointer;color:var(--green);font-weight:600}.adjustment-item{padding:10px 0;border-bottom:1px solid #e7edde;line-height:1.7;font-size:10px;color:var(--muted)}.adjustment-item strong{color:var(--ink)}.settings-storage{margin-top:22px}.settings-storage>p{font-size:12px;line-height:1.8;color:var(--muted);max-width:880px;margin-bottom:17px}.mode-label{font-size:10px;border:1px solid #d6e3d0;color:#527b51;background:#f1f6eb;border-radius:6px;padding:6px 9px}.storage-actions{display:grid;grid-template-columns:1fr 1fr;gap:28px;margin:24px 0;border-top:1px solid var(--line);padding-top:24px}.storage-actions h4{font-size:13px;margin-bottom:8px}.storage-actions p{font-size:11px;color:var(--muted);line-height:1.8;margin-bottom:14px}.settings-storage>.hint{font-size:10px;border-top:1px solid #e7ecdf;padding-top:17px;margin:0;max-width:none}.notice{border:1px solid #ddcda9;background:#fff6e6;color:#805e24;font-size:12px;line-height:1.7;padding:12px 14px;border-radius:8px;margin:15px 0;display:flex;align-items:center;justify-content:space-between;gap:15px}.notice.error{border-color:#e8c4b9;background:#fff1eb;color:#964438}.notice.success{border-color:#ccd9c3;background:#edf5e6;color:#4a7246}.notice p{margin:3px 0 0;font-size:11px}.notice button{white-space:nowrap}.footer{display:flex;justify-content:space-between;gap:15px;flex-wrap:wrap;border-top:1px solid var(--line);padding-top:18px;margin-top:28px;font-size:10px;color:var(--muted);line-height:1.7}.footer a{color:var(--muted);text-underline-offset:3px}.toast{position:fixed;left:50%;bottom:24px;transform:translateX(-50%);background:#264636;color:white;border-radius:10px;padding:14px 19px;box-shadow:0 6px 28px #17362426;z-index:20;font-size:12px;line-height:1.6;max-width:min(650px,90vw)}dialog{border:1px solid var(--line);border-radius:14px;box-shadow:0 20px 80px #1c392b40;max-width:min(720px,calc(100vw - 30px));width:640px;padding:0;color:var(--ink);max-height:92vh}dialog::backdrop{background:#18332866;backdrop-filter:blur(2px)}.dialog-inner{padding:27px}.dialog-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:15px;margin-bottom:20px}.dialog-heading h2{font-size:21px;line-height:1.35;margin:0}.dialog-heading .eyebrow{font-size:9px;margin-bottom:6px}.dialog-heading .icon-button{flex:none}.dialog-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;flex-wrap:wrap;margin-top:23px}.dialog-inner p{font-size:13px;line-height:1.8;color:#687767}.dialog-inner ul,.help-list{font-size:13px;line-height:1.8;color:#65765f;padding-left:20px}.help-list li{margin-bottom:15px;padding-left:4px}.detail-meta{display:flex;align-items:center;gap:12px;flex-wrap:wrap;font-size:11px;color:var(--muted);margin-bottom:17px}.detail-text{font-family:Arial,Helvetica,sans-serif;font-size:12px;line-height:1.9;white-space:pre-wrap;overflow-wrap:anywhere;background:#fbfcf9;border:1px solid #e4eadb;border-radius:9px;padding:24px;margin:0}.detail-dates{display:flex;flex-wrap:wrap;gap:6px;margin-top:18px}.detail-date{font-size:10px;background:#edf5e7;border-radius:5px;color:#52744c;padding:5px 7px}.action-input{width:100%;border:1px solid #ccd7c9;border-radius:7px;padding:10px;margin-top:8px}
@media(min-width:1300px){.request-layout{grid-template-columns:390px minmax(0,1fr)}.paper{padding:64px 56px;font-size:14px}.paper h2{font-size:14px}.year-calendar{gap:18px}.month-card{padding:19px}.calendar-day{height:31px}}
@media(max-width:1120px){.year-calendar{grid-template-columns:repeat(3,1fr)}.shell{padding:27px}.top-inner{padding:17px 27px}.request-layout{grid-template-columns:340px minmax(0,1fr);gap:20px}.paper-stage{padding:17px}.paper{padding:40px 32px;min-height:590px;font-size:12px}.paper h2{font-size:12px}.settings-layout{grid-template-columns:350px minmax(0,1fr)}.private-label{display:none}.stat{padding:19px}.stat-icon{right:18px}.card{padding:20px}.templates-card{padding:20px}}
@media(max-width:850px){.shell{padding:24px 18px}.top-inner{padding:16px 18px}.intro{align-items:flex-start}h1{font-size:24px}.subline{font-size:12px}.stats{gap:10px}.stat{padding:16px;min-height:120px}.stat-icon{display:none}.stat small{max-width:100%;font-size:9px}.stat-label{font-size:10px}.stat-value strong{font-size:29px}.request-layout{grid-template-columns:1fr}.request-controls{grid-template-columns:1fr 1.5fr;align-items:start}.paper{min-height:0;max-width:760px;margin:auto;font-size:14px;padding:56px}.paper h2{font-size:14px}.settings-layout{grid-template-columns:1fr}.settings-left{grid-template-columns:1fr 1fr;align-items:start}.year-calendar{gap:12px}.month-card{padding:14px}.calendar-day{font-size:10px}.tabs{gap:22px}.templates-card{margin-top:0}.view-heading h2{font-size:20px}.preview-column{max-width:780px;width:100%}.settings-storage{padding:22px}}
@media(max-width:620px){.top-right{gap:9px}.brand strong{font-size:15px}.brand-symbol{width:34px;height:38px}.brand span:not(.brand-symbol){font-size:9px}.top-right>.btn{font-size:10px;padding:8px}.top-right>.btn svg{display:none}.intro{gap:8px}h1{font-size:22px;max-width:300px}.subline{font-size:11px}.year-switch{height:37px;margin-top:22px}.year-switch input{font-size:12px;width:47px}.year-switch button{font-size:21px;width:22px}.stats{grid-template-columns:repeat(3,1fr);gap:7px;margin-bottom:13px}.stat{padding:13px 11px;border-radius:9px;min-height:130px}.stat-value{margin-top:13px}.stat-value strong{font-size:27px}.stat-value>span{font-size:10px}.stat-label{font-size:9px;line-height:1.5;display:block;min-height:28px}.stat small{font-size:8px}.storage-strip{padding:11px;gap:9px;align-items:flex-start}.storage-strip>div{align-items:flex-start;gap:7px}.storage-strip svg{width:15px;height:15px;margin-top:2px}.storage-strip strong{font-size:10px}.storage-strip small{font-size:9px}.storage-strip .btn{font-size:9px;padding:7px 8px;min-height:32px}.tabs{justify-content:space-between;gap:7px;margin:22px 0}.tab{font-size:10px;gap:6px;padding-bottom:12px}.tab svg{width:14px;height:14px}.count-badge{font-size:9px;padding:2px 4px}.request-controls{grid-template-columns:1fr}.request-layout{gap:23px}.paper-stage{padding:13px}.paper{padding:32px 26px;font-size:11px;min-height:0}.paper h2{font-size:11px;margin-bottom:24px}.paper .doc-date{margin-top:22px}.signature{margin-top:23px!important}.administrator{margin-top:23px!important}.view-heading{align-items:flex-start;flex-wrap:wrap;gap:13px}.view-heading h2{font-size:20px}.view-heading p{font-size:11px}.legend{font-size:10px;gap:13px}.year-calendar{grid-template-columns:1fr 1fr;gap:10px}.month-card{padding:13px 10px;border-radius:9px}.month-header{margin-bottom:10px}.month-header h3{font-size:11px}.month-header span{font-size:8px;padding:2px 4px}.month-grid{gap:2px}.calendar-day{height:26px;font-size:9px;padding:1px}.month-weekday{font-size:8px}.settings-left{grid-template-columns:1fr}.storage-actions{grid-template-columns:1fr;gap:23px}.settings-storage{padding:20px}.history-filters{gap:9px}.history-filters select{min-width:115px;font-size:11px;padding:9px}.search-field input{font-size:11px}.history-table th,.history-table td{padding:14px 13px}.notice{align-items:flex-start;font-size:11px;flex-wrap:wrap}.dialog-inner{padding:22px}.dialog-heading h2{font-size:19px}.detail-text{padding:18px;font-size:11px}.dialog-actions{justify-content:flex-start}.footer{font-size:9px}.preview-foot{font-size:9px}}
@media(max-width:370px){.year-calendar{grid-template-columns:1fr}.shell{padding:20px 12px}.top-inner{padding:14px 12px}.top-right>.btn{display:none}.stats{gap:5px}.stat{padding:11px 9px}.calendar-day{font-size:11px;height:31px}.month-card{padding:17px}.month-header h3{font-size:13px}.tabs{gap:4px}.tab{font-size:9px}.tab svg{display:none}}
@media(prefers-reduced-motion:reduce){.view{animation:none}}
@media print{@page{size:A4 portrait;margin:25mm 22mm}.topbar,.intro,.stats,.storage-strip,.tabs,.request-controls,.preview-header,.preview-foot,.footer,.notice,.toast,dialog,.icon-defs{display:none!important}html,body,.shell,.view,.request-layout,.preview-column,.paper-stage{margin:0!important;padding:0!important;border:0!important;background:white!important;box-shadow:none!important;width:100%!important;max-width:none!important;display:block!important}.view:not(#view-request){display:none!important}.paper{aspect-ratio:auto!important;min-height:0!important;padding:0!important;border:0!important;box-shadow:none!important;font-size:12pt!important}.paper h2{font-size:12pt!important}.paper>p{break-inside:avoid}.print-invalid .paper{display:none!important}}

.mode-switch{display:grid;grid-template-columns:1fr 1fr;padding:4px;gap:4px}.mode-switch button{border:0;border-radius:7px;padding:10px 12px;background:transparent;color:var(--muted);cursor:pointer;font:inherit;font-size:12px;font-weight:650}.mode-switch button.active{background:#fff;color:var(--green);box-shadow:0 1px 5px #213b2114}.mode-switch button:focus-visible{outline:2px solid #6b977a;outline-offset:1px}.manual-dates{margin:13px 0 17px}.manual-dates>summary{font-size:11px;cursor:pointer;color:var(--muted);padding:5px 0}.manual-dates[open]>summary{margin-bottom:10px}.manual-dates .field{margin-bottom:5px}.effective-count{margin-top:16px}.effective-count .label-row{gap:8px;flex-wrap:wrap}.effective-count #selectedCount{font-size:10px;color:var(--green);font-weight:600}.effective-count #selectedCount.mismatch{color:#af642e}.selection-actions{flex-wrap:wrap}

/* Profile editing and date selection stay close to the current request. */
body:has(dialog[open]){overflow:hidden}
#tab-settings{margin-left:auto}
.field-label{display:block;font-size:11px;font-weight:600;margin-bottom:8px}
.date-picker-trigger{width:100%;min-height:78px;display:flex;align-items:center;gap:12px;text-align:left;padding:14px 13px;border:1px solid #cbd9ca;border-radius:10px;background:#fafcf7;color:var(--ink)}
.date-picker-trigger:hover{background:#f0f6ec;border-color:#8caa8c}
.date-picker-trigger.has-date{border-color:#a8c2a8;background:#f2f7ed}
.date-picker-icon{display:grid;place-items:center;width:38px;height:40px;border:1px solid #d5e2ce;background:#eaf2e4;border-radius:9px;color:var(--green);flex:none}
.date-picker-icon svg{width:21px;height:21px}
.date-picker-value{flex:1;min-width:0}
.date-picker-value strong{font-size:13px;font-weight:650;display:block;line-height:1.5}
.date-picker-value small{font-size:10px;color:var(--muted);display:block;margin-top:5px;line-height:1.5}
.date-picker-chevron{font-size:25px;line-height:1;color:#71906f}
.settings-dialog{width:1080px;max-width:calc(100vw - 40px);max-height:calc(100dvh - 48px);overflow:hidden;background:var(--bg)}
.settings-dialog-inner{display:flex;flex-direction:column;max-height:calc(100dvh - 50px)}
.settings-dialog-header{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;padding:24px 26px 21px;background:#fbfcf8;border-bottom:1px solid var(--line);flex:none}
.settings-dialog-header h2{font-size:23px;line-height:1.3;margin:0 0 8px;outline:none}
.settings-dialog-header p:not(.eyebrow){font-size:12px;line-height:1.7;color:var(--muted);margin:0;max-width:580px}
.settings-dialog-header .eyebrow{font-size:9px;margin-bottom:8px}
.settings-dialog-buttons{display:flex;gap:12px;align-items:center;flex:none}
.settings-dialog-feedback{padding:0 26px;flex:none}
.settings-dialog-feedback .notice{margin:12px 0 0}
.settings-dialog-body{padding:23px 26px 26px;overflow-y:auto;overscroll-behavior:contain;min-height:0;scrollbar-gutter:stable}
.settings-dialog .settings-layout{grid-template-columns:340px minmax(0,1fr);gap:18px}
.settings-dialog .card{box-shadow:none}
.settings-dialog .settings-storage{margin-top:18px}
.date-dialog{width:470px;max-width:calc(100vw - 28px);max-height:calc(100dvh - 36px);background:#fff;overscroll-behavior:contain}
.date-dialog-inner{padding:24px 26px}
.date-dialog .dialog-heading{margin-bottom:10px}
.date-dialog .dialog-heading h2{font-size:21px}
.date-dialog-help{font-size:12px;line-height:1.7;color:var(--muted);margin-bottom:16px;max-width:370px}
.date-dialog .leave-date-picker{max-width:none}
.date-dialog .ldp-day,.date-dialog .ldp-calendar td{height:40px;min-height:40px}
.date-dialog .ldp-day{font-size:13px}
.date-dialog .ldp-nav{width:38px;height:36px}
.date-dialog .ldp-calendar th{height:29px;font-size:11px}
.date-dialog .ldp-instruction{font-size:12px}
.date-dialog .ldp-month{font-size:16px}
.date-dialog .ldp-summary{font-size:12px}
.date-dialog .ldp-text-button,.date-dialog .chip-button{font-size:11px}
.date-dialog .manual-dates{border-top:1px solid var(--line);padding-top:9px;margin:15px 0 0}
.date-dialog .manual-dates>summary{font-size:11px}
.date-dialog .selection-actions{margin:12px 0 0;gap:7px}
.date-dialog .dialog-actions{margin-top:18px;padding-top:16px;border-top:1px solid var(--line);justify-content:space-between}
.date-dialog .dialog-actions .primary{min-width:165px}
@media(max-width:850px){.settings-dialog .settings-layout{grid-template-columns:1fr}.settings-dialog-header{gap:18px}.settings-dialog-buttons .btn svg{display:none}.settings-dialog .settings-left{grid-template-columns:1fr 1fr}.settings-dialog-header h2{font-size:21px}}
@media(max-width:620px){.settings-dialog{max-width:calc(100vw - 20px);max-height:calc(100dvh - 24px);border-radius:12px}.settings-dialog-inner{max-height:calc(100dvh - 26px)}.settings-dialog-header{padding:18px;flex-wrap:wrap;gap:14px;position:relative}.settings-dialog-header>div:first-child{padding-right:37px}.settings-dialog-header .eyebrow{font-size:8px}.settings-dialog-header h2{font-size:20px}.settings-dialog-header p:not(.eyebrow){font-size:11px}.settings-dialog-buttons{width:100%}.settings-dialog-buttons .btn{width:100%;min-height:41px}.settings-dialog-buttons .icon-button{position:absolute;right:16px;top:18px}.settings-dialog-body{padding:17px;scrollbar-gutter:auto}.settings-dialog-feedback{padding:0 17px}.settings-dialog .settings-left{grid-template-columns:1fr}.settings-dialog .card{padding:18px}.date-dialog-inner{padding:22px 20px}.date-dialog .dialog-heading h2{font-size:19px}.date-dialog .dialog-actions{flex-wrap:nowrap}.date-dialog .dialog-actions .btn{padding:10px 13px}.date-dialog .dialog-actions .primary{min-width:145px}.date-picker-trigger{min-height:76px}}
@media(max-height:750px){.date-dialog-inner{padding-top:18px;padding-bottom:18px}.date-dialog-help{margin-bottom:10px}.date-dialog .ldp-day,.date-dialog .ldp-calendar td{height:34px;min-height:34px}.date-dialog .ldp-calendar th{height:24px}.date-dialog .dialog-actions{margin-top:13px;padding-top:13px}.date-dialog .ldp-summary{padding:8px 10px}.date-dialog .ldp-note{margin-top:6px}}

.leave-date-picker{--ldp-accent:#235c4e;--ldp-pale:#eaf2ec;--ldp-ink:#263d35;--ldp-muted:#738278;width:100%;min-width:0;font-family:inherit;color:var(--ldp-ink)}
.leave-date-picker *{box-sizing:border-box}
.ldp-instruction{min-height:36px;margin:0 0 8px;font-size:12px;line-height:1.5;font-weight:600;color:var(--ldp-accent)}
.ldp-months{display:grid;grid-template-columns:minmax(0,1fr);gap:20px;min-width:0}
.leave-date-picker.has-two-months .ldp-months{grid-template-columns:repeat(2,minmax(0,1fr))}
.ldp-panel{min-width:0}
.ldp-header{display:grid;grid-template-columns:32px minmax(0,1fr) 32px;align-items:center;gap:8px;margin-bottom:6px}
.ldp-nav-slot{display:block;width:32px;height:32px}
.ldp-month{width:100%;min-height:32px;padding:5px 2px;border:0;border-radius:8px;background:transparent;color:var(--ldp-ink);font-family:inherit;text-align:center;font-size:14px;font-weight:650;letter-spacing:-.2px;text-transform:capitalize;cursor:pointer}
.ldp-month::after{content:"⌄";margin-left:7px;font-size:12px;color:var(--ldp-muted)}
.ldp-month:hover{background:var(--ldp-pale)}
.ldp-jump{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(80px,1fr) auto auto;align-items:end;gap:10px;margin:0 0 14px;padding:12px;border:1px solid #dce5db;border-radius:10px;background:#f7f9f5}
.ldp-jump label{display:grid;gap:5px;min-width:0;font-size:11px;font-weight:600;color:var(--ldp-muted)}
.ldp-jump select,.ldp-jump input{width:100%;min-width:0;height:40px;padding:8px;border:1px solid #cbd8cd;border-radius:8px;background:#fff;color:var(--ldp-ink);font:inherit;font-size:13px;box-sizing:border-box}
.ldp-jump-apply{min-height:40px;padding:8px 12px;border:1px solid var(--ldp-accent);border-radius:8px;background:var(--ldp-accent);color:#fff;font:inherit;font-size:12px;font-weight:600;cursor:pointer}
.ldp-jump .ldp-text-button{min-height:40px;padding:8px 2px}
.ldp-nav{height:32px;width:32px;padding:0;display:grid;place-items:center;border:1px solid #dce5db;border-radius:8px;background:#fff;color:var(--ldp-ink);font-family:inherit;font-size:24px;line-height:1;cursor:pointer}
.ldp-nav:hover:not(:disabled){background:var(--ldp-pale);border-color:#adc4b1}
.ldp-nav:disabled{opacity:.35;cursor:default}
.ldp-calendar{width:100%;table-layout:fixed;border-collapse:separate;border-spacing:3px;font-size:12px;margin:0}
.ldp-calendar th{font-size:10px;font-weight:550;color:var(--ldp-muted);height:26px;text-align:center;padding:0;border:0;background:none}
.ldp-calendar td{padding:0;text-align:center;border:0;background:none;vertical-align:middle;height:34px}
.ldp-day{width:100%;height:34px;min-height:34px;padding:0;border:1px solid transparent;border-radius:8px;background:transparent;color:var(--ldp-ink);font-family:inherit;font-size:12px;font-weight:500;cursor:pointer;position:relative;transition:background .12s,color .12s,border-color .12s}
.ldp-day.outside{color:#a2afa4}
.ldp-day.weekend:not(.selected):not(.pending-start){color:#9a8c76}
.ldp-day:hover:not(:disabled){background:#edf2e9;border-color:#c4d6c4}
.ldp-day.in-range{background:var(--ldp-pale);color:var(--ldp-accent)}
.ldp-day.in-range.tentative{background:#edf3e8;border-color:#bfd1ba}
.ldp-day.selected{background:var(--ldp-accent);color:#fff;font-weight:650}
.ldp-day.selected:hover{background:#194a3e;border-color:#174236}
.ldp-day.pending-start{background:var(--ldp-accent);color:#fff;font-weight:650;outline:2px solid #9ebda9;outline-offset:1px}
.ldp-day.range-start.in-range:not(.selected),.ldp-day.range-end.in-range:not(.selected){border-color:#9ab99f}
.ldp-day[aria-current=date]::after{content:"";position:absolute;bottom:4px;left:calc(50% - 2px);width:4px;height:4px;border-radius:50%;background:currentColor}
.ldp-day:focus-visible,.ldp-nav:focus-visible,.ldp-month:focus-visible,.ldp-text-button:focus-visible,.ldp-jump-apply:focus-visible,.ldp-jump select:focus-visible,.ldp-jump input:focus-visible{outline:3px solid #8ebba4;outline-offset:2px;z-index:1}
.ldp-toolbar{display:flex;justify-content:space-between;align-items:center;margin:6px 0 9px;padding:0 3px}
.ldp-text-button{border:0;background:none;padding:4px 0;color:var(--ldp-accent);font-family:inherit;font-size:11px;font-weight:650;cursor:pointer}
.ldp-text-button:hover:not(:disabled){text-decoration:underline}
.ldp-text-button:disabled{color:#a3afa4;cursor:default}
.ldp-summary{margin:0;padding:10px 11px;border:1px solid #dce8da;background:#f4f7f1;border-radius:8px;font-size:12px;font-weight:600;line-height:1.6;overflow-wrap:anywhere}
.ldp-note{font-size:11px;line-height:1.6;color:var(--ldp-muted);margin:8px 1px 0}
.ldp-error{font-size:12px;line-height:1.6;margin:9px 0 0;padding:9px 10px;border-radius:7px;color:#9b4334;background:#fff0eb;border:1px solid #edcec5}
.leave-date-picker [hidden]{display:none!important}
@media(max-width:620px){.ldp-jump{grid-template-columns:minmax(0,1.5fr) minmax(90px,1fr)}.ldp-jump select,.ldp-jump input{font-size:16px}.ldp-jump-apply,.ldp-jump .ldp-text-button{min-height:44px}}
@media(max-width:380px){.ldp-calendar{border-spacing:2px}.ldp-day,.ldp-calendar td{height:32px;min-height:32px}.ldp-day{font-size:11px}.ldp-month{font-size:13px}.ldp-summary{font-size:11px}}
@media(prefers-reduced-motion:reduce){.ldp-day{transition:none}}

/* One focused workspace, with secondary tasks one click away. */
@media screen {
:root { --shadow:0 6px 28px #23324705; font-family:Inter,"Segoe UI",Arial,sans-serif; }
body { background:var(--bg); -webkit-font-smoothing:antialiased; }
button,a,input,select,textarea,summary { -webkit-tap-highlight-color:transparent; }
.topbar { background:#fff; border-bottom:1px solid var(--line); }
.top-inner { max-width:1180px; min-height:80px; padding:14px 32px; gap:24px; }
.brand { gap:12px; flex:none; }
.brand-symbol { width:38px; height:38px; border-radius:12px; background:var(--ink); border-color:var(--ink); color:#fff; }
.brand-symbol svg { width:20px; height:20px; }
.brand strong { font-size:17px; font-weight:650; letter-spacing:-.5px; }
.main-nav.tabs { gap:4px; border:0; margin:0; align-items:center; }
.main-nav .tab { min-height:44px; padding:11px 15px; border-radius:10px; font-size:13px; gap:8px; color:#6b7686; }
.main-nav .tab svg { width:17px; height:17px; }
.main-nav .tab.active { color:var(--green); background:var(--pale); }
.main-nav .tab.active::after { display:none; }
.main-nav .tab:hover { color:var(--ink); background:#f3f5f8; }
.main-nav #tab-settings { margin-left:14px; }
.main-nav .count-badge { color:#627086; background:#e9edf3; border-radius:5px; min-width:19px; font-size:10px; text-align:center; padding:2px 5px; }
.main-nav .dirty-dot { flex:none; }
.shell { max-width:1180px; padding:44px 32px 24px; }
body[data-view="request"] .shell > .notice { max-width:700px; margin:0 auto 20px; }
.quick-wrap { max-width:700px; margin:0 auto; }
.quick-heading { display:flex; justify-content:space-between; align-items:center; gap:24px; margin-bottom:26px; }
.quick-heading .eyebrow { font-size:10px; font-weight:650; letter-spacing:1.6px; color:#65758b; margin:0 0 10px; }
.quick-heading h1 { font-size:30px; font-weight:650; letter-spacing:-1.05px; line-height:1.22; margin:0 0 9px; max-width:none; }
.quick-subtitle { font-size:12px; line-height:1.7; color:var(--muted); margin:0; }
.balance-pill { display:flex; flex-direction:column; align-items:flex-start; gap:7px; flex:none; min-height:84px; max-width:235px; padding:13px 15px; color:var(--ink); background:#eaf0f6; border:1px solid #dde5ef; border-radius:14px; font-size:12px; line-height:1.5; text-align:left; }
.balance-pill:hover { border-color:#a7bad1; background:#e4ecf5; }
.balance-heading { display:flex; align-items:center; gap:6px; font-size:10px; color:#64758a; }
.balance-dot { width:5px; height:5px; border-radius:50%; background:#7591ad; }
.balance-pill #quickYear { margin-left:5px; font-size:10px; font-weight:500; }
.balance-pill #quickRemaining { font-size:14px; font-weight:650; letter-spacing:-.15px; }
.balance-link { display:flex; align-items:center; gap:22px; font-size:10px; color:#536e8c; }
.balance-link > svg { width:13px; height:13px; transform:rotate(-45deg); }
.card { border-color:var(--line); box-shadow:none; }
.quick-card { padding:0; border-radius:20px; box-shadow:0 12px 40px #23324706,0 2px 4px #23324702; overflow:hidden; }
.quick-profile { display:flex; align-items:center; gap:12px; padding:20px 26px; margin:0; background:#fbfcfe; border-bottom:1px solid var(--line); }
.profile-avatar { width:40px; height:40px; border:1px solid #e0e7f0; border-radius:50%; background:#eaf0f8; color:#597292; display:grid; place-items:center; font-size:12px; font-weight:650; flex:none; letter-spacing:.5px; }
.profile-identity { display:flex; flex-direction:column; gap:4px; min-width:0; line-height:1.5; flex:1; }
.profile-identity #profileName { font-size:14px; font-weight:650; overflow-wrap:anywhere; }
.profile-identity #profileCompany { font-size:11px; color:var(--muted); overflow-wrap:anywhere; }
.quick-profile .text-btn { display:flex; align-items:center; gap:6px; min-height:44px; padding:8px 0 8px 8px; font-size:11px; font-weight:600; flex:none; color:#5d708b; }
.quick-profile .text-btn svg { width:14px; height:14px; }
.request-fields { padding:24px 26px 22px; }
.mode-switch { display:grid; grid-template-columns:1fr 1fr; gap:4px; padding:4px; border:1px solid #e7ebf1; border-radius:12px; background:#f3f5f8; }
.quick-card .mode-switch { margin:0 0 23px; }
.quick-card .mode-switch button { display:flex; align-items:center; justify-content:center; gap:8px; min-height:44px; border-radius:9px; font-size:13px; font-weight:600; padding:11px 12px; color:#64758a; }
.quick-card .mode-switch button svg { width:16px; height:16px; }
.quick-card .mode-switch button.active { color:var(--green); background:#fff; box-shadow:0 1px 5px #22354c12; }
.quick-card .mode-switch button:not(.active):hover { color:var(--green); background:#e9eef5; }
.mode-switch button:focus-visible { outline:3px solid #6289c2; outline-offset:1px; }
.quick-card .field { margin-bottom:19px; }
.quick-card .field label,.quick-card .field-label { font-size:12px; font-weight:600; margin-bottom:9px; color:#536176; }
.quick-card .field input { min-height:46px; height:46px; font-size:14px; border:1px solid #d7e0eb; border-radius:9px; }
.quick-card .date-picker-trigger { min-height:88px; padding:16px; gap:13px; border:1px solid #cfdae8; background:#fff; border-radius:13px; }
.quick-card .date-picker-trigger:hover { background:#f8fafd; border-color:#8ba5c6; }
.quick-card .date-picker-trigger.has-date { border-color:#b6c8df; background:#f8fafd; }
.quick-card .date-picker-icon { width:43px; height:45px; background:#edf2f8; border:0; border-radius:11px; color:#5b789b; }
.quick-card .date-picker-icon svg { width:22px; height:22px; }
.quick-card .date-picker-value strong { font-size:16px; letter-spacing:-.25px; font-weight:600; line-height:1.5; }
.quick-card .date-picker-value small { font-size:11px; margin-top:4px; line-height:1.5; color:#66768b; }
.quick-card .date-picker-chevron { width:28px; height:28px; display:grid; place-items:center; background:#f2f5f9; border-radius:50%; color:#7b91aa; font-size:23px; }
.quick-card .effective-count { margin-top:18px; }
.quick-card .effective-count .label-row { gap:9px; flex-wrap:wrap; }
.quick-card .effective-count .label-row label { margin:0; }
.quick-card .effective-count #selectedCount { font-size:11px; }
.quick-card .hint { font-size:11px; line-height:1.65; }
.request-options { margin:2px 0 19px; border-bottom:1px solid #edf0f4; }
.request-options > summary { display:flex; align-items:center; gap:12px; min-height:46px; padding:0 1px 8px; font-size:12px; line-height:1.5; color:#6e7a8c; list-style:none; cursor:pointer; border-radius:6px; }
.request-options > summary::-webkit-details-marker { display:none; }
.request-options > summary::after { content:'›'; font-size:20px; line-height:1; transform:rotate(90deg); transition:transform .15s; color:#8997aa; }
.request-options[open] > summary::after { transform:rotate(-90deg); }
.request-options > summary:hover { color:var(--green); }
.request-options #requestDateSummary { margin-left:auto; color:#52657f; font-weight:500; text-align:right; }
.request-date-controls { display:flex; align-items:flex-end; gap:12px; padding:5px 0 16px; }
.request-date-controls .field { flex:1; margin:0; }
.request-date-controls .text-btn { min-height:46px; min-width:52px; font-size:12px; }
.quick-card .charge-summary { margin:0 0 18px; padding:11px 13px; border:1px solid #dee7f1; background:#f2f6fb; color:#63758c; border-radius:10px; font-size:12px; }
.quick-card .charge-summary.insufficient { background:#fff2ec; border-color:#edcbbf; color:var(--red); }
.quick-card .notice { margin:0 0 16px; font-size:12px; }
.generator-actions { display:grid; grid-template-columns:1fr 1.45fr; gap:12px; align-items:stretch; }
.generator-actions .btn { min-height:50px; padding:12px 16px; font-size:12px; border-radius:10px; gap:8px; }
.generator-actions .btn.quiet { border:1px solid #dce3ed; background:white; color:#5f7087; }
.generator-actions .btn.quiet:hover { background:#f7f9fc; border-color:#a6b9d1; }
.generator-actions .btn.primary { font-size:13px; background:var(--green); border-color:var(--green); box-shadow:0 3px 6px #304e7212; }
.generator-actions .btn.primary:hover { background:var(--green-dark); border-color:var(--green-dark); }
.generator-actions .generate-arrow { width:16px; height:16px; margin-left:auto; opacity:.65; }
.generator-actions .btn.primary > svg:first-child { margin-right:auto; }
.quick-card #generateHint { margin-top:12px; }
.saved-actions { display:flex; align-items:center; justify-content:space-between; gap:8px 14px; flex-wrap:wrap; margin-top:15px; padding:9px 12px; color:#3f6753; background:#f0f7f3; border:1px solid #dceadf; border-radius:9px; font-size:12px; line-height:1.6; }
.saved-actions > span { display:inline-flex; gap:6px; align-items:center; }
.saved-actions .text-btn { font-size:12px; min-height:40px; }
.quick-card .storage-strip { margin:0; padding:10px 26px; min-height:57px; background:#fbfcfe; border:0; border-top:1px solid var(--line); border-radius:0; gap:14px; align-items:center; }
.quick-card .storage-strip > div { gap:8px; align-items:center; }
.quick-card .storage-strip svg { width:15px; height:15px; color:#8c9aab; margin:0; }
.quick-card .storage-strip strong { font-size:11px; line-height:1.5; color:#66758a; font-weight:400; }
.quick-card .storage-strip small.sr-only { margin:0; }
.quick-card .storage-strip button { min-height:36px; padding:6px 0 6px 6px; font-size:11px; white-space:nowrap; color:#5d7491; }
.quick-card .storage-strip.has-warning { background:#fff9ed; align-items:flex-start; }
.quick-card .storage-strip.has-warning strong { color:var(--amber); font-weight:600; }
.quick-card .storage-strip.has-warning small { color:var(--amber); font-size:11px; max-width:440px; }
.footer { border:0; font-size:10px; margin-top:20px; padding:0 2px; align-items:center; gap:8px 16px; color:#65758a; }
body[data-view="request"] .footer { max-width:700px; margin-left:auto; margin-right:auto; }
.footer .footer-links { display:flex; align-items:center; gap:20px; }
.footer .text-btn,.footer a { font-size:10px; font-weight:400; color:#65758a; min-height:38px; display:inline-flex; align-items:center; }
.footer a { text-decoration:none; }
.footer a:hover { text-decoration:underline; }
.ledger-toolbar { display:flex; align-items:center; justify-content:space-between; gap:20px; margin-bottom:24px; }
.ledger-toolbar h1 { font-size:28px; letter-spacing:-.9px; font-weight:650; margin:0; max-width:none; }
.ledger-toolbar .year-switch { height:44px; border-radius:11px; margin:0; }
.ledger-toolbar .year-switch button { min-width:36px; height:36px; border-radius:7px; }
.ledger-toolbar .year-switch button:hover { background:var(--pale); }
.ledger-overview .stats { gap:15px; margin-bottom:32px; }
.ledger-overview .stat { min-height:126px; padding:21px 23px; border-radius:15px; box-shadow:none; }
.ledger-overview .stat-label { font-size:12px; font-weight:500; color:#65758b; }
.ledger-overview .stat-value { margin:11px 0 8px; }
.ledger-overview .stat-value strong { font-size:32px; font-weight:600; }
.ledger-overview .stat small { font-size:11px; color:#65758a; }
.ledger-overview .stat-icon { top:21px; right:22px; color:#a0afc1; }
.ledger-overview .stat-icon svg { width:20px; height:20px; }
.ledger-overview .stat.available { background:#eaf0f7; border-color:#dae3ef; }
.ledger-overview .stat.available .stat-icon { color:#6b87a8; }
.view-heading { margin-bottom:22px; }
.view-heading h2 { font-size:20px; font-weight:600; }
.view-heading p { font-size:12px; max-width:640px; }
.legend { font-size:11px; gap:16px; }
.year-calendar { gap:16px; }
.month-card { padding:18px 15px; border-radius:14px; }
.month-header { margin-bottom:14px; }
.month-header h3 { font-size:13px; font-weight:600; }
.month-header span { background:var(--pale); color:#5d7898; font-size:9px; }
.month-weekday { color:#65758a; font-size:10px; padding-bottom:9px; }
.calendar-day { color:#51657f; font-size:11px; height:32px; border-radius:7px; }
.calendar-day.weekend { color:#6c7c90; }
.calendar-day.today { border-color:#8aa5c9; }
.calendar-day.leave { background:var(--green); color:white; }
.calendar-day:not(.leave):hover { background:var(--pale); }
.footnote { font-size:11px; color:#65758a; }
.history-filters { gap:12px; margin-bottom:16px; }
.history-filters input,.history-filters select { height:44px; border:1px solid #d8e1ec; border-radius:10px; font-size:12px; color:var(--ink); }
.history-filters input::placeholder { color:#8e9bad; }
.search-field { width:400px; }
.history-table-wrap { border-radius:15px; }
.history-table th { background:#f9fafc; color:#65758a; font-size:10px; font-weight:600; padding:17px 20px; }
.history-table td { padding:20px; border-color:#edf0f4; }
.history-table td small { font-size:10px; }
.history-table tbody tr:hover { background:#fafcfe; }
.history-table .badge:not(.cancelled):not(.pending) { background:#edf3fa; color:#4d7098; }
.table-actions .text-btn { min-height:36px; }
.empty-state { padding:50px 24px; }
.empty-icon { border-color:#e0e7f1; background:#edf2f8; color:#7d96b7; border-radius:14px; }
.empty-state p { font-size:12px; }
.history-footer { font-size:11px; padding-top:17px; }
.btn { border-color:#d6dfea; border-radius:9px; }
.btn:hover { background:#f4f7fb; border-color:#9aafca; }
.btn.primary:hover { background:var(--green-dark); }
.toast { background:var(--ink); box-shadow:0 8px 30px #23324720; }
}
@media screen and (max-width:850px) {
.top-inner { padding:13px 22px; gap:18px; }
.main-nav .tab { padding:10px 11px; font-size:12px; }
.main-nav #tab-settings { margin-left:4px; }
.shell { padding:32px 22px 20px; }
.year-calendar { grid-template-columns:repeat(3,1fr); }
.ledger-overview .stat { padding:18px; }
.ledger-overview .stat small { font-size:10px; }
}
@media screen and (max-width:620px) {
body { padding-bottom:88px; }
.top-inner { min-height:66px; padding:12px 20px; }
.brand-symbol { width:34px; height:34px; border-radius:10px; }
.brand strong { font-size:16px; }
.main-nav.tabs { position:fixed; z-index:10; left:12px; right:12px; bottom:max(10px,env(safe-area-inset-bottom)); display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:4px; padding:6px; margin:0; border:1px solid #dce3ed; border-radius:18px; background:#fff; box-shadow:0 8px 32px #2438501a; }
.main-nav .tab { min-height:52px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:5px; font-size:10px; padding:7px 4px; border-radius:12px; }
.main-nav .tab svg { display:block; width:17px; height:17px; }
.main-nav #tab-settings { margin:0; }
.main-nav .count-badge { position:absolute; top:3px; right:12px; font-size:9px; min-width:15px; padding:1px 4px; }
.main-nav .dirty-dot { position:absolute; top:8px; right:25%; }
.shell { padding:24px 16px 12px; }
.quick-heading { display:block; margin-bottom:19px; }
.quick-heading .eyebrow { font-size:9px; margin-bottom:8px; }
.quick-heading h1 { font-size:27px; letter-spacing:-.8px; margin-bottom:7px; }
.quick-subtitle { font-size:12px; }
.balance-pill { max-width:none; width:100%; min-height:42px; margin-top:16px; display:flex; flex-direction:row; align-items:center; justify-content:space-between; gap:8px; padding:10px 12px; border-radius:10px; }
.balance-heading { font-size:10px; gap:5px; }
.balance-pill #quickYear { margin-left:3px; }
.balance-pill #quickRemaining { font-size:12px; }
.balance-link { display:none; }
.quick-card { border-radius:16px; }
.quick-profile { padding:15px 18px; gap:10px; }
.profile-avatar { width:34px; height:34px; font-size:11px; }
.profile-identity #profileName { font-size:13px; }
.profile-identity #profileCompany { font-size:10px; }
.quick-profile .text-btn { font-size:10px; gap:5px; padding-left:5px; }
.quick-profile .text-btn svg { width:13px; height:13px; }
.request-fields { padding:19px 18px 20px; }
.quick-card .mode-switch { margin-bottom:20px; }
.quick-card .mode-switch button { font-size:12px; min-height:42px; }
.quick-card .date-picker-trigger { min-height:82px; padding:13px; gap:10px; }
.quick-card .date-picker-icon { width:37px; height:40px; }
.quick-card .date-picker-icon svg { width:20px; height:20px; }
.quick-card .date-picker-value strong { font-size:14px; }
.quick-card .date-picker-value small { font-size:10px; }
.quick-card .date-picker-chevron { width:23px; height:23px; font-size:21px; }
.quick-card .field { margin-bottom:17px; }
.quick-card .hint { font-size:10px; }
.quick-card .effective-count #selectedCount { font-size:10px; }
.request-options { margin-bottom:17px; }
.request-options > summary { font-size:11px; gap:8px; }
.generator-actions { grid-template-columns:1fr 1.23fr; gap:9px; }
.generator-actions .btn { min-height:48px; padding:11px 10px; font-size:11px; gap:6px; }
.generator-actions .btn.primary { font-size:12px; }
.generator-actions .btn svg { width:16px; height:16px; }
.generator-actions .generate-arrow { display:none; }
.generator-actions .btn.primary > svg:first-child { margin:0; }
.quick-card .storage-strip { padding:9px 18px; gap:10px; min-height:54px; }
.quick-card .storage-strip strong,.quick-card .storage-strip button { font-size:10px; }
.quick-card .storage-strip svg { width:13px; height:13px; }
.footer { margin-top:13px; gap:4px 12px; font-size:9px; }
.footer .footer-links { gap:14px; }
.footer .text-btn,.footer a { font-size:9px; }
.ledger-toolbar { gap:12px; margin-bottom:20px; }
.ledger-toolbar h1 { font-size:22px; }
.ledger-toolbar .year-switch input { width:48px; }
.ledger-toolbar .year-switch button { min-width:26px; }
.ledger-overview .stats { gap:8px; margin-bottom:27px; }
.ledger-overview .stat { min-height:123px; padding:14px 11px; border-radius:12px; }
.ledger-overview .stat-label { min-height:30px; font-size:10px; line-height:1.5; }
.ledger-overview .stat-value { margin:9px 0 7px; }
.ledger-overview .stat-value strong { font-size:27px; }
.ledger-overview .stat-value > span { font-size:10px; }
.ledger-overview .stat small { font-size:9px; line-height:1.5; }
.view-heading { gap:14px; margin-bottom:18px; }
.view-heading h2 { font-size:19px; }
.view-heading p { font-size:11px; }
.year-calendar { grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.month-card { padding:14px 10px; border-radius:12px; }
.month-header h3 { font-size:12px; }
.month-header span { font-size:8px; }
.month-weekday { font-size:8px; }
.calendar-day { height:28px; font-size:10px; }
.history-filters { gap:8px; }
.history-filters input,.history-filters select { font-size:11px; }
.history-table th,.history-table td { padding:16px 14px; }
.history-footer { font-size:10px; }
.footnote { font-size:10px; }
.toast { bottom:90px; max-width:calc(100vw - 32px); width:max-content; }
}
@media screen and (max-width:360px) {
.shell { padding-left:12px; padding-right:12px; }
.quick-heading h1 { font-size:25px; }
.balance-pill { padding:9px 10px; }
.balance-heading { font-size:9px; }
.balance-pill #quickRemaining { font-size:11px; }
.profile-avatar { display:none; }
.quick-profile { padding-left:16px; padding-right:16px; }
.request-fields { padding-left:16px; padding-right:16px; }
.quick-card .storage-strip { padding-left:16px; padding-right:16px; }
.generator-actions .btn { padding-left:8px; padding-right:8px; font-size:10px; }
.generator-actions .btn.primary { font-size:11px; }
.main-nav .count-badge { right:9px; }
.year-calendar { grid-template-columns:1fr; }
.calendar-day { height:36px; font-size:12px; }
}
@media (prefers-reduced-motion:reduce) {
.request-options > summary::after { transition:none; }
}

@media screen {
.preview-dialog { width:790px; max-width:calc(100vw - 36px); max-height:calc(100dvh - 36px); background:#f5f7f1; overflow:auto; overscroll-behavior:contain; }
.preview-dialog-inner { padding:24px; }
.preview-dialog-header, .preview-dialog .dialog-heading { display:flex; justify-content:space-between; align-items:center; gap:20px; margin-bottom:20px; }
.preview-dialog-header h2, .preview-dialog .dialog-heading h2 { margin:0; font-size:21px; letter-spacing:-.45px; }
.preview-dialog-header p, .preview-dialog .dialog-heading p { margin:5px 0 0; color:var(--muted); font-size:12px; line-height:1.5; }
.preview-dialog-tools { display:flex; gap:16px; align-items:center; flex:none; }
.preview-dialog-tools .text-btn { min-height:44px; font-size:12px; }
.preview-dialog .icon-button { min-width:42px; width:42px; height:42px; }
.preview-dialog .paper-stage { padding:18px; border-color:#dce4d6; border-radius:10px; }
.preview-dialog .paper { min-height:0; max-width:none; margin:0; padding:60px 53px; aspect-ratio:210/297; font-size:14px; }
.preview-dialog .paper h2 { font-size:14px; }
.preview-dialog .preview-foot { font-size:11px; line-height:1.6; margin-top:17px; }
.preview-dialog .preview-foot .btn { min-height:44px; flex:none; }

}
@media screen and (max-width:620px) {
 .preview-dialog-header { align-items:flex-start; }
 .preview-dialog-tools .text-btn { max-width:70px; line-height:1.6; }
 .preview-dialog .paper { padding:32px 24px; min-height:430px; font-size:11px; }
 .preview-dialog .paper h2 { font-size:11px; margin-bottom:24px; }
 .preview-dialog .preview-foot .btn { padding:10px 12px; font-size:12px; }
}

@media print {
  html, body, body:has(dialog[open]) { overflow:visible!important; height:auto!important; background:#fff!important; }
  body > *:not(#previewDialog) { display:none!important; }
  #previewDialog { display:block!important; position:static!important; inset:auto!important; width:auto!important; max-width:none!important; height:auto!important; max-height:none!important; margin:0!important; padding:0!important; border:0!important; border-radius:0!important; background:#fff!important; overflow:visible!important; box-shadow:none!important; }
  #previewDialog::backdrop { display:none!important; }
  #previewDialog .preview-dialog-header, #previewDialog .dialog-heading, #previewDialog .preview-foot, #previewDialog .dialog-actions, #previewDialog .notice { display:none!important; }
  #previewDialog .preview-dialog-inner, #previewDialog .dialog-inner, #previewDialog .paper-stage { display:block!important; width:auto!important; height:auto!important; margin:0!important; padding:0!important; border:0!important; background:#fff!important; overflow:visible!important; box-shadow:none!important; }
  #previewDialog .paper { display:block!important; aspect-ratio:auto!important; width:100%!important; min-height:0!important; height:auto!important; margin:0!important; padding:0!important; border:0!important; box-shadow:none!important; font-size:12pt!important; line-height:1.85!important; }
  #previewDialog .paper h2 { font-size:12pt!important; }
  .print-invalid #previewDialog { display:none!important; }
}

@media screen {
 .generator-actions.full-actions { grid-template-columns:1.1fr .9fr 1.35fr; }
 .generator-actions.full-actions .btn { padding-left:12px; padding-right:12px; }
 .quick-card .storage-strip .storage-summary { display:flex; flex:1; align-items:center; gap:9px; min-width:0; min-height:42px; padding:3px 0; border:0; background:none; text-align:left; white-space:normal; cursor:pointer; }
 .quick-card .storage-summary > svg { flex:none; }
 .quick-card .storage-summary > span { min-width:0; }
 .quick-card .storage-summary strong { display:block; font-size:11px; }
 .quick-card .storage-summary small { display:block; margin-top:3px; font-size:10px; line-height:1.5; color:#7a8799; }
 .quick-card .storage-summary:hover strong { color:var(--green); text-decoration:underline; text-underline-offset:3px; }
 .quick-card .storage-summary:focus-visible { outline:2px solid #9bb8df; outline-offset:4px; border-radius:5px; }
 #actionContent > p { white-space:pre-line; }
 .calendar-count { margin:17px 0 12px; padding:16px 17px; border:1px solid #dce4ee; border-radius:11px; background:#f6f8fc; }
 .calendar-count .label-row { align-items:center; gap:12px; }
 .calendar-count .label-row label { font-size:12px; }
 .calendar-count #selectedCount { font-size:11px; color:#62738a; white-space:nowrap; }
 .calendar-count #selectedCount.mismatch { color:var(--red); }
 .calendar-count input { max-width:180px; min-height:44px; font-size:16px; }
 .calendar-count input[aria-invalid=true] { border-color:var(--red); }
 .calendar-count .hint { font-size:11px; max-width:600px; }
 .preview-dialog .preview-foot { align-items:flex-start; flex-direction:column; gap:14px; }
 .preview-action-buttons { display:flex; gap:10px; flex-wrap:wrap; align-items:center; width:100%; }
 .preview-action-buttons > .text-btn { margin-left:auto; padding:10px 4px; min-height:44px; }
 .preview-action-buttons .btn { gap:7px; }
}
@media screen and (max-width:620px) {
 .generator-actions.full-actions { grid-template-columns:1fr 1.35fr; gap:10px; }
 .generator-actions.full-actions #previewButton { grid-column:1 / -1; min-height:34px; padding:5px 10px; border:0; background:transparent; }
 .generator-actions.full-actions .generate-arrow { display:none; }
 .generator-actions.full-actions .btn.primary > svg:first-child { margin-right:0; }
 .quick-card .storage-strip { align-items:center; gap:10px; }
 .quick-card .storage-strip .storage-summary { padding-left:0; }
 .quick-card .storage-summary strong { font-size:10px; }
 .quick-card .storage-summary small { font-size:9px; }
 .calendar-count { padding:14px; }
 .calendar-count .label-row { align-items:flex-start; flex-wrap:wrap; gap:5px; }
 .preview-action-buttons { display:grid; grid-template-columns:1fr 1.3fr; }
 .preview-action-buttons > .text-btn { grid-column:1 / -1; margin:0; text-align:center; }
}

/* Screen-only dialog styling; document typography and A4 printing stay isolated. */
@media screen {
  dialog {
    border:1px solid var(--line);
    border-radius:20px;
    background:#fff;
    color:var(--ink);
    box-shadow:0 24px 90px #1c2f4c26,0 3px 12px #1c2f4c0d;
    max-height:calc(100dvh - 40px);
    overscroll-behavior:contain;
  }
  dialog::backdrop { background:#16253c66; backdrop-filter:blur(4px); }
  dialog .icon-button { width:44px; min-width:44px; height:44px; border-color:var(--line); border-radius:12px; color:var(--muted); background:#fff; }
  dialog .icon-button:hover { color:var(--ink); background:#f1f4f8; border-color:#cdd7e4; }
  dialog .btn { min-height:44px; border-radius:10px; }
  dialog .text-btn { min-height:44px; }
  dialog button:focus-visible, dialog summary:focus-visible, dialog a:focus-visible { outline:3px solid #a3b8d5; outline-offset:3px; }
  dialog .field label { font-size:12px; line-height:1.5; margin-bottom:8px; }
  dialog .field input, dialog select, dialog .action-input {
    min-height:44px;
    height:44px;
    padding:11px 12px;
    border:1px solid #d5dde8;
    border-radius:10px;
    color:var(--ink);
    background:#fff;
    font-size:13px;
  }
  dialog .field input::placeholder, dialog .action-input::placeholder { color:#8793a3; }
  dialog .field input:focus, dialog select:focus, dialog .template-piece:focus, dialog .action-input:focus { border-color:#7994b6; outline:3px solid #dce6f3; outline-offset:0; }
  dialog .hint { font-size:11px; line-height:1.65; color:var(--muted); }
  dialog .eyebrow { font-size:10px; letter-spacing:1.1px; color:var(--green); }
  .dialog-inner { padding:28px; }
  .dialog-heading { gap:18px; margin-bottom:22px; }
  .dialog-heading h2 { font-size:23px; font-weight:650; letter-spacing:-.6px; }
  .dialog-inner p, .dialog-inner ul, .help-list { color:var(--muted); }
  .dialog-actions { gap:10px; margin-top:24px; }
  .detail-meta { gap:10px; font-size:12px; }
  .detail-text { background:#f7f9fc; border-color:var(--line); border-radius:12px; }
  .detail-date { padding:7px 9px; border-radius:7px; background:var(--pale); color:var(--green); }
  .detail-meta .badge:not(.cancelled):not(.pending) { color:var(--green); background:var(--pale); }

  /* The header stays outside the independently scrolling settings body. */
  .settings-dialog { width:1080px; max-width:calc(100vw - 48px); max-height:calc(100dvh - 48px); background:var(--bg); overflow:hidden; }
  .settings-dialog-inner { max-height:calc(100dvh - 50px); }
  .settings-dialog-header { padding:25px 28px 23px; gap:24px; background:#fff; border-color:var(--line); }
  .settings-dialog-header h2 { font-size:25px; letter-spacing:-.65px; margin:0 0 8px; font-weight:650; }
  .settings-dialog-header .eyebrow { font-size:10px; margin-bottom:8px; }
  .settings-dialog-header p:not(.eyebrow) { max-width:550px; font-size:12px; line-height:1.65; }
  .settings-dialog-buttons { gap:10px; }
  .settings-dialog-buttons .btn { padding:12px 17px; font-size:12px; white-space:nowrap; }
  .settings-dialog-feedback { padding:0 28px; }
  .settings-dialog-body { padding:24px 28px 28px; }
  .settings-dialog .settings-layout { grid-template-columns:340px minmax(0,1fr); gap:20px; }
  .settings-dialog .settings-left { gap:20px; }
  .settings-dialog .card { border-radius:16px; padding:23px; border-color:var(--line); box-shadow:none; }
  .settings-dialog .section-head { margin-bottom:21px; gap:14px; }
  .settings-dialog .section-head h3 { font-size:15px; font-weight:650; letter-spacing:-.25px; }
  .settings-dialog .section-head p { font-size:11px; }
  .settings-dialog .field { margin-bottom:18px; }
  .settings-dialog .field:last-child { margin-bottom:0; }
  .settings-dialog .input-prefix { border-color:#d5dde8; border-radius:10px; background:#f3f6fa; }
  .settings-dialog .input-prefix > span { align-self:stretch; display:flex; align-items:center; justify-content:center; min-width:44px; background:#f1f4f8; color:#62738a; border-color:var(--line); }
  .settings-dialog .input-prefix input { border:0; border-radius:0; }
  .settings-dialog .input-prefix:focus-within { border-color:#7994b6; outline:3px solid #dce6f3; }
  .settings-dialog .input-prefix input:focus { outline:none; }
  .settings-dialog .optional { font-size:11px; }
  .settings-dialog .template-note { margin:0 0 20px; padding:12px 13px; border-color:#dce5f0; border-radius:10px; background:#f1f5fa; color:#516781; }
  .settings-dialog .template-section { border-color:var(--line); padding:10px 0; }
  .settings-dialog .template-section > summary { min-height:40px; padding:11px 0; color:var(--green); font-size:12px; line-height:1.5; }
  .settings-dialog .template-section[open] > summary { margin-bottom:6px; }
  .settings-dialog .template-flow { padding:12px; gap:9px; border-color:var(--line); border-radius:11px; background:#f7f9fc; }
  .settings-dialog .template-piece { min-height:44px; border-color:#d5dde8; border-radius:8px; padding:10px 11px; font-size:12px; line-height:1.65; color:var(--ink); }
  .settings-dialog .template-token { min-height:35px; padding:8px 10px; border-color:#cfdaea; background:#e9f0f9; color:#38567a; border-radius:7px; font-size:11px; }
  .settings-dialog .adjustment-details { border-color:var(--line); padding-top:7px; }
  .settings-dialog .adjustment-details > summary { min-height:40px; padding:11px 0; font-size:12px; }
  .settings-dialog .adjustment-item { border-color:var(--line); font-size:11px; }
  .settings-dialog .settings-storage { margin-top:20px; }
  .settings-dialog .mode-label { color:var(--green); background:var(--pale); border-color:#d8e2ef; border-radius:8px; padding:7px 10px; font-size:11px; }
  .settings-dialog .settings-storage > p { font-size:12px; line-height:1.75; }
  .settings-dialog .settings-storage > .hint { font-size:11px; border-color:var(--line); padding-top:18px; }
  .settings-dialog .storage-actions { gap:26px; margin:22px 0; padding-top:22px; border-color:var(--line); }
  .settings-dialog .storage-actions h4 { font-size:13px; }
  .settings-dialog .storage-actions p { font-size:11px; }
  .settings-dialog .button-row { gap:8px; }
  .settings-dialog .button-row .btn { padding:10px 12px; font-size:12px; }

  /* The same native dialog and picker model retain their apply/cancel behavior. */
  .date-dialog { width:490px; max-width:calc(100vw - 32px); max-height:calc(100dvh - 32px); background:#fff; }
  .date-dialog-inner { padding:25px 28px 24px; }
  .date-dialog .dialog-heading { margin-bottom:10px; gap:15px; }
  .date-dialog .dialog-heading h2 { font-size:23px; line-height:1.3; letter-spacing:-.65px; }
  .date-dialog .dialog-heading .eyebrow { font-size:9px; margin-bottom:7px; }
  .date-dialog-help { max-width:none; font-size:12px; line-height:1.65; color:var(--muted); margin-bottom:18px; }
  .date-dialog .leave-date-picker { --ldp-accent:var(--green); --ldp-pale:#eef3fa; --ldp-ink:var(--ink); --ldp-muted:var(--muted); }
  .date-dialog .ldp-instruction { font-size:12px; line-height:1.55; margin-bottom:12px; min-height:0; }
  .date-dialog .ldp-header { grid-template-columns:44px minmax(0,1fr) 44px; margin-bottom:8px; gap:10px; }
  .date-dialog .ldp-nav-slot { width:44px; height:44px; }
  .date-dialog .ldp-nav { width:44px; height:44px; border-color:var(--line); border-radius:11px; color:var(--ink); background:#fff; }
  .date-dialog .ldp-nav:hover:not(:disabled) { background:var(--pale); border-color:#b9c9de; }
  .date-dialog .ldp-month { min-height:44px; font-size:16px; font-weight:650; letter-spacing:-.3px; }
  .date-dialog .ldp-jump { border-color:var(--line); background:#f4f7fb; }
  .date-dialog .ldp-jump input { height:44px; border-color:#d5dde8; }
  .date-dialog .ldp-jump-apply { min-height:44px; }
  .date-dialog .ldp-calendar { border-spacing:4px; }
  .date-dialog .ldp-calendar th { height:30px; font-size:11px; color:var(--muted); }
  .date-dialog .ldp-day, .date-dialog .ldp-calendar td { height:44px; min-height:44px; }
  .date-dialog .ldp-day { font-size:13px; border-radius:10px; color:var(--ink); }
  .date-dialog .ldp-day.outside { color:#9aa5b4; }
  .date-dialog .ldp-day.weekend:not(.selected):not(.pending-start) { color:#7d899a; }
  .date-dialog .ldp-day:hover:not(:disabled) { background:#edf2f8; border-color:#c4d2e5; }
  .date-dialog .ldp-day.in-range { background:#edf2f9; color:var(--green); }
  .date-dialog .ldp-day.in-range.tentative { background:#eaf0f8; border-color:#c3d2e6; }
  .date-dialog .leave-date-picker:not(.is-range-only) .ldp-day.in-range:not(.selected):not(.tentative):not(.pending-start) { color:#748297; background:#f1f4f8; text-decoration:line-through; text-decoration-thickness:1px; }
  .date-dialog .is-range-only .ldp-day.in-range:not(.selected):not(.pending-start) { color:var(--green); background:#edf2f9; text-decoration:none; }
  .date-dialog .ldp-day.range-start.in-range:not(.selected), .date-dialog .ldp-day.range-end.in-range:not(.selected) { border-color:#b9c9dd; }
  .date-dialog .ldp-day.selected, .date-dialog .ldp-day.pending-start { color:#fff; background:var(--green); border-color:var(--green); font-weight:650; }
  .date-dialog .ldp-day.selected:hover { color:#fff; background:var(--green-dark); border-color:var(--green-dark); }
  .date-dialog .ldp-day.pending-start { outline:2px solid #a6bbd6; outline-offset:1px; }
  .date-dialog .ldp-day:focus-visible, .date-dialog .ldp-nav:focus-visible, .date-dialog .ldp-month:focus-visible, .date-dialog .ldp-text-button:focus-visible, .date-dialog .ldp-jump-apply:focus-visible { outline:3px solid #93acce; outline-offset:2px; }
  .date-dialog .ldp-toolbar { margin:3px 0 8px; padding:0 4px; gap:16px; }
  .date-dialog .ldp-text-button { min-height:40px; padding:8px 0; font-size:12px; }
  .date-dialog .ldp-text-button:disabled { color:#93a0b1; }
  .date-dialog .ldp-summary { padding:12px 14px; background:#f2f5fa; border-color:#dde6f1; border-radius:11px; font-size:12px; }
  .date-dialog .ldp-note { color:var(--muted); font-size:11px; margin:10px 3px 0; }
  .date-dialog .selection-actions { margin:13px 0 0; gap:7px; }
  .date-dialog .chip-button { min-height:40px; padding:8px 11px; border-radius:9px; border-color:var(--line); background:#fff; color:var(--green); font-size:11px; }
  .date-dialog .chip-button:hover:not(:disabled) { background:var(--pale); border-color:#bdcde0; }
  .date-dialog .manual-dates { margin:14px 0 0; padding-top:5px; border-color:var(--line); }
  .date-dialog .manual-dates > summary { min-height:44px; padding:12px 0; font-size:12px; line-height:1.6; color:var(--muted); }
  .date-dialog .manual-dates[open] > summary { margin-bottom:6px; }
  .date-dialog .dialog-actions { margin-top:15px; padding-top:18px; border-color:var(--line); gap:12px; }
  .date-dialog .dialog-actions .primary { min-width:170px; }

  /* Only the preview frame changes; .paper and its descendants are untouched. */
  .preview-dialog { width:800px; max-width:calc(100vw - 40px); max-height:calc(100dvh - 36px); border-radius:20px; background:#f5f7fa; }
  .preview-dialog-inner { padding:24px; }
  .preview-dialog-header { gap:18px; margin-bottom:21px; }
  .preview-dialog-header h2 { font-size:23px; font-weight:650; letter-spacing:-.6px; }
  .preview-dialog-header p { font-size:12px; color:var(--muted); }
  .preview-dialog-tools { gap:14px; }
  .preview-dialog .icon-button { width:44px; min-width:44px; height:44px; }
  .preview-dialog .paper-stage { border-color:#dfe5ee; background:#eaf0f6; border-radius:13px; padding:18px; }
  .preview-dialog .preview-foot { margin-top:18px; font-size:12px; line-height:1.65; color:var(--muted); }
  .preview-dialog .preview-foot .btn { min-height:44px; }
}

@media screen and (min-width:760px) {
  .date-dialog:has(.leave-date-picker.is-range) { width:820px; }
}

@media screen and (max-width:850px) {
  .settings-dialog .settings-layout { grid-template-columns:1fr; }
  .settings-dialog .settings-left { grid-template-columns:1fr 1fr; gap:18px; }
  .settings-dialog-header { gap:18px; padding:23px; }
  .settings-dialog-header h2 { font-size:23px; }
  .settings-dialog-header .eyebrow { font-size:9px; }
  .settings-dialog-buttons .btn { padding:11px 13px; }
  .settings-dialog-feedback { padding:0 23px; }
  .settings-dialog-body { padding:21px 23px 24px; }
  .settings-dialog .card { padding:21px; }
}

@media screen and (max-width:620px) {
  dialog { max-width:calc(100vw - 20px); max-height:calc(100dvh - 24px); border-radius:18px; }
  .dialog-inner { padding:21px; }
  .dialog-heading { gap:12px; }
  .dialog-heading h2 { font-size:21px; }
  dialog .field input, dialog .field input[type=date], dialog select, dialog .action-input { font-size:16px; }
  dialog .dialog-actions { gap:9px; }
  .settings-dialog { max-width:calc(100vw - 20px); max-height:calc(100dvh - 24px); border-radius:18px; }
  .settings-dialog-inner { max-height:calc(100dvh - 26px); }
  .settings-dialog-header { padding:20px; gap:15px; }
  .settings-dialog-header > div:first-child { padding-right:34px; }
  .settings-dialog-header h2 { font-size:21px; margin-bottom:7px; }
  .settings-dialog-header .eyebrow { font-size:9px; line-height:1.5; }
  .settings-dialog-header p:not(.eyebrow) { font-size:11px; line-height:1.6; }
  .settings-dialog-buttons { gap:10px; width:100%; }
  .settings-dialog-buttons .btn { width:100%; min-height:44px; font-size:13px; }
  .settings-dialog-buttons .icon-button { right:14px; top:16px; }
  .settings-dialog-feedback { padding:0 17px; }
  .settings-dialog-body { padding:17px; scrollbar-gutter:auto; }
  .settings-dialog .settings-layout { gap:16px; }
  .settings-dialog .settings-left { grid-template-columns:1fr; gap:16px; }
  .settings-dialog .card { padding:19px; border-radius:14px; }
  .settings-dialog .settings-storage { margin-top:16px; }
  .settings-dialog .storage-actions { grid-template-columns:1fr; gap:22px; }
  .settings-dialog .template-piece { font-size:16px; padding:9px 10px; }
  .settings-dialog .template-flow { padding:10px; gap:8px; }
  .settings-dialog .template-token { font-size:10px; }
  .settings-dialog .button-row .btn { font-size:12px; }
  .date-dialog { max-width:calc(100vw - 20px); max-height:calc(100dvh - 24px); }
  .date-dialog-inner { padding:22px 20px 20px; }
  .date-dialog .dialog-heading h2 { font-size:21px; }
  .date-dialog .dialog-heading .eyebrow { font-size:9px; }
  .date-dialog .ldp-calendar { border-spacing:3px; }
  .date-dialog .ldp-month { font-size:15px; }
  .date-dialog .ldp-day { font-size:13px; }
  .date-dialog .dialog-actions { gap:10px; }
  .date-dialog .dialog-actions .primary { min-width:150px; }
  .date-dialog .dialog-actions .btn { padding:11px 14px; }
  .preview-dialog { max-width:calc(100vw - 18px); max-height:calc(100dvh - 24px); border-radius:18px; }
  .preview-dialog-inner { padding:16px; }
  .preview-dialog-header { gap:12px; margin-bottom:17px; align-items:flex-start; }
  .preview-dialog-header h2 { font-size:19px; }
  .preview-dialog-header p { font-size:11px; }
  .preview-dialog-tools { gap:8px; }
  .preview-dialog-tools .text-btn { font-size:11px; }
  .preview-dialog .paper-stage { padding:10px; border-radius:10px; }
  .preview-dialog .preview-foot { font-size:11px; gap:12px; align-items:flex-start; }
  .preview-dialog .preview-foot .btn { font-size:12px; }
}

@media screen and (max-width:380px) {
  .settings-dialog-header { padding:18px; }
  .settings-dialog-body { padding:13px; }
  .settings-dialog .card { padding:17px; }
  .settings-dialog .two-fields { gap:9px; }
  .settings-dialog .two-fields .field label { font-size:11px; }
  .date-dialog-inner { padding:19px 15px 18px; }
  .date-dialog .dialog-heading h2 { font-size:20px; }
  .date-dialog .ldp-calendar { border-spacing:2px; }
  .date-dialog .ldp-day { border-radius:9px; }
  .date-dialog .chip-button { font-size:10px; padding:8px 9px; }
  .date-dialog .dialog-actions .primary { min-width:140px; }
  .preview-dialog-header { flex-wrap:wrap; }
  .preview-dialog-tools { margin-left:auto; }
  .preview-dialog .preview-foot { flex-wrap:wrap; }
}

@media screen and (max-height:750px) {
  .date-dialog-inner { padding-top:18px; padding-bottom:18px; }
  .date-dialog-help { margin-bottom:12px; }
  .date-dialog .ldp-instruction { margin-bottom:8px; }
  .date-dialog .ldp-header { margin-bottom:4px; }
  .date-dialog .ldp-calendar th { height:26px; }
  .date-dialog .ldp-summary { padding:10px 12px; }
  .date-dialog .dialog-actions { margin-top:12px; padding-top:14px; }
}

@media screen {
 .online-app .top-inner { max-width:1100px; }
 .online-header-actions { display:flex; align-items:center; gap:15px; }
 .online-edition { color:var(--muted); font-size:11px; }
 .online-header-actions .btn { min-height:44px; font-size:12px; border-color:var(--line); border-radius:10px; background:#fff; color:var(--green); }
 .online-header-actions .btn:hover { background:var(--pale); }
 .online-app .shell { padding-top:32px; }
 .online-app .quick-wrap { display:grid; max-width:1010px; grid-template-columns:minmax(0,1fr) minmax(286px,320px); gap:20px 24px; align-items:start; }
 .online-app .quick-heading { grid-column:1/-1; margin-bottom:0; }
 .online-request-flow { grid-column:1; grid-row:2; min-width:0; }
 .online-profile-fields { padding:23px 26px 22px; background:#fbfcfe; border-bottom:1px solid var(--line); }
 .online-section-heading { display:flex; align-items:center; justify-content:space-between; gap:14px; margin:0 0 19px; }
 .online-section-heading h2 { margin:0; font-size:14px; font-weight:650; letter-spacing:-.25px; }
 .online-profile-fields .field { margin:0 0 15px; }
 .online-profile-fields .two-fields .field { margin:0; }
 .online-profile-fields .two-fields { grid-template-columns:.9fr 1.1fr; gap:14px; }
 .online-profile-fields .input-prefix { border:1px solid #d7e0eb; border-radius:9px; background:#fff; }
 .online-profile-fields .input-prefix > span { border-color:var(--line); align-self:stretch; display:flex; align-items:center; background:#f1f4f8; min-width:44px; justify-content:center; color:#687a92; }
 .online-app .online-profile-fields .input-prefix input { border:0; border-radius:0; }
 .online-profile-fields .input-prefix:focus-within { outline:2px solid #9bb8df; }
 .online-profile-fields .input-prefix input:focus { outline:none; }
 .online-profile-fields input::placeholder { color:#7b8899; font-size:12px; }
 .online-app .request-fields { padding-top:21px; padding-bottom:22px; }
 .online-app .mode-switch { margin-bottom:20px; }
 .online-app .date-picker-trigger { min-height:80px; }
 .online-app .request-options { margin-bottom:17px; }
 .online-app .online-generator-actions { grid-template-columns:1.35fr 1fr; }
 .online-app .online-generator-actions .btn.primary > svg:first-child { margin:0; }
 .online-preview-button { display:flex; align-items:center; justify-content:center; gap:8px; min-height:42px; width:100%; margin:10px auto -6px; font-size:11px; color:var(--muted); }
 .online-preview-button svg { width:16px; height:16px; }
 .online-preview-button:hover { color:var(--green); }
 .online-form-footer { padding:9px 26px; display:flex; align-items:center; justify-content:space-between; gap:14px; min-height:55px; border-top:1px solid var(--line); background:#fbfcfe; }
 .online-form-footer p { display:flex; gap:7px; align-items:center; margin:0; font-size:11px; color:var(--muted); line-height:1.6; }
 .online-form-footer svg { width:13px; height:13px; }
 .online-form-footer .text-btn { font-size:10px; min-height:36px; flex:none; }
 .online-reset-actions { display:flex; align-items:center; gap:13px; flex:none; }
 .online-reset-actions .text-btn { display:inline-flex; align-items:center; justify-content:center; gap:5px; }
 .online-reset-actions #resetForm { color:var(--muted); font-weight:450; }
 .online-reset-actions #resetForm:hover { color:var(--ink); }
 .online-result { margin-top:18px; padding:23px 25px 18px; border:1px solid #cfddea; border-radius:15px; background:#f6f9fd; }
 .online-result-heading { display:flex; align-items:flex-start; gap:12px; }
 .online-result-icon { display:grid; place-items:center; flex:none; width:34px; height:34px; border-radius:50%; background:#e4eee7; color:#427259; }
 .online-result-icon svg { width:18px; height:18px; }
 .online-result-heading h2 { margin:0 0 8px; font-size:16px; font-weight:650; letter-spacing:-.3px; }
 .online-result-heading p { margin:3px 0; font-size:12px; line-height:1.6; color:var(--ink); }
 .online-result-heading #resultDate { color:var(--muted); font-size:10px; }
 .online-result-format { flex:none; margin-left:auto; padding:5px 7px; border:1px solid #d4dfeb; border-radius:6px; font-size:9px; letter-spacing:.6px; color:var(--muted); background:#fff; }
 .online-result-actions { display:grid; grid-template-columns:1.22fr 1fr .86fr; gap:9px; margin-top:18px; }
 .online-result-actions .btn { min-height:44px; font-size:11px; padding:10px; border-radius:9px; }
 .online-result-actions .btn svg { width:16px; height:16px; }
 .online-result-filename { overflow-wrap:anywhere; margin:12px 0 0; color:#7b8797; font-size:9px; line-height:1.6; }
 .online-calendar-count { margin:14px 0 0; padding:15px 16px; background:#f4f7fb; border:1px solid #dfe7f0; border-radius:11px; }
 .online-calendar-count .field { margin:0; }
 .online-calendar-count .label-row { gap:8px; flex-wrap:wrap; margin-bottom:10px; }
 .online-calendar-count .label-row label { font-size:12px; }
 .online-calendar-count .label-row span { color:var(--muted); font-size:10px; }
 .online-calendar-count input { max-width:235px; min-height:44px; font-size:14px; }
 .online-calendar-count .hint { font-size:11px; }
 .online-app input[aria-invalid="true"], .online-app button[aria-invalid="true"] { border-color:var(--red); }
 .complete-download { grid-column:2; grid-row:2; display:grid; gap:14px; padding:19px; border:1px solid #cbd9e9; border-radius:14px; background:#edf3fb; }
 .complete-download h2 { margin:0 0 5px; font-size:17px; font-weight:680; letter-spacing:-.3px; }
 .complete-download p { margin:0; color:#495e78; font-size:13px; line-height:1.45; }
 .download-complete-link.btn { min-height:56px; width:100%; padding:11px 12px; gap:8px; border-radius:10px; font-size:14px; font-weight:680; text-align:center; box-shadow:0 2px 5px #304e7226; }
 .download-complete-link svg { width:19px; height:19px; }
 .online-help-link { display:inline-flex; align-items:center; justify-self:start; gap:7px; min-height:40px; padding:3px 0; margin:-5px 0 -8px; font-size:13px; }
 .online-help-link svg { width:17px; height:17px; }
 .online-app .footer { margin-top:15px; }
 .online-templates-dialog.settings-dialog { width:850px; }
 .online-templates-dialog .settings-dialog-body { padding:23px; }
 .online-templates-dialog .templates-card { padding:22px; }
 .online-app .preview-dialog .preview-foot #previewStatus { white-space:normal; }
 .online-preview-actions { display:flex; align-items:center; gap:8px; flex:none; }
 .online-preview-actions .btn { font-size:11px; padding:10px 12px; gap:6px; }
 .online-preview-actions .text-btn { min-height:44px; padding:10px 8px; font-size:11px; }
 .online-preview-actions svg { width:16px; height:16px; }
}
@media screen and (max-width:760px) {
 .online-app .quick-wrap { display:flex; flex-direction:column; gap:16px; max-width:600px; }
 .online-app .quick-heading, .online-request-flow, .complete-download { width:100%; }
 .complete-download { grid-template-columns:minmax(0,1fr) auto; gap:10px; padding:14px; }
 .complete-download > div { grid-column:1; grid-row:1; }
 .complete-download h2 { font-size:15px; }
 .complete-download p { font-size:12px; }
 .download-complete-link { grid-column:1/-1; grid-row:2; }
 .online-help-link { grid-column:2; grid-row:1; align-self:center; min-height:44px; margin:0; }
}
@media screen and (max-width:620px) {
 body.online-app { padding-bottom:0; }
 .online-app .shell { padding:22px 16px 12px; }
 .online-app .top-inner { padding:12px 18px; min-height:66px; }
 .online-header-actions { gap:0; }
 .online-edition { display:none; }
 .online-header-actions .btn { font-size:11px; padding:9px 11px; }
 .online-header-actions .btn svg { width:15px; height:15px; }
 .online-app .quick-heading { margin-bottom:0; }
 .online-app .quick-heading h1 { font-size:26px; }
 .online-app .quick-subtitle { font-size:12px; }
 .online-profile-fields { padding:19px 18px; }
 .online-section-heading { margin-bottom:16px; gap:9px; }
 .online-section-heading h2 { font-size:13px; }
 .online-profile-fields .two-fields { grid-template-columns:1fr; gap:14px; }
 .online-app .field input, .online-app .field input[type=date] { font-size:16px; }
 .online-profile-fields input::placeholder { font-size:12px; }
 .online-app .request-fields { padding:19px 18px 20px; }
 .online-app .online-generator-actions { grid-template-columns:1.2fr 1fr; gap:9px; }
 .online-preview-button { font-size:11px; margin-top:7px; }
 .online-form-footer { padding:9px 18px; gap:6px 12px; flex-wrap:wrap; }
 .online-form-footer .text-btn { font-size:10px; }
 .online-reset-actions { width:100%; justify-content:space-between; }
 .online-result { padding:19px 17px 16px; margin-top:15px; border-radius:12px; }
 .online-result-heading { gap:10px; }
 .online-result-heading h2 { font-size:15px; }
 .online-result-heading p { font-size:11px; }
 .online-result-icon { width:30px; height:30px; }
 .online-result-format { font-size:8px; padding:5px; }
 .online-result-actions { grid-template-columns:1fr 1fr; margin-top:16px; }
 .online-result-actions #resultDownload { grid-column:1/-1; }
 .online-result-actions .btn { min-height:44px; font-size:11px; }
 .online-result-filename { font-size:8px; }
 .online-calendar-count { padding:13px; }
 .online-calendar-count input { max-width:none; font-size:16px; }
 .online-calendar-count .hint { font-size:10px; }
 .online-app .preview-dialog .preview-foot { flex-direction:column; align-items:stretch; }
 .online-preview-actions { display:grid; grid-template-columns:1fr 1fr; gap:8px; width:100%; }
 .online-preview-actions .text-btn { grid-column:1/-1; min-height:38px; }
 .online-app .footer { font-size:9px; margin-top:10px; }
 .online-templates-dialog.settings-dialog { max-width:calc(100vw - 20px); }
 .online-templates-dialog .settings-dialog-body { padding:15px; }
 .online-templates-dialog .templates-card { padding:17px; }
 .online-app .toast { bottom:20px; }
}
@media screen and (max-width:360px) {
 .online-app .shell { padding-left:12px; padding-right:12px; }
 .online-app .top-inner { padding-left:14px; padding-right:14px; }
 .online-app .brand { gap:9px; }
 .online-app .brand strong { font-size:15px; }
 .online-profile-fields { padding-left:16px; padding-right:16px; }
 .online-section-heading { align-items:flex-start; flex-direction:column; gap:5px; }
}

/* The quick-print sheet shares the PDF's exact A4 coordinates and embedded font. */
#leave-print-document { display:none; }
#leave-print-document text { stroke:none; font-kerning:none; font-variant-ligatures:none; letter-spacing:0; white-space:pre; }
@media print {
  @page { size:A4 portrait; margin:0; }
  body:not(.printing-request) #previewDialog { box-sizing:border-box!important; padding:25mm 22mm!important; }
  html:has(body.printing-request), body.printing-request {
    margin:0!important; padding:0!important; border:0!important; width:210mm!important;
    height:297mm!important; min-height:0!important; max-height:none!important;
    background:#fff!important; overflow:hidden!important; print-color-adjust:exact; -webkit-print-color-adjust:exact;
  }
  body.printing-request > *, body.printing-request #previewDialog { display:none!important; }
  body.printing-request dialog::backdrop { display:none!important; }
  body.printing-request > #leave-print-document {
    display:block!important; position:static!important; box-sizing:border-box!important;
    width:210mm!important; height:297mm!important; max-width:none!important; max-height:none!important;
    padding:0!important; margin:0!important; border:0!important; background:#fff!important;
    overflow:hidden!important; break-inside:avoid; break-after:avoid; line-height:0;
  }
  #leave-print-document > svg { display:block; width:210mm; height:297mm; margin:0; padding:0; }
}
