/* ==========================================================================
   CaribKeys PWA — Caribbean Real Estate Master Registry & Exchange
   Theme: Obsidian Emerald / Dark Executive Real Estate
   ========================================================================== */

:root {
  --bg-core: #090d16;
  --bg-surface: #111827;
  --bg-surface-elevated: #1f2937;
  --bg-surface-hover: #283548;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-emerald: rgba(16, 185, 129, 0.35);
  
  --emerald-primary: #10b981;
  --emerald-glow: rgba(16, 185, 129, 0.2);
  --emerald-light: #34d399;
  --teal-accent: #14b8a6;
  --cyan-accent: #06b6d4;
  --gold-accent: #f59e0b;
  --amber-glow: rgba(245, 158, 11, 0.2);
  
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-pill: 9999px;
  
  --shadow-card: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 20px rgba(16, 185, 129, 0.25);
  --bottom-bar-height: 64px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  background-color: var(--bg-core);
  color: var(--text-primary);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  overflow-x: hidden;
  padding-bottom: calc(var(--bottom-bar-height) + 20px);
}

/* App Layout */
.app-layout {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header */
.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(9, 13, 22, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
  padding: 12px 16px;
}

.header-inner {
  max-width: 1240px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-group {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-logo-box {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand-logo-img {
  width: 40px !important;
  height: 40px !important;
  max-width: 40px !important;
  max-height: 40px !important;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(16, 185, 129, 0.25));
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  flex-shrink: 0;
  display: block;
}

.brand-group:hover .brand-logo-img {
  transform: scale(1.08) rotate(4deg);
}

.brand-logo-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(6, 182, 212, 0.1));
  border: 1px solid var(--border-emerald);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--emerald-primary);
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.15);
}

.brand-meta {
  display: flex;
  flex-direction: column;
}

.brand-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand-name {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.brand-name-gold {
  color: #D4A759;
  background: linear-gradient(135deg, #fcd34d 0%, #D4A759 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.badge-region {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  background: rgba(16, 185, 129, 0.15);
  color: var(--emerald-light);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 2px 7px;
  border-radius: var(--radius-pill);
}

.brand-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: 0.01em;
}

.brand-sub strong {
  font-weight: 800;
  color: #f8fafc;
  letter-spacing: 0.05em;
}

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

.currency-toggle-box {
  display: inline-flex;
  align-items: center;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  padding: 2px;
  gap: 2px;
}

.curr-pill-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 700;
  font-family: var(--font-sans);
  padding: 4px 8px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.curr-pill-btn.active {
  background: var(--emerald-primary);
  color: #090d16;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.4);
}

.curr-pill-btn:hover:not(.active) {
  color: var(--text-primary);
}

.pro-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.12), rgba(16, 185, 129, 0.12));
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #fbbf24;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.pro-btn:hover {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(16, 185, 129, 0.25));
  border-color: #fbbf24;
  transform: translateY(-1px);
}

.pro-sparkle {
  color: #fbbf24;
  font-size: 0.9rem;
}

.pro-tag {
  background: #f59e0b;
  color: #090d16;
  font-size: 0.6rem;
  padding: 1px 5px;
  border-radius: 4px;
  font-weight: 800;
}

/* Search & Filters Section */
.search-section {
  background: var(--bg-core);
  padding: 16px 16px 8px;
  border-bottom: 1px solid var(--border-subtle);
}

.search-container {
  max-width: 1240px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.search-bar {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.search-icon {
  position: absolute;
  left: 14px;
  color: var(--text-muted);
  pointer-events: none;
}

.search-bar input {
  width: 100%;
  padding: 12px 42px 12px 44px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: var(--font-sans);
  transition: all 0.2s ease;
}

.search-bar input:focus {
  outline: none;
  border-color: var(--emerald-primary);
  box-shadow: 0 0 0 3px var(--emerald-glow);
}

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

.clear-btn {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1rem;
  cursor: pointer;
  padding: 4px;
}

/* Type Tabs */
.type-tabs-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 2px;
}

.type-tabs-scroll::-webkit-scrollbar {
  display: none;
}

.type-tabs {
  display: flex;
  gap: 8px;
  width: max-content;
}

.type-tab {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.type-tab:hover {
  background: var(--bg-surface-elevated);
  color: var(--text-primary);
}

.type-tab.active {
  background: var(--emerald-primary);
  border-color: var(--emerald-primary);
  color: #090d16;
  font-weight: 700;
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.3);
}

/* Filter Controls Row */
.filter-controls-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.filter-group label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.filter-select {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  padding: 9px 12px;
  font-size: 0.85rem;
  font-family: var(--font-sans);
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s ease;
}

.filter-select:focus {
  border-color: var(--emerald-primary);
}

/* Results Bar */
.results-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 4px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  flex-wrap: wrap;
  gap: 12px;
}

