/* Identité visuelle : couleurs, polices, mise en page et versions mobile. */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Playfair+Display:ital,wght@0,500;0,600;0,700;1,500;1,600&display=swap');

:root {
  --paper: #faf6ef;
  --ink: #352a31;
  --muted: #7c7377;
  --wine: #733b4a;
  --peach: #f0d8c9;
  --line: #ded6cc
}

* {
  box-sizing: border-box
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'DM Sans', sans-serif;
  font-size: 15px
}

button,
a {
  -webkit-tap-highlight-color: transparent
}

button {
  font: inherit;
  cursor: pointer
}

button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 3px solid #bd785a;
  outline-offset: 5px
}

header {
  max-width: 1280px;
  margin: auto;
  padding: 28px 55px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line)
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.15
}

.brand b {
  font-size: 23px;
  font-weight: 600
}

.brand-mark {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 30px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  width: 49px;
  height: 49px;
  display: grid;
  place-content: center;
  position: relative
}

.brand-mark span {
  font-family: serif;
  font-style: normal;
  font-size: 16px;
  position: absolute;
  right: -4px;
  top: -6px;
  background: var(--paper);
  color: var(--wine)
}

.header-note {
  font-size: 9px;
  letter-spacing: 1.8px;
  display: flex;
  gap: 22px;
  align-items: center
}

.header-note span {
  font-size: 25px;
  color: var(--wine)
}

main {
  max-width: 1170px;
  margin: auto;
  padding: 0 0
}

.screen {
  animation: appear .45s ease
}

.hidden {
  display: none !important
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding-top: 65px
}

.hero-copy {
  padding: 30px 0 50px 25px;
  z-index: 1
}

.eyebrow {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2px
}

.dot {
  display: inline-block;
  background: var(--wine);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  margin-right: 9px
}

h1,
h2,
h3 {
  font-family: 'Playfair Display', Georgia, serif;
  letter-spacing: -2.5px;
  font-weight: 500
}

h1 {
  font-size: clamp(60px, 7.4vw, 99px);
  line-height: 1.08;
  margin: 26px 0
}

em {
  color: var(--wine);
  font-weight: 500
}

h2 {
  font-size: 55px;
  line-height: 1.15;
  margin: 22px 0
}

.intro {
  font-size: 16px;
  line-height: 1.8;
  color: var(--muted);
  margin: 22px 0 30px
}

.primary {
  background: var(--wine);
  border: 1px solid var(--wine);
  color: white;
  border-radius: 6px;
  padding: 18px 24px;
  display: inline-flex;
  gap: 42px;
  align-items: center;
  justify-content: space-between;
  font-size: 14px;
  font-weight: 500;
  min-width: 245px;
  transition: background .2s, transform .2s
}

.primary:hover {
  background: #5e2e3b;
  transform: translateY(-2px)
}

.primary span {
  font-size: 22px;
  line-height: 1
}

.primary:disabled {
  background: #cfc4c6;
  border-color: #cfc4c6;
  cursor: default;
  transform: none
}

.micro {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.6;
  margin: 15px 0
}

.hero-art {
  position: relative;
  min-height: 530px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 5px
}

.halo {
  position: absolute;
  width: 370px;
  height: 410px;
  background: #f0e1d5;
  border-radius: 48% 48% 43% 43%;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%) rotate(-8deg)
}

.character {
  width: 300px;
  aspect-ratio: 3/4;
  position: relative;
  background-image: url('assets/olivier-poses.png');
  background-size: 200% 200%;
  background-repeat: no-repeat;
  z-index: 1
}

.pose-0 {
  background-position: 0 0
}

.pose-1 {
  background-position: 100% 0
}

.pose-2 {
  background-position: 0 100%
}

.pose-3 {
  background-position: 100% 100%
}

.hero-art .character {
  width: 350px
}

.hand-note {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  position: absolute;
  font-size: 17px;
  line-height: 1.5;
  top: 5px;
  left: 42px;
  transform: rotate(-7deg);
  z-index: 2
}

.hand-note span {
  font-size: 42px;
  position: absolute;
  right: -39px;
  top: 7px
}

.stamp {
  position: absolute;
  right: 10px;
  top: 210px;
  border: 1.5px solid var(--wine);
  border-radius: 50%;
  width: 98px;
  height: 98px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  font-size: 9px;
  letter-spacing: 1px;
  color: var(--wine);
  transform: rotate(14deg);
  line-height: 1.25;
  z-index: 2
}

