/* ============================================================
   TrustTrade – Global Stylesheet
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --green: #22c55e;
  --green-light: #dcfce7;
  --green-dark: #16a34a;
  --teal: #06b6d4;
  --navy: #0f172a;
  --dark: #1e293b;
  --mid: #475569;
  --muted: #94a3b8;
  --border: #e2e8f0;
  --bg: #f8fafc;
  --white: #ffffff;
  --red: #ef4444;
  --red-light: #fef2f2;
  --orange: #f97316;
  --orange-light: #fff7ed;
  --yellow: #eab308;
  --yellow-light: #fefce8;
  --purple: #8b5cf6;
  --purple-light: #f5f3ff;
  --blue: #3b82f6;
  --sidebar-w: 220px;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,.1);
}

body { font-family: 'Inter', sans-serif; background: var(--bg); color: var(--dark); font-size: 14px; line-height: 1.5; }

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

/* ── Layout ── */
.app-layout { display: flex; min-height: 100vh; }

/* ── Sidebar ── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--white);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  overflow-y: auto;
}

.sidebar-logo {
  padding: 20px 20px 16px;
  border-bottom: 1px solid var(--border);
}
.logo-link { display: flex; align-items: center; gap: 10px; }
.logo-text { font-size: 20px; font-weight: 700; letter-spacing: -.3px; }
.logo-trust { color: var(--navy); }
.logo-trade { color: var(--green); }

.sidebar-nav { flex: 1; padding: 12px 12px; display: flex; flex-direction: column; gap: 2px; }

.nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: 8px;
  font-size: 13.5px; font-weight: 500; color: var(--mid);
  transition: all .15s;
  position: relative;
}
.nav-item:hover { background: var(--bg); color: var(--dark); }
.nav-item.active { background: var(--green-light); color: var(--green-dark); font-weight: 600; }
.nav-item.active .nav-icon { color: var(--green); }

.nav-icon { width: 18px; height: 18px; flex-shrink: 0; }
.nav-divider { height: 1px; background: var(--border); margin: 6px 0; }
.nav-badge {
  margin-left: auto; background: var(--green); color: white;
  font-size: 10px; font-weight: 700; min-width: 18px; height: 18px;
  border-radius: 9px; display: flex; align-items: center; justify-content: center; padding: 0 5px;
}

.sidebar-footer { padding: 12px; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 10px; }

.upgrade-box {
  background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 10px;
  padding: 10px 12px; display: flex; gap: 10px; align-items: flex-start;
}
.upgrade-title { font-size: 12px; font-weight: 700; color: var(--dark); }
.upgrade-sub { font-size: 10.5px; color: var(--muted); line-height: 1.4; }
.upgrade-btn {
  width: 100%; background: var(--green); color: white; border: none;
  border-radius: 8px; padding: 9px 0; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: background .15s;
}
.upgrade-btn:hover { background: var(--green-dark); }

.user-profile { display: flex; align-items: center; gap: 9px; padding: 6px 4px; cursor: pointer; }
.user-avatar {
  width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg,#4ade80,#06b6d4);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; color: white; position: relative; flex-shrink: 0;
}
.user-verified {
  position: absolute; bottom: -2px; right: -2px; width: 14px; height: 14px;
  background: var(--green); border-radius: 50%; color: white; font-size: 8px;
  display: flex; align-items: center; justify-content: center; border: 1.5px solid white;
}
.user-info { flex: 1; min-width: 0; }
.user-name { font-size: 12px; font-weight: 600; color: var(--dark); display: flex; align-items: center; gap: 3px; }
.verified-icon { color: var(--green); font-size: 10px; }
.user-role { font-size: 10.5px; color: var(--muted); }

/* ── Main content ── */
.main-content { margin-left: var(--sidebar-w); flex: 1; display: flex; flex-direction: column; min-height: 100vh; }

