/* =========================================================================================================== */
/* BODY */
body.open-menu {
  overflow: hidden;
}

/* =========================================================================================================== */
/* LOGO */
.logo,
.logo:visited,
.logo:focus,
.logo:hover {
  width: auto;
  height: 50px;
  aspect-ratio: 1 / 0.6;
  display: block;
  background: url(../media/logo/logo.png) no-repeat 50% 50%;
  background-size: contain;
  transition: all var(--default-transition-duration)
    var(--default-transition-timing-function);
}
.bg-blu .logo,
.bg-blu .logo:visited,
.bg-blu .logo:focus,
.bg-blu .logo:hover {
  background: url(../media/logo/logo-bianco.png) no-repeat 50% 50%;
  background-size: contain;
}
body.open-menu .logo,
body.open-menu .logo:visited,
body.open-menu .logo:focus,
body.open-menu .logo:hover {
  background: url(../media/logo/logo.png) no-repeat 50% 50%;
  background-size: contain;
}
@media (width >= 1024px) {
  .logo,
  .logo:visited,
  .logo:focus,
  .logo:hover {
    height: 72px;
  }
}
.scrolled header .logo {
  height: 50px;
}

/* =========================================================================================================== */
/* CREDITS */
.credits,
.credits:visited,
.credits:focus,
.credits:hover {
  display: inline-flex;
  width: 86px;
  height: 12px;
  border: none !important;
  -webkit-mask: url(../media/logo/logo-hellobarrio.svg) no-repeat 50% 50%;
  mask: url(../media/logo/logo-hellobarrio.svg) no-repeat 50% 50%;
  -webkit-mask-size: contain;
  mask-size: contain;
  background-color: black;
  transition: all var(--default-transition-duration)
    var(--default-transition-timing-function);
}
.credits:hover {
  opacity: 0.5;
}

/* =========================================================================================================== */
/* CONT TESTO */
.cont-testo > * {
  font-size: var(--text-body);
  line-height: 1.5;
  font-weight: var(--text-body--font-weight);
}
.cont-testo > h1,
.cont-testo > h2 {
  font-size: var(--text-titolo2);
  line-height: var(--text-titolo2--line-height);
  font-weight: 700;
  color: var(--color-blu);
  text-transform: uppercase;
}
.single .cont-testo > h1,
.single .cont-testo > h2 {
  font-size: var(--text-titolo3);
  line-height: var(--text-titolo3--line-height);
}
.cont-testo > h3 {
  font-size: var(--text-titolo3);
  line-height: var(--text-titolo3--line-height);
  font-weight: 700;
  color: var(--color-blu);
}
.cont-testo > h4 {
  font-size: var(--text-titolo4);
  line-height: var(--text-titolo4--line-height);
  font-weight: var(--text-titolo4--font-weight);
  color: var(--color-blu);
}
.cont-testo > h5,
.cont-testo > h6 {
  font-size: var(--text-titolo5);
  line-height: var(--text-titolo5--line-height);
  font-weight: var(--text-titolo5--font-weight);
  color: var(--color-blu);
}

.cont-testo > p > a:not([class]) {
  text-decoration: underline;
  color: var(--color-azzurro);
}
.cont-testo > p > a:not([class]):hover {
  color: var(--color-blu);
}

.cont-testo > .wp-block-image figcaption {
  display: block;
  padding: calc(var(--spacing) * 3) 0;
  margin: 0;
  border-bottom: 1px solid black;
  font-size: var(--text-menu);
  line-height: var(--text-menu--line-height);
  font-weight: var(--text-menu--font-weight);
  color: black;
}

.wp-block-separator {
  border-top: 1px solid var(--color-grigio);
}

