/* Roboto Condensed — only for СПОРТ.ВЕЩИ logo */
@font-face {
  font-family: 'Roboto Condensed';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/static/fonts/roboto-condensed-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Roboto Condensed';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/static/fonts/roboto-condensed-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ===== RESET & BASE ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --black: #222;
  --gray: #999;
  --light: #f5f5f5;
  --border: #e8e8e8;
  --white: #fff;
  --price: #d32f2f;
  --accent: #222;
  --radius: 10px;
  --radius-btn: 20px;
  --brand-orange: #e26c1d;
  --brand-green: #206b16;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--black);
  background: var(--white);
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

/* ===== HEADER ===== */
.header {
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  gap: 20px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  color: var(--black);
}
.logo-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}
.logo-main {
  font-family: 'Roboto Condensed', sans-serif;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}
.logo-dot {
  color: var(--brand-orange);
}
.logo-sub {
  font-family: 'Roboto Condensed', sans-serif;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--gray);
  text-transform: lowercase;
}

.search-form {
  flex: 1;
  max-width: 560px;
  display: flex;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color .2s;
}
.search-form:focus-within { border-color: var(--black); }

.search-input {
  flex: 1;
  border: none;
  padding: 10px 14px;
  font-size: 14px;
  outline: none;
  background: transparent;
}

.search-btn {
  background: none;
  border: none;
  padding: 0 14px;
  cursor: pointer;
  color: var(--gray);
  display: flex;
  align-items: center;
}
.search-btn:hover { color: var(--black); }

.deal-type-tabs {
  display: flex;
  background: #f0f0f0;
  border-radius: 10px;
  padding: 3px;
  max-width: 280px;
}
.deal-type-tab {
  flex: 1;
  padding: 7px 8px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  color: #666;
  text-align: center;
  transition: all .2s;
  border: none;
  background: transparent;
  outline: none;
  cursor: pointer;
  font-family: inherit;
}
.deal-type-tab--active {
  background: #fff;
  color: #1d1d1f;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0,0,0,.1);
}

/* Desktop deal-type: Продажа=green, Аренда=orange */
.deal-type-tabs--desktop .deal-type-tab {
  color: rgba(102, 102, 102, 0.5);
}
.deal-type-tabs--desktop .deal-type-tab--active {
  color: #1d1d1f;
}
/* Продажа active = green */
body:not([data-deal="аренда"]) .deal-type-tabs--desktop .deal-type-tab--active {
  background: var(--brand-green);
  color: #fff;
}
body:not([data-deal="аренда"]) .deal-type-tabs--desktop .deal-type-tab:not(.deal-type-tab--active) {
  color: #999;
}
/* Аренда active = orange */
body[data-deal="аренда"] .deal-type-tabs--desktop .deal-type-tab--active {
  background: var(--brand-orange);
  color: #fff;
}
body[data-deal="аренда"] .deal-type-tabs--desktop .deal-type-tab:not(.deal-type-tab--active) {
  color: #999;
}

#sourceTabs { margin-left: 4px; gap: 3px; background: transparent; padding: 0; }
#sourceTabs .deal-type-tab { background: #f0f0f0; padding: 7px 10px; border-radius: 8px; }
#sourceTabs .deal-type-tab[data-source="store"].deal-type-tab--active { background: #e8772e; color: #fff; font-weight: 600; box-shadow: none; }
#sourceTabs .deal-type-tab[data-source="private"].deal-type-tab--active { background: #3a7d44; color: #fff; font-weight: 600; box-shadow: none; }
.source-tab-all { display: none; }

.header-link {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--gray);
  white-space: nowrap;
  transition: color .2s;
}
.header-link:hover { color: var(--black); }

.filter-toggle {
  display: none;
  align-items: center;
  gap: 6px;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 14px;
  font-size: 13px;
  cursor: pointer;
  color: var(--black);
  white-space: nowrap;
}

/* ===== CATEGORY CHIPS ===== */
.categories-bar {
  border-bottom: 1px solid var(--border);
  background: var(--white);
}

.categories-scroll {
  max-width: 1400px;
  margin: 0 auto;
  padding: 10px 20px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.categories-scroll::-webkit-scrollbar { display: none; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 7px 16px;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 13px;
  white-space: nowrap;
  color: var(--black);
  transition: all .2s;
  cursor: pointer;
}
.chip:hover { border-color: var(--black); }
.chip--active {
  background: var(--brand-green);
  color: var(--white);
  border-color: var(--brand-green);
}

.chip-count {
  font-size: 11px;
  color: var(--gray);
  margin-left: 2px;
}
.chip--active .chip-count { color: rgba(255,255,255,.6); }

/* ===== GROUP CHIPS ===== */
.groups-bar {
  border-bottom: 1px solid var(--border);
  background: var(--light);
}
.chip--sub {
  font-size: 12px;
  padding: 5px 14px;
  background: #e8e8e8;
  color: var(--black);
  border-color: #e8e8e8;
}
.chip--sub.chip--active {
  background: #666;
  color: var(--white);
  border-color: #666;
}
/* ===== SHOP CHIPS ===== */
.shops-bar {
  border-bottom: 1px solid var(--border);
  background: var(--white);
}
.chip--shop {
  font-size: 13px;
  padding: 6px 10px;
  background: transparent;
  border-color: var(--border);
  min-height: 36px;
}
.chip.chip--shop.chip--active {
  background: transparent !important;
  color: var(--black) !important;
  border-color: #e26c1d !important;
  border-width: 2px !important;
}
.chip-logo {
  width: 80px;
  height: 20px;
  border-radius: 2px;
  object-fit: contain;
  flex-shrink: 0;
}

/* ===== SUBGROUP CHIPS (second row) ===== */
.subgroups-bar {
  border-bottom: 1px solid var(--border);
  background: var(--white);
}
/* ===== GENDER FILTER (inline in results-bar) ===== */
.chip--sub2 {
  font-size: 11px;
  padding: 4px 12px;
  background: #f0f0f0;
  color: var(--black);
  border-color: #f0f0f0;
}
.chip--sub2.chip--active {
  background: #888;
  color: var(--white);
  border-color: #888;
}

/* Аренда mode: categories orange, subgroups stay gray */
body[data-deal="аренда"] .chip--active:not(.chip--sub) {
  background: var(--brand-orange);
  border-color: var(--brand-orange);
}

/* ===== LAYOUT ===== */
.layout {
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px;
  display: flex;
  gap: 30px;
}

/* ===== SIDEBAR ===== */
.sidebar {
  width: 220px;
  flex-shrink: 0;
}

.sidebar-header {
  display: none;
}

.sidebar-title {
  font-size: 15px;
  font-weight: 600;
}

.sidebar-close {
  background: none;
  border: none;
  cursor: pointer;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  font-size: 22px;
  font-weight: 300;
  line-height: 1;
  color: var(--gray);
}
.sidebar-close::after {
  content: '\00d7';
  display: block;
  font-size: 22px;
  font-weight: 300;
  line-height: 1;
}

.filter-group {
  margin-bottom: 24px;
}

.filter-label {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--gray);
  margin-bottom: 10px;
}

.radio-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 0;
  font-size: 14px;
  cursor: pointer;
}
.radio-option input[type="radio"] {
  accent-color: var(--black);
}

.filter-select {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  background: var(--white);
  cursor: pointer;
  outline: none;
}
.filter-select:focus { border-color: var(--black); }

/* Country filter buttons */
.country-btns {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.country-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  background: #fff;
  color: #333;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: background .15s, border-color .15s;
}
.country-btn:hover {
  background: #f5f5f5;
}
.country-btn--active {
  background: #e8e8e8;
  color: #111;
  border-color: #bbb;
  font-weight: 600;
}
.country-btn--active:hover {
  background: #e0e0e0;
}
.country-flag {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  flex-shrink: 0;
}
.country-count {
  margin-left: auto;
  font-size: 11px;
  opacity: .5;
}

.clear-btn {
  display: block;
  text-align: center;
  padding: 8px;
  font-size: 13px;
  color: var(--gray);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-top: 16px;
  transition: all .2s;
}
.clear-btn:hover { color: var(--black); border-color: var(--black); }

/* ===== CONTENT ===== */
.content { flex: 1; min-width: 0; }

.results-bar {
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.results-count {
  font-size: 11px;
  color: rgba(0,0,0,0.35);
  display: flex;
  align-items: center;
  gap: 8px;
}
.search-clear {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(230, 81, 0, 0.25);
  text-decoration: none;
  vertical-align: middle;
}
.search-clear::after {
  content: '\00d7';
  display: block;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  color: var(--brand-orange);
}
.search-clear:hover { background: rgba(230, 81, 0, 0.35); }

/* ===== PRODUCT GRID ===== */
.grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2px;
}

/* ===== PRODUCT CARD ===== */
.card {
  cursor: pointer;
  padding: 10px;
  transition: background .15s;
  border-radius: 8px;
}
.card:hover { background: var(--light); }

.card-img {
  position: relative;
  width: 100%;
  padding-top: 120%;
  background: linear-gradient(135deg, #ffffff, #e8e8e8);
  overflow: hidden;
  margin-bottom: 10px;
  border-radius: 8px;
}

.card-slider {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
}
.card-slide {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity .3s;
}
.card-slide--active { opacity: 1; }
.card--store .card-img { padding-top: 100%; background: #fff; }
.card--store .card-slide { object-fit: contain; }

.card-no-photo {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray);
  font-size: 13px;
}

.card-body { padding: 0 2px; }

.card-price {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 4px;
}

.card-name {
  font-size: 13px;
  color: var(--black);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.3;
  margin-bottom: 4px;
}

.card-sizes {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  margin-bottom: 4px;
}
.card-size-tag {
  font-size: 10px;
  padding: 1px 5px;
  border-radius: 4px;
  background: var(--bg);
  color: var(--gray);
  border: 1px solid #e0e0e0;
  line-height: 1.4;
}

.card-sizes--collapsed .card-size-hidden { display: none; }
.card-sizes--expanded .card-size-hidden { display: inline; }
.card-sizes--expanded .card-size-toggle { display: none; }
.card-size-toggle {
  font-size: 10px;
  padding: 1px 5px;
  border-radius: 4px;
  background: transparent;
  color: var(--brand-orange, #e87a2e);
  border: 1px solid var(--brand-orange, #e87a2e);
  line-height: 1.4;
  cursor: pointer;
  white-space: nowrap;
}

.card-city {
  font-size: 12px;
  color: var(--gray);
}

/* ===== CARD DOTS ===== */
.card-dots {
  position: absolute;
  bottom: 6px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 4px;
  z-index: 2;
}
.card-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(255,255,255,.25);
}
.card-dot--active {
  background: #fff;
}

/* ===== DISCOUNT BADGE ===== */
.discount-badge {
  position: absolute;
  bottom: 8px;
  left: 8px;
  z-index: 5;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  background: #d32f2f;
  color: #fff;
  line-height: 1;
}
.modal-gallery .discount-badge {
  bottom: 12px;
  left: 12px;
  top: auto;
  right: auto;
  font-size: 13px;
  padding: 5px 10px;
}
/* ===== GOOD PRICE BADGE ===== */
.good-price-badge {
  position: absolute;
  bottom: 8px;
  left: 8px;
  z-index: 5;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  background: #616161;
  color: #fff;
  line-height: 1;
}
.discount-badge ~ .good-price-badge { bottom: 36px; }
.modal-gallery .good-price-badge {
  bottom: 12px;
  left: 12px;
  top: auto;
  right: auto;
  font-size: 13px;
  padding: 5px 10px;
}
.modal-gallery .discount-badge ~ .good-price-badge { bottom: 48px; }
/* ===== PROMO BADGE ===== */
.promo-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: #FFD814;
  color: #666;
  padding: 3px 7px 3px 5px;
  border-radius: 20px;
  font-size: 10px;
  font-weight: 400;
  font-family: inherit;
  z-index: 6;
  line-height: 1;
  display: flex;
  align-items: center;
  gap: 3px;
  letter-spacing: 0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.price-old {
  text-decoration: line-through;
  color: var(--gray);
  font-weight: 400;
}

/* ===== EMPTY STATE ===== */
.empty {
  text-align: center;
  padding: 80px 20px;
}
.empty-icon { margin-bottom: 16px; }
.empty-text { font-size: 16px; color: var(--gray); margin-bottom: 12px; }
.empty-link { font-size: 14px; color: var(--black); border-bottom: 1px solid var(--border); }

/* ===== PAGINATION ===== */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin: 40px 0 20px;
}

.page-link {
  min-width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  color: var(--black);
  transition: all .2s;
}
.page-link:hover { border-color: var(--black); }
.page-link--active {
  background: var(--black);
  color: var(--white);
  border-color: var(--black);
}

.page-dots {
  min-width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--gray);
}

/* ===== MODAL ===== */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,.5);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay.open {
  display: flex;
}

