/* AXDIA OS — mises en page propres à certaines vues de l'espace client.
   Les composants (cartes, listes, boutons, badges, états, coque) viennent de app-design-system.css,
   chargé avant ce fichier. Ici : uniquement ce qui n'existe que sur une vue. */

/* Connexion, onboarding */
.auth{max-width:560px}
.auth-card h2{margin:10px 0 6px;font:500 27px/1.12 var(--font-serif);letter-spacing:-.015em}
.auth-tabs{margin:16px 0 14px}
.auth-google{width:100%;margin-bottom:12px}
.onboarding{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;list-style:none;margin:0 0 14px;padding:0}
.onboarding li{padding:11px 12px;border:1px solid var(--line);border-radius:11px;background:var(--surface2);color:var(--muted);font-size:12px}
.onboarding li.done{color:var(--green)}
.onboarding li.current{background:var(--accent-soft);color:var(--text);box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--accent) 40%,transparent)}

/* Premier accueil après le choix explicite de l'offre gratuite. */
.early-welcome{position:relative;isolation:isolate;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:28px;align-items:end;min-height:285px;margin:0 0 22px;padding:32px;border:1px solid color-mix(in srgb,var(--accent) 50%,var(--line));border-radius:22px;background:linear-gradient(120deg,var(--accent-soft),transparent 58%),var(--surface);overflow:hidden}
.early-welcome::after{content:"";position:absolute;z-index:-1;right:-90px;top:-120px;width:360px;height:360px;border-radius:50%;background:color-mix(in srgb,var(--accent) 14%,transparent);pointer-events:none}
.early-welcome-mark{display:grid;place-items:center;width:50px;height:50px;margin-bottom:18px;border-radius:14px;background:var(--accent-soft);color:var(--accent-text);font-size:29px}
.early-welcome h2{max-width:750px;margin:8px 0 12px;font:500 clamp(30px,4vw,54px)/1.05 var(--font-serif);letter-spacing:-.025em}
.early-welcome p:not(.kicker){max-width:660px;margin:0;color:var(--muted);line-height:1.6}
.early-welcome-actions{display:flex;flex-direction:column;align-items:stretch;gap:10px;min-width:215px}
.early-welcome-actions .btn{text-align:center;justify-content:center}
.early-access-card{border-color:color-mix(in srgb,var(--accent) 35%,var(--line));background:linear-gradient(120deg,var(--accent-soft),transparent 54%),var(--surface)}
@media(max-width:780px){.early-welcome{grid-template-columns:1fr;min-height:0;padding:24px;gap:24px}.early-welcome-actions{min-width:0}.early-welcome h2{font-size:clamp(29px,9vw,42px)}}

/* Commandes : carte de mission et étapes */
.mission-card .mission-head{display:flex;justify-content:space-between;align-items:flex-start;gap:14px;flex-wrap:wrap}
.mission-card h3{margin:6px 0 2px;font:500 22px/1.15 var(--font-serif)}
.mission-card .next-step{margin:12px 0 0;font-size:12.5px;color:var(--muted)}
.mission-card .next-step b{color:var(--text)}
.checkout-summary{padding:12px;border:1px solid var(--line);border-radius:11px;background:var(--bg2)}
.checkout-summary ul{margin:8px 0 0;padding-left:18px;color:var(--muted);font-size:12px}
.checkout-summary p{margin:6px 0 0;color:var(--muted);font-size:12px;line-height:1.5}
.framework-help>summary{display:flex;align-items:center;min-height:44px;cursor:pointer;font:500 22px/1.2 var(--font-serif)}
.framework-help[open]>summary{margin-bottom:10px}
.order-benefits{margin-bottom:14px}
.order-questionnaire{margin-top:18px}
.order-questionnaire h4{margin:0 0 5px;font:600 17px/1.3 var(--font-ui)}
.order-question-list{display:grid;gap:15px;margin:16px 0}
.order-question{display:grid;gap:6px;margin:0}
.order-question>label,.order-question legend{color:var(--muted);font-size:12px;font-weight:700}
.order-question>small:not(.order-question-error){color:var(--muted);font-size:12px;line-height:1.5}
.order-choice{padding:12px;border:1px solid var(--line);border-radius:10px}
.order-choice legend{padding:0 5px}
.order-options{display:grid;gap:7px;margin-top:8px}
.order-options label{display:flex;align-items:flex-start;gap:5px;font-size:12.5px;line-height:1.4;font-weight:500}
.order-options input{margin-top:1px}
.order-question-error{color:var(--red);font-size:12px}
.context-ref{padding:9px 12px;border-left:2px solid var(--accent2);border-radius:0 8px 8px 0;background:var(--bg2);font-size:12px}

