/*
  Hoja de estilos exclusiva para la cabecera REMCB.
  Sustituye la hoja anterior por esta: no modifica footer, columnas,
  artículos, comités, indexaciones ni el contenido de las páginas.
*/

.remcb-brand-header {
  width: 100%;
  color: #fff;
  background: linear-gradient(110deg, #00577b 0%, #006083 50%, #005276 100%);
  border-bottom: 1px solid rgba(255, 255, 255, .55);
}

.remcb-brand-header,
.remcb-brand-header * {
  box-sizing: border-box;
}

.remcb-brand-header__utility {
  min-height: 44px;
  background: #004866;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
}

.remcb-brand-header__utility-inner {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  width: 100%;
  min-height: 44px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 72px);
}

.remcb-brand-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 48px;
  width: 100%;
  min-height: 166px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 72px);
}

.remcb-language,
.remcb-login {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  border: 0;
  border-radius: 0;
  color: #fff;
  background: transparent;
  font-size: 14px;
  line-height: 1;
}

.remcb-language {
  gap: 7px;
  padding: 0 14px 0 0;
  border-right: 1px solid rgba(255, 255, 255, .7);
}

.remcb-language::after {
  content: "▾";
  margin-left: -22px;
  margin-right: 5px;
  font-size: 11px;
  pointer-events: none;
}

.remcb-language select {
  min-height: 32px;
  padding: 0 28px 0 4px;
  border: 0;
  color: #fff;
  background: transparent;
  font: inherit;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.remcb-language select option {
  color: #173d50;
  background: #fff;
}

.remcb-login {
  padding: 0;
  text-decoration: none;
  font-weight: 700;
}

.remcb-user-control,
.remcb-user-slot {
  display: flex;
  align-items: center;
  min-height: 34px;
}

.remcb-user-control {
  gap: 7px;
}

/* En la cabecera se muestra solo el acceso. OJS seguirá ofreciendo el
   registro desde su página de inicio de sesión. */
.remcb-user-slot #navigationUser a[href*="/user/register"] {
  display: none !important;
}

.remcb-tool-icon {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.remcb-user-slot #navigationUser {
  position: static !important;
  display: flex !important;
  align-items: center;
  float: none !important;
  min-height: 34px;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none;
}

.remcb-user-slot #navigationUser > li {
  position: relative;
  display: block;
  margin: 0;
}

.remcb-user-slot #navigationUser > li > a {
  display: flex;
  align-items: center;
  min-height: 34px;
  padding: 0 !important;
  border: 0;
  border-radius: 0;
  color: #fff !important;
  background: transparent !important;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
}

.remcb-user-slot #navigationUser > li > a:hover,
.remcb-user-slot #navigationUser > li > a:focus,
.remcb-user-slot #navigationUser > .open > a {
  color: #fff !important;
  background: transparent !important;
  text-decoration: underline;
}

.remcb-user-slot #navigationUser .dropdown-menu {
  right: 0;
  left: auto;
  z-index: 1100;
}

.remcb-user-slot #navigationUser .dropdown-menu a {
  color: #284c83 !important;
}

.remcb-login:hover,
.remcb-login:focus,
.remcb-language:focus-within {
  color: #fff;
  background: transparent;
  text-decoration: underline;
}

.remcb-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.remcb-brand-header__journal,
.remcb-brand-header__puce {
  display: block;
  flex: 0 1 auto;
  line-height: 0;
}

.remcb-brand-header__journal img {
  display: block;
  width: clamp(310px, 35vw, 500px);
  height: auto;
  max-height: 164px;
  object-fit: contain;
  object-position: left center;
}

.remcb-brand-header__puce img {
  display: block;
  width: clamp(275px, 28vw, 430px);
  height: auto;
  max-height: 132px;
  object-fit: contain;
  object-position: right center;
}

/* Solo conserva el azul y el contraste del menú de OJS. */
header .container-fluid {
  background-color: #005278 !important;
}

/* Oculta el título textual que OJS inserta a la izquierda del menú.
   No afecta los logotipos de la cabecera personalizada. */
header.navbar .navbar-header > a.navbar-brand,
header.navbar a.navbar-brand:not(.remcb-brand-header__journal) {
  display: none !important;
}

.navbar-default .nav > li > a,
.navbar-default .navbar-nav > li > a {
  color: #fff !important;
  font-weight: 700;
}

/* Amplía únicamente el contenedor principal de OJS; no alcanza al footer. */
.pkp_structure_content {
  box-sizing: border-box;
  width: 100% !important;
  max-width: none !important;
}

.dropdown-toggle:hover,
.navbar-default .navbar-nav > .open > a,
.navbar-default .navbar-nav > .open > a:hover,
.navbar-default .navbar-nav > .open > a:focus {
  background-color: rgba(255, 255, 255, .18) !important;
}

@media (max-width: 767px) {
  .remcb-brand-header__utility,
  .remcb-brand-header__utility-inner,
  .remcb-brand-header__inner {
    min-height: auto;
  }

  .remcb-brand-header__utility-inner {
    flex-wrap: wrap;
    padding: 8px 20px;
  }

  .remcb-brand-header__inner {
    flex-direction: column;
    align-items: center;
    gap: 22px;
    padding: 24px 20px;
  }

  .remcb-brand-header__journal img {
    width: min(100%, 430px);
    max-height: none;
  }

  .remcb-brand-header__puce img {
    width: min(86%, 330px);
    max-height: none;
  }
}

@media (max-width: 420px) {
  .remcb-brand-header__utility-inner {
    justify-content: center;
  }

  .remcb-language,
  .remcb-login,
  .remcb-user-slot #navigationUser > li > a {
    font-size: 13px;
  }
}
