.mast-end .checkout-trigger {
  min-height: 36px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  white-space: nowrap;
}

.mast-end .checkout-trigger:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.checkout-hotspot {
  position: absolute;
  z-index: 2;
  left: 5.625%;
  top: 30.81%;
  width: 67.5%;
  height: 38.03%;
  padding: 0;
  border: 0;
  border-radius: 7%;
  background: transparent;
}

.checkout-hotspot:focus-visible { outline-offset: 0; }

.rich-cards {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: #bedfdb;
}

.checkout-card {
  --card-ink: #153a36;
  --card-rim: #f4fffc;
  --card-base: #d3ede7;
  --card-edge: #9bbeb7;
  --card-sheen: #eafcf7;
  container-type: inline-size;
  box-sizing: border-box;
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--card-edge);
  border-radius: 27px;
  background: linear-gradient(145deg, var(--card-sheen), var(--card-base) 65%, #f4fbf8);
  color: var(--card-ink);
  box-shadow: inset 0 0 0 2px var(--card-rim), inset 0 -10px 30px #6aada325, 0 28px 84px #071d2d77;
}

dialog.checkout-card {
  position: fixed;
  inset: 0;
  width: min(92vw, 92dvh, 438px);
  height: auto;
  max-width: none;
  max-height: none;
  margin: auto;
}