.sort-control-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sort-label {
  font-size: 0.76rem;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.sort-select {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  padding: 5px 10px;
  font-size: 0.78rem;
  font-family: var(--font-sans);
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s ease;
}

.sort-select:focus {
  border-color: var(--emerald-primary);
}

.results-stats strong {
  color: var(--emerald-light);
}

.reset-link {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.8rem;
  cursor: pointer;
  text-decoration: underline;
}

.reset-link:hover {
  color: var(--text-primary);
}

/* Properties Grid */
.properties-feed-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 20px 16px;
  width: 100%;
}

.properties-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 640px) {
  .properties-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .properties-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Property Card */
.property-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.property-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-emerald);
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.7), 0 0 15px rgba(16, 185, 129, 0.15);
}

.card-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #1e293b;
}

.card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.property-card:hover .card-img {
  transform: scale(1.04);
}

.badge-stack {
  position: absolute;
  top: 12px;
  left: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 2;
}

.badge-tag {
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  padding: 4px 8px;
  border-radius: var(--radius-pill);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  text-transform: uppercase;
}

.badge-tag.for-sale {
  background: rgba(16, 185, 129, 0.9);
  color: #090d16;
}

.badge-tag.for-rent {
  background: rgba(6, 182, 212, 0.9);
  color: #090d16;
}

.badge-tag.land {
  background: rgba(245, 158, 11, 0.9);
  color: #090d16;
}

.badge-tag.fsbo {
  background: rgba(239, 68, 68, 0.95);
  color: #ffffff;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
}

.badge-verified-agency {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(17, 24, 39, 0.85);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: var(--emerald-light);
  font-size: 0.65rem;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: var(--radius-pill);
  backdrop-filter: blur(6px);
}

.badge-tag.no-photo {
  background: rgba(30, 41, 59, 0.88);
  border: 1px solid rgba(245, 158, 11, 0.45);
  color: #fbbf24;
  font-size: 0.65rem;
}

.badge-tag.sponsored-badge {
  background: linear-gradient(135deg, #06b6d4, #3b82f6);
  color: #090d16;
  font-weight: 800;
}

.property-card.sponsored-ad-card {
  border: 1px solid rgba(6, 182, 212, 0.35);
  background: linear-gradient(180deg, rgba(6, 182, 212, 0.06) 0%, #111827 100%);
}

.country-pill-select {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  color: var(--text-primary);
  padding: 6px 12px;
  font-size: 0.78rem;
  font-family: var(--font-sans);
  font-weight: 600;
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s ease;
}

.country-pill-select:focus {
  border-color: var(--emerald-primary);
}

.mortgage-calc-banner {
  background: #1e293b;
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mortgage-link-cta {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid var(--emerald-primary);
  color: var(--emerald-light);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.2s ease;
}

.mortgage-link-cta:hover {
  background: var(--emerald-primary);
  color: #090d16;
}


.card-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 6px;
}

.card-price {
  font-size: 1.35rem;
  font-weight: 800;
  color: #ffffff;
  font-family: var(--font-mono);
  letter-spacing: -0.02em;
}

.card-type-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.card-title {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

.location-icon {
  color: var(--emerald-primary);
  flex-shrink: 0;
}

.specs-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}

.spec-chip {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 4px;
}

.agency-footer-row {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.agency-name-text {
  font-weight: 600;
  color: var(--text-secondary);
  max-width: 170px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-actions-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  margin-top: 12px;
}

.btn-whatsapp-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 14px;
  background: #25d366;
  color: #090d16;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
}

.btn-whatsapp-cta:hover {
  background: #22c55e;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.35);
}

.btn-details-cta {
  padding: 10px 14px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-details-cta:hover {
  background: var(--bg-surface-hover);
  border-color: rgba(255, 255, 255, 0.2);
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  max-width: 420px;
  margin: 0 auto;
}

.empty-icon {
  font-size: 3rem;
  margin-bottom: 12px;
}

.empty-state h3 {
  font-size: 1.25rem;
  margin-bottom: 8px;
}

.empty-state p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.cta-secondary-btn {
  background: var(--emerald-primary);
  color: #090d16;
  border: none;
  padding: 10px 20px;
  border-radius: var(--radius-md);
  font-weight: 700;
  cursor: pointer;
}

/* Modals */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: fadeIn 0.2s ease;
}

.modal-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.85);
  position: relative;
}

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

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

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

