/* ==========================================================================
   Vgorode Modals & Dialog System (Auth, Route Search, Driver Registration, Item Fullscreen Preview)
   ========================================================================== */

/* ==========================================================================
   9. Личный кабинет пассажира и Авторизация (VK ID / Яндекс ID)
   ========================================================================== */
.btn-user-header {
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  color: var(--text-main);
  font-size: 0.82rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.btn-user-header:hover {
  background: var(--bg-hover);
  border-color: #cbd5e1;
}

.header-user-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 12px 4px 6px;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all 0.15s ease;
}

.header-user-badge:hover {
  background: var(--bg-hover);
  border-color: #cbd5e1;
}

.user-avatar-mini {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #0f172a;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.84rem;
  font-weight: 500;
}

.user-name-mini {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-main);
}

.user-rating-mini {
  font-size: 0.88rem;
  color: var(--accent-amber);
  font-weight: 500;
}

/* Социальные кнопки авторизации (VK ID, Яндекс ID) */
.btn-social-auth {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  height: 52px;
  padding: 0 20px;
  border-radius: 16px;
  border: none;
  cursor: pointer;
  transition: all 0.15s ease;
  width: 100%;
  text-align: center;
  box-sizing: border-box;
  font-size: 16px;
  font-weight: 600;
}

.btn-vk-id {
  background: #0077ff;
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(0, 119, 255, 0.28);
}

.btn-vk-id:hover {
  background: #0066dd;
  box-shadow: 0 4px 14px rgba(0, 119, 255, 0.35);
}

.btn-yandex-id {
  background: #000000;
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
}

.btn-yandex-id:hover {
  background: #1a1a1a;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

.yandex-icon-badge {
  width: 24px;
  height: 24px;
  background: #fc3f1d;
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 500;
  font-size: 0.95rem;
  flex-shrink: 0;
}

.auth-btn-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.auth-btn-title {
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1.2;
}

.auth-btn-sub {
  font-size: 0.84rem;
  opacity: 0.85;
  font-weight: 400;
}

.auth-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 16px 0 12px;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid var(--border-light);
}

.auth-divider span {
  padding: 0 10px;
}

/* Профиль в ЛК */
.passenger-lk-hero {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-light);
}

.passenger-lk-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #0f172a;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 500;
  flex-shrink: 0;
}

.passenger-lk-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.passenger-lk-name {
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text-main);
}

.passenger-lk-phone {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.passenger-lk-badges {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}

.lk-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
}

.lk-section-title {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.lk-saved-addrs {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.lk-addr-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 8px 12px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.lk-addr-item:hover {
  background: var(--bg-hover);
  border-color: #cbd5e1;
}

.lk-addr-icon {
  font-size: 1.1rem;
}

.lk-addr-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.lk-addr-name {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-main);
}

.lk-addr-detail {
  font-size: 0.86rem;
  color: var(--text-muted);
}

.lk-addr-pick-btn {
  font-size: 0.84rem;
  color: var(--accent-blue);
  font-weight: 500;
}

.lk-trips-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.lk-trip-card {
  background: var(--bg-input);
  border-radius: var(--radius-md);
  padding: 8px 12px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.lk-trip-route {
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-main);
}

.lk-trip-meta {
  font-size: 0.86rem;
  color: var(--text-muted);
}


/* -------------------------------------------------------------------------- */

/* ==========================================================================
   11. Модальная система & Полноценные Окна (Full Screen / Dialog System)
   ГЛОБАЛЬНОЕ ПРАВИЛО: font-weight максимум 500!
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: fadeInModal 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-backdrop.hidden {
  display: none !important;
}

@keyframes fadeInModal {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-card {
  background: #ffffff;
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.25), 0 0 1px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  animation: slideUpModal 0.24s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

@keyframes slideUpModal {
  from { transform: translateY(20px) scale(0.98); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-light);
  background: #ffffff;
  flex-shrink: 0;
}

.modal-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 500;
  color: var(--text-main);
}

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

.modal-close-btn:hover {
  background: var(--bg-hover);
  color: var(--text-main);
}

.modal-body {
  padding: 18px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 14px 18px;
  border-top: 1px solid var(--border-light);
  background: #ffffff;
  flex-shrink: 0;
}

.btn-modal-cancel {
  padding: 10px 16px;
  border-radius: var(--radius-md);
  background: var(--bg-input);
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.88rem;
}
.btn-modal-cancel:hover {
  background: var(--bg-hover);
  color: var(--text-main);
}

/* Меню сервиса (Боковая шторка меню) */
#mobile-main-menu:not(.hidden) {
  padding: 0 !important;
  display: flex !important;
  align-items: stretch !important;
  justify-content: flex-start !important;
}

#mobile-main-menu .mobile-menu-sheet {
  width: 330px !important;
  max-width: 85vw !important;
  height: 100% !important;
  height: 100dvh !important;
  max-height: 100dvh !important;
  border-radius: 0 !important;
  margin: 0 !important;
  background: #ffffff !important;
  box-shadow: 4px 0 25px rgba(0, 0, 0, 0.2) !important;
  display: flex !important;
  flex-direction: column !important;
  overflow-y: auto !important;
}

