/* ===========================================================================
   Your hoard — the cart page.

   Ported from design-reference/cart.html's <style> block, scoped under
   .rpg-ml-cart. Depends on ml-chrome.css for tokens, .btn, .eyebrow and the
   container rhythm.
   ========================================================================= */

.rpg-ml-cart .pagehead{ max-width:var(--wrap); margin:auto; padding:30px var(--gutter) 6px; }
.rpg-ml-cart .pagehead h1{ font-size:clamp(30px,4vw,44px); }

.rpg-ml-cart .split{ max-width:var(--wrap); margin:auto; padding:14px var(--gutter) 40px;
  display:grid; grid-template-columns:1.6fr 1fr; gap:26px; align-items:start; }
/* WooCommerce's shortcode wraps its output in a .woocommerce div that the
   design has no place for. display:contents lets the cart form and the
   collaterals be the two grid columns directly, without asking WooCommerce for
   markup it does not emit. */
.rpg-ml-cart .split > .woocommerce{ display:contents; }
/* Notices are the fixed corner toast site-wide, but the empty-cart message
   comes through the same wrapper and has to sit in the page. */
.rpg-ml-cart .split > .woocommerce > .woocommerce-notices-wrapper:has(.cart-empty){ grid-column:1 / -1; }

.rpg-ml-cart .panel{ background:var(--card); border:1px solid var(--line); border-radius:14px;
  padding:20px; }

/* ------------------------------------------- the summary follows you ------
   Round 16: "make the right rail sticky so summary/shipping/credit stay in
   view while the item list scrolls."

   The same three conditions the Rookery's info panel documents apply, and the
   reasons are worth repeating because each one is a silent failure:

   `align-items:start` on `.split` is already set (above) and is load-bearing —
   a sticky child of a STRETCHED grid item is a full-height box with nothing
   left to travel within, which is the commonest way `position:sticky` does
   exactly nothing while looking correct in the stylesheet.

   `top` is the site header's CONDENSED height, because this page's header is
   itself sticky and ml-motion.js shrinks it on scroll. Parking at 0 slides the
   summary under the nav; parking at the full --header-h leaves a 31px gap that
   never closes, since by the time anything is pinned the header has condensed.

   And a pinned column taller than the window hides its own bottom forever —
   here that would be the Proceed button, which is the one thing on this page
   that matters. Hence the cap and `overflow:auto`. On a long cart (the case
   this feature is for) it never engages: the summary runs ~1050px and a 1080px
   window leaves 959 for it, so it pins whole and the ten line items scroll past
   it. On a short window it scrolls internally, which is a nudge inside a panel
   rather than a checkout button parked below the fold.

   Below 861px the columns stack and there is nothing to be beside; below 720px
   of viewport there is no room worth pinning. Neither case gets it. */
@media (min-width:861px) and (min-height:720px){
  .rpg-ml-cart .cart-collaterals{ position:sticky; top:calc(var(--header-condensed-h) + 16px);
    max-height:calc(100vh - var(--header-condensed-h) - 32px); overflow:auto;
    /* An internal scroll on a sticky panel is a scroll the page did not ask
       for; keep it from chaining out to the document mid-flick. */
    overscroll-behavior:contain; }
}

/* ------------------------------------------------------------ line items -- */
.rpg-ml-cart .litem{ display:flex; gap:14px; padding:14px 0; border-bottom:1px solid var(--line); }
.rpg-ml-cart .litem:first-child{ padding-top:0; }
/* THE LINE, ROUND 55. Kevin: *"The product blocks are hard to read."* Three
   changes, and the third is the one that was actually unreadable.

   The cover is 64px wide (was 70) per the brief. It keeps a book's proportion
   rather than becoming a 64x64 square: every cover in this catalogue is
   portrait, and `object-fit:cover` on a square crops the top and bottom off
   the artwork. An event ticket has no cover of its own and drew WooCommerce's
   grey placeholder — it takes its event's poster now, see the
   `woocommerce_cart_item_thumbnail` filter in includes/cart-checkout.php.

   The title goes 16 -> 15px, which sounds like the wrong direction for
   legibility and is not: the block was hard to read because a 16px serif
   title, a 12px meta line and a 12px legal block were three sizes inside one
   14px-tall stack. 15px title over a 13px meta line is two.

   The meta line goes 12 -> 13px and to the mono face, which is what every
   other "these are the facts about this item" line on the site is set in.
   `--muted` #6b6555 on the panel's `--card` #faf4e6 measures 5.29:1, so it
   clears AA at that size without changing the colour. */