.modal-body {
  padding: 20px;
}

/* Pro MLS Modal Styling */
.pro-card-theme {
  border-color: rgba(245, 158, 11, 0.35);
  box-shadow: 0 0 40px rgba(245, 158, 11, 0.15);
}

.pro-badge-header {
  font-size: 0.75rem;
  font-weight: 800;
  color: #fbbf24;
  letter-spacing: 0.08em;
}

.pro-modal-body {
  padding: 24px;
}

.pro-modal-body h2 {
  font-size: 1.45rem;
  font-weight: 800;
  margin-bottom: 8px;
  background: linear-gradient(135deg, #ffffff 40%, #fde68a 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.pro-subtext {
  color: var(--text-secondary);
  font-size: 0.88rem;
  margin-bottom: 24px;
}

.pro-features-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 24px;
}

.pro-feature-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.pro-feat-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
  background: var(--bg-surface-elevated);
  padding: 8px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
}

.pro-feature-item strong {
  font-size: 0.92rem;
  color: #ffffff;
  display: block;
  margin-bottom: 2px;
}

.pro-feature-item p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.pro-pricing-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-bottom: 20px;
}

@media (min-width: 520px) {
  .pro-pricing-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.pricing-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  position: relative;
}

.pricing-card.highlighted {
  border-color: #f59e0b;
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.08) 0%, rgba(17, 24, 39, 0.6) 100%);
}

.highlight-tag {
  position: absolute;
  top: -10px;
  right: 14px;
  background: #f59e0b;
  color: #090d16;
  font-size: 0.62rem;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: var(--radius-pill);
}

.price-tier {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.price-val {
  font-size: 1.6rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: #ffffff;
  margin-bottom: 4px;
}

.price-currency {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.price-note {
  font-size: 0.74rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.pro-action-btn {
  margin-top: auto;
  text-align: center;
  padding: 10px;
  background: var(--bg-surface-hover);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border-radius: var(--radius-md);
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.2s ease;
}

.pro-action-btn:hover {
  background: #ffffff;
  color: #090d16;
}

.pro-action-btn.pass-btn {
  background: #f59e0b;
  color: #090d16;
  border-color: #f59e0b;
}

.pro-action-btn.pass-btn:hover {
  background: #fbbf24;
}

.payment-guarantee {
  border-top: 1px solid var(--border-subtle);
  padding-top: 14px;
  text-align: center;
}

.payment-badges {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.75rem;
  color: var(--emerald-light);
  font-weight: 600;
}

/* Mobile Bottom Navigation Bar */
.mobile-bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-bar-height);
  background: rgba(9, 13, 22, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-around;
  z-index: 90;
  padding-bottom: env(safe-area-inset-bottom);
}

.nav-item {
  background: none;
  border: none;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  font-size: 0.68rem;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.2s ease;
  padding: 6px 12px;
}

.nav-item.active {
  color: var(--emerald-primary);
}

.nav-item:hover {
  color: var(--text-primary);
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.97); }
  to { opacity: 1; transform: scale(1); }
}

/* ==========================================================================
   Smart Soft Wall & Metered Teaser Card Styles
   ========================================================================== */
.blurred-teaser-card {
  position: relative;
  border-color: rgba(245, 158, 11, 0.35);
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.05) 0%, #111827 100%);
}

.blurred-media {
  position: relative;
}

.blurred-media .card-img {
  filter: blur(10px);
  transform: scale(1.08);
}

.blur-overlay {
  position: absolute;
  inset: 0;
  background: rgba(9, 13, 22, 0.65);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  z-index: 3;
}

.blur-lock-icon {
  font-size: 1.8rem;
}

.blur-lock-text {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #fbbf24;
  text-transform: uppercase;
}

