:root {
  --bg: #eff1f2;
  --surface: rgba(255, 255, 255, 0.84);
  --surface-strong: #ffffff;
  --line: #ddd7ce;
  --text: #171414;
  --muted: #6f6a64;
  --chip: #ebe8e1;
  --chip-border: #c9c2b8;
  --accent: #151126;
  --violet: #7c6df0;
  --violet-dark: #6355d4;
  --shadow: 0 22px 60px rgba(37, 28, 18, 0.08);
}

html,
body {
  background: #eff1f2;
}

.site-nav {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  position: sticky;
  top: 0;
  z-index: 40;
  padding: 0 28px;
  min-height: 52px;
  background: #ffffff;
  border-bottom: 1px solid #ddd7ce;
}

.site-nav-spacer {
  min-width: 0;
}

.site-nav-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  transform: translateX(25px);
}

.site-nav-brand-link {
  display: inline-flex;
  align-items: center;
  min-width: 0;
}

.site-nav-logo-image {
  display: block;
  width: min(272px, 100%);
  height: auto;
}

.hero-beta-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 6px;
  border-radius: 5px;
  background: #efeafe;
  color: #5b3fd6;
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
  vertical-align: middle;
}

.app-version-indicator {
  color: #999999;
  font-size: 0.66rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.site-footer {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  padding: 18px 16px 24px;
}

.site-nav-end {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
  min-width: 0;
}

body.public-route .site-nav-end {
  display: none;
}

.site-nav-link {
  padding: 7px 13px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
  color: var(--muted);
  font-size: 0.82rem;
  cursor: pointer;
}

.site-nav-link:hover {
  background: rgba(255, 255, 255, 0.95);
  color: var(--text);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body {
  margin: 0;
  color: var(--text);
  background: #eff1f2;
  font-family: "SF Pro Display", "Neue Haas Grotesk Text Pro", "Helvetica Neue", sans-serif;
}

button,
input,
summary {
  font: inherit;
}

.button-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  display: block;
}

body.modal-open {
  overflow: hidden;
}

.page-shell,
.results-shell {
  max-width: 1220px;
  margin: 0 auto;
  padding: 24px 28px 0;
}

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 4px;
  padding-top: 36px;
  padding-bottom: 4px;
}

.hero-actions {
  display: none;
}

.rules-summary-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.78);
  color: var(--text);
  box-shadow: var(--shadow);
  cursor: pointer;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.75rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

h1 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
}

.hero-sparkle {
  color: var(--violet);
  font-size: 0.75em;
  vertical-align: super;
}

.debug-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 13px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
  color: var(--text);
  cursor: pointer;
  font-size: 0.82rem;
}

.debug-toggle[aria-pressed="true"] {
  background: #080617;
  color: #fff;
}

.search-panel {
  margin-top: 20px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.search-secondary {
  display: none;
}

.browse-category-scope-bar {
  margin-top: 0;
}

.browse-category-scope-field {
  display: grid;
  gap: 8px;
}

.browse-category-scope-label {
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.browse-category-scope-select {
  width: 100%;
  min-width: 0;
  min-height: 46px;
  padding: 0 40px 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff url("/pixelseek-icons/carrot-dropdown.svg") no-repeat right 12px center / 14px;
  color: var(--text);
  appearance: none;
}

.browse-trait-panel {
  display: grid;
  gap: 14px;
  margin-top: 14px;
  padding: 18px 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
}

.browse-trait-panel-header {
  display: flex;
  align-items: baseline;
  justify-content: flex-start;
  gap: 8px;
  flex-wrap: nowrap;
}

.browse-trait-panel-title {
  margin: 0;
  line-height: 1;
}

.browse-trait-panel-reset {
  padding: 0;
  border: 0;
  background: transparent;
  color: #c23b31;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
}

.browse-trait-panel-reset:not(:disabled):hover {
  color: #a12b22;
}

.browse-trait-panel-reset:disabled {
  opacity: 0.45;
  cursor: default;
}

.browse-trait-panel-fields {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.browse-trait-panel-fields-sidebar {
  grid-template-columns: 1fr;
  min-height: 0;
  overflow-y: auto;
  padding-right: 4px;
}

.browse-trait-field {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.browse-trait-field-label {
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.browse-trait-field-select {
  width: 100%;
  min-height: 44px;
  padding: 0 38px 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff url("/pixelseek-icons/carrot-dropdown.svg") no-repeat right 12px center / 14px;
  color: var(--text);
  appearance: none;
}

.browse-trait-field-select:disabled {
  color: var(--muted);
  background-color: #f5f3ef;
}

.browse-sidebar-section {
  gap: 12px;
}

.search-form {
  margin: 0;
  width: 100%;
}

.hero-subhead {
  margin: 8px 0 0;
  color: #5f6474;
  font-size: 1rem;
  line-height: 1.5;
}

.family-count-summary {
  display: grid;
  justify-items: center;
  gap: 10px;
  margin-top: 14px;
}

.family-count-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 4px 8px;
  border: 0.5px solid rgba(209, 213, 222, 0.95);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.98);
}

.family-count-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  white-space: nowrap;
}

.family-count-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 19px;
  height: 19px;
  color: #7c5cff;
  flex: 0 0 auto;
}

.family-count-icon svg {
  width: 19px;
  height: 19px;
  display: block;
}

.family-count-name {
  color: #8a8f9c;
  font-size: 0.92rem;
}

.family-count-value {
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 600;
}

.family-count-divider {
  width: 0.5px;
  align-self: stretch;
  background: rgba(209, 213, 222, 0.95);
}

.family-count-caption {
  margin: 0;
  color: #8a8f9c;
  font-size: 0.69rem;
  line-height: 1.3;
}

html:not(.landing-home) body .family-count-summary {
  display: none !important;
}

.search-entry-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 14px;
  align-items: stretch;
}

.search-entry-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 312px;
  padding: 28px 28px 26px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  transition:
    background-color 150ms ease,
    border-color 150ms ease,
    border-width 150ms ease,
    transform 150ms ease,
    box-shadow 150ms ease,
    opacity 150ms ease;
}

.search-entry-card-image {
  align-items: stretch;
  text-align: left;
  border: 1.5px dashed rgba(124, 109, 240, 0.55);
  cursor: default;
}

.search-entry-card-text {
  border: 0.5px solid rgba(209, 213, 222, 0.95);
}

.search-entry-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eeedfe;
  color: #3c3489;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition:
    background-color 150ms ease,
    color 150ms ease,
    opacity 150ms ease;
}

.search-entry-icon {
  width: 34px;
  height: 34px;
  margin-bottom: 18px;
  background: center / contain no-repeat;
  transition:
    transform 150ms ease,
    opacity 150ms ease,
    background-image 150ms ease;
}

.search-entry-icon-image {
  background-image: url("/pixelseek-icons/upload-image.svg");
}

.search-entry-grid.is-image-drag-active .search-entry-icon-image {
  background-image: url("/pixelseek-icons/arrow-down_active.svg");
}

.search-entry-icon-text {
  background-image: url("/pixelseek-icons/search-ia-circle.svg");
}

.search-entry-copy-block {
  display: grid;
  gap: 8px;
}

.search-entry-title {
  margin: 0;
  color: #1f2330;
  font-size: 1.35rem;
  font-weight: 650;
  line-height: 1.2;
  transition: color 150ms ease;
}

.search-entry-copy {
  margin: 0;
  color: #696f80;
  font-size: 0.96rem;
  line-height: 1.45;
  transition: color 150ms ease, opacity 150ms ease;
}

.search-entry-copy-mobile {
  display: none;
}

.search-entry-upload-button {
  margin-top: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: #7c6df0;
  color: #fff;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    background-color 150ms ease,
    border-color 150ms ease,
    color 150ms ease,
    opacity 150ms ease;
}

.search-entry-upload-button:hover {
  background: #6355d4;
}

.search-entry-upload-button-secondary {
  width: 100%;
  border: 1px solid #cfd5de;
  background: rgba(255, 255, 255, 0.88);
  color: #515868;
}

.search-entry-upload-button-secondary:hover {
  background: rgba(248, 249, 252, 0.98);
  border-color: #b9c1cd;
  color: #2f3643;
}

.search-entry-url-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  width: 100%;
  margin-top: 22px;
}

.search-entry-url-toggle {
  display: none;
  align-self: center;
  padding: 0;
  border: 0;
  background: transparent;
  color: #58505f;
  font: inherit;
  font-size: 0.92rem;
  text-decoration: underline;
  cursor: pointer;
}

.search-entry-url-input {
  width: 100%;
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid rgba(217, 221, 231, 0.98);
  border-radius: 14px;
  background: #fff;
  color: #1f2330;
  font: inherit;
}

.search-entry-url-input::placeholder {
  color: #8a90a0;
}

.search-entry-url-input:focus {
  outline: 2px solid rgba(124, 109, 240, 0.18);
  outline-offset: 1px;
  border-color: rgba(124, 109, 240, 0.7);
}

.search-entry-url-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 0;
  border-radius: 14px;
  background: #7c6df0;
  color: #fff;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    background-color 150ms ease,
    opacity 150ms ease;
}

.search-entry-url-button:hover:not(:disabled) {
  background: #6355d4;
}

.search-entry-url-button:disabled {
  opacity: 0.45;
  cursor: default;
}

.search-entry-divider {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  width: 100%;
  margin: 18px 0 12px;
}

.search-entry-divider-line {
  display: block;
  height: 1px;
  background: rgba(209, 213, 222, 0.95);
}

.search-entry-divider-label {
  color: #8a90a0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.search-entry-inline-error {
  width: 100%;
  margin: 0 0 12px;
  color: #b83a34;
  font-size: 0.84rem;
  line-height: 1.4;
}

.search-entry-card-image.is-drag-active {
  background: #eeedfe;
  border-width: 2.5px;
  border-color: #534ab7;
  transform: scale(1.01);
}

.search-entry-card-image.is-drag-active .search-entry-badge {
  background: #534ab7;
  color: #fff;
}

.search-entry-card-image.is-drag-active .search-entry-title,
.search-entry-card-image.is-drag-active .search-entry-copy {
  color: #2e2f57;
}

.search-entry-card-image.is-drag-active .search-entry-url-form,
.search-entry-card-image.is-drag-active .search-entry-divider,
.search-entry-card-image.is-drag-active .search-entry-upload-button-secondary,
.search-entry-card-image.is-drag-active .search-entry-inline-error {
  opacity: 0.4;
  pointer-events: none;
}

.search-entry-grid.is-image-drag-active .search-entry-card-text {
  opacity: 0.5;
}

.search-field {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 14px;
  min-height: 54px;
  margin-top: 18px;
  padding: 0 16px;
  border-radius: 16px;
  border: 1px solid rgba(217, 221, 231, 0.98);
  background: #fff;
}

.search-query-flow {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 14px 0;
  color: #6b7280;
  font-size: 1.02rem;
  line-height: 1.75;
}

.search-field.is-multiline .search-query-flow {
  line-height: 2.16;
}

.search-category-chip-wrap[hidden],
.search-category-prefix[hidden],
.search-category-suffix[hidden] {
  display: none;
}

.search-category-prefix {
  display: inline;
  color: #6b7280;
  font-size: 1.02rem;
  line-height: 1.75;
  white-space: pre-wrap;
}

.search-field.is-multiline .search-category-prefix {
  line-height: 2.16;
}

.search-category-suffix {
  display: inline;
  color: #6b7280;
  font-size: 1.02rem;
  line-height: 1.75;
  white-space: pre-wrap;
}

.search-field.is-multiline .search-category-suffix {
  line-height: 2.16;
}

.search-category-chip-wrap {
  display: inline-flex;
  vertical-align: middle;
  margin: 0 8px;
}

.search-category-chip-wrap[data-dropdown-mode="similar-look"] {
  cursor: pointer;
}

.search-category-chip-wrap[data-dropdown-mode="similar-look"] .search-category-select {
  pointer-events: none;
}

.search-category-select {
  min-width: 0;
  border: 0;
  border-radius: 12px;
  background: #7c6df0;
  color: #fff;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1;
  min-height: 36px;
  padding: 0 34px 0 14px;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5l3 3 3-3' fill='none' stroke='%23ffffff' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 12px;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.search-category-select:focus {
  outline: none;
}

.search-icon {
  display: inline-block;
  width: 24px;
  height: 24px;
  color: transparent;
  font-size: 0;
  background: center / contain no-repeat url("/pixelseek-icons/ai-search.svg");
  vertical-align: text-bottom;
  margin-right: 10px;
}

.search-field.has-inline-category .search-icon {
  display: none;
}

.search-input {
  display: inline-block;
  flex: 1 1 auto;
  min-width: 0;
  outline: 0;
  background: transparent;
  color: #6b7280;
  font-size: 1rem;
  font: inherit;
  line-height: 1.75;
  white-space: normal;
  word-break: break-word;
}

.search-field.is-multiline .search-input {
  line-height: 2.16;
}

.search-input:empty::before {
  content: attr(data-placeholder);
  color: #959bb1;
}

.search-input:focus:empty::before {
  content: "";
}

.search-input:focus {
  display: inline-block;
  min-width: 1px;
}

.search-clear-button {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 10px;
  min-height: 28px;
  padding: 4px 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: #e4e4eb;
  color: #959bb1;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  vertical-align: middle;
  cursor: pointer;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease;
}

.search-clear-button[hidden] {
  display: none;
}

.search-clear-button:hover {
  background: #dbdbe5;
  color: #7f86a0;
}

.search-clear-button:focus-visible {
  outline: 2px solid rgba(124, 109, 240, 0.45);
  outline-offset: 2px;
  background: #dbdbe5;
  color: #7f86a0;
}

.context-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  min-height: 34px;
}

.context-row-centered {
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 12px;
  text-align: center;
}

.context-label,
.results-header p,
.matched-label,
.debug-caption-label,
.status-panel {
  color: var(--muted);
}

