/* The owner's wide layout (pwa.laptop), the laptop's design (docs/design/laptop/approved.html) fitted to every width
   from 600 px, and only once the shell has set data-layout="laptop" on <body>, which it does for the owner alone.
   Nothing here reaches a phone, a driver or a window under 600 px, so every phone screen is drawn exactly as without it.

     600–1023   the menu opens over the screen from a button in the bar; tiles two across, the price card under them;
                tables keep Slip, Date, Company, Litres and Status; One delivery fills the window.
     1024–1279  the menu down the left, narrower; tiles three across; tables drop Location and Fuel; the panel narrower.
     1280+      as approved.
     1600+      the content no wider than 1360 px, centred in the room beside the menu.

   Sizes are fluid: tiles, the panel and its fields size from the room they have, and nothing is cut off with "…": a long
   name wraps. Table columns drop by the window's width in one fixed order (`pwa.delivery_table:DROP_ORDER`), each cell
   carrying its rank in data-drop; the widths here are COLUMN_BREAKS', and change with them. */

@media (min-width: 600px) {
  body[data-layout="laptop"] { --side: 208px; --pad: 32px; display: grid; grid-template-columns: var(--side) minmax(0, 1fr);
    grid-template-rows: 56px auto; align-items: start; min-height: 100vh; }

  /* The bar: the menu button below 1024 px, the back arrow whenever there is a screen to go back to, the wordmark; who
     is signed in at the right. No gear. */
  body[data-layout="laptop"] > header.bar { grid-column: 1 / -1; grid-row: 1; width: 100%; max-width: none; height: 56px;
    margin: 0; padding: 0 var(--pad); gap: 12px; background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none;
    box-shadow: inset 0 -1px 0 var(--line); }
  body[data-layout="laptop"] .bar .slot, body[data-layout="laptop"] .bar .gear { display: none; }
  body[data-layout="laptop"] .bar .brand { flex: none; text-align: left; }
  body[data-layout="laptop"] .bar .brand-row { justify-content: flex-start; }
  body[data-layout="laptop"] .menu-open { display: none; flex: none; align-items: center; justify-content: center; width: 44px; height: 44px;
    margin-left: -12px; padding: 0; border: 0; border-radius: var(--r-full); background: none; color: var(--fg); cursor: pointer; }
  body[data-layout="laptop"] .whoami { display: flex; align-items: center; gap: 10px; margin-left: auto; color: var(--fg2);
    font: 400 13px/1 Archivo, sans-serif; white-space: nowrap; }
  body[data-layout="laptop"] .whoami b { margin-left: -6px; color: var(--fg); font-weight: 700; }
  body[data-layout="laptop"] .whoami .avatar { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%;
    background: var(--raised); box-shadow: inset 0 0 0 1px var(--line2); color: var(--fg); font: 700 12px/1 Archivo, sans-serif; }

  /* The menu: its rows, the screen in front marked; Sign out and the build line at its foot. */
  body[data-layout="laptop"] .side { grid-column: 1; grid-row: 2; position: sticky; top: 56px; display: flex; flex-direction: column;
    height: calc(100vh - 56px); padding: 16px 12px; overflow-y: auto; background: var(--bg); box-shadow: inset -1px 0 0 var(--line); }
  body[data-layout="laptop"] .side-shade, body[data-layout="laptop"] .side-close { display: none; }
  body[data-layout="laptop"] .side .rows { display: flex; flex-direction: column; gap: 2px; }
  body[data-layout="laptop"] .side .row-item { padding: 10px 12px; border: 0; border-radius: 10px; background: none; color: var(--fg2);
    font: 400 15px/20px Archivo, sans-serif; text-align: left; cursor: pointer; }
  body[data-layout="laptop"] .side .row-item:hover { color: var(--fg); }
  body[data-layout="laptop"] .side .row-item[aria-current="page"] { background: var(--raised); color: var(--fg); font-weight: 700;
    box-shadow: inset 0 0 0 1px var(--line2); }
  body[data-layout="laptop"] .side .foot { display: flex; flex-direction: column; gap: 12px; margin-top: auto; padding: 14px 4px 0;
    box-shadow: inset 0 1px 0 var(--line); }
  body[data-layout="laptop"] .side [data-part="status"] { margin: 0; font-size: 12px; }
  body[data-layout="laptop"] .side [data-part="status"]:empty { display: none; }
  body[data-layout="laptop"] .side .signout { align-self: flex-start; padding: 0; border: 0; background: none; color: var(--bad);
    font: 400 13px/18px Archivo, sans-serif; cursor: pointer; }
  body[data-layout="laptop"] .side .signout:disabled { opacity: .5; cursor: default; }
  body[data-layout="laptop"] .side [data-part="build"] { margin: 0; font-size: 11px; line-height: 15px; }

  /* The room beside the menu. A screen with no wide layout keeps its phone column, and its footer bar under it. */
  body[data-layout="laptop"] #shell { grid-column: 2; grid-row: 2; width: 100%; max-width: none; min-width: 0; margin: 0;
    padding: 24px var(--pad) 40px; }
  body[data-layout="laptop"] #shell > :not(style):not(.is-laptop):not(.slide-over) { width: 100%; max-width: 412px; }
  body[data-layout="laptop"] .footbar { left: calc(var(--side) + var(--pad)); max-width: 412px; transform: none; }
  body[data-layout="laptop"] h1 { font-size: 32px; }

  /* Overview: three tiles that never move, then the chart the width of the room. */
  .overview.is-laptop { --gap: 16px; }
  .overview.is-laptop .top .sub { margin-top: 6px; font-size: 14px; line-height: 20px; }
  .overview.is-laptop [data-part="refresh"] { height: 40px; }
  .overview.is-laptop .tiles { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.25fr); gap: 16px; }
  .overview.is-laptop .tile { position: relative; display: flex; flex-direction: column; align-items: stretch; min-width: 0; min-height: 150px;
    padding: 18px 20px 18px 24px; border: 0; border-radius: var(--r-md); background: var(--raised); box-shadow: inset 0 0 0 1px var(--line);
    color: var(--fg); font: inherit; text-align: left; cursor: pointer; }
  .overview.is-laptop .tile:disabled { cursor: default; }
  .overview.is-laptop .tile::before { content: ""; position: absolute; left: 0; top: 18px; bottom: 18px; width: 3px; border-radius: 3px;
    background: var(--line2); }
  .overview.is-laptop .tile.ready:not(.none)::before { background: var(--warn); }
  .overview.is-laptop .tile.blocking:not(.none)::before { background: var(--bad); }
  .overview.is-laptop .tile-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
  .overview.is-laptop .tile .lab { margin: 0; }
  .overview.is-laptop .tile .open { flex: none; color: var(--fg2); font: 400 13px/1 Archivo, sans-serif; }
  .overview.is-laptop .tile .count { display: block; margin: 14px 0 6px; font: 800 34px/1 Archivo, sans-serif; letter-spacing: -.03em;
    font-variant-numeric: tabular-nums; }
  .overview.is-laptop .tile.ready .count { color: var(--warn); }
  .overview.is-laptop .tile.blocking .count { color: var(--bad); }
  .overview.is-laptop .tile.none .count { color: var(--fg2); }
  .overview.is-laptop .tile > small { display: block; color: var(--fg2); font: 400 13px/18px Archivo, sans-serif; }
  .overview.is-laptop .price-head .view { flex: none; }
  .overview.is-laptop .chart { padding: 20px 22px; }
  .overview.is-laptop .chart-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 12px 16px; }
  .overview.is-laptop .chart-head .headline b { font-size: 28px; }
  .overview.is-laptop .chart-head .chart-note { margin: 6px 0 0; }
  .overview.is-laptop .controls { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
  .overview.is-laptop .filter { position: relative; flex: 1 1 200px; max-width: 240px; }
  .overview.is-laptop .filter .field { height: 36px; padding: 0 12px; border-radius: 10px; background: var(--bg2); font-size: 13px; }
  .overview.is-laptop .filter .hits { position: absolute; top: 42px; left: 0; right: 0; z-index: 3; margin: 0; padding: 8px;
    border-radius: 12px; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line2), 0 18px 40px -16px rgba(0,0,0,.8); }
  .overview.is-laptop .filter .picked { min-height: 36px; padding: 0 6px 0 12px; border-radius: 10px; }
  .overview.is-laptop .filter .picked b { font-size: 13px; }
  .overview.is-laptop .controls .seg { margin: 0; padding: 3px; border-radius: 10px; }
  .overview.is-laptop .controls .seg button { flex: none; height: 30px; padding: 0 12px; border-radius: 8px; font-size: 13px; }
  .overview.is-laptop .bars { gap: clamp(4px, 1.2vw, 14px); height: 240px; margin-top: 22px; padding: 0 6px; }
  .overview.is-laptop .col { border-radius: 5px; }
  .overview.is-laptop .axis { gap: clamp(4px, 1.2vw, 14px); margin-top: 8px; padding: 0 6px; }
  .overview.is-laptop .key { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 12px; }

  /* Deliveries: Mine and My team, Confirmed and With the driver on one line over the table, wrapping when narrow. */
  .deliveries.is-laptop { display: grid; grid-template-columns: max-content minmax(0, 1fr); grid-auto-flow: row dense;
    align-items: center; gap: 14px 12px; }
  .deliveries.is-laptop > * { grid-column: 1 / -1; min-width: 0; }
  .deliveries.is-laptop > .tabs { grid-column: 1; width: auto; }
  .deliveries.is-laptop > .states { grid-column: 2; flex-wrap: wrap; justify-self: start; }
  .deliveries.is-laptop .tabs button { flex: none; padding: 0 14px; white-space: nowrap; }
  .deliveries.is-laptop .top [data-part="who"] { width: auto; gap: 6px; padding: 0 14px; font-size: 14px; }
  .deliveries.is-laptop [data-part="refresh"] { height: 44px; }
  .deliveries.is-laptop [data-part="owner-camera"] { justify-self: start; width: auto; padding: 0 22px; }
  .deliveries.is-laptop > .ledger { padding: 6px 10px; border-radius: var(--r-md); background: var(--raised);
    box-shadow: inset 0 0 0 1px var(--line); }
  .deliveries.is-laptop > [data-part="ledger-more"] { justify-self: start; width: auto; padding: 0 22px; }
  /* Whose deliveries, under the Filter button rather than up from the foot. */
  .deliveries.is-laptop .card-sheet { justify-content: flex-start; align-items: flex-end; padding: 128px var(--pad) 0 0; background: transparent; }
  .deliveries.is-laptop .card-sheet .panel { width: min(360px, 100%); max-height: 60vh; margin: 0; border-radius: var(--r-md);
    box-shadow: inset 0 0 0 1px var(--line2), 0 24px 60px -20px rgba(0,0,0,.9); }

  /* The table, the same on Deliveries and on a company's page: a row a delivery, a long name wrapping, never cut. */
  .ledger-table { width: 100%; border-collapse: collapse; font: 400 13.5px/18px Archivo, sans-serif; font-variant-numeric: tabular-nums; }
  .ledger-table th { padding: 10px 9px; border-bottom: 1px solid var(--line); color: var(--fg2); text-align: left; white-space: nowrap;
    font: 700 10.5px/1 Archivo, sans-serif; letter-spacing: .1em; text-transform: uppercase; }
  .ledger-table td { padding: 12px 9px; border-bottom: 1px solid var(--line); vertical-align: top; overflow-wrap: break-word; }
  .ledger-table .slip, .ledger-table .date, .ledger-table .num, .ledger-table .invoice, .ledger-table .fuel { white-space: nowrap; }
  .ledger-table tbody tr:last-child td { border-bottom: 0; }
  .ledger-table .num { text-align: right; }
  .ledger-table .slip, .ledger-table .slip button { font-weight: 700; }
  .ledger-table .slip button { padding: 0; border: 0; background: none; color: inherit; font: inherit; font-weight: 700; cursor: inherit; }
  .ledger-table .invoice { color: var(--fg2); }
  .ledger-table .status { font-size: 12.5px; font-weight: 700; }
  .ledger-table .status.ok { color: var(--ok); }
  .ledger-table .status.warn { color: var(--warn); }
  .ledger-table .status.bad { color: var(--bad); }
  .ledger-table .pip { display: inline-block; width: 7px; height: 7px; margin-right: 6px; border-radius: 50%; background: currentColor;
    vertical-align: 1px; }
  .ledger-table tr.opens { cursor: pointer; }
  .ledger-table tr.opens:hover td { background: rgba(255,255,255,.025); }
  .ledger-table tr[aria-current="true"] td { background: rgba(63,224,168,.07); }
  .ledger-table tr[aria-current="true"] td:first-child { box-shadow: inset 3px 0 0 var(--accent); }

  /* One delivery, slid in over the table from the right: its photo small beside Re-take and Download, the six fields
     in view, the longer lines under them, Save the changes in its own band at the foot. Its width follows the window. */
  .slide-over { position: fixed; top: 56px; right: 0; bottom: 0; z-index: 6; display: flex; flex-direction: column;
    width: clamp(380px, 37vw, 470px); background: var(--bg2); box-shadow: -1px 0 0 var(--line2), -30px 0 60px -20px rgba(0,0,0,.7);
    animation: slide-in .22s var(--ease); }
  .still .slide-over { animation: none; }
  .slide-over > .close { position: absolute; top: 22px; right: 24px; z-index: 2; display: grid; place-items: center; width: 32px; height: 32px;
    padding: 0; border: 0; border-radius: 10px; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line); color: var(--fg2);
    font: 400 15px/1 Archivo, sans-serif; cursor: pointer; }
  .slide-over .slide-body { display: flex; flex-direction: column; flex: 1; min-height: 0; padding: 22px 24px 18px; overflow-y: auto; }
  /* Save the changes in a band of its own at the pane's foot, outside what scrolls: what scrolls ends above it, so the
     last line of the pane scrolls into view above Save and nothing ever sits behind it. */
  .slide-over:has([data-part="save"]:not([hidden])) .slide-body { margin-bottom: 82px; box-shadow: inset 0 -1px 0 var(--line); }
  .slide-over .delivery-one { flex: none; gap: 14px; }
  .slide-over .delivery-one > * { flex-shrink: 0; }
  .slide-over .delivery-one h1 { padding-right: 44px; font-size: 24px; line-height: 28px; }
  .slide-over .delivery-one .sub { margin-top: -8px; font-size: 13px; line-height: 18px; }
  .slide-over .delivery-one .slip { display: grid; grid-template-columns: 150px minmax(0, 1fr); align-items: start; gap: 8px 14px;
    padding: 0; background: none; box-shadow: none; }
  .slide-over .delivery-one .slip > * { grid-column: 2; }
  .slide-over .delivery-one .slip .picture { grid-column: 1; grid-row: 1 / span 4; width: 150px; min-height: 0; }
  .slide-over .delivery-one .slip img { width: 150px; height: 110px; max-height: none; object-fit: cover; object-position: top; }
  .slide-over .delivery-one .slip [data-part="retake-button"] { order: 1; }
  .slide-over .delivery-one .slip [data-part="download"] { order: 2; }
  .slide-over .delivery-one .slip [data-part="retake-note"] { order: 3; font-size: 12px; line-height: 16px; }
  .slide-over .delivery-one .slip [data-part="download-status"] { order: 4; }
  /* A button's words wrap in a narrow pane rather than run out of it. */
  .slide-over .delivery-one .slip .btn { height: auto; min-height: 36px; padding: 8px 12px; border-radius: 10px; font-size: 13px;
    line-height: 17px; text-align: center; }
  /* The six fields three abreast, or two in a narrow pane, each at least wide enough for its date. */
  .slide-over .figures-form { display: grid; grid-template-columns: repeat(auto-fill, minmax(max(128px, calc((100% - 24px) / 3)), 1fr));
    gap: 10px 12px; }
  .slide-over .figures-form > * { grid-column: 1 / -1; }
  .slide-over .figures-form > .pair { display: contents; }
  .slide-over .figures-form > .pair > label { grid-column: auto; min-width: 0; }
  .slide-over .figures-form .chosen { padding: 12px 14px; }
  .slide-over .figures-form .lab { margin-bottom: 6px; }
  .slide-over .delivery-one .field { height: 40px; padding: 0 12px; border-radius: 10px; font-size: 14px; }
  .slide-over .delivery-one .plain { grid-template-columns: repeat(auto-fill, minmax(max(120px, calc((100% - 24px) / 3)), 1fr)); }
  .slide-over .delivery-one .plain .wide { grid-column: 1 / -1; }
  .slide-over .delivery-one .spacer { display: none; }
  .slide-over .delivery-one [data-part="save"] { position: absolute; left: 24px; right: 24px; bottom: 18px; width: auto; height: 46px;
    margin: 0; }

  /* A company: one column, its details, then the last 90 days with who delivered beside them, then its deliveries. */
  .customers.is-laptop { gap: 16px; }
  .customers.is-laptop .company-top { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
  .customers.is-laptop .company-top .sub { margin-top: 6px; font-size: 14px; line-height: 20px; }
  .customers.is-laptop .company-top .btn { width: auto; height: 40px; padding: 0 16px; font-size: 14px; }
  .customers.is-laptop [data-part="page"] { gap: 16px; }
  /* The status line keeps its room in the gaps either side, as Overview's does. */
  #shell .customers.is-laptop > p.note[role="status"] { margin: -10px 0; }
  .customers.is-laptop .box { padding: 18px 20px; }
  .customers.is-laptop .box .top { flex-wrap: wrap; }
  .customers.is-laptop .box .top .actions { display: flex; flex-wrap: wrap; gap: 8px; }
  .customers.is-laptop .box .btn { height: 34px; padding: 0 12px; font-size: 13px; }
  /* Each fact as wide as it is, but the invoice formula's note and the address, which wrap in what is left. Narrower, the facts
     wrap onto as many rows as they need. */
  .customers.is-laptop .facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px 20px; margin: 14px 0 0; }
  .customers.is-laptop .facts > div { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
  .customers.is-laptop .facts dt { font: 700 11px/1 Archivo, sans-serif; letter-spacing: .1em; text-transform: uppercase; }
  .customers.is-laptop .facts dd { font: 700 14px/20px Archivo, sans-serif; overflow-wrap: break-word; }
  .customers.is-laptop .facts .note { margin: 0; font-size: 12px; line-height: 16px; }
  .customers.is-laptop .details form { display: grid; grid-template-columns: repeat(auto-fill, minmax(max(200px, calc((100% - 32px) / 3)), 1fr));
    gap: 12px 16px; }
  .customers.is-laptop .details form .btn { grid-column: 1 / -1; justify-self: start; height: 40px; padding: 0 18px; font-size: 14px; }
  /* Change formula: the picker the form's whole width, as on Add a company. */
  .customers.is-laptop .details form > .formula { grid-column: 1 / -1; }
  .customers.is-laptop .days { display: grid; grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: 16px 0; }
  .customers.is-laptop .days .stats { grid-template-columns: repeat(3, minmax(0, 120px)); gap: 16px; }
  .customers.is-laptop .days .stats .waiting .n { color: var(--warn); }
  .customers.is-laptop .days .who { padding-left: 24px; box-shadow: inset 1px 0 0 var(--line); }
  .customers.is-laptop .tags { flex-direction: row; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
  .customers.is-laptop .tags li { display: inline-flex; align-items: baseline; gap: 8px; padding: 8px 12px; border-radius: 10px;
    background: var(--bg2); box-shadow: inset 0 0 0 1px var(--line); color: var(--fg2); font: 400 13px/18px Archivo, sans-serif; }
  .customers.is-laptop .tags b { color: var(--fg); font-size: 14px; }
  .customers.is-laptop .box .table { margin-top: 6px; }
  .customers.is-laptop .box .more { width: auto; padding: 0 18px; }
}

/* The owner's list screens, as docs/design/laptop/lists-approved.html draws them: a heading with its actions at the right,
   and a table, or cards, under it. */
@media (min-width: 600px) {
  .is-laptop .list-top { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 16px; }
  .is-laptop .list-top h1 { margin: 0; }
  .is-laptop .list-top .sub { margin-top: 6px; font-size: 14px; line-height: 20px; }
  .is-laptop .list-top .actions { display: flex; flex-wrap: wrap; gap: 10px; }
  .is-laptop .list-top .btn { flex: none; width: auto; height: 42px; padding: 0 18px; font-size: 15px; }
  .is-laptop .table-card { min-width: 0; padding: 6px 10px; border-radius: var(--r-md); background: var(--raised);
    box-shadow: inset 0 0 0 1px var(--line); }
  .is-laptop .table-card .counts { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 12px; padding: 12px 9px 4px;
    color: var(--fg2); font: 400 13px/18px Archivo, sans-serif; }
  .ledger-table .go-cell { width: 24px; color: var(--fg2); font-size: 18px; text-align: right; }
  .ledger-table .photo { width: 64px; }
  .ledger-table td.photo .thumb, .ledger-table td.photo img.thumb { display: flex; align-items: center; justify-content: center; width: 52px;
    height: 38px; padding: 0; border: 0; border-radius: 6px; background: var(--bg2); overflow: hidden; object-fit: cover; object-position: top;
    cursor: pointer; }
  .ledger-table td.photo .thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
  .ledger-table td { vertical-align: middle; }

  /* Waiting for you: the tick and the photo, then the slip's cells; a refused slip's reasons on a line under it. */
  .waiting.is-laptop { gap: 16px; }
  .waiting.is-laptop [data-part="status"] { margin: -6px 0; color: var(--fg2); font: 400 13px/18px Archivo, sans-serif; min-height: 18px; }
  .waiting.is-laptop [data-part="status"].bad { color: var(--bad); }
  .waiting.is-laptop .tick-cell { width: 36px; }
  /* The phone's rows are .slip buttons; its rules reach the table's Slip column, so it is set back here. */
  .waiting.is-laptop .ledger-table td.slip { padding: 12px 9px; border-bottom: 1px solid var(--line); font-weight: 700; }
  .waiting.is-laptop .ledger-table tbody tr:last-child td.slip,
  .waiting.is-laptop .ledger-table tr:has(+ tr.why-row) td.slip { border-bottom: 0; }
  .waiting.is-laptop .ledger-table th.slip { padding: 10px 9px; font: 700 10.5px/1 Archivo, sans-serif; letter-spacing: .1em; color: var(--fg2); }
  .waiting.is-laptop .tick { width: 32px; height: 32px; }
  .waiting.is-laptop .tick i { width: 20px; height: 20px; border-radius: 6px; }
  .waiting.is-laptop .thumb.bang { color: var(--bad); font: 800 18px/1 Archivo, sans-serif; cursor: default; }
  .waiting.is-laptop .ledger-table tr.why-row td { padding-top: 0; border-top: 0; }
  .waiting.is-laptop .why-row .why { display: block; color: var(--bad); font: 400 13px/18px Archivo, sans-serif; }
  /* A company's heading row: its tick, its name and how many slips, over the slips that go on its one invoice. */
  .waiting.is-laptop .ledger-table tr.company-row td { padding: 12px 9px; border-bottom: 1px solid var(--line2);
    background: color-mix(in srgb, var(--tomorrow) 14%, var(--bg2)); }
  .waiting.is-laptop tr.company-row td.company b { margin-right: 10px; font: 700 15px/20px Archivo, sans-serif; }
  .waiting.is-laptop tr.company-row td.company span { color: var(--fg2); font: 400 13px/18px Archivo, sans-serif; }
  .waiting.is-laptop .why-row .why.changed { color: var(--warn); }
  .waiting.is-laptop tr:has(+ tr.why-row) td { border-bottom: 0; }

  /* Blocking: one table, each reason a heading row with its count; the fix in the accent at the end of every row. */
  .blocking.is-laptop { gap: 16px; }
  .blocking.is-laptop .reason th { padding: 18px 9px 10px; text-align: left; border-bottom: 1px solid var(--line); }
  .blocking.is-laptop .reason .lab { display: inline; margin: 0; }
  .blocking.is-laptop .reason .badge { display: inline-grid; place-items: center; min-width: 20px; height: 20px; margin-left: 10px; padding: 0 6px;
    border-radius: var(--r-full); background: color-mix(in srgb, var(--warn) 18%, transparent); color: var(--warn);
    font: 700 11px/1 Archivo, sans-serif; }
  .blocking.is-laptop .reason.stopped .badge { background: color-mix(in srgb, var(--bad) 18%, transparent); color: var(--bad); }
  .blocking.is-laptop .reason [data-part="retry-all"] { float: right; width: auto; height: 32px; margin-top: -6px; padding: 0 12px; font-size: 13px; }
  .blocking.is-laptop td.what { font-weight: 700; }
  .blocking.is-laptop td.detail { color: var(--fg2); }
  .blocking.is-laptop .stopped-at { color: var(--bad); font-weight: 700; }
  .blocking.is-laptop td.fix { text-align: right; white-space: nowrap; }
  .blocking.is-laptop td.fix .remove { margin-right: 16px; padding: 0; border: 0; background: none; color: var(--fg2);
    font: 400 13px/18px Archivo, sans-serif; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
  .blocking.is-laptop .fix-link { padding: 0; border: 0; background: none; color: var(--accent); font: 700 13px/18px Archivo, sans-serif; cursor: pointer; }
  .blocking.is-laptop .more-row td { border-bottom: 0; }
  .blocking.is-laptop .more-row .btn { width: auto; height: 36px; padding: 0 16px; font-size: 13px; }

  /* Drivers: a card a driver, as many across as fit. */
  .drivers.is-laptop { gap: 16px; }
  .drivers.is-laptop .cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
  .drivers.is-laptop .driver { height: 100%; padding: 18px 20px; }

  /* Customers: the companies nothing is invoiced to in an amber band, then one table. */
  .customers.is-laptop > [data-part="find"] { max-width: 360px; height: 44px; font-size: 14px; }
  .customers.is-laptop .band:empty { display: none; }
  .customers.is-laptop .band { padding: 14px 18px; border-radius: var(--r-md); background: color-mix(in srgb, var(--warn) 7%, var(--bg));
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 40%, transparent); }
  .customers.is-laptop .band-title { display: block; color: var(--warn); font: 700 14px/20px Archivo, sans-serif; }
  .customers.is-laptop .band ul { gap: 2px; margin-top: 4px; }
  .customers.is-laptop .band-row { padding: 2px 0; border: 0; background: none; color: var(--fg); font: 400 14px/20px Archivo, sans-serif;
    text-align: left; cursor: pointer; }
  .customers.is-laptop .companies-table td.name { font-weight: 700; }
  .customers.is-laptop .companies-table tr.bad td.formula, .customers.is-laptop .companies-table tr.bad td.remark { color: var(--warn); font-weight: 700; }

  /* Prices: today and tomorrow as two highlighted cards, then a row an earlier day. */
  .prices.is-laptop { gap: 16px; }
  .prices.is-laptop .top { align-items: flex-end; justify-content: space-between; }
  .prices.is-laptop .top h1 { flex-grow: 0; margin: 0; }
  .prices.is-laptop [data-part="checked"] { margin-top: 6px; }
  .prices.is-laptop .cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .prices.is-laptop .day-card { display: flex; flex-direction: column; gap: 12px; min-width: 0; padding: 20px 22px; border-radius: var(--r-md);
    background: var(--raised); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 40%, var(--line)), 0 0 40px -18px rgba(63,224,168,.35);
    scroll-margin-top: 84px; }
  .prices.is-laptop .day-card .date, .prices.is-laptop .day-row .date { display: flex; align-items: baseline; gap: 10px;
    font: 700 17px/22px Archivo, sans-serif; }
  .prices.is-laptop .when { font: 700 12px/16px Archivo, sans-serif; letter-spacing: .08em; color: var(--fg2); }
  .prices.is-laptop .when.today, .prices.is-laptop .when { color: var(--accent); }
  .prices.is-laptop .day-card .lab { margin: 4px 0 0; }
  /* Tomorrow's card in its own colour, as approved: its ring, its word, what we charge and the supplier's figure that wins. */
  .prices.is-laptop .day-card.tomorrow { box-shadow: inset 0 0 0 1.5px var(--tomorrow); }
  .prices.is-laptop .day-card.tomorrow .when, .prices.is-laptop .day-card.tomorrow .charged .big,
  .prices.is-laptop .day-card.tomorrow .said-table .won .figure { color: var(--tomorrow); }
  .prices.is-laptop .charge { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px 20px; }
  .prices.is-laptop .charged .named { display: flex; align-items: baseline; gap: 6px; color: var(--fg2); font: 400 14px/20px Archivo, sans-serif; }
  .prices.is-laptop .charged .big { color: var(--accent); font: 800 34px/38px Archivo, sans-serif; letter-spacing: -.02em; }
  .prices.is-laptop .charged .big .unit { display: block; color: var(--fg2); font: 400 12px/16px Archivo, sans-serif; letter-spacing: 0; }
  .prices.is-laptop .charged .from, .prices.is-laptop .charged .none { color: var(--fg2); font: 400 13px/18px Archivo, sans-serif; }
  .prices.is-laptop .charged .pending { font: 400 12px/16px Archivo, sans-serif; color: var(--accent); }
  .prices.is-laptop .charged .pending.bad { color: var(--bad); }
  .prices.is-laptop .edited { font: 700 11px/14px Archivo, sans-serif; letter-spacing: .06em; color: var(--accent);
    border: 1px solid var(--accent); border-radius: var(--r-full); padding: 1px 7px; margin-left: 6px; }
  .prices.is-laptop .said-table { width: 100%; border-collapse: collapse; font: 400 14px/18px Archivo, sans-serif; }
  .prices.is-laptop .said-table th { padding: 8px 9px; border-bottom: 1px solid var(--line); color: var(--fg2); text-align: left;
    font: 700 10.5px/1 Archivo, sans-serif; letter-spacing: .1em; text-transform: uppercase; }
  .prices.is-laptop .said-table th.fuel-name { padding: 12px 9px; color: var(--fg); font: 400 14px/18px Archivo, sans-serif; letter-spacing: 0;
    text-transform: none; }
  .prices.is-laptop .said-table td { padding: 10px 9px; border-bottom: 1px solid var(--line); vertical-align: top; }
  .prices.is-laptop .said-table .num { text-align: right; }
  .prices.is-laptop .said-table .figure { font-variant-numeric: tabular-nums; }
  .prices.is-laptop .said-table .won .figure { color: var(--accent); font-weight: 700; }
  .prices.is-laptop .said-table .quiet { color: var(--fg2); }
  .prices.is-laptop .said-table .product { color: var(--fg2); font: 400 11.5px/16px Archivo, sans-serif; letter-spacing: .02em;
    text-transform: uppercase; overflow-wrap: anywhere; }
  .prices.is-laptop .edits { padding-top: 0; }
  .prices.is-laptop .day-card .hold, .prices.is-laptop .day-row .hold { margin: 0; color: var(--warn); overflow-wrap: anywhere; }
  .prices.is-laptop .day-card .blocked, .prices.is-laptop .day-row .blocked { margin: 4px 0 0; color: var(--bad); }
  .prices.is-laptop .earlier { display: flex; flex-direction: column; gap: 10px; }
  .prices.is-laptop .earlier > .lab { margin: 6px 0 0; }
  .prices.is-laptop .rows { padding: 6px 10px; border-radius: var(--r-md); background: var(--raised); box-shadow: inset 0 0 0 1px var(--line); }
  /* The Edit column a set width, so the heads, which have no buttons, line up with the rows under them. */
  .prices.is-laptop .row-head, .prices.is-laptop .day-row { display: grid; grid-template-columns: minmax(150px, 200px) repeat(2, minmax(0, 1fr)) 120px;
    gap: 8px 20px; align-items: start; }
  .prices.is-laptop .row-head { padding: 10px 9px; border-bottom: 1px solid var(--line); }
  .prices.is-laptop .row-head .lab { margin: 0; }
  .prices.is-laptop .day-row { padding: 16px 9px; border-bottom: 1px solid var(--line); scroll-margin-top: 84px; }
  .prices.is-laptop .day-row:last-child { border-bottom: 0; }
  .prices.is-laptop .day-row .empty-cell { grid-column: 2 / 4; }
  .prices.is-laptop .day-row .fuel-name { display: none; }
  .prices.is-laptop .day-row .charged-line { font: 400 13px/18px Archivo, sans-serif; color: var(--fg2); }
  .prices.is-laptop .day-row .charged-line b { color: var(--fg); font: 800 20px/24px Archivo, sans-serif; margin-right: 4px; }
  .prices.is-laptop .said-rows { display: grid; grid-template-columns: max-content minmax(0, 1fr) max-content; gap: 4px 14px; margin-top: 8px;
    font: 400 13px/18px Archivo, sans-serif; }
  .prices.is-laptop .said-rows .supplier { color: var(--fg2); }
  .prices.is-laptop .said-rows .product { color: var(--fg2); font-size: 12px; letter-spacing: .02em; text-transform: uppercase; overflow-wrap: anywhere; }
  .prices.is-laptop .said-rows .figure { text-align: right; }
  .prices.is-laptop .said-rows .won { color: var(--accent); font-weight: 700; }
  .prices.is-laptop .said-rows .quiet { color: var(--fg2); }
  .prices.is-laptop .day-row .edits { flex-direction: column; align-items: stretch; }
  .prices.is-laptop .day-row .rule { grid-column: 1 / -1; }

  /* Deliveries, With the driver: the note in an amber band, then a table, Confirm on each row. */
  .deliveries.is-laptop [data-part="held-list"] { display: none; }
  .deliveries.is-laptop .held-by { display: flex; flex-direction: column; gap: 14px; }
  .deliveries.is-laptop [data-part="held-line"] { margin: 0; padding: 14px 18px; border-radius: var(--r-md); color: var(--fg);
    background: color-mix(in srgb, var(--warn) 7%, var(--bg)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 40%, transparent);
    font: 400 14px/20px Archivo, sans-serif; }
  .deliveries.is-laptop .held-table td.slip { font-weight: 700; }
  .deliveries.is-laptop .held-table td.why.warn { color: var(--warn); font-weight: 700; }
  .deliveries.is-laptop .held-table td.act { text-align: right; }
  .deliveries.is-laptop .held-table td.act .btn { width: auto; height: 34px; padding: 0 14px; font-size: 13px; }
}