.soft-wall-gate-card {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, rgba(17, 24, 39, 0.95), rgba(15, 23, 42, 0.95));
  border: 1px solid rgba(245, 158, 11, 0.45);
  border-radius: var(--radius-xl);
  padding: 28px 20px;
  text-align: center;
  box-shadow: 0 0 35px rgba(245, 158, 11, 0.12), var(--shadow-card);
  margin-top: 10px;
}

.gate-card-inner {
  max-width: 580px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.gate-lock-badge {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}

.gate-lock-icon {
  font-size: 1.6rem;
}

.gate-status-pill {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.15);
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  margin-bottom: 10px;
}

.gate-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 8px;
}

.gate-subtitle {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 20px;
}

.gate-subtitle strong {
  color: #fbbf24;
}

.gate-benefits-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--emerald-light);
  margin-bottom: 22px;
  text-align: left;
}

.gate-actions-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  max-width: 400px;
  margin-bottom: 16px;
}

@media (min-width: 480px) {
  .gate-actions-group {
    flex-direction: row;
  }
}

.gate-primary-btn {
  flex: 1;
  padding: 12px 16px;
  background: #f59e0b;
  color: #090d16;
  font-size: 0.85rem;
  font-weight: 800;
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.gate-primary-btn:hover {
  background: #fbbf24;
  transform: translateY(-1px);
}

.gate-secondary-btn {
  flex: 1;
  padding: 12px 16px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
}

.gate-secondary-btn:hover {
  background: var(--bg-surface-hover);
  border-color: rgba(255, 255, 255, 0.25);
}

.gate-footer-sim {
  margin-top: 8px;
}

.sim-toggle-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.72rem;
  cursor: pointer;
  text-decoration: underline;
}

.sim-toggle-btn:hover {
  color: var(--text-secondary);
}

/* ==========================================================================
   Header Backoffice Button
   ========================================================================== */
.backoffice-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(31, 41, 55, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-secondary);
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.backoffice-btn:hover {
  background: rgba(245, 158, 11, 0.15);
  border-color: rgba(245, 158, 11, 0.4);
  color: #fbbf24;
}

.backoffice-icon {
  font-size: 0.85rem;
}

/* ==========================================================================
   Operator Backoffice Modal & Dashboard Styles
   ========================================================================== */
.backoffice-modal-card {
  max-width: 960px;
  width: 95%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 24px;
  background: #0d121f;
  border: 1px solid rgba(16, 185, 129, 0.35);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.7), 0 0 30px rgba(16, 185, 129, 0.1);
}

/* Auth View */
.backoffice-auth-box {
  max-width: 440px;
  margin: 40px auto;
  text-align: center;
  padding: 20px;
}

.auth-icon-badge {
  font-size: 2.4rem;
  margin-bottom: 12px;
}

.auth-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 8px;
}

.auth-subtitle {
  font-size: 0.84rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 24px;
}

