/* Dashboard layout — sidebar + main content */

.dashboard-body {
  display: flex;
  min-height: 100vh;
  background: var(--bg-primary);
}

/* ---- SIDEBAR ---- */
.sidebar {
  width: 240px;
  min-height: 100vh;
  background: var(--bg-secondary);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 28px 20px;
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.sidebar__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 36px;
}

.sidebar__logo {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--fg-primary);
  text-decoration: none;
  letter-spacing: -0.5px;
}

.sidebar__badge {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-glow);
  border: 1px solid rgba(212, 168, 67, 0.3);
  border-radius: 6px;
  padding: 2px 8px;
}

.sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.sidebar__link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--fg-secondary);
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}

.sidebar__link:hover {
  background: var(--bg-card);
  color: var(--fg-primary);
}

.sidebar__link--active {
  background: var(--bg-card);
  color: var(--fg-primary);
  border: 1px solid var(--border);
}

.sidebar__icon {
  font-size: 14px;
  width: 20px;
  text-align: center;
}

.sidebar__business {
  margin-top: 24px;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.sidebar__biz-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--fg-primary);
  margin-bottom: 4px;
}

.sidebar__biz-phone {
  font-size: 12px;
  color: var(--fg-muted);
}

.sidebar__upgrade {
  display: block;
  margin-top: 16px;
  padding: 11px 14px;
  background: var(--accent);
  color: var(--bg-primary);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  transition: opacity 0.2s;
}

.sidebar__upgrade:hover {
  opacity: 0.88;
}

/* ---- MAIN ---- */
.dash-main {
  flex: 1;
  min-width: 0;
  padding: 40px 48px;
  overflow-y: auto;
}

/* ---- HEADER ---- */
.dash-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 36px;
}

.dash-header h1 {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: 2rem;
  letter-spacing: -0.5px;
  line-height: 1.1;
  margin-bottom: 6px;
}

.dash-header__sub {
  font-size: 14px;
  color: var(--fg-muted);
}

.simulate-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--fg-primary);
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  position: relative;
}

.simulate-btn:hover:not(:disabled) {
  border-color: var(--accent-dim);
  background: var(--accent-glow);
}

.simulate-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.simulate-btn__pulse {
  width: 8px;
  height: 8px;
  background: #22c55e;
  border-radius: 50%;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.3); }
}

/* ---- STATS ---- */
.dash-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 32px;
}

.dash-stat {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
}

.dash-stat--accent {
  border-color: rgba(212, 168, 67, 0.35);
  background: rgba(212, 168, 67, 0.04);
}

.dash-stat__value {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: 2.4rem;
  color: var(--fg-primary);
  line-height: 1.1;
  letter-spacing: -1px;
}

.dash-stat--accent .dash-stat__value {
  color: var(--accent);
}

.dash-stat__label {
  font-size: 13px;
  font-weight: 600;
  color: var(--fg-secondary);
  margin-top: 6px;
}

.dash-stat__sub {
  font-size: 12px;
  color: var(--fg-muted);
  margin-top: 3px;
}

/* ---- SIMULATE BANNER ---- */
.simulate-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: rgba(212, 168, 67, 0.08);
  border: 1px solid rgba(212, 168, 67, 0.3);
  border-radius: 10px;
  margin-bottom: 28px;
  animation: fadein 0.3s ease;
}

@keyframes fadein {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

.simulate-banner__icon {
  font-size: 20px;
}

.simulate-banner__text {
  font-size: 14px;
  font-weight: 500;
  color: var(--fg-primary);
}

/* ---- GRID ---- */
.dash-grid {
  display: grid;
  grid-template-columns: 1.7fr 1fr;
  gap: 20px;
  margin-bottom: 32px;
}

/* ---- CARDS ---- */
.dash-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

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

.dash-card__header h2 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.3px;
}

.dash-card__count {
  font-size: 12px;
  color: var(--fg-muted);
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 3px 10px;
}

/* ---- CALLS LIST ---- */
.calls-list {
  max-height: 420px;
  overflow-y: auto;
}

.calls-empty {
  padding: 40px 24px;
  text-align: center;
  color: var(--fg-muted);
  font-size: 14px;
}

.call-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 24px;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}

.call-row:last-child {
  border-bottom: none;
}

.call-row:hover {
  background: var(--bg-secondary);
}

.call-row__avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-glow);
  border: 1px solid rgba(212, 168, 67, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: var(--accent);
  flex-shrink: 0;
}