.menu-list-items {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 14px;
}

.menu-item-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-lg);
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: all 0.15s ease;
}

.menu-item-row:hover {
  background: var(--bg-hover);
}

.menu-item-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
}

.menu-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.menu-item-title {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-main);
}

.menu-item-sub {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-weight: 400;
}

.menu-item-arrow {
  font-size: 1.2rem;
  color: var(--text-subtle);
}

.menu-item-row.logout-row .menu-item-title {
  color: var(--accent-red);
}


/* -------------------------------------------------------------------------- */

/* ==========================================================================
   12. ПОЛНОЦЕННОЕ ОКНО ПОИСКА ВОДИТЕЛЯ (Full Search Window)
   ========================================================================== */
.full-search-window-card {
  max-width: 640px;
  height: 88vh;
  max-height: 800px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #ffffff;
  border-radius: var(--radius-xl);
}

@media (max-width: 768px) {
  .full-search-window-card {
    max-width: 100vw !important;
    width: 100vw !important;
    height: 100% !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    border-radius: 0 !important;
    padding: 0 !important;
  }
}

.search-window-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-light);
  background: #ffffff;
  flex-shrink: 0;
}

.btn-window-back {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: var(--bg-input);
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-main);
  border: 1px solid var(--border-light);
  cursor: pointer;
}
.btn-window-back:hover {
  background: var(--bg-hover);
}

.search-window-title-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}

.search-window-h3 {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text-main);
}

.search-radar-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--accent-green);
  background: rgba(16, 185, 129, 0.1);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.radar-dot-pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-green);
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulseGreen 1.4s infinite;
}

@keyframes pulseGreen {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 7px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

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

.search-window-route-card {
  margin: 12px 18px 0;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.search-route-endpoints {
  display: flex;
  flex-direction: column;
  gap: 3px;
  position: relative;
}

.search-endpoint-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-main);
}

.endpoint-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.search-endpoint-connector {
  width: 2px;
  height: 10px;
  background: #cbd5e1;
  margin-left: 10px;
}

.search-route-meta-chips {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 2px;
}

.route-badge-pill {
  font-size: 0.84rem;
  font-weight: 500;
  padding: 2px 8px;
  background: rgba(37, 99, 235, 0.1);
  color: var(--accent-blue);
  border-radius: var(--radius-pill);
}

.route-meta-pill {
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-muted);
}

.search-window-price-box {
  margin: 10px 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #ffffff;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-lg);
}

.search-price-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.search-price-lbl {
  font-size: 0.84rem;
  color: var(--text-muted);
  font-weight: 400;
}

.search-price-val-wrap {
  display: flex;
  align-items: baseline;
  gap: 3px;
}

.search-price-val {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 500;
  color: var(--text-main);
}

.search-price-currency {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
}

.search-quick-bids {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

.bids-caption {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 400;
}

.bids-chips {
  display: flex;
  gap: 4px;
}

.b-chip {
  padding: 4px 8px;
  border-radius: var(--radius-pill);
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.15s ease;
}
.b-chip:hover {
  background: var(--accent-orange);
  border-color: var(--accent-orange);
  color: #ffffff;
}

.search-window-offers-block {
  flex: 1;
  overflow-y: auto;
  padding: 12px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.offers-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.offers-head-title {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-main);
}

.offers-live-tag {
  font-size: 0.84rem;
  color: var(--accent-green);
  font-weight: 500;
}

.search-offers-instruction {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-weight: 400;
  line-height: 1.3;
}

.search-window-offers-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.search-window-footer {
  padding: 12px 18px;
  border-top: 1px solid var(--border-light);
  background: #ffffff;
  flex-shrink: 0;
}

.btn-cancel-search {
  width: 100%;
  padding: 11px 0;
  border-radius: var(--radius-md);
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
}
.btn-cancel-search:hover {
  background: #fee2e2;
  border-color: #fca5a5;
  color: var(--accent-red);
}

/* Карточка оффера в окне поиска */
.search-offer-card {
  background: #ffffff;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: all 0.18s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.search-offer-card:hover {
  border-color: #94a3b8;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  transform: translateY(-1px);
}

.search-offer-card .card-lime-strip {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-lime);
}

