/* ==================== Black & White Minimalist Theme ==================== */
:root {
  /* Core Colors - Black & White */
  --bg: #1a1a1a;
  --bg-secondary: #262626;
  --bg-card: #2a2a2a;
  --text: #ffffff;
  --text-secondary: #888888;
  --border: rgba(255, 255, 255, 0.1);

  /* Accent - Telegram Blue */
  --accent: #3390ec;
  --accent-hover: #2b7fd4;

  /* Status Colors */
  --success: #4ade80;
  --warning: #fbbf24;
  --danger: #ef4444;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.5);

  /* Radius */
  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
}

/* ==================== Reset & Base ==================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
}

#app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ==================== Header ==================== */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.header-back {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border: none;
  border-radius: 50%;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s;
}

.header-back:active {
  transform: scale(0.95);
  background: var(--bg-card);
}

.header-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
}

.header-favorites {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.header-favorites:active {
  transform: scale(0.95);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-lang-switch {
  display: flex;
  background: var(--bg-secondary);
  border-radius: 8px;
  padding: 2px;
}

.header-lang-switch .lang-btn {
  padding: 6px 10px;
  background: transparent;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-family: inherit;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.header-lang-switch .lang-btn.active {
  background: var(--accent);
  color: var(--text);
}

/* ==================== Content ==================== */
.content {
  flex: 1;
  padding-bottom: env(safe-area-inset-bottom);
}

.page {
  display: none;
  animation: fadeIn 0.3s ease;
}

.page.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==================== Hero ==================== */
.hero {
  position: relative;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin: 16px;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, #2a2a2a 0%, #3a3a3a 100%);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--bg-secondary) 0%, #333 100%);
  z-index: 0;
}

.hero-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.5;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  color: var(--text);
  padding: 20px;
}

.hero-title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 8px;
}

.hero-subtitle {
  font-size: 14px;
  color: var(--text-secondary);
}

/* ==================== Stats ==================== */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  padding: 0 16px;
  margin-top: -30px;
  position: relative;
  z-index: 10;
}

.stat-card {
  background: linear-gradient(135deg, #f59e0b 0%, #f97316 100%);
  border-radius: var(--radius);
  padding: 16px 12px;
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.stat-icon {
  font-size: 24px;
}

.stat-value {
  font-size: 20px;
  font-weight: 700;
  color: #1a1a1a;
}

.stat-label {
  font-size: 11px;
  color: #422006;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 500;
}

/* ==================== Section Title ==================== */
.section-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text);
}

/* ==================== Type Selector ==================== */
.type-selector {
  padding: 24px 16px;
}

.type-cards {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.type-card {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  padding: 16px;
  background: var(--bg-card);
  border: 2px solid transparent;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all 0.2s;
  text-align: left;
  font-family: inherit;
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
}

.type-card:active {
  transform: scale(0.98);
}

.type-card:hover {
  border-color: var(--accent);
}

.type-card-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border-radius: var(--radius);
  font-size: 28px;
  box-shadow: var(--shadow);
}

.type-card-content {
  flex: 1;
}

.type-card-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
}

.type-card-desc {
  font-size: 13px;
  color: var(--text-secondary);
}

.type-card-arrow {
  color: var(--text-secondary);
}

/* ==================== Locations ==================== */
.locations-section {
  padding: 8px 16px 24px;
}

.locations-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.location-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  background: var(--bg-card);
  border: none;
  border-radius: var(--radius);
  font-size: 14px;
  font-family: inherit;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.location-chip:active {
  transform: scale(0.98);
  background: var(--accent);
}

.location-chip-icon {
  font-size: 16px;
}

/* ==================== Catalog ==================== */
.catalog-header {
  display: flex;
  gap: 12px;
  padding: 16px;
  position: sticky;
  top: 57px;
  background: var(--bg);
  z-index: 50;
}

.search-bar {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--bg-card);
  border-radius: var(--radius);
  color: var(--text-secondary);
}

.search-bar input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 15px;
  color: var(--text);
  outline: none;
}

.search-bar input::placeholder {
  color: var(--text-secondary);
}

.filter-btn {
  position: relative;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: none;
  border-radius: var(--radius);
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s;
}

.filter-btn:active {
  transform: scale(0.95);
}

.filter-count {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: white;
  font-size: 11px;
  font-weight: 600;
  border-radius: 9px;
  padding: 0 5px;
}

