@scope (.inventory-main) {
/* LINAS AGRO Brandbook 2025: digital palette (p. 13), system fonts (p. 15),
   original logo proportions (pp. 5-7), single-colour line icons (p. 44).
   Darker supporting text colours preserve contrast for small UI labels. */
:scope {
  color-scheme: light;
  --plant: #005B44; --plant-deep: #00422F; --plant-darker: #003224;
  --plant-20: #E7E7E7; --plant-10: #F2F2F2;
  --crops: #FFC25A; --crops-deep: #F0AE3F; --seeds: #A77200; --seeds-text: #835800;
  --white: #FFFFFF; --bg: var(--plant-10); --bg-elev: #FFFFFF;
  --fg: var(--plant); --fg-on-yellow: var(--plant); --fg-on-plant: #FFFFFF;
  --fg-dim: #415B50; --muted: #5C7065;
  --accent: var(--crops); --accent-hover: var(--crops-deep); --link: var(--plant);
  --danger: #AB3025; --ok: var(--plant);
  --ok-tint: #E7F2EA; --warn-tint: #FBEDEA;
  --border: var(--plant-20); --border-strong: #AABAB0;
  --shadow-sm: 0 1px 3px rgba(0,50,36,.04);
  --shadow: 0 4px 16px rgba(0,50,36,.04);
  --shadow-lg: 0 10px 30px rgba(0,50,36,.09);
  --content-width: 1200px;
}
* { box-sizing: border-box; }
:scope { -webkit-text-size-adjust: 100%; }
:scope {
  margin: 0; background: var(--bg); color: var(--fg);
  font-family: 'Jeko', Arial, Helvetica, sans-serif;
  font-size: 16px; line-height: 1.6; -webkit-font-smoothing: antialiased;
  min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column;
}
[hidden] { display: none !important; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
a { color: var(--link); text-underline-offset: 3px; }
button, input, select { font: inherit; }
button, a, input, select { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--plant); outline-offset: 4px; }
.topbar-wrap :focus-visible { outline-color: var(--plant); }
:scope {
  width: 100%; max-width: var(--content-width); margin: 0 auto;
  padding: 24px 16px 40px; flex: 1; min-width: 0;
}
:scope:focus { outline: none; }
h1, h2, h3 { color: var(--plant); line-height: 1.25; overflow-wrap: anywhere; }
h1 { font-size: clamp(1.65rem, 1.2rem + 1.5vw, 2.5rem); font-weight: 600; letter-spacing: -.025em; margin: 0 0 12px; }
h2 { font-size: 1.2rem; font-weight: 600; letter-spacing: -.01em; margin: 0 0 10px; }
p { margin: 0 0 16px; overflow-wrap: anywhere; }
.icon { flex-shrink: 0; vertical-align: middle; }
.icon-small { width: 18px; height: 18px; }
button .icon, .btn .icon { width: 20px; height: 20px; }
.skip-link {
  position: fixed; left: 16px; top: -100px; z-index: 1200; padding: 12px 20px;
  background: var(--crops); color: var(--plant-darker); border-radius: 8px; font-weight: 700;
}
.skip-link:focus { top: 12px; }
.topbar-wrap { background: var(--white); border-bottom: 3px solid var(--crops); }
header.topbar {
  max-width: var(--content-width); margin: 0 auto; padding: 4px 16px;
  display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between;
}
.brand { display: inline-flex; align-items: center; flex-shrink: 0; text-decoration: none; }
/* The supplied PNG already includes the brand's surrounding clear space. */
.brand-logo { display: block; width: 220px; height: auto; max-width: 100%; }
.site-nav { display: flex; flex-wrap: wrap; gap: 4px; width: 100%; }
.site-nav a {
  display: flex; align-items: center; min-height: 44px; padding: 10px 14px;
  border-radius: 6px; color: var(--plant); text-decoration: none; font-size: .9rem; font-weight: 600;
}
.site-nav a:hover { background: var(--plant-10); color: var(--plant); }
.site-nav a[aria-current="page"] { background: var(--plant-10); color: var(--plant); box-shadow: inset 0 -2px 0 var(--seeds); }
button.nav-toggle {
  width: 44px; min-height: 44px; margin: 0; padding: 9px; border: 1px solid var(--border-strong);
  border-radius: 6px; background: var(--white); color: var(--plant); font-size: .84rem;
}
.js .site-nav { display: none; }
.js .site-nav.is-open { display: flex; flex-direction: column; }
.site-footer {
  width: 100%; max-width: var(--content-width); margin: 0 auto; padding: 20px 16px;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 20px;
  border-top: 1px solid var(--border); color: var(--muted); font-size: .75rem;
}
.signed-in { overflow-wrap: anywhere; min-width: 0; }
.page-intro { margin-bottom: 26px; }
.home-intro { padding-top: 8px; }
.eyebrow { font-size: .71rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
.intro-description { color: var(--muted); max-width: 680px; font-size: .95rem; margin: 0; }
.action-grid { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); }
.action-card {
  display: flex; flex-direction: column; gap: 18px; min-width: 0;
  padding: 24px; border: 1px solid var(--border); border-radius: 10px;
  background: var(--white); color: var(--plant); text-decoration: none;
  box-shadow: var(--shadow-sm); transition: border-color 150ms, box-shadow 150ms, transform 150ms;
}
.action-card:hover { border-color: var(--plant); box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.action-card h2 { font-size: 1.15rem; margin-bottom: 8px; }
.action-card p { font-size: .88rem; color: var(--muted); margin: 0; max-width: 460px; }
.action-icon, .section-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; background: transparent; color: var(--plant);
}
.action-icon .icon { width: 28px; height: 28px; }
.action-link { display: flex; gap: 12px; align-items: center; justify-content: space-between; margin-top: auto; font-size: .8rem; font-weight: 700; }
.action-link .icon { width: 20px; height: 20px; }
.action-card-primary { background: var(--plant); border-color: var(--plant); }
.action-card-primary h2 { color: var(--white); }
.action-card-primary p { color: #D8E8DF; }
.action-card-primary .action-icon { color: var(--crops); }
.action-card-primary .action-link { color: var(--crops); }
.action-card-primary:focus-visible { outline-offset: 5px; }
.workflow-guide { margin-top: 32px; padding: 28px 0 0; border-top: 1px solid var(--border); }
.workflow-guide h2 { font-size: 1.1rem; }
.guide-steps { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 20px; }
.guide-steps li { display: flex; align-items: flex-start; gap: 14px; min-width: 0; }
.step-number { font-size: .74rem; font-weight: 800; color: var(--plant); background: #E5EDE6; border-radius: 50%; width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.guide-steps strong { font-size: .86rem; }
.guide-steps p { font-size: .8rem; color: var(--muted); margin: 4px 0 0; }
.back-link { display: inline-flex; align-items: center; min-height: 44px; margin: -8px 0 12px; color: var(--muted); font-size: .82rem; font-weight: 600; text-decoration: none; }
.back-link:hover { color: var(--plant); text-decoration: underline; }
.card {
  background: var(--white); border: 1px solid var(--border); border-radius: 10px;
  padding: 24px; margin: 0 0 20px; min-width: 0; box-shadow: var(--shadow);
}
#app > .card, #app > .workflow-results { max-width: 860px; margin-left: auto; margin-right: auto; }
#app > .asset-form-card { max-width: 1040px; }
.scan-grid { display: grid; grid-template-columns: minmax(0,1fr); gap: 20px; }
.scan-grid .card { margin: 0; }
.section-icon { margin-bottom: 20px; }
.scan-grid h2 { font-size: 1.3rem; }
.photo-actions { display: grid; gap: 12px; margin: 24px 0 8px; }
.photo-tip { margin-top: 24px; padding: 16px; border-radius: 10px; background: var(--plant-10); font-size: .8rem; }
.photo-tip strong { font-weight: 700; color: var(--plant); }
.photo-tip p { color: var(--muted); margin: 6px 0 0; }
.scan-manual form { margin-top: 24px; }
.scan-create-link { margin: 24px 0 0; padding-top: 20px; border-top: 1px solid var(--border); font-size: .84rem; color: var(--muted); }
.scan-create-link a { display: inline-block; padding: 8px 0; font-weight: 700; }
button, .btn {
  display: inline-flex; justify-content: center; align-items: center; gap: 10px;
  width: 100%; min-height: 48px; padding: 12px 18px; margin: 12px 0 0;
  border: 1px solid transparent; border-radius: 10px; background: var(--crops); color: var(--plant-darker);
  font-size: .9rem; font-weight: 700; line-height: 1.5; text-align: center; text-decoration: none;
  cursor: pointer; box-shadow: var(--shadow-sm); transition: background 150ms, border-color 150ms;
}
button:hover:not(:disabled), .btn:hover { background: var(--crops-deep); }
button:disabled { opacity: .6; cursor: wait; }
.btn-secondary { background: var(--white); border-color: var(--border-strong); color: var(--plant); }
.btn-secondary:hover { background: var(--plant-10); border-color: var(--plant); }
label.btn { text-transform: none; letter-spacing: normal; font-size: .9rem; margin: 0; }
.file-control { position: relative; min-width: 0; }
.file-input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.file-input:focus-visible + .btn { outline: 3px solid var(--plant); outline-offset: 4px; }
input[type="text"], input[type="email"], input[type="file"]:not(.file-input), select {
  width: 100%; min-width: 0; min-height: 48px; padding: 12px 14px; border-radius: 9px;
  border: 1px solid var(--border-strong); background: var(--white); color: var(--fg);
  font-size: 1rem; transition: border-color 150ms, box-shadow 150ms;
}
input:focus, select:focus { border-color: var(--plant); }
input::placeholder { color: #687A70; }
.serial-input { font-family: ui-monospace, Consolas, monospace !important; letter-spacing: .04em; }
select { cursor: pointer; padding-right: 32px; }
label { display: block; margin: 16px 0 6px; font-size: .82rem; font-weight: 700; color: var(--fg-dim); }
.field-hint { color: var(--muted); font-size: .78rem; margin: 8px 0 0; }
.field-error { color: var(--danger); font-size: .8rem; margin: 6px 0 0; font-weight: 600; }
.field-invalid { border-color: var(--danger) !important; }
.field { min-width: 0; }
.field label { margin-top: 0; }
.optional-label { color: var(--muted); font-size: .75rem; font-weight: 500; }
.form-section { border: 0; margin: 28px 0 0; padding: 0; min-width: 0; }
.form-section legend { font-weight: 700; font-size: .96rem; padding: 0; color: var(--plant); margin-bottom: 16px; }
.form-grid { display: grid; grid-template-columns: minmax(0,1fr); gap: 20px; }
.form-prefill { padding: 18px; background: var(--plant-10); border-radius: 12px; margin-top: 20px; }
.form-prefill .photo-actions { margin: 0; }
.form-actions { display: flex; flex-direction: column; gap: 12px; border-top: 1px solid var(--border); padding-top: 24px; margin-top: 28px; }
.form-actions .btn, .form-actions button { margin: 0; }
.checkbox-row { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding: 10px 0; font-size: .85rem; font-weight: 500; }
.checkbox-row input { width: 20px; height: 20px; flex-shrink: 0; accent-color: var(--plant); margin: 3px 0 0; }
.row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 20px; padding: 12px 0; border-bottom: 1px solid var(--border); font-size: .9rem; }
.row:last-child { border: 0; }
.row span:first-child { color: var(--muted); font-size: .82rem; }
.row span:last-child { font-weight: 600; overflow-wrap: anywhere; min-width: 0; }
.banner { padding: 14px 16px; border-radius: 10px; margin: 12px 0; font-size: .9rem; font-weight: 600; overflow-wrap: anywhere; }
.banner.ok { background: var(--ok-tint); color: var(--plant); border-left: 4px solid var(--plant); }
.banner.warn { background: var(--warn-tint); color: var(--danger); border-left: 4px solid var(--danger); }
.pickable-list { list-style: none; padding: 0; margin: 8px 0 0; max-height: 240px; overflow-y: auto; border: 1px solid var(--border); border-radius: 9px; background: var(--white); }
.pickable-list:empty { display: none; }
.pickable-list li { border-bottom: 1px solid var(--border); }
.pickable-list li:last-child { border-bottom: 0; }
.pickable-list button { display: block; width: 100%; text-align: left; background: var(--white); color: var(--plant); border: 0; border-radius: 0; margin: 0; box-shadow: none; padding: 12px 14px; font-weight: 500; overflow-wrap: anywhere; }
.pickable-list button:hover { background: var(--plant-10); }
.pickable-list button:focus-visible { outline-offset: -3px; }
.pickable-list li.muted { padding: 12px 14px; color: var(--muted); font-size: .85rem; }
.page-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.page-head h1 { margin-bottom: 8px; }
.muted-sub { color: var(--muted); font-size: .88rem; margin: 0 0 16px; }
.muted-sub strong { color: var(--plant); }
.count-badge { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 9px 14px; background: #E7EEE8; border: 1px solid var(--border); border-radius: 9px; font-size: .8rem; color: var(--plant); }
.toolbar { display: flex; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }
.toolbar-search { flex: 1 1 280px; min-width: 0; }
.toolbar-search label { margin-top: 0; }
.toolbar button, .toolbar .btn { width: auto; margin: 0; }
.asset-filters { padding: 20px; margin-bottom: 24px; border: 1px solid var(--border); border-radius: 12px; background: var(--white); }
.filter-search-row, .filter-select-row { display: grid; gap: 16px; grid-template-columns: minmax(0,1fr); }
.filter-select-row { grid-template-columns: repeat(2,minmax(0,1fr)); margin-top: 16px; }
.asset-filters label { margin-top: 0; }
.axdb-filters .filter-select-row { grid-template-columns: repeat(2,minmax(0,1fr)); }
.axdb-positions { margin-top: 12px; }
.axdb-positions summary { cursor: pointer; padding: 8px 0; min-height: 44px; }
.axdb-positions summary:focus-visible { outline: 3px solid var(--plant); outline-offset: 3px; }
.asset-filters input, .asset-filters select { min-width: 0; }
.asset-filter-details { margin-top: 16px; }
.asset-filter-details summary { cursor: pointer; color: var(--plant); font-size: .9rem; font-weight: 600; min-height: 44px; padding: 12px 0; }
.asset-filter-details summary span { display: block; margin-top: 4px; color: var(--muted); font-size: .76rem; font-weight: 400; }
.asset-filter-details summary:focus-visible { outline: 3px solid var(--plant); outline-offset: 3px; }
.filter-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 20px; }
.filter-actions button, .filter-actions .btn { width: auto; margin: 0; }
.asset-results-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.results-summary { margin: 0; color: var(--muted); font-size: .88rem; }
.results-summary strong { color: var(--plant); }
.page-size { display: flex; align-items: center; gap: 10px; }
.page-size label { margin: 0; font-size: .8rem; }
.page-size select { width: 76px; padding: 10px; }
.page-size-submit { width: auto; margin: 0; }
.js .page-size-submit { display: none; }
.asset-pagination { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 16px 0; }
.asset-pagination .btn { width: auto; margin: 0; min-height: 44px; padding: 10px 12px; font-size: .82rem; }
.pagination-disabled { opacity: .55; }
.mobile-page-number { font-size: .82rem; color: var(--muted); white-space: nowrap; }
.page-numbers { display: none; align-items: center; gap: 6px; }
.page-number { display: inline-flex; min-width: 44px; min-height: 44px; align-items: center; justify-content: center; border: 1px solid var(--border); border-radius: 7px; text-decoration: none; background: var(--white); font-size: .84rem; font-weight: 600; }
.page-number.is-current { color: var(--white); background: var(--plant); border-color: var(--plant); }
.page-number:hover { border-color: var(--plant); }
.page-ellipsis { padding: 0 4px; color: var(--muted); }
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 12px; background: var(--white); box-shadow: var(--shadow-sm); }
table.assets { width: 100%; border-collapse: collapse; font-size: .82rem; }
table.assets th, table.assets td { text-align: left; padding: 15px 16px; }
table.assets thead th { background: #EAF0EB; color: var(--fg-dim); font-size: .72rem; font-weight: 700; white-space: nowrap; }
table.assets tbody td { border-top: 1px solid var(--border); vertical-align: top; }
table.assets tbody tr:hover td { background: #F7FAF7; }
table.assets td.name { font-weight: 700; min-width: 160px; }
table.assets td { overflow-wrap: anywhere; }
table.assets td.asset-reference, table.assets td.asset-date { white-space: nowrap; overflow-wrap: normal; }
table.assets td:nth-child(4), table.assets td:nth-child(5) { min-width: 130px; }
table.assets .dim { color: var(--muted); }
.row-edit { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 12px; border: 1px solid var(--border); border-radius: 7px; text-decoration: none; font-size: .78rem; font-weight: 700; color: var(--plant); white-space: nowrap; }
.row-edit:hover { border-color: var(--plant); background: var(--plant-10); }
.type-pill { display: inline-block; padding: 4px 10px; border-radius: 6px; background: var(--plant-10); color: var(--plant); font-size: .72rem; font-weight: 700; white-space: nowrap; }
table.assets tr.group-row th { background: #F0F4F1; color: var(--plant); border-top: 1px solid var(--border-strong); font-size: .83rem; }
.count { font-weight: 500; color: var(--muted); }
.mobile-asset-list { display: grid; gap: 14px; }
.asset-mobile-card { padding: 20px; border: 1px solid var(--border); border-radius: 12px; background: var(--white); min-width: 0; }
.asset-mobile-card h2 { font-size: 1rem; margin: 10px 0 4px; }
.asset-mobile-card .asset-key { color: var(--muted); font-size: .75rem; margin: 0 0 16px; }
.asset-key-link { display: inline-flex; align-items: center; gap: 4px; min-height: 32px; font-weight: 600; white-space: nowrap; }
.asset-mobile-card .asset-key-link { min-height: 44px; }
.asset-facts { margin: 0; }
.asset-facts > div { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 12px; padding: 9px 0; border-top: 1px solid var(--border); font-size: .8rem; }
.asset-facts dt { color: var(--muted); }
.asset-facts dd { margin: 0; text-align: right; font-weight: 600; overflow-wrap: anywhere; }
.asset-mobile-card .row-edit { margin-top: 12px; width: 100%; }
.asset-group { margin-bottom: 24px; }
.asset-group-heading { font-size: 1rem; margin: 0 0 12px; }
.desktop-asset-list { display: none; }
.empty-state { padding: 32px 24px; text-align: center; }
.empty-state .section-icon { margin-bottom: 14px; }
.empty-state p { max-width: 480px; margin-left: auto; margin-right: auto; }
.spinner { text-align: center; padding: 24px; color: var(--muted); }
#htmx-loading { position: fixed; inset: 0; background: rgba(0,50,36,.4); display: none; align-items: center; justify-content: center; z-index: 1000; padding: 16px; }
#htmx-loading.is-visible { display: flex; }
#htmx-loading .panel { background: var(--white); border-radius: 16px; padding: 28px 32px; box-shadow: var(--shadow-lg); text-align: center; width: min(100%,300px); }
#htmx-loading .spinner-ring { width: 40px; height: 40px; border: 4px solid var(--plant-20); border-top-color: var(--plant); border-radius: 50%; margin: 0 auto 12px; animation: spin 800ms linear infinite; }
#htmx-loading .label { color: var(--plant); font-weight: 600; }
#htmx-error { position: fixed; left: 16px; right: 16px; bottom: 16px; max-width: 560px; margin: 0 auto; padding: 16px; background: var(--danger); color: var(--white); border-radius: 10px; box-shadow: var(--shadow-lg); font-weight: 600; display: none; z-index: 1100; }
#htmx-error.is-visible { display: block; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (min-width: 640px) {
  :scope { padding: 32px 24px 48px; }
  header.topbar { padding: 8px 24px; }
  .site-footer { padding: 22px 24px; }
  .action-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 20px; }
  .action-card { padding: 28px; min-height: 248px; }
  .action-card h2 { font-size: 1.3rem; }
  .guide-steps { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 24px; }
  .card { padding: 32px; }
  .form-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 24px; }
  .field-full { grid-column: 1 / -1; }
  .form-actions { flex-direction: row-reverse; align-items: center; }
  .form-actions button, .form-actions .btn { width: auto; }
  .photo-actions { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .filter-search-row { grid-template-columns: minmax(0,1.4fr) minmax(0,1fr); }
  .js .asset-filter-details summary { display: none; }
  .refresh-assets { margin-left: auto !important; }
  .page-numbers { display: flex; }
  .mobile-page-number { display: none; }
}
@media (min-width: 1024px) {
  :scope { padding: 40px 32px 56px; }
  header.topbar { padding: 8px 32px; gap: 24px; flex-wrap: nowrap; }
  button.nav-toggle { display: none; }
  .site-nav, .js .site-nav, .js .site-nav.is-open { display: flex; flex-direction: row; width: auto; }
  .site-footer { padding: 24px 32px; }
  .home-intro { margin-bottom: 32px; padding-top: 12px; }
  .scan-grid { grid-template-columns: minmax(0,1.15fr) minmax(0,1fr); gap: 24px; align-items: stretch; }
  .scan-grid .card { padding: 32px; }
  .workflow-guide { display: grid; grid-template-columns: minmax(0, .7fr) minmax(0, 2fr); gap: 32px; padding-top: 32px; margin-top: 36px; }
  .guide-steps { margin: 0; }
  .desktop-asset-list { display: block; }
  .mobile-asset-list, .mobile-asset-groups { display: none; }
  .filter-select-row { grid-template-columns: repeat(4,minmax(0,1fr)); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .action-card:hover { transform: none; }
}

/* User access administration */
.access-head > .btn { width: auto; flex-shrink: 0; }
.access-search { display: flex; align-items: end; gap: 16px; }
.access-search > div:first-child { flex: 1; min-width: 0; }
.access-search > div:nth-child(2) { width: 200px; }
.access-search button { width: auto; }
.access-list { display: grid; gap: 12px; margin: 20px 0; }
.access-account { display: grid; grid-template-columns: minmax(200px,1fr) minmax(240px,1.3fr) auto; gap: 24px; align-items: center; margin: 0; }
.access-account h2 { font-size: 1.05rem; margin: 0 0 6px; overflow-wrap: anywhere; }
.access-account-person p { overflow-wrap: anywhere; }
.access-account-rights p { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 0; }
.access-state { font-weight: 600; font-size: .85rem; color: var(--plant); }
.access-state-disabled { color: #785700; }
.access-edit-layout { display: grid; grid-template-columns: minmax(0,2fr) minmax(260px,1fr); gap: 24px; align-items: start; }
.access-form { margin: 0; }
.access-identity { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.access-option { display: flex; align-items: start; gap: 12px; padding: 16px; border: 1px solid var(--line, #b9c9c3); border-radius: 8px; cursor: pointer; min-height: 76px; margin: 0; font-weight: 400; }
.access-option:has(input:checked) { background: #eef5f0; border-color: var(--plant); }
.access-option input[type=checkbox] { flex: 0 0 20px; width: 20px; height: 20px; min-height: 0; margin: 2px 0 0; accent-color: var(--plant); }
.access-option strong { display: block; font-size: .95rem; }
.access-option small { display: block; font-size: .85rem; color: var(--muted); margin-top: 6px; font-weight: 400; }
.access-enabled { margin: 24px 0; }
.access-permissions { border: 0; margin: 24px 0; padding: 0; min-width: 0; }
.access-permissions legend { font-size: 1.1rem; font-weight: 600; margin-bottom: 14px; }
.access-options { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.access-options > div { display: grid; }
.access-form-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.access-form-actions button, .access-form-actions .btn { width: auto; }
.access-help .card { margin: 0 0 20px; }
.access-help p { font-size: .9rem; overflow-wrap: anywhere; }
.access-history { padding-left: 20px; font-size: .85rem; }
.access-history > li { padding: 12px 0; border-bottom: 1px solid var(--line,#b9c9c3); }
.access-history ul { padding-left: 16px; }
.access-history p { margin: 6px 0; }
.access-form .errorlist { color: #9b3021; padding-left: 20px; font-size: .9rem; }
@media (max-width: 1050px) {
  .access-account { grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .access-account > .btn { justify-self: start; }
  .access-edit-layout { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .access-search { display: grid; grid-template-columns: 1fr; }
  .access-search > div:nth-child(2) { width: auto; }
  .access-account, .access-identity, .access-options { grid-template-columns: 1fr; }
  .access-account { gap: 14px; }
  .access-form-actions > *, .access-form-actions .btn, .access-form-actions button { width: 100%; }
}

/* Comparison of durable Jira and AX snapshots. */
.reconcile-sources { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 24px; }
.reconcile-sources > div { padding: 14px 20px; border: 1px solid var(--border); border-radius: 8px; background: var(--white); }
.reconcile-sources strong, .reconcile-sources span { display: block; }
.reconcile-sources span { font-size: .85rem; color: var(--muted); }
.reconcile-checkbox { display: flex; align-items: center; gap: 12px; min-height: 44px; font-weight: 400; margin-top: 12px; }
.reconcile-checkbox input { width: 20px; height: 20px; min-height: 0; margin: 0; accent-color: var(--plant); }
.reconcile-counts { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 10px; margin: 24px 0; }
.reconcile-count { display: flex; flex-direction: column; padding: 14px; border: 1px solid var(--border); border-radius: 8px; background: var(--white); text-decoration: none; }
.reconcile-count strong { font-size: 1.6rem; line-height: 1.2; }
.reconcile-count span { font-size: .8rem; margin-top: 6px; }
.reconcile-count:hover, .reconcile-count.is-current { border-color: var(--plant); background: var(--ok-tint); }
.reconcile-table { table-layout: fixed; min-width: 0; }
.reconcile-table th:nth-child(1), .reconcile-table th:nth-child(2) { width: 36%; }
.reconcile-table th:nth-child(3) { width: 28%; }
.reconcile-table .group-row th { width: auto; }
.reconcile-table td { vertical-align: top; padding: 20px; }
.reconcile-asset-name { font-size: 1rem; font-weight: 600; line-height: 1.25; margin: 10px 0 6px; }
.reconcile-reference { display: inline-block; font-size: .8rem; margin: 0 0 14px; overflow-wrap: anywhere; }
.reconcile-sub { display: block; color: var(--muted); font-size: .75rem; font-weight: 400; margin-top: 4px; }
.reconcile-facts { margin: 0; font-size: .82rem; }
.reconcile-facts > div { display: grid; grid-template-columns: 100px minmax(0,1fr); gap: 10px; padding: 5px 0; }
.reconcile-facts dt { color: var(--muted); }
.reconcile-facts dd { margin: 0; overflow-wrap: anywhere; }
.reconcile-serial { font-family: Consolas,monospace; }
.reconcile-status { display: inline-flex; padding: 5px 9px; border-radius: 6px; background: var(--plant-10); color: var(--fg-dim); font-size: .8rem; font-weight: 600; }
.reconcile-status-matched { background: var(--ok-tint); color: var(--plant); }
.reconcile-status-assignment_diff { background: var(--warn-tint); color: var(--danger); }
.reconcile-status-review { background: #fff1d3; color: var(--seeds-text); }
.reconcile-reason { color: var(--muted); font-size: .8rem; margin: 10px 0 0; }
.reconcile-empty { color: var(--muted); font-size: .85rem; margin: 0; }
.reconcile-card { margin-bottom: 16px; padding: 20px; }
.reconcile-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 18px; }
.reconcile-source-card { border: 1px solid var(--border); border-radius: 8px; padding: 14px; min-width: 0; }
.source-title { font-size: .85rem; padding-bottom: 12px; border-bottom: 1px solid var(--border); }
.reconcile-help { margin-top: 24px; padding: 20px 0; border-top: 1px solid var(--border); font-size: .85rem; color: var(--muted); }
.reconcile-help summary { min-height: 44px; cursor: pointer; font-weight: 600; color: var(--plant); }
.reconcile-help p { margin: 12px 0; }
#reconcile-filters .filter-search-row + .filter-search-row { margin-top: 16px; }
@media (max-width: 639px) {
  .reconcile-sources, .reconcile-pair { grid-template-columns: 1fr; }
  .reconcile-counts { grid-template-columns: 1fr 1fr; }
  .reconcile-facts > div { grid-template-columns: 90px minmax(0,1fr); }
  .reconcile-count { padding: 12px; }
}

:scope{min-height:0;display:block;padding:0;width:100%;max-width:none;margin:0}.inventory-tabs{display:flex;gap:8px;overflow-x:auto;padding-bottom:16px;margin-bottom:20px;border-bottom:1px solid var(--border)}.inventory-tabs a{white-space:nowrap;padding:9px 13px;text-decoration:none;border-radius:7px;font-size:13px}.inventory-tabs a[aria-current]{background:var(--plant);color:white}.inventory-status:empty{display:none}.inventory-status{padding:12px;background:#fff6df;border-radius:8px}.inventory-page{min-width:0}.inventory-photo{max-width:100%;max-height:220px;object-fit:contain;border-radius:8px;margin-bottom:16px}input[readonly]{background:#f2f2f2}button{cursor:pointer}
}