.context-pills,
.chip-row,
.seed-queries {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.seed-image-examples {
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  gap: 10px;
  width: 100%;
}

.seed-queries {
  justify-content: center;
}

.context-pill,
.seed-query,
.chip {
  border-radius: 999px;
  border: 1px solid transparent;
  background: #e4e4eb;
  color: #959bb1;
}

.seed-query-image-card {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 58px;
  padding: 8px 12px 8px 8px;
  border-radius: 18px;
  text-align: left;
}

.seed-query-image-preview {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border-radius: 12px;
  background: center / cover no-repeat;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.seed-query-image-copy {
  display: grid;
  gap: 2px;
}

.seed-query-image-title {
  color: inherit;
  font-size: 0.83rem;
  font-weight: 600;
  line-height: 1.2;
}

.seed-query-image-brand {
  color: #8b92aa;
  font-size: 0.74rem;
  line-height: 1.2;
}

.context-pill,
.seed-query {
  padding: 8px 14px;
}

.context-pill:hover,
.seed-query:hover:not(.seed-query-image-card),
.context-pill.is-active,
.seed-query.is-active:not(.seed-query-image-card) {
  background: #8341ff;
  color: #ffffff;
}

.context-image-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 10px 6px 6px;
}

.context-filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.context-pill-clear {
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  line-height: 1;
  cursor: pointer;
  padding: 0;
}

.context-image-pill img {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  object-fit: cover;
  display: block;
}

.seed-queries {
  margin-top: 14px;
}

.seed-query {
  cursor: pointer;
}

.upload-button {
  padding: 11px 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  cursor: pointer;
}

.upload-button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.upload-button[disabled] {
  background: #f1ede7;
  color: #8d867d;
}

.upload-button-strong {
  background: #151126;
  color: #fff;
}

.modal-upload-icon-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.modal-upload-icon-button::before {
  content: "";
  width: 12px;
  height: 12px;
  flex: 0 0 auto;
  background: center / contain no-repeat url("/pixelseek-icons/upload-image.svg");
}

.manage-button,
#manageSelectionButton.manage-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 18px;
  border: none !important;
  border-radius: 999px;
  background: #7c6df0 !important;
  color: #fff !important;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
}

.manage-button:hover,
#manageSelectionButton.manage-button:hover {
  background: #6355d4 !important;
}

.upload-support-note {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.5;
}

.inspiration-preview-wrap {
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.65);
  padding: 10px;
}

.inspiration-preview-canvas {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(216, 210, 201, 0.85);
  background: #fff;
}

.inspiration-preview {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

.touch-crop-hint,
.touch-crop-zoom-pill,
.touch-crop-reset-pill {
  position: absolute;
  z-index: 3;
  border: 0;
  border-radius: 999px;
  background: rgba(67, 63, 60, 0.92);
  color: #fff;
  font: inherit;
  font-size: 0.88rem;
  line-height: 1.2;
}

.touch-crop-hint {
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  padding: 10px 16px;
  text-align: center;
}

.touch-crop-zoom-pill {
  top: 12px;
  right: 12px;
  padding: 6px 10px;
  font-size: 0.82rem;
  font-weight: 600;
}

.touch-crop-reset-pill {
  left: 12px;
  bottom: 12px;
  padding: 8px 12px;
  cursor: pointer;
}

.inspiration-preview-canvas.is-touch-crop-mode {
  aspect-ratio: 1 / 1;
  border: 1.5px solid rgba(255, 255, 255, 0.3);
  background: #f7f4ef;
  touch-action: none;
}

.inspiration-preview-canvas.is-touch-crop-mode .inspiration-preview {
  position: absolute;
  will-change: left, top, width, height;
}

.inspiration-preview-canvas.is-touch-crop-mode.is-interacted {
  border-color: #7f77dd;
  border-width: 2px;
}

.focus-box {
  position: absolute;
  z-index: 2;
  border: 2px solid #34c759;
  border-radius: 6px;
  background: rgba(52, 199, 89, 0.06);
  box-shadow:
    0 0 0 9999px rgba(12, 16, 24, 0.42),
    0 0 0 1px rgba(255, 255, 255, 0.22),
    inset 0 0 0 1px rgba(255, 255, 255, 0.34);
  cursor: move;
  overflow: hidden;
  min-width: 72px;
  min-height: 72px;
}

.focus-handle {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 0;
  background: #9ff7ca;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.88), 0 1px 6px rgba(0, 0, 0, 0.22);
}

.focus-handle-nw {
  top: -5px;
  left: -5px;
  cursor: nwse-resize;
}

.focus-handle-ne {
  top: -5px;
  right: -5px;
  cursor: nesw-resize;
}

.focus-handle-sw {
  bottom: -5px;
  left: -5px;
  cursor: nesw-resize;
}

.focus-handle-se {
  right: -5px;
  bottom: -5px;
  cursor: nwse-resize;
}

.focus-stage-card {
  display: grid;
  gap: 14px;
}

.image-modal-category-requirement {
  margin-top: 14px;
}

.image-modal-category-requirement .clarification-card {
  width: 100%;
  margin: 0;
  background: #f7f5ff;
  border: 1px solid rgba(124, 109, 240, 0.18);
  box-shadow: none;
}

.focus-stage-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  width: 100%;
  margin-top: 14px;
  column-gap: 16px;
}

.focus-crop-prompt {
  grid-column: 1;
  margin: 0;
  color: #1fa971;
  font-size: 0.95rem;
  font-weight: 600;
  justify-self: start;
  padding-left: 11px;
}

#applyFocusButton.upload-button-strong {
  justify-self: end;
  background: linear-gradient(to right, #7c3aed, #6d28d9);
  color: #ffffff;
  border: 0;
  font-size: 14px;
  font-weight: 600;
}

#applyFocusButton.upload-button-strong:hover {
  background: linear-gradient(to right, #6d28d9, #5b21b6);
}

.focus-skip-link {
  grid-column: 1;
  justify-self: start;
  align-self: center;
  padding: 0;
  padding-left: 11px;
  border: 0;
  background: transparent;
  color: #6b7280;
  font-size: 0.95rem;
  cursor: pointer;
  text-align: left;
}

.focus-skip-prefix {
  color: #6b7280;
}

.focus-skip-accent {
  color: #7c3aed;
  font-weight: 600;
}

.focus-analyze-loading {
  justify-content: flex-start;
  margin-top: 10px;
}

.focus-analyze-loading .image-analyze-loading-card {
  width: 100%;
}

.modal-shell {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
}

.debug-lightbox-shell {
  place-items: stretch;
}

.modal-shell[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(14, 11, 21, 0.46);
  backdrop-filter: blur(10px);
}

.modal-card {
  position: relative;
  z-index: 1;
  width: min(920px, calc(100vw - 32px));
  max-height: calc(100vh - 40px);
  overflow: auto;
  padding: 22px;
  border-radius: 24px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(250, 247, 242, 0.96));
  box-shadow: 0 30px 70px rgba(17, 11, 24, 0.22);
}

.image-search-modal-card {
  width: min(620px, calc(100vw - 40px));
  padding: 28px;
  border-radius: 12px;
  border: 0;
  background: #ffffff;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.rules-modal-card {
  max-width: 780px;
}

.rules-summary-content {
  display: grid;
  gap: 12px;
}

.rules-summary-details {
  display: grid;
  gap: 12px;
}

.rules-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.rules-copy-status {
  color: var(--muted);
  font-size: 0.88rem;
}

.debug-lightbox-card {
  width: 100vw;
  height: 100vh;
  max-width: none;
  max-height: none;
  border-radius: 0;
  border: 0;
  padding: 18px 20px 20px;
  display: flex;
  flex-direction: column;
}

.structured-traits-lightbox-card {
  padding: 18px 20px 20px;
}

.prompt-library-lightbox-card {
  padding: 18px 20px 20px;
}

.structured-traits-lightbox-content {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.prompt-library-lightbox-content {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.structured-traits-lightbox-content .structured-traits-list {
  flex: 1 1 auto;
  min-height: 0;
}

.prompt-library-content {
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  gap: 12px;
}

.prompt-library-panel {
  min-height: 0;
  display: grid;
  gap: 14px;
}

.prompt-library-view-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.prompt-library-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.prompt-library-title {
  margin: 0;
  font-size: 1.05rem;
}

.prompt-library-meta,
.prompt-library-generated {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.prompt-library-notes-card,
.prompt-library-source-card {
  padding: 14px 16px;
}

.prompt-library-source-list {
  display: grid;
  gap: 10px;
}

.prompt-library-source-item {
  display: grid;
  gap: 3px;
}

.prompt-library-source-title {
  font-size: 0.9rem;
}

.prompt-library-source-meta {
  color: var(--muted);
  font-size: 0.82rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  word-break: break-word;
}

.prompt-library-prompt-wrap {
  min-height: 0;
  overflow: auto;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
}

.prompt-library-prompt {
  margin: 0;
  padding: 18px;
  color: var(--text);
  font: 0.9rem/1.55 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  white-space: pre-wrap;
  word-break: break-word;
}

.prompt-library-formatted {
  display: grid;
  gap: 2px;
  padding: 18px;
  color: var(--text);
}

.prompt-library-line {
  margin: 0;
  padding: 0;
  padding-left: calc(var(--prompt-indent-level, 0) * 16px);
  white-space: pre-wrap;
  word-break: break-word;
}

.prompt-library-line-blank {
  min-height: 0.8rem;
}

.prompt-library-line-stage {
  margin-top: 6px;
  font: 600 1rem/1.45 "SF Pro Display", "Neue Haas Grotesk Text Pro", "Helvetica Neue", sans-serif;
  letter-spacing: 0.01em;
}

.prompt-library-line-section,
.prompt-library-line-subsection {
  margin-top: 4px;
  font: 600 0.9rem/1.5 "SF Pro Display", "Neue Haas Grotesk Text Pro", "Helvetica Neue", sans-serif;
}

.prompt-library-line-field,
.prompt-library-line-body,
.prompt-library-line-bullet,
.prompt-library-line-numbered,
.prompt-library-line-trait {
  font: 0.9rem/1.58 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.prompt-library-line-trait {
  margin-top: 2px;
  padding-top: 6px;
  border-top: 1px solid rgba(216, 210, 201, 0.45);
}

.prompt-library-line-trait + .prompt-library-line-trait {
  margin-top: 0;
}

.prompt-library-line-numbered,
.prompt-library-line-bullet {
  color: #2a2520;
}

.prompt-library-enum {
  display: inline;
  color: #3a2b17;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  background: rgba(234, 226, 213, 0.55);
  border-radius: 6px;
  padding: 0 3px;
}

.prompt-library-lightbox-actions {
  margin-top: 0;
  padding-top: 0;
}

.structured-traits-lightbox-content .structured-traits-panel {
  min-height: 0;
}

.structured-traits-lightbox-content .structured-traits-matrix-wrap,
.structured-traits-lightbox-content .structured-traits-scoring-wrap {
  flex: 1 1 auto;
  min-height: 0;
}

.structured-traits-lightbox-actions {
  margin-top: 0;
  padding-top: 0;
}

.description-audit-modal-card {
  max-width: 920px;
  display: grid;
  gap: 14px;
}

.debug-lightbox-header {
  margin-bottom: 10px;
}

.debug-lightbox-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 14px;
}

.debug-lightbox-table-wrap {
  overflow-x: auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  width: 100%;
  max-width: none;
  max-height: none;
  flex: 1 1 auto;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
}

.debug-score-table {
  width: max-content;
  min-width: 100%;
  min-width: 1280px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.84rem;
}

.debug-score-table th,
.debug-score-table td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(216, 210, 201, 0.75);
  border-right: 1px solid rgba(216, 210, 201, 0.55);
  vertical-align: top;
  text-align: left;
}

.debug-score-table th:last-child,
.debug-score-table td:last-child {
  border-right: 0;
}

.debug-score-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: rgba(248, 244, 238, 0.98);
}

.debug-score-group-row th {
  top: 0;
  z-index: 3;
  text-align: center;
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.debug-score-field-row th {
  top: 36px;
  z-index: 2;
}

.debug-score-group-header {
  background: rgba(238, 234, 226, 0.98);
}

.debug-score-table tbody tr:last-child td {
  border-bottom: 0;
}

.debug-score-header-main {
  display: block;
  font-weight: 700;
  color: var(--text);
}

.debug-score-header-sub {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.74rem;
  line-height: 1.3;
  white-space: normal;
}

.debug-score-table td.debug-score-number,
.debug-score-table th.debug-score-number {
  text-align: right;
  white-space: nowrap;
}

.debug-score-table td.debug-score-product {
  min-width: 180px;
}

.debug-score-table td.debug-score-file {
  min-width: 150px;
}

.debug-score-image-wrap {
  display: grid;
  gap: 8px;
}

.debug-score-image-thumb {
  width: 88px;
  height: 88px;
  object-fit: contain;
  object-position: center;
  border-radius: 10px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  background: rgba(248, 244, 238, 0.9);
}

.debug-score-image-label {
  display: block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 0.72rem;
  line-height: 1.25;
  word-break: break-word;
  color: var(--muted);
}

.debug-score-cell-hit {
  background: rgba(88, 170, 116, 0.18);
}

.debug-score-cell-miss {
  background: rgba(214, 106, 106, 0.16);
}

.debug-score-cell-neutral {
  background: rgba(90, 80, 68, 0.06);
  color: var(--muted);
}

.debug-score-cell-value {
  display: block;
  font-weight: 600;
  color: var(--text);
}

.debug-score-cell-meta {
  display: block;
  margin-top: 4px;
  font-size: 0.72rem;
  line-height: 1.2;
  color: var(--muted);
}

.debug-score-cell-empty {
  display: block;
  color: var(--muted);
}

.debug-score-totals-row td {
  position: sticky;
  bottom: 0;
  background: rgba(248, 244, 238, 0.98);
  font-weight: 600;
  z-index: 1;
}

.structured-traits-list {
  display: grid;
  gap: 10px;
}

.structured-traits-tab-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.structured-traits-tab {
  padding: 10px 14px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--muted);
  cursor: pointer;
}

.structured-traits-tab.is-active {
  background: #151126;
  color: #fff;
  border-color: #151126;
}

.structured-traits-panel {
  display: grid;
  gap: 16px;
}

.structured-traits-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}

.structured-traits-summary-card {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  background: rgba(255, 255, 255, 0.82);
}

.structured-traits-summary-value {
  font-size: 1.4rem;
  line-height: 1;
}

.structured-traits-summary-label {
  color: var(--muted);
  font-size: 0.84rem;
}

.structured-traits-filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.structured-traits-filter-button {
  padding: 8px 12px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--muted);
  cursor: pointer;
}

.structured-traits-filter-button.is-active {
  background: rgba(21, 17, 38, 0.08);
  color: var(--text);
  border-color: rgba(21, 17, 38, 0.22);
}

.structured-traits-matrix-wrap,
.structured-traits-scoring-wrap {
  overflow: auto;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.74);
}

.structured-traits-matrix-table,
.structured-traits-scoring-table {
  width: 100%;
  border-collapse: collapse;
}

.structured-traits-groupings-table {
  table-layout: fixed;
}

.structured-traits-groupings-col-trait {
  width: 23%;
}

.structured-traits-groupings-col-grouped {
  width: 34%;
}

.structured-traits-groupings-col-ungrouped {
  width: 43%;
}

