.oce-dialog { box-sizing: border-box; width: min(900px, calc(100vw - 32px)); max-width: calc(100vw - 32px); max-height: calc(100dvh - 32px); margin: auto; overflow: auto; padding: 20px; border: 1px solid #cbd7cf; border-radius: 12px; background: #fffdf8; color: #20382f; font-size: 14px; }
.oce-dialog::backdrop { background: #0e1714aa; }
.oce-dialog header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.oce-dialog header p { margin: 0; font-size: 12px; color: #546d60; }
.oce-dialog h2 { margin: 4px 0 14px; font-size: 20px; overflow-wrap: anywhere; }
.oce-dialog h3 { font-size: 16px; }
.oce-dialog button { min-height: 38px; border: 1px solid #a7b9ad; border-radius: 6px; background: #fff; color: inherit; font: inherit; padding: 8px 12px; cursor: pointer; }
.oce-dialog button:disabled { opacity: .5; cursor: default; }
.oce-dialog .oce-primary { background: #176e60; color: white; border-color: #176e60; }
.oce-dialog input, .oce-dialog textarea { box-sizing: border-box; width: 100%; min-width: 0; min-height: 38px; border: 1px solid #afc0b6; border-radius: 6px; padding: 7px 9px; font: inherit; background: white; color: inherit; }
.oce-dialog input:disabled, .oce-dialog textarea:disabled { background: #f0f3ef; }
.oce-dialog :focus-visible { outline: 2px solid #176e60; outline-offset: 2px; }
.oce-baseline { display: grid; grid-template-columns: 2fr 1fr; gap: 10px; }
.oce-baseline div { background: #f1f3ed; padding: 12px; border-radius: 7px; }
.oce-baseline dt { color: #526a5e; font-size: 12px; }
.oce-baseline dd { margin: 6px 0 0; overflow-wrap: anywhere; }
.oce-line-quantity { display: grid; gap: 6px; max-width: 180px; margin: 14px 0; }
.oce-table-scroll { max-width: 100%; overflow-x: auto; }
.oce-dialog table { display: table; table-layout: fixed; border-collapse: collapse; border-spacing: 0; width: 100%; }
.oce-components-table { min-width: 520px; }
.oce-components-table th:first-child { width: 50%; }
.oce-components-table th:last-child { width: 70px; }
.oce-financial-table { min-width: 608px; }
.oce-dialog thead { display: table-header-group; }
.oce-dialog tbody { display: table-row-group; }
.oce-dialog tr { display: table-row; width: auto; border: 0; border-radius: 0; background: transparent; }
.oce-dialog th, .oce-dialog td { display: table-cell; width: auto; padding: 9px; vertical-align: top; font-size: 13px; line-height: 1.4; overflow-wrap: anywhere; border-bottom: 1px solid #d4ded7; }
.oce-dialog th { font-size: 12px; background: #f3f7f3; }
.oce-dialog td::before { content: none; display: none; }
.oce-dialog small { display: block; color: #60756a; font-size: 12px; margin-top: 4px; }
.oce-dialog .oce-code { border-color: transparent; padding-left: 0; font-family: ui-monospace, monospace; }
.oce-total { background: #edf4ee; padding: 10px 12px; }
.oce-dialog form { display: flex; align-items: end; gap: 8px; margin: 14px 0; }
.oce-dialog form label { flex: 1; display: grid; gap: 6px; }
.oce-targets, .oce-line-list { display: grid; gap: 6px; }
.oce-line-list > label { display: flex; align-items: center; gap: 8px; overflow-wrap: anywhere; }
.oce-dialog input[data-opp-select] { width: 16px; height: 16px; min-height: 16px; flex: 0 0 16px; padding: 0; }
.oce-dialog form[data-opp-range] { flex-wrap: wrap; }
.oce-dialog form[data-opp-range] label { min-width: 140px; }
.oce-targets button, .oce-line-list button { text-align: left; display: grid; gap: 4px; overflow-wrap: anywhere; }
.oce-reason { display: grid; gap: 6px; margin-top: 16px; }
.oce-reason textarea { min-height: 65px; resize: vertical; }
.oce-dialog footer { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.oce-financial-summary td { background: #f1f6ef; font-size: 12px; }
.oce-error { color: #8c3026; background: #fff0eb; border: 1px solid #e7b4a7; padding: 10px; border-radius: 6px; }
.oce-result { border: 1px solid #c3d9c9; background: #eff7f0; padding: 14px; border-radius: 7px; }
@media (max-width: 640px) { .oce-dialog { padding: 14px; } .oce-baseline { grid-template-columns: 1fr; } .oce-dialog footer { display: grid; grid-template-columns: 1fr; } .oce-dialog footer button { width: 100%; } }
