/** Shopify CDN: Minification failed

Line 1045:0 Expected "}" to go with "{"

**/
/* ========================================
   EDM CART DRAWER — PRODUCTION READY
   Best Practice: Synced with edm-product-drawer.liquid
   
   STRUKTUR:
   A. Tokens & Isolation
   B. Base / Foundation  
   C. Header Component
   D. Content Area
   E. Footer Component
   F. Upsell / Cross-Sell
   G. Checkout Button
   H. MOBILE-SPECIFIC (≤ 1023px)
   I. DESKTOP-SPECIFIC (≥ 1024px)
   ======================================== */

/* ========================= 
 A. TOKENS & ISOLATION (Scoped to #CartDrawer) 
============================  */

#CartDrawer {
  /* === FARBEN === */
  --edm-blue: #00bbed;
  --edm-text-header: #fff;
  --edm-orange: #FF9F45;
  --edm-green: #4ECB71;
  
  /* === DRAWER THEME === */
  --content-background-color: #F0FAFF;
  --content-font-main-color: #444444;
  --content-font-price-color: #888888;
  --color-background: transparent;
  --edm-upsell-bg: #ffffff;
  --edm-upsell-shadow: 0 8px 24px rgba(0,0,0,0.08);
  --edm-progressbar-inactive: #E8E8E8;

  /* === GEOMETRIE (Synced with Product Drawer) === */
  --edm-drawer-width: 500px;
  --edm-header-height: auto;
  --edm-pad-outer: 20px; 
  --edm-drawer-gutter: var(--edm-pad-outer);
  
  /* === INHALT === */
  --edm-img-size: 84px;
  --edm-font-base: 16px;
  --edm-font-title: 20px;
  
  /* DYNAMIC CLOSE BUTTON CONFIG */
  --edm-close-btn-size: 44px;
  --edm-close-icon-size: 20px;
  
  /* === CART SPECIFIC === */
  --edm-gap: 8px;
  --edm-item-gap-y: 8px;
  --edm-row-gap: 0px;

  /* === CARD STYLES === */
  --edm-card-bg: rgba(255, 255, 255, 0.08);
  --edm-card-border: 1px solid rgba(255, 255, 255, 0.15);
  --edm-card-radius: 12px;
  
  /* === MOBILE TOKENS === */
  --edm-mobile-media-col: 88px;
  --edm-mobile-card-radius: 12px;
  --edm-mobile-card-pad: 16px;
  --edm-mobile-btn-radius: 8px;
  --mobile-price-font-size: 0.9375rem;
  --mobile-variant-line-height: 1.3;
  
  /* === DESKTOP TOKENS === */
  --edm-desktop-media-col: 96px;
  --edm-desktop-card-radius: 12px;
  --edm-desktop-card-pad: 20px;
  --desktop-outer-padding: 12px;
  --desktop-column-gap: 12px;
  --desktop-row-gap: 12px;
  --desktop-price-font-size: 1rem;
  --desktop-variant-line-height: 1.4;
  --edm-desktop-inner-pad: 12px;
  
  /* === ROW HEIGHTS === */
  --edm-row1-h: auto;
  --edm-row2-h: auto;
  
  /* === UPSELL TYPOGRAPHY === */
  --edm-lead-size: 1.1rem;
  --edm-title-size: 1rem;
  --edm-hint-size: 0.875rem;
}

@media (max-width: 749px) {
  #CartDrawer {
     --edm-pad-outer: 16px; 
     --edm-drawer-width: 100vw; 
    --edm-img-size: 64px;
    --edm-font-base: 14px;
  }
}

/* ========================================
   B. BASE / FOUNDATION (EDM PRODUCT DRAWER PATTERN)
   ======================================== */

/* GLOBAL RESET - Zwingt den Drawer in eine "Clean Box" (wie Product Drawer) */
cart-drawer {
  position: fixed !important; 
  top: 0 !important; 
  left: 0 !important; 
  width: 100vw !important; 
  height: 100vh !important; 
  z-index: 2147483647 !important;
  pointer-events: none;
  /* Anti-Zoom Protection */
  font-size: 16px !important;
  line-height: 1.5 !important;
  font-family: 'Poppins', sans-serif !important;
  color: var(--content-font-main-color) !important;
  text-size-adjust: 100% !important;
  -webkit-font-smoothing: antialiased;
  margin: 0 !important;
  padding: 0 !important;
}

/* Aggressiver Box-Model Reset */
cart-drawer *,
cart-drawer *::before,
cart-drawer *::after {
  box-sizing: border-box !important;
  -webkit-box-sizing: border-box !important;
}

/* HIDDEN STATE */
cart-drawer[hidden] {
  display: none !important;
}