/* ── Top bar ── */
.topbar {
  background: var(--white); border-bottom: 1px solid var(--border);
  padding: 0 28px; height: 64px; display: flex; align-items: center;
  justify-content: space-between; position: sticky; top: 0; z-index: 50;
}
.topbar-title { font-size: 20px; font-weight: 700; color: var(--navy); }
.topbar-sub { font-size: 13px; color: var(--muted); margin-top: 1px; }
.topbar-right { display: flex; align-items: center; gap: 14px; }
.topbar-icon-btn {
  width: 38px; height: 38px; border-radius: 50%; background: var(--bg);
  border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
  cursor: pointer; position: relative; color: var(--mid);
}
.topbar-badge {
  position: absolute; top: -3px; right: -3px; background: var(--green);
  color: white; font-size: 9px; font-weight: 700; min-width: 16px; height: 16px;
  border-radius: 8px; display: flex; align-items: center; justify-content: center;
  padding: 0 3px; border: 1.5px solid white;
}
.topbar-user {
  display: flex; align-items: center; gap: 8px; cursor: pointer;
  padding: 4px 10px 4px 4px; border-radius: 8px; border: 1px solid var(--border);
}
.topbar-user-name { font-size: 13px; font-weight: 600; color: var(--dark); }
.topbar-search-btn {
  width: 36px; height: 36px; border-radius: 50%; background: var(--bg);
  border: 1px solid var(--border); display: flex; align-items: center;
  justify-content: center; cursor: pointer; color: var(--mid);
}

/* ── Page body ── */
.page-body { padding: 24px 28px; flex: 1; }
.two-col { display: grid; grid-template-columns: 1fr 320px; gap: 20px; }
.three-col { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }

/* ── Card ── */
.card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.card-pad { padding: 20px; }

/* ── Hero search card (home) ── */
.hero-card {
  background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 60%, #e0f2fe 100%);
  border: 1px solid #bbf7d0; border-radius: var(--radius);
  padding: 28px 28px 24px; position: relative; overflow: hidden; margin-bottom: 20px;
}
.hero-label { font-size: 11px; font-weight: 700; color: var(--green); text-transform: uppercase; letter-spacing: .8px; margin-bottom: 6px; }
.hero-title { font-size: 28px; font-weight: 800; color: var(--navy); line-height: 1.2; margin-bottom: 8px; }
.hero-sub { font-size: 13.5px; color: var(--mid); margin-bottom: 20px; }
.hero-shield {
  position: absolute; right: 24px; top: 50%; transform: translateY(-50%);
  opacity: .15;
}
.search-row { display: flex; gap: 10px; max-width: 480px; }
.search-input {
  flex: 1; padding: 11px 16px 11px 40px; border: 1.5px solid var(--border);
  border-radius: 10px; font-size: 13.5px; color: var(--dark); background: white;
  outline: none; transition: border-color .15s;
}
.search-input:focus { border-color: var(--green); }
.search-wrap { position: relative; flex: 1; }
.search-wrap svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--muted); width: 16px; height: 16px; }
.search-btn {
  background: var(--green); color: white; border: none; border-radius: 10px;
  padding: 11px 22px; font-size: 14px; font-weight: 600; cursor: pointer;
  transition: background .15s; white-space: nowrap;
}
.search-btn:hover { background: var(--green-dark); }