/* Support : fil de discussion */
.thread .list-row{align-items:flex-start}
.thread .list-row.mine{background:var(--surface3)}

/* Bibliothèque : barre de recherche */
.toolbox-search{display:flex;gap:10px;align-items:center;margin-bottom:10px}
.toolbox-search input{max-width:520px}
.toolbox-count{margin:0 0 12px;color:var(--muted);font-size:12px}
.tool-card[hidden]{display:none}

/* Plug & Code : lecteur de module et mise en page du Prompt Builder */
.section-title-serif,.panel-head .section-title-serif,.card .section-title-serif{margin:4px 0 0;font:500 24px/1.15 var(--font-serif);letter-spacing:-.015em}
.pc-search-bar{display:grid;gap:2px;margin-bottom:4px}
.pc-summary h2{margin:4px 0 6px;font:500 22px/1.2 var(--font-serif)}
.pc-steps{list-style:none;margin:14px 0 0;padding:0}
.pc-steps .tabs{margin:6px 0 12px}
.pc-guide .guided-steps{margin-top:10px}
.pc-card{width:100%;text-align:left;cursor:pointer}
.pc-lead{max-width:760px;margin:0 0 14px;color:var(--muted)}
.pc-note{margin:12px 0 0!important;color:var(--muted)!important;font-size:12px}
.plain-steps{margin:0 0 12px;padding-left:20px;color:var(--muted)}.plain-steps li{margin:0 0 8px}.plain-steps strong{color:var(--text)}
.pc-links{font-size:12px}.pc-links a{color:var(--accent-text)}
#pc-panel:focus{outline:none}
.pc-resume{margin-bottom:12px}
.pc-card-meta{display:flex;align-items:center;justify-content:space-between;gap:8px}.pc-fav{color:var(--amber);margin-right:6px}
.pc-reader{max-width:880px}
.pc-reader-head{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:12px}
.pc-reader>h2{margin:0 0 16px;font:500 32px/1.1 var(--font-serif);letter-spacing:-.02em}.pc-reader>h2:focus{outline:none}
.pc-content{font-size:15px;line-height:1.7;color:var(--text)}
.pc-content h2,.pc-content h3,.pc-content h4,.pc-content h5,.pc-content h6{margin:26px 0 10px;font:700 17px/1.3 var(--font-ui)}.pc-content h3{font-size:15.5px}.pc-content h4,.pc-content h5,.pc-content h6{font-size:14px}
.pc-content p,.pc-content ul,.pc-content ol{margin:0 0 12px;color:var(--muted)}.pc-content li{margin:0 0 6px}.pc-content strong{color:var(--text)}
.pc-content pre{margin:0 0 14px;padding:13px;border:1px solid #2a3135;border-radius:10px;background:#07090b;color:#c5cdd1;overflow-x:auto}.pc-content pre code{padding:0;background:none;white-space:pre}
.pc-content blockquote{margin:0 0 12px;padding:10px 14px;border-left:3px solid var(--accent2);background:var(--surface2);color:var(--muted)}
.pc-reader-actions{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-top:24px;padding-top:16px;border-top:1px solid var(--line)}
.pc-existing{padding:12px;border:1px dashed var(--line2);border-radius:12px}
.pc-guide{position:sticky;top:calc(var(--topbar) + 16px)}
.pc-result{margin-top:13px}.pc-result:focus{outline:none}
.pc-summary{display:flex;gap:18px;align-items:center}
.pc-ring{--p:0;flex:none;width:96px;height:96px;border-radius:50%;display:grid;place-items:center;background:conic-gradient(var(--accent2) calc(var(--p)*1%),var(--surface3) 0);box-shadow:inset 0 0 0 1px var(--line)}
.pc-ring span{width:74px;height:74px;border-radius:50%;display:grid;place-items:center;background:var(--surface);font-size:18px;font-weight:800}
.pc-level{display:grid;grid-template-columns:110px 1fr 44px;align-items:center;gap:10px;font-size:12px}.pc-level small{color:var(--muted);text-align:right}
.pc-bar{height:8px;border-radius:99px;background:var(--surface3);overflow:hidden}.pc-bar span{display:block;height:100%;background:var(--accent2)}
.pc-danger{max-width:560px}

/* Mode test : panneau */
.test-panel fieldset{margin:0;padding:12px;border:1px solid var(--line);border-radius:12px;display:grid;gap:6px}
.test-panel legend{padding:0 6px;color:var(--muted);font-size:9.5px;letter-spacing:.13em;text-transform:uppercase}
.test-choice{display:flex!important;align-items:center;min-height:36px;color:var(--text)!important;font-weight:500!important}

@media(max-width:1050px){.pc-guide{position:static}}
@media(max-width:780px){.onboarding{grid-template-columns:1fr}.pc-summary{flex-direction:column;align-items:flex-start}.pc-level{grid-template-columns:90px 1fr 40px}.pc-reader-actions{flex-direction:column;align-items:stretch}.toolbox-search{flex-direction:column;align-items:stretch}.toolbox-search input{max-width:none}}

.pc-architect-frame{display:block;width:100%;height:900px;border:0;margin-top:16px;background:transparent}

body.app-drawer-open{overflow:hidden}

@media(min-width:781px) and (max-width:1100px){.pc-setup .grid3{grid-template-columns:1fr}}

/* Recent views: external style required by the existing strict app CSP. */
.note.recent-views{margin:12px 0 0}
.note.product-note{margin-top:14px}

.secure-runtime-frame{display:block;width:100%;min-height:80vh;border:1px solid var(--line,#273346);border-radius:12px;margin-top:16px;background:#020617}
.secure-space{min-width:0;overflow:hidden}
.secure-directory [data-secure-select]{width:100%;text-align:left;color:inherit;font:inherit;cursor:pointer}

.signal-file{max-width:230px;width:100%;min-width:0}

/* AXDIA Agent: plan-only entry. Execution controls are intentionally absent. */
.agent-entry{display:grid;gap:18px;margin-bottom:18px;padding:22px;border-color:color-mix(in srgb,var(--accent) 38%,var(--line));background:linear-gradient(135deg,var(--accent-soft),transparent 55%),var(--surface)}
.agent-entry h2{margin:5px 0 7px;font:500 clamp(25px,3vw,34px)/1.15 var(--font-serif)}
.agent-entry p{margin:0;color:var(--muted);line-height:1.6}
.agent-entry textarea{min-height:88px;font-size:15px}
.agent-entry .form-actions small{font-size:12px;color:var(--muted)}
.agent-suggestions{display:flex;flex-wrap:wrap;gap:7px}
.agent-suggestions .btn{min-height:44px;font-size:13px}
.agent-plan ol{display:grid;gap:11px;padding-left:22px}
.agent-plan ol li{padding-left:4px}
.agent-plan ol strong,.agent-plan ol small{display:block}
.agent-plan ol small{margin-top:4px;color:var(--muted)}
.agent-plan h3{margin:20px 0 8px;font-size:16px}
.agent-plan .agent-cost{padding:12px;border:1px solid var(--line);border-radius:10px;background:var(--surface2)}
.agent-missions{list-style:none;display:grid;gap:8px;padding:0;margin:0}
.agent-missions li{padding:10px 12px;border:1px solid var(--line);border-radius:10px}
.agent-missions strong,.agent-missions small{display:block}
.agent-missions small{margin-top:4px;color:var(--muted)}
.agent-private-preview{display:block;width:100%;height:min(70vh,680px);min-height:360px;margin-top:12px;border:1px solid var(--line);border-radius:10px;background:#fff}
.agent-entry label,.agent-plan small,.agent-plan .note,.agent-entry .form-actions small,[data-agent-context] label,[data-agent-context] .note,.agent-missions small{font-size:13px}
.agent-status:not(:empty){margin:10px 0 0;padding:10px 12px;border:1px solid var(--line);border-radius:10px;background:var(--surface2);font-size:13px}
.agent-status[data-state="success"]{border-color:color-mix(in srgb,var(--green) 50%,var(--line));color:var(--text)}
.agent-status[data-state="error"]{border-color:color-mix(in srgb,var(--red) 50%,var(--line));color:var(--text)}
@media(max-width:780px){.agent-entry{padding:18px}.agent-entry .form-actions{align-items:stretch;flex-direction:column}.agent-entry .form-actions .btn{width:100%}}