/* OVERLAY */
.edm-cart-overlay {
  position: fixed !important;
  inset: 0 !important;
  background: rgba(0, 0, 0, 0.5) !important;
  z-index: 999998 !important;
  cursor: pointer;
}
.edm-cart-overlay[hidden] {
  display: none !important;
}

@media (max-width: 1023px) {
  .edm-cart-overlay {
    display: none !important;
  }
}

/* Sticky Fix */
body:has(cart-drawer[open]) .sticky-buyme,
body:has(cart-drawer.active) .sticky-buyme { 
  z-index: 1 !important; 
  pointer-events: none !important; 
}

/* ====== RAILS & SCROLLING ================================================= */
/* CONTENT AREA - Product Drawer Pattern */
#CartDrawer .drawer__contents {
  background: var(--content-background-color) !important; /* Content Background für gefüllten Warenkorb */
  padding-inline: var(--edm-drawer-gutter) !important;
}

/* Sicherstellen dass Content Background nicht durchscheint */
cart-drawer:not(.is-empty) .drawer__contents {
  background: var(--content-background-color) !important;
}

/* ========================= 
 C. Header Component
============================  */

/* ====== DRAWER CONTAINER ============================== */
cart-drawer .drawer__inner {
  position: absolute !important;
  top: 0 !important;
  bottom: 0 !important;
  right: 0 !important;
  left: auto !important;
  width: 100% !important;
  max-width: var(--edm-drawer-width) !important;
  background: var(--edm-blue) !important; /* Header bleibt #00bbed */
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.2, 0.7, 0.2, 1);
  box-shadow: -5px 0 30px rgba(0,0,0,0.2);
  display: flex !important;
  flex-direction: column !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  pointer-events: auto !important;
}

/* Content Background für gefüllten Warenkorb */
cart-drawer:not(.is-empty) .drawer__inner {
  background: var(--content-background-color) !important;
}

cart-drawer[data-edm-open] .drawer__inner {
  transform: translateX(0) !important;
}

.cart-drawer__container { padding: 0; box-sizing: border-box; }

/* ====== HEADER ARCHITECTURE =========== */
#CartDrawer .drawer__header {
  flex: 0 0 auto; 
  position: relative !important;
  background: var(--edm-blue) !important;
  width: 100% !important;
  padding: 0 !important; /* Padding MUSS 0 sein. Der Abstand kommt nur von den inneren Elementen. */
  margin: 0 !important;
  z-index: 50;

  /* FLUID ALIGNMENT ENGINE */
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important; 
  justify-content: center !important;
  
  /* THEME OVERRIDE (Kill-Switch) */
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
}

/* SAFETY NET: Theme Pseudo-Elemente entfernen */
#CartDrawer .drawer__header::after,
#CartDrawer .drawer__header::before {
  display: none !important;
  content: none !important;
}

/* Header Content - FLEXBOX PATTERN */
#CartDrawer .drawer__header-content {
  display: flex !important;
  align-items: center !important;
  align-content: center !important;
  justify-content: space-between !important;
  width: calc(100% - (var(--edm-pad-outer) * 2)) !important; /* ALIGNMENT SYNC: Exakt die gleiche Breite wie Content unten */
  padding: 12px 0 !important; /* COMPACT HEADER */
  min-height: 60px !important; /* HEIGHT: Like Product Drawer */
  box-sizing: border-box !important;
}

/* Alignment Safety für Kinder */
#CartDrawer .drawer__header-content > * {
  align-self: center !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

/* Close Button */
#CartDrawer .drawer__close {
  color: var(--edm-text-header) !important;
  position: static !important;
  inset: auto !important;        /* Consolidates top/right/bottom/left */
  transform: none !important;
  margin: 0 0 0 calc((var(--edm-close-btn-size) - var(--edm-close-icon-size)) / -2) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: var(--edm-close-btn-size) !important; 
  height: var(--edm-close-btn-size) !important;
  padding: 0 !important;
  background: transparent !important;
  border: none !important;
  cursor: pointer;
}

#CartDrawer .drawer__close svg {
  width: var(--edm-close-icon-size) !important; 
  height: var(--edm-close-icon-size) !important;
  display: block; 
  fill: currentColor;
  transform: none !important;
}

/* Titel */
#CartDrawer .drawer__heading {
  margin: 0 !important;
  padding: 0 !important;
  font-size: var(--edm-font-title) !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  color: var(--edm-text-header) !important;
  white-space: nowrap !important;
  transition: font-size 0.2s ease;
}

/* Trennerlinie (Deaktiviert für Cleaner Look) */
#CartDrawer .drawer__header-border {
  display: none !important; 
  flex-shrink: 0 !important;
}