.modal {
  background: var(--white);
  border-radius: 8px;
  max-width: 900px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 18px; right: 20px;
  background: #e0e0e0;
  border: none;
  font-size: 20px;
  font-weight: 300;
  line-height: 1;
  cursor: pointer;
  color: #555;
  z-index: 10;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.modal-close::after {
  content: '\00d7';
  display: block;
  font-size: 22px;
  font-weight: 300;
  line-height: 1;
}
.modal-close:hover { background: #d0d0d0; color: #333; }
.modal-close--right { left: auto !important; right: 20px; }
#disclaimerModal .modal-close,
#loginModal .modal-close {
  background: rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.5);
  top: 8px;
  left: 8px;
}
#disclaimerModal .modal-close:hover,
#loginModal .modal-close:hover { background: rgba(255,255,255,0.3); color: rgba(255,255,255,0.8); }

.modal-back {
  display: none;
}

.modal-scroll {
  overflow-y: auto;
}

.modal-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 400px;
}

/* Modal gallery */
.modal-gallery {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  align-self: flex-start;
  position: relative;
}

.modal-thumbs {
  display: flex;
  flex-direction: row;
  gap: 6px;
  overflow-x: auto;
  padding: 8px 4px;
  justify-content: center;
}
.modal-thumbs::-webkit-scrollbar { width: 3px; }
.modal-thumbs::-webkit-scrollbar-thumb { background: #ccc; border-radius: 3px; }

.modal-thumb {
  width: 56px !important;
  height: 56px !important;
  object-fit: cover;
  border-radius: 10px;
  cursor: pointer;
  border: 2px solid transparent;
  opacity: 0.6;
  transition: opacity 0.2s, border-color 0.2s;
  display: block !important;
}
.modal-thumb.active {
  border-color: var(--primary);
  opacity: 1;
  box-shadow: 0 0 0 1px var(--primary);
}
.modal-thumb:hover { opacity: 1; }

.modal-main-photo {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 12px;
  background: #f0f0f0;
}

.modal-main-photo img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: none;
  object-fit: cover !important;
  border-radius: 12px;
}
.modal-main-photo img.active { display: block; }
.modal-store-logo {
  position: absolute;
  top: 8px;
  right: 8px;
  max-height: 56px;
  max-width: 120px;
  border-radius: 4px;
  background: #fff;
  padding: 5px 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,.15);
  z-index: 5;
  pointer-events: none;
  display: block !important;
  object-fit: contain !important;
}

.modal-fav-overlay {
  position: absolute;
  bottom: 10px;
  right: 10px;
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 6px;
}
.modal-views-counter {
  display: flex;
  align-items: center;
  gap: 3px;
  color: #fff;
  font-size: 13px;
  background: rgba(0,0,0,.35);
  border-radius: 12px;
  padding: 3px 8px;
}
.modal-fav-overlay .modal-fav-btn {
  background: rgba(0,0,0,.2);
  color: rgba(255,255,255,.8);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: all .2s;
}
.modal-fav-overlay .modal-fav-btn:hover { background: rgba(0,0,0,.35); }

.modal-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,.8);
  border: none;
  width: 36px; height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--black);
}
.modal-nav:hover { background: var(--white); }
.modal-nav--prev { left: 10px; }
.modal-nav--next { right: 10px; }

.modal-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
}
.modal-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: rgba(0,0,0,.3);
  cursor: pointer;
}
.modal-dot.active { background: var(--black); }

/* Modal info */
.modal-info {
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-family: inherit;
}

.modal-name-tg {
  font-size: 15px;
  font-weight: 400;
  color: var(--black);
  line-height: 1.3;
  text-transform: uppercase;
}

.modal-price {
  font-size: 20px;
  font-weight: 700;
  color: #0F1111;
}
.modal-price .price-converted {
  font-size: 20px;
  font-weight: 700;
}

.modal-condition {
  font-size: 14px;
  color: #565959;
}

.modal-desc-tg {
  margin: 4px 0;
  padding: 8px 12px;
  border-left: 3px solid var(--primary);
  background: #f9f9f9;
  font-size: 14px;
  line-height: 1.5;
  color: #333;
  border-radius: 0 6px 6px 0;
  white-space: pre-wrap;
}

.modal-location-block {
  background: #f5f5f5;
  border-radius: 10px;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.modal-location-line {
  font-size: 15px;
  color: var(--black);
  text-transform: uppercase;
}

.modal-info-card {
  background: transparent;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.modal-delivery-line {
  font-size: 13px;
  color: #0F1111;
}

.modal-category-line {
  font-size: 13px;
  color: #888;
}

.modal-actions-row {
  display: flex;
  gap: 8px;
  margin-top: 4px;
  flex-wrap: wrap;
}

.modal-action-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid #ddd;
  background: #fff;
  font-size: 13px;
  font-family: inherit;
  cursor: pointer;
  color: #444;
  flex: 1;
  transition: background 0.2s;
}
.modal-action-pill:hover { background: #f5f5f5; }
.modal-action-pill svg { flex-shrink: 0; }
.modal-action-pill--pin { background: transparent; border-color: #FFD814; color: #888; }
.modal-action-pill--pin:hover { background: rgba(255,216,20,0.08); }
.modal-action-pill--pinned { background: #FFD814; border-color: #FCD200; color: #666; }
.modal-action-pill--pinned:hover { background: #F7CA00; }

.admin-dropup {
  position: relative;
  display: inline-block;
}
.admin-dropup-menu {
  display: none;
  position: fixed;
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  padding: 6px 0;
  min-width: 200px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.18);
  z-index: 9000;
}
.admin-dropup-menu a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  color: #333;
  text-decoration: none;
  font-size: 13px;
  white-space: nowrap;
}
.admin-dropup-menu a svg {
  flex-shrink: 0;
  color: #888;
}
.admin-dropup-menu a:hover {
  background: #f5f5f5;
}
.admin-dropup-menu a:first-child {
  border-radius: 12px 12px 0 0;
}
.admin-dropup-menu a:last-child {
  border-radius: 0 0 12px 12px;
}
.admin-dropup.open .admin-dropup-menu {
  display: block;
}

.modal-name {
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 16px;
  line-height: 1.3;
}
.modal-item-id {
  font-size: 13px;
  color: var(--gray);
  font-weight: 400;
}

.modal-meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
  padding: 16px;
  background: var(--light);
  border-radius: var(--radius);
  font-size: 14px;
}

.modal-meta-row {
  display: flex;
  gap: 8px;
}
.modal-meta-label {
  color: var(--gray);
  min-width: 90px;
}

.modal-desc {
  font-size: 12px;
  font-weight: 400;
  line-height: 1.5;
  color: #888;
  margin-bottom: 8px;
  flex: 1;
}
.modal-desc.collapsed {
  max-height: 90px;
  overflow: hidden;
  position: relative;
}
.modal-desc.collapsed::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2em;
  background: linear-gradient(transparent, white);
  pointer-events: none;
}
.desc-toggle {
  background: none;
  border: none;
  color: #999;
  cursor: pointer;
  font-size: 13px;
  padding: 2px 0;
  font-weight: 400;
  margin-top: -16px;
  margin-bottom: 12px;
}

.modal-actions {
  display: flex;
  gap: 10px;
  margin-top: auto;
}

.modal-btn {
  flex: 1;
  padding: 10px 16px;
  border: none;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: opacity .2s;
}
.modal-btn:hover { opacity: .85; }
.modal-btn--primary {
  background: var(--brand-green);
  color: #fff;
  border: none;
}
.modal-btn--secondary {
  background: var(--brand-orange);
  color: #fff;
  border: none;
}
.modal-btn--seller {
  background: var(--brand-green);
  color: #fff;
  border: none;
}
.modal-btn--edit {
  background: #e8e8e8;
  color: #555;
  border: 1px solid #ddd;
  margin-top: 4px;
  padding: 10px 16px;
  flex: none;
  width: auto;
  align-self: flex-start;
}
.modal-btn--cancel {
  background: #e8e8e8;
  color: #555;
  border: 1px solid #ddd;
}
.modal-btn--danger {
  background: #d32f2f;
  color: #fff;
  border: 1px solid #c62828;
}
.modal-btn--accent {
  background: var(--brand-green);
  color: #fff;
}
.edit-actions--create {
  display: flex;
  gap: 8px;
  margin-bottom: 40px;
}
.edit-actions--create .modal-btn {
  flex: 1;
  font-size: 13px;
  padding: 14px 4px;
  white-space: nowrap;
}
.edit-actions--preview {
  display: flex;
  gap: 10px;
  padding: 16px 24px 24px;
}
.edit-actions--preview .modal-btn {
  flex: 1;
  font-size: 14px;
  padding: 14px 8px;
}
.modal-btn--outline {
  background: transparent;
  color: var(--brand-orange);
  border: 1px solid var(--brand-orange);
}
.modal-btn--outline:hover { background: var(--brand-orange); color: #fff; }
.edit-actions--3col { flex-wrap: wrap; }
.edit-actions--3col .modal-btn { flex: 1 1 auto; min-width: 120px; }

/* ===== FOOTER ===== */
.footer {
  border-top: 1px solid var(--border);
  margin-top: 60px;
  padding: 40px 20px 20px;
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  gap: 60px;
  margin-bottom: 30px;
}

.footer-col { display: flex; flex-direction: column; gap: 8px; }
.footer-logo {
  font-family: inherit;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0;
}
.footer-desc { font-size: 12px; color: var(--gray); font-family: inherit; }
.footer-col-title { font-size: 13px; font-weight: 700; color: var(--black); margin-bottom: 2px; }
.footer-col a { font-size: 13px; color: var(--gray); transition: color .2s; display: flex; align-items: center; gap: 6px; }
.footer-col a:hover { color: var(--black); }
.footer-icon { width: 16px; height: 16px; flex-shrink: 0; }
.footer-link { color: var(--black); text-decoration: underline; }
.footer-link:hover { color: var(--black); }

.footer-bottom {
  max-width: 1400px;
  margin: 0 auto;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: var(--gray);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
  .grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 992px) {
  .header-link span { display: none; }
  .filter-toggle { display: flex; }

  .sidebar {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 300px;
    height: 100%;
    background: var(--white);
    z-index: 200;
    padding: 20px;
    overflow-y: auto;
    box-shadow: 4px 0 20px rgba(0,0,0,.1);
  }
  .sidebar.open { display: block; }
  .sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border);
  }

  .layout { padding: 16px; gap: 0; }
  .grid { grid-template-columns: repeat(3, 1fr); }
  .modal-body { grid-template-columns: 1fr; }
  .modal-gallery { min-height: 300px; aspect-ratio: 1; overflow: hidden; }
  .modal-gallery .modal-thumb { height: 100%; object-fit: contain; }
}

.fab-add {
  display: flex;
  position: fixed;
  bottom: 24px;
  right: 24px;
  min-width: 145px;
  padding: 14px 20px;
  border-radius: 28px;
  justify-content: center;
  background: rgba(32, 107, 22, 0.55);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 4px 16px rgba(32, 107, 22, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  color: #fff;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  z-index: 1050;
  cursor: pointer;
  text-decoration: none;
}
.fab-add:hover { opacity: .9; }
.fab-add:active { transform: scale(.95); opacity: .85; }
.fab-help {
  display: flex;
  position: fixed;
  bottom: 24px;
  left: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,.45);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  backdrop-filter: blur(20px) saturate(1.8);
  border: 1px solid rgba(255,255,255,.6);
  box-shadow: 0 2px 12px rgba(0,0,0,.08), inset 0 1px 0 rgba(255,255,255,.5);
  color: #444;
  align-items: center;
  justify-content: center;
  z-index: 1050;
  cursor: pointer;
}
.fab-help--right { right: 16px; left: auto !important; }
.fab-add--hidden { display: none !important; }
body.modal-open { overflow: hidden; }