/* The owner's forms and detail screens, as docs/design/laptop/forms-approved.html draws them, one pattern for every form:
   the form on the left, what it does on the right, its buttons at the bottom right of the form; fields in pairs where they
   belong together, a required one marked. */
@media (min-width: 600px) {
  .is-laptop.form-screen { gap: 16px; }
  .is-laptop .form-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
  .is-laptop .form-card, .is-laptop .side-card { min-width: 0; padding: 18px 20px; border-radius: var(--r-md); background: var(--raised);
    box-shadow: inset 0 0 0 1px var(--line); }
  .is-laptop .side-card h3 { margin: 0 0 8px; font: 700 14px/1.3 Archivo, sans-serif; }
  .is-laptop .side-card p { margin: 0 0 10px; color: var(--fg2); font: 400 13px/19px Archivo, sans-serif; }
  .is-laptop .side-card p:last-child { margin-bottom: 0; }
  .is-laptop .side-card b { color: var(--fg); }
  .is-laptop .fgrid, .is-laptop .pair { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; align-items: start; }
  .is-laptop .pair { gap: 16px; }
  .is-laptop .fgrid > .full { grid-column: 1 / -1; }
  .is-laptop .fgrid > label, .is-laptop .f { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
  .is-laptop .fgrid .lab, .is-laptop .f .lab { margin: 0; }
  .is-laptop .fgrid .field, .is-laptop .f .field { height: 42px; padding: 0 12px; font-size: 14px; border-radius: 10px; }
  .is-laptop .fgrid .note, .is-laptop .f .note { margin: 0; font-size: 12.5px; line-height: 17px; }
  /* A choice with its ▾ at the right, as drawn. */
  .is-laptop .fgrid select.field { padding-right: 34px; background: var(--raised) no-repeat right 14px center / 10px 6px
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M0 0h10L5 6z' fill='%238A9AA3'/%3E%3C/svg%3E"); }
  .is-laptop .req { margin-left: 6px; color: var(--warn); font-size: 11px; letter-spacing: .04em; }
  .is-laptop .prefixed { position: relative; display: flex; align-items: center; }
  .is-laptop .prefixed .prefix { position: absolute; left: 12px; color: var(--fg2); font: 400 14px/1 Archivo, sans-serif; pointer-events: none; }
  .is-laptop .prefixed .field { padding-left: 26px; }
  .is-laptop .unit-entry { display: flex; align-items: center; gap: 8px; }
  .is-laptop .unit-entry .field { flex: 1; min-width: 0; }
  .is-laptop .unit-entry .unit { flex: none; color: var(--fg2); font: 400 13px/1 Archivo, sans-serif; }
  .is-laptop .form-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 20px;
    padding-top: 16px; border-top: 1px solid var(--line); }
  .is-laptop .form-actions.bare { padding-top: 0; border-top: 0; }
  .is-laptop .form-actions .btn { flex: none; width: auto; height: 44px; padding: 0 22px; font-size: 15px; }
  .is-laptop .form-actions .btn.sec { height: 40px; padding: 0 16px; }
  #shell .is-laptop .form-actions p.note[role="status"] { flex: 1 1 220px; min-width: 0; margin: 0; }
  .is-laptop .btn.danger { background: var(--raised); color: var(--bad); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--bad) 45%, transparent); }
  .is-laptop .warn-box { margin: 10px 0 0; padding: 10px 12px; border-radius: 10px; background: color-mix(in srgb, var(--warn) 8%, transparent);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 28%, transparent); color: var(--fg); font: 400 12.5px/17px Archivo, sans-serif; }
  .is-laptop .side-card table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
  .is-laptop .side-card th { padding: 9px; border-bottom: 1px solid var(--line); color: var(--fg2); text-align: left;
    font: 700 10.5px/1 Archivo, sans-serif; letter-spacing: .1em; text-transform: uppercase; }
  .is-laptop .side-card td { padding: 9px; border-bottom: 1px solid var(--line); vertical-align: top; }
  .is-laptop .side-card .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
  .is-laptop .side-card .mu { color: var(--fg2); }

  /* Add a company: the phone's form is a column with a gap above it; here it is the card. */
  .customers.is-laptop form.form-card { display: block; margin-top: 0; }

  /* One driver: the last 14 days as three tiles, then Set a new password and Disable this driver side by side. */
  .drivers.is-laptop .tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 10px; }
  .drivers.is-laptop .tiles > div { padding: 14px 18px; border-radius: var(--r-md); background: var(--raised); box-shadow: inset 0 0 0 1px var(--line); }
  .drivers.is-laptop .tiles .n { margin-top: 10px; font: 800 26px/1 Archivo, sans-serif; font-variant-numeric: tabular-nums; }
  .drivers.is-laptop .tiles .of { margin-top: 4px; color: var(--fg2); font: 400 13px/18px Archivo, sans-serif; }
  .drivers.is-laptop .pair .form-card > .lab { margin-bottom: 14px; }
  .drivers.is-laptop .pair .form-card > .sub { font-size: 13.5px; line-height: 20px; }

  /* The screens' own rules come after this sheet; these beat them where the laptop lays a part out differently. */
  .drivers.is-laptop [data-part="actions"] { display: grid; }
  .drivers.is-laptop form.form-card { display: block; }
  .edit-rate.is-laptop [data-part="fuels"] { display: grid; }
  .edit-rate.is-laptop [data-part="won"] { display: table-row-group; }
  .discounts.is-laptop .lab, .products.is-laptop .lab { padding: 0; }

  /* Edit a rate: a card a fuel, two abreast, Save under them; what this changes on the right. */
  .edit-rate.is-laptop .pair > .form-card:only-child { grid-column: 1 / -1; }
  .edit-rate.is-laptop .form-card > .lab { margin-bottom: 12px; overflow-wrap: anywhere; }
  .edit-rate.is-laptop .form-card .note { margin: 8px 0 0; font-size: 12.5px; line-height: 17px; }
  .edit-rate.is-laptop .won-row td:first-child { overflow-wrap: anywhere; }

  /* Supplier discount and Products: the amount in force large, a new one under it; the history beside them. */
  .discounts.is-laptop .supplier + .supplier, .products.is-laptop .supplier + .supplier { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); }
  .discounts.is-laptop .supplier > .lab, .products.is-laptop .supplier > .lab { margin-bottom: 8px; }
  .discounts.is-laptop .amount, .products.is-laptop .amount { margin: 0 0 14px; font: 800 30px/1.1 Archivo, sans-serif; font-variant-numeric: tabular-nums; }
  .discounts.is-laptop .amount span, .products.is-laptop .amount span { margin-left: 4px; color: var(--fg2); font: 700 13px/18px Archivo, sans-serif; }
  .discounts.is-laptop .shared, .products.is-laptop .shared { margin: 12px 0 0; font-size: 12.5px; line-height: 17px; }
  .discounts.is-laptop .side-card .lab, .products.is-laptop .side-card .lab { margin: 14px 0 0; }
  .discounts.is-laptop .side-card td:first-child, .products.is-laptop .side-card td:first-child { white-space: nowrap; }
}