.structured-traits-matrix-table th,
.structured-traits-matrix-table td,
.structured-traits-scoring-table th,
.structured-traits-scoring-table td {
  padding: 14px;
  border-bottom: 1px solid rgba(216, 210, 201, 0.75);
  vertical-align: top;
}

.structured-traits-matrix-table thead th,
.structured-traits-scoring-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: rgba(248, 244, 238, 0.98);
  text-align: left;
}

.structured-traits-matrix-table th:first-child,
.structured-traits-scoring-table th:first-child {
  min-width: 210px;
}

.structured-traits-matrix-key,
.structured-traits-scoring-key,
.structured-traits-matrix-trait-key {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.8rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.structured-traits-matrix-trait {
  position: sticky;
  left: 0;
  z-index: 1;
  background: rgba(248, 244, 238, 0.98);
}

.structured-traits-matrix-trait-title,
.structured-traits-section-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
}

.structured-traits-matrix-table th,
.structured-traits-matrix-table td {
  white-space: normal;
  word-break: break-word;
}

.structured-traits-matrix-table td {
  min-width: 220px;
  line-height: 1.45;
}

.structured-traits-matrix-table td.is-absent {
  background: rgba(116, 116, 116, 0.08);
}

.structured-traits-matrix-table thead th:first-child,
.structured-traits-matrix-table tbody th.structured-traits-matrix-trait,
.structured-traits-drift-row th.structured-traits-drift-label-cell {
  left: 0;
}

.structured-traits-value-stack,
.structured-traits-badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.structured-traits-badge-row {
  margin-top: 10px;
}

.structured-traits-value-chip,
.structured-traits-badge,
.structured-traits-absent-label {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  background: rgba(255, 255, 255, 0.92);
  font-size: 0.8rem;
  line-height: 1.2;
}

.structured-traits-value-chip.is-phrasing {
  border-color: rgba(64, 127, 255, 0.6);
  box-shadow: inset 0 0 0 1px rgba(64, 127, 255, 0.22);
}

.structured-traits-absent-label,
.structured-traits-badge-absent {
  background: rgba(116, 116, 116, 0.08);
  border-color: rgba(116, 116, 116, 0.24);
  color: #5a5752;
}

.structured-traits-badge-critical {
  border-color: rgba(191, 117, 23, 0.35);
  color: #7a4900;
}

.structured-traits-badge-missing {
  background: rgba(242, 197, 102, 0.14);
  border-color: rgba(201, 142, 33, 0.28);
  color: #7a5600;
}

.structured-traits-badge-extra {
  background: rgba(255, 229, 148, 0.16);
  border-color: rgba(194, 159, 42, 0.28);
  color: #6e5b00;
}

.structured-traits-badge-phrasing {
  background: rgba(110, 155, 255, 0.12);
  border-color: rgba(64, 127, 255, 0.24);
  color: #1e54b7;
}

.structured-traits-badge-grouping {
  background: rgba(148, 110, 255, 0.12);
  border-color: rgba(112, 74, 221, 0.24);
  color: #5a35b0;
}

.structured-traits-badge-clean {
  background: rgba(71, 138, 95, 0.1);
  border-color: rgba(71, 138, 95, 0.22);
  color: #2d6f46;
}

.structured-traits-section-card {
  display: grid;
  gap: 12px;
}

.structured-traits-drift-row th,
.structured-traits-drift-row td {
  background: rgba(250, 247, 242, 0.88);
}

.structured-traits-drift-label-cell {
  position: sticky;
  left: 0;
  z-index: 1;
  color: var(--muted);
  font-size: 0.84rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: rgba(250, 247, 242, 0.96);
}

.structured-traits-drift-detail-cell {
  padding-top: 12px;
  padding-bottom: 16px;
}

.structured-traits-drift-list {
  display: grid;
  gap: 8px;
}

.structured-traits-drift-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  flex-wrap: wrap;
}

.structured-traits-drift-text {
  color: var(--text);
  font-size: 0.88rem;
  line-height: 1.5;
}

.structured-traits-card {
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.76);
  overflow: hidden;
}

.structured-traits-toggle {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 0;
  background: transparent;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.structured-traits-toggle-label {
  display: grid;
  gap: 3px;
}

.structured-traits-category {
  font-weight: 600;
}

.structured-traits-key {
  color: var(--muted);
  font-size: 0.86rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.structured-traits-chevron {
  color: var(--muted);
  font-size: 0.95rem;
  transition: transform 160ms ease;
}

.structured-traits-card[open] .structured-traits-chevron {
  transform: rotate(90deg);
}

.structured-traits-body {
  padding: 0 16px 16px;
  border-top: 1px solid rgba(216, 210, 201, 0.75);
}

.structured-traits-actions {
  display: flex;
  justify-content: flex-end;
  padding-top: 12px;
  padding-bottom: 12px;
}

.structured-traits-copy-button {
  padding: 8px 12px;
  box-shadow: none;
}

.structured-traits-empty,
.structured-traits-field {
  margin: 0;
  color: var(--text);
  font: 0.9rem/1.5 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  word-break: break-word;
}

.structured-traits-field + .structured-traits-field {
  margin-top: 8px;
}

.rules-summary-intro {
  margin: 0;
  color: var(--muted);
}

.rules-summary-list {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 8px;
}

.rules-summary-grid {
  display: grid;
  gap: 10px;
}

.rules-card {
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.76);
  padding: 12px 14px;
}

.rules-card-title {
  margin: 0 0 8px;
  font-size: 0.92rem;
}

.rules-card-list {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.87rem;
}

.extraction-summary-content {
  display: grid;
  gap: 14px;
}

.extraction-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.extraction-summary-card {
  display: grid;
  gap: 10px;
}

.extraction-summary-metric {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
}

.extraction-summary-table-card {
  display: grid;
  gap: 12px;
}

.extraction-summary-table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(216, 210, 201, 0.8);
  border-radius: 14px;
}

.extraction-summary-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.extraction-summary-table th,
.extraction-summary-table td {
  padding: 11px 12px;
  border-bottom: 1px solid rgba(216, 210, 201, 0.65);
  text-align: left;
}

.extraction-summary-table th {
  background: rgba(248, 244, 238, 0.85);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.category-mapping-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: rgba(248, 244, 238, 0.98);
}

.category-mapping-table th:first-child,
.category-mapping-table td:first-child {
  min-width: 340px;
}

.extraction-summary-table tbody tr:last-child td {
  border-bottom: 0;
}

.extraction-summary-row.is-expandable {
  cursor: pointer;
}

.extraction-summary-row.is-expandable:hover td {
  background: rgba(248, 244, 238, 0.55);
}

.extraction-summary-row.is-expandable:focus-within td,
.extraction-summary-row.is-expandable:focus-visible td {
  outline: 2px solid rgba(111, 84, 234, 0.28);
  outline-offset: -2px;
}

.extraction-summary-category-cell {
  display: flex;
  align-items: center;
  gap: 8px;
}

.extraction-summary-row-indicator {
  color: var(--muted);
  width: 12px;
  flex: 0 0 12px;
}

.extraction-summary-number-cell,
.extraction-summary-health-cell,
.extraction-summary-trait-value,
.extraction-summary-trait-delta,
.extraction-summary-trait-supplemental {
  font-variant-numeric: tabular-nums;
}

.extraction-summary-health-cell.is-warning {
  color: #9a5a00;
  font-weight: 600;
}

.extraction-summary-detail-row td {
  padding: 0;
  background: transparent;
}

.extraction-summary-detail-panel {
  margin: 0 12px 12px 32px;
  padding: 12px 14px;
  border-left: 2px solid rgba(111, 84, 234, 0.18);
  border-radius: 0 12px 12px 0;
  background: rgba(248, 244, 238, 0.72);
  display: grid;
  gap: 8px;
}

.extraction-summary-trait-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 12px;
  font-size: 0.9rem;
}

.extraction-summary-trait-line.is-quiet {
  color: var(--muted);
  font-size: 0.86rem;
}

.extraction-summary-trait-name {
  font-family: "SFMono-Regular", SFMono-Regular, ui-monospace, Menlo, Consolas, monospace;
}

.extraction-summary-trait-value-wrap {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  justify-content: flex-end;
}

.extraction-summary-trait-value-wrap.has-context {
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.extraction-summary-trait-value.is-warning {
  color: #9a5a00;
  font-weight: 600;
}

.extraction-summary-trait-value.is-severe {
  color: #b42318;
  font-weight: 700;
}

.extraction-summary-trait-value.is-applicable-strong {
  color: #157347;
  font-weight: 700;
}

.extraction-summary-trait-context {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.2;
  text-align: right;
  max-width: 28ch;
}

.extraction-summary-trait-delta {
  color: var(--muted);
  font-size: 0.83rem;
}

.extraction-summary-trait-supplemental {
  color: var(--muted);
  font-size: 0.83rem;
}

.extraction-summary-breakdown-toggle {
  justify-self: start;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
}

.extraction-summary-breakdown-toggle:hover {
  color: var(--text);
}

.category-mapping-modal-card {
  width: min(1400px, calc(100vw - 40px));
}

.category-mapping-content {
  display: grid;
  gap: 14px;
}

.category-mapping-controls {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  align-items: end;
}

.category-mapping-control {
  display: grid;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--muted);
}

.category-mapping-control span {
  font-weight: 600;
  color: var(--text);
}

.category-mapping-control input,
.category-mapping-control select {
  width: 100%;
  border-radius: 10px;
  border: 1px solid rgba(216, 210, 201, 0.9);
  background: rgba(255, 255, 255, 0.9);
  color: var(--text);
  padding: 10px 12px;
  font: inherit;
}

.category-mapping-table td,
.category-mapping-product-table td {
  vertical-align: top;
}

.category-mapping-grouping-labels {
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1.45;
  white-space: normal;
  overflow-wrap: anywhere;
}

.category-mapping-source-badge,
.category-mapping-stale-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.category-mapping-source-badge.is-table {
  background: rgba(16, 185, 129, 0.14);
  color: #047857;
}

.category-mapping-source-badge.is-decision {
  background: rgba(59, 130, 246, 0.14);
  color: #1d4ed8;
}

.category-mapping-source-badge.is-legacy_extraction {
  background: rgba(245, 158, 11, 0.16);
  color: #b45309;
}

.category-mapping-source-badge.is-unmapped {
  background: rgba(220, 38, 38, 0.12);
  color: #b91c1c;
}

.category-mapping-stale-badge {
  margin-left: 8px;
  background: rgba(148, 163, 184, 0.18);
  color: #475569;
}

.category-mapping-detail-panel {
  margin-left: 16px;
}

.category-mapping-product-table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(216, 210, 201, 0.75);
  border-radius: 12px;
}

.category-mapping-product-table {
  min-width: 900px;
}

.category-mapping-id-cell {
  font-family: "SFMono-Regular", SFMono-Regular, ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.82rem;
}

.pipeline-diagnostics-note {
  color: var(--muted);
}

.extraction-summary-divider {
  border-top: 1px solid rgba(216, 210, 201, 0.75);
  margin: 2px 0 0;
}

.modal-header,
.modal-upload-grid,
.modal-results-grid,
.modal-actions {
  display: grid;
  gap: 18px;
}

.modal-header {
  grid-template-columns: 1fr auto;
  align-items: start;
  margin-bottom: 18px;
}

.modal-eyebrow {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.modal-title {
  margin: 0;
  font-size: 1.6rem;
  line-height: 1.1;
}

.modal-close {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.88);
  cursor: pointer;
  color: transparent;
  font-size: 0;
  background-image: url("/pixelseek-icons/close.svg");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px 10px;
}

.modal-upload-grid,
.modal-results-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.image-search-modal-header {
  margin-bottom: 14px;
}

.image-search-modal-header .modal-eyebrow {
  margin-bottom: 8px;
  color: #9ca3af;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.image-search-modal-header .modal-title {
  color: #111827;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.image-search-modal-card .modal-close {
  width: 28px;
  height: 28px;
  border: 0;
  background-color: transparent;
  background-size: 12px 12px;
  opacity: 0.95;
}

.modal-upload-block {
  padding: 16px 18px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.74);
}

.image-search-upload-stage {
  display: grid;
  gap: 16px;
}

.image-search-upload-note {
  margin: 0;
  color: #6b7280;
  font-size: 14px;
  line-height: 1.45;
}

.image-search-upload-grid {
  grid-template-columns: 1fr;
  gap: 14px;
}

.image-search-upload-block {
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
}

.image-search-upload-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
}

.image-search-upload-row-url {
  grid-template-columns: auto minmax(0, 1fr);
}

.image-search-upload-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background-color: #f3f4f6;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 14px 14px;
  flex: 0 0 auto;
}

.image-search-upload-icon-upload {
  background-image: url("/pixelseek-icons/upload-image.svg");
}

.image-search-upload-icon-camera {
  background-image: url("/pixelseek-icons/camera.svg");
}

.image-search-upload-icon-url {
  background-image: url("/pixelseek-icons/url.svg");
}

.image-search-upload-copy {
  min-width: 0;
}

.image-search-upload-title,
.image-search-upload-subtitle {
  margin: 0;
}

.image-search-upload-title {
  color: #111827;
  font-size: 13px;
  font-weight: 700;
}

.image-search-upload-subtitle {
  margin-top: 3px;
  color: #9ca3af;
  font-size: 11px;
}

.image-search-upload-copy-url {
  display: grid;
  gap: 8px;
}

.modal-url-input {
  width: 100%;
  min-height: 48px;
  padding: 0 14px 0 34px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  color: var(--text);
  background-image: url("/pixelseek-icons/url.svg");
  background-repeat: no-repeat;
  background-position: 12px center;
  background-size: 12px 12px;
}

.image-search-url-input {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #ffffff;
  background-image: none;
  color: #111827;
  box-shadow: none;
}

.image-search-url-input::placeholder {
  color: #9ca3af;
}

.image-search-url-input:focus {
  outline: none;
}

.modal-helper {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.image-search-file-name {
  margin-top: 10px;
  padding-left: 48px;
  color: #6b7280;
  font-size: 13px;
}

.modal-actions {
  grid-template-columns: auto auto;
  justify-content: end;
  margin-top: 18px;
}

.image-search-modal-actions {
  grid-template-columns: 1fr;
  justify-content: center;
  margin-top: 2px;
}

.modal-actions.focus-stage-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  justify-content: stretch;
  align-items: center;
  width: 100%;
  margin-top: 14px;
  column-gap: 16px;
}

.image-search-choose-button {
  min-height: 32px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid #7c3aed;
  background: #ffffff;
  color: #7c3aed;
  box-shadow: none;
  font-size: 13px;
  font-weight: 600;
}

.image-search-choose-button:hover {
  background: #faf5ff;
}

