/* ==========================================================
   OG CART ENGINE 1.0
   Matches OG Shop visual language — scoped to .og-cart-page
   ========================================================== */

.og-cart-page {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 54px 20px 80px;
  /* Avoid overflow containment here — it breaks desktop sticky Order Summary. */
}

.og-cart-eyebrow {
  margin: 0 0 14px;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #0878ff;
}

/* ---------- Hero ---------- */

.og-cart-hero {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 280px;
  padding: 54px 38px;
  border-radius: 34px;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 82% 22%, rgba(255, 255, 255, 0.18), transparent 28%),
    radial-gradient(circle at 88% 82%, rgba(8, 120, 255, 0.42), transparent 34%),
    linear-gradient(135deg, #061936 0%, #07346f 52%, #0878ff 130%);
  box-shadow: 0 28px 80px rgba(7, 27, 59, 0.18);
}

.og-cart-hero::after {
  content: "";
  position: absolute;
  right: -1%;
  bottom: -30%;
  width: min(42vw, 500px);
  height: min(42vw, 500px);
  background: url("../branding/og-signature.png") center / contain no-repeat;
  opacity: 0.08;
  pointer-events: none;
  user-select: none;
}

.og-cart-hero-copy {
  position: relative;
  z-index: 2;
  max-width: 760px;
}

.og-cart-hero .og-cart-eyebrow {
  color: #8bc2ff;
}

.og-cart-hero h1 {
  margin: 0;
  font-size: clamp(36px, 6vw, 72px);
  line-height: 0.95;
  letter-spacing: -0.055em;
}

.og-cart-hero-copy > p:last-child {
  max-width: 620px;
  margin: 18px 0 0;
  font-size: 18px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.82);
}

.og-cart-continue {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 0 24px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-weight: 900;
  text-decoration: none;
  transition: transform 0.22s ease, background 0.22s ease, box-shadow 0.22s ease;
}

.og-cart-continue:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.18);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.18);
  color: #fff;
}

/* ---------- Empty State ---------- */

.og-cart-empty {
  margin-top: 34px;
  padding: 48px 38px;
  border-radius: 30px;
  background: #fff;
  border: 1px solid #e8eef6;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.08);
  text-align: center;
}

.og-cart-empty h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1;
  letter-spacing: -0.04em;
  color: #071b3b;
}

.og-cart-empty p {
  max-width: 560px;
  margin: 16px auto 0;
  font-size: 18px;
  line-height: 1.55;
  color: #516176;
}

.og-cart-empty-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  margin-top: 28px;
  padding: 0 28px;
  border-radius: 999px;
  background: #0878ff;
  color: #fff;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 18px 38px rgba(8, 120, 255, 0.26);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.og-cart-empty-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 48px rgba(8, 120, 255, 0.32);
  color: #fff;
}

/* ---------- Layout ---------- */

.og-cart-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 380px);
  grid-template-areas:
    "items summary"
    "keep-shopping summary";
  gap: 28px;
  align-items: start;
  margin-top: 34px;
}

.og-cart-items {
  grid-area: items;
  display: grid;
  gap: 22px;
  min-width: 0;
}

.og-cart-summary {
  grid-area: summary;
}

.og-cart-keep-shopping {
  grid-area: keep-shopping;
}

/* ---------- Cart Item Cards ---------- */

.og-cart-item {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 24px;
  padding: 24px;
  border-radius: 30px;
  background: #fff;
  border: 1px solid #e8eef6;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.08);
  scroll-margin-top: calc(var(--og-header-height, 72px) + 16px);
  align-items: start;
}

