:root {
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  color: #1b2740;
  background: #f5f7fb;
  font-synthesis: none;
  --brand: #1668c9;
  --border: #e3e8ef;
  --muted: #6b7684;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  display: flex;
}
button,
input,
select {
  font: inherit;
}
button,
a,
select {
  touch-action: manipulation;
}
button {
  cursor: pointer;
}
button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
a {
  color: var(--brand);
  text-decoration: none;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid #87c9ad;
  outline-offset: 3px;
}
.sidebar {
  width: 242px;
  position: fixed;
  inset: 0 auto 0 0;
  background: #fff;
  border-right: 1px solid var(--border);
  padding: 35px 22px;
  display: flex;
  flex-direction: column;
}
.logo {
  display: flex;
  align-items: center;
  font-size: 29px;
  letter-spacing: -1.3px;
  font-weight: 750;
  color: #203c31;
  gap: 2px;
}
.logo-mark {
  background: #1668c9;
  color: white;
  font-size: 27px;
  width: 37px;
  height: 38px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 9px;
  position: relative;
}
.logo-mark span {
  font-size: 18px;
  position: absolute;
  right: 2px;
  top: 0;
}
.accent {
  color: #1f8fe0;
}
.workspace {
  border: 1px solid var(--border);
  border-radius: 9px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 10px;
  margin: 34px 0;
  font-size: 12px;
  font-weight: 600;
}
.workspace-icon {
  background: #eef2f8;
  border-radius: 7px;
  padding: 8px;
  color: #54675b;
  font-size: 11px;
}
.workspace small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 400;
  margin-top: 5px;
}
.dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: #32946d;
  border-radius: 50%;
  flex-shrink: 0;
}
.workspace .dot {
  margin-left: auto;
}
.nav-label {
  font-size: 9px;
  letter-spacing: 1.6px;
  color: #98a1b0;
  margin: 0 10px 14px;
}
.nav {
  width: 100%;
  border: 0;
  background: none;
  text-align: left;
  padding: 13px 12px;
  color: #69766e;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  border-radius: 7px;
  margin: 4px 0;
}
.nav > span {
  font-size: 20px;
  min-width: 19px;
}
.nav b {
  margin-left: auto;
  font-size: 10px;
  background: #e6eee9;
  padding: 3px 6px;
  border-radius: 4px;
}
.nav.active {
  background: #eaf2fb;
  color: #1668c9;
  font-weight: 650;
}
.sidebar-bottom {
  margin-top: auto;
  padding: 20px 10px 0;
}
.local {
  font-size: 11px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sidebar-bottom p {
  font-size: 11px;
  color: #8d9891;
  line-height: 1.8;
}
.version {
  font-size: 9px;
  letter-spacing: 1.2px;
  color: #a4ada7;
}
main {
  margin-left: 242px;
  flex: 1;
  min-width: 0;
}
.topbar {
  height: 77px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 42px;
  background: #fff;
  font-size: 11px;
  color: #6d7c73;
}
.slash {
  margin: 0 13px;
  color: #b7c0ba;
}
.user {
  display: flex;
  gap: 8px;
  align-items: center;
}
.user b {
  border-radius: 50%;
  background: #eaf0ec;
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  font-size: 10px;
  margin-left: 12px;
}
.content {
  padding: 39px 42px 20px;
  max-width: 1650px;
  margin: auto;
}
.page-intro {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 30px;
}
.eyebrow {
  font-size: 9px;
  letter-spacing: 1.8px;
  color: var(--brand);
  font-weight: 700;
}
h1 {
  font-size: 29px;
  letter-spacing: -0.9px;
  margin: 10px 0;
}
p {
  color: var(--muted);
  line-height: 1.65;
  font-size: 12px;
}
.page-intro p {
  margin: 0;
  font-size: 13px;
}
.primary,
.secondary,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 11px 16px;
  border-radius: 7px;
  border: 1px solid transparent;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.primary {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 2px 3px #173c1510;
}
.primary:hover {
  background: #106446;
}
.secondary {
  border-color: var(--border);
  background: #fff;
  color: #506458;
}
.secondary:hover {
  background: #f1f6f3;
}
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 28px;
}
.metrics article {
  padding: 20px 21px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
}
.metrics article > span {
  font-size: 11px;
  color: #6d7b73;
}
.metrics strong {
  display: block;
  font-size: 30px;
  letter-spacing: -1px;
  font-weight: 650;
  margin: 13px 0 8px;
}
.metrics strong span {
  font-size: 20px;
  margin-left: 3px;
  color: #899a8f;
}
.metrics small {
  color: #98a29b;
  font-size: 10px;
}
.panel {
  background: white;
  border: 1px solid var(--border);
  border-radius: 11px;
  overflow: hidden;
}
.panel-heading {
  padding: 23px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
}
h2 {
  font-size: 15px;
  margin: 0;
  font-weight: 650;
}
.panel-heading p {
  font-size: 11px;
  margin: 7px 0 0;
}
.count {
  font-size: 10px;
  padding: 3px 7px;
  background: #f0f4f9;
  color: #829188;
  border-radius: 5px;
  margin-left: 8px;
}
.filters {
  display: flex;
  gap: 12px;
  padding: 0 24px 20px;
}
.search {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0 12px;
  max-width: 560px;
}
.search span {
  font-size: 22px;
  color: #849a8c;
}
.search input {
  border: 0;
  padding: 12px 0;
  width: 100%;
  outline: none;
  font-size: 11px;
}
select {
  border: 1px solid var(--border);
  border-radius: 6px;
  color: #6e7d73;
  background: white;
  padding: 0 13px;
  font-size: 11px;
}
.table-wrap {
  overflow: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}
