:root {
  --ink: #002858; --soft: #505C6E; --bg: #F1F6FB; --white: #FFF; --line: #D5DBE3;
  --accent: #0068B8; --accent-dark: #004F8F; --danger: #B3241B; --ok: #15703C; --warn: #8A5200;
  --head: "Montserrat", "Segoe UI", Arial, sans-serif;
  --body: "Public Sans", "Segoe UI", Arial, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 15px/1.5 var(--body); }
a { color: var(--accent); }
h1, h2, h3 { font-family: var(--head); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: 1.75rem; } h2 { font-size: 1.15rem; } h3 { font-size: 1rem; margin-top: 1em; }
p { margin: 0 0 .7em; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
small { display: block; color: var(--soft); font-size: .84rem; }
.muted { color: var(--soft); }
.hint { font-size: .9rem; max-width: 75ch; }
.warn { color: var(--warn); background: #FBF2DF; padding: 8px 11px; border-radius: 6px; font-size: .93rem; }

.shell { display: grid; grid-template-columns: 216px minmax(0, 1fr); min-height: 100vh; }
.side { background: var(--ink); padding: 18px 12px; display: flex; flex-direction: column; gap: 2px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.side a { color: #DCE3EC; text-decoration: none; padding: 8px 10px; border-radius: 6px; }
.side a:hover { background: rgba(255,255,255,.1); }
.side a[aria-current="page"] { background: var(--white); color: var(--ink); font-weight: 700; }
.side-brand { display: block; flex: none; background: var(--white); border-radius: 6px; padding: 8px 10px !important; margin-bottom: 12px; }
.side-brand:hover { background: var(--white) !important; }
.side-brand img { width: 100%; min-width: 120px; }
.side-end { margin-top: auto; display: flex; flex-direction: column; gap: 2px; }
.side-end button { width: 100%; text-align: left; background: none; border: 0; color: #DCE3EC; font: inherit; padding: 8px 10px; border-radius: 6px; cursor: pointer; }
.side-end button:hover { background: rgba(255,255,255,.1); }
.side-end small { color: #A8B4C4; padding: 8px 10px 0; overflow-wrap: anywhere; }
.pill { background: #F0B429; color: var(--ink); border-radius: 10px; padding: 0 7px; font-size: .8rem; font-weight: 700; }
.content { padding: 24px 28px 56px; min-width: 0; }

.head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.head h1, .head h2 { margin: 0; }
.head.small { margin-bottom: 10px; }
.head-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.btn { display: inline-block; padding: 9px 16px; background: var(--accent); color: var(--white); border: 1px solid var(--accent); border-radius: 6px; font: 700 .94rem var(--body); text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--accent-dark); }
.btn.ghost { background: var(--white); color: var(--accent); }
.btn.ghost:hover { background: #E9EEFB; }
.btn.small { padding: 5px 10px; font-size: .84rem; }
.link { background: none; border: 0; padding: 0; color: var(--accent); text-decoration: underline; font: inherit; cursor: pointer; }
.danger { color: var(--danger) !important; }

.flash { padding: 9px 13px; border-radius: 6px; background: #E5F4EA; color: var(--ok); margin-bottom: 10px; }
.flash.error { background: #FBE9E7; color: #9B1C14; }
.job { padding: 9px 13px; border-radius: 6px; margin-bottom: 8px; }
.job.running { background: #E8EEFC; color: var(--accent-dark); }
.job.failed { background: #FBE9E7; color: #9B1C14; }
.job.done { background: #E5F4EA; color: var(--ok); }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 22px; }
.stats a { background: var(--white); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; text-decoration: none; color: var(--soft); }
.stats b { display: block; color: var(--ink); font: 700 1.8rem/1.1 var(--head); }
.columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; margin-bottom: 20px; }

.panel { background: var(--white); border: 1px solid var(--line); border-radius: 8px; padding: 18px 20px; margin-bottom: 16px; }
.table-wrap { position: relative; overflow-x: auto; background: var(--white); border: 1px solid var(--line); border-radius: 8px; margin-bottom: 12px; }
table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-weight: 700; font-size: .84rem; color: var(--soft); background: #F8FAFB; white-space: nowrap; }
th, td { padding: 8px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
.num { text-align: right; }
table.mini th { background: none; }
table.mini { margin-bottom: 10px; font-size: .92rem; }
.tag { display: inline-block; padding: 1px 9px; border-radius: 10px; font-size: .82rem; font-weight: 700; background: #E7EBF0; color: var(--ink); white-space: nowrap; }
.tag.live, .tag.completed, .tag.returned { background: #DDF1E4; color: var(--ok); }
.tag.won { background: #DDF1E4; color: var(--ok); }
.tag.contacted, .tag.quoted { background: #E1E9FB; color: var(--accent-dark); }
.tag.new { background: #FBEBC8; color: var(--warn); }
.tag.paid, .tag.shipped, .tag.confirmed, .tag.out { background: #E1E9FB; color: var(--accent-dark); }
.tag.cancelled { background: #F8E1DF; color: var(--danger); }

.filters { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.tabs { display: flex; gap: 4px; }
.tabs a { padding: 7px 14px; border-radius: 6px; text-decoration: none; color: var(--ink); background: var(--white); border: 1px solid var(--line); }
.tabs a[aria-current="page"] { background: var(--ink); border-color: var(--ink); color: var(--white); font-weight: 700; }
.find { display: flex; gap: 6px; }
.find input { margin: 0; width: 260px; max-width: 100%; }

.inventory { min-width: 880px; }
.inventory .photo { width: 62px; }
.inventory .photo img { width: 46px; height: 46px; object-fit: contain; background: var(--white); border: 1px solid var(--line); border-radius: 4px; }
.nophoto { display: grid; place-items: center; width: 46px; height: 46px; font-size: .72rem; color: var(--soft); border: 1px dashed var(--line); border-radius: 4px; }
.inventory .name { min-width: 220px; }
.inventory .name a { font-weight: 500; }
input:where(:not([type=checkbox]):not([type=radio]):not([type=color]):not([type=file])), select, textarea { display: block; width: 100%; padding: 8px 10px; margin-top: 3px; border: 1px solid #AEB8C5; border-radius: 6px; background: var(--white); color: var(--ink); font: 400 .95rem var(--body); }
.inventory input.cell { width: 96px; margin: 0 0 0 auto; text-align: right; border-color: transparent; background: #F4F6F9; font-variant-numeric: tabular-nums; }
.inventory input.cell:hover { border-color: #AEB8C5; }
.inventory input.cell:focus { background: var(--white); border-color: var(--accent); }
.inventory input.cell.low { background: #FBEBC8; font-weight: 700; }
.inventory input.cell.saved { background: #DDF1E4; }
.inventory input.cell.bad { background: #F8E1DF; border-color: var(--danger); }
.inventory select.cell { width: 86px; margin: 0; }
.inventory select.status-live { background: #DDF1E4; font-weight: 700; }
.save-note { min-height: 1.4em; font-size: .92rem; color: var(--ok); }
.save-note.error { color: var(--danger); }

label { display: block; font-weight: 500; font-size: .92rem; margin-bottom: 12px; }
input[type=file] { display: block; margin-top: 6px; font: inherit; max-width: 100%; }
input[type=color] { display: block; margin-top: 4px; width: 70px; height: 38px; padding: 2px; border: 1px solid #AEB8C5; border-radius: 6px; background: var(--white); }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 16px; }
.full { grid-column: 1 / -1; }
.check { display: block; font-weight: 500; }
.check input { margin-right: 6px; }
.check small { margin-left: 22px; font-weight: 400; }
.checks { display: grid; gap: 4px; }
.inline { display: inline-flex; align-items: center; gap: 8px; }
.inline select { width: 70px; margin: 0; }
.save-bar { display: flex; justify-content: flex-end; gap: 10px; padding: 8px 0; }
.delete-form { margin-top: 14px; text-align: right; }
.row-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.ai-tools { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.ai-tools h3 { margin-top: 0; }
.ai-draft { border-left: 4px solid var(--accent); }
.ai-draft p, .ai-draft li { max-width: 75ch; }

.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; margin-bottom: 8px; }
.photo-card { margin: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.photo-card.waiting { border: 2px dashed #C98A12; }
.photo-card img { width: 100%; aspect-ratio: 1; object-fit: contain; background: #F7F8FA; }
.photo-card figcaption { padding: 8px 10px 10px; }
.mini-actions { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 6px; }
.mini-actions button { background: none; border: 0; padding: 0; color: var(--accent); font: inherit; font-size: .86rem; text-decoration: underline; cursor: pointer; }

.banner-row { display: grid; grid-template-columns: 180px minmax(0, 1fr) auto; gap: 16px; align-items: center; background: var(--white); border: 1px solid var(--line); border-radius: 8px; padding: 10px; margin-bottom: 10px; }
.banner-row.off { opacity: .68; }
.banner-thumb { height: 76px; border-radius: 6px; overflow: hidden; display: grid; place-items: center; color: var(--white); font-weight: 700; font-size: .8rem; text-align: center; padding: 0; }
.banner-thumb img { width: 100%; height: 100%; object-fit: cover; }
.banner-info h2 { margin-bottom: 2px; font-size: 1.02rem; }
.banner-info p { margin: 0; font-size: .88rem; }
.banner-preview { max-height: 180px; width: 100%; object-fit: cover; border-radius: 6px; margin-bottom: 14px; }
.status-form { display: flex; gap: 6px; align-items: center; }
.status-form select { width: 116px; margin: 0; }
dl.totals { display: grid; grid-template-columns: 1fr auto; gap: 3px 18px; max-width: 280px; margin: 12px 0 0 auto; }
dl.totals dd { margin: 0; text-align: right; }
.switch-row { display: grid; grid-template-columns: 50px minmax(0, 1fr); gap: 12px; align-items: start; padding: 12px 0; margin: 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.switch-row:last-child { border-bottom: 0; padding-bottom: 0; }
.switch-row small { font-weight: 400; max-width: 70ch; margin-top: 2px; }
.switch-row input { position: absolute; opacity: 0; width: 46px; height: 26px; margin: 0; cursor: pointer; }
.switch-track { position: relative; display: block; width: 46px; height: 26px; border-radius: 13px; background: #8A96A6; transition: background-color .12s; }
.switch-track::after { content: ""; position: absolute; left: 3px; top: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--white); transition: transform .12s; }
.switch-row input:checked + .switch-track { background: var(--accent); }
.switch-row input:checked + .switch-track::after { transform: translateX(20px); }
.switch-row input:focus-visible + .switch-track { outline: 3px solid var(--accent); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .switch-track, .switch-track::after { transition: none; } }
.blank { text-align: center; padding: 44px 16px; background: var(--white); border: 1px dashed #AEB8C5; border-radius: 8px; }

.login-body { display: grid; place-items: center; min-height: 100vh; padding: 16px; background: var(--ink); }
.login { background: var(--white); padding: 28px; border-radius: 10px; width: 100%; max-width: 380px; }
.login h1 { font-size: 1.2rem; margin-bottom: 14px; }
.login-logo { width: 220px; margin-bottom: 18px; }

.side-links { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.menu-btn { display: none; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 16px; }
.market { font-size: 1.05rem; }
code { font-size: .88rem; background: #E8EFF7; padding: 1px 5px; border-radius: 4px; overflow-wrap: anywhere; }
.copy-line code { display: block; padding: 8px 10px; }
.pick { display: inline-flex; align-items: center; justify-content: center; position: relative; margin: 0; cursor: pointer; }
.pick input, .tool input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.pick:focus-within, .tool:focus-within { outline: 3px solid var(--accent); outline-offset: 2px; }
.picked { display: flex; flex-wrap: wrap; gap: 10px; margin: 10px 0 6px; }
.picked:empty { display: none; }
.picked-item { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 6px; background: var(--bg); border-radius: 6px; }
.picked-item img { width: 72px; height: 72px; object-fit: cover; border-radius: 4px; }
.pct-wrap { display: inline-flex; align-items: center; gap: 3px; justify-content: flex-end; }
.inventory input.cell.pct { width: 62px; }
.row-tools { white-space: nowrap; }
.row-tools form { display: inline-flex; gap: 8px; margin-right: 8px; }
.tool { display: inline-block; position: relative; margin: 0; padding: 0; background: none; border: 0; color: var(--accent); font: inherit; font-size: .88rem; font-weight: 500; text-decoration: underline; cursor: pointer; }
.tool.busy { opacity: .5; }
.inventory { min-width: 1080px; }

@media (max-width: 980px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .side { position: sticky; top: 0; z-index: 10; height: auto; flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; padding: 8px 12px; overflow: visible; }
  .side-brand { margin: 0; width: 132px; padding: 5px 8px !important; }
  .side-brand img { min-width: 0; }
  .menu-btn { display: block; min-height: 44px; padding: 0 16px; background: none; border: 1px solid #7E93B0; border-radius: 6px; color: var(--white); font: 700 .95rem var(--body); cursor: pointer; }
  .side-links { flex-basis: 100%; padding-top: 8px; max-height: calc(100vh - 70px); overflow-y: auto; }
  .js .side:not(.open) .side-links { display: none; }
  .side a:not(.side-brand) { padding: 12px 10px; }
  .side-end { margin: 8px 0 0; border-top: 1px solid rgba(255,255,255,.2); padding-top: 8px; }
  .side-end button { padding: 12px 10px; }
  .columns, .ai-tools { grid-template-columns: minmax(0, 1fr); }
  .content { padding: 18px 16px 48px; }
}
@media (max-width: 640px) {
  .stats, .grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid2 { grid-template-columns: minmax(0, 1fr); }
  .banner-row { grid-template-columns: minmax(0, 1fr); }
  .find, .find input { width: 100%; }
}

/* Phones: comfortable to tap, no zoom on focus, tables as labelled cards */
@media (max-width: 760px) {
  input:where(:not([type=checkbox]):not([type=radio]):not([type=color]):not([type=file])), select, textarea { font-size: 16px; min-height: 44px; }
  .btn { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; }
  .head .btn { flex: none; }
  .mini-actions { gap: 4px 14px; }
  .mini-actions button { min-height: 36px; padding: 4px 0; font-size: .92rem; }
  .tabs { flex-wrap: wrap; }
  .tabs a { padding: 10px 14px; }
  .save-bar { position: sticky; bottom: 0; background: var(--bg); padding: 10px 0; flex-wrap: wrap; }
  .save-bar .btn { flex: 1; }
  .row-actions .btn { flex: 1; }
  .grid3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .switch-row { padding: 14px 0; }
  .check { min-height: 44px; }
  .check input { width: 20px; height: 20px; vertical-align: -4px; }
  input[type=file] { min-height: 44px; }
  .delete-form .link { padding: 12px 0; }
  table.stack td:not(.name) a { padding: 6px 0; }
  .table-wrap:has(.stack) { background: none; border: 0; overflow: visible; }
  table.stack, table.stack tbody { display: block; min-width: 0; }
  table.stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  table.stack tr { display: block; background: var(--white); border: 1px solid var(--line); border-radius: 8px; padding: 6px 12px; margin-bottom: 10px; }
  table.stack td { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 40px; padding: 7px 0; text-align: right; border-bottom: 1px solid #E8EDF3; overflow-wrap: anywhere; }
  table.stack tr td:last-child { border-bottom: 0; }
  table.stack td[data-label]::before { content: attr(data-label); flex: none; color: var(--soft); font-size: .84rem; font-weight: 700; text-align: left; }
  table.stack td small { display: block; }
  .inventory.stack .photo { justify-content: flex-start; float: left; border: 0; min-height: 0; padding: 4px 12px 4px 0; width: auto; }
  .inventory.stack .photo::before { display: none; }
  .inventory.stack .photo img, .inventory.stack .nophoto { width: 58px; height: 58px; }
  .inventory.stack .name { display: block; text-align: left; min-height: 66px; }
  .inventory.stack .name::before { display: none; }
  .inventory.stack td:nth-child(3) { clear: both; }
  .inventory input.cell, .inventory input.cell.pct { width: 130px; background: #F1F5F9; }
  .inventory select.cell { width: 130px; }
  .pct-wrap { gap: 5px; }
  .pct-wrap input.cell.pct { width: 113px; }
  .row-tools { flex-wrap: wrap; justify-content: flex-start; white-space: normal; }
  .row-tools::before { display: none; }
  .row-tools form { margin: 0; gap: 8px; }
  .tool { display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px; border: 1px solid var(--accent); border-radius: 6px; text-decoration: none; background: var(--white); }
  .status-form { flex: 1; justify-content: flex-end; }
  dl.totals { max-width: none; }
}


/* ========== Visual style: built from the logo's navy, blue, cyan and wave ========== */
body { background: #F3F7FB; }
h1 { font-weight: 800; letter-spacing: -.02em; font-size: clamp(1.5rem, 2.4vw, 1.95rem); }
.side { background: linear-gradient(180deg, #002858, #001C40); padding: 16px 12px; }
.side-brand { border-radius: 12px; }
.side a:not(.side-brand) { display: flex; align-items: center; gap: 11px; border-radius: 10px; color: #C9D8E8; font-weight: 500; transition: background-color .12s, color .12s; }
.side a:not(.side-brand)::before { content: ""; width: 19px; height: 19px; flex: none; background: currentColor; }
.side a[aria-current="page"], .side a[aria-current="page"]:hover { background: rgba(255,255,255,.13); color: var(--white); box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); }
.side a[aria-current="page"]::before { background: #00C8F8; }
.side a[data-i="dash"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='8' height='8' rx='2'/%3E%3Crect x='13' y='3' width='8' height='5' rx='2'/%3E%3Crect x='13' y='11' width='8' height='10' rx='2'/%3E%3Crect x='3' y='14' width='8' height='7' rx='2'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='8' height='8' rx='2'/%3E%3Crect x='13' y='3' width='8' height='5' rx='2'/%3E%3Crect x='13' y='11' width='8' height='10' rx='2'/%3E%3Crect x='3' y='14' width='8' height='7' rx='2'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="inventory"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 8l-9-5-9 5 9 5 9-5z'/%3E%3Cpath d='M3 8v8l9 5 9-5V8'/%3E%3Cpath d='M12 13v8'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 8l-9-5-9 5 9 5 9-5z'/%3E%3Cpath d='M3 8v8l9 5 9-5V8'/%3E%3Cpath d='M12 13v8'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="banners"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='16' rx='2'/%3E%3Ccircle cx='9' cy='10' r='1.5'/%3E%3Cpath d='M21 16l-5-5-9 9'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='16' rx='2'/%3E%3Ccircle cx='9' cy='10' r='1.5'/%3E%3Cpath d='M21 16l-5-5-9 9'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="orders"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 3h14v18l-3-2-2 2-2-2-2 2-2-2-3 2z'/%3E%3Cpath d='M9 8h6M9 12h6'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 3h14v18l-3-2-2 2-2-2-2 2-2-2-3 2z'/%3E%3Cpath d='M9 8h6M9 12h6'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="rentals"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='16' rx='2'/%3E%3Cpath d='M3 10h18M8 3v4M16 3v4'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='16' rx='2'/%3E%3Cpath d='M3 10h18M8 3v4M16 3v4'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="quotes"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 4h16v12H9l-5 4z'/%3E%3Cpath d='M8 9h8M8 12h5'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 4h16v12H9l-5 4z'/%3E%3Cpath d='M8 9h8M8 12h5'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="payments"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='5' width='20' height='14' rx='2'/%3E%3Cpath d='M2 10h20M6 15h4'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='5' width='20' height='14' rx='2'/%3E%3Cpath d='M2 10h20M6 15h4'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="display"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 12s4-7 10-7 10 7 10 7-4 7-10 7-10-7-10-7z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 12s4-7 10-7 10 7 10 7-4 7-10 7-10-7-10-7z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="team"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='8' r='3.5'/%3E%3Cpath d='M2.5 20c.6-4 3.2-6 6.5-6s5.9 2 6.5 6'/%3E%3Cpath d='M16 4.8a3.5 3.5 0 010 6.4M18 14.5c2 .7 3.2 2.700 3.500 5.500'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='8' r='3.5'/%3E%3Cpath d='M2.5 20c.6-4 3.2-6 6.5-6s5.9 2 6.5 6'/%3E%3Cpath d='M16 4.8a3.5 3.5 0 010 6.4M18 14.5c2 .7 3.2 2.700 3.500 5.500'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="settings"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3Cpath d='M12 2v3M12 19v3M2 12h3M19 12h3M4.900 4.900l2.100 2.100M17 17l2.100 2.100M19.100 4.900L17 7M7 17l-2.100 2.100'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3Cpath d='M12 2v3M12 19v3M2 12h3M19 12h3M4.900 4.900l2.100 2.100M17 17l2.100 2.100M19.100 4.900L17 7M7 17l-2.100 2.100'/%3E%3C/svg%3E") center/contain no-repeat; }
.side a[data-i="store"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 9l1.500-5h13L20 9'/%3E%3Cpath d='M4 9a2.700 2.700 0 005.300 0 2.700 2.700 0 005.400 0 2.700 2.700 0 005.300 0'/%3E%3Cpath d='M5 12v8h14v-8'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 9l1.500-5h13L20 9'/%3E%3Cpath d='M4 9a2.700 2.700 0 005.300 0 2.700 2.700 0 005.400 0 2.700 2.700 0 005.300 0'/%3E%3Cpath d='M5 12v8h14v-8'/%3E%3C/svg%3E") center/contain no-repeat; }
.side-end button { display: flex; align-items: center; gap: 11px; border-radius: 10px; color: #C9D8E8; font-weight: 500; }
.side-end button::before { content: ""; width: 19px; height: 19px; flex: none; background: currentColor; -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 4H5v16h5'/%3E%3Cpath d='M14 8l4 4-4 4M18 12H9'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 4H5v16h5'/%3E%3Cpath d='M14 8l4 4-4 4M18 12H9'/%3E%3C/svg%3E") center/contain no-repeat; }
.pill { margin-left: auto; background: #00C8F8; color: #001C40; }
.content { padding: 28px 32px 60px; }
.btn { border: 0; border-radius: 11px; padding: 10px 18px; background: linear-gradient(135deg, #0A7AD1, #0058A6); box-shadow: 0 7px 16px rgba(0,88,166,.24); transition: transform .15s, box-shadow .15s, filter .15s; }
.btn:hover { background: linear-gradient(135deg, #0A7AD1, #0058A6); transform: translateY(-1px); filter: brightness(1.06); }
.btn.ghost, .btn.ghost:hover { background: var(--white); color: var(--accent); box-shadow: inset 0 0 0 1px #A9C9E4; filter: none; }
.stats { gap: 14px; }
.stats a { border: 0; border-radius: 16px; padding: 16px 18px; box-shadow: 0 0 0 1px #E2EAF2, 0 10px 24px rgba(0,40,88,.05); transition: transform .15s, box-shadow .15s; }
.stats a:hover { transform: translateY(-2px); box-shadow: 0 0 0 1px #BCD6EC, 0 14px 28px rgba(0,40,88,.1); }
.stats a:first-child { background: linear-gradient(135deg, #004F8F, #001C40); color: #CFE3F5; box-shadow: 0 14px 28px rgba(0,40,88,.22); }
.stats a:first-child b { color: var(--white); }
.stats b { font-weight: 800; font-size: 2rem; }
.panel { border: 0; border-radius: 16px; padding: 22px; box-shadow: 0 0 0 1px #E2EAF2, 0 10px 24px rgba(0,40,88,.04); }
.panel h2 { font-weight: 800; font-size: 1.1rem; }
.table-wrap { border: 0; border-radius: 16px; box-shadow: 0 0 0 1px #E2EAF2, 0 10px 24px rgba(0,40,88,.04); }
th { background: #F7FAFD; padding-top: 11px; padding-bottom: 11px; }
tbody tr { transition: background-color .1s; }
tbody tr:hover { background: #F8FBFE; }
.tabs { padding: 4px; gap: 3px; background: var(--white); border-radius: 12px; box-shadow: 0 0 0 1px #E2EAF2; }
.tabs a, .tabs a[aria-current="page"] { border: 0; border-radius: 9px; }
.tabs a { background: none; }
.tabs a[aria-current="page"] { background: var(--ink); }
input:where(:not([type=checkbox]):not([type=radio]):not([type=color]):not([type=file])), select, textarea { border-radius: 10px; border-color: #C9D6E3; transition: border-color .12s, box-shadow .12s; }
input:where(:not([type=checkbox]):not([type=radio]):not([type=color]):not([type=file])):focus, select:focus, textarea:focus { outline: 0; border-color: var(--accent); box-shadow: 0 0 0 4px rgba(0,200,248,.2); }
.inventory input.cell { border-radius: 8px; }
.inventory select.cell { border-radius: 8px; }
.inventory .photo img, .nophoto { border-radius: 10px; }
.tool { text-decoration: none; padding: 5px 9px; border-radius: 8px; background: #E8F2FB; color: #004F8F; font-weight: 600; font-size: .82rem; transition: background-color .12s; }
.tool:hover { background: #D4E8F8; }
.row-tools form { gap: 5px; margin-right: 5px; }
.switch-row input:checked + .switch-track { background: linear-gradient(135deg, #0A7AD1, #00A7E8); }
.ai-draft { border-left: 0; background: linear-gradient(180deg, #F0F8FE, #FFFFFF 140px); box-shadow: 0 0 0 1px #BCD6EC, 0 14px 30px rgba(0,88,166,.08); }
.market strong { color: var(--accent-dark); font-size: 1.15em; }
.photo-card { border: 0; border-radius: 14px; box-shadow: 0 0 0 1px #E2EAF2; }
.photo-card.waiting { border: 0; box-shadow: 0 0 0 2px #E6A823; }
.banner-row { border: 0; border-radius: 16px; box-shadow: 0 0 0 1px #E2EAF2, 0 10px 24px rgba(0,40,88,.04); }
.banner-thumb { border-radius: 10px; }
.blank { border: 1px dashed #B5CADF; border-radius: 16px; }
.flash, .job, .warn { border-radius: 11px; }
.login-body { background: linear-gradient(135deg, #001C40, #004F8F 75%, #0068B8); }
.login { border-radius: 20px; box-shadow: 0 30px 70px rgba(0,16,40,.45); }

@media (max-width: 980px) {
  .side { padding: 8px 12px; }
  .content { padding: 20px 16px 48px; }
  .side a:not(.side-brand) { padding: 12px 10px; }
  .side a.side-brand { background: var(--white); }
}
@media (max-width: 760px) {
  .table-wrap:has(.stack) { box-shadow: none; border-radius: 0; }
  table.stack tr { border: 0; border-radius: 16px; padding: 8px 14px; box-shadow: 0 0 0 1px #E2EAF2, 0 8px 18px rgba(0,40,88,.05); }
  tbody tr:hover { background: var(--white); }
  .tool { padding: 0 12px; border: 0; background: #E8F2FB; border-radius: 10px; }
  .panel { padding: 18px; }
  .stats a { padding: 13px 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .btn:hover, .stats a:hover { transform: none; }
}

/* Photos being resized before upload */
form.preparing .save-bar .btn { opacity: .65; }
form.preparing .save-bar::before { content: "Preparing photos"; align-self: center; margin-right: auto; color: var(--soft); font-size: .9rem; }

/* RavunoQ stock sync (2.1) */
.side a[data-i="sync"]::before { -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 7H8a4 4 0 00-4 4v1M4 17h12a4 4 0 004-4v-1'/%3E%3Cpath d='M17 4l3 3-3 3M7 20l-3-3 3-3'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 7H8a4 4 0 00-4 4v1M4 17h12a4 4 0 004-4v-1'/%3E%3Cpath d='M17 4l3 3-3 3M7 20l-3-3 3-3'/%3E%3C/svg%3E") center/contain no-repeat; }
input.synced, input[readonly] { background: #EEF3F8; color: var(--soft); cursor: not-allowed; }
td.num small { display: block; font-size: .72rem; color: var(--soft); margin-top: 2px; }
.key-panel { box-shadow: 0 0 0 2px var(--accent), 0 10px 24px rgba(0,40,88,.06); }
.inline-form { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.inline-form .grow { flex: 1 1 320px; }
.button-row { display: flex; gap: 10px; flex-wrap: wrap; }
.btn.danger { background: var(--danger); color: #fff !important; }

/* Show/hide password and forgot password (2.2) */
.pw-wrap { position: relative; display: block; }
.pw-wrap input { width: 100%; padding-right: 46px; }
.pw-eye { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 38px; height: 38px; display: grid; place-items: center;
  border: 0; border-radius: 8px; background: transparent; color: var(--soft); cursor: pointer; padding: 0; }
.pw-eye:hover { color: var(--accent); background: rgba(0,104,184,.08); }
.pw-eye:focus-visible { outline: 3px solid var(--accent); outline-offset: 1px; }
.pw-eye .pw-slash { display: none; }
.pw-eye[aria-pressed="true"] .pw-slash { display: inline; }
.login-alt { margin-top: 14px; text-align: center; font-size: .92rem; }
.login-alt a { color: var(--accent); font-weight: 600; }
.login p + p, .login p + form, .login p + ul { margin-top: 10px; }
.login-help { padding-left: 1.1em; display: grid; gap: 8px; margin: 10px 0; }
.set-pw { margin-bottom: 6px; }
.set-pw summary { cursor: pointer; color: var(--accent); font-weight: 600; font-size: .9rem; }
.set-pw form { margin-top: 8px; display: grid; gap: 8px; min-width: 220px; }
