.cr-admin .cr-admin-title,.cr-actions{display:flex;align-items:center;gap:.7rem;flex-wrap:wrap}
.cr-admin .cr-admin-title{justify-content:space-between;margin-bottom:.85rem}
.cr-admin h2{margin:0}
.cr-admin .cr-occupancy{margin:.75rem 0 0;color:#655542;font-size:.88rem}
.cr-admin [data-cr-admin-error]:not(:empty){margin:.7rem 0;color:#53361a}
.cr-timer{margin:0;padding:.35rem .8rem;background:#efe9d8;border-radius:20px;font-weight:700;font-variant-numeric:tabular-nums;width:fit-content}
.cr-banner{margin:0 0 .75rem}
.cr-dialog [hidden],.cr-admin [hidden]{display:none!important}

.cr-dialog{
    --cr-ink:#382713;
    --cr-teal:#096d71;
    --cr-line:#e4ddcf;
    width:min(850px,calc(100% - 2rem));
    max-width:none;
    max-height:calc(100vh - 2rem);
    max-height:min(900px,calc(100dvh - 2rem));
    margin:auto;
    padding:0;
    overflow:hidden;
    border:1px solid #d9cfbb;
    border-radius:18px;
    background:#fff;
    color:var(--cr-ink);
    box-shadow:0 24px 90px #201a1640;
    font:inherit;
    text-align:start;
}
.cr-dialog[open]{display:flex;flex-direction:column}
.cr-dialog::backdrop{background:#241e18a6}
body:has(.cr-dialog[open]){overflow:hidden}
.cr-top,.cr-foot{flex:none}
.cr-top{padding:1.1rem 1.4rem .95rem;border-bottom:1px solid var(--cr-line)}
.cr-heading,.cr-heading-copy small,.cr-clock-label,.cr-cell-head,.cr-cell-info{display:flex;align-items:center}
.cr-heading{justify-content:space-between;gap:1rem;margin:0 0 .83rem}
.cr-heading-copy small{gap:.35rem;color:#6f6049;font-size:.76rem;font-weight:700;line-height:1.45}
.cr-heading-copy small .icon{width:.88rem;height:.88rem}
.cr-heading h2{margin:.1rem 0 0;color:var(--cr-ink);font-size:clamp(1.45rem,2.8vw,1.95rem);line-height:1.35;letter-spacing:normal}
.cr-heading h2:focus{outline:0}
.cr-heading .close-btn{flex:none;width:42px;height:42px;display:grid;place-items:center}
.cr-clock-panel{
    --cr-clock-color:#866714;
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:center;
    gap:.4rem .75rem;
    padding:.48rem .85rem .65rem;
    border-radius:10px;
    background:#f8f4e8;
    color:#574314;
}
.cr-clock-panel.is-ending{--cr-clock-color:#a04b20;background:#fcf0e9;color:#82401e}
.cr-clock-label{gap:.42rem;font-size:.82rem;font-weight:700}
.cr-clock-label .icon{width:1rem;height:1rem}
.cr-clock-value{font-size:1.07rem;line-height:1.3;font-variant-numeric:tabular-nums}
.cr-clock-track,.cr-capacity-track{display:block;overflow:hidden;background:#e9e5db;border-radius:8px}
.cr-clock-track{grid-column:1 / -1;height:4px;background:#e5dabc}
.cr-clock-track i,.cr-capacity-track i{display:block;height:100%;border-radius:inherit}
.cr-clock-track i{width:var(--cr-time,100%);background:var(--cr-clock-color)}
.cr-body{min-height:0;overflow:auto;overscroll-behavior:contain;padding:1rem 1.4rem;background:#faf8f3}
.cr-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:.55rem}
.cr-cell{
    display:flex;
    position:relative;
    min-width:0;
    flex-direction:column;
    gap:.33rem;
    padding:.63rem .72rem;
    border:1px solid var(--cr-line);
    border-radius:10px;
    background:white;
    color:var(--cr-ink);
    line-height:1.4;
    cursor:pointer;
}
.cr-cell-head{justify-content:space-between;align-items:flex-start;gap:.3rem;flex:1}
.cr-cell-head strong{font-size:.86rem;line-height:1.45;overflow-wrap:anywhere}
.cr-mark{flex:none;display:grid;place-items:center;width:15px;height:15px;margin-top:.14rem;border:1px solid #a59a85;border-radius:50%}
.cr-mark .icon{width:10px;height:10px;stroke-width:3;visibility:hidden}
.cr-cell-info{justify-content:space-between;gap:.3rem;color:#685e4e;font-size:.71rem}
.cr-cell-info bdi{font-weight:700;color:#504739;white-space:nowrap;font-variant-numeric:tabular-nums}
.cr-capacity-track{height:3px}
.cr-capacity-track i{width:var(--cr-occupancy,0%);background:#6e8e83}
.cr-cell.is-full{background:#f2efea}
.cr-cell.is-full .cr-cell-state{color:#815b3d;font-weight:700}
.cr-cell.is-full .cr-capacity-track i{background:#ac9580}
.cr-cell.is-chosen{border-color:var(--cr-teal);background:#f0f8f6;box-shadow:inset 0 0 0 1px var(--cr-teal)}
.cr-cell.is-chosen .cr-mark{background:var(--cr-teal);border-color:var(--cr-teal);color:white}
.cr-cell.is-chosen .cr-mark .icon{visibility:visible}
.cr-cell.is-chosen .cr-capacity-track i{background:var(--cr-teal)}
.cr-cell:has(input:disabled){cursor:default}
.cr-cell:has(input:focus-visible){outline:3px solid #008696;outline-offset:1px}
@media(hover:hover){.cr-cell:has(input:enabled):hover{border-color:var(--cr-teal)}}
.cr-foot{padding:.85rem 1.4rem 1.1rem;border-top:1px solid var(--cr-line);background:white}
.cr-foot form{display:flex;align-items:flex-end;gap:.75rem;margin:0}
.cr-foot .field{flex:1;min-width:0;margin:0}
.cr-foot .field>span{display:block;font-size:.79rem;margin:0 0 .22rem;color:#594f3f;font-weight:700}
.cr-foot .field select{width:100%;min-width:0;min-height:44px;height:44px;padding-block:0}
.cr-foot form .btn{display:inline-flex;align-items:center;justify-content:center;gap:.4rem;min-height:44px;min-width:112px;height:44px;margin:0}
.cr-foot form .icon{width:1rem;height:1rem}
.cr-result{font-size:.87rem;color:#834825;line-height:1.6}
.cr-result:not(:empty){padding:.52rem .72rem;border-inline-start:3px solid #b78952;background:#fcf5ea;border-radius:5px}
.cr-result:not(:empty):has(+form:not([hidden])){margin-bottom:.55rem}
.cr-result.is-confirmed{color:#125f55;background:#edf7f3;border-inline-start-color:var(--cr-teal)}
@media(max-width:720px){.cr-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:540px){
    .cr-dialog{width:calc(100% - 1rem);max-height:calc(100vh - 1rem);max-height:calc(100dvh - 1rem);border-radius:14px}
    .cr-top{padding:.72rem .85rem .65rem}
    .cr-heading{margin-bottom:.52rem}
    .cr-body{padding:.65rem .85rem}
    .cr-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:.42rem}
    .cr-cell{padding:.46rem .54rem;gap:.23rem}
    .cr-cell-head strong{font-size:.81rem}
    .cr-foot{padding:.62rem .85rem max(.75rem,env(safe-area-inset-bottom))}
    .cr-foot form{gap:.5rem}
    .cr-foot form .btn{min-width:78px;padding-inline:.7rem}
}
@media(max-height:540px){
    .cr-top{padding-block:.45rem}
    .cr-heading{margin-bottom:.2rem}
    .cr-heading-copy small{display:none}
    .cr-heading h2{font-size:1.25rem}
    .cr-clock-panel{padding:.25rem .65rem;gap:.16rem .5rem}
    .cr-foot{padding-block:.45rem}
}
