/*
 * Evo Peptides — Cart Styles v2
 * Path: your-child-theme/assets/css/evo-cart.css
 */

/* ── Variables ── */
#evocart {
  --blue:       #0071E3;
  --blue-h:     #0077ED;
  --bg:         #f5f5f7;
  --white:      #ffffff;
  --label:      #1d1d1f;
  --muted:      #6e6e73;
  --border:     #e8e8ed;
  --pill:       #e8e8ed;
  --pill-h:     #d1d1d6;
  --green:      #34c759;
  --red:        #ff3b30;
  --amber:      #b87800;
  --amber-bg:   #fff4e0;
  --shadow:     0 2px 8px rgba(0,0,0,0.06), 0 8px 28px rgba(0,0,0,0.08);
  --r-outer:    24px;
  --r-card:     18px;
}

/* ── Outer shell — matches #evofaq exactly ── */
#evocart {
  font-family: -apple-system, 'SF Pro Text', 'Inter', sans-serif;
  background: var(--bg);
  border-radius: var(--r-outer);
  padding: 44px 0 40px;
  max-width: 960px;
  margin: 32px auto 60px;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ── Header ── */
#evocart .hd {
  padding: 0 28px 28px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

#evocart .hd h2 {
  font-size: 26px;
  font-weight: 700;
  color: var(--label);
  letter-spacing: -0.3px;
  line-height: 1.2;
  margin: 0;
}

#evocart .hd h2 em {
  font-style: normal;
  color: var(--muted);
  font-weight: 400;
}

#evocart .item-count {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}

/* ── Cart items list ── */
.evo-cart-items {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 0 28px;
}

/* ── Cart card ── */
.evo-cart-card {
  background: var(--white);
  border-radius: var(--r-card);
  padding: 16px;
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: 60px 1fr auto;
  grid-template-rows: auto;
  gap: 0 12px;
  align-items: center;
  transition: box-shadow 0.18s, opacity 0.26s, transform 0.26s;
}

.evo-cart-card:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.08), 0 12px 36px rgba(0,0,0,0.10);
}

.evo-cart-card.removing {
  opacity: 0;
  transform: translateX(18px) scale(0.97);
  pointer-events: none;
}

/* ── Thumbnail ── */
.evo-thumb {
  width: 60px;
  height: 60px;
  border-radius: 14px;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  grid-row: 1 / 3;
}

.evo-thumb img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  display: block;
}

.evo-thumb svg {
  color: var(--blue);
  flex-shrink: 0;
}

/* ── Product meta ── */
.evo-meta {
  min-width: 0;
  padding-right: 8px;
}

.evo-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 4px;
  line-height: 1;
}

.evo-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--label);
  line-height: 1.3;
  letter-spacing: -0.1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.evo-name a {
  color: inherit;
  text-decoration: none;
}

.evo-name a:hover { color: var(--blue); }

.evo-sub {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.5;
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Controls column ── */
.evo-controls {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  flex-shrink: 0;
}

.evo-price {
  font-size: 15px;
  font-weight: 700;
  color: var(--label);
  letter-spacing: -0.2px;
  white-space: nowrap;
}

/* Hide WC currency spans from breaking layout */
.evo-price .woocommerce-Price-currencySymbol { font-size: inherit; }

/* ── Qty stepper ── */
.evo-qty-row {
  display: flex;
  align-items: center;
  background: var(--pill);
  border-radius: 100px;
  overflow: hidden;
  height: 34px;
}

.evo-qty-btn {
  width: 34px;
  height: 34px;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  flex-shrink: 0;
  color: var(--label);
  transition: background 0.12s, transform 0.1s;
  border-radius: 100px;
  -webkit-tap-highlight-color: transparent;
}

.evo-qty-btn:hover  { background: var(--pill-h); }
.evo-qty-btn:active { transform: scale(0.88); }

.evo-qty-input {
  width: 28px;
  height: 34px;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  color: var(--label);
  text-align: center;
  padding: 0;
  -moz-appearance: textfield;
  appearance: textfield;
  cursor: default;
  pointer-events: none;
}

.evo-qty-input::-webkit-outer-spin-button,
.evo-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* ── Remove button ── */
.evo-remove {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: 0.2px;
  transition: color 0.12s;
  cursor: pointer;
  display: block;
}

.evo-remove:hover { color: var(--red); }

/* ── Divider ── */
.evo-divider {
  height: 1px;
  background: var(--border);
  margin: 20px 28px 0;
}

/* ── Summary card ── */
.evo-summary-card {
  background: var(--white);
  border-radius: var(--r-card);
  padding: 20px;
  box-shadow: var(--shadow);
  margin: 14px 28px 0;
}

/* Badge */
.evo-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 100px;
  margin-bottom: 14px;
}

.evo-badge--green { background: #e8f4ff; color: var(--blue); }
.evo-badge--amber { background: var(--amber-bg); color: var(--amber); }

/* Summary rows */
.evo-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 5px 0;
  gap: 12px;
}