.image-search-analyze-button {
  justify-self: center;
  width: auto;
  min-width: 190px;
  min-height: 42px;
  padding: 0 26px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(to right, #7c3aed, #6d28d9);
  box-shadow: none;
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
}

.image-search-analyze-button:hover {
  background: linear-gradient(to right, #6d28d9, #5b21b6);
}

.image-search-analyze-button::before {
  content: "";
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  background: center / contain no-repeat url("/pixelseek-icons/start-from-image.svg");
}

.image-analyze-loading {
  margin-top: 14px;
  width: 100%;
}

.image-analyze-loading-card {
  display: grid;
  gap: 10px;
  width: min(100%, 420px);
  padding: 14px 16px;
  border: 1px solid rgba(173, 139, 241, 0.28);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(246, 239, 255, 0.92));
  box-shadow: 0 12px 26px rgba(78, 45, 142, 0.08);
}

.image-analyze-loading-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.image-analyze-loading-eyebrow {
  margin: 0 0 2px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #8f74ca;
}

.image-analyze-loading-title {
  margin: 0;
  color: #1d1632;
  font-size: 0.98rem;
  font-weight: 600;
}

.image-analyze-loading-percent {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(164, 117, 240, 0.14);
  color: #7a48d6;
  font-size: 0.9rem;
  font-weight: 700;
  white-space: nowrap;
}

.image-analyze-loading-detail {
  margin: 0;
  color: #6d6781;
  font-size: 0.91rem;
}

.image-analyze-progressbar {
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: rgba(131, 65, 255, 0.10);
}

.image-analyze-progressbar-fill {
  position: relative;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #8a58ff 0%, #6eebbb 100%);
  transition: width 220ms ease;
  overflow: hidden;
}

.image-analyze-progressbar-fill.is-indeterminate::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-45%);
  background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.20) 25%, rgba(255, 255, 255, 0.75) 50%, rgba(255, 255, 255, 0.20) 75%, transparent 100%);
  animation: image-analyze-progressband 1.35s ease-in-out infinite;
}

.image-analyze-segmented-track {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.image-analyze-segment {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid rgba(31, 24, 52, 0.08);
  background: rgba(255, 255, 255, 0.68);
  color: #8b869c;
  font-size: 0.81rem;
  font-weight: 600;
  transition: background 180ms ease, border-color 180ms ease, color 180ms ease;
  position: relative;
  gap: 6px;
}

.image-analyze-segment.is-active {
  border-color: #8341ff;
  background: #8341ff;
  color: #ffffff;
  box-shadow: none;
}

.image-analyze-segment.is-complete {
  border-color: #1fa971;
  background: #dff5ec;
  color: #157a53;
  box-shadow: inset 0 0 0 1px rgba(31, 169, 113, 0.14);
}

.image-analyze-segment.is-complete::before {
  content: "✓";
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1;
}

.image-analyze-segment.is-active::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: currentColor;
}

@keyframes image-analyze-progressband {
  0% {
    transform: translateX(-45%);
  }
  100% {
    transform: translateX(100%);
  }
}

.results-shell {
  margin-top: 26px;
  padding-bottom: 48px;
}

body.results-loading-active .results-header,
body.results-loading-active #manageActions,
body.results-loading-active .results-sidebar {
  display: none !important;
}

html.landing-home body .site-nav-end,
html.landing-home body .results-shell {
  display: none !important;
}

html.initial-search-pending body .page-shell,
html.initial-search-pending body .status-panel,
html.initial-search-pending body #clarificationBar,
html.initial-search-pending body .results-header,
html.initial-search-pending body #manageActions,
html.initial-search-pending body .results-sidebar {
  display: none !important;
}

html.landing-home body .page-shell {
  min-height: auto;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding-top: 149px;
  padding-bottom: 96px;
}

html.landing-home body .hero {
  padding-top: 0;
}

html.landing-home body .search-panel {
  margin-top: 22px;
}

html.landing-home body .search-secondary {
  display: grid;
  gap: 16px;
  width: min(100%, 980px);
  margin: 16px auto 0;
  padding: 0 14px;
}

html.landing-home body .context-row {
  align-items: center;
  gap: 12px;
  transform: none;
}

html.landing-home body .context-label {
  min-width: 0;
  padding-top: 0;
  font-size: 0.92rem;
  color: #6f6a64;
}

html.landing-home body .context-pills,
html.landing-home body .seed-queries {
  flex: 1 1 auto;
}

html.landing-home body .seed-image-examples {
  flex: 0 0 auto;
}

html.landing-home body .search-secondary {
  margin-top: 50px;
}

html.landing-home body .search-image-trigger {
  display: none !important;
}

html.landing-home body .context-pill,
html.landing-home body .seed-query {
  padding: 9px 13px;
  background: rgba(228, 228, 235, 0.9);
  color: #7f87a0;
}

html.landing-home body .seed-query-image-card {
  padding: 8px 14px 8px 8px;
  background: rgba(255, 255, 255, 0.94);
  color: #2a3040;
  border: 1px solid rgba(214, 218, 229, 0.95);
}

html.landing-home body .seed-query-image-card:hover {
  background: rgba(255, 255, 255, 0.98);
  border-color: #7f77dd;
  box-shadow: inset 0 0 0 1px rgba(127, 119, 221, 0.78);
  color: #2a3040;
}

html.landing-home body .seed-query-image-card.is-active {
  background: rgba(246, 244, 255, 0.98);
  color: #2a3040;
}

html.landing-home body .seed-queries {
  gap: 6px;
}

html:not(.landing-home) body .hero-subhead {
  display: none;
}

html:not(.landing-home) body .search-entry-grid {
  display: block;
}

html:not(.landing-home) body .search-entry-card-image {
  display: none;
}

html:not(.landing-home) body .search-entry-card-text {
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
  border-radius: 0;
}

html:not(.landing-home) body .search-entry-card-text .search-entry-icon,
html:not(.landing-home) body .search-entry-card-text .search-entry-title,
html:not(.landing-home) body .search-entry-card-text .search-entry-copy {
  display: none;
}

html:not(.landing-home) body .search-entry-upload-button {
  display: none;
}

html:not(.landing-home) body .search-field {
  min-height: 82px;
  margin-top: 0;
  padding: 14px 10px;
  border-radius: 32px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.95);
}

html:not(.landing-home) body .search-query-flow {
  padding: 0 4px 0 25px;
}

html:not(.landing-home) body .search-input {
  font-size: 1.1rem;
}

html:not(.landing-home) body .search-image-trigger {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 18px;
  border: none !important;
  border-radius: 999px;
  background: #7c6df0 !important;
  color: #fff !important;
  font-size: 0.88rem;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
}

html:not(.landing-home) body .search-image-trigger:hover {
  background: #6355d4 !important;
}

html:not(.landing-home) body .context-row-centered {
  flex-direction: row;
  justify-content: flex-start;
  align-items: center;
  gap: 12px;
  text-align: left;
}

html:not(.landing-home) body .seed-queries {
  justify-content: flex-start;
}

html.landing-home body .context-pill:hover,
html.landing-home body .seed-query:hover:not(.seed-query-image-card),
html.landing-home body .context-pill.is-active,
html.landing-home body .seed-query.is-active:not(.seed-query-image-card) {
  background: #7c6df0;
  color: #ffffff;
}

.results-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.results-layout.has-sidebar {
  grid-template-columns: 300px minmax(0, 1fr);
}

.results-layout.has-browse-sidebar {
  grid-template-columns: 300px minmax(0, 1fr);
}

.cached-search-progress-strip {
  position: fixed;
  top: 0;
  left: 0;
  width: 0;
  height: 2px;
  opacity: 0;
  z-index: 2000;
  pointer-events: none;
  background: linear-gradient(90deg, #7c3aed 0%, #8b5cf6 100%);
  transition:
    width 320ms cubic-bezier(0.16, 1, 0.3, 1),
    opacity 300ms ease;
  will-change: width, opacity;
}

.results-loading-active .results-layout,
body.results-loading-active .results-layout {
  grid-template-columns: minmax(0, 1fr) !important;
}

.results-main {
  min-width: 0;
}

.results-loading-panel {
  display: grid;
  justify-items: center;
  align-content: start;
  min-height: 520px;
  padding-top: 56px;
}

.results-loading-card {
  width: min(100%, 420px);
}

.results-loading-panel.is-quick {
  min-height: 260px;
  padding-top: 36px;
}

.results-loading-panel.is-quick .results-loading-card {
  width: min(100%, 560px);
}

.results-loading-panel.is-quick .text-search-loading-card {
  padding: 28px 28px 24px;
  gap: 0;
}

.results-loading-panel.is-quick .image-analyze-loading-header {
  align-items: start;
}

.results-loading-panel.is-quick .image-analyze-loading-eyebrow {
  margin-bottom: 10px;
}

.results-loading-panel.is-quick .image-analyze-loading-title {
  font-size: 20px;
  line-height: 1.25;
}

.results-loading-panel.is-quick .image-analyze-progressbar {
  margin-top: 18px;
  height: 8px;
}

.results-loading-panel.is-quick .image-analyze-segmented-track,
.results-loading-panel.is-quick .image-analyze-loading-percent {
  display: none !important;
}

.results-loading-panel.is-quick .results-loading-copy,
.results-loading-panel.is-quick .image-analyze-loading-detail {
  margin-top: 16px;
  font-size: 14px;
  line-height: 1.45;
  max-width: 42ch;
}

.text-search-loading-card {
  width: 100%;
  max-width: none;
  margin-inline: auto;
  padding: 40px 32px;
  border-radius: var(--border-radius-lg, 28px);
  gap: 0;
}

.results-loading-category-requirement {
  margin-top: 22px;
  width: 100%;
}

.results-loading-category-requirement .clarification-card-category {
  gap: 16px;
}

.text-search-loading-card .image-analyze-loading-header {
  gap: 16px;
}

.text-search-loading-card .image-analyze-loading-eyebrow {
  font-size: 12px;
  margin: 0 0 12px;
}

.text-search-loading-card .image-analyze-loading-title {
  font-size: 24px;
  font-weight: 500;
  line-height: 1.2;
}

.text-search-loading-card .results-loading-copy,
.text-search-loading-card .image-analyze-loading-detail {
  margin-top: 24px;
  font-size: 14px;
  line-height: 1.45;
  max-width: none;
}

.text-search-loading-card .image-analyze-progressbar {
  margin-top: 28px;
  height: 10px;
}

.text-search-loading-card .image-analyze-loading-percent {
  padding: 4px 12px;
  font-size: 13px;
  min-width: 0;
}

.text-search-loading-card .image-analyze-segmented-track {
  margin-top: 28px;
  gap: 8px;
}

.text-search-loading-card .image-analyze-segment {
  min-height: 42px;
  padding: 10px 20px;
  font-size: 14px;
}

.results-loading-copy {
  max-width: 34ch;
}

.results-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  align-items: center;
  gap: 16px 24px;
  margin-bottom: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(149, 155, 177, 0.28);
}

.results-header-summary {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  min-width: 0;
  grid-column: 1;
}

.results-header p {
  margin: 0;
  font-size: 1.575rem;
}

.results-header p strong {
  font-weight: 700;
}

.results-sort {
  display: flex;
  align-items: center;
  justify-self: start;
  color: var(--muted);
  font-size: 0.92rem;
}

#refreshAgeFilterSelect {
  transform: translateX(15px);
}

.results-header.is-search-mode .results-sort-category {
  display: none;
}

.mobile-long-press-hint {
  display: none;
}

.results-sort select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  min-height: 40px;
  border: 1px solid #d9cec0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  padding: 0 36px 0 14px;
  font: inherit;
  font-size: 0.88rem;
  color: var(--text);
  cursor: pointer;
  background-image: url("/pixelseek-icons/carrot-dropdown.svg");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 12px;
}

.search-category-menu {
  position: relative;
  min-width: 212px;
}

.search-category-menu summary {
  list-style: none;
}

.search-category-menu summary::-webkit-details-marker {
  display: none;
}

.search-category-button {
  display: inline-flex;
  align-items: center;
  width: 100%;
  min-height: 40px;
  border: 1px solid #d9cec0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  padding: 0 38px 0 14px;
  font: inherit;
  font-size: 0.88rem;
  color: var(--text);
  cursor: pointer;
  background-image: url("/pixelseek-icons/carrot-dropdown.svg");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 12px;
  user-select: none;
  box-shadow: 0 8px 18px rgba(62, 51, 35, 0.04);
}

.search-category-menu[open] .search-category-button {
  border-color: rgba(124, 109, 240, 0.45);
  box-shadow: 0 10px 24px rgba(92, 74, 215, 0.12);
}

.search-category-panel {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 18;
  display: grid;
  gap: 4px;
  min-width: 240px;
  padding: 10px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 34px rgba(44, 32, 17, 0.16);
}

.search-category-option {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.9rem;
  text-align: left;
  cursor: pointer;
}

.search-category-option:hover,
.search-category-option:focus-visible {
  background: rgba(124, 109, 240, 0.08);
  outline: none;
}

.search-category-option.is-active {
  background: rgba(124, 109, 240, 0.12);
  color: #2f2664;
}

.search-category-option-label {
  min-width: 0;
}

.search-category-option-check {
  font-size: 0.92rem;
  font-weight: 700;
  color: #7c6df0;
  opacity: 0;
}

.search-category-option.is-active .search-category-option-check {
  opacity: 1;
}

.results-multiselect {
  position: relative;
}

.results-multiselect summary {
  list-style: none;
}

.results-multiselect summary::-webkit-details-marker {
  display: none;
}

.results-multiselect-button {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  min-width: 212px;
  border: 1px solid #d9cec0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  padding: 0 36px 0 14px;
  font: inherit;
  font-size: 0.88rem;
  color: var(--text);
  cursor: pointer;
  background-image: url("/pixelseek-icons/carrot-dropdown.svg");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 12px;
  white-space: nowrap;
}

.results-multiselect[open] .results-multiselect-button {
  border-bottom-left-radius: 18px;
  border-bottom-right-radius: 18px;
}

.results-multiselect-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 15;
  display: grid;
  gap: 8px;
  min-width: 240px;
  max-height: 280px;
  overflow: auto;
  padding: 12px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: var(--shadow);
}

.results-multiselect-option {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--text);
  cursor: pointer;
}

.results-multiselect-option input {
  width: 16px;
  height: 16px;
  margin: 0;
}

.refine-toggle-button {
  display: none;
}

.batch-manage-bar {
  grid-column: 5;
  justify-self: start;
  display: flex;
  align-items: center;
}

.batch-manage-actions {
  width: 100%;
  min-width: 0;
}

