/* ==========================================================================
   EduBridgeSA — Public homepage layer (v3, dark navy + amber atmosphere)
   --------------------------------------------------------------------------
   Loaded only by index.php. Every rule is scoped to `body.site-homepage` or the
   `.eb*` namespace, so the login page, workspace and all other public pages keep
   their existing design.

   Composition: atmospheric dark hero carrying the graduate photograph, three
   service tiles on the same navy bed, one light journey section with two compact
   panels, one dark closing call to action.
   ========================================================================== */

body.site-homepage {
  font-family: var(--eui-font-body, 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif);
  color: #0a1628;
  background: #fff;
}

body.site-homepage h1,
body.site-homepage h2,
body.site-homepage h3 {
  font-family: var(--eui-font-display, 'Poppins', sans-serif);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.ebhome {
  --eb-navy-900: #06101d;
  --eb-navy-800: #0a1628;
  --eb-navy-700: #0e2138;
  --eb-amber: #f59e0b;
  --eb-amber-warm: #fb923c;
  --eb-amber-light: #fbbf24;
  --eb-on-dark: #eaf1fb;
  --eb-on-dark-soft: #a9bdd6;
  --eb-ink: #0a1628;
  --eb-ink-soft: #41546b;
  --eb-ink-mute: #5a6c85;
  --eb-green: #22c55e;
  --eb-line: rgba(10, 22, 40, 0.1);
}

.ebhome__shell {
  width: min(100% - 2rem, 76rem);
  margin-inline: auto;
  min-width: 0;
}

.ebhome a:focus-visible,
.ebhome button:focus-visible {
  outline: 3px solid #fbbf24;
  outline-offset: 3px;
}

/* --------------------------------------------------------------------------
   1. Atmospheric hero
   -------------------------------------------------------------------------- */
.ebhero {
  position: relative;
  overflow: clip;
  isolation: isolate;
  /* Amber stays anchored to the top corner so it reads as warm light on navy,
     never as a brown wash across a narrow screen. */
  background:
    radial-gradient(30rem 22rem at 104% -8%, rgba(245, 158, 11, 0.3), rgba(245, 158, 11, 0) 62%),
    radial-gradient(34rem 24rem at 60% 40%, rgba(251, 146, 60, 0.1), transparent 72%),
    radial-gradient(38rem 30rem at -6% -14%, rgba(37, 99, 235, 0.34), transparent 66%),
    linear-gradient(165deg, #0e2340 0%, #0a1628 55%, #070f1c 100%);
  padding-top: clamp(1.25rem, 3vw, 2rem);
}

/* Warm floor glow that lifts the photograph off the navy. */
.ebhero::before {
  content: '';
  position: absolute;
  inset: auto 0 0 0;
  height: 55%;
  background: radial-gradient(60% 100% at 78% 100%, rgba(245, 158, 11, 0.11), transparent 72%);
  pointer-events: none;
  z-index: 0;
}

.ebhero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  width: 100%;
  max-width: 96rem;
  margin-inline: auto;
  padding-inline: 1rem;
}

.ebhero__copy {
  min-width: 0;
  padding-block: clamp(1.6rem, 5vw, 2.5rem) clamp(1.25rem, 4vw, 2rem);
}

.ebhero__eyebrow {
  position: relative;
  margin: 0 0 1.05rem;
  padding-bottom: 0.7rem;
  font-family: var(--eui-font-body, 'Inter', sans-serif);
  font-size: clamp(0.74rem, 0.7rem + 0.2vw, 0.86rem);
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #fcd34d;
}

.ebhero__eyebrow::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 3.5rem;
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(90deg, #fbbf24, #f97316);
}

.ebhero h1 {
  margin: 0 0 1.05rem;
  /* Sized so "ONE CLEAR PATH" holds a single desktop line at every breakpoint. */
  font-size: clamp(2rem, 1.1rem + 2.75vw, 3.6rem);
  line-height: 1.03;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  color: #ffffff;
  text-wrap: balance;
  text-shadow: 0 18px 40px rgba(3, 10, 20, 0.55);
}

.ebhero__lede {
  max-width: 33rem;
  margin: 0 0 clamp(1.3rem, 3vw, 1.8rem);
  font-size: clamp(1rem, 0.96rem + 0.33vw, 1.17rem);
  line-height: 1.62;
  color: #c6d5e8;
}

.ebhero__lede strong { font-weight: 700; color: #ffffff; }

.ebhero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.9rem 1.5rem;
}

.ebhero__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 3.4rem;
  padding: 0.9rem 1.65rem;
  border-radius: 0.4rem;
  font-family: var(--eui-font-body, 'Inter', sans-serif);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.055em;
  text-transform: uppercase;
  text-decoration: none;
  transition: transform 200ms ease, box-shadow 200ms ease, background-color 200ms ease;
}

