.menu-toggle,.menu-close,.nav-backdrop{display:none}

@media(max-width:900px){
    body{overflow-x:hidden}
    .menu-toggle{display:flex;position:fixed;z-index:30;top:calc(12px + env(safe-area-inset-top));left:14px;align-items:center;gap:9px;padding:10px 14px;background:#0a2842;color:#fff;border:1px solid #ffffff2e;box-shadow:0 8px 24px #071a2b35}
    .menu-toggle span:first-child{font-size:21px;line-height:1}
    .menu-close{display:block;position:absolute;top:12px;right:14px;padding:4px 10px;background:transparent;color:#fff;font-size:30px;font-weight:400}
    .nav-backdrop{display:block;position:fixed;z-index:38;inset:0;width:100%;height:100%;padding:0;border:0;border-radius:0;background:#071a2b99;opacity:0;visibility:hidden;transition:opacity .2s ease,visibility .2s ease}
    aside#sidebar{display:flex;position:fixed;z-index:40;inset:0 auto 0 0;width:min(82vw,310px);height:100dvh;padding:28px 20px;transform:translateX(-105%);transition:transform .22s ease;box-shadow:18px 0 45px #071a2b45;overflow-y:auto}
    aside#sidebar .brand-logo{width:150px;height:82px;margin-inline:auto}
    aside#sidebar nav{display:block;width:100%;margin:22px 0;flex:1}
    aside#sidebar nav a{display:block;width:100%;margin:3px 0;padding:12px;border-radius:8px}
    aside#sidebar form{width:100%}
    aside#sidebar .link{width:100%;text-align:left}
    body.nav-open{overflow:hidden}
    body.nav-open aside#sidebar{transform:translateX(0)}
    body.nav-open .nav-backdrop{opacity:1;visibility:visible}
    .shell{margin-left:0;padding:calc(88px + env(safe-area-inset-top)) 18px calc(24px + env(safe-area-inset-bottom));max-width:none}
}

@media(max-width:700px){
    .shell{padding-left:12px;padding-right:12px}
    header{margin-bottom:18px}
    header h1{font-size:27px;line-height:1.15;overflow-wrap:anywhere}
    header p{margin-bottom:0}
    .card{padding:18px}
    .split{gap:16px}

    .table{padding:12px;overflow:visible}
    .table table,.table tbody,.table tr,.table td{display:block;width:100%}
    .table thead{display:none}
    .table tbody{display:grid;gap:12px}
    .table tbody tr{padding:6px 12px;border:1px solid #dce5ef;border-radius:12px;background:#fff;box-shadow:0 4px 16px #16304d0a}
    .table tbody td{display:grid;grid-template-columns:minmax(88px,36%) minmax(0,1fr);gap:10px;padding:10px 0;border-bottom:1px solid #e8eef5;white-space:normal;overflow-wrap:anywhere}
    .table tbody td:last-child{border-bottom:0}
    .table tbody td::before{content:attr(data-label);color:#65768a;font-size:10px;font-weight:800;letter-spacing:.06em;text-transform:uppercase}
    .table tbody td[colspan]{display:block;text-align:center;padding:16px 4px}
    .table tbody td[colspan]::before{content:none}
    .table tbody td small,.table tbody td code{max-width:100%;overflow-wrap:anywhere;word-break:break-word}
    .table tbody td .button,.table tbody td button{max-width:100%;white-space:normal;text-align:center}
    .table tbody td.job-actions{display:grid;grid-template-columns:minmax(88px,36%) minmax(0,1fr);align-items:start}
    .table tbody td.job-actions::before{grid-column:1;grid-row:1/-1}
    .table tbody td.job-actions>*{grid-column:2;width:100%;margin:0}
    .table tbody td.job-actions .inline{display:block}
    .table tbody td.job-actions .inline button{width:100%}
    .delete-action>div{position:static;width:100%;margin-top:7px;box-shadow:none}
}

@media(max-width:420px){
    .menu-toggle{left:10px}
    .shell{padding-left:9px;padding-right:9px}
    .card{padding:15px}
    .table{padding:9px}
    .table tbody td{grid-template-columns:minmax(78px,34%) minmax(0,1fr);gap:8px}
    .table tbody td.job-actions{grid-template-columns:minmax(78px,34%) minmax(0,1fr)}
}

@media(min-width:901px){
    .menu-toggle,.menu-close,.nav-backdrop{display:none!important}
}