.batch-manage-trigger {
  justify-content: center;
}

.batch-manage-panel-row {
  margin: 0 0 18px;
}

.batch-manage-controls,
.batch-refresh-progress {
  display: grid;
  gap: 12px;
  width: 100%;
  min-width: 0;
  padding: 18px 20px;
  box-sizing: border-box;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.batch-manage-links {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  flex-wrap: wrap;
}

.batch-manage-link {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.batch-manage-link:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.batch-manage-link-right {
  margin-left: auto;
}

.batch-refresh-primary {
  justify-self: end;
}

.batch-refresh-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.batch-refresh-ids-toggle {
  color: var(--text);
}

.batch-refresh-ids-panel {
  display: grid;
  gap: 10px;
  padding: 14px 16px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 14px;
  background: rgba(248, 244, 238, 0.72);
}

.batch-refresh-ids-label {
  font-size: 0.88rem;
  color: var(--text);
}

.batch-refresh-ids-input {
  width: 100%;
  min-height: 96px;
  padding: 10px 12px;
  box-sizing: border-box;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--text);
  font: inherit;
  line-height: 1.45;
  resize: vertical;
}

.batch-refresh-ids-input:focus {
  outline: 2px solid color-mix(in srgb, var(--violet) 18%, transparent);
  outline-offset: 2px;
  border-color: color-mix(in srgb, var(--violet) 55%, white);
}

.batch-refresh-ids-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.batch-refresh-ids-count {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.batch-refresh-ids-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

#manageSelectionButton.manage-button[aria-pressed="true"] {
  background: #151126 !important;
  color: #fff !important;
}

#manageSelectionButton.manage-button[aria-pressed="true"]:hover {
  background: #080617 !important;
}

.batch-refresh-progress {
  gap: 10px;
}

.batch-refresh-headline,
.batch-refresh-meta,
.batch-refresh-current,
.batch-refresh-summary {
  margin: 0;
}

.batch-refresh-headline {
  color: var(--text);
  font-weight: 600;
}

.batch-refresh-meter-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.batch-refresh-meter {
  overflow: hidden;
  min-width: 0;
  height: 12px;
  border-radius: 999px;
  background: #e7e1d8;
}

.batch-refresh-meter-fill {
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: #151126;
  transition: width 180ms ease;
}

.batch-refresh-count {
  color: var(--text);
  font-size: 0.95rem;
  white-space: nowrap;
}

.batch-refresh-meta,
.batch-refresh-current,
.batch-refresh-summary,
.batch-refresh-failures {
  color: var(--muted);
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.batch-refresh-log {
  display: grid;
  gap: 8px;
  max-height: 172px;
  min-width: 0;
  overflow-y: auto;
  padding-right: 4px;
}

.batch-refresh-log-entry {
  color: var(--text);
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.batch-refresh-log-entry.failed {
  color: #8d2f2f;
}

.batch-refresh-failures {
  display: grid;
  gap: 4px;
  padding-top: 2px;
}

.batch-refresh-close {
  justify-self: start;
}

.scene-filter-progress-panel {
  margin-bottom: 18px;
}

.scene-filter-progress {
  gap: 10px;
  border-radius: 18px;
}

.scene-filter-progress-summary-line {
  display: block;
  padding: 14px 18px;
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

.scene-filter-progress-summary-line::-webkit-details-marker {
  display: none;
}

.scene-filter-progress-body {
  padding: 0 18px 18px;
}

.scene-filter-progress-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.scene-filter-progress-fill {
  background: linear-gradient(90deg, #3d6f5d 0%, #1f4f40 100%);
}

.scene-filter-progress-left {
  margin: 0;
  color: var(--muted);
  white-space: nowrap;
}

.scene-filter-resume-button {
  justify-self: start;
}

.status-panel {
  min-height: 24px;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.status-panel:empty {
  min-height: 0;
  margin-bottom: 0;
}

.status-panel-action {
  border: 1px solid rgba(124, 109, 240, 0.22);
  border-radius: 999px;
  background: rgba(124, 109, 240, 0.1);
  color: #5d53b6;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1;
  padding: 9px 12px;
  cursor: pointer;
}

.clarification-bar {
  position: sticky;
  top: 12px;
  z-index: 18;
  margin: -4px 0 18px;
}

.results-info-banner {
  margin: 0 0 18px;
  padding: 12px 14px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 248, 232, 0.92);
  color: #6d5530;
  box-shadow: 0 18px 36px rgba(37, 28, 18, 0.06);
}

.results-info-banner.warning {
  background: rgba(255, 248, 232, 0.92);
  color: #6d5530;
}

.results-info-banner.similar-look-loading {
  border-color: rgba(171, 156, 242, 0.42);
  background:
    linear-gradient(135deg, rgba(250, 247, 255, 0.98) 0%, rgba(244, 239, 255, 0.96) 100%);
  color: #4f438f;
  box-shadow: 0 18px 36px rgba(95, 76, 186, 0.08);
  font-weight: 600;
}

.clarification-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 36px rgba(37, 28, 18, 0.08);
  backdrop-filter: blur(14px);
}

.clarification-card-category {
  align-items: center;
  flex-direction: column;
  gap: 18px;
  padding: 12px 0 12px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.clarification-text {
  margin: 0;
  color: var(--text);
  font-size: 0.96rem;
  line-height: 1.35;
}

.clarification-text-category {
  font-size: 1.26rem;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
}

.clarification-text-category .clarification-subtext {
  font-weight: 400;
}

.clarification-options {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-left: auto;
}

.clarification-options-category {
  display: grid;
  justify-content: center;
  gap: 12px;
  margin-left: 0;
  max-width: 520px;
}

.clarification-families,
.clarification-subcategories {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.clarification-pill-family.is-active {
  background: #7c6df0;
  color: #fff;
  border-color: rgba(124, 109, 240, 0.92);
}

.clarification-pill {
  border: 1px solid var(--chip-border);
  border-radius: 999px;
  background: var(--chip);
  color: var(--text);
  padding: 8px 12px;
  cursor: pointer;
  white-space: nowrap;
}

.clarification-pill-category {
  border: 1px solid rgba(223, 225, 235, 0.95);
  background: rgba(240, 241, 249, 0.9);
  color: #7d8397;
  padding: 9px 18px;
  font-size: 1.025rem;
  box-shadow: none;
}

.clarification-pill:hover {
  background: #f1ede6;
}

.clarification-pill-category:hover {
  background: rgba(232, 234, 246, 1);
}

.clarification-close {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  color: transparent;
  cursor: pointer;
  font-size: 0;
  background-image: url("/pixelseek-icons/close.svg");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px 10px;
}

.clarification-close-category {
  display: none;
}

.status-panel.error {
  color: #8d2f2f;
}

.status-panel.empty {
  color: #7b6a4e;
}

.results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(236px, 1fr));
  gap: 18px;
}

.results-grid.is-browse-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.results-empty-state {
  grid-column: 1 / -1;
  display: grid;
  justify-items: start;
  gap: 14px;
  padding: 24px 24px 22px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 20px 40px rgba(37, 28, 18, 0.06);
}

.results-empty-state-title {
  margin: 0;
  color: #5e503b;
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.45;
}

.results-empty-state-action {
  border: 1px solid rgba(124, 109, 240, 0.22);
  border-radius: 999px;
  background: rgba(124, 109, 240, 0.1);
  color: #5d53b6;
  font: inherit;
  font-size: 0.94rem;
  font-weight: 600;
  line-height: 1;
  padding: 11px 14px;
  cursor: pointer;
}

.results-empty-state-action:hover,
.results-empty-state-action:focus-visible {
  background: rgba(124, 109, 240, 0.16);
  outline: none;
}

.result-tile {
  padding-bottom: 12px;
}

.results-cutoff-section {
  grid-column: 1 / -1;
  display: grid;
  justify-items: stretch;
  gap: 12px;
  padding: 6px 0 2px;
}

.results-cutoff-toggle {
  width: 100%;
  justify-content: center;
  padding: 15px 24px;
  border-radius: 999px;
  border: 1px solid #111111;
  background: #111111;
  color: #ffffff;
  box-shadow: none;
  font-size: 0.95rem;
  font-weight: 700;
  transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease;
}

.results-cutoff-toggle:hover,
.results-cutoff-toggle:focus-visible {
  background: #6d28d9;
  border-color: #6d28d9;
  color: #ffffff;
}

.results-cutoff-toggle:focus-visible {
  outline: 2px solid rgba(109, 40, 217, 0.28);
  outline-offset: 2px;
}

.results-cutoff-divider {
  width: 100%;
  padding-top: 2px;
  color: #6b7280;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.result-tile-weaker {
  opacity: 0.76;
  transition: opacity 180ms ease, transform 180ms ease;
}

.result-tile-weaker:hover,
.result-tile-weaker:focus-within {
  opacity: 0.92;
}

.result-tile-weaker .score-badge {
  background: rgba(190, 64, 24, 0.94);
  color: #fff7f2;
  box-shadow: 0 8px 18px rgba(190, 64, 24, 0.2);
}


.results-sidebar {
  position: sticky;
  top: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px 16px;
  max-height: calc(100vh - 48px);
  min-height: 0;
  overflow: hidden;
  border: 0;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  backdrop-filter: none;
}

.results-sidebar-header {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: start;
  gap: 12px;
}

.results-sidebar-title {
  margin: 2px 0 0;
  color: #111827;
  font-size: 1.05rem;
  font-weight: 700;
}

.refine-selected-image-wrap {
  margin-top: 10px;
  margin-bottom: 8px;
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 12px;
  background: #f3f4f6;
}

.refine-selected-image {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 12px;
}

.refine-sidebar-close {
  display: none;
}

.results-sidebar-section {
  display: grid;
  gap: 0;
  min-height: 0;
}

.results-sidebar #browseTraitFilterPanel {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.refine-category-card {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
  padding: 14px;
  border: 1px solid #e5ddd0;
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 243, 237, 0.96));
}

.refine-category-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.refine-category-card-title {
  margin: 0;
}

.refine-category-select-wrap {
  display: block;
}

.refine-category-select-wrap select {
  width: 100%;
}

.refine-category-helper {
  margin: 0;
  color: #6b7280;
  font-size: 0.84rem;
  line-height: 1.45;
}

.refine-category-spinner {
  width: 14px;
  height: 14px;
  border: 2px solid rgba(124, 109, 240, 0.18);
  border-top-color: #7c6df0;
  border-radius: 999px;
  animation: refine-category-spin 0.8s linear infinite;
}

@keyframes refine-category-spin {
  to {
    transform: rotate(360deg);
  }
}

.results-sidebar-section-title {
  margin: 0 0 10px;
  font-size: 0.76rem;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.refine-sidebar-notice {
  margin: 0 0 12px;
  padding: 10px 12px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 12px;
  background: rgba(255, 248, 232, 0.92);
  color: #6d5530;
  font-size: 0.9rem;
  line-height: 1.4;
}

.refine-bullets-list,
.refine-products-list {
  display: grid;
  gap: 0;
}

#refineBulletSection {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.refine-bullets-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding-right: 4px;
}

.refine-bullet-row,
.refine-product-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-top: 1px solid #e5e7eb;
  border-radius: 0;
  background: transparent;
}

.refine-bullet-row:first-child {
  border-top: 1px solid #e5e7eb;
}

.refine-bullet-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
  justify-items: start;
}

.refine-bullet-label,
.refine-bullet-value {
  margin: 0;
}

.refine-bullet-label {
  color: #111827;
  font-size: 0.86rem;
  font-weight: 600;
  line-height: 1.35;
}

.refine-bullet-value {
  color: #111827;
  font-size: 0.86rem;
  line-height: 1.35;
}

.priority-toggle {
  display: inline-flex;
  gap: 6px;
  align-items: center;
}

.priority-button {
  min-width: 32px;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background-color: transparent;
  color: transparent;
  font-size: 0;
  line-height: 0;
  cursor: pointer;
  font-weight: 700;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 32px 32px;
}

.priority-button[data-value="high"] {
  background-image: url("/pixelseek-icons/arrow-up.svg");
}

.priority-button[data-value="high"].is-active {
  background-image: url("/pixelseek-icons/arrow-up_active.svg");
}

.priority-button[data-value="normal"] {
  background-image: url("/pixelseek-icons/check.svg");
}

.priority-button[data-value="normal"].is-active {
  background-image: url("/pixelseek-icons/check_active.svg");
}

.priority-button[data-value="low"] {
  background-image: url("/pixelseek-icons/arrow-down.svg");
}

.priority-button[data-value="low"].is-active {
  background-image: url("/pixelseek-icons/arrow-down_active.svg");
}

.priority-button[data-value="off"] {
  background-image: url("/pixelseek-icons/delete.svg");
}

.priority-button[data-value="off"].is-active {
  background-image: url("/pixelseek-icons/delete_active.svg");
}

.refine-apply-button {
  width: 100%;
  justify-content: center;
  margin-top: 14px;
  border: none !important;
  background: #7c6df0 !important;
  color: #fff !important;
}

.refine-apply-button:hover {
  background: #6355d4 !important;
}

.desktop-refine-actions {
  margin-top: 14px;
  position: sticky;
  bottom: 0;
  padding-top: 12px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), #ffffff 24px);
}

.desktop-refine-apply-button[hidden] {
  display: none !important;
}

.refine-selected-image-wrap {
  position: relative;
}

.refine-selected-image-action {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 1;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(21, 17, 38, 0.76) center / 18px 18px no-repeat url("/pixelseek-icons/re-crop-image.svg");
  box-shadow: 0 10px 24px rgba(14, 11, 21, 0.18);
  cursor: pointer;
}

.mobile-category-dropdown-backdrop,
.mobile-result-card-menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: 70;
  background: rgba(10, 10, 18, 0.08);
}

.mobile-category-dropdown {
  position: fixed;
  top: 0;
  left: 16px;
  right: 16px;
  z-index: 72;
  display: grid;
  background: #fff;
  border: 1px solid rgba(226, 221, 213, 0.95);
  border-radius: 20px;
  box-shadow: 0 18px 40px rgba(23, 18, 32, 0.12);
  overflow: hidden;
}

.similar-look-debug-probe {
  position: fixed;
  right: 12px;
  bottom: 12px;
  z-index: 120;
  max-width: min(420px, calc(100vw - 24px));
  max-height: 40vh;
  overflow: auto;
  margin: 0;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(17, 20, 33, 0.92);
  color: #f4f6fb;
  font: 12px/1.45 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  white-space: pre-wrap;
  box-shadow: 0 18px 40px rgba(15, 14, 25, 0.32);
}