.ebhero__btn--primary {
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 55%, #f97316 100%);
  color: #08111f;
  box-shadow: 0 18px 38px -18px rgba(245, 158, 11, 0.75), 0 2px 0 rgba(255, 236, 179, 0.35) inset;
}

.ebhero__btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 44px -18px rgba(245, 158, 11, 0.85), 0 2px 0 rgba(255, 236, 179, 0.45) inset;
}

.ebhero__btn--primary i { font-size: 0.85em; }

.ebhero__btn--link {
  padding-inline: 0.3rem;
  color: #f4f8ff;
  text-decoration: underline;
  text-decoration-color: rgba(251, 191, 36, 0.9);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.45rem;
}

.ebhero__btn--link:hover { color: #fcd34d; }

.ebhero__login {
  margin: 1.15rem 0 0;
  font-size: 0.92rem;
  color: #93a8c2;
}

.ebhero__login a {
  color: #fcd34d;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 0.2rem;
}

/* Photography: masked into the navy on its left and lower edges, with a warm
   rim light so the graduates read as lit by the same amber glow as the hero. */
.ebhero__media {
  position: relative;
  margin: 0 -1rem;
  min-width: 0;
  height: clamp(14rem, 58vw, 20rem);
  overflow: clip;
}

.ebhero__media picture,
.ebhero__media img {
  display: block;
  width: 100%;
  height: 100%;
}

.ebhero__media img {
  object-fit: cover;
  object-position: 52% 18%;
  filter: saturate(1.06) contrast(1.04) brightness(0.97);
  -webkit-mask-image:
    linear-gradient(90deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.55) 7%, #000 22%),
    linear-gradient(180deg, #000 58%, rgba(0, 0, 0, 0) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, #000 10%);
  -webkit-mask-composite: source-in;
  mask-image:
    linear-gradient(90deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.55) 7%, #000 22%),
    linear-gradient(180deg, #000 58%, rgba(0, 0, 0, 0) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, #000 10%);
  mask-composite: intersect;
}

.ebhero__media::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(58% 46% at 82% 6%, rgba(245, 158, 11, 0.26), transparent 68%),
    linear-gradient(100deg, rgba(10, 22, 40, 0.55) 0%, rgba(10, 22, 40, 0) 34%);
  mix-blend-mode: screen;
  pointer-events: none;
}

@media (min-width: 62rem) {
  /* No top padding: the photograph then reaches the top of the hero and melts
     into the navy instead of starting on a visible horizontal edge. */
  .ebhero {
    padding-top: 0;
    background:
      radial-gradient(74rem 42rem at 88% 2%, rgba(245, 158, 11, 0.3), rgba(245, 158, 11, 0) 60%),
      radial-gradient(46rem 32rem at 64% 46%, rgba(251, 146, 60, 0.13), transparent 68%),
      radial-gradient(62rem 42rem at 2% -12%, rgba(37, 99, 235, 0.32), transparent 64%),
      linear-gradient(165deg, #0d2038 0%, #0a1628 54%, #070f1c 100%);
  }

  .ebhero__inner {
    grid-template-columns: minmax(0, 0.94fr) minmax(0, 1.06fr);
    align-items: stretch;
    min-height: 32rem;
    padding-left: max(1.5rem, calc((100% - 76rem) / 2));
    padding-right: 0;
    padding-inline-end: 0;
  }

  .ebhero__copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-block: clamp(2.5rem, 4.6vw, 3.6rem);
    padding-right: clamp(1rem, 3vw, 3rem);
  }

  .ebhero__media {
    margin: 0;
    height: auto;
    min-height: 0;
  }

  .ebhero__media img {
    object-position: 50% 12%;
    -webkit-mask-image:
      linear-gradient(90deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.65) 9%, #000 26%),
      linear-gradient(180deg, #000 62%, rgba(0, 0, 0, 0) 100%),
      linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, #000 9%);
    mask-image:
      linear-gradient(90deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.65) 9%, #000 26%),
      linear-gradient(180deg, #000 62%, rgba(0, 0, 0, 0) 100%),
      linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, #000 9%);
  }
}

/* --------------------------------------------------------------------------
   2. Three linked service tiles, on the navy bed
   -------------------------------------------------------------------------- */
.ebservices {
  background:
    radial-gradient(52rem 26rem at 92% 0%, rgba(245, 158, 11, 0.13), transparent 66%),
    linear-gradient(180deg, #070f1c 0%, #08131f 100%);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-block: clamp(1.4rem, 3.2vw, 2.1rem) clamp(1.9rem, 4vw, 2.9rem);
}

.ebservices__inner {
  width: min(100% - 2rem, 76rem);
  margin-inline: auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.7rem;
}

@media (min-width: 48rem) {
  .ebservices__inner { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.9rem; }
}

.ebtile {
  display: grid;
  grid-template-columns: auto 4px minmax(0, 1fr);
  align-items: start;
  gap: 0.9rem;
  min-width: 0;
  padding: 1.1rem 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.045);
  color: #ffffff;
  text-decoration: none;
  transition: border-color 200ms ease, background-color 200ms ease, transform 200ms ease;
}

.ebtile:hover {
  border-color: rgba(245, 158, 11, 0.5);
  background: rgba(255, 255, 255, 0.075);
  transform: translateY(-2px);
}

.ebtile__icon {
  display: grid;
  place-items: center;
  width: 2.35rem;
  height: 2.35rem;
  color: #fbbf24;
  font-size: 1.3rem;
  line-height: 1;
}

.ebtile__bar {
  align-self: stretch;
  width: 4px;
  border-radius: 2px;
  background: linear-gradient(180deg, #22c55e, #16a34a);
}

.ebtile__body { display: block; min-width: 0; }

.ebtile__title {
  display: block;
  margin-bottom: 0.28rem;
  font-family: var(--eui-font-display, 'Poppins', sans-serif);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: 0.045em;
  text-transform: uppercase;
  color: #ffffff;
}

.ebtile__text {
  display: block;
  font-size: 0.91rem;
  line-height: 1.5;
  color: var(--eb-on-dark-soft);
}

/* --------------------------------------------------------------------------
   3. Journey + two compact panels (light, for readability)
   -------------------------------------------------------------------------- */
.ebjourney {
  padding-block: clamp(2rem, 4.5vw, 3.25rem) clamp(2.4rem, 5vw, 3.75rem);
  background: linear-gradient(180deg, #f7fafd 0%, #ffffff 100%);
}

.ebjourney__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1.35rem, 3vw, 2rem);
}

@media (min-width: 64rem) {
  .ebjourney__grid {
    grid-template-columns: minmax(0, 1.45fr) minmax(0, 0.95fr) minmax(0, 1.2fr);
    align-items: start;
    gap: clamp(1.25rem, 2.4vw, 1.9rem);
  }
}

.ebjourney__intro { min-width: 0; }

.ebjourney h2 {
  margin: 0 0 0.55rem;
  font-size: clamp(1.4rem, 1.1rem + 1.35vw, 2.05rem);
  line-height: 1.12;
  text-transform: uppercase;
  color: #0a1628;
  max-width: 30rem;
}

.ebjourney__lede {
  margin: 0 0 clamp(1.35rem, 3vw, 2rem);
  font-size: clamp(0.96rem, 0.94rem + 0.2vw, 1.04rem);
  line-height: 1.6;
  color: var(--eb-ink-soft);
  max-width: 32rem;
}

.ebjourney__steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.4rem;
}

@media (min-width: 34rem) {
  .ebjourney__steps { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.16rem; }
}

.ebstage { position: relative; min-width: 0; }

.ebstage__num {
  display: inline-grid;
  place-items: center;
  width: 2.05rem;
  height: 2.05rem;
  border-radius: 50%;
  background: #12a150;
  color: #fff;
  font-family: var(--eui-font-body, 'Inter', sans-serif);
  font-size: 0.9rem;
  font-weight: 700;
}

.ebstage h3 {
  margin: 0.6rem 0 0.25rem;
  font-size: 0.94rem;
  line-height: 1.25;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #0a1628;
}

.ebstage p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--eb-ink-soft);
}

@media (min-width: 34rem) {
  .ebstage:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 0.75rem;
    right: -0.72rem;
    width: 1.15rem;
    height: 0.62rem;
    background: #b6cfe8;
    clip-path: polygon(0 38%, 52% 38%, 52% 0, 100% 50%, 52% 100%, 52% 62%, 0 62%);
  }
}

