:root {
  --color-blue: #178add;
  --color-black: #000;
  --color-white: #fff;
  --focus-ring: #17324d;
  --footer-height: 86px;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  min-width: 1180px;
  min-height: 100vh;
  background: var(--color-white);
  color: var(--color-black);
  font-family: Arial, Helvetica, sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

a:focus-visible {
  outline: 3px solid var(--focus-ring);
  outline-offset: 5px;
}

img {
  display: block;
  height: auto;
  max-width: 100%;
}

.home {
  position: relative;
  min-height: calc(100vh - var(--footer-height));
  overflow: hidden;
  background: var(--color-white);
}

.home__background,
.home__background-layer {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  user-select: none;
}

.home__background-layer {
  background-image: url("https://memorias.nilsa.com/2025/home/img/fondo.jpg");
  background-position: center center;
  background-repeat: no-repeat;
  background-size: contain;
  opacity: 0;
  transition: opacity 1400ms ease-in-out;
}

.home__background-layer.is-active {
  opacity: 1;
}

.home__header {
  position: absolute;
  z-index: 2;
  top: 77px;
  left: 8.6%;
}

.home__title {
  margin: 0 0 14px;
}

.home__logo-link {
  display: inline-block;
}

.home__logo-link img {
  width: 320px;
  filter: saturate(1.05) brightness(0.86);
}

.home__languages {
  display: inline-flex;
  align-items: stretch;
}

.home__languages a {
  min-width: 107px;
  min-height: 31px;
  padding: 5px 15px 4px;
  border: 1px solid #777;
  color: #202020;
  background: rgba(255, 255, 255, 0.86);
  font-size: 18px;
  line-height: 1.1;
  text-align: center;
}

.home__languages a + a {
  margin-left: -1px;
}

.home__languages a:hover,
.home__languages a:focus-visible {
  background: #f2f2f2;
  text-decoration: none;
}

.home__archive {
  position: absolute;
  z-index: 2;
  top: 25px;
  right: 8.7%;
  display: block;
}

.home__archive img {
  width: 99px;
}

.home__video {
  position: absolute;
  z-index: 2;
  top: 58.9%;
  left: 8.8%;
  display: flex;
  align-items: center;
  gap: 15px;
}

.home__play-link {
  display: block;
  flex: 0 0 auto;
}

.home__play-link img {
  width: 54px;
  filter: saturate(1.05) brightness(0.86);
}

.home__video-title {
  display: block;
  width: max-content;
  max-width: 340px;
  color: var(--color-blue);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.05;
}

.home__video-title span {
  display: block;
}

.home__partners {
  position: absolute;
  z-index: 2;
  bottom: 31px;
  left: 8.55%;
  display: flex;
  align-items: flex-end;
  gap: 10px;
}

.home__partners a {
  display: block;
}

.home__partner-link--cpen {
  position: relative;
  margin-left: 8px;
  padding-left: 13px;
}

.home__partner-link--cpen::before {
  position: absolute;
  top: 50%;
  left: 0;
  width: 1px;
  height: 34px;
  background: #9a9a9a;
  content: "";
  transform: translateY(-50%);
}

.home__partner-logo--gob {
  width: 142px;
}

.home__partner-logo--cpen {
  width: 82px;
}

.home__partner-logo--nilsa {
  width: 112px;
}

.site-footer {
  display: flex;
  min-height: var(--footer-height);
  flex-direction: column;
  gap: 13px;
  align-items: center;
  justify-content: center;
  padding-top: 18px;
  padding-bottom: 16px;
  background: var(--color-black);
  color: var(--color-white);
  font-family: Arial, Helvetica, sans-serif;
}

.site-footer a {
  display: inline-block;
  color: inherit;
}

.site-footer img {
  width: auto;
  max-width: 100%;
}

.legalLinks {
  margin: 0; z-index:2;
  color: var(--color-black);
  font-size: 12px;
  line-height: 20px;
  text-align: center;
  position: absolute; bottom: 30px; right:8.55%;
}

.legalLinks a {
  display: inline;
  color: var(--color-black);
  transition: opacity 160ms ease;
}

.legalLinks a:hover,
.legalLinks a:focus-visible {
  opacity: 0.5;
  text-decoration: none;
}

body.is-lightbox-open {
  overflow: hidden;
}

.video-lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 52px;
  background: rgba(0, 0, 0, 0.85);
}

.video-lightbox[hidden] {
  display: none;
}

.video-lightbox__frame {
  width: min(1120px, 100%);
  background: #000;
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.48);
}

.video-lightbox__video {
  display: block;
  width: 100%;
  max-height: calc(100vh - 104px);
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-lightbox__close {
  position: fixed;
  top: 24px;
  right: 24px;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.28);
  color: var(--color-white);
  cursor: pointer;
  transition: opacity 160ms ease, background 160ms ease;
}

