/* ===== DASHBOARD PIPELINE ===== */
.dash-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 32px;
  background: rgba(8, 11, 20, 0.95);
  border-bottom: 1px solid rgba(201, 169, 110, 0.15);
}
.dash-nav-back {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ivory-muted);
  text-decoration: none;
  font-size: 13px;
  transition: color 0.2s;
}
.dash-nav-back:hover { color: var(--gold); }
.dash-nav-brand {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 500;
  color: var(--gold);
}
.dash-nav-tag {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ivory-muted);
  opacity: 0.6;
}

.pipeline {
  padding: 100px 32px 48px;
  min-height: 100vh;
  background: var(--midnight);
}
.pipeline-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 40px;
  flex-wrap: wrap;
  gap: 20px;
}
.pipeline-title {
  font-family: var(--font-display);
  font-size: 36px;
  font-weight: 300;
  color: var(--ivory);
  margin-bottom: 4px;
}
.pipeline-subtitle {
  font-size: 14px;
  color: var(--ivory-muted);
  opacity: 0.6;
}
.pipeline-filters {
  display: flex;
  align-items: center;
  gap: 16px;
}
.filter-select {
  background: rgba(15, 21, 37, 0.8);
  border: 1px solid rgba(201, 169, 110, 0.2);
  border-radius: 8px;
  padding: 10px 16px;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--ivory);
  cursor: pointer;
  min-width: 160px;
}
.filter-select:focus {
  outline: none;
  border-color: var(--gold);
}
.filter-select option {
  background: var(--midnight-panel);
  color: var(--ivory);
}
.btn-add {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--gold);
  color: var(--midnight);
  border: none;
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s;
}
.btn-add:hover {
  background: var(--gold-light);
  box-shadow: 0 0 20px rgba(201, 169, 110, 0.3);
}

/* ===== KANBAN BOARD ===== */
.kanban-board {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  align-items: start;
}
.kanban-col {
  background: rgba(15, 21, 37, 0.5);
  border: 1px solid rgba(201, 169, 110, 0.1);
  border-radius: 12px;
  padding: 16px;
  min-height: 200px;
}
.kanban-col-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(201, 169, 110, 0.1);
}
.kanban-col-title {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.kanban-col[data-status="new"] .kanban-col-title { color: var(--amber); }
.kanban-col[data-status="qualified"] .kanban-col-title { color: var(--gold); }
.kanban-col[data-status="tour_scheduled"] .kanban-col-title { color: var(--gold-light); }
.kanban-col[data-status="contract_sent"] .kanban-col-title { color: var(--ivory-muted); }
.kanban-col[data-status="booked"] .kanban-col-title { color: #4ade80; }

.kanban-col-count {
  background: rgba(201, 169, 110, 0.15);
  border-radius: 10px;
  padding: 2px 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gold);
}
.kanban-cards {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ===== LEAD CARDS ===== */
.lead-card {
  background: rgba(15, 21, 37, 0.8);
  border: 1px solid rgba(201, 169, 110, 0.08);
  border-radius: 8px;
  padding: 14px;
  cursor: pointer;
  transition: border-color 0.2s, transform 0.2s;
}
.lead-card:hover {
  border-color: rgba(201, 169, 110, 0.3);
  transform: translateY(-2px);
}
.lead-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 8px;
}
.lead-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--ivory);
  line-height: 1.3;
}
.lead-budget {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gold);
  white-space: nowrap;
}
.lead-card-venue {
  font-size: 12px;
  color: var(--ivory-muted);
  opacity: 0.7;
  margin-bottom: 10px;
}
.lead-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.lead-date {
  font-size: 11px;
  color: var(--ivory-muted);
  opacity: 0.5;
}
.lead-source {
  font-size: 10px;
  padding: 2px 8px;
  background: rgba(201, 169, 110, 0.1);
  border-radius: 4px;
  color: var(--gold);
  opacity: 0.8;
}

/* ===== MODALS ===== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0.2s;
}
.modal.open {
  opacity: 1;
  visibility: visible;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 11, 20, 0.85);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.modal-content {
  position: relative;
  background: var(--midnight-panel);
  border: 1px solid rgba(201, 169, 110, 0.2);
  border-radius: 16px;
  padding: 32px;
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5);
}
.modal-detail {
  max-width: 640px;
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}
.modal-header h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 400;
  color: var(--ivory);
}
.modal-close {
  background: none;
  border: none;
  font-size: 28px;
  color: var(--ivory-muted);
  cursor: pointer;
  line-height: 1;
  padding: 0;
  transition: color 0.2s;
}
.modal-close:hover { color: var(--gold); }

/* ===== FORMS ===== */
.lead-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-group label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ivory-muted);
}
.form-group input,
.form-group select,
.form-group textarea {
  background: rgba(8, 11, 20, 0.6);
  border: 1px solid rgba(201, 169, 110, 0.15);
  border-radius: 8px;
  padding: 12px 14px;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--ivory);
  transition: border-color 0.2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--gold);
}
.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--ivory-muted);
  opacity: 0.4;
}
.form-group select option {
  background: var(--midnight-panel);
}
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 8px;
}
.btn-cancel {
  padding: 10px 20px;
  background: transparent;
  border: 1px solid rgba(201, 169, 110, 0.3);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--ivory-muted);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.btn-cancel:hover {
  border-color: var(--gold);
  color: var(--ivory);
}
.btn-save {
  padding: 10px 24px;
  background: var(--gold);
  border: none;
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--midnight);
  cursor: pointer;
  transition: background 0.2s;
}
.btn-save:hover { background: var(--gold-light); }

