.checkout-page {
  background: #f4f1ea;
}

.checkout-shell {
  width: min(760px, calc(100% - 2rem));
  margin: 2rem auto 4rem;
}

.checkout-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.checkout-header h1 {
  margin: .2rem 0 .5rem;
}

.checkout-eyebrow {
  margin: 0;
  color: #605648;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.checkout-card {
  margin: 1rem 0;
  padding: 1.5rem;
  background: #fff;
  border: 1px solid #ded8cd;
  border-radius: .75rem;
  box-shadow: 0 .25rem 1rem rgba(38, 31, 24, .08);
}

.checkout-items {
  margin: 0;
  padding: 0;
  list-style: none;
}

.checkout-items li,
.checkout-total {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid #ebe6dd;
}

.checkout-items span {
  display: block;
  color: #6d655c;
  font-size: .9rem;
}

.checkout-item-price {
  text-align: right;
  white-space: nowrap;
}

.checkout-item-price button {
  padding: 0;
  border: 0;
  background: transparent;
  color: #6a201c;
  text-decoration: underline;
}

.checkout-total {
  border-bottom: 0;
  font-size: 1.25rem;
}

.checkout-shipping {
  color: #514b44;
}

.checkout-notice,
.checkout-result {
  margin: 1rem 0;
  padding: .85rem 1rem;
  border-radius: .4rem;
  background: #eef4ed;
}

.checkout-notice--error,
.checkout-result--error {
  background: #fae9e7;
  color: #681f19;
}

.checkout-payment paypal-button {
  display: block;
  min-height: 44px;
}

.checkout-links {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
}

.checkout-links a {
  padding: .65rem 1rem;
  border-radius: .35rem;
  background: #24211e;
  color: #fff;
}

/* Match the public site's navy, white, and restrained editorial styling. */
:root {
  --checkout-navy: #080b53;
  --checkout-navy-hover: #151a75;
  --checkout-link: #3273c8;
  --checkout-ink: #202020;
  --checkout-muted: #62656d;
  --checkout-line: #dedede;
}

.checkout-page {
  background: #fff;
  color: var(--checkout-ink);
}

.checkout-shell {
  width: min(820px, calc(100% - 2rem));
  margin-top: clamp(1.5rem, 3vw, 2.5rem);
}

.checkout-header {
  max-width: 720px;
  margin-right: auto;
  margin-bottom: 1.7rem;
  margin-left: auto;
}

.checkout-header h1 {
  color: var(--checkout-navy);
  font-size: clamp(2rem, 4vw, 2.55rem);
  font-weight: 400;
  line-height: 1.1;
}

.checkout-header > p:last-child {
  color: var(--checkout-muted);
  line-height: 1.55;
}

.checkout-eyebrow {
  color: var(--checkout-navy);
  font-size: 0.85rem;
  letter-spacing: 0.11em;
}

.checkout-card {
  border-color: var(--checkout-line);
  border-radius: 0.7rem;
  box-shadow: 0 4px 17px rgba(0, 0, 0, 0.11);
}

.checkout-card h2 {
  color: var(--checkout-navy);
  font-size: 1.65rem;
  font-weight: 500;
}

.checkout-items li,
.checkout-total {
  border-bottom-color: var(--checkout-line);
}

.checkout-items span,
.checkout-shipping {
  color: var(--checkout-muted);
}

.checkout-item-price button {
  color: #8e2626;
  cursor: pointer;
}

.checkout-total strong {
  color: var(--checkout-navy);
}

.checkout-notice,
.checkout-result {
  border-radius: 0.3rem;
  background: #f2f8f2;
}

.checkout-notice--error,
.checkout-result--error {
  background: #fbefef;
}

.checkout-fulfillment {
  background: #eef2ff;
  border-radius: 0.45rem;
  color: var(--checkout-navy) !important;
  margin: 1rem auto 0;
  max-width: 680px;
  padding: 0.8rem 1rem;
}

.checkout-links a {
  border-radius: 999px;
  background: var(--checkout-navy);
  padding: 0.55rem 1rem;
  transition: background-color 150ms ease, transform 150ms ease;
}

.checkout-links a:hover,
.checkout-links a:focus-visible {
  background: var(--checkout-navy-hover);
  color: #fff;
  text-decoration: none;
  transform: translateY(-1px);
}

.checkout-header,
.checkout-card {
  animation: checkout-enter 300ms ease both;
}

.checkout-card:nth-of-type(2) {
  animation-delay: 60ms;
}

@keyframes checkout-enter {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 560px) {
  .checkout-card {
    padding: 1.1rem;
  }

  .checkout-items li {
    align-items: stretch;
    flex-direction: column;
  }

  .checkout-item-price {
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  .checkout-header,
  .checkout-card {
    animation: none;
  }

  .checkout-links a:hover,
  .checkout-links a:focus-visible {
    transform: none;
  }
}