.mobile-category-dropdown[data-dropdown-mode="desktop-similar-look"] {
  min-width: 320px;
  max-width: 360px;
  border-radius: 18px;
  box-shadow: 0 16px 40px rgba(24, 18, 48, 0.14);
}

.mobile-category-dropdown-label {
  padding: 14px 16px 8px;
  color: #7c7a78;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.mobile-category-dropdown-option {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 16px;
  border: 0;
  border-top: 1px solid rgba(232, 229, 223, 0.95);
  background: #fff;
  color: #171421;
  font: inherit;
  font-size: 1rem;
  text-align: left;
  cursor: pointer;
}

.mobile-category-dropdown-option.is-active {
  background: rgba(127, 119, 221, 0.12);
  color: #4d439d;
}

.mobile-category-dropdown-check {
  font-size: 1rem;
  color: #6e62d3;
}

.similar-look-origin-badge {
  margin: 2px 0 0;
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(123, 115, 221, 0.12);
  color: #5d53b6;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.2;
}

.similar-look-dropdown-label {
  padding: 0 0 8px;
  color: #7a718a;
}

.similar-look-family {
  display: grid;
  border-top: 1px solid rgba(232, 229, 223, 0.95);
}

.similar-look-family:first-of-type {
  border-top: 0;
}

.similar-look-family-button {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 11px 14px;
  border: 0;
  background: #fff;
  color: #171421;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.similar-look-family.is-expanded .similar-look-family-button {
  background: rgba(127, 119, 221, 0.08);
  color: #4d439d;
}

.similar-look-family.is-disabled .similar-look-family-button {
  color: #aaa29a;
  background: #f8f6f2;
  cursor: default;
}

.similar-look-family-chevron {
  color: rgba(93, 83, 182, 0.9);
  font-size: 0.95rem;
}

.similar-look-family.is-disabled .similar-look-family-chevron {
  color: #c1b8af;
}

.similar-look-options-wrap {
  display: grid;
  gap: 6px;
  padding: 0 14px 12px 14px;
  background: rgba(127, 119, 221, 0.04);
}

.similar-look-option-button {
  width: 100%;
  min-height: 36px;
  border: 1px solid rgba(214, 208, 233, 0.95);
  border-radius: 12px;
  background: #fff;
  color: #171421;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  text-align: left;
  padding: 8px 11px;
  cursor: pointer;
}

.similar-look-option-button.is-active {
  border-color: rgba(123, 115, 221, 0.75);
  background: rgba(127, 119, 221, 0.14);
  color: #4d439d;
}

.similar-look-loading-note {
  padding: 12px 16px 16px;
  color: #6a6378;
  font-size: 0.85rem;
  font-weight: 500;
}

@media (min-width: 901px) {
  .mobile-category-dropdown[data-dropdown-mode="desktop-similar-look"] {
    padding: 12px;
  }

  .mobile-category-dropdown[data-dropdown-mode="desktop-similar-look"] .similar-look-family {
    border-top-color: rgba(232, 229, 223, 0.72);
  }

  .mobile-category-dropdown[data-dropdown-mode="desktop-similar-look"] .similar-look-family-button {
    padding: 10px 12px;
  }

  .mobile-category-dropdown[data-dropdown-mode="desktop-similar-look"] .similar-look-options-wrap {
    padding: 0 12px 10px 12px;
  }
}

.mobile-result-card-menu {
  position: fixed;
  z-index: 74;
  width: min(280px, calc(100vw - 32px));
  padding: 12px 0 0;
  border: 1px solid rgba(227, 223, 216, 0.96);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 40px rgba(15, 14, 25, 0.18);
  overflow: hidden;
}

.mobile-result-card-menu-header {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  padding: 0 14px 12px;
  border-bottom: 1px solid rgba(232, 229, 223, 0.95);
}

.mobile-result-card-menu-thumb {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  object-fit: cover;
  background: #f4f1eb;
}

.mobile-result-card-menu-name,
.mobile-result-card-menu-brand {
  margin: 0;
}

.mobile-result-card-menu-name {
  color: #171421;
  font-size: 0.96rem;
  font-weight: 600;
}

.mobile-result-card-menu-brand {
  color: #72717a;
  font-size: 0.86rem;
}

.mobile-result-card-menu-action {
  width: 100%;
  padding: 14px 16px;
  border: 0;
  border-top: 1px solid rgba(232, 229, 223, 0.95);
  background: #fff;
  color: #171421;
  font: inherit;
  font-size: 1rem;
  text-align: left;
  cursor: pointer;
}

.mobile-result-card-menu-action-find-similar {
  color: #5d53b6;
  font-weight: 600;
}

.mobile-result-card-menu-action-more {
  color: #198f61;
}

.mobile-result-card-menu-action-less {
  color: #bf7a19;
}

.refine-product-copy {
  min-width: 0;
}

.refine-product-name,
.refine-product-meta,
.refine-empty {
  margin: 0;
}

.refine-product-name {
  color: #111827;
  font-size: 0.86rem;
  font-weight: 600;
}

.refine-product-meta,
.refine-empty {
  color: #6b7280;
  font-size: 0.8rem;
  line-height: 1.45;
}

.refine-product-remove {
  box-shadow: none;
  padding: 8px 10px;
}

.refine-drawer-backdrop {
  display: none;
}

.result-tile {
  display: grid;
  gap: 12px;
  position: relative;
  overflow: visible;
}

.card {
  overflow: hidden;
  padding: 0;
  border: 0;
  border-radius: 16px;
  background: transparent;
  box-shadow: none;
}

.card-image-wrap {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 20px rgba(64, 49, 26, 0.1);
}

.card-image-wrap.is-linked {
  cursor: pointer;
}

.card-image-wrap.is-empty {
  background:
    linear-gradient(180deg, rgba(245, 246, 248, 0.98), rgba(237, 239, 243, 0.98));
}

.card-image-wrap.is-empty::after {
  content: "Image unavailable";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #8a8f9c;
  font-size: 0.88rem;
  font-weight: 600;
}

.card-image {
  width: 95%;
  height: 95%;
  margin: 2.5%;
  border-radius: 16px;
  object-position: center;
  display: block;
}

.card-image-wrap.is-product-image .card-image,
.card-image.is-product-image {
  object-fit: contain;
}

.card-image-wrap.is-scene-image .card-image,
.card-image.is-scene-image {
  object-fit: cover;
}

.score-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(28, 24, 37, 0.92);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  box-shadow: 0 8px 18px rgba(28, 24, 37, 0.18);
}

.scene-filter-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid rgba(232, 227, 241, 0.96);
  background: rgba(255, 255, 255, 0.96);
  color: #575068;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  box-shadow: 0 8px 18px rgba(33, 26, 45, 0.08);
}

.scene-filter-badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 0 3px rgba(124, 109, 240, 0.1);
}

.scene-filter-badge.is-product {
  color: #6f6785;
}

.scene-filter-badge.is-scene {
  color: #9b6d34;
}

.search-from-image-button {
  position: absolute;
  left: 10px;
  bottom: 10px;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: 39px;
  min-width: 39px;
  height: 39px;
  padding: 0 12px;
  border: 2px solid rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  background:
    center / contain no-repeat url("/pixelseek-icons/search-ia-circle.svg"),
    rgba(124, 109, 240, 0.98);
  color: transparent;
  font-size: 0.96rem;
  line-height: 1;
  overflow: hidden;
  box-shadow: 0 10px 18px rgba(111, 84, 234, 0.22);
  cursor: pointer;
  transition:
    width 150ms ease-out,
    box-shadow 150ms ease-out,
    transform 150ms ease-out,
    background-color 150ms ease-out;
}

.search-from-image-button:hover,
.search-from-image-button:focus-visible {
  width: fit-content;
  min-width: 121px;
  box-shadow: 0 14px 24px rgba(111, 84, 234, 0.28);
  border-color: rgba(214, 208, 233, 0.95);
  background-image: none;
  background: rgba(244, 239, 255, 0.98);
  color: #5d53b6;
}

.search-from-image-button:focus-visible {
  outline: 2px solid rgba(124, 109, 240, 0.28);
  outline-offset: 2px;
}

.search-from-image-button-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  flex: 0 0 16px;
  height: 16px;
  background-color: currentColor;
  -webkit-mask: center / contain no-repeat url("/pixelseek-icons/ai-search.svg");
  mask: center / contain no-repeat url("/pixelseek-icons/ai-search.svg");
  opacity: 0;
  color: inherit;
  font-size: 0;
  transform: translateX(-4px);
  transition:
    opacity 120ms ease-out,
    transform 150ms ease-out;
}

.search-from-image-button-label {
  opacity: 0;
  max-width: 0;
  overflow: hidden;
  white-space: nowrap;
  font-size: 0.8rem;
  font-weight: 600;
  transform: translateX(-4px);
  transition:
    opacity 120ms ease-out,
    max-width 150ms ease-out,
    transform 150ms ease-out;
}

.search-from-image-button:hover .search-from-image-button-label,
.search-from-image-button:focus-visible .search-from-image-button-label {
  opacity: 1;
  max-width: 82px;
  transform: translateX(0);
}

.search-from-image-button:hover .search-from-image-button-icon,
.search-from-image-button:focus-visible .search-from-image-button-icon {
  opacity: 1;
  transform: translateX(0);
}

.search-from-image-button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.inspect-control {
  position: absolute;
  top: 13px;
  right: 12px;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-width: 30px;
  min-height: 30px;
}

.product-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.product-title-row .product-name {
  margin: 0;
}

.description-audit-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  padding: 0;
  border: 1px solid rgba(222, 215, 238, 0.95);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  color: #342a63;
  box-shadow: 0 8px 16px rgba(37, 28, 18, 0.1);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
}

.description-audit-button:hover {
  background: #fff;
}

.card-select-toggle {
  position: absolute;
  inset: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.card-select-checkbox {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.card-select-indicator {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid rgba(111, 84, 234, 0.45);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 10px 22px rgba(37, 28, 18, 0.16);
  position: relative;
}

.card-select-indicator::after {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: 999px;
  border: 2px solid #6f54ea;
  opacity: 0.45;
}

.card-select-checkbox:checked + .card-select-indicator {
  background: #151126;
  border-color: #151126;
}

.card-select-checkbox:checked + .card-select-indicator::after {
  inset: 8px 7px 9px 8px;
  border-width: 0 2px 2px 0;
  border-radius: 0;
  width: 6px;
  height: 10px;
  transform: rotate(45deg);
  opacity: 1;
  border-color: #fff;
}

.inspect-button {
  position: absolute;
  inset: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 1px solid rgba(222, 215, 238, 0.95);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  color: transparent;
  box-shadow: 0 8px 16px rgba(37, 28, 18, 0.1);
  font-size: 0;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
  background-image: url("/pixelseek-icons/ai-stars.svg");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 16px 16px;
}

@keyframes refresh-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.inspect-button[aria-pressed="true"] {
  background: #151126;
  border-color: #151126;
  background-image: url("/pixelseek-icons/ai-stars-white.svg");
}

.description-audit-button:focus-visible,
.inspect-button:focus-visible {
  outline: 2px solid rgba(111, 84, 234, 0.72);
  outline-offset: 2px;
}

.inspect-button[aria-label*="score"] {
  font-size: 0;
  letter-spacing: 0;
}

.card-body {
  display: grid;
  gap: 10px;
  padding: 0 4px 4px;
  overflow: visible;
}

.thumbnail-strip {
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-start;
  gap: 4px;
  padding: 0 4px;
  overflow: hidden;
}

.description-audit-list {
  display: grid;
  gap: 12px;
  max-height: min(62vh, 640px);
  overflow-y: auto;
  padding-right: 4px;
}

.description-audit-entry {
  display: grid;
  gap: 10px;
}

.description-audit-entry-header {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.description-audit-filename {
  margin: 0;
  color: var(--text);
  font-weight: 600;
  overflow-wrap: anywhere;
}

.description-audit-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(111, 84, 234, 0.14);
  color: #5a41d6;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.description-audit-field {
  display: grid;
  gap: 5px;
}

.description-audit-label {
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.description-audit-description,
.description-audit-empty {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.thumbnail-strip-hidden {
  display: none;
}

.thumbnail-button {
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 8px;
  overflow: hidden;
  background: #e4e4eb;
  cursor: pointer;
}

.thumbnail-button.active {
  border-color: #8341ff;
  background: #8341ff;
  box-shadow: none;
}

.thumbnail-button-overflow {
  display: grid;
  place-items: center;
  cursor: default;
  pointer-events: none;
}

.thumbnail-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.thumbnail-overflow-label {
  color: #959bb1;
  font-size: 0.62rem;
  font-weight: 700;
}

.matched-block {
  padding-bottom: 14px;
  border-bottom: 1px solid #e8e1d8;
}

.matched-label,
.brand-name,
.debug-caption-label,
.debug-content p {
  margin: 0 0 10px;
}

.chip-row-strong .chip {
  padding: 4px 10px;
  font-weight: 600;
}

.chip-row-muted .chip {
  padding: 4px 9px;
}

.chip {
  display: inline-flex;
  align-items: center;
  font-size: 0.92rem;
}

.chip.muted {
  color: var(--muted);
  background: #f0ede8;
}

.meta-block {
  display: grid;
  gap: 6px;
  padding-top: 0;
  position: relative;
  overflow: visible;
}

.product-name {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0;
}

.product-name-link {
  color: inherit;
  text-decoration: none;
}

.product-name-link:hover,
.product-name-link:focus-visible {
  color: #7c3aed;
  text-decoration: none;
}

.card-refinement-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 4px 0 0;
}

.card-refinement-actions .rules-summary-button {
  width: 100%;
  justify-content: center;
  padding: 7px 11px;
  border-radius: 999px;
  border-color: rgba(221, 216, 231, 0.95);
  background: rgba(248, 246, 251, 0.96);
  color: #675d83;
  font-size: 0.7rem;
  font-weight: 600;
  box-shadow: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.card-refinement-actions .rules-summary-button[aria-pressed="true"] {
  background: #151126;
  border-color: #151126;
  color: #fff;
}

.card-refinement-actions [data-role="moreLikeThisButton"]::before,
.card-refinement-actions [data-role="lessLikeThisButton"]::before,
#resetSearchButton::before {
  content: "";
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
}

.card-refinement-actions [data-role="moreLikeThisButton"]::before,
.card-refinement-actions [data-role="lessLikeThisButton"]::before {
  display: none;
}

#resetSearchButton {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: none;
  border-radius: 999px;
  background: #f28c1b;
  color: #fff;
  box-shadow: none;
}

#resetSearchButton:hover {
  background: #db7c13;
}

#resetSearchButton::before {
  background-image: url("/pixelseek-icons/reset_white.svg");
}

