/* LS-PrePost 4.7.7 web clone — measured layout.
 *
 * Reference: /data/dev/ansys2202r1-work/shots/lsprepost-main.png (1354x1016 full window,
 * 8px outer frame). Client area = abs (8,31)-(1346,1008) => 1338x977. This clone renders
 * ONLY the client area, so every coordinate below is a client coordinate
 *   client_x = abs_x - 8 , client_y = abs_y - 31
 * measured pixel-by-pixel from that capture (probe rows/cols in the recon report).
 *
 * Vertical bands (client px):
 *   0..17    menu bar #FFFFFF (ink rows 4..16, font 11px)
 *   18       #F2F2F2 line
 *   19..21   #F0F0F0 gap
 *   22       #000000 frame line (full width)
 *   23       #F0F0F0 inset row
 *   24..888  3D viewport: linear gradient #F2F2F2 -> #505082, x 3..1303
 *   889..890 #F0F0F0 inset rows
 *   891      #000000 frame line (full width)
 *   892..926 toolbar band #F0F0F0 (35px, icons are 24/21px crops)
 *   927..951 command/status field row (white inset fields, prompt ">")
 *   952      #D7D7D7 rule
 *   953..976 status row #F0F0F0 ("Fast Renderer" + size grip)
 * Horizontal: viewport x 3..1303 (1301px) | inset x1304..1305 | black line x1306 |
 *   right icon strip x1307..1337 (31px, #F0F0F0) | client edge x1337.
 */
:root {
  --lsp-bg: #F0F0F0;
  --lsp-menu-bg: #FFFFFF;
  --lsp-select: #E5F1FB;
  --lsp-line: #F2F2F2;
  --lsp-frame: #000000;
  --lsp-field: #FEFEFE;
  --lsp-field-border: #ABADB3;
  --lsp-sep: #848484;
  --lsp-text: #000000;
  --lsp-text-dim: #6B6B6B;
  --lsp-font: "DejaVu Sans", "Liberation Sans", Arial, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; width: 1338px; height: 977px; overflow: hidden; background: var(--lsp-bg); }
body {
  font-family: var(--lsp-font);
  font-size: 11px;
  color: var(--lsp-text);
  user-select: none;
  -webkit-font-smoothing: antialiased;
}
img { -webkit-user-drag: none; display: block; }
.win { position: relative; width: 1338px; height: 977px; overflow: hidden; background: var(--lsp-bg); }

/* ---------------- menu bar ---------------- */
.menubar { position: absolute; left: 0; top: 0; width: 1338px; height: 18px; background: var(--lsp-menu-bg); z-index: 30; }
.menubar .m {
  position: absolute; top: 0; height: 18px; line-height: 17px; padding: 2px 8px 0;
  font-family: "DejaVu Sans Condensed", "DejaVu Sans", sans-serif;
  font-size: 12px; color: #000; white-space: nowrap; cursor: default;
}
.menubar .m:hover, .menubar .m.open { background: var(--lsp-select); }
.menuline { position: absolute; left: 0; top: 18px; width: 1338px; height: 1px; background: var(--lsp-line); }
.menugap { position: absolute; left: 0; top: 19px; width: 1338px; height: 3px; background: var(--lsp-bg); }

/* ---------------- viewport black frame ---------------- */
.frame { position: absolute; background: var(--lsp-frame); z-index: 5; }
.fl-top { left: 1px; top: 22px; width: 1306px; height: 1px; }
.fl-bottom { left: 1px; top: 891px; width: 1306px; height: 1px; }
.fl-left { left: 1px; top: 22px; width: 1px; height: 870px; }
.fl-right { left: 1306px; top: 22px; width: 1px; height: 870px; }