.search-offer-row-1 {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.drv-avatar-box {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  overflow: hidden;
  background: #0f172a;
  flex-shrink: 0;
  position: relative;
  border: 1.5px solid #e2e8f0;
}

.drv-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.drv-info-col {
  flex: 1;
  margin-left: 10px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.drv-name-line {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 6px;
}

.drv-stars {
  font-size: 0.88rem;
  color: var(--accent-amber);
  font-weight: 500;
}

.drv-car-line {
  font-size: 0.90rem;
  color: var(--text-muted);
  font-weight: 400;
}

.search-offer-price-col {
  text-align: right;
}

.search-offer-price {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-main);
}

.search-offer-eta {
  font-size: 0.86rem;
  color: var(--accent-green);
  font-weight: 500;
}

.search-offer-row-2 {
  display: flex;
  width: 100%;
}

.btn-offer-accept {
  width: 100%;
  flex: 1;
  padding: 11px 14px;
  border-radius: var(--radius-md);
  background: var(--accent-orange);
  border: none;
  font-size: 0.92rem;
  font-weight: 500;
  color: #ffffff;
  text-align: center;
  cursor: pointer;
  box-shadow: 0 3px 10px var(--accent-orange-glow);
  transition: all 0.15s ease;
}
.btn-offer-accept:hover {
  background: var(--accent-orange-hover);
  transform: translateY(-1px);
}


/* -------------------------------------------------------------------------- */

/* ==========================================================================
   13. ПОЛНОЦЕННАЯ СТРАНИЦА КАРТОЧКИ ВОДИТЕЛЯ (Driver Full Page Card)
   ========================================================================== */
.driver-full-page-card {
  max-width: 680px;
  height: 92vh;
  max-height: 860px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #ffffff;
  border-radius: var(--radius-xl);
}

@media (max-width: 768px) {
  .driver-full-page-card {
    max-width: 100vw !important;
    width: 100vw !important;
    height: 100% !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    border-radius: 0 !important;
    padding: 0 !important;
  }
}

.driver-page-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  border-bottom: 1px solid var(--border-light);
  background: #ffffff;
  flex-shrink: 0;
}

.btn-page-back {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: var(--bg-input);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-main);
  border: 1px solid var(--border-light);
  cursor: pointer;
}
.btn-page-back:hover {
  background: var(--bg-hover);
}

.driver-page-title {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text-main);
}

.driver-page-scrollable {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-bottom: 20px;
}

.driver-car-hero-banner {
  position: relative;
  width: 100%;
  height: 220px;
  overflow: hidden;
  background: #1e293b;
}

@media (max-width: 768px) {
  .driver-car-hero-banner {
    height: 190px;
  }
}

.driver-car-photo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.driver-car-photo-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 14px 18px;
  background: linear-gradient(to top, rgba(15,23,42,0.9) 0%, rgba(15,23,42,0.4) 60%, rgba(15,23,42,0) 100%);
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
}

.car-info-tag {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.car-title-bold {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 500;
  color: #ffffff;
  text-shadow: 0 1px 4px rgba(0,0,0,0.6);
}

.car-color-year {
  font-size: 0.82rem;
  color: #e2e8f0;
  font-weight: 400;
  text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}

/* Госномер РФ */
.license-plate-badge {
  background: #ffffff;
  border: 1.5px solid #0f172a;
  border-radius: 4px;
  padding: 2px 7px;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  font-family: monospace;
}

.plate-number {
  font-size: 0.95rem;
  font-weight: 500;
  color: #0f172a;
  letter-spacing: 1px;
}

.plate-region {
  display: flex;
  flex-direction: column;
  align-items: center;
  border-left: 1px solid #94a3b8;
  padding-left: 5px;
  line-height: 1;
}

.reg-code {
  font-size: 0.84rem;
  font-weight: 500;
  color: #0f172a;
}

.reg-country {
  font-size: 0.90rem;
  color: #64748b;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 2px;
}

.rus-flag {
  width: 8px;
  height: 5px;
  background: linear-gradient(to bottom, #ffffff 33%, #0039a6 33%, #0039a6 66%, #d52b1e 66%);
  border: 0.5px solid #94a3b8;
  display: inline-block;
}

/* Главный герой профиля водителя */
.driver-profile-main-hero {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px 18px;
  margin-top: 10px;
  background: #ffffff;
}

.driver-header-profile-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.driver-avatar-container {
  position: relative;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}

.driver-real-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2.5px solid #ffffff;
}

.driver-modal-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff6b00 0%, #ea580c 100%);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 500;
  border: 2.5px solid #ffffff;
}

.avatar-online-indicator {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #10b981;
  border: 2px solid #ffffff;
}

.driver-title-and-badges {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}

.driver-h3-name {
  font-family: inherit;
  font-size: 1.25rem;
  font-weight: 500;
  color: #0f172a;
  line-height: 1.3;
  margin: 0;
  word-break: break-word;
}

.driver-tags-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.badge-verified-580 {
  font-size: 0.86rem;
  font-weight: 500;
  background: #ecfdf5;
  color: #059669;
  border: 1px solid #a7f3d0;
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
}

.badge-reliability {
  color: #2563eb;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  font-weight: 500;
  font-size: 0.86rem;
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
}

.driver-quick-specs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 10px 8px;
  margin-top: 2px;
}

.spec-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2px;
  min-width: 0;
}

.spec-label {
  font-size: 0.82rem;
  color: #64748b;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.spec-val-row {
  display: flex;
  align-items: center;
  justify-content: center;
}

.rating-stars-badge {
  font-size: 0.95rem;
  font-weight: 500;
  color: #d97706;
}

.spec-value {
  font-size: 0.95rem;
  font-weight: 500;
  color: #0f172a;
}

.spec-sub-text {
  font-size: 0.82rem;
  color: #94a3b8;
  font-weight: 400;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.spec-highlight {
  color: #16a34a !important;
  font-weight: 500;
}

/* Карточки секций страницы водителя */
.driver-section-card {
  margin: 0 18px;
  padding: 14px;
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.driver-section-h4 {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-main);
}

.driver-bio-text {
  font-size: 0.84rem;
  color: #334155;
  line-height: 1.45;
  font-weight: 400;
}

.driver-amenities-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.amenity-chip {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-main);
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  padding: 4px 10px;
}

