/* ==========================================================================
   ALM.care Pages CSS
   Home, Search, Listing Detail, Sell Wizard, Chat, Profile & CMS
   ========================================================================== */

/* ==========================================================================
   1. HOME PAGE
   ========================================================================== */

.hero-section {
  position: relative;
  padding: 60px 0 50px;
  background: radial-gradient(circle at 50% 20%, rgba(229, 169, 60, 0.15) 0%, rgba(8, 11, 17, 0) 70%);
  border-bottom: 1px solid rgba(229, 169, 60, 0.12);
  text-align: center;
  overflow: hidden;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(229, 169, 60, 0.12);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-full);
  padding: 6px 18px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--gold-bright);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 18px;
}

.hero-title {
  font-size: 3.2rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 12px;
  background: linear-gradient(180deg, #FFFFFF 30%, #CBD5E1 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
@media (max-width: 768px) {
  .hero-section {
    padding: 28px 0 20px;
  }
  .hero-badge {
    font-size: 0.72rem;
    padding: 4px 12px;
    margin-bottom: 12px;
  }
  .hero-title {
    font-size: 1.85rem;
    line-height: 1.2;
    margin-bottom: 6px;
  }
  .hero-slogan {
    font-size: 1.05rem;
    margin-bottom: 20px;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.5rem;
  }
  .hero-slogan {
    font-size: 0.92rem;
  }
}

.hero-slogan {
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--gold-light);
  letter-spacing: 0.05em;
  margin-bottom: 34px;
}

/* Big Hero Search Box */
.hero-search-wrapper {
  max-width: 820px;
  margin: 0 auto 30px;
  background: var(--bg-surface);
  border: 2px solid var(--border-gold);
  border-radius: var(--radius-full);
  padding: 8px 10px 8px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow-gold);
  transition: all var(--transition-fast);
}
.hero-search-wrapper:focus-within {
  border-color: var(--gold-bright);
  box-shadow: var(--shadow-gold-lg);
}

@media (max-width: 768px) {
  .hero-search-wrapper {
    border-radius: var(--radius-lg);
    flex-direction: column;
    padding: 12px;
    gap: 10px;
    width: 100%;
    box-sizing: border-box;
  }
  .hero-search-wrapper > i.fa-magnifying-glass {
    display: none;
  }
  .hero-search-input {
    width: 100%;
    text-align: center;
    font-size: 0.95rem;
    padding: 10px 12px;
    border-bottom: 1px solid var(--border-subtle);
    box-sizing: border-box;
  }
  .hero-emirate-select {
    width: 100%;
    box-sizing: border-box;
    text-align: center;
    border-radius: var(--radius-md);
  }
  .hero-search-btn {
    width: 100%;
    border-radius: var(--radius-md);
    padding: 12px;
  }
  .hero-emirates-strip {
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    padding: 6px 4px 10px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .hero-emirates-strip::-webkit-scrollbar {
    display: none;
  }
  .hero-emirates-strip > span {
    flex-shrink: 0;
  }
  .emirate-chip {
    flex-shrink: 0;
    white-space: nowrap;
    padding: 5px 12px;
    font-size: 0.78rem;
  }
}


.hero-search-input {
  flex: 1;
  background: transparent;
  color: var(--text-primary);
  font-size: 1.1rem;
}
.hero-search-input::placeholder {
  color: var(--text-muted);
}

.hero-emirate-select {
  background: var(--bg-surface-elevated);
  color: var(--text-primary);
  padding: 10px 14px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
}

.hero-search-btn {
  padding: 12px 28px;
  border-radius: var(--radius-full);
  font-size: 1rem;
}
@media (max-width: 768px) {
  .hero-search-btn {
    width: 100%;
  }
}

/* Quick Emirate Pills */
.hero-emirates-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.emirate-chip {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 5px;
}
.emirate-chip:hover, .emirate-chip.active {
  background: var(--gold-surface);
  border-color: var(--gold-primary);
  color: var(--gold-bright);
}

/* Category Cards Grid */
.categories-section {
  padding: 50px 0;
}

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 28px;
}