.cont-testo > * + * {
  margin-top: calc(var(--spacing) * 4);
}
.cont-testo > * + h1,
.cont-testo > * + h2,
.cont-testo > * + h3,
.cont-testo > * + h4,
.cont-testo > * + h5,
.cont-testo > * + h6 {
  margin-top: calc(var(--spacing) * 8);
}
.cont-testo > * + hr,
.cont-testo > hr + * {
  margin-top: calc(var(--spacing) * 3);
}
.cont-testo > hr + h1,
.cont-testo > hr + h2,
.cont-testo > hr + h3 {
  margin-top: calc(var(--spacing) * 6);
}
.cont-testo > * + .wp-block-image,
.cont-testo > .wp-block-image + * {
  margin-top: calc(var(--spacing) * 6);
}
@media (width >= 1024px) {
  .cont-testo > * + * {
    margin-top: calc(var(--spacing) * 6);
  }
  .cont-testo > * + h1,
  .cont-testo > * + h2,
  .cont-testo > * + h3,
  .cont-testo > * + h4,
  .cont-testo > * + h5,
  .cont-testo > * + h6 {
    margin-top: calc(var(--spacing) * 12);
  }
  .cont-testo > * + hr,
  .cont-testo > hr + * {
    margin-top: calc(var(--spacing) * 4);
  }
  .cont-testo > hr + h1,
  .cont-testo > hr + h2,
  .cont-testo > hr + h3 {
    margin-top: calc(var(--spacing) * 8);
  }
  .cont-testo > * + .wp-block-image,
  .cont-testo > .wp-block-image + * {
    margin-top: calc(var(--spacing) * 8);
  }
}

/* =========================================================================================================== */
/* CUSTOM SELECT */
.custom-select {
  background: url(/wp-content/themes/barriotheme/media/icons/arrow-down.svg)
    no-repeat calc(100% - 30px) 50%;
  background-size: 20px;
}

/* =========================================================================================================== */
/* IFRAME */
iframe {
  width: 100%;
  height: auto;
  aspect-ratio: 16/9;
}

/* =========================================================================================================== */
/* HAMBURGER */
.btn-hamburger {
  width: 30px;
  height: 20px;
  position: relative;
  cursor: pointer;
}
.btn-hamburger .line {
  width: 100%;
  height: 1px;
  background-color: var(--color-blu);
  position: absolute;
  left: 0;
  transition: all var(--default-transition-duration)
    var(--default-transition-timing-function);
}
.bg-blu .btn-hamburger .line {
  background-color: white;
}
body.open-menu .btn-hamburger .line {
  background-color: var(--color-blu);
}

.btn-hamburger .line.top {
  top: 0;
  transform: translateY(0);
}
.btn-hamburger .line.center {
  top: 50%;
  transform: translateY(-50%);
  transform-origin: center center;
}
.btn-hamburger .line.bottom {
  bottom: 0;
  transform: translateY(0);
}
body.open-menu .btn-hamburger .line.top {
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) rotate(45deg);
}
body.open-menu .btn-hamburger .line.center {
  opacity: 0;
}
body.open-menu .btn-hamburger .line.bottom {
  left: 50%;
  bottom: 50%;
  transform: translate(-50%, 50%) rotate(-45deg);
}

/* =========================================================================================================== */
/* OVERLAY */
header {
  transition-delay: 300ms;
}
body.open-menu header {
  background: var(--color-blu-chiaro);
}
.overlay {
  transition-delay: 300ms;
  clip-path: inset(0 0 100% 0);
  pointer-events: none;
}
body.open-menu .overlay {
  clip-path: inset(0 0 0 0);
  pointer-events: all;
}
.overlay-content {
  opacity: 0;
  pointer-events: none;
}
body.open-menu .overlay-content {
  transition-delay: 500ms;
  opacity: 1;
  pointer-events: all;
}

/* COMING SOON */
.page-template-page-coming-soon header,
.page-template-page-coming-soon footer {
  display: none !important;
}

.page-template-page-home header .linguise_switcher a > span {
  color: black !important;
}

/* ACCESSIBILITÀ */
.wp-theme-barriotheme
  .floatable-wrapper.iub-floatable-wrapper-aw-2025:not(
    .iub-floatable-wrapper-2025
  )[data-tp-float="bottom-left"] {
  left: 0 !important;
  bottom: 0 !important;
  margin: 16px !important;
}
.wp-theme-barriotheme
  .floatable-wrapper.iub-floatable-wrapper-aw-2025:not(
    .iub-floatable-wrapper-2025
  )[data-tp-float="bottom-left"]
  button {
  display: grid !important;
  place-items: center !important;
}
.wp-theme-barriotheme
  .floatable-wrapper.iub-floatable-wrapper-aw-2025:not(
    .iub-floatable-wrapper-2025
  )[data-tp-float="bottom-left"]
  button
  svg {
  width: auto !important;
  margin: 0 auto !important;
  height: 24px !important;
}

.page-template-page-coming-soon .floatable-wrapper {
  display: none !important;
}

/* MODAL POPUP */
#modal-popup {
  opacity: 0;
  pointer-events: none;
  transition-delay: 300ms;
}
body.popup-opened #modal-popup {
  opacity: 1;
  pointer-events: all;
  transition-delay: 0ms;
}