/* ========================= 
 D. Content Area
============================  */

#CartDrawer .cart-drawer__items {
   overflow: visible !important;
}

/* Alle Borders auf cart-drawer-items entfernen (könnte Border-Bottom haben) */
#CartDrawer cart-drawer-items,
#CartDrawer cart-drawer-items::before,
#CartDrawer cart-drawer-items::after {
  border: none !important;
  box-shadow: none !important;
}

  /* === LAYOUT: VISUELLE TRENNERLINIEN === */
  /* Design-Entscheidung: Pseudo-Elemente statt Borders für präzise Positionierung zwischen Grid-Rows */
  #CartDrawer .cart-item__details > .product-option:first-of-type,
  #CartDrawer .cart-item__details > .cart-item__discounted-prices{
    position: relative;
  }
  /* Trennerlinie: ENTFERNT - Keine Linien mehr */
  #CartDrawer .bundle-variants::after,
  #CartDrawer .cart-item__details > .product-option:first-of-type::after,
  #CartDrawer .cart-item__details > .cart-item__discounted-prices::after{
    content: none !important;
    display: none !important;
  }
  /* Bundle-Varianten: gleiche Trennerlinie-Logik für visuelle Konsistenz */
  #CartDrawer .bundle-variants{
    position: relative;
  }

  /* === QUANTITY CONTROLS === */
 
  /* 1. QUANTITY INPUT RESET (Base State) */
#CartDrawer .cart-item__quantity :is(quantity-input, quantity-popover, .quantity, .quantity-popover-container) .quantity__input {
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  text-align: center;
  color: var(--content-font-main-color) !important;
  min-height: 0 !important;
  height: auto !important;
  -moz-appearance: textfield; /* Firefox Number-Input Fix */
}
#CartDrawer .cart-item__quantity .quantity__input::-webkit-outer-spin-button,
#CartDrawer .cart-item__quantity .quantity__input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* 2. QUANTITY BUTTONS RESET */
#CartDrawer .cart-item__quantity :is(button, .quantity__button) {
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: var(--content-font-main-color) !important;
  cursor: pointer;
  min-width: 24px;
}
#CartDrawer .cart-item__quantity :is(button, .quantity__button):disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

/* 3. ICON COLORS */
#CartDrawer .cart-item__quantity svg {
  fill: currentColor !important;
  color: inherit !important;
}

/* 4. BUNDLE / DISABLED STATES (Global Logic) */
/* Gilt für alle Inputs, die disabled oder readonly sind (egal ob Mobile oder Desktop) */
#CartDrawer tr.cart-item--bundle :is(.quantity, quantity-input, quantity-popover) .quantity__input:is([disabled], [readonly]) {
  font-weight: 400 !important;
  pointer-events: none !important;
  opacity: 1 !important;
  border: none !important;
  color: var(--content-font-main-color) !important;
  background: transparent !important;
}
/* Versteckte Buttons im Bundle */
#CartDrawer tr.cart-item--bundle :is(.quantity__button, button).is-hidden {
  display: none !important;
}

/* 5. START-SMART BUTTONS (Override Base) */
#CartDrawer tr.cart-item--start-smart .cart-item__quantity :is(button, .quantity__button) {
  background: var(--content-background-color) !important;
  border-radius: 4px !important;
  opacity: 1 !important; 
}
  
/* ========================= 
 E. Footer Component
============================  */

/* FOOTER: Product Drawer Pattern - KEIN seitliches Padding, Zentrierung via Flex */
#CartDrawer .drawer__footer {
  padding-inline: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  position: relative !important;
  padding-top: 0px !important; 
  margin-top: auto !important; /* Push to bottom safety */
  z-index: 20; /* Sicherstellen, dass Footer über Card-Shadows liegt */
  
  /* THEME OVERRIDE (Der Kill-Switch wie im Product Drawer) */
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
  display: grid; 
  row-gap: 0 !important;
}

#CartDrawer .cart-drawer__footer {
  border: none !important;
  box-shadow: none !important;
  padding-bottom: 4px !important; /* Footer: Grid-Layout mit einheitlichen Spacings */
  width: 100% !important;
  padding-top: 0 !important;
  margin-top: 0 !important;
}

/* SAFETY NET: Theme-Pseudo-Elemente auf Kindern entfernen (wie Product Drawer Pattern) */
#CartDrawer .drawer__footer::after,
#CartDrawer .drawer__footer::before,
#CartDrawer .cart-drawer__footer::before,
#CartDrawer .cart-drawer__footer::after {
  display: none !important; /* Footer Trennerlinie (Deaktiviert für Cleaner Look) */
  content: none !important;
  border: none !important;
}