.auth-form-row {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-form-row input {
  background: var(--bg-surface-elevated);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  color: #ffffff;
  font-size: 0.95rem;
  text-align: center;
  letter-spacing: 0.05em;
}

.auth-form-row input:focus {
  outline: none;
  border-color: var(--emerald-primary);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.auth-submit-btn {
  padding: 12px;
  background: var(--emerald-primary);
  color: #090d16;
  border: none;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
}

.auth-submit-btn:hover {
  background: var(--emerald-light);
  transform: translateY(-1px);
}

.auth-error-msg {
  margin-top: 12px;
  font-size: 0.8rem;
  color: #f87171;
  background: rgba(248, 113, 113, 0.1);
  padding: 8px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(248, 113, 113, 0.25);
}

/* Authenticated Dashboard Header */
.backoffice-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 12px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 16px;
  margin-bottom: 20px;
}

.backoffice-title-stack h2 {
  font-size: 1.3rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 4px;
}

.backoffice-env-pill {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--emerald-light);
  background: rgba(16, 185, 129, 0.12);
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

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

.bo-secondary-btn {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: #ffffff;
  padding: 7px 14px;
  border-radius: var(--radius-md);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.bo-secondary-btn:hover {
  background: var(--bg-surface-hover);
  border-color: rgba(255, 255, 255, 0.25);
}

.bo-logout-btn {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #f87171;
  padding: 7px 12px;
  border-radius: var(--radius-md);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
}

.bo-logout-btn:hover {
  background: rgba(239, 68, 68, 0.25);
}

/* KPI Grid */
.bo-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.bo-kpi-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
}

.bo-kpi-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.bo-kpi-val {
  font-size: 1.4rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: #ffffff;
}

/* Tab Navigation */
.bo-tabs-nav {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 20px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.bo-tab-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 700;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.bo-tab-btn.active {
  background: rgba(16, 185, 129, 0.15);
  color: var(--emerald-light);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.bo-tab-btn:hover:not(.active) {
  color: #ffffff;
  background: var(--bg-surface-elevated);
}

/* Tab Panes */
.bo-tab-pane {
  display: none;
}

.bo-tab-pane.active {
  display: block;
}

.bo-pane-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.bo-filter-input {
  flex: 1;
  min-width: 240px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  padding: 8px 14px;
  border-radius: var(--radius-md);
  color: #ffffff;
  font-size: 0.84rem;
}

.bo-count-text {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Data Table */
.bo-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
}

.bo-data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  text-align: left;
}

.bo-data-table th {
  background: #141c2b;
  padding: 10px 12px;
  color: var(--text-secondary);
  font-weight: 700;
  border-bottom: 1px solid var(--border-subtle);
  white-space: nowrap;
}

.bo-data-table td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  color: #e2e8f0;
  vertical-align: middle;
}

.bo-data-table tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.bo-action-btn-sm {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.72rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.bo-action-btn-sm:hover {
  background: #ffffff;
  color: #090d16;
}

.bo-action-btn-sm.del:hover {
  background: #ef4444;
  color: #ffffff;
  border-color: #ef4444;
}

/* Forms */
.bo-form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 600px) {
  .bo-form-grid {
    grid-template-columns: 1fr 1fr;
  }
  .bo-form-grid .span-2 {
    grid-column: span 2;
  }
}

.bo-form-grid .form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.bo-form-grid label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.bo-form-grid input,
.bo-form-grid select,
.bo-form-grid textarea {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  color: #ffffff;
  font-size: 0.82rem;
  font-family: inherit;
}

.bo-form-grid input:focus,
.bo-form-grid select:focus,
.bo-form-grid textarea:focus {
  outline: none;
  border-color: var(--emerald-primary);
}

.bo-primary-btn {
  background: var(--emerald-primary);
  color: #090d16;
  border: none;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
}

.bo-primary-btn:hover {
  background: var(--emerald-light);
}

/* Sponsor Manager */
.bo-sponsor-manager-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

@media (min-width: 640px) {
  .bo-sponsor-manager-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.bo-sponsor-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bo-sponsor-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.bo-sponsor-slot {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--cyan-accent);
  text-transform: uppercase;
}

.bo-sponsor-header h4 {
  font-size: 0.95rem;
  color: #ffffff;
  margin-top: 2px;
}

.bo-sponsor-card p {
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.bo-setting-input {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  color: #ffffff;
  font-size: 0.78rem;
  font-family: var(--font-mono);
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 38px;
  height: 22px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #374151;
  transition: .3s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .3s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: var(--emerald-primary);
}

input:checked + .slider:before {
  transform: translateX(16px);
}

/* Harvester Controls */
.bo-harvest-controls {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.bo-pipeline-status-card,
.bo-raw-ingest-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 18px;
}

.bo-pipeline-status-card h4,
.bo-raw-ingest-card h4 {
  font-size: 1rem;
  color: #ffffff;
  margin-bottom: 6px;
}

.bo-pipeline-status-card p,
.bo-raw-ingest-card p {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 14px;
  line-height: 1.4;
}

.bo-pipeline-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.bo-raw-ingest-card textarea {
  width: 100%;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px;
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  resize: vertical;
}

/* ==========================================================================
   In-Feed Sponsor Cards Specific Stylings
   ========================================================================== */
.sponsored-ad-card.leadguru-card {
  border-color: rgba(168, 85, 247, 0.4);
  background: linear-gradient(135deg, rgba(23, 17, 36, 0.95), rgba(15, 23, 42, 0.95));
  box-shadow: 0 0 25px rgba(168, 85, 247, 0.1);
}

.leadguru-badge {
  background: linear-gradient(135deg, #a855f7, #6366f1);
  color: #ffffff;
  font-weight: 800;
}

.sponsored-ad-card.valuation-card {
  border-color: rgba(245, 158, 11, 0.35);
  background: linear-gradient(135deg, rgba(30, 24, 15, 0.95), rgba(17, 24, 39, 0.95));
}

.valuation-badge {
  background: #f59e0b;
  color: #090d16;
  font-weight: 800;
}

.sponsored-ad-card.legal-card {
  border-color: rgba(16, 185, 129, 0.35);
  background: linear-gradient(135deg, rgba(13, 27, 22, 0.95), rgba(17, 24, 39, 0.95));
}

.legal-badge {
  background: #10b981;
  color: #090d16;
  font-weight: 800;
}

.sponsored-ad-card.diaspora-card {
  border-color: rgba(6, 182, 212, 0.4);
  background: linear-gradient(135deg, rgba(8, 30, 42, 0.95), rgba(15, 23, 42, 0.95));
}

.diaspora-badge {
  background: #06b6d4;
  color: #090d16;
  font-weight: 800;
}

/* ==========================================================================
   1-Tap Native Share Sheet, Card Action Controls & Toast Notifications
   ========================================================================== */
.card-footer-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-share-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}

.card-share-btn:hover {
  color: var(--emerald-light);
  background: var(--bg-surface-elevated);
}

.card-share-btn.copied {
  color: var(--emerald-light) !important;
}

.btn-share-modal {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #e2e8f0;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-share-modal:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

.btn-share-modal.copied {
  background: rgba(16, 185, 129, 0.2) !important;
  border-color: var(--emerald-primary) !important;
  color: var(--emerald-light) !important;
}

.caribkeys-toast {
  position: fixed;
  bottom: calc(var(--bottom-bar-height) + 24px);
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #0f172a;
  color: #ffffff;
  border: 1px solid var(--emerald-primary);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.7), 0 0 20px rgba(16, 185, 129, 0.35);
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.caribkeys-toast.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.toast-icon {
  font-size: 1rem;
}

.toast-msg {
  white-space: nowrap;
}

/* ==========================================================================
   WhatsApp Inquiry Mode Presets & Bank Print Dossier
   ========================================================================== */
.inquiry-presets-container {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 10px;
  margin-bottom: 12px;
}

.inquiry-preset-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 6px;
  color: #e2e8f0;
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.18s ease;
}

.inquiry-preset-btn:hover {
  background: rgba(37, 211, 102, 0.15);
  border-color: rgba(37, 211, 102, 0.4);
  color: #86efac;
  transform: translateX(2px);
}

.preset-arrow {
  color: var(--emerald-light);
  font-size: 0.85rem;
}

.btn-print-dossier {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: rgba(6, 182, 212, 0.12);
  border: 1px solid rgba(6, 182, 212, 0.35);
  color: #38bdf8;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 8px;
  transition: all 0.2s ease;
}

.btn-print-dossier:hover {
  background: rgba(6, 182, 212, 0.22);
  border-color: #38bdf8;
  color: #ffffff;
}

/* ==========================================================================
   Bank Pre-Approval Dossier Print Stylesheet (@media print)
   ========================================================================== */
@media screen {
  .print-only-dossier {
    display: none !important;
  }
}

@media print {
  @page {
    margin: 1cm;
    size: A4 portrait;
  }

  body {
    background: #ffffff !important;
    color: #0f172a !important;
    padding: 0 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .app-layout,
  .app-header,
  .search-section,
  .properties-feed-container,
  .modal-backdrop,
  .mobile-bottom-bar,
  #detail-modal,
  #pro-modal,
  #backoffice-modal,
  .caribkeys-toast {
    display: none !important;
  }

  .print-only-dossier {
    display: block !important;
    width: 100% !important;
    max-width: 800px;
    margin: 0 auto;
    padding: 10px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
    background: #ffffff !important;
    color: #0f172a !important;
  }

  .print-dossier-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-bottom: 2px solid #0f172a;
    padding-bottom: 12px;
    margin-bottom: 14px;
  }

  .print-brand-title {
    font-size: 1.6rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.02em;
  }

  .print-brand-sub {
    font-size: 0.78rem;
    text-transform: uppercase;
    font-weight: 700;
    color: #059669;
    letter-spacing: 0.05em;
  }

  .print-meta-box {
    text-align: right;
    font-size: 0.76rem;
    color: #475569;
    line-height: 1.4;
  }

  .print-hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 16px;
    margin-bottom: 14px;
  }

  .print-hero-img {
    width: 100%;
    aspect-ratio: 16/10;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    display: block;
  }

  .print-price-box {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 12px;
  }

  .print-price-headline {
    font-size: 1.55rem;
    font-weight: 800;
    color: #059669;
    font-family: monospace;
    margin-bottom: 2px;
  }

  .print-specs-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 8px;
    font-size: 0.8rem;
  }

  .print-specs-table td {
    padding: 4px 6px;
    border-bottom: 1px solid #e2e8f0;
  }

  .print-section-title {
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
    color: #334155;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 2px;
  }

  .print-desc {
    font-size: 0.8rem;
    color: #334155;
    line-height: 1.45;
    margin-bottom: 14px;
  }

  .print-agent-box {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 10px 12px;
    margin-bottom: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .print-verification-footer {
    border-top: 2px solid #0f172a;
    padding-top: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.7rem;
    color: #64748b;
  }
}

/* --- FEATURED LISTINGS PINNING & PROMOTION --- */
.badge-tag.featured {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #090d16;
  font-weight: 800;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.45);
}