.rpg-ml-cart .litem .cov{ width:64px; height:86px; border-radius:6px; overflow:hidden; flex:0 0 auto;
  background:var(--forest); }
.rpg-ml-cart .litem .cov img{ width:100%; height:100%; object-fit:cover; display:block; }
.rpg-ml-cart .litem .info{ flex:1; min-width:0; }
.rpg-ml-cart .litem .nm{ font-family:var(--serif); font-weight:600; font-size:15px; line-height:1.3; }
.rpg-ml-cart .litem .nm a{ color:inherit; }
.rpg-ml-cart .litem .nm a:hover{ color:var(--brass-ink); }
.rpg-ml-cart .litem .pdfline{ display:block; font-family:var(--mono); font-size:13px; color:var(--muted); margin-top:5px; }
.rpg-ml-cart .litem .backorder_notification{ font-family:var(--mono); font-size:13px; color:var(--brass-ink); margin-top:5px; }
.rpg-ml-cart .litem .variation{ font-family:var(--mono); font-size:13px; color:var(--muted); margin:5px 0 0; }
/* WooCommerce/Kadence style a.remove as a 24px round "x" button. Here it is a
   text link that says "remove", so the fixed box has to go or the word breaks
   one character per line. */
.rpg-ml-cart .litem a.remove.rm{ display:inline-block; width:auto; height:auto; min-width:0;
  margin-top:6px; padding:0; border:0; border-radius:0; background:none; line-height:1.4;
  font-size:12px; font-weight:400; white-space:nowrap; cursor:pointer;
  /* WooCommerce ships `a.remove{color:red!important}` — the only way past it
     without out-specifying the whole cascade is to match it. */
  color:var(--muted)!important; }
.rpg-ml-cart .litem a.remove.rm:hover{ color:var(--wine)!important; background:none; }
/* The price, right-aligned — it already was; stated with the rest of the line
   so the four properties the brief lists are readable in one place. */
.rpg-ml-cart .litem-right{ text-align:right; flex:0 0 auto; }
.rpg-ml-cart .litem-right .price{ margin-top:6px; font-family:var(--serif); font-size:15px; font-weight:700; }

/* WooCommerce's quantity input, dressed as the reference's stepper. Kadence
   adds its own -/+ buttons to .quantity; both are styled here rather than
   adding a third pair (see rpg-shop/CLAUDE.md — a second pair rendered
   "- - 1 + +" on the PDP). */
.rpg-ml-cart .quantity{ display:inline-flex; align-items:center; border:1px solid var(--line);
  border-radius:7px; overflow:hidden; background:var(--paper); }
.rpg-ml-cart .quantity input.qty{ width:42px; text-align:center; font-weight:700; border:0;
  background:none; padding:7px 0; font-size:14px; -moz-appearance:textfield; }
.rpg-ml-cart .quantity input.qty::-webkit-outer-spin-button,
.rpg-ml-cart .quantity input.qty::-webkit-inner-spin-button{ -webkit-appearance:none; margin:0; }
.rpg-ml-cart .quantity input.minus,
.rpg-ml-cart .quantity input.plus,
.rpg-ml-cart .quantity button{ width:30px; height:32px; min-height:0; font-size:15px; border:0;
  background:none; color:var(--ink); cursor:pointer; padding:0; border-radius:0; }
.rpg-ml-cart .quantity input.minus:hover,
.rpg-ml-cart .quantity input.plus:hover,
.rpg-ml-cart .quantity button:hover{ background:rgba(0,0,0,.05); }
.rpg-ml-cart .quantity .screen-reader-text{ position:absolute; width:1px; height:1px;
  overflow:hidden; clip:rect(0 0 0 0); }

/* -------------------------------------------------------------- actions --- */
.rpg-ml-cart .cartactions{ display:flex; flex-wrap:wrap; gap:10px; align-items:center;
  padding-top:16px; }
.rpg-ml-cart .coupon{ display:flex; gap:8px; flex:1 1 260px; min-width:0; }
.rpg-ml-cart .coupon input{ flex:1; min-width:0; border:1px solid var(--line); border-radius:7px;
  padding:10px 12px; font-size:16px; background:var(--paper); color:var(--ink); }
.rpg-ml-cart .keepwandering{ margin-top:14px; }