th {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.7px;
  background: #f8faf9;
  color: #8c9890;
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
td {
  padding: 17px 20px;
  border-bottom: 1px solid #edf1f7;
  font-size: 11px;
}
td strong {
  font-size: 12px;
  font-weight: 600;
  display: block;
  max-width: 330px;
}
td small {
  display: block;
  margin-top: 6px;
  color: #8b9a90;
  font-size: 10px;
}
.product-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}
.product-icon {
  border: 1px solid var(--border);
  border-radius: 8px;
  min-width: 36px;
  height: 39px;
  background: #f5f8f5;
  color: #8ba190;
  display: grid;
  place-items: center;
  font-size: 18px;
}
.pill {
  display: inline-block;
  background: #edf5ef;
  color: #537f61;
  padding: 5px 8px;
  border-radius: 5px;
  font-size: 9px;
  white-space: nowrap;
}
.pill.amber {
  background: #fff5e5;
  color: #aa7a32;
}
.progress {
  width: 82px;
  height: 4px;
  background: #edf1f7;
  border-radius: 3px;
  margin-top: 6px;
  overflow: hidden;
}
.progress i {
  display: block;
  height: 100%;
  background: #56a47c;
  width: 0;
}
.empty {
  text-align: center;
  padding: 43px 20px 45px;
}
.empty-symbol {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  background: #eff6f1;
  color: #548d68;
  font-size: 29px;
  border-radius: 14px;
  margin: 0 auto 17px;
}
.empty h3 {
  font-size: 15px;
  font-weight: 600;
}
.empty p {
  font-size: 12px;
}
.empty > a {
  display: block;
  font-size: 10px;
  margin-top: 15px;
}
.table-footer {
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  padding: 14px 23px;
  font-size: 10px;
  color: #9aa59e;
}
.workflow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 1px dashed #d9e3dc;
  border-radius: 10px;
  padding: 23px 27px;
  margin-top: 24px;
  gap: 15px;
}
.workflow h3 {
  display: inline;
  font-size: 11px;
  font-weight: 600;
  margin-left: 7px;
}
.workflow p {
  font-size: 10px;
  margin: 8px 0 0;
}
.step {
  font-size: 9px;
  color: #699279;
  background: #e9f1eb;
  border-radius: 4px;
  padding: 4px;
}
.connector {
  color: #b3c1b7;
}
.footnote {
  text-align: center;
  font-size: 10px;
  color: #a3ada6;
  padding: 27px;
}
.footnote span {
  margin-right: 5px;
}
.hidden {
  display: none !important;
}
.notice {
  background: #edf4ef;
  color: #587561;
  border: 1px solid #dbe8df;
  padding: 16px 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-size: 12px;
  line-height: 1.7;
}
.cards {
  padding: 0 24px 24px;
}
.card {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 18px;
  margin-top: 12px;
}
.card-head {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  align-items: center;
}
.card h3 {
  font-size: 13px;
  margin: 0;
}
.card p {
  margin: 6px 0;
}
.card a {
  font-size: 11px;
  overflow-wrap: anywhere;
}
.card table {
  margin: 15px 0;
}
.card td {
  overflow-wrap: anywhere;
  max-width: 350px;
  white-space: pre-wrap;
}
.card th {
  padding: 10px;
}
.card td {
  padding: 10px;
}
.card-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.card .muted {
  font-size: 10px;
}
.icon-button {
  border: 0;
  background: transparent;
  font-size: 22px;
  color: #748b7c;
  cursor: pointer;
}
.empty-inline {
  padding: 40px 15px;
  text-align: center;
  color: #89998e;
  font-size: 12px;
}
.muted {
  color: var(--muted);
}
dialog {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 28px;
  width: min(760px, 94vw);
  max-height: 88vh;
  color: #1b2740;
  box-shadow: 0 20px 80px #142d3029;
}
dialog::backdrop {
  background: #152e2459;
  backdrop-filter: blur(3px);
}
.dialog-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}
.dialog-heading h2 {
  font-size: 21px;
  margin-top: 7px;
}
dialog label {
  font-size: 12px;
  display: block;
}
dialog input:not([type="checkbox"]) {
  display: block;
  width: 100%;
  margin-top: 9px;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px;
  background: white;
}
.file-drop {
  margin: 20px 0;
  padding: 20px;
  border: 1px dashed #bad2c4;
  border-radius: 9px;
  background: #f6faf7;
  color: #537762;
}
dialog a {
  font-size: 12px;
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 22px;
}
.error-list {
  color: #a94b38;
  font-size: 12px;
  background: #fff4ef;
  padding: 15px;
  max-height: 180px;
  overflow: auto;
}
.success-box {
  background: #edf7f0;
  padding: 14px;
  border-radius: 6px;
  color: #377449;
  font-size: 12px;
}
.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin: 23px 0;
}
.detail-grid div {
  background: #f7f9fc;
  border: 1px solid var(--border);
  padding: 12px;
  border-radius: 7px;
  overflow-wrap: anywhere;
  font-size: 12px;
  white-space: pre-wrap;
}
.detail-grid small {
  display: block;
  color: #89988d;
  font-size: 10px;
  margin-bottom: 7px;
}
.toast {
  position: fixed;
  bottom: 25px;
  right: 25px;
  background: #213f30;
  color: white;
  max-width: 550px;
  padding: 16px 22px;
  z-index: 10;
  border-radius: 9px;
  font-size: 13px;
  box-shadow: 0 8px 30px #0002;
}
.toast.error {
  background: #8d3f33;
}
.research-links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.research-links a {
  border: 1px solid var(--border);
  padding: 9px 12px;
  border-radius: 6px;
}
.checkbox {
  accent-color: var(--brand);
}
@media (min-width: 1500px) {
  .content {
    padding-top: 48px;
  }
  .empty {
    padding: 65px 20px;
  }
}
@media (max-width: 1100px) {
  .sidebar {
    width: 205px;
    padding: 30px 15px;
  }
  main {
    margin-left: 205px;
  }
  .content {
    padding: 28px 24px;
  }
  .topbar {
    padding: 0 24px;
  }
  .metrics {
    gap: 10px;
  }
  .metrics article {
    padding: 17px 14px;
  }
  .metrics small {
    font-size: 9px;
  }
  .workflow {
    padding: 20px 15px;
  }
  .workflow h3 {
    font-size: 10px;
  }
}
@media (max-width: 760px) {
  .sidebar {
    position: static;
    width: 100%;
    padding: 17px;
    gap: 12px;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
  body {
    display: block;
  }
  .logo {
    font-size: 25px;
  }
  .workspace,
  .nav-label,
  .sidebar-bottom {
    display: none;
  }
  .sidebar nav {
    display: flex;
    gap: 3px;
  }
  .nav {
    padding: 9px 7px;
    font-size: 10px;
    justify-content: center;
  }
  .nav > span {
    display: none;
  }
  .nav b {
    margin-left: 0;
  }
  .topbar {
    height: 50px;
    padding: 0 18px;
  }
  main {
    margin: 0;
  }
  .content {
    padding: 25px 16px;
  }
  .page-intro {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
  }
  h1 {
    font-size: 25px;
  }
  .metrics {
    grid-template-columns: 1fr 1fr;
  }
  .metrics small {
    font-size: 9px;
  }
  .panel-heading {
    padding: 20px 15px;
    flex-wrap: wrap;
  }
  .filters {
    padding: 0 15px 18px;
    flex-direction: column;
  }
  select {
    padding: 11px;
  }
  .workflow {
    flex-direction: column;
    align-items: flex-start;
  }
  .connector {
    display: none;
  }
  .workflow div {
    padding: 6px;
  }
  .table-footer {
    gap: 15px;
    line-height: 1.5;
  }
  .cards {
    padding: 0 12px 15px;
  }
  .card {
    padding: 12px;
  }
  .card table {
    font-size: 10px;
  }
  .card td {
    max-width: 100px;
  }
  .detail-grid {
    grid-template-columns: 1fr;
  }
  .toast {
    left: 15px;
    right: 15px;
    bottom: 15px;
  }
  .user b {
    display: none;
  }
}
.intro-actions {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
}
.editor-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 17px;
  margin: 24px 0;
}
.editor-grid .wide {
  grid-column: 1/-1;
}
textarea {
  font: inherit;
  display: block;
  width: 100%;
  margin-top: 9px;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px;
  resize: vertical;
  font-size: 13px;
  line-height: 1.6;
}
input[readonly] {
  color: #84978b;
  background: #f3f6fa !important;
}
#editor-review h3 {
  font-size: 14px;
  margin-top: 25px;
}
#editor-review td {
  max-width: 240px;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}
.edit-detail-button {
  float: right;
}
#editor-review {
  margin-top: 20px;
}
@media (max-width: 760px) {
  .editor-grid {
    grid-template-columns: 1fr;
  }
  .intro-actions {
    width: 100%;
  }
  .intro-actions button {
    flex: 1;
  }
  .edit-detail-button {
    float: none;
    margin-bottom: 15px;
  }
}
.advanced-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0 24px 20px;
}
.advanced-filters select {
  padding: 10px;
  max-width: 280px;
}
.pagination {
  display: flex;
  align-items: center;
  gap: 9px;
}
.pagination label {
  display: flex;
  align-items: center;
  gap: 7px;
}
.pagination select {
  padding: 6px;
}
.pagination button {
  padding: 6px 10px;
}
.category-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
  padding: 0 24px 24px;
}
.category-cards .card {
  margin: 0;
  min-width: 0;
}
.category-cards h3 {
  overflow-wrap: anywhere;
}
.category-cards .card-head {
  align-items: flex-start;
}
.category-cards .empty-inline {
  grid-column: 1/-1;
}
@media (max-width: 760px) {
  .sidebar nav {
    flex-wrap: wrap;
  }
  .sidebar .nav {
    width: auto;
    flex: 1 1 28%;
  }
  .advanced-filters {
    padding: 0 15px 15px;
  }
  .advanced-filters select {
    flex: 1;
    min-width: 120px;
  }
  .table-footer {
    flex-direction: column;
  }
  .pagination {
    justify-content: space-between;
  }
  .category-cards {
    padding: 0 15px 15px;
  }
}

