/*
 * Navigation aquarium CDWeb.
 * Ce fichier est volontairement autonome : aucun style du thème n'est modifié.
 */

.cdw-aquarium-nav,
.cdw-aquarium-nav * {
  box-sizing: border-box;
}

.cdw-aquarium-nav {
  --cdw-sea-ink: #06324d;
  --cdw-sea-blue: #0c5d79;
  --cdw-sea-light: #bdebf2;
  --cdw-chest-wood-light: #a9cadb;
  --cdw-chest-wood-dark: #638faa;
  --cdw-chest-metal-light: #2b6c8f;
  --cdw-chest-metal-dark: #073f62;
  --cdw-chest-algae: #8da986;
  bottom: 0;
  contain: layout style;
  height: 100vh;
  height: 100dvh;
  isolation: isolate;
  left: 0;
  overflow: hidden;
  pointer-events: none;
  position: fixed;
  right: 0;
  top: 0;
  width: 100vw;
  z-index: 130;
}

.cdw-aquarium-nav--pending {
  opacity: 0;
}

/* Le décor historique de l'accueil est repris sans ses poissons statiques. */
body.path-frontpage {
  background-color: #ffffff !important;
  background-image: url('../images/aquarium-background.svg') !important;
  background-position: bottom center !important;
  background-repeat: no-repeat !important;
  background-size: 100% auto !important;
}

/* Le texte d'accueil retrouve le bleu de marque sur le fond blanc. */
.path-frontpage .bg-home h2 {
  color: #073453;
  text-shadow: 0 2px 12px rgba(99, 162, 184, 0.12);
}

/* Le thème masque le titre de page avec display:none. Cette variante le garde
 * dans la structure sémantique et dans l'arbre d'accessibilité sans dupliquer
 * visuellement le slogan présent dans le décor. */
body.path-frontpage #block-cdweb-page-title {
  border: 0 !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  display: block !important;
  height: 1px !important;
  margin: -1px !important;
  overflow: hidden !important;
  padding: 0 !important;
  position: absolute !important;
  white-space: nowrap !important;
  width: 1px !important;
}

/* Le lourd hublot gris du contenu Drupal est masqué, mais son balisage et le
 * logo qu'il contient sont conservés. */
.path-frontpage .center-home-logo {
  animation: cdw-porthole-float 6.5s ease-in-out infinite;
  aspect-ratio: 1;
  height: auto;
  isolation: isolate;
  left: 50vw;
  pointer-events: none;
  position: fixed;
  top: 42vh;
  transform: translate(-50%, -65%);
  width: clamp(220px, 21vw, 330px);
  z-index: 120;
}

.path-frontpage .center-home-logo::before {
  animation: cdw-porthole-halo 4.8s ease-in-out infinite;
  border: 2px solid rgba(221, 247, 250, 0.38);
  border-radius: 50%;
  box-shadow: 0 0 25px rgba(197, 237, 243, 0.34), inset 0 0 18px rgba(231, 250, 252, 0.18);
  content: '';
  inset: 8%;
  pointer-events: none;
  position: absolute;
  z-index: 0;
}

.path-frontpage .center-home-logo::after {
  background: radial-gradient(ellipse, rgba(5, 42, 63, 0.3) 0 35%, rgba(5, 42, 63, 0) 72%);
  bottom: -1%;
  content: '';
  height: 16%;
  left: 14%;
  pointer-events: none;
  position: absolute;
  width: 72%;
  z-index: 0;
}

.path-frontpage .center-home-logo-back {
  background: url('../images/cdw-porthole.svg') no-repeat center / contain;
  inset: 0;
  position: absolute;
  z-index: 1;
}

.path-frontpage .center-home-logo-back > i {
  display: none;
}

