:root {
  color-scheme: dark;
  --bg: #071017;
  --panel: #0d171d;
  --panel-2: #111e25;
  --border: #243640;
  --text: #edf1f3;
  --muted: #8c98a2;
  --accent: #f4b400;
  --accent-hover: #ffc928;
  --success: #5ecb88;
  --danger: #ff6b6b;
}
* { box-sizing: border-box; }
body { margin:0; min-height:100vh; background:radial-gradient(circle at 72% -10%,#0c2633 0,transparent 34%),linear-gradient(145deg,#071017,#08131a 48%,#061016); color:var(--text); font-family:"Segoe UI",Tahoma,Geneva,Verdana,sans-serif; }
.crm-auth-screen { position:fixed; z-index:1000; inset:0; display:grid; place-items:center; padding:24px; background:radial-gradient(circle at 70% 0,#173544 0,transparent 40%),linear-gradient(145deg,#071017,#0a151c 55%,#050b0f); }
.crm-auth-card { width:min(440px,100%); padding:32px; border:1px solid #2d4653; border-radius:18px; background:rgba(11,24,31,.96); box-shadow:0 30px 100px #000b; }
.crm-auth-brand { display:flex; align-items:center; gap:8px; margin-bottom:28px; color:#f5f7f8; font-size:28px; font-weight:850; letter-spacing:-.045em; }
.crm-auth-brand img { display:block; width:min(245px,75%); height:auto; }
.crm-auth-brand small { margin-left:5px; color:#8ca0b0; font-size:14px; font-weight:500; letter-spacing:0; }
.crm-auth-form h1 { margin-bottom:9px; font-size:30px; }
.crm-auth-form > .muted { margin-bottom:22px; line-height:1.5; }
.crm-auth-form label { display:grid; gap:7px; margin:0 0 14px; color:#cbd4d9; font-size:12px; font-weight:700; }
.crm-auth-form input { width:100%; padding:12px 13px; border:1px solid #3d515c; border-radius:9px; background:#071117; color:var(--text); outline:0; }
.crm-auth-form input:focus { border-color:var(--accent); box-shadow:0 0 0 3px rgba(244,180,0,.1); }
.crm-auth-form > button { width:100%; min-height:43px; }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
.topbar { position:sticky; z-index:100; top:0; height:62px; padding:0 20px; display:grid; grid-template-columns:188px minmax(0,1fr) auto; align-items:center; gap:20px; border-bottom:1px solid #20333e; background:rgba(7,16,23,.96); box-shadow:0 8px 30px rgba(0,0,0,.2); backdrop-filter:blur(16px); }
.brand { min-width:0; display:flex; align-items:center; gap:5px; color:#f5f7f8; text-decoration:none; font-size:26px; font-weight:850; letter-spacing:-.045em; }
.brand img { display:block; width:132px; max-width:100%; height:auto; }
.brand small { margin-left:5px; color:#8ca0b0; font-size:14px; font-weight:500; letter-spacing:0; }
.workspace-selectors { min-width:0; display:flex; align-items:center; gap:0; overflow:visible; opacity:0; pointer-events:none; }
body:has(#workspace:not(.hidden)) .workspace-selectors { opacity:1; pointer-events:auto; }
.context-selector { min-width:0; max-width:240px; flex:1 1 0; height:42px; display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap:7px; padding:0 10px; border:0; border-left:1px solid #c49300; border-radius:0; background:transparent; color:#9ba8b1; font-size:10px; font-weight:500; text-align:left; }
.context-selector-wrap { position:relative; min-width:0; flex:1 1 0; }
.context-selector-wrap > .context-selector { width:100%; }
.context-menu { position:absolute; z-index:130; top:calc(100% + 8px); left:0; width:360px; max-height:520px; overflow:hidden; padding:8px; border:1px solid #344a56; border-radius:10px; background:#0a151b; box-shadow:0 22px 70px #000c; }
.context-menu > label { height:40px; display:grid; grid-template-columns:25px 1fr; align-items:center; gap:6px; margin:0 0 7px; padding:0 9px; border:1px solid #344852; border-radius:7px; color:#b7c4cb; }
.context-menu > label span { font-size:20px; }
.context-menu > label input { width:100%; border:0; background:transparent; color:#eef2f4; outline:0; }
.context-menu button { width:100%; display:block; padding:9px 10px; border:0; border-radius:7px; background:transparent; color:#dce3e7; text-align:left; }
.context-menu button:hover,.context-menu button.selected { background:#14242c; color:#ffc400; }
.context-menu button strong,.context-menu button small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.context-menu button strong { font-size:11px; }
.context-menu button small { margin-top:3px; color:#7f8e97; font-size:9px; }
.context-menu-all { margin-bottom:6px; border-bottom:1px solid #253944 !important; border-radius:7px 7px 0 0 !important; }
.customer-options { max-height:390px; overflow-y:auto; display:grid; gap:2px; }
.customer-options-section { position:sticky; z-index:1; top:0; display:block; margin:4px 2px 2px; padding:7px 8px 5px; border-bottom:1px solid #263944; background:#0a151b; color:#7f9099; font-size:8px; font-weight:800; letter-spacing:.09em; text-transform:uppercase; }
.customer-options-section.recent { color:#d9b640; }
.project-search-status { display:block; padding:12px 10px; color:#87969e; font-size:10px; }
.project-search-status.error { color:#ff8e92; }
.context-selector strong { overflow:hidden; color:#e6ebee; font-size:12px; text-overflow:ellipsis; white-space:nowrap; }
.context-selector i { color:#d6dde1; font-style:normal; }
.context-selector:hover { background:#0d1a21; }
.connection { font-size:11px; color:#85939d; white-space:nowrap; }
.connection i { display: inline-block; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%; background: var(--success); }
.connection.pending i { background: var(--accent); }
.top-actions { display:flex; align-items:center; justify-content:flex-end; gap:14px; }
.top-search-button { width:36px; height:36px; display:grid; place-items:center; padding:0; border:0; background:transparent; color:#c9d7df; font-size:26px; font-weight:400; }
.top-search-button:hover { color:var(--accent); }
.user-avatar { width:35px; height:35px; display:flex; align-items:center; justify-content:center; padding:0; border:1px solid #b58500; border-radius:50%; background:#3a2d00; color:#ffc400; font-size:12px; font-weight:800; line-height:1; letter-spacing:0; text-align:center; text-indent:0; }
.user-avatar:hover { border-color:var(--accent-hover); background:#4a3900; }
.top-button { padding: 6px 9px; border-color: var(--border); background: transparent; color: var(--muted); font-size: 11px; }
.top-button:hover { color: var(--text); }
main { max-width:1440px; margin:0 auto; padding:44px 24px 80px; }
body:has(#workspace:not(.hidden)) main { max-width:none; margin:0; padding:22px 22px 60px 232px; transition:padding-left .2s ease; }
.search-panel { max-width: 760px; margin: 0 auto 42px; text-align: center; }
.eyebrow { margin: 0 0 7px; color: var(--accent); font-size: 11px; font-weight: 800; letter-spacing: .14em; }
h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 10px; font-size: clamp(30px, 5vw, 48px); line-height: 1.08; }
h2 { margin-bottom: 0; font-size: 22px; }
.lead, .muted { color: var(--muted); }
.search-box { display: flex; align-items: center; gap: 12px; margin-top: 25px; padding: 0 18px; height: 58px; border: 1px solid #555; border-radius: 12px; background: var(--panel); box-shadow: 0 12px 40px rgba(0,0,0,.25); }
.search-box:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(244,180,0,.12); }
.search-box span { color: var(--accent); font-size: 28px; }
.search-box input { width: 100%; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 18px; }
#searchStatus { min-height: 23px; margin-top: 10px; font-size: 13px; }
.search-results { margin-top: 8px; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: var(--panel); text-align: left; }
.search-results:empty { display: none; }
.result { width: 100%; padding: 15px 18px; display: flex; justify-content: space-between; gap: 20px; border: 0; border-bottom: 1px solid var(--border); background: transparent; color: var(--text); text-align: left; cursor: pointer; }
.result:last-child { border-bottom: 0; }
.result:hover, .result:focus-visible { background: #252525; outline: 0; }
.result strong { display: block; }
.result small { color: var(--muted); }
.workspace { display:grid; grid-template-columns:minmax(0,1fr); gap:0; align-items:start; }
.customer-card, .content-section { border: 1px solid var(--border); border-radius: 14px; background: var(--panel); }
.customer-card { position:fixed; z-index:90; top:62px; bottom:0; left:0; width:210px; padding:0; border:0; border-right:1px solid #1d303a; border-radius:0; background:#081219; transition:width .2s ease; }
.customer-card h2 { margin-bottom:10px; line-height:1.25; font-size:14px; }
.customer-card dl { margin:0 0 14px; }
.customer-card dt { margin-top:8px; color:#697983; font-size:8px; text-transform:uppercase; letter-spacing:.08em; }
.customer-card dd { margin:2px 0 0; overflow-wrap:anywhere; color:#b4c0c7; font-size:10px; }
.sidebar-toggle { position:absolute; top:22px; right:10px; width:34px; height:32px; display:grid; place-items:center; padding:0; border:1px solid #263a45; border-radius:8px; background:#0d1a21; color:#9cabb4; font-size:25px; line-height:1; transition:right .2s ease,border-color .15s,color .15s; }
.sidebar-toggle > span { display:grid; place-items:center; width:100%; height:100%; }
.sidebar-toggle > span svg { width:16px; height:16px; display:block; fill:none; stroke:currentColor; stroke-width:2.2; stroke-linecap:round; stroke-linejoin:round; transition:transform .16s ease; }
.sidebar-toggle > span.points-right svg { transform:rotate(180deg); }
.sidebar-toggle:hover { border-color:#60727d; color:#fff; }
.sidebar-navigation { display:grid; gap:4px; padding:54px 9px 12px; }
.sidebar-navigation button { width:100%; height:50px; display:flex; align-items:center; gap:13px; padding:0 14px; border:0; border-left:4px solid transparent; border-radius:7px; background:transparent; color:#c0cbd2; font-size:13px; font-weight:600; text-align:left; }
.sidebar-navigation button:hover { background:#10202a; color:#fff; }
.sidebar-navigation button.active { border-left-color:var(--accent); background:linear-gradient(90deg,rgba(244,180,0,.17),rgba(244,180,0,.06)); color:#ffc400; box-shadow:0 10px 25px rgba(0,0,0,.18); }
.sidebar-icon { width:25px; display:grid; place-items:center; color:currentColor; font-size:24px; font-weight:400; }
.sidebar-icon svg { width:23px; height:23px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.sidebar-customer-context { margin:13px 14px 58px; padding:13px; border-top:1px solid #20313b; color:#c5ced4; }
.sidebar-customer-context .eyebrow { font-size:8px; }
.sidebar-customer-context .text-link { font-size:10px; }
.sidebar-settings { position:absolute; right:12px; bottom:18px; left:12px; display:flex; align-items:center; gap:11px; padding:11px 13px; border:0; background:transparent; color:#bac5cc; font-size:12px; font-weight:600; }
.sidebar-settings:hover { background:#10202a; color:#fff; }
.sidebar-settings span { font-size:20px; }
.sidebar-settings .sidebar-settings-label { font-size:12px; }
.sidebar-customer-contacts { position:absolute; right:12px; bottom:158px; left:12px; min-height:42px; display:flex; align-items:center; gap:10px; padding:0 12px; border:1px solid #263a45; background:#0c1820; color:#c2ccd2; font-size:11px; text-align:left; }
.sidebar-customer-contacts:hover { border-color:#6b5a20; background:rgba(244,180,0,.07); color:#f0ca4d; }
.sidebar-customer-contacts .sidebar-icon { width:22px; }
.sidebar-customer-contacts .sidebar-icon svg { width:20px; height:20px; }
.sidebar-bottom-calculator { position:absolute; right:12px; bottom:108px; left:12px; min-height:42px; display:flex; align-items:center; gap:10px; padding:0 12px; border:1px solid #263a45; border-left:4px solid transparent; background:#0c1820; color:#c2ccd2; font-size:11px; font-weight:600; text-align:left; }
.sidebar-bottom-calculator:hover { border-color:#6b5a20; background:rgba(244,180,0,.07); color:#f0ca4d; }
.sidebar-bottom-calculator.active { border-left-color:var(--accent); background:linear-gradient(90deg,rgba(244,180,0,.17),rgba(244,180,0,.06)); color:#ffc400; box-shadow:0 10px 25px rgba(0,0,0,.18); }
.sidebar-bottom-calculator .sidebar-icon { width:22px; }
.sidebar-bottom-calculator .sidebar-icon svg { width:20px; height:20px; }
.sidebar-firmao-connection { position:absolute; right:25px; bottom:66px; left:25px; display:flex; align-items:center; min-height:30px; padding:0 2px; border-bottom:1px solid #20313b; font-size:10px; }
body.sidebar-collapsed:has(#workspace:not(.hidden)) main { padding-left:94px; }
body.sidebar-collapsed .customer-card { width:72px; }
body.sidebar-collapsed .sidebar-toggle { right:19px; }
body.sidebar-collapsed .sidebar-navigation button { justify-content:center; gap:0; padding:0; }
body.sidebar-collapsed .sidebar-navigation button > span:last-child { display:none; }
body.sidebar-collapsed .sidebar-settings { justify-content:center; padding-inline:0; }
body.sidebar-collapsed .sidebar-settings-label { display:none; }
body.sidebar-collapsed .sidebar-customer-contacts { right:12px; left:12px; justify-content:center; padding:0; }
body.sidebar-collapsed .sidebar-customer-contacts-label { display:none; }
body.sidebar-collapsed .sidebar-bottom-calculator { right:12px; left:12px; justify-content:center; padding:0; }
body.sidebar-collapsed .sidebar-bottom-calculator-label { display:none; }
body.sidebar-collapsed .sidebar-firmao-connection { right:20px; left:20px; justify-content:center; padding:0; font-size:0; }
body.sidebar-collapsed .sidebar-firmao-connection i { margin-right:0; }
.text-link { color: var(--accent); text-decoration: none; font-size: 14px; font-weight: 700; }
.offer-actions { display: grid; justify-items: end; gap: 5px; }
.vision-link { padding: 6px 9px; border-color: #5a4813; background: rgba(244,180,0,.08); color: var(--accent); font-size: 11px; }
.content { min-width:0; display:grid; gap:18px; }
.content-section { padding:22px; }
.workspace .clients-section,.workspace .projects-section,.workspace .offers-section,.workspace .standalone-calculator-section,.workspace #visionEditor { display:none; }
.workspace.view-clients .clients-section,.workspace.view-projects .projects-section,.workspace.view-offers .offers-section,.workspace.view-orders .offers-section,.workspace.view-invoices .offers-section { display:block; }
.workspace.view-calculator .standalone-calculator-section { display:block; }
.workspace.view-offers #visionEditor:not(.hidden) { display:block; }
.workspace.view-offers:has(#visionEditor:not(.hidden)) .offers-section { display:none; }
.workspace.view-offers:has(#visionEditor:not(.hidden)) .content { gap:0; }
.standalone-calculator-section { padding:0; overflow:hidden; }
.standalone-calculator-header { display:flex; align-items:center; justify-content:space-between; gap:20px; margin:0; padding:20px 22px; border-bottom:1px solid #263a45; }
.standalone-calculator-header h2 { margin:3px 0 5px; }
.calculator-header-controls,.calculator-dialog-controls { display:flex; align-items:center; gap:10px; }
.calculator-header-controls label,.calculator-dialog-controls label { display:grid; gap:4px; margin:0; color:#83939c; font-size:9px; font-weight:800; text-transform:uppercase; letter-spacing:.06em; }
.calculator-header-controls select,.calculator-dialog-controls select { min-width:260px; height:38px; padding:0 34px 0 11px; border:1px solid #3a505b; border-radius:8px; background:#0a151b; color:#edf2f4; outline:none; }
.calculator-header-controls select:focus,.calculator-dialog-controls select:focus { border-color:#c99a00; box-shadow:0 0 0 3px rgba(244,180,0,.08); }
.standalone-calculator-results { display:grid; grid-template-columns:repeat(3,minmax(130px,1fr)) minmax(220px,1.5fr); gap:9px; padding:14px 22px; background:#0b171d; border-bottom:1px solid #263a45; }
.standalone-calculator-results > span { padding:10px 12px; border:1px solid #2c414c; border-radius:8px; background:#0e1b22; }
.standalone-calculator-results small,.standalone-calculator-results strong { display:block; }
.standalone-calculator-results small { margin-bottom:4px; color:#71818a; font-size:8px; }
.standalone-calculator-results strong { color:#edf2f4; font-size:12px; }
.standalone-calculator-state { border-color:#67581e !important; }
.standalone-calculator-state strong { color:#f0c54c; font-size:10px; }
.standalone-calculator-frame { display:block; width:100%; height:680px; border:0; background:#111; }
.calculator-offer-dialog form { width:min(600px,calc(100vw - 36px)); }
.calculator-offer-dialog select { width:100%; }
.workspace .clients-section { width:100%; max-width:none; margin:0; text-align:left; }
.workspace .clients-section h1 { font-size:clamp(30px,4vw,46px); }
.workspace .clients-section #search-title,
.workspace .projects-section .section-header h2,
.workspace .offers-section .section-header h2 {
  display:inline-block;
  margin:0;
  padding:8px 14px 9px;
  border-radius:4px;
  background:linear-gradient(135deg,#e4a900,#f4b400);
  box-shadow:0 8px 22px rgba(244,180,0,.14);
  color:#111820;
  font-size:18px;
  font-weight:700;
  line-height:1;
  letter-spacing:.02em;
  text-transform:uppercase;
  text-shadow:none;
}
.workspace .clients-section #search-title { font-size:20px; }
.clients-header { margin-bottom:0; }
.section-title-block { display:flex; flex-direction:column; align-items:flex-start; gap:7px; }
.section-context-label { display:block; color:#91a0a9; font-size:11px; font-weight:500; }
.workspace .clients-section .search-box { margin-top:24px; }
.workspace .clients-section .search-results { max-height:480px; overflow:auto; border-radius:9px; }
.customer-list-header,.workspace .clients-section .result { min-width:720px; display:grid; grid-template-columns:42px minmax(240px,1.65fr) minmax(120px,.75fr) minmax(145px,.8fr) 82px; align-items:center; gap:12px; }
.customer-list-header { position:sticky; z-index:2; top:0; min-height:42px; padding:0 16px; border-bottom:1px solid #2b414c; background:#0b181f; color:#8fa0aa; font-size:9px; font-weight:800; letter-spacing:.08em; }
.workspace .clients-section .result { min-height:63px; padding:9px 16px; border-bottom:1px solid #21343e; background:#0d181e; }
.workspace .clients-section .result:hover { background:#12232b; }
.customer-row-number { width:27px; height:27px; display:grid; place-items:center; border-radius:6px; background:#283239; color:var(--accent); font-size:11px; font-weight:800; }
.customer-row-name,.customer-row-name strong,.customer-row-name small { min-width:0; display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.customer-row-name strong { color:#edf2f4; font-size:12px; }
.customer-row-name small,.customer-row-city,.customer-row-id { color:#84949e; font-size:10px; }
.customer-row-name small:empty { display:none; }
.customer-row-open { display:flex; align-items:center; justify-content:flex-end; gap:8px; color:#ffc400; font-size:10px; font-weight:800; }
.customer-row-open i { font-size:15px; font-style:normal; }
.customer-load-more { width:100%; min-height:45px; border:0; border-top:1px solid #273c47; border-radius:0; background:#0a151b; color:#ffc400; font-size:11px; }
.customer-load-more:hover { background:#12232b; }
.customer-load-more small { margin-left:7px; color:#7e8f99; }
.customer-list-empty { margin:12px; }
.section-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.section-hint { display: block; margin-top: 5px; color: var(--muted); }
.actions { display: flex; gap: 9px; }
button { border-radius: 8px; border: 1px solid transparent; padding: 10px 15px; font-weight: 700; cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .45; }
.primary { background: var(--accent); color: #111; }
.primary:hover:not(:disabled) { background: var(--accent-hover); }
.secondary { border-color: var(--border); background: var(--panel-2); color: var(--text); }
.projects-section .section-header h2 { font-size:18px; letter-spacing:.02em; }
.project-toolbar { display:grid; grid-template-columns:minmax(280px,1fr) repeat(3,auto); gap:10px; align-items:center; margin:20px 0 16px; }
.document-toolbar { display:grid; grid-template-columns:minmax(280px,1fr) repeat(3,auto); gap:10px; align-items:center; margin:18px 0 12px; }
.document-search { width:100%; }
.customer-toolbar { display:grid; grid-template-columns:minmax(280px,1fr) repeat(3,auto); gap:10px; align-items:center; margin:24px 0 10px; }
.customer-directory-search { width:100%; }
.project-search { min-width:0; height:36px; display:grid; grid-template-columns:24px minmax(0,1fr) 24px; align-items:center; gap:4px; margin:0; padding:0 9px; border:1px solid #40545f; border-radius:7px; background:#0a151b; }
.project-search:focus-within { border-color:#718792; box-shadow:0 0 0 2px rgba(117,147,163,.1); }
.project-search > span { color:#b8c9d2; font-size:19px; }
.project-search input { width:100%; border:0; background:transparent; color:#eef2f4; outline:0; font-size:11px; }
.project-search button { width:24px; height:24px; padding:0; border:0; background:transparent; color:#aab8c0; font-size:18px; }
.project-filter { min-width:92px; height:36px; display:flex; align-items:center; justify-content:center; gap:8px; padding:0 10px; border:1px solid #283e49; border-radius:7px; background:#0b161c; color:#aebbc2; font-size:9px; font-weight:650; }
.project-filter strong { min-width:19px; height:19px; display:grid; place-items:center; padding:0 5px; border-radius:999px; background:#142630; color:#cbd6dc; font-size:8px; }
.project-filter.active { border-color:#8a6d13; background:rgba(244,180,0,.1); color:#f4c744; }
.project-filter.active strong { background:rgba(244,180,0,.16); color:#ffd35c; }
.project-grid { display:grid; gap:12px; overflow-x:auto; border:0; border-radius:9px; background:transparent; }
.project-list-header,.project { min-width:900px; display:grid; grid-template-columns:34px minmax(190px,1.5fr) minmax(150px,1fr) 110px 105px 105px 140px; align-items:center; gap:10px; }
.project-list-header { min-height:45px; padding:0 14px; border:1px solid #263a45; border-radius:8px; background:#0b181f; color:#8fa0aa; font-size:8px; font-weight:800; letter-spacing:.07em; }
.project { width:100%; min-height:77px; padding:10px 14px; border:1px solid #263a45; border-radius:10px; background:linear-gradient(100deg,rgba(244,180,0,.035),#111e25 36%,#0d181e 100%); box-shadow:0 5px 16px rgba(0,0,0,.16); color:var(--text); font-family:"Segoe UI",Tahoma,Geneva,Verdana,sans-serif; font-size:10px; font-weight:400; text-align:left; cursor:pointer; transition:border-color .2s ease,background .2s ease,box-shadow .2s ease,transform .2s ease; }
.project:hover { border-color:rgba(244,180,0,.55); background:linear-gradient(100deg,rgba(244,180,0,.075),#15262e 38%,#102029 100%); box-shadow:0 12px 28px rgba(0,0,0,.3),0 0 0 1px rgba(244,180,0,.06); transform:translateY(-2px); }
.project.selected { border-color:#3a515d; background:linear-gradient(100deg,rgba(244,180,0,.055),#132129 42%,#0e1a21 100%); box-shadow:0 7px 20px rgba(0,0,0,.22); }
.project-number { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 6px; background: #303030; color: var(--accent); font-size: 12px; font-weight: 800; }
.project-body { min-width: 0; }
.project strong { display:block; margin-bottom:2px; line-height:1.2; }
.project-body strong,.offer-name-cell strong { font-family:"Segoe UI",Tahoma,Geneva,Verdana,sans-serif; font-size:13px; font-weight:700; line-height:1.25; letter-spacing:0; }
.project small { display: block; overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; }
.project-customer,.project-offers,.project-activity { min-width:0; }
.project-customer strong,.project-customer small,.project-offers strong,.project-offers small,.project-activity strong,.project-activity small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.project-customer strong,.project-offers strong,.project-activity strong { color:#a6b4bc; font-family:"Segoe UI",Tahoma,Geneva,Verdana,sans-serif; font-size:10px; font-weight:400; line-height:1.25; letter-spacing:0; }
.project-customer small,.project-offers small,.project-activity small { margin-top:3px; color:#8d9aa3; font-size:9px; }
.project-offers small { color:#8bc9ef; text-decoration:underline; }
.project-status { min-height:33px; display:inline-flex; align-items:center; justify-content:center; gap:7px; padding:0 10px; border:1px solid transparent; border-radius:6px; font-size:10px; font-weight:800; white-space:nowrap; }
.project-status i { width:8px; height:8px; border-radius:50%; background:currentColor; box-shadow:0 0 8px currentColor; }
.project-status.open { border-color:#12622d; background:#0c5a28; color:#54ee80; }
.project-status.closed { border-color:#6c282b; background:#59151a; color:#ff7075; }
.project-actions { display:flex; align-items:center; justify-content:flex-end; gap:8px; white-space:nowrap; }
.project-open { min-width:94px; height:36px; display:flex; align-items:center; justify-content:center; gap:13px; padding:0 12px; border:1px solid #d29b00; background:transparent; color:#ffc400; font-size:10px; }
.project-open:hover { background:rgba(244,180,0,.08); }
.project-open span { font-size:16px; }
.project-more { width:36px; height:36px; padding:0; border:1px solid #314751; background:#0a151b; color:#d5dfe4; font-size:20px; text-decoration:none; }
.project-list-footer { display:flex; justify-content:space-between; padding:16px 8px 0; color:#adb8bf; font-size:11px; }
.project-arrow { color: var(--accent); font-size: 11px; }
.rename-project { color: var(--muted); font-size: 11px; text-decoration: underline; }
.rename-project:hover, .rename-project:focus { color: var(--text); outline: 0; }
.empty { padding: 24px; border: 1px dashed var(--border); border-radius: 10px; color: var(--muted); text-align: center; }
.document-search-status { margin:-5px 2px 10px; color:#8fa0aa; font-size:9px; }
.document-search-status::before { content:'⌕'; margin-right:6px; color:#d6a817; }
.document-no-results { display:grid; justify-items:center; gap:8px; }
.document-no-results strong { color:#dbe3e7; }
.document-no-results small { color:#8998a1; }
.document-no-results button { margin-top:4px; }
.offers-list { display:grid; gap:13px; }
.offer-list-header,.offer { min-width:900px; grid-template-columns:34px minmax(120px,1.4fr) minmax(110px,1fr) 105px 78px minmax(135px,1.1fr) 90px 90px 100px; gap:11px; }
.offer-list-header.without-status,.offer.without-status { grid-template-columns:34px minmax(150px,1.5fr) minmax(130px,1.1fr) 120px 90px 100px 100px 105px; }
.offer-list-header { display:grid; align-items:center; min-height:40px; margin-bottom:8px; padding:0 17px; border:1px solid #263a45; border-radius:8px; background:#0b181f; color:#8fa0aa; font-size:8px; font-weight:800; letter-spacing:.07em; }
.offer-family { overflow:hidden; border:1px solid #263a45; border-radius:10px; background:#0d181e; box-shadow:0 5px 16px rgba(0,0,0,.16); transition:border-color .2s ease,box-shadow .2s ease,transform .2s ease; }
.offer-family.single:hover { border-color:rgba(244,180,0,.55); box-shadow:0 12px 28px rgba(0,0,0,.3),0 0 0 1px rgba(244,180,0,.06); transform:translateY(-2px); }
.offer-family > header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 17px; border-bottom: 1px solid var(--border); background: #202020; }
.offer-family > header div { display: flex; align-items: center; gap: 10px; }
.offer-family > header span, .history-label { color: var(--accent); font-size: 9px; font-weight: 900; letter-spacing: .09em; }
.offer-family > header small { color: var(--muted); }
.offer-family > header .family-header-actions { justify-content: flex-end; }
.history-toggle { padding: 6px 9px; border-color: #555; background: #292929; color: #ddd; font-size: 10px; }
.history-toggle:hover { border-color: var(--accent); color: var(--accent); }
.offer-history.hidden { display: none; }
.offer-family.single > header { display: none; }
.offer.deleted-firmao { border-left:3px solid #d65b5b; background:linear-gradient(90deg,rgba(155,48,48,.09),transparent 28%); }
.offer.deleted-firmao .status.deleted { color:#ff8f8f; border-color:#6f3b3b; background:rgba(190,62,62,.12); }
.recreate-offer { padding:6px 9px; border:1px solid #6e5414; border-radius:7px; background:rgba(244,180,0,.09); color:var(--accent); font-size:10px; font-weight:750; }
.recreate-offer:hover { background:var(--accent); color:#171717; }
.offer { display:grid; align-items:center; padding:15px 17px; border-bottom:1px solid var(--border); cursor:pointer; transition:background .2s ease,box-shadow .2s ease; }
.document-number { width:30px; height:30px; }
.offer:hover { background:#13232b; box-shadow:none; }
.offer:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.offer:last-child { border-bottom: 0; }
.offer.current { background:linear-gradient(100deg,rgba(244,180,0,.045),#111e25 36%,#0d181e 100%); }
.offer.current:hover { background:linear-gradient(100deg,rgba(244,180,0,.11),#15262e 38%,#102029 100%); }
.offer.historical { opacity: .58; background: #181818; }
.offer.historical:hover { opacity: .9; }
@media (prefers-reduced-motion: reduce) {
  .offer-family,.offer,.project { transition:none; }
  .offer-family.single:hover,.project:hover { transform:none; }
}
.history-label { padding: 8px 17px; border-bottom: 1px solid var(--border); color: #777; background: #171717; }
.version-state { display: inline-block; margin-right: 5px; padding: 4px 7px; border-radius: 999px; font-size: 9px; font-weight: 900; }
.version-state.current { color: #111; background: var(--accent); }
.version-state.history { color: #aaa; border: 1px solid #4a4a4a; }
.offer-actions { display: grid; justify-items: end; gap: 5px; }
.restore-version { padding: 5px 8px; border-color: #555; background: transparent; color: #bbb; font-size: 10px; }
.offer strong, .offer small { display: block; }
.offer small { margin-top: 3px; color: var(--muted); }
.offer-name-cell,.offer-customer-cell,.offer-number-cell,.offer-date-cell { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.offer-customer-cell,.offer-number-cell,.offer-date-cell { color:#a6b4bc; font-size:10px; }
.offer-status-cell { display:flex; flex-wrap:wrap; align-items:center; gap:4px; }
.money { text-align: right; white-space: nowrap; }
.offer-net strong,.offer-gross strong { font-size:11px; }
.document-pagination { display:flex; align-items:center; justify-content:space-between; gap:16px; padding:14px 6px 2px; color:#91a0a9; font-size:10px; }
.document-pagination > div { display:flex; align-items:center; gap:5px; }
.document-pagination button { width:30px; height:30px; display:grid; place-items:center; padding:0; border:1px solid #2d424d; background:#0b171d; color:#c6d1d7; font-size:10px; }
.document-pagination button:hover:not(:disabled),.document-pagination button.active { border-color:#9d7a12; background:rgba(244,180,0,.11); color:#ffd252; }
.document-pagination i { padding:0 2px; color:#677781; font-style:normal; }
.status { display: inline-block; padding: 5px 8px; border-radius: 999px; background: #333; font-size: 11px; white-space: nowrap; }
.status.open { color: #9be7b7; background: rgba(94,203,136,.12); }
.status.closed { color: #bbb; background: #303030; }
.type-badge { display: inline-block; margin-right: 4px; padding: 5px 8px; border: 1px solid #5a4813; border-radius: 999px; color: var(--accent); font-size: 11px; white-space: nowrap; }
.vision-header { align-items:flex-start; gap:24px; margin:0; padding:22px; border:1px solid #263944; border-radius:14px; background:linear-gradient(115deg,#10171c 0%,#0e181e 58%,#0b151b 100%); box-shadow:0 18px 48px rgba(0,0,0,.2); }
.vision-title-block { min-width:240px; }
.vision-header h1 { margin:0 0 3px; font-size:27px; line-height:1.05; letter-spacing:-.035em; }
.vision-header h2 { margin:0 0 5px; color:#f4f6f7; font-size:18px; letter-spacing:.01em; }
.vision-header p { margin:0; color:#8e9aa4; }
.version-create { min-height:36px; padding:8px 12px; border-color:#354752; background:#101a20; font-size:11px; }
.version-create:hover { border-color:var(--accent); color:var(--accent); }
.version-control-panel { display:flex; flex-wrap:wrap; align-items:center; justify-content:flex-end; gap:8px; }
.vision-wide { width:100%; margin-left:0; }
#visionEditor { overflow:visible; padding:0; border:0; background:transparent; box-shadow:none; }
.version-switcher { display:flex; align-items:center; gap:8px; padding:3px; border:1px solid #263844; border-radius:10px; background:#0c151a; }
.version-bar-label { color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .08em; }
.version-control-panel .version-bar-label { display:none; }
.version-tabs { display: flex; gap: 6px; }
.version-tab { min-width:46px; min-height:30px; display:flex; align-items:center; justify-content:center; gap:5px; padding:6px 10px; border-color:transparent; background:transparent; color:#cfd5da; font-size:11px; }
.version-tab small { color: var(--muted); font-size: 9px; font-weight: 500; }
.version-tab.active { border-color:var(--accent); background:var(--accent); color:#12171a; box-shadow:0 0 18px rgba(244,180,0,.12); }
.version-tab.current-version { background:rgba(244,180,0,.09); }
.version-tab.active.current-version { background:var(--accent); }
.version-tab small { margin-left: 3px; color: var(--accent); }
.version-tab.deleted-version { border-color:#6a3b3d; color:#ff9b9e; background:rgba(194,55,61,.08); }
.version-tab.deleted-version small { color:#ff777c; }
.editing-strip { display:none; }
.editing-strip span { color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .06em; }
.editing-strip strong:last-child { color: var(--muted); font-weight: 600; }
.editing-strip-actions { display:flex; align-items:center; gap:7px; margin-left:auto; }
.offer-files-section { margin:14px 0 22px; padding:14px 16px; border:1px solid #263944; border-radius:12px; background:linear-gradient(135deg,#111a20,#0f171c); }
.deleted-offers-vault { margin-top:16px; padding-top:12px; border-top:1px solid #30343a; }
.deleted-offers-toggle { padding:7px 10px; border:1px solid #474c52; border-radius:8px; background:#181a1d; color:#8f969e; font-size:10px; }
.deleted-offers-toggle:hover { border-color:#6a7078; color:#d2d5d8; }
.deleted-offers-list { margin-top:10px; opacity:.78; }
.offer-files-section > header { display:flex; align-items:center; justify-content:space-between; gap:16px; }
.offer-files-section > header div { display:grid; gap:2px; }
.offer-files-section > header strong { color:#e7e9eb; font-size:13px; }
.offer-files-section > header span { color:#818892; font-size:10px; }
.offer-files-count { display:grid; place-items:center; min-width:25px; height:25px; padding:0 7px; border:1px solid #4d5157; border-radius:999px; color:#d8dade !important; font-weight:800; }
.offer-files-drop { display:flex; align-items:center; justify-content:center; gap:8px; min-height:52px; margin-top:11px; border:1px dashed #50565e; border-radius:9px; color:#858c95; cursor:pointer; }
.offer-files-drop:hover, .offer-files-drop.dragging { border-color:var(--accent); background:rgba(244,180,0,.05); }
.offer-files-drop input { position:absolute; width:1px; height:1px; opacity:0; pointer-events:none; }
.offer-files-drop strong { color:#e5e7e9; font-size:11px; }
.offer-files-drop span { font-size:10px; }
.offer-files-list { display:grid; gap:6px; margin-top:9px; }
.offer-file-row { display:grid; grid-template-columns:34px minmax(0,1fr) auto auto; align-items:center; gap:10px; padding:7px 9px; border:1px solid #30353b; border-radius:8px; background:#1d2024; }
.offer-file-kind { display:grid; place-items:center; width:34px; height:30px; border-radius:6px; background:#292d32; color:#d3b75d; font-size:8px; font-weight:900; }
.offer-file-row strong, .offer-file-row small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.offer-file-row strong { color:#dfe2e5; font-size:11px; }
.offer-file-row small { margin-top:2px; color:#777f88; font-size:9px; }
.offer-file-open { padding:5px 8px; border:0; background:transparent; color:var(--accent); font-size:10px; font-weight:750; }
.offer-files-section > header .offer-files-header-actions { display:flex; align-items:center; gap:8px; }
.gallery-open-button { min-height:36px; padding:7px 11px; border-color:#354752; background:#101a20; color:#e0e3e6; font-size:10px; }
.gallery-open-button:hover { border-color:var(--accent); color:var(--accent); }
.version-info-trigger { position:relative; min-height:36px; display:flex; align-items:center; gap:7px; padding:6px 10px; border:1px solid #354752; border-radius:8px; background:#101a20; color:#c4c8cd; font-size:10px; font-weight:750; }
.version-info-trigger:hover { border-color:var(--accent); color:var(--accent); }
.version-control-panel > #versionInfoButton { display:none !important; }
.firmao-refresh-trigger { min-width:72px; justify-content:center; }
.firmao-refresh-icon { display:grid; place-items:center; width:15px; height:15px; color:#65bdf4; }
.firmao-refresh-icon svg { width:15px; height:15px; fill:none; stroke:currentColor; stroke-width:1.9; stroke-linecap:round; stroke-linejoin:round; }
.firmao-refresh-trigger.is-syncing .firmao-refresh-icon { animation:spin 1s linear infinite; }
.firmao-refresh-trigger:disabled { opacity:.62; cursor:wait; }
.firmao-sync-block { display:flex; align-items:center; justify-content:center; gap:7px; }
.firmao-sync-block > small { color:#38d77a; font-size:8px; white-space:nowrap; }
.version-info-symbol { display:grid; place-items:center; width:17px; height:17px; border:1px solid currentColor; border-radius:50%; font:700 10px/1 Georgia,serif; }
.version-info-trigger.attention::after { content:''; position:absolute; top:-3px; right:-3px; width:8px; height:8px; border:2px solid #202020; border-radius:50%; background:var(--accent); }
.version-info-dialog { width:min(980px,calc(100vw - 34px)); padding:0; border:1px solid #3b4046; border-radius:14px; background:#17191b; color:var(--text); box-shadow:0 28px 90px #000b; }
.version-info-dialog::backdrop { background:rgba(0,0,0,.72); backdrop-filter:blur(3px); }
.version-info-dialog-header { display:flex; align-items:center; justify-content:space-between; padding:20px 22px 14px; border-bottom:1px solid #30343a; }
.version-info-dialog-header h2 { margin:2px 0 0; font-size:20px; }
.new-version-dialog { width:min(680px,calc(100vw - 34px)); }
.new-version-dialog form { margin:0; }
.new-version-content { display:grid; gap:14px; padding:20px 22px; }
.new-version-content label { margin:0; color:#e6e8ea; font-size:12px; font-weight:750; }
.new-version-content textarea { width:100%; margin-top:7px; }
.version-files-choice { display:grid; grid-template-columns:1fr 1fr; gap:9px; margin:0; padding:0; border:0; }
.version-files-choice legend { grid-column:1/-1; margin-bottom:1px; color:#aeb4bb; font-size:10px; font-weight:800; letter-spacing:.06em; text-transform:uppercase; }
.version-files-choice label { display:flex; align-items:flex-start; gap:9px; min-height:68px; padding:11px 12px; border:1px solid #3a4047; border-radius:9px; background:#1c1f22; cursor:pointer; }
.version-files-choice label:has(input:checked) { border-color:var(--accent); background:rgba(244,180,0,.07); box-shadow:inset 3px 0 0 var(--accent); }
.version-files-choice input { margin-top:2px; accent-color:var(--accent); }
.version-files-choice span,.version-files-choice strong,.version-files-choice small { display:block; }
.version-files-choice strong { color:#eef0f2; font-size:11px; }
.version-files-choice small { margin-top:4px; color:#8c949d; font-size:9px; line-height:1.4; }
.new-version-history { padding:12px 13px; border:1px solid #3c4147; border-radius:9px; background:#1c1f22; }
.new-version-history strong { color:#d9bc61; font-size:11px; }
.new-version-history p { margin:5px 0 0; color:#9299a2; font-size:10px; line-height:1.45; }
.new-version-dialog footer { display:flex; justify-content:flex-end; gap:9px; padding:0 22px 20px; }
.dialog-close { display:grid; place-items:center; width:34px; height:34px; padding:0; border:1px solid #3c4147; border-radius:9px; background:#22252a; color:#cdd1d5; font-size:22px; }
.dialog-close:hover { border-color:#6a717a; color:#fff; }
.items-header { display:flex; align-items:center; justify-content:space-between; gap:20px; margin:58px 0 18px; }
.items-heading { display: flex; align-items: center; gap: 16px; }
.items-heading-marker { width:8px; height:42px; border-radius:5px; background:linear-gradient(180deg,#ffc400,#e99f00); box-shadow:0 0 20px rgba(244,180,0,.16); }
.items-header h3 { margin:0 0 4px; font-size:24px; letter-spacing:-.025em; }
.items-header p { margin: 0; color: #9aa0a9; font-size: 13px; }
.items-header .primary { padding: 12px 20px; border-radius: 11px; font-size: 13px; }
.items-header-actions { display:flex; align-items:center; gap:9px; }
.profit-visibility-button { min-height:41px; display:inline-flex; align-items:center; gap:7px; padding:0 13px; border-color:#344852; border-radius:10px; background:#0d181f; color:#aeb9c0; font-size:10px; font-weight:750; }
.profit-visibility-button [data-profit-icon] { color:#42dd78; font-size:15px; line-height:1; }
.profit-visibility-button:hover,.profit-visibility-button.active { border-color:#297747; color:#e7f5ec; }
.profit-visibility-button.active { background:rgba(39,185,91,.07); }
.vision-items { min-width: 0; }
.vision-table-scroll { overflow-x: auto; }
.vision-table { min-width:1480px; overflow:hidden; border:1px solid #243742; border-radius:13px; background:#0e171c; box-shadow:0 18px 48px rgba(0,0,0,.16); }
.vision-table-header, .vision-table-row { display:grid; grid-template-columns:42px minmax(270px,1.8fr) 96px 135px 112px 105px 112px 115px 82px 105px 180px; gap:12px; align-items:center; }
.vision-table-header { padding:13px 16px; border-bottom:1px solid #263944; background:#101d24; color:#97a3ac; font-size:9px; font-weight:800; letter-spacing:.075em; }
.vision-table-header small { color:#70767e; font-size:7px; font-weight:750; letter-spacing:.06em; }
.vision-table-row { min-height:78px; margin:0; padding:10px 16px; border:0; border-bottom:1px solid #26343d; border-radius:0; background:linear-gradient(110deg,#121c22,#10181d); transition:background .14s,border-color .14s,box-shadow .14s; }
.vision-table-row:last-child { border-bottom:0; }
.vision-table-row:hover { background:#152129; }
.item-index { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 8px; background: #2b2f34; color: #d9b959; font-size: 11px; font-weight: 800; box-shadow: inset 0 0 0 1px #363b42; }
.item-main { position:relative; min-width:0; display:block; }
.item-thumbnail { width:52px; height:52px; display:grid; place-items:center; overflow:hidden; border:1px solid #30434f; border-radius:8px; background:#18262e; color:#d6b23d; font-size:18px; font-weight:900; }
.item-thumbnail img,.item-thumbnail .gallery-file-icon { width:100%; height:100%; margin:0; border:0; border-radius:0; object-fit:cover; box-shadow:none; }
.item-thumbnail.empty { background:linear-gradient(135deg,#18242b,#10191f); }
.item-main-copy { min-width:0; }
.item-title-line { display: flex; align-items: center; gap: 7px; min-width: 0; }
.item-title-line > strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item-main strong, .item-main small { display: block; }
.item-main small { margin-top: 2px; overflow: hidden; color: var(--muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.item-clickable { cursor: pointer; }
.item-clickable:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.item-clickable.details-open { background:linear-gradient(110deg,#172229,#10191f); box-shadow:inset 3px 0 0 var(--accent); }
.item-clickable.inline-dirty { box-shadow: inset 3px 0 0 #df8d32; }
.item-row-hint { margin-top: 5px !important; color: #747b84 !important; font-size: 9px !important; letter-spacing: .02em; }
.item-row-hint span { color: #c6a84d; font-size: 12px; }
.inline-table-input { width:100%; min-width:0; min-height:38px; box-sizing:border-box; padding:8px 10px; border:1px solid rgba(101,126,139,.24); border-radius:8px; background:rgba(6,14,19,.22); color:#e8eaed; font:inherit; font-variant-numeric:tabular-nums; transition:border-color .13s,background .13s,box-shadow .13s; }
.inline-table-input[type="number"] { appearance:textfield; -moz-appearance:textfield; }
.inline-table-input[type="number"]::-webkit-inner-spin-button,.inline-table-input[type="number"]::-webkit-outer-spin-button { margin:0; appearance:none; -webkit-appearance:none; }
.inline-table-input:hover { border-color:#465862; background:#131c21; }
.inline-table-input:focus { border-color: #caa53b; background: #111315; box-shadow: 0 0 0 2px rgba(244,180,0,.11); outline: 0; }
.inline-product { min-height: 28px; padding: 3px 5px; color: var(--text); font-size: 14px; font-weight: 750; }
.item-group-name { min-height:18px; padding-left:20px; }
.inline-group-input { width: 100%; padding: 0 5px; border: 0; background: transparent; color: #aeb3ba; font-size: 10px; font-weight: 700; text-transform: uppercase; outline: 0; }
.inline-group-input:not([readonly]):focus { color: var(--accent); }
.inline-group-input[readonly], .group-inherited { color: #6f757d; }
.group-owner-name { color:#c9b56d; font-size:10px; font-weight:750; text-transform:uppercase; }
.group-connection { display:flex; align-items:center; gap:4px; color:#777f88; font-size:9px; white-space:nowrap; }
.group-connection > span { color:#c29c31; font-size:13px; line-height:1; }
.group-connection strong { display:inline !important; max-width:180px; overflow:hidden; color:#b6bbc1; font-size:9px; text-overflow:ellipsis; text-transform:uppercase; white-space:nowrap; }
.product-search-field { position:relative; }
.product-source-hint { position:absolute; top:4px; right:6px; padding:2px 5px; border:1px solid #4e421f; border-radius:999px; color:#c8a84b; background:#1b1a15; font-size:8px; font-weight:800; pointer-events:none; }
.product-search-field > input { padding-right:48px !important; }
.product-suggestions { position:absolute; z-index:80; top:calc(100% + 6px); left:0; width:min(520px,calc(100vw - 50px)); max-height:300px; overflow-y:auto; padding:6px; border:1px solid #4b5159; border-radius:10px; background:#121416; box-shadow:0 18px 50px #000c; }
.product-suggestions.hidden { display:none; }
.product-suggestions button { width:100%; display:flex; align-items:center; justify-content:space-between; gap:20px; padding:10px 11px; border:0; border-radius:7px; background:transparent; color:#e7e9eb; text-align:left; }
.product-suggestions button:hover, .product-suggestions button:focus { background:#282c31; outline:0; }
.product-suggestions button span, .product-suggestions button strong, .product-suggestions button small { display:block; }
.product-suggestions button small { margin-top:3px; color:#858c94; font-size:9px; }
.product-suggestion-price { flex:0 0 auto; text-align:right; }
.product-suggestion-price strong { color:var(--accent); font-size:11px; }
.product-search-status { display:block; padding:10px; color:#9299a1; font-size:10px; }
.product-search-status.error { color:#ff9d9d; }
.inline-select { min-width:130px; padding-right:32px; cursor:pointer; white-space:nowrap; }
.inline-save-status { display:grid; place-items:center; width:22px; height:22px; border-radius:50%; font-size:12px; font-weight:900; cursor:help; }
.inline-save-status.saved { color:#43d982; }
.inline-save-status.pending { color:#e0ad31; }
.inline-save-status.saving { color:#7db8ff; animation:spin 1s linear infinite; }
.inline-save-status.error { color:#ff6065; border:1px solid currentColor; }
.item-actions .inline-save-status { display:none; }
.item-clickable.inline-saving { box-shadow:inset 3px 0 0 #5599e8; }
@keyframes spin { to { transform:rotate(360deg); } }
.inline-detail-field { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 8px; margin-top: 5px; }
.inline-detail-field input, .item-quick-preview textarea { width: 100%; padding: 8px 9px; border: 1px solid #444; border-radius: 6px; background: #111; color: var(--text); outline: 0; }
.inline-detail-field input:focus, .item-quick-preview textarea:focus { border-color: var(--accent); }
.inline-detail-field a { color: var(--accent); font-size: 11px; white-space: nowrap; }
.item-quick-preview { grid-column:1/-1; display:block; margin:8px -16px -10px; padding:18px 20px 22px; border-top:1px solid #263944; background:linear-gradient(180deg,#0c171d,#0a1419); }
.item-quick-preview.hidden { display: none; }
.item-quick-preview > header { display: flex; align-items: baseline; justify-content: space-between; gap: 15px; padding-bottom: 10px; border-bottom: 1px solid #30343a; }
.item-quick-preview > header span { color: #747b84; font-size: 10px; }
.item-detail-grid { display:grid; grid-template-columns:minmax(420px,1.3fr) minmax(310px,.95fr) minmax(280px,.8fr); gap:14px; align-items:stretch; }
.item-detail-grid > section { min-width:0; padding:16px; border:1px solid #263a45; border-radius:12px; background:#101b21; box-shadow:0 10px 28px rgba(0,0,0,.12); }
.item-detail-grid > section + section { padding-left:16px; border-left:1px solid #263a45; }
.detail-card-header { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:13px; padding-bottom:10px; border-bottom:1px solid #263a45; }
.detail-card-header div > span,.detail-card-header div > small { display:block; }
.detail-card-header div > small { margin-top:3px; color:#71818a; font-size:8px; }
.item-quick-preview .detail-card-header > strong { flex:0 0 28px; width:28px; min-width:28px; height:28px; display:grid; place-items:center; box-sizing:border-box; margin:0; padding:0; border:1px solid #47545b; border-radius:50%; color:#e8edf0; font-size:10px; line-height:1; text-align:center; text-indent:0; }
.item-detail-files { border-color:#4f461f !important; background:linear-gradient(145deg,rgba(244,180,0,.045),#101b21 42%) !important; }
.item-detail-description textarea { min-height:112px; resize:vertical; line-height:1.45; }
.detail-description-text { min-height:82px; margin:0 0 14px; color:#d6dde1; font-size:11px; line-height:1.55; white-space:pre-wrap; }
.item-detail-description .detail-metric-fields { display:grid; grid-template-columns:1fr 1fr; gap:10px; margin-top:12px; }
.detail-metric-fields label { margin:0; display:grid; grid-template-columns:1fr 82px; align-items:center; gap:8px; color:#88949d; font-size:10px; }
.detail-metric-fields input { width:100%; padding:7px 8px; border:1px solid #35444e; border-radius:7px; background:#111b20; color:#edf0f2; text-align:right; }
.detail-percent { position:relative; display:block; }
.detail-percent input { padding-right:23px; }
.detail-percent small { position:absolute; top:50%; right:8px; margin:0; transform:translateY(-50%); }
.calculator-cell { min-height:52px; display:grid; place-items:center; align-content:center; gap:4px; padding:5px; border:1px solid #344954; border-radius:8px; background:#101c22; color:#dce4e8; }
.calculator-cell span { font-size:15px; }
.calculator-cell strong { color:#ffc400; font-size:9px; }
.calculator-cell:hover { border-color:#ba8c00; }
.item-visualizer-placeholder button { width:100%; min-height:42px; border:1px solid #354a56; background:#101c22; color:#dce4e8; font-size:10px; }
.item-visualizer-placeholder button:hover { border-color:#ba8c00; color:#ffc400; }
.item-visualizer-placeholder > small { margin-top:8px; color:#74838c; font-size:9px; line-height:1.4; }
.item-detail-tools { display:grid; align-content:start; gap:12px; }
.detail-tool-card { min-width:0; padding:13px; border:1px solid #293c46; border-radius:9px; background:#0c171d; }
.detail-tool-card .preview-label { margin-bottom:8px; }
.item-detail-calculator { grid-column:1/-1; padding:0 !important; overflow:hidden; border-color:#3f3a22 !important; background:linear-gradient(135deg,rgba(244,180,0,.04),#101b21 40%) !important; }
.empty-calculator-details { display:flex; align-items:center; min-height:72px; padding:15px 17px !important; }
.empty-calculator-details .preview-label { margin-bottom:3px; }
.empty-calculator-details small { color:#71818a; font-size:9px; }
.calculator-breakdown > summary { min-height:70px; display:flex; align-items:center; justify-content:space-between; gap:16px; padding:14px 17px; cursor:pointer; list-style:none; user-select:none; }
.calculator-breakdown > summary::-webkit-details-marker { display:none; }
.calculator-breakdown > summary:hover { background:rgba(244,180,0,.035); }
.calculator-breakdown > summary .preview-label { margin-bottom:3px; }
.calculator-breakdown > summary small { color:#71818a; font-size:9px; }
.calculator-details-action { display:flex; align-items:center; gap:10px; color:#e6b800; font-size:9px; font-weight:800; white-space:nowrap; }
.calculator-action-open { display:none; }
.calculator-details-action b { width:28px; height:28px; display:grid; place-items:center; border:1px solid #66571a; border-radius:50%; font-size:14px; line-height:1; transition:transform .18s ease; }
.calculator-breakdown[open] .calculator-details-action b { transform:rotate(180deg); }
.calculator-breakdown[open] .calculator-action-closed { display:none; }
.calculator-breakdown[open] .calculator-action-open { display:inline; }
.calculator-summary-strip { display:grid; grid-template-columns:repeat(7,minmax(105px,1fr)); gap:8px; padding:0 17px 14px; }
.calculator-summary-strip > span { min-width:0; padding:10px 11px; border:1px solid #2d414b; border-radius:8px; background:#0c171d; }
.calculator-summary-strip small,.calculator-summary-strip strong { display:block; }
.calculator-summary-strip small { margin:0 0 5px; color:#71818a; font-size:8px; }
.calculator-summary-strip strong { color:#eef2f4; font-size:11px; white-space:nowrap; }
.calculator-summary-strip .calculator-summary-total { border-color:#8b7000; background:rgba(244,180,0,.07); }
.calculator-summary-strip .calculator-summary-total small,.calculator-summary-strip .calculator-summary-total strong { color:#ffd137; }
.calculator-breakdown-scroll { overflow-x:auto; border-top:1px solid #263a45; }
.calculator-breakdown table { width:100%; min-width:1040px; border-collapse:collapse; font-size:9px; }
.calculator-breakdown th { padding:10px 12px; background:#0b161b; color:#78909c; font-size:8px; letter-spacing:.05em; text-align:left; white-space:nowrap; }
.calculator-breakdown td { padding:11px 12px; border-top:1px solid #21313a; color:#dbe2e6; white-space:nowrap; }
.calculator-breakdown tbody tr:hover { background:rgba(255,255,255,.018); }
.calculator-position-number { width:22px; height:22px; display:grid; place-items:center; border:1px solid #46545c; border-radius:50%; color:#ffc400; font-weight:800; }
.item-file-actions { display:grid; grid-template-columns:1fr 1fr; gap:8px; }
.synology-placeholder { min-height:58px; padding:8px; border:1px solid #a77d00; background:rgba(244,180,0,.05); color:#ffc400; font-size:9px; }
.item-file-actions .inline-drop-zone { min-height:58px; padding:7px; }
.item-file-actions .inline-drop-zone strong { font-size:9px; }
.item-file-actions .inline-drop-zone span { font-size:8px; }
.paste-screenshot-zone { grid-column:1/-1; min-height:54px; display:grid; place-content:center; gap:4px; padding:8px; border:1px dashed #3d7b60; border-radius:9px; background:rgba(49,174,105,.055); color:#d8eee1; text-align:center; }
.paste-screenshot-zone strong,.paste-screenshot-zone span { display:block; }
.paste-screenshot-zone strong { color:#54df8c; font-size:10px; }
.paste-screenshot-zone span { color:#8fa99a; font-size:8px; }
.paste-screenshot-zone:hover,.paste-screenshot-zone:focus { border-color:#54df8c; background:rgba(49,174,105,.1); outline:none; }
.paste-screenshot-zone.pasting { opacity:.7; }
.item-quick-preview img { width: 64px; height: 48px; margin-top: 7px; object-fit: contain; border-radius: 6px; background: #fff; }
.item-quick-preview strong, .item-quick-preview a, .item-quick-preview p, .item-quick-preview small { display: block; }
.item-quick-preview a { margin-top: 5px; color: var(--accent); font-weight: 700; }
.item-quick-preview p { margin: 7px 0 0; color: #d2d2d2; font-size: 12px; white-space: pre-wrap; }
.item-quick-preview small, .preview-empty { margin-top: 6px; color: var(--muted); font-size: 10px; }
.preview-label { display: block; margin: 0 0 10px; color: #eff1f3; font-size: 12px; font-weight: 750; letter-spacing: 0; }
.preview-label small { color: #8c929a; font-weight: 500; }
.item-detail-files small { line-height: 1.4; }
.sync-badge { position: relative; display: inline-flex; width: 19px; height: 19px; margin-top: 4px; align-items: center; justify-content: center; border: 1px solid currentColor; border-radius: 50%; font-size: 11px; font-weight: 900; line-height: 1; cursor: help; }
.sync-badge::after { content: attr(data-tooltip); position: absolute; z-index: 20; bottom: calc(100% + 7px); left: 0; width: max-content; max-width: 280px; padding: 6px 8px; border: 1px solid #555; border-radius: 6px; background: #0f0f0f; color: #eee; box-shadow: 0 5px 18px rgba(0,0,0,.35); font-size: 10px; font-weight: 600; line-height: 1.35; opacity: 0; pointer-events: none; transform: translateY(3px); transition: opacity .12s, transform .12s; }
.sync-badge:hover::after, .sync-badge:focus-visible::after { opacity: 1; transform: translateY(0); }
.sync-badge.synced { color: #9be7b7; background: rgba(94,203,136,.12); }
.sync-badge.local { color: #ffd979; background: rgba(244,180,0,.13); }
.sync-badge.changed { color: #ffc0a8; background: rgba(255,126,76,.13); }
.sync-dot { position: relative; flex: 0 0 auto; width: 10px; height: 10px; margin-left: 3px; border-radius: 50%; cursor: help; box-shadow: 0 0 8px currentColor; }
.sync-dot.synced { color:#35d479; background:#35d479; }
.sync-dot.changed { color:#f1a340; background:#f1a340; }
.sync-dot.local { color:#f0c54c; background:#f0c54c; }
.sync-dot::after { content: attr(data-tooltip); position:absolute; z-index:30; bottom:calc(100% + 9px); left:0; width:max-content; max-width:280px; padding:7px 9px; border:1px solid #4a4f55; border-radius:7px; background:#0e1012; color:#eee; box-shadow:0 8px 24px #0008; font-size:10px; opacity:0; pointer-events:none; transform:translateY(4px); transition:.14s; }
.sync-dot:hover::after { opacity:1; transform:translateY(0); }
.item-serial { min-width: 0; }
.item-serial strong, .item-serial small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item-serial strong { color: var(--accent); font-size: 12px; }
.item-serial small { margin-top: 2px; color: var(--muted); font-size: 10px; }
.variant-badge { display: inline-flex; justify-content: center; padding: 4px 7px; border: 1px solid #5a4813; border-radius: 999px; color: var(--accent); background: rgba(244,180,0,.06); font-size: 10px; font-weight: 800; white-space: nowrap; }
.item-classification strong, .item-classification small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item-classification strong { font-size: 12px; }
.item-classification small { margin-top: 2px; color: var(--muted); font-size: 10px; }
.numeric-cell { text-align:right; white-space:nowrap; font-variant-numeric:tabular-nums; }
.quantity-unit-cell { display:grid; grid-template-columns:minmax(50px,.78fr) minmax(42px,.56fr); align-items:center; gap:4px; }
.quantity-unit-cell > span { color:#aeb6bc; font-size:11px; text-align:center; }
.unit-input { padding-inline:4px; color:#aeb6bc; text-align:center; }
.line-total { color:#f0f3f5; }
.gross-value { display:grid; justify-items:end; gap:2px; color:#f0f3f5; }
.gross-value strong { color:inherit; font-size:12px; }
.gross-value small { color:#6f7b84; font-size:8px; font-weight:650; }
.profit-value { color:#42dd78; font-size:12px; transition:filter .16s ease,opacity .16s ease; }
.internal-value { color: #d4b0b0; }
.currency-field, .percent-field { position:relative; display:block; margin:0; }
.currency-field .inline-table-input, .percent-field .inline-table-input { padding-right:34px; }
.currency-field > span, .percent-field > span { position:absolute; top:50%; right:9px; color:#aeb3ba; font-size:11px; pointer-events:none; transform:translateY(-50%); }
.currency-field.internal-value > span { color:#c49d9d; }
.calculator-price-confirm { position:fixed; z-index:12000; box-sizing:border-box; padding:13px; border:1px solid #a47d08; border-radius:10px; background:#111c22; box-shadow:0 16px 48px #000c; color:#dce3e7; }
.calculator-price-confirm::before { content:''; position:absolute; top:-6px; left:calc(50% - 6px); width:10px; height:10px; border-top:1px solid #a47d08; border-left:1px solid #a47d08; background:#111c22; transform:rotate(45deg); }
.calculator-price-confirm.above::before { top:auto; bottom:-6px; border:0; border-right:1px solid #a47d08; border-bottom:1px solid #a47d08; }
.calculator-price-confirm-heading { display:flex; align-items:center; gap:8px; color:#ffd34d; font-size:11px; }
.calculator-price-confirm-heading > span { width:20px; height:20px; display:grid; place-items:center; flex:0 0 auto; border:1px solid #a47d08; border-radius:50%; font-weight:900; }
.calculator-price-confirm p { margin:8px 0 12px; color:#aebbc2; font-size:10px; line-height:1.45; }
.calculator-price-confirm-actions { display:flex; justify-content:flex-end; gap:7px; }
.calculator-price-confirm-actions button { min-height:32px; padding:0 11px; font-size:10px; }
.item-actions { display: flex; align-items: center; justify-content: flex-end; gap: 7px; }
.mini-button { padding: 6px 8px; border-color: var(--border); background: #292929; color: var(--text); font-size: 10px; }
.mini-button.danger { color: #ff9999; }
.icon-button, .chevron-button { display:grid; place-items:center; width:36px; height:36px; padding:0; border:1px solid #383d43; border-radius:9px; background:#24272b; color:#e9ebed; font-size:17px; }
.icon-button svg { width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.icon-button:hover, .chevron-button:hover { border-color:#626973; background:#2b2f34; }
.icon-button.danger { color:#ff555a; font-size:18px; }
.chevron-button { width:30px; border-color:transparent; background:transparent; color:#b6bbc2; font-size:20px; }
.inline-drop-zone { min-height:92px; display:grid; place-content:center; gap:5px; border:1px dashed #5b6169; border-radius:10px; color:#9da3ab; text-align:center; cursor:pointer; }
.inline-drop-zone:hover, .inline-drop-zone.dragging { border-color:var(--accent); background:rgba(244,180,0,.05); }
.inline-drop-zone input { position:absolute; width:1px; height:1px; opacity:0; }
.inline-drop-zone strong { color:#eee; font-size:12px; }
.inline-drop-zone span { font-size:10px; }
.inline-file-list { display:grid; gap:5px; margin-top:8px; }
.item-detail-files .inline-file-list { max-height:255px; overflow:auto; padding-right:3px; }
.inline-file-list > span { display:flex; align-items:center; gap:7px; color:#aeb3ba; font-size:10px; }
.inline-file-row { display:flex; align-items:center; gap:7px; padding:4px; border:1px solid transparent; border-radius:8px; }
.inline-file-row:hover { border-color:#363b41; background:#1d2023; }
.inline-file-preview { min-width:0; flex:1; display:flex; align-items:center; gap:8px; padding:0; border:0; background:transparent; color:inherit; text-align:left; }
.inline-file-preview > span:last-child { min-width:0; }
.inline-file-preview .gallery-file-icon { flex:0 0 auto; width:28px; height:24px; border-radius:5px; font-size:7px; box-shadow:none; }
.inline-file-list img { width:28px; height:22px; margin:0; }
.inline-file-list strong, .inline-file-list small { display:block; }
.inline-file-list strong { color:#d9dde1; font-size:10px; }
.inline-file-list small { margin-top:2px; color:#777e87; font-size:9px; }
.file-delete-icon { flex:0 0 auto; width:30px; height:30px; margin-left:auto; }
.file-delete-icon svg { width:15px; height:15px; }
.variant-summaries { min-width:1450px; display:grid; gap:9px; margin-top:10px; }
.items-summary { min-width:0; display:grid; grid-template-columns:1fr repeat(5,auto); gap:42px; align-items:end; margin:0; padding:14px 20px; border:1px solid #263944; border-radius:12px; background:linear-gradient(120deg,#121d23,#10191e); color:#8f9aa3; font-size:10px; }
.variant-summaries.multiple .items-summary { border-left:3px solid #b88900; }
.items-summary span:not(:first-child) { display:grid; gap:5px; }
.items-summary strong { color:#f1f2f3; font-size:14px; }
.items-summary .summary-net { min-width:132px; margin:-6px -8px; padding:8px 12px; border:1px solid #b88900; border-radius:8px; background:rgba(244,180,0,.065); color:#d8bd62; font-weight:750; }
.items-summary .summary-net strong { color:#fff4c4; font-size:16px; font-weight:900; }
.items-summary > span:first-child:not(.summary-variant) strong { margin-left:6px; font-size:12px; }
.items-summary .summary-variant { min-width:260px; display:grid; gap:3px; }
.items-summary .summary-variant small { color:#f4bd28; font-size:8px; font-weight:850; letter-spacing:.09em; }
.items-summary .summary-variant strong { overflow:hidden; color:#eef2f4; font-size:12px; text-overflow:ellipsis; white-space:nowrap; }
.items-summary .summary-variant em { color:#778791; font-size:9px; font-style:normal; }
.items-summary .summary-profit { min-width:116px; margin:-6px -8px; padding:8px 12px; border:1px solid #1d7b40; border-radius:8px; background:rgba(39,185,91,.06); }
.items-summary .summary-profit { color:#68bd86; font-size:9px; }
.items-summary .summary-profit strong { color:#43e77b; font-size:12px; font-weight:800; transition:filter .16s ease,opacity .16s ease; }
#visionEditor.profit-hidden .profit-value,#visionEditor.profit-hidden .summary-profit strong { filter:blur(6px); opacity:.72; user-select:none; }
.offer-action-bar { position:static; display:flex; align-items:center; gap:9px; margin:12px 0 0; padding:11px 12px; border:1px solid #263a45; border-radius:10px; background:#091218; box-shadow:none; }
.offer-action-spacer { flex:1; }
.offer-action-link,.offer-action-button { min-height:38px; display:inline-flex; align-items:center; justify-content:center; padding:0 15px; border:1px solid #3a4e59; border-radius:8px; background:#0d181f; color:#e4e9ec; font-size:10px; font-weight:750; text-decoration:none; }
.offer-action-link:hover { border-color:#6b7e89; color:#fff; }
.offer-action-button.accent-outline { border-color:#a97e00; color:#ffc400; }
.offer-action-button:disabled { opacity:.46; }
.offer-more-wrap { position:relative; }
.offer-more-button { width:38px; height:38px; padding:0; border:1px solid #354752; background:#101a20; color:#dbe2e6; font-size:22px; }
.offer-more-button:hover { border-color:var(--accent); color:var(--accent); }
.offer-more-menu { position:absolute; z-index:70; top:calc(100% + 7px); right:0; width:220px; padding:6px; border:1px solid #344854; border-radius:10px; background:#0b151b; box-shadow:0 18px 50px #000b; }
.offer-more-menu button { width:100%; display:block; padding:9px 10px; border:0; background:transparent; color:#d8e0e4; font-size:10px; text-align:left; }
.offer-more-menu button:hover { background:#15242c; color:#ffc400; }
.lock-label { color: var(--muted); font-size: 11px; }
.item-dialog { width:min(1380px,calc(100vw - 24px)); max-height:calc(100vh - 24px); }
.item-dialog form { max-height:calc(100vh - 48px); overflow:auto; }
.item-entry-table { overflow-x: auto; overflow-y: visible; border: 1px solid var(--border); border-radius: 8px; }
.item-entry-head, .item-entry-row { min-width:1180px; display:grid; grid-template-columns:minmax(270px,2fr) 96px 132px 72px 70px 105px 105px 118px 78px; }
.item-entry-head { background: #292929; color: #999; font-size: 9px; font-weight: 800; letter-spacing: .06em; }
.item-entry-head span { padding: 8px; border-right: 1px solid var(--border); }
.item-entry-row { align-items:stretch; background:#1d1d1d; }
.item-entry-row label { margin: 0; padding: 0; border-right: 1px solid var(--border); }
.item-entry-row label:last-child, .item-entry-head span:last-child { border-right: 0; }
.item-entry-row input, .item-entry-row select { height: 43px; padding: 8px; border: 0; border-radius: 0; background: #181818; }
.item-entry-row input:focus { box-shadow: inset 0 0 0 1px var(--accent); }
.item-entry-row input.group-name-inherited { color: var(--muted); background: #202020; }
.item-entry-name { min-width:0; display:grid; grid-template-rows:43px 34px; border-right:1px solid var(--border); }
.item-entry-name label { min-width:0; border-right:0; }
.item-entry-name label:last-child { border-top:1px solid #303030; }
.item-entry-name label:last-child input { height:34px; color:#9ba8af; font-size:10px; }
.item-entry-row > .calculator-cell { min-height:67px; margin:5px; }
.item-form-gross { display:grid; place-content:center; padding:7px; border-right:1px solid var(--border); color:#f0f3f4; font-weight:800; text-align:right; }
.item-form-gross small { display:block; margin-top:2px; color:#85959e; font-size:8px; }
.item-dialog-detail-grid { display:grid; grid-template-columns:minmax(360px,1.15fr) minmax(340px,1fr) minmax(270px,.75fr); gap:12px; margin-top:12px; }
.item-dialog-card { min-width:0; min-height:320px; padding:15px; border:1px solid #2b424e; border-radius:11px; background:#0d1a20; }
.item-dialog-card.item-detail-files { border-color:#65541a; }
.item-dialog-card .attachment-preview { display:grid; gap:6px; margin-top:10px; padding:0; background:transparent; }
.item-dialog-card .attachment-preview:empty { display:block; }
.item-dialog-card .attachment-preview:empty::after { content:'Brak plików tej pozycji.'; color:#80909a; font-size:10px; }
.item-dialog-card.item-detail-description textarea { width:100%; min-height:175px; }
.item-dialog-card.item-detail-tools { display:grid; grid-template-columns:1fr; align-content:start; }
.item-dialog-card .detail-tool-card label { margin:0; }
.item-dialog-card .detail-tool-card label > strong,.item-dialog-card .detail-tool-card label > small { display:block; }
.item-dialog-card .detail-tool-card input { margin-top:8px; }
.item-entry-details { display: grid; grid-template-columns: 90px minmax(230px,.8fr) minmax(360px,1.5fr); gap: 10px; margin-top: 12px; align-items: stretch; }
.item-entry-details label { margin: 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.internal-field { padding: 10px; border: 1px solid #4a3b3b; border-radius: 8px; background: rgba(255,107,107,.05); }
.attachment-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.attachment-grid.unified-attachments { grid-template-columns:1fr; }
.drop-zone { position: relative; min-height: 105px; margin: 0; padding: 14px; place-content: center; border: 1px dashed #555; border-radius: 9px; background: #181818; color: var(--muted); text-align: center; cursor: pointer; }
.drop-zone.dragging { border-color: var(--accent); background: rgba(244,180,0,.08); }
.drop-zone > strong { color: var(--text); }
.attachment-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.attachment-preview:empty { display: none; }
.attachment-preview { display: grid; gap: 6px; margin-top: 8px; padding: 7px; border-radius: 7px; background: #242424; text-align: left; }
.attachment-preview-row { display: grid; grid-template-columns: 48px minmax(0,1fr) auto; align-items: center; gap: 9px; }
.attachment-preview-row > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.attachment-preview-row.pending { border-left:2px solid var(--accent); }
.attachment-preview-row small { display:block; margin-top:2px; color:#8b929a; font-size:8px; }
.hidden-upload-frame { position:fixed; width:1px; height:1px; border:0; opacity:0; pointer-events:none; }
.attachment-preview img, .attachment-file-icon { width: 48px; height: 38px; object-fit: contain; border-radius: 4px; background: #fff; }
.attachment-file-icon { display: grid; place-items: center; color: #222; font-size: 10px; font-weight: 900; }
.product-suggestions.floating { position:fixed; z-index:100000; }
.item-files { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 5px; }
.item-files span { max-width: 100%; padding: 2px 6px; border: 1px solid #494949; border-radius: 999px; color: #c9c9c9; font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.firmao-annotations-preview:empty { display: none; }
.firmao-annotations-preview { margin-top: 12px; padding: 11px 13px; border: 1px solid var(--border); border-radius: 8px; background: #181818; }
.firmao-annotations-preview > strong { color: var(--muted); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; }
.firmao-annotations-preview pre { margin: 7px 0 0; color: #cfcfcf; font: 12px/1.45 "Segoe UI", sans-serif; white-space: pre-wrap; }
.version-change-panel { margin:0; padding:22px; border:0; border-radius:0; background:transparent; }
.version-change-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.version-change-grid label { display: grid; gap: 7px; margin: 0; color: #d5d5d5; font-size: 12px; font-weight: 700; }
.version-change-grid textarea { width: 100%; padding: 10px; border: 1px solid #4b4b4b; border-radius: 7px; background: #111; color: var(--text); resize: vertical; }
.version-change-grid > div { padding: 10px; border-radius: 7px; background: #181818; }
.version-change-grid > div > strong { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .06em; }
.version-change-grid pre { margin: 7px 0 0; font: 12px/1.45 "Segoe UI", sans-serif; white-space: pre-wrap; }
.required-mark { margin-left: 5px; color: var(--accent); font-size: 9px; }
.version-change-actions { display: flex; align-items: center; justify-content: flex-end; gap: 12px; margin-top: 10px; }
.version-change-actions span { margin-right: auto; font-size: 11px; }
dialog { width: min(540px, calc(100vw - 30px)); padding: 0; border: 1px solid var(--border); border-radius: 14px; background: var(--panel); color: var(--text); box-shadow: 0 24px 80px #000; }
dialog::backdrop { background: rgba(0,0,0,.72); backdrop-filter: blur(3px); }
dialog form { padding: 25px; }
dialog header { margin-bottom: 20px; }
dialog label { display: grid; gap: 7px; margin-bottom: 15px; color: #c7c7c7; font-size: 13px; font-weight: 700; }
dialog input, dialog textarea, dialog select { width: 100%; padding: 11px 12px; border: 1px solid #4b4b4b; border-radius: 8px; background: #111; color: var(--text); outline: 0; resize: vertical; }
dialog input:focus, dialog textarea:focus, dialog select:focus { border-color: var(--accent); }
.compact { margin: -7px 0 14px; font-size: 12px; }
dialog footer { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }
.warning { padding: 11px 13px; border-left: 3px solid var(--accent); background: rgba(244,180,0,.08); color: #d9d0b5; font-size: 13px; }
.form-error { min-height: 20px; color: var(--danger); font-size: 13px; }
.login-dialog footer { justify-content: stretch; }
.login-dialog footer button { width: 100%; }
.account-dialog { width:min(620px,calc(100vw - 30px)); }
.account-dialog form { max-height:calc(100vh - 40px); overflow:auto; }
.customer-contacts-dialog { width:min(720px,calc(100vw - 30px)); max-height:calc(100vh - 40px); overflow:hidden; }
.customer-contacts-header { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; margin:0; padding:20px 22px 16px; border-bottom:1px solid #2b404b; }
.customer-contacts-header h2 { margin:3px 0 2px; font-size:21px; }
.customer-contacts-header small { color:#7f9099; font-size:10px; }
.customer-contacts-content { max-height:calc(100vh - 145px); overflow:auto; padding:18px 22px 22px; }
.customer-company-card { padding:15px; border:1px solid #354b56; border-radius:11px; background:#0d1920; }
.customer-company-card-secondary { margin-top:18px; }
.customer-company-card h3 { margin:0 0 12px; color:#f0f3f5; font-size:16px; }
.customer-company-details { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:9px 18px; }
.customer-detail { min-width:0; display:grid; gap:3px; }
.customer-detail small { color:#748791; font-size:8px; font-weight:800; letter-spacing:.08em; text-transform:uppercase; }
.customer-detail strong,.customer-detail a { overflow-wrap:anywhere; color:#d9e1e5; font-size:11px; text-decoration:none; }
.customer-detail a:hover,.contact-methods a:hover { color:var(--accent); }
.customer-contacts-section-title { display:flex; align-items:center; justify-content:space-between; gap:12px; margin:18px 2px 9px; }
.customer-contacts-section-title.first { margin-top:0; }
.customer-contacts-section-title h3 { margin:0; font-size:14px; }
.customer-contacts-section-title span { min-width:24px; height:24px; display:grid; place-items:center; padding:0 6px; border:1px solid #4f461f; border-radius:999px; color:var(--accent); font-size:9px; }
.customer-contact-list { display:grid; gap:8px; }
.customer-contact-card { display:grid; grid-template-columns:42px minmax(0,1fr); gap:13px; padding:14px; border:1px solid #2c414c; border-radius:10px; background:#0b161c; }
.customer-contact-avatar { width:42px; height:42px; display:grid; place-items:center; border-radius:50%; background:#30280d; color:#f2bd20; font-size:11px; font-weight:850; }
.customer-contact-card strong { display:block; font-size:14px; line-height:1.25; }
.customer-contact-role { display:block; margin-top:3px; color:#84949d; font-size:10px; }
.contact-methods { display:flex; flex-wrap:wrap; gap:8px 10px; margin-top:10px; }
.contact-methods a { display:inline-flex; align-items:center; min-height:32px; padding:6px 10px; border:1px solid #344b57; border-radius:8px; background:#101e25; color:#dce8ed; font-size:13px; font-weight:750; line-height:1.2; text-decoration:none; }
.contact-methods a:hover { border-color:#8f7410; background:#17232a; }
.account-section { margin-top:14px; padding:16px; border:1px solid var(--border); border-radius:10px; background:#101b21; }
.account-section h3 { margin:0 0 13px; font-size:15px; }
.account-section-heading { display:flex; align-items:start; justify-content:space-between; gap:12px; }
.account-section-heading p { margin:4px 0 0; font-size:11px; }
.crm-users-list { display:grid; gap:7px; margin-bottom:14px; }
.crm-user-row { display:grid; grid-template-columns:34px minmax(0,1fr) auto; align-items:center; gap:10px; padding:9px 10px; border:1px solid #30424c; border-radius:8px; background:#0b151b; }
.crm-user-row > i { width:30px; height:30px; display:grid; place-items:center; border-radius:50%; background:#332b10; color:var(--accent); font-size:10px; font-style:normal; font-weight:800; }
.crm-user-row strong,.crm-user-row small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.crm-user-row strong { font-size:11px; }
.crm-user-row small { margin-top:2px; color:var(--muted); font-size:9px; }
.crm-user-row em { color:#c7ad50; font-size:9px; font-style:normal; }
.new-crm-user-fields { padding-top:14px; border-top:1px solid var(--border); }
.new-crm-user-fields > button { width:100%; }
.check-label { display: flex; grid-template-columns: none; align-items: center; gap: 8px; cursor: pointer; }
.check-label input { width: 16px; height: 16px; margin: 0; accent-color: var(--accent); }
.security-note { margin: 8px 0 14px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.settings-status { padding: 13px; border: 1px solid var(--border); border-radius: 8px; background: #202020; }
.settings-actions { display: grid; gap: 9px; }
.integration-settings-form { max-height:calc(100vh - 50px); overflow:auto; }
#apiSettingsDialog { width:min(1080px,calc(100vw - 32px)); }
.integration-settings-section { padding:14px; border:1px solid var(--border); border-radius:10px; background:#191919; }
.integration-settings-section + .integration-settings-section { margin-top:14px; }
.integration-settings-section h3 { margin:0 0 11px; font-size:15px; }
.settings-field-grid { display:grid; grid-template-columns:1fr 1fr; gap:0 10px; }
.settings-field-grid .settings-wide { grid-column:1/-1; }
.synology-settings-actions { grid-template-columns:1fr 1fr; }
.synology-settings-actions .danger-outline { grid-column:1/-1; }
.settings-help { margin:-3px 0 12px; color:#8d9aa2; font-size:10px; line-height:1.45; }
.calculator-settings-group { margin:0; padding:12px; border:1px solid #34434b; border-radius:9px; background:#111a1f; }
.calculator-settings-group + .calculator-settings-group { margin-top:11px; }
.calculator-settings-group legend { padding:0 7px; color:#d8e1e5; font-size:11px; font-weight:800; }
.calculator-settings-group summary { cursor:pointer; color:#e2e9ec; font-size:11px; font-weight:850; list-style:none; }
.calculator-settings-group summary::-webkit-details-marker { display:none; }
.calculator-settings-group summary::after { content:'＋'; float:right; color:#f4b400; }
.calculator-settings-group[open] summary { margin-bottom:12px; }
.calculator-settings-group[open] summary::after { content:'−'; }
.calculator-specific-settings-list { display:grid; gap:9px; margin-top:11px; }
.calculator-specific-settings-list .calculator-settings-group + .calculator-settings-group { margin-top:0; }
.calculator-settings-empty { margin:0; color:#81919a; font-size:10px; }
.calculator-specific-settings { border-color:#65541a; background:rgba(244,180,0,.035); }
.calculator-specific-settings legend { color:#f1c83f; }
.calculator-settings-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; }
.calculator-settings-grid label { min-width:0; margin:0; color:#9eabb2; font-size:9px; }
.calculator-settings-grid input { width:100%; margin-top:5px; }
.calculator-settings-section .settings-status { margin:11px 0; font-size:10px; }
.calculator-settings-actions { grid-template-columns:1fr 1fr; }
@media (max-width:700px) { .calculator-settings-grid { grid-template-columns:1fr 1fr; } }
.danger-outline { border-color: #654040; color: #ffaaaa; }
.synology-browser-dialog { width:min(1120px,calc(100vw - 34px)); height:min(820px,calc(100vh - 24px)); max-height:calc(100vh - 24px); padding:0; overflow:hidden; }
.synology-browser-dialog[open] { display:flex; flex-direction:column; }
.synology-browser-header { display:flex; align-items:center; justify-content:space-between; gap:20px; margin:0; padding:18px 20px; border-bottom:1px solid var(--border); }
.synology-browser-header h2 { margin:2px 0 0; }
.synology-browser-header p:last-child { margin:5px 0 0; font-size:11px; }
.synology-location-bar { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:10px 20px; border-bottom:1px solid var(--border); background:#17191b; }
.synology-location-tabs { display:flex; gap:7px; }
.synology-location-tabs button { min-width:110px; height:34px; padding:0 12px; font-size:10px; }
.synology-location-tabs button.active { border-color:var(--accent); background:rgba(244,180,0,.08); color:var(--accent); }
.synology-advanced-options { position:relative; }
.synology-advanced-options > summary { padding:7px 10px; color:#8e979e; font-size:9px; cursor:pointer; list-style:none; }
.synology-advanced-options > summary::after { content:'⌄'; margin-left:7px; }
.synology-advanced-options[open] > summary { color:#d3b94f; }
.synology-advanced-options .synology-mapping-panel { position:absolute; z-index:5; top:calc(100% + 9px); right:0; width:min(650px,calc(100vw - 50px)); border:1px solid #3b454c; border-radius:9px; box-shadow:0 18px 50px #000c; }
.synology-mapping-panel { display:flex; align-items:center; justify-content:space-between; gap:18px; padding:13px; background:#1a1d1f; }
.synology-mapping-panel span,.synology-mapping-panel strong { display:block; }
.synology-mapping-panel span { color:var(--muted); font-size:9px; font-weight:800; letter-spacing:.08em; text-transform:uppercase; }
.synology-mapping-panel strong { max-width:520px; margin-top:4px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:12px; }
.synology-folder-context { min-width:0; display:grid; grid-template-columns:auto minmax(0,1fr); align-items:center; gap:3px 9px; }
.synology-folder-context strong { margin:0; }
.synology-mapping-actions { display:flex; gap:8px; }
.synology-comparison-panel { display:flex; align-items:center; gap:12px; padding:9px 20px; border-bottom:1px solid #5f4e18; background:rgba(244,180,0,.065); color:#d8c57e; font-size:10px; }
.synology-comparison-panel > span { flex:1; }
.synology-comparison-panel button { height:31px; padding:0 10px; font-size:9px; }
.synology-comparison-panel.error { border-color:#6b3030; background:rgba(255,80,80,.06); color:#ffaaaa; }
.synology-comparison-loading,.synology-comparison-error { padding:7px 9px; color:var(--muted); font-size:10px; }
.synology-comparison-error { color:#ffb0a8; }
.synology-comparison-summary { display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.synology-comparison-summary span { display:flex; align-items:center; gap:6px; padding:6px 9px; border:1px solid #3b4248; border-radius:7px; color:#c8cdd1; font-size:9px; }
.synology-comparison-summary b { color:#fff; font-size:11px; }
.synology-comparison-summary .firmao-only { border-color:#725900; background:rgba(244,180,0,.08); }
.synology-comparison-summary .synology-only { border-color:#38536b; background:rgba(67,145,208,.06); }
.synology-difference-columns { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin-top:8px; }
.synology-difference-list { min-width:0; border:1px solid #30363b; border-radius:7px; background:#121212; }
.synology-difference-list summary { padding:7px 9px; color:#cfd3d6; font-size:9px; font-weight:800; cursor:pointer; }
.synology-difference-list summary b { margin-left:5px; color:var(--accent); }
.synology-difference-list ul { max-height:90px; margin:0; padding:0 9px 7px; overflow:auto; list-style:none; }
.synology-difference-list li { display:flex; justify-content:space-between; gap:12px; padding:4px 0; border-top:1px solid #262a2d; font-size:9px; }
.synology-difference-list li span { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.synology-difference-list li small { flex:none; color:var(--muted); }
.synology-difference-list li.more { color:var(--muted); }
.synology-breadcrumbs { display:flex; align-items:center; gap:5px; min-height:42px; padding:8px 20px; border-bottom:1px solid var(--border); overflow:auto; }
.synology-breadcrumbs button { padding:5px 8px; border:0; background:transparent; color:#d5b642; font-size:10px; }
.synology-breadcrumbs i { color:#666; font-style:normal; }
.synology-operation-bar { flex:none; display:grid; grid-template-columns:minmax(260px,1.35fr) minmax(260px,1fr) auto; align-items:stretch; gap:14px; margin:10px 14px; padding:16px; border:2px solid #dba900; border-radius:11px; background:linear-gradient(105deg,rgba(244,180,0,.18),rgba(16,29,36,.98) 48%); box-shadow:0 12px 35px #0006,0 0 0 3px rgba(244,180,0,.06); }
.synology-operation-copy { min-width:0; }
.synology-operation-copy > small { display:block; margin-bottom:5px; color:#ffc400; font-size:8px; font-weight:900; letter-spacing:.13em; }
.synology-operation-copy > strong,.synology-operation-copy > span { display:block; }
.synology-operation-copy > strong { color:#fff1bd; font-size:15px; }
.synology-operation-copy > span { margin-top:4px; overflow:hidden; color:#c5c0b3; font-size:10px; text-overflow:ellipsis; white-space:nowrap; }
.synology-operation-copy ol { display:flex; flex-wrap:wrap; gap:5px 18px; margin:11px 0 0; padding-left:18px; color:#d5dbe0; font-size:9px; }
.synology-destination-card { min-width:0; display:grid; align-content:center; gap:5px; padding:10px 12px; border:1px solid #465865; border-radius:8px; background:#0b171e; }
.synology-destination-card > span { color:#8fa0aa; font-size:7px; font-weight:850; letter-spacing:.1em; }
.synology-destination-card > strong { overflow:hidden; color:#fff; font-size:11px; text-overflow:ellipsis; white-space:nowrap; }
.synology-destination-card > small { color:#e7bd42; font-size:8px; line-height:1.4; }
.synology-operation-actions { display:flex; align-items:center; gap:8px; }
.synology-operation-bar button { min-height:40px; padding:0 14px; font-size:9px; white-space:nowrap; }
.synology-operation-bar .primary { box-shadow:0 0 0 3px rgba(244,180,0,.12); }
.choosing-synology-destination .synology-breadcrumbs { border-top:1px solid #8d6c00; background:rgba(244,180,0,.055); }
.choosing-synology-destination .synology-browser-row.directory { border-left:3px solid #bd9200; background:linear-gradient(90deg,rgba(244,180,0,.08),transparent 50%); }
.choosing-synology-destination .synology-browser-row.directory:hover { background:rgba(244,180,0,.14); }
.synology-file-name .destination-hint { color:#e8bc36; }
@media (max-width:1000px) { .synology-operation-bar { grid-template-columns:1fr; } .synology-operation-actions { justify-content:flex-end; } }
.synology-search-toolbar { display:flex; align-items:center; gap:12px; padding:10px 14px; border-bottom:1px solid var(--border); background:#181818; }
.synology-search-toolbar label { min-width:0; flex:1; display:grid; grid-template-columns:24px minmax(0,1fr) 30px; align-items:center; gap:4px; height:38px; margin:0; padding:0 7px; border:1px solid #4b4b4b; border-radius:8px; background:#111; }
.synology-search-toolbar label:focus-within { border-color:var(--accent); box-shadow:0 0 0 2px rgba(244,180,0,.09); }
.synology-search-toolbar label > span { color:var(--accent); text-align:center; font-size:17px; }
.synology-search-toolbar input { height:100%; padding:0; border:0; background:transparent; color:var(--text); outline:0; }
.synology-search-toolbar button { width:28px; height:28px; padding:0; border:0; background:transparent; color:#9aa0a6; font-size:18px; }
.synology-search-toolbar #selectVisibleSynologyFiles { width:auto; height:34px; padding:0 11px; border:1px solid #3d454d; background:#20252a; color:#d9dde1; font-size:10px; white-space:nowrap; }
.synology-search-toolbar #synologyPasteScreenshotButton { width:auto; height:34px; padding:0 12px; border:1px dashed #3d7b60; background:rgba(49,174,105,.06); color:#54df8c; font-size:9px; font-weight:800; white-space:nowrap; }
.synology-search-toolbar #synologyPasteScreenshotButton:hover,.synology-search-toolbar #synologyPasteScreenshotButton:focus { border-color:#54df8c; background:rgba(49,174,105,.12); outline:none; }
.synology-search-toolbar #synologyPasteScreenshotButton.pasting { opacity:.7; }
.synology-search-toolbar > span { min-width:105px; color:var(--muted); font-size:10px; text-align:right; }
.synology-browser-main { min-height:0; flex:1 1 auto; display:grid; grid-template-columns:minmax(0,1fr) 300px; overflow:hidden; background:#141414; }
.synology-browser-list { min-height:0; overflow:auto; padding:10px 14px; background:#141414; }
.synology-browser-row { width:100%; display:grid; grid-template-columns:24px 34px minmax(0,1fr) 110px 145px; align-items:center; gap:10px; padding:10px 12px; border:1px solid transparent; border-bottom-color:#303030; background:transparent; color:var(--text); text-align:left; }
.synology-browser-row:hover { background:#202020; border-color:#3a3a3a; }
.synology-browser-row.context-target { border-color:#8c741d; background:rgba(244,180,0,.055); }
.synology-browser-row.selected { border-color:var(--accent); background:rgba(244,180,0,.07); }
.synology-file-check { width:17px; height:17px; display:grid; place-items:center; border:1px solid #58616a; border-radius:4px; color:#111; font-size:12px; font-weight:900; }
.synology-browser-row.selected .synology-file-check { border-color:var(--accent); background:var(--accent); }
.synology-browser-row.directory .synology-file-check { border-color:transparent; }
.synology-browser-row .file-symbol { color:var(--accent); font-size:17px; text-align:center; }
.synology-file-name { min-width:0; display:flex; align-items:center; gap:8px; overflow:hidden; }
.synology-browser-row strong { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:12px; }
.synology-file-name em { flex:none; padding:3px 5px; border:1px solid #3a4248; border-radius:999px; color:#9fa7ae; font-size:8px; font-style:normal; font-weight:800; }
.synology-file-name em.in-both { border-color:#2c654b; color:#72d5a4; }
.synology-file-name em.only-synology { border-color:#38536b; color:#79b5df; }
.synology-file-name em.customer-file { border-color:#5a4e30; color:#cbb879; }
.synology-browser-row small { color:var(--muted); font-size:10px; text-align:right; }
.synology-load-more { width:100%; margin:8px 0 2px; padding:9px; border:1px solid #3b4248; border-radius:7px; background:#1d2124; color:#d5b642; font-size:10px; }
.synology-load-more:hover { border-color:#75631e; background:#242414; }
.synology-file-preview { min-width:0; display:flex; flex-direction:column; border-left:1px solid var(--border); background:#101214; }
.synology-preview-empty { height:100%; display:grid; place-content:center; justify-items:center; gap:7px; padding:24px; color:var(--muted); text-align:center; }
.synology-preview-empty i { color:#735f1a; font-size:42px; font-style:normal; }
.synology-preview-empty strong { color:#d8dadd; font-size:12px; }
.synology-preview-empty span { max-width:210px; font-size:10px; line-height:1.5; }
.synology-preview-stage { min-height:0; flex:1; display:grid; place-items:center; overflow:hidden; padding:12px; background:radial-gradient(circle at 50% 42%,#292d30,#0d0f10 70%); }
.synology-preview-stage img { display:block; max-width:100%; max-height:100%; object-fit:contain; border-radius:4px; box-shadow:0 12px 32px #000a; }
.synology-preview-stage.pdf { padding:0; background:#252525; }
.synology-preview-stage iframe { width:100%; height:100%; min-height:260px; border:0; background:#fff; }
.synology-preview-stage.unsupported { align-content:center; gap:10px; color:var(--muted); font-size:10px; text-align:center; }
.synology-preview-stage.unsupported i { display:grid; place-items:center; width:62px; height:76px; border:1px solid #4a5055; border-radius:7px; background:#25292c; color:#d8b52f; font-size:11px; font-style:normal; font-weight:900; }
.synology-preview-meta { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:6px 10px; padding:12px 14px; border-top:1px solid var(--border); background:#17191b; }
.synology-preview-meta strong { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:11px; }
.synology-preview-meta span { color:var(--muted); font-size:9px; }
.synology-preview-meta a { grid-column:1/-1; color:var(--accent); font-size:9px; }
.synology-browser-footer { flex:none; display:flex; align-items:center; justify-content:flex-end; gap:14px; margin:0; padding:12px 20px; border-top:1px solid var(--border); background:#181a1c; box-shadow:0 -8px 24px #0005; }
.synology-browser-footer span { margin-right:auto; color:var(--muted); font-size:11px; }
.synology-browser-footer .primary { min-width:210px; }
.synology-context-menu { position:fixed; z-index:10000; width:270px; overflow:hidden; padding:7px; border:1px solid #4b5157; border-radius:10px; background:#202327; box-shadow:0 20px 55px #000d; }
.synology-context-menu header { padding:8px 9px 10px; border-bottom:1px solid #353a3f; }
.synology-context-menu header span,.synology-context-menu header strong { display:block; }
.synology-context-menu header span { color:#9a8334; font-size:8px; font-weight:850; letter-spacing:.09em; }
.synology-context-menu header strong { margin-top:4px; overflow:hidden; color:#f0f1f2; font-size:11px; text-overflow:ellipsis; white-space:nowrap; }
.synology-context-menu > button { width:100%; display:block; padding:9px 10px; border:0; border-radius:6px; background:transparent; color:#d9dde1; font-size:10px; text-align:left; }
.synology-context-menu > button:hover,.synology-context-menu > button:focus-visible { background:#30353a; color:#fff; outline:0; }
.synology-context-menu > button.danger { margin-top:4px; border-top:1px solid #3b3333; border-radius:0 0 6px 6px; color:#ff9e96; }
.synology-context-menu > button.danger:hover,.synology-context-menu > button.danger:focus-visible { background:rgba(199,61,52,.18); color:#ffc0ba; }
.file-gallery-dialog { width:min(1180px,calc(100vw - 34px)); max-height:min(850px,calc(100vh - 34px)); padding:0; overflow:hidden; border-color:#3b4046; background:#151719; }
.file-gallery-dialog::backdrop { background:rgba(0,0,0,.78); backdrop-filter:blur(5px); }
.file-gallery-header { display:flex; align-items:center; justify-content:space-between; gap:20px; margin:0; padding:20px 22px 17px; border-bottom:1px solid #30353a; background:linear-gradient(135deg,#1d2023,#17191b); }
.file-gallery-header h2 { margin:3px 0 0; font-size:21px; }
.file-gallery-header p:last-child { margin:5px 0 0; color:#8c939b; font-size:11px; }
.file-gallery-layout { height:min(710px,calc(100vh - 150px)); display:grid; grid-template-columns:minmax(0,1.55fr) minmax(320px,.75fr); }
.file-gallery-preview { min-width:0; display:grid; grid-template-rows:minmax(0,1fr) auto; padding:18px; border-right:1px solid #30353a; background:#111315; }
.gallery-preview-stage { min-height:350px; display:grid; place-items:center; overflow:hidden; border:1px solid #30353a; border-radius:12px; background:radial-gradient(circle at 50% 40%,#24282c,#101214 68%); }
.gallery-preview-stage img { display:block; max-width:100%; max-height:100%; width:auto; height:auto; object-fit:contain; }
.pdf-preview-wrap { width:100%; height:100%; min-height:420px; display:grid; place-items:center; align-content:center; gap:10px; overflow:auto; padding:18px; }
.pdf-preview-wrap canvas { display:block; max-width:100%; height:auto; background:#fff; box-shadow:0 18px 55px #000b; }
.pdf-preview-status { color:#8f969e; font-size:10px; }
.pdf-preview-status a { color:var(--accent); }
.gallery-file-icon { display:grid; place-items:center; width:64px; height:78px; border:1px solid #4d545c; border-radius:9px; background:linear-gradient(145deg,#343a40,#22262b); color:#e6c65f; font-size:14px; font-weight:900; letter-spacing:.05em; box-shadow:0 16px 38px #0008; }
.file-gallery-thumb .gallery-file-icon { width:48px; height:58px; font-size:10px; box-shadow:none; }
.gallery-preview-info { padding:16px 2px 0; }
.gallery-preview-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.gallery-preview-actions { display:flex; align-items:center; gap:8px; }
.gallery-delete-button { width:32px; height:32px; }
.gallery-preview-info h3 { margin:10px 0 4px; overflow-wrap:anywhere; color:#f0f1f2; font-size:16px; }
.gallery-preview-info > p { margin:0; color:#9299a1; font-size:11px; }
.gallery-preview-info dl { display:flex; flex-wrap:wrap; gap:10px; margin:14px 0 0; }
.gallery-preview-info dl div { min-width:105px; padding:8px 10px; border:1px solid #343940; border-radius:8px; background:#1b1e21; }
.gallery-preview-info dt { color:#737b84; font-size:8px; font-weight:800; letter-spacing:.08em; text-transform:uppercase; }
.gallery-preview-info dd { margin:3px 0 0; color:#dfe2e4; font-size:11px; font-weight:750; }
.gallery-external-link { padding:7px 10px; border:1px solid #454b52; border-radius:8px; background:#202429; color:#e0e3e6; font-size:10px; }
.file-gallery-sidebar { min-width:0; overflow:auto; padding:14px; background:#1a1d20; }
.file-gallery-grid { display:grid; gap:8px; }
.file-gallery-card-wrap { position:relative; min-width:0; }
.file-gallery-card { width:100%; display:grid; grid-template-columns:66px minmax(0,1fr); align-items:center; gap:11px; padding:9px; border:1px solid #343940; border-radius:10px; background:#202327; color:#dfe2e5; text-align:left; transition:border-color .15s,background .15s,transform .15s; }
.file-gallery-card:hover { border-color:#5a6169; background:#25292e; transform:translateY(-1px); }
.file-gallery-card.selected { border-color:var(--accent); background:rgba(244,180,0,.065); box-shadow:inset 3px 0 0 var(--accent); }
.file-gallery-thumb { width:66px; height:66px; display:grid; place-items:center; overflow:hidden; border-radius:8px; background:#121416; }
.file-gallery-thumb img { width:100%; height:100%; object-fit:cover; }
.file-gallery-card-body { min-width:0; display:block; }
.file-gallery-card-body strong,.file-gallery-card-body small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.file-gallery-card-body strong { margin-top:7px; font-size:11px; }
.file-gallery-card-body small { margin-top:3px; color:#858d96; font-size:9px; }
.gallery-copy-version-button { position:absolute; right:8px; bottom:8px; min-width:58px; height:25px; padding:0 8px; border:1px solid #806500; border-radius:7px; background:#171b1e; color:#f2c42e; font-size:8px; font-weight:850; box-shadow:0 4px 12px #0007; }
.gallery-copy-version-button:hover { border-color:#ffc400; background:#29230e; }
.gallery-copy-version-button.copied { border-color:#2c6843; color:#57d98a; }
.gallery-copy-version-button:disabled { opacity:.75; cursor:default; }
.gallery-context-menu > button:disabled { color:#57d98a; cursor:default; opacity:.75; }
.gallery-context-empty { display:block; padding:12px 10px; color:#8f969e; font-size:10px; }
.gallery-scope-badge { display:inline-flex; width:max-content; padding:3px 6px; border:1px solid #4d535b; border-radius:999px; color:#b8bec5; font-size:8px; font-weight:850; letter-spacing:.06em; text-transform:uppercase; }
.gallery-scope-badge.item { border-color:#5d512b; background:rgba(244,180,0,.06); color:#dec15f; }
.gallery-empty { display:grid; place-items:center; color:#9299a1; }
.paste-screenshot-dialog { width:min(720px,calc(100vw - 28px)); max-height:calc(100vh - 28px); overflow:hidden; border-color:#45535c; background:#111b21; }
.paste-screenshot-dialog::backdrop { background:rgba(0,0,0,.82); backdrop-filter:blur(5px); }
.paste-screenshot-dialog form { max-height:calc(100vh - 30px); padding:0; display:flex; flex-direction:column; }
.paste-screenshot-header { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; margin:0; padding:20px 22px 16px; border-bottom:1px solid #30424c; }
.paste-screenshot-header h2 { margin:2px 0 5px; }
.paste-screenshot-header .muted { margin:0; max-width:540px; font-size:11px; line-height:1.45; }
.paste-screenshot-body { min-height:0; overflow:auto; padding:18px 22px; }
.paste-screenshot-preview { height:min(390px,45vh); display:grid; place-items:center; overflow:hidden; margin-bottom:16px; border:1px solid #344751; border-radius:10px; background:#080e12; }
.paste-screenshot-preview img { display:block; width:100%; height:100%; object-fit:contain; }
.paste-screenshot-dialog label { margin:0; }
.paste-screenshot-dialog label small { color:#8598a3; font-size:10px; font-weight:500; }
.paste-screenshot-dialog input { font-size:14px; font-weight:700; }
.paste-screenshot-dialog footer { position:relative; z-index:2; flex:0 0 auto; margin:0; padding:14px 22px 18px; border-top:1px solid #30424c; background:#10191f; }
.calculator-dialog { width:min(1500px,calc(100vw - 24px)); height:calc(100vh - 24px); max-height:calc(100vh - 24px); padding:0; overflow:hidden; }
.calculator-dialog[open] { display:flex; flex-direction:column; }
.calculator-dialog-header { flex:0 0 auto; display:flex; align-items:center; justify-content:space-between; gap:20px; margin:0; padding:14px 18px; border-bottom:1px solid #30424c; background:#101b21; }
.calculator-dialog-header h2 { margin:2px 0 0; font-size:18px; }
.calculator-dialog-header p:last-child { margin:4px 0 0; font-size:10px; }
.calculator-dialog-body { min-height:0; flex:1 1 auto; padding:0; background:#0b1419; }
.calculator-dialog-body iframe { width:100%; height:100%; display:block; border:0; background:#0b1419; }
.calculator-dialog-footer { position:relative; z-index:2; flex:0 0 auto; display:flex; align-items:center; justify-content:flex-end; gap:10px; margin:0; padding:10px 16px; border-top:1px solid #30424c; background:#10191f; box-shadow:0 -8px 24px #0006; }
.calculator-result-summary { display:flex; align-items:center; gap:8px; margin-right:auto; }
.calculator-result-summary > span { min-width:125px; display:grid; gap:3px; padding:7px 10px; border:1px solid #334650; border-radius:8px; background:#0c171d; }
.calculator-result-summary small { color:#80929c; font-size:8px; }
.calculator-result-summary strong { color:#e8eef1; font-size:12px; }
.calculator-result-summary .calculator-sale-result { border-color:#8f7410; background:rgba(244,180,0,.06); }
.calculator-result-summary .calculator-sale-result strong { color:#ffd65a; font-size:14px; }
.calculator-cell.configured { border-color:#8f7410; background:rgba(244,180,0,.075); }
.calculator-cell.configured span { color:#ffc400; }
@media (max-width:760px) { .calculator-result-summary { width:100%; overflow-x:auto; } .calculator-dialog-footer { flex-wrap:wrap; } }
@media (max-width:760px) { .calculator-header-controls,.calculator-dialog-controls { width:100%; align-items:stretch; flex-direction:column; } .calculator-header-controls label,.calculator-dialog-controls label,.calculator-header-controls select,.calculator-dialog-controls select { width:100%; min-width:0; } .calculator-dialog-header { align-items:flex-start; flex-direction:column; } .calculator-dialog-controls { position:relative; padding-right:48px; } .calculator-dialog-controls .dialog-close { position:absolute; top:0; right:0; width:38px; } }
.file-transfer-panel { position:fixed; z-index:9000; right:22px; bottom:82px; width:min(420px,calc(100vw - 32px)); overflow:hidden; border:1px solid #40545f; border-radius:12px; background:#0d181e; box-shadow:0 18px 55px #000c; }
.file-transfer-panel > header { display:flex; align-items:center; justify-content:space-between; gap:14px; padding:12px 13px; border-bottom:1px solid #2f414b; background:#122129; }
.file-transfer-panel > header strong,.file-transfer-panel > header small { display:block; }
.file-transfer-panel > header strong { color:#f0f4f6; font-size:13px; }
.file-transfer-panel > header small { margin-top:3px; color:#8fa0a9; font-size:9px; }
.file-transfer-panel > header > div:last-child { display:flex; gap:5px; }
.file-transfer-panel > header button { width:28px; height:28px; display:grid; place-items:center; padding:0; border:1px solid #3a4d57; background:#17252c; color:#d9e1e5; font-size:15px; line-height:1; }
.file-transfer-panel > header button svg { width:14px; height:14px; display:block; fill:none; stroke:currentColor; stroke-width:2.2; stroke-linecap:round; stroke-linejoin:round; transition:transform .16s ease; }
.file-transfer-panel > header button.is-collapsed svg { transform:rotate(180deg); }
.file-transfer-panel > header button:disabled { opacity:.35; }
.file-transfer-list { display:grid; gap:1px; max-height:290px; overflow:auto; background:#263942; }
.file-transfer-row { display:grid; grid-template-columns:30px minmax(0,1fr); gap:10px; align-items:center; padding:11px 13px; background:#0d181e; }
.file-transfer-state { width:28px; height:28px; display:grid; place-items:center; border:1px solid #53636b; border-radius:50%; color:#b6c2c8; font-size:13px; font-weight:900; }
.file-transfer-row.uploading .file-transfer-state { border-color:#d6a900; color:#ffc400; animation:transferPulse 1.1s infinite; }
.file-transfer-row.success .file-transfer-state { border-color:#19894c; background:#103321; color:#45e78d; }
.file-transfer-row.error .file-transfer-state { border-color:#9a3d43; background:#35181b; color:#ff7c84; }
.file-transfer-row strong,.file-transfer-row small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.file-transfer-row strong { color:#e7ecef; font-size:11px; }
.file-transfer-row small { margin-top:4px; color:#8fa0a9; font-size:9px; }
.file-transfer-row.error small { color:#ff9da3; white-space:normal; }
.file-transfer-progress { position:relative; display:block; height:3px; margin-top:8px; overflow:hidden; border-radius:4px; background:#283941; }
.file-transfer-progress::after { content:''; position:absolute; inset:0; width:38%; border-radius:inherit; background:#ffc400; animation:transferProgress 1.2s ease-in-out infinite; }
.file-transfer-panel.collapsed .file-transfer-list { display:none; }
.file-transfer-panel.collapsed > header { border-bottom:0; }
@keyframes transferProgress { from { transform:translateX(-110%); } to { transform:translateX(300%); } }
@keyframes transferPulse { 50% { box-shadow:0 0 12px #ffc40088; } }
.toast { position: fixed; right: 24px; bottom: 24px; max-width: 380px; padding: 13px 16px; border-radius: 9px; background: #292929; box-shadow: 0 14px 40px #000; opacity: 0; transform: translateY(12px); pointer-events: none; transition: .2s; }
.toast.visible { opacity: 1; transform: translateY(0); }
.toast.error { border-left: 4px solid var(--danger); }
.toast.success { border-left: 4px solid var(--success); }
.hidden { display: none !important; }
@media (max-width: 1100px) { .context-selector { min-width:160px; } .connection:not(.sidebar-firmao-connection) { display:none; } }
@media (max-width: 850px) { .workspace { grid-template-columns:1fr; } .offer { grid-template-columns:1fr 1fr; } .customer-card { width:72px; } .sidebar-toggle { display:none; } .sidebar-navigation { padding-top:24px; } .sidebar-navigation button { justify-content:center; padding:0; } .sidebar-navigation button > span:last-child,.sidebar-customer-context { display:none; } .sidebar-bottom-calculator { justify-content:center; padding:0; } .sidebar-bottom-calculator-label { display:none; } .sidebar-settings { justify-content:center; font-size:0; } .sidebar-settings-label { display:none; } body:has(#workspace:not(.hidden)) main { padding-left:94px; } .topbar { grid-template-columns:72px minmax(0,1fr) auto; } .brand { font-size:18px; } .brand small { display:none; } .context-selector { min-width:0; } .context-selector > span { display:none; } }
@media (max-width: 850px) { .standalone-calculator-results { grid-template-columns:repeat(2,minmax(120px,1fr)); } .standalone-calculator-header { align-items:flex-start; flex-direction:column; } }
@media (max-width: 1120px) { .item-entry-details { grid-template-columns:90px 1fr; } .item-detail-grid,.item-dialog-detail-grid { grid-template-columns:minmax(380px,1.2fr) minmax(300px,1fr); } .item-detail-tools { grid-column:1/-1; grid-template-columns:1fr 1fr; } .calculator-summary-strip { grid-template-columns:repeat(4,minmax(105px,1fr)); } }
@media (max-width: 850px) { .vision-wide { width:auto; margin-left:0; } }
@media (max-width: 700px) { .project-list-header { display: none; } .project { grid-template-columns: 30px minmax(0,1fr) auto; } .project-actions { grid-column: 2 / -1; justify-content: flex-start; } }
@media (max-width: 560px) { main { padding-inline:14px; } body:has(#workspace:not(.hidden)) main { padding:14px 12px 50px; } .customer-card { display:none; } .topbar { grid-template-columns:auto minmax(0,1fr) auto; padding-inline:12px; } .workspace-selectors { overflow-x:auto; } .context-selector { min-width:135px; } .top-search-button,.user-avatar { display:none; } .section-header { align-items:flex-start; flex-direction:column; } .offer { grid-template-columns:1fr; } .money { text-align:left; } .version-control-panel { justify-content:flex-start; } .version-switcher { align-items:flex-start; flex-direction:column; } .editing-strip { align-items:flex-start; flex-wrap:wrap; } .item-entry-details,.attachment-grid,.item-detail-grid,.item-dialog-detail-grid { grid-template-columns:1fr; } .item-detail-tools { grid-column:auto; grid-template-columns:1fr; } .calculator-summary-strip { grid-template-columns:repeat(2,minmax(105px,1fr)); } .calculator-breakdown > summary { align-items:flex-start; } .offer-action-bar { flex-wrap:wrap; } .offer-action-spacer { display:none; } }
@media (max-width: 760px) { .version-change-grid { grid-template-columns: 1fr; } }
@media (max-width: 820px) { .file-gallery-layout { height:auto; max-height:calc(100vh - 120px); grid-template-columns:1fr; overflow:auto; } .file-gallery-preview { min-height:480px; border-right:0; border-bottom:1px solid #30353a; } .file-gallery-sidebar { overflow:visible; } }
@media (max-width: 820px) { .synology-browser-main { grid-template-columns:1fr; } .synology-file-preview { display:none; } .synology-mapping-panel { align-items:flex-start; flex-direction:column; } .synology-mapping-actions { width:100%; flex-wrap:wrap; } .synology-difference-columns { grid-template-columns:1fr; } }