.photo-tools {
  padding: 0 24px 20px;
  display: grid;
  gap: 14px;
}
.photo-tools label {
  display: grid;
  gap: 8px;
  font-size: 12px;
}
.photo-tools input,
.photo-tools select {
  min-width: 0;
  width: 100%;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: white;
}
.photo-tools form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: end;
}
.photo-tools p {
  margin: 0;
}
.photo-gallery {
  padding: 0 24px 24px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(235px, 1fr));
  gap: 16px;
}
.photo-card {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}
.photo-card img {
  width: 100%;
  height: 210px;
  object-fit: contain;
  background: #f7f9fc;
  border-radius: 7px;
}
.photo-card .card-actions {
  flex-wrap: wrap;
  justify-content: flex-start;
}
.photo-card .pill {
  align-self: flex-start;
}
.photo-gallery .empty-inline {
  grid-column: 1/-1;
}
@media (max-width: 760px) {
  .photo-tools {
    padding: 0 15px 20px;
  }
  .photo-tools form {
    grid-template-columns: 1fr;
  }
  .photo-gallery {
    padding: 0 15px 20px;
  }
}

.fiscal-form {
  padding: 0 24px 24px;
  max-width: 750px;
}
.fiscal-form fieldset {
  border: 0;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 14px;
  min-width: 0;
}
.fiscal-form label {
  font-size: 13px;
  font-weight: 600;
}
.fiscal-form input,
.fiscal-form select {
  width: 100%;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: white;
  font: inherit;
}
.fiscal-form #fiscal-period-group label {
  display: block;
  margin-bottom: 12px;
}
.fiscal-form p {
  font-size: 13px;
  line-height: 1.6;
}
.fiscal-form button {
  justify-self: start;
}
.fiscal-form fieldset:disabled {
  opacity: 0.6;
}
@media (max-width: 760px) {
  .fiscal-form {
    padding: 0 15px 20px;
  }
}

.login-layout {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.login-card {
  flex: initial;
  margin: 0;
  width: min(100%, 480px);
  padding: 36px;
  background: white;
  border: 1px solid #dfe6df;
  border-radius: 18px;
  box-shadow: 0 14px 50px #183b2010;
}
.login-card .logo {
  margin-bottom: 32px;
}
.login-card h1 {
  font-size: 30px;
  line-height: 1.2;
}
.login-card form {
  display: grid;
  gap: 16px;
  margin: 24px 0;
}
.login-card label {
  display: grid;
  gap: 8px;
}
.login-card input {
  width: 100%;
  padding: 12px;
  border: 1px solid #ccd8cc;
  border-radius: 8px;
}
.login-card #access-error {
  color: #a12626;
  margin: 0;
}
.login-card .eyebrow {
  margin: 12px 0;
}
.login-card .muted {
  font-size: 13px;
}

.product-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}
.product-update {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
}
.product-update span {
  font-size: 20px;
  line-height: 1;
}
.update-options {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0;
}
.update-options button {
  flex: 1 1 210px;
  min-height: 48px;
}
.product-update:focus-visible {
  outline: 3px solid #18643c;
  outline-offset: 3px;
}

.photo-search-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.photo-selection-bar {
  padding: 20px 24px;
  background: #f2f7fc;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.photo-selection-bar p {
  flex-basis: 100%;
  font-size: 13px;
  margin: 0;
}
.photo-pick {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
}
.photo-card:has(input[data-photo-pick]:checked) {
  outline: 3px solid #187c51;
}
.photo-pick input {
  width: 20px;
  height: 20px;
}
#image-search-form {
  display: grid;
  gap: 16px;
}
#image-search-form label {
  display: grid;
  gap: 8px;
}
#image-search-key {
  padding: 12px;
  width: 100%;
}

/* Consistent left/right edges and control heights across forms. */
input,
select,
textarea {
  box-sizing: border-box;
  font: inherit;
  max-width: 100%;
}
dialog label,
.editor-grid label,
.photo-tools label,
.fiscal-form label {
  min-width: 0;
}
dialog input:not([type="checkbox"]),
dialog select,
dialog textarea,
.photo-tools input:not([type="checkbox"]),
.photo-tools select,
.fiscal-form input,
.fiscal-form select {
  width: 100%;
  min-width: 0;
  display: block;
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 11px 12px;
  margin-top: 8px;
  min-height: 44px;
  background: white;
  color: inherit;
}
dialog textarea {
  min-height: 100px;
  resize: vertical;
}
.editor-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
}
.editor-grid label {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
}
.editor-grid input,
.editor-grid textarea,
.photo-tools input,
.photo-tools select,
.fiscal-form input,
.fiscal-form select {
  margin-top: 0;
}
.fiscal-form {
  max-width: none;
  width: 100%;
}
.filters {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(200px, 3fr);
  align-items: stretch;
}
.filters .search {
  max-width: none;
  min-width: 0;
  width: 100%;
}
.filters select,
.filters .search {
  min-height: 44px;
  width: 100%;
}
.advanced-filters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  align-items: stretch;
}
.advanced-filters select {
  max-width: none;
  width: 100%;
  min-height: 44px;
}
.photo-product-controls {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}
.photo-tools.photo-product-controls label > input:not([type="checkbox"]) {
  margin-top: 0;
}
.photo-product-controls small:empty {
  display: none;
}
#photo-form {
  grid-template-columns: minmax(0, 1fr) auto;
}
#photo-form button {
  min-height: 44px;
}
#photo-rights-form > label {
  margin-top: 16px;
}
#image-search-form input {
  margin-top: 0;
}
@media (max-width: 760px) {
  .filters,
  .advanced-filters,
  .photo-product-controls,
  .editor-grid,
  #photo-form {
    grid-template-columns: minmax(0, 1fr);
  }
  .advanced-filters select {
    min-width: 0;
  }
  .photo-search-actions button {
    width: 100%;
  }
}

/* Local SVG icons share one visual weight and alignment baseline. */
.ui-icon {
  display: inline-block;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
  vertical-align: middle;
  pointer-events: none;
}
.nav > span {
  width: 22px;
  min-width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.nav .ui-icon {
  width: 21px;
  height: 21px;
}
.nav {
  min-height: 46px;
  align-items: center;
  line-height: 1.3;
}
.primary .ui-icon,
.secondary .ui-icon,
.button .ui-icon {
  width: 17px;
  height: 17px;
}
.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 7px;
  flex: 0 0 auto;
}
.icon-button .ui-icon {
  width: 20px;
  height: 20px;
}
.icon-button:hover {
  background: #edf5f0;
  color: var(--brand);
}
.logo-mark .ui-icon {
  width: 25px;
  height: 25px;
  stroke-width: 1.65;
}
.logo-mark {
  margin-right: 9px;
}
.product-icon .ui-icon {
  width: 20px;
  height: 20px;
}
.empty-symbol .ui-icon {
  width: 27px;
  height: 27px;
}
.search > span {
  display: flex;
  align-items: center;
}
.search .ui-icon {
  width: 18px;
  height: 18px;
}
.connector .ui-icon {
  width: 18px;
  height: 18px;
}
.footnote .ui-icon {
  width: 13px;
  height: 13px;
}
.product-update > span {
  display: flex;
  align-items: center;
}
.card a .ui-icon {
  width: 14px;
  height: 14px;
  margin-left: 3px;
}

.photo-original-url {
  display: grid;
  gap: 7px;
  font-size: 11px;
  min-width: 0;
}
.photo-original-url input {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 10px;
  background: #f7f9fc;
  font-size: 11px;
}
#image-search-provider {
  width: 100%;
  min-height: 44px;
}