.path-frontpage .center-home-logo-front,
.path-frontpage .center-home-logo:hover .center-home-logo-front {
  align-items: center;
  background: transparent !important;
  border-radius: 50%;
  display: flex;
  height: 44%;
  justify-content: center;
  left: 17%;
  position: absolute;
  top: 28%;
  transform: none;
  transition: none;
  width: 66%;
  z-index: 2;
}

.path-frontpage .center-home-logo-front > i {
  display: block;
  filter: drop-shadow(0 4px 3px rgba(3, 31, 47, 0.42));
  line-height: 0;
  width: 92%;
}

.path-frontpage .center-home-logo-front svg {
  display: block;
  height: auto;
  max-height: 100%;
  width: 100%;
}

/* Zone interactive indépendante du contenu historique. Elle reprend
 * exactement la position et le mouvement du hublot afin que toute sa surface
 * reste cliquable, sans empêcher les coffres situés au-dessus de l'être. */
.cdw-porthole-link {
  animation: cdw-porthole-float 6.5s ease-in-out infinite;
  aspect-ratio: 1;
  border-radius: 50%;
  cursor: pointer;
  height: auto;
  isolation: isolate;
  left: 50vw;
  perspective: 900px;
  pointer-events: auto;
  position: fixed;
  top: 42vh;
  transform: translate(-50%, -65%);
  transform-style: preserve-3d;
  width: clamp(220px, 21vw, 330px);
  z-index: 121;
}

.cdw-porthole-link__glow {
  background: radial-gradient(circle, rgba(190, 235, 242, 0.3) 0 20%, rgba(86, 160, 184, 0.2) 40%, rgba(7, 52, 83, 0) 72%);
  border-radius: 50%;
  inset: 17%;
  opacity: 0;
  pointer-events: none;
  position: absolute;
  transform: scale(0.72);
  transition: opacity 0.38s ease, transform 0.55s cubic-bezier(0.2, 0.86, 0.26, 1.08);
  z-index: 0;
}

.cdw-porthole-link__door {
  background: url('../images/cdw-porthole-door.svg') no-repeat center / contain;
  filter: drop-shadow(-5px 8px 6px rgba(3, 31, 48, 0.38));
  inset: 14%;
  pointer-events: none;
  position: absolute;
  transform: rotateY(0deg) translateZ(2px);
  transform-origin: 98% 50%;
  transform-style: preserve-3d;
  transition: filter 0.38s ease, transform 0.68s cubic-bezier(0.18, 0.82, 0.2, 1.04);
  will-change: transform;
  z-index: 1;
}

