*{box-sizing:border-box;margin:0;padding:0;}
body{font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;background:#fff;color:#1a1a1a;direction:rtl;}
html,body{width:100%;min-height:100%;overflow:hidden;}

/* DEMO BAR */
.demo-bar{background:#f5f3ef;border-bottom:1px solid #e0dbd2;padding:8px 40px;display:flex;align-items:center;justify-content:space-between;}
/* demo user state: segmented control (Guest / Logged in), not real authorisation */
.seg{display:inline-flex;gap:2px;padding:2px;background:#fff;border:1px solid #d4cfc7;border-radius:6px;}
.seg-btn{font:inherit;font-size:12px;line-height:16px;color:#555;background:transparent;border:0;border-radius:4px;padding:4px 12px;cursor:pointer;white-space:nowrap;transition:background-color .2s,color .2s;}
.seg-btn:hover{color:#1a1a1a;}
.seg-btn[aria-pressed="true"]{background:#1a1a1a;color:#fff;font-weight:600;cursor:default;}
.demo-tag{font-size:11px;color:#666;border:1px solid #d4cfc7;border-radius:4px;padding:3px 8px;}

/* HEADER */
.header{display:flex;align-items:center;padding:0 40px;height:56px;border-bottom:1px solid #e8e4dc;}
.header-icons{display:flex;gap:16px;align-items:center;}
.header-icons svg{width:20px;height:20px;cursor:pointer;}
.header-nav{flex:1;display:flex;justify-content:center;gap:28px;}
.header-nav a{font-size:13px;color:#1a1a1a;text-decoration:none;}
.header-nav a.active{font-weight:600;}
.logo{font-size:17px;font-weight:700;white-space:nowrap;}

/* PAGE */
.page{padding:40px 40px 60px;}
.page-title{text-align:center;font-size:20px;font-weight:700;margin-bottom:32px;}

/* GRID — 4 equal columns, cards stretch to same height */
.grid{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:16px;
  max-width:1200px;
  margin:0 auto;
  align-items:stretch;
}

/* CARD — flex column, full height */
.card{
  display:flex;
  flex-direction:column;
  border:none;
  background:#fff;
  direction:rtl; /* portfolio: Hebrew content stays RTL inside each card */
}
/* portfolio: approved visual order left to right (Kati, Salio, Ocean, Lonnie); the page and header stay RTL */
.grid{direction:ltr;}

/* IMAGE */
.card-img-wrap{position:relative;overflow:hidden;flex-shrink:0;}
.card-img-wrap img{width:100%;display:block;object-fit:cover;aspect-ratio:3/4;}
.trash-btn{
  position:absolute;top:10px;right:10px; /* portfolio: top-right corner, as in the approved Wishlist design */
  width:34px;height:34px;border-radius:50%;
  background:#fff;border:none;cursor:pointer;
  display:flex;align-items:center;justify-content:center;
  box-shadow:0 1px 4px rgba(0,0,0,.15);
}
.trash-btn img{width:16px;height:16px;}

/* STATUS BADGE */
.badge{padding:6px 12px;font-size:12px;text-align:right;flex-shrink:0;}
.badge.oos{background:#fce8ea;color:#c0392b;}
.badge.low{background:#fdf3e3;color:#a0600a;}
.badge.empty{visibility:hidden;}

/* CARD BODY — grows to fill remaining space, pushes button down */
.card-body{
  padding:10px 0 0;
  direction:rtl;
  display:flex;
  flex-direction:column;
  flex:1;
}
.card-name{font-size:13px;color:#1a1a1a;margin-bottom:2px;}
.card-price{font-size:13px;font-weight:600;margin-bottom:10px;}
.size-title{font-size:11px;color:#666;margin-bottom:6px;}

/* SIZE ROW — nowrap to keep all chips on one line */
.size-row{
  display:flex;
  flex-wrap:nowrap;
  gap:4px;
  margin-bottom:10px;
  overflow:visible;
}
.chip{
  display:inline-flex;align-items:center;justify-content:center;
  min-width:34px;height:30px;padding:0 5px;
  font-size:11px;border:1px solid #c8c4bc;border-radius:4px;
  cursor:pointer;background:#fff;color:#1a1a1a;
  transition:all .15s;white-space:nowrap;flex-shrink:0;
}
.chip:hover:not(.disabled){border-color:#1a1a1a;}
.chip.selected{border:1.5px solid #1a1a1a;font-weight:600;}
.chip.disabled{cursor:not-allowed;color:rgba(26,26,26,.55);border-color:#d4cfc7;background:rgba(0,0,0,.05);} /* portfolio: readable but clearly unavailable, same neutral disabled language as the Add to bag button */
.size-one{font-size:12px;color:#1a1a1a;margin-bottom:10px;}
.size-placeholder{height:40px;flex-shrink:0;}

/* SPACER pushes button to bottom */
.spacer{flex:1;}

/* BUTTONS — always at bottom */
.btn-wrap{flex-shrink:0;margin-top:0;}
.btn{
  width:100%;height:38px;border:none;
  font-size:13px;font-family:inherit;cursor:pointer;
  transition:opacity .15s;
}
.btn-primary{background:#1a1a1a;color:#fff;}
.btn-disabled{
  background:rgba(0,0,0,.05);
  color:rgba(26,26,26,.5);
  cursor:not-allowed;
}
.btn-confirmed{background:#e8f5e4;color:#2a6b2a;border:none;cursor:default;font-size:12px;}
.btn-notify{background:#fff;color:#1a1a1a;border:1px solid #c8c4bc;}
.btn-cancel{
  width:100%;height:34px;
  background:#fff;color:#1a1a1a;
  border:1px solid #c8c4bc;
  margin-top:6px;font-size:12px;
  font-family:inherit;cursor:pointer;
}

/* PANEL */
.panel-overlay{display:none;position:fixed;inset:0;background:rgba(0,0,0,.5);z-index:200;}
.panel-overlay.open{display:block;}
.panel{
  position:fixed;top:0;right:0;
  width:420px;max-width:100%;height:100%;
  background:#fff;z-index:201;
  display:flex;flex-direction:column;direction:rtl;
  transform:translateX(100%);transition:transform .25s;
}
.panel.open{transform:translateX(0);}
.panel-inner{padding:28px 28px 0;flex:1;min-height:0;overflow-y:auto;} /* portfolio: scrolls inside the panel when the visible area is short */
.panel-footer{padding:20px 28px 28px;border-top:1px solid #e8e4dc;}
.panel-close{
  background:none;border:none;cursor:pointer;
  font-size:22px;color:#666;margin-bottom:20px;
  display:block;text-align:left;direction:ltr;
}
.panel-title{font-size:16px;font-weight:700;margin-bottom:10px;}
.panel-sub{font-size:13px;color:#555;margin-bottom:18px;line-height:1.6;}
.chan-row{display:flex;gap:8px;margin-bottom:18px;direction:rtl;}
.chan-btn{
  flex:1;height:36px;font-size:13px;
  border:1px solid #c8c4bc;border-radius:4px;
  cursor:pointer;background:#fff;font-family:inherit;
}
.chan-btn.active{background:#1a1a1a;color:#fff;border-color:#1a1a1a;}
.field-label{font-size:12px;color:#555;margin-bottom:5px;text-align:right;}
.field-input{
  width:100%;height:38px;border:1px solid #c8c4bc;border-radius:4px;
  padding:0 12px;font-size:13px;font-family:inherit;
  direction:rtl;margin-bottom:16px;outline:none;
}
.field-input:focus{border-color:#1a1a1a;}
.consent-row{display:flex;align-items:flex-start;gap:8px;font-size:12px;color:#555;margin-bottom:0;cursor:pointer;}
.consent-row a{color:#1a1a1a;text-decoration:underline;}
.send-btn{width:100%;height:40px;border:none;font-size:13px;font-family:inherit;cursor:pointer;}
.send-btn:disabled{background:#e8e4dc;color:#aaa;cursor:not-allowed;}
.send-btn:not(:disabled){background:#1a1a1a;color:#fff;}

/* portfolio: Add to bag feedback. Bag count = TwentySix's header badge (black disc, white figure, over the icon's upper left) */
.bag-icon{position:relative;display:inline-flex;}
.bag-count{position:absolute;top:-6px;left:-8px;min-width:16px;height:16px;padding:0 4px;border-radius:8px;background:#1a1a1a;color:#fff;
  font-size:10px;font-weight:600;line-height:16px;text-align:center;direction:ltr;pointer-events:none;}
.bag-count[hidden]{display:none;}
.bag-count.pop{animation:bagPop 320ms cubic-bezier(.3,1.4,.5,1);}
@keyframes bagPop{from{transform:scale(.4);}60%{transform:scale(1.15);}to{transform:none;}}
.btn-added{display:flex;align-items:center;justify-content:center;gap:6px;cursor:default;} /* with .btn-confirmed: the prototype's own confirmation colours */
.btn-added svg{width:14px;height:14px;flex:none;}
.fly{position:absolute;z-index:150;background:#f2f0ec center/cover no-repeat;pointer-events:none;will-change:transform;}
.sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0;}
/* portfolio: keyboard focus, visible only for keyboard users */
.chip:focus-visible,.btn:focus-visible,.trash-btn:focus-visible,.chan-btn:focus-visible,.send-btn:focus-visible,.panel-close:focus-visible,.field-input:focus-visible,.consent-row input:focus-visible{outline:2px solid #1a1a1a;outline-offset:2px;}
.seg-btn:focus-visible{outline:2px solid #1a1a1a;outline-offset:2px;}
@media (prefers-reduced-motion: reduce){
  .chip,.btn,.seg-btn,.panel{transition:none;}
  .bag-count.pop{animation:none;}
}

@media (max-width: 900px){
  .demo-bar,.header,.page{padding-left:18px;padding-right:18px;}
  .header-nav{display:none;}
  .grid{grid-template-columns:repeat(2,1fr);}
}
@media (max-width: 560px){
  .grid{grid-template-columns:1fr;}
  .page{padding-top:24px;}
}

/* ===== migration (stage 6): from the markup, same effect ===== */
/* was style="display:none" on the cancel button (inline styles are not allowed by the strict CSP); the script still
   shows and hides it through its inline style */
#cancel-btn{display:none;}
/* product photos are <picture> (AVIF / WebP from the image pipeline): the wrapper takes no box, layout sees the <img> */
.card-img-wrap picture{display:contents;}


/* ===== portfolio: shopping bag drawer (Angela's After design of the bag): the restock panel component, its content as in the design ===== */
.bag-icon{cursor:pointer;}
.bag-icon:focus-visible{outline:2px solid #1a1a1a;outline-offset:4px;}
.cart-close{width:24px;height:24px;padding:0;margin:0 auto 20px 0;color:#1a1a1a;}
.cart-close svg{width:24px;height:24px;display:block;}
.cart-title{font-size:24px;font-weight:400;line-height:1.2;}
.cart-count{font-size:14px;margin-top:6px;}
.cart-ship{display:flex;align-items:center;gap:20px;background:#f2f2f2;padding:22px 24px;margin:20px 0 24px;}
.cart-ship-text{flex:1;}
.cart-ship-text p{font-size:13px;margin-bottom:12px;}
.cart-ship-bar{display:block;height:6px;border-radius:3px;background:#d9d9d9;overflow:hidden;}
.cart-ship-bar span{display:block;height:100%;width:0;background:#1a1a1a;border-radius:3px;transition:width .3s;}
.cart-ship-icon{width:34px;height:34px;flex:none;color:#1a1a1a;}
.cart-list{list-style:none;border-top:1px solid #ececec;}
.cart-item{display:grid;grid-template-columns:96px 1fr auto;gap:0 18px;padding:22px 0;border-bottom:1px solid #ececec;}
.cart-item-img{grid-row:1 / 3;width:96px;aspect-ratio:3/4;object-fit:cover;display:block;}
.cart-item-name{font-size:16px;}
.cart-item-size{font-size:13px;margin-top:8px;}
.cart-item-stock{font-size:12px;color:#c07d00;margin-top:8px;}
.cart-item-price{font-size:16px;font-weight:600;white-space:nowrap;}
.cart-item-actions{grid-column:2 / 4;display:flex;align-items:flex-end;justify-content:space-between;margin-top:14px;}
.cart-qty{display:inline-flex;align-items:center;border:1px solid #c8c4bc;height:36px;}
.cart-qty button{width:36px;height:100%;background:none;border:none;cursor:pointer;font-size:18px;color:#1a1a1a;font-family:inherit;}
.cart-qty span{min-width:24px;text-align:center;font-size:15px;}
.cart-remove{width:36px;height:36px;border:1px solid #c8c4bc;background:#fff;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;}
.cart-remove img{width:16px;height:16px;}
.cart-empty{font-size:14px;color:#555;padding:24px 0;}
.cart-footer{display:flex;flex-direction:column;gap:18px;}
.cart-sum{display:flex;justify-content:space-between;align-items:flex-start;}
.cart-sum-label{font-size:18px;font-weight:600;}
.cart-sum-value{font-size:18px;font-weight:600;text-align:left;}
.cart-vat{font-size:13px;color:#555;text-align:left;margin-top:4px;}
.cart-checkout{height:46px;font-size:14px;background:#1a1a1a;color:#fff;cursor:default;}
.cart.is-empty .cart-ship,.cart.is-empty .cart-footer,.cart.is-empty .cart-list{display:none;}
.cart:not(.is-empty) .cart-empty{display:none;}
.cart-qty button:focus-visible,.cart-remove:focus-visible,.cart-close:focus-visible{outline:2px solid #1a1a1a;outline-offset:2px;}
@media (max-width:600px){.cart-item{grid-template-columns:80px 1fr auto;gap:0 14px;}.cart-item-img{width:80px;}.cart-ship{padding:18px;}}
.cart-toast{position:absolute;left:50%;bottom:168px;transform:translate(-50%,8px);background:#1a1a1a;color:#fff;font-size:13px;padding:10px 16px;white-space:nowrap;opacity:0;pointer-events:none;transition:opacity .2s,transform .2s;}
.cart-toast.show{opacity:1;transform:translate(-50%,0);}
@media (prefers-reduced-motion: reduce){.cart-toast{transition:opacity .15s;transform:translate(-50%,0);}}
/* free shipping reached (owner's design 28.10.2026): green success state, same block size and layout */
.cart-ship-ok{display:none;width:34px;height:34px;flex:none;}
.cart-ship.is-free{background:#F4F8F1;color:#277B00;}
.cart-ship.is-free .cart-ship-icon{display:none;}
.cart-ship.is-free .cart-ship-ok{display:block;color:#277B00;animation:cartOkIn 280ms ease-out both;}
.cart-ship.is-free .cart-ship-tick{stroke-dasharray:18;animation:cartTick 280ms ease-out 60ms both;}
.cart-ship.is-free .cart-ship-bar{background:#D8E9D0;}
.cart-ship.is-free .cart-ship-bar span{background:#277B00;}
@keyframes cartOkIn{from{opacity:0;}to{opacity:1;}}
@keyframes cartTick{from{stroke-dashoffset:18;}to{stroke-dashoffset:0;}}
@media (prefers-reduced-motion: reduce){.cart-ship.is-free .cart-ship-ok,.cart-ship.is-free .cart-ship-tick{animation:none;}}
