:root { color-scheme: light; font-family: Inter, Segoe UI, Arial, sans-serif; background: #f3f6f8; color: #162331; }
body { margin: 0; }
header { display:flex; justify-content:space-between; align-items:center; padding: 14px 5vw; background:#153e68; color:#fff; }
h1 { font-size:1.35rem; margin:0; } h2 { margin-top:0; font-size:1.1rem; }
main, .notice { max-width:1100px; margin:18px auto; padding:0 18px; } .notice { color:#5a3000; background:#fff4d8; border-left:4px solid #e7a819; padding-top:10px; padding-bottom:10px; }
section { background:#fff; border:1px solid #d7e0e8; border-radius:8px; padding:18px; margin:16px 0; box-shadow:0 1px 2px #0012; }
form { display:grid; gap:10px; } label { display:grid; gap:4px; font-size:.92rem; } input, select, textarea { font:inherit; padding:7px; border:1px solid #aebdcc; border-radius:4px; }
fieldset { display:grid; gap:8px; border:1px solid #cbd7e2; border-radius:5px; } legend { font-weight:600; } button, .button { appearance:none; background:#1769aa; border:0; border-radius:4px; color:white; padding:8px 12px; font:inherit; cursor:pointer; text-decoration:none; width:max-content; } header button { background:#fff; color:#153e68; }
.market-row, .attachment-row { display:grid; grid-template-columns:90px 1fr 1fr 1.4fr 145px; gap:6px; align-items:center; margin:5px 0; } .attachment-row { grid-template-columns: 300px 1fr; }
.message { white-space:pre-wrap; margin-top:10px; }.error { color:#a51e1e; }.ok { color:#176333; }.actions { display:flex; gap:8px; flex-wrap:wrap; }.job { border-top:1px solid #d7e0e8; padding:12px 0; }.job h3 { margin:0 0 6px; font-size:1rem; }.bad { color:#a51e1e; font-weight:600; }.good { color:#176333; font-weight:600; }
code { background:#edf2f6; padding:1px 3px; } .login { max-width:360px; margin:12vh auto; background:#fff; padding:24px; border-radius:8px; box-shadow:0 1px 7px #0013; }.login form { margin-top:18px; }
@media (max-width:800px) { .market-row { grid-template-columns:1fr 1fr; }.attachment-row { grid-template-columns:1fr; } }
button:disabled { opacity: .5; cursor: not-allowed; }
#template-originals { display: grid; gap: 12px; }
#template-originals legend, #template-originals code { overflow-wrap: anywhere; }
* { box-sizing: border-box; }
input, select, textarea, fieldset, .ingredient-row { min-width: 0; max-width: 100%; }
fieldset { grid-template-columns: minmax(0,1fr); }
.attachment-row span { overflow-wrap: anywhere; }
.ingredient-row { padding: 8px 0; border-bottom: 1px solid #cbd7e2; display: grid; gap: 6px; }
.ingredient-toolbar { display: flex; align-items: center; gap: 10px; }
.ingredient-toolbar select { flex: 0 1 360px; }
.ingredient-toolbar .remove-ingredient { margin-left: auto; }
.ingredient-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 10px; }
.ingredient-field { min-width: 0; display: grid; grid-template-columns: minmax(0,.9fr) minmax(0,1.1fr); gap: 6px; align-items: center; }
.ingredient-label { font-size: 12px; line-height: 16px; }
.ingredient-control { display: grid; grid-template-columns: minmax(0,1fr) max-content; gap: 6px; align-items: center; }
.ingredient-control > input, .ingredient-control > select, .ingredient-control > textarea { width: 100%; }
.ingredient-row input:not([type=checkbox]):not([type=file]), .ingredient-row select, .ingredient-row textarea { font-size: 12px; padding: 3px 5px; min-height: 25px; }
.ingredient-row select { text-overflow: ellipsis; }
.ingredient-row button { font-size: 12px; padding: 4px 8px; min-height: 26px; }
.ingredient-row .icon-button { width: 24px; height: 24px; min-height: 24px; padding: 0; font-size: 18px; }
.ingredient-row .check { font-size: 11px; gap: 4px; padding: 0; line-height: 16px; }
.ingredient-row .check input { width: 13px; height: 13px; margin: 0; }
.ingredient-row .confidential-control { white-space: nowrap; }
.ingredient-row summary { font-size: 12px; padding: 4px 0; }
.clp-classification { width: calc((100% - 10px) / 2); margin: 8px 0; }
.clp-fields { grid-template-columns: repeat(2,minmax(0,1fr)); }
.ingredient-field-wide { grid-column: 1 / -1; grid-template-columns: minmax(0,.45fr) minmax(0,1.55fr); }
.ingredient-field-wide textarea { min-height: 48px; resize: vertical; }
.check { display: flex; align-items: center; gap: 6px; font-size: .82rem; padding: 4px 0; overflow-wrap: anywhere; }
.check input { flex: none; }
.toxicity-details summary, summary { cursor: pointer; padding: 8px 0; }
.toxicity-reports { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 12px; }
.toxicity-report { display: grid; grid-template-columns: minmax(0,1fr) max-content max-content; gap: 4px 6px; align-items: center; border-bottom: 1px solid #d7e0e8; padding: 6px 0; min-width: 0; }
.toxicity-report .add-report { grid-column: 3; grid-row: 1; }
.report-list { grid-column: 1 / -1; }
.report-list:empty { display: none; }
.report-file { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.report-file span, .report-file a, .pending-report { overflow-wrap: anywhere; display: block; min-width: 0; }
.icon-button { width: 32px; height: 32px; padding: 0; font-size: 22px; line-height: 1; display: inline-grid; place-items: center; background: #eef1f4; color: #9e2424; }
.job-heading { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.job-heading h3 { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.job-heading .remove-job { flex: none; border: 1px solid #bd6b6b; }
.job-tabs { display: flex; gap: 2px; border-bottom: 1px solid #aebdcc; margin-top: 12px; }
.job-tabs button { background: transparent; color: #354757; border-radius: 0; border-bottom: 3px solid transparent; }
.job-tabs button[aria-selected=true] { color: #105a97; border-bottom-color: #1769aa; font-weight: 600; }
#editor-source { font-size: .85rem; color: #354757; }
#editor-source:empty { display: none; }
.compact-job { padding: 8px 0; font-size: 12px; }
.job-line { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; min-width: 0; }
.job-line h3 { margin: 0; font-size: 12px; white-space: nowrap; }
.job-line .job-brand { flex: 1 1 160px; min-width: 0; overflow-wrap: anywhere; }
.job-line time { white-space: nowrap; color: #52616d; }
.job-line input[type=checkbox] { width: 14px; height: 14px; margin: 0; flex: none; }
.job-line .remove-job { width: 24px; height: 24px; flex: none; }
.job-tools { display: flex; align-items: start; flex-wrap: wrap; gap: 4px 12px; margin-top: 4px; }
.job-tools button { font-size: 11px; padding: 3px 7px; min-height: 24px; }
.job-tools > button { background: #edf2f6; color: #20577d; }
.job-tools details { min-width: 0; max-width: 100%; }
.job-tools details[open] { flex-basis: 100%; }
.job-tools summary { padding: 3px 0; }
.job-tools details > label { font-size: 12px; }
.job-state { font-size: 11px; }
#batch-csv { width: 100%; font-family: monospace; resize: vertical; }
.batch-preview-row { border-top: 1px solid #d7e0e8; font-size: 12px; overflow-wrap: anywhere; }
.batch-preview-row table { border-collapse: collapse; width: 100%; max-width: 500px; text-align: left; }
.batch-preview-row th, .batch-preview-row td { padding: 5px 10px; border-bottom: 1px solid #e0e6eb; }
#batch-send-controls { padding: 8px 0; align-items: center; }
#batch-send-controls button { font-size: 12px; }
#batch-send-controls .danger { background: #9e2929; }
.history-preview-product { display: grid; grid-template-columns: 150px minmax(0,1fr) max-content; gap: 6px 12px; border-top: 1px solid #d7e0e8; padding: 8px 0; align-items: center; font-size: 12px; }
.history-preview-product > label { display: flex; gap: 8px; align-items: center; min-width: 0; }
.history-preview-product select { width: 100%; min-width: 0; font-size: 12px; padding: 5px; text-overflow: ellipsis; }
.history-preview-product details { grid-column: 1 / -1; min-width: 0; }
.history-version { display: grid; gap: 5px; padding: 8px 0; border-top: 1px solid #e0e6eb; font-size: 12px; overflow-wrap: anywhere; }
.history-version p { margin: 2px 0; }
.history-unverified { color: #75581d; font-size: 11px; }
.history-library-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: 12px; padding: 7px 0; border-top: 1px solid #d7e0e8; }
.history-brand { flex: 1 1 140px; overflow-wrap: anywhere; min-width: 0; }
.history-library-row button { font-size: 12px; padding: 4px 7px; }
.history-pages { display: flex; align-items: center; gap: 12px; margin: 8px 0; font-size: 12px; }
.history-pages button { width: 30px; height: 28px; padding: 0; }
#history-search { width: min(100%,400px); }
#history-versions { max-height: 85vh; overflow-y: auto; }
.name-comparison { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 16px; border-block: 1px solid #d7e0e8; padding: 8px 0; margin-bottom: 8px; }
.name-comparison > div { display: grid; gap: 4px; overflow-wrap: anywhere; }
.clp-check { display: grid; gap: 5px; padding: 8px 0; border-top: 1px solid #d7e0e8; overflow-wrap: anywhere; }
.clp-check table { width: 100%; max-width: 650px; border-collapse: collapse; table-layout: fixed; text-align: left; }
.clp-check th, .clp-check td { padding: 5px; border-bottom: 1px solid #d7e0e8; overflow-wrap: anywhere; }
@media (max-width: 650px) { .history-preview-product { grid-template-columns: minmax(0,1fr); } .history-preview-product > label { display: grid; } .history-library-row { gap: 8px; } }
.job pre { white-space: pre-wrap; overflow-wrap: anywhere; }
#confidential-fields { display: grid; gap: 4px; }
dialog { width: min(760px, calc(100% - 24px)); border: 1px solid #aebdcc; border-radius: 6px; padding: 20px; }
dialog textarea { width: 100%; }
dialog::backdrop { background: #0006; }
[hidden] { display: none !important; }
section { border-radius: 0; box-shadow: none; }
@media (max-width: 650px) { .ingredient-fields, .toxicity-reports, .market-row { grid-template-columns: minmax(0,1fr); } header { padding: 12px; gap: 12px; } h1 { font-size: 1.05rem; } section { padding: 12px; } }
@media (max-width: 650px) { .ingredient-field { grid-template-columns: minmax(0,1fr); gap: 2px; } .clp-classification { width: 100%; } .toxicity-report { grid-template-columns: minmax(0,1fr) max-content; } .toxicity-report .add-report { grid-column: 1; grid-row: auto; justify-self: start; } }