.og-cart-item-media {
  align-self: start;
  width: 100%;
  max-width: 180px;
  aspect-ratio: 4 / 3;
  min-height: 0;
  border-radius: 22px;
  overflow: hidden;
  background:
    radial-gradient(circle at 30% 20%, rgba(8, 120, 255, 0.18), transparent 34%),
    linear-gradient(145deg, #f8fbff 0%, #ddebff 100%);
}

.og-cart-item-image-link {
  display: block;
  width: 100%;
  height: auto;
}

.og-cart-item-media img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 180px;
  min-height: 0;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.og-cart-item-media.has-artwork-preview img {
  object-fit: contain;
  background: #fff;
}

.og-cart-item-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

.og-cart-item-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.og-cart-item-eyebrow {
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: #0878ff;
}

.og-cart-item-title {
  margin: 0;
  font-size: clamp(22px, 3vw, 30px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.og-cart-item-title a {
  color: #071b3b;
  text-decoration: none;
}

.og-cart-item-title a:hover {
  color: #0878ff;
}

.og-cart-item-price {
  flex: 0 0 auto;
  font-size: 22px;
  font-weight: 950;
  color: #071b3b;
  white-space: nowrap;
}

.og-cart-item-price .woocommerce-Price-amount {
  color: inherit;
}

/* ---------- Item Meta / Options ---------- */

.og-cart-item-meta {
  overflow: hidden;
  padding: 16px 18px;
  border-radius: 18px;
  background: #f8fbff;
  border: 1px solid #e2ebf7;
}

.og-cart-item-summary {
  display: grid;
  gap: 10px;
}

.og-cart-item-summary-compact {
  display: grid;
  gap: 8px;
}

.og-cart-item-summary-row {
  display: grid;
  grid-template-columns: minmax(72px, 88px) minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
}

.og-cart-item-summary-label {
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0878ff;
}

.og-cart-item-summary-value {
  font-size: 15px;
  font-weight: 800;
  line-height: 1.45;
  color: #071b3b;
}

.og-cart-item-summary-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  width: fit-content;
  margin: 2px 0 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: #0878ff;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.og-cart-item-summary-toggle:hover,
.og-cart-item-summary-toggle:focus-visible {
  color: #055fcc;
  outline: none;
}

.og-cart-item-summary-indicator {
  font-size: 12px;
  line-height: 1;
}

.og-cart-item-summary-details-heading {
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0878ff;
}

.og-cart-item-summary-details[hidden] {
  display: none !important;
}

.og-cart-item-meta dl {
  margin: 0;
}

.og-cart-item-meta dl.variation {
  display: grid;
  gap: 10px;
}

.og-cart-item-meta dt {
  margin: 0;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0878ff;
}

.og-cart-item-meta dd {
  margin: 4px 0 0;
  font-size: 15px;
  line-height: 1.45;
  color: #516176;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.og-cart-item-meta dd p {
  margin: 0;
}

/* ---------- Item Actions ---------- */

.og-cart-item-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
  margin-top: auto;
}

.og-cart-edit,
.og-cart-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.og-cart-edit {
  border: 1px solid #d7e3f1;
  background: #fff;
  color: #071b3b;
}

.og-cart-edit:hover {
  transform: translateY(-2px);
  border-color: #0878ff;
  color: #0878ff;
}

.og-cart-remove {
  color: #b42318;
  background: #fff5f5;
  border: 1px solid #fecaca;
}

.og-cart-remove:hover {
  transform: translateY(-2px);
  background: #fee2e2;
  color: #991b1b;
}

/* ---------- Order Summary ---------- */

.og-cart-summary-sentinel {
  display: block;
  width: 100%;
  height: 1px;
  margin: 0;
  padding: 0;
  overflow: hidden;
  visibility: hidden;
  pointer-events: none;
}

.og-cart-summary {
  grid-area: summary;
  align-self: start;
  padding: 28px;
  border-radius: 30px;
  background: #fff;
  border: 1px solid #e8eef6;
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.12);
}

.og-cart-summary .og-order-summary-toggle {
  display: none;
}

@media (min-width: 981px) {
  .og-cart-summary {
    position: sticky;
    top: var(--og-summary-sticky-top, 96px);
    max-height: calc(100vh - var(--og-summary-sticky-top, 96px) - 24px);
    overflow: auto;
    align-self: start;
  }
}

.og-cart-summary.is-stuck {
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.16);
}

