:root {
  --bg-page: #FDF6F0;
  --bg-sidebar: #FBEFE4;
  --bg-sidebar-active: #F3D9C4;
  --text-sidebar-active: #6B3712;
  --text-sidebar: #8A6F5C;
  --text-heading: #3A2E22;
  --text-muted: #A69684;
  --card-bg: #FFFFFF;

  --coral-bg: #FBEFE4; --coral-text: #8A4B23; --coral-strong: #D89B44;
  --sage-bg: #E9F1E4; --sage-text: #4E7A3B; --sage-strong: #8FBF7B;
  --pink-bg: #FBEAF0; --pink-text: #B14C6D; --pink-strong: #E58C7E;

  --radius-card: 12px;
  --radius-pill: 8px;
  --font-body: 'Segoe UI', Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg-page);
  color: var(--text-heading);
}

.app-shell { display: flex; min-height: 100vh; }

/* Sidebar */
.sidebar {
  width: 190px;
  background: var(--bg-sidebar);
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex-shrink: 0;
}
.sidebar-brand {
  font-size: 14px; font-weight: 600; color: var(--coral-text);
  margin-bottom: 16px; padding: 0 8px;
}
.sidebar-item {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px; border-radius: 10px;
  font-size: 13px; color: var(--text-sidebar);
  text-decoration: none;
}
.sidebar-item i { font-size: 15px; }
.sidebar-item.active {
  background: var(--bg-sidebar-active);
  color: var(--text-sidebar-active);
  font-weight: 600;
}
.sidebar-item:hover:not(.active) { background: rgba(0,0,0,0.03); }

/* Main area */
.main { flex: 1; padding: 20px 28px; max-width: 1100px; }
.page-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px;
}
.page-title { font-size: 18px; font-weight: 600; margin: 0; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--bg-sidebar-active); color: var(--coral-text);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 600;
}

/* Stat cards */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat-card { background: var(--card-bg); border-radius: var(--radius-card); padding: 14px; }
.stat-label { font-size: 11px; color: var(--text-muted); }
.stat-value { font-size: 22px; font-weight: 600; margin-top: 4px; }

/* Generic card */
.card { background: var(--card-bg); border-radius: var(--radius-card); padding: 16px; margin-bottom: 14px; }
.card-title { font-size: 12px; color: var(--text-muted); margin-bottom: 10px; }
.card-grid-2 { display: grid; grid-template-columns: 1.3fr 1fr; gap: 14px; }

/* Progress bar */
.progress-track { background: #F2ECE3; border-radius: var(--radius-pill); height: 8px; overflow: hidden; }
.progress-fill { background: var(--sage-strong); height: 100%; border-radius: var(--radius-pill); }

/* Badges */
.badge { font-size: 11px; padding: 3px 10px; border-radius: var(--radius-pill); display: inline-block; }
.badge-sage { background: var(--sage-bg); color: var(--sage-text); }
.badge-coral { background: var(--coral-bg); color: var(--coral-strong); }
.badge-pink { background: var(--pink-bg); color: var(--pink-text); }
.badge-muted { background: #F2ECE3; color: #8A6F5C; }

/* Rows / lists */
.row-item {
  display: flex; align-items: center; gap: 12px;
  background: var(--card-bg); border-radius: var(--radius-card);
  padding: 12px 14px; margin-bottom: 8px;
}
.row-icon {
  width: 34px; height: 34px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.row-title { font-size: 13px; font-weight: 500; }
.row-sub { font-size: 11px; color: var(--text-muted); }

/* Filter tabs */
.filter-tabs { display: flex; gap: 8px; margin-bottom: 16px; }
.filter-tab { font-size: 12px; color: var(--text-sidebar); padding: 5px 12px; border-radius: 8px; cursor: pointer; }
.filter-tab.active { background: var(--bg-sidebar-active); color: var(--text-sidebar-active); }

/* Kanban */
.kanban-board { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.kanban-column { background: rgba(0,0,0,0.02); border-radius: var(--radius-card); padding: 10px; min-height: 200px; }
.kanban-column-title { font-size: 12px; color: var(--text-muted); margin-bottom: 8px; padding: 0 4px; }
.task-card { background: var(--card-bg); border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; font-size: 12px; cursor: grab; }
.task-card.dragging { opacity: 0.5; }

/* Forms */
input, textarea, select, button {
  font-family: var(--font-body); font-size: 13px;
  border: 1px solid #E5DCCF; border-radius: 8px;
  padding: 8px 10px; background: #fff;
}
button { background: var(--bg-sidebar-active); color: var(--text-sidebar-active); border: none; cursor: pointer; font-weight: 600; }
button:hover { filter: brightness(0.97); }
button.secondary { background: #fff; color: var(--text-heading); border: 1px solid #E5DCCF; }

/* Chat / feedback bubbles */
.bubble { border-radius: 12px; padding: 8px 12px; font-size: 12px; max-width: 75%; }
.bubble-in { align-self: flex-start; background: var(--coral-bg); color: #5A4A3C; }
.bubble-out { align-self: flex-end; background: var(--sage-bg); color: #3E5A32; }
.bubble-meta { font-size: 10px; color: var(--text-muted); margin-top: 4px; }

.chat-column { display: flex; flex-direction: column; gap: 10px; }

.empty-state { color: var(--text-muted); font-size: 12px; padding: 20px; text-align: center; }
.error-banner { background: var(--pink-bg); color: var(--pink-text); padding: 10px 14px; border-radius: 10px; font-size: 12px; margin-bottom: 14px; }