.section-title-group h2 {
  font-size: 1.75rem;
  display: flex;
  align-items: center;
  gap: 10px;
}
.section-title-group h2 i {
  color: var(--gold-primary);
}
.section-subtitle {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 16px;
}
@media (max-width: 640px) {
  .category-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }
  .category-card {
    padding: 14px 6px;
    gap: 8px;
  }
  .category-icon-box {
    width: 44px;
    height: 44px;
    font-size: 1.25rem;
  }
  .category-name {
    font-size: 0.8rem;
  }
  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}

@media (max-width: 420px) {
  .category-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
}


.category-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 22px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  cursor: pointer;
  transition: all var(--transition-normal);
  text-decoration: none;
  color: inherit;
}
.category-card:hover {
  transform: translateY(-4px);
  border-color: var(--gold-primary);
  background: linear-gradient(180deg, rgba(229, 169, 60, 0.08) 0%, var(--bg-surface) 100%);
  box-shadow: var(--shadow-gold);
}

.category-icon-box {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-md);
  background: rgba(229, 169, 60, 0.1);
  border: 1px solid rgba(229, 169, 60, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--gold-primary);
  transition: all var(--transition-fast);
}
.category-card:hover .category-icon-box {
  background: var(--gold-gradient);
  color: #080B11;
  transform: scale(1.08);
}

.category-name {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.3;
  color: #F8FAFC;
  letter-spacing: -0.01em;
}

/* Listings Showcase Shelves */
.showcase-shelf {
  padding: 40px 0;
}

.listings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
@media (max-width: 640px) {
  .listings-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* UAE Trust Banner */
.trust-banner-section {
  padding: 50px 0;
}
.trust-banner-box {
  background: linear-gradient(135deg, #131E33 0%, #0D1424 100%);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-xl);
  padding: 40px;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  align-items: center;
  gap: 40px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-gold);
}
@media (max-width: 900px) {
  .trust-banner-box {
    grid-template-columns: 1fr;
    padding: 26px;
  }
}

.trust-features-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.trust-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px;
}
.trust-feature-icon {
  font-size: 1.4rem;
  color: var(--gold-bright);
}
.trust-feature-text h4 {
  font-size: 0.95rem;
  margin-bottom: 2px;
}
.trust-feature-text p {
  font-size: 0.78rem;
  line-height: 1.4;
}

/* ==========================================================================
   2. SEARCH & CATALOG PAGE
   ========================================================================== */

.search-page-layout {
  display: grid;
  grid-template-columns: 290px 1fr;
  gap: 30px;
  padding: 30px 0 60px;
}
@media (max-width: 960px) {
  .search-page-layout {
    grid-template-columns: 1fr;
  }
}

.filter-sidebar {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  height: fit-content;
  position: sticky;
  top: calc(var(--header-height) + 20px);
}
@media (max-width: 960px) {
  .filter-sidebar {
    position: static;
  }
}

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

.filter-block {
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.filter-title {
  font-size: 0.92rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.filter-price-inputs {
  display: flex;
  align-items: center;
  gap: 8px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--text-secondary);
  cursor: pointer;
  margin-bottom: 8px;
}
.checkbox-label input[type="checkbox"] {
  accent-color: var(--gold-primary);
  width: 16px;
  height: 16px;
}

/* Catalog Toolbar */
.catalog-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px 18px;
  margin-bottom: 20px;
}

.results-count-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
}
.results-count-text strong {
  color: var(--gold-bright);
}

.toolbar-controls {
  display: flex;
  align-items: center;
  gap: 14px;
}