.og-cart-summary-title {
  margin: 0 0 22px;
  font-size: clamp(26px, 3vw, 34px);
  line-height: 1;
  letter-spacing: -0.04em;
  color: #071b3b;
}

.og-cart-summary-row,
.og-cart-summary-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.og-cart-summary-row {
  padding: 12px 0;
  border-bottom: 1px solid #edf2f8;
  font-size: 15px;
  color: #516176;
}

.og-cart-summary-row strong {
  color: #071b3b;
  font-weight: 900;
  text-align: right;
}

.og-cart-summary-total {
  margin-top: 8px;
  padding: 18px 0 0;
  font-size: 17px;
  font-weight: 900;
  color: #071b3b;
}

.og-cart-summary-total strong {
  font-size: clamp(24px, 3vw, 30px);
  letter-spacing: -0.03em;
}

.og-cart-checkout {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 58px;
  margin-top: 24px;
  border-radius: 999px;
  background: #0878ff;
  color: #fff;
  font-size: 17px;
  font-weight: 950;
  text-decoration: none;
  box-shadow: 0 18px 38px rgba(8, 120, 255, 0.26);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.og-cart-checkout:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 48px rgba(8, 120, 255, 0.32);
  color: #fff;
}

.og-cart-checkout.is-blocked,
.og-cart-checkout.is-blocked:hover {
  background: #9eb0c8;
  box-shadow: none;
  transform: none;
  cursor: not-allowed;
  pointer-events: auto;
}

.og-cart-checkout-gate-summary,
.og-cart-artwork-gate-error {
  margin: 12px 0 0;
  font-size: 13px;
  line-height: 1.5;
  font-weight: 800;
  color: #c62828;
  text-align: center;
}

.og-cart-artwork-gate-error {
  text-align: left;
}

.og-cart-artwork-extras.has-gate-error .og-cart-artwork-files {
  border-color: rgba(198, 40, 40, 0.35);
}

.og-cart-item.has-artwork-gate-error {
  box-shadow: inset 0 0 0 1px rgba(198, 40, 40, 0.18);
}

.og-cart-secure {
  margin: 16px 0 0;
  font-size: 13px;
  line-height: 1.5;
  text-align: center;
  color: #516176;
}

/* ---------- Keep Shopping ---------- */

.og-cart-keep-shopping {
  padding: 20px 22px;
  border-radius: 24px;
  background: #fff;
  border: 1px solid #e8eef6;
  box-shadow: 0 12px 36px rgba(15, 23, 42, 0.06);
}

.og-cart-keep-shopping-title {
  margin: 0 0 14px;
  font-size: 13px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0878ff;
}

.og-cart-keep-shopping-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.og-cart-keep-shopping-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid #d7e3f1;
  background: #f8fbff;
  color: #071b3b;
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
  transition: transform 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.og-cart-keep-shopping-link:hover {
  transform: translateY(-1px);
  border-color: #0878ff;
  color: #0878ff;
}

/* ---------- Toast ---------- */

.og-cart-toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--og-mobile-nav-height, 72px) + 18px);
  z-index: 120;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  background: #071b3b;
  color: #fff;
  font-size: 14px;
  font-weight: 900;
  box-shadow: 0 16px 40px rgba(7, 27, 59, 0.28);
  opacity: 0;
  transform: translate(-50%, 12px);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.og-cart-toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

@media (min-width: 769px) {
  .og-cart-toast {
    bottom: 32px;
  }
}

.og-cart-unavailable {
  max-width: 1320px;
  margin: 40px auto;
  padding: 0 20px;
  color: #516176;
}

/* ---------- Responsive ---------- */

@media (max-width: 980px) {
  .og-cart-layout {
    grid-template-columns: 1fr;
    grid-template-areas:
      "items"
      "summary"
      "keep-shopping";
  }

  .og-cart-items {
    order: 1;
  }

  .og-cart-summary {
    order: 2;
    position: static;
    top: auto;
    bottom: auto;
    z-index: auto;
    max-height: none;
    overflow: visible;
    border-radius: 30px;
    box-shadow: 0 22px 60px rgba(15, 23, 42, 0.12);
  }

  .og-cart-keep-shopping {
    order: 3;
  }
}