/* Встроенный чат в карточке водителя */
.chat-section-card {
  background: #f8fafc;
}

.chat-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.chat-live-badge {
  font-size: 0.84rem;
  color: var(--accent-green);
  font-weight: 500;
}

.chat-quick-replies {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
}

.chat-quick-btn {
  padding: 4px 10px;
  font-size: 0.86rem;
  font-weight: 500;
  border-radius: var(--radius-pill);
  background: #ffffff;
  border: 1px solid var(--border-light);
  color: var(--text-main);
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.15s ease;
}
.chat-quick-btn:hover {
  background: var(--bg-hover);
  border-color: #cbd5e1;
}

.driver-chat-messages-box {
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  height: 160px;
  overflow-y: auto;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.driver-chat-input-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.driver-chat-input {
  flex: 1;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-light);
  background: #ffffff;
  font-size: 0.84rem;
  font-weight: 500;
  outline: none;
}
.driver-chat-input:focus {
  border-color: #94a3b8;
}

.driver-chat-send-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent-orange);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 2px 6px var(--accent-orange-glow);
  transition: all 0.15s ease;
}
.driver-chat-send-btn:hover {
  background: var(--accent-orange-hover);
}

/* Отзывы пассажиров */
.reviews-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.reviews-total-tag {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-weight: 400;
}

.reviews-list-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.review-card-item {
  background: var(--bg-input);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.review-top-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.review-author-name {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-main);
}

.review-stars-val {
  font-size: 0.88rem;
  color: var(--accent-amber);
  font-weight: 500;
}

.review-content-p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
  font-weight: 400;
}

.review-time-stamp {
  font-size: 0.82rem;
  color: var(--text-subtle);
  align-self: flex-end;
}

/* Фиксированный подвал выбора водителя */
.driver-page-sticky-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-top: 1px solid var(--border-light);
  background: #ffffff;
  flex-shrink: 0;
  gap: 14px;
  box-shadow: 0 -4px 14px rgba(0,0,0,0.04);
}

.footer-price-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.footer-price-lbl {
  font-size: 0.84rem;
  color: var(--text-muted);
  font-weight: 400;
}

.footer-price-val {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--text-main);
}

.btn-choose-driver-primary {
  flex: 1;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  background: var(--accent-orange);
  color: #ffffff;
  font-size: 0.92rem;
  font-weight: 500;
  text-align: center;
  border: none;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 4px 12px var(--accent-orange-glow);
}
.btn-choose-driver-primary:hover {
  background: var(--accent-orange-hover);
  transform: translateY(-1px);
}


/* -------------------------------------------------------------------------- */

/* ==========================================================================
   18. Регистрация водителя (Анкета, Авторизация, Города РФ, Фото, ЮKassa)
   ========================================================================== */
.driver-register-card {
  max-width: 580px;
  max-height: 90vh;
}

.badge-zero-comm {
  background: #dcfce7;
  color: #15803d;
  font-size: 0.84rem;
  font-weight: 500;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
}

.reg-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 14px;
}

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

.reg-step-badge {
  background: #0f172a;
  color: #ffffff;
  font-size: 0.82rem;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.reg-step-title {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-main);
}

.reg-locked-notice {
  background: #f1f5f9;
  border: 1px dashed #cbd5e1;
  border-radius: var(--radius-md);
  padding: 10px 14px;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
}

.reg-section.disabled-step {
  opacity: 0.45;
  pointer-events: none;
  filter: grayscale(0.5);
}

.driver-auth-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 10px;
}

.driver-social-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

@media (max-width: 560px) {
  .driver-social-grid {
    grid-template-columns: 1fr;
  }
}

.driver-auth-confirmed {
  animation: fadeInModal 0.2s ease;
}

.auth-user-info-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #ffffff;
  border: 1px solid #bbf7d0;
  border-radius: var(--radius-lg);
  padding: 10px 14px;
}

.auth-user-avatar-wrap {
  position: relative;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
}

.auth-avatar-pic {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #10b981;
}

.auth-social-logo-corner {
  position: absolute;
  bottom: -2px;
  right: -2px;
  background: #0077ff;
  color: #fff;
  font-size: 0.90rem;
  font-weight: 500;
  padding: 1px 4px;
  border-radius: 4px;
}

.auth-user-meta {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.auth-user-name {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-main);
}

.auth-user-sub {
  font-size: 0.90rem;
  color: var(--text-muted);
}

.auth-verified-chip {
  font-size: 0.84rem;
  color: #15803d;
  font-weight: 500;
}

.btn-change-social-account {
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 6px 10px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
}
.btn-change-social-account:hover {
  background: var(--bg-hover);
  color: var(--text-main);
}

/* Красивый кастомный выпадающий список городов РФ со связкой с картой */
.custom-city-select-box {
  position: relative;
  width: 100%;
}

.city-select-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.15s ease;
}
.city-select-trigger:hover {
  border-color: #94a3b8;
}

