/* IMIM touch-ups on top of the original Rhye styles. Loaded last on every page. */

/* Headings: Instrument Serif (Google Fonts). It has one weight (400) + italic, so no fake bold. */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6,
.xl, .xxl, .elementor-heading-title {
  font-family: 'Instrument Serif', Georgia, serif !important;
  font-weight: 400 !important;
  font-synthesis: none;
}

.imnav__short { display: none; }
/* small laptops (992–1359px): tighter header, shorter labels, so the link bar still fits on one line */
@media (min-width: 992px) and (max-width: 1359px) {
  #page-header, #page-header .header__container { padding-left: 24px !important; padding-right: 24px !important; }
  #page-header .header__container { padding-left: 0 !important; padding-right: 0 !important; }
  #page-header .header__controls > .row { margin-left: 0 !important; margin-right: 0 !important; padding: 0 20px; }
  #page-header .header__col { padding-left: 6px !important; padding-right: 6px !important; }
  #page-header .imnav-col { flex: 1 1 0 !important; min-width: 0 !important; width: auto !important; }
  #page-header .logo__img-primary, #page-header .logo__img-secondary { max-height: 44px; width: auto; }
  .imnav-col { padding: 0 12px !important; }
  .imnav > ul { gap: 0 !important; }
  .imnav__link { font-size: 14px !important; padding: 12px 9px !important; gap: 6px !important; }
  .imnav__link::after { left: 9px !important; right: 9px !important; }
  .imnav__full { display: none; }
  .imnav__short { display: inline; }
  .imnav__cta { padding: 11px 14px !important; font-size: 12px !important; }
  .imnav-cta-col { margin-left: 10px !important; }
  #page-header .header__col-lang-switcher { margin-left: 4px !important; }
  #page-header .lang-switcher a { padding-left: 12px !important; padding-right: 12px !important; font-size: 14px !important; }
}

/* ---------- Header navigation (desktop) — links built by header-nav.js from the WordPress menu ---------- */
.imnav-col, .imnav-cta-col { display: none; }
@media (min-width: 992px) {
  #page-header { --ink: #21442d; --ink-soft: rgba(33, 68, 45, .62); --panel: #f4f2ec; }
  #page-header.bg-dark-1, #page-header.header_sticky.bg-dark-1, .header_menu-opened #page-header { --ink: #f4f2ec; --ink-soft: rgba(244, 242, 236, .66); }
  .imnav-col { display: flex; justify-content: center; flex: 1 1 auto; min-width: 0; padding: 0 24px; }
  /* Rhye's header ignores the mouse except on its own controls; switch it back on for the link bar + button */
  .imnav-col .imnav, .imnav-col .imnav *, .imnav-cta-col, .imnav-cta-col * { pointer-events: auto !important; }
  .imnav, .imnav * { white-space: nowrap; word-break: normal !important; overflow-wrap: normal !important; hyphens: none; }
  #page-header .header__controls > .row { flex-wrap: nowrap; }
  #page-header .header__col { flex-shrink: 0; }
  #page-header .imnav-col { flex-shrink: 1; }
  .imnav-cta-col { margin-left: 16px; }
  #page-header .header__col-lang-switcher { margin-left: 12px; }
  .imnav-cta-col { display: block; }
  #page-header #js-burger { display: none; }
  .imnav ul { list-style: none; margin: 0; padding: 0; }
  .imnav > ul { display: flex; align-items: center; gap: clamp(2px, 1vw, 14px); }
  .imnav__item { position: relative; }
  .imnav__link {
    display: inline-flex; align-items: center; gap: 8px;
    font: 500 15px/1 'Mulish', system-ui, sans-serif; letter-spacing: .01em; text-align: left;
    color: var(--ink); background: none; border: 0; cursor: pointer;
    padding: 12px clamp(10px, .9vw, 16px); text-decoration: none !important; position: relative;
  }
  .imnav__link::after {             /* thin underline that draws in from the left */
    content: ''; position: absolute; left: 14px; right: 14px; bottom: 6px; height: 1px;
    background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .35s cubic-bezier(.2, .7, .2, 1);
  }
  .imnav__link:hover::after, .imnav__item.open > .imnav__link::after,
  .imnav__item.is-current > .imnav__link::after { transform: scaleX(1); }
  .imnav__link i {                  /* small chevron */
    width: 6px; height: 6px; border-right: 1px solid currentColor; border-bottom: 1px solid currentColor;
    transform: translateY(-2px) rotate(45deg); transition: transform .3s;
  }
  .imnav__item.open > .imnav__link i { transform: translateY(1px) rotate(225deg); }
  .imnav__link:focus-visible, .imnav__panel a:focus-visible, .imnav__cta:focus-visible { outline: 1px solid var(--ink); outline-offset: 2px; }

  .imnav__panel {
    position: absolute; top: calc(100% + 10px); left: 50%; min-width: 260px;
    padding: 10px; background: var(--panel); border: 1px solid rgba(33, 68, 45, .14);
    box-shadow: 0 24px 50px -24px rgba(20, 35, 25, .35);
    opacity: 0; visibility: hidden; transform: translate(-50%, 8px);
    transition: opacity .25s, transform .3s cubic-bezier(.2, .7, .2, 1), visibility 0s .3s;
  }
  .imnav__panel::before { content: ''; position: absolute; left: 0; right: 0; top: -12px; height: 12px; } /* hover bridge */
  .imnav__item.open > .imnav__panel { opacity: 1; visibility: visible; transform: translate(-50%, 0); transition-delay: 0s; }
  .imnav__panel a {
    display: block; padding: 11px 14px; color: #21442d; text-decoration: none !important;
    font: 400 15px/1.3 'Mulish', system-ui, sans-serif; white-space: nowrap;
    transition: background .2s, padding-left .25s;
  }
  .imnav__panel a:hover, .imnav__panel a[aria-current] { background: rgba(33, 68, 45, .07); padding-left: 20px; }

  .imnav__cta {
    display: inline-flex; align-items: center; gap: 10px; padding: 12px 20px;
    font: 600 13px/1 'Mulish', system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase;
    color: var(--ink); border: 1px solid var(--ink); text-decoration: none !important;
    transition: background .3s, color .3s;
  }
  .imnav__cta i { font-style: normal; transition: transform .3s; }
  .imnav__cta:hover { background: var(--ink); color: var(--panel); }
  #page-header.bg-dark-1 .imnav__cta:hover { color: #21442d; }
  .imnav__cta:hover i { transform: translateX(4px); }
}

