/*
  ANNA PERLY — styly 1. kroku košíku
  Nahrát do Nastavení → Soubory, načítá se z patičky HTML kódů.
*/

/* ---------------------------------------------------------------- proměnné */
.ap-blk{
  --ap-gold:#CDA978;
  --ap-gold-soft:rgba(205,169,120,.12);
  --ap-ok:#1D7A52;
  --ap-ok-soft:rgba(29,122,82,.10);
  --ap-text:#141414;
  --ap-muted:#6F6B66;
  --ap-line:rgba(0,0,0,.09);
  font-family:"Source Sans 3",sans-serif;
  color:var(--ap-text);
}

/* ------------------------------------------- ukazatel dopravy zdarma */
.ap-progress{
  background:#fff;border:1px solid var(--ap-line);border-radius:14px;
  padding:14px 16px;margin:0 0 16px;
}
.ap-progress__head{
  display:flex;align-items:baseline;justify-content:space-between;
  gap:12px;margin-bottom:10px;
}
.ap-progress__title{font-size:15px;font-weight:700;line-height:1.3}
.ap-progress__title--done{color:var(--ap-ok)}
.ap-progress__hint{font-size:13px;color:var(--ap-muted);white-space:nowrap}
.ap-progress__track{height:6px;border-radius:6px;background:rgba(0,0,0,.07);overflow:hidden}
.ap-progress__bar{
  height:100%;border-radius:6px;background:var(--ap-gold);width:0;
  transition:width .35s ease;
}
.ap-progress__bar--done{background:var(--ap-ok)}

/* ------------------------------------------------ blok s dárkem (doplněk) */
/* Obsah vykresluje doplněk, my měníme jen umístění a vzhled. */
.up-cart-gifts-modal-trigger-wrapper{
  margin:0 0 16px !important;
}
.ap-cart .up-cart-gifts-modal-trigger-heading{
  margin:0 0 10px !important;
  font-family:"Exo 2",sans-serif;
  font-size:15px !important;
  font-weight:700 !important;
  line-height:1.25;
  text-align:left !important;
  color:var(--ap-text);
}
.ap-cart .up-cart-gifts-modal-trigger-container{
  display:flex;align-items:center;gap:14px;flex-wrap:wrap;
  background:var(--ap-ok-soft);
  border:1px solid rgba(29,122,82,.22);
  border-radius:14px;
  padding:12px 14px;
  margin:0 !important;
}
.ap-cart .up-cart-gifts-modal-trigger-thumbnails{
  display:flex;gap:8px;flex-shrink:0;margin:0;
}
.ap-cart .up-cart-gifts-modal-trigger-thumbnail img{
  width:56px;height:56px;object-fit:contain;
  background:#fff;border-radius:10px;
  border:1px solid var(--ap-line);
  display:block;
}
.ap-cart .up-cart-gifts-modal-trigger-content{
  flex:1 1 220px;min-width:0;
  display:flex;flex-direction:column;align-items:flex-start;gap:6px;
}
.ap-cart .up-cart-gifts-modal-trigger-header{
  font-size:14px;line-height:1.35;font-weight:700;color:var(--ap-ok);
}
/* Modal výběru dárků je v doplňku rozbitý (useknutý na desktopu,
   na mobilu mimo obrazovku bez možnosti zavřít). Do opravy tlačítko
   skrýváme. Až přibudou další dárky, tenhle blok smažte. */
.ap-cart .up-cart-gifts-modal-trigger-action{display:none !important}

/* dva a více dárků — mřížka místo řádku, beze změny kódu */
.ap-cart .up-cart-gifts-modal-trigger-thumbnails:has(> :nth-child(2)){
  flex-wrap:wrap;max-width:200px;
}

/* ------------------------------------------------------------- položky */
/* Shoptet hlásí dopravu zdarma podruhé pod cross-sellem, včetně vlastního
   proužku. Náš ukazatel je nahoře, tenhle už jen duplikuje. */
.ap-cart .extras-col.extras-separated{display:none !important}

/* nefunkční odkaz (cíl je vypnutý projektovým CSS) */
.cart-table a.show-related{display:none !important}

/* ------------------------------------------------------ sleva u položky */
.ap-price-wrap{
  display:inline-block;text-align:right;line-height:1.25;vertical-align:middle;
}
.ap-price-wrap .ap-save{display:block;margin:0 0 2px}
.ap-price-wrap .price-final{display:block}