.catalog-tabs {
  display: flex;
  gap: 8px;
  padding: 0 16px 12px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.catalog-tabs::-webkit-scrollbar {
  display: none;
}

.tab {
  flex-shrink: 0;
  padding: 8px 16px;
  background: var(--bg-card);
  border: none;
  border-radius: 20px;
  font-size: 13px;
  font-family: inherit;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.tab.active {
  background: var(--accent);
  color: var(--text);
}

.tabs-scroll {
  display: flex;
  gap: 8px;
}

/* ==================== Lots Grid ==================== */
.catalog-results {
  padding: 0 16px 16px;
}

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

.lot-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: all 0.2s;
}

.lot-card:active {
  transform: scale(0.98);
}

.lot-card-image {
  position: relative;
  width: 100%;
  padding-top: 75%;
  background: var(--bg-secondary);
  overflow: hidden;
}

.lot-card-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lot-card-image .placeholder {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 32px;
  opacity: 0.5;
}

.lot-card-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 4px 8px;
  background: rgba(0,0,0,0.7);
  color: white;
  font-size: 11px;
  font-weight: 500;
  border-radius: 6px;
}

.lot-card-favorite {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: none;
  border-radius: 50%;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.lot-card-favorite.active {
  color: var(--danger);
  background: rgba(239, 68, 68, 0.2);
}

.lot-card-favorite svg {
  width: 18px;
  height: 18px;
}

.lot-card-favorite.active svg {
  fill: var(--danger);
}

.lot-card-content {
  padding: 12px;
}

.lot-card-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--text);
}

.lot-card-location {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.lot-card-location svg {
  width: 12px;
  height: 12px;
}

.lot-card-price {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}

.lot-card-price span {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-secondary);
}

/* ==================== Load More ==================== */
.load-more {
  margin-top: 16px;
  text-align: center;
}

/* ==================== Empty State ==================== */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
  text-align: center;
}

.empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
}

.empty-state p {
  color: var(--text-secondary);
  margin-bottom: 16px;
}

/* ==================== Detail Page ==================== */
.detail-gallery {
  position: relative;
  width: 100%;
  height: 280px;
  background: var(--bg-secondary);
  overflow: hidden;
}

.gallery-slides {
  display: flex;
  height: 100%;
  transition: transform 0.3s ease;
}

.gallery-slide {
  flex-shrink: 0;
  width: 100%;
  height: 100%;
}

.gallery-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-slide .placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 64px;
  opacity: 0.5;
}

.gallery-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
}

.gallery-dot {
  width: 8px;
  height: 8px;
  background: rgba(255,255,255,0.5);
  border-radius: 50%;
  transition: all 0.2s;
}

.gallery-dot.active {
  width: 24px;
  border-radius: 4px;
  background: white;
}

.detail-content {
  padding: 20px 16px 100px;
}

.detail-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.detail-title {
  font-size: 22px;
  font-weight: 700;
  flex: 1;
  color: var(--text);
}

.detail-favorite {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: none;
  border-radius: 50%;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.detail-favorite.active {
  background: rgba(239, 68, 68, 0.2);
  color: var(--danger);
}

.detail-favorite.active svg {
  fill: var(--danger);
}

.detail-location {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 20px;
}

.detail-specs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.spec-tag {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: var(--bg-card);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}

.spec-tag-icon {
  font-size: 14px;
}

/* ==================== Prices ==================== */
.detail-prices {
  margin-bottom: 24px;
}

.price-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.price-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 14px 12px;
  text-align: center;
}

.price-card.highlighted {
  background: var(--bg-card);
  border: 2px solid var(--accent);
}

.price-card-period {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.price-card-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
}

.price-card-currency {
  font-size: 13px;
  font-weight: 400;
}

.price-card-unavailable {
  font-size: 12px;
  color: var(--text-secondary);
}

/* ==================== Conditions ==================== */
.detail-conditions {
  margin-bottom: 24px;
}

.conditions-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.condition-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--bg-card);
  border-radius: var(--radius);
}

.condition-icon {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border-radius: 8px;
  font-size: 18px;
}

.condition-content {
  flex: 1;
}

.condition-label {
  font-size: 12px;
  color: var(--text-secondary);
}

.condition-value {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}

/* ==================== Description ==================== */
.detail-description {
  margin-bottom: 24px;
}

.detail-description p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
}

/* ==================== Landlord Card ==================== */
.detail-landlord {
  margin-bottom: 24px;
}

.landlord-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  cursor: pointer;
}

.landlord-avatar {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  border-radius: 50%;
  font-size: 22px;
  color: white;
  font-weight: 600;
}

.landlord-info {
  flex: 1;
}

.landlord-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 2px;
}

.landlord-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  color: var(--text-secondary);
}

.landlord-rating .star {
  color: var(--warning);
}

.landlord-arrow {
  color: var(--text-secondary);
}

/* ==================== Detail Actions ==================== */
.detail-actions {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px;
  padding-bottom: calc(16px + env(safe-area-inset-bottom));
  background: var(--bg);
  border-top: 1px solid var(--border);
  z-index: 999;
}

.detail-actions .btn {
  position: relative;
  z-index: 1000;
}