.evo-row > span:first-child {
  font-size: 14px;
  color: var(--muted);
  font-weight: 500;
  flex-shrink: 0;
}

.evo-val {
  font-size: 14px;
  color: var(--label);
  font-weight: 600;
  text-align: right;
}

.evo-val strong, .evo-val bdi { font-weight: 600; font-size: inherit; }

.evo-row--total > span:first-child {
  font-size: 16px;
  font-weight: 700;
  color: var(--label);
}

.evo-row--total .evo-val {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.2px;
}

.evo-sep {
  height: 1px;
  background: var(--border);
  margin: 10px 0;
}

/* ── Shipping options — styled pills ── */
.evo-row--shipping {
  align-items: flex-start;
  flex-direction: column;
  gap: 8px;
}

.evo-row--shipping > span:first-child {
  font-size: 14px;
  color: var(--muted);
  font-weight: 500;
}

.evo-ship-options {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}

.evo-ship-label {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 12px;
  background: var(--bg);
  cursor: pointer;
  transition: background 0.12s;
  border: 1.5px solid transparent;
}

.evo-ship-label:hover { background: var(--border); }

.evo-ship-label--active {
  border-color: var(--blue);
  background: #e8f4ff;
}

/* Hide native radio, use custom indicator */
.evo-ship-radio {
  appearance: none;
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: var(--white);
  flex-shrink: 0;
  transition: border-color 0.12s, background 0.12s;
  position: relative;
  cursor: pointer;
}

.evo-ship-radio:checked {
  border-color: var(--blue);
  background: var(--blue);
  box-shadow: inset 0 0 0 3px var(--white);
}

.evo-ship-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--label);
  flex: 1;
}

.evo-ship-cost {
  font-size: 13px;
  font-weight: 700;
  color: var(--label);
  margin-left: auto;
}

.evo-ship-cost .free {
  color: var(--green);
}

/* ── Promo row ── */
.evo-promo-form { margin: 0; }

.evo-promo-row {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

.evo-promo-input {
  flex: 1;
  height: 42px;
  border-radius: 12px;
  border: 1.5px solid var(--border);
  background: var(--bg);
  padding: 0 14px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--label);
  outline: none;
  transition: border-color 0.15s;
  -webkit-appearance: none;
}

.evo-promo-input::placeholder { color: #aeaeb2; }
.evo-promo-input:focus { border-color: var(--blue); }

.evo-promo-btn {
  height: 42px;
  padding: 0 18px;
  border-radius: 12px;
  background: var(--pill);
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--label);
  white-space: nowrap;
  transition: background 0.12s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
}

.evo-promo-btn:hover  { background: var(--pill-h); }
.evo-promo-btn:active { transform: scale(0.96); }