/* ---------- Mega menu (desktop) — full-width panel under the header bar ---------- */
@media (min-width: 992px) {
  .imnav .imnav__item.has-sub { position: static; }
  .imnav .imnav__panel.mega {
    position: fixed; left: 24px; right: 24px; top: calc(var(--imnav-top, 90px) + 10px);
    min-width: 0; padding: 0; transform: translateY(-10px);
    background: #21442d; color: #f4f2ec; border: 1px solid rgba(244, 242, 236, .12);
    box-shadow: 0 40px 80px -30px rgba(10, 22, 14, .55);
    clip-path: inset(0 0 100% 0);
    transition: opacity .3s, transform .5s cubic-bezier(.2, .8, .2, 1), clip-path .55s cubic-bezier(.7, 0, .2, 1), visibility 0s .55s;
  }
  .imnav .imnav__item.open > .imnav__panel.mega { transform: none; clip-path: inset(0 0 0 0); }
  .imnav .imnav__panel.mega::before { top: -16px; height: 16px; }   /* hover bridge across the gap */
  .mega__in {
    display: grid; grid-template-columns: minmax(180px, .8fr) 2.2fr minmax(200px, 1fr);
    gap: clamp(24px, 3vw, 56px); padding: clamp(28px, 3vw, 44px); align-items: stretch;
  }
  /* intro column */
  .mega__intro { display: flex; flex-direction: column; border-right: 1px solid rgba(244, 242, 236, .14); padding-right: clamp(20px, 2.5vw, 40px); }
  .mega__idx { font: 500 12px/1 'Mulish', sans-serif; letter-spacing: .18em; color: #c9a77c; }
  .mega__title {
    margin: 18px 0 0; font: 400 clamp(34px, 3.4vw, 54px)/1 'Instrument Serif', Georgia, serif; color: #f4f2ec;
    white-space: normal !important; letter-spacing: -.01em;
  }
  .mega__count { margin-top: auto; padding-top: 24px; font: 400 13px/1 'Mulish', sans-serif; color: rgba(244, 242, 236, .55); }
  /* links: two columns, numbered, big serif names */
  .mega__links {
    display: grid !important; grid-auto-flow: column; grid-template-rows: repeat(var(--rows, 4), auto);
    column-gap: clamp(20px, 3vw, 48px); align-content: start;
  }
  .imnav .mega__links a {
    display: grid; grid-template-columns: 28px 1fr auto; align-items: baseline; gap: 10px;
    padding: 13px 0 !important; border-bottom: 1px solid rgba(244, 242, 236, .12);
    color: #f4f2ec !important; background: none !important; white-space: normal !important;
    opacity: 0; transform: translateY(12px);
    transition: opacity .4s, transform .5s cubic-bezier(.2, .8, .2, 1), color .25s;
  }
  .imnav .imnav__item.open .mega__links a { opacity: 1; transform: none; transition-delay: calc(.12s + var(--k, 0) * .04s), calc(.12s + var(--k, 0) * .04s), 0s; }
  .mega__n { font: 500 11px/1 'Mulish', sans-serif; letter-spacing: .1em; color: rgba(244, 242, 236, .45); }
  .mega__t { font: 400 clamp(20px, 1.7vw, 26px)/1.15 'Instrument Serif', Georgia, serif; transition: transform .35s cubic-bezier(.2, .8, .2, 1); }
  .imnav .mega__links a i { font-style: normal; font-size: 16px; opacity: 0; transform: translateX(-8px); transition: opacity .25s, transform .35s; }
  .imnav .mega__links a:hover, .imnav .mega__links a[aria-current] { color: #e8c99a !important; padding-left: 0 !important; }
  .imnav .mega__links a:hover .mega__t { transform: translateX(6px); }
  .imnav .mega__links a:hover i, .imnav .mega__links a[aria-current] i { opacity: 1; transform: none; }
  .imnav .mega__links a:hover .mega__n { color: #e8c99a; }
  /* picture */
  .mega__fig { margin: 0; overflow: hidden; position: relative; min-height: 200px; background: #2c5239; }
  .mega__fig img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.12); transition: transform 1.1s cubic-bezier(.2, .8, .2, 1); }
  .imnav .imnav__item.open .mega__fig img { transform: scale(1); }
  @media (prefers-reduced-motion: reduce) {
    .imnav .imnav__panel.mega, .imnav .mega__links a, .mega__fig img { transition: opacity .2s, visibility 0s !important; transform: none !important; clip-path: none !important; }
  }
}
@media (min-width: 992px) and (max-width: 1199px) {
  .mega__in { grid-template-columns: 1fr 2.4fr; }
  .mega__fig { display: none; }
}
/* the portrait collage sits on white: keep his face in frame */
.mega__fig img[src*='Lucian-Yong'] { object-position: 50% 22%; }

/* ---------- Footer bottom bar: copyright left, social icons right, no empty column ---------- */
.footer__area_lower { padding-top: 28px !important; padding-bottom: 28px !important; }
.footer__area_lower > .row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 40px; margin: 0; }
.footer__area_lower > .row > .footer__column { flex: 0 1 auto; max-width: none; width: auto; padding: 0; order: 0 !important; }
.footer__area_lower > .row > .footer__column:first-child { display: none; }       /* empty block */
.footer__area_lower > .row > .footer__column:nth-child(2) { flex: 1 1 520px; max-width: 760px; }
.footer__area_lower .textwidget p { margin: 0; font-size: 13px !important; line-height: 1.7; text-align: left !important; opacity: .72; }
.footer__area_lower .widget { margin: 0 !important; padding: 0 !important; }
.footer__area_lower .social { display: flex; gap: 6px; margin: 0; padding: 0; justify-content: flex-end; }
.footer__area_lower .social__item { margin: 0 !important; }
.footer__area_lower .social__icon {
  display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px;
  border: 1px solid rgba(244, 242, 236, .22); border-radius: 50%; transition: background .25s, border-color .25s, color .25s;
}
.footer__area_lower .social__icon:hover { background: #f4f2ec; border-color: #f4f2ec; color: #21442d !important; }
@media (max-width: 767px) {
  .footer__area_lower > .row { flex-direction: column-reverse; align-items: flex-start; }
  .footer__area_lower > .row > .footer__column, .footer__area_lower > .row > .footer__column:nth-child(2) { flex: 0 0 auto; max-width: 100%; }
  .footer__area_lower .social { justify-content: flex-start; }
}
/* page H1 added for search engines where the design had none (visually hidden, still read by screen readers) */
.seo-h1{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}

/* ---------- Team video (replaces the old team photo grid + group collage) ---------- */
.imvid { position: relative; margin: 0; overflow: hidden; background: #21442d; aspect-ratio: 4 / 5; width: 100%; }
.imvid__v { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; cursor: pointer; }
.imvid::after {   /* soft shade so the labels stay readable */
  content: ''; position: absolute; inset: auto 0 0 0; height: 38%; pointer-events: none;
  background: linear-gradient(to top, rgba(17, 34, 23, .62), rgba(17, 34, 23, 0));
}
.imvid__tag {
  position: absolute; z-index: 2; top: 16px; left: 16px; display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 12px; background: rgba(244, 242, 236, .92); color: #21442d; font: 600 12px/1 'Mulish', sans-serif; letter-spacing: .06em;
}
.imvid__tag i { width: 7px; height: 7px; border-radius: 50%; background: #c0392b; box-shadow: 0 0 0 0 rgba(192, 57, 43, .6); }
.imvid.is-playing .imvid__tag i { animation: imvidLive 1.6s infinite; }
@keyframes imvidLive { 70% { box-shadow: 0 0 0 8px rgba(192, 57, 43, 0); } 100% { box-shadow: 0 0 0 0 rgba(192, 57, 43, 0); } }
.imvid__sound {
  position: absolute; z-index: 2; left: 16px; bottom: 22px; display: inline-flex; align-items: center; gap: 10px;
  min-height: 44px; padding: 10px 16px 10px 12px; border: 0; cursor: pointer;
  background: #f4f2ec; color: #21442d; font: 700 13px/1 'Mulish', sans-serif; letter-spacing: .04em;
  transition: background .25s, color .25s, transform .25s;
}
.imvid__sound:hover { background: #e8c99a; }
.imvid__sound:focus-visible { outline: 2px solid #f4f2ec; outline-offset: 3px; }
.imvid__ico { position: relative; width: 22px; height: 22px; border-radius: 50%; background: #21442d; flex: none; }
.imvid__ico::before {   /* speaker */
  content: ''; position: absolute; left: 6px; top: 7px; width: 4px; height: 8px; background: #f4f2ec;
  clip-path: polygon(0 25%, 45% 25%, 100% 0, 100% 100%, 45% 75%, 0 75%);
  transform: scale(1.5); transform-origin: left center;
}
.imvid__ico::after {    /* waves when sound is on, a slash when muted */
  content: ''; position: absolute; left: 12px; top: 6px; width: 6px; height: 10px; border: 2px solid #f4f2ec;
  border-left: 0; border-top-color: transparent; border-bottom-color: transparent; border-radius: 0 50% 50% 0; opacity: 0;
}
.imvid.is-sound .imvid__ico::after { opacity: 1; }
.imvid:not(.is-sound) .imvid__sound { animation: imvidNudge 2.8s ease-in-out 1.5s 3; }
@keyframes imvidNudge { 0%, 100% { transform: none; } 50% { transform: translateY(-3px); } }
.imvid__bar { position: absolute; z-index: 2; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(244, 242, 236, .25); }
.imvid__bar i { display: block; height: 100%; background: #e8c99a; transform: scaleX(0); transform-origin: left; transition: transform .25s linear; }
.imvid--sm { max-width: 420px; margin: 0 auto; }

/* section */
.imteam { background: #f4f2ec; padding: clamp(64px, 9vw, 140px) clamp(20px, 5vw, 80px); position: relative; overflow: hidden; }
.imteam__in { max-width: 1240px; margin: 0 auto; display: grid; grid-template-columns: 1fr minmax(300px, 480px); gap: clamp(40px, 7vw, 120px); align-items: center; }
.imteam__eye { margin: 0 0 22px; font: 600 12px/1 'Mulish', sans-serif; letter-spacing: .2em; text-transform: uppercase; color: #9a7a4e; display: flex; align-items: center; gap: 14px; }
.imteam__eye::before { content: ''; width: 40px; height: 1px; background: currentColor; }
.imteam__h { margin: 0; font: 400 clamp(42px, 5.6vw, 88px)/.98 'Instrument Serif', Georgia, serif !important; color: #21442d; letter-spacing: -.01em; text-transform: none; }
.imteam__p { margin: 26px 0 0; max-width: 34ch; font: 400 clamp(16px, 1.25vw, 19px)/1.65 'Mulish', sans-serif; color: rgba(33, 68, 45, .8); }
.imteam__cta {
  margin-top: 36px; display: inline-flex; align-items: center; gap: 12px; min-height: 48px; padding: 14px 22px;
  border: 1px solid #21442d; color: #21442d !important; font: 600 13px/1 'Mulish', sans-serif; letter-spacing: .08em; text-transform: uppercase;
  text-decoration: none !important; transition: background .3s, color .3s;
}
.imteam__cta:hover { background: #21442d; color: #f4f2ec !important; }
.imteam__cta i { font-style: normal; transition: transform .3s; }
.imteam__cta:hover i { transform: translateX(4px); }
.imteam__media { position: relative; }
.imteam__deco { position: absolute; inset: 28px -28px -28px 28px; border: 1px solid rgba(33, 68, 45, .25); pointer-events: none; }
.imteam__media .imvid { box-shadow: 0 40px 80px -40px rgba(20, 35, 25, .45); }
@media (max-width: 860px) {
  .imteam__in { grid-template-columns: 1fr; }
  .imteam__media { max-width: 460px; width: 100%; margin: 0 auto; }
  .imteam__deco { inset: 16px -12px -16px 12px; }
  .imteam__p { max-width: none; }
}
@media (prefers-reduced-motion: reduce) { .imvid__sound { animation: none !important; } }