.property-card.featured-card {
  border: 1px solid rgba(245, 158, 11, 0.55);
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.12);
  position: relative;
}

.property-card.featured-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #f59e0b, #fbbf24, #f59e0b);
  border-radius: 12px 12px 0 0;
  z-index: 3;
}

/* --- COUNTRY-EXCLUSIVE FINANCIAL CARD (MODAL) --- */
.country-finance-card {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(15, 23, 42, 0.95) 100%);
  border: 1px solid rgba(16, 185, 129, 0.28);
  border-radius: 10px;
  padding: 14px;
  margin-bottom: 16px;
}

.country-finance-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.country-finance-title {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--emerald-light);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: flex;
  align-items: center;
  gap: 6px;
}

.country-tax-pill {
  font-size: 0.72rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
}

.country-tax-pill.exempt {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.country-tax-pill.due {
  background: rgba(245, 158, 11, 0.18);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.country-finance-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  font-size: 0.82rem;
  margin-bottom: 10px;
}

.country-finance-perks {
  font-size: 0.76rem;
  color: #94a3b8;
  line-height: 1.45;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  padding-top: 8px;
}

/* --- FEATURED LISTING PRICING & PAYMENT MODAL --- */
.featured-pricing-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(17, 24, 39, 0.95));
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 10px;
  padding: 14px 18px;
  margin-bottom: 16px;
}

