/* ===== 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: 4px;
  --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--active { background: rgba(76, 175, 80, 0.7); 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) ===== */
.gender-chips {
  display: flex;
  gap: 5px;
  margin-left: auto;
  flex-shrink: 0;
}
.gender-chip {
  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.35);
  text-decoration: none;
  white-space: nowrap;
  transition: all 0.15s;
  line-height: 1.2;
}
.gender-chip:hover {
  border-color: rgba(0,0,0,0.25);
  color: rgba(0,0,0,0.55);
}
.gender-chip--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;
}
.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;
}
.sidebar-close::after {
  content: '';
  display: block;
  width: 18px;
  height: 18px;
  background: var(--gray);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round'%3E%3Cline x1='18' y1='6' x2='6' y2='18'/%3E%3Cline x1='6' y1='6' x2='18' y2='18'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round'%3E%3Cline x1='18' y1='6' x2='6' y2='18'/%3E%3Cline x1='6' y1='6' x2='18' y2='18'/%3E%3C/svg%3E") center/contain no-repeat;
}

.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: '';
  display: block;
  width: 12px;
  height: 12px;
  background: var(--brand-orange);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round'%3E%3Cline x1='18' y1='6' x2='6' y2='18'/%3E%3Cline x1='6' y1='6' x2='18' y2='18'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round'%3E%3Cline x1='18' y1='6' x2='6' y2='18'/%3E%3Cline x1='6' y1='6' x2='18' y2='18'/%3E%3C/svg%3E") center/contain no-repeat;
}
.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-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 {
  top: 12px;
  right: 12px;
  bottom: auto;
  left: auto;
  font-size: 13px;
  padding: 5px 10px;
}
/* ===== PROMO BADGE ===== */
.promo-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: #E26C1D;
  color: #fff;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  z-index: 6;
  line-height: 1;
  letter-spacing: 0.5px;
}
.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: 12px; left: 16px;
  background: #e0e0e0;
  border: none;
  font-size: 0;
  cursor: pointer;
  color: #555;
  z-index: 10;
  line-height: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.modal-close::after {
  content: '';
  display: block;
  width: 16px;
  height: 16px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round'%3E%3Cline x1='18' y1='6' x2='6' y2='18'/%3E%3Cline x1='6' y1='6' x2='18' y2='18'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2.5' stroke-linecap='round'%3E%3Cline x1='18' y1='6' x2='6' y2='18'/%3E%3Cline x1='6' y1='6' x2='18' y2='18'/%3E%3C/svg%3E") center/contain no-repeat;
}
.modal-close:hover { background: #d0d0d0; color: #333; }
#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 {
  position: relative;
  background: var(--light);
  aspect-ratio: 1;
  overflow: hidden;
  align-self: center;
}

.modal-gallery img {
  width: 100%;
  height: 100%;
  display: none;
  object-fit: cover;
}
.modal-gallery img.active { display: block; }

.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: 32px 28px;
  display: flex;
  flex-direction: column;
}

.modal-price {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 12px;
}

.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: 14px;
  line-height: 1.6;
  color: #444;
  margin-bottom: 24px;
  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: 8px;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  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: #e0e0e0;
  color: #333;
}
.modal-btn--secondary {
  background: var(--brand-green);
  color: #fff;
  border: none;
}
.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: 14px;
  padding: 14px 8px;
  white-space: nowrap;
}
.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: 'Roboto Condensed', sans-serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0;
}
.footer-desc { font-size: 12px; color: var(--gray); font-family: 'Roboto Condensed', sans-serif; }
.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 img { height: 100%; object-fit: cover; }
}

.fab-add { display: none; }
.fab-back { display: none; }

