/**
 * Chemesis Core â€” Cart page styles.
 * Port of the approved Vercel cart body. Prefix: .chk-*.
 */

.chk-section {
  background: var(--ch-paper);
}

.chk-inner {
  padding-top: 2.5rem;
  padding-bottom: 5rem;
}

@media (min-width: 768px) {
  .chk-inner {
    padding-top: 3rem;
  }
}

.chk-status {
  margin: 0 0 1rem;
  font-size: 0.8125rem;
  color: #b32626;
}

.chk-grid {
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 1024px) {
  .chk-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr));
  }
}

.chk-main,
.chk-aside {
  min-width: 0;
}

@media (min-width: 1024px) {
  .chk-main {
    grid-column: span 8;
  }

  .chk-aside {
    grid-column: span 4;
  }
}

/* ------------------------------------------------------------------
   Table head
   ------------------------------------------------------------------ */
.chk-head {
  display: none;
}

@media (min-width: 768px) {
  .chk-head {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 1rem;
    border-bottom: 1px solid var(--ch-line);
    padding-bottom: 0.75rem;
  }

  .chk-head span {
    font-family: var(--ch-font-mono);
    font-size: var(--ch-type-label);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--ch-faint);
  }

  .chk-head-product {
    grid-column: span 6;
  }

  .chk-head span:not(.chk-head-product):not(.chk-head-total) {
    grid-column: span 2;
  }

  .chk-head-total {
    grid-column: span 2;
    text-align: right;
  }
}

/* ------------------------------------------------------------------
   Rows
   ------------------------------------------------------------------ */
.chk-rows {
  list-style: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border-radius: var(--ch-radius-md);
  border: 1px solid var(--ch-line);
  background: #fff;
}

@media (min-width: 768px) {
  .chk-rows {
    border: 0;
    border-radius: 0;
  }
}

.chk-row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  border-bottom: 1px solid var(--ch-line);
  padding: 1.25rem;
  transition: opacity 0.24s ease, transform 0.24s ease;
}

@media (min-width: 768px) {
  .chk-row {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 0;
  }
}

.chk-row.is-removing {
  opacity: 0;
  transform: translateX(6px);
}

.chk-row.is-busy {
  opacity: 0.6;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .chk-row {
    transition: none;
  }
}

/* Product cell */
.chk-cell-product {
  display: flex;
  align-items: center;
  gap: 1rem;
}

@media (min-width: 768px) {
  .chk-cell-product {
    grid-column: span 6;
  }
}

.chk-thumb {
  display: block;
  width: 5rem;
  flex-shrink: 0;
  text-decoration: none;
}

@media (min-width: 768px) {
  .chk-thumb {
    width: 6rem;
  }
}

.chk-thumb-stage {
  position: relative;
  display: block;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid var(--ch-line);
  border-radius: var(--ch-radius-md);
  background: radial-gradient(120% 90% at 50% 0%, #ffffff 0%, #eef1f6 55%, #e4e9f1 100%);
}

.chk-thumb-stage img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 9%;
}

.chk-thumb-neutral {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12%;
}

.chk-thumb-neutral img {
  position: static;
  width: 100%;
  height: auto;
  object-fit: contain;
  padding: 0;
}

.chk-ident {
  min-width: 0;
}

.chk-grade {
  margin: 0;
  font-family: var(--ch-font-mono);
  font-size: var(--ch-type-label);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ch-faint);
}

.chk-name {
  display: block;
  margin-top: 0.25rem;
  font-family: var(--ch-font-display);
  font-size: var(--ch-type-product-title);
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--ch-ink-900);
  text-decoration: none;
  transition: color 0.3s var(--ch-ease-expo);
}

.chk-name:hover {
  color: var(--ch-blue-600);
}

.chk-cas {
  margin: 0.25rem 0 0;
  font-family: var(--ch-font-mono);
  font-size: var(--ch-type-mono);
  line-height: 1rem;
  color: var(--ch-muted);
}

/* Price cell */
.chk-cell-price {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

@media (min-width: 768px) {
  .chk-cell-price {
    display: block;
    grid-column: span 2;
  }
}

.chk-mobile-label {
  font-family: var(--ch-font-mono);
  font-size: var(--ch-type-label);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ch-faint);
}

@media (min-width: 768px) {
  .chk-mobile-label {
    display: none;
  }
}

.chk-price {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
}

@media (min-width: 768px) {
  .chk-price {
    display: block;
  }
}

.chk-price-sale {
  font-size: var(--ch-type-body);
  line-height: 1.25rem;
  font-weight: 600;
  color: var(--ch-ink-900);
}

.chk-price-reg {
  font-family: var(--ch-font-mono);
  font-size: var(--ch-type-mono);
  color: var(--ch-faint);
  text-decoration: line-through;
}

@media (min-width: 768px) {
  .chk-price-reg {
    display: block;
    margin-top: 0.25rem;
  }
}

/* Quantity cell */
.chk-cell-qty {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

@media (min-width: 768px) {
  .chk-cell-qty {
    grid-column: span 2;
    justify-content: flex-start;
  }
}

.chk-qtybox {
  display: inline-flex;
  height: 2.75rem;
  align-items: center;
  border: 1px solid var(--ch-line);
  border-radius: var(--ch-radius-sm);
  background: #fff;
}

.chk-qty-btn {
  display: flex;
  height: 100%;
  width: 2.5rem;
  align-items: center;
  justify-content: center;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--ch-muted);
  cursor: pointer;
  transition: color 0.3s var(--ch-ease-expo);
}

.chk-qty-btn:hover {
  color: var(--ch-ink-900);
}

.chk-qty-btn[disabled] {
  opacity: 0.4;
  cursor: not-allowed;
}

