:root{font-family:Inter,system-ui,-apple-system,Arial,sans-serif;color:#e7f1ff;background:#08111e}*{box-sizing:border-box}body{margin:0;background:radial-gradient(ellipse at 90% 0%,#173654,#08111e 65%);min-height:100vh}button,input,select{font:inherit}button{cursor:pointer;color:#e4f0ff;background:#172b40;border:1px solid #36516a;border-radius:9px;padding:11px 15px}button:hover{border-color:#75c7ef}button:disabled{opacity:.55;cursor:wait}.primary{background:#6dc6f2;color:#061320;font-weight:750;border:0}.brand{font-weight:800;letter-spacing:2px;font-size:14px}.brand small{display:block;font-weight:500;letter-spacing:2.5px;font-size:9px;color:#87b5d4;margin:6px 0 0 34px}.login{min-height:100vh;display:grid;place-items:center;padding:20px}.loginbox{background:#101e30;border:1px solid #2c4861;border-radius:20px;padding:38px;width:min(100%,470px)}h1{font-size:32px;margin:10px 0 16px}h2{font-size:18px;margin:0 0 12px}.muted{color:#9db2c7;font-size:13px}#portal{min-height:100vh;display:flex}.sidebar{width:260px;flex:none;background:#0d1a2a;border-right:1px solid #284059;padding:30px 18px;display:flex;flex-direction:column;gap:42px}.sidebar nav{display:grid;gap:8px}.sidebar nav button{width:100%;text-align:left;border:0;background:transparent}.sidebar nav button.active{background:#193750;color:#85d6ff}.sidefoot{margin-top:auto;display:flex;align-items:center;justify-content:space-between;gap:8px;text-transform:capitalize}.sidefoot span{color:#85d6ff}.workspace{flex:1;min-width:0;max-width:1300px;padding:36px 42px}.workspace header{display:flex;align-items:center;justify-content:space-between;margin-bottom:32px;gap:15px}.eyebrow{font-size:11px;color:#76c6f2;letter-spacing:2px;font-weight:700}.panel{border:1px solid #2c4760;border-radius:15px;background:#111f31;padding:24px;margin-bottom:18px}.metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.metric{background:#172a40;padding:18px;border-radius:12px;display:grid;gap:9px}.metric strong{font-size:26px}.entry{display:flex;justify-content:space-between;gap:15px;align-items:center;padding:16px 0;border-bottom:1px solid #2a3e51}.entry:last-child{border:0}.entry p{margin:6px 0 0;overflow-wrap:anywhere}.actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.actions select{max-width:160px}.small{padding:8px 11px}.editor{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;align-items:end}.editor .primary{height:44px}.field{display:grid;gap:7px;margin:15px 0;color:#d8e5f3;font-size:13px}.field input,.field select,.actions select{width:100%;min-width:0;border-radius:9px;border:1px solid #38516a;padding:11px;background:#0a1625;color:#f2f7ff}input[type=file]{padding:8px}.loginbox .primary{width:100%;margin-top:12px;padding:14px}#status{position:fixed;bottom:16px;right:18px;background:#173047;border-radius:9px;padding:10px 16px;max-width:min(90vw,550px);box-shadow:0 8px 25px #0005}#status:empty{display:none}#status.bad{background:#6e2831}footer{font-size:12px;color:#7d9ab3;margin-top:30px}[hidden]{display:none!important}@media(max-width:850px){#portal{display:block}.sidebar{width:100%;gap:14px;padding:16px}.sidebar nav{display:flex;overflow-x:auto}.sidebar nav button{white-space:nowrap;width:auto}.sidefoot{margin-top:0}.workspace{padding:22px 15px}.metrics{grid-template-columns:repeat(2,1fr)}.editor{grid-template-columns:1fr}.entry{align-items:flex-start;flex-direction:column}.workspace header h1{font-size:25px}}

/* Drone Envision official identity — visual layer only */
:root{--de-orange:#ffa300;--de-cyan:#35c9e8;--de-border:#28455b}body{background:radial-gradient(ellipse at 85% -10%,#13364b 0%,#091522 55%,#07111b 100%)}.brand{letter-spacing:0;display:flex;flex-direction:column;align-items:flex-start;gap:4px}.brand .de-logo{width:min(100%,225px);height:62px;object-fit:contain;object-position:left center}.brand small{margin:0!important;letter-spacing:2.1px!important;color:#92aebf!important}.sidebar{background:linear-gradient(180deg,#0c1c2b,#081521);border-right-color:var(--de-border)}.sidebar nav button.active{background:linear-gradient(90deg,rgba(53,201,232,.17),rgba(255,163,0,.045));color:#a5ebf6;border-left:3px solid var(--de-orange)}.loginbox,.panel{border-color:#2b475a;background:linear-gradient(155deg,#112538,#0b1929)}.loginbox{box-shadow:0 24px 90px #0005;border-top:2px solid var(--de-orange)}.primary{background:linear-gradient(110deg,#32c4e4,#71dbea);color:#061b25}.primary:hover{filter:brightness(1.08)}.eyebrow{color:#fbb657}.workspace header{border-bottom:1px solid #254154;padding-bottom:23px}@media(max-width:680px){.brand .de-logo{width:175px;height:48px}}

/* Readability refinements */
:root{--muted:#b1c5d0}button:focus-visible,a:focus-visible,input:focus-visible{outline:2px solid #4bd2ed;outline-offset:2px}

/* Unified application hub: future modules use cards rather than sidebar items. */
.app-hub-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(235px,1fr));gap:14px;margin-top:18px}
.app-hub-card{border:1px solid #29465a;border-radius:13px;padding:20px;background:linear-gradient(145deg,#122b3b,#0c1b29);min-height:150px}
.app-hub-card strong{font-size:17px;color:#eaf7ff}
.app-hub-card p{line-height:1.55}
.app-launch{display:inline-block;text-decoration:none;padding:12px 18px;margin-top:8px;border-radius:8px}
.app-hub-card:focus-within{outline:2px solid #4dd9ed;outline-offset:2px}

/* Subtle Drone Envision motion — respects reduced-motion preferences */
@media (prefers-reduced-motion: no-preference) {
  .workspace,.app-hub-card,.panel,.card,.section-card {animation:de-rise .32s ease-out both}
  .app-hub-card,button,a,.nav-item,.sidebar a {transition:transform .18s ease,background-color .18s ease,border-color .18s ease,box-shadow .18s ease}
  .app-hub-card:hover {transform:translateY(-2px);border-color:#3a8299;box-shadow:0 8px 24px #0002}
  button:not(:disabled):hover,.app-launch:hover {transform:translateY(-1px)}
  button:not(:disabled):active,.app-launch:active {transform:translateY(0)}
  @keyframes de-rise {from{opacity:.6;transform:translateY(5px)}to{opacity:1;transform:translateY(0)}}
}
@media (prefers-reduced-motion: reduce) {*,*::before,*::after {animation-duration:.01ms!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}

/* Responsive motion pass: no scripted waits, no artificial transition delays. */
.login-feedback{min-height:1.4em;margin-top:12px;color:#a8d9e8;font-size:13px;line-height:1.45}
.login-feedback:empty{min-height:0;margin-top:0}
.loginbox{position:relative;overflow:hidden}
.loginbox::before{content:"";position:absolute;inset:0 0 auto;height:2px;background:linear-gradient(90deg,#ffa300,#35c9e8,transparent);pointer-events:none}
#loginForm.is-authenticating .primary{position:relative;padding-right:38px}
#loginForm.is-authenticating .primary::after{content:"";position:absolute;right:15px;top:calc(50% - 7px);width:14px;height:14px;border:2px solid #123d4a;border-right-color:transparent;border-radius:50%;animation:de-spin .65s linear infinite}
@keyframes de-spin{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:no-preference){
 .loginbox{animation:de-enter .26s ease-out both}
 #portal:not([hidden]) .sidebar{animation:de-enter .22s ease-out both}
 #portal:not([hidden]) .workspace{animation:de-enter .26s ease-out both}
 #content>.panel{animation:de-enter .24s ease-out both}
 .entry{transition:background-color .16s ease,border-color .16s ease}
 .entry:hover{background:rgba(53,201,232,.035)}
 .sidebar nav button{transition:background-color .16s ease,color .16s ease,transform .16s ease}
 .sidebar nav button:hover{transform:translateX(2px)}
 .field input,.field select{transition:border-color .16s ease,box-shadow .16s ease}
 .field input:focus,.field select:focus{border-color:#48cce5;box-shadow:0 0 0 3px rgba(53,201,232,.12)}
 @keyframes de-enter{from{opacity:.76;transform:translateY(5px)}to{opacity:1;transform:none}}
}
@media(max-width:680px){.loginbox{padding:28px 22px}.loginbox h1{font-size:27px}.workspace{padding:20px 14px}.panel{padding:19px}.entry .actions{width:100%}.entry .actions button{min-height:42px}}

/* V4 responsive form/control refinement — visual-only; no auth or storage changes */
:root{color-scheme:dark;--control-bg:#0b2132;--control-border:#365a70;--control-focus:#48d0e8}
button,input,select,textarea{font:inherit}
.field input,.field select,.actions select,.field textarea{appearance:none;-webkit-appearance:none;background-color:var(--control-bg);border:1px solid var(--control-border);color:#edf8ff;border-radius:12px;min-height:48px;padding:12px 15px;line-height:1.3;box-shadow:inset 0 1px 1px #0002;max-width:100%}
.field select,.actions select{padding-right:43px;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2378d9ed' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 15px center;background-size:16px}
.field select option,.actions select option{background:#10283a;color:#f1f8ff}
.field input:focus,.field select:focus,.actions select:focus,.field textarea:focus{outline:2px solid var(--control-focus);outline-offset:2px;border-color:var(--control-focus)}
.field input::placeholder{color:#9cb6c7}
.editor{grid-template-columns:repeat(2,minmax(0,1fr));align-items:end;column-gap:18px;row-gap:18px}
.editor>.field{min-width:0;margin:0;align-self:stretch;display:flex;flex-direction:column;justify-content:flex-end;gap:9px}
.editor>.field>span{min-height:1.3em}
.editor>.primary,.editor>button{width:100%;min-height:48px;height:auto;display:inline-flex;align-items:center;justify-content:center;text-align:center;align-self:end;margin:0}
button{display:inline-flex;align-items:center;justify-content:center;text-align:center;min-height:43px;line-height:1.25}
.sidebar nav button{justify-content:flex-start}
.actions{gap:10px}.actions button{white-space:normal}
.panel{overflow-wrap:anywhere}.entry{min-width:0}
@media(min-width:1100px){.workspace{padding:36px clamp(30px,3.2vw,52px)}}
@media(max-width:850px){.sidebar{position:relative}.sidebar nav{scrollbar-width:thin;gap:6px;padding-bottom:4px}.sidebar nav button{flex:0 0 auto;min-height:44px}.workspace header{flex-wrap:wrap}.workspace header>button{margin-left:auto}}
@media(max-width:680px){.editor{grid-template-columns:minmax(0,1fr);gap:16px}.editor>.field{margin:0}.editor>.primary,.editor>button{width:100%}.field input,.field select,.actions select{font-size:16px}.panel{padding:18px}.actions{width:100%}.actions button{flex:1 1 auto}.workspace header{align-items:flex-start}.metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.metric{padding:13px}.metric strong{font-size:22px}}
@media(max-width:390px){.metrics{grid-template-columns:1fr}.sidebar{padding:13px}.workspace{padding:16px 12px}.panel{padding:15px}}
@media(prefers-reduced-motion:no-preference){button,.field input,.field select,.actions select{transition:border-color .15s ease,box-shadow .15s ease,background-color .15s ease,transform .15s ease}.primary:active{transform:scale(.995)}}

/* Session restoration / sign-in transition: never blocks completed auth */
.session-splash[hidden]{display:none!important}
.session-splash{position:fixed;inset:0;z-index:1000;display:grid;place-items:center;padding:24px;background:radial-gradient(ellipse at 70% 18%,#10374a 0%,#091b2b 46%,#07111e 100%);color:#eaf6ff}
.session-splash-card{width:min(100%,430px);padding:38px 34px;background:#0e2436;border:1px solid #31536a;border-top:3px solid #f5a623;border-radius:22px;box-shadow:0 22px 80px #0006;text-align:center}
.session-splash-logo{display:block;width:min(100%,280px);height:auto;margin:0 auto 26px}
.session-splash-title{font-size:22px;font-weight:750;letter-spacing:-.02em}
.session-splash-subtitle{margin-top:10px;color:#a7c3d1;font-size:15px}
.session-splash-track{height:4px;overflow:hidden;border-radius:99px;background:#27445a;margin-top:28px}
.session-splash-bar{height:100%;width:40%;border-radius:99px;background:linear-gradient(90deg,#1b9bce,#60e0ee);animation:de-splash 1.15s ease-in-out infinite alternate}
@keyframes de-splash{from{transform:translateX(-100%)}to{transform:translateX(350%)}}
@media(prefers-reduced-motion:reduce){.session-splash-bar{animation:none;width:100%;opacity:.8}}
@media(max-width:480px){.session-splash-card{padding:30px 22px}.session-splash-title{font-size:20px}}

/* Account Management — test build */
.account-toolbar{display:flex;gap:12px;flex-wrap:wrap;margin:16px 0}
.account-toolbar input{flex:2;min-width:190px}
.account-toolbar select{flex:1;min-width:145px}
.account-list{display:grid;gap:8px;max-height:380px;overflow:auto;margin-bottom:10px}
.account-entry{text-align:left;white-space:normal;width:100%;padding:13px 15px;border:1px solid #31536b;background:#102536;color:#e4f4fa;border-radius:10px;cursor:pointer}
.account-entry.selected{border-color:#34c7df;background:#14384a}
.account-toggle{display:flex;align-items:center;gap:12px;padding:12px;margin:7px 0;border:1px solid #31536b;border-radius:10px;cursor:pointer}
.account-toggle input{width:18px;height:18px;accent-color:#30c3de}
@media(max-width:650px){.account-toolbar{flex-direction:column}}

.account-list .account-entry{text-align:left;display:block}.account-toolbar input,.account-toolbar select{background:#102536;color:#e8f5fc;border:1px solid #35566c;border-radius:8px;padding:12px;min-height:44px}.account-list{max-height:65vh}.account-entry.selected{border-color:#35c8e0}

.project-search{width:100%;margin:14px 0;padding:12px}.project-directory{display:grid;gap:10px}.project-entry{display:flex;flex-direction:column;align-items:flex-start;text-align:left;gap:7px;width:100%;padding:16px;background:#102536;border:1px solid #31536b;border-radius:12px;color:#e4f4fa;cursor:pointer}.project-entry:hover{border-color:#36c4d8}

/* Projects and account refinements */
.project-toolbar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:16px 0}
.project-toolbar .project-search{flex:2;min-width:190px;margin:0}
.project-toolbar select{flex:1;min-width:145px}
.project-create{margin:12px 0 20px}
.project-create[hidden]{display:none!important}
@media(max-width:650px){.project-toolbar{flex-direction:column;align-items:stretch}}

/* V8 visual system: consistent dark controls and destructive confirmations */
select,input,textarea{color-scheme:dark;background:#0b2233!important;color:#edf8ff!important;border:1px solid #386075!important;border-radius:11px!important;padding:12px 14px!important;min-height:45px;max-width:100%}select option{background:#0c2536;color:#edf8ff}input::placeholder{color:#93afbf}select:focus,input:focus,textarea:focus{outline:2px solid #43d2e9;outline-offset:1px}
.de-overlay{position:fixed;inset:0;z-index:9998;background:rgba(1,9,17,.8);backdrop-filter:blur(7px);display:grid;place-items:center;padding:16px}
.de-dialog{width:min(100%,500px);background:linear-gradient(145deg,#142e42,#091b2a);border:1px solid #35657a;border-top:3px solid #ffa300;border-radius:19px;padding:26px;box-shadow:0 28px 90px #000a}
.de-dialog h2{font-size:22px}.de-dialog .de-actions{display:flex;justify-content:flex-end;gap:10px;flex-wrap:wrap;margin-top:20px}.de-danger{background:#742c38!important;border:1px solid #b45160!important;color:#fff!important}.de-danger:hover{background:#963848!important}
@media(max-width:600px){.de-dialog{padding:19px}.de-dialog .de-actions button{flex:1}}

/* V9 interaction polish */
button,.project-entry,.row,.panel{transition:background-color .16s ease,border-color .16s ease,transform .16s ease}button:not(:disabled):active{transform:scale(.985)}.project-entry:hover{transform:translateY(-2px);border-color:#35acc9}.de-dialog{animation:deV9In .18s ease-out}@keyframes deV9In{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;transition-duration:.01ms!important}}

/* V10: full-width responsive workspace and balanced overview */
#portal{width:100%;min-height:100vh}
.workspace{width:0;flex:1 1 auto;max-width:none;min-width:0;padding:clamp(22px,2.7vw,48px) clamp(22px,3vw,56px)}
#content{width:100%;min-width:0}
#content>.panel{width:100%;min-width:0}
#content.overview-layout{display:grid;grid-template-columns:minmax(0,1fr);gap:18px;align-items:start}
#content.overview-layout>.panel{margin:0}
#content.overview-layout .metrics{grid-template-columns:repeat(4,minmax(0,1fr));gap:clamp(10px,1.2vw,20px)}
#content.overview-layout .metric{min-height:106px;justify-content:center}
#content.overview-layout .overview-projects{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,270px),1fr));gap:12px}
#content.overview-layout .overview-projects .entry{display:block;border:1px solid #29475c;border-radius:12px;background:#10283a;padding:16px;min-height:84px;transition:border-color .16s ease,transform .16s ease}
#content.overview-layout .overview-projects .entry:hover{border-color:#35c9e8;transform:translateY(-2px)}
#content.overview-layout .overview-projects .entry p{line-height:1.45}
@media(min-width:1600px){#content.overview-layout .metric{min-height:125px}.workspace{padding-left:58px;padding-right:58px}}
@media(max-width:1000px){#content.overview-layout .metrics{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:850px){.workspace{width:100%;padding:22px 16px}}
@media(max-width:480px){#content.overview-layout .metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.metric{min-width:0}}
@media(prefers-reduced-motion:reduce){#content.overview-layout .overview-projects .entry{transition:none;transform:none!important}}

/* V11 navigation placement */
.workspace>header{display:flex;align-items:center;flex-wrap:wrap;gap:12px}.workspace>header #de-app-switch{margin-left:auto}@media(max-width:740px){.workspace>header #de-app-switch{margin-left:0}}

/* V13 — account security settings */
.de-settings-form{max-width:580px;display:grid;gap:12px;margin-top:16px}.de-settings-form .field{margin:0}.de-settings-form .primary{justify-self:start;min-width:170px}.de-settings-form .muted{line-height:1.6;margin:0}.de-account-summary{display:grid;gap:5px;overflow-wrap:anywhere}.de-account-summary strong{font-size:17px}.de-text-action{border:0;background:transparent;padding:8px 0;min-height:0;color:#81dced;text-decoration:underline;text-underline-offset:4px}.de-text-action:hover{background:transparent;color:#b3eff8}@media(max-width:680px){.de-settings-form .primary{width:100%}}

/* V19: project descriptions expand as content grows */
.de-expanding-description textarea{width:100%;min-height:92px;resize:none;overflow-y:hidden;line-height:1.5;white-space:pre-wrap;overflow-wrap:anywhere}

/* V20: align creation form and provide a true client picker. */
.project-create .editor{align-items:start;grid-template-columns:repeat(2,minmax(0,1fr));}
.project-create .editor>.field{justify-content:flex-start;align-self:start;min-width:0;}
.project-create .editor>.field>span,.project-create .editor>.field>label{min-height:1.3em;}
.project-create .editor>.de-expanding-description textarea{min-height:48px;height:auto;max-height:none;}
.project-create .editor>.primary{align-self:start;margin-top:calc(1.3em + 9px);}
.de-client-picker{position:relative;z-index:5;}
.de-client-picker input{width:100%;}
.de-client-results{position:absolute;top:calc(1.3em + 9px + 48px + 5px);left:0;right:0;z-index:20;max-height:250px;overflow-y:auto;background:#10283a;border:1px solid #47718a;border-radius:12px;box-shadow:0 16px 30px #0008;padding:5px;}
.de-client-option{display:flex;flex-direction:column;align-items:flex-start;text-align:left;gap:3px;width:100%;border:0;background:transparent;border-radius:8px;padding:11px 12px;min-height:0;}
.de-client-option span{color:#a5bdcf;font-size:12px;overflow-wrap:anywhere;}
.de-client-option:hover,.de-client-option.is-active{background:#1b4659;}
.de-client-empty{padding:13px;color:#a5bdcf;font-size:13px;}
.de-client-help{color:#9db2c7;font-size:12px;min-height:0!important;}
.de-client-selected{font-size:12px;color:#79dfcb;min-height:0!important;}
@media(max-width:680px){.project-create .editor{grid-template-columns:minmax(0,1fr)}.project-create .editor>.primary{margin-top:0}}

/* V21: ensure multiline project descriptions resize and client suggestions are visible. */
.project-create .de-expanding-description textarea{display:block!important;box-sizing:border-box!important;width:100%!important;min-height:96px!important;max-height:none!important;overflow:hidden!important;resize:vertical!important;line-height:1.55!important;white-space:pre-wrap!important;}
.project-create .editor{overflow:visible!important;align-items:start!important;}
.project-create .de-client-picker{z-index:30!important;overflow:visible!important;}
.project-create .de-client-results{top:calc(100% - 17px)!important;z-index:999!important;max-height:290px!important;overflow-y:auto!important;}
.project-create .de-client-option{touch-action:manipulation;}
@media(max-width:680px){.project-create .editor{grid-template-columns:minmax(0,1fr)!important}}