.payment-section {
  overflow: hidden;
  border-top: 1px solid #305459;
  background: radial-gradient(ellipse at 78% 35%, #3d817d 0%, #173d43 39%, #0b2530 84%);
  color: #effef9;
}

.payment-section-layout {
  width: min(calc(100% - 48px), 1010px);
  min-height: 520px;
  margin: auto;
  padding-block: clamp(42px, 6.7vw, 88px);
  display: grid;
  grid-template-columns: 1fr minmax(300px, 400px);
  align-items: center;
  gap: clamp(24px, 6vw, 100px);
}

.payment-section h2 {
  font-size: clamp(43px, 6.4vw, 85px);
  letter-spacing: -.057em;
  line-height: .98;
}

.payment-section h2 em {
  color: #adede0;
  font-style: normal;
}

.checkout-example { box-shadow: inset 0 0 0 2px var(--card-rim), 0 18px 52px #051e2d87; }

.checkout-card[data-merchant="retail"] {
  --card-ink: #193b51;
  --card-base: #dcecf5;
  --card-edge: #9ab7c7;
  --card-sheen: #effaff;
}

.checkout-card::backdrop {
  background: #061d2b86;
  backdrop-filter: blur(7px);
}

.checkout-card .checkout-close {
  position: absolute;
  z-index: 1;
  top: 10px;
  right: 10px;
  margin: 0;
}

.checkout-card .checkout-close button {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--card-edge);
  border-radius: 50%;
  background: linear-gradient(#fff, var(--card-base));
  color: var(--card-ink);
  font: 25px/1 Arial, sans-serif;
}

.checkout-merchant {
  display: grid;
  height: 15%;
  align-content: center;
  text-align: center;
  text-transform: uppercase;
  border-bottom: 1px solid #547a7033;
  background: linear-gradient(#f6fffc96 0%, #f1fff783 48%, #b9ddd462 51%, #c8e9e3a6);
  font-size: clamp(15px, 4.6cqw, 22px);
  font-weight: 750;
  letter-spacing: .11em;
  box-shadow: inset 0 -1px #f8fffcbe;
}

.checkout-summary {
  display: flex;
  min-height: 18%;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
  margin: 0 7%;
  padding: 4% 0 3%;
  border-bottom: 1px solid #547a703d;
}

.checkout-summary .checkout-product {
  margin: 0;
  font-size: clamp(14px, 5.4cqw, 24px);
  line-height: 1.06;
  letter-spacing: -.035em;
  font-weight: 670;
}

.checkout-detail {
  margin: 4px 0 0;
  color: #345658;
  font-size: clamp(11px, 3.25cqw, 15px);
}

.checkout-price {
  white-space: nowrap;
  font-size: clamp(16px, 6.2cqw, 29px);
  line-height: 1;
  font-weight: 620;
  letter-spacing: -.04em;
}

.checkout-art {
  display: grid;
  position: absolute;
  inset: 33% 7% 24%;
  place-items: center;
}

.checkout-art img {
  display: block;
  width: 89%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.checkout-card[data-merchant="genic"] .checkout-art img { mix-blend-mode: normal; }

.checkout-action {
  display: grid;
  position: absolute;
  inset: auto 7% 5%;
  gap: 6px;
}

.checkout-pay {
  display: flex;
  min-height: max(36px, 10cqw);
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid #17242a;
  border-radius: 9px;
  padding: 4px 8px;
  font-size: clamp(12px, 4cqw, 17px);
  font-weight: 620;
  background: linear-gradient(#2c363b, #0a1017 57%, #121c22);
  color: #fff;
  box-shadow: inset 0 1px #ffffff33, 0 4px 8px #10262a25;
}

.checkout-pay .apple { width: 1em; height: 1.1em; fill: currentColor; }
.checkout-card[data-complete="true"] .apple { display: none; }

.checkout-status {
  margin: 0;
  color: #385960;
  text-align: center;
  font-size: clamp(10px, 3cqw, 13px);
}

@media (max-width: 720px) {
  .payment-section-layout {
    width: min(calc(100% - 36px), 372px);
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
    text-align: center;
  }
  .payment-section h2 { font-size: clamp(37px, 8vw, 56px); }
  .checkout-example { text-align: left; }
}

@media (max-width: 320px), (max-height: 360px) {
  .checkout-card { border-radius: 17px; }
  .checkout-card .checkout-close { top: 3px; right: 3px; }
  .checkout-card .checkout-close button { width: 28px; height: 28px; font-size: 18px; }
}

.rich-cards {
  padding: clamp(26px, 6vw, 88px) clamp(12px, 4vw, 50px);
  background: radial-gradient(ellipse at 25% 15%, #f2fcf3, transparent 61%), linear-gradient(150deg, #dcefe4, #a7d3cc);
}

.rich-threads {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(10px, 2vw, 28px);
  width: min(100%, 1120px);
  margin: auto;
}

.rich-thread {
  container-type: inline-size;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  border: 1px solid #7e9eaf;
  border-radius: 22px;
  background: linear-gradient(#e9f2f6,#d8e8ee);
  color: #193347;
  box-shadow: inset 0 0 0 1px #fff, 0 20px 42px #2e5c6150;
}

.rich-thread-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 9px 16px;
  padding: 12px 18px;
  background: linear-gradient(#f4f9fd 0%,#c5d7e8 49%,#adc3d8 51%,#c3d6e6 100%);
  border-bottom: 1px solid #94afc1;
}

.rich-contact {
  display:flex;
  align-items:center;
  gap:7px;
  white-space:nowrap;
}

.rich-contact-avatar {
  display:grid;
  flex:0 0 26px;
  width:26px;
  height:26px;
  place-items:center;
  border:1px solid #8aaac2;
  border-radius:50%;
  background:linear-gradient(#f9fdff,#d5e7f4);
  color:#254a65;
  font-size:10px;
  font-weight:750;
}
.rich-thread-header h3 {
  margin:0;
  color:#28445c;
  font:700 13px/1.1 "Helvetica Neue",Arial,sans-serif;
}
.rich-messages {
  display:grid;
  gap:10px;
  padding:16px 18px 13px;
}

.rich-messages p {
  width:max-content;
  max-width:90%;
  padding:7px 12px;
  border:1px solid #879fae;
  border-radius:18px;
  font: 500 clamp(13px,2.1cqw,17px)/1.2 "Helvetica Neue",Arial,sans-serif;
  box-shadow:inset 0 1px #fff;
}

.rich-request { justify-self:end; background:linear-gradient(#e3f4ff,#8ac4ee); }
.rich-answer { justify-self:start; background:linear-gradient(#fff,#e8eded); }

.rich-photo-count {
  margin: 0 6% 8px;
  color: #426480;
  font-size: 12px;
  font-weight: 650;
}

.rich-stack {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1.01;
  user-select: none;
  touch-action: pan-y;
  cursor: grab;
}

.rich-stack.is-dragging { cursor: grabbing; }
.rich-stack:focus-visible { outline: 2px solid #4277a3; outline-offset: -3px; }

.rich-result {
  position: absolute;
  top: 1px;
  left: 6%;
  width: 72%;
  aspect-ratio: 3 / 4;
  box-sizing: border-box;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: clamp(5px, 2.5cqw, 10px);
  padding: clamp(9px, 4.4cqw, 16px);
  overflow: hidden;
  border: 1px solid #c5dae3;
  border-radius: 14px;
  background: linear-gradient(158deg, #fdffff, #e0edf5 76%, #fff);
  box-shadow: inset 0 1px #fff, 0 4px 10px #4e758526;
  transform-origin: left center;
  pointer-events: none;
}

.rich-result:nth-child(3n+1) { background:linear-gradient(157deg,#fcffff,#d3ece1 75%,#f4fffb); }
.rich-seller { color:#31566b; font-size:clamp(11px,4cqw,13px); font-weight:700; }
.rich-result img { width:100%; height:100%; min-height:0; border-radius:7px; object-fit:cover; }
.rich-product img { object-fit:contain; mix-blend-mode:multiply; }
.rich-result h4 { margin:0 0 2px; font-size:clamp(13px,5cqw,17px); line-height:1.1; }
.rich-detail { margin:.15rem 0 0; color:#334e59; font-size:clamp(10px,3.8cqw,13px); }
.rich-price { display:block; color:#172d37; font-size:clamp(17px,6.4cqw,23px); font-weight:740; }

@media (max-width: 740px) {
  .rich-threads { grid-template-columns: 1fr; max-width: 380px; gap: 17px; }
}