.city-trigger-val {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-main);
}

.city-dropdown-arrow {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.city-dropdown-panel {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-lg);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  z-index: 100;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  max-height: 280px;
  animation: fadeInModal 0.15s ease;
}

.city-search-row {
  display: flex;
  align-items: center;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border-light);
  gap: 8px;
  background: #f8fafc;
}

.city-search-field {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 0.85rem;
  color: var(--text-main);
  font-weight: 500;
}

.city-search-clear {
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1.1rem;
}

.quick-cities-bar {
  display: flex;
  gap: 4px;
  padding: 8px 12px;
  overflow-x: auto;
  border-bottom: 1px solid var(--border-light);
  background: #ffffff;
  scrollbar-width: none;
}
.quick-cities-bar::-webkit-scrollbar {
  display: none;
}

.quick-city-chip {
  padding: 4px 8px;
  border-radius: var(--radius-pill);
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
  cursor: pointer;
}
.quick-city-chip.active,
.quick-city-chip:hover {
  background: var(--accent-orange);
  border-color: var(--accent-orange);
  color: #ffffff;
}

.city-options-container {
  overflow-y: auto;
  max-height: 180px;
}

.city-option-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 14px;
  cursor: pointer;
  transition: background 0.12s ease;
  border-bottom: 1px solid #f1f5f9;
}
.city-option-item:hover {
  background: #f1f5f9;
}
.city-option-item.selected {
  background: #f0fdf4;
}

.city-option-name {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-main);
}

.city-option-region {
  font-size: 0.84rem;
  color: var(--text-muted);
}

.city-helper-hint {
  font-size: 0.84rem;
  color: var(--accent-green);
  font-weight: 500;
  margin-top: 2px;
  display: block;
}

/* Загрузка фото водителя и авто */
.photo-upload-row,
.car-photo-upload-box {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 10px 12px;
}

.driver-photo-preview-wrap {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid #e2e8f0;
  flex-shrink: 0;
  background: #0f172a;
}

.driver-photo-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.car-photo-preview-wrap {
  width: 90px;
  height: 56px;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid #e2e8f0;
  flex-shrink: 0;
  background: #0f172a;
}

.car-photo-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-upload-actions {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.btn-upload-photo {
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 6px 12px;
  font-size: 0.90rem;
  font-weight: 500;
  color: var(--text-main);
  cursor: pointer;
  width: fit-content;
  transition: all 0.15s ease;
}
.btn-upload-photo:hover {
  background: var(--bg-hover);
  border-color: #94a3b8;
}

.upload-hint {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* Подписка ЮKassa (499 ₽/мес) */
.driver-sub-widget {
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.sub-widget-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.sub-widget-title {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-main);
}

.sub-widget-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.35;
  margin-top: 2px;
}

.sub-status-tag {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 500;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  background: #fef2f2;
  color: #dc2626;
  white-space: nowrap;
}

.sub-status-dot.unpaid {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #dc2626;
}

.btn-pay-yookassa-action {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  background: #0f172a;
  color: #ffffff;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all 0.15s ease;
}
.btn-pay-yookassa-action:hover {
  background: #1e293b;
}

.sub-secure-label {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 4px;
}

.sub-paid-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  color: #15803d;
  font-size: 0.82rem;
}
.paid-check {
  font-size: 1.2rem;
  font-weight: 500;
}
.paid-sub-details {
  font-size: 0.86rem;
  color: #166534;
}

.btn-submit-locked {
  opacity: 0.55;
  cursor: not-allowed !important;
  background: #94a3b8 !important;
}

/* Окно оплаты ЮKassa */
.yookassa-pay-card {
  max-width: 440px;
}

.yoo-pay-summary {
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}

.yoo-pay-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
}
.yoo-lbl {
  color: var(--text-muted);
}
.yoo-val {
  color: var(--text-main);
  font-weight: 500;
}

.yoo-pay-amount-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 6px;
  margin-top: 4px;
  border-top: 1px dashed #cbd5e1;
}
.yoo-amount-lbl {
  font-size: 0.85rem;
  font-weight: 500;
}
.yoo-amount-val {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 500;
  color: #0f172a;
}

.yoo-methods-title {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-main);
  margin-bottom: 8px;
}

.yoo-methods-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 14px;
}

.yoo-method-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.15s ease;
}
.yoo-method-card:hover {
  border-color: #94a3b8;
  background: #f8fafc;
}
.yoo-method-card input[type="radio"]:checked + .yoo-method-content {
  color: var(--text-main);
}

.yoo-method-content {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}

.yoo-method-name {
  font-size: 0.84rem;
  font-weight: 500;
}

.yoo-method-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.yoo-security-note {
  font-size: 0.84rem;
  color: var(--text-muted);
  text-align: center;
}


/* -------------------------------------------------------------------------- */

/* ==========================================================================
   21. Полноэкранная страница поиска маршрута (Откуда и Куда)
   ========================================================================== */
.route-search-full-page {
  max-width: 600px;
  height: 92vh;
  max-height: 840px;
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border-radius: var(--radius-xl);
  overflow: hidden;
}
.search-page-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow-y: auto;
  overflow-x: hidden;
  flex: 1;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}