.video-lightbox__close:hover,
.video-lightbox__close:focus-visible {
  background: rgba(255, 255, 255, 0.14);
  opacity: 0.72;
}

.video-lightbox__close span::before,
.video-lightbox__close span::after {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 23px;
  height: 2px;
  background: currentColor;
  content: "";
  transform-origin: center;
}

.video-lightbox__close span::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.video-lightbox__close span::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

@media (max-width: 1179px) {
  body {
    min-width: 0;
  }

  .home {
    display: flex;
    min-height: auto;
    flex-direction: column;
    align-items: center;
    gap: 33px;
    padding: 42px 24px 48px;
  }

  .home__background {
    opacity: 0.18;
  }

  .home__background-layer {
    background-position: center top;
    background-size: min(1080px, 130vw) auto;
  }

  .home__header,
  .home__archive,
  .home__video,
  .home__partners {
    position: relative;
    z-index: 2;
    top: auto;
    right: auto;
    bottom: auto;
    left: auto;
  }

  .home__header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
  }

  .home__title {
    margin: 0;
  }

  .home__languages {
    justify-content: center;
  }

  .home__video {
    justify-content: center;
    margin-top: 12px;
  }

  .home__archive img {
    width: 92px;
  }

  .home__partners {
    justify-content: center;
    margin-top: 5px;
  }
  .legalLinks { bottom:10px; left:0; right:0;  margin-left:auto; margin-right:auto; 
  }
}

@media (max-width: 700px) {

  .home__partners { padding-bottom:20px; }
  .home {
    gap: 29px;
    padding: 36px 20px 44px;
  }

  .home__background {
    opacity: 0.16;
  }

  .home__background-layer {
    background-size: min(860px, 158vw) auto;
  }

  .home__logo-link img {
    width: min(320px, 82vw);
  }

  .home__languages a {
    min-width: 0;
    padding-right: 14px;
    padding-left: 14px;
    font-size: 17px;
  }

  .home__video {
    gap: 13px;
  }

  .home__play-link img {
    width: 49px;
  }

  .home__video-title {
    max-width: 270px;
    font-size: 21px;
  }

  .home__partners {
    gap: 9px;
  }

  .home__partner-logo--gob {
    width: 124px;
  }

  .home__partner-logo--cpen {
    width: 72px;
  }

  .home__partner-logo--nilsa {
    width: 98px;
  }

  .home__partner-link--cpen {
    margin-left: 4px;
    padding-left: 11px;
  }

  .site-footer {
    padding-right: 20px;
    padding-left: 20px;
  }
}

@media (max-width: 460px) {
  .home {
    gap: 26px;
    padding-right: 16px;
    padding-left: 16px;
  }

  .home__languages {
    width: 100%;
    max-width: 286px;
  }

  .home__languages a {
    flex: 1 1 0;
  }

  .home__video {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .home__video-title {
    max-width: 300px;
    font-size: 20px;
  }

  .home__partners {
    flex-wrap: wrap;
    row-gap: 14px;
  }

  .home__partner-link--cpen::before {
    height: 30px;
  }

  .legalLinks {
    max-width: 320px;
  }

  .video-lightbox {
    padding: 22px;
  }

  .video-lightbox__video {
    max-height: calc(100vh - 44px);
  }

  .video-lightbox__close {
    top: 16px;
    right: 16px;
    width: 42px;
    height: 42px;
  }
}

@media (max-width: 359px) {
  .site-footer img {
    width: 70%;
    max-width: 70%;
    margin-right: auto;
    margin-left: auto;
  }
}

@media (max-width: 299px) {
  .home {
    gap: 20px;
    padding: 28px 12px 34px;
  }

  .home__header {
    gap: 14px;
  }

  .home__logo-link img {
    width: 240px;
  }

  .home__languages {
    max-width: 246px;
  }

  .home__languages a {
    min-height: 29px;
    padding: 5px 8px 4px;
    font-size: 14px;
  }

  .home__play-link img {
    width: 42px;
  }

  .home__video-title {
    max-width: 246px;
    font-size: 18px;
  }

  .home__archive img {
    width: 76px;
  }

  .home__partners {
    gap: 7px;
    row-gap: 12px;
  }

  .home__partner-logo--gob {
    width: 108px;
  }

  .home__partner-logo--cpen {
    width: 62px;
  }

  .home__partner-logo--nilsa {
    width: 84px;
  }

  .home__partner-link--cpen {
    margin-left: 2px;
    padding-left: 9px;
  }

  .site-footer {
    gap: 10px;
    padding: 16px 12px 14px;
  }

  .site-footer img {
    max-width: 240px;
  }

  .legalLinks {
    max-width: 252px;
    font-size: 11px;
    line-height: 18px;
  }
}
@media (min-width: 360px) {
	.home__partner-logo--cpen { margin-right:40px; }
}
@media (min-width: 360px) and (max-width: 438px) {
	.home__partner-logo--gob { margin-left:40px; }
}