@media (max-width: 768px) {
  .header-inner { padding: 10px 16px; gap: 10px; flex-wrap: nowrap; 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; }
  .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; }
  .auth-area { margin-left: auto; gap: 8px; flex-wrap: nowrap; flex-shrink: 0; }
  .user-menu { order: 1; }
  .filter-toggle { display: none !important; }
  .header-link--fav { 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 only */
  .fab-add {
    display: flex;
    position: fixed;
    bottom: 90px;
    right: 16px;
    padding: 14px 20px;
    border-radius: 28px;
    background: var(--brand-green);
    color: #fff;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 700;
    font-family: 'Roboto Condensed', sans-serif;
    box-shadow: 0 4px 12px rgba(0,0,0,.3);
    z-index: 1000;
    border: none;
    cursor: pointer;
    text-decoration: none;
  }
  .fab-add:active { transform: scale(.95); }
  .fab-back {
    display: none !important;
    position: fixed;
    bottom: 90px;
    right: 16px;
    padding: 14px 20px;
    border-radius: 28px;
    background: rgba(0,0,0,0.35);
    color: #fff;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 700;
    font-family: 'Roboto Condensed', sans-serif;
    box-shadow: 0 4px 12px rgba(0,0,0,.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1100;
    border: none;
    cursor: pointer;
    text-decoration: none;
  }
  .fab-back:active { transform: scale(.95); }
  #modal > .modal {
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .modal-close {
    position: absolute;
    top: 8px;
    left: 12px;
    font-size: 0;
    z-index: 100;
    background: #e0e0e0;
    color: #555;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 0;
    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 { aspect-ratio: 1; overflow: hidden; }
  .modal-gallery img { height: 100%; object-fit: cover; }
}

/* 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);
  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; }

.header-link--fav {
  color: var(--gray);
  transition: color .2s;
}
.header-link--fav:hover { color: #e53935; }
.header-link--fav-active { color: #e53935; }

.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 ===== */
.cart-btn {
  position: absolute;
  bottom: 6px;
  right: 40px;
  z-index: 5;
  width: 29px;
  height: 29px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,.25);
  color: #ccc;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
}
.cart-btn:hover { background: rgba(255,255,255,.9); color: var(--brand-green, #43a047); }
.cart-btn--active { color: var(--brand-green, #43a047); background: rgba(255,255,255,.9); }
@media (max-width: 768px) {
  .cart-btn { background: rgba(255,255,255,.25); }
}

/* ===== FAVORITE BUTTON ON CARD ===== */
.fav-btn {
  position: absolute;
  bottom: 6px;
  right: 6px;
  z-index: 5;
  width: 29px;
  height: 29px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,.25);
  color: #ccc;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
}
.fav-btn:hover { background: rgba(255,255,255,.9); color: #e53935; }
.fav-btn--active { color: #e53935; background: rgba(255,255,255,.9); }
@media (max-width: 768px) {
  .fav-btn { background: rgba(255,255,255,.25); }
}

/* ===== MODAL FAVORITE BUTTON ===== */
.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: #e53935; border-color: #e53935; }
.modal-fav-btn--active { color: #e53935; border-color: #e53935; }
.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); }
.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;
}
.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: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, sans-serif;
}
.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-items-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.seller-items-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.seller-item {
  cursor: pointer;
  transition: opacity .2s;
}
.seller-item:hover { opacity: .8; }

.seller-item-photo {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: 6px;
  background: var(--light);
}

.seller-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;
}

.seller-item-price {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.seller-item-name {
  font-size: 12px;
  color: var(--gray);
  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-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: 10px;
}
.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;
  margin-bottom: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.rec-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.rec-item {
  cursor: pointer;
  transition: opacity .2s;
}
.rec-item:hover { opacity: .8; }

.rec-item-photo {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: 6px;
  background: var(--light);
}

.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 { gap: 8px; }
}

/* ===== 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 (favorites page) ===== */
.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);
}

.my-item-card {
  display: flex;
  flex-direction: column;
}
.my-item-card .card {
  flex: 1;
}

.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--inactive {
  background: rgba(0,0,0,.65);
  color: #fff;
}
.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;
  gap: 6px;
  padding: 0 10px 10px;
}

.my-item-btn {
  flex: 1;
  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);
  overflow: hidden;
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
}
.edit-photo-slot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.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);
}

/* ===== 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: 14px;
  padding: 12px 14px;
  border: 1px solid var(--brand-green);
  border-radius: 8px;
  background: #e8f5e9;
}
.ai-recognize-btn:hover { background: #c8e6c9; }
.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 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .login-btn span { display: none; }
  .seller-items-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .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; }
.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: 'Roboto Condensed', sans-serif;
}
.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;
}

.bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  flex: 1;
  padding: 6px 0 3px;
  color: #999;
  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-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 {
  position: absolute;
  top: 2px;
  right: 50%;
  margin-right: -18px;
  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;
}

@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: 8px;
  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: 28px;
  max-width: 60px;
  border-radius: 4px;
  background: #fff;
  padding: 3px 5px;
  box-shadow: 0 1px 3px rgba(0,0,0,.15);
  z-index: 5;
  pointer-events: none;
}

/* ===== 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; }

/* 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: var(--brand-green); color: var(--brand-green); }

/* 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); }
@media (max-width: 768px) {
  .header-link--cart { display: none; }
}

/* 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;
}