/* ==================== Buttons ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  font-size: 15px;
  font-family: inherit;
  font-weight: 600;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--accent);
  color: var(--text);
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-large {
  width: 100%;
  padding: 16px 24px;
  font-size: 16px;
  border-radius: var(--radius-lg);
}

/* ==================== Modal ==================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: flex-end;
  justify-content: center;
}

.modal.active {
  display: flex;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.7);
  animation: fadeIn 0.2s ease;
  z-index: 1;
}

.modal-content {
  position: relative;
  width: 100%;
  z-index: 2;
  max-height: 85vh;
  background: var(--bg);
  color: var(--text);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  overflow: hidden;
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px;
  border-bottom: 1px solid var(--border);
}

.modal-header h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
}

.modal-close {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border: none;
  border-radius: 50%;
  font-size: 20px;
  color: var(--text);
  cursor: pointer;
}

.modal-body {
  padding: 20px;
  max-height: 60vh;
  overflow-y: auto;
}

.modal-footer {
  display: flex;
  gap: 12px;
  padding: 16px 20px;
  padding-bottom: calc(16px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--border);
}

.modal-footer .btn {
  flex: 1;
}

/* ==================== Contacts Modal ==================== */
.contacts-modal {
  max-width: 360px;
  border-radius: var(--radius-xl);
}

.contacts-modal-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 24px 20px 16px;
  text-align: center;
}

.contacts-modal-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  font-size: 24px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}

.contacts-modal-name {
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
  margin: 0;
}

.contacts-modal-body {
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--bg-card);
  border-radius: var(--radius);
}

.contact-icon {
  font-size: 20px;
  width: 24px;
  text-align: center;
}

.contact-info {
  flex: 1;
  min-width: 0;
}

.contact-label {
  display: block;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 2px;
}

.contact-value {
  display: block;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contact-value:hover {
  color: var(--accent);
}

.contact-copy {
  padding: 8px;
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.2s;
}

.contact-copy:hover {
  opacity: 1;
}

.contacts-modal-footer {
  padding: 16px 20px 24px;
  text-align: center;
}

.contacts-hint {
  font-size: 13px;
  color: var(--text-secondary);
  margin: 0;
}

/* ==================== Filter Groups ==================== */
.filter-group {
  margin-bottom: 20px;
}

.filter-group label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 10px;
  color: var(--text);
}

.range-inputs {
  display: flex;
  align-items: center;
  gap: 12px;
}

.range-inputs input {
  flex: 1;
  padding: 12px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 15px;
  color: var(--text);
  outline: none;
  transition: all 0.2s;
}

.range-inputs input::placeholder {
  color: var(--text-secondary);
}

.range-inputs input:focus {
  border-color: var(--accent);
}

.range-inputs span {
  color: var(--text-secondary);
}

.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.checkbox {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  font-size: 14px;
  color: var(--text);
}

.checkbox input {
  display: none;
}

.checkmark {
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: 6px;
  transition: all 0.2s;
}

.checkbox input:checked + .checkmark {
  background: var(--accent);
  border-color: var(--accent);
}

.checkbox input:checked + .checkmark::after {
  content: '';
  width: 6px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* ==================== Loading ==================== */
.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(26, 26, 26, 0.95);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}

.loading-overlay.active {
  display: flex;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--bg-card);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ==================== Favorites Page ==================== */
.favorites-list {
  padding: 16px;
}

.favorites-list .lot-card {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
}

.favorites-list .lot-card-image {
  width: 100px;
  padding-top: 0;
  height: 80px;
  border-radius: var(--radius);
  flex-shrink: 0;
}

.favorites-list .lot-card-content {
  flex: 1;
  padding: 4px 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* ==================== Responsive ==================== */
@media (min-width: 400px) {
  .lots-grid {
    gap: 16px;
  }

  .hero {
    height: 220px;
  }

  .hero-title {
    font-size: 28px;
  }
}

/* ==================== Landlord Promo ==================== */
.landlord-promo {
  padding: 8px 16px 24px;
}

.promo-card {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--accent);
  border-radius: var(--radius-lg);
  cursor: pointer;
  text-align: left;
  transition: all 0.2s;
  font-family: inherit;
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
}

.promo-card:active {
  transform: scale(0.98);
}

.promo-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border-radius: var(--radius);
  font-size: 24px;
}

.promo-content {
  flex: 1;
}

.promo-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.promo-desc {
  font-size: 13px;
  color: var(--text-secondary);
}

.promo-card svg {
  color: var(--text-secondary);
}

/* ==================== Landlord Dashboard ==================== */
.dashboard-header {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 16px;
  padding-right: 60px;
  background: var(--bg-secondary);
  color: var(--text);
}

.dashboard-avatar {
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  border-radius: 50%;
  font-size: 24px;
  font-weight: 600;
}

.dashboard-info {
  flex: 1;
}

.dashboard-name {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text);
}

.dashboard-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  color: var(--text-secondary);
}

.dashboard-settings {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: none;
  border-radius: 50%;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s;
}

.dashboard-settings:active {
  transform: scale(0.95);
}

.dashboard-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  padding: 16px;
  margin-top: -20px;
}