.ebpanelcard {
  min-width: 0;
  border: 1px solid var(--eb-line);
  border-radius: 0.85rem;
  background: #fff;
  overflow: hidden;
  box-shadow: 0 16px 34px -30px rgba(10, 22, 40, 0.75);
}

.ebpanelcard__head {
  margin: 0;
  padding: 0.75rem 1rem;
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.055em;
  text-transform: uppercase;
  color: #0a1628;
}

.ebpanelcard--green .ebpanelcard__head { background: #edf8f0; }
.ebpanelcard--blue .ebpanelcard__head { background: #e9f2fe; }

.ebpanelcard__note {
  margin: 0;
  padding: 0.6rem 1rem 0.7rem;
  border-bottom: 1px solid rgba(10, 22, 40, 0.07);
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--eb-ink-mute);
}

.ebpanelcard__links,
.ebpanelcard__news {
  list-style: none;
  margin: 0;
  padding: 0;
}

.ebpanelcard__links li + li,
.ebpanelcard__news li + li { border-top: 1px solid rgba(10, 22, 40, 0.07); }

.ebpanelcard__links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 2.9rem;
  padding: 0.62rem 1rem;
  color: #0a1628;
  font-size: 0.93rem;
  font-weight: 600;
  text-decoration: none;
}

.ebpanelcard__links a:hover { background: #f7fbff; color: #0f5132; }

.ebpanelcard__links i { color: #ea7a12; font-size: 0.82em; }

.ebpanelcard__news a {
  display: block;
  padding: 0.7rem 1rem;
  color: #0a1628;
  text-decoration: none;
}

.ebpanelcard__news a:hover .ebnewstitle { color: #123e75; text-decoration: underline; text-underline-offset: 0.2rem; }

.ebnewstitle {
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.38;
}

.ebnewsdate {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.28rem;
  font-size: 0.78rem;
  color: var(--eb-ink-mute);
}

.ebnewsdate i { font-size: 0.85em; }

.ebpanelcard__all {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 2.75rem;
  padding: 0.6rem 1rem;
  border-top: 1px solid rgba(10, 22, 40, 0.07);
  color: #123e75;
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
}

.ebpanelcard__all:hover { background: #f7fbff; }
.ebpanelcard__all i { font-size: 0.8em; color: #ea7a12; }

/* --------------------------------------------------------------------------
   4. Closing call to action, back in the navy with amber light
   -------------------------------------------------------------------------- */
.ebcta {
  position: relative;
  overflow: clip;
  background:
    radial-gradient(46rem 22rem at 84% 50%, rgba(245, 158, 11, 0.22), transparent 68%),
    radial-gradient(38rem 20rem at 8% 0%, rgba(37, 99, 235, 0.2), transparent 70%),
    linear-gradient(160deg, #0c1d33 0%, #0a1628 60%, #070f1c 100%);
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  padding-block: clamp(1.8rem, 3.8vw, 2.6rem);
}

.ebcta__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  align-items: center;
}

@media (min-width: 52rem) {
  .ebcta__inner { grid-template-columns: minmax(0, 1fr) auto; gap: 2rem; }
}

.ebcta h2 {
  margin: 0;
  font-size: clamp(1.25rem, 1.05rem + 1vw, 1.8rem);
  line-height: 1.15;
  text-transform: uppercase;
  color: #ffffff;
}

.ebcta__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 3.15rem;
  padding: 0.8rem 1.5rem;
  border-radius: 0.4rem;
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 55%, #f97316 100%);
  color: #08111f;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  justify-self: start;
  box-shadow: 0 16px 34px -20px rgba(245, 158, 11, 0.8);
  transition: transform 200ms ease, box-shadow 200ms ease;
}

.ebcta__btn:hover { transform: translateY(-2px); box-shadow: 0 20px 38px -18px rgba(245, 158, 11, 0.9); }
.ebcta__btn i { font-size: 0.85em; }

@media (min-width: 52rem) {
  .ebcta__btn { justify-self: end; }
}

/* --------------------------------------------------------------------------
   5. Reveal — transform only, never hides content
   -------------------------------------------------------------------------- */
.ebhome-reveal { opacity: 1; transform: none; }

.ebhome-js .ebhome-reveal {
  transform: translateY(0.85rem);
  transition: transform 540ms cubic-bezier(0.16, 1, 0.3, 1);
}

.ebhome-js .ebhome-reveal.is-visible { transform: none; }

/* --------------------------------------------------------------------------
   6. Accessibility
   -------------------------------------------------------------------------- */
.ebhero h1,
.ebhero__lede,
.ebtile__title,
.ebjourney h2,
.ebnewstitle { overflow-wrap: break-word; }

.ebhome a,
.ebhome button { -webkit-tap-highlight-color: transparent; }

@media (prefers-reduced-motion: reduce) {
  .ebhome-js .ebhome-reveal,
  .ebhome-js .ebhome-reveal.is-visible { opacity: 1; transform: none; transition: none; }
  .ebtile:hover,
  .ebhero__btn--primary:hover,
  .ebcta__btn:hover { transform: none; }
}

@media (prefers-contrast: more) {
  .ebtile { border-color: rgba(255, 255, 255, 0.45); }
  .ebpanelcard,
  .ebpanelcard__links li + li,
  .ebpanelcard__news li + li { border-color: rgba(10, 22, 40, 0.55); }
}
