/* Only for the bilingual JA Designs + RIVLYX concept.
   Reuses existing website layout; not part of the original live style.css. */
.ja-locale-switch{display:inline-flex;align-items:center;justify-content:center;gap:7px;flex-shrink:0;white-space:nowrap}
.ja-lang-flag{position:relative;display:inline-flex;align-items:center;justify-content:center;width:30px;height:30px;padding:0;border:1px solid transparent;border-radius:5px;background:transparent;color:#eee5d9;font:normal 20px/1 Arial,sans-serif;cursor:pointer;opacity:.65;filter:saturate(.9);transition:opacity .22s ease,background .22s ease,border-color .22s ease,transform .22s ease}
.ja-lang-flag:hover,.ja-lang-flag:focus-visible{opacity:1;filter:saturate(1);background:#c9a16b14;transform:translateY(-2px)}
.ja-lang-flag.active,.ja-lang-flag[aria-pressed="true"]{opacity:1;filter:saturate(1);background:#c9a16b16;border-color:#c9a16b66}
.ja-lang-flag span{display:block;line-height:1;font-size:20px}
header:not(.rv-header) .ja-locale-switch{margin-left:9px}
.rv-page .rv-header .ja-locale-switch{margin-left:0}
.privacy-locale-control{position:fixed;z-index:10;top:18px;right:5%;background:#11100ecf;padding:6px;border:1px solid #c9a16b38;border-radius:8px}
@media(max-width:850px){header:not(.rv-header) .ja-locale-switch{margin-left:auto;margin-right:10px}.rv-page .rv-header .ja-locale-switch{margin-left:auto;margin-right:8px}}
@media(max-width:520px){.ja-locale-switch{gap:2px}.ja-lang-flag{width:27px;height:29px}.ja-lang-flag span{font-size:18px}}
@media(prefers-reduced-motion:reduce){.ja-lang-flag{transition:none!important}.ja-lang-flag:hover{transform:none!important}}


/* Both headers use exactly the same desktop grid columns and gaps.
   Flags are exclusive to the JA Designs homepage. The RIVLYX header reserves
   a non-interactive space in their position, so nav + CTA never shift. */
@media (min-width: 1101px) {
  header:not(.rv-header), .rv-page .rv-header {
    display:grid;
    grid-template-columns:minmax(0,1fr) auto 187px 70px;
    align-items:center;
    gap:18px;
    justify-content:normal;
    padding-left:5%;
    padding-right:5%;
  }
  header:not(.rv-header) nav, .rv-page .rv-header nav {
    margin:0;
    justify-self:end;
    gap:36px;
  }
  header:not(.rv-header) .header-cta, .rv-page .rv-header .rv-return-home {
    width:187px;
    min-width:187px;
    box-sizing:border-box;
    justify-self:stretch;
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:13px 15px;
    white-space:nowrap;
  }
  header:not(.rv-header) .header-cta .ja-arrow, .rv-page .rv-header .rv-return-home .ja-arrow {
    margin-left:14px;
  }
  header:not(.rv-header) .ja-locale-switch {margin:0;justify-self:end}
  .rv-page .rv-header .ja-language-position-placeholder {width:70px;display:block}
}
@media (max-width:1100px) {
  .rv-page .rv-header .ja-language-position-placeholder{display:none}
}
@media (min-width:851px) {
  .rv-page .rv-header nav .rv-mobile-back {display:none}
}
@media (max-width:850px) {
  .rv-page .rv-header nav .rv-mobile-back {display:block}
}

/* Final 1px parity: identical typography and CTA height for both headers. */
@media (min-width:1101px){
  header:not(.rv-header) nav a, .rv-page .rv-header nav a {
    font-family:'DM Sans',Arial,sans-serif;
    font-size:13px;
    font-weight:300;
    line-height:normal;
    letter-spacing:normal;
  }
  header:not(.rv-header) .header-cta, .rv-page .rv-header .rv-return-home {
    height:44px;
    font-family:'DM Sans',Arial,sans-serif;
    font-weight:300;
    line-height:normal;
  }
}


/* Perfectly centered main navigation on both pages;
   retain the right-hand CTA/flag positioning and original main-site styling. */
@media (min-width:1101px){
  header:not(.rv-header),.rv-page .rv-header {
    grid-template-columns:minmax(0,1fr) 187px 70px;
  }
  header:not(.rv-header) nav,.rv-page .rv-header nav{
    position:absolute;
    left:50%;
    top:50%;
    transform:translate(-50%,-50%);
    margin:0;
    justify-self:auto;
    white-space:nowrap;
  }
  header:not(.rv-header) .brand,.rv-page .rv-header .brand{grid-column:1}
  header:not(.rv-header) .header-cta,.rv-page .rv-header .rv-return-home{grid-column:2}
  header:not(.rv-header) .ja-locale-switch,
  .rv-page .rv-header .ja-language-position-placeholder{grid-column:3}
}


/* Centered text without GPU transforms: sharp hover glyphs on both pages. */
@media (min-width:1101px){
 header:not(.rv-header) nav,
 .rv-page .rv-header nav {
   inset:0;
   width:max-content;
   max-width:calc(100% - 500px);
   height:100%;
   margin-inline:auto;
   display:flex;
   align-items:center;
   transform:none!important;
   translate:none!important;
   filter:none!important;
   will-change:auto;
 }
}
header:not(.rv-header) nav a,
.rv-page .rv-header nav a {
  transform:none!important;
  translate:none!important;
  filter:none!important;
  text-shadow:none!important;
  will-change:auto!important;
  transition:color .16s ease!important;
}