.hero-features { display: flex; gap: 24px; margin-top: 20px; }
.hero-feat { display: flex; align-items: flex-start; gap: 8px; }
.hero-feat-icon { width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.hero-feat-icon.green { background: #dcfce7; color: var(--green); }
.hero-feat-icon.orange { background: #fff7ed; color: var(--orange); }
.hero-feat-icon.blue { background: #eff6ff; color: var(--blue); }
.hero-feat-title { font-size: 13px; font-weight: 700; color: var(--dark); }
.hero-feat-sub { font-size: 11.5px; color: var(--muted); }

/* ── Community feed ── */
.section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.section-title { font-size: 16px; font-weight: 700; color: var(--navy); }
.section-sub { font-size: 12px; color: var(--muted); }
.view-all { font-size: 12.5px; font-weight: 600; color: var(--green); display: flex; align-items: center; gap: 4px; }
.view-all:hover { color: var(--green-dark); }

.feed-controls { display: flex; align-items: center; gap: 8px; }
.sort-select {
  font-size: 12.5px; font-weight: 500; color: var(--dark); background: var(--bg);
  border: 1px solid var(--border); border-radius: 8px; padding: 5px 10px;
  cursor: pointer;
}
.filter-btn { width: 32px; height: 32px; background: var(--bg); border: 1px solid var(--border); border-radius: 8px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--mid); }

/* Post */
.post {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px; margin-bottom: 12px; box-shadow: var(--shadow);
}
.post-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 10px; }
.post-author { display: flex; align-items: center; gap: 10px; }
.post-avatar {
  width: 38px; height: 38px; border-radius: 50%; display: flex; align-items: center;
  justify-content: center; font-size: 12px; font-weight: 700; color: white; flex-shrink: 0;
}
.post-meta-name { font-size: 13.5px; font-weight: 700; color: var(--dark); display: flex; align-items: center; gap: 5px; }
.post-verified { color: var(--green); font-size: 12px; }
.post-meta-sub { font-size: 11.5px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.post-tag {
  font-size: 10.5px; font-weight: 600; padding: 2px 8px; border-radius: 20px;
}
.post-tag.purple { background: var(--purple-light); color: var(--purple); }
.post-tag.orange { background: var(--orange-light); color: var(--orange); }
.post-tag.green { background: var(--green-light); color: var(--green-dark); }
.post-tag.red { background: var(--red-light); color: var(--red); }
.post-actions { display: flex; gap: 6px; }
.icon-btn { width: 30px; height: 30px; border-radius: 6px; background: none; border: none; cursor: pointer; color: var(--muted); display: flex; align-items: center; justify-content: center; transition: all .15s; }
.icon-btn:hover { background: var(--bg); color: var(--dark); }
.post-title { font-size: 14px; font-weight: 700; color: var(--navy); margin-bottom: 6px; }
.post-body { font-size: 13px; color: var(--mid); line-height: 1.6; margin-bottom: 12px; }
.post-footer { display: flex; align-items: center; gap: 16px; }
.post-stat { display: flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--muted); cursor: pointer; }
.post-stat:hover { color: var(--dark); }
.post-stat svg { width: 15px; height: 15px; }

/* Community input */
.community-input-row {
  display: flex; align-items: center; gap: 10px; background: var(--white);
  border: 1.5px solid var(--border); border-radius: var(--radius); padding: 12px 16px; margin-top: 4px;
}
.community-input { flex: 1; border: none; outline: none; font-size: 13.5px; color: var(--mid); background: transparent; }
.post-btn { background: var(--green); color: white; border: none; border-radius: 8px; padding: 8px 18px; font-size: 13px; font-weight: 600; cursor: pointer; }
.pencil-icon { color: var(--muted); width: 18px; height: 18px; }

/* ── Right panel (home) ── */
.panel-section { margin-bottom: 20px; }
.worker-filters { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.filter-chip {
  padding: 5px 12px; border-radius: 20px; font-size: 12px; font-weight: 600;
  cursor: pointer; border: 1.5px solid var(--border); color: var(--mid);
  background: var(--white); transition: all .15s;
}
.filter-chip.active { background: var(--navy); color: white; border-color: var(--navy); }
.worker-card {
  display: flex; align-items: center; gap: 12px; padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.worker-card:last-child { border-bottom: none; }
.worker-icon-wrap {
  width: 42px; height: 42px; border-radius: 10px; display: flex;
  align-items: center; justify-content: center; flex-shrink: 0;
}
.worker-info { flex: 1; }
.worker-type { font-size: 13.5px; font-weight: 700; color: var(--dark); }
.worker-detail { font-size: 11.5px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.worker-dot { width: 3px; height: 3px; background: var(--muted); border-radius: 50%; }
.worker-when { font-size: 11px; font-weight: 600; }
.worker-when.this { color: var(--green); }
.worker-when.next { color: var(--blue); }
.view-btn {
  font-size: 12px; font-weight: 600; color: var(--green); border: 1.5px solid var(--green-light);
  background: var(--green-light); border-radius: 6px; padding: 5px 12px; cursor: pointer;
  transition: all .15s;
}
.view-btn:hover { background: var(--green); color: white; }

.availability-cta {
  display: flex; align-items: center; gap: 12px; padding: 14px 16px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 10px;
  margin-top: 12px; cursor: pointer;
}
.avail-icon { width: 40px; height: 40px; border-radius: 10px; background: var(--green-light); display: flex; align-items: center; justify-content: center; }
.avail-title { font-size: 13px; font-weight: 700; color: var(--dark); }
.avail-sub { font-size: 11.5px; color: var(--muted); }
.avail-arrow { margin-left: auto; color: var(--muted); }

/* ── Client Report ── */
.report-topbar {
  background: var(--white); border-bottom: 1px solid var(--border);
  padding: 0 28px; height: 64px; display: flex; align-items: center; justify-content: space-between;
}
.report-title-row { display: flex; align-items: center; gap: 10px; }
.report-main-title { font-size: 20px; font-weight: 800; color: var(--navy); }
.report-verified-icon { color: var(--green); }
.report-sub { font-size: 12px; color: var(--muted); }

.report-search-bar {
  display: flex; gap: 10px; padding: 20px 28px 0; background: var(--white); border-bottom: 1px solid var(--border); padding-bottom: 20px;
}
.report-search-input {
  flex: 1; padding: 11px 16px; border: 1.5px solid var(--border);
  border-radius: 10px; font-size: 14px; color: var(--dark); outline: none;
}
.report-search-input:focus { border-color: var(--green); }
.report-generated { font-size: 11.5px; color: var(--muted); white-space: nowrap; align-self: center; }

.report-body { display: grid; grid-template-columns: 1fr 280px; gap: 20px; padding: 20px 28px; }

.client-card { padding: 20px; }
.client-header { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 20px; }
.client-initials {
  width: 64px; height: 64px; border-radius: 50%; background: #dcfce7;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 800; color: #16a34a; flex-shrink: 0;
}
.client-name-row { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.client-name { font-size: 22px; font-weight: 800; color: var(--navy); }
.risk-badge {
  font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 20px;
}
.risk-badge.high { background: var(--red-light); color: var(--red); border: 1px solid #fecaca; }
.risk-badge.medium { background: var(--yellow-light); color: #a16207; }
.risk-badge.low { background: var(--green-light); color: var(--green-dark); }
.client-detail { font-size: 12.5px; color: var(--mid); display: flex; align-items: center; gap: 6px; margin-bottom: 3px; }
.client-detail svg { width: 13px; height: 13px; color: var(--muted); flex-shrink: 0; }

.trust-score-box { text-align: center; }
.trust-score-label { font-size: 12px; color: var(--muted); font-weight: 500; margin-bottom: 4px; display: flex; align-items: center; justify-content: center; gap: 4px; }
.trust-score-num { font-size: 44px; font-weight: 900; color: var(--red); line-height: 1; }
.trust-score-denom { font-size: 18px; color: var(--muted); font-weight: 400; }

/* Gauge */
.gauge-wrap { position: relative; width: 160px; margin: 8px auto; }
.gauge-svg { width: 100%; }
.gauge-label { position: absolute; bottom: 0; left: 0; right: 0; text-align: center; }
.gauge-risk-chip {
  display: inline-block; font-size: 11px; font-weight: 700;
  padding: 3px 12px; border-radius: 20px; margin-top: 6px;
}
.gauge-risk-chip.high { background: var(--red-light); color: var(--red); border: 1px solid #fecaca; }

.stats-row { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; margin-bottom: 20px; }
.stat-box { padding: 14px 16px; border: 1px solid var(--border); border-radius: 10px; background: white; }
.stat-num { font-size: 22px; font-weight: 800; color: var(--navy); }
.stat-sub { font-size: 11px; color: var(--muted); margin-top: 2px; }
.stat-icon { width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; margin-bottom: 6px; }
.stat-icon.red { background: var(--red-light); color: var(--red); }
.stat-icon.orange { background: var(--orange-light); color: var(--orange); }
.stat-icon.purple { background: var(--purple-light); color: var(--purple); }
.stat-icon.teal { background: #ecfeff; color: var(--teal); }

/* Tabs */
.tabs { display: flex; gap: 0; border-bottom: 2px solid var(--border); margin-bottom: 18px; }
.tab-btn {
  padding: 10px 18px; font-size: 13.5px; font-weight: 500; color: var(--muted);
  border: none; background: none; cursor: pointer; border-bottom: 2.5px solid transparent;
  margin-bottom: -2px; transition: all .15s;
}
.tab-btn.active { color: var(--green); border-bottom-color: var(--green); font-weight: 700; }
.tab-btn:hover:not(.active) { color: var(--dark); }

/* Charts section */
.charts-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; margin-bottom: 20px; }
.chart-box { border: 1px solid var(--border); border-radius: 10px; padding: 16px; background: var(--white); }
.chart-title { font-size: 13px; font-weight: 700; color: var(--dark); margin-bottom: 12px; }

/* Donut chart */
.donut-wrap { display: flex; align-items: center; gap: 16px; }
.donut-svg { flex-shrink: 0; }
.donut-legend { font-size: 11.5px; display: flex; flex-direction: column; gap: 5px; }
.legend-item { display: flex; align-items: center; gap: 6px; }
.legend-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.legend-count { font-weight: 700; color: var(--dark); }
.legend-label { color: var(--muted); }

/* Rating distribution bars */
.rating-row { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; }
.rating-star-label { font-size: 11.5px; color: var(--mid); width: 38px; flex-shrink: 0; display: flex; align-items: center; gap: 3px; }
.rating-bar-bg { flex: 1; height: 7px; background: var(--bg); border-radius: 4px; overflow: hidden; }
.rating-bar-fill { height: 100%; border-radius: 4px; }
.rating-bar-fill.star5 { background: var(--green); }
.rating-bar-fill.star4 { background: #86efac; }
.rating-bar-fill.star3 { background: var(--yellow); }
.rating-bar-fill.star2 { background: var(--orange); }
.rating-bar-fill.star1 { background: var(--red); }
.rating-count { font-size: 11.5px; color: var(--muted); width: 26px; text-align: right; }

/* Dispute donut */
.dispute-center { text-align: center; position: relative; }
.dispute-pct { font-size: 26px; font-weight: 800; color: var(--navy); }
.dispute-sub { font-size: 10.5px; color: var(--muted); line-height: 1.4; max-width: 120px; margin: 0 auto; }

/* Social profiles */
.social-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; }
.social-item { border: 1px solid var(--border); border-radius: 10px; padding: 14px 12px; text-align: center; }
.social-icon { width: 38px; height: 38px; border-radius: 10px; display: flex; align-items: center; justify-content: center; margin: 0 auto 6px; font-weight: 800; font-size: 15px; color: white; }
.social-name { font-size: 12px; font-weight: 700; color: var(--dark); }
.social-status { font-size: 10.5px; color: var(--muted); margin-top: 2px; }
.social-check { color: var(--green); font-size: 11px; }
.social-dash { color: var(--muted); }

/* Public records */
.records-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.record-item { border: 1px solid var(--border); border-radius: 10px; padding: 14px; display: flex; align-items: flex-start; gap: 10px; }
.record-icon-wrap { width: 34px; height: 34px; border-radius: 8px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.record-icon-wrap.green { background: var(--green-light); color: var(--green); }
.record-icon-wrap.yellow { background: var(--yellow-light); color: var(--yellow); }
.record-name { font-size: 12.5px; font-weight: 700; color: var(--dark); }
.record-detail { font-size: 11px; color: var(--muted); margin-top: 2px; }

/* Recent reviews */
.reviews-row { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; }
.review-card { border: 1px solid var(--border); border-radius: 10px; padding: 14px; }
.review-platform-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.review-platform { font-size: 12px; font-weight: 700; }
.review-date { font-size: 10.5px; color: var(--muted); }
.review-stars { color: var(--yellow); font-size: 13px; margin-bottom: 6px; }
.review-text { font-size: 12px; color: var(--mid); line-height: 1.5; }
.disputed-chip {
  display: inline-block; margin-top: 8px; font-size: 10px; font-weight: 700;
  padding: 2px 8px; border-radius: 20px; background: var(--red-light); color: var(--red);
}

/* Right panel - client report */
.ai-card { border: 1px solid var(--border); border-radius: 10px; padding: 16px; margin-bottom: 14px; }
.ai-title-row { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.ai-label { font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .6px; }
.ai-diamond { color: #f59e0b; font-size: 14px; }
.ai-conclusion { font-size: 18px; font-weight: 800; color: var(--red); margin-bottom: 8px; }
.ai-text { font-size: 12.5px; color: var(--mid); line-height: 1.6; }

.rec-box { background: var(--red-light); border: 1px solid #fecaca; border-radius: 10px; padding: 14px; margin-bottom: 14px; }
.rec-title { font-size: 12px; font-weight: 700; color: var(--red); margin-bottom: 4px; display: flex; align-items: center; gap: 5px; }
.rec-text { font-size: 12px; color: var(--mid); line-height: 1.5; }

.flags-card { border: 1px solid var(--border); border-radius: 10px; padding: 16px; margin-bottom: 14px; }
.flags-title { font-size: 13px; font-weight: 700; color: var(--dark); margin-bottom: 10px; }
.flag-item { display: flex; align-items: flex-start; gap: 7px; font-size: 12px; color: var(--mid); margin-bottom: 7px; }
.flag-item::before { content: '✕'; color: var(--red); font-size: 10px; font-weight: 700; margin-top: 1px; flex-shrink: 0; }

.activity-card { border: 1px solid var(--border); border-radius: 10px; padding: 16px; background: white; }
.activity-title { font-size: 13px; font-weight: 700; color: var(--dark); margin-bottom: 10px; }
.activity-row { display: flex; align-items: center; justify-content: space-between; padding: 5px 0; border-bottom: 1px solid var(--border); }
.activity-row:last-child { border-bottom: none; }
.activity-label { font-size: 12px; color: var(--mid); display: flex; align-items: center; gap: 6px; }
.activity-val { font-size: 13px; font-weight: 700; color: var(--dark); }
.activity-val.red { color: var(--red); }
.activity-val.orange { color: var(--orange); }

/* ── My Company ── */
.company-hero { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; margin-bottom: 20px; }
.company-hero-inner { display: flex; gap: 20px; padding: 24px; align-items: flex-start; position: relative; }
.company-cover { position: absolute; right: 0; top: 0; bottom: 0; width: 280px; }
.company-cover img { width: 100%; height: 100%; object-fit: cover; }
.company-logo { width: 80px; height: 80px; border-radius: 16px; background: var(--navy); display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 900; color: white; flex-shrink: 0; position: relative; border: 3px solid var(--white); box-shadow: 0 4px 12px rgba(0,0,0,.15); }
.company-logo-badge { position: absolute; bottom: -4px; right: -4px; width: 20px; height: 20px; background: var(--green); border-radius: 50%; display: flex; align-items: center; justify-content: center; border: 2px solid white; }
.company-details { flex: 1; }
.company-name-row { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.company-name { font-size: 24px; font-weight: 800; color: var(--navy); }
.company-verified-chip { background: var(--green-light); color: var(--green-dark); font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 20px; border: 1px solid #86efac; display: flex; align-items: center; gap: 4px; }
.company-tagline { font-size: 13.5px; color: var(--mid); margin-bottom: 10px; }
.company-meta { display: flex; gap: 18px; flex-wrap: wrap; }
.company-meta-item { font-size: 12.5px; color: var(--mid); display: flex; align-items: center; gap: 5px; }
.edit-profile-btn { position: absolute; top: 20px; right: 24px; background: white; border: 1.5px solid var(--border); border-radius: 8px; padding: 7px 14px; font-size: 13px; font-weight: 600; color: var(--dark); cursor: pointer; display: flex; align-items: center; gap: 6px; }

.trust-overview { display: grid; grid-template-columns: auto 1fr 1fr 1fr 1fr; gap: 20px; align-items: center; padding: 20px; background: var(--bg); border-top: 1px solid var(--border); }
.trust-score-big { text-align: center; padding-right: 20px; border-right: 1px solid var(--border); }
.trust-score-big-num { font-size: 48px; font-weight: 900; color: var(--green-dark); line-height: 1; }
.trust-score-big-denom { font-size: 20px; color: var(--muted); font-weight: 400; }
.trust-score-big-label { font-size: 11.5px; font-weight: 700; color: var(--green-dark); margin-top: 4px; background: var(--green-light); display: inline-block; padding: 2px 10px; border-radius: 20px; }

.metric-box { text-align: center; }
.metric-num { font-size: 26px; font-weight: 800; color: var(--navy); }
.metric-label { font-size: 11px; color: var(--muted); margin-top: 2px; }
.metric-stars { color: var(--yellow); font-size: 16px; }
.metric-sub { font-size: 11px; color: var(--muted); }

.platform-grid { display: grid; grid-template-columns: repeat(5,1fr); gap: 14px; margin-bottom: 20px; }
.platform-card { border: 1px solid var(--border); border-radius: 10px; padding: 14px; }
.platform-name { font-size: 12px; font-weight: 700; color: var(--dark); margin-bottom: 4px; }
.platform-rating { font-size: 22px; font-weight: 800; color: var(--navy); }
.platform-denom { font-size: 13px; color: var(--muted); font-weight: 400; }
.platform-stars { color: var(--yellow); font-size: 14px; margin: 4px 0; }
.platform-reviews { font-size: 11px; color: var(--muted); }
.platform-trend { margin-top: 8px; }

/* Simple mini sparkline */
.sparkline { height: 32px; }

/* Jobs table */
.jobs-table { width: 100%; border-collapse: collapse; }
.jobs-table th { font-size: 11.5px; font-weight: 600; color: var(--muted); text-align: left; padding: 8px 12px; border-bottom: 1px solid var(--border); }
.jobs-table td { font-size: 13px; color: var(--dark); padding: 11px 12px; border-bottom: 1px solid var(--border); }
.jobs-table tr:last-child td { border-bottom: none; }
.client-initials-sm { width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; color: white; }
.status-chip { font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 20px; }
.status-chip.completed { background: var(--green-light); color: var(--green-dark); }
.status-chip.pending { background: var(--yellow-light); color: #a16207; }
.rating-num { font-weight: 700; color: var(--dark); font-size: 13px; }

/* Right panel - company */
.avail-panel-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.new-avail-btn { background: var(--green); color: white; border: none; border-radius: 8px; padding: 7px 12px; font-size: 12.5px; font-weight: 600; cursor: pointer; display: flex; align-items: center; gap: 5px; }
.avail-worker-card { border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; margin-bottom: 10px; display: flex; align-items: center; gap: 12px; cursor: pointer; transition: box-shadow .15s; }
.avail-worker-card:hover { box-shadow: var(--shadow-md); }
.avail-when-chip { font-size: 10.5px; font-weight: 700; padding: 3px 9px; border-radius: 20px; margin-left: auto; }
.avail-when-chip.this { background: #dcfce7; color: var(--green-dark); }
.avail-when-chip.next { background: #dbeafe; color: #1d4ed8; }
.avail-when-chip.custom { background: var(--orange-light); color: var(--orange); }
.avail-arrow-btn { width: 28px; height: 28px; border-radius: 50%; background: var(--bg); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; color: var(--muted); }

.activity-feed-item { display: flex; align-items: flex-start; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.activity-feed-item:last-child { border-bottom: none; }
.activity-icon-wrap { width: 34px; height: 34px; border-radius: 50%; background: var(--green-light); display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--green); }
.activity-feed-text { font-size: 12.5px; color: var(--dark); line-height: 1.5; }
.activity-feed-time { font-size: 11px; color: var(--muted); margin-top: 2px; }
.activity-feed-link { font-size: 12px; font-weight: 600; color: var(--green); margin-left: 6px; }

/* ── Misc pages ── */
.placeholder-page { display: flex; flex-direction: column; align-items: center; justify-content: center; flex: 1; padding: 60px 20px; text-align: center; color: var(--muted); }
.placeholder-page h2 { font-size: 22px; font-weight: 700; color: var(--dark); margin-bottom: 8px; }
.placeholder-page p { font-size: 14px; }

/* ── Save report btn ── */
.save-report-btn {
  background: white; border: 1.5px solid var(--border); border-radius: 8px;
  padding: 8px 16px; font-size: 13px; font-weight: 600; color: var(--dark);
  cursor: pointer; display: flex; align-items: center; gap: 6px;
}

/* ── Responsive tweaks ── */
@media (max-width: 1100px) {
  .two-col { grid-template-columns: 1fr; }
  .charts-grid { grid-template-columns: 1fr 1fr; }
  .platform-grid { grid-template-columns: repeat(3,1fr); }
  .trust-overview { grid-template-columns: 1fr 1fr; }
}

/* ── Find Workers page ── */
.workers-page-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px,1fr)); gap: 16px; }
.worker-full-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.worker-full-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.worker-full-icon { width: 50px; height: 50px; border-radius: 12px; display: flex; align-items: center; justify-content: center; }

/* ── Messages page ── */
.messages-layout { display: grid; grid-template-columns: 320px 1fr; gap: 0; height: calc(100vh - 64px); }
.message-list { border-right: 1px solid var(--border); overflow-y: auto; }
.message-item { padding: 16px 20px; border-bottom: 1px solid var(--border); cursor: pointer; transition: background .15s; }
.message-item:hover, .message-item.active { background: var(--bg); }
.message-item-name { font-size: 13.5px; font-weight: 700; color: var(--dark); }
.message-item-preview { font-size: 12px; color: var(--muted); }

/* Utility */
.flex { display: flex; }
.flex-center { display: flex; align-items: center; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.mt-4 { margin-top: 16px; }
.mb-3 { margin-bottom: 12px; }
.mb-4 { margin-bottom: 16px; }
.font-bold { font-weight: 700; }
.text-muted { color: var(--muted); }
.text-green { color: var(--green); }
.text-red { color: var(--red); }
.text-dark { color: var(--dark); }
.text-sm { font-size: 12px; }
.w-full { width: 100%; }
