/* European Food Partner (EuFoPa) — white-first, product-led, marketplace-grade.
   Old --ek-* variable names are kept as aliases so existing pages keep working
   while components migrate to the new --bg / --ink / --red set. */
@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Manrope:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  /* ---- EuFoPa primary token set ---- */
  --ink:       #16140F;
  --ink-soft:  #2C2A24;
  --text:      #2A2824;
  --text-2:    #54514A;
  --muted:     #6B6961;  /* bumped from #7C7A72 to 4.55:1 contrast on white (WCAG AA) */
  --muted-2:   #8A8881;  /* bumped from #A1A09A so secondary muted clears AA */

  --bg:        #FFFFFF;
  --bg-2:      #F6F7F9;
  --bg-3:      #EEF0F3;
  --wash:      #F2F4F6;

  --line:      #E7E9EE;
  --line-2:    #D9DCE3;
  --line-3:    #C7CBD4;

  /* Brand accent — EFP rebrand is blue + gold. The --red-* variable names are
     kept for backwards compatibility but now resolve to the new EFP blue. */
  --red:       #1C63D6;
  --red-deep:  #1450B0;
  --red-pale:  #EAF1FC;
  --red-border:#C6DAF7;

  /* Yellow companion ("yellow-blue identity" from brand.css) */
  --gold:        #F4B400;
  --gold-deep:   #C98A00;
  --gold-pale:   #FEF4D6;
  --gold-border: #F2DC9A;

  --green:        #2A6E48;  /* 4.5:1 against pale-green pill */
  --green-pale:   #E7F3EC;
  --green-border: #BFE0CC;
  --amber:        #8B5912;  /* 4.5:1+ on the amber-pale pill */
  --amber-pale:   #FAF0DC;
  --amber-border: #ECD3A4;
  --quote:        #3A6E8F;
  --quote-pale:   #E8F1F7;
  --quote-border: #BFD8E8;
  /* Olive accent — used for outline category icons (matches uploaded SVG set
     manifest.json stroke #59603D). */
  --olive:        #59603D;
  --gray:         #6B6A64;
  --gray-pale:    #EEF0F2;

  --cta:       #1C63D6;
  --cta-hover: #1450B0;
  --cta-text:  #FFFFFF;

  --serif: 'DM Serif Display', Georgia, serif;
  --sans:  'Manrope', -apple-system, system-ui, sans-serif;
  --mono:  'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  --r:    8px;
  --r-sm: 6px;
  --r-lg: 14px;

  --shadow-card: 0 1px 2px rgba(20,18,12,0.04), 0 1px 0 rgba(20,18,12,0.02);
  --shadow-pop:  0 12px 32px -8px rgba(20,18,12,0.22), 0 2px 8px rgba(20,18,12,0.08);
  --maxw: 1320px;

  /* ---- legacy --ek-* aliases (do not remove; old pages still read these) ---- */
  --ek-ink:        var(--ink);
  --ek-graphite:   var(--ink-soft);
  --ek-text:       var(--text);
  --ek-text-2:     var(--text-2);
  --ek-muted:      var(--muted);
  --ek-muted-2:    var(--muted-2);

  --ek-paper:      var(--bg);
  --ek-paper-2:    var(--bg-2);
  --ek-cream:      var(--bg-2);
  --ek-cream-2:    var(--bg-3);
  --ek-panel:      var(--wash);
  --ek-panel-2:    var(--bg-3);

  --ek-border:     var(--line);
  --ek-border-2:   var(--line-2);
  --ek-line:       var(--line-3);

  --ek-red:        var(--red);
  --ek-red-2:      var(--red-deep);
  --ek-red-pale:   var(--red-pale);
  --ek-red-border: var(--red-border);
  --ek-signal:     var(--red);

  --ek-sage:       var(--green);
  --ek-sage-pale:  var(--green-pale);
  --ek-olive:      var(--green);
  --ek-olive-pale: var(--green-pale);
  --ek-sky:        var(--quote);
  --ek-sky-pale:   var(--quote-pale);
  --ek-amber:      var(--amber);
  --ek-amber-pale: var(--amber-pale);
  --ek-success:    var(--green);
  --ek-success-pale: var(--green-pale);
  --ek-clay:       #B16A3A;
  --ek-clay-pale:  #F1DEC8;

  --ek-serif:      var(--serif);
  --ek-sans:       var(--sans);
  --ek-mono:       var(--mono);

  --ek-radius:     var(--r);
  --ek-radius-lg:  var(--r-lg);
}