/* The slip cards on the owner's wide layout, as docs/design/laptop/cards-approved.html draws them: Upload a slip photo at
   Mine's top right, Yours to finish as a table, Confirm the slip and Confirm for a driver in the slide-in pane with their
   buttons in a band at its foot, and the upload, the crop and a duplicate slip in centred windows over everything. */
@media (min-width: 600px) {
  .deliveries.is-laptop .top [data-part="owner-camera"] { flex: none; width: auto; height: 44px; margin-left: auto; padding: 0 20px;
    font-size: 15px; }
  .deliveries.is-laptop .top [data-part="owner-take"] { display: none; }

  /* Yours to finish: its own table above the deliveries, headed with its count, what is left to do in amber. */
  .deliveries.is-laptop .finish { gap: 0; padding: 6px 10px; border-radius: var(--r-md); background: var(--raised);
    box-shadow: inset 0 0 0 1px var(--line); }
  .deliveries.is-laptop .finish h2 { padding: 12px 9px 4px; color: var(--fg2); }
  .deliveries.is-laptop [data-part="finish-list"] { display: none; }
  .deliveries.is-laptop .finish-table td.slip { font-weight: 700; }
  .deliveries.is-laptop .finish-table td.todo.warn { color: var(--warn); font-weight: 700; }
  .deliveries.is-laptop .finish-table tbody tr { cursor: pointer; }

  /* A slip to confirm in the pane: what scrolls in a part of its own, the buttons in a band at the pane's foot after
     it, so nothing ever sits behind them. */
  .slide-over .slide-body:has(> .in-pane:not([hidden])) { overflow: hidden; padding-bottom: 0; }
  /* Beats the card's and the takeover's own rules, which come after this sheet. */
  .slide-over .card.in-pane, .slide-over .takeover.in-pane { display: flex; flex-direction: column; flex: 1; min-height: 0; gap: 0;
    padding: 0; }
  .slide-over .in-pane .pane-scroll { display: flex; flex-direction: column; flex: 1; min-height: 0; gap: 14px; padding: 0 0 16px;
    overflow-x: hidden; overflow-y: auto; }
  .slide-over .in-pane .pane-scroll > * { flex-shrink: 0; }
  .slide-over .in-pane h1 { margin: 0; padding-right: 44px; font-size: 24px; line-height: 28px; }
  .slide-over .in-pane .sub { margin-top: -8px; font-size: 13px; line-height: 18px; }
  /* The card's heading and its line share a block of their own. */
  .slide-over .card.in-pane .sub { margin-top: 6px; }
  .slide-over .in-pane .photo { display: grid; grid-template-columns: 150px minmax(0, 1fr); align-items: start; gap: 14px; min-height: 0;
    padding: 0; background: none; box-shadow: none; }
  .slide-over .in-pane .photo img { width: 150px; height: 110px; max-width: none; max-height: none; object-fit: cover; object-position: top;
    border-radius: 8px; }
  .slide-over .in-pane .photo .title { display: none; }
  .slide-over .in-pane .photo .note { margin: 0; font-size: 12px; line-height: 16px; }
  .slide-over .card.in-pane .six { display: grid; grid-template-columns: repeat(auto-fill, minmax(max(128px, calc((100% - 24px) / 3)), 1fr));
    gap: 10px 12px; }
  .slide-over .card.in-pane .six > label { min-width: 0; }
  /* Under the six, DEF among them, as docs/design/laptop/formulas-approved.html draws it: the add-on fee the full width. */
  .slide-over .in-pane .xtra, .slide-over .figures-form > .xtra { display: block; margin-top: 4px; }
  .slide-over .in-pane .lab { margin-bottom: 6px; }
  .slide-over .in-pane .field { height: 40px; padding: 0 12px; border-radius: 10px; font-size: 14px; }
  .slide-over .in-pane .six .note { font-size: 12px; line-height: 16px; overflow-wrap: anywhere; }
  .slide-over .in-pane .company .btn { height: 36px; font-size: 14px; }
  /* Beats the rules that place a phone column's footer bar under it, at every width. */
  body[data-layout="laptop"] .slide-over .footbar { position: static; left: auto; z-index: auto; transform: none; width: auto;
    max-width: none; }
  .slide-over .pane-foot { flex: none; gap: 8px; padding: 16px 0 18px; background: var(--bg2); }
  .slide-over .pane-foot > .btn { width: 100%; height: 46px; }
  .slide-over .pane-foot .line { text-align: left; }
  .slide-over .pane-foot .foot-links { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 16px; }
  .slide-over .pane-foot .foot-links .line { flex: 1 1 200px; font-size: 12.5px; }
  .slide-over .pane-foot .quiet { align-self: auto; min-height: 30px; padding: 0; font-size: 13px; line-height: 18px; }
  .slide-over .pane-foot .quiet input { display: none; }
  .slide-over .pane-foot [data-part="remove"] { margin-left: auto; color: var(--bad); }
  /* Which company? inside the pane, rising from its foot, as the phone's rises from the screen's. */
  .slide-over .card-sheet { position: absolute; }
  .slide-over .card-sheet .panel { max-width: none; }

  /* A window over everything, centred: the upload, the crop and a duplicate slip. It fits the window it is in, and
     scrolls inside itself, never sideways, when the window is short. */
  .window-veil { position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; padding: 16px; background: rgba(4, 6, 8, .72); }
  .window { position: relative; width: min(620px, 100%); max-height: calc(100dvh - 32px); padding: 24px; overflow-x: hidden;
    overflow-y: auto; border-radius: 18px; background: var(--bg2); box-shadow: inset 0 0 0 1px var(--line2), 0 30px 80px -20px rgba(0, 0, 0, .8); }
  .window[data-part="crop-window"] { width: min(760px, 100%); }
  /* On the owner's wide layout, under the bar, whose back arrow closes it too. */
  body[data-layout="laptop"] .window-veil { top: 56px; }
  body[data-layout="laptop"] .window { max-height: calc(100dvh - 56px - 32px); }
  .window[data-part="duplicate-window"] { width: min(640px, 100%); }
  .window > .close { position: absolute; top: 22px; right: 22px; z-index: 2; display: grid; place-items: center; width: 32px; height: 32px;
    padding: 0; border: 0; border-radius: 10px; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line); color: var(--fg2);
    font: 400 15px/1 Archivo, sans-serif; cursor: pointer; }
  .window .window-body h1 { margin: 0; padding-right: 44px; font-size: 24px; line-height: 28px; }
  .window .window-body .sub, .window .camera > .note { margin: 6px 0 0; font-size: 13.5px; line-height: 19px; }
  .window .window-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; }
  .window .window-actions .btn { flex: none; width: auto; height: 44px; padding: 0 18px; font-size: 15px; }
  .window .camera.in-window { display: flex; flex-direction: column; gap: 14px; }
  .window .camera.in-window .frame { width: 100%; height: min(440px, calc(100dvh - 330px)); min-height: 200px; aspect-ratio: auto;
    border-radius: 12px; background: #000; box-shadow: none; }
  .window .camera.in-window .turns { display: flex; justify-content: center; gap: 10px; }
  .window .camera.in-window .turns[hidden] { display: none; }
  .window .camera.in-window .turns .btn { width: auto; height: 36px; gap: 6px; padding: 0 12px; font-size: 14px; }
  .window .camera.in-window .window-actions { justify-content: space-between; }
  .window .camera.in-window .track { margin: 0; }
  .window .crop.in-window { gap: 12px; }
  .window .crop.in-window .kept { margin: 0; }
  .window .crop.in-window .note.bad:empty { display: none; }
  .window .crop.in-window .resets { display: flex; flex-wrap: wrap; gap: 10px; margin-right: auto; }
  .window .crop.in-window .resets .btn { height: 40px; padding: 0 12px; font-size: 14px; }
  .window .conflict.in-window { display: flex; flex-direction: column; gap: 16px; }
  .window .conflict.in-window .photos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .window .conflict.in-window figure { display: flex; flex-direction: column; gap: 8px; margin: 0; min-width: 0; }
  .window .conflict.in-window .slot { display: flex; align-items: center; justify-content: center; height: 220px; overflow: hidden;
    border-radius: 10px; background: var(--raised); }
  .window .conflict.in-window .slot img { width: 100%; height: 100%; object-fit: cover; object-position: top; color: transparent; }
  .window .conflict.in-window figcaption { color: var(--fg2); font: 400 13px/18px Archivo, sans-serif; overflow-wrap: anywhere; }
  .window .conflict.in-window .none { color: var(--fg2); font: 400 13px/18px Archivo, sans-serif; }
}

