:root {
  --black: #050806;
  --green: #009b3a;
  --green-bright: #16e85f;
  --gold: #fed100;
  --deep: #0c1711;
  --panel: rgba(14, 31, 22, 0.9);
  --line: rgba(254, 209, 0, 0.22);
  --text: #f7fff9;
  --muted: rgba(247, 255, 249, 0.72);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px 1fr;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 74% 18%, rgba(0, 155, 58, 0.24), transparent 34%),
    linear-gradient(135deg, rgba(254, 209, 0, 0.14), transparent 26%),
    var(--black);
}

a { color: inherit; text-decoration: none; }

.client-sidebar {
  min-height: 100vh;
  padding: 28px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(4, 8, 6, 0.86);
  position: sticky;
  top: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: conic-gradient(from 45deg, var(--gold) 0 25%, var(--black) 0 50%, var(--green) 0 75%, var(--gold) 0);
  box-shadow: 0 0 22px rgba(22, 232, 95, 0.45);
}

.client-sidebar nav {
  display: grid;
  gap: 10px;
  margin: 44px 0;
}

.client-sidebar nav a {
  padding: 13px 14px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--muted);
  font-weight: 800;
}

.client-sidebar nav a:hover,
.client-sidebar nav a.active {
  color: var(--text);
  border-color: var(--line);
  background: rgba(0, 155, 58, 0.16);
}

.support-card,
.panel,
.metric-grid article {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.32);
}

.support-card {
  padding: 18px;
}

.support-card span,
.eyebrow,
.metric-grid span,
.customer-card span {
  color: var(--gold);
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.support-card strong {
  display: block;
  margin: 8px 0;
  font-size: 1.15rem;
}

small,
p {
  color: var(--muted);
  line-height: 1.55;
}

.client-shell {
  padding: 34px;
}

.client-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 28px;
  margin-bottom: 28px;
}

.client-header h1 {
  max-width: 900px;
  margin: 10px 0;
  font-size: clamp(2rem, 4vw, 4.4rem);
  line-height: 0.98;
}

.client-header p {
  max-width: 760px;
  font-size: 1.02rem;
}

.header-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.primary-button,
.ghost-button,
.small-button {
  min-height: 44px;
  border: 0;
  border-radius: 8px;
  padding: 0 18px;
  font-weight: 900;
  cursor: pointer;
}

.primary-button {
  background: linear-gradient(135deg, var(--green-bright), var(--green));
  color: #041006;
}

.ghost-button,
.small-button {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.metric-grid article {
  padding: 20px;
}

.metric-grid strong {
  display: block;
  margin: 8px 0;
  font-size: 2.45rem;
  line-height: 1;
}

.metric-grid .gold strong {
  color: var(--gold);
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr 0.9fr;
  gap: 18px;
}

.panel {
  padding: 22px;
}

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

.panel h2 {
  margin: 5px 0 0;
  font-size: 1.45rem;
}

.conversation-list,
.appointments,
.task-list,
.customer-card {
  display: grid;
  gap: 12px;
}

.conversation {
  width: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 13px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  text-align: left;
}

.conversation.active {
  border-color: rgba(254, 209, 0, 0.42);
  background: rgba(0, 155, 58, 0.18);
}

.status {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--green-bright);
  box-shadow: 0 0 14px rgba(22, 232, 95, 0.8);
}

.status.warm { background: var(--gold); }
.status.cool { background: #a6b7aa; box-shadow: none; }

.conversation em,
.pill {
  border-radius: 999px;
  padding: 7px 10px;
  background: rgba(254, 209, 0, 0.12);
  color: var(--gold);
  font-size: 0.75rem;
  font-style: normal;
  font-weight: 900;
}

.customer-card {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.customer-card div,
.ai-summary,
.pipeline div,
.appointments div,
.task-list label {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.customer-card div,
.ai-summary {
  padding: 14px;
}

.customer-card strong {
  display: block;
  margin-top: 7px;
}

.ai-summary {
  margin-top: 14px;
}

.ai-summary p {
  margin-bottom: 0;
}

.pipeline-panel,
.appointment-panel,
.followup-panel,
.report-panel {
  min-height: 270px;
}

.pipeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.pipeline div {
  min-height: 120px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 14px;
  border-color: rgba(0, 155, 58, 0.26);
}

.pipeline strong {
  margin-top: 8px;
  font-size: 2rem;
  color: var(--green-bright);
}

.appointments div {
  display: grid;
  gap: 6px;
  padding: 14px;
}

.appointments strong {
  color: var(--gold);
}

.task-list label {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 14px;
  color: var(--muted);
  font-weight: 700;
}

.task-list input {
  accent-color: var(--green);
  margin-top: 3px;
}

.bar-chart {
  height: 170px;
  display: flex;
  align-items: end;
  gap: 12px;
  padding-top: 20px;
}

.bar-chart span {
  flex: 1;
  height: var(--h);
  min-height: 32px;
  border-radius: 8px 8px 0 0;
  background: linear-gradient(180deg, var(--gold), var(--green));
}

.client-calls-panel {
  grid-column: span 2;
}

.client-call-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.client-call-grid div,
.call-log div {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.client-call-grid div {
  padding: 14px;
}

.client-call-grid span {
  color: var(--gold);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.client-call-grid strong {
  display: block;
  margin: 8px 0;
  color: var(--green-bright);
  font-size: 1.65rem;
  line-height: 1;
}

.call-log {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.call-log div {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 13px;
}

.call-log strong {
  color: var(--gold);
}

.call-log span {
  color: var(--muted);
  font-weight: 750;
}

.call-log em {
  border-radius: 999px;
  padding: 7px 10px;
  background: rgba(0, 155, 58, 0.18);
  color: var(--green-bright);
  font-size: 0.75rem;
  font-style: normal;
  font-weight: 900;
}

@media (max-width: 1100px) {
  body {
    grid-template-columns: 1fr;
  }

  .client-sidebar {
    position: relative;
    min-height: auto;
  }

  .client-sidebar nav {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin: 24px 0;
  }

  .client-header,
  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .client-calls-panel {
    grid-column: auto;
  }

  .client-header {
    display: grid;
  }

  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .client-shell,
  .client-sidebar {
    padding: 20px;
  }

  .client-sidebar nav,
  .metric-grid,
  .customer-card,
  .pipeline,
  .client-call-grid,
  .call-log div {
    grid-template-columns: 1fr;
  }

  .header-actions {
    justify-content: stretch;
  }

  .primary-button,
  .ghost-button {
    width: 100%;
    justify-content: center;
  }
}