.inline-refinement-panel {
  display: grid;
  gap: 10px;
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  right: 0;
  z-index: 12;
  padding: 12px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 16px 36px rgba(37, 28, 18, 0.12);
}

.inline-refinement-title,
.inline-refinement-copy,
.inline-refinement-note {
  margin: 0;
}

.inline-refinement-title {
  font-size: 0.92rem;
  font-weight: 700;
}

.inline-refinement-copy,
.inline-refinement-note {
  color: var(--muted);
  line-height: 1.45;
}

.inline-refinement-pill-row {
  display: grid;
  gap: 8px;
}

.inline-refinement-pill {
  width: 100%;
  min-height: 64px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 18px;
  background: #e4e4eb;
  color: #959bb1;
  font: inherit;
  line-height: 1.25;
  cursor: pointer;
  display: grid;
  justify-items: center;
  align-content: center;
  text-align: center;
}

.inline-refinement-pill.is-selected {
  background: #151126;
  border-color: #151126;
  color: #ffffff;
}

.inline-refinement-pill-label,
.inline-refinement-pill-value {
  display: block;
}

.inline-refinement-pill-label {
  font-weight: 700;
}

.inline-refinement-pill-value {
  font-size: 0.94em;
}

.inline-refinement-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.inline-refinement-apply {
  width: 100%;
  min-height: 40px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(to right, #7c3aed, #6d28d9);
  color: #ffffff;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
}

.inline-refinement-apply:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.inline-refinement-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #ef4444;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.brand-name {
  margin: 0 0 6px;
  font-size: 0.85rem;
  color: #6f6a64;
}

.category-chip-row {
  margin-top: 2px;
}

.category-chip-row .chip {
  padding: 4px 10px;
  border-color: transparent;
  background: #e4e4eb;
  color: #959bb1;
  font-size: 0.82rem;
  font-weight: 600;
}

.debug-details {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #e8e1d8;
}

.debug-details summary {
  list-style: none;
  cursor: pointer;
  color: var(--muted);
}

.debug-details summary::-webkit-details-marker {
  display: none;
}

.debug-details summary::after {
  content: "⌄";
  float: right;
  transition: transform 140ms ease;
}

.debug-details[open] summary::after {
  transform: rotate(180deg);
}

.debug-content {
  padding-top: 14px;
}

.score-breakdown {
  display: grid;
  gap: 8px;
}

.score-breakdown-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(248, 245, 240, 0.8);
}

.score-breakdown-label {
  color: var(--text);
  font-size: 0.95rem;
}

.score-breakdown-value {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.score-breakdown-value.positive {
  color: #245b3d;
}

.score-breakdown-value.negative {
  color: #8a2f2f;
}

.debug-caption {
  margin: 0 0 18px;
  font-style: italic;
  line-height: 1.5;
}

.debug-description {
  margin: 0 0 18px;
  line-height: 1.55;
}

@media (max-width: 1100px) {
  .extraction-summary-grid {
    grid-template-columns: 1fr;
  }

  .category-mapping-controls {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  html,
  body {
    overflow-x: hidden;
  }

  .site-nav {
    grid-template-columns: 1fr;
    padding: 12px 16px;
  }

  .site-nav-spacer {
    display: none;
  }

  .site-nav-brand {
    order: 1;
    gap: 6px;
  }

  .site-nav-end {
    order: 2;
    gap: 8px;
    justify-content: center;
  }

  .site-nav-link,
  .debug-toggle {
    flex: 1 1 140px;
    justify-content: center;
  }

  .category-mapping-modal-card {
    width: min(100vw - 20px, 1000px);
  }

  .category-mapping-controls {
    grid-template-columns: 1fr;
  }

  .page-shell,
  .results-shell {
    padding: 18px 16px 0;
  }

  .hero {
    align-items: center;
  }

  .family-count-summary {
    width: 100%;
    padding-inline: 16px;
    box-sizing: border-box;
  }

  .family-count-bar {
    width: 100%;
    justify-content: center;
  }

  .family-count-icon {
    display: none;
  }

  .search-panel {
    padding: 16px;
  }

  .browse-trait-panel {
    padding: 16px;
    border-radius: 20px;
  }

  .browse-category-scope-field,
  .browse-category-scope-select {
    width: 100%;
  }

  .browse-trait-panel-fields {
    grid-template-columns: 1fr;
  }

  .search-secondary {
    margin-top: 14px;
  }

  html.landing-home body .search-secondary {
    margin-top: 5px;
  }

  .search-entry-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .search-entry-card {
    min-height: 0;
    padding: 24px 22px;
    border-radius: 22px;
  }

  .search-entry-card-image {
    border-style: solid;
    border-width: 1px;
    border-color: rgba(124, 109, 240, 0.3);
  }

  .search-entry-copy-desktop {
    display: none;
  }

  .search-entry-copy-mobile {
    display: inline;
  }

  .search-field {
    align-items: center;
    min-height: 74px;
    border-radius: 22px;
  }

  .search-query-flow {
    width: 100%;
  }

  .search-image-trigger {
    width: 100%;
    justify-content: center;
    margin-top: 8px;
  }

  .clarification-card {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .clarification-options {
    margin-left: 0;
  }

  .results-header {
    grid-template-columns: 1fr;
  }

  .results-header-summary,
  .refine-toggle-button,
  .results-sort,
  .batch-manage-bar {
    grid-column: auto;
  }

  .results-header-summary {
    flex-wrap: wrap;
    align-items: center;
  }

  .refine-toggle-button {
    display: inline-flex;
    justify-self: start;
  }

  .results-sort,
  .batch-manage-bar,
  .batch-manage-actions {
    justify-content: flex-start;
  }

  .batch-manage-actions {
    width: 100%;
  }

  .results-layout {
    display: block;
  }

  .results-layout.has-browse-sidebar {
    grid-template-columns: none;
  }

  .results-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 70;
    width: min(88vw, 340px);
    border-radius: 0 24px 24px 0;
    transform: translateX(-105%);
    transition: transform 180ms ease;
    overflow: auto;
  }

  .results-sidebar.is-open {
    transform: translateX(0);
  }

  .results-grid.is-browse-grid {
    grid-template-columns: repeat(auto-fill, minmax(236px, 1fr));
  }

  .refine-sidebar-close,
  .refine-drawer-backdrop {
    display: block;
  }

  .refine-drawer-backdrop {
    position: fixed;
    inset: 0;
    z-index: 65;
    background: rgba(14, 11, 21, 0.28);
    backdrop-filter: blur(3px);
  }

  .modal-upload-grid,
  .modal-results-grid {
    grid-template-columns: 1fr;
  }

  .modal-actions {
    grid-template-columns: 1fr;
  }

  .image-search-upload-row {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .image-search-choose-button {
    grid-column: 1 / -1;
    justify-self: start;
    margin-left: 48px;
  }
}

@media (max-width: 640px) {
  .page-shell,
  .results-shell {
    padding-left: 12px;
    padding-right: 12px;
  }

  html.landing-home body .page-shell {
    padding-top: 72px;
    padding-bottom: 48px;
  }

  .search-entry-card {
    min-height: 0;
    padding: 18px 16px;
    border-radius: 18px;
  }

  .search-entry-card-image {
    text-align: center;
    align-items: center;
    border: 1.5px solid rgba(127, 119, 221, 0.78);
  }

  .search-entry-copy-block {
    justify-items: center;
    text-align: center;
  }

  .search-entry-icon-image {
    background-image: url("/pixelseek-icons/camera.svg");
  }

  .search-entry-url-toggle {
    display: inline-flex;
    order: 5;
    margin-top: 10px;
    font-size: 0.88rem;
  }

  .search-entry-url-form.is-mobile-collapsed,
  .search-entry-url-form.is-mobile-collapsed + .search-entry-divider {
    display: none;
  }

  .search-entry-url-form {
    order: 4;
    margin-top: 14px;
  }

  .search-entry-divider {
    order: 3;
  }

  .search-entry-upload-button-secondary {
    order: 2;
    width: 100%;
    margin-top: 4px;
    border: 0;
    background: #7c6df0;
    color: #fff;
  }

  .search-entry-upload-button-secondary:hover {
    background: #6355d4;
    border-color: transparent;
    color: #fff;
  }

  .search-entry-card-text .search-entry-icon {
    background-image: url("/pixelseek-icons/search-ia-circle.svg");
    opacity: 0.72;
  }

  .mobile-search-expanded-panel {
    grid-column: 1 / -1;
    display: grid;
    justify-items: stretch;
    margin-left: auto;
    margin-top: 2px;
    min-width: 0;
    padding-left: 8px;
    width: min(100%, 390px);
    max-width: 100%;
  }

  .mobile-search-expanded-panel .sr-only,
  .mobile-search-expanded-input {
    display: none !important;
  }

  .mobile-search-expanded-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    padding-top: 10px;
    border-top: 0.5px solid rgba(221, 215, 206, 0.92);
    width: 100%;
    max-width: none;
  }

  .mobile-search-expanded-secondary-actions {
    display: none;
  }

  .mobile-search-secondary-button {
    display: none;
  }

  .mobile-search-cancel-button {
    width: 190px;
    min-width: 190px;
    height: 35px;
    min-height: 35px;
    box-sizing: border-box;
    padding: 0;
    border: 1px solid #d8d3cb;
    border-radius: 14px;
    background: #fff;
    color: #171421;
    font: inherit;
    font-size: 0.94rem;
    font-weight: 600;
    line-height: 35px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .mobile-search-apply-button {
    width: 190px;
    min-width: 190px;
    height: 35px;
    min-height: 35px;
    box-sizing: border-box;
    padding: 0;
    border-radius: 14px;
    background: #7f77dd;
    color: #fff;
    border: 0;
    line-height: 35px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .mobile-search-apply-button:hover {
    background: #6a62ca;
  }

  .modal-shell {
    place-items: stretch;
  }

  .modal-backdrop {
    background: transparent;
    backdrop-filter: none;
  }

  .modal-card,
  .image-search-modal-card {
    width: 100vw;
    max-width: none;
    max-height: 100vh;
    min-height: 100vh;
    margin: 0;
    border-radius: 0;
    border: 0;
    box-shadow: none;
    padding: 18px 16px 24px;
  }

  .image-search-upload-note {
    display: none;
  }

  .image-search-upload-stage {
    gap: 14px;
    align-content: start;
  }

  .image-search-upload-note {
    font-size: 0.88rem;
  }

  .image-search-upload-grid {
    gap: 12px;
  }

  .image-search-upload-block {
    padding: 18px 16px;
    border: 1.5px solid rgba(127, 119, 221, 0.38);
    border-radius: 20px;
    background: #fff;
  }

  .image-search-upload-row {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
    gap: 10px;
  }

  .image-search-upload-row-url {
    grid-template-columns: 1fr;
    justify-items: stretch;
    text-align: left;
  }

  .image-search-upload-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background-color: rgba(238, 237, 254, 0.92);
    background-size: 18px 18px;
  }

  .image-search-upload-icon-camera {
    background-image: url("/pixelseek-icons/camera.svg");
  }

  .image-search-upload-copy {
    text-align: center;
  }

  .image-search-upload-title {
    font-size: 1.05rem;
  }

  .image-search-upload-subtitle {
    margin-top: 4px;
    font-size: 0.88rem;
    color: #6b7280;
  }

  .image-search-choose-button {
    width: 100%;
    min-height: 46px;
    margin-left: 0;
    border-radius: 14px;
    border: 0;
    background: #7c6df0;
    color: #fff;
    font-size: 0.98rem;
  }

  .image-search-upload-format-hint {
    margin: 8px 0 0;
    color: #7a7788;
    font-size: 0.76rem;
    text-align: center;
  }

  .image-modal-url-toggle {
    display: flex;
    justify-content: center;
    width: 100%;
    margin: 10px auto 0;
    font-size: 0.88rem;
    text-align: center;
  }

  #imageModalUrlBlock {
    padding-top: 14px;
  }

  #imageModalUrlBlock[hidden] {
    display: none !important;
  }

  .image-search-upload-copy-url {
    justify-items: stretch;
  }

  .image-search-upload-copy-url .image-search-upload-title {
    text-align: left;
    font-size: 0.9rem;
  }

  .image-search-url-input {
    min-height: 44px;
    border-radius: 14px;
    padding: 0 14px;
    font-size: 0.94rem;
  }

  .image-search-modal-actions {
    margin-top: 4px;
  }

  .image-search-analyze-button {
    width: 100%;
    min-width: 0;
    min-height: 46px;
    border-radius: 14px;
  }

  .focus-stage-card {
    gap: 12px;
  }

  .image-modal-category-requirement {
    margin-top: 12px;
  }

  .image-modal-category-requirement .clarification-card-category {
    align-items: center;
  }

  .image-modal-category-requirement .clarification-options-category {
    justify-items: center;
  }

  .image-modal-category-requirement .clarification-families,
  .image-modal-category-requirement .clarification-subcategories {
    width: 100%;
    justify-content: center;
  }

  #imageModalResultsStage[data-analysis-active="true"] .inspiration-preview-wrap {
    display: none;
  }

  .inspiration-preview-wrap {
    padding: 0;
    border: 0;
    background: transparent;
  }

  .inspiration-preview-canvas {
    aspect-ratio: 1 / 1;
  }

  .inspiration-preview-canvas.is-touch-crop-mode {
    border-radius: 14px;
  }

  .focus-stage-actions {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .focus-analyze-loading {
    margin-top: 0;
  }

  .focus-analyze-loading .image-analyze-loading-card,
  .image-search-modal-card .image-analyze-loading-card {
    width: 100%;
    gap: 12px;
    border-radius: 16px;
    background: #eeedfe;
    box-shadow: none;
    border: 0;
  }

  .image-search-modal-card .image-analyze-progressbar,
  .focus-analyze-loading .image-analyze-progressbar {
    height: 4px;
  }

  .image-search-modal-card .image-analyze-segmented-track,
  .focus-analyze-loading .image-analyze-segmented-track {
    gap: 6px;
  }

  .image-search-modal-card .image-analyze-segment,
  .focus-analyze-loading .image-analyze-segment {
    min-height: 34px;
    font-size: 0.76rem;
    padding: 0 8px;
  }

  html:not(.landing-home) body .search-panel {
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  html:not(.landing-home) body .search-entry-grid {
    display: block;
  }

  html:not(.landing-home) body .search-secondary,
  html:not(.landing-home) body .context-row,
  html:not(.landing-home) body .context-pills {
    display: none !important;
  }

  html:not(.landing-home) body .search-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    min-height: 52px;
    margin-top: 0;
    padding: 8px;
    border-radius: 999px;
    align-items: center;
    gap: 8px;
    background: #f5f2ec;
    border-color: rgba(221, 215, 206, 0.9);
  }

  html:not(.landing-home) body .search-field.is-mobile-expanded {
    border-radius: 22px;
    border: 1.5px solid rgba(127, 119, 221, 0.92);
    align-items: center;
    padding-bottom: 8px;
  }

  html:not(.landing-home) body .search-query-flow {
    display: flex;
    align-items: center;
    min-width: 0;
    min-height: 36px;
    padding: 0 0 0 8px;
    gap: 8px;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
  }

  html:not(.landing-home) body .search-field.is-mobile-expanded .search-query-flow {
    display: flex;
    flex-wrap: wrap;
    align-items: start;
    row-gap: 8px;
    column-gap: 8px;
    white-space: normal;
    overflow: visible;
    padding-top: 2px;
    width: 100%;
  }

  html:not(.landing-home) body .search-input {
    display: block;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.92rem;
    line-height: 1.2;
    color: #474b57;
  }

  html:not(.landing-home) body .search-field.is-mobile-expanded .search-icon {
    display: none;
  }

  html:not(.landing-home) body .search-field.is-mobile-expanded .search-input {
    display: block;
    min-width: 0;
    flex: 1 1 calc(100% - 132px);
    min-height: 88px;
    max-height: 88px;
    overflow: auto;
    white-space: normal;
    text-overflow: clip;
    padding-top: 2px;
    line-height: 1.45;
  }

  html:not(.landing-home) body .search-field.is-mobile-expanded .search-icon {
    display: none !important;
  }

  html:not(.landing-home) body .search-input,
  html:not(.landing-home) body .search-category-prefix,
  html:not(.landing-home) body .search-category-suffix {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  html:not(.landing-home) body .search-field.is-mobile-expanded .search-category-prefix,
  html:not(.landing-home) body .search-field.is-mobile-expanded .search-category-suffix {
    display: inline;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
  }

  html:not(.landing-home) body #searchCategoryChipWrap {
    position: relative;
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    padding: 6px 28px 6px 12px;
    border-radius: 999px;
    background: #7f77dd;
    color: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    flex: 0 0 auto;
  }

  html:not(.landing-home) body #searchCategoryChipWrap::before {
    content: attr(data-mobile-label);
  }

  html:not(.landing-home) body #searchCategoryChipWrap::after {
    content: "⌄";
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.76rem;
  }

  html:not(.landing-home) body #searchCategoryChipWrap.is-open::after {
    content: "⌃";
  }

  html:not(.landing-home) body #searchCategorySelect {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
  }

  html:not(.landing-home) body .search-category-prefix,
  html:not(.landing-home) body .search-category-suffix {
    font-size: 0.98rem;
  }

  html:not(.landing-home) body .search-image-trigger {
    width: 36px;
    height: 36px;
    min-height: 36px;
    padding: 0;
    margin-top: 0;
    border-radius: 999px;
    flex: 0 0 36px;
    overflow: hidden;
    font-size: 0;
    border-color: rgba(171, 163, 182, 0.8);
    box-shadow: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: center;
    justify-self: center;
  }

  html:not(.landing-home) body .search-field.is-mobile-expanded .search-image-trigger {
    margin-top: -35px;
  }

  html:not(.landing-home) body .search-image-trigger .button-icon {
    width: 18px;
    height: 18px;
    margin: -2px 0 0 9px;
    display: block;
    object-fit: contain;
  }

  body.mobile-search-expanded-active .results-header,
  body.mobile-search-expanded-active .results-layout {
    opacity: 0.62;
    transition: opacity 140ms ease;
  }

  .results-header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
    padding-bottom: 10px;
  }

  .results-header-summary {
    display: inline-flex;
    grid-column: 1;
    gap: 10px;
  }

  .results-header-summary p {
    font-size: 1rem;
    font-weight: 600;
  }

  .mobile-long-press-hint {
    display: flex;
    align-items: center;
    min-height: 32px;
    margin: 0 0 7px;
    padding: 6px 10px;
    border-radius: 12px;
    background: rgba(124, 109, 240, 0.08);
    color: #7a718a;
  }

  .mobile-long-press-hint-text {
    font-size: 0.78rem;
    font-weight: 500;
    line-height: 1.25;
    letter-spacing: 0.01em;
  }

  .results-sort-category,
  .results-sort-refresh-age {
    display: none !important;
  }

  #resetSearchButton {
    display: inline-flex;
    padding: 6px 10px;
    font-size: 0.92rem;
  }

  .search-clear-button {
    margin-left: 6px;
    min-width: 30px;
    min-height: 30px;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 1px solid rgba(205, 197, 185, 0.96);
    background: rgba(227, 221, 209, 0.92);
    color: transparent;
    position: relative;
    flex: 0 0 auto;
  }

  .search-clear-button::before {
    content: "×";
    position: absolute;
    inset: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #5f584d;
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1;
  }

  .search-clear-button:hover,
  .search-clear-button:focus-visible {
    background: rgba(216, 206, 191, 0.96);
    color: transparent;
  }

  .refine-toggle-button {
    display: inline-flex;
    grid-column: 2;
    justify-self: end;
    min-height: 36px;
    padding: 0 14px;
    border-radius: 12px;
    align-items: center;
    gap: 8px;
    box-shadow: none;
  }

  .refine-toggle-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 6px;
    border-radius: 999px;
    background: #7f77dd;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1;
  }

  .results-layout {
    display: block;
  }

  .results-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .results-grid.is-browse-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .results-empty-state {
    padding: 18px 18px 16px;
    gap: 12px;
    border-radius: 20px;
  }

  .results-empty-state-title {
    font-size: 0.98rem;
  }

  .result-tile {
    padding-bottom: 0;
  }

  .search-from-image-button {
    width: 39px;
    min-width: 39px;
    padding: 0;
  }

  .search-from-image-button:hover,
  .search-from-image-button:focus-visible {
    width: 39px;
    min-width: 39px;
  }

  .search-from-image-button-label {
    display: none;
  }

  .refinement-actions,
  .thumbnail-strip,
  .category-chip-row,
  .card-refinement-actions,
  .description-audit-button,
  .inspect-control,
  .scene-filter-badge {
    display: none !important;
  }

  .meta-block {
    gap: 4px;
  }

  .product-title-row {
    align-items: start;
    gap: 0;
  }

  .product-name {
    font-size: 0.94rem;
    line-height: 1.2;
  }

  .brand-name {
    margin: 0;
    font-size: 0.8rem;
    line-height: 1.25;
  }

  .card-body {
    padding-top: 8px;
  }

  .results-sidebar {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: auto;
    border-radius: 0;
    transform: translateY(100%);
    padding: 18px 16px 104px;
    z-index: 78;
    box-shadow: none;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }

  .results-sidebar.is-open {
    transform: translateY(0);
  }

  .refine-sidebar-close,
  .refine-drawer-backdrop {
    display: block;
  }

  .refine-drawer-backdrop {
    background: rgba(11, 10, 18, 0.24);
    backdrop-filter: none;
  }

  .results-sidebar-section-title {
    font-size: 0.78rem;
    letter-spacing: 0.08em;
  }

  .refine-bullet-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    padding: 12px;
    border: 0;
    border-radius: 14px;
    background: rgba(244, 241, 235, 0.9);
    margin-bottom: 8px;
  }

  #refineBulletSection {
    display: flex;
    flex: 1 1 auto;
    min-height: 0;
    flex-direction: column;
  }

  .refine-bullets-list {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    padding-bottom: 16px;
  }

  .priority-button {
    width: 28px;
    height: 28px;
    min-width: 28px;
    background-size: 28px 28px;
  }

  .mobile-refine-footer {
    position: relative;
    flex: 0 0 auto;
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 10px;
    margin: 0 -16px -104px;
    padding: 14px 16px calc(env(safe-area-inset-bottom, 0px) + 14px);
    background: #ffffff;
    border-top: 0.5px solid rgba(216, 211, 203, 0.92);
    box-shadow: 0 -10px 24px rgba(17, 11, 24, 0.05);
  }

  .mobile-refine-reset {
    min-height: 46px;
    border: 1px solid #d8d3cb;
    border-radius: 14px;
    background: #fff;
    color: #171421;
    font: inherit;
    font-size: 0.96rem;
    font-weight: 600;
  }

  .refine-apply-button {
    min-height: 46px;
    border-radius: 14px;
    margin-top: 0;
  }
}
.compare-body {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(171, 211, 255, 0.35), transparent 30%),
    linear-gradient(180deg, #f3f0e7 0%, #f8f7f3 100%);
}