@media (max-width: 720px) {
  .og-cart-page {
    padding-top: 34px;
    padding-bottom: 120px;
  }

  .og-cart-hero {
    padding: 34px 24px;
    min-height: 0;
  }

  .og-cart-hero::after {
    right: 50%;
    bottom: -5%;
    transform: translateX(50%);
    width: 360px;
    height: 360px;
    opacity: 0.08;
}

  .og-cart-continue {
    width: 100%;
  }

  .og-cart-item {
    grid-template-columns: 1fr;
  }

  .og-cart-item-media {
    max-width: none;
    aspect-ratio: 16 / 10;
  }

  .og-cart-item-media img {
    max-height: 220px;
    aspect-ratio: 16 / 10;
  }

  .og-cart-item-head {
    flex-direction: column;
  }

  .og-cart-item-price {
    white-space: normal;
  }

  .og-cart-item-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .og-cart-edit,
  .og-cart-remove {
    width: 100%;
  }

  /* Mobile-only collapsible Order Summary */
  .og-cart-summary[data-og-order-summary] {
    padding: 0;
    overflow: hidden;
  }

  .og-cart-summary .og-order-summary-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    margin: 0;
    padding: 18px 20px;
    border: 0;
    background: transparent;
    color: inherit;
    text-align: left;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
  }

  .og-cart-summary .og-order-summary-toggle:focus-visible {
    outline: 2px solid #0878ff;
    outline-offset: -2px;
  }

  .og-cart-summary .og-order-summary-toggle-label {
    flex: 1 1 auto;
    min-width: 0;
    font-size: 15px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #071b3b;
  }

  .og-cart-summary .og-order-summary-toggle-total {
    flex: 0 0 auto;
    font-size: 18px;
    font-weight: 950;
    letter-spacing: -0.03em;
    color: #071b3b;
    white-space: nowrap;
  }

  .og-cart-summary .og-order-summary-toggle-total .woocommerce-Price-amount,
  .og-cart-summary .og-order-summary-toggle-total .amount {
    font-weight: 950;
  }

  .og-cart-summary .og-order-summary-toggle-chevron {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    background: #eef5ff;
    color: #0878ff;
    transition: transform 0.22s ease;
  }

  .og-cart-summary.is-summary-expanded .og-order-summary-toggle-chevron {
    transform: rotate(180deg);
  }

  .og-cart-summary .og-order-summary-panel {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.24s ease;
  }

  .og-cart-summary.is-summary-expanded .og-order-summary-panel {
    grid-template-rows: 1fr;
  }

  .og-cart-summary .og-order-summary-panel-inner {
    overflow: hidden;
    min-height: 0;
    padding: 0 20px;
    opacity: 0;
    transition: opacity 0.2s ease, padding 0.24s ease;
  }

  .og-cart-summary.is-summary-expanded .og-order-summary-panel-inner {
    padding: 0 20px 22px;
    opacity: 1;
  }

  .og-cart-summary .og-order-summary-desktop-label {
    display: none;
  }

  .og-cart-summary .og-cart-summary-title {
    margin-top: 4px;
  }
}

/* Desktop / tablet: Order Summary stays fully expanded */
@media (min-width: 721px) {
  .og-cart-summary .og-order-summary-toggle {
    display: none !important;
  }

  .og-cart-summary .og-order-summary-panel,
  .og-cart-summary.is-summary-collapsed .og-order-summary-panel,
  .og-cart-summary.is-summary-expanded .og-order-summary-panel {
    display: block !important;
    grid-template-rows: none !important;
  }

  .og-cart-summary .og-order-summary-panel-inner {
    overflow: visible !important;
    opacity: 1 !important;
    padding: 0 !important;
    min-height: 0;
  }
}

/* ---------- Cart Inline Editor (in-card expand) ---------- */

