/* =========================================================================
   Interface client — arrivee nocturne
   Direction : le mur de casiers d'un hotel la nuit. Fond bleu-nuit, laiton
   des porte-cles, typographie serif pour la voix de l'hotel, mono pour tout
   ce qui se compose au clavier (code, reference).
   ========================================================================= */

:root {
  --ink: #0e1116;
  --ink-soft: #161d26;
  --ink-raised: #1c2530;
  --cream: #f3efe7;
  --muted: #97a1ad;
  --brass: #c9a24b;
  --brass-dim: #8a6f33;
  --sage: #8fb08c;
  --alert: #d1705f;
  --line: rgba(243, 239, 231, 0.12);

  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: ui-sans-serif, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace;

  --radius: 14px;
  --shell: 32rem;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--ink);
  color: var(--cream);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background-image: radial-gradient(120% 70% at 50% 0%, #18212c 0%, var(--ink) 62%);
}

a { color: var(--brass); }

.shell {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding: 1.5rem 1.25rem 3rem;
  flex: 1;
}

/* --- En-tete ------------------------------------------------------------ */
.masthead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.5rem 0 1.75rem;
}

.masthead__hotel {
  font-family: var(--serif);
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--cream);
  text-decoration: none;
}

.masthead__night {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.langs { display: flex; gap: 0.35rem; }

.langs a {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--muted);
  text-decoration: none;
  padding: 0.2rem 0.35rem;
  border-radius: 4px;
}

.langs a:hover { color: var(--cream); }
.langs a[aria-current="true"] { color: var(--ink); background: var(--brass); }

/* --- Titres ------------------------------------------------------------- */
h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2rem, 8vw, 2.6rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0 0 0.85rem;
}

h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.3rem;
  margin: 0 0 0.6rem;
}

.lede { color: var(--muted); margin: 0 0 2rem; }

.eyebrow {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 0 0 0.9rem;
}

/* --- Cartes chambre : porte-cle en laiton -------------------------------- */
.rooms { display: grid; gap: 0.85rem; margin: 0 0 2rem; }

.room {
  display: block;
  position: relative;
  padding: 1.15rem 1.25rem 1.15rem 2.1rem;
  background: linear-gradient(180deg, var(--ink-raised), var(--ink-soft));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: inherit;
  text-decoration: none;
  transition: transform 0.16s ease, border-color 0.16s ease;
}

.room::before {
  content: "";
  position: absolute;
  left: 0.9rem;
  top: 1.55rem;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--sage);
  box-shadow: 0 0 0 4px rgba(143, 176, 140, 0.14);
}

.room:hover, .room:focus-visible { transform: translateY(-2px); border-color: var(--brass-dim); }

.room__head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.room__number { font-family: var(--serif); font-size: 1.5rem; }
.room__price { font-family: var(--mono); font-size: 1.1rem; color: var(--brass); white-space: nowrap; }
.room__meta { color: var(--muted); font-size: 0.86rem; margin-top: 0.2rem; }
.room__unit { font-size: 0.72rem; color: var(--muted); }

/* --- Boutons ------------------------------------------------------------ */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 58px;
  padding: 0 1.25rem;
  border: 0;
  border-radius: 12px;
  background: var(--brass);
  color: #14181e;
  font-family: var(--sans);
  font-size: 1.02rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
  transition: filter 0.15s ease;
}

.btn:hover { filter: brightness(1.07); }
.btn:active { filter: brightness(0.94); }
.btn--ghost { background: transparent; color: var(--cream); border: 1px solid var(--line); }
.btn--ghost:hover { border-color: var(--brass-dim); }

/* --- Formulaire --------------------------------------------------------- */
.field { margin-bottom: 1.15rem; }

.field label {
  display: block;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.4rem;
}

.field input, .field select {
  width: 100%;
  min-height: 54px;
  padding: 0 0.9rem;
  background: var(--ink-soft);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--cream);
  font-family: var(--sans);
  font-size: 1.02rem;
}

.field input:focus, .field select:focus {
  outline: 2px solid var(--brass);
  outline-offset: 1px;
  border-color: transparent;
}

.field__checkbox {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  min-height: 58px;
  padding: 0.6rem 0;
  color: var(--cream);
  font-size: 0.92rem;
  line-height: 1.4;
  cursor: pointer;
}
.field__checkbox input[type="checkbox"] {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  margin-top: 0.1rem;
  accent-color: var(--brass);
}
.field--error input { border-color: var(--alert); }
.field__error { color: var(--alert); font-size: 0.82rem; margin-top: 0.35rem; }
.field__hint { color: var(--muted); font-size: 0.8rem; margin-top: 0.35rem; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }

.note {
  border-left: 2px solid var(--brass-dim);
  padding: 0.15rem 0 0.15rem 0.9rem;
  color: var(--muted);
  font-size: 0.86rem;
  margin: 1.5rem 0;
}

/* --- Recapitulatif ------------------------------------------------------ */
.summary {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 1rem 1.15rem;
  background: var(--ink-soft);
  border: 1px solid var(--line);
  border-bottom: none;
  border-radius: var(--radius) var(--radius) 0 0;
}