.search-page-body::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}
.search-inputs-card {
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: 16px;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
}
.search-addr-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 0;
}
.modal-addr-field {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-main);
  outline: none;
}
.modal-addr-field::placeholder {
  color: var(--text-muted);
  font-weight: 400;
}
.modal-addr-clear {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: none;
  background: #e2e8f0;
  color: var(--text-muted);
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}
.modal-addr-clear:hover {
  background: #cbd5e1;
  color: var(--text-main);
}
.search-addr-divider {
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
  margin: 4px 0;
}
.search-swap-wrap {
  width: 22px;
  display: flex;
  justify-content: center;
}
.search-divider-line {
  flex: 1;
  height: 1px;
  background: #e2e8f0;
}
.btn-pick-on-map-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: 14px;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
}
.btn-pick-on-map-row:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}
.pick-map-icon {
  font-size: 1.2rem;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: #ecfdf5;
  color: #10b981;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.pick-map-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.pick-map-title {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-main);
}
.pick-map-sub {
  font-size: 0.84rem;
  color: var(--text-muted);
}
.pick-map-arrow {
  font-size: 1.1rem;
  color: var(--text-muted);
}
.search-quick-favs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 2px 6px 2px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}
.search-quick-favs::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}
.fav-quick-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-main);
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.15s ease;
  flex-shrink: 0;
}
.fav-quick-chip:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}
.fav-quick-chip:active {
  transform: scale(0.97);
}
.search-results-section-header {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-top: 4px;
}
.modal-search-suggestions {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.search-suggestion-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
}
.search-suggestion-item:hover {
  background: #f8fafc;
  border-color: var(--border-light);
}
.sugg-icon {
  font-size: 1.1rem;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.sugg-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.sugg-title {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sugg-sub {
  font-size: 0.86rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sugg-city-badge {
  font-size: 0.82rem;
  padding: 3px 8px;
  background: #f1f5f9;
  color: #475569;
  border-radius: var(--radius-pill);
  font-weight: 500;
  flex-shrink: 0;
}
.search-page-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border-light);
  background: #ffffff;
}


/* -------------------------------------------------------------------------- */

/* ==========================================================================
   Шторка оценки поездки (#trip-rating-modal)
   ========================================================================== */
.rating-sheet-card {
  max-width: 440px;
  margin: auto auto 0 auto;
  border-radius: 24px 24px 0 0;
  padding: 12px 20px 24px 20px;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.15);
  animation: slideUpSheet 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.rating-header-block {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.rating-badge-icon {
  font-size: 2rem;
  line-height: 1;
  margin-bottom: 2px;
}

.rating-modal-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-main);
  margin: 0;
}

.rating-modal-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 0;
}

/* 5 Звёздочек */
.rating-stars-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.star-btn {
  background: transparent;
  border: none;
  font-size: 2.2rem;
  color: #e2e8f0;
  cursor: pointer;
  transition: transform 0.12s ease, color 0.12s ease;
  line-height: 1;
  padding: 0 4px;
}
.star-btn.active {
  color: #f59e0b;
  text-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}
.star-btn:hover {
  transform: scale(1.15);
}

.rating-score-label {
  text-align: center;
  font-size: 0.85rem;
  font-weight: 500;
  color: #0f172a;
  margin-top: -6px;
}

/* Теги похвалы */
.rating-chips-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
}

.rating-tag-chip {
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: #f1f5f9;
  border: 1px solid var(--border-light);
  font-size: 0.90rem;
  font-weight: 500;
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.15s ease;
}
.rating-tag-chip.active {
  background: #fff7ed;
  border-color: var(--accent-orange);
  color: var(--accent-orange);
}