.featured-price-tag {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-family: var(--font-mono);
}

.featured-price-tag .price-val {
  font-size: 1.55rem;
  font-weight: 800;
  color: #fbbf24;
}

.featured-price-tag .price-divider {
  color: #64748b;
  font-size: 1.1rem;
}

.featured-price-tag .price-val-usd {
  font-size: 1.2rem;
  font-weight: 700;
  color: #f8fafc;
}

.featured-badge-pill {
  font-size: 0.68rem;
  font-weight: 800;
  background: #f59e0b;
  color: #090d16;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.payment-options-title {
  font-size: 0.74rem;
  font-weight: 800;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 18px 0 10px 0;
}

.payment-rail-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.payment-rail-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  background: #111827;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
}

.payment-rail-card:hover {
  background: #1e293b;
  border-color: rgba(245, 158, 11, 0.4);
  transform: translateY(-1px);
}

.payment-rail-card .rail-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
}

.payment-rail-card .rail-info {
  flex-grow: 1;
}

.payment-rail-card .rail-info strong {
  display: block;
  font-size: 0.88rem;
  color: #f8fafc;
  margin-bottom: 2px;
}

.payment-rail-card .rail-info span {
  font-size: 0.74rem;
  color: #94a3b8;
  line-height: 1.3;
  display: block;
}

.payment-rail-card .rail-arrow {
  color: #fbbf24;
  font-size: 0.95rem;
  font-weight: 800;
}

.btn-promote-modal-trigger {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.16), rgba(245, 158, 11, 0.05));
  border: 1px solid rgba(245, 158, 11, 0.45);
  color: #fbbf24;
  font-weight: 700;
  font-size: 0.84rem;
  padding: 10px;
  border-radius: 8px;
  cursor: pointer;
  margin-top: 8px;
  transition: all 0.2s ease;
}

.btn-promote-modal-trigger:hover {
  background: rgba(245, 158, 11, 0.25);
  border-color: #fbbf24;
}

/* Hero Statement */
.hero-banner {
  text-align: center;
  margin-bottom: 16px;
  padding: 4px 0;
}