.search-sites {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.search-sites label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}
.search-sites input[type="checkbox"] {
  width: 18px;
  min-height: 18px;
  flex: 0 0 18px;
}
#image-search-marketplaces {
  border: 1px solid var(--line, #d8e1ec);
  border-radius: 10px;
  padding: 16px;
  margin: 16px 0;
}
#image-search-marketplaces[hidden] {
  display: none;
}
@media (max-width: 600px) {
  .search-sites {
    grid-template-columns: 1fr;
  }
}

.photo-card .pill {
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.5;
}
#image-search-form .search-sites label {
  display: flex;
  align-items: center;
  gap: 8px;
}

#image-search-form [hidden] {
  display: none !important;
}
.results-filters {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
}
.fiscal-results {
  margin: 18px 0;
}
.fiscal-results table {
  width: 100%;
  min-width: 420px;
}
.fiscal-results th,
.fiscal-results td {
  text-align: left;
  vertical-align: top;
  white-space: normal;
  overflow-wrap: anywhere;
}
.fiscal-results .pill {
  white-space: normal;
}
.fiscal-results details {
  margin-top: 12px;
}
#search-results .card {
  min-width: 0;
}
#search-results a {
  overflow-wrap: anywhere;
}
@media (max-width: 600px) {
  .results-filters {
    grid-template-columns: 1fr;
  }
}

#photo-workspace:not(.hidden) {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 24px;
  padding: 20px;
  align-items: start;
}
#workspace-editor,
.product-media {
  min-width: 0;
}
#workspace-editor {
  position: static;
  margin: 0;
  padding: 24px;
  border-radius: 12px;
}
#workspace-editor #editor-fields {
  max-height: 55vh;
  overflow: auto;
  padding: 2px 8px 10px 0;
}
#workspace-editor input,
#workspace-editor textarea {
  display: block;
  width: 100%;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 11px 12px;
  background: white;
  color: inherit;
}
#workspace-editor textarea {
  resize: vertical;
}
#workspace-editor .close-dialog[hidden] {
  display: none;
}
#workspace-editor .dialog-actions {
  flex-wrap: wrap;
}
#workspace-editor #editor-review {
  max-height: 35vh;
  overflow: auto;
}
#workspace-editor #reason-label {
  display: block;
  margin-top: 16px;
}
#workspace-editor #editor-status {
  min-height: 36px;
}
.product-media .photo-gallery {
  grid-template-columns: repeat(auto-fill, minmax(235px, 1fr));
  padding: 0;
  gap: 16px;
}
.product-media {
  border-top: 1px solid var(--border);
  padding-top: 24px;
}
.editor-tabs {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--border);
  margin: 20px 0;
}
.editor-tabs button {
  border: 0;
  border-bottom: 3px solid transparent;
  background: none;
  padding: 14px 18px;
  color: var(--muted);
  font-weight: 600;
}
.editor-tabs button[aria-selected="true"] {
  border-bottom-color: var(--brand);
  color: var(--brand);
  background: #f2f8f5;
}
.editor-tabs span {
  background: #e3eee7;
  padding: 3px 7px;
  border-radius: 6px;
  margin-left: 6px;
}
.selected-photo-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.selected-photo-heading h3 {
  font-size: 16px;
}
.editor-photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(165px, 1fr));
  gap: 16px;
  margin: 18px 0;
}
.selected-photo-card {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.selected-photo-card img {
  width: 100%;
  height: 155px;
  object-fit: contain;
  background: #f7f9fc;
  border-radius: 7px;
}
.selected-photo-card .pill {
  white-space: normal;
}
.editor-photo-grid .empty-inline {
  grid-column: 1/-1;
}
#workspace-editor .editor-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 900px) {
  #workspace-editor .editor-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .selected-photo-heading {
    flex-wrap: wrap;
  }
}
@media (max-width: 600px) {
  #workspace-editor .editor-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  #workspace-editor {
    padding: 16px;
  }
  .editor-tabs button {
    padding: 12px;
  }
  .editor-photo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.product-media .photo-tools {
  padding: 16px;
}
.product-media #photo-form {
  grid-template-columns: minmax(0, 1fr);
}
.product-media .intro-actions,
.product-media .photo-search-actions {
  flex-wrap: wrap;
}
.product-media .photo-tools button {
  max-width: 100%;
}
@media (max-width: 1100px) {
  #photo-workspace:not(.hidden) {
    grid-template-columns: minmax(0, 1fr);
  }
  #workspace-editor {
    position: static;
  }
  #workspace-editor #editor-fields {
    max-height: 50vh;
  }
}
@media (max-width: 600px) {
  #photo-workspace:not(.hidden) {
    padding: 10px;
    gap: 12px;
  }
  .product-media .photo-gallery {
    grid-template-columns: minmax(0, 1fr);
  }
}

.photo-open {
  padding: 0;
  border: 0;
  background: transparent;
  width: 100%;
  cursor: zoom-in;
}
.photo-open img {
  display: block;
}
#photo-viewer {
  width: min(920px, 94vw);
  max-width: 94vw;
}
#photo-viewer-image {
  display: block;
  width: 100%;
  height: 65vh;
  object-fit: contain;
  background: #f7f9fc;
}
#photo-viewer-download {
  margin-top: 12px;
}
.all-found-fields {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px;
  background: #f7fafd;
  margin-bottom: 24px;
}
.all-found-fields table {
  min-width: 600px;
}
.all-found-fields td,
.all-found-fields th {
  vertical-align: top;
  white-space: normal;
  max-width: 420px;
  overflow-wrap: anywhere;
}
.all-found-fields .found-value {
  white-space: pre-wrap;
  color: #1b2740;
  font-size: 12px;
}
.all-found-fields select {
  max-width: 100%;
  width: 100%;
  padding: 10px;
}
.all-found-fields input {
  width: 18px;
  height: 18px;
}
.all-found-fields > button {
  margin-top: 16px;
}
/* Named search batches */
#jobs-form {
  padding: 0 28px 24px;
}
#jobs-page > .panel {
  margin-bottom: 24px;
}
.batch-fields {
  display: grid;
  grid-template-columns: 2fr 1fr 1.5fr;
  gap: 20px;
  align-items: start;
}
.batch-fields label,
.batch-selection label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}
.batch-fields input,
.batch-fields select,
.batch-selection input {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  min-height: 44px;
  border: 1px solid #d8e1de;
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  color: #183c34;
  font: inherit;
  margin: 0;
}
.batch-fields input:focus,
.batch-fields select:focus,
.batch-selection input:focus {
  outline: 2px solid #91caba;
  outline-offset: 1px;
}
.batch-selection {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: end;
  margin-top: 24px;
}
.batch-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-top: 20px;
  flex-wrap: wrap;
}
.batch-product-list {
  max-height: 480px;
  overflow: auto;
}
.batch-card progress {
  width: 100%;
  height: 12px;
  accent-color: #178066;
}
.batch-result {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 20px;
  padding: 18px 0;
  border-bottom: 1px solid #dfe7e5;
}
.batch-result > div {
  min-width: 0;
}
.batch-result small {
  display: block;
  margin-top: 5px;
}
.batch-result p {
  overflow-wrap: anywhere;
}
.batch-result > button {
  flex-shrink: 0;
}
.batch-results {
  max-height: 600px;
  overflow: auto;
}
.batch-card .card-head > div {
  min-width: 0;
}
.batch-card h3 {
  overflow-wrap: anywhere;
}
@media (max-width: 760px) {
  #jobs-form {
    padding: 0 16px 20px;
  }
  .batch-fields,
  .batch-selection {
    grid-template-columns: 1fr;
  }
  .batch-result {
    flex-direction: column;
  }
  .batch-footer {
    align-items: stretch;
  }
  .batch-footer > .primary {
    width: 100%;
  }
}
#source-engine-status {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 20px 0;
}
#source-engine-status .card {
  min-width: 0;
  margin: 0;
}
#sources-page > .panel + .panel {
  margin-top: 20px;
}
#sources-page .photo-tools .intro-actions {
  align-items: flex-end;
  gap: 16px;
}
#sources-page .photo-tools .intro-actions > button {
  align-self: flex-end;
  min-height: 44px;
}
@media (max-width: 900px) {
  #source-engine-status {
    grid-template-columns: 1fr;
  }
}
.unopim-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 20px 0;
}
.unopim-options label {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.unopim-options input,
.unopim-options select {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}
.unopim-mapping {
  margin: 16px 0;
}
#unopim-preview .intro-actions {
  margin: 16px 0;
  align-items: center;
}
#unopim-preview details p {
  max-width: 550px;
  overflow-wrap: anywhere;
}
@media (max-width: 700px) {
  .unopim-options {
    grid-template-columns: 1fr;
  }
}