.dash-stat {
  background: linear-gradient(135deg, #f59e0b 0%, #f97316 100%);
  border-radius: var(--radius);
  padding: 16px 12px;
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.dash-stat-value {
  display: block;
  font-size: 24px;
  font-weight: 700;
  color: #1a1a1a;
}

.dash-stat-label {
  font-size: 12px;
  color: #422006;
  font-weight: 500;
}

.dashboard-actions {
  padding: 8px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.dash-action-card {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 16px;
  background: var(--bg-card);
  border: none;
  border-radius: var(--radius-lg);
  cursor: pointer;
  text-align: left;
  transition: all 0.2s;
  font-family: inherit;
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
}

.dash-action-card:active {
  transform: scale(0.98);
}

.dash-action-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border-radius: var(--radius);
  font-size: 22px;
}

.dash-action-content {
  flex: 1;
}

.dash-action-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.dash-action-desc {
  font-size: 13px;
  color: var(--text-secondary);
}

.dash-action-card svg {
  color: var(--text-secondary);
}

.dashboard-switch {
  padding: 24px 16px;
}

.btn-block {
  width: 100%;
}

/* ==================== My Lots ==================== */
.quick-actions {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
}

.btn-quick-action {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  font-family: inherit;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.btn-quick-action:active {
  transform: scale(0.98);
}

.btn-quick-action:first-child {
  background: var(--accent);
  border-color: var(--accent);
}

.btn-quick-action.btn-mark-all-rented {
  background: #6b7280;
  border-color: #6b7280;
  color: #fff;
}

.quick-action-icon {
  font-size: 16px;
}

.my-lots-tabs,
.requests-tabs {
  display: flex;
  gap: 8px;
  padding: 16px 16px 12px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.my-lots-list,
.requests-list {
  padding: 0 16px 100px;
}

.my-lot-card {
  display: flex;
  gap: 12px;
  padding: 14px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  margin-bottom: 12px;
  cursor: pointer;
}

.my-lot-card:active {
  transform: scale(0.99);
}

.my-lot-image {
  width: 80px;
  height: 80px;
  border-radius: var(--radius);
  background: var(--bg-secondary);
  overflow: hidden;
  flex-shrink: 0;
}

.my-lot-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.my-lot-image .placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  opacity: 0.5;
}

.my-lot-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.my-lot-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.my-lot-price {
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
  margin-bottom: 6px;
}

.my-lot-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  width: fit-content;
}

.my-lot-status.published {
  background: rgba(34, 197, 94, 0.2);
  color: #22c55e;
}

.my-lot-status.rented {
  background: rgba(107, 114, 128, 0.2);
  color: #9ca3af;
}

.my-lot-status.draft {
  background: var(--bg-secondary);
  color: var(--text-secondary);
}

.my-lot-status.hidden {
  background: rgba(239, 68, 68, 0.2);
  color: var(--danger);
}

.my-lot-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
  background: var(--danger);
  color: white;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  padding: 0 6px;
}

/* Landlord Lot Card */
.landlord-lot-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  margin-bottom: 12px;
  overflow: hidden;
  transition: all 0.2s;
  border: 2px solid transparent;
}

.landlord-lot-card.status-published {
  border-color: #22c55e;
}

.landlord-lot-card.status-rented {
  border-color: #6b7280;
  opacity: 0.7;
}

.landlord-lot-card.status-draft {
  border-color: var(--border);
  opacity: 0.6;
}

.landlord-lot-card-main {
  display: flex;
  gap: 12px;
  padding: 14px;
  cursor: pointer;
}

.landlord-lot-image {
  position: relative;
  width: 80px;
  height: 80px;
  border-radius: var(--radius);
  background: var(--bg-secondary);
  overflow: hidden;
  flex-shrink: 0;
}

.landlord-lot-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.landlord-lot-image .placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  opacity: 0.5;
}

.lot-status-badge {
  position: absolute;
  bottom: 4px;
  left: 4px;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 600;
}

.lot-status-badge.published {
  background: #22c55e;
  color: #000;
}

.lot-status-badge.rented {
  background: #6b7280;
  color: #fff;
}

.lot-status-badge.draft {
  background: var(--bg-secondary);
  color: var(--text);
}

.landlord-lot-info {
  flex: 1;
  min-width: 0;
}

.landlord-lot-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.landlord-lot-price {
  font-size: 13px;
  color: var(--text);
  font-weight: 500;
  margin-bottom: 4px;
}

.landlord-lot-meta {
  display: flex;
  gap: 12px;
  font-size: 11px;
  color: var(--text-secondary);
}

.lot-time-counter {
  position: absolute;
  top: 4px;
  right: 4px;
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  background: rgba(0, 0, 0, 0.7);
  border-radius: 4px;
  font-size: 10px;
  font-weight: 600;
  color: var(--text);
}

.lot-time-counter.expiring {
  background: var(--warning);
  color: #000;
}

.lot-time-counter.expired {
  background: var(--danger);
  color: var(--text);
}

