:root {
  color-scheme: light;
  --ink: #0b0b0b;
  --muted: #4b4b4b;
  --paper: #f8f8f8;
  --surface: #ffffff;
  --pink: #f47ad7;
  --yellow: #ffc900;
  --mint: #23a094;
  --line: #0b0b0b;
  --shadow: 5px 5px 0 #0b0b0b;
  font-family: Arial, Helvetica, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
}

button,
a {
  font: inherit;
}

a {
  color: inherit;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
  padding: 12px clamp(14px, 4vw, 48px);
  border-bottom: 2px solid var(--line);
  background: var(--yellow);
}

.cta-topbar {
  justify-content: flex-end;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-size: 20px;
  font-weight: 900;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 2px solid var(--line);
  border-radius: 50%;
  background: var(--pink);
  font-size: 14px;
  box-shadow: 3px 3px 0 var(--line);
}

.nav-buy,
.primary-buy,
.mobile-buy-bar button {
  min-height: 44px;
  border: 2px solid var(--line);
  border-radius: 4px;
  background: var(--pink);
  color: var(--ink);
  cursor: pointer;
  font-weight: 800;
  text-decoration: none;
  transition: filter 140ms ease, transform 140ms ease;
}

.nav-buy {
  padding: 0 22px;
}

.nav-buy:hover,
.primary-buy:hover,
.mobile-buy-bar button:hover {
  filter: brightness(0.96);
  transform: translateY(-1px);
}

.gumroad-page {
  padding: clamp(18px, 5vw, 58px) 16px;
}

.gumroad-product {
  max-width: 1120px;
  margin: 0 auto;
  border: 2px solid var(--line);
  border-radius: 4px;
  background: var(--surface);
  overflow: hidden;
}

.product-preview {
  margin: 0;
  border-bottom: 2px solid var(--line);
  background: #111;
}

.product-preview img {
  display: block;
  width: 100%;
  max-height: 560px;
  object-fit: cover;
}

.product-title-row {
  padding: 28px 26px;
  border-bottom: 2px solid var(--line);
}

h1 {
  margin: 0;
  font-size: clamp(36px, 5.4vw, 54px);
  line-height: 1.05;
  letter-spacing: 0;
  font-weight: 500;
}

.product-meta-row {
  display: grid;
  grid-template-columns: 138px 1fr;
  min-height: 64px;
  border-bottom: 2px solid var(--line);
}

.price-ribbon {
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 2px solid var(--line);
  background: var(--pink);
  font-size: 20px;
  font-weight: 800;
  clip-path: polygon(0 0, calc(100% - 22px) 0, 100% 50%, calc(100% - 22px) 100%, 0 100%);
}

.creator-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 24px;
  font-weight: 800;
  text-decoration: none;
}

.creator-avatar {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border: 2px solid var(--line);
  border-radius: 50%;
  background: var(--yellow);
  font-size: 11px;
  text-decoration: none;
}

.product-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: stretch;
}

.product-description-panel {
  min-height: 760px;
  padding: clamp(24px, 4vw, 34px);
  border-right: 2px solid var(--line);
}

.description-content {
  display: grid;
  gap: 18px;
  max-width: 760px;
  font-size: 18px;
  line-height: 1.48;
  font-weight: 650;
}

.description-content p {
  margin: 0;
}

.description-content h3 {
  margin: 22px 0 0;
  font-size: 24px;
  line-height: 1.15;
}

.description-content ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.description-content li {
  position: relative;
  padding-left: 25px;
}

.description-content li::before {
  position: absolute;
  left: 0;
  content: "\2713";
  color: var(--mint);
  font-weight: 900;
}

.buy-panel {
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 24px;
}

.primary-buy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  padding: 0 22px;
}

.buy-panel p {
  margin: 0;
  padding: 18px;
  border: 2px solid var(--line);
  border-radius: 4px;
  font-size: 17px;
  font-weight: 800;
  line-height: 1.45;
}

.buy-panel dl {
  margin: 0;
  border: 2px solid var(--line);
  border-radius: 4px;
}

.buy-panel dl div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
}

.buy-panel dl div + div {
  border-top: 2px solid var(--line);
}

.buy-panel dt,
.buy-panel dd {
  margin: 0;
  font-weight: 800;
}

.mobile-buy-bar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 19;
  display: none;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-top: 2px solid var(--line);
  background: var(--surface);
}

.mobile-buy-bar span {
  display: inline-block;
  width: max-content;
  min-width: 98px;
  padding: 8px 12px;
  background: var(--pink);
  font-size: 18px;
  font-weight: 900;
  clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 50%, calc(100% - 18px) 100%, 0 100%);
}

.mobile-buy-bar button {
  min-width: 112px;
  padding: 0 20px;
}