/* ===== LEAD DETAIL ===== */
.detail-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}
.detail-badge {
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.detail-badge.status-new { background: rgba(232, 184, 75, 0.15); color: var(--amber); }
.detail-badge.status-qualified { background: rgba(201, 169, 110, 0.15); color: var(--gold); }
.detail-badge.status-tour_scheduled { background: rgba(201, 169, 110, 0.12); color: var(--gold-light); }
.detail-badge.status-contract_sent { background: rgba(255, 255, 255, 0.08); color: var(--ivory-muted); }
.detail-badge.status-booked { background: rgba(74, 222, 128, 0.15); color: #4ade80; }

.detail-venue {
  font-size: 13px;
  color: var(--ivory-muted);
  opacity: 0.7;
}
.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
}
.detail-section h3 {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
  opacity: 0.7;
}
.detail-list {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 16px;
}
.detail-list dt {
  font-size: 12px;
  color: var(--ivory-muted);
  opacity: 0.6;
}
.detail-list dd {
  font-size: 13px;
  color: var(--ivory);
}
.detail-notes {
  padding-top: 20px;
  border-top: 1px solid rgba(201, 169, 110, 0.1);
  margin-bottom: 24px;
}
.detail-notes p {
  font-size: 14px;
  color: var(--ivory-muted);
  line-height: 1.6;
}
.detail-followups h3 {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
  opacity: 0.7;
}
#detail-followups-list {
  margin-bottom: 16px;
  max-height: 200px;
  overflow-y: auto;
}
.followup-item {
  padding: 12px;
  background: rgba(8, 11, 20, 0.4);
  border-radius: 8px;
  margin-bottom: 8px;
}
.followup-date {
  font-size: 11px;
  color: var(--gold);
  opacity: 0.7;
  margin-bottom: 4px;
}
.followup-note {
  font-size: 13px;
  color: var(--ivory);
  line-height: 1.5;
}
.no-followups {
  font-size: 13px;
  color: var(--ivory-muted);
  opacity: 0.5;
  font-style: italic;
}
.followup-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.followup-form textarea {
  background: rgba(8, 11, 20, 0.6);
  border: 1px solid rgba(201, 169, 110, 0.15);
  border-radius: 8px;
  padding: 12px 14px;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--ivory);
  resize: none;
}
.followup-form textarea:focus {
  outline: none;
  border-color: var(--gold);
}
.btn-add-followup {
  align-self: flex-end;
  padding: 8px 16px;
  background: transparent;
  border: 1px solid rgba(201, 169, 110, 0.3);
  border-radius: 6px;
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--ivory-muted);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.btn-add-followup:hover {
  border-color: var(--gold);
  color: var(--ivory);
}
.detail-actions {
  display: flex;
  gap: 12px;
  padding-top: 20px;
  border-top: 1px solid rgba(201, 169, 110, 0.1);
  margin-top: 24px;
}
.btn-edit-lead {
  flex: 1;
  padding: 10px 20px;
  background: var(--gold);
  border: none;
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--midnight);
  cursor: pointer;
  transition: background 0.2s;
}
.btn-edit-lead:hover { background: var(--gold-light); }
.btn-delete-lead {
  padding: 10px 20px;
  background: transparent;
  border: 1px solid rgba(220, 100, 100, 0.4);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 13px;
  color: rgb(220, 100, 100);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.btn-delete-lead:hover {
  border-color: rgb(220, 100, 100);
  background: rgba(220, 100, 100, 0.1);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
  .kanban-board {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (max-width: 900px) {
  .kanban-board {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 600px) {
  .pipeline {
    padding: 90px 16px 32px;
  }
  .pipeline-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .kanban-board {
    grid-template-columns: 1fr;
  }
  .modal-content {
    margin: 16px;
    padding: 24px;
  }
  .form-row {
    grid-template-columns: 1fr;
  }
  .detail-grid {
    grid-template-columns: 1fr;
  }
}