/* Footer-Kinder: Margin-Reset für konsistentes Spacing (verhindert Doppel-Margins) */
#CartDrawer .drawer__footer > :where(.cart-drawer__footer, .edm-upsell, .cart__ctas){
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  margin-block: 0 !important;
}
#CartDrawer .drawer__footer > :first-child:not(.cart-drawer__footer){ margin-top: 0 !important; }
#CartDrawer .drawer__footer > :last-child{ margin-bottom: 0 !important; }
#CartDrawer .cart-drawer__footer .totals{
  margin: 0 !important;
  padding-bottom: 0 !important;
}

/* === CROSS-SELL SPACING (Allgemein für Mobile & Desktop) === */
#CartDrawer .cart-drawer__footer { margin-bottom: 4px !important; } /* Minimale Höhe: 6px → 4px */
#CartDrawer .cart-drawer__footer ~ .edm-upsell { margin-top: 2px; }
#CartDrawer .edm-upsell + .cart__ctas { margin-top: 4px !important; } /* Minimale Höhe: 6px → 4px */


/* ========================= 
 G. Checkout Button
============================  */

/* === CHECKOUT BUTTON COMPONENT === */
/* Checkout-Button: Total-Anzeige mit Separator für bessere UX */
#CartDrawer .cart__checkout-button{
  display:inline-flex; align-items:center; justify-content:center; gap:.5rem;
  width:100%; white-space:nowrap;
}
#CartDrawer .cart__checkout-button [data-label]{ flex:0 0 auto; }
#CartDrawer .cart__checkout-button .edm-btn-sep{ margin:0 .25rem; }
#CartDrawer .cart__checkout-button .edm-btn-total{ font-weight:700; }

/* ========================================
   H. MOBILE-SPECIFIC (≤ 1023px)
   ======================================== */

@media (max-width: 1023px) {

  /* --------------------------------------------------------
     1. LAYOUT FUNDAMENTALS & RESET (MOBILE)
  -------------------------------------------------------- */

 /* Performance & Containment */
  /* Inner/Contents auf visible setzen, damit Schatten in das Padding laufen können */
  #CartDrawer .drawer__inner {
    overflow-x: clip; /* Nur der äußerste Container beschneidet den Screen */
    max-width: 100%;
    contain: layout style;
  }
  #CartDrawer :is(.drawer__contents, .drawer__cart-items-wrapper) {
    overflow-x: visible !important; /* Erlaubt Schatten-Bleed in die Gutter */
    overflow-y: visible !important;
  }
  body:has(cart-drawer[open]) { overflow-x: clip; } /* Body: Overflow-Kontrolle verhindert horizontales Scrollen beim geöffneten Drawer */
  
  /* Table Reset for Grid Conversion */
  #CartDrawer .cart-items {
    width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
  }
  #CartDrawer .cart-items :is(th, td) {
    word-break: normal;
    overflow-wrap: anywhere;
    display: block !important; /* Prerequisite for Grid placement on cells */
    padding: 0 !important;     /* FIX HYP 1: Kill Ghost Paddings */
    margin: 0 !important;
    width: auto !important;
    border: none !important;
  }
  #CartDrawer .cart-items thead { display: none; } /* Table-Header: Ausblenden auf Mobile (kein Platz für Tabellen-Header) */

