
      :root {
        /* Surfaces and ink. Held separate from the accent so a colour
           change never silently restyles text. */
        --alv-paper:      #ffffff;
        --alv-surface:    #f8f9fa;
    --alv-surface-deep: #e9ecef;  /* the far stop of the panel wash */
        --alv-ink:        #21343c;
        --alv-ink-soft:   #5b6b73;
        --alv-ink-faint:  #8a979d;
        --alv-ink-strong: #41535c;   /* column headings                  */
        --alv-line:       #e3e8ea;
        --alv-line-soft:  #f1f3f5;

        /* Semantic, and deliberately not aliases of the accent token. A
           status must not change meaning because the brand colour moved.
           (Wording note - this comment avoids writing a token name with a
           colon after it, because that reads as a declaration to any tool
           matching on one, including our own test extractor.) */
        --alv-good:       #1e7d4f;
        --alv-good-soft:  #e6f4ec;
        --alv-good-ink:   #155737;   /* ink on the tint - measures 7.56  */
        --alv-good-line:  #bfe0cd;   /* edge, and pale green on dark ink */
        --alv-warn:       #8e6207;
        --alv-warn-soft:  #fdf3dd;
        --alv-warn-ink:   #6a4a05;   /* ink on the tint - measures 7.34  */
        --alv-warn-line:  #ecd39e;   /* edge, and pale warm on dark ink  */

        /* RC-2, 9 Oct 2026 - the recipe module's warm identity.
           NOT --alv-warn, which means caution: these carry an Edit
           button, a Save button and a unit chip. --alv-warn would
           hold white at 5.38 and was refused on meaning, not ratio.
           --alv-spice SHARES --alv-grade-4's value deliberately.
           Ten candidates were measured: every orange light enough to
           read as orange rather than brown falls under 5.0 against
           white, and every one clearing 5.2 lands on this colour.
           Orange at the ratio this house holds its solids to IS
           burnt sienna, so the two tokens share a value on purpose
           and a later change to one must not be copied to the other. */
        --alv-spice:      #a8481a;   /* white on it - measures 5.82      */
        --alv-spice-ink:  #8a3f08;   /* text, and the hover partner 7.51 */
        --alv-spice-soft: #fdf0e4;   /* the tint - 6.71 with spice-ink   */
        --alv-spice-line: #f0d7bd;   /* edges, and pale warm on dark ink */
        --alv-bad:        #b3261e;
        --alv-bad-soft:   #fbeae9;
        --alv-bad-ink:    #8f1d17;   /* ink on the tint - measures 7.66  */
        --alv-bad-line:   #f2cecb;   /* the tint's own edge              */
        --alv-info:       var(--alv-accent);
        --alv-info-soft:  var(--alv-accent-soft);
        --alv-neutral:    #616c74;
        --alv-neutral-soft: #eef1f2;

        /* THE CATEGORY FAMILY'S INKS, lifted out of the .alv-tag-* rules so
           that something which is not a chip can use one.

           The Issues Analysis modal's "Logged vs resolved" chart asked
           first. Logged is a CATEGORY - how many arrived - not a verdict,
           so it wanted a categorical tone; but the five tag inks were
           literals inside class definitions, and a canvas element cannot
           read a class. It had #2a78d6, a blue nothing else in the system
           used.

           Lifting all five rather than the one that was asked for: a family
           with one member promoted reads as an accident, and the next
           asker wants a different colour of the same set. No chip changes
           appearance - the classes below now name these instead of
           repeating them. */
        --alv-tag-sky-ink:   #2b6a86;
        --alv-tag-moss-ink:  #4a6b3c;
        --alv-tag-clay-ink:  #8a5a34;
        --alv-tag-slate-ink: #55606b;
        --alv-tag-plum-ink:  #6b4a72;

        /* AND THEIR GROUNDS, NAMED - 29 Sep. The five .alv-tag rules
           below already wrote these exact values as literals; the inks
           two lines up were pulled out for the reason the comment
           above gives, and the grounds were left behind. Celebrations
           needs them outside a chip - a row's background and a stripe
           take the same tone as the chip on that row - and a page
           cannot reach into a rule to borrow a literal. Same values,
           so nothing changes appearance. */
        --alv-tag-sky-soft:   #e8f1f5;  --alv-tag-sky-line:   #d3e4ec;
        --alv-tag-moss-soft:  #eef4e9;  --alv-tag-moss-line:  #dde8d6;
        --alv-tag-clay-soft:  #f7efe7;  --alv-tag-clay-line:  #ecdfd2;
        --alv-tag-slate-soft: #eef1f3;  --alv-tag-slate-line: #e0e5e9;
        --alv-tag-plum-soft:  #f3edf5;  --alv-tag-plum-line:  #e5dae8;

        /* A sequential scale, for AGEING. Four steps, mild to severe.
           Named for ageing rather than a general-purpose sequence: one use
           case does not justify a general scale, and the same restraint
           deferred the segmented toggle and the compact table until a second
           page asked.

           The ENDS ARE THE SEMANTIC TOKENS - step 2 is the warn colour and
           step 4 is the bad one - so this scale cannot drift away from the
           meaning of the statuses beside it. The two middle steps walk the
           hue between them. The soft variants also lighten monotonically, so
           a row of tinted cells reads left to right even for a reader who
           cannot separate the hues.

           There is deliberately no step for NOT YET DUE. That is the absence
           of ageing, not the first degree of it, and it takes the good token
           like any other healthy state. */
        /* AG-1, 4 Oct 2026 - ONE TONE, DEEPENING. Demetri, of the
           Outstanding Invoices Report: "I don't like these colours any
           more. They don't fit within our team and grey theme... I have
           decided that I don't need a green and red scale."

           WHAT THIS REPLACED, named so it is never re-derived: #8a7a12
           olive, #8e6207 amber, #a8481a rust and #b3261e red, with
           #fdf8e6 / #fbeec9 / #f8e0cd / #f6d5d2 beneath them, and
           --alv-good standing in for step 0. Six columns of one report,
           each a different hue, in an application whose palette is one
           teal and a run of greys.

           AND THE TRAFFIC LIGHT WAS THE WRONG PICTURE. Green to red
           says healthy versus broken. Money forty days late is not a
           different KIND of thing from money ten days late - it is the
           same thing further along, which is what one deepening tone
           says, and says to a reader who cannot separate hues too.

           WARM, NOT THE GREY ALREADY HERE. --alv-surface and
           --alv-surface-deep are this page's own wash; an ageing column
           has to read AS a tint beside them, and cool grey on cool grey
           does not. Warm is still the grey theme and still separable.

           MEASURED AGAINST --alv-ink, which is what the figures in
           these cells are written in:
               step 0  12.40    step 1  11.47    step 2  10.30
               step 3   9.03    step 4   7.63
           The scale this replaced carried coloured ink at 4.05 to 4.78.

           THE SOLID TOKEN STILL DEEPENS because it drives the DOT and
           the BAR FILL, which are shapes, not text: 3.00 to 11.80
           against paper, the lowest exactly on the 3:1 non-text needs.
           It is NOT the pill's text colour any more - see .alv-age-pill,
           where carrying it over literally would have put #8a8578 on
           #f2f1ee at 3.26. */
        --alv-age-0:      #8a979d;
        --alv-age-0-soft: #fafaf9;
        --alv-age-1:      #8a8578;
        --alv-age-1-soft: #f2f1ee;
        --alv-age-2:      #6f6a5d;
        --alv-age-2-soft: #e8e5df;
        --alv-age-3:      #55504a;
        --alv-age-3-soft: #dcd7cd;
        --alv-age-4:      #3b3733;
        --alv-age-4-soft: #cdc6b9;

        /* THE GRADING SCALE - five steps, best to worst.
           A sibling of the ageing scale, NOT a member of it: ageing runs
           "not ageing" to "severe" and begins at good, while a grade runs
           across a distribution and has a MIDDLE. Ends anchored on the
           semantics already in this block - step 1 is the good tint, step 5
           is the bad tint, step 3 is neutral - so the scale cannot drift
           away from the meanings around it, which is exactly what the
           computed hsl() ramp it replaces had done. */
        --alv-grade-1:      #1e7d4f;
        --alv-grade-1-soft: #cfe9da;
        --alv-grade-2:      #4a7b46;
        --alv-grade-2-soft: #e2f0e0;
        --alv-grade-3:      #5b6b73;
        --alv-grade-3-soft: #f2f1ee;
        --alv-grade-4:      #a8481a;
        --alv-grade-4-soft: #fae3da;
        --alv-grade-5:      #b3261e;
        --alv-grade-5-soft: #f7d3ce;

        /* THE SERIES SCALE - one colour per THING, on a chart.
           ===== ALV SERIES SCALE v1 ===== 23 Sep 2026

           act_expense and financial_indicators each drew one mark per
           property from its own hardcoded array of twelve colours, and the
           two arrays shared not one value. Run through a palette validator,
           both FAILED, and two pairs were the same colour to a reader with
           ordinary sight:

             financial_indicators  the PORTFOLIO line #0e7c8b and the 12th
                                   property #00838f      delta-E  2.0
             act_expense           properties 10 and 11
                                   #d6336c and #c2255c   delta-E  5.0

           The floor is 15. Below it the two cannot be told apart at all -
           and on Financial Indicators the collision was with the portfolio
           average, the line every property is being compared against.

           THE HOUSE INKS CANNOT DO THIS JOB, and that was measured before
           this scale was written. The five tag inks were tried first: all
           five fall below the chroma floor (they read as grey on a chart
           surface), moss and clay separate by delta-E 2.1 under protanopia,
           slate and plum by 7.5 in ordinary sight. Those inks were drawn to
           sit BEHIND TEXT IN A CHIP, where low chroma is the whole point. A
           2px mark on white is a different job and needs more colour. A
           second, more muted attempt failed the same two checks. So this
           scale is louder than the rest of the palette on purpose.

           VALIDATED, not chosen by eye:
             lightness band    all 8 inside L 0.43-0.77   PASS
             chroma floor      all 8 >= 0.1               PASS
             CVD separation    worst adjacent 9.1         PASS
             normal vision     worst adjacent 19.6        PASS
             contrast          3 slots under 3:1          WARN - relieved by
                               the legend both charts already carry

           THE ORDER IS LOAD-BEARING. The checks are run on ADJACENT pairs,
           so re-ordering can break them: two re-orderings tried here
           dropped CVD separation to 6.1 and 6.9, into the band that is
           legal only with a second encoding. This order is the validated
           one, rotated by one place so that BLUE - the only hue within
           delta-E 15 of the accent, at 12.4 - lands in the last slot
           instead of the first. Rotation preserves every adjacent pair.
           Check any change with a validator; do not eyeball it.

           NOT A STATUS COLOUR. good, warn, bad and the grade steps are
           reserved for what a number MEANS. These say only WHICH thing a
           mark belongs to, and a chart must never borrow one for the other.

           EIGHT, AND NO NINTH HUE. A ninth series does not get a generated
           colour - it takes slot 1 again with a second MARK, so no two
           series are ever identical: a dash on a line chart, a different
           point shape where the mark is a dot. Sixteen distinguishable
           series; past that a chart needs fewer things on it, not more
           colours.                                  [test_series_scale.py] */
        --alv-series-1:   #eb6834;   /* orange  */
        --alv-series-2:   #1baf7a;   /* aqua    */
        --alv-series-3:   #eda100;   /* yellow  */
        --alv-series-4:   #e87ba4;   /* magenta */
        --alv-series-5:   #008300;   /* green   */
        --alv-series-6:   #4a3aa7;   /* violet  */
        --alv-series-7:   #e34948;   /* red     */
        --alv-series-8:   #2a78d6;   /* blue    */

        /* Action colours for the icon buttons. */
        --alv-edit:       #2563eb;
        --alv-view:       var(--alv-accent);
        --alv-danger:     var(--alv-bad);

        /* One hook for typography. base.html loads no webfont today, so
           this inherits. Pointing it at a family later is a one-line
           change that reaches every component below. */
        --alv-font-ui:    inherit;
        --alv-radius:     8px;
        /* D-12, 9 Oct 2026 - 158 border-radius: 6px literals across
     the corpus now read var(--alv-radius-sm). Identical
     computed value, so nothing moved; what changed is that
     retuning this one line now retunes all of them. D-7 rode
     along: the dead comment-author class came off five spans
     on four report pages. */
  --alv-radius-sm:  6px;
      }

      /* ================================================== THE TABLE SHELL */
      .table-container {
        background: var(--alv-paper);
        border-radius: var(--alv-radius);
        /* clip, NOT hidden. Both clip the rounded corners, but overflow:hidden
           makes this element the scroll container for any sticky descendant -
           and since it never scrolls, the header never sticks. Measured: at a
           650px scroll the header sat 615px above the viewport with hidden,
           and at top:0 with clip. overflow:clip needs Safari 16+; older Safari
           loses the corner rounding and nothing else. */
        overflow: clip;
        box-shadow: 0 1px 2px rgba(16, 34, 40, .05),
                    0 1px 3px rgba(16, 34, 40, .04);
      }

      /* ===== DD-1 ===== 3 Oct 2026 ==================================
         A TABLE THAT HOLDS A POPUP DOES NOT CLIP IT.

         The `clip` above is deliberate - see the note on it - but it
         clips ABSOLUTELY-POSITIONED DESCENDANTS exactly as `hidden`
         does. A dropdown opened from a cell is one of those, and on the
         recipe capture page the container's bottom edge sits a few
         pixels under the input: the suggestions came out as a sliver.

         THE POPUP SAYS SO, THE CONTAINER DOES NOT GUESS. Only a
         container holding .alv-escapes stops clipping, so every other
         table in the app keeps its corners. Marking the popup rather
         than the table also means the fact lives next to the thing it
         is true of.

         A BROWSER WITHOUT :has() DROPS THIS RULE AND BEHAVES AS IT DOES
         TODAY, which is the only safe way for a fix to fail.
                                            [test_escaping_drop.py] */
      .table-container:has(.alv-escapes) { overflow: visible; }
      /* ===== /DD-1 ===== */

      /* ===== IN-2 ===== 11 Oct 2026 ==================================
         THE INVOICE LINE GRID, SAID ONCE.

         customer_invoice_form and physical_invoice_edit both wrote
         these three rules and wrote them identically, character for
         character. Two callers is what D-3 and D-5 were waiting for.

         ON A PHONE IT STOPS BEING A TABLE. The grid is 720px wide and
         a phone is 390: measured, 362px of it sat outside the box with
         nothing on screen to say so, and what was outside was Qty,
         Unit Price and VAT. A scroll you cannot see is worse on a form
         you fill in than on one you read.

         So each line becomes a labelled block. It costs height - 980px
         for two lines against 151 - and that was chosen from the two
         renders, against pinning a column and adding a swipe cue.

         EVERY CELL CARRIES data-label, INCLUDING THE TEMPLATE'S. Both
         pages add lines by cloning <template id="lineTemplate">, so a
         row added after load comes from there. Labelling only the
         server-rendered rows would leave every line the user adds as a
         column of unnamed boxes - a defect that appears only after an
         interaction.
                                            [test_lines_table.py] */
      .lines-scroll {
        overflow-x: auto;
        background: var(--alv-paper);
        border-radius: var(--alv-radius);
        /* A literal, and deliberately. base writes its own shadows as
           literals - there is no shadow token to move this to, and a
           shadow scale is a decision of its own. */
        box-shadow: 0 2px 8px rgba(0,0,0,0.06);
      }
      .lines-table { margin-bottom: 0; min-width: 720px; }
      .lines-table thead th {
        background-color: var(--alv-ink);
        color: var(--alv-on-accent);
        font-weight: 600;
        font-size: 13px;
        vertical-align: middle;
      }

      @media screen and (max-width: 768px) {
        .lines-scroll {
          overflow-x: visible;
          background: transparent;
          box-shadow: none;
          border-radius: 0;
        }
        .lines-table,
        .lines-table tbody,
        .lines-table tr,
        .lines-table td { display: block; width: 100%; }
        .lines-table { min-width: 0; border: 0; }
        .lines-table thead { display: none; }
        .lines-table tr {
          border: 1px solid var(--alv-line);
          border-radius: var(--alv-radius);
          padding: 12px 14px;
          margin-bottom: 12px;
          background: var(--alv-paper);
        }
        .lines-table td { border: 0; padding: 0 0 10px; }
        .lines-table td:last-child { padding: 0; text-align: right; }
        .lines-table td[data-label]::before {
          content: attr(data-label);
          display: block;
          font-size: 12px;
          color: var(--alv-ink-soft);
          margin-bottom: 4px;
        }
      }
      /* ===== /IN-2 ===== */

      .alv-table {
        font-family: var(--alv-font-ui);
        color: var(--alv-ink);
        margin-bottom: 0;
        border-color: var(--alv-line);
      }
      .alv-table thead th {
        background: var(--alv-surface);
        /* Was #5b6b73 at 12.5px with .02em tracking. Uppercase, tracking,
           small size and light ink are each a way of making a label quiet;
           all four at once made it faint. Two of them relax here. */
        color: var(--alv-ink-strong);
        font-weight: 600;
        font-size: 13.5px;
        letter-spacing: .01em;
        text-transform: uppercase;
        vertical-align: middle;
        padding: 11px 12px;

        /* Sticky. This does nothing on its own - see .table-container below,
           whose overflow decides whether it can work at all. */
        position: sticky;
        top: 0;
        z-index: 2;

        /* NOT border-bottom. A border on a sticky cell detaches from it
           while scrolling; an inset shadow is painted with the background
           and stays put. */
        border-bottom: 0;
        border-top: none;
        box-shadow: inset 0 -1px 0 var(--alv-line);
      }
      .alv-table tbody td {
        border-top: 1px solid var(--alv-line-soft);
        vertical-align: middle;
        padding: 11px 12px;
      }
      .alv-table tbody tr:hover { background: var(--alv-accent-soft); }

      /* Vertical grid lines off. Bootstrap's .table-bordered draws a box
         around every cell, which is the most dated thing on these pages.
         Horizontal rules alone are enough to track a row across, and the
         eye follows them better without the verticals competing.

         Done here rather than by editing markup so that a page which has
         not migrated yet still loses them the moment it gains .alv-table. */
      .alv-table.table-bordered { border: 0; }
      .alv-table.table-bordered thead th,
      .alv-table.table-bordered tbody td,
      .alv-table.table-bordered tbody th {
        border-left: 0;
        border-right: 0;
      }
      .alv-table.table-bordered thead th {
        border-top: 0;
        border-bottom: 1px solid var(--alv-line);
      }

      /* Zebra off - decision 2. Done HERE rather than by editing markup,
         so no template has to drop its table-striped class. */
      .alv-table.table-striped tbody tr:nth-of-type(odd),
      .alv-table.table-striped tbody tr:nth-of-type(even) {
        background-color: transparent;
      }
      .alv-table.table-striped tbody tr:hover {
        background-color: var(--alv-accent-soft);
      }

      /* Action columns stay centred. Everything else went left when the
         page dropped Bootstrap's text-center, which is right for names and
         companies and wrong for a column holding one 34px button. */
      .alv-table .desktop-action-cell,
      .alv-table th.desktop-action-cell { text-align: center; }

      /* A NUMERIC HEADING IS RIGHT-ALIGNED BY DEFAULT - see .num above - and
         that is right when the label is short enough to sit on one line,
         because it then hangs over the last digit of its own column.

         A stack of three-line labels over narrow columns reads differently:
         right-aligned they all crowd one edge and the column looks lopsided,
         with the label's shortest line stranded. .col-center is the opt-out,
         and it applies to the HEADING only - the figures underneath stay on
         .num, because numbers line up on the decimal or they line up on
         nothing. */
      .alv-table thead th.col-center { text-align: center; }

      /* ONE actions column, right-aligned, rather than one column per verb.
         Three headers reading EDIT / REPORT / DELETE say what the icons
         beneath them already say, and cost about a tenth of the table's
         width - which Role and Company Name would rather have.

         Right, not centre: the actions are the end of the row, and a ragged
         centre line down a narrow column reads as an accident. Against the
         right edge they form a clean column of their own. */
      /* Heading AND cells centred, which is the only arrangement that
         lines them up for any number of buttons.

         Centring the heading alone centres it on the COLUMN; the buttons are
         a right-aligned cluster that stops short of the right edge. Two
         different centre lines, and the gap between them moves with the
         button count and the column width - measured at 51px on a 3-button
         20% column and 11px on a 4-button 16% one. Centring both is 0.0px
         every time. */
      .alv-table .cell-actions,
      .alv-table th.cell-actions {
        text-align: center;
        white-space: nowrap;
      }
      .row-actions {
        display: inline-flex;
        align-items: center;
        gap: 6px;
      }

      /* The shadow appears only while the heading is actually stuck.
         A permanent one would make an unstuck heading look like it were
         floating, which is a worse lie than no cue at all. The class is put
         on by the observer at the end of this file. */
      .table-container.is-stuck .alv-table thead th {
        box-shadow: inset 0 -1px 0 var(--alv-line),
                    0 6px 12px -6px rgba(16, 34, 40, .28);
      }

      /* Numbers line up on the decimal, names do not. */
      .alv-table .num, .alv-table td.num, .alv-table th.num {
        text-align: right;
        font-variant-numeric: tabular-nums;
      }

      /* A TOTALS ROW BELONGS IN A tfoot, and until now the standard had no
         rule for one - so every table that wanted a summary line put it in
         the tbody as an ordinary <tr> and styled it by hand. Outstanding
         Invoices did exactly that, with a background literal and a navy
         border.

         It is not only tidiness. A tfoot is announced as a summary rather
         than as another record, and a browser repeats it at the foot of each
         printed page, which a tbody row cannot do.

         Deliberately NOT sticky. .alv-matrix pins its footer because it
         scrolls sideways under a frozen column; an ordinary table does not,
         and a footer that follows the viewport in a page that scrolls
         normally is furniture, not information. */
      .alv-table tfoot td,
      .alv-table tfoot th {
        background: var(--alv-surface);
        border-top: 2px solid var(--alv-line);
        color: var(--alv-ink-strong);
        font-weight: 600;
        padding: 11px 12px;
      }
      /* AN IDENTIFIER YOU CAN CLICK - IR-1, 23 Oct 2026. G1.
         Demetri, 16 Oct: the receipt number is small grey monospace,
         the invoice number is a teal link. Two registers for one kind
         of thing. He chose the invoice's on 23 October.

         ONE RULE, NOT TWO. physical_invoice_list carried its own
         .pi-number-link with these exact three declarations. A second
         copy here would make "one register" true by coincidence
         rather than by construction, so both pages take this.

         WHAT WAS HERE: .alv-table .ref, monospace 12.5px in
         --alv-ink-soft, defined in base and used on ONE cell of ONE
         page. It is gone rather than left, because a base rule with
         no consumer is one the next page will pick up by accident. */
      .alv-ref-link {
        color: var(--alv-accent);
        text-decoration: none;
        font-weight: 600;
      }
      .alv-ref-link:hover { text-decoration: underline; }
      /* GS-1, 27 Oct 2026 - A FINGER-SIZED TARGET ON A PHONE. The link
         measured 78x20 at 375px, under the 44px the house asks of every
         control (test_tap_target). The same answer as Edit Asset's photo
         buttons: the TAP AREA grows, the layout does not - 12px of
         padding above and below is cancelled by the same negative
         margin, so the row is exactly as tall as it was. Screen-only, so
         it never reaches paper. [test_gate_speed_two.py] */
      @media screen and (max-width: 768px) {
        .alv-ref-link {
          display: inline-block;
          padding: 12px 4px;
          margin: -12px -4px;
        }
      }

      /* ============================================ ICON ACTION BUTTONS */
      /* One definition. Previously three, differing by `padding: 0`. */
      .icon-action-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 34px;
        height: 34px;
        padding: 0;
        border-radius: var(--alv-radius-sm);
        border: 1px solid var(--alv-line);
        background: var(--alv-paper);
        color: var(--alv-ink-soft);
        text-decoration: none;
        font-size: 13.5px;
        cursor: pointer;
        transition: background-color .15s ease, border-color .15s ease,
                    color .15s ease;
      }
      .icon-action-btn i { font-size: 13.5px; }
      .icon-action-btn:hover,
      .icon-action-btn:focus {
        text-decoration: none;
        box-shadow: none;
      }
      .icon-action-btn:focus-visible {
        outline: 2px solid var(--alv-accent);
        outline-offset: 2px;
      }

      .icon-edit   { color: var(--alv-edit);   border-color: #c9d8f7; }
      .icon-view   { color: var(--alv-view);   border-color: var(--alv-accent-line); }
      .icon-delete { color: var(--alv-danger); border-color: var(--alv-bad-line); }
      .icon-edit:hover   { background: var(--alv-edit);   border-color: var(--alv-edit);   color: var(--alv-on-accent); }
      .icon-view:hover   { background: var(--alv-view);   border-color: var(--alv-view);   color: var(--alv-on-accent); }
      .icon-delete:hover { background: var(--alv-danger); border-color: var(--alv-danger); color: var(--alv-on-accent); }

      /* Upload - a new name on an existing colour, not a seventh colour.
         Aliased to --alv-edit because uploading a document writes to the
         record in the same way editing it does, and the palette is already
         six tones deep. It gets its OWN class rather than borrowing
         .icon-edit so the markup does not claim a button edits when it
         uploads - and so that pointing it somewhere else later is one line
         here rather than a search across every page. */
      .icon-upload   { color: var(--alv-edit); border-color: #c9d8f7; }
      .icon-upload:hover { background: var(--alv-edit); border-color: var(--alv-edit); color: var(--alv-on-accent); }

      /* Document: the SIXTH NAME on --alv-view, added by RA-1 on 4 Oct 2026.
   .icon-view was carrying FOUR pictures - fa-eye eleven times, but also
   fa-file-contract on View Lease Agreement and View Title Deed, fa-box
   on View Property Assets and fa-file-pdf on View receipt. base states
   the rule beside .icon-duplicate, .icon-manage and .icon-list and it
   was simply not being kept: A CLASS CARRIES ONE PICTURE. Alias the
   colour, never the name.

   Opening the paper a record refers to is still a LOOK, so it points at
   --alv-view like the eye. It takes its own name because the row-action
   ORDER sorts on the NAME: a lease agreement wearing .icon-view sorts as
   "view this record" and lands in the wrong place inside Look. The split
   is what makes the standard expressible, not decoration.

   THREE NAMES, ONE PER PICTURE. .icon-pdf and .icon-assets are here for
   the same reason .icon-document is, and for no other: fa-file-pdf is
   not fa-file-contract, and a property's assets are not a shopping
   list. The first build of this round economised - both document
   glyphs on .icon-document, fa-box on the existing .icon-list - and
   repaired a class carrying four pictures by making two that carried
   two. All three point at --alv-view and the palette is unchanged.

   THE ORDER ITSELF - LOOK, CHANGE, COPY, ADVANCE, DESTROY - is in
   alv_rowactions.py, shared by the patcher, Show-RowActionDrift.py and
   test_row_action_order.py so that it is written once.
                                       [test_row_action_order.py] */
      .icon-document,
      .icon-pdf,
      .icon-assets       { color: var(--alv-view); border-color: var(--alv-accent-line); }
      .icon-document:hover,
      .icon-pdf:hover,
      .icon-assets:hover { background: var(--alv-view); border-color: var(--alv-view); color: var(--alv-on-accent); }
      .icon-color-document,
      .icon-color-pdf,
      .icon-color-assets { color: var(--alv-view); }

      /* Comment: the SEVENTH NAME on --alv-view, added by PD-2 on 4 Oct
         2026 for the Property Issues row action (fa-comments). Reading
         what somebody wrote about an issue SHOWS you something and
         changes nothing, which is what this colour means here.

         Its own name, by the rule three blocks up: a class carries ONE
         PICTURE, so fa-comments does not go on .icon-view beside the
         eye. Alias the colour, never the name. Nothing is added to the
         palette.                            [test_pd_tables.py] */
      .icon-comment       { color: var(--alv-view); border-color: var(--alv-accent-line); }
      .icon-comment:hover { background: var(--alv-view); border-color: var(--alv-view); color: var(--alv-on-accent); }
      .icon-color-comment { color: var(--alv-view); }

      /* Save and Cancel - the two halves of an INLINE EDIT, which three
         Personal pages do in the row itself rather than on a screen of
         their own. Same rule as .icon-upload above: a new action takes
         its own NAME on an EXISTING colour, never a seventh tone.

         Save is --alv-good, which .icon-approve (fa-check) and
         .icon-unlock (fa-user-check, IC-2) already
         wear - committing an edit is a confirmation, and it reads as one.

         Cancel is .icon-action-btn's own resting ink. It is deliberately
         NOT "no class at all": a button with no alias says nothing about
         itself, and if the quiet one ever needs to stop being quiet, that
         is one line here rather than a search across every page. */
      .icon-save   { color: var(--alv-good); border-color: var(--alv-good-line); }
      .icon-save:hover { background: var(--alv-good); border-color: var(--alv-good); color: var(--alv-on-accent); }
      .icon-cancel { color: var(--alv-ink-soft); border-color: var(--alv-line); }
      .icon-cancel:hover { background: var(--alv-neutral); border-color: var(--alv-ink-faint); color: var(--alv-ink-strong); }

      /* Void - Cash Receipts, and the same rule again. It wore
         .icon-delete and drew fa-ban, so .icon-delete had two pictures
         and neither the class nor the glyph said what the button does:
         voiding a receipt KEEPS the record. Danger's colour is right;
         Delete's name was not. */
      .icon-void   { color: var(--alv-danger); border-color: var(--alv-bad-line); }
      .icon-void:hover { background: var(--alv-danger); border-color: var(--alv-danger); color: var(--alv-on-accent); }

      /* Approve / unapprove / send, used by Physical Invoices. */
      .icon-approve   { color: var(--alv-good); border-color: var(--alv-good-line); }
      .icon-approve:hover { background: var(--alv-good); border-color: var(--alv-good); color: var(--alv-on-accent); }
      .icon-unapprove { color: var(--alv-warn); border-color: var(--alv-warn-line); }
      .icon-unapprove:hover { background: var(--alv-warn); border-color: var(--alv-warn); color: var(--alv-on-accent); }
      .icon-send      { color: var(--alv-accent); border-color: var(--alv-accent-line); }
      .icon-send:hover { background: var(--alv-accent); border-color: var(--alv-accent); color: var(--alv-on-accent); }
      /* RA34 - Acquisitions' Start the PC search on a run's row: the search goes out, as send does. */
      .icon-pc-search      { color: var(--alv-accent); border-color: var(--alv-accent-line); }
      .icon-pc-search:hover { background: var(--alv-accent); border-color: var(--alv-accent); color: var(--alv-on-accent); }

      /* A permission the user does not have is shown, not hidden - so the
         page reads the same for everyone and the absence is explained by
         the title attribute rather than by a missing button. */
      .icon-disabled,
      .icon-action-btn.icon-disabled {
        color: var(--alv-ink-faint);
        border-color: var(--alv-line);
        background: var(--alv-surface);
        cursor: not-allowed;
      }
      .icon-disabled:hover {
        background: var(--alv-surface);
        color: var(--alv-ink-faint);
        border-color: var(--alv-line);
        box-shadow: none;
      }

      /* ================================================== ROW ACTIONS,
         WITH A WORD ===== ALV ROW PILL v1 ===== 23 Sep 2026

         The labelled row action - Edit and Delete with the word, not only
         the icon above - which six Financials pages each carried a copy
         of. The copies had drifted into saying something untrue: Edit was
         GREEN on the three revenue pages and RED on the three expense
         pages, so the colour tracked which MODULE you were in rather than
         what the button did; and on finance_expense_line_types the pair
         was inverted, Edit red and Delete grey, so the destructive one was
         the quiet one. Decision 3.1 - colour means something - and the
         instruction that every Financials sub-module takes the same format
         as the rest of the system.

         THE SAME TWO COLOURS AS .icon-edit AND .icon-delete ABOVE. They
         are the same two actions in a different shape, and a page that
         shows Edit as an icon must not disagree with a page that shows it
         as a word. The BORDER stays 2px solid in the action's own colour,
         which is the weight these six already had - this round changes the
         hue, not the shape.

         pointer-events stays AUTO on the disabled variants. finance_expense
         worked that out first and wrote the reason beside it: a disabled
         control still has to be able to say WHY it is disabled, and its
         `title` never appears while pointer-events is none. Five of the six
         did not have it. Now all six do.

         A page joins by DELETING its copy - no markup changes, so no
         template tag and no permission block is ever at risk.
                                                  [test_row_actions.py] *      /* A permission the user does not have is SHOWN, not hidden - the
         same decision the icon row actions take above. *      /* On a phone the row becomes a card and the action takes the width,
         which four of the six already did for themselves. Unscoped, so the
         two that put their copy behind a card class - and were therefore
         still 34px on a phone - get it as well.

         min-height, and 44 rather than the 43 those four copies actually
         measured. 9px of padding on 14px type came to 43px with the two
         borders, one short of the target standard 3.4 has promised for
         weeks, and nobody had measured it. The ALV TAP TARGET block does
         not reach this control, because a row pill is not a .btn. */
      @media screen and (max-width: 768px) {      }
      /* ===== /ALV ROW PILL v1 ===== */

      /* ========================================================== PILLS */
      /* A state the reader cannot act on. Buttons stay buttons while they
         are still an action - decision 5. */
      .alv-pill {
        display: inline-flex;
        align-items: center;
        gap: 5px;
        padding: 3px 10px;
        border-radius: 999px;
        font-size: 12px;
        font-weight: 600;
        line-height: 1.5;
        white-space: nowrap;
        border: 1px solid transparent;
      }
      .alv-pill-good    { background: var(--alv-good-soft);    color: var(--alv-good);    border-color: var(--alv-good-line); }
      .alv-pill-attn    { background: var(--alv-warn-soft);    color: var(--alv-warn);    border-color: var(--alv-warn-line); }
      .alv-pill-bad     { background: var(--alv-bad-soft);     color: var(--alv-bad);     border-color: var(--alv-bad-line); }
      .alv-pill-info    { background: var(--alv-info-soft);    color: var(--alv-accent-ink); border-color: var(--alv-accent-line); }
      .alv-pill-neutral { background: var(--alv-neutral-soft); color: var(--alv-neutral); border-color: var(--alv-line); }

      /* ================================================= STATUS BUTTONS */
      /* Actual Expenses: Manage / Approved? / Paid? are actions until they
         are settled, and a state afterwards. */
      .status-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        min-height: 30px;
        padding: 4px 12px;
        border-radius: var(--alv-radius-sm);
        border: 1px solid var(--alv-accent-line);
        background: var(--alv-paper);
        color: var(--alv-accent-ink);
        font-size: 12.5px;
        font-weight: 600;
        cursor: pointer;
        transition: background-color .15s ease, border-color .15s ease;
      }
      .status-btn:hover {
        background: var(--alv-accent-soft);
        text-decoration: none;
        color: var(--alv-accent-ink);
      }
      .status-btn.is-disabled,
      .status-btn:disabled {
        background: var(--alv-surface);
        border-color: var(--alv-line);
        color: var(--alv-ink-faint);
        cursor: not-allowed;
      }

      /* ==================================================== EMPTY STATE */
      /* Seven of the eight list pages render nothing at all when there is
         nothing to show, which reads as a broken page rather than an empty
         one. */
      /* THE REQUIRED MARKER - 7 Sep. base's first.

         An asterisk in a label is how this system says a field is required.
         It did it 115 times across 34 templates in SEVEN shapes, and those
         seven rendered as THREE things: #dc3545 on 102 of them (Bootstrap's
         red, reached by four spellings, three of which hardcoded the value
         in eighteen separate page rules), a louder #FF0000 on nine inline
         ones, and NOTHING on four bare asterisks, where the signal was a
         character rather than a colour.

         --alv-bad appeared nowhere among them. The system said "required" in
         a colour it did not own, and if Bootstrap ever left, 102 asterisks
         would have turned black.

         font-weight is here because the asterisk is small and the ink is
         dark; at 400 it reads as punctuation. */
      .alv-req {
        color: var(--alv-bad);
        margin-left: 2px;
        font-weight: 600;
      }

      .alv-empty {
        padding: 44px 20px;
        text-align: center;
        color: var(--alv-ink-soft);
        background: var(--alv-paper);
      }
      .alv-empty i {
        font-size: 30px;
        color: var(--alv-ink-faint);
        margin-bottom: 12px;
        display: block;
      }
      .alv-empty .alv-empty-title {
        font-weight: 600;
        color: var(--alv-ink);
        margin-bottom: 4px;
      }
      .alv-empty .alv-empty-hint { font-size: 13.5px; }

      /* ============================================ MOBILE: ROWS → CARDS */
      /* Hidden on desktop; the page markup carries both and CSS chooses. */
      .mobile-action-bar { display: none !important; }

      @media screen and (max-width: 768px) {
        .table-container {
          background: transparent;
          box-shadow: none;
          border-radius: 0;
          overflow: visible;
        }

        .alv-table { border: none; background: transparent; }
        .alv-table thead { display: none; }
        .alv-table,
        .alv-table tbody,
        .alv-table tfoot,
        .alv-table tr,
        .alv-table td { display: block; width: 100%; }

        .alv-table tbody tr,
        .alv-table.table-striped tbody tr:nth-of-type(odd),
        .alv-table.table-striped tbody tr:nth-of-type(even) {
          background: var(--alv-paper);
          border: 1px solid var(--alv-line);
          border-radius: var(--alv-radius);
          margin-bottom: 12px;
          padding: 12px;
          box-shadow: 0 1px 2px rgba(16, 34, 40, .05);
        }
        .alv-table tbody tr:hover { background: var(--alv-paper); }

        .alv-table td {
          border: none !important;
          border-top: none !important;
          padding: 6px 0 !important;
          text-align: left !important;
          display: flex;
          /* CW-1, 5 Oct 2026 - or the value leaves the page.
             The label beside it is flex-shrink: 0, so a value wider than
             the room it leaves had nowhere to go: the Ingredients
             Conversion cell put its badges 58px past a 390px screen.
             Six of the eight card tables painted do not move at all. */
          flex-wrap: wrap;
          justify-content: space-between;
          align-items: center;
          gap: 8px;
          min-height: 28px;
        }
        .alv-table td::before {
          content: attr(data-label);
          font-weight: 600;
          color: var(--alv-ink-soft);
          font-size: 12.5px;
          flex-shrink: 0;
        }
        /* An empty data-label gets no prefix, rather than an empty one. */
        .alv-table td[data-label=""]::before,
        .alv-table td:not([data-label])::before { content: none; }

        /* The first cell is the card title on every one of these pages -
           Contact Person, Property, Tenant, Date, Number. So :first-child
           does the job that eight per-page rules were doing. */
        .alv-table tbody td:first-child {
          display: block;
          font-size: 16px;
          font-weight: 600;
          color: var(--alv-ink);
          padding-bottom: 8px !important;
          margin-bottom: 4px;
          border-bottom: 1px solid var(--alv-line-soft) !important;
        }
        .alv-table tbody td:first-child::before { content: none; }

        .alv-table .num, .alv-table td.num { text-align: right; }

        /* The desktop action cells step aside for the action bar. */
        .desktop-action-cell { display: none !important; }

        .mobile-action-bar {
          display: grid !important;
          grid-template-columns: repeat(3, 1fr);
          gap: 6px;
          margin-top: 10px;
          padding: 10px 0 0 0 !important;
          border-top: 1px solid var(--alv-line-soft);
          align-items: stretch !important;
          min-height: auto !important;
          justify-content: stretch !important;
        }
        .mobile-action-bar::before { content: none !important; display: none !important; }
        .mobile-action-bar.cols-1 { grid-template-columns: 1fr; }
        .mobile-action-bar.cols-2 { grid-template-columns: repeat(2, 1fr); }
        .mobile-action-bar.cols-4 { grid-template-columns: repeat(4, 1fr); }
        /* CR-2, 27 Oct 2026 - Receipts: View, Edit, Duplicate, Email, Void. */
        .mobile-action-bar.cols-5 { grid-template-columns: repeat(5, 1fr); }

    /* A ROW ACTION THAT POSTS IS WRAPPED IN A FORM - 30 Sep 2026.
       Demetri, on Tenants on a phone: why is Delete smaller, and why is
       there a gap between Delete and Report?

       One cause, both symptoms. Edit, Report and Agreement are links,
       so each is a grid item and fills its column. Delete has to post,
       so it is a button inside a form - and the GRID's item is the
       form. The form fills the column; the button inside sizes to its
       own content. Measured at 390px on tenant.html: an 85px column
       holding a 42px button. The 43px it does not fill is the gap.

       display: contents takes the form out of the LAYOUT without taking
       it out of the document - it still posts, still carries its action
       and its CSRF token - and puts its BUTTON in the grid, where the
       other three already are.

       Not a typo. Four pages had already solved this locally in two
       different dialects, and the two pages that never got a copy were
       still broken. Eight copied rules came out when this arrived.
                                                   [test_row_form.py] */
    .mobile-action-bar > form { display: contents; }

        .mobile-action-btn {
          display: flex;
          flex-direction: column;
          align-items: center;
          justify-content: flex-start;
          gap: 6px;
          padding: 8px 4px;
          min-height: 56px;
          border-radius: var(--alv-radius-sm);
          border: 1px solid var(--alv-line);
          background: var(--alv-surface);
          color: var(--alv-ink-soft);
          font-size: 11px;
          text-decoration: none;
          cursor: pointer;
          transition: background-color .15s ease;
        }
        .mobile-action-btn:hover,
        .mobile-action-btn:active {
          background: var(--alv-line-soft);
          color: var(--alv-ink-soft);
          text-decoration: none;
        }
        .mobile-action-icon { font-size: 18px; line-height: 1; }
        .mobile-action-label {
          font-size: 11px;
          font-weight: 500;
          line-height: 1.2;
          text-align: center;
        }

        .icon-color-edit   { color: var(--alv-edit); }
        .icon-color-view   { color: var(--alv-view); }
        .icon-color-delete { color: var(--alv-danger); }
        /* ADDED by E3b, 25 Sep - the family was missing its own
           -add. celebration_management paints an Add Event icon
           with it; valued like .icon-color-approve. */
        .icon-color-add { color: var(--alv-good); }
        .icon-color-upload { color: var(--alv-edit); }

        .mobile-action-disabled {
          opacity: .5;
          cursor: not-allowed;
          color: var(--alv-ink-faint);
        }
        .mobile-action-disabled .mobile-action-icon { color: var(--alv-ink-faint); }
        .mobile-action-disabled:hover,
        .mobile-action-disabled:active {
          background: var(--alv-surface);
          color: var(--alv-ink-faint);
        }
      }
    
      /* ================================================================
         .alv-card - a panel whose header does not shout      --alv-card-std

         Asset Details stacks a blue bar, a green bar and a teal bar down a
         single page. None is the accent colour, and the colour carries no
         information the words do not - a Warranty card is green whether the
         warranty is live or dead, because the bar is decoration.

         So the header goes quiet and the MEANING moves to a pill on the
         right, where it can actually change.
         ================================================================ */
      .alv-card {
        background: var(--alv-paper);
        border: 1px solid var(--alv-line);
        border-radius: var(--alv-radius-sm);
        margin-bottom: 20px;
        /* clip, NOT hidden. An ancestor with overflow:hidden becomes the
           scroll container, so a sticky heading inside a card has nothing
           to stick to - measured 542px above the viewport after a 600px
           scroll. clip rounds the corners without that side effect. The
           same fault, and the same fix, as .table-container. */
        overflow: clip;
      }
      .alv-card > .alv-card-head {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 12px 16px;
        background: var(--alv-surface);
        border-bottom: 1px solid var(--alv-line);
        font-family: var(--alv-font-ui);
        font-size: 13.5px;
        font-weight: 600;
        letter-spacing: .01em;
        color: var(--alv-ink-strong);
      }
      .alv-card > .alv-card-head .alv-card-title {
        margin: 0;
        font: inherit;
        color: inherit;
      }
      /* Icons in a card header are ornament, not content. */
      .alv-card > .alv-card-head i,
      .alv-card > .alv-card-head .fa,
      .alv-card > .alv-card-head .fas {
        color: var(--alv-ink-faint);
      }
      .alv-card > .alv-card-head .alv-card-aside { margin-left: auto; }

      /* The FIRST card on a detail screen names the thing the page is about.
         The page h1 says which SCREEN you are on; this says which asset. It
         is the only card that gets to be loud, and it is loud in size only -
         same calm surface as every other. */
      .alv-card-lead > .alv-card-head {
        padding: 16px;
        font-size: 18px;
        font-weight: 600;
        letter-spacing: 0;
        color: var(--alv-ink);
      }

      .alv-card-body { padding: 16px; }
      /* A table filling a card provides its own edges. */
      .alv-card-body > .alv-table,
      .alv-card > .alv-table,
      .alv-card > .table-container { margin-bottom: 0; }
      .alv-card > .table-container { border: 0; border-radius: 0; }

      /* ================================================================
         .alv-stat - a figure and the words for it        --alv-stat-std

         Four screens built this four times before base got it: .pd-stat
         on Tenant Payment Behaviour, .ia-kpi in the Issues Analysis
         modal, and .summary-stat twice over in Financial Indicators and
         Vacancy Management, near enough the same bytes in two files.

         A VERDICT COLOURS THE FIGURE, NOT THE TILE. Two of those four
         washed the whole box green, amber or red - which repeats, in
         the loudest way available, what the label under the figure has
         already said in words. The figure is the part a reader looks
         at, so the figure is where the colour goes, and it comes from
         the same tokens as .alv-pill so that a tile and the pill in the
         table below it cannot part company.

         The tile brings its OWN surface. Stacking .alv-card underneath
         one to borrow a border is what made .pd-stat need a paragraph
         explaining what it was subtracting back out.
         ================================================================ */
      .alv-stats {
        display: grid;
        /* Three tiles, four, or the five in the Issues Analysis strip -
           one grid, set per page, rather than a second class each time.
           Deliberately a DEFAULTED custom property: no page has to
           define it, and nothing in base defines it either. */
        grid-template-columns: repeat(var(--alv-stats-cols, 4), 1fr);
        gap: 12px;
        margin-bottom: 20px;
      }
      .alv-stat {
        background: var(--alv-paper);
        border: 1px solid var(--alv-line);
        border-radius: var(--alv-radius-sm);
        padding: 14px 16px;
        text-align: center;
        /* A long label must not widen its own column and starve the rest. */
        min-width: 0;
      }
      .alv-stat-value {
        font-family: var(--alv-font-ui);
        font-size: 1.7rem;
        font-weight: 700;
        line-height: 1.1;
        color: var(--alv-ink-strong);
        /* Figures side by side line up only if the digits are one width. */
        font-variant-numeric: tabular-nums;
        white-space: nowrap;
      }
      .alv-stat-label {
        font-size: 0.78rem;
        color: var(--alv-ink-soft);
        text-transform: uppercase;
        letter-spacing: 0.4px;
        margin-top: 4px;
        /* SL-1, 4 Oct 2026. A label is one word often enough - Completed,
           Pending, Overdue - and in Greek one word is thirteen characters
           of uppercase. With nothing to break on it drew 44px past its own
           tile at 1200 and over the tile beside it. Demetri: "The
           Completed Box Cuts off in Greek."

           On the component, not on .is-3up where this used to live, so
           every tile is covered at every width and not only below 768. */
        overflow-wrap: break-word;
      }
      .alv-stat-good .alv-stat-value { color: var(--alv-good); }
      .alv-stat-attn .alv-stat-value { color: var(--alv-warn); }
      .alv-stat-bad  .alv-stat-value { color: var(--alv-bad); }

      /* AND FROM THE AGEING SCALE, for a figure that is a DURATION rather
         than a verdict. .alv-age-0..4 set --age; this is the application
         class that puts it on a figure, the same way .alv-age-pill and
         .alv-age-dot put it on a chip and a dot.

         The Issues Analysis strip asked. Its "Oldest open" tile carried a
         verdict class in the MARKUP - the script only ever wrote the number
         - so it read 12d in red exactly as loudly as it read 300d. A
         verdict that cannot change is decoration.

         NO COMPACT DENSITY CAME WITH IT, though a draft of that round tried.
         The argument was that a .78rem uppercase label does not fit a 180px
         tile; measured, the longest of the five is 137px in a 142px box and
         all five sit on one line. The variant saved 23px of strip height and
         cost a 9.9px label. The restraint above this block stands. */
      .alv-stat-age .alv-stat-value { color: var(--age, var(--alv-ink-strong)); }
/* A STRIP THAT FOLDS ON A PHONE - 30 Sep 2026, OPT-IN. Demetri, on
   Payment Behaviour: on a phone show average days to pay and flagged
   slow, and put the rest behind a chevron. Four tiles are a 2x2 block on
   a phone, and two of the four answered the question.

   Three names. .alv-stats-collapse says this group folds;
   .alv-stat-more marks a tile that folds away; .alv-stats-more is the
   chevron, a grid item spanning both columns. Opt-in because four pages
   use .alv-stats and one of them asked - fsr, with five, is the obvious
   next one and is NOT folded.

   The chevron is desktop-invisible: above 768px the strip is four
   columns across and there is nothing to fold.
                                              [test_stats_fold.py] */
.alv-stats-more { display: none; }

      @media screen and (max-width: 768px) {
        /* Four figures across a phone is four figures nobody can read. */
        .alv-stats { grid-template-columns: repeat(2, 1fr); gap: 10px; }
        .alv-stat { padding: 12px 10px; }
        .alv-stat-value { font-size: 1.4rem; }

        /* THREE ACROSS, FOR A STRIP OF THREE - 1 Oct 2026.
           Two columns is right for four or five stats and leaves a
           strip of three as 2 + 1. Demetri asked for the Task List's
           three on one line.

           The type tightens with the column count because it has to:
           three across at the sizes above holds its label on one line
           at 386px and WRAPS at 360 and 320. Measured, "Total Tasks":
           37px tall at those widths untightened, 16px with this.
           360 is an ordinary Android width.

           overflow-wrap is for GREEK. This page has a language switch,
           and the Greek labels are long words - a 13-character
           OLOKLIROMENES does not fit an 83px box and SPILLS OUT of it
           at 320 and 360 without this. English never needs it. The
           before measured the same spill at 320 already, so this fixes
           something that was there and stops the round spreading it to
           360.

           Opt in with .is-3up. It is not the default, because fsr has
           five stats and three of those would be 77px wide.
                                                [test_stats_3up.py] */
        .alv-stats.is-3up { grid-template-columns: repeat(3, 1fr);
                            gap: 8px; }
        .alv-stats.is-3up .alv-stat { padding: 10px 4px; }
        .alv-stats.is-3up .alv-stat-value { font-size: 1.25rem; }
        .alv-stats.is-3up .alv-stat-label { font-size: 0.66rem;
                                            letter-spacing: .2px; }
    /* THE FOLD, AND WHY IT WAITS FOR THE SCRIPT - 30 Sep 2026. Hiding is
       conditional on .js-ready, which base's script adds. With
       JavaScript off nothing is hidden and no chevron appears: the page
       renders as it does today rather than putting two numbers behind a
       control that cannot be pressed.        [test_stats_fold.py] */
    .alv-stats-collapse.js-ready .alv-stat-more { display: none; }
    .alv-stats-collapse.js-ready.is-open .alv-stat-more { display: block; }
    .alv-stats-collapse.js-ready .alv-stats-more {
        display: flex;
        grid-column: 1 / -1;
        align-items: center;
        justify-content: center;
        gap: 8px;
        min-height: 44px;
        padding: 10px 12px;
        background: var(--alv-surface);
        border: 1px dashed var(--alv-line);
        border-radius: var(--alv-radius-sm);
        font-family: var(--alv-font-ui);
        font-size: 0.78rem;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.4px;
        color: var(--alv-ink-soft);
        cursor: pointer;
        user-select: none;
    }
    .alv-stats-collapse.js-ready .alv-stats-more:focus-visible {
        outline: 2px solid var(--alv-accent);
        outline-offset: 2px;
    }
    .alv-stats-more-chev { transition: transform .15s ease; }
    .alv-stats-collapse.is-open .alv-stats-more-chev {
        transform: rotate(180deg);
    }
      }

      /* ================================================================
         .alv-tag - a CATEGORY, not a status

         Semantics live on .alv-pill and mean something: good, warn, bad.
         A maintenance type is none of those. Painting Repair amber and
         Inspection blue borrows a scale that says "attention" and
         "information" about two words that say neither.

         These tones are named for the colour precisely BECAUSE they carry
         no meaning. Assign them however a page likes; nothing downstream
         reads anything into them.
         ================================================================ */
      .alv-tag {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 2px 9px;
        border-radius: 3px;
        font-family: var(--alv-font-ui);
        font-size: 11.5px;
        font-weight: 600;
        letter-spacing: .02em;
        line-height: 1.7;
        color: var(--alv-ink-soft);
        background: var(--alv-neutral-soft);
        border: 1px solid var(--alv-line);
        white-space: nowrap;
      }
      .alv-tag-sky::before,
      .alv-tag-moss::before,
      .alv-tag-clay::before,
      .alv-tag-slate::before,
      .alv-tag-plum::before {
        content: "";
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: currentColor;
        opacity: .55;
        flex: none;
      }
      /* ===== ALV MESSAGE v1 ===== 29 Sep 2026
         The bar Django's messages framework renders. 77 loops across the
         tree wrote it sixteen different ways; they now write one, and
         .alv-message is what marks a bar as one of THOSE rather than one
         of the twenty static alerts a page puts in its own content.

         THE TEXT STAYS CENTRED. Fifty-odd of the loops centred it with a
         <center> tag - deprecated, and what the G-series is removing. It
         is a rule here instead, so the only thing that moved on the
         screen when the round landed was the colour.

         The close button is Bootstrap's, positioned absolutely, so the
         centred text needs room on both sides rather than one.
                                                 [test_message_bar.py] */
      /* ===== ALV CONTROL ACCENT v1 ===== 29 Sep 2026
         A browser paints a checkbox, a radio and a range slider with
         accent-color and with nothing else - so this one property
         decides what every tick in the system looks like.

         IT WAS BEING DECIDED NINE TIMES. Measured before this rule was
         written: accent-color appeared on nine pages with FIVE values -
         #0e7c8b on three (the accent, longhand), var(--alv-accent) on
         one, #28a745 on Household Members, and #dc3545 / #adb5bd on the
         two expense screens. A tick was green on one screen and teal on
         another for no reason either screen could give.

         A page that wants a different one still can: this is a plain
         element selector, so any class-based rule beats it. The expense
         screens' red is left exactly that way, deliberately, and is
         reported by the suite rather than overridden.
                                              [test_control_accent.py] */
      input[type="checkbox"],
      input[type="radio"],
      input[type="range"] { accent-color: var(--alv-accent); }

      .alv-message { text-align: center; }
      .alv-message.alert-dismissible { padding-right: 52px; padding-left: 52px; }
      @media screen and (max-width: 768px) {
        .alv-message.alert-dismissible { padding-right: 44px; padding-left: 16px; text-align: left; }
      }

      .alv-tag-sky   { color: var(--alv-tag-sky-ink); background: var(--alv-tag-sky-soft); border-color: var(--alv-tag-sky-line); }
      .alv-tag-moss  { color: var(--alv-tag-moss-ink); background: var(--alv-tag-moss-soft); border-color: var(--alv-tag-moss-line); }
      .alv-tag-clay  { color: var(--alv-tag-clay-ink); background: var(--alv-tag-clay-soft); border-color: var(--alv-tag-clay-line); }
      .alv-tag-slate { color: var(--alv-tag-slate-ink); background: var(--alv-tag-slate-soft); border-color: var(--alv-tag-slate-line); }
      .alv-tag-plum  { color: var(--alv-tag-plum-ink); background: var(--alv-tag-plum-soft); border-color: var(--alv-tag-plum-line); }

      /* ================================================================
         Print                                              --alv-print-std

         Reports get printed, and print is where this design is weakest: a
         1px #e3e8ea hairline is often nothing at all on paper.

         The bigger hazard is inherited. Browsers drop background graphics
         in the print dialog by default, so today's navy header band loses
         its background and keeps its white text - white on white. Every
         rule below that paints anything therefore forces colour on.
         ================================================================ */
      @media print {
        /* Interactive furniture does not belong on paper. Property Assets
           printed its Add Asset button, its Back arrow and its Group-by
           toggle before this rule existed.

           Naming a few page-specific classes here is deliberate: a page
           cannot add itself to a base.html print rule, and these are the
           only kinds of furniture the system has. .no-print is the escape
           hatch for anything this list does not know about. */
        .page-action-buttons,
        .action-more-wrapper,
        .action-more-menu,
        .back-button,
        .view-toggle-row,
        .filter-panel,
        .search-row,
        .modal,
        .modal-backdrop,
        .alert-dismissible .close,
        .mobile-action-bar,
        /* AND THE DESKTOP ACTIONS TOO, since 1 Sep. The phone block used
           to read `@media (max-width: 768px)` with no `screen`, and A4
           portrait is about 718 CSS px of content - so it fired on paper
           and hid .desktop-action-cell for us, while the mobile bar above
           was hidden here.
           So the Actions column did not print BY ACCIDENT, and fixing the
           media query would have started printing a row of icon buttons on
           every page. A button on paper is furniture whichever breakpoint
           put it there. */
        .desktop-action-cell,
        .alv-table .cell-actions,
        .row-actions,
        .no-print { display: none !important; }

        .alv-table { font-size: 10.5pt; }
        .alv-table th,
        .alv-table td {
          border-bottom: 1px solid #9aa5ab !important;
          -webkit-print-color-adjust: exact;
          print-color-adjust: exact;
        }
        .alv-table thead th {
          border-bottom: 1.5pt solid var(--alv-ink-soft) !important;
          box-shadow: none !important;
          position: static !important;   /* sticky is meaningless on paper */
          color: #000 !important;
        }
        .alv-table tbody tr:hover td { background: transparent !important; }
        .alv-table tbody tr { break-inside: avoid; }
        .table-container { overflow: visible !important; }

        /* The tile stopped borrowing .alv-card for a surface, so it
           stopped borrowing its paper treatment with it. */
        .alv-card,
        .alv-stat { border-color: #9aa5ab !important; break-inside: avoid; }
        .alv-card > .alv-card-head {
          border-bottom: 1px solid #9aa5ab !important;
          color: #000 !important;
          -webkit-print-color-adjust: exact;
          print-color-adjust: exact;
        }

        /* Tints do not survive a printer that is out of cyan. An outline
           does, and still reads as a chip. */
        .alv-pill,
        .alv-tag {
          border: 1px solid var(--alv-ink-soft) !important;
          color: #000 !important;
          background: transparent !important;
        }
        .alv-tag::before { opacity: 1; }
      }
    
      /* ================================================================
         The page-header action bar                     --alv-actions-std

         Nineteen templates carried a copy of this, 115 rules between
         them, and base.html carried none of it. The names below are the
         ones those pages already use, so a page joins by DELETING its
         copy rather than by being rewritten.

         Colour is by WEIGHT, not by verb. A page has one main thing you
         came to do; that is the solid one. Everything else is outlined.
         Measured before deciding: btn-info 60, btn-secondary 26,
         btn-success 13, btn-danger 9, btn-warning 6 - which is to say
         the colours meant nothing.
         ================================================================ */      /* a Back link outside a bar is still a button.
         Splitting layout from tone left a gap. TONE is unscoped, so a Back
         anywhere gets the house colour; LAYOUT is scoped to
         .page-action-buttons, so a Back with no bar to live in falls back to
         Bootstrap's shape. Measured: 8px/16px, weight 600, radius 8px inside
         a bar; 6px/12px, weight 400, radius 4px outside one. That is why
         Back reads as bare text on FSR Details and Resolved Issues.

         POSITION IS LOAD-BEARING. This sits BEFORE .page-action-buttons so
         the bar's own rules still win inside a bar - on a phone the bar
         shrinks Back to a 44px icon with no padding, and a later rule of
         equal specificity (0,2,0) would silently undo that. */
      .btn.action-back,
      .btn.back-button {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 8px 16px;
        border-radius: var(--alv-radius);
        font-family: var(--alv-font-ui);
        font-size: 14px;
        font-weight: 600;
      }

      /* .disabled-btn dims; it does not grey. On a primary that is now
         handled above. A secondary needs it too - properties_title_deed.html
         has a "Document Not Available" twin that would otherwise render as a
         live outlined button at 60% opacity. */
      .btn.action-secondary.disabled-btn,
      .btn.action-secondary:disabled,
      .btn.action-secondary[disabled] {
        background: var(--alv-disabled-bg, var(--alv-surface-deep));
        border-color: var(--alv-disabled-bg, var(--alv-surface-deep));
        color: var(--alv-disabled-ink, var(--alv-ink-faint));
      }


      .page-action-buttons {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-wrap: wrap;
        margin-bottom: 1.5rem;
      }
      /* Back is navigation, not an action on the data, so it sits apart
         from the verbs. Actions left, Back right - unchanged, so no
         page's layout moves when it joins. */
      .page-action-buttons .action-back { margin-left: auto; }

      .page-action-buttons .btn,
      .page-action-buttons .action-primary,
      .page-action-buttons .action-secondary,
      .page-action-buttons .action-back {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        padding: 8px 16px;
        border-radius: var(--alv-radius);
        font-family: var(--alv-font-ui);
        font-size: 14px;
        font-weight: 600;
        line-height: 1.2;
        border: 1px solid transparent;
        white-space: nowrap;
        text-decoration: none;
      }

      /* UNSCOPED, and colour only. A tone is not bar behaviour: the same
         four names have to work in a modal footer, a report header and a
         card. Sizing stays with whoever owns the layout - the bar rule
         above, or Bootstrap's .btn / .btn-sm everywhere else. Setting
         padding here would have inflated the small "quick add" buttons
         inside the Add Asset modal. */
      .action-primary,
      .btn.action-primary {
        background: var(--alv-accent);
        border: 1px solid var(--alv-accent);
        color: var(--alv-on-accent);
      }
      .action-primary:hover,
      .action-primary:focus,
      .btn.action-primary:hover,
      .btn.action-primary:focus {
        background: var(--alv-accent-ink);
        border-color: var(--alv-accent-ink);
        color: var(--alv-on-accent);
        text-decoration: none;
      }

      .action-secondary,
      .btn.action-secondary {
        background: var(--alv-paper);
        border: 1px solid var(--alv-line);
        color: var(--alv-ink);
      }
      /* A SMALL ADD CONTROL WELDED TO A FIELD - 30 Sep 2026. Demetri, on the
         Add New Asset panel: why are these + buttons in green, they
         should be in teal. Three of them on property_assets - add a
         category, a subcategory, a supplier - all raw
         btn-outline-success, with not one line of CSS on the page. They
         were green because nothing had ever decided otherwise, and
         Show-ButtonDrift had them under LEAVE as welded to an input, so
         the report said nothing drifting over three green buttons.

         BOOTSTRAP KEEPS THE GEOMETRY. `btn` stays on the element and
         input-group-append still matches the height of the field beside
         it - that is what the LEAVE note was really protecting. Only
         the colour moves, and the hover fills rather than tints, which
         is the move .btn.action-secondary above already makes.

         A NAME, because there will be a fourth: a page that grows an
         inline add button reaches for btn-outline-success today because
         there is nothing else to reach for.   [test_field_add.py] */
      .btn.action-field-add {
        background: var(--alv-paper);
        border: 1px solid var(--alv-accent);
        color: var(--alv-accent);
      }
      .btn.action-field-add:hover,
      .btn.action-field-add:focus {
        background: var(--alv-accent);
        border-color: var(--alv-accent);
        color: var(--alv-paper);
      }
      /* PRESSED - B-1, 2 Oct 2026.

         The same answer .action-filter has had since the filter round, and
         for the reason written down there: a toggle with no visible state
         gets pressed twice. recipe_management's Favourites link was saying
         it with btn-danger versus btn-outline-danger, and losing, because
         .btn.action-secondary is (0,2,0) against btn-danger's (0,1,0).

         THE SAME THREE TOKENS as .action-filter[aria-pressed="true"]. This
         round invents no tone and adds no literal to base. */
      .btn.action-secondary[aria-pressed="true"] {
        background: var(--alv-accent-soft);
        border-color: var(--alv-accent-line);
        color: var(--alv-accent-ink);
      }

      .action-secondary:hover,
      .action-secondary:focus,
      .btn.action-secondary:hover,
      .btn.action-secondary:focus {
        background: var(--alv-surface);
        color: var(--alv-ink);
        text-decoration: none;
      }

      /* A TONE, not a position - worn alongside -primary or -secondary,
         so a destructive button keeps whatever layout behaviour its
         position class gives it. Outlined at rest and red only on hover:
         the same bargain .icon-action-btn.icon-delete already strikes in
         every table row, one level up. */
      .action-danger,
      .btn.action-danger {
        background: var(--alv-paper);
        border: 1px solid var(--alv-bad-line);
        color: var(--alv-danger);
      }
      .action-danger:hover,
      .action-danger:focus,
      .btn.action-danger:hover,
      .btn.action-danger:focus {
        background: var(--alv-danger);
        border-color: var(--alv-danger);
        color: var(--alv-on-accent);
        text-decoration: none;
      }

      /* .back-button is what four report pages call theirs. Same thing,
         different name, so it gets the same treatment rather than a
         rewrite of four templates' markup. */
      .action-back,
      .back-button,
      .btn.action-back,
      .btn.back-button {
        background: transparent;
        border: 1px solid transparent;
        color: var(--alv-ink-soft);
      }
      .action-back:hover,
      .action-back:focus,
      .back-button:hover,
      .back-button:focus,
      .btn.action-back:hover,
      .btn.back-button:hover {
        background: var(--alv-surface);
        color: var(--alv-ink);
        text-decoration: none;
      }

      .page-action-buttons .btn:focus-visible,
      .page-action-buttons .action-back:focus-visible {
        outline: 2px solid var(--alv-accent);
        outline-offset: 2px;
      }

      /* Copied onto sixteen pages, defined in none of them twice the
         same. pointer-events matters: without it a "disabled" anchor is
         still a working link. */
      .disabled-btn {
        opacity: .6;
        cursor: not-allowed;
        pointer-events: none;
      }

      /* a switched-off primary is grey, not pale teal.
         .disabled-btn used to set only opacity/cursor/pointer-events, so a
         button's grey came entirely from Bootstrap's .btn-secondary. Once
         that class is swept off, `.action-primary.disabled-btn` alone would
         render solid teal at 60% - a washed-out button that still reads as
         clickable. The colour is half of "disabled"; it has to live here.

         Three shapes of switched-off button exist in this codebase and all
         three are covered: the class, the `disabled` attribute, and
         aria-disabled. Counted, not assumed. */
      .action-primary.disabled-btn,
      .btn.action-primary.disabled-btn,
      .btn.action-primary:disabled,
      .btn.action-primary[disabled],
      .btn.action-primary[aria-disabled="true"] {
        background: var(--alv-disabled-bg, var(--alv-surface-deep));
        border-color: var(--alv-disabled-bg, var(--alv-surface-deep));
        color: var(--alv-disabled-ink, var(--alv-ink-faint));
        box-shadow: none;
      }

      /* AND A SWITCHED-OFF DANGER. E-10, 11 Oct 2026.
         The two blocks above name action-primary and action-secondary and
         no danger tone, so `btn action-danger` carrying the disabled
         attribute kept its soft red border and its red text and took the
         whole of its dimming from Bootstrap's .btn:disabled{opacity:.65}.

         Measured on crs/submission_detail.html's Close button - off until
         XSD validation passes on every file:

             btn action-danger      + disabled   text rgb(179, 38, 30)
             btn action-secondary   + disabled   text rgb(138, 151, 157)
             btn action-primary     + disabled   text rgb(138, 151, 157)

         It was the only switched-off button in the application that was
         not grey. The colour is half of "disabled"; it belongs where the
         other two tones keep it, not in a class list on one page.

         test_disabled_state.py printed "nothing in the tree is in that
         position today" on every run while that button existed - its
         census could not open the CRS app, and its own tone list named
         only primary and secondary, so neither half of it could see.

         NOT action-back. Measured the same day: ZERO switched-off
         action-back controls exist in the tree, and a rule for nothing
         is a control that cannot fail. */
      .action-danger.disabled-btn,
      .btn.action-danger.disabled-btn,
      .btn.action-danger:disabled,
      .btn.action-danger[disabled],
      .btn.action-danger[aria-disabled="true"] {
        background: var(--alv-disabled-bg, var(--alv-surface-deep));
        border-color: var(--alv-disabled-bg, var(--alv-surface-deep));
        color: var(--alv-disabled-ink, var(--alv-ink-faint));
        box-shadow: none;
      }

      .action-more-wrapper { display: none; }

      @media screen and (max-width: 768px) {
        /* The half worth hoisting. One row, always: the primary takes the
           space, the secondaries move into the More menu, and Back keeps
           a 44px target. */
        .page-action-buttons {
          flex-direction: row;
          flex-wrap: nowrap;
          gap: 8px;
          width: 100%;
        }
        .page-action-buttons .action-primary {
          flex: 1 1 auto;
          min-width: 0;
          height: 44px;
        }
        /* A SECONDARY HIDES ONLY WHERE SOMETHING CARRIES IT - 7 Sep.
           This rule used to read `.page-action-buttons .action-secondary`,
           unconditionally, on the assumption stated three lines above: that
           the secondaries move into the More menu. Across the 63 action
           bars in this project that assumption holds 22 times and fails 11,
           and on those eleven the button simply disappeared below 768px
           with nothing carrying it - Cancel on six Add/Edit forms that have
           no Back button either, Help on three pages, and two under
           finance/.

           `:has()` rather than a marker class, because every bar that has a
           menu spells it `action-more-btn` (22 of 22), and because
           recipe_management builds its menu in JavaScript, where a
           class somebody has to remember would eventually be forgotten. */
        .page-action-buttons:has(.action-more-btn) .action-secondary {
          display: none;
        }
        /* And it has to be SIZED, which it never needed while it was always
           hidden here: its neighbours were all 38px and it came out 35.
           44px since 22 Sep, with the rest of the bar - ALV TAP TARGET. */
        .page-action-buttons .action-secondary {
          flex: 0 1 auto;
          min-width: 0;
          height: 44px;
        }
        .page-action-buttons .action-back {
          margin-left: 0;
          flex: 0 0 auto;
          width: 44px;
          height: 44px;
          padding: 0;
        }
        /* A BAR WITH NO PRIMARY HAS NOTHING TO PUSH BACK RIGHT.
           `margin-left: 0` above is correct only while a
           `.action-primary { flex: 1 1 auto }` is in the bar taking the
           slack. Fifteen bars hold a Back and NO primary, and on a phone
           every one of them packed Back hard against its neighbours:
           measured at 390px, celebration_calendar left it 316px from the
           right edge, unit_conversions_wizard 300, finance and
           notification_settings 236, occupancy_trends 220,
           passport_management 184. properties came out at 0 - because it
           HAS a primary.
           Found 27 Sep, reported as "the Back is wrong here" on one page;
           it was wrong on about thirteen. */
        .page-action-buttons:not(:has(.action-primary)) .action-back {
          margin-left: auto;
        }
        /* ===== ALV BACK LABEL v1 ===== 24 Sep 2026
           The word beside the arrow on a Back button, hidden below 768px
           so the button is a 44px square. 3.4 asks for the square; this
           is what makes room for it.

           THIS RULE USED TO BE THREE ANCESTORS DEEP -
           `.page-action-buttons .action-back .action-back-label` - and 77
           pages each wrote `.action-back-label { display: none }`,
           unscoped, to make up the difference. Measured 24 Sep: one rule
           per page, the same declaration on every one of them, and of the
           100 label elements in the system base could reach only 85. Of
           the other fifteen, fourteen sit in a .action-back that is not
           inside the bar - so deleting their copy WITHOUT widening this
           would have put the word back on a phone - and one sat on a
           .btn.back-button with no rule at all, which is why
           resolved_issues_report SHOWED THE WORD.

           The label only ever appears inside a back button. That is what
           it is scoped to now, and nothing else. .back-button comes too:
           base already settled, beside the paint rules above, that it "is
           what four report pages call theirs - same thing, different
           name", and gave it the same treatment rather than rewriting
           four templates.
           See test_back_label.py. */
        .action-back .action-back-label,
        .back-button .action-back-label { display: none; }
        /* ===== /ALV BACK LABEL v1 ===== */

        .action-more-wrapper {
          display: block;
          position: relative;
          flex: 0 0 auto;
        }
        /* Scoped to the bar, or the generic
           `.page-action-buttons .btn { border-color: transparent }` above
           wins on specificity (0,2,0 beats 0,1,0) and the More button
           becomes a white box on white. Measured, not guessed. */
        .page-action-buttons .action-more-btn {
          width: 44px;
          height: 44px;
          padding: 0;
          display: flex;
          align-items: center;
          justify-content: center;
          background: var(--alv-paper);
          border: 1px solid var(--alv-line);
          border-radius: var(--alv-radius);
          color: var(--alv-ink);
        }
        .page-action-buttons .action-more-btn:hover,
        .page-action-buttons .action-more-btn:focus {
          background: var(--alv-surface);
          color: var(--alv-ink);
        }
        /* HOW IT HIDES. base has styled this menu completely
           since the action-bar round and never said this - every page
           that works, works because the BROWSER hides [hidden] for us,
           and two pages wrote the rule out locally rather than lean on
           that. One line, and the component is whole. */
        .action-more-menu[hidden] { display: none; }

        .action-more-menu {
          position: absolute;
          top: calc(100% + 6px);
          right: 0;
          z-index: 1030;
          min-width: 200px;
          background: var(--alv-paper);
          border: 1px solid var(--alv-line);
          border-radius: var(--alv-radius);
          box-shadow: 0 8px 20px -8px rgba(16, 34, 40, .28);
          padding: 6px;
        }
        .action-more-item {
          display: flex;
          align-items: center;
          gap: 12px;
          width: 100%;
          padding: 10px 12px;
          border: 0;
          background: transparent;
          border-radius: var(--alv-radius);
          font-size: 14px;
          color: var(--alv-ink);
          text-align: left;
          text-decoration: none;
        }
        .action-more-item i {
          color: var(--alv-accent);
          width: 18px;
          text-align: center;
          flex-shrink: 0;
        }
        .action-more-item:hover,
        .action-more-item:focus {
          background: var(--alv-surface);
          color: var(--alv-ink);
          text-decoration: none;
        }
        /* The rule between two groups of menu items. Only
           recipe_management has ever drawn one, in its own copy of this
           menu, and base declared no such name - so the one page that
           wanted a divider kept the whole component locally to get it.
           Already on a token when it arrived; it only had to move. */
        .action-more-divider {
          height: 1px;
          background: var(--alv-surface-deep);
          margin: 6px 0;
        }

        .action-more-item-danger { color: var(--alv-danger); }
        .action-more-item-danger i { color: var(--alv-danger); }
      }
    