.view-mode-toggle {
  display: flex;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.view-btn {
  background: var(--bg-surface-elevated);
  border: none;
  padding: 6px 12px;
  color: var(--text-muted);
  cursor: pointer;
}
.view-btn.active {
  background: var(--gold-primary);
  color: #080B11;
}

/* ==========================================================================
   3. LISTING DETAIL PAGE
   ========================================================================== */

.listing-detail-layout {
  display: grid;
  grid-template-columns: 1fr 390px;
  gap: 34px;
  padding: 24px 0 60px;
}
@media (max-width: 1024px) {
  .listing-detail-layout {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 768px) {
  .listing-detail-layout {
    padding-bottom: calc(var(--bottom-nav-height) + 80px);
  }
  .seller-sticky-card {
    position: static !important;
    margin-bottom: calc(var(--bottom-nav-height) + 40px);
  }
}

.breadcrumbs-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.breadcrumbs-bar a:hover {
  color: var(--gold-bright);
}

/* Gallery */
.gallery-container {
  background: #06090F;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin-bottom: 28px;
}

.main-gallery-view {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  max-height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  cursor: zoom-in;
}

.main-gallery-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.gallery-zoom-badge {
  position: absolute;
  bottom: 14px;
  right: 14px;
  background: rgba(8, 11, 17, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-md);
  padding: 6px 12px;
  color: #FFF;
  font-size: 0.8rem;
  backdrop-filter: blur(4px);
  pointer-events: none;
}

.gallery-thumbs-track {
  display: flex;
  gap: 12px;
  padding: 14px;
  background: var(--bg-surface);
  overflow-x: auto;
}

.gallery-thumb {
  width: 80px;
  height: 60px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  opacity: 0.65;
  transition: all var(--transition-fast);
  flex-shrink: 0;
}
.gallery-thumb.active, .gallery-thumb:hover {
  border-color: var(--gold-primary);
  opacity: 1;
}
.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Listing Information Block */
.listing-info-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 30px;
  margin-bottom: 24px;
}

.listing-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}

.listing-big-title {
  font-size: 1.85rem;
  line-height: 1.25;
  font-weight: 800;
}
@media (max-width: 768px) {
  .listing-big-title {
    font-size: 1.4rem;
  }
}

.listing-price-tag {
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--gold-bright);
}
.listing-negotiable-badge {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 600;
  margin-top: -4px;
}

.listing-meta-row {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 0.88rem;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 20px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

/* Specs Table */
.specs-table-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-bottom: 30px;
}
@media (max-width: 640px) {
  .specs-table-grid {
    grid-template-columns: 1fr;
  }
}

.spec-cell {
  background: var(--bg-surface-elevated);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-md);
  padding: 13px 18px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  transition: border-color var(--transition-fast);
}
.spec-cell:hover {
  border-color: rgba(229, 169, 60, 0.4);
}
.spec-cell-label {
  font-size: 0.8rem;
  color: #94A3B8;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.spec-cell-val {
  font-size: 1.02rem;
  font-weight: 700;
  color: #FFFFFF;
}

.description-text {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  white-space: pre-line;
}

/* Sticky Contact Sidebar */
.seller-sticky-card {
  background: var(--bg-surface);
  border: 1.5px solid var(--border-gold);
  border-radius: var(--radius-xl);
  padding: 26px;
  box-shadow: var(--shadow-gold);
  height: fit-content;
  position: sticky;
  top: calc(var(--header-height) + 20px);
}

.seller-profile-snippet {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border-subtle);
}

.seller-avatar-lg {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-full);
  border: 2px solid var(--gold-primary);
  object-fit: cover;
}

.seller-name {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.seller-rating-stars {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--gold-bright);
}

.seller-badges-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 22px;
}

.contact-actions-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 22px;
}

.phone-reveal-btn {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-weight: 700;
  padding: 12px;
}

/* ==========================================================================
   4. SELL / POST AN AD WIZARD (8-Step Flow)
   ========================================================================== */

.sell-wizard-container {
  max-width: 860px;
  margin: 30px auto 70px;
  background: var(--bg-surface);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-xl);
  padding: 36px;
  box-shadow: var(--shadow-gold);
}
@media (max-width: 768px) {
  .sell-wizard-container {
    padding: 20px;
  }
}

.wizard-steps-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 34px;
  position: relative;
}
.wizard-steps-bar::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--border-subtle);
  z-index: 1;
}

.wizard-step-node {
  position: relative;
  z-index: 2;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  background: var(--bg-surface-elevated);
  border: 2px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--text-muted);
  transition: all var(--transition-fast);
}
.wizard-step-node.active {
  background: var(--gold-gradient);
  border-color: #FFF;
  color: #080B11;
  box-shadow: var(--shadow-gold);
}
.wizard-step-node.completed {
  background: var(--gold-primary);
  color: #080B11;
  border-color: var(--gold-light);
}