/* ---------------------------------------------------------- the chest ----- */
.rpg-ml-cart .chestwrap{ display:flex; align-items:center; gap:14px;
  background:linear-gradient(120deg,#243a2c,#14261d); color:var(--text-inverse);
  border-radius:14px; padding:16px 18px; position:relative; overflow:hidden;
  margin-bottom:14px; }
.rpg-ml-cart .chest{ font-size:34px; transition:transform .4s cubic-bezier(.2,.7,.2,1); }
.rpg-ml-cart .chestwrap.is-open .chest{ animation:rpgchest .5s cubic-bezier(.2,.7,.2,1); }
@keyframes rpgchest{ 40%{ transform:scale(1.25) rotate(-6deg) } 100%{ transform:scale(1) } }
.rpg-ml-cart .chestwrap .msg{ flex:1; font-size:13.5px; min-width:0; }
.rpg-ml-cart .chestwrap .msg b{ color:var(--gold-hi); }
.rpg-ml-cart .chestwrap .msg .amount,
.rpg-ml-cart .chestwrap .msg .woocommerce-Price-amount{ color:var(--gold-hi); font-weight:700; }
.rpg-ml-cart .fstrack{ height:9px; background:rgba(255,255,255,.16); border-radius:6px;
  overflow:hidden; margin-top:8px; }
.rpg-ml-cart .fsbar{ height:100%; background:linear-gradient(90deg,var(--gold),var(--gold-hi));
  transition:width .4s; }

/* --------------------------------------------- the delayed-items panel ----
   rpg-order-management's cart notice, repainted (round 16). Three notes:

   1. It could not be repainted at all before rpg-order-management 1.8.0 — every
      colour, margin and font-size was an inline `style=` attribute, which no
      stylesheet can outrank without !important on a dozen properties. That
      plugin carries classes and its own baseline sheet now, and this is an
      override of rules rather than a fight with attributes.
   2. It is the ONE thing on the page that speaks about time rather than money,
      so it takes the brass the site uses for "pay attention" and not the wine
      it uses for "something is wrong" — a pre-order is good news arriving late,
      not an error.
   3. It sits directly above the chest, and the chest is a dark green block. A
      second heavy block above it would give the column two lids; this one is a
      parchment card with a brass rule down its edge, so the eye reaches the
      chest through it rather than over it. */
.rpg-ml-cart .rpg-bo-panel{ background:var(--paper); border:1px solid var(--line);
  border-left:3px solid var(--brass); border-radius:12px; padding:var(--sp-4);
  margin:0 0 var(--sp-4); }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-head{ display:flex; align-items:baseline; gap:var(--sp-2);
  margin:0 0 var(--sp-3); font-family:var(--serif); font-weight:600; font-size:15.5px;
  line-height:1.25; color:var(--ink); }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-glyph{ margin:0; font-size:14px; flex:0 0 auto; }

.rpg-ml-cart .rpg-bo-panel .rpg-bo-items{ margin:0 0 var(--sp-3); }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-items li{ margin:0 0 var(--sp-2); padding:0 0 var(--sp-2);
  border-bottom:1px solid var(--line); }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-items li:last-child{ margin-bottom:0; padding-bottom:0;
  border-bottom:0; }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-name{ font-family:var(--serif); font-weight:600;
  font-size:14px; line-height:1.3; color:var(--ink); }
/* The kind is the label, not the item: mono small-caps, the same voice the
   Guild panel's heading and the summary's asides use. */
.rpg-ml-cart .rpg-bo-panel .rpg-bo-kind{ font-family:var(--mono); font-size:10.5px;
  letter-spacing:.06em; text-transform:uppercase; font-weight:700; color:var(--brass-ink);
  margin-top:3px; }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-note{ font-size:13px; color:var(--muted); }

.rpg-ml-cart .rpg-bo-panel .rpg-bo-choice{ background:var(--card); border:1px solid var(--line);
  border-radius:8px; padding:var(--sp-3); font-size:13px; }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-choice-head{ font-family:var(--mono); font-size:10.5px;
  letter-spacing:.06em; text-transform:uppercase; font-weight:700; color:var(--muted);
  margin:0 0 var(--sp-2); }
/* The two options are a choice, not prose — the bullet adds nothing and costs
   20px of a 439px column, which is what pushed the "(€ 5,74 + € 5,74 pre-order)"
   aside onto its own wrapped line. */
.rpg-ml-cart .rpg-bo-panel .rpg-bo-choice ul{ list-style:none; margin:0; padding:0;
  color:var(--ink); }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-choice li + li{ margin-top:var(--sp-2);
  padding-top:var(--sp-2); border-top:1px solid var(--line); }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-choice li strong{ font-weight:600; }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-free{ color:#3d7d1f; font-weight:700; }
.rpg-ml-cart .rpg-bo-panel .rpg-bo-sum{ display:block; font-size:11.5px; color:var(--muted);
  margin-top:2px; }
.rpg-ml-cart .rpg-bo-panel .woocommerce-Price-amount{ font-weight:700; }

/* --------------------------------------------------------- the summary ---- */
.rpg-ml-cart .cart_totals h3{ font-size:17px; margin-bottom:12px; }
.rpg-ml-cart .sumrow{ display:flex; justify-content:space-between; gap:12px; padding:7px 0;
  font-size:14px; }
.rpg-ml-cart .sumrow.tot{ border-top:1px solid var(--line); margin-top:6px; padding-top:12px;
  font-weight:700; font-size:17px; font-family:var(--serif); }
.rpg-ml-cart .sumrow small{ display:block; font-size:11px; color:var(--muted); font-weight:400; }

/* The Guild's credit panel, now that rpg-guild 1.19.0 renders it as a block
   here too (rpg_guild_credit_toggle_as_row, declared false by ml-cart.php).
   It used to arrive as a <tr> into a summary made of divs, so the browser threw
   the wrapper away and kept the toggle — which is why the control has been
   sitting in this column with no heading since the cart was redesigned. */
.rpg-ml-cart .rpg-guild-credit-row--block{ display:block; margin:10px 0;
  padding:11px 13px; background:var(--paper); border:1px solid var(--line);
  border-radius:10px; }
.rpg-ml-cart .rpg-guild-credit-row__title{ font-family:var(--mono); font-size:10.5px;
  letter-spacing:.06em; text-transform:uppercase; color:var(--muted); margin:0 0 8px;
  font-weight:700; }

/* The shipping section is WooCommerce's own table (see cart-totals.php for
   why it stays one); this makes its rows read as .sumrow siblings. */
/* The row is one label and a stack of methods; side by side in a 439px column
   the method names wrapped to one word per line. Stacked, it reads. */
.rpg-ml-cart .shiprows table{ width:100%; border:0; margin:0; table-layout:auto; }
.rpg-ml-cart .shiprows tr{ display:block; padding:7px 0; }
.rpg-ml-cart .shiprows th,
.rpg-ml-cart .shiprows td{ display:block; width:auto; border:0; padding:0; font-size:14px;
  font-weight:400; text-align:left; }
.rpg-ml-cart .shiprows th{ margin-bottom:4px; }
.rpg-ml-cart .shiprows td::before{ content:none; } /* shop_table_responsive data-title */
.rpg-ml-cart .shiprows small,
.rpg-ml-cart .shiprows .rpg-delivery-est{ display:block; font-size:12px; color:var(--muted);
  margin-top:2px; }
.rpg-ml-cart .shiprows ul#shipping_method{ list-style:none; margin:0; padding:0; text-align:left; }
.rpg-ml-cart .shiprows ul#shipping_method li{ margin:0 0 6px; display:flex; gap:8px;
  align-items:flex-start; }
.rpg-ml-cart .shiprows ul#shipping_method label{ font-size:13.5px; }
.rpg-ml-cart .shiprows .woocommerce-shipping-destination{ font-size:12px; color:var(--muted);
  text-align:left; margin-top:6px; }

.rpg-ml-cart .loyalty{ background:#eef6e7; border:1px solid #cfe3bd; border-radius:8px;
  padding:10px 14px; font-size:13px; margin:12px 0; }
.rpg-ml-cart .loyalty b{ color:#3d7d1f; }
.rpg-ml-cart .bm{ background:#fbf3dd; border:1px solid #ecdcae; border-radius:8px;
  padding:10px 14px; font-size:13px; margin-top:12px; }

/* WooCommerce's own "Proceed to checkout" button, wearing the gold. */
.rpg-ml-cart .wc-proceed-to-checkout{ padding:0; }
.rpg-ml-cart .wc-proceed-to-checkout .checkout-button{ display:inline-flex; align-items:center;
  justify-content:center; gap:9px; width:100%; font-weight:700; font-size:14px; padding:14px 22px;
  border-radius:8px; min-height:46px; margin:4px 0 0;
  background:linear-gradient(var(--gold-hi),#c19338); color:#231a07;
  box-shadow:0 6px 18px rgba(150,110,40,.3); border:0; }
.rpg-ml-cart .wc-proceed-to-checkout .checkout-button:hover{ filter:brightness(1.05);
  transform:translateY(-1px); }

/* ----------------------------------------------------- express payment ----
   The PayPal smart button, kept from the Blocks cart (FEEDBACK round 7).

   `.ppc-button-wrapper` and everything in it is drawn by WooCommerce PayPal
   Payments, on `woocommerce_proceed_to_checkout` at priority 20 — i.e. markup
   this repo does not own and cannot version. So these rules set spacing and a
   width and deliberately touch neither the button's colours nor its shape:
   PayPal's brand rules require their SDK's own rendering, and it is painted
   into an <iframe> anyway, where our CSS does not reach.

   `.express-sep` is ours but lives INSIDE that wrapper — it is printed on
   ppcp's `ppcp_start_button_wrapper_ppcp_gateway` action, which is the only
   anchor that lands between the gold CTA and the PayPal button (both sit at
   priority 20, so no priority separates them — see ml-cart.php). Hence the
   top margin is on the wrapper and not on the divider: the gap belongs above
   the whole express group. */
.rpg-ml-cart .express-sep{ display:flex; align-items:center; gap:12px;
  margin:0 0 12px; color:var(--muted); font-size:12px; letter-spacing:.04em;
  text-transform:lowercase; }
.rpg-ml-cart .express-sep::before,
.rpg-ml-cart .express-sep::after{ content:""; flex:1 1 auto; height:1px;
  background:linear-gradient(90deg,transparent,rgba(120,95,55,.38),transparent); }
.rpg-ml-cart .express-sep span{ flex:0 0 auto; }

.rpg-ml-cart .ppc-button-wrapper{ margin:16px 0 0; }
/* ppcp's SDK sizes the button to its container, so the width comes from here
   and the height from PayPal. */
.rpg-ml-cart #ppc-button-ppcp-gateway{ width:100%; min-height:48px; }
/* The Pay Later line ("pay in 3 instalments") sits between the divider and the
   button; left-aligned at 12px on live, per the ppcp settings read 2026-09-01. */
.rpg-ml-cart .ppcp-messages,
.rpg-ml-cart .wc-block-checkout__payment-method-messaging{ margin:0 0 10px; }

/* ------------------------------------------------------------- empty ------ */
.rpg-ml-cart .cart-empty{ text-align:center; }
.rpg-ml-cart .return-to-shop{ text-align:center; }

@media (max-width:860px){
  .rpg-ml-cart .split{ grid-template-columns:1fr; }
}
@media (max-width:480px){
  /* At this width the cover, the text and the stepper cannot share a row
     without the price wrapping to one character per line. */
  .rpg-ml-cart .litem{ flex-wrap:wrap; }
  .rpg-ml-cart .litem-right{ width:100%; display:flex; justify-content:space-between;
    align-items:center; text-align:left; }
  .rpg-ml-cart .litem-right .price{ margin-top:0; }
}
@media (prefers-reduced-motion:reduce){
  .rpg-ml-cart .chestwrap.is-open .chest{ animation:none; }
  .rpg-ml-cart .fsbar{ transition:none; }
}

/* Round 11: the discounted line. The block itself is shared chrome — see
   rpg-site-styles/assets/ml-chrome.css, "THE DISCOUNT" — and its `--line`
   variant is built by `rpg_ml_price_cart_subtotal()` in rpg-shop, because this
   column prints a LINE SUBTOTAL and never touches `get_price_html()`. All the
   cart adds is the column's own alignment. */
.rpg-ml-cart .litem-right .price .mlpr{ align-items:baseline; justify-content:flex-end;
  text-align:right; gap:.35em; }

/* =========================================================================
   THE MIMIC (round 15)

   Kevin: "The cart page gets a mimic chest that BITES when clicked (lid snaps,
   teeth, maybe a tongue; brief rattle then settles; reduced-motion static).
   Placed as decoration near the summary — never blocking controls."

   Recoloured to the shop's palette, as asked: wine/leather body, brass bands,
   paper-ivory teeth, wine-pink tongue.

   THE HINGE IS THE BODY'S TOP-LEFT CORNER, so the mouth opens as a wedge
   widening to the right rather than the lid sliding off the top. It is written
   in VIEW-BOX units (`transform-box:view-box; transform-origin:44px 78px`) and
   not as a percentage of the lid's own box, because the lid group contains the
   upper fangs — a percentage origin moves the hinge every time a tooth gets
   longer, which is a bug you only see as the lid drifting sideways.
   ========================================================================= */

/* WHERE IT SITS (round 16 moved it)
   It used to be centred in the summary column under the checkout button, where
   Kevin found it "crowds the layout" — and the screenshot agrees for a reason
   the code could not show: on a short cart the summary column runs out before
   the item panel does, so a 172px chest centred at the bottom of it stands
   alone in a large pale rectangle. Centred and alone is a mascot. Kevin asked
   for "a discovered creature, not an obstacle".

   So it is the last thing inside the ITEM PANEL now, at the right, half over
   the panel's own bottom edge — a chest climbing out of the shelf you have been
   loading. The overhang is the whole gag, and it is safe there because nothing
   is below the item panel in that column at any width above the mobile stack.

   NEVER OVER A CONTROL. The bottom of that panel holds the coupon field, Apply,
   Update the hoard and the "keep wandering" link, all of which are left-aligned
   or full-width; the chest is right-aligned and, below 860px where the columns
   stack, it stops overhanging entirely (see the mobile block) because the
   summary column's first card would be underneath it. */
.rpg-ml-cart .mimicwrap{ display:flex; justify-content:flex-end; margin:6px -4px -46px 0;
  position:relative; }

/* A <button> so a keyboard can reach the joke, stripped of every button
   affordance so it does not read as a control the checkout needs. */
.rpg-ml-cart .mimic{ display:block; width:124px; max-width:40%; padding:0; margin:0;
  border:0; background:none; cursor:pointer; line-height:0; -webkit-tap-highlight-color:transparent; }
.rpg-ml-cart .mimic:focus-visible{ outline:2px solid var(--gold-hi); outline-offset:6px;
  border-radius:10px; }
.rpg-ml-cart .mimic svg{ width:100%; height:auto; overflow:visible; }

/* ---- the palette --------------------------------------------------------- */
.rpg-ml-cart .mimic .mm-shell{ fill:#7a3a2e; }                 /* wine leather */
.rpg-ml-cart .mimic .mm-body .mm-shell{ fill:#6d3428; }        /* body a shade deeper than the lid */
.rpg-ml-cart .mimic .mm-planks path{ stroke:#54251c; stroke-width:2.4; fill:none; opacity:.65; }
.rpg-ml-cart .mimic .mm-lidbands path{ stroke:#54251c; stroke-width:2.2; fill:none; opacity:.5; }
.rpg-ml-cart .mimic .mm-band{ fill:#c19338; }
.rpg-ml-cart .mimic .mm-lidband{ fill:none; stroke:#c19338; stroke-width:7; stroke-linejoin:round; }
.rpg-ml-cart .mimic .mm-caps path{ fill:#b8873c; }
.rpg-ml-cart .mimic .mm-lock{ fill:#e8cd86; stroke:#8a6320; stroke-width:1.6; }
.rpg-ml-cart .mimic .mm-feet rect{ fill:#54251c; }
.rpg-ml-cart .mimic .mm-maw{ fill:#2a0f0c; }
.rpg-ml-cart .mimic .mm-teeth path{ fill:#f4ead2; }            /* paper ivory */
.rpg-ml-cart .mimic .mm-tongue path{ fill:#c8586b; }           /* wine-pink */
.rpg-ml-cart .mimic .mm-tongue-line{ fill:none; stroke:#a8404f; stroke-width:2.4;
  stroke-linecap:round; opacity:.7; }
.rpg-ml-cart .mimic .mm-drip{ fill:#e7f0f4; opacity:.85; }
.rpg-ml-cart .mimic .mm-eye{ fill:#f6efdd; stroke:#54251c; stroke-width:2; }
.rpg-ml-cart .mimic .mm-pupil{ fill:#2a1810; }
.rpg-ml-cart .mimic .mm-glint{ fill:#fff; opacity:.9; }
.rpg-ml-cart .mimic .mm-coins ellipse{ fill:#c19338; opacity:.55; }

/* ---- closed and innocent ------------------------------------------------- */
/* Nothing with teeth in it is visible until it bites. A chest showing its
   fangs is a monster, and a monster is not a surprise. */
.rpg-ml-cart .mimic .mm-open{ opacity:0; }
.rpg-ml-cart .mimic .mm-tongue,
.rpg-ml-cart .mimic .mm-drip,
.rpg-ml-cart .mimic .mm-coins,
.rpg-ml-cart .mimic .mm-eyes{ transform-box:fill-box; }
.rpg-ml-cart .mimic .mm-lid{ transform-box:view-box; transform-origin:44px 78px; }

/* Breathing: almost imperceptible, which is the point — you notice it a second
   after you have decided the chest is ordinary. */
.rpg-ml-cart .mimic svg{ animation:mm-breathe 4.6s ease-in-out infinite; }
@keyframes mm-breathe{
  0%,100%{ transform:translateY(0) scaleY(1); }
  50%    { transform:translateY(-1.2px) scaleY(1.012); } }

/* A rare blink. 11s so it is never the thing you are waiting for. */
.rpg-ml-cart .mimic .mm-eyes{ transform-origin:50% 50%;
  animation:mm-blink 11s steps(1,end) infinite; }
@keyframes mm-blink{
  0%,96%,100%{ transform:scaleY(1); }
  97%,98%    { transform:scaleY(.1); }
  99%        { transform:scaleY(1); } }

/* ---- the bite ------------------------------------------------------------ */
/* Chomp-chomp, not one chomp: a single snap reads as a lid falling shut. The
   second, smaller one is what makes it a bite. */
/* `animation` on a later rule REPLACES the earlier one rather than adding to
   it, so the two mouth parts that also move say both of their animations in
   one declaration. The tongue lolling with no opacity is an invisible tongue. */
.rpg-ml-cart .mimic.is-biting .mm-open{ animation:mm-reveal 1.5s linear forwards; }
.rpg-ml-cart .mimic.is-biting .mm-lid{ animation:mm-chomp 1.5s cubic-bezier(.3,.8,.3,1) forwards; }
.rpg-ml-cart .mimic.is-biting .mm-tongue{
  animation:mm-reveal 1.5s linear forwards, mm-loll 1.5s cubic-bezier(.3,.8,.3,1) forwards; }
/* The drool owns its own opacity — it swells, falls and is gone well before
   the mouth closes, so mm-reveal would only fight it. */
.rpg-ml-cart .mimic.is-biting .mm-drip{ animation:mm-drool 1.5s ease-in forwards; }
.rpg-ml-cart .mimic.is-biting .mm-coins{ animation:mm-rattle .55s ease-out; }

@keyframes mm-chomp{
  0%  { transform:rotate(0deg); }
  10% { transform:rotate(-34deg); }   /* SNAP open */
  26% { transform:rotate(-2deg); }    /* bite */
  38% { transform:rotate(-24deg); }   /* and again, smaller */
  52% { transform:rotate(-1deg); }
  64% { transform:rotate(-9deg); }    /* one last little chew */
  74% { transform:rotate(0deg); }
  100%{ transform:rotate(0deg); }     /* …a perfectly ordinary chest */ }

/* The teeth and the maw are only there while the mouth is, and they go out
   BEFORE the lid lands, not after: the maw is a dark band across the chest's
   own face, so a fade that outlasts the lid leaves a black stripe on a closed
   chest. Out by 76%, lid down at 74%. */
@keyframes mm-reveal{
  0%  { opacity:0; } 6%{ opacity:1; } 70%{ opacity:1; } 76%{ opacity:0; } 100%{ opacity:0; } }

@keyframes mm-loll{
  0%  { transform:translateY(10px) rotate(0deg); }
  14% { transform:translateY(0) rotate(-6deg); }
  30% { transform:translateY(4px) rotate(5deg); }
  46% { transform:translateY(0) rotate(-4deg); }
  70% { transform:translateY(2px) rotate(2deg); }
  86% { transform:translateY(12px) rotate(0deg); } }

/* The drop has to have FALLEN before the lid lands, not while: a bead of drool
   still fading over a shut chest is the one frame that gives the whole thing
   away. Gone by 68%, lid down at 74%. */
@keyframes mm-drool{
  0%,20%{ transform:translateY(0) scale(.4); opacity:0; }
  34%   { transform:translateY(0) scale(1); opacity:.9; }
  56%   { transform:translateY(14px) scale(.85); opacity:.7; }
  68%   { transform:translateY(24px) scale(.5); opacity:0; }
  100%  { opacity:0; } }

@keyframes mm-rattle{
  0%,100%{ transform:translate(0,0); }
  20%    { transform:translate(-2px,-2px) rotate(-3deg); }
  45%    { transform:translate(2px,-1px) rotate(2deg); }
  70%    { transform:translate(-1px,1px) rotate(-1deg); } }

/* ---- reduced motion ------------------------------------------------------ */
/* "Reduced-motion: static closed chest with eyes." Exactly that — and the
   button stops being a button, because a control that cannot do anything is
   worse than no control. */
@media (prefers-reduced-motion: reduce){
  .rpg-ml-cart .mimic{ cursor:default; }
  .rpg-ml-cart .mimic svg,
  .rpg-ml-cart .mimic .mm-eyes,
  .rpg-ml-cart .mimic.is-biting .mm-open,
  .rpg-ml-cart .mimic.is-biting .mm-lid,
  .rpg-ml-cart .mimic.is-biting .mm-tongue,
  .rpg-ml-cart .mimic.is-biting .mm-drip,
  .rpg-ml-cart .mimic.is-biting .mm-coins{ animation:none; }
  .rpg-ml-cart .mimic .mm-open{ opacity:0; }
  .rpg-ml-cart .mimic .mm-lid{ transform:none; }
}

/* On a phone the two columns stack, so the summary's first card is directly
   under the item panel and the overhang would land on it. The chest sits inside
   the panel there instead — still bottom-right, still an aside, just not
   leaning out over something. */
@media (max-width:860px){
  .rpg-ml-cart .mimicwrap{ margin:10px -4px 0 0; }
  .rpg-ml-cart .mimic{ width:104px; }
}

/* =====================================================================
   ROUND 56 — THE CART ON A PHONE (docs/deploys/briefs/MOBILE-SWEEP.md §8)
   ===================================================================== */
/* The mimic stays a desktop pleasure: at 360 it was 114px of chest (plus its
   negative-margin overhang) between the last line and the summary, and a
   phone scrolls past it to reach the total. */
@media (max-width:480px){
  .rpg-ml-cart .mimicwrap{ display:none; }
}
/* Round 56 §9. "Proceed to checkout" was #fbf7ee on the gold gradient — 1.79:1.
   The house's gold-button ink, as every other gold button on the site uses. */
.rpg-ml-cart .wc-proceed-to-checkout .checkout-button{ color:#231a07; }
/* rpg-order-management's free-shipping bar in the summary prints #f57c00 and
   #888 as inline styles (2.47 and 3.23:1 on the card); scoped overrides, since
   the bar's markup belongs to that plugin. */
.rpg-ml-cart [style*="color: #f57c00"]{ color:#9a4a00 !important; }
.rpg-ml-cart [style*="color: #888"]{ color:#5c5645 !important; }
.rpg-ml-cart .wc-proceed-to-checkout .checkout-button:focus-visible{ outline:3px solid var(--focus); outline-offset:3px; }
/* …and past WooCommerce's `.woocommerce a.button.alt` (0,3,1), which painted
   the label in the theme's button white. */
.rpg-ml-cart .wc-proceed-to-checkout a.checkout-button.button{ color:#231a07; }

/* =====================================================================
   1.91.0 — "PAIRS WELL WITH" (ml-cart.php)
   Inside the cart form, under the lines: a quiet aside, not a shelf. The
   heading is the PDP rail's mono eyebrow; the cards are the house `.prod`
   card a step smaller, as in the PDP's buy column (ml-product.css), with
   the keeper's verdict dropped because it is what makes a card tall.
   Width is the COLUMN's, not the viewport's — the form is 1.6fr of the split
   on a desktop and the full width on a phone — so the 2-up → 4-up switch is
   a container query on the rail itself: four across only when each card
   still gets ~140px.
   ===================================================================== */
.rpg-ml-cart .cartpairs{ container-type:inline-size; margin:18px 0 0; padding-top:16px;
  border-top:1px solid var(--line); }
.rpg-ml-cart .cartpairsh{ font-family:var(--mono); font-size:11px; letter-spacing:.1em;
  text-transform:uppercase; color:var(--muted); font-weight:700; margin:0 0 12px; }
.rpg-ml-cart .cartpairsrail{ display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
/* Two-up, it is ONE row of two: a second row put ~360px of suggestions
   between the last line and the total on a phone, and the total is what
   that phone scrolled down for. */
.rpg-ml-cart .cartpairsrail > .prod:nth-child(n+3){ display:none; }
@container (min-width:600px){
  .rpg-ml-cart .cartpairsrail{ grid-template-columns:repeat(4,minmax(0,1fr)); }
  .rpg-ml-cart .cartpairsrail > .prod:nth-child(n+3){ display:flex; }
}
.rpg-ml-cart .cartpairsrail .prod .pb{ padding:10px 11px 12px; }
.rpg-ml-cart .cartpairsrail .prod .pb h3{ font-size:14px; line-height:1.25; }
.rpg-ml-cart .cartpairsrail .prod .pb .price{ font-size:14px; }
.rpg-ml-cart .cartpairsrail .prod .verdict,
.rpg-ml-cart .cartpairsrail .prod .vby{ display:none; }
