/* ══════════════════════════════════════════════════════════════════
   Phase 2 · Page hero templates                       S.MONK 2026-04
   ══════════════════════════════════════════════════════════════════
   Five hero templates that every non-homepage public page uses.
   The homepage's hero (.home-hero) is owned by Phase 1A and stays
   distinct.

     A  Content / guide hero       — class .page-hero.ph--content
     B  Tool / reference hero      — class .page-hero.ph--tool
     C  Course detail hero         — class .page-hero.ph--course
     D  Sales / conversion hero    — class .page-hero.ph--sales
     E  Auth / form hero           — class .page-hero.ph--auth

   All five share the same navy gradient and the same nav offset.
   ══════════════════════════════════════════════════════════════════ */

/* Phase-2 colour locals (legacy spec uses these specific values). */
:root {
  --ph-navy:     #0B1D3F;
  --ph-navy-2:   #172B55;
  --ph-cyan:     #00AFEF;
  --ph-orange:   #F97316;
  --ph-orange-2: #F88649;
  --ph-ink:      #0B1D3F;
  --ph-ink-2:    #4A5568;
  --ph-border-light: #E8EBF0;
  --ph-light-bg: #FAFBFD;
}

/* ── Shell: gradient, nav offset, container ─────────────────────── */
.page-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #0B1D3F 0%, #172B55 60%, rgba(0, 175, 239, 0.13) 100%);
  margin-top: -68px;
  padding: calc(68px + clamp(40px, 5vw, 64px)) 0 clamp(48px, 5vw, 80px);
  isolation: isolate;
  color: #fff;
}

/* Faint grid overlay reused across every hero. */
.page-hero::before {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse at center, black 55%, transparent 100%);
          mask-image: radial-gradient(ellipse at center, black 55%, transparent 100%);
  pointer-events: none;
  z-index: 0;
}

.page-hero > .wrap,
.page-hero > .ph-inner {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 32px);
}

/* ── Common atoms shared across all five templates ──────────────── */
.ph-crumb {
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  margin-bottom: 22px;
}
.ph-crumb a {
  color: rgba(255,255,255,0.78);
  text-decoration: none;
  transition: color 150ms ease;
}
.ph-crumb a:hover { color: #fff; }
.ph-crumb-sep { margin: 0 6px; opacity: 0.5; }

.ph-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(0, 175, 239, 0.12);
  border: 1px solid rgba(0, 175, 239, 0.32);
  color: #4DC4F4;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 22px;
}
.ph-pill--orange {
  background: rgba(249, 115, 22, 0.12);
  border-color: rgba(249, 115, 22, 0.35);
  color: #F88649;
}
.ph-pill--green {
  background: rgba(16, 216, 122, 0.12);
  border-color: rgba(16, 216, 122, 0.32);
  color: #10D87A;
}

.ph-h1 {
  font-family: 'Space Grotesk', 'Manrope', sans-serif;
  font-size: clamp(34px, 5vw, 56px);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.025em;
  color: #fff;
  margin: 0 0 18px;
}
.ph-h1 .acc { color: var(--ph-orange-2); }

.ph-sub {
  color: rgba(255, 255, 255, 0.72);
  font-size: 17px;
  line-height: 1.55;
  max-width: 540px;
  margin: 0 0 24px;
}

.ph-stats {
  display: flex; flex-wrap: wrap;
  gap: clamp(20px, 3vw, 40px);
  margin-top: 28px;
}
.ph-stat-num {
  font-family: 'Space Grotesk', 'Manrope', sans-serif;
  color: #fff;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1;
  margin-bottom: 6px;
}
.ph-stat-num em { font-style: normal; color: var(--ph-orange-2); }
.ph-stat-lbl {
  color: rgba(255, 255, 255, 0.55);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ph-chips {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 24px;
}
.ph-chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.85);
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 150ms ease, border-color 150ms ease;
}
.ph-chip:hover { background: rgba(255,255,255,0.12); border-color: rgba(255,255,255,0.22); }
.ph-chip--active {
  background: rgba(0,175,239,0.18);
  border-color: rgba(0,175,239,0.4);
  color: #4DC4F4;
}

.ph-ctas {
  display: flex; flex-wrap: wrap; gap: 12px;
  margin-top: 24px;
}
.ph-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 22px;
  border-radius: 10px;
  font-family: 'Manrope', system-ui, sans-serif;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  border: 1.5px solid transparent;
  line-height: 1;
  cursor: pointer;
  transition: background 150ms ease, transform 150ms ease, border-color 150ms ease;
}
.ph-btn--primary { background: var(--ph-orange); color: #fff; }
.ph-btn--primary:hover { background: #E85D1A; transform: translateY(-1px); }
.ph-btn--ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,0.32); }
.ph-btn--ghost:hover { border-color: rgba(255,255,255,0.6); background: rgba(255,255,255,0.05); }

/* ══════════════════════════════════════════════════════════════════
   A · CONTENT HERO
   ══════════════════════════════════════════════════════════════════ */