/* 600–1023: what a form does under it, and paired fields one under the other. */
@media (min-width: 600px) and (max-width: 1023px) {
  .is-laptop .form-layout, .is-laptop .fgrid, .is-laptop .pair { grid-template-columns: minmax(0, 1fr); }
}

/* 600–1023: Prices' cards stack, and each earlier day's cells stack under its date. */
@media (min-width: 600px) and (max-width: 1023px) {
  .prices.is-laptop .cards { grid-template-columns: minmax(0, 1fr); }
  .prices.is-laptop .row-head { display: none; }
  .prices.is-laptop .day-row { grid-template-columns: minmax(0, 1fr); }
  .prices.is-laptop .day-row .empty-cell { grid-column: auto; }
  .prices.is-laptop .day-row .fuel-name { display: block; color: var(--fg2); font: 700 11px/1 Archivo, sans-serif; letter-spacing: .1em;
    text-transform: uppercase; margin-bottom: 6px; }
  .prices.is-laptop .day-row .edits { flex-direction: row; }
}

@media (min-width: 1280px) {
  /* As approved: the facts on one line, each as wide as it is, the invoice formula's note and the address wrapping. */
  .customers.is-laptop .facts { grid-template-columns: minmax(0, max-content) minmax(0, max-content) minmax(120px, .8fr)
    minmax(0, 1.2fr) minmax(0, max-content) minmax(0, max-content); }
  /* As approved (docs/design/laptop/tweaks-approved.html): Overview's name filter and its two switches on one row at
     the right, the four buttons one width; narrower, they wrap as before. */
  .overview.is-laptop .controls { flex-wrap: nowrap; justify-content: flex-end; }
  .overview.is-laptop .filter { flex: 0 1 300px; min-width: 200px; max-width: none; }
  .overview.is-laptop .controls .seg { flex: none; }
  .overview.is-laptop .controls .seg button { width: 118px; padding: 0; text-align: center; }
}