.wizard-step-content {
  min-height: 380px;
}

.dropzone-upload {
  border: 2px dashed rgba(229, 169, 60, 0.4);
  background: rgba(229, 169, 60, 0.03);
  border-radius: var(--radius-lg);
  padding: 40px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  margin-bottom: 20px;
}
.dropzone-upload:hover {
  border-color: var(--gold-bright);
  background: rgba(229, 169, 60, 0.08);
}

.uploaded-photos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.uploaded-photo-item {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-gold);
}
.uploaded-photo-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.remove-photo-btn {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 24px;
  height: 24px;
  border-radius: var(--radius-full);
  background: rgba(239, 68, 68, 0.9);
  color: #FFF;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
}

/* Promotion Tiers */
.promotion-tiers-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin: 20px 0;
}
@media (max-width: 768px) {
  .promotion-tiers-grid {
    grid-template-columns: 1fr;
  }
}

.promo-tier-card {
  background: var(--bg-surface-elevated);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 22px;
  cursor: pointer;
  transition: all var(--transition-fast);
  position: relative;
}
.promo-tier-card:hover, .promo-tier-card.selected {
  border-color: var(--gold-primary);
  background: rgba(229, 169, 60, 0.08);
  box-shadow: var(--shadow-gold);
}
.promo-tier-card.selected::after {
  content: '✓';
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--gold-primary);
  color: #080B11;
  width: 22px;
  height: 22px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.8rem;
}

/* ==========================================================================
   5. CHAT & MESSAGING INTERFACE
   ========================================================================== */

.chat-app-window {
  display: grid;
  grid-template-columns: 320px 1fr;
  height: calc(100vh - var(--header-height) - 40px);
  min-height: 600px;
  background: var(--bg-surface);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin: 20px auto;
}
@media (max-width: 768px) {
  .chat-app-window {
    grid-template-columns: 1fr;
    height: calc(100vh - var(--header-height) - var(--bottom-nav-height) - 20px);
  }
}

.chat-contacts-col {
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  background: #090E18;
}

.contacts-header {
  padding: 18px 20px;
  border-bottom: 1px solid var(--border-subtle);
  font-size: 1.1rem;
  font-weight: 700;
}

.contacts-list {
  flex: 1;
  overflow-y: auto;
}

.contact-thread-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  cursor: pointer;
  transition: background var(--transition-fast);
}
.contact-thread-item:hover, .contact-thread-item.active {
  background: var(--bg-surface-elevated);
}

.chat-main-thread {
  display: flex;
  flex-direction: column;
  background: #0B101C;
  position: relative;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

.chat-listing-banner {
  background: var(--bg-surface-elevated);
  border-bottom: 1px solid var(--border-subtle);
  padding: 10px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 10;
}

.chat-messages-area {
  flex: 1;
  min-height: 0;
  padding: 20px;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-primary) rgba(14, 21, 34, 0.7);
}

/* Highly Visible Custom Gold Scrollbar */
.chat-messages-area::-webkit-scrollbar {
  width: 9px;
}
.chat-messages-area::-webkit-scrollbar-track {
  background: rgba(14, 21, 34, 0.85);
  border-left: 1px solid var(--border-subtle);
}
.chat-messages-area::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--gold-primary) 0%, #B45309 100%);
  border-radius: 6px;
  border: 1.5px solid #0B101C;
}
.chat-messages-area::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--gold-bright) 0%, var(--gold-primary) 100%);
}
.chat-messages-area::-webkit-scrollbar-button:single-button:vertical:decrement {
  height: 10px;
  width: 9px;
  background: rgba(229, 169, 60, 0.3) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='100' height='100' fill='%23e5a93c'><polygon points='50,20 10,80 90,80'/></svg>") no-repeat center center;
  background-size: 6px;
}
.chat-messages-area::-webkit-scrollbar-button:single-button:vertical:increment {
  height: 10px;
  width: 9px;
  background: rgba(229, 169, 60, 0.3) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='100' height='100' fill='%23e5a93c'><polygon points='50,80 10,20 90,20'/></svg>") no-repeat center center;
  background-size: 6px;
}