.landlord-lot-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: center;
}

.landlord-lot-status-controls {
  display: flex;
  gap: 8px;
  padding: 0 14px 14px;
  border-top: 1px solid var(--border);
  padding-top: 10px;
}

.lot-action-btn {
  padding: 6px 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
}

.lot-action-btn:active {
  transform: scale(0.95);
}

.lot-status-toggle {
  display: flex;
  gap: 6px;
  margin-left: auto;
}

.btn-status-toggle {
  flex: 1;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-family: inherit;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  -webkit-appearance: none;
  appearance: none;
}

.btn-status-toggle.available {
  background: var(--bg-secondary);
  color: var(--text);
  border: 1px solid #22c55e;
}

.btn-status-toggle.available:hover,
.btn-status-toggle.available.active {
  background: #22c55e;
  color: #000;
}

.btn-status-toggle.rented {
  background: var(--bg-secondary);
  color: var(--text);
  border: 1px solid #6b7280;
}

.btn-status-toggle.rented:hover,
.btn-status-toggle.rented.active {
  background: #6b7280;
  color: #fff;
}

/* ==================== FAB ==================== */
.fab {
  position: fixed;
  bottom: calc(24px + env(safe-area-inset-bottom));
  right: 16px;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: var(--text);
  border: none;
  border-radius: 50%;
  box-shadow: var(--shadow-xl);
  cursor: pointer;
  z-index: 50;
  transition: all 0.2s;
}

.fab:active {
  transform: scale(0.95);
}

/* ==================== Lot Form ==================== */
.lot-form,
.profile-form {
  padding: 16px;
  padding-bottom: 100px;
}

.form-section {
  margin-bottom: 24px;
}

.form-section-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
}

.form-group {
  margin-bottom: 16px;
}

.form-group.checkbox-row {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

.form-group.checkbox-row .checkbox {
  flex: 0 0 auto;
}

.form-group > label:not(.checkbox) {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 15px;
  color: var(--text);
  outline: none;
  transition: all 0.2s;
  font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.type-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.type-toggle-btn {
  padding: 14px;
  background: var(--bg-card);
  border: 2px solid transparent;
  border-radius: var(--radius);
  font-size: 15px;
  font-family: inherit;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.type-toggle-btn.active {
  border-color: var(--accent);
  background: rgba(51, 144, 236, 0.1);
}

.price-inputs {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.price-input-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.price-input-group .checkbox {
  flex-shrink: 0;
  width: 100px;
}

.price-input-group input {
  flex: 1;
  padding: 12px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 15px;
  color: var(--text);
  outline: none;
}

.price-input-group input:focus {
  border-color: var(--accent);
}

/* ==================== Photos Upload ==================== */
.photos-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 12px;
}

.photo-item {
  position: relative;
  width: 100%;
  padding-top: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-secondary);
}

.photo-item img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-item-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.6);
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 14px;
  cursor: pointer;
  z-index: 2;
}

.photo-item-main {
  position: absolute;
  bottom: 4px;
  left: 4px;
  padding: 2px 8px;
  background: var(--accent);
  color: white;
  font-size: 10px;
  font-weight: 600;
  border-radius: 4px;
}

.photo-add-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px;
  background: var(--bg-card);
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.photo-add-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ==================== Form Actions ==================== */
.form-actions {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  gap: 12px;
  padding: 16px;
  padding-bottom: calc(16px + env(safe-area-inset-bottom));
  background: var(--bg);
  border-top: 1px solid var(--border);
  z-index: 100;
}

.form-actions .btn {
  flex: 1;
}

/* ==================== Requests ==================== */
.request-card {
  padding: 14px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  margin-bottom: 12px;
  cursor: pointer;
}

.request-card:active {
  transform: scale(0.99);
}

.request-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.request-card-avatar {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  border-radius: 50%;
  color: white;
  font-size: 16px;
  font-weight: 600;
}

.request-card-info {
  flex: 1;
}

.request-card-name {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 2px;
  color: var(--text);
}

.request-card-date {
  font-size: 12px;
  color: var(--text-secondary);
}

.request-card-status {
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 500;
}

.request-card-status.pending {
  background: rgba(251, 191, 36, 0.2);
  color: var(--warning);
}

.request-card-status.available {
  background: rgba(74, 222, 128, 0.2);
  color: var(--success);
}

.request-card-status.unavailable {
  background: rgba(239, 68, 68, 0.2);
  color: var(--danger);
}

.request-card-lot {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  background: var(--bg-secondary);
  border-radius: var(--radius);
}

.request-card-lot-image {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  overflow: hidden;
  background: var(--bg-card);
}

.request-card-lot-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.request-card-lot-title {
  flex: 1;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}

/* Request card new styles */
.request-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.request-lot-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.request-lot-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.request-time {
  font-size: 12px;
  color: var(--text-secondary);
}

