/* =========================================================
   Effets interactifs : « La photo faite de code » + « Votre site en 10 secondes »
   Couleurs via les jetons du site : fonctionnent en thème clair et sombre.
   ========================================================= */

/* ---------- Photo × Code (section Photographie, fond clair/sombre selon le thème) ---------- */
.pxc {
  display: grid; grid-template-columns: 1fr 1.1fr; gap: var(--s8); align-items: center;
  margin-top: var(--s12); padding-top: var(--s12); border-top: 1px solid var(--border);
}
.pxc__text { max-width: 30rem; }
.pxc__text .h-display { margin-bottom: var(--s3); }
.pxc__text p { color: var(--fg-muted); }
.pxc__hint {
  display: inline-flex; align-items: center; gap: .6rem; margin-top: var(--s3);
  font: 600 .78rem ui-monospace, "SF Mono", Menlo, Consolas, monospace; letter-spacing: .12em; text-transform: uppercase;
  color: var(--accent) !important;
}
.pxc__hint::before { content: ""; width: 28px; height: 1px; background: currentColor; }
.pxc__fig {
  position: relative; margin: 0; width: 100%; max-width: 560px; justify-self: center;
  aspect-ratio: 2 / 3; max-height: 82vh; border-radius: 14px; overflow: hidden;
  background: #111; box-shadow: 0 30px 70px -30px rgba(var(--shadow-rgb), .45);
}
.pxc__fig canvas { display: block; width: 100%; height: 100%; cursor: ew-resize; touch-action: pan-y; }
.pxc__fig:focus-within { outline: 2px solid var(--accent); outline-offset: 4px; }
.pxc__labels { position: absolute; inset: auto 0 0 0; display: flex; justify-content: space-between; padding: .8rem 1rem; pointer-events: none;
  font: 600 .7rem ui-monospace, "SF Mono", Menlo, Consolas, monospace; letter-spacing: .15em; text-transform: uppercase; color: #f7f5f1;
  text-shadow: 0 1px 6px rgba(0, 0, 0, .6); }
@media (max-width: 900px) {
  .pxc { grid-template-columns: 1fr; gap: var(--s4); }
  .pxc__fig { max-height: none; max-width: 480px; }
}