.stamp b {
  font-family: 'Playfair Display', serif;
  font-size: 23px;
  margin: -6px 0
}

.spark {
  position: absolute;
  color: var(--wine);
  font-size: 44px
}

.s1 {
  left: 50px;
  top: 240px
}

.s2 {
  right: 50px;
  top: 90px;
  font-size: 55px
}

.name-tag {
  position: absolute;
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 9px 15px;
  font-size: 10px;
  bottom: 7px;
  z-index: 3;
  transform: rotate(-4deg);
  border-radius: 2px
}

.bottom-strip {
  grid-column: 1/-1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin: 45px 0 0;
  padding: 24px 25px;
  font-size: 9px;
  letter-spacing: 1.5px
}

.bottom-strip span:nth-child(even) {
  font-size: 23px;
  color: var(--wine)
}

footer {
  max-width: 1170px;
  margin: 0 auto;
  padding: 26px 25px;
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 10px
}

footer>span:last-child {
  font-size: 8px;
  letter-spacing: 1.5px
}

.heart {
  color: var(--wine);
  font-size: 15px;
  margin: 0 4px
}

.step-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 30px 25px
}

.text-button {
  background: none;
  border: 0;
  color: var(--muted);
  padding: 8px 0;
  font-size: 12px
}

.text-button:hover {
  color: var(--wine)
}

.rating-layout {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 45px;
  padding: 12px 25px 50px
}

.rating-layout h2 {
  font-size: 52px
}

.rating-art {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  min-height: 500px
}

.rating-art .character {
  width: 340px
}

.rating-art .halo {
  height: 350px;
  width: 340px;
  bottom: 25px
}

.speech {
  position: absolute;
  top: 12px;
  right: 5px;
  border: 1px solid var(--line);
  background: var(--paper);
  border-radius: 16px 16px 16px 0;
  padding: 15px 23px;
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 16px;
  transform: rotate(5deg);
  z-index: 2;
  max-width: 230px
}

fieldset {
  border: 0;
  margin: 30px 0 0;
  padding: 0
}

.score-grid {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 5px
}

.score-option {
  position: relative
}

.score-option input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  margin: 0;
  width: 100%;
  height: 100%
}

.score-option span {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  border: 1px solid var(--line);
  border-radius: 5px;
  font-family: 'Playfair Display', serif;
  font-size: 20px;
  transition: .2s
}

.score-option input:checked+span {
  background: var(--wine);
  color: white;
  border-color: var(--wine);
  transform: translateY(-4px)
}

.score-option input:focus-visible+span {
  outline: 3px solid #bd785a;
  outline-offset: 3px
}

.scale-labels {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--muted);
  margin-top: 10px
}

.selection {
  display: flex;
  gap: 15px;
  align-items: center;
  min-height: 85px
}

.selection strong {
  font-family: 'Playfair Display', serif;
  font-size: 35px;
  font-weight: 500;
  color: var(--wine)
}

.selection span {
  font-size: 13px;
  color: var(--muted)
}

.processing {
  text-align: center;
  padding: 25px
}

.processing .character {
  width: 200px;
  margin: auto
}

.processing h2 {
  font-size: 32px;
  letter-spacing: -1px
}

.loading {
  background: #eaded6;
  max-width: 250px;
  height: 4px;
  margin: 30px auto;
  border-radius: 3px;
  overflow: hidden
}

.loading span {
  height: 100%;
  display: block;
  background: var(--wine);
  animation: load 2.4s linear forwards
}

.result-heading {
  text-align: center;
  margin: 10px auto 30px;
  padding: 0 20px;
  max-width: 750px
}

.result-heading h2 {
  font-size: 48px;
  margin: 15px 0
}

.result-heading .intro {
  margin: 12px 0
}

.result-layout {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 65px;
  padding: 0 65px 20px;
  align-items: center
}

.ticket-wrap {
  text-align: center
}

.ticket {
  background: #fffdf8;
  border: 1px solid #d6c3ad;
  border-radius: 10px;
  padding: 25px 30px 20px;
  box-shadow: 0 12px 30px #4c30270a;
  position: relative
}

.ticket-top {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  font-size: 8px;
  letter-spacing: 1.2px;
  color: var(--muted)
}