.cdw-porthole-link__label {
  border: 0;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

.cdw-porthole-link:hover .cdw-porthole-link__door,
.cdw-porthole-link:focus .cdw-porthole-link__door,
.cdw-porthole-link:focus-visible .cdw-porthole-link__door {
  filter: drop-shadow(-16px 12px 10px rgba(3, 31, 48, 0.5));
  transform: rotateY(-104deg) translateZ(6px);
}

.cdw-porthole-link:hover .cdw-porthole-link__glow,
.cdw-porthole-link:focus .cdw-porthole-link__glow,
.cdw-porthole-link:focus-visible .cdw-porthole-link__glow {
  opacity: 0.56;
  transform: scale(1.1);
}

.cdw-porthole-link:focus-visible {
  outline: 4px solid #ffd257;
  outline-offset: 5px;
}

@keyframes cdw-porthole-float {
  0%, 100% { transform: translate(-50%, -65%) translateY(0) rotate(-0.5deg); }
  50% { transform: translate(-50%, -65%) translateY(-8px) rotate(0.5deg); }
}

@keyframes cdw-porthole-halo {
  0%, 100% { opacity: 0.46; transform: scale(0.98); }
  50% { opacity: 0.8; transform: scale(1.025); }
}

/* Les trois anciens poissons de la page restent dans le contenu Drupal, mais
 * sont remplacés visuellement par les poissons articulés du module. */
.path-frontpage .bg-home > .poisson.poisson-1,
.path-frontpage .bg-home > .poisson.poisson-2,
.path-frontpage .bg-home > .poisson.poisson-3 {
  display: none !important;
}

.cdw-aquarium-nav__stage,
.cdw-aquarium-nav__rocks,
.cdw-aquarium-nav__fish-layer {
  height: 100%;
  inset: 0;
  pointer-events: none;
  position: absolute;
  width: 100%;
}

.cdw-aquarium-nav__fish-layer {
  overflow: hidden;
  z-index: 0;
}

.cdw-fish {
  filter: drop-shadow(0 5px 4px rgba(4, 41, 61, 0.2));
  left: 0;
  opacity: 0.78;
  position: absolute;
  top: 0;
  transform-origin: 50% 50%;
  will-change: transform;
}

.cdw-fish svg {
  display: block;
  height: auto;
  overflow: visible;
  width: 100%;
}

.cdw-fish--reef { width: clamp(104px, 8.4vw, 150px); }
.cdw-fish--needle { width: clamp(132px, 11.2vw, 196px); opacity: 0.68; }
.cdw-fish--stripe { width: clamp(82px, 6.3vw, 112px); opacity: 0.83; }
.cdw-fish--angel { width: clamp(90px, 7vw, 124px); }
.cdw-fish--puffer { width: clamp(94px, 7.4vw, 132px); opacity: 0.74; }
.cdw-fish--sail { width: clamp(125px, 10vw, 175px); opacity: 0.72; }

.cdw-fish__tail {
  animation: cdw-fish-tail 0.56s ease-in-out infinite alternate;
  transform-box: fill-box;
  transform-origin: 100% 50%;
}

.cdw-fish__fin {
  animation: cdw-fish-fin 0.92s ease-in-out infinite alternate;
  transform-box: fill-box;
  transform-origin: 82% 18%;
}

.cdw-fish__body {
  animation: cdw-fish-breathe 1.8s ease-in-out infinite alternate;
  transform-box: fill-box;
  transform-origin: 50% 50%;
}

.cdw-fish--needle .cdw-fish__tail,
.cdw-fish--sail .cdw-fish__tail { animation-duration: 0.44s; }
.cdw-fish--angel .cdw-fish__tail { animation-duration: 0.7s; }
.cdw-fish--puffer .cdw-fish__tail { animation-duration: 0.82s; }
.cdw-fish--stripe .cdw-fish__fin { animation-delay: -0.42s; }
.cdw-fish--sail .cdw-fish__fin { animation-delay: -0.27s; }

@keyframes cdw-fish-tail {
  from { transform: rotate(-8deg) skewY(-3deg); }
  to { transform: rotate(10deg) skewY(4deg); }
}

@keyframes cdw-fish-fin {
  from { transform: rotate(-5deg) scaleY(0.9); }
  to { transform: rotate(9deg) scaleY(1.08); }
}

@keyframes cdw-fish-breathe {
  from { transform: scaleY(0.985); }
  to { transform: scaleY(1.015); }
}

.cdw-fish-bubble {
  animation: cdw-fish-bubble-rise var(--cdw-bubble-duration, 5s) ease-in both;
  border: 2px solid rgba(224, 249, 255, 0.88);
  border-radius: 50%;
  box-shadow: inset 2px 2px 0 rgba(255, 255, 255, 0.5), 0 0 7px rgba(188, 235, 244, 0.42);
  height: var(--cdw-bubble-size, 9px);
  left: 0;
  opacity: 0;
  pointer-events: none;
  position: absolute;
  top: 0;
  width: var(--cdw-bubble-size, 9px);
  z-index: 1;
}

@keyframes cdw-fish-bubble-rise {
  0% {
    opacity: 0;
    transform: translate3d(-50%, -50%, 0) scale(0.42);
  }
  9% { opacity: 0.86; }
  76% { opacity: 0.72; }
  100% {
    opacity: 0;
    transform: translate3d(var(--cdw-bubble-drift, 16px), var(--cdw-bubble-rise, -400px), 0) scale(1.28);
  }
}

.cdw-aquarium-nav__rocks {
  z-index: 1;
}

.cdw-aquarium-nav__rock {
  left: 0;
  position: absolute;
  top: 0;
  transform-origin: 50% 50%;
  will-change: transform;
}

.cdw-aquarium-nav__rock svg {
  display: block;
  filter: drop-shadow(0 7px 5px rgba(0, 26, 42, 0.28));
  height: 100%;
  overflow: visible;
  width: 100%;
}

.cdw-aquarium-nav__treasures {
  align-items: flex-end;
  bottom: max(0.75rem, env(safe-area-inset-bottom));
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: center;
  left: 0;
  list-style: none;
  margin: 0;
  padding: 0 0.75rem;
  pointer-events: none;
  position: absolute;
  right: 0;
  z-index: 2;
}

.cdw-aquarium-nav__item {
  display: block;
  list-style: none;
  margin: 0;
  padding: 0;
}

.cdw-aquarium-nav.is-physics-ready .cdw-aquarium-nav__treasures {
  bottom: auto;
  display: block;
  inset: 0;
  padding: 0;
}

.cdw-aquarium-nav.is-physics-ready .cdw-aquarium-nav__item {
  height: 0;
  position: static;
  width: 0;
}

.cdw-treasure {
  --cdw-chest-width: 172px;
  --cdw-chest-height: 107px;
  color: #fff9dc;
  cursor: pointer;
  display: block;
  font-family: 'Architects Daughter', cursive;
  height: var(--cdw-chest-height);
  isolation: isolate;
  pointer-events: auto;
  position: relative;
  text-decoration: none;
  touch-action: manipulation;
  width: var(--cdw-chest-width);
}

.cdw-aquarium-nav.is-physics-ready .cdw-treasure {
  left: 0;
  opacity: 0;
  position: absolute;
  top: 0;
  transform-origin: 50% var(--cdw-body-center, 62%);
  transition: opacity 0.24s ease;
  will-change: transform;
}

.cdw-aquarium-nav.is-physics-ready .cdw-treasure[data-cdw-spawned='true'] {
  opacity: 1;
}

.cdw-treasure--variant-1 {
  --cdw-chest-wood-light: #9fc5d7;
  --cdw-chest-wood-dark: #557f9b;
  --cdw-chest-algae: #799d86;
}

.cdw-treasure--variant-2 {
  --cdw-chest-wood-light: #b2ceda;
  --cdw-chest-wood-dark: #7195aa;
  --cdw-chest-metal-light: #255f83;
  --cdw-chest-algae: #96aa78;
}

.cdw-treasure__art {
  display: block;
  height: 100%;
  inset: 0;
  overflow: visible;
  position: absolute;
  width: 100%;
  z-index: 2;
}

.cdw-treasure__ground-shadow {
  fill: rgba(7, 52, 83, 0.22);
}

.cdw-treasure__lid {
  transform: translateY(-16px) rotate(-2.5deg);
  transform-box: fill-box;
  transform-origin: 50% 100%;
  transition: transform 0.36s cubic-bezier(0.2, 0.86, 0.26, 1.18);
}

.cdw-treasure__lid-wood,
.cdw-treasure__base-wood,
.cdw-treasure__rim,
.cdw-treasure__metal,
.cdw-treasure__lock {
  stroke: #073f62;
  stroke-linejoin: round;
  stroke-width: 3;
}

.cdw-treasure__rim,
.cdw-treasure__metal,
.cdw-treasure__lock {
  stroke: #073453;
  stroke-width: 2.4;
}

.cdw-treasure__lock {
  fill: #b7d5df;
}

.cdw-treasure__foot {
  fill: #28556d;
}

.cdw-treasure__wood-line {
  fill: none;
  opacity: 0.5;
  stroke: #376b87;
  stroke-linecap: round;
  stroke-width: 3;
}

.cdw-treasure__opening {
  fill: #082c43;
  stroke: #80aec5;
  stroke-width: 2;
  transition: fill 0.25s ease, filter 0.25s ease;
}

.cdw-treasure__rivet {
  fill: #a9d1df;
  stroke: #073f62;
  stroke-width: 1.2;
}

.cdw-treasure__keyhole {
  fill: #073453;
}

.cdw-treasure__algae {
  fill: none;
  opacity: 0.9;
  stroke: var(--cdw-chest-algae);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 6;
}

.cdw-treasure__algae--lid {
  opacity: 0.72;
  stroke-width: 5;
}

.cdw-treasure__barnacles path {
  fill: #eef5f3;
  stroke: #6e96a9;
  stroke-linejoin: round;
  stroke-width: 1.5;
}

.cdw-treasure__barnacles circle {
  fill: #e6ae43;
  stroke: #073f62;
  stroke-width: 1.3;
}

.cdw-treasure__visible-label {
  clip-path: inset(0 -16% 38% -16%);
  color: #ffd257;
  font-size: var(--cdw-label-size, 1.42rem);
  font-weight: 700;
  left: 50%;
  letter-spacing: 0.01em;
  line-height: 1;
  max-width: none;
  overflow: visible;
  position: absolute;
  text-align: center;
  text-shadow:
    -1px -1px 0 #073453,
    0 -1px 0 #073453,
    1px -1px 0 #073453,
    -1px 0 0 #073453,
    1px 0 0 #073453,
    -1px 1px 0 #073453,
    0 1px 0 #073453,
    1px 1px 0 #073453;
  top: 38%;
  transform: translate(-50%, 0);
  transition: clip-path 0.22s ease, color 0.22s ease, transform 0.36s cubic-bezier(0.2, 0.86, 0.26, 1.18);
  white-space: nowrap;
  z-index: 6;
}

.cdw-aquarium-nav.is-physics-ready .cdw-treasure:hover,
.cdw-aquarium-nav.is-physics-ready .cdw-treasure:focus,
.cdw-aquarium-nav.is-physics-ready .cdw-treasure:focus-visible {
  z-index: 999 !important;
}

.cdw-treasure:hover .cdw-treasure__lid,
.cdw-treasure:focus .cdw-treasure__lid,
.cdw-treasure:focus-visible .cdw-treasure__lid {
  transform: translateY(-27px) rotate(-6deg) scaleY(0.93);
}

.cdw-treasure:hover .cdw-treasure__opening,
.cdw-treasure:focus .cdw-treasure__opening,
.cdw-treasure:focus-visible .cdw-treasure__opening {
  fill: #061e30;
  filter: drop-shadow(0 -4px 7px rgba(189, 235, 242, 0.78));
}

.cdw-treasure:hover .cdw-treasure__visible-label,
.cdw-treasure:focus .cdw-treasure__visible-label,
.cdw-treasure:focus-visible .cdw-treasure__visible-label {
  clip-path: inset(-35% -14% -25% -14%);
  color: #ffd257;
  text-shadow:
    -1px -1px 0 #073453,
    0 -1px 0 #073453,
    1px -1px 0 #073453,
    -1px 0 0 #073453,
    1px 0 0 #073453,
    -1px 1px 0 #073453,
    0 1px 0 #073453,
    1px 1px 0 #073453;
  transform: translate(-50%, -182%) scale(1.28);
}

.cdw-treasure:focus-visible {
  outline: 4px solid #fff0a5;
  outline-offset: 6px;
}

.cdw-treasure__bubbles {
  height: 70%;
  left: 50%;
  pointer-events: none;
  position: absolute;
  top: -42%;
  transform: translateX(-50%);
  width: 68%;
  z-index: 5;
}

.cdw-treasure__bubbles i {
  animation: none;
  border: 2px solid rgba(219, 250, 255, 0.88);
  border-radius: 50%;
  bottom: 0;
  height: 10px;
  left: 24%;
  opacity: 0;
  position: absolute;
  width: 10px;
}

.cdw-treasure__bubbles i:nth-child(2) {
  height: 7px;
  left: 51%;
  width: 7px;
}

.cdw-treasure__bubbles i:nth-child(3) {
  height: 13px;
  left: 74%;
  width: 13px;
}

.cdw-treasure:hover .cdw-treasure__bubbles i,
.cdw-treasure:focus-visible .cdw-treasure__bubbles i {
  animation: cdw-treasure-bubble 1.65s ease-out infinite;
}

.cdw-treasure:hover .cdw-treasure__bubbles i:nth-child(2),
.cdw-treasure:focus-visible .cdw-treasure__bubbles i:nth-child(2) {
  animation-delay: 0.36s;
}

.cdw-treasure:hover .cdw-treasure__bubbles i:nth-child(3),
.cdw-treasure:focus-visible .cdw-treasure__bubbles i:nth-child(3) {
  animation-delay: 0.72s;
}

@keyframes cdw-treasure-bubble {
  0% {
    opacity: 0;
    transform: translate3d(0, 12px, 0) scale(0.55);
  }
  18% { opacity: 0.92; }
  100% {
    opacity: 0;
    transform: translate3d(9px, -54px, 0) scale(1.08);
  }
}

.cdw-aquarium-nav__landing-puff {
  height: 36px;
  pointer-events: none;
  position: absolute;
  transform: translate(-50%, -50%) scale(var(--cdw-puff-scale, 1));
  width: 90px;
  z-index: 24;
}

.cdw-aquarium-nav__landing-puff i {
  animation: cdw-landing-puff 1.05s ease-out var(--cdw-puff-delay, 0s) both;
  background: rgba(245, 226, 171, 0.72);
  border-radius: 50%;
  bottom: 0;
  box-shadow: 0 0 9px rgba(222, 246, 246, 0.5);
  height: 12px;
  left: 50%;
  position: absolute;
  width: 12px;
}

@keyframes cdw-landing-puff {
  0% {
    opacity: 0;
    transform: translate3d(0, 4px, 0) scale(0.35);
  }
  20% { opacity: 0.8; }
  100% {
    opacity: 0;
    transform: translate3d(var(--cdw-puff-x, 0), -27px, 0) scale(1.65);
  }
}

.cdw-aquarium-nav__sr-only {
  border: 0;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

.cdw-aquarium-nav__noscript {
  background: rgba(7, 52, 83, 0.92);
  bottom: 0;
  left: 0;
  padding: 0.75rem;
  position: fixed;
  right: 0;
  z-index: 190;
}

.cdw-aquarium-nav__noscript ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  list-style: none;
  margin: 0;
  padding: 0;
}

.cdw-aquarium-nav__noscript a {
  background: #ffd257;
  border-radius: 999px;
  color: #073453;
  display: block;
  font-weight: 700;
  padding: 0.55rem 0.85rem;
  text-decoration: none;
}

/* Mode sans animation : le menu reste utilisable si JavaScript est coupé. */
.cdw-aquarium-nav.is-reduced-motion .cdw-aquarium-nav__treasures,
.cdw-aquarium-nav.is-static-fallback .cdw-aquarium-nav__treasures {
  align-content: flex-end;
  max-height: 62vh;
  overflow: auto;
  pointer-events: auto;
  scrollbar-width: thin;
}

.cdw-aquarium-nav.is-reduced-motion .cdw-treasure,
.cdw-aquarium-nav.is-static-fallback .cdw-treasure {
  opacity: 1;
}

@media (max-width: 700px) {
  body.path-frontpage {
    background-image: url('../images/aquarium-background.svg') !important;
    background-position: bottom center !important;
    background-size: 160% auto !important;
  }

  .path-frontpage .center-home-logo {
    top: 41vh;
    width: clamp(176px, 49vw, 205px);
    z-index: 120;
  }

  .cdw-porthole-link {
    top: 41vh;
    width: clamp(176px, 49vw, 205px);
  }

  .cdw-aquarium-nav {
    z-index: 185;
  }

  /* Poulpyx reste pleinement cliquable, mais occupe moins de place devant le
   * dernier couloir de coffres. Le panneau de discussion, positionné en fixed
   * par son propre module, conserve ses dimensions normales. */
  body.path-frontpage .poulpyx-chat.poulpyx-chat--launcher-mascot {
    bottom: 6px;
    height: 96px;
    right: 6px;
    width: 92px;
  }

  body.path-frontpage .poulpyx-chat--launcher-mascot .poulpyx-chat__launcher,
  body.path-frontpage .poulpyx-chat--launcher-mascot .poulpyx-mascot {
    height: 96px;
    width: 92px;
  }

  body.path-frontpage .poulpyx-chat--launcher-mascot .poulpyx-chat__notification {
    right: 5px;
    top: 14px;
  }

  .cdw-aquarium-nav__treasures {
    bottom: max(0.35rem, env(safe-area-inset-bottom));
    gap: 0.1rem;
    padding-inline: 0.25rem;
  }

  .cdw-fish--reef { width: 96px; }
  .cdw-fish--needle { width: 124px; }
  .cdw-fish--stripe { width: 76px; }
  .cdw-fish--angel { width: 80px; }
  .cdw-fish--puffer { width: 86px; }
  .cdw-fish--sail { width: 116px; }

  .cdw-treasure {
    --cdw-chest-width: 110px;
    --cdw-chest-height: 68px;
  }

  /* Un couvercle plus relevé rend immédiatement la fonction du coffre
   * compréhensible, même avant le premier toucher. */
  .cdw-treasure__lid {
    transform: translateY(-17px) rotate(-3deg);
  }

  .cdw-treasure__visible-label {
    clip-path: inset(0 -14% 24% -14%);
    font-size: var(--cdw-label-size, 1rem);
    top: 32%;
  }

  .cdw-treasure:hover .cdw-treasure__lid,
  .cdw-treasure:focus .cdw-treasure__lid,
  .cdw-treasure:focus-visible .cdw-treasure__lid {
    transform: translateY(-29px) rotate(-6deg) scaleY(0.93);
  }

  .cdw-treasure:hover .cdw-treasure__visible-label,
  .cdw-treasure:focus .cdw-treasure__visible-label,
  .cdw-treasure:focus-visible .cdw-treasure__visible-label {
    clip-path: inset(-35% -14% -25% -14%);
    transform: translate(-50%, -166%) scale(1.2);
  }
}

@media (max-height: 650px) {
  .path-frontpage .center-home-logo {
    top: 39vh;
    width: 168px;
  }


  .cdw-porthole-link {
    top: 39vh;
    width: 168px;
  }
}

@media (hover: none) and (pointer: coarse) {
  .cdw-treasure__visible-label {
    clip-path: inset(0 -14% 20% -14%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .path-frontpage .center-home-logo,
  .path-frontpage .center-home-logo::before,
  .cdw-porthole-link {
    animation: none !important;
  }

  .path-frontpage .center-home-logo,
  .cdw-porthole-link {
    transform: translate(-50%, -65%);
  }

  .cdw-porthole-link__door,
  .cdw-porthole-link__glow {
    transition-duration: 0.01ms !important;
  }

  .cdw-treasure,
  .cdw-treasure__lid,
  .cdw-treasure__opening,
  .cdw-treasure__visible-label {
    scroll-behavior: auto;
    transition-duration: 0.01ms !important;
  }

  .cdw-treasure__bubbles i {
    animation: none !important;
  }

  .cdw-aquarium-nav__landing-puff {
    display: none;
  }

  .cdw-fish__tail,
  .cdw-fish__fin,
  .cdw-fish__body,
  .cdw-fish-bubble {
    animation: none !important;
  }
}