/* ---- Interface refresh: compact gallery, grouped editor, report summaries ---- */
.pill.grey {
  background: #eef1f6;
  color: #6d7873;
}
.pill.match-high {
  background: #e3f3ea;
  color: #1d6b47;
}
.pill.match-mid {
  background: #fff5e5;
  color: #aa7a32;
}
.pill.match-low {
  background: #fbeceb;
  color: #a04b3f;
}
b.count {
  font-weight: 500;
}
.gallery-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
  padding: 0 0 14px;
}
.chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.chip {
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 11px;
  font-weight: 600;
  color: #506458;
  display: inline-flex;
  gap: 6px;
  align-items: center;
}
.chip b {
  background: #eef2f8;
  border-radius: 999px;
  padding: 2px 7px;
  font-size: 10px;
}
.chip.active {
  background: #eaf2fb;
  border-color: #bcdccb;
  color: var(--brand);
}
.chip.active b {
  background: #d5eadf;
}
.gallery-tools {
  display: flex;
  align-items: flex-end;
  gap: 10px;
}
.gallery-tools label {
  display: grid;
  gap: 6px;
  font-size: 11px;
  color: var(--muted);
}
.gallery-tools select {
  min-height: 40px;
  padding: 0 10px;
}
.gallery-tools .secondary {
  min-height: 40px;
}
.photo-selection-bar {
  position: sticky;
  top: 0;
  z-index: 5;
  border: 1px solid #d7e6dc;
  border-radius: 10px;
  padding: 12px 16px;
}
.photo-selection-bar p {
  flex-basis: 100%;
  font-size: 11px;
}
.product-media .photo-gallery {
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}
.photo-card {
  gap: 10px;
  padding: 10px;
}
.photo-card.status-rejected {
  opacity: 0.7;
}
.photo-card.unavailable .photo-frame {
  outline: 2px dashed #e2b4ad;
  border-radius: 7px;
}
.photo-frame {
  position: relative;
}
.photo-frame img {
  width: 100%;
  height: 170px;
  object-fit: contain;
  background: #f7f9fc;
  border-radius: 7px;
  display: block;
}
.photo-frame .photo-pick {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  background: #fff;
  border-radius: 6px;
  padding: 4px;
  box-shadow: 0 1px 4px #0002;
  margin: 0;
}
.photo-frame .photo-pick input {
  width: 18px;
  height: 18px;
  display: block;
  margin: 0;
}
.photo-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  background: var(--brand);
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 4px 7px;
  border-radius: 5px;
  text-transform: uppercase;
}
.photo-open {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
}
a.photo-open {
  cursor: pointer;
}
.photo-meta {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.photo-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.photo-card .pill {
  white-space: nowrap;
}
.photo-title {
  margin: 0;
  font-size: 11px;
  color: #1b2740;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.photo-source {
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}
.photo-meta small {
  color: #8b9a90;
  font-size: 10px;
}
.photo-quick {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.photo-quick .primary,
.photo-quick .secondary,
.photo-quick .button {
  padding: 7px 10px;
  font-size: 11px;
}
.photo-more {
  border-top: 1px solid #edf1f7;
  padding-top: 8px;
}
.photo-more summary {
  font-size: 11px;
  color: var(--muted);
  cursor: pointer;
}
.photo-more .card-actions {
  justify-content: flex-start;
  flex-wrap: wrap;
  margin-top: 8px;
}
.photo-more .card-actions .secondary,
.photo-more .card-actions .button {
  padding: 7px 10px;
  font-size: 11px;
}
.photo-more p {
  font-size: 11px;
  margin: 6px 0;
}
.gallery-more {
  width: 100%;
  margin-top: 14px;
}
#photo-counter {
  font-weight: 500;
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  font-size: 12px;
}
.feedback-summary {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12px;
}
.feedback-summary span {
  background: #f2f7fc;
  border: 1px solid #d7e6dc;
  padding: 8px 12px;
  border-radius: 7px;
}
#photo-feedback details {
  margin-top: 8px;
  font-size: 11px;
}
#photo-feedback summary {
  cursor: pointer;
  color: var(--muted);
}
#photo-feedback p {
  margin: 6px 0 0;
}
#editor-fields.editor-grid {
  display: block;
  margin: 16px 0;
}
.editor-group {
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 0 14px 14px;
  margin-bottom: 12px;
}
.editor-group:not([open]) {
  padding-bottom: 0;
}
.editor-group summary {
  cursor: pointer;
  padding: 12px 0;
  font-size: 12px;
  font-weight: 650;
  display: flex;
  align-items: center;
  gap: 8px;
}
.editor-group summary b {
  font-weight: 500;
  font-size: 10px;
  color: var(--muted);
  background: #f0f4f9;
  padding: 2px 7px;
  border-radius: 5px;
}
.editor-group .editor-grid {
  margin: 0;
}
#photo-search-count {
  font-size: 10px;
  color: var(--muted);
}
.product-media .photo-tools {
  padding: 16px 0;
}
.report-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.report-head h3 {
  margin: 0 0 4px;
}
.report-head small {
  color: var(--muted);
  font-size: 11px;
}
.fiscal-results > summary {
  cursor: pointer;
  font-size: 12px;
  font-weight: 650;
  padding: 10px 0;
}
.row-missing td,
.row-missing th {
  color: #9aa59e;
}
#product-data-report .notice {
  margin: 10px 0;
}
@media (max-width: 760px) {
  .gallery-toolbar {
    align-items: stretch;
  }
  .gallery-tools {
    flex-wrap: wrap;
  }
  .photo-selection-bar {
    position: static;
  }
}