/* Floating Scroll-to-Bottom / Latest Messages Button */
.chat-scroll-bottom-btn {
  position: absolute;
  bottom: 120px;
  right: 22px;
  padding: 8px 14px;
  border-radius: var(--radius-full);
  background: rgba(14, 21, 34, 0.95);
  border: 1.5px solid var(--gold-primary);
  color: var(--gold-primary);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.65), 0 0 16px rgba(229, 169, 60, 0.35);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 30;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px) scale(0.95);
}

.chat-scroll-bottom-btn.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.chat-scroll-bottom-btn:hover {
  background: var(--gold-primary);
  color: #080B11;
  box-shadow: 0 10px 28px rgba(229, 169, 60, 0.55);
  transform: translateY(-2px) scale(1.02);
}

.chat-scroll-bottom-btn:active {
  transform: translateY(0) scale(0.96);
}

.chat-scroll-bottom-btn i {
  font-size: 0.85rem;
  animation: scrollDownBounce 1.5s infinite ease-in-out;
}

@keyframes scrollDownBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(3px); }
}

.chat-scroll-new-badge {
  background: #EF4444;
  color: #FFF;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: var(--radius-full);
  border: 1px solid #FFF;
}

.chat-bubble {
  max-width: 75%;
  padding: 12px 18px;
  border-radius: var(--radius-lg);
  font-size: 0.94rem;
  line-height: 1.45;
  position: relative;
}
.chat-bubble.sent {
  align-self: flex-end;
  background: linear-gradient(135deg, #2D3748 0%, #1A202C 100%);
  border: 1px solid var(--border-gold);
  color: #FFF;
  border-bottom-right-radius: 4px;
}
.chat-bubble.received {
  align-self: flex-start;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  border-bottom-left-radius: 4px;
}

.chat-time-tag {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-align: right;
  margin-top: 4px;
}

.chat-input-bar {
  padding: 14px 18px;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  display: flex;
  align-items: center;
  gap: 12px;
}

/* In-Chat Offer Card */
.chat-offer-card {
  background: linear-gradient(135deg, rgba(229, 169, 60, 0.15) 0%, rgba(14, 21, 34, 0.9) 100%);
  border: 1.5px solid var(--gold-primary);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-top: 8px;
}

/* Chat Quick Chips & Typing Indicators */
.chat-quick-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 8px 18px;
  background: rgba(14, 21, 34, 0.7);
  border-top: 1px solid var(--border-subtle);
  scrollbar-width: thin;
}
.chat-quick-chips::-webkit-scrollbar {
  height: 4px;
}
.chat-quick-chips::-webkit-scrollbar-thumb {
  background: rgba(229, 169, 60, 0.2);
  border-radius: 4px;
}

.chat-chip-btn {
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  background: rgba(229, 169, 60, 0.08);
  border: 1px solid rgba(229, 169, 60, 0.3);
  color: var(--gold-light);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.chat-chip-btn:hover {
  background: var(--gold-primary);
  color: #080B11;
  font-weight: 700;
  border-color: var(--gold-primary);
  transform: translateY(-1px);
}

.typing-bubble {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 10px 16px;
  border-radius: var(--radius-lg);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  width: fit-content;
}

.typing-dot {
  width: 6px;
  height: 6px;
  background: var(--gold-primary);
  border-radius: 50%;
  display: inline-block;
  animation: typingBounce 1.4s infinite ease-in-out;
}
.typing-dot:nth-child(1) { animation-delay: 0s; }
.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
  0%, 60%, 100% {
    transform: translateY(0);
    opacity: 0.35;
  }
  30% {
    transform: translateY(-5px);
    opacity: 1;
  }
}

.chat-search-input {
  width: 100%;
  padding: 9px 34px 9px 12px;
  font-size: 0.82rem;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  outline: none;
  transition: border-color 0.2s ease;
}
.chat-search-input:focus {
  border-color: var(--gold-primary);
  box-shadow: 0 0 0 2px rgba(229, 169, 60, 0.15);
}