/* Media Column Foundation */
  #CartDrawer .cart-item__media { 
    width: var(--edm-mobile-media-col); 
    /* width: auto; */
    grid-column: 1; 
    grid-row: 1 / 3; 
    z-index: 2; 
  }
  #CartDrawer .cart-item__image {
    width: 100% !important; /* Container steuert die Breite via Grid */
    height: auto !important;
    max-width: 100%;
    display: block;
    border-radius: var(--edm-mobile-card-radius); /* Token Konsistenz */
    object-fit: cover;
  }

  /* --------------------------------------------------------
     2. MAIN GRID SYSTEM (The Card)
     -------------------------------------------------------- */

  /* Grid Definition: [Media] | [Content (Nested Grid)] | [Totals] */
  #CartDrawer .cart-items tr:is(.cart-item, .cart-item--bundle) {
    display: grid !important;
    /* Use minmax for content column robustness */
    grid-template-columns: var(--edm-mobile-media-col) minmax(0, 1fr) auto !important;
    grid-template-rows: auto auto auto auto !important;
    column-gap: var(--edm-gap);
    row-gap: 8px;
    
    /* Box Styling */
    background: #ffffff !important;
    padding: var(--edm-mobile-card-pad) !important;
    margin: 8px 0 16px 0 !important; /* Mehr Margin Bottom verhindert Shadow-Cutoff */
    border-radius: var(--edm-mobile-card-radius) !important;
    border: 1px solid rgba(255, 255, 255, 0.5) !important; /* Subtiler Border statt Full White */
    box-shadow: 0 8px 24px -4px rgba(0,0,0,0.12), 0 4px 12px rgba(0,0,0,0.04) !important;
    
    position: relative;
    z-index: 5;
  }

  /* --------------------------------------------------------
     3. CELL MAPPING (Where things go)
     -------------------------------------------------------- */

  /* Group 1: The Content Container (Spans Col 2-3) 
     Uses a Nested Grid to stack Name, Price, Variants vertically */
  #CartDrawer :is(.cart-item__details, tr.cart-item--bundle .cart-item__details) {
    display: grid !important;
    grid-column: 2 / 4 !important;
    grid-row: 1 / 3 !important;
    grid-template-rows: auto 1fr auto; /* Title | Price | Vars */
    align-content: start;
    min-width: 0;
    padding: 0 !important;
    margin: 0 !important;
    z-index: 3;
  }

  /* ROW 1 (Inside Content): Name */
  #CartDrawer :is(.cart-item__name, tr.cart-item--bundle .cart-item__name) {
    grid-row: 1 !important;
    grid-column: 1 / -1 !important;
    align-self: start !important;
    margin: 0 0 4px 0 !important;
    z-index: 3;
  }

  /* ROW 2 (Inside Content): Prices (Standard & Bundle) */
  #CartDrawer :is(
    .cart-item__details > .cart-item__discounted-prices,
    .cart-item__details > .product-option:first-of-type,
    tr.cart-item--bundle .cart-item__details > .bundle-price
  ) {
    grid-row: 2 !important;
    grid-column: 1 / -1 !important;
    align-self: end !important;
    margin: 0 0 2px 0 !important;
    z-index: 3;
  }

  /* ROW 3 (Inside Content): Variants & Lists */
  #CartDrawer :is(
    .cart-item__details > dl,
    tr.cart-item--bundle .cart-item__details > .bundle-variants
  ) {
    grid-row: 3 !important;
    grid-column: 1 / -1 !important;
    margin: 0 !important;
    padding: 0 !important;
    z-index: 3;
  }

  /* EXTERNAL CELLS (Outside Content Container) */
  
  /* Quantity (Col 2, Row 4) */
  #CartDrawer .cart-item__quantity {
    grid-column: 2 !important;
    grid-row: 4 !important;
    align-self: start !important;
    justify-content: flex-end !important; /* Right aligned per design */
    display: flex;
    gap: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    z-index: 1;
  }
  #CartDrawer .cart-item__quantity :is(cart-remove-button, .cart-remove-button) { position: static; transform: none; }

  /* Totals (Col 3, Row 4) */
  #CartDrawer .cart-item__totals {
    grid-column: 3 !important;
    grid-row: 4 !important;
    /* FIX 3: Vertical Center zur Quantity Row */
    align-self: center !important; 
    position: relative;
    /* Reset Padding/Margin für saubere Zentrierung */
    padding: 0 !important;
    margin: 0 !important;
  }

  /* --------------------------------------------------------
     4. TYPOGRAPHY & VISUALS (Consolidated)
     -------------------------------------------------------- */

  /* A. Main Text Color Enforcer (Global) */
  #CartDrawer :is(
    .cart-item__name, 
    .cart-item__details > .product-option:first-of-type, 
    .caption-with-letter-spacing, 
    .cart-item__totals .price,
    .cart-item__totals .unit-price,
    .cart-item__totals .caption,
    .cart-item__details > dl dt,
    .cart-item__details > dl dd,
    .bundle-variants__count,
    .bundle-variants__list > li,
    tr.cart-item--start-smart .cart-item__name,
    tr.cart-item--start-smart .bundle-variants__subtitle
  ) {
    color: var(--content-font-main-color) !important;
  }
  /* A.2 Discount Color Override */
  #CartDrawer :is(.bundle-price .bundle-discount, .cart-item__details .discounts__discount, .cart-item__details .discounts) {
    color: #D32F2F !important;
    font-weight: 700 !important;
    font-size: 0.85rem !important;
  }

  /* B. Headings & Names */
  #CartDrawer .cart-item__name {
    font-size: var(--mobile-price-font-size);
    font-weight: 700;
    line-height: 1.25;
    overflow-wrap: anywhere;
    word-break: break-word; /* Backwards compat */
  }

  /* C. Prices (Baseline & Layout) */
  #CartDrawer :is(.cart-item__discounted-prices, .bundle-price) {
    display: inline-flex;
    align-items: baseline;
    gap: 0.4em;
    flex-wrap: wrap;
    border-bottom: none !important; /* Bundle clean */
  }
  #CartDrawer .bundle-price::after { display: none !important; }

  /* D. Price Values (Font Sizes) */
  #CartDrawer :is(
    .cart-item__details > .product-option:first-of-type,
    .cart-item__final-price,
    .bundle-price .cart-item__final-price,
    .bundle-price .bundle-discount
  ) {
    font-size: var(--mobile-price-font-size) !important;
    font-weight: 400;
  }

  /* E. Secondary/Meta Text (Variants, Old Prices) */
  #CartDrawer :is(
    .cart-item__old-price,
    .cart-item__discounted-prices > .product-option:last-child,
    .bundle-price > .product-option:last-child,
    .cart-item__details > dl,
    .bundle-variants
  ) {
    font-weight: 400;
    font-size: 0.9375rem; /* Explicit size from original */
    color: var(--content-font-main-color) !important;
    opacity: 1;
  }
  
  /* Strikethroughs */
  #CartDrawer .cart-item__old-price {
    text-decoration: line-through;
    text-decoration-thickness: 1px;
    opacity: 0.65;
  }

  /* F. Totals (Specific Larger Size) */
  #CartDrawer .cart-item__totals :is(.price, .cart-item__price-wrapper, .cart-item__discounted-prices) {
    font-size: 1.125rem !important; /* Distinct from item price */
    line-height: 1.4;
    font-weight: 700;
    display: inline-block;
  }
  /* Totals Cleanups */
  #CartDrawer .cart-item__totals :is(.cart-item__old-price, s.price, .cart-item__discounted-prices s) { display: none !important; }
  #CartDrawer .cart-item__totals .cart-item__discounted-prices { display: block; }

  /* G. Bundle & List Specifics */
  #CartDrawer .bundle-variants__count { margin: 0 0 4px 0; font-weight: 700; }
  #CartDrawer .bundle-variants__list { list-style: none !important; margin: 0; padding-left: 0; list-style-position: outside; }
  #CartDrawer .bundle-variants__list > li { display: block !important; margin: 0.15em 0; }
  #CartDrawer tr.cart-item--start-smart .bundle-variants__subtitle { font-size: 0.8rem; margin-top: 4px; font-weight: 700; }
  /* Override hidden options for bundles */
  #CartDrawer tr.cart-item--bundle .cart-item__details > .product-option { display: block !important; }

  /* H. Global Hiders (Cleanups) */
  #CartDrawer .cart-item__details :is(
    .caption-with-letter-spacing, 
    .discounts, 
    .product-option:nth-of-type(n+2):not(.bundle-variants),
    dl:empty, 
    p.product-option:empty, 
    ul.discounts:empty
  ) { display: none !important; }
  #CartDrawer .cart-item__details > dl:not(:has(dt)) { display: none !important; }
  /* Definition List Formatting */
  #CartDrawer .cart-item__details > dl dt { margin-bottom: 0.05em; }
  #CartDrawer .cart-item__details > dl dd { margin: 0 0 0.2em !important; }
  #CartDrawer .cart-item__details > dl dd:last-child { margin-bottom: 0; }

  /* --------------------------------------------------------
     6. TINY SCREENS (≤ 380px)
     -------------------------------------------------------- */
  @media (max-width: 380px) {
    #CartDrawer .cart-item__media { width: 72px; }
    #CartDrawer .cart-item__image { width: 72px !important; }
    #CartDrawer .quantity__input { width: 3.2rem; }
    #CartDrawer .cart-item__totals .price { white-space: normal; }
  }

} 