.request-user {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.request-user-avatar {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  font-size: 16px;
  font-weight: 600;
}

.request-user-info {
  flex: 1;
}

.request-user-name {
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
}

.request-user-username {
  font-size: 13px;
  color: var(--accent);
  text-decoration: none;
}

.request-contact {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: var(--bg-secondary);
  border-radius: var(--radius);
  margin-bottom: 12px;
}

.request-contact-label {
  font-size: 13px;
  color: var(--text-secondary);
}

.request-contact-value {
  font-size: 14px;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
}

.request-message {
  font-size: 14px;
  color: var(--text-secondary);
  font-style: italic;
  padding: 10px 12px;
  background: var(--bg-secondary);
  border-radius: var(--radius);
  margin-bottom: 12px;
}

.request-actions {
  display: flex;
  gap: 8px;
}

.request-action-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 14px;
  font-family: inherit;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
  border: none;
}

.request-action-btn.telegram {
  background: #0088cc;
  color: #fff;
}

.request-action-btn.phone {
  background: var(--success);
  color: #fff;
}

.request-action-btn:active {
  transform: scale(0.98);
}

.request-status-btn {
  padding: 6px 12px;
  border-radius: 16px;
  font-size: 12px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
  border: none;
}

.request-status-btn.new {
  background: var(--accent);
  color: #fff;
}

.request-status-btn.processed {
  background: var(--bg-secondary);
  color: var(--text-secondary);
}

.request-status-btn:active {
  transform: scale(0.95);
}

.request-card.processed {
  opacity: 0.7;
}

.request-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.request-lot-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.request-lot-title {
  font-weight: 600;
  font-size: 15px;
  color: var(--text);
}

.request-time {
  font-size: 12px;
  color: var(--text-secondary);
}

/* ==================== Setup Screen ==================== */
.page-setup {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding: 20px;
  padding-top: calc(20px + env(safe-area-inset-top));
  background: var(--bg);
  color: var(--text);
}

.setup-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 400px;
  margin: 0 auto;
  width: 100%;
}

.setup-header {
  text-align: center;
  margin-bottom: 32px;
}

.setup-logo {
  font-size: 48px;
  margin-bottom: 16px;
}

.setup-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}

.setup-subtitle {
  font-size: 14px;
  color: var(--text-secondary);
  margin-top: 8px;
}

.or-divider {
  font-size: 14px;
  font-weight: 400;
  opacity: 0.7;
}

.language-options,
.role-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.language-btn {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 20px;
  background: var(--bg-card);
  border: 2px solid transparent;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all 0.2s;
  text-align: left;
  font-family: inherit;
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
}

.language-btn:active {
  transform: scale(0.98);
}

.language-btn.selected {
  border-color: var(--accent);
}

.language-flag {
  font-size: 32px;
  line-height: 1;
}

.language-name {
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
}

/* Compact language switcher */
.language-switcher {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 20px;
}

.language-switcher .language-btn {
  padding: 10px 20px;
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: 20px;
  font-size: 14px;
  font-family: inherit;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.language-switcher .language-btn:active {
  transform: scale(0.95);
}

.language-switcher .language-btn.active {
  background: var(--accent);
  border-color: var(--accent);
}

.role-btn {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  padding: 20px;
  background: var(--bg-card);
  border: 2px solid transparent;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all 0.2s;
  text-align: left;
  font-family: inherit;
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
}

.role-btn:active {
  transform: scale(0.98);
}

.role-btn.selected {
  border-color: var(--accent);
}

.role-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border-radius: var(--radius);
  font-size: 28px;
  flex-shrink: 0;
}

.role-content {
  flex: 1;
}

.role-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
}

.role-desc {
  font-size: 13px;
  color: var(--text-secondary);
}

.role-title-en {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 500;
}

/* ==================== Welcome Screen ==================== */
.welcome-text {
  text-align: center;
  margin-bottom: 32px;
}

.welcome-greeting {
  font-size: 20px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 8px;
}

.welcome-block {
  margin-bottom: 20px;
  padding: 16px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  text-align: left;
  border-left: 3px solid var(--accent);
}

.welcome-block-ru {
  border-left-color: var(--accent);
}

.welcome-block-en {
  border-left-color: var(--success);
}

.welcome-tagline {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 12px;
  line-height: 1.4;
}

.welcome-desc {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 10px;
  line-height: 1.5;
}

.welcome-features {
  list-style: none;
  padding: 0;
  margin: 0 0 12px 0;
}

.welcome-features li {
  font-size: 14px;
  color: var(--text);
  padding: 4px 0;
}

.welcome-pricing {
  font-size: 14px;
  font-weight: 500;
  color: var(--accent);
  line-height: 1.4;
}

/* ==================== Landlord Onboarding ==================== */
.pricing-info {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
}

.pricing-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
}

.pricing-icon {
  font-size: 28px;
}

.pricing-text {
  flex: 1;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
}

.pricing-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
}