/* Manual mode: step 1 (Atualizar dados) and step 2 (Fotos do produto) */
.nav-more {
  margin: 4px 0;
}
.nav-more > summary {
  list-style: none;
  cursor: pointer;
}
.nav-more > summary::-webkit-details-marker {
  display: none;
}
.nav-more > summary b {
  margin-left: 8px;
}
.nav-more > summary::after {
  content: "";
  margin-left: auto;
  width: 8px;
  height: 8px;
  border-right: 2px solid #98a1b0;
  border-bottom: 2px solid #98a1b0;
  transform: rotate(45deg);
  transition: transform 0.2s;
  flex-shrink: 0;
}
.nav-more[open] > summary::after {
  transform: rotate(-135deg);
}
.nav-more.has-active > summary {
  color: #1668c9;
  font-weight: 650;
}
.nav-more-list {
  margin: 2px 0 6px 14px;
  padding-left: 6px;
  border-left: 2px solid #e6eee9;
}
.nav-more-list .nav {
  padding: 10px 12px;
  min-height: 40px;
  font-size: 12.5px;
}
#data-workspace:not(.hidden) {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 24px;
  padding: 20px;
  align-items: start;
}
.data-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
}
/* Ações da tela Atualizar dados: ícones em cores fortes (verde buscar, azul sites, vermelho descartar). */
#product-data-search,
#data-sites-settings,
#product-data-dismiss {
  color: #fff;
  border-color: transparent;
  box-shadow: 0 2px 4px #0000001f;
}
#product-data-search {
  background: #0f7b3f;
}
#product-data-search:hover {
  background: #0b5f30;
}
#data-sites-settings {
  background: #1d4ed8;
}
#data-sites-settings:hover {
  background: #1e40af;
}
#product-data-dismiss {
  background: #c62828;
}
#product-data-dismiss:hover {
  background: #a01e1e;
}
#product-data-search:disabled,
#data-sites-settings:disabled,
#product-data-dismiss:disabled {
  opacity: 0.55;
}
.data-actions .photo-search-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
#data-status {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
  min-width: 0;
}
.data-queue {
  margin: 0 20px 4px;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 16px;
}
.data-queue > summary {
  cursor: pointer;
  font-weight: 650;
  font-size: 13px;
}
.data-queue .table-wrap {
  max-height: 360px;
  overflow: auto;
}
.data-queue table small {
  display: block;
  color: var(--muted);
  margin-top: 4px;
}
.data-queue td button {
  white-space: nowrap;
}
#photo-product-summary {
  padding: 18px 22px;
  border-radius: 12px;
}
.summary-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}
.summary-head h3 {
  margin: 0 0 4px;
  overflow-wrap: anywhere;
}
.summary-head small {
  color: var(--muted);
  overflow-wrap: anywhere;
}
.summary-warning {
  color: #8a5300;
  background: #fff7e6;
  border-radius: 8px;
  padding: 10px 12px;
  margin: 12px 0 0;
  font-size: 12px;
}
#photo-product-summary p.muted {
  margin: 12px 0 0;
}
.batch-list {
  margin: 0 0 16px;
}
.batch-list > summary {
  cursor: pointer;
  font-weight: 650;
  font-size: 13px;
  padding: 8px 0;
}
.batch-pagination {
  margin-top: 10px;
}
.batch-selection {
  grid-template-columns: 1.6fr 1fr auto;
}
.batch-selection select {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  min-height: 44px;
  border: 1px solid #d8e1de;
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  color: #183c34;
  font: inherit;
  margin: 0;
}
.batch-result-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
}
@media (max-width: 760px) {
  .nav-more {
    flex: 1 1 100%;
    margin: 0;
  }
  .nav-more > summary {
    justify-content: center;
    padding: 9px 7px;
    font-size: 10px;
  }
  .nav-more > summary::after {
    margin-left: 6px;
  }
  .nav-more-list {
    display: flex;
    flex-wrap: wrap;
    gap: 3px;
    border: 0;
    margin: 0;
    padding: 0;
  }
  .nav-more-list .nav {
    width: auto;
    flex: 1 1 28%;
    padding: 9px 7px;
    font-size: 10px;
    justify-content: center;
  }
  .data-queue {
    margin: 0 10px 4px;
    padding: 10px;
  }
  #data-workspace:not(.hidden) {
    padding: 10px;
    gap: 12px;
  }
  .batch-selection {
    grid-template-columns: 1fr;
  }
  .batch-result-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }
}
.picker-scope {
  padding: 0 20px 16px;
}
#products-body td small {
  display: block;
}
@media (max-width: 760px) {
  .picker-scope {
    padding: 0 10px 12px;
  }
}
.detail-thumbnail {
  display: block;
  width: 120px;
  height: 120px;
  object-fit: contain;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #f7f9fc;
  margin-bottom: 12px;
}
.review-table tr.changed td {
  background: #fff7e6;
  font-weight: 650;
}
.review-table tr.changed td:first-child::before {
  content: "● ";
  color: #c98a00;
}
#workspace-editor #editor-review {
  max-height: 60vh;
}
.review-box {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  margin-top: 14px;
}
.review-box h4 {
  margin: 0 0 10px;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Botões só com ícone e tooltip; grupos de ações alinhados à direita (08/09/2026). */
.icon-only {
  padding: 0.45rem 0.6rem;
  min-width: 2.25rem;
  min-height: 2.25rem;
  justify-content: center;
  gap: 0;
}
.icon-only .ui-icon {
  width: 18px;
  height: 18px;
}
.card-actions,
.intro-actions,
.dialog-actions,
.photo-quick,
.product-actions,
.report-head,
.jobs-actions,
.picker-actions,
.gallery-toolbar {
  justify-content: flex-end;
}
.panel-heading > .icon-only,
.photo-tools > .icon-only,
form > .icon-only,
fieldset > .icon-only,
.fiscal-form .icon-only,
.notice > .icon-only,
p > .icon-only {
  margin-left: auto;
  display: inline-flex;
}

/* Ícones de ação ficam juntos na direita: só o primeiro empurra, os seguintes acompanham (09/09/2026). */
.panel-heading > .icon-only ~ .icon-only,
.photo-tools > .icon-only ~ .icon-only,
form > .icon-only ~ .icon-only,
fieldset > .icon-only ~ .icon-only,
.fiscal-form .icon-only ~ .icon-only,
.notice > .icon-only ~ .icon-only,
p > .icon-only ~ .icon-only {
  margin-left: 0;
}

/* Em todas as telas, cada grupo de ações termina na mesma linha vertical do cabeçalho do painel. */
.panel .panel-heading,
.panel .filters,
.panel .advanced-filters,
.panel .card-actions,
.panel .gallery-tools,
.panel .photo-tools,
.panel .pagination {
  padding-right: 22px;
  margin-right: 0;
}
.panel .scope-note {
  margin: 0 22px 10px;
  padding-right: 0;
}
.panel table td:last-child,
.panel table th:last-child {
  padding-right: 22px;
}
/* Dentro de um cartao que ja tem borda e recuo proprios, nao somar o recuo da tabela. */
.data-queue table td:last-child,
.data-queue table th:last-child,
.panel .pagination {
  padding-right: 0;
}
.panel table td:last-child .product-actions,
.panel table td:last-child .row-icons {
  justify-content: flex-end;
}
.photo-tools {
  justify-content: flex-end;
}

/* Atualizar dados em formato planilha (08/09/2026). */
.data-sheet th.num,
.data-sheet td.num {
  text-align: right;
  width: 64px;
}
.data-sheet td code {
  font-size: 12px;
}
.data-sheet .sheet-fields {
  white-space: normal;
  max-width: 520px;
  color: #3e5148;
}
.data-sheet .row-icons {
  text-align: right;
  white-space: nowrap;
}
.data-queue > summary {
  margin-bottom: 8px;
}
.all-found-fields {
  padding: 0;
  background: transparent;
  border: 0;
}
.all-found-fields table {
  min-width: 0;
  width: 100%;
}
.compare-box {
  margin-top: 0;
  margin-bottom: 14px;
}
.compare-box .review-table {
  max-height: none;
}
.compare-box td:first-child {
  color: #4a5c53;
  width: 26%;
}
.compare-box tr.found td {
  background: #fff9ec;
}
.compare-box tr.found td:nth-child(3) {
  font-weight: 650;
}
.compare-box .found-sources {
  display: block;
  font-weight: 400;
  color: var(--muted);
  margin-top: 2px;
}
.compare-box .accept-cell {
  width: 44px;
  text-align: right;
}
.accept-toggle {
  color: #9aa9a1;
  border: 1px solid transparent;
}
.accept-toggle[aria-pressed="true"] {
  color: #fff;
  background: #1d7a4a;
  border-color: #1d7a4a;
}
.accept-toggle[aria-pressed="true"]:hover {
  background: #166238;
}
.accept-toggle:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.all-found-fields .card-actions {
  align-items: center;
  gap: 12px;
  margin-top: 4px;
}
#use-found-feedback {
  font-size: 12px;
  color: var(--muted);
}
.picker-scope[hidden] {
  display: none;
}
/* Tela de fotos enxuta: barra de busca, endereço, fontes e pacote ficam fora da tela (08/09/2026). */
#photo-toolbar[hidden] {
  display: none;
}
/* Galeria: barra de seleção fora da tela; ferramentas da galeria à direita (08/09/2026). */
.photo-selection-bar[hidden] {
  display: none;
}
.gallery-tools {
  margin-left: auto;
  display: flex;
  align-items: end;
  gap: 8px;
}

