/* Espace client TOM Agency : nuit violette, dans la continuité du site */
body.portal { background: #0b0b0e; min-height: 100vh; overflow-x: hidden; }
.p-glow { position: fixed; inset: -20vh -10vw auto; height: 90vh; pointer-events: none; z-index: 0;
  background: radial-gradient(50% 60% at 75% 10%, rgba(133, 47, 232, .38), transparent 70%), radial-gradient(40% 50% at 10% 0%, rgba(201, 166, 255, .14), transparent 70%); }
body.portal::after { content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 0; opacity: .5;
  background-image: radial-gradient(rgba(255,255,255,.035) 1px, transparent 1px); background-size: 22px 22px; }
.p-top, .p-main, .p-foot { position: relative; z-index: 1; }
.p-top { display: flex; justify-content: space-between; align-items: center; padding: calc(18px + env(safe-area-inset-top)) clamp(16px, 4vw, 48px) 18px; }
.p-logo img { height: 44px; width: auto; }
.p-hello { color: var(--muted); font-weight: 600; }
.p-main { max-width: 980px; margin: 0 auto; padding: 10px clamp(16px, 4vw, 32px) 80px; }
.p-foot { text-align: center; color: var(--faint); font-size: 12px; padding: 30px 16px calc(30px + env(safe-area-inset-bottom)); }
.p-foot a { color: var(--muted); }
.p-h1 { font-size: clamp(30px, 5vw, 52px); font-weight: 800; letter-spacing: -.035em; line-height: 1.02; color: #fff; }
.p-h1 em, .p-auth h1 em { font-style: normal; background: linear-gradient(90deg, #c9a6ff, #a463f5); -webkit-background-clip: text; background-clip: text; color: transparent; }
.p-h2 { font-size: 24px; font-weight: 800; letter-spacing: -.02em; margin-bottom: 16px; color: #fff; }
.p-h3 { font-size: 15px; margin: 22px 0 10px; }
.p-sub { color: var(--muted); font-size: 16px; margin: 10px 0 0; }
.p-section { margin-top: 46px; scroll-margin-top: 90px; }

/* Auth */
.p-auth { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(24px, 5vw, 64px); align-items: center; min-height: 70vh; }
.p-auth h1 { font-size: clamp(34px, 5vw, 58px); font-weight: 800; letter-spacing: -.04em; line-height: 1; color: #fff; margin-bottom: 18px; }
.p-auth-copy p { color: var(--ink-2); font-size: 17px; line-height: 1.6; max-width: 46ch; }
.p-perks { list-style: none; padding: 0; margin: 26px 0 0; display: grid; gap: 12px; }
.p-perks li { display: flex; gap: 12px; align-items: center; color: var(--ink-2); }
.p-perks .ci { color: #c9a6ff; }
.p-auth-card { padding: 30px; background: rgba(21, 17, 29, .72); backdrop-filter: blur(18px); border-color: rgba(255,255,255,.09); box-shadow: 0 40px 120px -40px rgba(133, 47, 232, .55); }
.p-auth-card h2 { font-size: 22px; margin-bottom: 8px; }
.p-auth-card .muted { margin: 0 0 20px; }
.p-otp { font: 700 32px var(--mono); letter-spacing: .4em; text-align: center; padding: 16px; }
.p-code { text-transform: uppercase; letter-spacing: .1em; font-size: 17px; }

/* Hero dossier */
.p-hero { padding: 28px 0 8px; }
.p-hero .ref-chip { font: 600 12px var(--mono); padding: 6px 11px; border-radius: 9px; background: rgba(255,255,255,.08); color: #e9dcff; border: 1px solid rgba(255,255,255,.14); cursor: pointer; display: inline-flex; gap: 6px; align-items: center; }
.p-steps { list-style: none; display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; padding: 0; margin: 30px 0 0; counter-reset: s; }
.p-steps li { position: relative; display: flex; flex-direction: column; gap: 10px; font-size: 12.5px; color: var(--faint); font-weight: 600; }
.p-steps li::before { content: ''; position: absolute; top: 15px; left: 32px; right: -6px; height: 2px; background: rgba(255,255,255,.1); }
.p-steps li:last-child::before { display: none; }
.p-steps li.is-done::before { background: linear-gradient(90deg, #a463f5, #c9a6ff); }
.p-dot { position: relative; z-index: 1; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font: 700 12px var(--mono); background: #15111d; border: 1.5px solid rgba(255,255,255,.16); color: var(--faint); }
.p-steps .is-done .p-dot { background: #a463f5; border-color: #a463f5; color: #fff; }
.p-steps .is-done { color: var(--ink-2); }
.p-steps .is-current { color: #fff; }
.p-steps .is-current .p-dot { border-color: #c9a6ff; color: #fff; box-shadow: 0 0 0 6px rgba(164, 99, 245, .2); animation: pulse 2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 10px rgba(164, 99, 245, .08); } }
.p-contact { display: flex; align-items: center; gap: 12px; margin-top: 28px; padding: 14px 16px; border-radius: 16px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); width: fit-content; max-width: 100%; }
.p-contact div { display: flex; flex-direction: column; }
.p-contact span:not(.avatar) { color: var(--muted); font-size: 12.5px; }
.p-nav { position: sticky; top: calc(10px + env(safe-area-inset-top)); z-index: 20; display: flex; gap: 4px; margin-top: 30px; padding: 5px; width: fit-content; max-width: 100%; overflow-x: auto; border-radius: 14px; background: rgba(21, 17, 29, .78); backdrop-filter: blur(16px); border: 1px solid rgba(255,255,255,.08); }
.p-nav a { display: inline-flex; gap: 7px; align-items: center; padding: 8px 13px; border-radius: 10px; font-weight: 600; font-size: 13px; color: var(--ink-2); white-space: nowrap; }
.p-nav a:hover { background: rgba(255,255,255,.07); color: #fff; }

.portal .card { background: rgba(21, 17, 29, .7); border-color: rgba(255,255,255,.08); backdrop-filter: blur(10px); }
.portal .table th { background: transparent; }
.p-accept { margin-top: 14px; border-color: rgba(164, 99, 245, .45) !important; box-shadow: 0 30px 80px -40px rgba(133, 47, 232, .8); }
.p-accept h3 { font-size: 19px; margin-bottom: 6px; }
.p-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.p-option { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 14px; border: 1px solid rgba(255,255,255,.09); cursor: pointer; transition: border-color .2s, background .2s; }
.p-option:has(input:checked) { border-color: #a463f5; background: rgba(164, 99, 245, .1); }
.p-option input { margin-top: 3px; accent-color: #a463f5; }
.p-option span { flex: 1; display: flex; flex-direction: column; gap: 3px; }
.p-option small { color: var(--muted); font-size: 12px; }
.p-option em { font: 600 12px var(--mono); font-style: normal; color: #c9a6ff; white-space: nowrap; }
.p-paychoice { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.p-pay-card { position: relative; display: flex; flex-direction: column; gap: 6px; padding: 22px; border-radius: 20px; border: 1.5px solid rgba(255,255,255,.1); background: rgba(21, 17, 29, .7); cursor: pointer; transition: border-color .2s, transform .2s var(--ease), box-shadow .2s; }
.p-pay-card:hover { transform: translateY(-2px); }
.p-pay-card > input { position: absolute; opacity: 0; }
.p-pay-card:has(> input:checked) { border-color: #a463f5; box-shadow: 0 30px 70px -36px rgba(164, 99, 245, .9); }
.p-pay-k { font: 600 11px var(--mono); text-transform: uppercase; letter-spacing: .12em; color: #c9a6ff; }
.p-pay-card strong { font: 700 30px var(--mono); letter-spacing: -.04em; color: #fff; }
.p-step-row { display: grid; grid-template-columns: 90px 1fr 1fr; gap: 8px; }
.p-drop { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; padding: 36px 20px; border-radius: 22px; border: 2px dashed rgba(201, 166, 255, .3); background: rgba(164, 99, 245, .05); transition: border-color .2s, background .2s; }
.p-drop.is-over { border-color: #c9a6ff; background: rgba(164, 99, 245, .14); }
.p-drop .ci-lg { color: #c9a6ff; width: 34px; height: 34px; }
.p-uploads { width: 100%; max-width: 520px; display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.p-up { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; text-align: left; font-size: 13px; }
.p-up .progress { grid-column: span 2; }
.p-deal-card { display: flex; flex-direction: column; gap: 4px; transition: transform .2s var(--ease), border-color .2s; }
.p-deal-card:hover { transform: translateY(-2px); border-color: rgba(164, 99, 245, .5); }
.p-deal-card strong { font-size: 18px; }

@media (max-width: 760px) {
  .p-auth { grid-template-columns: 1fr; min-height: 0; padding-top: 10px; }
  .p-steps { grid-template-columns: repeat(3, 1fr); row-gap: 18px; }
  .p-steps li:nth-child(3)::before { display: none; }
  .p-options, .p-paychoice { grid-template-columns: 1fr; }
  .p-step-row { grid-template-columns: 70px 1fr; }
  .p-step-row input:last-child { grid-column: span 2; }
}


/* Mobile : champs à 16 px minimum, sinon l'iPhone zoome à la saisie */
@media (max-width: 760px), (pointer: coarse) {
  .input, .select, .textarea, input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=hidden]), select, textarea { font-size: 16px; }
}