.page-hero.ph--content {
  min-height: 480px;
}
.page-hero.ph--content .ph-inner {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: inherit;
}
.page-hero.ph--content .ph-h1 { max-width: 800px; }
.page-hero.ph--content .ph-stats { margin-top: 36px; }

@media (max-width: 768px) {
  .page-hero.ph--content { min-height: 360px; }
}

/* ══════════════════════════════════════════════════════════════════
   B · TOOL / REFERENCE HERO
   ══════════════════════════════════════════════════════════════════ */
.page-hero.ph--tool { min-height: 460px; }
.page-hero.ph--tool .ph-inner { text-align: center; }
.page-hero.ph--tool .ph-pill,
.page-hero.ph--tool .ph-h1,
.page-hero.ph--tool .ph-sub { margin-left: auto; margin-right: auto; }
.page-hero.ph--tool .ph-h1 { max-width: 720px; }
.page-hero.ph--tool .ph-sub { max-width: 560px; }
.page-hero.ph--tool .ph-chips { justify-content: center; }
.page-hero.ph--tool .ph-ctas { justify-content: center; }

.ph-search {
  display: flex;
  max-width: 560px;
  margin: 24px auto 0;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 150ms ease, background 150ms ease;
}
.ph-search:focus-within {
  border-color: rgba(0,175,239,0.55);
  background: rgba(255,255,255,0.1);
}
.ph-search__icon {
  display: grid; place-items: center;
  width: 48px;
  color: rgba(255,255,255,0.55);
}
.ph-search__input {
  flex: 1;
  padding: 14px 8px;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 15px;
  font-family: inherit;
  outline: none;
}
.ph-search__input::placeholder { color: rgba(255,255,255,0.4); }
.ph-search__btn {
  padding: 0 22px;
  background: var(--ph-orange);
  border: none;
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
}
.ph-search__btn:hover { background: #E85D1A; }

.ph-value-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  max-width: 880px;
  margin: 40px auto 0;
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,0.08);
}
.ph-value {
  text-align: center;
}
.ph-value__icon {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  margin: 0 auto 12px;
  border-radius: 10px;
  background: rgba(0,175,239,0.12);
  color: #4DC4F4;
}
.ph-value__title {
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 4px;
}
.ph-value__body {
  color: rgba(255,255,255,0.6);
  font-size: 13px;
  line-height: 1.5;
}

@media (max-width: 768px) {
  .ph-value-strip { grid-template-columns: 1fr; gap: 18px; }
}

/* ══════════════════════════════════════════════════════════════════
   C · COURSE DETAIL HERO
   ══════════════════════════════════════════════════════════════════ */
.page-hero.ph--course { padding-bottom: clamp(64px, 6vw, 96px); }
.page-hero.ph--course .ph-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(320px, 0.9fr);
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}

.ph-course-code {
  display: inline-block;
  padding: 5px 14px;
  background: rgba(0, 175, 239, 0.18);
  border: 1px solid rgba(0, 175, 239, 0.4);
  color: #4DC4F4;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 18px;
}
.ph-course-tag {
  color: rgba(255,255,255,0.7);
  font-size: 16px;
  font-weight: 500;
  margin: -8px 0 22px;
}
.ph-course-facts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px 28px;
  padding: 22px 0;
  border-top: 1px solid rgba(255,255,255,0.1);
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin: 28px 0;
}
.ph-course-fact-lbl {
  color: rgba(255,255,255,0.55);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.ph-course-fact-val {
  color: #fff;
  font-size: 15px;
  font-weight: 600;
}
.ph-course-modules {
  margin-top: 6px;
}
.ph-course-modules-head {
  color: rgba(255,255,255,0.55);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.ph-course-modules-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 24px;
}
.ph-course-module {
  display: flex; align-items: flex-start; gap: 10px;
  color: rgba(255,255,255,0.85);
  font-size: 14px;
  line-height: 1.4;
}
.ph-course-module svg { color: var(--ph-orange-2); flex-shrink: 0; margin-top: 2px; }

/* Sticky buy card */
.ph-buy-card {
  position: sticky;
  top: 88px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 18px;
  padding: 24px;
  backdrop-filter: blur(8px);
}
.ph-buy-card__price {
  font-family: 'Space Grotesk', 'Manrope', sans-serif;
  color: #fff;
  font-size: 36px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}
.ph-buy-card__price-sub {
  color: var(--ph-orange-2);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 18px;
}
.ph-buy-card__list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 18px;
  margin-bottom: 22px;
}
.ph-buy-card__list li {
  display: flex; align-items: flex-start; gap: 10px;
  color: rgba(255,255,255,0.85);
  font-size: 13px;
  line-height: 1.45;
  padding: 7px 0;
}
.ph-buy-card__list svg { color: #10D87A; flex-shrink: 0; margin-top: 2px; }
.ph-buy-card__cta {
  display: block;
  width: 100%;
  text-align: center;
  padding: 13px 0;
  background: var(--ph-orange);
  color: #fff;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  margin-bottom: 10px;
  transition: background 150ms ease;
}
.ph-buy-card__cta:hover { background: #E85D1A; }
.ph-buy-card__ghost {
  display: block;
  width: 100%;
  text-align: center;
  padding: 11px 0;
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: border-color 150ms ease;
}
.ph-buy-card__ghost:hover { border-color: rgba(255,255,255,0.6); }
.ph-buy-card__trust {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.55);
  font-size: 11px;
  text-align: center;
}

@media (max-width: 980px) {
  .page-hero.ph--course .ph-inner { grid-template-columns: 1fr; }
  .ph-buy-card { position: static; }
}
@media (max-width: 600px) {
  .ph-course-modules-grid,
  .ph-course-facts { grid-template-columns: 1fr; }
}

/* ══════════════════════════════════════════════════════════════════
   D · SALES / CONVERSION HERO
   ══════════════════════════════════════════════════════════════════ */
.page-hero.ph--sales .ph-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 4vw, 56px);
  align-items: center;
}

