/* One sticky header inside the existing Safari page scroller. */
html body.sf-navigation.sf-enhanced.web-order .main-head,
html body.sf-navigation.sf-enhanced.web-order .main-head.has-realm-segments {
 position:sticky;top:0;z-index:var(--tdf-z-sticky,50);gap:12px;
 box-shadow:0 3px 12px #17221c0a;padding-top:12px;padding-bottom:12px;
}
html:has(.sf-navigation),.sf-navigation .sf-page-scroll {scroll-padding-top:calc(var(--sf-header-height,140px) + 12px)}
.sf-navigation :is(#products,#ui-main-content,#product-page) {scroll-margin-top:12px}
html body.sf-navigation .main-head .wordmark {flex-basis:215px}
html body.sf-navigation .main-head .sf-header-search {order:2;flex:1 1 260px;position:relative}
html body.sf-navigation .main-head .header-account-cart {order:3;gap:12px}
html body.sf-navigation.sf-enhanced .main-head>.sf-header-categories {
 order:6;flex:0 0 100%;grid-column:1/-1;grid-row:auto;
 display:flex!important;align-items:stretch;gap:8px;min-width:0;width:100%;max-width:100%;
 margin:0;padding:4px 0 6px;overflow-x:auto;overscroll-behavior-x:contain;
 background:var(--tdf-surface,#fff);border:0;scroll-padding-inline:4px;
 scrollbar-width:thin;
}
html body.sf-navigation.sf-enhanced .main-head>.sf-header-categories button {flex:none;min-height:48px;white-space:nowrap}
.sf-categories-pinned #events>.v9-featured {grid-row:3}
.sf-category-toggle {order:1;display:flex;align-items:center;justify-content:center;gap:8px;border:1px solid var(--sf-line);background:var(--tdf-page);color:var(--tdf-text);border-radius:10px;padding:10px 12px;min-height:48px;flex:none;font-weight:650;cursor:pointer}
.sf-category-toggle svg {width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.6}
html body.sf-navigation .sf-category-toggle {min-block-size:48px}
.sf-category-toggle[aria-expanded=true] {border-color:var(--sf-pine);background:var(--tdf-soft,#eaf7f0);color:var(--sf-pine)}
html body.sf-navigation .sf-search-clear {border:0;background:transparent;flex:none;width:44px;min-height:44px;font-size:24px;color:var(--tdf-text-muted);cursor:pointer;padding:0}
/* Reserve the clear action's space so the text field does not resize mid-entry. */
html body.sf-navigation .sf-search-clear[hidden] {display:block!important;visibility:hidden}
html body.sf-navigation #search-submit {display:flex;align-items:center;justify-content:center;flex:none;min-width:44px;min-height:44px;padding:0;border:0;background:transparent;color:var(--sf-pine);cursor:pointer}
html body.sf-navigation #search {padding-right:4px!important}
.sf-navigation #search::-webkit-search-cancel-button {display:none}
.sf-navigation .sf-search-actions {display:none}
html body.sf-navigation .search-suggestions {top:calc(100% + 8px);left:0;right:0;width:100%;max-height:max(44px,min(440px,calc(100dvh - var(--sf-header-height,140px) - 65px)));overflow:auto;overscroll-behavior:contain;border:1px solid var(--sf-line);border-radius:12px;background:var(--tdf-surface);box-shadow:var(--tdf-shadow-sheet);z-index:2}
.sf-navigation .suggestion-heading {font-size:12px;font-weight:700;color:var(--tdf-text-muted);padding:10px 12px;background:var(--tdf-page)}
html body.sf-navigation .suggestion-item {min-height:56px;width:100%;padding:10px 12px;text-align:left;gap:10px;border:0;border-bottom:1px solid var(--sf-line);border-radius:0;background:var(--tdf-surface);color:var(--tdf-text);display:flex;align-items:center}
.sf-navigation .suggestion-item.highlighted,.sf-navigation .suggestion-item:hover {background:var(--tdf-soft,#eaf7f0)!important}
.sf-navigation .suggestion-main {flex:1;min-width:0;overflow-wrap:anywhere}
.sf-navigation .suggestion-main b {white-space:normal!important;overflow:visible;display:block;-webkit-line-clamp:unset}
.sf-navigation .suggestion-main small {display:block;color:var(--tdf-text-muted)}
.sf-navigation .suggestion-price {flex:none;max-width:35%;font-size:13px;white-space:normal;text-align:right}
.sf-navigation .suggestion-icon img {width:36px;height:36px;object-fit:cover;border-radius:6px}
.sf-search-message {padding:14px;color:var(--tdf-text-muted);font-size:14px}
.sf-search-message button {margin-top:8px;display:block}
.sf-category-panel {position:absolute;top:100%;left:20px;right:20px;max-width:1050px;margin:0 auto;z-index:3;background:var(--tdf-surface);border:1px solid var(--sf-line);border-radius:0 0 16px 16px;box-shadow:var(--tdf-shadow-sheet);overflow:hidden;padding:20px;color:var(--tdf-text)}
.sf-category-heading {display:flex;align-items:center;justify-content:space-between;gap:12px}
.sf-category-heading h2 {font-size:20px;margin:0;font-family:inherit}
.sf-category-close {border:1px solid var(--sf-line);background:var(--tdf-surface);color:var(--tdf-text);border-radius:8px;min-width:44px;min-height:44px;font-size:26px;cursor:pointer}
html body.sf-navigation .sf-category-close {min-block-size:44px;font-size:24px}
.sf-category-caption {margin:4px 0 16px;color:var(--tdf-text-muted);font-size:14px}
.sf-category-links {display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;overflow:auto;max-height:calc(100svh - var(--sf-header-height,140px) - 130px);overscroll-behavior:contain;padding:4px}
.sf-category-link {display:flex;align-items:center;gap:10px;min-height:72px;padding:10px;border:1px solid var(--sf-line);border-radius:10px;text-decoration:none;color:var(--tdf-text);background:var(--tdf-surface)}
.sf-category-link img {width:36px;height:36px;object-fit:cover;border-radius:6px;flex:none}
.sf-category-copy {display:grid;gap:4px;min-width:0;flex:1}
.sf-category-copy strong {font-size:14px;overflow-wrap:anywhere}
.sf-category-copy small {font-size:12px;color:var(--tdf-text-muted)}
.sf-category-gift {grid-column:1/-1;background:var(--tdf-soft,#eaf7f0);border-color:var(--sf-pine)}
.sf-category-chevron {font-size:24px;color:var(--tdf-text-muted)}
.sf-category-link:hover,.sf-category-link[aria-current] {border-color:var(--sf-pine);background:var(--tdf-soft,#eaf7f0);color:var(--sf-pine)}
.sf-category-shade {position:fixed;inset:0;background:var(--tdf-overlay);z-index:1000}
.sf-category-selection {min-height:44px;max-width:100%;margin:0 0 12px;padding:8px 12px;border:1px solid var(--sf-pine);border-radius:10px;background:var(--tdf-soft);color:var(--sf-pine);font:inherit;font-size:14px;text-align:left;cursor:pointer}
.sf-category-selection[hidden] {display:none!important}
@media (max-width:1100px) and (min-width:701px) and (min-height:501px),(max-width:1100px) and (min-width:1001px){.sf-category-links{grid-template-columns:repeat(3,minmax(0,1fr))}html body.sf-navigation .main-head .wordmark{flex-basis:190px}html body.sf-navigation .main-head .sf-header-search{flex-basis:250px}}
@media (max-width:700px),(max-width:1000px) and (max-height:500px){
 html body.sf-navigation.sf-enhanced .v9-bottom-nav>:is(.sf-bottom-category,.sf-bottom-dishes) {
  display:flex!important;flex-direction:column;align-items:center;justify-content:center;gap:4px;
  position:static!important;width:auto!important;min-width:0;height:auto!important;min-height:48px;
  margin:0;padding:4px 1px!important;border:0;border-radius:0;
  background:transparent!important;color:var(--tdf-text)!important;box-shadow:none;cursor:pointer;
 }
 html body.sf-navigation.sf-enhanced .v9-bottom-nav>:is(.sf-bottom-category,.sf-bottom-dishes)[aria-expanded=true] {color:var(--sf-pine)!important}
 /* Brand and guarded realm switch share one row; search gets its own row. */
 html body.sf-navigation.sf-enhanced.web-order .main-head,
 html body.sf-navigation.sf-enhanced.web-order .main-head.has-realm-segments {grid-template-columns:minmax(0,1fr) auto;gap:8px;padding:8px max(12px,env(safe-area-inset-right)) 8px max(12px,env(safe-area-inset-left))}
 html body.sf-navigation.sf-enhanced .main-head>.sf-header-categories {display:none!important}
 html body.sf-navigation.sf-enhanced.web-order .main-head .wordmark {display:flex!important;grid-column:1!important;grid-row:1!important;padding:0;width:auto;max-width:100%;min-height:44px;gap:6px}
 html body.sf-navigation .main-head .wordmark>span {display:block!important;min-width:0}
 html body.sf-navigation.sf-enhanced .main-head .wordmark strong {font-size:clamp(12px,3.8vw,18px);white-space:nowrap}
 html body.sf-navigation.sf-enhanced .main-head .wordmark small {display:none!important}
 html body.sf-navigation.sf-enhanced .main-head .brand-logo {width:28px;height:28px;flex:none;object-fit:contain}
 html body.sf-navigation.sf-enhanced.web-order .main-head .realm-segments:not([hidden]) {grid-row:1;grid-column:2;width:auto;max-width:100%;min-width:0;gap:2px;padding:2px;border-radius:12px;justify-self:end}
 html body.sf-navigation.sf-enhanced .main-head .realm-segments button {flex:1;min-width:0;min-height:44px;padding:8px;font-size:12px}
 html body.sf-navigation .main-head #v9-header-search.sf-header-search {grid-column:1/-1;grid-row:2;min-width:0}
 html body.sf-navigation .sf-header-search.is-search-editing .sf-search-actions {display:flex;gap:8px;margin-top:8px}
 html body.sf-navigation .sf-search-actions button {flex:1;min-width:44px;min-height:44px;padding:8px 12px;border:1px solid var(--sf-line);border-radius:10px;background:var(--tdf-surface);color:var(--sf-pine);font:inherit;font-size:14px;font-weight:650;cursor:pointer}
 html body.sf-navigation .sf-search-actions button:focus-visible {outline:2px solid var(--sf-pine);outline-offset:2px}
 html body.sf-navigation .sf-search-actions button:active {background:var(--tdf-soft)}
 html body.sf-navigation.sf-enhanced.web-order .main-head .commerce-realm-tools {display:none!important}
 html body.sf-navigation.sf-enhanced .main-head .commerce-gift-link {min-height:44px;display:flex;align-items:center;justify-content:center;font-size:14px}
 html body.sf-navigation.sf-enhanced.web-order--catalog .main-head .header-account-cart {display:none!important}
 /* Direct product pages keep search full-width and cart beside browse actions. */
 html body.sf-navigation.sf-enhanced.web-order--product .main-head>#cart-open {grid-column:2;grid-row:3;justify-self:end;position:relative;z-index:1}
 html body.sf-navigation .v9-bottom-nav>:is(a,button):focus-visible {outline:2px solid var(--sf-pine);outline-offset:-3px;border-radius:8px}
 html body.sf-navigation .v9-bottom-nav>:is(a,button):active {background:var(--tdf-soft)!important}
 html body.sf-navigation.sf-enhanced .v9-bottom-nav>:is(.sf-bottom-category,.sf-bottom-dishes)[data-active=true] {color:var(--sf-pine)!important;font-weight:700}
 html body.sf-navigation .v9-bottom-nav>:is(.sf-bottom-category,.sf-bottom-dishes)[data-active=true] small {text-decoration:underline;text-underline-offset:3px}
 .sf-category-panel {position:fixed;inset:max(8px,env(safe-area-inset-top)) 8px max(8px,env(safe-area-inset-bottom));z-index:1010;max-width:none;border-radius:14px;padding:16px;display:grid;grid-template-rows:auto auto minmax(0,1fr)}
 .sf-category-links {grid-template-columns:repeat(2,minmax(0,1fr));max-height:none;align-content:start}
 .sf-category-link {gap:8px;padding:8px;min-height:80px}
 .sf-category-link img {width:28px;height:32px}.sf-category-chevron{display:none}
 .sf-category-copy strong {font-size:13px}
 .sf-category-heading h2 {font-size:18px}
 .sf-category-caption {font-size:13px;margin-bottom:8px}
 .sf-navigation .suggestion-price {font-size:12px;max-width:38%}
 .sf-navigation .suggestion-item .suggestion-icon {display:none}
}
@media (max-height:360px){.sf-category-panel{padding:8px}.sf-category-caption{display:none}.sf-category-links{margin-top:4px}.sf-navigation .main-head .wordmark small{display:none!important}
 html body.sf-navigation.sf-enhanced .main-head>.sf-header-categories {padding:0 0 2px}
 html body.sf-navigation.sf-enhanced .main-head>.sf-header-categories button {min-height:44px;padding:6px 10px}
 html body.sf-navigation.sf-enhanced .main-head>.sf-header-categories button :is(img,.v9-category-all) {display:none}
}
/* Let short landscape/keyboard viewports reclaim the entire content area. */
@media (max-width:700px) and (max-height:360px),(max-width:1000px) and (max-height:360px) and (max-height:500px){
 html body.sf-navigation.sf-enhanced.web-order .main-head,
 html body.sf-navigation.sf-enhanced.web-order .main-head.has-realm-segments {position:relative}
 html:has(.sf-navigation),.sf-navigation .sf-page-scroll {scroll-padding-top:12px}
}
@media print{html body.sf-navigation.sf-enhanced.web-order .main-head{position:static}.sf-category-panel,.sf-category-shade{display:none!important}}

/* Recipe matches belong to the submitted catalog query, in the page scroller. */
.catalog-recipes{margin:0 0 24px;padding:16px;border:1px solid var(--sf-line);border-radius:12px;background:var(--tdf-surface)}
.catalog-recipes[hidden]{display:none!important}
.catalog-recipes-header{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.catalog-recipes-header h2{margin:0;font:inherit;font-size:18px;font-weight:700;color:var(--sf-pine)}
.catalog-recipes-all{display:inline-flex;align-items:center;min-height:44px;color:var(--sf-pine);font-weight:600}
.catalog-recipes-status{margin:6px 0 12px;color:var(--tdf-text-muted);font-size:14px;overflow-wrap:anywhere}
.catalog-recipe-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
.catalog-recipe-card{display:flex;align-items:center;gap:10px;min-width:0;min-height:80px;padding:8px;border:1px solid var(--sf-line);border-radius:10px;background:var(--tdf-surface);color:var(--tdf-text);font:inherit;text-align:start;cursor:pointer}
.catalog-recipe-grid+.catalog-recipes-all{margin-top:12px}
.catalog-recipe-card:hover{border-color:var(--sf-pine);background:var(--tdf-soft)}
.catalog-recipe-card:focus-visible,.catalog-recipes-all:focus-visible{outline:2px solid var(--sf-pine);outline-offset:3px}
.catalog-recipe-card img{width:60px;height:60px;object-fit:cover;border-radius:6px;flex:none}
.catalog-recipe-card>span{display:grid;gap:6px;min-width:0;overflow-wrap:anywhere}
.catalog-recipe-card strong{font-size:14px;line-height:1.45}
.catalog-recipe-card small{font-size:12px;color:var(--tdf-text-muted)}
@media(max-width:1100px){.catalog-recipe-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){.catalog-recipes{padding:12px}.catalog-recipes-header{gap:4px}.catalog-recipe-grid{grid-template-columns:1fr}.catalog-recipe-card{min-height:76px}.catalog-recipes-header h2{font-size:16px}}

/* Explicit meanings for an ambiguous search stay in normal document flow. */
html body.sf-navigation .catalog-query-choices{display:flex;flex-wrap:wrap;gap:8px}
html body.sf-navigation .catalog-query-choices>.btn{min-height:44px;min-width:44px}