.pricing-note {
  text-align: center;
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.pricing-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.onboarding-form {
  margin-bottom: 24px;
}

.onboarding-hint {
  font-size: 14px;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 16px;
}

.onboarding-input {
  width: 100%;
  padding: 16px;
  background: var(--bg-card);
  border: 2px solid transparent;
  border-radius: var(--radius);
  font-size: 16px;
  color: var(--text);
  outline: none;
  transition: all 0.2s;
  margin-bottom: 12px;
}

.onboarding-input:focus {
  border-color: var(--accent);
}

.contact-input-group {
  margin-bottom: 16px;
}

.contact-input-group label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 8px;
}

/* ==================== Filter Button Groups ==================== */
.filter-btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-range-btn {
  padding: 10px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  font-family: inherit;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  -webkit-appearance: none;
  appearance: none;
}

.filter-range-btn:hover {
  color: var(--text);
}

.filter-range-btn:active {
  transform: scale(0.98);
}

.filter-range-btn.active {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}

/* ==================== Form Selector Button Groups ==================== */
.selector-btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.selector-btn {
  padding: 10px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  font-family: inherit;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.selector-btn:hover {
  color: var(--text);
}

.selector-btn:active {
  transform: scale(0.98);
}

.selector-btn.active {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}

.selector-custom-input {
  display: none;
  margin-top: 10px;
}

.selector-custom-input.visible {
  display: block;
}

.selector-custom-input input {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 15px;
  color: var(--text);
  outline: none;
}

/* ==================== Guide Section ==================== */
.guide-section {
  padding: 24px 16px 32px;
}

.guide-block {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  margin-bottom: 12px;
  overflow: hidden;
}

.guide-block summary {
  padding: 16px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.guide-block summary::after {
  content: '▼';
  font-size: 10px;
  color: var(--text-secondary);
  transition: transform 0.2s;
}

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

.guide-list {
  padding: 0 16px 16px 32px;
  margin: 0;
}

.guide-list li {
  font-size: 14px;
  color: var(--text);
  padding: 6px 0;
  line-height: 1.5;
}

/* ==================== Location Filter ==================== */
.filter-location-current {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: var(--bg-card);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.2s;
  margin-bottom: 12px;
}

.filter-location-current:active {
  transform: scale(0.98);
}

.filter-location-icon {
  font-size: 16px;
  margin-right: 8px;
}

.filter-location-name {
  flex: 1;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}

.filter-location-change {
  padding: 6px 12px;
  background: var(--accent);
  color: var(--text);
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.filter-location-change:active {
  transform: scale(0.95);
}

.filter-district-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-district-chip {
  padding: 8px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 13px;
  font-family: inherit;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
  white-space: nowrap;
  flex-shrink: 0;
}

.filter-district-chip:active {
  transform: scale(0.95);
}

.filter-district-chip.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
}

/* Location Picker Overlay */
.location-picker-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.location-picker-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.location-picker {
  width: 100%;
  max-height: 70vh;
  background: var(--bg);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  overflow: hidden;
  transform: translateY(100%);
  transition: transform 0.3s ease-out;
}

.location-picker-overlay.active .location-picker {
  transform: translateY(0);
}

.location-picker-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  border-bottom: 1px solid var(--border);
}

.location-picker-header h3 {
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
}

.location-picker-close {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  font-size: 18px;
  color: var(--text);
}

.location-picker-list {
  overflow-y: auto;
  max-height: calc(70vh - 60px);
}

.location-picker-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 14px 16px;
  background: var(--bg);
  border: none;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background 0.2s;
  font-family: inherit;
  font-size: 15px;
  color: var(--text);
  text-align: left;
  -webkit-appearance: none;
  appearance: none;
}

.location-picker-item:active {
  background: var(--bg-secondary);
}

.location-picker-item.active {
  background: rgba(51, 144, 236, 0.1);
}

.location-picker-item-name {
  font-size: 15px;
  color: var(--text);
}

.location-picker-item-check {
  color: var(--accent);
  font-size: 16px;
}

/* ==================== Subscription Status ==================== */
.subscription-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  margin: 0 16px -8px;
  background: var(--bg-card);
  border-radius: var(--radius);
}

.subscription-status.status-trial {
  border: 1px solid var(--accent);
}

.subscription-status.status-active {
  border: 1px solid var(--success);
}

.subscription-status.status-expired {
  border: 1px solid var(--danger);
}

.subscription-status .status-icon {
  font-size: 18px;
}

.subscription-status .status-text {
  flex: 1;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}

.subscription-status .btn-subscribe {
  padding: 6px 12px;
  background: var(--accent);
  color: var(--text);
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

/* Balance Section */
.balance-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  margin: 8px 16px 0;
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

.balance-section .balance-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 0;
  background: transparent;
}

.balance-section .balance-label {
  font-size: 12px;
  color: var(--text-secondary);
}

.balance-section .balance-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
}