/* ========================================
   I. DESKTOP-SPECIFIC (≥ 1024px)
   ======================================== */
@media (min-width: 1024px) {
  
/* --------------------------------------------------------
     1. STRUCTURAL RESET & CONTAINER
     -------------------------------------------------------- */
  
  /* Hard Reset for Table Elements to allow Block/Grid Context */
  #CartDrawer :is(.cart-items, .cart-items tbody, .cart-items tr, .cart-items td, .cart-items th) {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    border-collapse: collapse !important;
    box-shadow: none !important;
    background: transparent !important;
  }

  /* Structural Padding */
  .cart-drawer__container { padding: var(--desktop-outer-padding, 20px) !important; box-sizing: border-box !important; }
  #CartDrawer .drawer__footer { padding-bottom: var(--edm-pad-outer, 20px) !important; }

  /* --------------------------------------------------------
     2. MAIN GRID LAYOUT SYSTEM
     -------------------------------------------------------- */
  
  /* Grid Definition: [Image 96px] | [Content Elastic] | [Totals 140px] */
  #CartDrawer .cart-items tbody tr:is(.cart-item, .cart-item--bundle) {
    display: grid !important;
    grid-template-columns: 96px minmax(0, 1fr) 140px !important;
    grid-template-rows: auto auto auto !important; /* Title, Price/Qty, Extras */
    column-gap: var(--desktop-column-gap, 20px) !important;
    row-gap: 4px !important;
    align-items: start !important;
    
    /* Card Styling */
    background: #ffffff !important;
    padding: 20px !important;
    margin-bottom: var(--desktop-row-gap, 16px) !important;
    border-radius: 16px !important;
    border: 1px solid #ffffff !important;
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.18), 0 0 20px rgba(0,0,0,0.08) !important;
    position: relative;
    z-index: 5;
    transform: translateZ(0);
  }

  /* Clean up Phantom Borders */
  #CartDrawer .cart-item :is(td, .cart-item__totals, .cart-item__details)::before,
  #CartDrawer .cart-item :is(td, .cart-item__totals, .cart-item__details)::after {
    content: none !important; display: none !important;
  }

  /* --------------------------------------------------------
     3. CELL PLACEMENT (Mapping)
     -------------------------------------------------------- */

  /* --- LAYER 1 (BACKGROUND): DETAILS --- */
  /* Col 1: Image (Spans all rows) */
  #CartDrawer .cart-item__media {
    grid-column: 1 / 2 !important;
    grid-row: 1 / -1 !important;
    width: 100% !important;
    height: auto !important;
    z-index: 1 !important;
    overflow: visible !important;
  }
  #CartDrawer .cart-item__image {
    width: var(--edm-desktop-media-col, 96px) !important;
    height: var(--edm-desktop-media-col, 96px) !important;
    object-fit: contain !important;
  }

  /* Col 2: Content Container (Allows splitting children into Grid) */
  #CartDrawer .cart-item__details,
  #CartDrawer tr.cart-item--bundle .cart-item__details,
  #CartDrawer .cart-items .cart-item .cart-item__details {
    display: contents !important; 
  }

  /* --- LOGIC ROW 1: Titles --- */
  #CartDrawer :is(.cart-item__name, .bundle-variants__subtitle, .bundle-variants__count) {
    grid-column: 2 / -1 !important;
    grid-row: 1 !important;
    width: 100% !important;
    justify-self: start !important;
    padding-bottom: 4px !important;
    padding-right: 0 !important;
    white-space: normal !important;
    display: block !important;
  }

  /* --- LOGIC ROW 2: Prices (Layout) --- */
  #CartDrawer :is(.cart-item__details .cart-item__discounted-prices, .bundle-price, .cart-item__details > .product-option:first-of-type) {
    grid-column: 2 / 3 !important;
    grid-row: 2 !important;
    width: fit-content !important;
    max-width: 80% !important;
    margin: 4px 0 0 !important;
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: baseline !important;
    gap: 6px !important;
    line-height: 1.2 !important;
  }

  /* --- LOGIC ROW 3: Extras/Lists/Variants --- */
  #CartDrawer :is(.cart-item__details > .product-option:not(:first-of-type), .cart-item__details dl, .bundle-variants, .cart-item__details > ul.discounts) {
    grid-column: 2 / -1 !important;
    grid-row: 3 !important;
    width: 100% !important;
    justify-self: start !important;
    margin-top: 8px !important;
    display: block !important;
  }
  
  /* Specific: Bundle List items appear as blocks */
  #CartDrawer .bundle-variants__list { list-style: none !important; margin: 0 !important; padding: 0 !important; display: block !important; }
  #CartDrawer .bundle-variants__list li { display: block !important; margin-bottom: 2px !important; }