/* Чаевые */
.rating-tips-block {
  background: #f8fafc;
  border-radius: 14px;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.rating-tips-label {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-weight: 500;
}

.tips-chips-row {
  display: flex;
  gap: 6px;
}

.tip-chip {
  flex: 1;
  padding: 6px 0;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid var(--border-light);
  font-size: 0.90rem;
  font-weight: 500;
  color: var(--text-main);
  text-align: center;
  cursor: pointer;
  transition: all 0.15s ease;
}
.tip-chip.active {
  background: var(--accent-orange);
  border-color: var(--accent-orange);
  color: #ffffff;
  box-shadow: 0 2px 6px var(--accent-orange-glow);
}

.rating-actions-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

.btn-skip-rating {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  padding: 8px;
  text-align: center;
  transition: color 0.15s ease;
}
.btn-skip-rating:hover {
  color: var(--text-main);
}


/* -------------------------------------------------------------------------- */

/* ==========================================================================
   Стили модалки правовых документов (#legal-docs-modal)
   ========================================================================== */
.legal-tabs-bar {
  display: flex;
  background: #f1f5f9;
  border-bottom: 1px solid var(--border-light);
  padding: 6px 12px;
  gap: 8px;
}

.legal-tab-btn {
  flex: 1;
  padding: 9px 12px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  background: transparent;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: center;
}

.legal-tab-btn.active {
  background: #ffffff;
  color: var(--accent-orange);
  border-color: var(--border-light);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.legal-content-pane {
  display: flex;
  flex-direction: column;
}


/* -------------------------------------------------------------------------- */

/* ==========================================================================
   МОДАЛКА ПОЛНОГО ПРОСМОТРА КАРТОЧКИ ОБЪЕКТА (ЖИЛЬЁ, КАФЕ, ОТДЫХ)
   ========================================================================== */
.catalog-detail-modal-card {
  max-width: 540px;
  width: 95%;
  max-height: 90vh;
  border-radius: 22px;
  overflow-y: auto;
  padding: 0;
  position: relative;
  background: #ffffff;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.2);
  scrollbar-width: none;
}

.catalog-detail-modal-card::-webkit-scrollbar {
  display: none;
}

.catalog-detail-hero {
  position: relative;
  width: 100%;
  height: 230px;
  background: #0f172a;
  overflow: hidden;
}

.cat-detail-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.btn-close-cat-detail {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 5;
  transition: transform 0.15s ease, background 0.15s ease;
}

.btn-close-cat-detail:hover {
  transform: scale(1.08);
  background: rgba(15, 23, 42, 0.9);
}

.cat-detail-hero-overlay {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.cat-detail-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.catalog-detail-body {
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

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

.cat-detail-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-main);
  margin: 0;
  line-height: 1.3;
}

.cat-detail-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 3px;
}

.cat-detail-price {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 500;
  color: var(--accent-orange);
  white-space: nowrap;
}

.cat-detail-addr-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: #f8fafc;
  border: 1px solid #f1f5f9;
  border-radius: 12px;
  padding: 9px 12px;
}

.cat-detail-addr-text {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  color: #334155;
  min-width: 0;
  flex: 1;
}

.btn-detail-map-focus {
  padding: 6px 12px;
  background: #ffffff;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-pill);
  font-size: 0.80rem;
  font-weight: 500;
  color: #0f172a;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.btn-detail-map-focus:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.cat-detail-contact-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  border-radius: 12px;
  padding: 9px 12px;
}

.cat-contact-pill {
  color: #047857;
  font-size: 0.84rem;
  font-weight: 500;
}

.cat-contact-phone {
  color: #065f46;
  font-size: 0.88rem;
  font-weight: 500;
}

.cat-detail-specs-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.cat-detail-section-title {
  font-size: 0.80rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  font-weight: 500;
  margin-bottom: 5px;
}

.cat-detail-desc {
  font-size: 0.90rem;
  color: #334155;
  line-height: 1.5;
  margin: 0;
}

.cat-detail-chips {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.cat-detail-chip {
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 4px 8px;
  font-size: 0.82rem;
  color: #334155;
}

.cat-detail-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  padding-top: 10px;
  border-top: 1px solid #f1f5f9;
}

