/* ANYA — appli téléphone (page « Déposer »), habillage « Anya 2.0 by Netora » : noir profond, vert lumineux.
   Gros boutons, lisible en extérieur, sans dépendance ni police externe. Animations discrètes, coupées si
   l'appareil demande moins de mouvement. Le module Studio vidéo (anya-video.css) est remis aux couleurs en fin de fichier. */
:root {
  --bg: #050706; --s1: #0C1411; --s2: #121C18; --s3: #18241F; --line: rgba(93, 202, 165, .16);
  --ink: #EAF5EF; --muted: #93AB9F; --g: #2DD4A0; --g2: #1D9E75; --g3: #5DCAA5; --on-g: #03130C;
  --err: #FF7A7A; --ok: #2DD4A0; --warn: #F5B84A;
  /* compatibilité avec les anciens noms */
  --navy: var(--ink); --gold: var(--g);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font: 17px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; }
body { min-height: 100vh; background: radial-gradient(420px 320px at 100% -40px, rgba(45, 212, 160, .14), transparent 70%) no-repeat, var(--bg); }
.dp { max-width: 560px; margin: 0 auto; padding: calc(10px + env(safe-area-inset-top)) 16px calc(28px + env(safe-area-inset-bottom)); }
body.has-tabbar .dp { padding-bottom: calc(104px + env(safe-area-inset-bottom)); }

/* En-tête : Anya, par Netora — entreprise connectée à droite, discrète. */
.dp-head { display: flex; align-items: center; gap: 10px; padding: 8px 2px 16px; }
.dp-ava { flex: none; width: 42px; height: 42px; border-radius: 13px; overflow: hidden; border: 1.5px solid rgba(45, 212, 160, .6); }
.dp-ava img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 18%; display: block; }
.dp-brand { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.dp-brand h1 { margin: 0; font-size: 21px; line-height: 1; letter-spacing: -.01em; color: var(--ink); }
.dp-brand p { margin: 0; display: flex; align-items: center; gap: 5px; color: var(--muted); font-size: 12px; }
.dp-brand p img { height: 13px; width: auto; display: block; }
.dp-company { margin-left: auto; display: inline-flex; align-items: center; gap: 7px; max-width: 46%; padding: 7px 11px; border-radius: 99px; background: var(--s1); border: 1px solid var(--line); color: #C9DBD2; font-size: 12px; font-weight: 700; text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dp-company[hidden] { display: none; }
.dp-dot { flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--g); box-shadow: 0 0 0 3px rgba(45, 212, 160, .18); }

.dp-card { background: var(--s1); border: 1px solid var(--line); border-radius: 22px; padding: 18px; margin-bottom: 14px; }
.dp-card h2 { margin: 0 0 10px; font-size: 19px; color: var(--ink); }
.dp-help { color: var(--muted); font-size: 14px; margin: 8px 0 0; }
.dp-center { text-align: center; color: var(--muted); }
label { display: block; font-weight: 600; margin: 12px 0 0; }
label small { font-weight: 400; color: var(--muted); }
input:not([type=checkbox]):not([type=file]), textarea { display: block; width: 100%; margin-top: 6px; padding: 14px; font: inherit; color: var(--ink); border: 1px solid var(--line); border-radius: 14px; background: var(--s2); }
input::placeholder, textarea::placeholder { color: #6E857A; }
input:focus, textarea:focus { outline: 2px solid var(--g); outline-offset: 1px; border-color: transparent; }
.dp-check { display: flex; align-items: center; gap: 12px; font-weight: 600; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--s2); }
.dp-check input { width: 24px; height: 24px; flex: none; accent-color: var(--g); }
.dp-btn { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 54px; padding: 14px 18px; border-radius: 16px; border: 0; font: inherit; font-weight: 800; cursor: pointer; text-align: center; margin: 0; transition: transform .18s ease, box-shadow .25s ease, background .2s; }
.dp-btn:active { transform: scale(.97); }
.dp-btn:disabled { opacity: .5; }
a.dp-btn { text-decoration: none; }
.dp-primary { background: var(--g); color: var(--on-g); box-shadow: 0 8px 26px rgba(45, 212, 160, .26); }
.dp-ghost { background: var(--s2); color: var(--ink); border: 1px solid var(--line); }
.dp-xl { min-height: 72px; font-size: 19px; }
.dp-big { display: grid; gap: 12px; }
.dp-row { display: grid; grid-template-columns: 1fr 2fr; gap: 10px; margin-top: 16px; }
.dp-preview img, .dp-preview video { display: block; width: 100%; max-height: 52vh; object-fit: contain; background: #000; border-radius: 16px; }
.dp-progress { margin-top: 16px; }
.dp-bar { height: 12px; background: var(--s2); border-radius: 99px; overflow: hidden; }
.dp-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--g2), var(--g)); border-radius: 99px; transition: width .2s; }
.dp-progress p { margin: 8px 0 0; font-size: 15px; color: var(--muted); text-align: center; font-variant-numeric: tabular-nums; }
.dp-err { color: var(--err); font-weight: 600; margin: 10px 0 0; min-height: 1em; }
.dp-reasons { padding-left: 20px; color: var(--err); }
.dp-text { white-space: pre-wrap; background: var(--s2); border-radius: 14px; padding: 12px; font-size: 15px; }
.dp-item { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid rgba(93, 202, 165, .1); }
.dp-item:first-child { border-top: 0; }
.dp-item img, .dp-ph { width: 56px; height: 56px; border-radius: 12px; object-fit: cover; flex: none; background: var(--s2); display: flex; align-items: center; justify-content: center; font-size: 24px; }
.dp-item small { display: block; color: var(--muted); font-size: 13px; }
.dp-foot { text-align: center; color: var(--muted); font-size: 13px; margin-top: 22px; line-height: 2; }
.dp-foot img { height: 20px; width: auto; vertical-align: middle; }
.dp-link { background: none; border: 0; color: var(--g); text-decoration: underline; font: inherit; padding: 8px; cursor: pointer; }
summary { cursor: pointer; font-weight: 600; margin-top: 8px; color: var(--g3); }
.dp-back { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 16px 0 10px; margin: 0 0 12px; border-radius: 99px; background: var(--s1); border: 1px solid var(--line); color: var(--ink); font-weight: 700; text-decoration: none; }
.dp-back[hidden] { display: none; }
body.has-tabbar .dp-back { display: none; }   /* la barre d'onglets fait office de retour */