/* --------------------------------------------------------
     4. TYPOGRAPHY & VISUALS (Consolidated)
-------------------------------------------------------- */

  /* Shared Font Foundation (Name, Price, Bundle Items) */
  #CartDrawer :is(.cart-item__name, .bundle-variants__subtitle, .bundle-variants__count, .cart-item__final-price, .bundle-price .cart-item__final-price, .cart-item__details .price, .bundle-variants__list li, .cart-item__details > .product-option:first-of-type ) {
    font-size: var(--desktop-price-font-size, 1rem) !important;
    color: var(--content-font-main-color, #444444) !important;
    line-height: 1.3 !important;
    letter-spacing: normal !important;
  }

  /* Weights */
  #CartDrawer :is(.cart-item__name, .bundle-variants__subtitle, .bundle-variants__count) { font-weight: 700 !important; }
  
  /* Regular Weights (Removed strong tag to prevent overriding inherit) */
  #CartDrawer :is(.cart-item__final-price, .cart-item__details .price, .bundle-variants__list li) { font-weight: 400 !important; }
  
  /* Strict Inheritance for Bundle Count Strong logic */
  #CartDrawer .bundle-variants__count strong { font-weight: inherit !important; color: inherit !important; }

  /* Secondary Text (Meta info, lists in Row 3) */
  #CartDrawer :is(.cart-item__details > .product-option:not(:first-of-type), .cart-item__details dl, .bundle-variants,  .cart-item__details > ul.discounts) {
    font-size: 0.9em !important;
    line-height: 1.4 !important;
    color: rgba(var(--color-foreground), 0.75) !important;
  }

  /* Visual: Crossed Out Prices & Discounts */
  #CartDrawer :is(.bundle-price .cart-item__old-price, s.price) {
     text-decoration: line-through !important;
     opacity: 0.6 !important;
     font-size: 0.85rem !important;
     color: var(--content-font-main-color) !important;
     font-weight: 400 !important;
  }
  #CartDrawer .bundle-price .bundle-discount {
     font-weight: 700 !important;
     color: #D32F2F !important;
     font-size: 0.85rem !important;
  }
  /* Hide unwanted strikethrough in bundle totals */
  #CartDrawer tr.cart-item--bundle .cart-item__totals :is(s.price, .cart-item__old-price) { display: none !important; }