.ph-preview {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 18px;
  padding: 22px;
  backdrop-filter: blur(6px);
}
.ph-preview__head {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 13px;
  color: rgba(255,255,255,0.65);
  margin-bottom: 16px;
  font-weight: 600;
}
.ph-preview__count {
  display: inline-block;
  background: rgba(0,175,239,0.18);
  color: #4DC4F4;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 999px;
}
.ph-preview-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 0;
  border-top: 1px solid rgba(255,255,255,0.08);
  gap: 12px;
}
.ph-preview-row:first-child { border-top: none; padding-top: 0; }
.ph-preview-row__title {
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 3px;
}
.ph-preview-row__meta {
  color: rgba(255,255,255,0.58);
  font-size: 12px;
}
.ph-preview-row__badge {
  flex-shrink: 0;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(249,115,22,0.18);
  color: var(--ph-orange-2);
}
.ph-preview-row__badge--green { background: rgba(16,216,122,0.18); color: #10D87A; }
.ph-preview-row__badge--cyan  { background: rgba(0,175,239,0.18); color: #4DC4F4; }

@media (max-width: 980px) {
  .page-hero.ph--sales .ph-inner { grid-template-columns: 1fr; }
}

/* ══════════════════════════════════════════════════════════════════
   E · AUTH / FORM HERO
   ══════════════════════════════════════════════════════════════════ */
.page-hero.ph--auth { min-height: 520px; padding-bottom: clamp(64px, 6vw, 96px); }
.page-hero.ph--auth .ph-inner {
  display: grid;
  grid-template-columns: 1fr minmax(360px, 460px);
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}
.page-hero.ph--auth .ph-h1 {
  font-size: clamp(28px, 4vw, 42px);
}
.ph-auth-bullets {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
}
.ph-auth-bullets li {
  display: flex; align-items: flex-start; gap: 10px;
  color: rgba(255,255,255,0.78);
  font-size: 14px;
  line-height: 1.5;
  padding: 6px 0;
}
.ph-auth-bullets svg { color: var(--ph-orange-2); flex-shrink: 0; margin-top: 3px; }

.ph-form-card {
  background: #fff;
  border-radius: 18px;
  padding: 28px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
  color: var(--ph-ink);
}
.ph-form-card__head {
  margin-bottom: 18px;
}
.ph-form-card__title {
  color: var(--ph-ink);
  font-family: 'Space Grotesk', 'Manrope', sans-serif;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 4px;
}
.ph-form-card__sub {
  color: var(--ph-ink-2);
  font-size: 13px;
}
.ph-form-card .field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}
.ph-form-card .field label {
  font-size: 12px;
  font-weight: 700;
  color: var(--ph-ink);
  letter-spacing: 0.04em;
}
.ph-form-card .field input,
.ph-form-card .field textarea,
.ph-form-card .field select {
  padding: 11px 13px;
  border: 1.5px solid var(--ph-border-light);
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  color: var(--ph-ink);
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
.ph-form-card .field input:focus,
.ph-form-card .field textarea:focus,
.ph-form-card .field select:focus {
  border-color: var(--ph-orange);
  box-shadow: 0 0 0 3px rgba(249,115,22,0.12);
}
.ph-form-card__cta {
  display: inline-flex; align-items: center; justify-content: center;
  width: 100%;
  padding: 13px 0;
  background: var(--ph-orange);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background 150ms ease;
  font-family: inherit;
}
.ph-form-card__cta:hover { background: #E85D1A; }
.ph-form-card__alt {
  text-align: center;
  font-size: 13px;
  color: var(--ph-ink-2);
  margin-top: 14px;
}
.ph-form-card__alt a { color: var(--ph-orange); font-weight: 700; text-decoration: none; }
.ph-form-card__alt a:hover { text-decoration: underline; }

@media (max-width: 980px) {
  .page-hero.ph--auth .ph-inner { grid-template-columns: 1fr; }
}

/* ══════════════════════════════════════════════════════════════════
   Reduced motion safety
   ══════════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  .ph-btn, .ph-chip, .ph-buy-card__cta, .ph-form-card__cta,
  .ph-buy-card__ghost, .ph-form-card .field input { transition: none; }
}