.ap-save{font-size:inherit;font-weight:400;white-space:nowrap}
.ap-save s{color:#E24B4A;text-decoration:line-through}

/* slevu z doplňku vykreslujeme sami, jeho verzi vypínáme */
.ap-cart .up-addon-cart-cell{display:none}
.cart-table td.up-addon-cart-cell-classic{display:none !important}

.ap-sum__row--save > span:first-child{color:#8F715D !important;font-weight:600}
.ap-sum__val--save{color:#8F715D;font-weight:700}

.ap-delivery{
  display:block;font-size:13px;line-height:1.35;
  color:var(--ap-muted);margin-top:6px;
}
.ap-delivery b{color:var(--ap-text);font-weight:700}
.ap-delivery svg{
  width:15px;height:15px;stroke:currentColor;fill:none;stroke-width:2;
  stroke-linecap:round;stroke-linejoin:round;
  vertical-align:-3px;margin-right:5px;
}

/* ------------------------------------------------- slevový kupón */
.ap-cart .cart-summary{margin-top:10px}
.ap-cart .cart-summary > h2,
.ap-cart .cart-summary > .h4{display:none !important}

.ap-coupon-toggle{
  display:inline-flex;align-items:center;gap:9px;
  background:none;border:0;padding:10px 0;margin:0;
  font-family:"Source Sans 3",sans-serif;
  font-size:14px;font-weight:600;line-height:1.3;
  color:#B08F5E;cursor:pointer;text-align:left;
}
.ap-coupon-toggle:hover{color:var(--ap-gold)}
.ap-coupon-toggle:focus-visible{outline:2px solid var(--ap-gold);outline-offset:3px}
.ap-coupon-toggle svg{
  width:17px;height:17px;flex-shrink:0;
  stroke:currentColor;fill:none;stroke-width:2;
  stroke-linecap:round;stroke-linejoin:round;
  transition:transform .2s ease;
}
.ap-cart .cart-summary.ap-coupon-open .ap-coupon-toggle svg{transform:rotate(90deg)}

/* zabalené: pole schované, vidět je jen odkaz */
.ap-cart .cart-summary.ap-coupon:not(.ap-coupon-open) .extras-col.coupon-box{display:none}
.ap-cart .cart-summary.ap-coupon .extras-wrapper{margin-top:2px}
.ap-cart .cart-summary.ap-coupon .discount-coupon form{max-width:420px}

@media (prefers-reduced-motion:reduce){
  .ap-coupon-toggle svg{transition:none}
}

/* ------------------------------------------------------- souhrn ceny */
.ap-sum{
  border-bottom:1px solid var(--ap-line);
  padding-bottom:12px;margin-bottom:14px;
}
.ap-sum__row{
  display:flex;align-items:baseline;justify-content:space-between;
  gap:12px;font-size:14px;line-height:1.5;padding:3px 0;
}
.ap-sum__row > span:first-child{color:var(--ap-muted)}
.ap-sum__val{font-weight:600}
.ap-sum__val--free{color:var(--ap-ok);font-weight:700}
.ap-sum__val--pending{color:var(--ap-muted);font-weight:400;font-size:13px}

.sidebar-in-cart .price-label.price-secondary,
.sidebar-in-cart .price.price-secondary{
  font-size:12px !important;font-weight:400 !important;
  color:var(--ap-muted) !important;line-height:1.4 !important;
}
.sidebar-in-cart .price-label.price-primary{font-weight:700}

.ap-note{
  font-size:13px;line-height:1.4;color:var(--ap-muted);
  text-align:center;margin:10px 2px 0;
}

/* --------------------------------------------------------- trust box */
.ap-trust{
  background:#fff;border:1px solid var(--ap-line);border-radius:14px;
  padding:16px 18px;margin:14px 0 18px;
}
.ap-trust__title{
  font-family:"Exo 2",sans-serif;font-size:15px;font-weight:700;
  line-height:1.25;margin:0 0 12px;
}
.ap-trust__list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:10px}
.ap-trust__item{
  display:grid;grid-template-columns:20px 1fr;gap:11px;
  align-items:start;font-size:14px;line-height:1.4;
}
.ap-trust__item svg{
  width:18px;height:18px;margin-top:1px;stroke:var(--ap-gold);fill:none;
  stroke-width:2;stroke-linecap:round;stroke-linejoin:round;
}
.ap-trust__item b{font-weight:700}
.ap-trust__item span{color:var(--ap-muted)}
.ap-trust__phone{color:var(--ap-text);text-decoration:underline}

/* ------------------------------------------------- sticky lišta mobil */
.ap-sticky{
  display:none;position:fixed;left:0;right:0;bottom:0;z-index:950;
  background:#fff;border-top:1px solid var(--ap-line);
  box-shadow:0 -6px 18px rgba(0,0,0,.07);
  padding:10px 14px calc(10px + env(safe-area-inset-bottom));
  align-items:center;justify-content:space-between;gap:12px;
}
.ap-sticky__price{display:flex;flex-direction:column;line-height:1.15}
.ap-sticky__label{font-size:12px;color:var(--ap-muted)}
.ap-sticky__value{font-size:18px;font-weight:700}
.ap-sticky__btn{
  flex:0 0 auto;background:var(--ap-gold);color:#fff !important;
  border:0;border-radius:4px;padding:13px 22px;
  font-size:15px;font-weight:700;text-decoration:none !important;white-space:nowrap;
}
.ap-sticky__btn:focus-visible{outline:2px solid var(--ap-text);outline-offset:2px}

@media (max-width:767px){
  .ap-sticky.is-visible{display:flex}
  body.ap-has-sticky{padding-bottom:82px}
  .ap-progress{padding:12px 14px}
  .ap-progress__head{flex-direction:column;gap:2px;align-items:flex-start}
  .ap-progress__hint{white-space:normal}
  .ap-cart .up-cart-gifts-modal-trigger-container{gap:12px}
  .ap-cart .up-cart-gifts-modal-trigger-thumbnail img{width:48px;height:48px}
}

/* dotyková zařízení bez ohledu na šířku */
@media (hover:none){
  .cart-table .quantity .increase,
  .cart-table .quantity .decrease{min-width:44px;min-height:44px}
  .cart-table .remove-item{min-width:44px;min-height:44px}
}

@media (prefers-reduced-motion:reduce){
  .ap-progress__bar{transition:none}
}