/* ── CTA buttons ── */
.evo-cta {
  padding: 14px 28px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.evo-checkout-btn {
  display: block;
  width: 100%;
  height: 52px;
  line-height: 52px;
  border-radius: 14px;
  background: var(--blue);
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  letter-spacing: -0.2px;
  box-shadow: 0 4px 16px rgba(0,113,227,0.28);
  transition: background 0.12s, transform 0.1s, box-shadow 0.12s;
  -webkit-tap-highlight-color: transparent;
  padding: 0;
}

.evo-checkout-btn:hover  { background: var(--blue-h); color: #fff; box-shadow: 0 6px 20px rgba(0,113,227,0.36); }
.evo-checkout-btn:active { transform: scale(0.98); color: #fff; }

.evo-continue-btn {
  display: block;
  width: 100%;
  height: 44px;
  line-height: 44px;
  border-radius: 14px;
  background: var(--pill);
  color: var(--muted);
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  transition: background 0.12s, transform 0.1s;
  -webkit-tap-highlight-color: transparent;
  padding: 0;
}

.evo-continue-btn:hover  { background: var(--pill-h); color: var(--muted); }
.evo-continue-btn:active { transform: scale(0.98); }

/* ── Trust strip ── */
.evo-trust {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 20px 28px 0;
}

.evo-trust-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.evo-trust-item svg { color: var(--blue); flex-shrink: 0; }

/* ── Nav dots ── */
.evo-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px 0;
}

.evo-dots { display: flex; gap: 5px; align-items: center; }

.evo-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #c7c7cc;
  transition: all 0.22s ease;
}

.evo-dot--on {
  width: 20px;
  border-radius: 3px;
  background: var(--label);
}

.evo-step {
  font-size: 11px;
  font-weight: 600;
  color: #aeaeb2;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

/* ── Empty state ── */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 60px 28px;
}

.empty-state svg  { color: #c7c7cc; margin-bottom: 18px; }
.empty-state h3   { font-size: 18px; font-weight: 700; color: var(--label); margin: 0 0 6px; letter-spacing: -0.2px; }
.empty-state p    { font-size: 14px; color: var(--muted); line-height: 1.6; margin: 0 0 20px; }

.evo-btn-shop {
  display: inline-block;
  height: 44px;
  line-height: 44px;
  padding: 0 28px;
  border-radius: 14px;
  background: var(--blue);
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(0,113,227,0.28);
  transition: background 0.12s, transform 0.1s;
}

.evo-btn-shop:hover  { background: var(--blue-h); color: #fff; }
.evo-btn-shop:active { transform: scale(0.97); }

/* ── WC notices ── */
#evocart .woocommerce-message,
#evocart .woocommerce-error,
#evocart .woocommerce-info {
  margin: 0 28px 16px;
  border-radius: 12px;
  border-top: none !important;
  padding: 12px 16px;
  font-size: 13px;
  list-style: none;
}

/* ── Loading overlay on card ── */
.evo-cart-card.evo-loading {
  opacity: 0.5;
  pointer-events: none;
}

/* ── MOBILE: ≤ 600px ── */
@media (max-width: 600px) {

  #evocart {
    border-radius: 18px;
    padding: 28px 0 28px;
    margin: 12px 0 32px;
  }

  #evocart .hd { padding: 0 16px 20px; }
  #evocart .hd h2 { font-size: 20px; }

  .evo-cart-items { padding: 0 16px; gap: 8px; }

  .evo-cart-card {
    grid-template-columns: 52px 1fr auto;
    gap: 0 10px;
    padding: 14px;
  }

  .evo-thumb {
    width: 52px;
    height: 52px;
    border-radius: 12px;
  }

  .evo-thumb img { width: 52px; height: 52px; }

  .evo-name { font-size: 13px; }
  .evo-sub  { display: none; } /* hide on very small screens */
  .evo-price { font-size: 14px; }

  .evo-qty-btn { width: 30px; height: 30px; }
  .evo-qty-row { height: 30px; }
  .evo-qty-input { height: 30px; font-size: 13px; }

  .evo-summary-card { margin: 12px 16px 0; padding: 16px; }
  .evo-cta          { padding: 12px 16px 0; }
  .evo-trust        { padding: 16px 16px 0; gap: 10px; }
  .evo-nav          { padding: 16px 16px 0; }
  .evo-divider      { margin: 16px 16px 0; }

  .evo-checkout-btn { font-size: 15px; height: 48px; line-height: 48px; }
  .evo-trust-item   { font-size: 10px; }

}

/* ── VERY SMALL: ≤ 380px ── */
@media (max-width: 380px) {
  .evo-cart-card {
    grid-template-columns: 1fr auto;
  }
  .evo-thumb { display: none; }
  .evo-trust { flex-direction: column; align-items: flex-start; }
}

/* Fix qty buttons — override Hello Elementor */
body.evo-cart-page .evo-qty-btn {
    width: 30px !important;
    height: 30px !important;
    min-width: unset !important;
    min-height: unset !important;
    padding: 0 !important;
    border-radius: 100px !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    font-size: 0 !important;
    line-height: 0 !important;
}

body.evo-cart-page .evo-qty-row {
    height: 30px !important;
    border-radius: 100px !important;
    background: #e8e8ed !important;
    overflow: hidden !important;
    display: inline-flex !important;
    align-items: center !important;
    width: auto !important;
}

body.evo-cart-page .evo-qty-input {
    width: 28px !important;
    height: 30px !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    text-align: center !important;
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
}

/* Fix promo Apply button */
body.evo-cart-page .evo-promo-btn {
    height: 42px !important;
    min-height: unset !important;
    min-width: unset !important;
    padding: 0 18px !important;
    border-radius: 12px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    background: #e8e8ed !important;
    color: #1d1d1f !important;
    border: none !important;
    box-shadow: none !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
}
/* Shipping radio — show checkmark when selected */
#evocart .evo-ship-radio:checked + .evo-ship-name::before {
    content: '';
}

#evocart .evo-ship-label--active .evo-ship-radio {
    border-color: #0071E3 !important;
    background: #0071E3 !important;
    box-shadow: inset 0 0 0 3px #fff !important;
}

#evocart .evo-ship-label--active {
    border-color: #0071E3 !important;
    background: #e8f4ff !important;
}

#evocart .evo-ship-radio {
    appearance: none !important;
    -webkit-appearance: none !important;
    width: 16px !important;
    height: 16px !important;
    min-width: 16px !important;
    min-height: 16px !important;
    border-radius: 50% !important;
    border: 2px solid #d1d1d6 !important;
    background: #fff !important;
    flex-shrink: 0 !important;
    cursor: pointer !important;
    transition: all 0.15s !important;
}

#evocart .evo-ship-radio:checked {
    border-color: #0071E3 !important;
    background: #0071E3 !important;
    box-shadow: inset 0 0 0 3px #fff !important;
}