.compare-shell {
  max-width: 1400px;
  margin: 0 auto;
  padding: 48px 24px 64px;
}

.compare-header {
  max-width: 820px;
  margin-bottom: 24px;
}

.compare-subtitle {
  max-width: 680px;
  color: #4f5a67;
}

.compare-form {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 18px;
}

.compare-search-field {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  min-height: 60px;
  border: 1px solid rgba(30, 41, 59, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.08);
}

.compare-search-field input {
  flex: 1;
  border: 0;
  background: transparent;
  font: inherit;
  color: inherit;
}

.compare-search-field input:focus {
  outline: none;
}

.compare-submit {
  min-height: 60px;
}

.compare-status {
  margin-bottom: 24px;
  color: #4f5a67;
}

.compare-image-trigger {
  min-height: 60px;
  white-space: nowrap;
}

.compare-analysis-summary {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 20px;
  margin-bottom: 28px;
  padding: 18px;
  border: 1px solid rgba(30, 41, 59, 0.12);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.06);
}

.compare-analysis-media {
  min-width: 0;
}

.compare-analysis-preview {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  object-fit: cover;
  background: #e8ecf1;
}

.compare-analysis-copy {
  min-width: 0;
}

.compare-analysis-query {
  margin: 0 0 12px;
  font-size: 24px;
  line-height: 1.2;
}

.compare-analysis-bullets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.compare-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.compare-column {
  min-width: 0;
}

.compare-column-header {
  margin-bottom: 16px;
}

.compare-meta {
  color: #687384;
}

.compare-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.compare-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(30, 41, 59, 0.1);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.08);
}

.compare-rank {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.82);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}

.compare-image {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: #e8ecf1;
}

.compare-card-body {
  padding: 14px;
}

.compare-card-title {
  margin: 0 0 6px;
  font-size: 16px;
  line-height: 1.3;
}

.compare-score-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  margin: 0 0 12px;
  padding: 7px 12px;
  border: 1px solid rgba(25, 65, 95, 0.14);
  border-radius: 12px;
  background: linear-gradient(135deg, #eef6ff 0%, #f8fbff 100%);
}

.compare-score-label {
  color: #547089;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.compare-score-value {
  color: #15344f;
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.compare-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.compare-tag,
.compare-empty-tag {
  display: inline-flex;
  align-items: center;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1.2;
}

.compare-tag {
  background: #e5eef8;
  color: #23415f;
}

.compare-empty-tag {
  background: #eef1f4;
  color: #687384;
}

.compare-empty {
  padding: 24px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.7);
  color: #687384;
}

@media (max-width: 1100px) {
  .compare-columns {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .compare-shell {
    padding: 32px 16px 48px;
  }

  .compare-form {
    flex-direction: column;
    align-items: stretch;
  }

  .compare-grid {
    grid-template-columns: 1fr;
  }

  .compare-analysis-summary {
    grid-template-columns: 1fr;
  }
}

.curate-body {
  min-height: 100vh;
}

.curate-shell {
  max-width: 1380px;
  margin: 0 auto;
  padding: 28px;
}

.curate-header {
  margin-bottom: 22px;
}

.curate-subtitle {
  max-width: 760px;
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.curate-upload-panel {
  padding: 22px;
  border: 1px solid rgba(215, 208, 198, 0.9);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.75), rgba(250, 247, 242, 0.92));
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.curate-upload-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
}

.curate-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(320px, 0.9fr);
  gap: 22px;
  align-items: start;
  margin-top: 22px;
}

.curate-results-column,
.curate-sidebar {
  min-height: 0;
  padding: 18px;
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow);
}

.curate-section-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.curate-section-header h2 {
  margin: 0;
  font-size: 1.2rem;
}

.curate-results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
  max-height: 72vh;
  padding-right: 4px;
  overflow-y: auto;
}

.curate-result-card,
.curate-ideal-card {
  border: 1px solid rgba(216, 210, 201, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.94);
}

.curate-result-card {
  overflow: hidden;
}

.curate-result-rank {
  padding: 10px 12px 0;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 600;
}

.curate-result-image {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: #f4f1ec;
}

.curate-result-body {
  display: grid;
  gap: 10px;
  padding: 12px;
}

.curate-result-title,
.curate-ideal-title {
  margin: 0;
  font-size: 0.98rem;
}

.curate-result-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.curate-add-button {
  justify-content: center;
}

.curate-sidebar {
  position: sticky;
  top: 20px;
}

.curate-ideal-list {
  display: grid;
  gap: 10px;
  min-height: 220px;
  max-height: 60vh;
  overflow-y: auto;
}

.curate-ideal-card {
  display: grid;
  grid-template-columns: 40px 64px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px;
  cursor: grab;
  transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease;
}

.curate-ideal-card.is-dragging {
  opacity: 0.55;
  transform: scale(0.985);
}

.curate-ideal-card.is-drop-target {
  border-color: #151126;
  box-shadow: 0 0 0 2px rgba(21, 17, 38, 0.08);
}

.curate-ideal-rank {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: var(--chip);
  border: 1px solid var(--chip-border);
  font-weight: 600;
}

.curate-ideal-image {
  display: block;
  width: 64px;
  height: 64px;
  border-radius: 12px;
  object-fit: cover;
  background: #f4f1ec;
}

.curate-ideal-copy {
  min-width: 0;
}

.curate-remove-button {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.curate-export-button {
  width: 100%;
  justify-content: center;
  margin-top: 14px;
}

.curate-empty {
  margin: 0;
  color: var(--muted);
  text-align: center;
  padding: 32px 18px;
  border: 1px dashed var(--line);
  border-radius: 18px;
  background: rgba(250, 247, 242, 0.7);
}

@media (max-width: 1100px) {
  .curate-workspace {
    grid-template-columns: 1fr;
  }

  .curate-sidebar {
    position: static;
  }

  .curate-results-grid,
  .curate-ideal-list {
    max-height: none;
  }
}

@media (max-width: 720px) {
  .curate-shell {
    padding: 18px;
  }

  .curate-section-header {
    flex-direction: column;
  }

  .curate-ideal-card {
    grid-template-columns: 36px 56px minmax(0, 1fr);
  }

  .curate-remove-button {
    grid-column: 2 / -1;
    justify-self: start;
    padding: 0;
  }
}