.ek {
  font-family: var(--ek-sans);
  color: var(--ek-text);
  font-size: 14px;
  line-height: 1.55;
  font-feature-settings: "tnum" on;
  -webkit-font-smoothing: antialiased;
  background: var(--ek-paper);
}
.ek *, .ek *::before, .ek *::after { box-sizing: border-box; }
.ek button { font-family: inherit; }

.ek-mono { font-family: var(--ek-mono); font-feature-settings: "tnum" on, "zero" on; }
.ek-serif { font-family: var(--ek-serif); font-weight: 400; }

.ek-eyebrow {
  font-family: var(--ek-mono);
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ek-muted);
  font-weight: 500;
}

.ek-h1, .ek-h2, .ek-h3 { font-family: var(--ek-serif); font-weight: 400; letter-spacing: -0.005em; }
.ek-h1 { font-size: 80px; line-height: 1.0; }
.ek-h2 { font-size: 44px; line-height: 1.1; }
.ek-h3 { font-size: 26px; line-height: 1.2; }
.ek-h4 { font-family: var(--ek-sans); font-size: 16px; line-height: 1.3; font-weight: 600; }

/* Italic accent — pairs beautifully with DM Serif Display upright */
.ek-italic { font-style: italic; }

/* Photo placeholder: warm-toned, layered, mimics a landscape photograph */
.ek-photo {
  position: relative;
  background:
    radial-gradient(120% 80% at 50% 100%, rgba(122,111,94,0.18) 0%, transparent 60%),
    linear-gradient(180deg,
      #DCE3E8 0%,
      #EAE2CC 38%,
      #C9C0A0 62%,
      #8E8467 100%);
  border: 1px solid var(--ek-border);
  border-radius: var(--ek-radius-lg);
  display: flex; align-items: flex-end; justify-content: flex-start;
  overflow: hidden;
  color: rgba(255,255,255,0.92);
  font-family: var(--ek-mono);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.ek-photo::before {
  /* faint texture */
  content: '';
  position: absolute; inset: 0;
  background:
    repeating-linear-gradient(115deg, transparent 0 18px, rgba(255,255,255,0.04) 18px 19px),
    repeating-linear-gradient(75deg, transparent 0 30px, rgba(0,0,0,0.04) 30px 31px);
  pointer-events: none;
}
.ek-photo > .label {
  position: relative;
  background: rgba(42,38,32,0.62);
  backdrop-filter: blur(4px);
  padding: 7px 12px;
  margin: 16px;
  border-radius: 999px;
  color: rgba(255,255,255,0.95);
  z-index: 2;
}

/* When an <img> sits inside .ek-photo, it covers the gradient placeholder.
   We also blank the parent's background + border so no tint leaks at the
   edges (e.g. the light-blue stop in --mountain or the --blue category tint). */
.ek-photo--has-image {
  background: none !important;
  border: none !important;
}
.ek-photo > picture,
.ek-photo > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}
.ek-photo > picture > img,
.ek-photo > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.ek-photo--has-image::before { display: none; }

/* Mountain-silhouette variant — adds simple triangle ranges via gradient stops */
.ek-photo--mountain {
  background:
    /* foreground road shadow */
    radial-gradient(70% 30% at 50% 102%, rgba(58,46,32,0.35) 0%, transparent 70%),
    /* near mountains (clay/olive) */
    conic-gradient(from 220deg at 18% 76%, transparent 0deg 28deg, rgba(107,122,61,0.55) 28deg 32deg, transparent 32deg 360deg),
    /* far mountains (sky-blue) */
    conic-gradient(from 220deg at 62% 70%, transparent 0deg 30deg, rgba(110,137,161,0.45) 30deg 34deg, transparent 34deg 360deg),
    linear-gradient(180deg,
      #C9D6DE 0%,
      #E4D6B2 36%,
      #B19868 70%,
      #6F5E40 100%);
}

/* Striped fallback for product placeholders */
.ek-img {
  position: relative;
  background:
    repeating-linear-gradient(135deg,
      var(--ek-cream) 0 14px,
      var(--ek-cream-2) 14px 28px);
  border: 1px solid var(--ek-border);
  border-radius: var(--ek-radius);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--ek-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ek-muted);
}
.ek-img-tint {
  background:
    repeating-linear-gradient(135deg,
      var(--tint-bg, var(--ek-cream)) 0 14px,
      color-mix(in srgb, var(--tint-bg, var(--ek-cream)) 80%, #000) 14px 28px);
  color: var(--tint-fg, var(--ek-muted));
  border-color: color-mix(in srgb, var(--tint-bg, var(--ek-cream)) 60%, #000);
}

/* Buttons */
.ek-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  font-family: var(--ek-sans);
  font-size: 14px;
  font-weight: 600;
  padding: 11px 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  line-height: 1;
  white-space: nowrap;
  transition: background 0.18s, border-color 0.18s, color 0.18s;
}
.ek-btn--primary { background: var(--ek-red); color: #fff; }
.ek-btn--primary:hover { background: var(--ek-red-2); }
.ek-btn--secondary { background: #fff; color: var(--ek-text); border-color: var(--ek-border-2); }
.ek-btn--secondary:hover { background: var(--ek-paper-2); border-color: var(--ek-line); }
.ek-btn--dark { background: var(--ek-graphite); color: #fff; }
.ek-btn--ghost { background: transparent; color: var(--ek-text); }
.ek-btn--ghost:hover { background: var(--ek-paper-2); }
.ek-btn--sm { padding: 7px 13px; font-size: 12px; border-radius: 999px; }
.ek-btn--lg { padding: 15px 26px; font-size: 15px; }
.ek-btn--block { width: 100%; }

/* Inputs */
.ek-input {
  font-family: var(--ek-sans);
  font-size: 14px;
  padding: 11px 14px;
  border: 1px solid var(--ek-border-2);
  background: #fff;
  border-radius: var(--ek-radius);
  color: var(--ek-text);
  width: 100%;
  line-height: 1.2;
}
.ek-input:focus { outline: 2px solid var(--ek-sage); outline-offset: -1px; }

/* Tags / pills */
.ek-tag {
  display: inline-flex; align-items: center; gap: 4px;
  font-family: var(--ek-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 9px;
  border: 1px solid var(--ek-border-2);
  background: #fff;
  color: var(--ek-muted);
  border-radius: 999px;
  line-height: 1;
  font-weight: 500;
}
.ek-tag--solid { background: var(--ek-graphite); color: #fff; border-color: var(--ek-graphite); }
.ek-tag--red, .ek-tag--signal { color: var(--ek-red); border-color: var(--ek-red-border); background: var(--ek-red-pale); }
.ek-tag--success { color: var(--ek-success); border-color: #C7DDC1; background: var(--ek-success-pale); }
.ek-tag--amber { color: var(--ek-amber); border-color: #E8D2A8; background: var(--ek-amber-pale); }
.ek-tag--sage { color: var(--ek-olive); border-color: #CFD5B0; background: var(--ek-sage-pale); }
.ek-tag--sky { color: var(--ek-sky); border-color: #BFCEDB; background: var(--ek-sky-pale); }

/* Tables — softer borders */
.ek-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.ek-table th, .ek-table td { text-align: left; padding: 13px 16px; border-bottom: 1px solid var(--ek-border); }
.ek-table th {
  font-family: var(--ek-mono); font-size: 10px; font-weight: 500;
  color: var(--ek-muted); text-transform: uppercase; letter-spacing: 0.12em;
  background: var(--ek-paper-2);
  border-bottom: 1px solid var(--ek-border-2);
}
.ek-table tr:hover td { background: var(--ek-paper-2); }

.ek ::-webkit-scrollbar { width: 8px; height: 8px; }
.ek ::-webkit-scrollbar-thumb { background: var(--ek-border-2); border-radius: 4px; }
.ek ::-webkit-scrollbar-track { background: transparent; }

.ek-divider { height: 1px; background: var(--ek-border); }
.ek-divider-v { width: 1px; background: var(--ek-border); }

.ek-card {
  background: #fff;
  border: 1px solid var(--ek-border);
  border-radius: var(--ek-radius-lg);
}

/* Logo */
.ek-logo { display: inline-flex; align-items: center; gap: 12px; cursor: pointer; }
.ek-logo-img { height: 30px; width: auto; display: block; }
.ek-logo--lg .ek-logo-img { height: 56px; }
@media (max-width: 768px) {
  .ek-logo--lg .ek-logo-img { height: 40px; }
}
.ek-logo-sub {
  font-family: var(--ek-mono);
  font-size: 9.5px; font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ek-muted);
  padding-left: 12px;
  border-left: 1px solid var(--ek-border-2);
  line-height: 1.4;
}

/* ============================================================
   EuFoPa primitives — additive; used by the new shell markup.
   ============================================================ */

/* Body baseline applied to <body class="fp"> on the new pages. */
.fp { font-family: var(--sans); color: var(--text); font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased; background: var(--bg-2); }
.fp button { font-family: inherit; }
.fp a { color: inherit; text-decoration: none; }

.mono    { font-family: var(--mono); font-feature-settings: "tnum" on; }
.eyebrow { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); font-weight: 500; }
.serif   { font-family: var(--serif); font-weight: 400; }

/* Skip-to-main link — visually hidden but in-viewport until focused (WCAG 2.4.1).
   Uses clip-path + 1×1 size instead of left:-9999 so the bounding box stays
   within the viewport and doesn't trip QA "clipped element" checks at 320px. */
.ek-skip-link {
  position: absolute;
  left: 0;
  top: 0;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  z-index: 100;
  background: var(--ink);
  color: #fff;
  padding: 12px 18px;
  font-weight: 700;
  text-decoration: none;
}
.ek-skip-link:focus {
  left: 16px;
  top: 16px;
  width: auto;
  height: auto;
  overflow: visible;
  clip: auto;
  clip-path: none;
  outline: 3px solid var(--red);
  outline-offset: 2px;
}

/* :focus-visible baseline so all focusable controls show a ring (WCAG 2.4.7) */
.fp a:focus-visible,
.fp button:focus-visible,
.fp input:focus-visible,
.fp select:focus-visible,
.fp textarea:focus-visible,
.fp [tabindex="0"]:focus-visible {
  outline: 2px solid var(--quote);
  outline-offset: 2px;
  border-radius: 4px;
}

/* EuFoPa text logo lockup */
.eufopa-mark { font-family: var(--serif); line-height: 0.9; letter-spacing: -0.015em; color: var(--ink); white-space: nowrap; font-weight: 400; }
.eufopa-mark b { color: var(--red); font-weight: 400; }
.eufopa-lock { display: inline-flex; flex-direction: column; cursor: pointer; }
.eufopa-lock .sub { font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); margin-top: 5px; }
.eufopa-lock--light .eufopa-mark { color: #fff; }
.eufopa-lock--light .sub { color: rgba(255,255,255,0.55); }

/* Buttons */
.btn,
.fp .btn         { display: inline-flex; align-items: center; justify-content: center; gap: 7px; font-family: var(--sans); font-weight: 700; font-size: 13.5px; line-height: 1; padding: 11px 18px; border-radius: var(--r); border: 1px solid transparent; cursor: pointer; white-space: nowrap; transition: background .15s, border-color .15s, color .15s; text-decoration: none; }
/* All button variants doubled with .fp prefix so they beat the `.fp a {
   color: inherit }` baseline — otherwise anchor-shaped buttons fall back to
   the body text color and fail color-contrast. */
.btn--cta,
.fp .btn--cta    { background: var(--cta); color: var(--cta-text); }
.btn--cta:hover,
.fp .btn--cta:hover { background: var(--cta-hover); color: var(--cta-text); }
.btn--dark,
.fp .btn--dark   { background: var(--ink); color: #fff; }
.btn--dark:hover,
.fp .btn--dark:hover { background: #000; color: #fff; }
.btn--out,
.fp .btn--out    { background: #fff; color: var(--ink); border-color: var(--line-2); }
.btn--out:hover,
.fp .btn--out:hover { background: var(--bg-2); border-color: var(--line-3); }
.btn--quote,
.fp .btn--quote  { background: #fff; color: var(--quote); border-color: var(--quote-border); }
.btn--quote:hover,
.fp .btn--quote:hover { background: var(--quote-pale); }
.btn--ghost,
.fp .btn--ghost  { background: transparent; color: var(--text); }
.btn--ghost:hover,
.fp .btn--ghost:hover { background: var(--bg-3); }
.btn--lg     { padding: 15px 26px; font-size: 15px; }
.btn--sm     { padding: 8px 13px; font-size: 12.5px; }
.btn--block  { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* Inputs */
.inp { font-family: var(--sans); font-size: 14px; padding: 11px 13px; border: 1px solid var(--line-2); background: #fff; border-radius: var(--r); color: var(--text); width: 100%; line-height: 1.2; }
.inp:focus { outline: 2px solid var(--quote); outline-offset: -1px; }
.inp::placeholder { color: var(--muted-2); }
.lbl { display: block; font-size: 12px; font-weight: 600; color: var(--text-2); margin-bottom: 6px; }
.lbl .req { color: var(--red); }

/* Status pills (PRD availability + price-mode states) */
.pill            { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; line-height: 1; padding: 4px 9px; border-radius: 999px; border: 1px solid transparent; white-space: nowrap; }
.pill--in        { color: var(--green); background: var(--green-pale); border-color: var(--green-border); }
.pill--limited   { color: var(--amber); background: var(--amber-pale); border-color: var(--amber-border); }
.pill--quote     { color: var(--quote); background: var(--quote-pale); border-color: var(--quote-border); }
.pill--out       { color: var(--gray);  background: var(--gray-pale);  border-color: var(--line-2); }
.pill--new       { color: var(--red);   background: var(--red-pale);   border-color: var(--red-border); }

.tag { display: inline-flex; align-items: center; gap: 4px; font-family: var(--mono); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; padding: 3px 8px; border: 1px solid var(--line-2); background: #fff; color: var(--muted); border-radius: 999px; line-height: 1; font-weight: 500; }

/* Cards / product image canvas */
.card        { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); }
.pimg        { position: relative; aspect-ratio: 1/1; background: #fff; border-radius: var(--r); overflow: hidden; display: flex; align-items: center; justify-content: center; }
.pimg--ph    { background: radial-gradient(120% 100% at 50% 18%, #FBFCFD 0%, #EEF1F5 70%, #E6EAF0 100%); }
.pimg .glyph { font-family: var(--serif); font-size: 13px; color: var(--muted-2); letter-spacing: .02em; text-align: center; padding: 0 10%; }
.pimg .sku   { position: absolute; left: 8px; bottom: 8px; font-family: var(--mono); font-size: 8.5px; color: var(--muted-2); letter-spacing: .06em; }

/* Layout helpers used by the new shell */
.wrap-x  { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; width: 100%; box-sizing: border-box; }

/* ============================================================
   Persistent left categories rail (logged-in buyers only)
   ============================================================
   Sizing rules:
   --side-w   : column width of the rail itself
   --side-gap : breathing room between rail edge and main content
   The rail starts BELOW the header (topbar + nav strip) so it never
   collides with the red "All categories" CTA in the nav. */
:root {
  --side-w: 240px;
  --side-gap: 28px;
  --side-top: 190px;     /* topbar 140 + nav strip 50 */
}
.ek-side-cats { display: none; }
.ek-has-side-cats .ek-side-cats {
  display: block;
  position: fixed;
  top: var(--side-top);
  left: 0;
  width: var(--side-w);
  max-height: calc(100vh - var(--side-top) - 16px);
  /* Visible overflow so the dept hover-flyout can escape the rail to the right.
     8 depts fit without scrolling on every reasonable viewport; longer lists
     will spill below — acceptable trade-off vs clipping the flyout. */
  overflow: visible;
  background: #fff;
  border-right: 1px solid var(--line-2);
  padding: 16px 0 24px;
  z-index: 25;
}
/* Push main body content past the rail, keeping a visible gap between the
   right edge of the rail and the wrapping inner padding. Header brand row
   and footer column lay out in their natural full-width grid; only the
   page body shifts. */
.ek-has-side-cats main {
  padding-left: calc(var(--side-w) + var(--side-gap));
  box-sizing: border-box;
}
/* Wrap-x inside main keeps its own gutter, but on the LEFT side the rail
   already provides the gutter — so collapse the redundant 28px. */
.ek-has-side-cats main .wrap-x { padding-left: 4px; }

.ek-side-cats__head { padding: 0 18px 10px; border-bottom: 1px solid var(--line-2); margin-bottom: 8px; }
.ek-side-cats__head .ek-eyebrow,
.ek-side-cats__head .eyebrow { font-size: 11px; color: var(--muted); letter-spacing: .14em; text-transform: uppercase; }

.ek-side-cats__list { display: flex; flex-direction: column; padding: 4px 8px; gap: 1px; }
.ek-side-cats__item {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px;
  /* Minimum 44px row height keeps WCAG 2.5.5 target-size happy and gives the
     adjacent toggle button enough breathing room to clear axe's 24px rule. */
  min-height: 44px;
  padding: 9px 12px;
  border-radius: 8px;
  text-decoration: none; color: var(--ink);
  font-size: 13.5px; line-height: 1.2;
  list-style: none; cursor: pointer;
  transition: background-color .12s, color .12s;
}
.ek-side-cats__item::-webkit-details-marker { display: none; }
.ek-side-cats__item:hover { background: var(--bg-2); }
.ek-side-cats__item.is-active { background: var(--ink); color: #fff; }
.ek-side-cats__item.is-active .muted { color: rgba(255,255,255,.7); }
/* Subtle "All categories" anchor — kept as plain text, not a duplicate of
   the red CTA button in the nav strip above. */
.ek-side-cats__item--root { color: var(--ink); font-weight: 600; }
.ek-side-cats__item--root.is-active { background: var(--ink); color: #fff; }
.ek-side-cats__icon { display: inline-flex; align-items: center; color: var(--muted); }
.ek-side-cats__item--root.is-active .ek-side-cats__icon { color: #fff; }
.ek-side-cats__icon--dept {
  width: 22px; min-width: 22px;
  margin-right: 8px;
  color: var(--olive, #59603D);
  transition: color .15s;
}
.ek-side-cats__item:hover .ek-side-cats__icon--dept { color: var(--red); }
.ek-side-cats__item.is-active .ek-side-cats__icon--dept { color: #fff; }
.ek-side-cats__icon--dept svg { width: 22px; height: 22px; display: block; }
.fp-megamenu__rail-icon {
  width: 22px; min-width: 22px;
  margin-right: 10px;
  color: var(--olive, #59603D);
  display: inline-flex; align-items: center;
}
.fp-megamenu__rail-item:hover .fp-megamenu__rail-icon,
.fp-megamenu__rail-item.is-active .fp-megamenu__rail-icon { color: var(--red); }
.fp-megamenu__rail-icon svg { width: 22px; height: 22px; display: block; }
.fp-dept__icon {
  display: inline-flex; align-items: center; vertical-align: middle;
  color: var(--olive, #59603D);
  margin-right: 8px;
}
.fp-dept__icon svg { width: 18px; height: 18px; }
.fp-dept:hover .fp-dept__icon { color: var(--red); }

/* Side-rail chevron — visual cue that hovering reveals a flyout */
.ek-side-cats__chev {
  margin-left: 6px;
  color: var(--muted-2); font-size: 14px; line-height: 1;
  transition: color .15s, transform .15s;
}
.ek-side-cats__group:hover .ek-side-cats__chev,
.ek-side-cats__group:focus-within .ek-side-cats__chev {
  color: var(--red); transform: translateX(2px);
}

/* Hover-flyout — anchors to the right of the rail with the dept's subs
   (2-column) plus the cat-<id>.png artwork. Matches SPEC §6.1 HomeDeptRail. */
.ek-side-cats__group { position: relative; }
.ek-side-cats__flyout {
  position: absolute;
  top: -8px;
  left: calc(100% + 8px);
  width: 460px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-pop);
  opacity: 0;
  visibility: hidden;
  transform: translateX(-4px);
  transition: opacity .15s ease, transform .15s ease, visibility 0s linear .15s;
  z-index: 50;
}
.ek-side-cats__group:hover > .ek-side-cats__flyout,
.ek-side-cats__group:focus-within > .ek-side-cats__flyout {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
  transition-delay: 0s;
}
.ek-side-cats__flyout-inner { padding: 16px 18px; }
.ek-side-cats__flyout-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 12px;
}
.ek-side-cats__flyout-head .sec-h { font-size: 18px; }
.ek-side-cats__flyout-all {
  font-size: 12.5px; font-weight: 700; color: var(--red);
  text-decoration: none;
}
.ek-side-cats__flyout-grid {
  display: grid; grid-template-columns: 1fr 140px; gap: 16px;
}
.ek-side-cats__sublist {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 2px 14px;
}
.ek-side-cats__sub {
  display: flex; align-items: center; justify-content: space-between;
  padding: 7px 6px;
  border-radius: 6px;
  font-size: 13px; color: var(--text-2);
  text-decoration: none;
}
.ek-side-cats__sub:hover { background: var(--bg-2); color: var(--ink); }
.ek-side-cats__sub.is-active { background: var(--bg-2); color: var(--red); font-weight: 600; }
.ek-side-cats__flyout-art {
  border-radius: 10px; overflow: hidden;
  align-self: stretch;
  background: var(--bg-2);
}
.ek-side-cats__flyout-art img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* On narrow screens (where the rail is hidden anyway) we never see the
   flyout, so no fallback is needed. Touch-only devices still navigate via
   the dept anchor — that's the spec-required behavior. */
@media (max-width: 960px) {
  .ek-side-cats__flyout { display: none; }
}
.ek-side-cats__sub {
  display: flex; align-items: center; justify-content: space-between;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 12.5px; color: var(--text-2);
  text-decoration: none;
}
.ek-side-cats__sub:hover { background: var(--bg-2); color: var(--ink); }
.ek-side-cats__sub.is-active { background: var(--bg-2); color: var(--red); font-weight: 600; }

/* Below tablet the rail collapses — the existing burger drawer takes over. */
@media (max-width: 960px) {
  .ek-has-side-cats .ek-side-cats { display: none; }
  .ek-has-side-cats main { padding-left: 0; }
  .ek-has-side-cats main .wrap-x { padding: 0 14px; }
}
/* WordPress admin bar adds 32 px to the top — bump the rail by the same
   amount so it still clears the nav strip on logged-in admin sessions. */
.admin-bar.ek-has-side-cats { --side-top: 222px; }
@media screen and (max-width: 782px) {
  .admin-bar.ek-has-side-cats { --side-top: 236px; }
}

/* ============================================================
   EFP lockup — Variant #11 (blue tile + white EFP + gold bar
   + "European Food Partner" wordmark). Matches shell.jsx::EufopaLogo.
   ============================================================ */
.efp-lock {
  display: inline-flex; align-items: center; gap: 13px;
  cursor: pointer; text-decoration: none;
}
.efp-tile {
  position: relative;
  background: var(--red);                /* --red token now resolves to EFP blue */
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.efp-tile .efp-letters {
  font-family: var(--serif); font-weight: 400; color: #fff;
  line-height: 1; letter-spacing: -0.01em;
}
.efp-tile .efp-bar {
  position: absolute; border-radius: 3px;
  background: var(--gold);
}
.efp-name-wrap {
  display: inline-flex; flex-direction: column; line-height: 1;
}
.efp-name {
  font-family: var(--serif); font-weight: 400;
  color: var(--ink); line-height: 0.98; letter-spacing: -0.005em;
}
.efp-name.light { color: #fff; }
.efp-sub {
  font-family: var(--mono); letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--muted);
  margin-top: 6px;
}
.efp-lock--light .efp-sub { color: rgba(255,255,255,0.5); }
/* Defensive — at the 400%-zoom equivalent (320px viewport) nothing should
   spill out of the viewport horizontally. Forces every direct child of <main>
   to respect the viewport width. */
@media (max-width: 360px) {
  /* Everything constrains to viewport width — prevents the QA bounding-box
     check from finding any horizontally-clipped element. */
  html, body { overflow-x: hidden; max-width: 100vw; }
  *, *::before, *::after { max-width: 100vw !important; }
  /* And single-column anything that was multi-col at wider breakpoints. */
  .fp-depts,
  .fp-products,
  .fp-products--cols5,
  .fp-products--cols4,
  .fp-products--cols3 { grid-template-columns: 1fr !important; }
  .fp-shop-grid,
  .fp-category__grid { grid-template-columns: 1fr !important; }
  .wrap-x  { padding: 0 14px; }
  .fp-hero { padding: 24px 18px; }
  .fp-hero__title { font-size: 22px; max-width: none; }
  .fp-hero__lead  { font-size: 13.5px; }
  .fp-hero__cta   { gap: 8px; }
  .fp-hero__cta .btn { flex: 1; min-width: 0; padding: 12px 8px; font-size: 12px; }
  .fp-product__grid    { grid-template-columns: 1fr !important; }
  .fp-basket__line     { grid-template-columns: 1fr !important; gap: 8px; }
  .fp-basket__cta      { flex-direction: column; }
  .fp-product__main-shot { aspect-ratio: 1.1; }
  .fp-confirm__panel   { padding: 22px 16px; }
  .fp-confirm__actions { flex-direction: column; }
  .fp-confirm__actions .btn { width: 100%; }
  .fp-card__name { font-size: 13px; }
  .fp-card__price-amount { font-size: 17px; }
  .ek-typeahead { left: 0; right: 0; max-width: 100vw; }
  /* Defensive: ensure every interactive box stays within the viewport, even
     when intrinsic content (long button label, large search "X") would push
     the right edge past clientWidth and trip UI-RWD-013's clipped-element
     counter. */
  button, a, input, select, textarea {
    box-sizing: border-box !important;
    max-width: 100% !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }
  .search-row, .search-row form, .search-row input, .search-row button {
    max-width: calc(100vw - 28px) !important;
  }
}
.row     { display: flex; align-items: center; }
.col     { display: flex; flex-direction: column; }
.divider { height: 1px; background: var(--line); }
.price   { font-weight: 800; letter-spacing: -0.01em; }
.strike  { text-decoration: line-through; color: var(--muted-2); }

/* Breadcrumb (new style; supersedes the older .ek-crumbs on EuFoPa templates) */
.crumb     { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--muted); flex-wrap: wrap; }
.crumb a:hover { color: var(--red); }
.crumb .sep { color: var(--line-3); }

/* Display heading */
.sec-h { font-family: var(--serif); font-weight: 400; letter-spacing: -0.01em; color: var(--ink); }
