/* Page « bientôt disponible » de Restobip. Fichier à part : la CSP du service interdit le style en ligne. */
:root { --ink: #0a0f1e; --card: #121a30; --text: #eef2ff; --muted: #9aa6c7; --go: #2ee59d; --warm: #ffc94d; }
* { box-sizing: border-box; margin: 0; }
html, body { height: 100%; }
html { overflow-x: clip; } /* les ondes de la démonstration débordent de la page */
body { background: var(--ink); color: var(--text); font: 17px/1.5 system-ui, "Segoe UI", Roboto, "Noto Sans Arabic", sans-serif;
  display: flex; flex-direction: column; min-height: 100%; overflow-x: hidden; }

/* Halos animés du fond. */
.glow { position: fixed; width: 60vmax; height: 60vmax; border-radius: 50%; filter: blur(90px); opacity: .35; z-index: 0; pointer-events: none; }
.g1 { background: #2a5cff; top: -25vmax; left: -15vmax; animation: drift 16s ease-in-out infinite alternate; }
.g2 { background: var(--go); bottom: -30vmax; right: -20vmax; opacity: .22; animation: drift 20s ease-in-out infinite alternate-reverse; }
@keyframes drift { to { transform: translate(8vmax, 6vmax) scale(1.15); } }

.top, .hero, .foot { position: relative; z-index: 1; width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.top { display: flex; justify-content: space-between; align-items: center; padding-top: 22px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.25rem; letter-spacing: .3px; }
.dot { width: 12px; height: 12px; border-radius: 50%; background: var(--go); box-shadow: 0 0 0 0 rgba(46, 229, 157, .7); animation: ping 2s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 14px rgba(46, 229, 157, 0); } 100% { box-shadow: 0 0 0 0 rgba(46, 229, 157, 0); } }
.lang { background: transparent; color: var(--text); border: 1.5px solid rgba(255, 255, 255, .35); border-radius: 999px;
  padding: 8px 18px; font: inherit; font-weight: 600; cursor: pointer; }
.lang:hover, .lang:focus-visible { border-color: var(--go); outline: none; }

.hero { flex: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: center; padding-top: 32px; padding-bottom: 32px; }
.soon { display: inline-block; color: var(--ink); background: var(--warm); font-weight: 800; font-size: .85rem; letter-spacing: 1.2px;
  text-transform: uppercase; padding: 6px 14px; border-radius: 999px; margin-bottom: 22px; }
h1 { font-size: clamp(2.1rem, 5.2vw, 4rem); line-height: 1.08; letter-spacing: -.5px; margin-bottom: 20px; }
.lead { font-size: clamp(1.05rem, 1.7vw, 1.3rem); color: var(--muted); max-width: 34em; margin-bottom: 28px; }
.points { list-style: none; padding: 0; display: grid; gap: 12px; }
.points li { display: flex; align-items: center; gap: 12px; font-weight: 600; }
.points li::before { content: ""; flex: none; width: 10px; height: 10px; border-radius: 3px; background: var(--go); transform: rotate(45deg); }

/* Téléphone de démonstration. */
.demo { position: relative; display: grid; place-items: center; min-height: 440px; }
.phone { position: relative; width: 240px; height: 440px; border-radius: 38px; background: var(--card); border: 2px solid rgba(255, 255, 255, .14);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .55); padding: 54px 22px 26px; text-align: center; display: flex; flex-direction: column; align-items: center;
  transition: border-color .4s, box-shadow .4s; }
.notch { position: absolute; top: 14px; left: 50%; width: 84px; height: 22px; margin-left: -42px; border-radius: 999px; background: var(--ink); }
.label { color: var(--muted); font-size: .9rem; letter-spacing: 2px; text-transform: uppercase; margin-top: 26px; }
.number { font-size: 5.2rem; font-weight: 900; line-height: 1; margin: 6px 0 22px; font-variant-numeric: tabular-nums; transition: color .4s; }
.state { font-weight: 700; font-size: 1.15rem; }
.state.done { display: none; color: var(--go); font-size: 1.5rem; }
.bar { margin-top: auto; width: 100%; height: 8px; border-radius: 999px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.bar span { display: block; height: 100%; width: 35%; border-radius: inherit; background: var(--warm); animation: load 1.6s ease-in-out infinite; }
@keyframes load { 0% { transform: translateX(-110%); } 100% { transform: translateX(310%); } }

.rings { position: absolute; inset: 0; display: grid; place-items: center; }
.rings span { position: absolute; width: 240px; height: 240px; border-radius: 50%; border: 2px solid var(--go); opacity: 0; }

/* État « prête » : le téléphone vibre, le numéro passe au vert, des ondes partent. */
.phone.ready { border-color: var(--go); box-shadow: 0 30px 90px rgba(46, 229, 157, .28); animation: buzz .5s 3; }
.phone.ready .number { color: var(--go); }
.phone.ready .wait { display: none; }
.phone.ready .done { display: block; }
.phone.ready .bar span { width: 100%; background: var(--go); animation: none; transform: none; }
.demo.ready .rings span { animation: wave 1.8s ease-out infinite; }
.demo.ready .rings span:nth-child(2) { animation-delay: .5s; }
.demo.ready .rings span:nth-child(3) { animation-delay: 1s; }
@keyframes wave { 0% { transform: scale(.7); opacity: .7; } 100% { transform: scale(2.3); opacity: 0; } }
@keyframes buzz { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-3deg) translateX(-3px); } 75% { transform: rotate(3deg) translateX(3px); } }

.foot { padding-top: 18px; padding-bottom: 22px; color: var(--muted); font-size: .9rem; }

[dir=rtl] h1 { letter-spacing: 0; line-height: 1.3; }
[dir=rtl] .soon, [dir=rtl] .label { letter-spacing: 0; }

@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; gap: 20px; padding-top: 20px; }
  .demo { min-height: 400px; order: -1; }
  .phone { width: 200px; height: 370px; padding-top: 48px; }
  .number { font-size: 4.2rem; }
}
@media (prefers-reduced-motion: reduce) {
  .glow, .dot, .bar span, .phone.ready, .demo.ready .rings span { animation: none; }
}