/* Ícones modernos e vivos (08/09/2026): duotone com preenchimento suave e uma cor por ícone.
   Dentro de botões verdes, no logotipo e nos ícones de ação coloridos, o traço fica branco. */
.ui-icon {
  color: var(--icon-color, currentColor);
  --icon-fill: color-mix(in srgb, currentColor 18%, transparent);
}
svg.ui-icon:has(use[href$="#search"]) {
  --icon-color: #2563eb;
}
svg.ui-icon:has(use[href$="#image"]) {
  --icon-color: #7c3aed;
}
svg.ui-icon:has(use[href$="#edit"]) {
  --icon-color: #f59e0b;
}
svg.ui-icon:has(use[href$="#download"]) {
  --icon-color: #0284c7;
}
svg.ui-icon:has(use[href$="#upload"]) {
  --icon-color: #0891b2;
}
svg.ui-icon:has(use[href$="#save"]) {
  --icon-color: #16a34a;
}
svg.ui-icon:has(use[href$="#check"]) {
  --icon-color: #16a34a;
}
svg.ui-icon:has(use[href$="#plus"]) {
  --icon-color: #16a34a;
}
svg.ui-icon:has(use[href$="#close"]) {
  --icon-color: #ef4444;
}
svg.ui-icon:has(use[href$="#trash"]) {
  --icon-color: #ef4444;
}
svg.ui-icon:has(use[href$="#refresh"]) {
  --icon-color: #0d9488;
}
svg.ui-icon:has(use[href$="#settings"]) {
  --icon-color: #6366f1;
}
svg.ui-icon:has(use[href$="#external"]) {
  --icon-color: #3b82f6;
}
svg.ui-icon:has(use[href$="#arrow-right"]) {
  --icon-color: #0f766e;
}
svg.ui-icon:has(use[href$="#arrow-left"]) {
  --icon-color: #0f766e;
}
svg.ui-icon:has(use[href$="#arrow-up"]) {
  --icon-color: #0f766e;
}
svg.ui-icon:has(use[href$="#arrow-down"]) {
  --icon-color: #0f766e;
}
svg.ui-icon:has(use[href$="#folder"]) {
  --icon-color: #f97316;
}
svg.ui-icon:has(use[href$="#database"]) {
  --icon-color: #8b5cf6;
}
svg.ui-icon:has(use[href$="#box"]) {
  --icon-color: #d97706;
}
svg.ui-icon:has(use[href$="#grid"]) {
  --icon-color: #1f8fe0;
}
svg.ui-icon:has(use[href$="#quality"]) {
  --icon-color: #22c55e;
}
svg.ui-icon:has(use[href$="#history"]) {
  --icon-color: #64748b;
}
svg.ui-icon:has(use[href$="#document"]) {
  --icon-color: #e11d48;
}
svg.ui-icon:has(use[href$="#compare"]) {
  --icon-color: #a855f7;
}
svg.ui-icon:has(use[href$="#spark"]) {
  --icon-color: #eab308;
}
svg.ui-icon:has(use[href$="#logout"]) {
  --icon-color: #dc2626;
}
svg.ui-icon:has(use[href$="#key"]) {
  --icon-color: #ca8a04;
}
svg.ui-icon:has(use[href$="#user"]) {
  --icon-color: #0ea5e9;
}
svg.ui-icon:has(use[href$="#pause"]) {
  --icon-color: #f59e0b;
}
svg.ui-icon:has(use[href$="#play"]) {
  --icon-color: #16a34a;
}
/* Prioridade acima das cores por ícone: traço branco em fundo colorido. */
.primary svg.ui-icon:has(use),
.logo-mark svg.ui-icon:has(use),
.accept-toggle[aria-pressed="true"] svg.ui-icon:has(use),
#product-data-search svg.ui-icon:has(use),
#data-sites-settings svg.ui-icon:has(use),
#product-data-dismiss svg.ui-icon:has(use),
#photo-download-selected svg.ui-icon:has(use),
.jobs-actions .primary svg.ui-icon:has(use) {
  --icon-color: #fff;
  --icon-fill: rgba(255, 255, 255, 0.28);
}
.nav.active .ui-icon {
  filter: saturate(1.15);
}
.icon-button:hover .ui-icon,
.secondary:hover .ui-icon {
  filter: brightness(0.85);
}
/* Salvar e concluir na tela de fotos: verde forte, à direita da linha de filtros (08/09/2026). */
#photo-complete {
  background: #0f7b3f;
  border-color: transparent;
}
#photo-complete:hover {
  background: #0b5f30;
}
#photo-complete:disabled {
  opacity: 0.55;
}
/* Menu Configuração (08/09/2026): cartões com as APIs, o acesso e os formulários de busca. */
.config-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 0 20px 14px;
}
.config-card {
  padding: 16px 18px;
}
.config-card.config-wide {
  margin: 0 20px 14px;
}
.config-card h3 {
  margin: 0 0 10px;
  font-size: 14px;
}
.config-card input:not([type="checkbox"]),
.config-card select,
.config-card textarea {
  width: 100%;
  min-width: 0;
  display: block;
  margin-top: 6px;
}
.config-card label {
  display: block;
  margin: 10px 0;
  font-size: 13px;
}
.config-card fieldset {
  margin: 12px 0;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
}
.config-card .search-sites label,
.config-card .photo-pick {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 4px 12px 4px 0;
}
.config-card .search-sites label input,
.config-card .photo-pick input {
  width: auto;
  display: inline-block;
  margin: 0;
}
.config-status dl {
  margin: 0;
  display: grid;
  gap: 6px;
}
.config-status dl > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  border-bottom: 1px dashed var(--border);
  padding-bottom: 4px;
}
.config-status dt {
  color: var(--muted);
}
.config-status dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
}
@media (max-width: 760px) {
  .config-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}
/* Conferência do lote (08/09/2026): planilha por produto dentro do cartão do lote. */
.batch-audit {
  margin: 10px 0 12px;
  max-height: 420px;
  overflow: auto;
}
.batch-audit tr.audit-ready td {
  background: #f1fbf4;
}
.batch-audit tr.audit-done td {
  color: var(--muted);
}
.batch-audit tr.audit-done code {
  color: var(--muted);
}

/* Ícones novos do pacote intuitivo (08/09/2026). */
svg.ui-icon:has(use[href$="#camera"]) {
  --icon-color: #7c3aed;
}
svg.ui-icon:has(use[href$="#badge-check"]) {
  --icon-color: #16a34a;
}
svg.ui-icon:has(use[href$="#package-check"]) {
  --icon-color: #16a34a;
}
svg.ui-icon:has(use[href$="#layers"]) {
  --icon-color: #0284c7;
}
svg.ui-icon:has(use[href$="#globe"]) {
  --icon-color: #0891b2;
}
svg.ui-icon:has(use[href$="#thumbs-up"]) {
  --icon-color: #16a34a;
}
svg.ui-icon:has(use[href$="#thumbs-down"]) {
  --icon-color: #ef4444;
}
svg.ui-icon:has(use[href$="#backup"]) {
  --icon-color: #0d9488;
}
svg.ui-icon:has(use[href$="#clipboard"]) {
  --icon-color: #6366f1;
}
svg.ui-icon:has(use[href$="#list-checks"]) {
  --icon-color: #0f766e;
}
svg.ui-icon:has(use[href$="#eye"]) {
  --icon-color: #3b82f6;
}
svg.ui-icon:has(use[href$="#star"]) {
  --icon-color: #f59e0b;
}