.summary__room { font-family: var(--serif); font-size: 1.25rem; }
.summary__price { font-family: var(--mono); color: var(--brass); }

/* --- Ventilation du prix (hebergement HT / TVA / taxe de sejour) -------- */
.price-breakdown {
  margin: 0 0 1.75rem;
  padding: 0.15rem 1.15rem 0.85rem;
  background: var(--ink-soft);
  border: 1px solid var(--line);
  border-top: 1px dashed var(--line);
  border-radius: 0 0 var(--radius) var(--radius);
  font-size: 0.86rem;
}

.price-breakdown div {
  display: flex;
  justify-content: space-between;
  padding: 0.3rem 0;
}

.price-breakdown dt { color: var(--muted); margin: 0; }
.price-breakdown dd { font-family: var(--mono); margin: 0; }

.price-breakdown__total {
  border-top: 1px solid var(--line);
  margin-top: 0.2rem;
  padding-top: 0.55rem !important;
  font-weight: 600;
}
.price-breakdown__total dt,
.price-breakdown__total dd { color: var(--cream); }

/* --- Signature : la plaque a code --------------------------------------- */
.plate {
  position: relative;
  margin: 1.5rem 0 1.25rem;
  padding: 2rem 1.25rem 1.75rem;
  text-align: center;
  border-radius: 18px;
  background: linear-gradient(180deg, #232d39 0%, #151c25 100%);
  border: 1px solid var(--brass-dim);
  box-shadow: inset 0 1px 0 rgba(243, 239, 231, 0.08), 0 18px 40px -28px #000;
}

.plate__rivets {
  position: absolute;
  inset: 0.55rem;
  border: 1px dashed rgba(201, 162, 75, 0.28);
  border-radius: 13px;
  pointer-events: none;
}

.plate__label {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--brass);
}

.plate__code {
  font-family: var(--mono);
  font-size: clamp(3.4rem, 20vw, 5rem);
  font-weight: 700;
  letter-spacing: 0.16em;
  line-height: 1.05;
  margin: 0.55rem 0 0.2rem;
  text-indent: 0.16em;
  color: var(--cream);
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.45);
}

.plate__where {
  display: flex;
  justify-content: center;
  gap: 1.75rem;
  margin-top: 0.9rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--line);
}

.plate__where div { text-align: center; }
.plate__where dt { font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.plate__where dd { margin: 0.2rem 0 0; font-family: var(--serif); font-size: 1.5rem; }

.screenshot-hint { text-align: center; color: var(--muted); font-size: 0.85rem; margin: 0 0 2rem; }

/* --- Etats -------------------------------------------------------------- */
.status {
  padding: 1.1rem 1.25rem;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--ink-soft);
  margin-bottom: 1.5rem;
}

.status--wait { border-left: 3px solid var(--brass); }
.status--stop { border-left: 3px solid var(--alert); }
.status--done { border-left: 3px solid var(--sage); }
.status h2 { margin-bottom: 0.35rem; }
.status p { margin: 0; color: var(--muted); font-size: 0.92rem; }

.banner-demo {
  background: repeating-linear-gradient(135deg, #3a2d0f, #3a2d0f 12px, #302608 12px, #302608 24px);
  border: 1px solid var(--brass-dim);
  color: var(--brass);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-align: center;
  padding: 0.7rem;
  border-radius: 10px;
  margin-bottom: 1.25rem;
}

.reference {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  font-family: var(--mono);
  padding: 0.9rem 1.15rem;
  border: 1px dashed var(--line);
  border-radius: 10px;
  margin-bottom: 1.5rem;
}

.reference span:first-child { font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.reference span:last-child { font-size: 1.1rem; color: var(--cream); }

/* --- Instructions ------------------------------------------------------- */
.steps { list-style: none; margin: 0 0 2rem; padding: 0; }

.steps li {
  padding: 0.95rem 0;
  border-bottom: 1px solid var(--line);
}

.steps li:last-child { border-bottom: 0; }
.steps dt, .steps h3 { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--brass); margin: 0 0 0.3rem; font-weight: 400; }
.steps p { margin: 0; color: var(--cream); font-size: 0.94rem; }

/* --- Pied de page ------------------------------------------------------- */
.footer {
  max-width: var(--shell);
  width: 100%;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 2.5rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.82rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  justify-content: space-between;
}

.footer a { color: var(--muted); }

.emergency {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.15rem;
  border: 1px solid var(--brass-dim);
  border-radius: var(--radius);
  margin-bottom: 1.25rem;
}

.emergency span { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.emergency a { font-family: var(--mono); font-size: 1.15rem; text-decoration: none; }

/* --- Entree en scene (discrete, une seule fois) -------------------------- */
.rise { animation: rise 0.5s cubic-bezier(0.2, 0.7, 0.3, 1) both; }
.rise--2 { animation-delay: 0.07s; }
.rise--3 { animation-delay: 0.14s; }

@keyframes rise {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .rise { animation: none; }
  * { transition: none !important; }
}

:focus-visible { outline: 2px solid var(--brass); outline-offset: 2px; }