.footer {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  justify-content: center;
  padding: 36px 18px 52px;
  border-top: 2px solid var(--line);
  color: var(--ink);
  font-weight: 800;
}

.footer a {
  text-decoration-thickness: 2px;
}

.checkout-dialog {
  width: min(560px, calc(100vw - 24px));
  padding: 0;
  border: 2px solid var(--line);
  border-radius: 4px;
  color: var(--ink);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.checkout-dialog::backdrop {
  background: rgba(11, 11, 11, 0.45);
}

.dialog-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
  padding: 20px;
  border-bottom: 2px solid var(--line);
  background: var(--pink);
}

.dialog-head p,
.dialog-head h2 {
  margin: 0;
}

.dialog-head p {
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
}

.dialog-head h2 {
  margin-top: 5px;
  font-size: 24px;
  line-height: 1.05;
}

.icon-button {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border: 2px solid var(--line);
  border-radius: 4px;
  background: white;
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
}

.checkout-summary {
  display: flex;
  justify-content: space-between;
  padding: 18px 20px;
  border-bottom: 2px solid var(--line);
  font-size: 19px;
  font-weight: 900;
}

.paypal-buttons {
  min-height: 150px;
  padding: 20px 20px 12px;
}

.checkout-status {
  min-height: 24px;
  margin: 0;
  padding: 0 20px 20px;
  color: var(--muted);
  font-size: 16px;
}

.thank-you-body {
  min-height: 100vh;
  background: var(--mint);
}

.thank-you-topbar {
  background: var(--yellow);
}

.receipt-link {
  font-weight: 800;
  text-decoration-thickness: 2px;
}

.thank-you {
  max-width: 960px;
  margin: 0 auto;
  padding: clamp(28px, 7vw, 74px) 18px;
}

.download-panel {
  padding: clamp(24px, 6vw, 54px);
  border: 2px solid var(--line);
  border-radius: 4px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.download-panel .eyebrow {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
  text-transform: uppercase;
}

.download-panel h1 {
  margin: 0;
  font-size: clamp(44px, 8vw, 84px);
}

.download-panel p {
  color: var(--muted);
  font-size: 18px;
  line-height: 1.55;
}

.receipt-card {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 16px;
  align-items: center;
  margin: 30px 0 22px;
  padding: 14px;
  border: 2px solid var(--line);
  border-radius: 4px;
  background: var(--yellow);
}

.receipt-cover {
  width: 140px;
  aspect-ratio: 16 / 9;
  border: 2px solid var(--line);
  background: white;
  object-fit: cover;
}

.receipt-card span,
.receipt-card strong {
  display: block;
}

.receipt-card span {
  color: var(--muted);
  font-weight: 800;
}

.receipt-card strong {
  margin-top: 3px;
  font-size: 18px;
}

.receipt-card p {
  margin: 6px 0 0;
  font-size: 15px;
}

.legal {
  max-width: 800px;
  margin: 34px auto;
  padding: clamp(24px, 5vw, 44px);
  border: 2px solid var(--line);
  border-radius: 4px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.legal h1 {
  font-size: clamp(42px, 7vw, 72px);
}

.legal h2 {
  margin-top: 30px;
  font-size: 28px;
}

.legal p {
  color: var(--muted);
  line-height: 1.65;
}

@media (max-width: 860px) {
  .gumroad-page {
    padding: 14px 12px 0;
  }

  .gumroad-product {
    border-radius: 3px;
  }

  .product-content-grid {
    grid-template-columns: 1fr;
  }

  .product-description-panel {
    min-height: auto;
    border-right: 0;
  }

  .buy-panel {
    border-top: 2px solid var(--line);
  }
}

@media (max-width: 640px) {
  .topbar {
    min-height: 54px;
    padding: 8px 12px;
  }

  .brand {
    font-size: 15px;
  }

  .brand-mark {
    width: 30px;
    height: 30px;
    font-size: 11px;
    box-shadow: none;
  }

  .topbar .nav-buy {
    display: none;
  }

  .cta-topbar .nav-buy {
    display: inline-flex;
    align-items: center;
  }

  .product-preview img {
    max-height: 220px;
  }

  .product-title-row {
    padding: 24px 22px;
  }

  h1 {
    font-size: clamp(40px, 12vw, 56px);
  }

  .product-meta-row {
    grid-template-columns: 120px 1fr;
  }

  .creator-link {
    padding: 10px 18px;
  }

  .product-description-panel,
  .buy-panel {
    padding: 22px;
  }

  .description-content {
    font-size: 16px;
  }

  .mobile-buy-bar {
    display: grid;
  }

  .footer {
    padding-bottom: 88px;
  }

  .receipt-card {
    grid-template-columns: 1fr;
  }

  .receipt-cover {
    width: 100%;
  }
}