.hero-title {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #f8fafc;
  margin-bottom: 4px;
}

.hero-subtitle {
  font-size: 0.85rem;
  color: #94a3b8;
  font-weight: 500;
}

@media (max-width: 640px) {
  .hero-title {
    font-size: 1.05rem;
  }
  .hero-subtitle {
    font-size: 0.78rem;
  }
}

/* Calculator Header Button */
.calc-tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: var(--emerald-light);
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.calc-tool-btn:hover {
  background: rgba(16, 185, 129, 0.22);
  border-color: var(--emerald-primary);
  transform: translateY(-1px);
}

/* Calculator Modal Theme */
.calc-card-theme {
  max-width: 620px;
  width: 95%;
  background: #0f172a;
  border: 1px solid rgba(16, 185, 129, 0.35);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.8), 0 0 30px rgba(16, 185, 129, 0.15);
}

.calc-badge-header {
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--emerald-light);
  letter-spacing: 0.05em;
}

.calc-modal-body {
  padding: 16px 20px 24px;
  max-height: 82vh;
  overflow-y: auto;
}

.calc-country-tabs {
  display: flex;
  gap: 6px;
  background: #1e293b;
  padding: 4px;
  border-radius: 10px;
  margin-bottom: 16px;
  overflow-x: auto;
}

.calc-country-tab {
  flex: 1;
  min-width: 90px;
  padding: 8px 10px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #94a3b8;
  background: transparent;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.calc-country-tab.active {
  background: var(--emerald-primary);
  color: #090d16;
  box-shadow: 0 2px 6px rgba(16, 185, 129, 0.3);
}

.calc-input-group {
  margin-bottom: 14px;
}

.calc-input-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: #cbd5e1;
  font-weight: 600;
  margin-bottom: 6px;
}

.calc-val-pill {
  font-family: var(--font-mono);
  color: var(--emerald-light);
  font-weight: 700;
}

.calc-range-slider {
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: #334155;
  outline: none;
  -webkit-appearance: none;
  accent-color: var(--emerald-primary);
  cursor: pointer;
}

.calc-quick-pills {
  display: flex;
  gap: 6px;
  margin-top: 6px;
  flex-wrap: wrap;
}

.calc-pill-btn {
  padding: 4px 10px;
  font-size: 0.74rem;
  font-weight: 600;
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #cbd5e1;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s;
}

.calc-pill-btn:hover {
  border-color: var(--emerald-primary);
  color: #ffffff;
}

.calc-pill-btn.active {
  background: rgba(16, 185, 129, 0.2);
  border-color: var(--emerald-primary);
  color: var(--emerald-light);
  font-weight: 700;
}

/* Calculator Summary Result Card */
.calc-summary-card {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(15, 23, 42, 0.95));
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: 12px;
  padding: 16px;
  margin-top: 18px;
}

.calc-summary-highlight {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 12px;
}

.calc-highlight-val {
  font-size: 1.6rem;
  font-family: var(--font-mono);
  font-weight: 800;
  color: var(--emerald-light);
}

.calc-breakdown-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  font-size: 0.8rem;
  color: #cbd5e1;
  margin-bottom: 14px;
}

.calc-breakdown-item {
  background: rgba(0, 0, 0, 0.25);
  padding: 8px 10px;
  border-radius: 6px;
}

.calc-breakdown-item span {
  display: block;
  font-size: 0.7rem;
  color: #94a3b8;
  margin-bottom: 2px;
}

.calc-breakdown-item strong {
  font-family: var(--font-mono);
  color: #f8fafc;
}

.calc-cta-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px;
  background: var(--emerald-primary);
  color: #090d16;
  font-weight: 800;
  font-size: 0.88rem;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
}

.calc-cta-btn:hover {
  background: var(--emerald-light);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(16, 185, 129, 0.35);
}

/* Global Desktop Footer */
.app-desktop-footer {
  margin-top: 48px;
  padding: 24px 16px;
  border-top: 1px solid var(--border-subtle);
  background: rgba(9, 13, 22, 0.95);
  font-size: 0.8rem;
  color: var(--text-muted);
}

.footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-admin-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.75rem;
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid transparent;
  transition: all 0.2s;
}

.footer-admin-link:hover {
  color: #94a3b8;
  border-color: rgba(255, 255, 255, 0.1);
}