.btn-pay {
  padding: 8px 16px;
  font-size: 14px;
  -webkit-appearance: none;
  appearance: none;
}

/* Top Up Modal */
.topup-amounts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

.topup-btn {
  padding: 14px;
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 16px;
  font-family: inherit;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.topup-btn:hover,
.topup-btn:active {
  border-color: var(--accent);
  background: rgba(51, 144, 236, 0.1);
}

.payment-note {
  font-size: 13px;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 16px;
}

/* Subscription Modal */
.subscription-info {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.balance-info {
  font-size: 15px;
  color: var(--text);
  padding: 12px;
  background: var(--bg-card);
  border-radius: var(--radius);
  margin: 16px 0;
}

.balance-info strong {
  color: var(--accent);
}

.referral-block {
  padding: 16px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  margin-top: 16px;
  border: 1px solid var(--border);
}

.referral-label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.referral-code-box {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--bg-secondary);
  border-radius: var(--radius);
}

.referral-code {
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  font-family: monospace;
  color: var(--accent);
  letter-spacing: 1px;
}

.btn-copy {
  padding: 6px 10px;
  background: var(--accent);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  color: var(--text);
}

.referral-hint {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 10px;
  text-align: center;
}

/* Referral Input in Onboarding */
.referral-input-group {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px dashed var(--border);
}

.referral-input-group label {
  font-size: 13px;
  color: var(--text-secondary);
}

.referral-status {
  font-size: 13px;
  margin-top: 6px;
  min-height: 18px;
}

.referral-status.valid {
  color: var(--success);
}

.referral-status.invalid {
  color: var(--danger);
}

/* ==================== Global Input Styles ==================== */
input, select, textarea {
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid var(--border);
}

input::placeholder {
  color: var(--text-secondary);
}

input:focus, select:focus, textarea:focus {
  border-color: var(--accent);
  outline: none;
}

/* ==================== Landlord Profile View (for tenants) ==================== */
.page-landlord-view {
  padding: 16px;
}

.landlord-profile-view {
  max-width: 600px;
  margin: 0 auto;
}

.landlord-profile-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  margin-bottom: 16px;
}

.landlord-profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 600;
  flex-shrink: 0;
}

.landlord-profile-info {
  flex: 1;
}

.landlord-profile-name {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 4px;
}

.landlord-profile-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  color: var(--text-secondary);
}

.landlord-profile-rating .star {
  font-size: 14px;
}

.landlord-profile-location {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.landlord-profile-description {
  padding: 16px;
  background: var(--bg-card);
  border-radius: var(--radius);
  margin-bottom: 16px;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
}

.landlord-lots-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.landlord-lots-list .lot-card {
  cursor: pointer;
}

.landlord-lots-list .empty-text {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--text-secondary);
  padding: 40px 20px;
}

.landlord-profile-since {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 4px;
}

.landlord-actions {
  display: flex;
  gap: 12px;
  margin: 16px 0;
}

.landlord-actions .btn {
  flex: 1;
  padding: 12px 16px;
  font-size: 14px;
}

/* Reviews List */
.landlord-reviews-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.review-item {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 12px 16px;
}

.review-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.review-author {
  font-weight: 500;
  font-size: 14px;
  color: var(--text);
}

.review-date {
  font-size: 12px;
  color: var(--text-tertiary);
}

.review-stars {
  font-size: 12px;
  margin-bottom: 6px;
}

.review-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin: 0;
}

.landlord-reviews-list .empty-text {
  text-align: center;
  color: var(--text-secondary);
  padding: 30px 20px;
}

/* Rating Modal */
.rating-stars-select {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 20px 0;
}

.star-btn {
  font-size: 32px;
  cursor: pointer;
  opacity: 0.3;
  transition: opacity 0.2s, transform 0.2s;
}

.star-btn:hover {
  transform: scale(1.1);
}

.star-btn.selected {
  opacity: 1;
}

/* ==================== Request Modal ==================== */
#requestModal {
  align-items: center;
  justify-content: center;
}

#requestModal .modal-content {
  border-radius: var(--radius-lg);
  max-width: 400px;
  width: 90%;
  margin: 20px;
}

.request-modal {
  padding: 24px;
  text-align: center;
}

.request-modal .modal-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 8px;
}

.request-modal .modal-subtitle {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.request-modal .form-group {
  margin-bottom: 16px;
  text-align: left;
  position: relative;
  z-index: 10;
}

.request-modal .form-input {
  display: block;
  width: 100%;
  padding: 14px 16px;
  font-size: 16px;
  border-radius: var(--radius);
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text);
  box-sizing: border-box;
  -webkit-appearance: none;
  appearance: none;
  pointer-events: auto;
}

.request-modal .form-input:focus {
  border-color: var(--accent);
  outline: none;
}

.request-modal textarea.form-input {
  resize: none;
  min-height: 80px;
}

.request-modal .btn-large {
  margin-top: 8px;
  width: 100%;
}