.call-row__info {
  min-width: 130px;
}

.call-row__name {
  font-size: 14px;
  font-weight: 600;
  color: var(--fg-primary);
}

.call-row__phone {
  font-size: 12px;
  color: var(--fg-muted);
  margin-top: 2px;
}

.call-row__mid {
  flex: 1;
  min-width: 0;
}

.call-row__reply {
  display: flex;
  align-items: center;
  gap: 8px;
}

.reply-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  flex-shrink: 0;
}

.call-row__reply-msg {
  font-size: 12px;
  color: var(--fg-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.call-row__no-reply {
  font-size: 12px;
  color: var(--fg-muted);
  font-style: italic;
}

.call-row__right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  flex-shrink: 0;
}

.call-row__time {
  font-size: 11px;
  color: var(--fg-muted);
}

/* Status badges */
.call-status {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.call-status--booked {
  background: rgba(34, 197, 94, 0.12);
  color: #22c55e;
  border: 1px solid rgba(34, 197, 94, 0.25);
}

.call-status--replied {
  background: rgba(212, 168, 67, 0.12);
  color: var(--accent);
  border: 1px solid rgba(212, 168, 67, 0.25);
}

.call-status--missed {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.call-status--closed {
  background: var(--bg-secondary);
  color: var(--fg-muted);
  border: 1px solid var(--border);
}

/* ---- APPOINTMENTS ---- */
.appt-list {
  max-height: 420px;
  overflow-y: auto;
}

.appt-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}

.appt-row:last-child {
  border-bottom: none;
}

.appt-row:hover {
  background: var(--bg-secondary);
}

.appt-row__date {
  min-width: 56px;
  text-align: center;
  background: var(--accent-glow);
  border: 1px solid rgba(212, 168, 67, 0.2);
  border-radius: 8px;
  padding: 8px 4px;
}

.appt-row__day {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 12px;
  color: var(--accent);
  white-space: nowrap;
}

.appt-row__time {
  font-size: 11px;
  color: var(--fg-muted);
  margin-top: 2px;
  white-space: nowrap;
}

.appt-row__info {
  flex: 1;
}

.appt-row__name {
  font-size: 14px;
  font-weight: 600;
  color: var(--fg-primary);
}

.appt-row__service {
  font-size: 12px;
  color: var(--fg-secondary);
  margin-top: 2px;
}

.conf-sent {
  font-size: 11px;
  color: #22c55e;
  white-space: nowrap;
}

/* ---- HOW IT WORKS ---- */
.dash-how {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  margin-bottom: 32px;
}

.dash-how__header {
  margin-bottom: 40px;
}

.dash-how__header h2 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: -0.3px;
  margin-bottom: 8px;
}

.dash-how__header p {
  font-size: 14px;
  color: var(--fg-secondary);
}

.dash-how__steps {
  display: flex;
  align-items: center;
  gap: 0;
}

.how-step {
  flex: 1;
  padding: 0 20px;
  position: relative;
}

.how-step__arrow {
  font-size: 20px;
  color: var(--fg-muted);
  flex-shrink: 0;
}

.how-step__num {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: 11px;
  color: var(--fg-muted);
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.how-step__icon {
  font-size: 28px;
  margin-bottom: 12px;
}

.how-step__title {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 15px;
  margin-bottom: 8px;
}

.how-step__desc {
  font-size: 13px;
  color: var(--fg-secondary);
  line-height: 1.6;
}

/* ---- FOOTER ---- */
.dash-footer {
  padding: 24px 0 8px;
  border-top: 1px solid var(--border);
}

.dash-footer p {
  font-size: 13px;
  color: var(--fg-muted);
}

.dash-footer a {
  color: var(--fg-secondary);
  text-decoration: none;
}

.dash-footer a:hover {
  color: var(--fg-primary);
}

/* ---- RESPONSIVE ---- */
@media (max-width: 1024px) {
  .dash-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .dash-grid {
    grid-template-columns: 1fr;
  }
  .dash-how__steps {
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
  }
  .how-step__arrow {
    transform: rotate(90deg);
  }
}

@media (max-width: 768px) {
  .sidebar {
    display: none;
  }
  .dash-main {
    padding: 24px 20px;
  }
  .dash-stats {
    grid-template-columns: 1fr 1fr;
  }
  .call-row__mid {
    display: none;
  }
}