/* --------------------------------------------------------
     5. FOREGROUND LAYERS (Totals & Actions)
     -------------------------------------------------------- */
  
  /* Row 1: Totals (Overlays Title) */
  #CartDrawer .cart-item__totals {
    grid-column: 3 / 4 !important;
    grid-row: 1 !important;
    justify-self: end !important;
    text-align: right !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
    z-index: 10 !important;
    pointer-events: none !important; /* Click-through to title if needed */
  }
  
  #CartDrawer .cart-item__totals .price {
    font-weight: 700;
    text-align: right !important;
    /* Size/Color inherited from Shared Font Foundation if added, otherwise specific: */
    font-size: var(--desktop-price-font-size, 1rem) !important;
    color: var(--content-font-main-color) !important;
  }

  /* Row 2: Quantity (Overlays Details) */
  #CartDrawer .cart-item__quantity {
    grid-column: 3 / 4 !important;
    grid-row: 2 !important;
    justify-self: end !important;
    padding-top: 4px !important;
    display: flex !important;
    justify-content: flex-end !important;
    z-index: 10 !important;
  }

  /* --- COMPONENT: QUANTITY UI --- */
  
  #CartDrawer :is(.cart-item__quantity-wrapper, quantity-input, .quantity-popover-container) {
    width: auto !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 2px !important;
  }

  /* 1. Stepper Buttons (+ / -) */

  #CartDrawer .quantity__button {
    background-color: var(--content-background-color, #f4f4f4) !important;
    color: var(--content-font-main-color) !important;
    border: none !important;
    width: 28px !important; height: 28px !important;
    display: flex !important; align-items: center !important; justify-content: center !important;
    border-radius: 4px !important;
    transition: opacity 0.2s ease !important;
  }
  #CartDrawer .quantity__button:hover { opacity: 0.8 !important; }
  #CartDrawer .quantity__button svg { width: 10px !important; height: 10px !important; }
  
  /* 2. Input Field (Number) */

  #CartDrawer .quantity__input {
    width: 2.5rem !important;
    text-align: center !important;
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
    border: none !important;
    font-weight: 400 !important;
    color: var(--content-font-main-color) !important;
    -moz-appearance: textfield !important; /* Remove Spinner Arrows */
  }
  #CartDrawer .quantity__input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
  
  /* 3. Trash / Remove Button */

  #CartDrawer .cart-remove-button {
    margin-left: 8px !important;
    order: 2 !important;
    background: transparent !important; border: none !important; box-shadow: none !important;
    padding: 0 !important;
    width: auto !important; height: auto !important;
    min-width: unset !important; min-height: unset !important; /* Safety for Dawn defaults */
    display: flex !important; align-items: center !important;
  }
  #CartDrawer .cart-remove-button svg {
    width: 18px !important; height: 18px !important;
    color: var(--content-font-main-color) !important;
    opacity: 0.6 !important;
  }
  #CartDrawer .cart-remove-button:hover svg { opacity: 1 !important; }

  /* 4. Utils & Empty States */

  /* Loading Spinner Position Safe */
  #CartDrawer :is(.cart-item__totals, .cart-item__quantity) :is(loading-spinner, .loading-spinner):not(.hidden) {
    display: block !important;
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
  }
  /* Empty State Cleanup */
  #CartDrawer .cart-item__details :is(dl:empty, .product-option:empty, p:empty) { display: none !important; }
  /* Remove Vertical Lines from Prices (Dawn Specific) */
  #CartDrawer :is(.price--end, .price-item) { border-left: none !important; padding-left: 0 !important; }




