/* PD Unit / Course Detail — wireframe match */

.pd-unit-page {
  background: var(--pd-bg, #f9f7f4);
  padding-bottom: 0;
}

/* Breadcrumb */
.pd-unit-breadcrumb {
  padding: 20px 0 8px;
  font-size: .78rem;
  color: var(--pd-ink-muted, #555);
}

.pd-unit-breadcrumb a {
  color: var(--pd-ink-muted, #555);
  text-decoration: none;
}

.pd-unit-breadcrumb a:hover {
  color: var(--pd-ink, #1a1a1a);
}

.pd-unit-breadcrumb span {
  margin: 0 6px;
  color: var(--pd-ink-light, #888);
}

/* Hero */
.pd-unit-hero {
  padding: 16px 0 32px;
}

.pd-unit-label {
  display: block;
  font-size: .78rem;
  font-weight: 700;
  color: var(--pd-ink, #1a1a1a);
  letter-spacing: .06em;
  text-decoration: underline;
  text-underline-offset: 4px;
  margin-bottom: 8px;
}

.pd-unit-title {
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  font-weight: 800;
  color: var(--pd-ink, #1a1a1a);
  line-height: 1.3;
  margin-bottom: 14px;
}

.pd-unit-desc {
  font-size: .88rem;
  color: var(--pd-ink-muted, #555);
  line-height: 1.75;
  margin-bottom: 22px;
  max-width: 540px;
}

.rich-text ul, .rich-text ol {
  margin: 0.5em 0 0.5em 1.25em;
  padding: 0;
}

.rich-text p:last-child {
  margin-bottom: 0;
}

.rich-text a {
  color: var(--pd-ink, #1a1a1a);
  text-decoration: underline;
}

.pd-unit-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.pd-unit-actions form { margin: 0; }

.pd-unit-actions .btn-pd-outline i {
  margin-right: 6px;
}

/* Illustration */
.pd-unit-illus {
  position: relative;
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pd-unit-illus-blob {
  position: absolute;
  inset: 10px 0;
  background: #ebe8e3;
  border-radius: 60% 40% 55% 45% / 50% 60% 40% 50%;
  z-index: 0;
}

.pd-unit-illus-svg {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 220px;
  height: auto;
}

/* Stats bar */
.pd-unit-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  padding: 20px 0 0;
  margin-top: 28px;
  border-top: 1px solid var(--pd-border-light, #ccc);
  font-size: .78rem;
  color: var(--pd-ink-muted, #555);
}

.pd-unit-stats i {
  color: var(--pd-ink, #1a1a1a);
  margin-right: 6px;
  width: 16px;
  text-align: center;
}

/* Content section */
.pd-unit-content {
  padding: 36px 0 44px;
  border-top: 1px solid var(--pd-border-light, #ccc);
}

.pd-unit-section-title {
  font-size: .82rem;
  font-weight: 800;
  color: var(--pd-ink, #1a1a1a);
  letter-spacing: .07em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.pd-unit-section-title-left {
  text-align: left;
  margin-bottom: 20px;
}

.pd-unit-title-line {
  width: 48px;
  height: 2px;
  background: var(--pd-ink, #1a1a1a);
  margin-bottom: 18px;
}

.pd-unit-learn-list {
  margin: 0;
  padding-left: 18px;
}

.pd-unit-learn-list li {
  margin-bottom: 10px;
  font-size: .86rem;
  color: var(--pd-ink, #1a1a1a);
  line-height: 1.5;
}

/* Summary blob box */
.pd-unit-summary-box {
  background: #ebe8e3;
  border-radius: 24px 8px 20px 10px / 10px 20px 8px 24px;
  padding: 28px 24px;
  height: 100%;
}

.pd-unit-summary-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 22px;
  position: relative;
}

.pd-unit-summary-item:last-child {
  margin-bottom: 0;
}

.pd-unit-summary-icon {
  width: 36px;
  height: 36px;
  min-width: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--pd-ink, #1a1a1a);
  font-size: 1rem;
}

.pd-unit-summary-item strong {
  display: block;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .06em;
  color: var(--pd-ink, #1a1a1a);
  margin-bottom: 6px;
}

.pd-unit-summary-item p {
  font-size: .78rem;
  color: var(--pd-ink-muted, #555);
  line-height: 1.6;
  margin: 0;
}

.pd-unit-summary-assess {
  padding-right: 24px;
}

.pd-unit-chevron {
  position: absolute;
  right: 0;
  bottom: 4px;
  color: var(--pd-ink-light, #888);
  font-size: .75rem;
}

/* Instructor */
.pd-unit-instructor {
  padding: 40px 0;
  border-top: 1px solid var(--pd-border-light, #ccc);
}

.pd-instructor-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 28px;
  align-items: start;
}

.pd-instructor-avatar {
  width: 90px;
  height: 90px;
  border: 2px solid var(--pd-border-light, #ccc);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--pd-ink-light, #888);
  background: var(--pd-white, #fff);
}

.pd-instructor-info h3 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--pd-ink, #1a1a1a);
  margin: 0 0 4px;
}

.pd-instructor-role {
  font-size: .82rem;
  color: var(--pd-ink-muted, #555);
  margin-bottom: 10px;
}

.pd-instructor-bio {
  font-size: .8rem;
  color: var(--pd-ink-muted, #555);
  line-height: 1.65;
  margin-bottom: 14px;
}

.btn-pd-profile {
  padding: 8px 18px;
  font-size: .72rem;
}

.pd-instructor-stats {
  background: #ebe8e3;
  border-radius: 12px;
  padding: 18px 20px;
  min-width: 240px;
}

.pd-instructor-stat {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 16px;
  font-size: .76rem;
}

.pd-instructor-stat:last-child {
  margin-bottom: 0;
}

.pd-instructor-stat i {
  color: var(--pd-ink, #1a1a1a);
  margin-top: 2px;
  width: 18px;
}

.pd-instructor-stat strong {
  display: block;
  color: var(--pd-ink, #1a1a1a);
  font-weight: 700;
  line-height: 1.35;
}

.pd-instructor-stat span {
  display: block;
  color: var(--pd-ink-muted, #555);
  font-size: .7rem;
  margin-top: 2px;
}

/* Related on unit page */
.pd-unit-related {
  border-top: 1px solid var(--pd-border-light, #ccc);
}

/* Category catalog page */
.pd-catalog-page .pd-catalog-hero {
  padding-bottom: 24px;
}

.pd-catalog-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: .78rem;
  font-weight: 600;
  color: var(--pd-ink-muted, #555);
  margin-bottom: 20px;
}

.pd-catalog-meta i {
  margin-right: 6px;
  color: var(--pd-ink, #1a1a1a);
  opacity: .85;
}

.pd-catalog-sketch-wrap {
  position: relative;
  z-index: 1;
  width: 120px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pd-catalog-sketch-icon {
  width: 100%;
  height: 100%;
  color: var(--pd-ink, #1a1a1a);
}

.pd-catalog-categories {
  padding: 0 0 8px;
  border-bottom: 1px solid var(--pd-border-light, #ddd);
  margin-bottom: 8px;
}

.pd-catalog-categories-label {
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--pd-ink-muted, #555);
  margin: 0 0 10px;
}

.pd-catalog-categories-scroll {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-bottom: 16px;
}

.pd-catalog-chip {
  display: inline-block;
  padding: 8px 14px;
  border: 1px solid var(--pd-border-light, #ccc);
  border-radius: 999px;
  font-size: .72rem;
  font-weight: 600;
  color: var(--pd-ink, #1a1a1a);
  text-decoration: none;
  background: var(--pd-white, #fff);
  transition: border-color .15s, background .15s, color .15s;
}

.pd-catalog-chip:hover {
  border-color: var(--pd-ink, #1a1a1a);
  color: var(--pd-ink, #1a1a1a);
}

.pd-catalog-chip.is-active {
  background: var(--pd-ink, #1a1a1a);
  border-color: var(--pd-ink, #1a1a1a);
  color: #fff;
}

.pd-catalog-list {
  padding-top: 36px;
  padding-bottom: 48px;
}

.pd-catalog-grid {
  margin-top: 20px;
}

.pd-catalog-course-meta {
  font-size: .62rem;
  color: var(--pd-ink-muted, #666);
  margin: 4px 0 0;
  line-height: 1.4;
}

.pd-catalog-empty {
  text-align: center;
  max-width: 420px;
  margin: 32px auto 0;
  padding: 32px 16px 8px;
}

.pd-catalog-empty-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
  color: var(--pd-ink-muted, #888);
}

.pd-catalog-empty h3 {
  font-size: 1rem;
  font-weight: 800;
  color: var(--pd-ink, #1a1a1a);
  margin-bottom: 10px;
}

.pd-catalog-empty p {
  font-size: .82rem;
  color: var(--pd-ink-muted, #555);
  line-height: 1.65;
  margin-bottom: 20px;
}

/* Checkout / buy course */
.pd-unit-price-tag {
  font-size: .78rem;
  font-weight: 600;
  color: var(--pd-ink-muted, #555);
  margin: -8px 0 18px;
}

.pd-checkout-section-title {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--pd-ink, #1a1a1a);
  margin-bottom: 14px;
}

.pd-checkout-card {
  max-width: none;
}

.pd-checkout-summary {
  border: 1px solid var(--pd-border-light, #ddd);
  border-radius: 10px;
  padding: 22px;
  background: var(--pd-white, #fff);
}

.pd-checkout-course-name {
  font-weight: 700;
  font-size: .95rem;
  color: var(--pd-ink, #1a1a1a);
  margin-bottom: 16px;
}

.pd-checkout-includes {
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
}

.pd-checkout-includes li {
  font-size: .82rem;
  color: var(--pd-ink-muted, #555);
  padding: 8px 0;
  border-bottom: 1px solid var(--pd-border-light, #eee);
  display: flex;
  align-items: center;
  gap: 10px;
}

.pd-checkout-includes li:last-child {
  border-bottom: none;
}

.pd-checkout-includes i {
  width: 18px;
  color: var(--pd-ink, #1a1a1a);
}

.pd-checkout-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 16px;
  border-top: 2px solid var(--pd-ink, #1a1a1a);
  font-size: .88rem;
}

.pd-checkout-total strong {
  font-size: 1.25rem;
  font-weight: 800;
}

.pd-stripe-box {
  border: 1px solid var(--pd-border-light, #ddd);
  border-radius: 8px;
  padding: 14px 16px;
  background: #f8fafc;
}

.pd-stripe-box code {
  font-size: 0.75rem;
}

.pd-demo-pay-page {
  background: #f6f9fc;
  min-height: 70vh;
  /* Clear fixed site header so checkout card is fully visible */
  padding-top: 130px;
  padding-bottom: 56px;
}

@media (max-width: 991.98px) {
  .pd-demo-pay-page {
    padding-top: 110px;
  }
}

.pd-demo-pay-shell {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

.pd-demo-pay-header {
  background: linear-gradient(135deg, #635bff, #7a73ff);
  color: #fff;
  padding: 24px;
}

.pd-demo-pay-header h1 {
  font-size: 1.35rem;
  margin: 8px 0 4px;
  color: #fff;
}

.pd-demo-pay-header p {
  margin: 0;
  opacity: 0.9;
  font-size: 0.9rem;
  color: #fff;
}

.pd-demo-pay-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.pd-demo-pay-summary {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px;
  border-bottom: 1px solid #e5e7eb;
}

.pd-demo-pay-amount {
  font-weight: 800;
  white-space: nowrap;
}

.pd-demo-pay-form {
  padding: 24px;
}

.pd-demo-pay-btn {
  background: #635bff;
  border-color: #635bff;
  font-weight: 700;
}

.pd-demo-pay-btn:hover {
  background: #5851ea;
  border-color: #5851ea;
}

.pd-related-compact {
  text-decoration: none;
  color: inherit;
  transition: border-color .15s;
}

.pd-related-compact:hover {
  border-color: var(--pd-ink, #1a1a1a);
}

/* Responsive */
@media (max-width: 991px) {
  .pd-instructor-card {
    grid-template-columns: 1fr;
  }

  .pd-instructor-avatar {
    margin: 0 auto;
  }

  .pd-instructor-stats {
    min-width: 0;
  }
}

@media (max-width: 575px) {
  .pd-unit-stats {
    flex-direction: column;
    gap: 12px;
  }
}
