/* The result belongs to the document flow: the landing page owns scrolling. */
#result-dialog {
  width: min(460px, 100vw);
  height: auto;
  position: relative;
  inset: auto;
  margin: 0 auto;
  max-width: 100vw;
  max-height: none;
  padding: max(8px, env(safe-area-inset-top)) 10px
    max(8px, env(safe-area-inset-bottom));
  overflow: visible;
}
.result-content {
  position: relative;
  height: auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.result-main {
  min-height: 0;
  flex: 0 0 auto;
  overflow: visible;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 0 3px 4px;
}
.result-main > * {
  flex-shrink: 0;
}
#result-dialog .result-brand {
  width: 180px;
  aspect-ratio: 3 / 2;
  margin: 0 auto -10px;
  background-size: contain;
  clip-path: polygon(
    4% 21%,
    10% 15%,
    28% 17%,
    40% 12%,
    45% 8%,
    49% 12%,
    57% 16%,
    69% 13%,
    86% 16%,
    96% 21%,
    99% 48%,
    95% 57%,
    95% 82%,
    92% 85%,
    8% 85%,
    5% 82%,
    5% 57%,
    1% 49%
  );
}
#result-dialog .result-brand img {
  left: 21.5%;
  top: 25%;
  width: 57%;
  height: auto;
  max-height: none;
  object-fit: contain;
}
#result-dialog .result-score {
  width: 100%;
  box-sizing: border-box;
  padding: 10px;
}
#result-dialog .result-score h2 {
  font-size: 26px;
  margin-bottom: 2px;
}
#result-dialog .result-score > strong {
  font-size: 44px;
}
#result-dialog #result-stars {
  font-size: 25px;
}
#result-dialog #round-recap {
  margin: 3px 0 0;
}
#result-dialog .throw-chip {
  font-size: 12px;
  padding: 1px 3px;
}
#result-dialog .result-offer {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 12px 14px;
}
#result-dialog .result-photo {
  width: min(100%, 220px);
  height: auto;
  aspect-ratio: 1;
  margin: 0 auto 8px;
  border-radius: 10px;
  overflow: hidden;
  background: none;
}
#result-dialog .result-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: none;
}
#result-dialog #result-product {
  font-size: 28px;
  margin-bottom: 2px;
}
#result-dialog #result-price {
  font-size: 42px;
  line-height: 1.1;
}
#result-dialog #result-dates {
  font-size: 18px;
  font-weight: 700;
}
#result-dialog .result-share {
  flex: 0 0 auto;
  box-sizing: border-box;
  width: 100%;
  padding: 10px;
}
#result-dialog .result-share h2 {
  font-size: 26px;
  margin-bottom: 3px;
}
#result-dialog .result-share > div {
  margin-top: 6px;
}
#result-dialog button {
  min-height: 44px;
}
#result-skip {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 2;
}
#result-dialog [hidden] {
  display: none;
}
body.showing-result:has(#result-dialog[open]) {
  display: block;
  height: auto;
  min-height: 100%;
  overflow: visible;
  background:
    linear-gradient(#160b0380, #160b0380),
    url("assets/chalet-vide.webp") center / cover fixed;
}
body.showing-result > main {
  display: none;
}
#share-feedback:empty {
  display: none;
}

/* Test Nico : l’encart complet est remplacé par le visuel fourni. */
#result-dialog .result-offer-image {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  overflow: hidden;
}
#result-dialog .result-offer-image::before,
#result-dialog .result-offer-image::after { content: none; }
#result-dialog .result-offer-image > img {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  margin: 0;
  object-fit: contain;
}