.gift-icon {
  font-size: 52px;
  margin: 24px 0 15px;
  line-height: 1.2
}

.ticket-label {
  font-size: 9px;
  letter-spacing: 2px;
  color: var(--wine)
}

.ticket h3 {
  font-size: 37px;
  letter-spacing: -1px;
  line-height: 1.2;
  margin: 14px 0
}

.ticket #gift-description {
  font-size: 13px;
  line-height: 1.8;
  color: var(--muted);
  min-height: 48px
}

.ticket-divider {
  margin: 25px -30px 20px;
  border-top: 1px dashed #d6c3ad;
  position: relative
}

.ticket-divider:before,
.ticket-divider:after {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  background: var(--paper);
  border: 1px solid #d6c3ad;
  border-radius: 50%;
  top: -10px
}

.ticket-divider:before {
  left: -10px;
  border-left-color: transparent
}

.ticket-divider:after {
  right: -10px;
  border-right-color: transparent
}

.ticket-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: left;
  font-size: 8px;
  letter-spacing: 1px;
  line-height: 1.8
}

.ticket-bottom b {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0
}

.signature {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 28px;
  transform: rotate(-10deg);
  color: var(--wine)
}

.fine-print {
  font-size: 9px;
  color: var(--muted);
  margin: 20px 0 0;
  line-height: 1.6
}

.save-button {
  width: 100%;
  margin-top: 20px
}

.result-art {
  min-height: 460px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center
}

.result-art .character {
  width: 330px
}

.result-art .halo {
  width: 320px;
  height: 350px;
  bottom: 35px
}

.result-art .hand-note {
  top: auto;
  bottom: -5px;
  left: 70px;
  text-align: center
}

.gentle-note {
  text-align: center;
  font-size: 12px;
  color: var(--muted);
  margin: 30px 20px
}

.choices {
  padding-top: 15px;
  font-size: 12px
}

.choices>div {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 7px
}

.choice-button {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: transparent;
  font-size: 11px;
  color: var(--ink)
}

.choice-button:hover,
.choice-button[aria-pressed=true] {
  background: var(--wine);
  color: white;
  border-color: var(--wine)
}

.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
}

@keyframes appear {
  from {
    opacity: 0;
    transform: translateY(8px)
  }

  to {
    opacity: 1;
    transform: translateY(0)
  }
}

@keyframes load {
  from {
    width: 0
  }

  to {
    width: 100%
  }
}

@media(min-width:1500px) {
  .hero {
    padding-top: 85px
  }

  .hero-art {
    min-height: 570px
  }
}

@media(max-width:1000px) {
  header {
    padding: 24px 30px
  }

  main {
    padding: 0 25px
  }

  .hero-copy {
    padding-left: 0
  }

  h1 {
    font-size: 75px
  }

  .hero-art .character {
    width: 300px
  }

  .hero-art .halo {
    width: 300px;
    height: 360px
  }

  .stamp {
    right: -10px;
    top: 230px;
    width: 80px;
    height: 80px
  }

  .hand-note {
    left: 0
  }

  .s1 {
    left: 0
  }

  .hero-art {
    min-height: 510px
  }

  .bottom-strip {
    padding: 20px 0;
    letter-spacing: 1px
  }

  .rating-layout {
    padding: 10px 0 30px;
    gap: 20px
  }

  .rating-layout h2 {
    font-size: 43px
  }

  .rating-art .character {
    width: 280px
  }

  .rating-art .halo {
    width: 270px
  }

  .score-grid {
    grid-template-columns: repeat(5, 1fr);
    gap: 9px
  }

  .result-layout {
    padding: 0 10px;
    gap: 20px
  }

  .result-art .character {
    width: 280px
  }

  .result-art .halo {
    width: 260px
  }

  .result-heading h2 {
    font-size: 40px
  }
}