/* ---------------- 3D viewport ---------------- */
.viewport {
  position: absolute; left: 3px; top: 24px; width: 1301px; height: 865px;
  background: linear-gradient(to bottom, #F2F2F2 0%, #505082 100%);
  overflow: hidden; z-index: 4;
}

/* ---------------- right icon strip ---------------- */
.rightstrip { position: absolute; left: 1307px; top: 23px; width: 31px; height: 868px; background: var(--lsp-bg); z-index: 6; }
.rightstrip .rs-btn { position: absolute; left: 0; width: 31px; cursor: default; z-index: 1; }
.rightstrip .rs-btn:hover { background: #DDEBF7; }
.rightstrip .rs-btn img { display: block; }
.rightstrip .rs-sep { position: absolute; left: 2px; width: 27px; height: 1px; background: var(--lsp-sep); }

/* ---------------- bottom toolbar ---------------- */
.toolbar { position: absolute; left: 0; top: 892px; width: 1338px; height: 35px; background: var(--lsp-bg); z-index: 8; }
.toolbar .tb-btn { position: absolute; top: 0; cursor: default; }
.toolbar .tb-btn:hover { background: #DDEBF7; }
.toolbar .tb-btn img { display: block; }
.toolbar .tb-sep { position: absolute; top: 2px; width: 1px; height: 26px; background: var(--lsp-sep); }

/* ---------------- command / message row ---------------- */
.msgrow { position: absolute; left: 0; top: 927px; width: 1338px; height: 26px; background: var(--lsp-bg); z-index: 8; }
.cmdleft {
  position: absolute; left: 1px; top: 0; width: 650px; height: 25px;
  background: var(--lsp-field); border-top: 1px solid #ECECEC; border-bottom: 1px solid #838383;
}
.cmdleft .prompt { position: absolute; left: 2px; top: 1px; font-size: 13px; line-height: 18px; color: #000; }
.cmdright {
  position: absolute; left: 653px; top: 0; width: 654px; height: 25px;
  background: #FFFFFF; border: 1px solid var(--lsp-field-border);
}
.cmdright .msg { position: absolute; left: 2px; top: 2px; font-size: 12px; line-height: 18px; color: #000; white-space: nowrap; }
.statusrule { position: absolute; left: 0; top: 952px; width: 1338px; height: 1px; background: #D7D7D7; z-index: 8; }

/* ---------------- status row ---------------- */
.statusrow { position: absolute; left: 0; top: 953px; width: 1338px; height: 24px; background: var(--lsp-bg); z-index: 8; }
.statusrow .renderersep { position: absolute; left: 1189px; top: 0; width: 1px; height: 24px; background: #D7D7D7; }
.statusrow .renderer { position: absolute; left: 1194px; top: 5px; font-size: 12px; line-height: 16px; color: #000; white-space: nowrap; }
.statusrow .grip {
  position: absolute; left: 1327px; top: 15px; width: 9px; height: 8px; opacity: .55;
  background-image: radial-gradient(#6B6B6B 0.8px, transparent 0.9px);
  background-size: 3px 3px; background-position: 0 0, 0 0;
}

/* ---------------- menu popup (LS-PrePost Qt look) ---------------- */
.qtmenu {
  background: #F0F0F0; border: 2px solid #F9F9F9; box-shadow: 2px 2px 4px rgba(0,0,0,.25);
  padding: 0; min-width: 130px; font-family: var(--lsp-font); font-size: 11px; color: #000;
}
.qtmenu .mi { height: 21px; line-height: 21px; padding: 0 8px 0 26px; position: relative; font-size: 11px; }
.qtmenu .mi:hover { background: var(--lsp-select); }
.qtmenu .mi .icon { position: absolute; left: 5px; top: 50%; margin-top: -8px; width: 16px; height: 16px; }
.qtmenu .mi .accel { position: absolute; right: 10px; top: 0; line-height: 21px; color: #000; }
.qtmenu .mi .arrow { position: absolute; right: 6px; top: 0; line-height: 21px; padding: 0; margin: 0; }
.qtmenu .mi .inf { position: absolute; right: 10px; top: 0; line-height: 21px; font-size: 9px; font-style: italic; color: #8A8A8A; }
.qtmenu .mi .arrow + .inf, .qtmenu .mi .accel + .inf { display: none; }
.qtmenu .sep { height: 8px; background: transparent; border-top: 1px solid #D8DDE2; margin: 0 4px; }
.qtmenu .mi.disabled { color: #9A9A9A; }
.qtmenu .mi.disabled .inf { color: #BDBDBD; }

/* ---------------- modal menus backdrop (from shared kit) ---------------- */
.modal-backdrop.menu { position: fixed; inset: 0; z-index: 40; }
.modal-backdrop.menu + .qtmenu, .qtmenu { z-index: 50; }

/* ---------------- explicit dynamics panel (hidden by default, real computation) ---------------- */
.dynpanel { position: absolute; left: 3px; top: 24px; width: 1301px; height: 865px;
  background: rgba(20, 24, 40, .28); z-index: 60; }
.dynpanel[hidden] { display: none; }
.dynwin { position: absolute; left: 258px; top: 46px; width: 780px; background: #F0F0F0;
  border: 2px solid #F9F9F9; box-shadow: 3px 3px 9px rgba(0,0,0,.35); }
.dynwin .dtitle { height: 24px; line-height: 24px; padding: 0 8px; background: #E4E8EC;
  border-bottom: 1px solid #ABADB3; font-size: 12px; font-weight: 700; color: #1B1B1B; }
.dynwin .dtitle .x { position: absolute; right: 6px; top: 3px; width: 18px; height: 18px;
  text-align: center; line-height: 17px; font-size: 12px; cursor: default; }
.dynwin .dtitle .x:hover { background: #C42B1C; color: #FFF; }
.dynwin .dbody { padding: 8px 10px 6px; }
.dynwin fieldset { border: 1px solid #B9B9B9; margin: 0 0 8px; padding: 4px 8px 6px; }
.dynwin legend { padding: 0 4px; font-size: 11px; color: #333; }
.dynwin .fields { display: flex; flex-wrap: wrap; gap: 4px 14px; }
.dynwin .f { display: flex; align-items: center; gap: 4px; font-size: 11px; }
.dynwin .f input { width: 76px; height: 19px; font: inherit; font-size: 11px; padding: 0 3px;
  border: 1px solid #AEB4BA; background: #FFF; }
.dynwin .btns { display: flex; gap: 6px; flex-wrap: wrap; }
.dynwin button { height: 22px; min-width: 74px; padding: 0 8px; font: inherit; font-size: 11px;
  background: #E9EBEE; border: 1px solid #AEB4BA; border-radius: 2px; cursor: default; }
.dynwin button:hover { background: #DDEBF7; }
.dynwin button.primary { background: #CCE4F7; border-color: #7EA8CE; }
.dynwin .results { width: 100%; border-collapse: collapse; font-size: 11px; background: #FFF; table-layout: fixed; }
.dynwin .results th, .dynwin .results td { border: 1px solid #C7CCD1; padding: 2px 5px; text-align: left; white-space: nowrap; overflow: hidden; }
.dynwin .results td:last-child { white-space: normal; font-size: 10px; line-height: 13px; color: #333; }
.dynwin .results th { background: #E4E8EC; font-weight: 700; }
.dynwin .results td.num { text-align: right; font-family: "DejaVu Sans Mono", monospace; }
.dynwin .results .pass { color: #0B6B2E; font-weight: 700; }
.dynwin .results .fail { color: #B00020; font-weight: 700; }
.dynwin .plotwrap { background: #FFF; border: 1px solid #B9B9B9; padding: 2px; margin-top: 6px; }
.dynwin .note { margin-top: 5px; font-size: 10px; color: #4B5B6B; line-height: 14px; }
.dynwin .dfoot { height: 26px; border-top: 1px solid #C7CCD1; padding: 3px 8px 0; text-align: right; background: #F0F0F0; }

/* boot error banner (must stay empty in normal operation) */
#boot-error { position: fixed; left: 4px; bottom: 4px; z-index: 9999; background: #FFF; color: #B00020;
  font: 11px monospace; padding: 3px 7px; border: 1px solid #B00020; white-space: pre-wrap; max-width: 1200px; }
#boot-error:empty { display: none; }