/* 1024–1279: the menu narrower, and the table without Location and Fuel. */
@media (min-width: 600px) and (max-width: 1279px) {
  body[data-layout="laptop"] { --side: 184px; --pad: 24px; }
  .ledger-table [data-drop="1"], .ledger-table [data-drop="2"] { display: none; }
}

/* 600–1023: no menu down the left; a button in the bar opens it over the screen. */
@media (min-width: 600px) and (max-width: 1023px) {
  body[data-layout="laptop"] { --side: 0px; --pad: 20px; grid-template-columns: minmax(0, 1fr); }
  body[data-layout="laptop"] .menu-open { display: flex; }
  body[data-layout="laptop"] #shell { grid-column: 1; }
  /* Opened under the bar, which stays above it with its back arrow, the way to close it. */
  body[data-layout="laptop"] .side { position: fixed; top: 56px; bottom: 0; left: 0; z-index: 12; width: min(300px, 85vw); height: auto;
    padding-top: 56px; transform: translateX(-100%); visibility: hidden; transition: transform .2s var(--ease), visibility .2s;
    box-shadow: inset -1px 0 0 var(--line2), 30px 0 60px -20px rgba(0,0,0,.8); }
  body[data-layout="laptop"][data-menu="open"] .side { transform: none; visibility: visible; }
  body[data-layout="laptop"] .side-close { position: absolute; top: 12px; right: 12px; display: grid; place-items: center; width: 32px; height: 32px;
    padding: 0; border: 0; border-radius: 10px; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line); color: var(--fg2);
    font: 400 15px/1 Archivo, sans-serif; cursor: pointer; }
  body[data-layout="laptop"][data-menu="open"] .side-shade { position: fixed; inset: 0; z-index: 11; display: block; border: 0;
    background: rgba(8,11,14,.74); cursor: pointer; }
  /* A screen with no wide layout: its phone column in the middle, its footer bar under it, as on a phone. */
  body[data-layout="laptop"] #shell > :not(style):not(.is-laptop):not(.slide-over) { margin-inline: auto; }
  body[data-layout="laptop"] .footbar { left: 50%; transform: translateX(-50%); }
  .overview.is-laptop .tiles { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .overview.is-laptop .tile.price { grid-column: 1 / -1; min-height: 0; }
  .ledger-table [data-drop] { display: none; }
  .customers.is-laptop .days { grid-template-columns: minmax(0, 1fr); }
  .customers.is-laptop .days .who { padding: 16px 0 0; box-shadow: inset 0 1px 0 var(--line); }
  /* One delivery over the whole window under the bar, closed by its ✕ or the bar's back arrow. */
  .slide-over { top: 56px; left: 0; z-index: 13; width: auto; animation: none; }
}

/* Under 768: who is signed in by the circle alone. */
@media (min-width: 600px) and (max-width: 767px) {
  body[data-layout="laptop"] .whoami .who-name, body[data-layout="laptop"] .whoami b { display: none; }
  body[data-layout="laptop"] .whoami { font-size: 0; gap: 0; }
}

/* 1600+: the content no wider than 1360 px, centred in the room beside the menu. */
@media (min-width: 1600px) {
  body[data-layout="laptop"] #shell { padding-inline: max(var(--pad), calc((100% - 1360px) / 2)); }
}

@keyframes slide-in { from { transform: translateX(100%); } to { transform: none; } }

/* The slip at its full size, opened from the pane; it stays over everything until closed. */
.fullsize { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 48px; background: rgba(3,5,7,.92); }
.fullsize img { max-width: 100%; max-height: 100%; border-radius: 12px; }
.fullsize .close { position: absolute; top: 20px; right: 24px; display: grid; place-items: center; width: 36px; height: 36px; padding: 0;
  border: 0; border-radius: 10px; background: var(--raised); box-shadow: inset 0 0 0 1px var(--line2); color: var(--fg);
  font: 400 16px/1 Archivo, sans-serif; cursor: pointer; }