@media(max-width:650px) {
  header {
    padding: 20px 22px
  }

  .brand {
    gap: 10px;
    font-size: 12px
  }

  .brand b {
    font-size: 20px
  }

  .brand-mark {
    width: 43px;
    height: 43px;
    font-size: 26px
  }

  .header-note {
    font-size: 0;
    gap: 0
  }

  .header-note span {
    font-size: 26px
  }

  main {
    padding: 0 22px
  }

  .hero {
    padding-top: 36px;
    display: flex;
    flex-direction: column
  }

  .hero-copy {
    padding: 0;
  }

  .eyebrow {
    font-size: 8px;
    letter-spacing: 1.6px
  }

  h1 {
    font-size: 64px;
    margin: 22px 0 18px;
    line-height: 1.05;
    letter-spacing: -2.5px
  }

  .intro {
    font-size: 14px;
    line-height: 1.8;
    margin: 20px 0 24px
  }

  .primary {
    padding: 16px 20px;
    font-size: 13px;
    min-width: 235px
  }

  .micro {
    font-size: 10px
  }

  .hero-art {
    min-height: 340px;
    margin-top: 15px;
    padding: 0
  }

  .hero-art .character {
    width: 240px
  }

  .hero-art .halo {
    height: 260px;
    width: 260px;
    bottom: 15px
  }

  .hero-art .hand-note {
    font-size: 13px;
    left: 0;
    top: 8px;
    max-width: 140px
  }

  .hero-art .hand-note span {
    right: -25px;
    top: 0;
    font-size: 30px
  }

  .stamp {
    right: 0;
    top: 160px;
    width: 74px;
    height: 74px;
    font-size: 7px
  }

  .stamp b {
    font-size: 19px
  }

  .s1 {
    top: 140px;
    left: 10px;
    font-size: 29px
  }

  .s2 {
    top: 35px;
    right: 12px;
    font-size: 35px
  }

  .name-tag {
    bottom: 0;
    font-size: 8px;
    padding: 7px 12px
  }

  .bottom-strip {
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
    padding: 18px 0;
    margin-top: 32px;
    font-size: 7px;
    letter-spacing: 1px
  }

  .bottom-strip span:last-child {
    display: none
  }

  .bottom-strip span:nth-child(4) {
    display: none
  }

  footer {
    padding: 22px;
    gap: 15px;
    align-items: center;
    font-size: 9px
  }

  footer>span:last-child {
    font-size: 7px;
    text-align: right;
    max-width: 90px
  }

  .step-top {
    padding: 20px 0
  }

  .rating-layout {
    display: flex;
    flex-direction: column;
    padding: 0;
    gap: 0
  }

  .rating-layout h2 {
    font-size: 41px;
    letter-spacing: -1.5px;
    margin: 15px 0
  }

  .score-grid {
    grid-template-columns: repeat(5, 1fr)
  }

  .score-option span {
    height: 49px
  }

  .selection {
    min-height: 75px
  }

  .rating-layout .primary {
    width: 100%
  }

  .rating-art {
    min-height: 300px;
    align-items: flex-end
  }

  .rating-art .character {
    width: 215px
  }

  .rating-art .halo {
    height: 235px;
    width: 245px;
    bottom: 8px
  }

  .speech {
    font-size: 12px;
    padding: 10px 14px;
    top: 10px;
    right: 0;
    max-width: 170px
  }

  .processing {
    padding: 35px 0;
    min-height: 600px
  }

  .processing h2 {
    font-size: 29px
  }

  .processing .character {
    width: 220px;
    margin-bottom: 30px
  }

  .result-heading {
    margin: 15px auto 25px;
    padding: 0
  }

  .result-heading h2 {
    font-size: 37px;
    letter-spacing: -1px
  }

  .result-heading .intro {
    font-size: 13px
  }

  .result-layout {
    display: flex;
    flex-direction: column;
    padding: 0;
    gap: 0
  }

  .ticket-wrap {
    width: 100%
  }

  .ticket {
    padding: 22px
  }

  .ticket h3 {
    font-size: 33px
  }

  .ticket-divider {
    margin-left: -22px;
    margin-right: -22px
  }

  .ticket-top {
    font-size: 7px
  }

  .result-art {
    min-height: 310px;
    width: 100%;
    margin-top: 10px
  }

  .result-art .character {
    width: 215px
  }

  .result-art .halo {
    height: 240px;
    width: 245px;
    bottom: 30px
  }

  .result-art .hand-note {
    font-size: 12px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) rotate(-6deg);
    width: 200px
  }

  .gentle-note {
    font-size: 11px;
    margin: 25px 0
  }

  .gift-icon {
    margin-top: 20px
  }

  .screen {
    scroll-margin-top: 15px
  }
}

@media(prefers-reduced-motion:reduce) {

  *,
  *:before,
  *:after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important
  }

  .loading span {
    width: 100%
  }
}
