:root {
  --rp-navy: #003964;
  --rp-teal: #368ba9;
  --rp-teal-hover: #2d7590;
  --rp-orange: #cd6414;
  --rp-orange-hover: #a84f0f;
  --rp-green: #5a8c4d;
  --rp-charcoal: #404041;
  --rp-text: #333333;
  --rp-text-body: #404041;
  --rp-bg: #ffffff;
  --rp-amber: #cd6414;
  --rp-amber-hover: #a84f0f;
  --font-display: 'IBM Plex Serif', Georgia, serif;
  --font-body: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  overflow-x: hidden !important;
}

body {
  background: var(--rp-bg);
  color: var(--rp-text);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden !important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-family: var(--font-body);
}

/* Max-width / overflow safety */
.hero,
.hero-section,
.page-hero,
.hero-bg,
.trust-strip {
  position: relative;
  z-index: 1;
  max-width: 100%;
}

.hero * {
  max-width: 100%;
}

/* Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--rp-amber);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0 32px;
  height: 52px;
  min-width: 200px;
  border: 2px solid transparent;
  border-radius: 4px;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.15s, box-shadow 0.15s, transform 0.15s;
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.btn-primary:hover {
  background: var(--rp-amber-hover);
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.2);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: transparent;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0 28px;
  height: 52px;
  border: 1.5px solid rgba(255,255,255,0.55);
  border-radius: 4px;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: all 0.2s;
}

.btn-secondary:hover {
  border-color: #fff;
  background: rgba(255,255,255,0.1);
}

/* Hero */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  max-height: 880px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  padding-top: 60px;
}

.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  animation: heroZoom 20s ease-out both;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 55%;
  display: block;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(175deg, rgba(0,57,100,0.2) 0%, transparent 40%),
    linear-gradient(to bottom, transparent 30%, rgba(0,0,0,0.75) 100%);
}

@keyframes heroZoom {
  from { transform: scale(1.06); }
  to { transform: scale(1); }
}

.hero-inner {
  position: relative;
  z-index: 2;
  padding: 0 80px 80px;
  max-width: 900px !important;
  width: 100%;
  animation: heroRise 0.9s cubic-bezier(0.2,0.8,0.3,1) 0.15s both;
}

@keyframes heroRise {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: none; }
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.72);
  margin-bottom: 18px;
}

.hero-kicker-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--rp-amber);
  flex-shrink: 0;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(38px, 5.5vw, 66px);
  font-weight: 700;
  color: #fff;
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin: 0 0 18px 0 !important;
}

.hero-sub {
  font-size: 17px;
  font-weight: 300;
  color: rgba(255,255,255,0.86);
  line-height: 1.65;
  max-width: 620px;
  margin-bottom: 36px;
}

.hero-ctas {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

/* Trust strip */
.trust-strip {
  background: var(--rp-navy);
  display: flex;
}

.trust-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 22px 12px;
  border-right: 1px solid rgba(255,255,255,0.1);
  gap: 4px;
}

.trust-item:last-child { border-right: none; }

.trust-stars {
  color: #FFD700;
  font-size: 14px;
  letter-spacing: 3px;
  line-height: 1;
  white-space: nowrap;
}

.trust-num {
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  line-height: 1;
  text-align: center;
  word-break: keep-all;
}

.trust-label {
  font-size: 10px;
  font-weight: 500;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: center;
}

/* Programs intro */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--rp-teal);
  margin-bottom: 12px;
}

.eyebrow::before {
  content: '';
  width: 28px;
  height: 2px;
  background: var(--rp-teal);
  flex-shrink: 0;
}

.section-title {
  font-size: clamp(26px, 3.2vw, 42px);
  font-weight: 700;
  color: var(--rp-navy);
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin-bottom: 40px;
}

.programs-intro {
  max-width: 1200px;
  margin: 0 auto;
  padding: 72px 48px 40px;
}

/* =========================
   Tablet (<= 1024px)
========================= */
@media (max-width: 1024px) {
  .hero {
    height: auto;
    min-height: 560px;
    max-height: none;
    padding-top: 56px;
  }

  .hero-bg img {
    object-position: center center; /* center crop on smaller screens */
    transform: none;
  }

  .hero-inner {
    max-width: 760px !important;
    padding: 0 24px 56px;
  }

  .hero h1 {
    font-size: clamp(32px, 5vw, 48px);
    line-height: 1.04;
    margin-bottom: 14px !important;
  }

  .hero-sub {
    font-size: 15px;
    line-height: 1.55;
    max-width: 100%;
    margin-bottom: 24px;
  }

  .hero-ctas {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    width: 100%;
    align-items: stretch;
  }

  .hero-ctas .btn-primary,
  .hero-ctas .btn-secondary {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    height: 50px;
    padding: 0 14px;
    justify-content: center;
    text-align: center;
    white-space: normal;
  }

  /* Trust strip: switch to grid to prevent broken wrapping */
  .trust-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: 100%;
    overflow: hidden;
  }

  .trust-item {
    min-width: 0;
    width: auto;
    flex: unset;
    padding: 18px 10px;
    border-right: 1px solid rgba(255,255,255,0.1);
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }

  .trust-item:nth-child(3n) { border-right: none; }
  .trust-item:nth-last-child(-n+2) { border-bottom: none; }

  .trust-num { font-size: 18px; line-height: 1.05; }
  .trust-label { font-size: 9px; line-height: 1.2; letter-spacing: 0.08em; }
  .trust-stars { font-size: 12px; letter-spacing: 2px; }

  .programs-intro {
    padding: 44px 24px 24px;
  }

  .programs-intro .section-title {
    margin-bottom: 16px;
  }

  .programs-intro p {
    margin-top: 0 !important;
    font-size: 15px !important;
    line-height: 1.6 !important;
  }
}