/* ---------- Votre site en 10 secondes (section Création web, toujours sombre) ---------- */
.gen {
  display: grid; grid-template-columns: 1fr 1.25fr; gap: var(--s8); align-items: center;
  margin-top: var(--s12); padding-top: var(--s12); border-top: 1px solid var(--line-dark);
}
.gen__text p { color: var(--on-dark-muted); }
.gen__text .h-sub { color: var(--on-dark); }
.gen__form { margin-top: var(--s4); display: grid; gap: var(--s1); }
.gen__form label { font-size: .78rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--on-dark); }
.gen__row { display: flex; gap: var(--s1); flex-wrap: wrap; }
.gen__row input {
  flex: 1 1 14rem; min-width: 0; min-height: 48px; padding: .7rem 1rem; border-radius: var(--radius);
  border: 1px solid var(--line-dark); background: rgba(247, 245, 241, .06); color: var(--on-dark); font: inherit;
}
.gen__row input::placeholder { color: #8d867c; }
.gen__row input:focus { outline: none; border-color: var(--on-dark-accent); box-shadow: 0 0 0 3px rgba(224, 180, 140, .25); }
.gen__row input[aria-invalid="true"] { border-color: #f0a39b; }
.gen__err { min-height: 1.2em; font-size: .85rem; color: #f0a39b !important; }
.gen__kinds { display: flex; flex-wrap: wrap; gap: var(--s1); }
.gen .chip { border-color: var(--line-dark); color: var(--on-dark-muted); }
.gen .chip:hover { border-color: var(--on-dark); color: var(--on-dark); }
.gen .chip[aria-pressed="true"] { background: var(--on-dark); border-color: var(--on-dark); color: var(--dark); }
.gen__note { margin-top: var(--s3); font-size: .8rem; }
.gen__real { grid-column: 2; justify-self: start; margin-top: calc(var(--s4) * -1); }

/* fenêtre de navigateur */
.gen__win {
  --g-bg: #f6efe6; --g-ink: #2b1d14; --g-acc: #8a4f2a;
  border-radius: 12px; overflow: hidden; border: 1px solid var(--line-dark); background: #1a1816;
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, .8);
}
.gen__bar { display: flex; align-items: center; gap: 6px; padding: .6rem .9rem; background: #232120; border-bottom: 1px solid var(--line-dark); }
.gen__bar i { width: 10px; height: 10px; border-radius: 50%; background: #3a3633; }
.gen__url {
  flex: 1; margin-left: .6rem; padding: .25rem .8rem; border-radius: 100px; background: #151412; min-width: 0;
  font: 500 .75rem ui-monospace, "SF Mono", Menlo, Consolas, monospace; color: #b8b1a6; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.gen__view { position: relative; aspect-ratio: 16 / 11; background: var(--g-bg); color: var(--g-ink); overflow: hidden; transition: background var(--dur) var(--ease-out); }
.gen__win:not(.is-live) .gen__view { background: #151412; }
.gen__empty {
  position: absolute; inset: 0; display: grid; place-items: center; margin: 0; padding: var(--s3); text-align: center;
  font: 500 .85rem ui-monospace, "SF Mono", Menlo, Consolas, monospace; color: #6b645b !important;
}
.gen__win.is-live .gen__empty { display: none; }
.gen__code {
  position: absolute; inset: 0; z-index: 2; margin: 0; padding: 1rem 1.2rem; background: #151412;
  font: 500 clamp(.72rem, 1.6vw, .9rem)/1.7 ui-monospace, "SF Mono", Menlo, Consolas, monospace; color: var(--on-dark-accent);
  white-space: pre-wrap; overflow-wrap: anywhere; opacity: 0; pointer-events: none; transition: opacity 300ms var(--ease-out);
}
.gen__win.is-coding .gen__code { opacity: 1; }

/* la maquette : tailles relatives à la fenêtre (container queries) */
.gen__site { position: absolute; inset: 0; display: grid; grid-template-rows: auto 1fr auto; container-type: inline-size; }
.g-part { opacity: 0; transform: translateY(10px); transition: opacity 450ms var(--ease-out), transform 450ms var(--ease-out); }
.g-part.is-in { opacity: 1; transform: none; }
.g-nav { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 3cqw 4cqw; border-bottom: 1px solid color-mix(in srgb, var(--g-ink) 12%, transparent); }
.g-logo { font-family: var(--serif); font-size: 3.4cqw; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.g-links { display: flex; gap: 3cqw; font-size: 1.9cqw; opacity: .7; white-space: nowrap; }
.g-hero {
  display: grid; grid-template-columns: 1.25fr 1fr; align-items: center; min-height: 0;
  background: radial-gradient(ellipse 70% 90% at 85% 50%, color-mix(in srgb, var(--g-acc) 16%, var(--g-bg)) 0%, var(--g-bg) 70%);
}
.g-hero__txt { display: flex; flex-direction: column; justify-content: center; gap: 1.6cqw; padding: 3cqw 4cqw; min-width: 0; }
.g-kicker { margin: 0; font-size: 1.6cqw; letter-spacing: .2em; text-transform: uppercase; color: var(--g-acc) !important; font-weight: 600; }
.g-title { margin: 0; font-family: var(--serif); font-size: 5.6cqw; line-height: 1; overflow-wrap: anywhere; color: var(--g-ink); }
.g-tag { margin: 0; font-size: 2.1cqw; opacity: .75; color: var(--g-ink) !important; }
.g-btn { align-self: start; padding: 1.3cqw 2.6cqw; border-radius: 100px; background: var(--g-acc); color: #fff; font-size: 1.9cqw; font-weight: 600; }
.g-art { display: grid; place-items: center; padding: 2cqw; min-height: 0; height: 100%; }
.g-art svg { width: 70%; max-height: 100%; fill: none; stroke: var(--g-acc); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }

/* section propre à l'activité */
.g-sec { padding: 2.4cqw 4cqw 3cqw; border-top: 1px solid color-mix(in srgb, var(--g-ink) 10%, transparent); }
.g-sec__head { display: flex; justify-content: space-between; align-items: center; gap: 2cqw; margin-bottom: 1.8cqw; }
.g-sec__head b { font-family: var(--serif); font-size: 2.8cqw; color: var(--g-ink); }
.g-badge { padding: .8cqw 1.8cqw; border-radius: 100px; font-size: 1.5cqw; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
  background: color-mix(in srgb, var(--g-acc) 12%, var(--g-bg)); color: var(--g-acc); }
.g-items { display: grid; gap: 1.6cqw; }
.g-item { display: flex; justify-content: space-between; align-items: baseline; gap: 2cqw; font-size: 1.9cqw; color: var(--g-ink); min-width: 0; }
.g-item__name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.g-item__meta { white-space: nowrap; font-weight: 600; color: var(--g-acc); }
/* restaurant & beauté : lignes « nom ....... prix » */
.g-items--r .g-item, .g-items--s .g-item { padding-bottom: 1.2cqw; border-bottom: 1px dashed color-mix(in srgb, var(--g-ink) 18%, transparent); }
/* boutique & artisan : vignettes */
.g-items--b, .g-items--a { grid-template-columns: repeat(3, 1fr); }
.g-items--b .g-item, .g-items--a .g-item { display: grid; gap: .6cqw; align-items: start; }
.g-tile { display: grid; place-items: center; aspect-ratio: 4 / 3; border-radius: 1.2cqw;
  background: linear-gradient(135deg, color-mix(in srgb, var(--g-acc) 22%, var(--g-bg)), color-mix(in srgb, var(--g-acc) 6%, var(--g-bg))); }
.g-tile svg { width: 42%; fill: none; stroke: var(--g-acc); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; opacity: .8; }
.g-items--b .g-item__meta, .g-items--a .g-item__meta { font-size: 1.6cqw; }

/* ---------- Noms de domaine ---------- */
.gen__domains { margin-top: var(--s4); }
.gen__dlabel { font-size: .78rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--on-dark) !important; margin-bottom: var(--s1); }
.gen__dlist { list-style: none; display: grid; grid-template-columns: minmax(0, 1fr); gap: .5rem; max-width: 30rem; }
.gen__dom {
  width: 100%; min-height: 48px; display: flex; justify-content: space-between; align-items: center; gap: .6rem; padding: .55rem .8rem;
  border-radius: var(--radius); border: 1px solid var(--line-dark); background: rgba(247, 245, 241, .04); color: var(--on-dark); text-align: left;
  font: 500 .82rem ui-monospace, "SF Mono", Menlo, Consolas, monospace; cursor: pointer;
  transition: border-color var(--dur-fast), background var(--dur-fast);
}
.gen__dname { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.gen__dstate { flex: none; font-family: var(--sans); font-size: .7rem; font-weight: 600; letter-spacing: .04em; padding: .2rem .5rem; border-radius: 100px; }
.gen__dom[data-status="check"] .gen__dstate { color: var(--on-dark-muted); }
.gen__dom[data-status="free"] .gen__dstate { background: var(--on-dark-accent); color: var(--dark); }
.gen__dom[data-status="taken"] { color: #8d867c; cursor: default; }
.gen__dom[data-status="taken"] .gen__dname { text-decoration: line-through; }
.gen__dom[data-status="taken"] .gen__dstate, .gen__dom[data-status="unknown"] .gen__dstate { color: #8d867c; border: 1px solid var(--line-dark); }
.gen__dom[data-status="unknown"] { cursor: default; }
.gen__dom[data-status="free"]:hover { border-color: var(--on-dark-accent); }
.gen__dom[aria-pressed="true"] { border-color: var(--on-dark-accent); background: rgba(224, 180, 140, .12); }
.gen__dnote { margin-top: var(--s1); font-size: .75rem; }
.gen__dmore { margin-bottom: .6rem; font-size: .82rem; color: var(--on-dark-accent) !important; }

@media (max-width: 900px) {
  .gen { grid-template-columns: 1fr; gap: var(--s4); }
  .gen__real { grid-column: 1; margin-top: 0; }
  .gen__view { aspect-ratio: 4 / 5; }
  .g-hero { grid-template-columns: 1.4fr 1fr; }
  .g-logo { font-size: 5cqw; } .g-links { font-size: 3cqw; }
  .g-kicker { font-size: 2.6cqw; } .g-title { font-size: 8cqw; } .g-tag { font-size: 3.4cqw; } .g-btn { font-size: 3.2cqw; padding: 2cqw 4cqw; }
  .g-sec__head b { font-size: 4.4cqw; } .g-badge { font-size: 2.6cqw; padding: 1.2cqw 2.6cqw; }
  .g-item { font-size: 3.2cqw; } .g-items--b .g-item__meta, .g-items--a .g-item__meta { font-size: 2.8cqw; }
  .g-items { gap: 2.4cqw; }
}
@media (prefers-reduced-motion: reduce) { .g-part { transition: none; } .gen__code { transition: none; } }
