:root {
  color-scheme: light;
  --ink: #171717;
  --secondary: #52525b;
  --muted: #71717a;
  --line: #e4e4e7;
  --bg: #eef2f6;
  --white: #fff;
  --green: #24714d;
  --accent: #0b7a66;
  --accent-hover: #086451;
  --accent-ink: #075648;
  --accent-soft: #e3f4ed;
  --glass: linear-gradient(135deg, #dbe5d599, #d4dfdc80 55%, #c9d4d78c);
  --glass-paper: linear-gradient(145deg, #ffffffd9, #f2f8f4b8);
  --glass-mint: linear-gradient(145deg, #cbf0e7ed, #a8ddd0eb);
  --glass-control-shadow:
    inset 0 1.5px 1px #ffffffe0,
    inset 0 0 0 1px #ffffff40,
    inset 0 -1px 2px #40554f1a,
    0 4px 12px #244b3a12;
  --glass-shadow:
    0 12px 32px #29465b24,
    0 3px 8px #29465b0f,
    inset 0 1.5px 1px #ffffffed,
    inset 1px 0 1px #ffffff80,
    inset -1px 0 1px #ffffff59,
    inset 0 -1px 2px #45647c26;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background:
    radial-gradient(ellipse at 8% 0%, #dbebe787, transparent 48%),
    radial-gradient(ellipse at 50% 100%, #bfcee65c, transparent 50%),
    var(--bg);
  background-attachment: fixed;
  color: var(--ink);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea {
  font: inherit;
}
button, a, input, select, summary {
  touch-action: manipulation;
}
button {
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}
button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
a {
  color: inherit;
  text-decoration: none;
}
h1, h2, h3, p {
  margin: 0;
}
strong {
  font-weight: 600;
}
small {
  font-size: 13px;
}
svg {
  flex-shrink: 0;
}
.icon {
  width: 19px;
  height: 19px;
  vertical-align: middle;
}
button .icon {
  pointer-events: none;
}
button:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 3px solid #0b7a6659;
  outline-offset: 3px;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent) !important;
  box-shadow: 0 0 0 3px #0b7a6614;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid #d4d4d8;
  background: #fff;
  padding: 10px 15px;
  border-radius: 11px;
  font-weight: 500;
  font-size: 14px;
  line-height: 1.5;
  white-space: nowrap;
  transition: background 0.15s, box-shadow 0.15s, transform 0.15s;
}
.btn:hover {
  background: #f4f4f5;
}
.btn.primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: inset 0 1px 0 #ffffff30, 0 3px 8px #0b7a6618;
}
.btn.primary:hover:not(:disabled) {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  box-shadow: inset 0 1px 0 #ffffff30, 0 5px 12px #0b7a6626;
  transform: translateY(-1px);
}
.btn.small {
  padding: 8px 12px;
  font-size: 14px;
}
.btn.destructive {
  background: #b42332;
  border-color: #b42332;
  color: #fff;
}
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: #62626b;
}
.icon-btn[data-action="close-modal"], .icon-btn[data-action="close-photo"] {
  border-radius: 50%;
  flex-shrink: 0;
  padding: 0;
}
.icon-btn:hover {
  border-color: #e4e4e7;
  background: #f4f4f5;
  color: #171717;
}
.icon-btn.danger:hover {
  color: #b42332;
  background: #fff1f2;
}
.icon-btn.is-saved {
  color: var(--accent);
}
.icon-btn.is-saved svg {
  fill: var(--accent);
}
.subtle, .muted {
  color: var(--muted);
  font-size: 13px;
}
.skip {
  position: fixed;
  left: 20px;
  top: -80px;
  z-index: 99;
  background: #171717;
  color: #fff;
  padding: 12px;
}
.skip:focus {
  top: 10px;
}
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 30px;
  font-weight: 650;
  letter-spacing: -1.5px;
  line-height: 1;
}
.brand-icon {
  display: block;
  flex-shrink: 0;
  width: 38px;
  height: 38px;
}
.boot-logo {
  margin-bottom: 16px;
}
.boot {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 30px;
  font-weight: 600;
}
.boot span {
  font-size: 15px;
  font-weight: 400;
  color: var(--secondary);
  margin-top: 15px;
}
/* App frame */
.app-shell {
  min-height: 100vh;
  display: flex;
}
.avatar {
  height: 32px;
  width: 32px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-ink);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 550;
}
.app-body {
  flex: 1;
  min-width: 0;
}
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  padding: 12px 36px;
}
.demo-badge {
  padding: 4px 9px;
  border: 1px solid #e4e4e7;
  border-radius: 5px;
  font-size: 12px;
  color: #62626b;
  background: #fff;
}
.app-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
  font-size: 28px;
  font-weight: 650;
  letter-spacing: -1.2px;
  line-height: 1;
}
.header-account {
  border-radius: 50%;
  padding: 0;
  flex-shrink: 0;
}
.header-account .avatar {
  width: 30px;
  height: 30px;
}
.account-dropdown {
  position: relative;
}
.header-account[aria-expanded="true"] {
  background: var(--accent-soft);
  border-color: #0b7a6630;
}
.account-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 30;
  width: 200px;
  max-width: calc(100vw - 32px);
  padding: 6px;
  border: 1px solid #fff;
  border-radius: 16px;
  background: #fffffff0;
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  box-shadow: 0 10px 36px #143a2826, 0 2px 6px #143a280a;
}
.account-menu[hidden] {
  display: none;
}
.account-menu button {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 10px;
  text-align: left;
  font-size: 15px;
}
.account-menu button:hover, .account-menu button:focus-visible {
  background: var(--accent-soft);
  color: var(--accent-ink);
}
.dashboard {
  padding: 12px 36px calc(124px + env(safe-area-inset-bottom, 0px));
  max-width: 1680px;
  margin: 0 auto;
}
.page-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
}
.feed-heading {
  display: contents;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.page-heading h1 {
  font-size: 26px;
  line-height: 1.4;
  font-weight: 600;
  letter-spacing: -0.65px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.page-heading h1 > span {
  font-size: 16px;
  color: #71717a;
  letter-spacing: 0;
  font-weight: 400;
}
.page-heading p {
  font-size: 14px;
  color: var(--muted);
  margin-top: 5px;
}
.loading-state {
  padding: 140px 20px;
  text-align: center;
  color: #52525b;
}
/* Feed */
.segmented {
  position: relative;
  grid-area: sources;
  justify-self: center;
  display: flex;
  gap: 3px;
  max-width: 100%;
  padding: 5px;
}
.segmented button {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  min-height: 42px;
  padding: 8px 26px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: #33473e;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  transition: background 0.18s, border-color 0.18s, box-shadow 0.18s;
}
.segmented button:hover {
  background: #ffffff30;
}
.segmented .source-count {
  position: absolute;
  top: -3px;
  right: 1px;
  display: grid;
  place-items: center;
  min-width: 20px;
  height: 18px;
  padding: 0 4px;
  border: 1.5px solid #eff5f8;
  border-radius: 999px;
  background: #d52d46;
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  pointer-events: none;
}
.segmented [data-source="facebook"] .source-count {
  right: 8px;
}
.segmented button.selected {
  background: linear-gradient(150deg, #ffffff9c, #ffffff40);
  border-color: #ffffffa6;
  color: #152b22;
  box-shadow: inset 0 1px 1px #ffffffd9, 0 2px 5px #314c5e0f;
}
.toolbar-right {
  grid-area: controls;
  justify-self: end;
  display: flex;
  gap: 9px;
  align-items: center;
}
.toolbar-right select {
  min-width: 0;
  border: 1px solid var(--line);
  background: #fff;
  color: #52525b;
  padding: 9px 24px 9px 10px;
  border-radius: 8px;
  font-size: 13px;
  max-width: 155px;
}
.listing-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  align-items: stretch;
}
.listing-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px;
  background: #fff;
  box-shadow: 0 2px 4px #00000003;
  min-width: 0;
}
.card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}
.card-heading > div {
  min-width: 0;
}
.source {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #3f3f46;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
}
.source > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 5px;
  font-size: 14px;
  font-weight: 700;
}
.source.chotot > span {
  background: #ffdf7f;
  color: #795500;
}
.source.facebook > span {
  background: #e8efff;
  color: #2259b3;
  font-size: 18px;
  padding-top: 2px;
  font-family: Arial, sans-serif;
}
.card-location {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.card-image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  max-height: 280px;
  border: 1px solid #eeeeef;
  border-radius: 9px;
  padding: 0;
  background: #f5f5f6;
  overflow: hidden;
}
.product-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f1f3;
  color: #77777f;
  height: 50px;
  width: 50px;
  border-radius: 9px;
  overflow: hidden;
  flex-shrink: 0;
}
.product-thumb .icon {
  width: 26px;
  height: 26px;
  stroke-width: 1.2;
}
.product-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.card-image .product-thumb {
  width: 100%;
  height: 100%;
  border-radius: 0;
}
.card-image .product-thumb .icon {
  width: 76px;
  height: 76px;
  stroke-width: 1;
  color: #797983;
}
.card-image .camera {
  background: #eeedeb;
}
.card-image .chair {
  background: #edf0eb;
}
.card-image .monitor {
  background: #eaeef3;
}
.card-image:hover .product-thumb {
  filter: brightness(0.98);
}
.card-content {
  padding: 17px 0 20px;
}
.listing-title {
  display: block;
  text-align: left;
  padding: 0;
  font-size: 17px;
  font-weight: 500;
  line-height: 1.5;
  color: #171717;
  letter-spacing: -0.25px;
  overflow-wrap: anywhere;
}
.listing-title:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.card-price {
  display: block;
  font-size: 23px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.5px;
  margin: 10px 0;
  font-variant-numeric: tabular-nums;
}
.card-watch {
  display: inline-block;
  color: #62626b;
  background: #f4f4f5;
  border-radius: 5px;
  padding: 3px 7px;
  font-size: 12px;
}
.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 4px;
  margin-top: auto;
}
.card-footer time {
  font-size: 13px;
  color: var(--muted);
}
.card-footer .icon {
  width: 15px;
  height: 15px;
}
.results-limit {
  font-size: 13px;
  color: #71717a;
  margin-top: 25px;
}
.empty-state {
  text-align: center;
  padding: 90px 25px;
  border: 1px dashed #d4d4d8;
  border-radius: 12px;
  color: #71717a;
}
.empty-state > .icon {
  width: 34px;
  height: 34px;
  stroke-width: 1.3;
  margin-bottom: 17px;
}
.empty-state h3 {
  color: #52525b;
  font-size: 17px;
  font-weight: 500;
}
.empty-state p {
  font-size: 14px;
  margin: 10px auto 0;
  max-width: 400px;
}
.empty-state .btn {
  margin-top: 20px;
}
/* Watches */
.watch-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.watch-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 22px;
}
.watch-card-top {
  display: flex;
  align-items: center;
  gap: 12px;
}
.watch-card-top > .icon-btn {
  margin-left: auto;
}
.status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 20px;
  font-size: 12px;
  color: #2d6949;
  background: #eff7f1;
  padding: 4px 8px;
  white-space: nowrap;
}
.status-pill.paused {
  color: #62626b;
  background: #f1f1f3;
}
.watch-card .status-pill:not(.paused) {
  color: #fff;
  background: #21834a;
}
.watch-card h2 {
  font-size: 19px;
  font-weight: 550;
  line-height: 1.5;
  margin: 20px 0 6px;
  letter-spacing: -0.4px;
}
.watch-query {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #62626b;
}
.watch-query .icon {
  width: 14px;
  height: 14px;
}
.budget {
  padding: 15px 0;
  margin: 12px 0 10px;
}
.budget small {
  font-size: 12px;
  color: #71717a;
  display: block;
}
.budget strong {
  display: block;
  font-size: 21px;
  font-weight: 550;
  letter-spacing: -0.5px;
  margin-top: 5px;
}
.watch-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 12px;
  color: #62626b;
  margin: 0 0 22px;
}
.watch-meta span {
  display: flex;
  align-items: center;
  gap: 5px;
}
.watch-meta .icon {
  width: 14px;
  height: 14px;
}
.source-statuses {
  border-top: 1px solid #eeeeef;
  border-bottom: 1px solid #eeeeef;
  padding: 12px 0;
}
.source-statuses > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 5px 0;
}
.scan-state {
  font-size: 12px;
  color: #62626b;
}
.scan-state.has-error {
  color: #956019;
}
.scan-error {
  color: #8f5d1b;
  font-size: 13px;
  line-height: 1.7;
  padding: 5px 0 9px;
}
.watch-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  font-size: 12px;
  color: #62626b;
}
.watch-card-footer > div {
  display: flex;
  gap: 3px;
}
.watch-card-footer .icon {
  width: 16px;
  height: 16px;
}
/* Settings and activity */
.settings-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}
.settings-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 26px;
}
.settings-card.wide {
  grid-column: 1 / -1;
}
.settings-card h2 {
  display: flex;
  gap: 9px;
  align-items: center;
  font-size: 17px;
  font-weight: 550;
  margin-bottom: 22px;
}
.settings-card h3 {
  font-size: 15px;
  font-weight: 550;
  margin-bottom: 8px;
}
.settings-card > p {
  font-size: 14px;
  color: #62626b;
  line-height: 1.7;
  margin-bottom: 20px;
}
.profile {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 25px;
}
.profile .avatar {
  height: 44px;
  width: 44px;
  font-size: 17px;
}
.profile strong {
  font-size: 15px;
}
.profile p {
  font-size: 13px;
  color: #71717a;
  margin-top: 4px;
}
.settings-card .field-hint {
  margin-bottom: 20px;
}
.settings-divider {
  height: 1px;
  background: var(--line);
  margin: 26px 0;
}
.connection-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  padding: 18px 0;
}
.connection-row + .connection-row {
  border-top: 1px solid var(--line);
}
.connection-row .source {
  font-size: 15px;
}
.connection-row p {
  font-size: 13px;
  line-height: 1.75;
  color: #62626b;
  max-width: 680px;
  margin-top: 10px;
}
.connection-row > .subtle {
  white-space: nowrap;
}
.notice {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: #52525b;
  background: #f5f5f6;
  border: 1px solid #e4e4e7;
  padding: 14px;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.7;
}
.notice .icon {
  width: 17px;
  height: 17px;
  margin-top: 3px;
}
.notice button {
  text-decoration: underline;
  padding: 0;
}
.settings-card .notice {
  margin-top: 20px;
}
.notification-list {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
}
.notification-list > .empty-state {
  border: 0;
}
.notification-item {
  display: flex;
  align-items: center;
  gap: 17px;
  padding: 24px;
}
.notification-item + .notification-item {
  border-top: 1px solid var(--line);
}
.notification-item.unread {
  background: #fafafa;
}
.notification-item > .product-thumb {
  height: 64px;
  width: 64px;
  border-radius: 10px;
}
.notification-content {
  min-width: 0;
}
.notification-overline {
  display: none;
}
.notification-item h3 {
  font-size: 16px;
  font-weight: 500;
  margin-bottom: 5px;
}
.notification-item p {
  font-size: 15px;
}
.notification-item p span {
  color: #71717a;
  font-size: 13px;
}
.notification-item small {
  color: #71717a;
  display: block;
  margin-top: 5px;
  font-size: 13px;
}
.notification-item > a, .notification-item > .sample-label {
  margin-left: auto;
}
.sample-label {
  display: inline-block;
  font-size: 12px;
  color: #71717a;
  background: #f4f4f5;
  border-radius: 5px;
  padding: 3px 7px;
  white-space: nowrap;
}
/* Forms */
.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 20px;
  font-size: 14px;
  color: #3f3f46;
  font-weight: 500;
}
.field input, .field textarea, .field select {
  padding: 11px 12px;
  border: 1px solid #d4d4d8;
  border-radius: 7px;
  color: #171717;
  background: #fff;
  width: 100%;
  font-size: 15px;
  font-weight: 400;
  min-height: 44px;
}
.field input::placeholder, .field textarea::placeholder {
  color: #8b8b94;
}
.field textarea {
  resize: vertical;
}
.field-hint {
  font-size: 13px;
  color: #62626b;
  line-height: 1.7;
  margin-top: 8px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.source-options {
  display: flex;
  gap: 12px;
}
.source-options label {
  display: flex;
  align-items: center;
  flex: 1;
  gap: 10px;
  border: 1px solid #d4d4d8;
  padding: 12px;
  border-radius: 7px;
  cursor: pointer;
}
.source-options label:has(input:checked) {
  border-color: var(--accent);
  background: #f1faf6;
}
.source-options input {
  width: 16px;
  height: 16px;
  min-height: 0;
  accent-color: var(--accent);
}
details {
  margin-top: 24px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}
summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  color: #52525b;
  font-size: 14px;
  list-style: none;
}
summary .icon {
  width: 16px;
  height: 16px;
}
details[open] summary .icon {
  transform: rotate(180deg);
}
.form-error {
  margin-top: 15px;
  color: #b42332;
  font-size: 14px;
}
.form-error:empty {
  display: none;
}
dialog {
  --dialog-limit: min(90dvh, 900px);
  border: 1px solid #dedee2;
  border-radius: 14px;
  padding: 0;
  width: min(560px, calc(100vw - 30px));
  max-height: var(--dialog-limit);
  overflow: hidden;
  color: var(--ink);
  box-shadow: 0 20px 90px #00000026;
}
dialog[open] {
  display: flex;
}
body:has(dialog[open]) {
  overflow: hidden;
}
.modal-layout {
  display: flex;
  flex-direction: column;
  min-height: 0;
  max-height: calc(var(--dialog-limit) - 2px);
  width: 100%;
}
.modal-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0 28px 24px;
  scrollbar-gutter: stable;
}
dialog::backdrop {
  background: #00000045;
}
.modal-heading {
  flex: 0 0 auto;
  padding: 20px 28px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin-bottom: 0;
}
.modal-heading h2 {
  font-size: 23px;
  letter-spacing: -0.5px;
  font-weight: 550;
}
.modal-intro {
  color: #52525b;
  font-size: 15px;
  margin: 12px 0 24px;
}
.modal-footer {
  flex: 0 0 auto;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--line);
  margin-top: 0;
  padding: 18px 28px;
}
.detail-dialog {
  --dialog-limit: min(92dvh, 1000px);
  width: min(1200px, calc(100vw - 48px));
}
.detail-dialog .modal-body {
  padding-top: 28px;
}
.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.3fr);
  gap: 32px;
  align-items: start;
}
.detail-gallery {
  min-width: 0;
  position: sticky;
  top: 0;
  border-radius: 12px;
}
.gallery-stage {
  aspect-ratio: 1;
  position: relative;
  border-radius: 12px;
  background: #222;
  overflow: hidden;
}
.detail-photo.product-thumb {
  width: 100%;
  height: 100%;
  background: #222;
  color: #bcbcc2;
  border-radius: 0;
}
.detail-photo img {
  object-fit: contain;
}
.detail-photo .icon {
  width: 72px;
  height: 72px;
}
.gallery-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #171717b3;
  color: #fff;
}
.gallery-arrow:hover {
  background: #171717;
}
.gallery-arrow.previous {
  left: 12px;
}
.gallery-arrow.next {
  right: 12px;
}
.gallery-arrow.previous .icon {
  transform: rotate(90deg);
}
.gallery-arrow.next .icon {
  transform: rotate(-90deg);
}
.gallery-expand {
  position: absolute;
  top: 12px;
  right: 12px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  color: #171717;
  box-shadow: 0 2px 8px #0002;
}
.gallery-expand:hover {
  background: #f1f1f3;
}
.photo-viewer {
  --dialog-limit: 100dvh;
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  border: 0;
  border-radius: 0;
  padding: max(16px, env(safe-area-inset-top))
    max(16px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom))
    max(16px, env(safe-area-inset-left));
  background: #111;
  color: #fff;
}
.photo-viewer[open] {
  flex-direction: column;
  gap: 16px;
}
.photo-viewer-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  gap: 16px;
}
.photo-viewer-heading h2 {
  font-size: 17px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.photo-viewer-heading .icon-btn {
  color: #fff;
  background: #ffffff1a;
  flex-shrink: 0;
}
.photo-viewer-heading .icon-btn:hover {
  background: #ffffff30;
}
.photo-viewer .detail-gallery {
  position: static;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.photo-viewer .detail-gallery:focus-visible {
  outline: none;
}
.photo-viewer .gallery-stage {
  flex: 1;
  min-height: 0;
  aspect-ratio: auto;
  background: #111;
}
.photo-viewer .detail-photo {
  position: absolute;
  inset: 0;
  background: #111;
}
.photo-viewer .gallery-thumbnails {
  flex-shrink: 0;
  width: fit-content;
  max-width: 100%;
  margin: 12px auto 0;
}
.photo-viewer .gallery-thumb.product-thumb {
  background: #111;
}
.photo-viewer .gallery-thumb[aria-pressed="true"] {
  border-color: #fff;
}
.photo-viewer .gallery-expand {
  display: none;
}
.gallery-count {
  position: absolute;
  right: 12px;
  bottom: 12px;
  border-radius: 6px;
  padding: 3px 9px;
  background: #171717b3;
  color: #fff;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.gallery-thumbnails {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 4px 2px 8px;
  margin-top: 10px;
  scrollbar-width: thin;
}
.gallery-thumb.product-thumb {
  height: 68px;
  width: 68px;
  border: 2px solid transparent;
  padding: 3px;
  background: #fff;
  border-radius: 9px;
}
.gallery-thumb img {
  border-radius: 5px;
}
.gallery-thumb[aria-pressed="true"] {
  border-color: #171717;
}
.detail-info {
  min-width: 0;
}
.detail-title-row {
  display: flex;
  align-items: start;
  gap: 18px;
  justify-content: space-between;
}
.detail-title-row h3 {
  font-size: 27px;
  font-weight: 650;
  letter-spacing: -0.6px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.detail-save {
  flex-shrink: 0;
  border-radius: 30px;
  padding: 9px 14px;
}
.detail-save .icon {
  height: 22px;
  width: 22px;
}
.detail-save.is-saved {
  color: #d71940;
  border-color: #edbcc7;
}
.detail-save.is-saved .icon {
  fill: currentColor;
}
.detail-summary {
  color: #52525b;
  font-size: 17px;
  margin-top: 16px;
}
.detail-asking-price {
  display: block;
  color: #e91845;
  font-size: 30px;
  letter-spacing: -0.6px;
  line-height: 1.3;
  margin-top: 12px;
}
.detail-meta {
  display: grid;
  gap: 16px;
  margin-top: 24px;
  font-size: 16px;
}
.detail-meta > div {
  display: flex;
  align-items: start;
  gap: 10px;
}
.detail-meta .icon {
  margin-top: 3px;
  width: 21px;
  height: 21px;
}
.detail-meta small {
  display: block;
  margin-top: 3px;
  color: #71717a;
  font-size: 14px;
}
.detail-budget {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 20px;
  margin-top: 24px;
  background: #f5f5f6;
  border-radius: 10px;
}
.detail-info h4 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
}
.detail-budget p {
  font-size: 16px;
  margin-top: 5px;
  color: #52525b;
}
.budget-status {
  font-size: 14px;
  font-weight: 500;
}
.budget-status.within {
  color: #21834a;
}
.budget-status.outside {
  color: #b42332;
}
.detail-seller {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}
.seller-avatar {
  height: 48px;
  width: 48px;
  object-fit: cover;
  border-radius: 50%;
}
.seller-name {
  flex: 1;
  min-width: 140px;
}
.seller-name a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 14px;
  color: #52525b;
  margin-top: 5px;
}
.seller-name a:hover {
  text-decoration: underline;
}
.seller-name .icon {
  width: 14px;
  height: 14px;
}
.seller-stats {
  display: flex;
  text-align: center;
  gap: 20px;
}
.seller-stats strong {
  display: block;
  font-size: 20px;
}
.seller-stats span {
  color: #62626b;
  font-size: 13px;
}
.seller-stats .icon {
  color: #f5b500;
  fill: currentColor;
  height: 18px;
  width: 18px;
}
.detail-section {
  margin-top: 24px;
}
.detail-description {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 15px;
  color: #52525b;
  line-height: 1.8;
  margin-top: 10px;
}
.detail-attributes {
  margin: 10px 0 0;
  font-size: 15px;
}
.detail-attributes > div {
  display: grid;
  grid-template-columns: minmax(100px, 0.9fr) minmax(0, 1.3fr);
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #f1f1f3;
}
.detail-attributes dt {
  color: #62626b;
}
.detail-attributes dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.detail-loading {
  color: #62626b;
  margin-top: 20px;
  font-size: 14px;
}
.btn.detail-contact {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 600;
}
.btn.detail-contact:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}
@media (max-width: 800px) {
  .detail-dialog {
    width: min(640px, calc(100vw - 24px));
  }
  .detail-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }
  .detail-gallery {
    position: static;
  }
  .gallery-stage {
    aspect-ratio: 4 / 3;
  }
  .detail-title-row h3 {
    font-size: 23px;
  }
}
#toast {
  --toast-ink: #075648;
  --toast-tint: #caede3de;
  position: fixed;
  inset: auto;
  margin: 0;
  left: 50%;
  bottom: 25px;
  width: max-content;
  max-width: min(560px, calc(100vw - 24px));
  max-height: min(40svh, 280px);
  overflow: auto;
  transform: translate(-50%, 20px);
  border: 1.5px solid #ffffffe8;
  background: linear-gradient(135deg, #fffffff0, var(--toast-tint));
  color: var(--toast-ink);
  border-radius: 28px;
  padding: 12px;
  font-size: 15px;
  line-height: 1.5;
  text-align: left;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
  backdrop-filter: blur(24px) saturate(155%);
  -webkit-backdrop-filter: blur(24px) saturate(155%);
  box-shadow: var(--glass-shadow);
}
#toast.visible {
  display: flex;
  align-items: center;
  gap: 11px;
  opacity: 1;
  transform: translate(-50%, 0);
  pointer-events: auto;
}
#toast[data-tone="error"] {
  --toast-ink: #833c43;
  --toast-tint: #f3ddddde;
}
#toast[data-tone="info"] {
  --toast-ink: #315c58;
}
.toast-symbol, .toast-close {
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #ffffff80;
  box-shadow: inset 0 1px 1px #fff;
}
.toast-message {
  min-width: 0;
  overflow-wrap: anywhere;
}
.toast-close {
  color: inherit;
  padding: 7px;
}
.toast-close:hover {
  background: #ffffffd9;
}
.toast-symbol .icon, .toast-close .icon {
  width: 18px;
  height: 18px;
}
@media (prefers-reduced-motion: reduce) {
  #toast {
    transition: none;
  }
}
/* Sign in */
.landing {
  background: #fff;
  min-height: 100vh;
}
.landing-nav {
  max-width: 1200px;
  margin: auto;
  padding: 32px;
}
.landing-hero {
  max-width: 750px;
  padding: 130px 25px;
  margin: auto;
  text-align: center;
}
.landing-hero h1 {
  font-size: 48px;
  line-height: 1.2;
  font-weight: 550;
  letter-spacing: -1.8px;
}
.landing-hero > p {
  font-size: 18px;
  color: #62626b;
  margin-top: 24px;
}
.hero-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 35px;
}
.landing-hero p.setup-note {
  font-size: 13px;
  color: #71717a;
  margin-top: 22px;
}
@media (max-width: 1250px) {
  .dashboard {
    padding-left: 26px;
    padding-right: 26px;
  }
  .topbar {
    padding-left: 26px;
    padding-right: 26px;
  }
  .listing-grid, .watch-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .toolbar-right {
    flex-wrap: wrap;
  }
}
@media (max-width: 800px) {
  .topbar {
    justify-content: flex-start;
    border-bottom: 1px solid #ffffffb8;
    background: linear-gradient(135deg, #ffffffe6, #e9f8f0c2);
    -webkit-backdrop-filter: blur(24px) saturate(160%);
    backdrop-filter: blur(24px) saturate(160%);
    box-shadow: 0 2px 12px #164f3d08, inset 0 -1px 0 #fff6;
    padding: 12px 20px;
  }
  .app-brand {
    display: inline-flex;
  }
  .app-brand {
    align-items: center;
    gap: 8px;
    font-size: 23px;
    letter-spacing: -1px;
    font-weight: 600;
    margin-right: auto;
  }
  .app-brand .brand-icon {
    width: 32px;
    height: 32px;
  }
  .dashboard {
    padding: 27px 20px 45px;
  }
  .page-heading h1 {
    font-size: 24px;
  }
  .toolbar-right {
    width: 100%;
    flex-wrap: nowrap;
  }
  .toolbar-right select {
    max-width: 150px;
  }
  .listing-grid, .watch-grid {
    gap: 16px;
  }
  .listing-card {
    padding: 16px;
  }
  .listing-title {
    font-size: 16px;
  }
  .card-price {
    font-size: 22px;
  }
  .settings-grid {
    grid-template-columns: 1fr;
  }
  .settings-card.wide {
    grid-column: auto;
  }
  .connection-row {
    flex-wrap: wrap;
    gap: 15px;
  }
  .connection-row > .subtle {
    white-space: normal;
  }
}
@media (max-width: 540px) {
  .dashboard {
    padding: 24px 16px 40px;
  }
  .topbar {
    padding: 10px 16px;
    gap: 9px;
    min-height: 60px;
  }
  .demo-badge {
    font-size: 12px;
    padding: 3px 6px;
  }
  .page-heading {
    margin-bottom: 24px;
    gap: 10px;
  }
  .page-heading h1 {
    font-size: 24px;
    gap: 9px;
  }
  .page-heading .btn {
    padding: 9px 12px;
    font-size: 13px;
  }
  .page-heading .btn .icon {
    width: 16px;
    height: 16px;
  }
  .page-heading h1 > span {
    font-size: 15px;
  }
  .segmented {
    gap: 2px;
    padding: 4px;
  }
  .segmented button {
    padding: 7px 22px;
    font-size: 13px;
  }
  .toolbar-right {
    flex-wrap: wrap;
    gap: 8px;
  }
  .toolbar-right select {
    flex: 1;
    max-width: none;
    font-size: 13px;
  }
  .listing-grid, .watch-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .card-image {
    max-height: none;
    aspect-ratio: 16 / 10;
  }
  .listing-card {
    padding: 18px;
  }
  .listing-title {
    font-size: 18px;
  }
  .card-price {
    font-size: 24px;
  }
  .card-location {
    font-size: 13px;
  }
  .card-content {
    padding: 18px 0 22px;
  }
  .watch-card {
    padding: 22px;
  }
  .notification-item {
    padding: 20px 16px;
    gap: 12px;
    flex-wrap: wrap;
  }
  .notification-item > .notification-content {
    flex: 1;
    min-width: 180px;
  }
  .notification-item > a {
    margin-left: 76px;
  }
  .notification-item > .sample-label {
    margin-left: 76px;
  }
  .notification-item h3 {
    font-size: 15px;
  }
  .settings-card {
    padding: 22px;
  }
  .profile p {
    overflow-wrap: anywhere;
  }
  .form-row {
    gap: 12px;
  }
  .field {
    font-size: 14px;
  }
  .field input, .field textarea, .field select {
    font-size: 15px;
    padding: 10px;
  }
  dialog {
    --dialog-limit: 92dvh;
    padding: 0;
    max-height: var(--dialog-limit);
  }
  .modal-heading {
    padding: 18px 20px;
  }
  .modal-body {
    padding: 0 20px 20px;
  }
  .modal-footer {
    padding: 16px 20px;
  }
  .modal-heading h2 {
    font-size: 22px;
  }
  .modal-footer .btn {
    font-size: 13px;
    padding: 10px 12px;
  }
  .detail-dialog .modal-body {
    padding: 20px;
  }
  .detail-title-row {
    gap: 12px;
  }
  .detail-title-row h3 {
    font-size: 21px;
  }
  .detail-save {
    padding: 8px 10px;
    font-size: 14px;
  }
  .detail-asking-price {
    font-size: 27px;
  }
  .gallery-thumb.product-thumb {
    height: 58px;
    width: 58px;
  }
  .detail-seller {
    gap: 12px;
  }
  .seller-stats {
    margin-left: 60px;
  }
  .detail-dialog .modal-footer {
    gap: 10px;
  }
  .detail-dialog .modal-footer .source {
    font-size: 12px;
  }
  .landing-nav {
    padding: 26px;
  }
  .landing-hero {
    padding: 100px 26px;
  }
  .landing-hero h1 {
    font-size: 38px;
    letter-spacing: -1.3px;
  }
  .landing-hero > p {
    font-size: 16px;
  }
  .hero-buttons {
    flex-direction: column;
  }
  .hero-buttons .btn {
    width: 100%;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *, *::before, *::after {
    transition: none !important;
    animation: none !important;
  }
}

select {
  appearance: none;
  -webkit-appearance: none;
  min-height: 40px;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='m5 6 3 3 3-3' fill='none' stroke='%2333473e' stroke-width='1.5'/%3E%3C/svg%3E"),
    var(--glass) !important;
  background-repeat: no-repeat, no-repeat !important;
  background-size: 16px, 100% 100% !important;
  background-position: right 10px center, center !important;
  padding-right: 34px !important;
}
select option {
  color: var(--ink);
  background: #f3f7f5;
}

.source > img {
  display: block;
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
}

.boot .btn {
  margin-top: 22px;
}
.boot > span {
  max-width: 560px;
  text-align: center;
  padding: 0 20px;
}

/* Searchable multi-select; only the option list scrolls inside its dropdown. */
.location-field {
  min-width: 0;
}
.location-picker {
  border: 0;
  padding: 0;
  margin: 0;
}
.location-picker > summary {
  min-height: 46px;
  border: 1px solid #d4d4d8;
  border-radius: 7px;
  padding: 10px 12px;
  gap: 10px;
  font-size: 15px;
  color: var(--ink);
  background: #fff;
}
.location-picker[open] > summary {
  border-color: #71717a;
}
.location-picker > summary > span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.location-menu {
  margin-top: 6px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 5px 16px #00000008;
}
.location-search {
  display: flex;
  gap: 7px;
  align-items: center;
  padding: 4px 7px;
  border-bottom: 1px solid var(--line);
}
.location-search .icon {
  height: 16px;
  width: 16px;
  color: var(--muted);
}
.location-search input {
  min-width: 0;
  width: 100%;
  min-height: 36px;
  padding: 7px 0;
  border: 0;
  box-shadow: none;
  font-size: 14px;
}
.location-clear {
  display: block;
  text-align: left;
  padding: 9px 10px;
  width: 100%;
  font-size: 14px;
  border-radius: 5px;
  color: #52525b;
}
.location-clear:hover {
  background: #f4f4f5;
}
.location-options {
  max-height: 210px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.location-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  font-size: 14px;
  font-weight: 400;
  cursor: pointer;
  border-radius: 5px;
}
.location-option:hover {
  background: #f4f4f5;
}
.location-option[hidden] {
  display: none;
}
.location-option input {
  height: 16px;
  width: 16px;
  min-height: 0;
  flex-shrink: 0;
  margin: 0;
  accent-color: var(--accent);
}
.location-empty {
  padding: 12px 10px;
  font-size: 13px;
  color: var(--muted);
}
.location-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.location-chips:empty {
  display: none;
}
.location-chips button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f4f4f5;
  padding: 4px 7px;
  font-size: 12px;
}
.location-chips .icon {
  height: 12px;
  width: 12px;
}
/* Shared glass materials for controls, floating menus and content surfaces. */
.btn,
.icon-btn,
.toolbar-right select,
.field input,
.field textarea,
.field select,
.location-picker > summary,
.location-chips button,
.gallery-expand {
  border-color: #ffffffb8;
  background: var(--glass);
  -webkit-backdrop-filter: blur(20px) saturate(155%);
  backdrop-filter: blur(20px) saturate(155%);
  box-shadow: var(--glass-control-shadow);
}
.btn, .toolbar-right select, .location-picker > summary {
  border-radius: 999px;
  color: #263e31;
}
.field input, .field select {
  border-radius: 14px;
}
.field textarea {
  border-radius: 16px;
}
.btn:hover, .icon-btn:hover, .gallery-expand:hover {
  background: linear-gradient(135deg, #eef8eac9, #e6f1ece0);
  border-color: #fffffff0;
}
.btn.primary, .header-account[aria-expanded="true"] {
  background: var(--glass-mint);
  color: var(--accent-ink);
  border-color: #73bba580;
  box-shadow:
    var(--glass-control-shadow),
    0 4px 14px #07564812;
}
.btn.primary:hover:not(:disabled) {
  background: linear-gradient(145deg, #bcebdce8, #99d5c3ed);
  color: var(--accent-ink);
  border-color: #62b39b99;
  box-shadow:
    var(--glass-control-shadow),
    0 5px 16px #07564820;
}
.btn.destructive {
  background: linear-gradient(145deg, #ffe9edeb, #f5c8d0df);
  border-color: #d57a8a66;
  color: #9e2139;
}
.header-account, .header-account:hover, .header-account[aria-expanded="true"] {
  border-radius: 50%;
}
.header-account .avatar {
  background: transparent;
}
.listing-card,
.watch-card,
.settings-card,
.notification-list,
.account-menu,
.location-menu,
dialog:not(.photo-viewer) {
  border-color: #ffffffcc;
  background: var(--glass-paper);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  backdrop-filter: blur(20px) saturate(140%);
  box-shadow: inset 0 1px 1px #ffffffed, 0 6px 24px #274e3e0c;
}
.account-menu, .location-menu {
  background: linear-gradient(145deg, #f9fff5dc, #e3eeead6);
  box-shadow:
    var(--glass-control-shadow),
    0 10px 30px #244b3a1f;
  -webkit-backdrop-filter: blur(28px) saturate(155%);
  backdrop-filter: blur(28px) saturate(155%);
}
.topbar, .modal-heading, .modal-footer {
  background: linear-gradient(135deg, #ffffff9c, #e1eee5a6);
  -webkit-backdrop-filter: blur(24px) saturate(155%);
  backdrop-filter: blur(24px) saturate(155%);
  border-color: #ffffffb8;
  box-shadow: inset 0 1px 1px #ffffffb3, 0 2px 12px #164f3d08;
}
.topbar {
  border-bottom: 1px solid #ffffffb8;
}
.notification-item.unread {
  background: #d8eee54d;
}
.location-search input {
  background: transparent;
}
dialog:not(.photo-viewer) {
  box-shadow: inset 0 1px 1px #ffffffed, 0 20px 80px #153a2a30;
}

html {
  scroll-padding-bottom: calc(124px + env(safe-area-inset-bottom, 0px));
}
.dashboard {
  padding-bottom: calc(124px + env(safe-area-inset-bottom, 0px));
}
.bottom-dock {
  --dock-size: 66px;
  position: fixed;
  bottom: calc(
    20px + env(safe-area-inset-bottom, 0px) + var(--dock-keyboard-offset, 0px)
  );
  left: 0;
  right: 0;
  z-index: 15;
  width: min(560px, calc(100% - 32px));
  height: var(--dock-size);
  margin: 0 auto;
}
.bottom-tabbar, .dock-search, .segmented {
  isolation: isolate;
  overflow: hidden;
  border: 1px solid #ffffffb8;
  border-radius: 999px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(24px) saturate(155%);
  backdrop-filter: blur(24px) saturate(155%);
  box-shadow:
    0 10px 32px #1f333b26,
    inset 0 1.5px 1px #ffffffe0,
    inset 0 -1px 2px #40554f30;
}
.bottom-tabbar {
  position: relative;
  display: flex;
  align-items: stretch;
  width: calc(100% - var(--dock-size) - 12px);
  height: 100%;
  padding: 7px;
  transition: opacity 0.2s, transform 0.35s;
}
.bottom-tabbar::before,
.bottom-tabbar::after,
.dock-search::before,
.dock-search::after,
.segmented::before,
.segmented::after {
  content: "";
  position: absolute;
  z-index: -1;
  pointer-events: none;
  border-radius: inherit;
}
.bottom-tabbar::before, .dock-search::before, .segmented::before {
  inset: 0;
  background: radial-gradient(
    180px 100px at var(--glass-x, 20%) var(--glass-y, 0%),
    #ffffff6b,
    transparent 80%
  );
}
.bottom-tabbar::after, .dock-search::after, .segmented::after {
  inset: 2px;
  border: 1px solid #ffffff2b;
}
.tabbar-button {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  gap: 0;
  min-width: 48px;
  padding: 7px 12px;
  border-radius: 999px;
  color: #26332e;
  line-height: 1.2;
  white-space: nowrap;
  transition: background 0.18s, flex 0.25s, color 0.18s;
}
.tabbar-button:hover {
  background: #ffffff30;
}
.tabbar-button.active {
  flex: 1.85;
  gap: 10px;
  color: #075648;
  background: linear-gradient(145deg, #cbf0e7ed, #a8ddd0eb);
  box-shadow:
    inset 0 1px 1px #ffffffd9,
    inset 0 0 0 1px #4baf964d,
    0 3px 10px #07564814;
}
.tabbar-button:not(.active):active {
  background: #ffffff52;
}
.tabbar-icon {
  position: relative;
  display: flex;
  flex-shrink: 0;
}
.tabbar-icon > .icon {
  width: 27px;
  height: 27px;
  stroke-width: 1.8;
}
.tabbar-label {
  max-width: 0;
  overflow: hidden;
  opacity: 0;
  font-size: 16px;
  font-weight: 600;
  text-overflow: ellipsis;
}
.tabbar-button.active .tabbar-label {
  max-width: 150px;
  opacity: 1;
}
.search-open .bottom-tabbar {
  opacity: 0;
  transform: translateX(-20px) scale(0.96);
  pointer-events: none;
}
.dock-search {
  position: absolute;
  top: 0;
  right: 0;
  width: var(--dock-size);
  height: var(--dock-size);
  transition: width 0.38s cubic-bezier(0.22, 1, 0.36, 1);
}
.search-open .dock-search {
  width: 100%;
}
.dock-search-toggle {
  position: absolute;
  right: 0;
  top: 0;
  display: grid;
  place-items: center;
  width: var(--dock-size);
  height: var(--dock-size);
  border-radius: 50%;
  color: #20342b;
}
.dock-search-toggle:hover {
  background: #ffffff40;
}
.dock-search-toggle > .icon {
  width: 27px;
  height: 27px;
  stroke-width: 1.8;
}
.dock-search-field {
  position: absolute;
  inset: 0 var(--dock-size) 0 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding-left: 22px;
  opacity: 0;
  transform: translateX(28px);
  pointer-events: none;
  transition: opacity 0.15s, transform 0.3s;
}
.search-open .dock-search-field {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
  transition-delay: 0.08s;
}
.dock-search-field > .icon {
  width: 23px;
  height: 23px;
  color: #40564b;
}
.dock-search-field input {
  width: 100%;
  min-width: 0;
  padding: 14px 0;
  border: 0;
  background: transparent;
  color: #152b22;
  font-size: 16px;
  box-shadow: none;
}
.dock-search-field input:focus {
  box-shadow: none;
}
.dock-search-field input::placeholder {
  color: #53645b;
}
.dock-search-field input::-webkit-search-cancel-button {
  -webkit-appearance: none;
}
.dock-search-clear {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  height: 32px;
  width: 32px;
  border-radius: 50%;
  background: #ffffff40;
  color: #40564b;
}
.dock-search-clear[hidden] {
  display: none;
}
.dock-search-clear .icon {
  width: 16px;
  height: 16px;
}
.tabbar-badge {
  position: absolute;
  top: -6px;
  left: 15px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  display: grid;
  place-items: center;
  border: 1.5px solid #eff5f8;
  border-radius: 12px;
  background: #d52d46;
  color: #fff;
  font-size: 9px;
  font-weight: 600;
  line-height: 1;
}
#toast {
  bottom: calc(112px + env(safe-area-inset-bottom, 0px));
}
@media (max-width: 800px) {
  .bottom-dock {
    --dock-size: 60px;
    bottom: calc(
      12px + env(safe-area-inset-bottom, 0px) + var(--dock-keyboard-offset, 0px)
    );
    width: min(520px, calc(100% - 24px));
  }
  .bottom-tabbar {
    padding: 6px;
    width: calc(100% - var(--dock-size) - 10px);
  }
  .tabbar-button {
    min-width: 38px;
    padding: 7px 8px;
  }
  .tabbar-button.active {
    flex: 1;
    gap: 0;
  }
  .tabbar-icon > .icon {
    width: 24px;
    height: 24px;
  }
  .tabbar-label {
    display: none;
  }
  .dock-search-field {
    padding-left: 18px;
    gap: 9px;
  }
  .dashboard {
    padding-bottom: calc(108px + env(safe-area-inset-bottom, 0px));
  }
  #toast {
    bottom: calc(100px + env(safe-area-inset-bottom, 0px));
  }
  .topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    padding-top: calc(12px + env(safe-area-inset-top, 0px));
  }
}
@media (max-width: 540px) {
  .topbar {
    padding-top: calc(10px + env(safe-area-inset-top, 0px));
  }
}
@supports not (backdrop-filter: blur(1px)) {
  @supports not (-webkit-backdrop-filter: blur(1px)) {
    .bottom-tabbar, .dock-search, .segmented {
      background: #f0f5f8;
    }
    .segmented button.selected {
      background: #deeee9;
    }
    .topbar {
      background: #f7fcf9;
    }
  }
}
@media (prefers-reduced-transparency: reduce) {
  .topbar, .account-menu {
    background: #f0faf5;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .bottom-tabbar, .dock-search, .segmented {
    background: #f0f5f8;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .tabbar-button.active {
    background: #bce8dc;
  }
  .segmented button.selected {
    background: #deeee9;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bottom-tabbar, .tabbar-button, .dock-search, .dock-search-field {
    transition: none;
  }
}

@media (max-width: 380px) {
  .tabbar-button {
    min-width: 34px;
    padding: 7px 6px;
  }
  .tabbar-button.active {
    min-width: 34px;
    flex: 1;
    gap: 0;
  }
  .tabbar-icon > .icon {
    width: 22px;
    height: 22px;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .btn,
  .icon-btn,
  .toolbar-right select,
  .field input,
  .field textarea,
  .field select,
  .location-picker > summary,
  .location-chips button,
  .gallery-expand,
  .listing-card,
  .watch-card,
  .settings-card,
  .notification-list,
  .account-menu,
  .location-menu,
  dialog:not(.photo-viewer),
  .topbar,
  .modal-heading,
  .modal-footer {
    background: #f0f5f3;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .btn.primary,
  .btn.primary:hover:not(:disabled),
  .header-account[aria-expanded="true"] {
    background: #bce8dc;
  }
  .btn.destructive {
    background: #f7d6dd;
  }
  select {
    --glass: linear-gradient(#edf5f0, #edf5f0);
  }
}

/* Logo, source tabs, filters and avatar share one sticky header. */
.header-brand, .header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.header-brand {
  margin-right: auto;
}
.header-actions {
  justify-content: flex-end;
}
.topbar.with-filters {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  grid-template-areas: "brand sources actions";
}
.topbar.with-filters .header-brand {
  grid-area: brand;
}
.topbar.with-filters .header-actions {
  grid-area: actions;
}
.topbar.with-filters .toolbar-right {
  flex: 0 1 290px;
  flex-wrap: nowrap;
  min-width: 0;
  width: auto;
}
.topbar.with-filters .toolbar-right select {
  flex: 1;
  min-width: 0;
}
@media (max-width: 1100px) {
  .topbar.with-filters {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "brand account" "sources sources" "controls controls";
    row-gap: 12px;
  }
  .topbar.with-filters .header-actions {
    display: contents;
  }
  .topbar.with-filters .account-dropdown {
    grid-area: account;
  }
  .topbar.with-filters .toolbar-right {
    grid-area: controls;
    justify-self: center;
    width: 100%;
    max-width: 360px;
  }
}

.btn.new-watch-button {
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  padding: 0;
  border-radius: 50%;
  flex-shrink: 0;
}
.new-watch-button .icon {
  width: 28px;
  height: 28px;
  stroke-width: 1.8;
}
@media (max-width: 800px) {
  .btn.new-watch-button {
    width: 48px;
    height: 48px;
  }
}

/* Custom filter popups keep the same glass material when opened. */
.filter-layer {
  position: fixed;
  inset: 0;
  z-index: 40;
  pointer-events: none;
}
.filter-dropdown {
  position: relative;
  flex: 1;
  min-width: 0;
}
.btn.filter-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 40px;
  padding: 9px 12px;
  gap: 9px;
  font-size: 13px;
}
.filter-trigger > span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.filter-trigger > .icon {
  height: 16px;
  width: 16px;
  transition: transform 0.18s;
}
.filter-trigger[aria-expanded="true"] {
  border-color: #3b9e8280;
  background: var(--glass-mint);
}
.filter-trigger[aria-expanded="true"] > .icon {
  transform: rotate(180deg);
}
.filter-options {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 40;
  width: max-content;
  min-width: 100%;
  max-width: min(340px, calc(100vw - 32px));
  max-height: min(320px, calc(100dvh - 150px));
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 6px;
  border: 1px solid #ffffffd9;
  border-radius: 20px;
  background: linear-gradient(145deg, #f6fff5cf, #ddebe3db);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
  backdrop-filter: blur(28px) saturate(160%);
  box-shadow:
    var(--glass-control-shadow),
    0 12px 32px #244b3a26;
  pointer-events: auto;
  transform-origin: top right;
  animation: filter-reveal 0.16s ease-out;
}
.filter-options[hidden] {
  display: none;
}
.filter-dropdown:first-child .filter-options {
  left: 0;
  right: auto;
  transform-origin: top left;
}
.filter-option {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 14px;
  color: #263e31;
  text-align: left;
  font-size: 14px;
  line-height: 1.4;
}
.filter-option > span {
  overflow-wrap: anywhere;
}
.filter-option > .icon {
  width: 18px;
  height: 18px;
  opacity: 0;
}
.filter-option[aria-selected="true"] {
  background: #bce8dc80;
  border-color: #ffffff8c;
  color: var(--accent-ink);
}
.filter-option[aria-selected="true"] > .icon {
  opacity: 1;
}
.filter-option:hover, .filter-option:focus-visible {
  background: #ffffffa6;
  border-color: #ffffffcc;
  outline: 1.5px solid #26886c80;
  outline-offset: -2px;
}
@keyframes filter-reveal {
  from {
    opacity: 0;
    transform: translateY(-5px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}
@media (prefers-reduced-transparency: reduce) {
  .filter-options {
    background: #edf5f0;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .filter-trigger[aria-expanded="true"] {
    background: #bce8dc;
  }
}

/* Region selection stays inside its glass dropdown. */
.region-selection {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  flex: 1;
}
.selected-region-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.selected-region-extra {
  display: grid;
  place-items: center;
  min-width: 25px;
  padding: 2px 6px;
  flex-shrink: 0;
  border: 1px solid #ffffffb8;
  border-radius: 999px;
  background: #c6eaddb3;
  color: var(--accent-ink);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
}
.filter-trigger.has-filter {
  background: var(--glass-mint);
  border-color: #73bba580;
}
.region-filter-options {
  display: flex;
  flex-direction: column;
  width: 300px;
  overflow: hidden;
}
.region-filter-search {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  flex-shrink: 0;
}
.region-filter-search .icon {
  width: 17px;
  height: 17px;
  color: var(--secondary);
}
.region-filter-search input {
  width: 100%;
  min-width: 0;
  padding: 6px 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-size: 16px;
  box-shadow: none;
}
.region-filter-search input:focus {
  box-shadow: none;
}
.region-filter-list {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.filter-option[hidden] {
  display: none;
}
.region-filter-empty {
  padding: 12px;
  color: var(--secondary);
  font-size: 14px;
}
.region-filter-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 6px 2px;
  flex-shrink: 0;
  border-top: 1px solid #ffffff8c;
}
.region-filter-footer > button:first-child {
  padding: 8px;
  border-radius: 999px;
  color: var(--accent-ink);
  font-size: 13px;
}
.topbar.with-filters .toolbar-right {
  flex-basis: 400px;
}
.feed-viewbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 14px;
}
.view-switcher {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 4px;
  border: 1px solid #ffffffb8;
  border-radius: 999px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(20px) saturate(155%);
  backdrop-filter: blur(20px) saturate(155%);
  box-shadow: var(--glass-control-shadow);
}
.view-switcher button {
  display: grid;
  place-items: center;
  width: 38px;
  height: 36px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: #40564b;
}
.view-switcher button:hover {
  background: #ffffff52;
}
.view-switcher button.selected {
  background: var(--glass-mint);
  border-color: #ffffffb8;
  color: var(--accent-ink);
}
.view-switcher .icon {
  width: 19px;
  height: 19px;
}
.listing-grid.layout-small {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.layout-small .listing-card {
  padding: 12px;
}
.layout-small .card-heading {
  gap: 6px;
  margin-bottom: 10px;
}
.layout-small .card-heading .icon-btn {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}
.layout-small .source, .layout-small .card-location {
  font-size: 12px;
}
.layout-small .source img {
  width: 16px;
  height: 16px;
}
.layout-small .card-image {
  aspect-ratio: 4 / 3;
  max-height: 180px;
}
.layout-small .card-content {
  padding: 12px 0 8px;
}
.layout-small .listing-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 14px;
}
.layout-small .card-price {
  font-size: 19px;
  margin: 8px 0;
}
.layout-small .card-watch, .layout-list .card-watch {
  display: none;
}
.layout-small .card-footer {
  flex-wrap: wrap;
  gap: 8px;
}
.layout-small .card-footer .btn {
  padding: 6px 10px;
  font-size: 12px;
}
.layout-small .card-footer time {
  font-size: 12px;
}
.listing-grid.layout-list {
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}
.layout-list .listing-card {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) auto;
  grid-template-areas: "image heading heading" "image content footer";
  column-gap: 18px;
  row-gap: 6px;
  padding: 14px;
}
.layout-list .card-image {
  grid-area: image;
  width: 110px;
  height: 110px;
  aspect-ratio: 1;
  align-self: center;
}
.layout-list .card-heading {
  grid-area: heading;
  margin: 0;
}
.layout-list .card-heading > div {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.layout-list .card-location {
  margin: 0;
}
.layout-list .card-content {
  grid-area: content;
  min-width: 0;
  padding: 0;
}
.layout-list .listing-title {
  font-size: 16px;
}
.layout-list .card-price {
  margin: 5px 0 0;
  font-size: 20px;
}
.layout-list .card-footer {
  grid-area: footer;
  align-self: end;
  padding: 0;
  margin: 0;
}
@media (max-width: 1250px) {
  .listing-grid.layout-small {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 800px) {
  .listing-grid.layout-small {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
}
@media (max-width: 540px) {
  .topbar.with-filters .toolbar-right {
    gap: 6px;
  }
  .btn.filter-trigger {
    padding: 9px 9px;
    gap: 5px;
    font-size: 12px;
  }
  .filter-trigger > .icon {
    width: 13px;
    height: 13px;
  }
  .layout-small .listing-card {
    padding: 10px;
  }
  .layout-small .card-footer .btn {
    width: 100%;
    justify-content: center;
  }
  .layout-list .listing-card {
    grid-template-columns: 72px minmax(0, 1fr);
    grid-template-areas: "image heading" "image content" "footer footer";
    gap: 8px 12px;
    padding: 12px;
  }
  .layout-list .card-image {
    width: 72px;
    height: 86px;
  }
  .layout-list .card-heading > div {
    display: block;
  }
  .layout-list .card-location {
    margin-top: 3px;
    font-size: 12px;
  }
  .layout-list .card-heading .icon-btn {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
  }
  .layout-list .listing-title {
    font-size: 14px;
  }
  .layout-list .card-price {
    font-size: 18px;
  }
  .layout-list .card-footer .btn {
    font-size: 12px;
    padding: 6px 10px;
  }
}
@media (prefers-reduced-transparency: reduce) {
  .view-switcher {
    background: #edf5f0;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}

.watch-card-footer > div {
  align-items: center;
  gap: 7px;
}
.watch-switch {
  position: relative;
  width: 52px;
  height: 32px;
  padding: 0;
  flex-shrink: 0;
  border: 1px solid #ffffffb8;
  border-radius: 999px;
  background: linear-gradient(145deg, #dce5e3b3, #bfcfca9c);
  -webkit-backdrop-filter: blur(20px) saturate(155%);
  backdrop-filter: blur(20px) saturate(155%);
  box-shadow: var(--glass-control-shadow);
  transition: background 0.2s, border-color 0.2s;
}
.watch-switch[aria-checked="true"] {
  background: linear-gradient(145deg, #a8e4d1e6, #69bea3d9);
  border-color: #439f8280;
}
.watch-switch-knob {
  position: absolute;
  left: 3px;
  top: 3px;
  width: 24px;
  height: 24px;
  border: 1px solid #ffffffe6;
  border-radius: 50%;
  background: linear-gradient(145deg, #fff, #eaf5f0ed);
  box-shadow: inset 0 1px 1px #fff, 0 2px 6px #214b3b33;
  transition: transform 0.22s cubic-bezier(0.22, 1, 0.36, 1);
}
.watch-switch[aria-checked="true"] .watch-switch-knob {
  transform: translateX(20px);
}
.watch-switch:disabled {
  cursor: wait;
}
@media (prefers-reduced-transparency: reduce) {
  .watch-switch {
    background: #dce5e1;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .watch-switch[aria-checked="true"] {
    background: #8ad1b9;
  }
}

.watch-card-top > .watch-switch {
  margin-left: auto;
}
.feed-viewbar {
  position: sticky;
  top: calc(var(--header-height, 78px) + 8px);
  z-index: 18;
  pointer-events: none;
}
.feed-viewbar .view-switcher {
  pointer-events: auto;
}

.mobile-controls-toggle {
  display: none;
}
@media (max-width: 800px) {
  .topbar.with-filters {
    grid-template-columns: minmax(0, 1fr) auto auto;
    grid-template-areas: "brand tools account" "sources sources sources";
    column-gap: 10px;
  }
  .topbar.with-filters .mobile-controls-toggle {
    display: grid;
    place-items: center;
    grid-area: tools;
    width: 36px;
    height: 36px;
    border-radius: 50%;
  }
  .mobile-controls-toggle[aria-expanded="true"] {
    background: var(--glass-mint);
    color: var(--accent-ink);
  }
  .app-shell:not(.mobile-controls-open) .topbar.with-filters .toolbar-right,
  .app-shell:not(.mobile-controls-open) .feed-viewbar {
    display: none;
  }
  .mobile-controls-open .topbar.with-filters {
    grid-template-areas:
      "brand tools account" "sources sources sources" "controls controls controls";
  }
}

@media (max-width: 800px) {
  .notification-item {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr) 36px;
    align-items: start;
  }
  .notification-item > .notification-content {
    min-width: 0;
    grid-column: 2;
    grid-row: 1;
  }
  .notification-item > .notification-open {
    margin-left: 0;
    grid-column: 3;
    grid-row: 1;
    align-self: start;
    justify-self: end;
    width: 36px;
    height: 36px;
    padding: 0;
    display: grid;
    place-items: center;
    border-radius: 50%;
  }
  .notification-open .open-link-label {
    display: none;
  }
}

.auth-panel {
  width: min(380px, 100%);
  margin: 32px auto 0;
  padding: 24px;
  border: 1px solid #ffffffc7;
  border-radius: 24px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  backdrop-filter: blur(20px) saturate(150%);
  box-shadow: var(--glass-control-shadow);
  text-align: left;
}
.auth-panel > .btn,
.auth-panel form > .btn {
  width: 100%;
  justify-content: center;
}
.auth-panel .field {
  margin-bottom: 16px;
}
.auth-panel .field input {
  width: 100%;
  font-size: 16px;
}
.auth-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 20px 0;
  color: #52675f;
  font-size: 13px;
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  height: 1px;
  flex: 1;
  background: #496b5c26;
}
.landing-hero .auth-switch {
  margin: 18px 0 0;
  font-size: 14px;
  text-align: center;
  color: #415a4e;
}
.auth-switch button {
  color: var(--accent-ink);
  font-weight: 600;
}
.landing-hero .auth-notice {
  margin: 0 0 20px;
  padding: 12px;
  border-radius: 12px;
  background: #caeadead;
  color: #174b39;
  font-size: 14px;
  line-height: 1.5;
}
@media (max-width: 540px) {
  .auth-panel {
    padding: 20px;
  }
}

.connection-state {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px 24px 64px;
  text-align: center;
}
.connection-illustration {
  display: block;
  width: min(360px, 85vw);
  height: auto;
  margin-bottom: 12px;
}
.connection-state h1 {
  margin: 0 0 12px;
  font-size: clamp(25px, 4.5vw, 34px);
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.8px;
  color: #203c31;
}
.connection-state p {
  max-width: 360px;
  margin: 0;
  color: #52665c;
  font-size: 16px;
  line-height: 1.7;
}
.connection-state .btn {
  margin-top: 26px;
  min-height: 46px;
  padding: 12px 22px;
  border-radius: 999px;
  gap: 9px;
  font-size: 15px;
}
.connection-state .btn .icon {
  width: 18px;
  height: 18px;
}
@media (max-width: 540px) {
  .connection-state {
    padding: 24px 20px 56px;
  }
  .connection-illustration {
    width: min(300px, 85vw);
  }
}

/* Installation stays optional; updates wait until the user is ready. */
[data-pwa-install][hidden], #pwa-update[hidden] {
  display: none !important;
}
.pwa-landing-install {
  margin-top: 20px;
  border-radius: 999px;
}
.pwa-settings > .btn {
  margin-top: 8px;
}
#install-dialog {
  width: min(480px, calc(100% - 24px));
}
#install-dialog .icon-btn {
  border-radius: 50%;
}
.pwa-help > img {
  display: block;
  margin: 0 auto 18px;
  border-radius: 18px;
}
.pwa-help p, .pwa-help li {
  line-height: 1.65;
}
.pwa-help h3 {
  font-size: 18px;
  margin: 22px 0 12px;
}
.pwa-help ol {
  padding-left: 24px;
}
.pwa-help li + li {
  margin-top: 12px;
}
.pwa-update {
  position: fixed;
  z-index: 45;
  bottom: calc(110px + env(safe-area-inset-bottom, 0px));
  left: 50%;
  transform: translateX(-50%);
  width: max-content;
  max-width: calc(100% - 24px);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid #fff;
  border-radius: 24px;
  background: var(--glass-paper);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  box-shadow: var(--glass-shadow);
  font-size: 15px;
}
.pwa-update .btn {
  min-height: 40px;
  padding: 8px 16px;
}
.pwa-update .icon-btn {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  font-size: 24px;
  border-radius: 50%;
}

.watch-viewbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 16px;
  position: sticky;
  top: calc(var(--header-height, 78px) + 8px);
  z-index: 18;
  pointer-events: none;
}
.watch-viewbar .view-switcher {
  pointer-events: auto;
}
.watch-grid.layout-small {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.watch-grid.layout-small .watch-card {
  padding: 16px;
}
.watch-grid.layout-small .watch-card-top {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
}
.watch-grid.layout-small .watch-card-top > .product-thumb {
  width: 44px;
  height: 44px;
}
.watch-grid.layout-small .watch-switch {
  grid-column: 2;
  grid-row: 1;
}
.watch-grid.layout-small .status-pill {
  grid-column: 1 / -1;
  justify-self: start;
  font-size: 14px;
}
.watch-grid.layout-small h2 {
  font-size: 17px;
  margin-top: 14px;
}
.watch-grid.layout-small .budget strong {
  font-size: 18px;
  line-height: 1.5;
}
.watch-grid.layout-small .watch-meta {
  gap: 8px;
}
.watch-grid.layout-small .source-statuses > div {
  flex-wrap: wrap;
  gap: 6px;
}
.watch-grid.layout-small .watch-card-footer {
  flex-wrap: wrap;
  gap: 12px;
}
.watch-grid.layout-list {
  grid-template-columns: 1fr;
  gap: 14px;
}
.watch-grid.layout-list .watch-card {
  display: grid;
  grid-template-columns:
    84px minmax(160px, 1.3fr) minmax(180px, 1fr) minmax(180px, 1fr) auto;
  grid-template-areas:
    "image title budget status toggle" "image meta sources sources footer";
  gap: 14px 20px;
  align-items: center;
  padding: 20px;
}
.watch-grid.layout-list .watch-card-top {
  display: contents;
}
.watch-grid.layout-list .watch-card-top > .product-thumb {
  grid-area: image;
  width: 84px;
  height: 84px;
  align-self: start;
}
.watch-grid.layout-list .status-pill {
  grid-area: status;
  justify-self: start;
}
.watch-grid.layout-list .watch-switch {
  grid-area: toggle;
  justify-self: end;
}
.watch-grid.layout-list h2 {
  grid-area: title;
  margin: 0;
  font-size: 18px;
}
.watch-grid.layout-list .watch-query {
  display: none;
}
.watch-grid.layout-list .budget {
  grid-area: budget;
  margin: 0;
  padding: 0;
}
.watch-grid.layout-list .budget small {
  display: none;
}
.watch-grid.layout-list .budget strong {
  font-size: 18px;
  margin: 0;
}
.watch-grid.layout-list .watch-meta {
  grid-area: meta;
  margin: 0;
  gap: 8px;
}
.watch-grid.layout-list .source-statuses {
  grid-area: sources;
  padding: 0;
  border: 0;
}
.watch-grid.layout-list .source-statuses > div {
  justify-content: flex-start;
  flex-wrap: wrap;
}
.watch-grid.layout-list .watch-card-footer {
  grid-area: footer;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
}
@media (max-width: 1200px) {
  .watch-grid.layout-small {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .watch-grid.layout-list .watch-card {
    grid-template-columns: 72px minmax(0, 1fr) auto;
    grid-template-areas:
      "image title toggle" "image budget status" "meta meta meta" "sources sources footer";
    gap: 12px 16px;
  }
  .watch-grid.layout-list .watch-card-top > .product-thumb {
    width: 72px;
    height: 72px;
  }
}
@media (max-width: 800px) {
  .watch-grid.layout-small {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 540px) {
  .watch-grid.layout-small {
    gap: 12px;
  }
  .watch-grid.layout-small .watch-card {
    padding: 12px;
  }
  .watch-grid.layout-small .watch-card-top > .product-thumb {
    width: 38px;
    height: 38px;
  }
  .watch-grid.layout-small h2, .watch-grid.layout-small .budget strong {
    font-size: 16px;
  }
  .watch-grid.layout-small .source-statuses > div {
    flex-direction: column;
    align-items: flex-start;
  }
  .watch-grid.layout-small .watch-card-footer > div {
    gap: 4px;
  }
  .watch-grid.layout-small .watch-card-footer .icon-btn {
    width: 32px;
    height: 32px;
  }
  .watch-grid.layout-list .watch-card {
    padding: 16px;
    grid-template-columns: 60px minmax(0, 1fr) auto;
    grid-template-areas:
      "image title toggle" "image budget budget" "status status status" "meta meta meta" "sources sources sources" "footer footer footer";
    gap: 12px;
  }
  .watch-grid.layout-list .watch-card-top > .product-thumb {
    width: 60px;
    height: 60px;
  }
  .watch-grid.layout-list h2, .watch-grid.layout-list .budget strong {
    font-size: 17px;
  }
  .watch-grid.layout-list .watch-card-footer {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

/* The touch highlight and keyboard focus follow the control's own radius. */
button, a, summary, [role="switch"] {
  -webkit-tap-highlight-color: transparent;
}
button:focus:not(:focus-visible), a:focus:not(:focus-visible) {
  outline: none;
}
.btn:focus-visible,
.icon-btn:focus-visible,
.watch-switch:focus-visible,
.view-switcher button:focus-visible,
.segmented button:focus-visible,
.tabbar-button:focus-visible,
.toast-close:focus-visible {
  outline: none;
  box-shadow:
    var(--glass-control-shadow),
    0 0 0 3px #4cb8a05e;
}
.skeleton, .product-thumb.is-loading::after {
  background: linear-gradient(100deg, #dce9e5 20%, #f5faf8 45%, #dce9e5 70%);
  background-size: 220% 100%;
  animation: skeleton-shimmer 1.5s ease-in-out infinite;
}
.skeleton-line {
  height: 16px;
  width: 100%;
  border-radius: 999px;
  margin: 12px 0;
}
.skeleton-line.short {
  width: 60%;
}
.skeleton-avatar {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  margin-bottom: 20px;
}
.watch-grid .skeleton-card {
  display: block;
  min-height: 200px;
}
.product-thumb.is-loading {
  position: relative;
  overflow: hidden;
}
.product-thumb.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}
.product-thumb.is-loading img {
  opacity: 0;
}
.product-thumb img {
  transition: opacity 0.18s ease;
}
@keyframes skeleton-shimmer {
  from {
    background-position: 100% 0;
  }
  to {
    background-position: -100% 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .skeleton, .product-thumb.is-loading::after {
    animation: none;
  }
  .product-thumb img {
    transition: none;
  }
}
.budget-compact, .watch-more, .watch-mobile-alert {
  display: none;
}
.watch-details {
  margin: 0 0 20px;
}
.watch-details > div {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.watch-details dt {
  font-size: 14px;
  color: var(--secondary);
  margin-bottom: 6px;
}
.watch-details dd {
  margin: 0;
  font-size: 16px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.watch-detail-actions {
  flex-wrap: wrap;
  gap: 10px;
}
.watch-detail-actions > .danger {
  margin-right: auto;
}
@media (max-width: 800px) {
  .watch-grid .watch-card .watch-query,
  .watch-grid .watch-card .budget small,
  .watch-grid .watch-card .budget-full,
  .watch-grid .watch-card .watch-meta,
  .watch-grid .watch-card .source-statuses,
  .watch-grid .watch-card .watch-actions,
  .watch-grid .watch-card .status-pill,
  .watch-grid .watch-card .watch-count-extra {
    display: none;
  }
  .watch-grid:not(.layout-list) .watch-card {
    display: flex;
    flex-direction: column;
    padding: 14px;
  }
  .watch-grid .watch-card .watch-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }
  .watch-grid .watch-card .watch-card-top > .product-thumb {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    border-radius: 12px;
  }
  .watch-grid:not(.layout-list) .watch-card h2 {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    min-height: 3em;
    margin: 12px 0 8px;
    font-size: 16px;
    line-height: 1.5;
  }
  .watch-grid .watch-card .budget {
    padding: 0;
    margin: 0 0 12px;
  }
  .watch-grid .watch-card .budget strong {
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: -0.3px;
  }
  .watch-grid .watch-card .budget-compact {
    display: block;
  }
  .watch-grid .watch-card .watch-card-footer {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding-top: 10px;
    margin-top: auto;
    color: #49615b;
    font-size: 14px;
  }
  .watch-grid .watch-card .watch-more {
    display: grid;
    flex: 0 0 36px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
  }
  .watch-grid .watch-card .watch-mobile-alert {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    line-height: 1.5;
    text-align: left;
    padding: 5px 8px;
    border: 1px solid #fff;
    border-radius: 12px;
    color: #80521d;
    background: #f7eed8b3;
    margin: 0 0 10px;
  }
  .watch-mobile-alert .icon {
    flex: 0 0 15px;
    width: 15px;
    height: 15px;
  }
  .watch-grid.layout-list .watch-card {
    padding: 14px;
    grid-template-columns: 56px minmax(0, 1fr) auto;
    grid-template-areas:
      "image title toggle" "image budget budget" "footer footer footer";
    gap: 10px 12px;
  }
  .watch-grid.layout-list .watch-card .watch-card-top {
    display: contents;
  }
  .watch-grid.layout-list .watch-card .watch-card-top > .product-thumb {
    width: 56px;
    height: 56px;
  }
  .watch-grid.layout-list .watch-card h2 {
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
  }
  .watch-grid.layout-list .watch-card .budget {
    margin: 0;
  }
  .watch-grid.layout-list .watch-card .watch-mobile-alert {
    grid-column: 1 / -1;
  }
}