/* =========================
   Phone (<= 640px)
========================= */
@media (max-width: 640px) {
  .hero {
    min-height: 500px;
    padding-top: 50px;
  }

  .hero-bg img {
    object-position: center 42%; /* lift crop a bit for faces */
  }

  .hero-inner {
    padding: 0 18px 44px;
  }

  .hero-kicker {
    font-size: 10px;
    letter-spacing: 0.14em;
    gap: 8px;
    margin-bottom: 12px;
    flex-wrap: wrap;
  }

  .hero h1 {
    font-size: clamp(26px, 8vw, 34px);
    line-height: 1.05;
  }

  .hero-sub {
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 18px;
  }

  .hero-ctas .btn-primary,
  .hero-ctas .btn-secondary {
    height: 48px;
    font-size: 11px;
    letter-spacing: 0.06em;
    max-width: 100%;
  }

  /* Trust strip: 2-column phone layout, fix last item */
  .trust-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .trust-item {
    padding: 16px 8px;
    border-right: 1px solid rgba(255,255,255,0.1);
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }

  .trust-item:nth-child(2n) { border-right: none; }

  /* If odd count (5 items), make the last tile full width */
  .trust-item:last-child:nth-child(odd) {
    grid-column: 1 / -1;
    border-right: none;
  }

  .trust-item:last-child { border-bottom: none; }

  .trust-num { font-size: 16px; }
  .trust-label { font-size: 8.5px; letter-spacing: 0.07em; }

  .programs-intro {
    padding: 34px 18px 18px;
  }

  .programs-intro .section-title {
    font-size: clamp(24px, 7vw, 30px);
    line-height: 1.12;
  }
}
  /* ==========================================
   FINAL MOBILE + TRUST STRIP + READABILITY PATCH
========================================== */

/* 1) Mobile-only button width fix */
@media (max-width: 640px) {
  .hero-ctas .btn-primary,
  .hero-ctas .btn-secondary {
    max-width: 80% !important;
    margin-left: 0 !important;
    margin-right: auto !important;
  }
}

/* 2) Trust strip underline consistency fix
   Keep bottom borders visible on the bottom row too */
@media (max-width: 1024px) {
  .trust-item:nth-last-child(-n+2) {
    border-bottom: 1px solid rgba(255,255,255,0.1) !important;
  }
}

@media (max-width: 640px) {
  .trust-item:last-child {
    border-bottom: 1px solid rgba(255,255,255,0.1) !important;
  }
}

/* 3) Make hero subtext easier to read on busy images */
.hero-sub {
  color: rgba(255,255,255,0.96) !important;
  text-shadow:
    0 1px 2px rgba(0,0,0,0.65),
    0 2px 10px rgba(0,0,0,0.45) !important;
}

/* Optional: also help the kicker/meta line readability */
.hero-kicker {
  color: rgba(255,255,255,0.9) !important;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5) !important;
}

/* Stronger overlay behind text for difficult images (best fix overall) */
.hero-bg::after {
  background:
    linear-gradient(180deg, rgba(0,0,0,0.08) 0%, rgba(0,0,0,0.12) 28%, rgba(0,0,0,0.68) 100%),
    linear-gradient(175deg, rgba(0,57,100,0.18) 0%, transparent 42%) !important;
}

/* Mobile: darken lower portion a bit more where text sits */
@media (max-width: 640px) {
  .hero-bg::after {
    background:
      linear-gradient(180deg, rgba(0,0,0,0.10) 0%, rgba(0,0,0,0.18) 30%, rgba(0,0,0,0.78) 100%),
      linear-gradient(175deg, rgba(0,57,100,0.14) 0%, transparent 45%) !important;
  }
}

/* Explore More Section */
.rp-related-section {
  margin: 2rem 0 0;
  padding: 1.5rem 0 0;
  border-top: 2px solid #e5e7eb;
}

.rp-related-eyebrow {
  margin: 0 0 0.5rem 0;
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #6b7280;
  line-height: 1.3;
}

.rp-related-title {
  margin: 0 0 1.1rem 0;
  font-size: 1.15rem;
  font-weight: 600;
  color: #003964;
  line-height: 1.3;
}

.rp-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.rp-card {
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}

.rp-card-image-wrap {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #003964;
}

.rp-card-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rp-card-body {
  padding: 0.65rem 0.75rem 0.75rem;
}

.rp-card-label {
  margin: 0 0 0.15rem 0;
  font-size: 0.63rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #00a89c;
  line-height: 1.3;
}

.rp-card-title {
  margin: 0 0 0.3rem 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: #003964;
  line-height: 1.3;
}

.rp-card-link {
  display: inline-block;
  margin: 0;
  font-size: 0.75rem;
  color: #6b7280;
  line-height: 1.4;
  text-decoration: none;
}

.rp-card-link:hover,
.rp-card-link:focus {
  text-decoration: underline;
}

@media (max-width: 991px) {
  .rp-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .rp-card-grid {
    grid-template-columns: 1fr;
  }
}
