/* Admin Login & Dashboard */
.admin-body {
  background-color: #f4f4f4;
  font-family: 'Segoe UI', sans-serif;
}
.login-container {
  max-width: 400px;
  margin: 100px auto;
  background: white;
  padding: 40px;
  border-radius: 8px;
  box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}
.login-container h2 {
  text-align: center;
  margin-bottom: 30px;
  color: var(--gold-dark);
}
.login-container .btn {
  width: 100%;
  padding: 14px;
}
.dashboard-header {
  background-color: var(--dark);
  color: white;
  padding: 15px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}
.dashboard-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.dashboard-header h1 {
  color: var(--gold);
  margin: 0;
}
.logout-btn {
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
  padding: 8px 20px;
  border-radius: 4px;
  cursor: pointer;
  transition: var(--transition);
}
.logout-btn:hover {
  background: var(--gold);
  color: white;
}
.dashboard-main {
  padding: 40px 0;
}
.leads-table {
  width: 100%;
  background: white;
  border-collapse: collapse;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.leads-table th,
.leads-table td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid #eee;
}
.leads-table th {
  background-color: var(--gold-light);
  color: var(--dark);
  font-weight: 600;
}
.leads-table tr:hover {
  background-color: #fafafa;
}
.leads-table img {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 4px;
}
.price-card {
  background: white;
  padding: 25px;
  border-radius: 8px;
  margin-bottom: 30px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.price-card h3 {
  color: var(--gold-dark);
  margin-bottom: 20px;
}
.price-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  align-items: end;
}
.price-form .form-group {
  margin-bottom: 0;
}
.price-form .btn {
  padding: 12px 20px;
  margin-top: 24px;
}
/* WhatsApp column */
.wa-link {
  color: #25d366;
  font-size: 1.5rem;
  transition: transform 0.2s;
  display: inline-block;
}
.wa-link:hover {
  transform: scale(1.2);
}
.bulk-wa {
  margin-bottom: 20px;
  text-align: right;
}
.bulk-wa textarea {
  width: 100%;
  margin-top: 10px;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 0.9rem;
  display: none;
}
/* Debug panel */
#apiDebug {
  background: #f0f0f0;
  padding: 10px;
  margin-bottom: 20px;
  border-radius: 4px;
  font-family: monospace;
  white-space: pre-wrap;
  max-height: 300px;
  overflow: auto;
}
/* Counter Cards */
.counter-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 15px;
  margin-bottom: 30px;
}
.counter-card {
  background: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
}
.counter-card.new { border-left: 5px solid #27ae60; }
.counter-card.contacted { border-left: 5px solid #f39c12; }
.counter-card.interested { border-left: 5px solid #2980b9; }
.counter-card.negotiating { border-left: 5px solid #e67e22; }
.counter-card.closed { border-left: 5px solid #e74c3c; }
.counter-card.rejected { border-left: 5px solid #7f8c8d; }

/* Chart Card */
.chart-card {
  background: white;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 30px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

/* Filter Bar */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
  align-items: center;
}
.filter-bar input, .filter-bar select {
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  min-width: 150px;
}
.filter-bar .btn {
  padding: 10px 20px;
  margin-left: auto;
}

/* Status Badge & Dropdown */
.status-badge {
  padding: 4px 8px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  color: white;
  display: inline-block;
  cursor: pointer;
}
.status-new { background-color: #27ae60; }
.status-contacted { background-color: #f39c12; }
.status-interested { background-color: #2980b9; }
.status-negotiating { background-color: #e67e22; }
.status-closed { background-color: #e74c3c; }
.status-rejected { background-color: #7f8c8d; }

.status-select {
  padding: 4px;
  border-radius: 4px;
  font-size: 0.8rem;
}
/* Counter Cards */
.counter-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 15px;
  margin-bottom: 30px;
}
.counter-card {
  background: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
}
.counter-card.new { border-left: 5px solid #27ae60; }
.counter-card.contacted { border-left: 5px solid #f39c12; }
.counter-card.interested { border-left: 5px solid #2980b9; }
.counter-card.negotiating { border-left: 5px solid #e67e22; }
.counter-card.closed { border-left: 5px solid #e74c3c; }
.counter-card.rejected { border-left: 5px solid #7f8c8d; }

/* Filter Bar */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
  align-items: center;
}
.filter-bar input, .filter-bar select {
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  min-width: 150px;
}
.filter-bar .btn {
  padding: 10px 20px;
}

/* Status Dropdown */
.status-select {
  padding: 4px;
  border-radius: 4px;
  font-size: 0.8rem;
}
/* ... existing styles ... */

/* Status dropdown */
.status-select {
  padding: 5px;
  border: 1px solid #ddd;
  border-radius: 4px;
  background: white;
  cursor: pointer;
}
.status-select:focus {
  outline: none;
  border-color: var(--gold);
}

/* Price chart container */
#priceChart {
  max-height: 300px;
  width: 100%;
}

/* Download button icon */
#downloadLeadsBtn i {
  margin-right: 8px;
}

/* Responsive filter bar */
@media (max-width: 768px) {
  .dashboard-main > div:first-of-type {
    flex-direction: column;
    align-items: stretch !important;
  }
  #serviceFilter, #statusFilter, #downloadLeadsBtn {
    width: 100%;
  }
}