/* V7: solo pantalla. Sin imágenes nuevas, filtros ni animaciones de búsqueda. */
@media screen {
 :is(html,body)[data-ea7-theme="lime"] {
  --v7-canvas:#dceecb;
  --v7-surface:#f0f8e8;
  --v7-field:#f8fcf3;
  --v7-ink:#173d28;
  --v7-muted:#3d6348;
  --v7-edge:#94b781;
  --v7-soft:#d8efbc;
  --v7-accent:#285b20;
  --v7-primary:#31701b;
  --v7-end:#205b23;
  --v7-wash:#a7e34d70;
  --v7-alt:#4ab87135;
  --v7-top:#ffffffcf;
  --v7-shadow:#28592024;
  --v7-button:#edf8df;
  --v7-glass:#f1f9e6dc;
  --v7-danger:#b02238;
  --v7-warning:#735200;
  --v7-success:#176b37;
  --v7-canvasfx:radial-gradient(ellipse at 5% 8%,#b4f346 0,transparent 36%),radial-gradient(ellipse at 95% 35%,#63bf5f66,transparent 42%),linear-gradient(125deg,#edf7dc,#d3ecc7);
  --v7-shadowfx:inset 0 1px 0 #ffffffd9,0 8px 24px #315b2225;
 }
 :is(html,body)[data-ea7-theme="titanium"] {
  --v7-canvas:#111725;
  --v7-surface:#20273a;
  --v7-field:#192235;
  --v7-ink:#f1f5ff;
  --v7-muted:#becce6;
  --v7-edge:#596a8a;
  --v7-soft:#303e5f;
  --v7-accent:#a1dfff;
  --v7-primary:#3156bc;
  --v7-end:#6540b0;
  --v7-wash:#1598d43d;
  --v7-alt:#a074d42e;
  --v7-top:#c9eaff38;
  --v7-shadow:#03061580;
  --v7-button:#293650;
  --v7-glass:#20273aeb;
  --v7-danger:#ff9ca8;
  --v7-warning:#ffe16b;
  --v7-success:#91e7b6;
  --v7-canvasfx:radial-gradient(ellipse at 3% 8%,#1888bc66,transparent 40%),radial-gradient(ellipse at 95% 36%,#7946bc4d,transparent 42%),linear-gradient(135deg,#141c2d,#101320 55%,#25304b);
  --v7-shadowfx:inset 0 1px 0 #bddeff42,0 12px 28px #02051170,0 0 12px #4668d51a;
 }
 :is(html,body)[data-ea7-theme="opal"] {
  --v7-canvas:#edf0f7;
  --v7-surface:#fafbff;
  --v7-field:#fff;
  --v7-ink:#262943;
  --v7-muted:#545c79;
  --v7-edge:#b9c3df;
  --v7-soft:#e4e6fc;
  --v7-accent:#494da2;
  --v7-primary:#4c4eb2;
  --v7-end:#6950b3;
  --v7-wash:#71d5e83b;
  --v7-alt:#bb9ce53b;
  --v7-top:#fffffff0;
  --v7-shadow:#555e9925;
  --v7-button:#f3f3ff;
  --v7-glass:#fbfcffeb;
  --v7-danger:#af263b;
  --v7-warning:#775600;
  --v7-success:#216a43;
  --v7-canvasfx:radial-gradient(ellipse at 15% 2%,#bbf1f2a1,transparent 43%),radial-gradient(ellipse at 90% 38%,#dbc5f19c,transparent 45%),linear-gradient(145deg,#fafcff,#e9edf7 60%,#f6eefb);
  --v7-shadowfx:inset 0 1px 0 #fff,0 7px 22px #5869971c,2px 2px 0 #b8bee72e;
 }
 :is(html,body)[data-ea7-theme="graphite"] {
  --v7-canvas:#202224;
  --v7-surface:#2d3033;
  --v7-field:#242729;
  --v7-ink:#f3f4f6;
  --v7-muted:#c4c9d0;
  --v7-edge:#60666c;
  --v7-soft:#3c444f;
  --v7-accent:#b4d0ff;
  --v7-primary:#345daf;
  --v7-end:#285294;
  --v7-wash:#ffffff08;
  --v7-alt:#00000016;
  --v7-top:#ffffff18;
  --v7-shadow:#00000061;
  --v7-button:#383d42;
  --v7-glass:#303336;
  --v7-danger:#ff9ca8;
  --v7-warning:#ffe16b;
  --v7-success:#91e7b6;
  --v7-canvasfx:linear-gradient(135deg,#292c2f,#202224 64%,#26292b);
  --v7-shadowfx:inset 0 1px 0 #ffffff1f,7px 7px 16px #00000057,-3px -3px 10px #ffffff08;
 }
 :is(html,body)[data-ea7-theme="lavender"] {
  --v7-canvas:#b6b5e8;
  --v7-surface:#e7e5fa;
  --v7-field:#f3f1ff;
  --v7-ink:#2d2855;
  --v7-muted:#554e7a;
  --v7-edge:#a39aca;
  --v7-soft:#d6cef5;
  --v7-accent:#574196;
  --v7-primary:#6246b4;
  --v7-end:#493698;
  --v7-wash:#8586ec55;
  --v7-alt:#e7aae14a;
  --v7-top:#ffffffb3;
  --v7-shadow:#5144882e;
  --v7-button:#ede8fd;
  --v7-glass:#e8e4f9df;
  --v7-danger:#a82741;
  --v7-warning:#765100;
  --v7-success:#206546;
  --v7-canvasfx:radial-gradient(ellipse at 10% 8%,#8da3f5a3,transparent 44%),radial-gradient(ellipse at 95% 40%,#eaa2de80,transparent 42%),linear-gradient(145deg,#c5c3f0,#b3b4e6 58%,#d2bfe9);
  --v7-shadowfx:inset 0 1px 0 #ffffffe0,0 8px 24px #554b942b,0 0 0 1px #ffffff24;
 }

 :is(html,body).ea7-theme {
  --ea-canvas:var(--v7-canvas);--app-bg:var(--v7-canvas);--ea-surface:var(--v7-surface);--panel:var(--v7-surface);
  --ea-ink:var(--v7-ink);--text:var(--v7-ink);--ea-muted:var(--v7-muted);--muted:var(--v7-muted);
  --ea-edge:var(--v7-edge);--line:var(--v7-edge);--field:var(--v7-field);--ea-soft:var(--v7-soft);--row:var(--v7-soft);
  --ea-highlight:var(--v7-accent);--accent:var(--v7-accent);--blue:var(--v7-accent);
  --ea2-glass:var(--v7-glass);--ea2-edge:var(--v7-edge);--ea2-glow:var(--v7-shadow);--ea2-wash:var(--v7-wash);--ea2-wash-alt:var(--v7-alt);
  --ea2-title:var(--v7-ink);--ea2-top:var(--v7-top);--ea2-shade:var(--v7-shadow);--ea2-button:var(--v7-button);
  --ea3-field:var(--v7-field);--ea3-focus:var(--v7-accent);--ea3-primary:var(--v7-primary);--ea3-primary-end:var(--v7-end);
  --ea3-panel-edge:var(--v7-edge);--ea3-selection:var(--v7-soft);--ea3-danger:var(--v7-danger);
  --ea-m2-panel:var(--v7-surface);--ea-m2-text:var(--v7-ink);--ea-m2-accent:var(--v7-accent);
  color-scheme:light;color:var(--v7-ink);background:var(--v7-canvas)!important;
 }
 :is(html,body).ea7-dark {color-scheme:dark!important}
 body.ea7-theme {font-family:system-ui,"Segoe UI Variable","Segoe UI",Arial,sans-serif}
 body.ea7-theme :is(button,input,select,textarea){font-family:inherit}
 body.ea7-theme :is(#app,#content){background:transparent!important;color:var(--v7-ink)}
 body.ea7-theme .main.ea-main-v1 {background:var(--v7-canvasfx)!important;color:var(--v7-ink)}
 body.ea7-theme .sidebar {background:linear-gradient(155deg,var(--v7-wash),transparent 70%),var(--v7-surface)!important;border-color:var(--v7-edge);box-shadow:4px 0 20px var(--v7-shadow)}
 body.ea7-theme :is(.ea-main-v1>.topbar,#content .card,#content .stat,.login>.card,#modal .card,.ea-dashboard-v1>.toolbar) {
  background:linear-gradient(130deg,var(--v7-alt),transparent 70%),var(--v7-glass)!important;
  border:1px solid var(--v7-edge);border-radius:18px;box-shadow:var(--v7-shadowfx)!important;
  backdrop-filter:none!important;-webkit-backdrop-filter:none!important;
 }
 body.ea7-theme :is(.dialog,.price-menu,.date-picker-panel,.ea5-select-list,.ea-m2-options-panel,#ea-mobile-nav) {
  background:linear-gradient(140deg,var(--v7-alt),transparent 70%),var(--v7-surface)!important;
  color:var(--v7-ink);border-color:var(--v7-edge);box-shadow:var(--v7-shadowfx);
 }
 body.ea7-theme :is(h1,h2,h3,.document-total,.stat strong){color:var(--v7-ink)!important;font-family:inherit}
 body.ea7-theme :is(label,.muted,.business-footer){color:var(--v7-muted)!important}
 body.ea7-theme :is(td,th){border-color:var(--v7-edge);color:var(--v7-ink)}
 body.ea7-theme th {background:var(--v7-soft)!important;color:var(--v7-ink)!important}
 body.ea7-theme :is(input,select,textarea){color:var(--v7-ink)!important;accent-color:var(--v7-primary)}
 body.ea7-theme #theme-selector {background:var(--v7-field)!important;color:var(--v7-ink)!important;border-color:var(--v7-edge)!important}
 /* El mismo fondo blanco de apoyo que usa el modo noche original; imagen intacta. */
 body.ea7-dark :is(.brand,.document-logo) {background:#fff}
 body.ea7-theme input::placeholder,body.ea7-theme textarea::placeholder {color:var(--v7-muted)!important;opacity:1}
 body.ea7-theme :is(input,select,textarea):focus-visible {outline:2px solid var(--v7-accent);outline-offset:2px}
 body.ea7-theme button:not(.nav),body.ea7-theme .button-link {
  background:linear-gradient(150deg,var(--v7-top),transparent 65%),var(--v7-button);color:var(--v7-ink);
  border-color:var(--v7-edge);box-shadow:inset 0 1px 0 var(--v7-top),0 2px 5px var(--v7-shadow);
 }
 body.ea7-theme button.primary,body.ea7-theme .button-link.primary {
  background:linear-gradient(135deg,var(--v7-primary),var(--v7-end))!important;color:#fff!important;
  border-color:var(--v7-primary)!important;box-shadow:inset 0 1px 0 #ffffff45,0 3px 9px var(--v7-shadow);
 }
 body.ea7-theme .sidebar .nav.active {background:var(--v7-soft)!important;box-shadow:inset 3px 0 var(--v7-accent),0 2px 7px var(--v7-shadow)}
 body.ea7-theme :is(.note,.warning,.price-warning){background:var(--v7-soft);color:var(--v7-ink);border-color:var(--v7-edge)}
 body.ea7-theme :is(.error,.loss,.refund-red){color:var(--v7-danger)!important}
 body.ea7-theme :is(.profit){color:var(--v7-success)!important}
 body.ea7-theme :is(.status-cancelled,.ended12,.stock-zero12) td,body.ea7-theme #modal td.g2-stock-zero {color:var(--v7-danger)!important}
 body.ea7-theme :is(.status-credit,.ending12,.stock-one12) td,body.ea7-theme #modal td.g2-stock-one {color:var(--v7-warning)!important}
 body.ea7-theme :is(.status-delivered,.active12) td {color:var(--v7-success)!important}
 body.ea7-theme .tablewrap tbody tr:hover,body.ea7-theme .tablewrap tbody tr.selected-row {background:var(--v7-soft)!important}
 body.ea7-theme .tablewrap tbody tr.selected-row {box-shadow:inset 4px 0 var(--v7-accent)}
 body.ea7-theme .tablewrap tbody tr:focus-visible {outline-color:var(--v7-accent)}
 /* Ningún cambio de tema reconstruye formularios. Efectos limitados a color/borde. */
 body.ea7-theme :is(.ea4-enter,#modal .dialog){animation:none!important}
 body.ea7-theme button {transition:background-color 120ms ease,border-color 120ms ease,box-shadow 120ms ease}
 @media(hover:hover){body.ea7-theme button:not(:disabled):hover{border-color:var(--v7-accent);box-shadow:inset 0 1px 0 var(--v7-top),0 0 0 1px var(--v7-accent)}}
 @media(prefers-reduced-motion:reduce){body.ea7-theme button{transition:none}}
 body[data-ea7-theme="graphite"] :is(input:not([type=checkbox]):not([type=radio]),select,textarea){box-shadow:inset 3px 3px 6px #0005,inset -1px -1px 3px #ffffff0f!important}
 body[data-ea7-theme="graphite"] button:not(.nav){box-shadow:3px 3px 7px #0005,-1px -1px 3px #ffffff0f}
 body[data-ea7-theme="opal"] :is(.card,.topbar){border-top-color:#fff;border-bottom-color:#b8bbe0}
 body[data-ea7-theme="lavender"] :is(.card,.topbar){border-color:#eeeaff;box-shadow:inset 0 1px 0 #fff,0 7px 22px #52448835!important}
 /* Ancho visual, sin alterar min/max/validación. La PWA conserva Datos adicionales. */
 #document-form .ea7-validity input {width:calc(4ch + 3.2rem)!important;max-width:100%;min-width:0;box-sizing:border-box}
 @media(min-width:701px){
  html:not(.ea-mobile-app-m2) #document-form .grid3>.ea7-address {grid-column:1 / -1}
  html:not(.ea-mobile-app-m2) #document-form .ea7-document-details {display:flex;flex-wrap:wrap;align-items:end;gap:12px}
  html:not(.ea-mobile-app-m2) #document-form .ea7-document-details>.ea7-note {flex:1 1 280px;min-width:0}
  html:not(.ea-mobile-app-m2) #document-form .ea7-document-details>.ea7-validity {flex:0 0 160px;min-width:0}
  html:not(.ea-mobile-app-m2) #document-form .ea7-note input {width:100%;min-width:0}
 }
}