.chk-qty {
  width: 2.75rem;
  height: 100%;
  border: 0;
  padding: 0;
  background: transparent;
  text-align: center;
  font-family: var(--ch-font-mono);
  font-size: var(--ch-type-body);
  color: var(--ch-ink-900);
}

body .chk-section .chk-qtybox input.chk-qty:focus {
  outline: 2px solid var(--ch-blue);
  outline-offset: -2px;
}

/* Total cell */
.chk-cell-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

@media (min-width: 768px) {
  .chk-cell-total {
    grid-column: span 2;
    justify-content: flex-end;
    gap: 1rem;
  }
}

.chk-line {
  font-size: var(--ch-type-body);
  line-height: 1.25rem;
  font-weight: 600;
  color: var(--ch-ink-900);
}

.chk-remove {
  display: flex;
  height: 2.25rem;
  width: 2.25rem;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ch-line);
  border-radius: var(--ch-radius-sm);
  background: transparent;
  color: var(--ch-faint);
  cursor: pointer;
  transition: border-color 0.3s var(--ch-ease-expo), color 0.3s var(--ch-ease-expo);
}

.chk-remove:hover {
  border-color: #fca5a5;
  color: #ef4444;
}

/* Under-row links */
.chk-under {
  margin-top: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.chk-continue {
  font-size: var(--ch-type-body-sm);
}

.chk-clear {
  border: 0;
  background: transparent;
  padding: 0;
  font-size: var(--ch-type-body-sm);
  color: var(--ch-faint);
  cursor: pointer;
  transition: color 0.3s var(--ch-ease-expo);
}

.chk-clear:hover {
  color: #ef4444;
}

/* ------------------------------------------------------------------
   Order summary
   ------------------------------------------------------------------ */
@media (min-width: 1024px) {
  .chk-summary {
    position: sticky;
    top: 7rem;
  }
}

.chk-summary {
  border-radius: var(--ch-radius-md);
  border: 1px solid var(--ch-line);
  background: #fff;
  padding: 1.75rem;
}

.chk-eyebrow {
  margin: 0;
  font-family: var(--ch-font-mono);
  font-size: var(--ch-type-label);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ch-faint);
}

.chk-summary-list {
  margin: 1.5rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.chk-summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.chk-summary-row dt {
  font-size: var(--ch-type-body-sm);
  line-height: 1.25rem;
  color: var(--ch-muted);
}

.chk-summary-row dd {
  margin: 0;
  font-family: var(--ch-font-mono);
  font-size: var(--ch-type-mono);
  line-height: 1.25rem;
  color: var(--ch-inktext, #1c2438);
}

.chk-savings {
  color: var(--ch-blue-600) !important;
}

.chk-muted {
  font-size: var(--ch-type-mono) !important;
  color: var(--ch-faint) !important;
}

.chk-summary-total {
  border-top: 1px solid var(--ch-line);
  padding-top: 0.75rem;
}

.chk-summary-total dt {
  font-size: var(--ch-type-body-sm);
  font-weight: 600;
  color: var(--ch-ink-900);
}

.chk-summary-total dd {
  font-family: var(--ch-font-display);
  font-size: var(--ch-type-price);
  line-height: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--ch-ink-900);
}

.chk-checkout {
  margin-top: 1.75rem;
  width: 100%;
  justify-content: center;
}

.chk-checkout.is-disabled {
  opacity: 0.45;
  pointer-events: none;
}

.chk-note {
  margin: 1rem 0 0;
  font-family: var(--ch-font-mono);
  font-size: var(--ch-type-mono);
  line-height: 1.625;
  color: var(--ch-faint);
}

/* ------------------------------------------------------------------
   Empty state
   ------------------------------------------------------------------ */
.chk-empty {
  border-radius: var(--ch-radius-md);
  border: 1px solid var(--ch-line);
  background: #fff;
  padding: 5rem 1.5rem;
  text-align: center;
}

.chk-empty-icon {
  display: flex;
  height: 3.5rem;
  width: 3.5rem;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  border-radius: 9999px;
  background: var(--ch-blue-100);
  color: var(--ch-blue-600);
}

.chk-empty-heading {
  margin: 1.5rem 0 0;
  font-family: var(--ch-font-display);
  font-size: var(--ch-type-h3);
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--ch-ink-900);
}

.chk-empty-text {
  margin: 0.75rem auto 0;
  max-width: 28rem;
  font-size: var(--ch-type-body);
  line-height: 1.65;
  color: var(--ch-muted);
}

.chk-empty-actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

/* ------------------------------------------------------------------
   Elementor kit shields for Cart blocks
   ------------------------------------------------------------------ */
body .chk-section button,
body .chk-section button:hover,
body .chk-section button:focus,
body .chk-section button:focus-visible {
  background: transparent;
  color: inherit;
  padding: 0;
}

body .chk-section .ch-btn-primary,
body .chk-section .ch-btn-primary:hover {
  background: var(--ch-blue);
  color: #fff;
  padding-inline: var(--ch-btn-padding);
}

body .chk-section .ch-btn-primary:hover {
  background: var(--ch-blue-600);
}

body .chk-section .ch-btn-outline {
  background: transparent;
  color: var(--ch-ink-900);
  padding-inline: var(--ch-btn-padding);
}

body .chk-section .ch-btn[disabled],
body .chk-section .ch-btn.is-disabled {
  opacity: 0.45;
  pointer-events: none;
}

body .chk-section .chk-qtybox input.chk-qty {
  width: 2.75rem;
  height: 100%;
  border: 0;
  padding: 0;
  background: transparent;
  text-align: center;
  font-family: var(--ch-font-mono);
  font-size: var(--ch-type-body);
  color: var(--ch-ink-900);
  box-shadow: none;
}