.og-cart-item.is-expanded {
  border-color: #c8dcf5;
}

.og-cart-inline-editor {
  max-height: 0;
  overflow: hidden;
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
  /* Match open/close: same duration + easing both directions. */
  transition: max-height 0.28s ease, margin-top 0.28s ease, padding-top 0.28s ease, border-color 0.28s ease;
}

.og-cart-inline-editor:not(.is-open) {
  max-height: 0 !important;
}

.og-cart-inline-editor:not(.is-open) .og-cart-inline-form {
  opacity: 0;
  pointer-events: none;
}

.og-cart-inline-editor.is-open {
  max-height: 2400px;
  margin-top: 11px;
  padding-top: 11px;
  border-top: 1px solid #dbe8f7;
}

/*
 * Edit Item: never show Configuration Summary and inline editor together.
 * Height/opacity animated in JS with the same 280ms ease as the editor.
 */
.og-cart-item.is-expanded .og-cart-item-actions [data-og-cart-edit-toggle] {
  opacity: 0;
  pointer-events: none;
  max-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
}

.og-cart-item-actions [data-og-cart-edit-toggle] {
  transition: opacity 0.28s ease, max-height 0.28s ease, margin 0.28s ease, padding 0.28s ease;
  max-height: 60px;
}

/* Mobile: let in-flow Custom Select lists expand the editor without clipping. */
@media (max-width: 980px) {
  .og-cart-inline-editor.is-open:not(.is-opening):not(.is-closing) {
    max-height: none;
    overflow: visible;
  }
}

.og-cart-inline-editor.is-open .og-cart-inline-form {
  opacity: 1;
  pointer-events: auto;
  /*
   * Use transform:none when open. translateY(0) still creates a containing
   * block that traps desktop OG Custom Select fixed overlay lists inside the
   * editor's overflow:hidden. Mobile Cart Edit uses in-flow lists (.is-inflow)
   * and is unaffected.
   */
  transform: none;
  transition: opacity 0.28s ease;
}