/* ============================================================================
   Tema 2026: superfícies mais leves, cantos maiores, sombras suaves, tipografia
   mais firme e estados de foco e passagem do mouse desenhados. As regras ficam
   no fim do arquivo para vencer as anteriores sem reescrevê-las. */
:root {
  font-family: "Inter", "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
  --brand: #1668c9;
  --brand-700: #0f4a94;
  --brand-50: #eaf2fc;
  --ink: #0f1f3d;
  --muted: #6b7684;
  --border: #e2e7ee;
  --bg: #f3f6fa;
  --surface: #ffffff;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(15, 31, 61, 0.05), 0 1px 4px rgba(15, 31, 61, 0.05);
  --shadow-md: 0 6px 18px rgba(15, 31, 61, 0.08);
  --ring: 0 0 0 3px rgba(22, 104, 201, 0.22);
  color: var(--ink);
  background: var(--bg);
}
body {
  background: radial-gradient(1200px 600px at 100% -10%, #e9f2fb 0%, var(--bg) 55%);
}
.sidebar {
  background: linear-gradient(180deg, #ffffff 0%, #f8fafd 100%);
  border-right: 1px solid var(--border);
  padding: 28px 18px;
}
.logo {
  font-size: 27px;
  letter-spacing: -1px;
  margin-bottom: 10px;
}
.logo-mark {
  border-radius: 12px;
  box-shadow: 0 6px 14px rgba(22, 104, 201, 0.25);
}
.nav {
  padding: 11px 12px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 550;
  color: #55655d;
  transition: background 120ms ease, color 120ms ease, transform 120ms ease;
  position: relative;
}
.nav:hover {
  background: #f0f5f2;
  color: var(--ink);
}
.nav.active {
  background: var(--brand-50);
  color: var(--brand-700);
  font-weight: 650;
}
.nav.active::before {
  content: "";
  position: absolute;
  left: -18px;
  top: 10px;
  bottom: 10px;
  width: 4px;
  border-radius: 0 4px 4px 0;
  background: var(--brand);
}
.nav b {
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 10.5px;
  background: #e6efe9;
  color: #2f5b45;
}
.nav.active b {
  background: var(--brand);
  color: #fff;
}
.topbar {
  height: 64px;
  padding: 0 34px;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 5;
  font-size: 12px;
}
.content {
  padding: 30px 34px 28px;
}
h1 {
  font-size: 26px;
  letter-spacing: -0.6px;
}
.eyebrow {
  font-size: 10px;
}
.metrics article {
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform 140ms ease, box-shadow 140ms ease;
}
.metrics article:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.metrics strong {
  font-size: 28px;
}
.panel,
.card {
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  background: var(--surface);
}
.panel-heading {
  padding: 20px 22px 14px;
}
h2 {
  font-size: 16px;
  letter-spacing: -0.2px;
}
th {
  font-size: 10px;
  letter-spacing: 0.9px;
  text-transform: uppercase;
  color: #7a877f;
  background: #f7f9fc;
  padding: 12px 18px;
  position: sticky;
  top: 0;
  z-index: 1;
}
td {
  padding: 14px 18px;
  font-size: 12px;
}
tbody tr {
  transition: background 100ms ease;
}
tbody tr:hover td {
  background: #f7fafd;
}
.pill,
.count {
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.2px;
}
.pill {
  background: #e8f4ec;
  color: #1f6a45;
}
.pill.amber {
  background: #fff3dc;
  color: #9a6512;
}
.chip {
  border-radius: 999px;
  transition: background 120ms ease, color 120ms ease, border-color 120ms ease;
}
.chip.active {
  background: var(--brand-50);
  border-color: #bcd9c8;
  color: var(--brand-700);
}
.primary,
.secondary,
.button {
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 12.5px;
  transition: background 120ms ease, box-shadow 120ms ease, transform 120ms ease, border-color 120ms ease;
}
.primary {
  box-shadow: 0 2px 6px rgba(22, 104, 201, 0.28);
}
.primary:hover {
  background: var(--brand-700);
  transform: translateY(-1px);
}
.secondary {
  border-color: #d8e1db;
  color: #3f5148;
  background: #fff;
}
.secondary:hover {
  background: #f2f7f4;
  border-color: #c4d3ca;
}
.icon-only,
.icon-button {
  border-radius: 10px;
}
.icon-button:hover {
  background: #eef5f1;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: none;
  box-shadow: var(--ring);
}
input:not([type="checkbox"]),
select,
textarea {
  border-radius: 10px;
  border: 1px solid #d9e2dc;
  background: #fff;
  transition: border-color 120ms ease, box-shadow 120ms ease;
}
input:not([type="checkbox"]):focus,
select:focus,
textarea:focus {
  border-color: var(--brand);
}
.data-queue,
.review-box,
.config-card,
.batch-card,
.compare-box {
  border-radius: 12px;
}
.data-sheet th:first-child,
.data-sheet td:first-child {
  padding-left: 18px;
}
.data-sheet code {
  background: #f1f5f2;
  padding: 2px 6px;
  border-radius: 6px;
  font-size: 11.5px;
}
.compare-box tr.found td {
  background: #fff8e8;
}
.accept-toggle[aria-pressed="true"] {
  box-shadow: 0 2px 6px rgba(31, 143, 224, 0.35);
}
.progress {
  height: 5px;
  border-radius: 999px;
}
.progress i {
  border-radius: 999px;
}
.footnote {
  opacity: 0.8;
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}

/* Teto de consultas pagas (Configurações) e frentes do lote */
.budget-form{display:flex;align-items:flex-end;gap:12px;flex-wrap:wrap}
.budget-form label{display:flex;flex-direction:column;gap:6px;font-weight:600}
.budget-form input{width:140px}
.batch-fronts{margin:4px 0 0}

/* Subtitulo da marca, abaixo do nome, como no desenho da logo (09/09/2026) */
.logo {
  flex-wrap: wrap;
}
.logo-image {
  display: block;
  width: 100%;
  max-width: 208px;
  height: auto;
}
.login-card .logo-image {
  max-width: 260px;
  margin: 0 auto 6px;
}

/* Cartões do painel como atalho: aviso do recorte aplicado e cartão clicável (09/09/2026) */
.metrics article[data-scope] {
  cursor: pointer;
}
.metrics article[data-scope]:hover {
  border-color: var(--brand);
}
.scope-note {
  margin: 0 22px 10px;
  font-size: 13px;
  color: var(--muted);
}
.scope-note strong {
  color: var(--ink);
}
.link-button {
  background: none;
  border: 0;
  padding: 0 0 0 6px;
  color: var(--brand);
  font: inherit;
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
}

/* Cartões do painel: rótulos centralizados e número alinhado à direita (pedido de 09/09/2026) */
.metrics article > span,
.metrics article > small {
  display: block;
  text-align: center;
}
.metrics article > strong {
  text-align: right;
}

/* Aproveitamento medido dos sites, em Configurações (09/09/2026) */
.sites-performance {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.sites-performance h4 {
  margin: 0 0 4px;
  font-size: 13px;
}
.sites-performance table {
  width: 100%;
  font-size: 12px;
}
.sites-performance td:nth-child(2) {
  font-weight: 650;
}

/* Linhas de ação alinhadas à direita, com o rótulo à esquerda (pedido de 09/09/2026) */
.scope-note {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-end;
}
.scope-note-label {
  margin-right: auto;
}
.sites-performance {
  text-align: right;
}
.sites-performance h4,
.sites-performance p,
.sites-performance table {
  text-align: left;
}
