/* Avertissement avant d'ouvrir un lien externe — voir assets/js/pe-external-link.js
   La boîte est centrée explicitement : une remise à zéro des marges du site (« * { margin: 0 } ») retirait le
   centrage automatique du <dialog> et la collait en haut à gauche. */
.pe-xl {
    position: fixed; inset: 0; margin: auto;
    width: min(440px, calc(100vw - 32px)); height: fit-content; max-height: calc(100dvh - 32px);
    padding: 0; overflow: auto;
    border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 20px;
    background: linear-gradient(180deg, #131822 0%, #0d1016 100%); color: #e9edf3;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.4), 0 32px 80px rgba(0, 0, 0, 0.6);
    font-family: 'Outfit', system-ui, -apple-system, 'Segoe UI', sans-serif;
    text-align: center;
}
.pe-xl::backdrop { background: rgba(4, 6, 10, 0.7); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.pe-xl[open] { animation: pe-xl-in 240ms cubic-bezier(0.23, 1, 0.32, 1); }
.pe-xl[open]::backdrop { animation: pe-xl-fade 240ms ease-out; }
@keyframes pe-xl-in { from { opacity: 0; transform: translateY(10px) scale(0.97); } to { opacity: 1; transform: none; } }
@keyframes pe-xl-fade { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .pe-xl[open], .pe-xl[open]::backdrop { animation: none; } }

.pe-xl-box { position: relative; margin: 0; padding: 34px 28px 26px; }
.pe-xl-close {
    position: absolute; top: 12px; right: 12px; width: 32px; height: 32px; padding: 0;
    display: flex; align-items: center; justify-content: center;
    border: 0; border-radius: 50%; background: transparent; color: #748092; cursor: pointer;
    transition: background-color 140ms, color 140ms;
}
.pe-xl-close:hover { background: rgba(255, 255, 255, 0.08); color: #e9edf3; }
.pe-xl-close:focus-visible { outline: 2px solid #7cb2ff; outline-offset: 2px; }
.pe-xl-icon {
    width: 56px; height: 56px; margin: 0 auto 16px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: #fbbf24; background: radial-gradient(circle at 50% 40%, rgba(251, 191, 36, 0.22), rgba(251, 191, 36, 0.06));
    box-shadow: inset 0 0 0 1px rgba(251, 191, 36, 0.3), 0 0 32px rgba(251, 191, 36, 0.12);
}
.pe-xl-title { margin: 0 0 10px; font-size: 1.3rem; font-weight: 650; letter-spacing: -0.02em; line-height: 1.25; }
.pe-xl-text { margin: 0; font-size: 0.9rem; line-height: 1.6; color: #a0abb9; text-wrap: pretty; }
.pe-xl-dest {
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    margin-top: 20px; padding: 14px 16px; border-radius: 12px;
    background: rgba(0, 0, 0, 0.32); border: 1px solid rgba(255, 255, 255, 0.09);
}
.pe-xl-label { display: inline-flex; align-items: center; gap: 4px; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: #748092; }
.pe-xl-label svg { opacity: 0.8; }
.pe-xl-host { max-width: 100%; font-size: 1.15rem; font-weight: 650; letter-spacing: -0.01em; overflow-wrap: anywhere; color: #fff; }
.pe-xl-url { max-width: 100%; font-size: 0.76rem; color: #748092; overflow-wrap: anywhere; font-family: 'Cascadia Mono', 'SF Mono', ui-monospace, monospace; }
.pe-xl-tip {
    display: flex; align-items: flex-start; gap: 8px; justify-content: center; text-align: left;
    margin: 16px 0 0; font-size: 0.78rem; line-height: 1.5; color: #748092;
}
.pe-xl-tip svg { flex: none; margin-top: 2px; color: #6ee7b7; opacity: 0.85; }
.pe-xl-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 22px; }
.pe-xl-btn {
    min-height: 44px; padding: 8px 14px; border-radius: 10px; cursor: pointer;
    font: inherit; font-size: 0.88rem; font-weight: 600; line-height: 1.25;
    border: 1px solid transparent; transition: background-color 140ms, border-color 140ms, transform 140ms;
}
.pe-xl-btn:active { transform: scale(0.98); }
.pe-xl-btn--ghost { background: #e9edf3; color: #0b0d12; }
.pe-xl-btn--ghost:hover { background: #fff; }
.pe-xl-btn--go { background: transparent; color: #cdd5e0; border-color: rgba(255, 255, 255, 0.16); overflow-wrap: anywhere; }
.pe-xl-btn--go:hover { background: rgba(255, 255, 255, 0.06); border-color: rgba(255, 255, 255, 0.26); }
.pe-xl-btn:focus-visible { outline: 2px solid #7cb2ff; outline-offset: 2px; }
@media (max-width: 480px) {
    .pe-xl-box { padding: 30px 20px 22px; }
    .pe-xl-actions { grid-template-columns: 1fr; }
    .pe-xl-btn--ghost { order: -1; }
}