.og-cart-inline-form {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.og-cart-inline-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.og-cart-inline-field {
  display: grid;
  gap: 5px;
  font-weight: 900;
  color: #071b3b;
}

.og-cart-inline-field select:not(.og-custom-select__native) {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid #d7e3f1;
  background: #fff;
  color: #071b3b;
  font-weight: 900;
}

.og-cart-inline-field .og-custom-select {
  width: 100%;
  max-width: 100%;
}

.og-cart-inline-field .og-custom-select__trigger {
  font-weight: 700;
}

.og-cart-inline-field--notes textarea {
  width: 100%;
  min-height: 84px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid #d7e3f1;
  background: #fff;
  color: #071b3b;
  font: inherit;
  font-weight: 600;
  line-height: 1.45;
  resize: vertical;
}

.og-cart-artwork-extras {
  grid-column: 1 / -1;
  display: grid;
  gap: 8px;
}

.og-cart-artwork-panel[hidden] {
  display: none !important;
}

.og-cart-artwork-files {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border-radius: 16px;
  background: #f8fbff;
  border: 1px solid #dbe8f7;
}

.og-cart-artwork-files-title {
  margin: 0;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0878ff;
}

.og-cart-artwork-file-row {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.og-cart-artwork-file-row.has-error .og-cart-artwork-choose,
.og-cart-artwork-file-row.has-error .og-cart-artwork-replace {
  border-color: #fecaca;
}

.og-cart-artwork-file-error {
  flex: 1 0 100%;
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
  font-weight: 700;
  color: #b42318;
}

.og-cart-artwork-file-error[hidden] {
  display: none !important;
}

.og-cart-artwork-file-row[hidden] {
  display: none !important;
}

.og-cart-artwork-file-label {
  font-size: 13px;
  font-weight: 900;
  color: #071b3b;
}

.og-cart-artwork-file-control {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.og-cart-artwork-file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.og-cart-artwork-choose,
.og-cart-artwork-replace {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid #d7e3f1;
  background: #fff;
  color: #071b3b;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

/* Author display:* must not override the hidden attribute on face controls. */
.og-cart-artwork-choose[hidden],
.og-cart-artwork-replace[hidden],
.og-cart-artwork-filename[hidden],
.og-cart-artwork-file-input[hidden] {
  display: none !important;
}

.og-cart-artwork-replace {
  color: #0878ff;
  border-color: #c8dcf5;
}

.og-cart-artwork-filename {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 13px;
  font-weight: 700;
  color: #516176;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.og-cart-artwork-service-note {
  margin: 0;
  padding: 12px 14px;
  border-radius: 16px;
  background: #f8fbff;
  border: 1px solid #dbe8f7;
  font-size: 13px;
  line-height: 1.45;
  color: #516176;
}

.og-cart-inline-note {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border-radius: 16px;
  background: #f8fbff;
  border: 1px solid #dbe8f7;
  color: #071b3b;
}

.og-cart-inline-note strong {
  font-size: 14px;
  font-weight: 950;
}

.og-cart-inline-note span {
  font-size: 14px;
  line-height: 1.45;
  color: #516176;
}

.og-cart-inline-actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  margin-top: 10px;
}

/*
 * While mobile Done closes the tall editor, hide lower-page chrome so the
 * footer/order summary cannot flash before the smooth item scroll catches up.
 */
@media (max-width: 720px) {
  html.og-cart-edit-closing .og-cart-summary,
  html.og-cart-edit-closing .og-cart-keep-shopping,
  html.og-cart-edit-closing .og-site-footer {
    visibility: hidden !important;
    pointer-events: none !important;
  }
}

.og-cart-inline-autosave-status {
  min-height: 1.25em;
  font-size: 0.92rem;
  font-weight: 700;
  color: #516176;
}

.og-cart-inline-autosave-status[data-status="saving"] {
  color: #0b4ea2;
}

.og-cart-inline-autosave-status[data-status="saved"] {
  color: #15803d;
}

.og-cart-inline-autosave-status[data-status="error"] {
  color: #b91c1c;
}

/* Progressive enhancement: hide Update after inline autosave arms */
.og-cart-page.og-cart-inline-autosave-ready
  [data-og-cart-inline-editor]:not(.is-autosave-fallback)
  [data-og-cart-inline-update] {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.og-cart-inline-secondary,
.og-cart-inline-primary {
  width: 100%;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  font-weight: 950;
  cursor: pointer;
}

.og-cart-inline-secondary {
  background: #fff;
  color: #071b3b;
  border: 1px solid #d7e3f1;
}

.og-cart-inline-primary {
  background: #0878ff;
  color: #fff;
  border: 1px solid #0878ff;
  box-shadow: 0 14px 30px rgba(8, 120, 255, 0.22);
  transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.og-cart-inline-primary.is-updated {
  background: #16a34a;
  border-color: #16a34a;
  box-shadow: 0 14px 30px rgba(22, 163, 74, 0.24);
}

.og-cart-inline-primary:disabled {
  cursor: default;
  opacity: 1;
}

@media (min-width: 721px) {
  .og-cart-inline-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .og-cart-inline-actions {
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
  }

  .og-cart-inline-secondary,
  .og-cart-inline-primary {
    width: auto;
  }
}

/* ---------- Mobile floating Order Total ---------- */

.og-cart-floating-total {
  display: none;
}

@media (max-width: 720px) {
  .og-cart-floating-total {
    display: block;
    position: fixed;
    top: var(--og-cart-floating-top, calc(68px + env(safe-area-inset-top, 0px)));
    left: 0;
    right: 0;
    z-index: 920;
    pointer-events: none;
    opacity: 0;
    transform: translateY(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease, top 0.12s ease;
    will-change: opacity, transform;
  }

  .og-cart-floating-total.is-visible {
    pointer-events: auto;
    opacity: 1;
    transform: translateY(0);
  }

  .og-cart-floating-total-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 52px;
    padding: 10px 16px;
    border: 0;
    border-bottom: 1px solid #d7e3f1;
    border-radius: 0;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.1);
    backdrop-filter: blur(12px);
  }

  .og-cart-floating-total-copy {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
  }

  .og-cart-floating-total-label {
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #516176;
  }

  .og-cart-floating-total-amount {
    font-size: 1.05rem;
    font-weight: 950;
    color: #071b3b;
    line-height: 1.15;
  }

  .og-cart-floating-total-amount .woocommerce-Price-amount,
  .og-cart-floating-total-amount .amount {
    color: inherit;
  }

  .og-cart-floating-total-action {
    flex-shrink: 0;
    min-height: 34px;
    padding: 0 12px;
    border: 1px solid rgba(8, 120, 255, 0.28);
    border-radius: 999px;
    background: rgba(8, 120, 255, 0.08);
    color: #0878ff;
    font-size: 0.78rem;
    font-weight: 850;
    cursor: pointer;
  }

  .og-cart-floating-total-action:focus-visible {
    outline: 2px solid #0878ff;
    outline-offset: 2px;
  }

  .og-cart-page.is-floating-total-visible {
    padding-top: calc(34px + 64px);
  }
}

/* ==========================================================
   OG Platform — hide mobile scrollbars (keep scrolling)
   Scoped to Cart scroll containers (no global *).
========================================================== */

@media (max-width: 1100px) {
  .og-cart-page,
  .og-cart-summary,
  .og-cart-page .og-custom-select__panel,
  .og-cart-page .og-custom-select__list {
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
  }

  .og-cart-page::-webkit-scrollbar,
  .og-cart-summary::-webkit-scrollbar,
  .og-cart-page .og-custom-select__panel::-webkit-scrollbar,
  .og-cart-page .og-custom-select__list::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
    display: none !important;
    background: transparent !important;
  }
}

/* ==========================================================
   OG Platform — desktop scrollbars (design system)
========================================================== */

@media (min-width: 1101px) {
  .og-cart-page,
  .og-cart-summary,
  .og-cart-page .og-custom-select__panel,
  .og-cart-page .og-custom-select__list {
    scrollbar-width: thin;
    scrollbar-color: var(--og-scrollbar-thumb, var(--og-brand, #006cff))
      var(--og-scrollbar-track, var(--og-bg-soft, #f4f8fc));
  }

  .og-cart-page::-webkit-scrollbar,
  .og-cart-summary::-webkit-scrollbar,
  .og-cart-page .og-custom-select__panel::-webkit-scrollbar,
  .og-cart-page .og-custom-select__list::-webkit-scrollbar {
    width: var(--og-scrollbar-size, 8px);
    height: var(--og-scrollbar-size, 8px);
  }

  .og-cart-page::-webkit-scrollbar-track,
  .og-cart-summary::-webkit-scrollbar-track,
  .og-cart-page .og-custom-select__panel::-webkit-scrollbar-track,
  .og-cart-page .og-custom-select__list::-webkit-scrollbar-track {
    background: var(--og-scrollbar-track, var(--og-bg-soft, #f4f8fc));
    border-radius: 999px;
  }

  .og-cart-page::-webkit-scrollbar-thumb,
  .og-cart-summary::-webkit-scrollbar-thumb,
  .og-cart-page .og-custom-select__panel::-webkit-scrollbar-thumb,
  .og-cart-page .og-custom-select__list::-webkit-scrollbar-thumb {
    background: var(--og-scrollbar-thumb, var(--og-brand, #006cff));
    border-radius: 999px;
    border: 2px solid transparent;
    background-clip: padding-box;
    transition: background-color 0.2s ease;
  }

  .og-cart-page::-webkit-scrollbar-thumb:hover,
  .og-cart-summary::-webkit-scrollbar-thumb:hover,
  .og-cart-page .og-custom-select__panel::-webkit-scrollbar-thumb:hover,
  .og-cart-page .og-custom-select__list::-webkit-scrollbar-thumb:hover {
    background: var(--og-scrollbar-thumb-hover, var(--og-brand-dark, #0052c3));
  }
}