@media (max-width: 768px) {
  .header-inner { padding: 10px 16px; gap: 8px; flex-wrap: wrap; justify-content: space-between; }
  .logo-icon { width: 36px; height: 36px; }
  .logo-main { font-size: 18px; letter-spacing: 0; }
  .logo-sub { display: block; font-size: 9px; }
  .search-form { display: none !important; }
  .mobile-search-bar { display: flex !important; margin: 8px 16px; }
  .mobile-search-bar .search-input { flex: 1; padding: 8px 12px; border: 1px solid #ddd; border-radius: 20px; font-size: 14px; outline: none; }
  .mobile-search-bar .search-input:focus { border-color: var(--brand-green, #4caf50); }
  .mobile-search-bar .search-btn { background: none; border: none; margin-left: -36px; cursor: pointer; padding: 8px; }
  .deal-type-tabs { max-width: none; padding: 2px; flex: 1; justify-content: center; }
  .deal-type-tabs--desktop { display: none !important; }
  .deal-type-tab { padding: 4px 10px; font-size: 12px; }
  .categories-scroll { padding: 8px 16px; }
  .add-item-btn { display: none !important; }
  .header-link--messages { display: none !important; }
  .auth-area { margin-left: auto; gap: 8px; flex-wrap: nowrap; flex-shrink: 0; }
  .user-menu { order: 1; }
  .filter-toggle { display: none !important; }
  .header-link--notif { display: flex !important; }
  .user-menu { display: none !important; }
  .user-name { max-width: 80px; }
  .login-text { display: none; }
  .login-link { padding: 6px 8px !important; background: none !important; border: none !important; color: #888 !important; }

  html, body { overscroll-behavior-y: none; }
  body { padding-bottom: 80px; }

  /* Floating add button - mobile overrides */
  .fab-add {
    bottom: 90px;
    right: 16px;
  }
  .fab-help { bottom: 90px; left: 16px; }
  .fab-help:active { transform: scale(.9); opacity: .8; }
  #modal > .modal {
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .modal-close {
    position: absolute;
    top: 8px;
    left: 12px;
    font-size: 20px;
    line-height: 1;
    z-index: 100;
    background: #e0e0e0;
    color: #555;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
  }
  #modal > .modal > .modal-scroll {
    overflow-y: auto;
    flex: 1;
    padding-top: 44px;
    padding-bottom: 40px;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: contain;
  }
  .modal-back { display: none; }
  .modal-nav { display: none; }
  .footer { margin-top: 24px; padding: 24px 16px 80px; }
  .footer-inner { flex-direction: column; gap: 20px; margin-bottom: 16px; }
  .footer-bottom { font-size: 11px; }

  .layout { padding: 8px; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 1px; }
  .card { padding: 6px; }
  .card-price { font-size: 14px; }
  .card-name { font-size: 12px; }
}

@media (max-width: 480px) {
  .chip { padding: 6px 12px; font-size: 12px; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .modal { border-radius: 0; height: 100%; max-height: none; }
  .modal--search { border-radius: 16px; height: auto; max-height: none; }
  .modal--seller { border-radius: 20px; max-height: none; height: auto; }
  .modal--subscribe { border-radius: 16px; height: auto; max-height: none; }
  .modal--edit > .modal-close { color: #fff; }
  .modal--subscribe > .modal-close { color: #fff; }
  .modal-overlay { padding: 0; align-items: flex-start; }
  #searchModal.modal-overlay { padding: 20px; align-items: center; }
  #createModal.modal-overlay { padding: 0; align-items: flex-start; }
  #disclaimerModal.modal-overlay { padding: 20px; align-items: center; }
  #subscribeModal.modal-overlay { padding: 20px; align-items: center; }
  #sellerModal.modal-overlay { padding: 20px; }
  .modal-gallery { flex-direction: column; padding: 0; }
  .modal-thumbs {
    flex-direction: row;
    width: 100%;
    min-width: unset;
    max-height: none;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 8px 12px;
    justify-content: center;
    gap: 8px;
  }
  .modal-thumb { width: 48px !important; height: 48px !important; min-width: 48px; object-fit: cover !important; border-radius: 8px; }
  .modal-main-photo { width: 100%; min-width: unset; overflow: hidden; border-radius: 0; margin: 0; border: none; box-shadow: none; background: #f8f8f8; aspect-ratio: 1; position: relative; }
  .modal-main-photo img { position: absolute !important; top: 0; left: 0; width: 100% !important; height: 100% !important; object-fit: cover !important; border-radius: 0; display: none; }
  .modal-main-photo img.active { display: block; }
}

/* Sidebar overlay on mobile */
.sidebar-backdrop {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,.3);
  z-index: 199;
}
.sidebar-backdrop.open { display: block; }

/* ===== AUTH AREA ===== */
.auth-area {
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
}

.add-item-btn {
  display: inline-flex;
  align-items: center;
  padding: 7px 14px;
  background: var(--brand-green);
  color: #fff;
  border: none;
  border-radius: var(--radius-btn);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: background .2s;
}
.add-item-btn:hover { background: #1b5e20; }

.login-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--brand-green);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity .2s;
}
.login-btn:hover { opacity: .85; }


.user-menu { position: relative; }

.user-btn {
  display: flex;
  align-items: center;
  gap: 4px;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 7px 12px;
  font-size: 13px;
  cursor: pointer;
  color: var(--black);
  transition: border-color .2s;
}
.user-btn:hover { border-color: var(--black); }
.user-avatar { width: 22px; height: 22px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.user-avatar-fallback { flex-shrink: 0; color: var(--gray); }
.user-name { max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
.user-icon-mobile { display: none; }

.user-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 4px 12px rgba(0,0,0,.1);
  min-width: 140px;
  z-index: 110;
  overflow: hidden;
}
.user-dropdown.show { display: block; }
.user-dropdown a,
.user-dropdown button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 10px 14px;
  font-size: 13px;
  border: none;
  background: none;
  cursor: pointer;
  color: var(--black);
  transition: background .15s;
}
.user-dropdown a:hover,
.user-dropdown button:hover { background: var(--light); }

/* ===== CART BUTTON ON CARD PHOTO ===== */
.card-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
  gap: 4px;
}
.card-price-row .card-price { margin-bottom: 0; }
.card-img-actions {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  pointer-events: none;
  z-index: 4;
}
.cart-btn {
  position: absolute;
  bottom: 8px;
  right: 8px;
  pointer-events: auto;
  width: 28px;
  height: 28px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  color: #555;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
  padding: 0;
  z-index: 5;
}
.cart-btn:hover { background: rgba(255,255,255,.95); color: var(--brand-green, #43a047); }
.cart-btn--active { color: var(--brand-green, #43a047); }
/* ===== VIEWS COUNTER INLINE (price row) ===== */
.card-views-inline {
  display: flex;
  align-items: center;
  gap: 2px;
  color: #ccc;
  font-size: 11px;
  white-space: nowrap;
  flex-shrink: 0;
}
.modal-price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}
.modal-price-row .modal-price { margin-bottom: 0; }
.modal-views-inline {
  display: flex;
  align-items: center;
  gap: 3px;
  color: #bbb;
  font-size: 12px;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ===== MODAL ACTION BUTTONS ===== */
.modal-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.modal-fav-btn {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--white);
  color: #ccc;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
}
.modal-fav-btn:hover { color: var(--brand-green); border-color: var(--brand-green); }
.modal-edit-btn { color: var(--gray); text-decoration: none; }
.modal-edit-btn:hover { color: var(--brand-green); border-color: var(--brand-green); }
.modal-share-btn { color: var(--gray); }
.modal-share-btn:hover { color: var(--brand-green); border-color: var(--brand-green); }

/* Share sheet */
.share-overlay {
  position: fixed; inset: 0; z-index: 10001;
  background: rgba(0,0,0,0.4);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  animation: shareOverlayIn .2s ease;
}
@keyframes shareOverlayIn { from { opacity: 0; } to { opacity: 1; } }
.share-sheet {
  background: var(--white, #fff); border-radius: 16px;
  width: 100%; max-width: 340px; padding: 24px 20px;
  animation: shareOverlayIn .2s ease;
}
.share-sheet-title {
  text-align: center; font-size: 15px; font-weight: 600; color: #333;
  margin-bottom: 20px; font-family: inherit;
}
.share-sheet-buttons { display: flex; gap: 12px; justify-content: center; }
.share-sheet-btn {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 14px 18px; border-radius: 14px; border: 1px solid #e0e0e0;
  background: #f5f5f5; cursor: pointer; text-decoration: none;
  color: #222; font-size: 13px; font-family: inherit;
  transition: background .15s; flex: 1; min-width: 0;
}
.share-sheet-btn:hover { background: #eee; border-color: #ccc; }

.modal-btn--share {
  background: var(--white, #fff); border: 1px solid #ddd; color: #555;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-family: inherit;
}
.modal-btn--share:hover { background: #f5f5f5; border-color: #bbb; }

.modal-bump-btn { color: var(--gray); }
.modal-bump-btn:hover { color: var(--brand-orange); border-color: var(--brand-orange); }
.modal-unpublish-btn { color: var(--gray); }
.modal-unpublish-btn:hover { color: #d32f2f; border-color: #d32f2f; }

/* ===== MODAL SELLER LINK ===== */
.modal-seller {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  font-size: 14px;
}
.seller-link {
  color: var(--brand-green);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.seller-link:hover { color: #1b5e20; }

/* ===== SELLER PROFILE MODAL ===== */
.modal--seller {
  max-width: 600px;
  max-height: none;
  height: auto;
  border-radius: 20px;
  overflow: visible;
}
.modal-body--seller {
  max-height: 80vh;
  overflow-y: auto;
  padding: 48px 24px 24px;
  font-family: inherit;
}
.modal--oferta { max-width: 640px; max-height: 90vh; border-radius: 12px; }
.modal-body--oferta {
  display: block;
  max-height: 80vh;
  overflow-y: auto;
  padding: 48px 20px 30px;
  font-size: 14px;
  line-height: 1.75;
  color: #1d1d1f;
  font-family: inherit;
}
.modal-body--oferta::-webkit-scrollbar { width: 4px; }
.modal-body--oferta::-webkit-scrollbar-thumb { background: #d2d2d7; border-radius: 4px; }
.oferta-title {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 4px;
  color: #1d1d1f;
}
.oferta-subtitle {
  font-size: 15px;
  color: #86868b;
  margin-bottom: 32px;
}
.oferta-section {
  margin-bottom: 28px;
}
.oferta-section-title {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #86868b;
  margin-bottom: 12px;
}
.oferta-text {
  font-size: 14px;
  color: #1d1d1f;
  margin-bottom: 8px;
}
.oferta-list {
  list-style: none;
  padding: 0;
  margin: 8px 0 12px;
}
.oferta-list li {
  position: relative;
  padding-left: 16px;
  margin-bottom: 6px;
  color: #1d1d1f;
}
.oferta-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 9px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #86868b;
}
.oferta-divider {
  height: 1px;
  background: #d2d2d7;
  margin: 28px 0;
}
.modal-body--oferta a { color: #0066cc; text-decoration: none; }
.modal-body--oferta a:hover { text-decoration: underline; }
.oferta-date {
  font-size: 13px;
  color: #86868b;
  margin-top: 24px;
}
.modal-body--seller { display: block; padding: 48px 28px 32px; }

.seller-profile { }

.seller-header {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 24px;
}

.seller-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--brand-green);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 700;
  flex-shrink: 0;
}
.seller-avatar-img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.seller-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
  align-items: flex-start;
  margin-left: auto;
}
.seller-action-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #333;
  text-decoration: none;
  transition: background .2s;
}
.seller-action-btn:hover { background: #e0e0e0; }

.seller-info { flex: 1; min-width: 0; }

.seller-name {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.seller-badge {
  display: inline-block;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  background: #e8f5e9;
  color: var(--brand-green);
  border-radius: 10px;
}

.seller-username {
  font-size: 13px;
  color: var(--gray);
  margin-bottom: 6px;
}
.seller-contact-info {
  font-size: 13px;
  color: var(--gray);
  margin-bottom: 6px;
}

.seller-rating {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}
.seller-stars { color: #f9a825; font-size: 16px; letter-spacing: 1px; }
.seller-stars--interactive { cursor: pointer; }
.seller-stars--interactive .rating-star {
  color: #ddd;
  transition: color .15s, transform .15s;
  display: inline-block;
}
.seller-stars--interactive .rating-star--avg { color: #f9a825; }
.seller-stars--interactive .rating-star--active { color: #f57f17; }
.seller-stars--interactive .rating-star--hover { color: #ffb300; transform: scale(1.2); }
.seller-rating-text { font-size: 13px; color: var(--gray); }

.seller-stats {
  font-size: 13px;
  color: var(--gray);
}

.seller-contact {
  margin-bottom: 20px;
}
.seller-contact .modal-btn {
  width: 100%;
  text-decoration: none;
}
.seller-contact-buttons {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.seller-contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  flex: 1;
  justify-content: center;
  min-width: 0;
  transition: opacity 0.2s;
  color: #fff;
}
.seller-contact-btn svg { flex-shrink: 0; }
.seller-contact-btn:active { opacity: 0.7; }
.seller-contact-btn--tg { background: #2AABEE; }
.seller-contact-btn--phone { background: #bbb; }
.seller-contact-btn--wa { background: #25D366; }
.seller-contact-btn--app {
  background: transparent;
  border: 1px solid #e0e0e0;
  color: #999;
  font-weight: 400;
}

.seller-items-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.seller-items-grid {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 8px;
  scrollbar-width: none;
}
.seller-items-grid::-webkit-scrollbar { display: none; }

.seller-item {
  flex-shrink: 0;
  width: 130px;
  cursor: pointer;
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,.06);
  scroll-snap-align: start;
}

.seller-item-photo {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--light);
}

.seller-item-no-photo {
  width: 100%;
  aspect-ratio: 1;
  background: var(--light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray);
  font-size: 11px;
}

.seller-item-info {
  padding: 6px 8px;
}

.seller-item-price {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.seller-item-name {
  font-size: 11px;
  color: var(--gray);
  margin-top: 2px;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.seller-item--draft {
  opacity: 0.7;
  position: relative;
}

/* ===== SELLER REPORT ===== */
.report-link {
  color: var(--gray);
  cursor: pointer;
  text-decoration: underline;
}
.report-link:hover { color: var(--black); }

.report-inactive-link {
  font-size: 12px;
  color: #bbb;
  text-decoration: underline;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.report-inactive-link:active { color: #999; }
.report-inactive-done {
  color: #27ae60;
  text-decoration: none;
  pointer-events: none;
}

.report-form {
  padding: 8px 0;
}
.report-form-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 16px;
}
.report-form-textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 12px;
  font-size: 14px;
  font-family: inherit;
  resize: vertical;
  min-height: 80px;
  margin-bottom: 12px;
}
.report-form-textarea:focus {
  outline: none;
  border-color: var(--gray);
}
.report-form-file {
  display: block;
  margin-bottom: 12px;
  cursor: pointer;
}
.report-form-file input[type="file"] {
  display: none;
}
.report-form-file span {
  font-size: 13px;
  color: var(--gray);
}
.report-form-file:hover span {
  color: var(--black);
}
.report-preview-img {
  max-width: 100%;
  max-height: 160px;
  border-radius: var(--radius);
  margin-bottom: 12px;
}
.report-form-actions {
  display: flex;
  gap: 12px;
  margin-top: 12px;
  margin-bottom: 8px;
}
.report-form-actions .modal-btn {
  flex: 1;
}

/* ===== REVIEWS LIST ===== */
.reviews-list {
  max-height: 300px;
  overflow-y: auto;
  margin-bottom: 16px;
}
.review-item {
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.review-item:last-child { border-bottom: none; }
.review-item-stars { font-size: 14px; margin-bottom: 4px; }
.review-item-text { font-size: 14px; font-style: italic; color: var(--text-primary); }
.review-item-author { font-size: 12px; color: var(--text-secondary); margin-top: 4px; }
.review-empty { text-align: center; color: var(--text-secondary); padding: 20px 0; font-size: 14px; }

/* ===== REVIEW STARS ===== */
.review-stars-row {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 12px 0 4px;
}
.review-star {
  font-size: 32px;
  color: #ccc;
  cursor: pointer;
  transition: color 0.15s, transform 0.15s;
  user-select: none;
}
.review-star:hover,
.review-star--active {
  color: #f9a825;
  transform: scale(1.15);
}
.review-stars-hint {
  text-align: center;
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 12px;
  min-height: 20px;
}

/* ===== RECOMMENDED ITEMS ===== */
#modalRecommended {
  padding: 0 28px 24px;
}

.rec-title {
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  margin-bottom: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.rec-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
}

.rec-item {
  cursor: pointer;
  transition: opacity .2s;
}
.rec-item:hover { opacity: .8; }

.rec-item-photo {
  width: 100%;
  aspect-ratio: 4/5;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 4px;
  background: var(--light);
  filter: grayscale(100%);
  transition: filter 0.3s;
}
.rec-item:hover .rec-item-photo { filter: grayscale(0%); }
.rec-item--promo { position: relative; }
.rec-item--promo .rec-item-photo { filter: none; }

.rec-item-no-photo {
  width: 100%;
  aspect-ratio: 1;
  background: var(--light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray);
  font-size: 12px;
  margin-bottom: 6px;
}

.rec-item-price {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.rec-item-name {
  font-size: 12px;
  color: var(--black);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.rec-item-city {
  font-size: 11px;
  color: var(--gray);
}

@media (max-width: 480px) {
  #modalRecommended { padding: 0 16px 20px; }
  .rec-grid { grid-template-columns: repeat(3, 1fr); gap: 6px; }
}

/* ===== LOGIN TOAST ===== */
.login-toast {
  position: fixed;
  bottom: -60px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--black);
  color: var(--white);
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 14px;
  z-index: 2000;
  transition: bottom .3s ease;
  white-space: nowrap;
}
.login-toast.show { bottom: 24px; }

/* ===== CONTENT FULL WIDTH ===== */
.content--full { max-width: 1200px; margin: 0 auto; flex: 1; min-width: 0; width: 100%; }

.my-rating-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-weight: 500;
  color: #1d1d1f;
  white-space: nowrap;
}

/* ===== PROFILE SECTION ===== */
.profile-section { padding: 16px 16px 0; max-width: 1200px; margin: 0 auto; width: 100%; box-sizing: border-box; }
.profile-contact-row { display: flex; align-items: center; gap: 6px; margin-top: 4px; font-size: 14px; }
.profile-contact-label { color: var(--gray); font-size: 13px; }
.profile-contact-value { font-size: 14px; }
.profile-contact-edit-btn { background: none; border: none; color: var(--gray); cursor: pointer; font-size: 14px; padding: 0 4px; }
.profile-contact-input { border: 1px solid var(--border); border-radius: var(--radius); padding: 4px 8px; font-size: 14px; width: 180px; }

/* ===== DRAFTS TOP SECTION ===== */
.drafts-top-section {
  max-width: 1200px; margin: 0 auto; padding: 12px 16px 0;
  box-sizing: border-box; width: 100%;
}
.drafts-top-title {
  font-size: 15px; font-weight: 600; margin-bottom: 10px;
  color: var(--brand-orange);
}
.drafts-top-grid {
  display: flex; gap: 10px; overflow-x: auto;
  scrollbar-width: none; -ms-overflow-style: none;
}
.drafts-top-grid::-webkit-scrollbar { display: none; }
.drafts-top-card {
  position: relative; flex: 0 0 100px; cursor: pointer;
  opacity: 0.8; transition: opacity .2s;
}
.drafts-top-card:hover { opacity: 1; }
.drafts-top-photo {
  width: 100px; height: 100px; object-fit: cover;
  border-radius: var(--radius); background: var(--light);
}
.drafts-top-no-photo {
  width: 100px; height: 100px; background: var(--light);
  border-radius: var(--radius); display: flex;
  align-items: center; justify-content: center;
  color: var(--gray); font-size: 12px;
}
.drafts-top-card .card-badge--draft {
  position: absolute; top: 4px; left: 4px;
  font-size: 9px; padding: 1px 5px;
}
.drafts-top-img {
  position: relative;
}
.drafts-top-name {
  font-size: 11px; margin-top: 4px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  max-width: 100px; cursor: pointer;
}
.drafts-top-delete {
  position: absolute; top: 2px; right: 2px;
  width: 20px; height: 20px; border-radius: 50%;
  background: rgba(0,0,0,.5); color: #fff;
  border: none; font-size: 12px; line-height: 20px;
  text-align: center; cursor: pointer; padding: 0;
  z-index: 2;
}
.drafts-top-delete:hover { background: #d32f2f; }

/* ===== MY ITEMS PAGE ===== */
.my-items-tabs {
  display: flex;
  background: #f0f0f0;
  border-radius: 10px;
  padding: 3px;
  margin: 0 16px 16px;
}
.my-items-tab {
  flex: 1;
  padding: 9px 8px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  color: #666;
  text-align: center;
  transition: all .2s;
}
.my-items-tab--active {
  background: #fff;
  color: #1d1d1f;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0,0,0,.1);
}

/* eBay-style horizontal cards for my-items */
.my-items-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 480px;
}
.my-item-card {
  background: #fff;
  border-radius: 12px;
  overflow: visible;
  border: 1px solid rgba(0,0,0,.06);
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
}
.my-item-top {
  display: flex;
  flex-direction: row;
  cursor: pointer;
  border-radius: 12px 12px 0 0;
  overflow: hidden;
}
.my-item-card .card-img-wrap {
  flex-shrink: 0;
  width: 100px;
  height: 100px;
  position: relative;
  overflow: hidden;
}
.my-item-card .card-img-wrap img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  max-width: 100px;
}
.my-item-card .card-img-wrap .card-badge {
  position: absolute;
  top: 4px;
  left: 4px;
  font-size: 9px;
  padding: 2px 6px;
}
.my-item-card .my-item-info {
  flex: 1;
  min-width: 0;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
}
.my-item-card .my-item-name {
  font-size: 13px;
  font-weight: 500;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--black);
}
.my-item-card .my-item-price {
  font-size: 15px;
  font-weight: 700;
}
.my-item-card .my-item-price .price-old {
  font-size: 12px;
  font-weight: 400;
  text-decoration: line-through;
  color: var(--gray);
  margin-right: 4px;
}
.my-item-card .my-item-meta {
  font-size: 11px;
  color: var(--gray);
}
.my-item-status-line {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
}
.my-item-card .my-item-status {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  text-align: center;
}
.my-item-status--active { background: #e8f5e9; color: #2e7d32; }
.my-item-status--stale { background: rgba(211,47,47,.1); color: #b71c1c; }
.my-item-status--draft { background: #fff3e0; color: #e65100; }
.my-item-status--moderation { background: #e3f2fd; color: #1565c0; }
.my-item-status--sold { background: #f5f5f5; color: #757575; }
.my-item-status--promo { background: #fff8e1; color: #f57f17; }
.my-item-card .card { display: none; }
.my-item-date {
  font-size: 10px;
  color: #aaa;
  font-style: italic;
}
.my-item-views {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  color: #999;
  margin-left: auto;
}
/* Action buttons bar */
.my-item-actions-bar {
  display: flex;
  gap: 6px;
  padding: 6px 10px 8px;
  flex-wrap: wrap;
}
.mi-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 5px 10px;
  border-radius: 20px;
  border: 1px solid #ddd;
  background: #fff;
  font-size: 11px;
  font-family: inherit;
  cursor: pointer;
  color: #444;
  white-space: nowrap;
  transition: background .2s;
}
.mi-btn:active { background: #f0f0f0; }
.mi-btn svg { flex-shrink: 0; }
.mi-btn--bump { color: var(--brand-green, #2e7d32); border-color: var(--brand-green, #2e7d32); }
.mi-btn--pin { background: #FFD814; border-color: #FCD200; color: #333; }
.mi-btn--pin-outline { background: transparent; border-color: #FFD814; color: #666; }
.mi-btn--edit { color: #444; }
.mi-btn--unpublish { color: #b71c1c; border-color: #e0b0b0; }

.card-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 5;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .3px;
}
.card-badge--draft {
  background: var(--brand-orange);
  color: #fff;
}
.card-edit-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,.75);
  color: var(--black);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
}
.card-edit-btn:hover { background: rgba(255,255,255,.9); }

.my-item-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 10px 10px;
}

.my-item-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all .2s;
  color: var(--black);
}
.my-item-btn:hover { border-color: var(--black); }
.my-item-btn:disabled { opacity: .5; cursor: not-allowed; }

.my-item-btn--bump {
  border-color: var(--brand-green);
  color: var(--brand-green);
}
.my-item-btn--bump:hover { background: var(--brand-green); color: #fff; }

.my-item-btn--unpublish {
  border-color: #b71c1c;
  color: #b71c1c;
}
.my-item-btn--unpublish:hover { background: #b71c1c; color: #fff; }

.my-item-btn--edit {
  flex: 0 0 auto;
  border-color: #555;
  color: #555;
  padding: 8px 10px;
}
.my-item-btn--edit:hover { background: #555; color: #fff; }

.my-item-btn--republish {
  border-color: var(--brand-green);
  color: var(--brand-green);
}
.my-item-btn--republish:hover { background: var(--brand-green); color: #fff; }

/* ===== LOGOUT ===== */
.logout-section {
  text-align: center;
  padding: 24px 16px 16px;
}
.logout-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: none;
  color: var(--gray);
  font-size: 14px;
  cursor: pointer;
}
.logout-btn:hover { color: var(--black); border-color: var(--black); }

/* ===== EDIT MODAL ===== */
.modal--edit { max-width: 560px; }
.modal-body--edit {
  display: block;
  padding: 44px 28px 24px;
  min-height: auto;
}

.edit-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 20px;
}

.edit-row {
  margin-bottom: 14px;
}

.edit-row-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.edit-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: .3px;
  margin-bottom: 4px;
}

/* Toggle buttons for edit form */
.edit-toggle {
  display: flex;
  background: #f0f0f0;
  border-radius: 8px;
  padding: 2px;
  gap: 2px;
}
.edit-toggle-btn {
  flex: 1;
  padding: 6px 4px;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  color: #999;
  background: transparent;
  cursor: pointer;
  transition: all .2s;
}
.edit-toggle-btn.active {
  background: #fff;
  color: var(--black);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0,0,0,.1);
}
/* Deal type colored toggles */
.edit-toggle--deal .edit-toggle-btn--sell.active {
  background: var(--brand-green);
  color: #fff;
}
.edit-toggle--deal .edit-toggle-btn--rent.active {
  background: var(--brand-orange);
  color: #fff;
}
/* Currency toggle under price input */
.edit-toggle--currency {
  padding: 1px;
}
.edit-toggle--currency .edit-toggle-btn {
  font-size: 13px;
  padding: 2px 6px;
}

.edit-input {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  font-family: inherit;
  outline: none;
  background: var(--white);
  transition: border-color .2s;
}
.edit-input:focus { border-color: var(--black); }

.edit-textarea {
  resize: vertical;
  min-height: 80px;
}

.edit-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}
.edit-actions .modal-btn { flex: 1; }

/* Edit photos grid */
.edit-photos-grid {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.edit-photo-slot {
  width: 72px;
  height: 72px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
}
.edit-photo-slot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: var(--radius);
}
.edit-photo-slot--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  color: #999;
  font-size: 24px;
}
.edit-photo-slot--loading {
  opacity: .5;
  pointer-events: none;
}
.edit-photo-slot--loading::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,.6);
}
.edit-photo-slot--primary { outline: 2px solid var(--accent); outline-offset: -2px; }
.edit-photo-primary-badge {
  position: absolute; top: 2px; left: 2px;
  background: var(--accent); color: #fff;
  width: 18px; height: 18px; border-radius: 50%;
  font-size: 11px; line-height: 18px; text-align: center;
  pointer-events: none;
}
.edit-photo-menu {
  position: absolute; bottom: -4px; left: 50%; transform: translate(-50%, 100%);
  background: #fff; border-radius: 8px; box-shadow: 0 2px 12px rgba(0,0,0,.18);
  z-index: 100; min-width: 160px; overflow: hidden;
}
.edit-photo-menu-btn {
  display: block; width: 100%; padding: 10px 14px;
  border: none; background: none; text-align: left;
  font-size: 14px; cursor: pointer; white-space: nowrap;
}
.edit-photo-menu-btn:active { background: #f5f5f5; }
.edit-photo-num-badge {
  position: absolute; top: 2px; left: 2px;
  background: rgba(0,0,0,0.5); color: #fff;
  width: 18px; height: 18px; border-radius: 50%;
  font-size: 11px; line-height: 18px; text-align: center;
  pointer-events: none;
}
.edit-photo-num-badge--primary {
  background: var(--accent);
}
.edit-photo-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(0,0,0,0.5); color: #fff;
  border: none; font-size: 10px; line-height: 22px; text-align: center;
  cursor: pointer; padding: 0; z-index: 5;
}
.edit-photo-arrow:active { background: rgba(0,0,0,0.8); }
.edit-photo-arrow--left { left: 2px; }
.edit-photo-arrow--right { right: 2px; }
.edit-photo-slot[draggable="true"] { cursor: pointer; }
.edit-photo-slot.dragging { opacity: 0.4; transform: scale(0.95); }
.edit-photo-slot.drag-over { outline: 2px solid var(--accent); outline-offset: -2px; }
.edit-photo-drag-clone {
  position: fixed;
  z-index: 99999;
  pointer-events: none;
  opacity: 0.85;
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  transform: scale(1.1);
}

/* ===== CREATE ITEM: AI SUGGEST BUTTONS ===== */
.edit-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}
.edit-label-row .edit-label {
  margin-bottom: 0;
}
.ai-suggest-btn {
  background: none;
  border: none;
  color: var(--brand-green);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  transition: color .2s;
  white-space: nowrap;
}
.ai-suggest-btn:hover { color: #1b5e20; }
.ai-suggest-btn:disabled { color: var(--gray); cursor: wait; }
.ai-recognize-btn {
  font-size: 13px;
  padding: 8px 18px;
  border: 1px solid #ddd;
  border-radius: 20px;
  background: #fff;
  color: #444;
  font-family: inherit;
}
.ai-recognize-btn:hover { background: #f5f5f5; }
.create-photos-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
  flex-wrap: wrap;
}

/* ===== CREATE ITEM PHOTOS ===== */
.create-photos-grid {
  display: flex;
  gap: 8px;
  margin-top: 8px;
  flex-wrap: wrap;
}
.create-photo-thumb {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

/* ===== RESPONSIVE ADDITIONS ===== */
@media (max-width: 768px) {
  .auth-area { gap: 8px; }
  .user-name { max-width: 80px; }
  .seller-items-grid { gap: 8px; }
}

@media (max-width: 480px) {
  .login-btn span { display: none; }
  .seller-items-grid { gap: 8px; }
  .seller-item { width: 110px; }
  .edit-row-2col { grid-template-columns: 1fr; gap: 0; }
  .modal,
  #modal > .modal {
    border-radius: 0;
    max-height: 100vh;
  }
  #modal > .modal > .modal-close {
    top: calc(env(safe-area-inset-top, 4px) + 4px);
  }
  .modal--seller {
    border-radius: 20px;
    max-height: none;
    height: auto;
    display: block;
    overflow: visible;
  }
  .modal--seller > .modal-close {
    top: 12px;
    left: 16px;
  }
}

/* ===== NOTIFICATION BELL ===== */
.header-link--notif {
  position: relative;
  color: var(--gray);
  transition: color .2s;
}
.header-link--notif:hover { color: var(--black); }
.header-link--notif-active { color: var(--black); }

.notif-badge {
  position: absolute;
  top: -4px;
  right: -6px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 8px;
  background: #d32f2f;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
}

/* ===== NOTIFICATIONS LIST ===== */
.notif-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.notif-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: background .15s;
}

.notif-item--unread {
  background: #f0f7ff;
  border-color: #c8ddf5;
}

.notif-icon {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--light);
  display: flex;
  align-items: center;
  justify-content: center;
}

.notif-item--unread .notif-icon {
  background: #dce8f7;
}

.notif-content {
  flex: 1;
  min-width: 0;
  cursor: pointer;
}

.notif-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
  line-height: 1.3;
}

.notif-message {
  font-size: 13px;
  color: #555;
  line-height: 1.4;
  margin-bottom: 4px;
}

.notif-date {
  font-size: 12px;
  color: var(--gray);
}

.notif-mark-btn {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--white);
  color: var(--gray);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
}
.notif-mark-btn:hover {
  border-color: var(--brand-green);
  color: var(--brand-green);
  background: #e8f5e9;
}

.notif-read-all-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  color: var(--black);
  transition: all .2s;
}
.notif-read-all-btn:hover {
  border-color: var(--black);
  background: var(--light);
}

@media (max-width: 480px) {
  .notif-item { padding: 10px 12px; gap: 10px; }
  .notif-title { font-size: 13px; }
  .notif-message { font-size: 12px; }
}

/* ===== NOTIFICATION MODAL BUTTONS ===== */
.notif-modal-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  color: var(--black);
  transition: all .2s;
}
.notif-modal-btn:hover { border-color: var(--black); background: var(--light); }
.notif-modal-btn--danger { color: #d32f2f; border-color: #d32f2f; }
.notif-modal-btn--danger:hover { background: #ffeef0; }

/* ===== SEARCH MODAL ===== */
.modal--search {
  max-width: 400px;
  border-radius: 16px;
  height: auto;
  max-height: none;
  overflow: hidden;
}
.search-modal-label {
  font-size: 16px;
  font-weight: 600;
  margin-top: 12px;
  margin-bottom: 4px;
  text-align: center;
}
.search-modal-hint {
  font-size: 12px;
  color: var(--gray);
  text-align: center;
  margin-bottom: 14px;
}
.search-modal-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 24px;
}
.search-modal-input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 16px;
  outline: none;
  box-sizing: border-box;
}
.search-modal-input:focus {
  border-color: var(--green);
}
.search-modal-actions {
  display: flex;
  gap: 8px;
}
.search-modal-actions .modal-btn {
  flex: 1;
}

/* ===== MESSAGES MODAL FIX ===== */
#messagesModal.modal-overlay {
  padding: 16px;
  align-items: flex-start;
}
#messagesModal .modal--seller {
  margin-top: 40px;
  overflow: hidden;
}
#messagesModal .modal-body--seller {
  padding-top: 56px;
  padding-left: 20px;
  padding-right: 20px;
}
#messagesModal .modal-close {
  top: 12px;
  left: 12px;
  right: auto;
}
#filterModal.modal-overlay {
  padding: 16px;
  align-items: flex-start;
}
#filterModal .modal--seller {
  margin-top: 40px;
}
#filterModal .modal-body--seller {
  padding-top: 52px;
}
#searchModal .modal--search {
  padding-top: 12px;
}

/* ===== SUBSCRIBE MODAL ===== */
.modal--subscribe { max-width: 380px; border-radius: 16px; overflow: hidden; }
.modal-body--subscribe {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0;
  min-height: auto;
}
.subscribe-header {
  width: 100%;
  background: linear-gradient(135deg, var(--brand-green) 0%, #43a047 100%);
  padding: 32px 28px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.subscribe-logo {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(255,255,255,.3);
  margin-bottom: 12px;
}
.subscribe-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 0;
  color: #fff;
}
.subscribe-body {
  padding: 20px 28px 24px;
}
.subscribe-text {
  font-size: 14px;
  color: #555;
  margin-bottom: 20px;
  line-height: 1.5;
}
.subscribe-actions {
  display: flex;
  gap: 10px;
  width: 100%;
}
.subscribe-actions .modal-btn { flex: 1; text-decoration: none; border-radius: 8px; padding: 12px 16px; font-size: 14px; }
.modal-btn--subscribe {
  background: var(--brand-green);
  color: #fff;
  border: none;
}
.modal-btn--subscribe:hover { background: #1b5e20; }
.push-perm-icon {
  font-size: 40px;
  margin-bottom: 8px;
}
.push-perm-list {
  margin: 8px 0 0 0;
  padding-left: 18px;
  text-align: left;
  font-size: 13px;
  color: #555;
  line-height: 1.6;
}
.subscribe-btn {
  display: block;
  background: var(--brand-green);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.subscribe-btn:hover { opacity: .9; }

/* ===== BOTTOM NAV INLINE SEARCH ===== */
.bottom-nav-items {
  display: flex;
  align-items: center;
  justify-content: space-around;
  width: 100%;
}
.bottom-nav-search {
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  padding: 6px 12px;
  gap: 4px;
}
.bottom-nav-search-label {
  font-size: 12px;
  color: #999;
  text-align: center;
}
.bottom-nav-search-form {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}
.bottom-nav-search-input {
  flex: 1;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 12px;
  font-size: 16px;
  outline: none;
  background: var(--white);
}
.bottom-nav-search-input:focus {
  border-color: var(--black);
}
.bottom-nav-search-submit {
  background: none;
  border: none;
  color: var(--brand-green);
  cursor: pointer;
  padding: 6px;
  display: flex;
  align-items: center;
}
.bottom-nav-search-cancel {
  background: none;
  border: none;
  color: #999;
  font-size: 13px;
  cursor: pointer;
  white-space: nowrap;
  padding: 6px 0;
}

/* ===== BOTTOM NAVIGATION (mobile) ===== */
.bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: auto;
  padding-bottom: env(safe-area-inset-bottom, 12px);
  background: var(--white);
  border-top: 1px solid var(--border);
  z-index: 999;
  align-items: center;
  justify-content: space-around;
  /* iOS PWA fix: force GPU compositing layer to prevent tap events being lost after scroll */
  -webkit-transform: translate3d(0, 0, 0);
  transform: translateZ(0);
  will-change: transform;
}

.bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  flex: 1;
  padding: 6px 0 4px;
  color: #999;
  position: relative;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 9px;
  font-weight: 500;
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: none;
  position: relative;
  -webkit-tap-highlight-color: transparent;
  transition: opacity 0.1s;
}
.bottom-nav-item:active {
  opacity: 0.5;
}

.bottom-nav-item--active {
  color: var(--brand-green);
  font-weight: 700;
}
.bottom-nav-item--sell.bottom-nav-item--active {
  color: var(--brand-green);
}
.bottom-nav-item--sell.bottom-nav-item--active svg { stroke-width: 2.8; }
.bottom-nav-item--rent.bottom-nav-item--active {
  color: var(--brand-orange);
}
.bottom-nav-item--rent.bottom-nav-item--active svg { stroke-width: 2.8; }

.bottom-nav-icon {
  width: 24px;
  height: 24px;
}
.bottom-nav-item--home.bottom-nav-item--active svg {
  stroke: var(--brand-green);
  stroke-width: 2.2;
}
.bottom-nav-home-label {
  font-size: 9px;
  font-weight: 400;
  letter-spacing: -0.3px;
  margin-top: 1px;
}
.bottom-nav-item--active .bottom-nav-home-label {
  font-weight: 700;
}

/* Nav loading overlay — instant feedback on page switch */
.nav-loading-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(255,255,255,0.85);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: navFadeIn 0.15s ease;
}
@keyframes navFadeIn { from { opacity: 0; } to { opacity: 1; } }
.nav-loading-spinner {
  width: 28px;
  height: 28px;
  border: 3px solid #e8e8e8;
  border-top-color: var(--brand-green);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

.bottom-nav-icon--img {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
}

.bottom-nav-item--active .bottom-nav-icon--img {
  box-shadow: none;
}

.bottom-nav-icon--avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
}

.bottom-nav-item--active .bottom-nav-icon--avatar {
  box-shadow: 0 0 0 2px var(--brand-green);
}

.login-link {
  display: inline-block;
  padding: 6px 16px;
  background: none;
  color: #888;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.bottom-nav-badge,
.bottom-nav-item .notif-badge {
  position: absolute;
  top: -2px;
  right: -4px;
  min-width: 14px;
  height: 14px;
  padding: 0 3px;
  border-radius: 7px;
  background: #d32f2f;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
}

@media (max-width: 768px) {
  .bottom-nav { display: flex; }
}

/* ===== BOOKING SYSTEM ===== */

/* Card booking badges - left bottom on photo */
.card-booking-badges {
  position: absolute;
  bottom: 8px;
  left: 8px;
  z-index: 5;
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
}
.card-booking-label,
.card-booking-date {
  color: #fff;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 10px;
  text-align: center;
  white-space: nowrap;
}
.card-booking-label {
  background: var(--brand-orange);
  font-weight: 600;
}
.card-booking-date {
  background: rgba(0,0,0,0.55);
  font-weight: 400;
}

/* Booking button */
.modal-btn--booking {
  background: var(--brand-orange);
  color: #fff;
  width: 100%;
}
.modal-actions--booking {
  display: flex;
  margin-bottom: 6px;
}

/* Booking badges overlay on gallery */
.booking-badges-overlay {
  position: absolute;
  bottom: 52px;
  right: 8px;
  z-index: 5;
  display: inline-flex;
  flex-direction: column;
  gap: 3px;
  pointer-events: none;
}
.booking-label,
.booking-date {
  color: #fff;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11px;
  text-align: center;
  white-space: nowrap;
}
.booking-label {
  background: var(--brand-orange);
  font-weight: 600;
}
.booking-date {
  background: rgba(0,0,0,0.55);
  font-weight: 400;
}

/* Pending bookings for owner */
.pending-bookings-title {
  font-size: 13px;
  font-weight: 600;
  margin: 12px 0 6px;
  color: #333;
}
.pending-booking-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 13px;
  border-bottom: 1px solid var(--border);
}
.pending-booking-row span:first-child { flex: 1; }
.pending-booking-btn {
  border: none;
  background: none;
  font-size: 18px;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
}
.pending-booking-btn:hover { background: #f0f0f0; }

/* Booking modal */
#bookingModal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 10001;
  background: rgba(0,0,0,.45);
  justify-content: center;
  align-items: flex-start;
  padding: 40px 16px;
  overflow-y: auto;
}
#bookingModal.open { display: flex; }

.booking-modal {
  background: #fff;
  border-radius: 14px;
  max-width: 420px;
  width: 100%;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  position: relative;
}
.booking-modal-header {
  padding: 16px 20px;
  font-size: 16px;
  font-weight: 700;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.booking-modal-body {
  padding: 12px 16px 16px;
  overflow-y: auto;
  flex: 1;
}
.booking-modal-footer {
  padding: 12px 16px 16px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
}
#bookingSelectedInfo {
  font-size: 13px;
  color: #666;
}
#bookingSubmitBtn {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 8px;
  background: var(--brand-orange);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
#bookingSubmitBtn:disabled {
  background: #ccc;
  cursor: default;
}

/* Calendar */
.cal-month { margin-bottom: 16px; }
.cal-month-title {
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 6px;
  color: #333;
}
.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  font-size: 11px;
  color: #999;
  margin-bottom: 4px;
}
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  justify-items: center;
}
.cal-day {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  cursor: pointer;
  transition: background 0.15s;
  user-select: none;
}
.cal-day:hover:not(.cal-day--past):not(.cal-day--booked):not(.cal-day--pending):not(.cal-day--empty):not(.cal-day--selected):not(.cal-day--range) {
  background: #f5f5f5;
}
.cal-day--empty { cursor: default; }
.cal-day--past { color: #ccc; cursor: default; }
.cal-day--booked { background: #e0e0e0; color: #999; cursor: default; }
.cal-day--pending { background: #fff3e0; color: var(--brand-orange); cursor: default; }
.cal-day--selected { background: var(--brand-orange); color: #fff; }
.cal-day--range { background: rgba(230, 81, 0, 0.15); }
.cal-day--today { font-weight: 700; }

@media (max-width: 420px) {
  .cal-day { width: 32px; height: 32px; font-size: 12px; }
}

/* ===== VARIANTS (SIZE/COLOR BUTTONS) ===== */
.modal-variants {
  margin: 10px 0;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.modal-variants-label {
  font-size: 13px;
  color: #888;
  font-weight: 700;
}
.modal-variants-btns {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.modal-variant-info { margin-top: 4px; min-height: 16px; }
.variant-btn {
  padding: 6px 14px;
  border: 1.5px solid #ddd;
  border-radius: 8px;
  background: #fff;
  color: #333;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s;
}
.variant-btn:hover {
  border-color: var(--brand-orange);
}
.variant-btn--active {
  border-color: var(--brand-orange);
  background: var(--brand-orange);
  color: #fff;
}
.variant-btn--disabled {
  border-color: #eee;
  background: #f5f5f5;
  color: #bbb;
  cursor: default;
  text-decoration: line-through;
}
.variant-btn--disabled:hover {
  border-color: #eee;
}

/* ===== DISCOUNT PRICE ===== */
.modal-price-old {
  text-decoration: line-through;
  color: #999;
  font-size: 0.85em;
  font-weight: 400;
}
.modal-price-discount {
  color: var(--price);
  font-weight: 700;
}
.card-price-old {
  text-decoration: line-through;
  color: #999;
  font-size: 0.8em;
  font-weight: 400;
  margin-right: 4px;
}
.card-price-discount {
  color: var(--price);
  font-weight: 700;
}

/* ===== OUT OF STOCK ===== */
.modal-out-of-stock {
  background: #f8d7da;
  color: #721c24;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  margin: 6px 0;
  display: inline-block;
}
.modal-btn--disabled {
  background: #e0e0e0;
  color: #999;
  cursor: default;
  padding: 12px 16px;
  border-radius: 10px;
  border: none;
  font-size: 14px;
  font-weight: 700;
  width: 100%;
}
.card-badge-outofstock {
  position: absolute;
  top: 6px;
  right: 6px;
  background: rgba(220,53,69,0.9);
  color: #fff;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
}
.new-condition-badge {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: rgba(34, 139, 34, 0.88);
  color: #fff;
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 4px;
  z-index: 5;
}
.discount-badge ~ .new-condition-badge { bottom: 36px; }
.card-store-logo {
  position: absolute;
  top: 8px;
  right: 8px;
  max-height: 35px;
  max-width: 75px;
  border-radius: 4px;
  background: #fff;
  padding: 3px 5px;
  box-shadow: 0 1px 3px rgba(0,0,0,.15);
  z-index: 5;
  pointer-events: none;
}
.modal-views-badge {
  position: absolute;
  bottom: 8px;
  right: 8px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 3px;
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: #333;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 6px;
  border-radius: 4px;
  pointer-events: none;
  line-height: 1;
}
.card-views-badge {
  position: absolute;
  bottom: 8px;
  right: 8px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 3px;
  background: rgba(255,255,255,.3);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 6px;
  border-radius: 4px;
  pointer-events: none;
  line-height: 1;
}

/* ===== CART ===== */
.modal--cart { max-width: 500px; }
.cart-title {
  font-size: 18px;
  font-weight: 600;
  padding: 16px 20px 8px;
  margin: 0;
}
.cart-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--gray);
  font-size: 15px;
}
.cart-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 20px;
  border-bottom: 1px solid var(--border);
}
.cart-item-photo {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  background: #f0f0f0 center / cover no-repeat;
  flex-shrink: 0;
  cursor: pointer;
}
.cart-item-info {
  flex: 1;
  min-width: 0;
  cursor: pointer;
}
.cart-item-name {
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cart-item-price {
  font-size: 13px;
  font-weight: 600;
  color: var(--black);
  margin-top: 2px;
}
.cart-item-remove {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border: none;
  background: none;
  color: #bbb;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all .2s;
}
.cart-item-remove:hover { color: #e53935; background: #fef2f2; }
.cart-contact-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 12px 20px;
  padding: 12px;
  border-radius: 8px;
  background: var(--brand-green);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity .2s;
}
.cart-contact-btn:hover { opacity: .85; }
.cart-actions {
  display: flex;
  gap: 8px;
  margin: 12px 20px;
}
.cart-actions .cart-contact-btn {
  margin: 0;
  flex: 1;
}
.cart-order-btn {
  flex: 1;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--black);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: all .2s;
}
.cart-order-btn:hover { border-color: var(--black); }
.cart-order-btn--full { flex: none; width: 100%; }
.messenger-picker {
  display: flex;
  gap: 8px;
  width: 100%;
}
.messenger-btn {
  flex: 1;
  padding: 10px 8px;
  border-radius: 8px;
  border: none;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
}
.messenger-btn--wa { background: #25D366; }
.messenger-btn--tg { background: #2AABEE; }
.cart-seller-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px 4px;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray);
  border-top: 1px solid var(--border);
}
.cart-seller-header:first-child { border-top: none; }
.cart-seller-logo {
  width: 80px;
  height: 20px;
  border-radius: 2px;
  object-fit: contain;
}
.cart-seller-name { color: var(--black); }
.cart-seller-link {
  color: var(--brand-green);
  text-decoration: none;
  font-weight: 600;
}
.cart-seller-link:hover { text-decoration: underline; }

/* CDEK info block in cart */
.cart-cdek-block {
  display: flex; align-items: center; gap: 12px;
  margin: 16px 0 4px; padding: 12px 14px;
  background: #f8faf8; border: 1px solid #e0e8e0; border-radius: 10px;
  cursor: pointer; transition: background .15s;
}
.cart-cdek-block:hover { background: #f0f5f0; }
.cart-cdek-logo { height: 24px; flex-shrink: 0; }
.cart-cdek-text { flex: 1; min-width: 0; }
.cart-cdek-title { font-size: 13px; font-weight: 600; color: #00823b; }
.cart-cdek-desc { font-size: 12px; color: #888; margin-top: 2px; }
.cart-cdek-link {
  font-size: 12px; color: #00823b; font-weight: 600;
  flex-shrink: 0; white-space: nowrap;
}

/* Cart button in modal (full-width) */
.modal-btn--cart {
  flex: 1;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--gray);
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: all .2s;
}
.modal-btn--cart:hover { border-color: var(--brand-green); color: var(--brand-green); }
.modal-btn--cart-active { border-color: #444; color: #333; background: #fff; }

/* CDEK button */
.modal-btn--cdek {
  background: #00823b; color: #fff; border: none; gap: 6px;
  display: inline-flex; align-items: center; padding: 10px 18px;
  border-radius: 8px; font-weight: 600; cursor: pointer; transition: all .2s;
}
.modal-btn--cdek svg { stroke: #fff; }
.modal-btn--cdek:hover { background: #006a30; }

/* CDEK modal overlay */
.cdek-overlay {
  position: fixed; inset: 0; z-index: 10000;
  background: rgba(0,0,0,.7); display: flex;
  align-items: center; justify-content: center; padding: 16px;
}
.cdek-modal {
  background: #fff; border-radius: 16px; max-width: 440px; width: 100%;
  padding: 28px 24px; color: #222; position: relative;
  font-family: inherit;
  max-height: calc(100vh - 32px); overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.cdek-modal-header { text-align: center; margin-bottom: 16px; }
.cdek-logo { height: 36px; margin-bottom: 8px; }
.cdek-modal h3 { margin: 0 0 4px; font-size: 18px; color: #00823b; }
.cdek-subtitle { margin: 0; font-size: 13px; color: #888; }
.cdek-steps {
  padding-left: 20px; margin: 12px 0; font-size: 14px; line-height: 1.6;
}
.cdek-steps li { margin-bottom: 6px; }
.cdek-steps em { color: #d32f2f; font-style: normal; font-weight: 600; }
.cdek-details {
  display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0;
  font-size: 13px; color: #555;
}
.cdek-details span {
  background: #f5f5f5; padding: 4px 10px; border-radius: 6px;
}
.cdek-buttons {
  display: flex; gap: 10px; margin-top: 16px;
}
.cdek-btn-primary {
  flex: 1; padding: 12px; border-radius: 10px; font-weight: 600;
  background: #00823b; color: #fff; text-align: center;
  text-decoration: none; font-size: 15px; transition: background .2s;
}
.cdek-btn-primary:hover { background: #006a30; }
.cdek-btn-close {
  padding: 12px 20px; border-radius: 10px; border: 1px solid #ddd;
  background: #fff; color: #666; cursor: pointer; font-size: 15px;
}
.cdek-btn-close:hover { background: #f5f5f5; }

/* Message dialog */
.msg-dialog { max-width: 400px; }
.msg-dialog-header {
  display: flex; align-items: center; gap: 12px; margin-bottom: 12px;
}
.msg-dialog-photo {
  width: 48px; height: 48px; border-radius: 8px; object-fit: cover; flex-shrink: 0;
}
.msg-dialog-item-name {
  font-size: 14px; font-weight: 600; color: #333;
  overflow: hidden; text-overflow: ellipsis;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.msg-dialog-input {
  width: 100%; box-sizing: border-box; padding: 12px;
  border: 1px solid #ddd; border-radius: 10px; font-size: 14px;
  resize: vertical; min-height: 80px; font-family: inherit;
}
.msg-dialog-input:focus { border-color: #4CAF50; outline: none; }
.msg-dialog-counter {
  text-align: right; font-size: 11px; color: #999; margin: 4px 4px 8px 0;
}
.msg-dialog-send { background: #4CAF50 !important; }
.msg-dialog-send:hover { background: #43A047 !important; }
.msg-dialog-send:disabled { background: #ccc !important; cursor: not-allowed; }

/* Message button in item modal */
.modal-btn--msg {
  display: inline-flex; align-items: center; gap: 6px;
  background: #4CAF50; color: #fff; border: none; border-radius: 10px;
  padding: 10px 20px; font-size: 14px; cursor: pointer; width: 100%;
  justify-content: center; margin-top: 6px; transition: background .2s;
}
.modal-btn--msg:hover { background: #43A047; }
.modal-btn--msg svg { stroke: #fff; }

/* Message center */
.msg-tabs {
  display: flex; border-bottom: 2px solid #eee; margin-bottom: 12px;
}
.msg-tab {
  flex: 1; padding: 10px 0; text-align: center; cursor: pointer;
  font-size: 14px; font-weight: 500; color: #999; border: none;
  background: none; position: relative; transition: color .2s;
}
.msg-tab--active { color: #f60; }
.msg-tab--active::after {
  content: ''; position: absolute; bottom: -2px; left: 0; right: 0;
  height: 2px; background: #f60;
}
.msg-tab-badge {
  display: inline-block; background: #f60; color: #fff; border-radius: 10px;
  font-size: 11px; padding: 1px 6px; margin-left: 4px; vertical-align: middle;
}

/* Conversations list */
.conv-list { display: flex; flex-direction: column; gap: 1px; }
.conv-item {
  display: flex; align-items: center; gap: 12px; padding: 12px;
  cursor: pointer; border-radius: 10px; transition: background .15s;
}
.conv-item { position: relative; }
.conv-item:hover { background: #f8f8f8; }
.conv-delete { display: none; position: absolute; right: 8px; top: 8px; background: none; border: none; font-size: 18px; color: #ccc; cursor: pointer; padding: 2px 6px; line-height: 1; border-radius: 50%; }
.conv-delete:hover { color: #d32f2f; background: rgba(211,47,47,.08); }
.conv-item:hover .conv-delete { display: block; }
.conv-item--unread { background: #fff8f0; }
.conv-item--unread:hover { background: #fff3e6; }
.conv-photo {
  width: 44px; height: 44px; border-radius: 8px; object-fit: cover;
  flex-shrink: 0; background: #f0f0f0;
}
.conv-photo--none {
  width: 44px; height: 44px; border-radius: 8px; flex-shrink: 0;
  background: #f0f0f0; display: flex; align-items: center; justify-content: center;
}
.conv-info { flex: 1; min-width: 0; }
.conv-name { font-size: 14px; font-weight: 600; color: #333; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conv-preview { font-size: 13px; color: #888; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.conv-meta { text-align: right; flex-shrink: 0; }
.conv-time { font-size: 11px; color: #aaa; }
.conv-unread-badge {
  display: inline-block; background: #f60; color: #fff; border-radius: 10px;
  font-size: 11px; min-width: 18px; text-align: center; padding: 1px 5px;
  margin-top: 4px;
}

/* Chat view */
.chat-header {
  display: flex; align-items: center; gap: 8px; padding: 8px 0 12px;
  border-bottom: 1px solid #eee; margin-bottom: 8px;
}
.chat-back {
  background: none; border: none; cursor: pointer; padding: 4px;
  color: #666; display: flex; align-items: center;
}
.chat-back:hover { color: #333; }
.chat-title { font-size: 15px; font-weight: 600; flex: 1; }
.chat-messages {
  display: flex; flex-direction: column; gap: 6px; padding: 8px 0;
  max-height: 50vh; overflow-y: auto;
}
.chat-bubble {
  max-width: 80%; padding: 10px 14px; border-radius: 16px;
  font-size: 14px; line-height: 1.4; word-break: break-word;
}
.chat-bubble--own {
  background: rgba(76, 175, 80, 0.1); color: #333; align-self: flex-end;
  border-bottom-right-radius: 4px;
}
.chat-bubble--other {
  background: #f0f0f0; color: #333; align-self: flex-start;
  border-bottom-left-radius: 4px;
}
.chat-bubble-time {
  font-size: 10px; opacity: 0.7; margin-top: 2px;
}
.chat-bubble--own .chat-bubble-time { text-align: right; }
.chat-bubble-source {
  font-size: 10px; opacity: 0.5; margin-top: 1px;
}
.chat-input-area {
  display: flex; gap: 8px; padding: 8px 0; border-top: 1px solid #eee; margin-top: 8px;
}
.chat-input {
  flex: 1; padding: 10px 14px; border: 1px solid #ddd; border-radius: 20px;
  font-size: 14px; font-family: inherit; outline: none;
}
.chat-input:focus { border-color: #4CAF50; }
.chat-send-btn {
  background: #4CAF50; color: #fff; border: none; border-radius: 50%;
  width: 40px; height: 40px; cursor: pointer; display: flex;
  align-items: center; justify-content: center; flex-shrink: 0;
  transition: background .2s;
}
.chat-send-btn:hover { background: #43A047; }
.chat-send-btn:disabled { background: #ccc; cursor: not-allowed; }
.conv-empty {
  text-align: center; padding: 40px 20px; color: #999; font-size: 14px;
}

/* Messaging settings */
.msg-settings {
  padding: 12px 0; border-top: 1px solid #eee; margin-top: 12px;
}
.msg-settings-title { font-size: 13px; font-weight: 600; color: #666; margin-bottom: 8px; }
.msg-setting-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 6px 0;
}
.msg-setting-label { font-size: 13px; color: #333; }
.msg-toggle {
  width: 44px; height: 24px; border-radius: 12px; background: #ddd;
  border: none; cursor: pointer; position: relative; transition: background .2s;
}
.msg-toggle--on { background: #f60; }
.msg-toggle::after {
  content: ''; position: absolute; top: 2px; left: 2px;
  width: 20px; height: 20px; border-radius: 50%; background: #fff;
  transition: transform .2s;
}
.msg-toggle--on::after { transform: translateX(20px); }

/* Cart icon in header */
.header-link--cart {
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  color: #666;
  padding: 0;
  display: flex;
  align-items: center;
}
.header-link--cart:hover { color: var(--black); }
/* cart always visible in header */

/* Cart badge */
.cart-badge {
  position: absolute;
  top: 2px;
  right: 50%;
  margin-right: -16px;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background: #e53935;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
}
.cart-badge--header {
  top: -6px;
  right: -8px;
  margin-right: 0;
}
.header-link--cart {
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  color: #666;
  padding: 0;
  display: flex;
  align-items: center;
}
.header-link--cart:hover { color: var(--black); }
/* cart always visible in header */

/* Cart badge */
.cart-badge {
  position: absolute;
  top: 2px;
  right: 50%;
  margin-right: -16px;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background: #e53935;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
}
.cart-badge--header {
  top: -6px;
  right: -8px;
  margin-right: 0;
}

/* ===== Banner carousel ===== */
.banner-carousel {
  position: relative;
  margin-bottom: 16px;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 12px rgba(0,0,0,.15);
  border: 1px solid rgba(0,0,0,.1);
}
.banner-carousel.hidden { display: none; }
.banner-logo .cdek-logo { height: 20px; margin-bottom: 0; }
.banner-badge-inline {
  background: #e53935; color: #fff;
  font-family: inherit;
  font-size: 8px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.5px; padding: 2px 6px; border-radius: 3px;
  white-space: nowrap; flex-shrink: 0;
}
.banner-close-btn {
  position: absolute; top: 8px; right: 8px; z-index: 10;
  background: none; border: none; cursor: pointer;
  color: #999; font-size: 22px; line-height: 1;
  padding: 4px 8px;
}
.banner-close-btn:active { color: #666; }
.banner-track {
  display: flex;
  width: 100%;
  transition: transform 0.3s ease;
}
.banner-slide {
  position: relative;
  display: flex;
  flex-shrink: 0;
  width: 100%;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  height: 80px;
  overflow: hidden;
  box-sizing: border-box;
}
/* Two halves: left (logo+text) | right (photos) */
.banner-left {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 8px 16px;
  gap: 4px;
}
.banner-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: nowrap;
}
.banner-badge-inline { margin-left: auto; }
.banner-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}
.banner-shop-logo {
  height: 16px;
  width: auto;
  object-fit: contain;
  border-radius: 0;
}
.banner-shop {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.5;
}
.banner-title {
  font-family: inherit;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 3px;
}
.banner-brand-img {
  height: 30px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  object-position: left;
  margin-bottom: 1px;
  align-self: flex-start;
}
.banner-badge {
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  background: #e53935;
  color: #fff;
  font-family: inherit;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 8px;
  border-radius: 4px;
  white-space: nowrap;
  flex-shrink: 0;
}
.banner-subtitle {
  font-size: 11px;
  opacity: 0.6;
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.banner-right {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  width: 30%;
  max-height: 80px;
  overflow: hidden;
  padding-right: 24px;
}
.banner-images {
  display: flex;
  gap: 4px;
  padding: 8px;
  flex-wrap: nowrap;
  justify-content: center;
  align-items: center;
}
.banner-prod-img {
  width: 50px;
  height: 60px;
  object-fit: contain;
  border-radius: 6px;
  mix-blend-mode: multiply;
}
.banner-hero-img {
  max-height: 65px;
  max-width: 100%;
  width: auto;
  object-fit: contain;
}
.banner-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 0 0 10px;
}
.banner-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(0,0,0,0.15);
  cursor: pointer;
  transition: all 0.2s;
}
.banner-dot--active {
  background: var(--brand-green, #206b16);
  width: 18px;
  border-radius: 3px;
}
/* CDEK custom banner */
.banner-cdek-logos {
  display: flex;
  align-items: center;
  gap: 8px;
}
.banner-cdek-logos img.cdek-sv {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
}
.banner-cdek-logos span {
  font-size: 14px;
  opacity: 0.4;
}
.banner-cdek-logos img.cdek-logo {
  height: 20px;
  width: auto;
}

/* Mobile */
@media (max-width: 600px) {
  .banner-slide { height: 70px; }
  .banner-left { padding: 8px 10px; }
  .banner-logo { margin-bottom: 4px; }
  .banner-title { font-size: 13px; }
  .banner-subtitle { font-size: 10px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .banner-brand-img { height: 12px; }
  .banner-badge { font-size: 9px; padding: 1px 6px; }
  .banner-prod-img {
    width: 40px;
    height: 48px;
    border-radius: 4px;
  }
  .banner-images { gap: 3px; padding: 4px; }
  .banner-shop-logo { height: 18px; }
  .banner-carousel { margin-bottom: 8px; }
  .banner-hero-img { max-height: 50px; }
  .banner-cdek-logos img.cdek-sv { width: 22px; height: 22px; }
  .banner-cdek-logos img.cdek-logo { height: 16px; }
}
@media (max-width: 380px) {
  .banner-prod-img:nth-child(4) { display: none; }
}

/* ===== FILTER DROPDOWNS ===== */
.filter-dropdowns {
  display: flex;
  gap: 6px;
  margin-left: auto;
  flex-shrink: 0;
}
.filter-dropdown {
  position: relative;
}
.filter-dropdown-btn {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 12px;
  border: 1px solid rgba(0,0,0,0.12);
  background: transparent;
  color: rgba(0,0,0,0.45);
  cursor: pointer;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 4px;
  line-height: 1.2;
  transition: all 0.15s;
}
.filter-dropdown-btn:hover {
  border-color: rgba(0,0,0,0.25);
  color: rgba(0,0,0,0.6);
}
.filter-dropdown-btn--active {
  background: rgba(0,0,0,0.08);
  border-color: rgba(0,0,0,0.3);
  color: rgba(0,0,0,0.7);
  font-weight: 600;
}
.filter-dropdown-btn svg {
  transition: transform 0.2s;
}
.filter-dropdown.open .filter-dropdown-btn svg {
  transform: rotate(180deg);
}
.filter-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.12);
  z-index: 100;
  min-width: 120px;
  overflow: hidden;
}
.filter-dropdown.open .filter-dropdown-menu {
  display: block;
}
.filter-dropdown-item {
  display: block;
  padding: 8px 14px;
  font-size: 13px;
  color: #333;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.1s;
}
.filter-dropdown-item:hover {
  background: rgba(0,0,0,0.04);
}
.filter-dropdown-item--active {
  font-weight: 600;
  color: var(--brand-green, #206b16);
}

/* ===== PULL TO REFRESH ===== */
.ptr-indicator {
  position: fixed;
  top: -50px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: top 0.2s ease;
  pointer-events: none;
}
/* Spinner (iOS-style) */
.spinner {
  width: 28px; height: 28px;
  border: 3px solid #e0e0e0;
  border-top-color: #999;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

@media (min-width: 769px) {
  .ptr-indicator { display: none !important; }
}

/* ===== FULLSCREEN PHOTO VIEWER ===== */
.photo-viewer-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,.92);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.photo-viewer-close {
  position: absolute;
  top: 16px; right: 16px;
  background: none;
  border: none;
  color: #fff;
  font-size: 32px;
  cursor: pointer;
  z-index: 10;
  width: 44px; height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.7;
}
.photo-viewer-close:hover { opacity: 1; }
.photo-viewer-counter {
  position: absolute;
  top: 20px; left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,.7);
  font-size: 14px;
  z-index: 10;
}
.photo-viewer-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,.15);
  border: none;
  color: #fff;
  font-size: 28px;
  width: 48px; height: 48px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
}
.photo-viewer-nav:hover { background: rgba(255,255,255,.3); }
.photo-viewer-prev { left: 16px; }
.photo-viewer-next { right: 16px; }
.photo-viewer-img-wrap {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.photo-viewer-img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
  cursor: zoom-in;
  transition: transform 0.1s ease;
  user-select: none;
  -webkit-user-select: none;
}

/* ===== ADMIN PANEL ===== */
.admin-toggle-bar {
  display: flex; gap: 8px; padding: 12px 16px 0; background: #fff;
  max-width: 800px; margin: 0 auto;
}
.admin-toggle-btn {
  padding: 7px 18px; border-radius: 20px; border: 1px solid #ddd;
  background: #fff; color: #555;
  font-family: inherit; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: all .2s;
}
.admin-toggle-btn--active { background: var(--brand-green, #2e7d32); color: #fff; border-color: var(--brand-green, #2e7d32); }

.admin-stats-bar {
  display: flex; flex-direction: column; gap: 4px; padding: 8px 12px;
  background: #f8f8f8; border-radius: 10px; margin-bottom: 4px; margin-top: 10px;
}
.admin-stats-row {
  display: flex; flex-wrap: nowrap; gap: 8px;
  overflow-x: auto; -webkit-overflow-scrolling: touch;
}
.admin-stat { font-size: 11px; color: #666; white-space: nowrap; }
.admin-stat b { color: #222; }

.admin-chips {
  display: flex; flex-wrap: wrap; gap: 6px; padding-bottom: 10px;
}
.admin-chip {
  padding: 6px 12px; border-radius: 16px; border: 1px solid #ddd;
  background: #fff; font-size: 12px; font-family: inherit;
  cursor: pointer; white-space: nowrap; color: #555; transition: all .2s;
  text-decoration: none; flex: 1; text-align: center;
}
.admin-chip--active { background: #333; color: #fff; border-color: #333; }

.admin-card {
  display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px solid #f0f0f0;
  align-items: center;
}
.admin-card-img {
  width: 50px; height: 50px; object-fit: cover; border-radius: 8px; flex-shrink: 0;
  background: #f5f5f5;
}
.admin-card-img--empty { background: #eee; }
.admin-card-img--round { border-radius: 50%; }
.admin-card-info { flex: 1; min-width: 0; }
.admin-card-name {
  font-size: 13px; font-weight: 600; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}
.admin-card-meta { font-size: 12px; color: #888; }
.admin-card-views { font-size: 11px; color: #888; margin-top: 2px; }
.admin-card-actions { display: flex; gap: 4px; flex-shrink: 0; }

.admin-btn {
  padding: 4px 12px; border: none; border-radius: 6px; font-size: 12px;
  cursor: pointer; font-weight: 600;
}
.admin-btn--ok { background: #206b16; color: #fff; }
.admin-btn--no { background: #e53935; color: #fff; }
.admin-btn--profile {
  background: #fff; border: 1px solid #ddd; color: #555; font-size: 11px;
  padding: 4px 10px; border-radius: 12px;
}
.admin-btn--profile:active { background: #f0f0f0; }

.admin-more-btn {
  display: block; width: 100%; padding: 10px; margin-top: 8px;
  border: 1px solid #ddd; border-radius: 10px; background: #fff;
  font-size: 13px; color: #555; cursor: pointer; text-align: center;
  font-family: inherit;
}
.admin-more-btn:active { background: #f5f5f5; }

.admin-card--review { align-items: flex-start; }

/* Admin chip variants */
.admin-chip--ghost {
  background: rgba(0,0,0,.04); border-color: rgba(0,0,0,.08); color: #888;
}
.admin-chip--create {
  background: rgba(32,107,22,.35); color: #fff; border-color: rgba(32,107,22,.25);
  font-weight: 700; display: inline-flex; align-items: center; gap: 4px;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}

/* Admin charts grid */
.admin-charts-grid {
  display: grid; grid-template-columns: 1fr; gap: 12px; padding-bottom: 16px;
}
@media (min-width: 700px) {
  .admin-charts-grid { grid-template-columns: 1fr 1fr; }
}
.admin-chart-card {
  background: #fff; border-radius: 12px; padding: 14px 16px;
  border: 1px solid rgba(0,0,0,.06); box-shadow: 0 1px 3px rgba(0,0,0,.06);
}
.admin-chart-title {
  font-size: 13px; font-weight: 700; color: #333; margin-bottom: 8px;
  display: flex; align-items: center; gap: 6px;
}
.admin-chart-title .dot {
  width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex-shrink: 0;
}
.admin-chart-wrap { position: relative; height: 180px; }
.admin-chart-meta { font-size: 11px; color: #888; margin-bottom: 6px; }

/* Auth login buttons (unified TG/VK) */
.auth-login-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 12px 24px; border-radius: 10px; font-size: 15px; font-weight: 600;
  text-decoration: none; font-family: inherit; width: 100%; max-width: 280px;
  box-sizing: border-box; color: #fff; transition: opacity .15s;
}
.auth-login-btn:active { opacity: .85; }
.auth-login-btn--tg { background: #2AABEE; }
.auth-login-btn--vk { background: #0077FF; }

/* Admin top-items table */
.admin-tbl { width: 100%; border-collapse: collapse; font-size: 12px; }
.admin-tbl th { text-align: left; font-weight: 600; color: #888; padding: 4px 6px; border-bottom: 1px solid #eee; font-size: 11px; }
.admin-tbl td { padding: 5px 6px; border-bottom: 1px solid #f5f5f5; }
.admin-tbl tr:last-child td { border-bottom: none; }

/* Admin priority chips (top row, 2 per line) */
.admin-chips--priority {
  display: grid; grid-template-columns: 1fr 1fr; gap: 6px; width: 100%; margin-bottom: 6px;
}
.admin-chips--priority .admin-chip {
  padding: 10px 14px; font-size: 13px; font-weight: 600; flex: unset;
}

/* Admin chip color variants */
.admin-chip--green { background: rgba(52,199,89,0.12); border-color: rgba(52,199,89,0.25); color: #1b7a2e; }
.admin-chip--green.admin-chip--active { background: #34c759; color: #fff; border-color: #34c759; }
.admin-chip--purple { background: rgba(175,82,222,0.12); border-color: rgba(175,82,222,0.25); color: #8e44ad; }
.admin-chip--purple.admin-chip--active { background: #af52de; color: #fff; border-color: #af52de; }
.admin-chip--gold { background: rgba(212,160,23,0.12); border-color: rgba(212,160,23,0.25); color: #b8860b; }
.admin-chip--gold.admin-chip--active { background: #d4a017; color: #fff; border-color: #d4a017; }
.admin-chip--red { background: rgba(229,57,53,0.1); border-color: rgba(229,57,53,0.2); color: #c62828; }
.admin-chip--red.admin-chip--active { background: #e53935; color: #fff; border-color: #e53935; }
.admin-chip--blue-light { background: rgba(0,113,227,0.06); border-color: rgba(0,113,227,0.12); color: #555; }
.admin-chip--blue-light.admin-chip--active { background: #0071e3; color: #fff; border-color: #0071e3; }
.admin-chip--pink { background: rgba(229,57,53,0.08); border-color: rgba(229,57,53,0.15); color: #c62828; }
.admin-chip--pink.admin-chip--active { background: #e53935; color: #fff; border-color: #e53935; }
.admin-chip--violet { background: rgba(175,82,222,0.12); border-color: rgba(175,82,222,0.2); color: #7b1fa2; }
.admin-chip--violet.admin-chip--active { background: #7b1fa2; color: #fff; border-color: #7b1fa2; }
.admin-chip--ig { background: rgba(228,64,95,0.1); border-color: rgba(228,64,95,0.2); color: #c13584; }
.admin-chip--ig.admin-chip--active { background: #E4405F; color: #fff; border-color: #E4405F; }

/* Chart period selector */
.admin-chart-periods {
  display: flex; gap: 4px; margin-left: auto;
}
.admin-chart-periods button {
  padding: 2px 8px; border: 1px solid #ddd; border-radius: 10px;
  background: #fff; font-size: 10px; color: #888; cursor: pointer;
  font-family: inherit; transition: all .15s;
}
.admin-chart-periods button.active {
  background: #333; color: #fff; border-color: #333;
}

/* ===== SUBSCRIPTION RETENTION MECHANICS ===== */
.sub-banner, .sub-card, .sub-nudge, .sold-sub-prompt {
  font-family: inherit;
}

/* Feature 1: Sticky bottom banner */
.sub-banner {
  position: fixed; bottom: -100px; left: 0; right: 0; z-index: 1001;
  background: #fff;
  border: 1px solid rgba(36,160,237,0.3);
  box-shadow: 0 -2px 8px rgba(36,160,237,.08), 0 2px 8px rgba(36,160,237,.08);
  padding: 10px 16px; display: flex; align-items: center; justify-content: space-between;
  transition: bottom .4s ease;
}
.sub-banner--visible { bottom: 0 !important; }
@media (max-width: 768px) {
  .sub-banner--visible { bottom: 150px !important; border-radius: 16px 16px 0 0; }
}
.sub-banner-content { display: flex; align-items: center; justify-content: center; gap: 12px; flex: 1; min-width: 0; }
.sub-banner-text { font-size: 13px; color: #333; line-height: 1.3; }
.sub-banner-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: #2AABEE; color: #fff; border: none; border-radius: 8px;
  padding: 7px 14px; font-size: 13px; font-weight: 500; text-decoration: none;
  white-space: nowrap; cursor: pointer; flex-shrink: 0;
}
.sub-banner-btn:active { opacity: .85; }
.sub-banner-btn svg { flex-shrink: 0; }
.sub-banner-btn--vk { background: #0077FF; }
.sub-banner-btn--donate { background: #FF6600; }
.sub-banner-close {
  background: none; border: none; color: #999; font-size: 20px; line-height: 1;
  padding: 4px 8px; cursor: pointer; flex-shrink: 0; margin-left: 4px;
}
.sub-banner-close:active { color: #666; }

/* Feature 2: Inline subscription card between items */
.sub-card {
  grid-column: 1 / -1;
  padding: 20px 16px; text-align: center;
  background: #f0f7ff; border-radius: 12px; border: 1px dashed #b3d4f0;
  margin: 4px 0;
}
.sub-card-icon { font-size: 24px; margin-bottom: 6px; }
.sub-card-text { font-size: 14px; color: #444; line-height: 1.4; margin-bottom: 12px; }
.sub-card-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.sub-card-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 18px; border-radius: 8px; font-size: 13px; font-weight: 500;
  text-decoration: none; color: #fff; cursor: pointer;
  flex: 1; min-width: 120px; max-width: 180px;
}
.sub-card-btn:active { opacity: .85; }
.sub-card-btn--tg { background: #2AABEE; }
.sub-card-btn--vk { background: #2A5885; }
.sub-card-btn svg { width: 16px; height: 16px; flex-shrink: 0; }

/* Feature 3: Post-modal nudge toast */
.sub-nudge {
  position: fixed; bottom: -70px; left: 50%; transform: translateX(-50%);
  background: #333; color: #fff; padding: 10px 16px; border-radius: 12px;
  z-index: 2001; transition: bottom .3s ease;
  display: flex; align-items: center; gap: 10px;
  font-size: 13px; white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0,0,0,.2);
  max-width: calc(100vw - 32px);
}
.sub-nudge--visible { bottom: 80px; }
.sub-nudge-text { overflow: hidden; text-overflow: ellipsis; }
.sub-nudge-btn {
  display: inline-flex; align-items: center; gap: 5px;
  background: #2AABEE; color: #fff; border-radius: 6px;
  padding: 5px 12px; font-size: 12px; font-weight: 500; text-decoration: none;
  white-space: nowrap; flex-shrink: 0;
}
.sub-nudge-btn:active { opacity: .85; }
@media (max-width: 768px) {
  .sub-nudge--visible { bottom: calc(120px + env(safe-area-inset-bottom, 12px)); }
}

/* Feature 4: Sold item subscription prompt */
.sold-sub-prompt {
  background: #f5f5f5; border-radius: 10px; padding: 16px;
  margin: 12px 0; text-align: center;
}
.sold-sub-prompt-text { font-size: 14px; color: #555; margin-bottom: 10px; line-height: 1.4; }
.sold-sub-prompt-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: #2AABEE; color: #fff; border-radius: 8px;
  padding: 8px 18px; font-size: 13px; font-weight: 500; text-decoration: none;
}
.sold-sub-prompt-btn:active { opacity: .85; }
.sold-sub-prompt-btn svg { width: 16px; height: 16px; }