/* Connexion */
.dp-login { text-align: left; }
.dp-login-ava { width: 128px; height: 170px; margin: 4px auto 14px; border-radius: 24px; overflow: hidden; animation: dpGlow 3.2s ease-in-out infinite, dpFloat 6s ease-in-out infinite; }
.dp-login-ava img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 15%; display: block; }
.dp-login h2 { text-align: center; }
.dp-login form .dp-btn { margin-top: 18px; }

/* Accueil : Anya vivante, action principale, modules en cartes. */
.dp-hero { position: relative; display: flex; gap: 16px; align-items: flex-end; padding: 18px; margin-bottom: 14px; border-radius: 24px; border: 1px solid var(--line); background: linear-gradient(160deg, #0F1D18, #070B09); overflow: hidden; }
.dp-hero-ava { flex: none; width: 108px; height: 146px; border-radius: 20px; overflow: hidden; animation: dpGlow 3.2s ease-in-out infinite, dpFloat 6s ease-in-out infinite; }
.dp-hero-ava img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 15%; display: block; }
.dp-hero-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 9px; }
.dp-hero-txt h2 { margin: 0; font-size: 21px; line-height: 1.15; letter-spacing: -.01em; }
.dp-live { align-self: flex-start; display: inline-flex; align-items: center; gap: 7px; padding: 4px 10px; border-radius: 99px; background: rgba(45, 212, 160, .12); color: var(--g3); font-size: 12px; font-weight: 800; }
.dp-bubble { margin: 0; min-height: 60px; padding: 10px 12px; border-radius: 16px 16px 16px 4px; background: var(--s2); border: 1px solid var(--line); font-size: 14px; line-height: 1.4; }
.dp-bubble.is-in { animation: dpIn .45s ease both; }
.dp-cta { margin-bottom: 18px; }
.dp-sec { margin: 0 0 12px; font-size: 17px; letter-spacing: -.01em; }
.dp-menu { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.dp-tile { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; min-height: 156px; padding: 16px; border-radius: 22px; background: var(--s1); color: var(--ink); text-decoration: none; border: 1px solid var(--line); transition: transform .18s ease, border-color .2s; }
a.dp-tile:active { transform: scale(.97); border-color: var(--g); }
a.dp-tile:focus-visible { outline: 2px solid var(--g); outline-offset: 2px; }
.dp-tile-ico { flex: none; width: 44px; height: 44px; border-radius: 14px; display: flex; align-items: center; justify-content: center; background: rgba(45, 212, 160, .12); color: var(--g); }
.dp-tile-txt { min-width: 0; }
.dp-tile-txt b { display: block; font-size: 16px; color: var(--ink); }
.dp-tile-txt small { display: block; color: var(--muted); font-size: 12.5px; line-height: 1.4; margin-top: 4px; }
.dp-tile-new { border-color: rgba(45, 212, 160, .45); background: linear-gradient(160deg, #0F2019, var(--s1)); }
.dp-tile-new .dp-tile-ico { background: var(--g); color: var(--on-g); }
.dp-badge { margin-top: auto; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; color: var(--on-g); background: var(--g); border-radius: 99px; padding: 4px 10px; }
.dp-soon { opacity: .55; }
.dp-locked { opacity: .5; }
.dp-badge-mut { background: rgba(147, 171, 159, .16) !important; color: var(--muted) !important; }
.dp-soon .dp-tile-ico { background: rgba(147, 171, 159, .12); color: var(--muted); }
.dp-soon .dp-badge { background: rgba(147, 171, 159, .14); color: var(--muted); }
/* Apparition en cascade des cartes de l'accueil. */
#v-home:not([hidden]) > *, #v-home:not([hidden]) .dp-tile { animation: dpRise .5s cubic-bezier(.2, .8, .2, 1) both; }
#v-home .dp-cta { animation-delay: .06s !important; }
#v-home .dp-sec { animation-delay: .1s !important; }
#v-home .dp-tile:nth-child(1) { animation-delay: .14s; } #v-home .dp-tile:nth-child(2) { animation-delay: .18s; }
#v-home .dp-tile:nth-child(3) { animation-delay: .22s; } #v-home .dp-tile:nth-child(4) { animation-delay: .26s; }
#v-main:not([hidden]), #v-off:not([hidden]), #v-studio:not([hidden]), #v-account:not([hidden]), #v-login:not([hidden]) { animation: dpRise .45s cubic-bezier(.2, .8, .2, 1) both; }

/* Compte */
.dp-kicker { margin: 0; color: var(--muted); font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.dp-company-name { margin: 4px 0 0 !important; font-size: 22px !important; }

/* Barre d'onglets (bas d'écran, au-dessus de la zone du geste d'accueil). */
.dp-nav { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(10px + env(safe-area-inset-bottom)); width: min(528px, calc(100% - 24px)); height: 66px; display: flex; align-items: center; padding: 0 4px; border-radius: 24px; background: rgba(12, 20, 17, .92); border: 1px solid var(--line); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); z-index: 50; }
.dp-nav[hidden] { display: none; }
.dp-nav a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 7px 0 5px; color: var(--muted); font-size: 11px; font-weight: 700; text-decoration: none; transition: color .2s; }
.dp-nav a span { display: flex; align-items: center; justify-content: center; width: 46px; height: 30px; border-radius: 99px; transition: background .25s; }
.dp-nav a[aria-current] { color: var(--g); }
.dp-nav a[aria-current] span { background: rgba(45, 212, 160, .14); }

@keyframes dpRise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes dpIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes dpFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@keyframes dpGlow { 0%, 100% { box-shadow: 0 0 0 2px rgba(45, 212, 160, .55), 0 0 24px rgba(45, 212, 160, .22); } 50% { box-shadow: 0 0 0 2px rgba(45, 212, 160, .9), 0 0 42px rgba(45, 212, 160, .42); } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
@media (max-width: 350px) { .dp-menu { grid-template-columns: 1fr; } .dp-tile { min-height: 0; } }

/* ---------------------------------------------------------------------------------------------
   Studio vidéo dans l'appli : même module que l'admin (anya-video.js / anya-video.css),
   remis aux couleurs Netora. Variables et classes « ax-* » de l'admin redéfinies ici.
   --------------------------------------------------------------------------------------------- */
.dp-studio, .ax-modal, .ax-toast { --c-bg: var(--s2); --ax-line: var(--line); --c-text: var(--ink); --c-text-soft: #C5D6CD; --c-text-mute: var(--muted); --c-dark: var(--ink); --c-blue: var(--g); --c-blue-3: var(--g3); --c-gold: var(--g); --ax-ok: var(--ok); --ax-warn: var(--warn); --ax-err: var(--err); --ax-pink: #FF5FA2; }
.dp-studio .ax-card { background: var(--s1); border: 1px solid var(--line); border-radius: 22px; padding: 16px; margin-bottom: 14px; }
.dp-studio .ax-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.dp-studio .ax-card-head h2 { margin: 0; font-size: 18px; color: var(--ink); }
.dp-studio .ax-help { font-size: 13.5px; color: var(--muted); margin: 6px 0 12px; line-height: 1.5; }
.dp-studio .ax-help b { color: var(--ink); }
.dp-studio fieldset { border: 1px solid var(--line); border-radius: 16px; padding: 12px; margin: 0 0 12px; min-width: 0; }
.dp-studio legend { padding: 0 6px; font-weight: 800; font-size: 14px; }
.dp-studio .ax-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.dp-studio .ax-actions .ax-btn { flex: 1; justify-content: center; min-height: 54px; font-size: 16px; }
.ax-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; border: 1px solid transparent; border-radius: 14px; padding: 9px 16px; font: inherit; font-size: 14px; font-weight: 800; cursor: pointer; text-decoration: none; transition: transform .18s ease, background .2s; }
.ax-btn:active { transform: scale(.97); }
.ax-btn:disabled { opacity: .5; }
.ax-btn-primary { background: var(--g); color: var(--on-g); box-shadow: 0 8px 24px rgba(45, 212, 160, .22); }
.ax-btn-ghost { background: var(--s2); border-color: var(--line); color: var(--ink); }
.ax-btn-danger-ghost { background: var(--s2); border-color: rgba(255, 122, 122, .4); color: var(--err); }
.ax-badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 99px; font-size: 11.5px; font-weight: 800; white-space: nowrap; }
.ax-badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.ax-badge.ok { background: rgba(45, 212, 160, .14); color: var(--g); }
.ax-badge.off { background: rgba(147, 171, 159, .14); color: var(--muted); }
.ax-badge.warn { background: rgba(245, 184, 74, .14); color: var(--warn); }
.ax-badge.err { background: rgba(255, 122, 122, .14); color: var(--err); }
.ax-badge.info { background: rgba(93, 202, 165, .12); color: var(--g3); }
.dp-studio select, .dp-studio input:not([type=checkbox]):not([type=radio]):not([type=file]) { width: 100%; padding: 12px; border-radius: 12px; background: var(--s2); border: 1px solid var(--line); color: var(--ink); font: inherit; }
.dp-studio label.vs-ph { margin: 0; }
.dp-studio .vs-style, .dp-studio .vs-job, .dp-studio .vs-logo-opt { background: var(--s2); border-color: var(--line); color: var(--ink); }
.dp-studio .vs-style.is-on { border-color: var(--g); background: rgba(45, 212, 160, .08); box-shadow: none; }
.dp-studio .vs-job[data-status=ready] { background: rgba(45, 212, 160, .06); border-color: rgba(45, 212, 160, .45); }
.dp-studio .vs-chip { background: var(--s2); border-color: var(--line); color: var(--muted); }
.dp-studio .vs-chip b { color: var(--ink); }
.dp-studio .vs-ph-num, .dp-studio .vs-ph-grip { background: rgba(5, 7, 6, .78); }
.dp-studio .vs-ph-acts { background: linear-gradient(transparent, rgba(5, 7, 6, .9)); }
.dp-studio .vs-ph-acts button { min-height: 36px; background: rgba(18, 28, 24, .92); color: var(--ink); border: 1px solid var(--line); }
.dp-studio .vs-drop:hover, .dp-studio .vs-drop.is-over, .dp-studio form.is-over { background: rgba(45, 212, 160, .06); }
.dp-studio .vs-progress { background: var(--s2); }
.dp-studio .vs-progress span { background: linear-gradient(90deg, var(--g2), var(--g)); }
.ax-modal { position: fixed; inset: 0; background: rgba(0, 0, 0, .7); display: grid; place-items: center; z-index: 100; padding: 16px; }
.ax-modal[hidden] { display: none; }
.ax-modal-box { width: 100%; max-width: 520px; max-height: 92vh; overflow: auto; background: var(--s1); color: var(--ink); border: 1px solid var(--line); border-radius: 22px; padding: 18px; animation: dpRise .25s ease both; }
.ax-modal-box h3 { margin: 0 0 10px; font-size: 18px; }
.ax-modal-box p { color: #C5D6CD; }
.ax-modal-box b { color: var(--ink); }
.ax-modal .ax-actions { display: flex; gap: 10px; margin-top: 14px; }
.ax-modal .ax-actions .ax-btn { flex: 1; min-height: 50px; }
.ax-toast { position: fixed; left: 50%; bottom: calc(92px + env(safe-area-inset-bottom)); transform: translate(-50%, 10px); width: max-content; max-width: calc(100% - 32px); background: var(--s3); color: var(--ink); border: 1px solid var(--line); padding: 12px 16px; border-radius: 14px; font-size: 14px; font-weight: 700; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; z-index: 101; }
.ax-toast.is-on { opacity: 1; transform: translate(-50%, 0); }
.ax-toast.is-err { background: #3A1414; border-color: rgba(255, 122, 122, .4); }