.btn-cat-call {
  flex: 1;
  min-height: 44px;
  background: #ecfdf5;
  color: #047857;
  border: 1px solid rgba(16, 185, 129, 0.4);
  border-radius: 12px;
  font-size: 0.90rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-cat-call:hover {
  background: #d1fae5;
  color: #065f46;
}

.btn-cat-taxi {
  flex: 1.2;
  min-height: 44px;
  background: var(--accent-orange, #ff6b00);
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-size: 0.90rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 2px 8px var(--accent-orange-glow);
}

.btn-cat-taxi:hover {
  background: var(--accent-orange-hover, #e05e00);
  box-shadow: 0 4px 14px var(--accent-orange-glow);
}

.btn-cat-msg {
  flex: 0 0 44px;
  width: 44px;
  min-height: 44px;
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-cat-msg:hover {
  background: #f1f5f9;
}


/* -------------------------------------------------------------------------- */

/* ==========================================================================
   КАСТОМНОЕ ПОИСКОВОЕ ВЫПАДАЮЩЕЕ МЕНЮ ГОРОДОВ РФ (1136+ ГОРОДОВ)
   ========================================================================== */
.custom-city-dropdown {
  position: relative;
  width: 100%;
}

.custom-city-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: #ffffff;
  border: 1.5px solid var(--border-light, #e2e8f0);
  border-radius: 12px;
  padding: 8px 12px;
  font-family: var(--font-sans);
  font-size: 0.90rem;
  font-weight: 500;
  color: var(--text-main, #0f172a);
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  box-sizing: border-box;
}

.custom-city-trigger:hover {
  border-color: #cbd5e1;
}

.custom-city-trigger.active {
  border-color: var(--accent-orange);
  box-shadow: 0 0 0 3px rgba(255, 107, 0, 0.12);
}

.custom-city-trigger-left {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.custom-city-current-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
}

.custom-city-arrow {
  color: var(--text-muted);
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.custom-city-trigger.active .custom-city-arrow {
  transform: rotate(180deg);
}

.custom-city-popover {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: #ffffff;
  border: 1.5px solid var(--border-light, #e2e8f0);
  border-radius: 14px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.12);
  z-index: 100;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.custom-city-search-box {
  padding: 8px;
  background: #f8fafc;
  border-bottom: 1px solid #edf2f7;
  display: flex;
  align-items: center;
  gap: 6px;
}

.custom-city-search-input {
  flex: 1;
  border: 1px solid var(--border-light, #cbd5e1);
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 0.86rem;
  font-family: var(--font-sans);
  background: #ffffff;
  color: var(--text-main);
  outline: none;
  box-sizing: border-box;
}

.custom-city-search-input:focus {
  border-color: var(--accent-orange);
}

.custom-city-search-clear {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: #94a3b8;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.custom-city-search-clear:hover {
  color: #0f172a;
}

.custom-city-list {
  max-height: 230px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  padding: 4px 0;
}

.custom-city-section-header {
  padding: 6px 12px 2px;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
  font-weight: 500;
}

.custom-city-item {
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  cursor: pointer;
  transition: background 0.12s ease;
  font-size: 0.88rem;
  color: var(--text-main);
}

.custom-city-item:hover {
  background: #f1f5f9;
}

.custom-city-item.selected {
  background: #fff7ed;
  color: var(--accent-orange);
  font-weight: 500;
}

.city-item-region {
  font-size: 0.76rem;
  color: #64748b;
}

.custom-city-empty-hint {
  padding: 16px 12px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.84rem;
}



/* -------------------------------------------------------------------------- */

/* ==========================================================================
   КОМПАКТНЫЙ АККУРАТНЫЙ ДИЗАЙН МОДАЛКИ «СДАТЬ ЖИЛЬЁ»
   ========================================================================== */
#modal-add-rent-apartment .full-page-modal-card {
  max-width: 520px;
  max-height: 88vh;
  margin: auto;
}

#modal-add-rent-apartment .modal-body {
  padding: 12px 18px 16px !important;
}

#modal-add-rent-apartment .modal-input,
#modal-add-rent-apartment .form-select,
#modal-add-rent-apartment input[type="text"],
#modal-add-rent-apartment input[type="tel"],
#modal-add-rent-apartment input[type="number"],
#modal-add-rent-apartment select {
  min-height: 38px !important;
  height: 38px !important;
  padding: 6px 12px !important;
  font-size: 0.9rem !important;
  border-radius: 9px !important;
}

#modal-add-rent-apartment select.form-select,
#modal-add-rent-apartment select.modal-input {
  padding-right: 34px !important;
  background-position: right 10px center !important;
}

#modal-add-rent-apartment textarea.modal-textarea {
  min-height: 60px !important;
  padding: 8px 12px !important;
  font-size: 0.88rem !important;
  border-radius: 9px !important;
}

#modal-add-rent-apartment .form-group {
  margin-top: 8px !important;
  margin-bottom: 0 !important;
  gap: 3px !important;
}

#modal-add-rent-apartment .form-label {
  font-size: 0.8rem !important;
  font-weight: 500 !important;
  color: var(--text-muted, #64748b) !important;
  margin-bottom: 2px !important;
}

#modal-add-rent-apartment .rent-form-intro {
  padding: 8px 12px;
  background: #f1f5f9;
  border-radius: 8px;
  margin-bottom: 6px;
}

.dark-theme #modal-add-rent-apartment .rent-form-intro {
  background: rgba(255, 255, 255, 0.05);
}

#modal-add-rent-apartment .rent-amenities-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-top: 4px;
}

#modal-add-rent-apartment .amenity-checkbox {
  font-size: 0.78rem;
  padding: 5px 6px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  white-space: nowrap;
}

.dark-theme #modal-add-rent-apartment .amenity-checkbox {
  background: #1e293b;
  border-color: #334155;
  color: #e2e8f0;
}

#modal-add-rent-apartment .rent-photo-actions-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 4px;
}

#modal-add-rent-apartment .btn-upload-photo {
  padding: 6px 14px;
  font-size: 0.84rem;
  border-radius: 8px;
}

/* ==========================================================================
   ИЕРАРХИЯ СЛОЕВ И ПОЛНОЭКРАННЫЙ РЕЖИМ ДЛЯ ДЕТАЛЕЙ ОБЪЕКТА И СДАЧИ ЖИЛЬЯ
   ========================================================================== */
#modal-guide-route-choice {
  z-index: 100005 !important;
}

#modal-catalog-item-detail {
  z-index: 100000 !important;
}

#modal-add-rent-apartment {
  z-index: 99990 !important;
}

#modal-add-rent-apartment .modal-footer {
  position: static !important;
  bottom: auto !important;
  box-shadow: none !important;
  padding: 18px 0 !important;
}

@media (max-width: 768px) {
  #modal-catalog-item-detail.modal-backdrop {
    padding: 0 !important;
    background: #000000 !important;
  }
  #modal-catalog-item-detail .modal-card,
  #modal-catalog-item-detail .catalog-detail-modal-card {
    width: 100vw !important;
    max-width: 100vw !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    border-radius: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    display: flex !important;
    flex-direction: column !important;
  }
  #modal-catalog-item-detail .catalog-detail-body {
    flex: 1 1 auto !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    padding-bottom: max(32px, calc(16px + env(safe-area-inset-bottom, 16px))) !important;
  }
}

#modal-catalog-item-detail.modal-backdrop:not(.hidden) {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

#modal-navigator-search {
  z-index: 100010 !important;
}

#modal-navigator-search.modal-backdrop:not(.hidden) {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

