/* ================================================================
   VIP OFFICE — Design System Base
   Baseado no layout v4 (SaaS Bento Grid) · Inter · v2 palette
   ================================================================ */

/* ── GOOGLE FONTS ── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ── DESIGN TOKENS ── */
:root {
  --bg: #F8FAFC;
  --surface: #FFFFFF;
  --surface-2: #F1F5F9;
  --border: #E2E8F0;
  --border-strong: #CBD5E1;
  --accent: #2563EB;
  --accent-hover: #1D4ED8;
  --accent-light: #EFF6FF;
  --accent-mid: #BFDBFE;
  --green: #10B981;
  --green-light: #ECFDF5;
  --amber: #F59E0B;
  --amber-light: #FFFBEB;
  --red: #EF4444;
  --red-light: #FEF2F2;
  --purple: #7C3AED;
  --purple-light: #F5F3FF;
  --navy: #0F172A;
  --navy-mid: #1E293B;
  --text-primary: #0F172A;
  --text-secondary: #475569;
  --text-muted: #94A3B8;
  --sidebar-w: 224px;
  --header-h: 64px;
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 14px;
  --r-xl: 20px;
}

/* ── RESET ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
body { background: var(--bg); color: var(--text-primary); font-family: 'Inter', -apple-system, sans-serif; font-size: 15px; line-height: 1.6; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }
img { display: block; max-width: 100%; }
ul { list-style: none; }

/* ── TYPOGRAPHY ── */
.t-tag { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); margin-bottom: 8px; }
.t-h1 { font-size: 36px; font-weight: 800; letter-spacing: -0.025em; line-height: 1.1; }
.t-h2 { font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.t-h3 { font-size: 18px; font-weight: 700; }
.t-page-title { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.t-muted { color: var(--text-muted); }
.t-secondary { color: var(--text-secondary); }
.t-accent { color: var(--accent); }
.t-green { color: var(--green); }
.t-red { color: var(--red); }
.t-amber { color: var(--amber); }

/* ── STATUS BADGES ── */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 10px; border-radius: 20px;
  font-size: 11px; font-weight: 700; letter-spacing: 0.04em;
  white-space: nowrap;
}
.badge::before { content: ''; width: 5px; height: 5px; border-radius: 50%; flex-shrink: 0; }
.b-pending       { background: var(--amber-light); color: var(--amber); }  .b-pending::before { background: var(--amber); }
.b-confirmed     { background: var(--green-light); color: var(--green); }  .b-confirmed::before { background: var(--green); }
.b-canceled      { background: var(--red-light); color: var(--red); }      .b-canceled::before { background: var(--red); }
.b-paid          { background: var(--green-light); color: var(--green); }  .b-paid::before { background: var(--green); }
.b-failed        { background: var(--red-light); color: var(--red); }      .b-failed::before { background: var(--red); }
.b-review        { background: var(--accent-light); color: var(--accent); }.b-review::before { background: var(--accent); }
.b-counter       { background: var(--purple-light); color: var(--purple); }.b-counter::before { background: var(--purple); }
.b-accepted      { background: var(--green-light); color: var(--green); }  .b-accepted::before { background: var(--green); }
.b-rejected      { background: var(--red-light); color: var(--red); }      .b-rejected::before { background: var(--red); }
.b-active        { background: var(--green-light); color: var(--green); }  .b-active::before { background: var(--green); }
.b-inactive      { background: var(--border); color: var(--text-muted); }  .b-inactive::before { background: var(--text-muted); }
.b-sent          { background: var(--accent-light); color: var(--accent); }.b-sent::before { background: var(--accent); }
.b-direct        { background: #F0FDF4; color: #15803D; }                  .b-direct::before { background: #15803D; }
.b-guided        { background: var(--purple-light); color: var(--purple); }.b-guided::before { background: var(--purple); }
.b-negotiated    { background: var(--amber-light); color: var(--amber); }  .b-negotiated::before { background: var(--amber); }

/* ── BUTTONS ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 18px; border-radius: var(--r-sm); border: none;
  font-size: 14px; font-weight: 600; cursor: pointer; transition: all 0.15s;
  white-space: nowrap;
}
.btn-primary  { background: var(--accent); color: white; }
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); }
.btn-ghost    { background: transparent; border: 1.5px solid var(--border); color: var(--text-secondary); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn-danger   { background: var(--red); color: white; }
.btn-danger:hover { background: #DC2626; }
.btn-success  { background: var(--green); color: white; }
.btn-success:hover { background: #059669; }
.btn-text     { background: transparent; color: var(--accent); padding: 9px 0; }
.btn-text:hover { text-decoration: underline; }
.btn-sm       { padding: 6px 13px; font-size: 13px; }
.btn-lg       { padding: 12px 24px; font-size: 15px; }
.btn-icon     { padding: 8px; width: 36px; height: 36px; }

/* ── PUBLIC NAVIGATION ── */
.pub-nav {
  background: rgba(255,255,255,0.97); border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 40px; height: var(--header-h);
  position: sticky; top: 0; z-index: 100; backdrop-filter: blur(8px);
}
.pub-nav-brand { display: flex; align-items: center; gap: 10px; }
.pub-nav-brand img { height: 44px; border-radius: 4px; }
.pub-nav-brand-sub { font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); }
.pub-nav-links { display: flex; gap: 2px; }
.pub-nav-link { padding: 7px 12px; font-size: 13px; font-weight: 500; color: var(--text-secondary); border-radius: var(--r-sm); transition: all 0.15s; }
.pub-nav-link:hover { background: var(--bg); color: var(--text-primary); }
.pub-nav-link.on { color: var(--accent); font-weight: 600; }
.pub-nav-right { display: flex; align-items: center; gap: 8px; }

/* Language switcher */
.lang-sw { display: flex; gap: 2px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 3px; }
.lang-btn { padding: 3px 8px; border-radius: 4px; font-size: 11px; font-weight: 700; color: var(--text-muted); cursor: pointer; border: none; background: transparent; transition: all 0.15s; }
.lang-btn.on { background: var(--accent); color: white; }

/* ── APP LAYOUT (sidebar + main) ── */
.app { display: flex; min-height: 100vh; }

/* Sidebar */
.sidebar {
  width: var(--sidebar-w); background: var(--surface); border-right: 1px solid var(--border);
  position: fixed; top: 0; left: 0; bottom: 0;
  display: flex; flex-direction: column; z-index: 50; overflow-y: auto;
}
.sb-logo { padding: 14px 18px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 8px; text-decoration: none; }
.sb-logo img { height: 38px; border-radius: 4px; }
.sb-logo-sub { font-size: 9px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); margin-top: 1px; }

.sb-section { padding: 16px 10px 4px; }
.sb-section-lbl { font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); padding: 0 8px; margin-bottom: 6px; }
.sb-link {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--r-sm);
  font-size: 13px; font-weight: 500; color: var(--text-secondary); margin-bottom: 1px;
  transition: all 0.15s; cursor: pointer;
}
.sb-link:hover { background: var(--bg); color: var(--text-primary); }
.sb-link.on { background: var(--accent-light); color: var(--accent); font-weight: 600; }
.sb-icon { font-size: 15px; width: 20px; text-align: center; flex-shrink: 0; }
.sb-badge { margin-left: auto; background: var(--red); color: white; font-size: 10px; font-weight: 700; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; display: flex; align-items: center; justify-content: center; }

.sb-footer { margin-top: auto; padding: 14px 16px; border-top: 1px solid var(--border); }
.sb-user { display: flex; align-items: center; gap: 10px; }
.sb-avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--accent); color: white; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; flex-shrink: 0; }
.sb-user-name { font-size: 13px; font-weight: 600; line-height: 1.2; }
.sb-user-role { font-size: 11px; color: var(--text-muted); }

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

/* App header */
.app-hdr {
  background: var(--surface); border-bottom: 1px solid var(--border);
  height: var(--header-h); padding: 0 28px;
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 40;
}
.app-hdr-left { display: flex; align-items: center; gap: 14px; }
.app-hdr-title { font-size: 15px; font-weight: 700; }
.app-hdr-bread { font-size: 13px; color: var(--text-muted); display: flex; align-items: center; gap: 5px; }
.app-hdr-bread a { color: var(--text-muted); }
.app-hdr-bread a:hover { color: var(--text-primary); }
.app-hdr-right { display: flex; align-items: center; gap: 10px; }

.co-sel {
  display: flex; align-items: center; gap: 7px; padding: 6px 12px;
  border: 1.5px solid var(--border); border-radius: var(--r-sm);
  font-size: 13px; font-weight: 500; cursor: pointer; background: var(--surface);
  transition: border-color 0.15s;
}
.co-sel:hover { border-color: var(--accent-mid); }
.co-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); flex-shrink: 0; }
.co-arrow { color: var(--text-muted); font-size: 10px; }

.notif-btn {
  position: relative; width: 36px; height: 36px; border: 1.5px solid var(--border);
  border-radius: var(--r-sm); display: flex; align-items: center; justify-content: center;
  font-size: 17px; cursor: pointer; color: var(--text-secondary); background: var(--surface);
  transition: border-color 0.15s;
}
.notif-btn:hover { border-color: var(--accent-mid); }
.notif-dot { position: absolute; top: -3px; right: -3px; width: 16px; height: 16px; background: var(--red); color: white; font-size: 9px; font-weight: 700; border-radius: 50%; display: flex; align-items: center; justify-content: center; border: 2px solid var(--surface); }

/* Page content */
.page { padding: 28px 32px; flex: 1; }
.page-hdr { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 24px; }
.page-hdr-left .page-title { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.page-hdr-left .page-sub { font-size: 13px; color: var(--text-secondary); margin-top: 3px; }
.page-hdr-actions { display: flex; gap: 8px; align-items: center; flex-shrink: 0; }

/* ── KPI CARDS ── */
.kpi-row { display: grid; gap: 14px; margin-bottom: 24px; }
.kpi-4 { grid-template-columns: repeat(4, 1fr); }
.kpi-3 { grid-template-columns: repeat(3, 1fr); }
.kpi-card {
  background: var(--surface); border: 1.5px solid var(--border);
  border-radius: var(--r-lg); padding: 20px 22px;
}
.kpi-icon { font-size: 24px; margin-bottom: 10px; }
.kpi-val { font-size: 28px; font-weight: 800; letter-spacing: -0.025em; line-height: 1; margin-bottom: 4px; }
.kpi-lbl { font-size: 13px; color: var(--text-secondary); }
.kpi-delta { font-size: 12px; font-weight: 600; margin-top: 6px; display: flex; align-items: center; gap: 3px; }
.kpi-up { color: var(--green); }
.kpi-down { color: var(--red); }

/* ── CARDS ── */
.card { background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--r-lg); overflow: hidden; }
.card-hdr { padding: 16px 20px; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; }
.card-hdr-title { font-size: 15px; font-weight: 700; }
.card-hdr-action { font-size: 13px; font-weight: 600; color: var(--accent); cursor: pointer; }
.card-hdr-action:hover { text-decoration: underline; }
.card-body { padding: 20px; }
.card-foot { padding: 14px 20px; border-top: 1px solid var(--border); background: var(--bg); }

/* Item card (space/service) */
.item-card {
  background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--r-md);
  overflow: hidden; cursor: pointer; transition: all 0.2s;
}
.item-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.08); border-color: var(--accent-mid); }
.item-thumb { height: 150px; display: flex; align-items: center; justify-content: center; font-size: 44px; background: var(--bg); }
.item-body { padding: 16px; }
.item-type { font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 4px; }
.item-name { font-size: 15px; font-weight: 700; margin-bottom: 2px; }
.item-sub { font-size: 12px; color: var(--text-muted); margin-bottom: 12px; }
.item-foot { display: flex; align-items: center; justify-content: space-between; }
.item-price { font-size: 15px; font-weight: 700; color: var(--accent); }
.item-price span { font-size: 11px; font-weight: 400; color: var(--text-muted); }

/* ── TABLES ── */
.tbl-wrap { overflow-x: auto; border-radius: var(--r-md); border: 1.5px solid var(--border); }
table { width: 100%; border-collapse: collapse; }
thead th {
  padding: 11px 16px; text-align: left; background: var(--bg);
  font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-muted); border-bottom: 1px solid var(--border); white-space: nowrap;
}
tbody td { padding: 13px 16px; font-size: 14px; border-bottom: 1px solid var(--border); }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: var(--bg); }
.td-name { font-weight: 600; color: var(--text-primary); }
.td-sub { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.td-actions { display: flex; gap: 6px; }

/* ── FORMS ── */
.form-group { margin-bottom: 16px; }
.form-lbl { display: block; font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-secondary); margin-bottom: 6px; }
.form-input {
  width: 100%; padding: 10px 14px; border: 1.5px solid var(--border);
  border-radius: var(--r-sm); font-size: 14px; color: var(--text-primary);
  background: var(--surface); outline: none; transition: border-color 0.15s;
}
.form-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-light); }
.form-input::placeholder { color: var(--text-muted); }
.form-select {
  width: 100%; padding: 10px 32px 10px 14px; border: 1.5px solid var(--border);
  border-radius: var(--r-sm); font-size: 14px; color: var(--text-primary);
  background: var(--surface); outline: none; cursor: pointer; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'%3E%3Cpath fill='%2394A3B8' d='M5 7L0.67 2h8.66z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
  transition: border-color 0.15s;
}
.form-select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-light); }
.form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }
.form-hint { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.form-error { font-size: 12px; color: var(--red); margin-top: 4px; }

/* ── FILTER BAR ── */
.filter-bar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 20px; }
.filter-search-wrap { display: flex; flex: 1; min-width: 200px; max-width: 340px; }
.filter-search-wrap input { flex: 1; padding: 8px 12px; border: 1.5px solid var(--border); border-right: none; border-radius: var(--r-sm) 0 0 var(--r-sm); font-size: 14px; outline: none; }
.filter-search-wrap input:focus { border-color: var(--accent); }
.filter-search-btn { padding: 8px 14px; background: var(--accent); color: white; border: none; border-radius: 0 var(--r-sm) var(--r-sm) 0; cursor: pointer; font-size: 14px; }
.filter-select { padding: 8px 28px 8px 12px; border: 1.5px solid var(--border); border-radius: var(--r-sm); font-size: 13px; font-weight: 500; outline: none; cursor: pointer; appearance: none; background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'%3E%3Cpath fill='%2394A3B8' d='M5 7L0.67 2h8.66z'/%3E%3C/svg%3E") no-repeat right 10px center; }
.filter-tag { display: flex; align-items: center; gap: 5px; padding: 6px 12px; border-radius: 20px; font-size: 12px; font-weight: 600; cursor: pointer; border: 1.5px solid var(--border); color: var(--text-secondary); background: var(--surface); white-space: nowrap; }
.filter-tag.on { background: var(--accent-light); border-color: var(--accent-mid); color: var(--accent); }

/* ── TIMELINE ── */
.timeline { display: flex; flex-direction: column; }
.tl-item { display: flex; gap: 14px; padding-bottom: 22px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-left { display: flex; flex-direction: column; align-items: center; width: 36px; flex-shrink: 0; }
.tl-icon-wrap { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 15px; flex-shrink: 0; border: 2px solid var(--border); background: var(--surface); }
.tl-line { width: 2px; flex: 1; background: var(--border); margin-top: 4px; }
.tl-item:last-child .tl-line { display: none; }
.tl-content { flex: 1; padding-top: 6px; }
.tl-event { font-size: 14px; font-weight: 600; margin-bottom: 2px; }
.tl-desc { font-size: 13px; color: var(--text-secondary); line-height: 1.5; }
.tl-time { font-size: 12px; color: var(--text-muted); margin-top: 5px; }
/* Timeline color variants */
.tl-g .tl-icon-wrap { background: var(--green-light); border-color: var(--green); }
.tl-b .tl-icon-wrap { background: var(--accent-light); border-color: var(--accent); }
.tl-a .tl-icon-wrap { background: var(--amber-light); border-color: var(--amber); }
.tl-r .tl-icon-wrap { background: var(--red-light); border-color: var(--red); }
.tl-p .tl-icon-wrap { background: var(--purple-light); border-color: var(--purple); }

/* ── PROPOSAL PIPELINE ── */
.pipeline { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.pipe-col { background: var(--bg); border: 1.5px solid var(--border); border-radius: var(--r-md); padding: 12px; min-height: 300px; }
.pipe-col-hdr { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 12px; display: flex; align-items: center; justify-content: space-between; }
.pipe-col-hdr .pipe-count { background: var(--surface); border: 1px solid var(--border); color: var(--text-secondary); font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 10px; }
.pipe-card { background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--r-sm); padding: 12px; margin-bottom: 8px; cursor: pointer; transition: border-color 0.15s; }
.pipe-card:hover { border-color: var(--accent-mid); }
.pipe-card-title { font-size: 13px; font-weight: 600; margin-bottom: 4px; }
.pipe-card-val { font-size: 14px; font-weight: 700; color: var(--accent); margin-bottom: 6px; }
.pipe-card-sub { font-size: 11px; color: var(--text-muted); }

/* ── MODAL ── */
.modal-bg { position: fixed; inset: 0; background: rgba(15,23,42,0.5); z-index: 200; display: flex; align-items: center; justify-content: center; backdrop-filter: blur(4px); }
.modal { background: var(--surface); border-radius: var(--r-xl); padding: 32px; max-width: 480px; width: 90%; box-shadow: 0 20px 60px rgba(0,0,0,0.2); }
.modal-title { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.modal-body { font-size: 14px; color: var(--text-secondary); line-height: 1.65; margin-bottom: 24px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; }

/* ── EMPTY STATE ── */
.empty { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 64px 24px; text-align: center; }
.empty-icon { font-size: 52px; margin-bottom: 16px; opacity: 0.6; }
.empty-title { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.empty-sub { font-size: 14px; color: var(--text-secondary); max-width: 300px; margin-bottom: 24px; line-height: 1.6; }

/* ── SKELETON ── */
.sk { background: linear-gradient(90deg,#E2E8F0 25%,#F1F5F9 50%,#E2E8F0 75%); background-size: 400% 100%; animation: shimmer 1.5s infinite; border-radius: 4px; }
@keyframes shimmer { 0%{background-position:100% 0} 100%{background-position:-100% 0} }
.sk-ln { height: 14px; margin-bottom: 8px; border-radius: 3px; }
.sk-title { height: 22px; width: 55%; margin-bottom: 12px; border-radius: 3px; }
.sk-card { border-radius: var(--r-md); }

/* ── TABS ── */
.tabs { display: flex; border-bottom: 1px solid var(--border); margin-bottom: 22px; gap: 0; }
.tab-btn { padding: 10px 16px; font-size: 14px; font-weight: 500; color: var(--text-muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; transition: all 0.15s; background: transparent; border-top: none; border-left: none; border-right: none; }
.tab-btn:hover { color: var(--text-primary); }
.tab-btn.on { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }

/* ── BREADCRUMB ── */
.bread { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-muted); margin-bottom: 16px; }
.bread a { color: var(--text-muted); }
.bread a:hover { color: var(--text-primary); }
.bread-sep { color: var(--border-strong); }

/* ── PAGINATION ── */
.pag { display: flex; align-items: center; gap: 4px; padding-top: 16px; justify-content: center; }
.pag-btn { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border-radius: var(--r-sm); font-size: 13px; font-weight: 500; cursor: pointer; border: 1.5px solid transparent; color: var(--text-secondary); background: transparent; }
.pag-btn:hover { background: var(--bg); border-color: var(--border); }
.pag-btn.on { background: var(--accent); color: white; border-color: var(--accent); }

/* ── NOTIFICATION ITEM ── */
.notif-item { display: flex; align-items: flex-start; gap: 14px; padding: 16px; border-bottom: 1px solid var(--border); cursor: pointer; transition: background 0.15s; position: relative; }
.notif-item:last-child { border-bottom: none; }
.notif-item:hover { background: var(--bg); }
.notif-item.unread { background: var(--accent-light); }
.notif-item.unread::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--accent); border-radius: 0 2px 2px 0; }
.notif-icon-wrap { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.notif-content { flex: 1; min-width: 0; }
.notif-title { font-size: 14px; font-weight: 600; margin-bottom: 3px; }
.notif-sub { font-size: 13px; color: var(--text-secondary); line-height: 1.4; }
.notif-time { font-size: 12px; color: var(--text-muted); margin-top: 5px; }

/* ── MISC UTILITIES ── */
.gap-8  { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-24 { gap: 24px; }
.mb-8   { margin-bottom: 8px; }
.mb-16  { margin-bottom: 16px; }
.mb-24  { margin-bottom: 24px; }
.mb-32  { margin-bottom: 32px; }
.mt-16  { margin-top: 16px; }
.flex   { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-center  { display: flex; align-items: center; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.w-full { width: 100%; }
.divider { height: 1px; background: var(--border); }

/* Avatar */
.ava { width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: white; flex-shrink: 0; }
.ava-b { background: var(--accent); }
.ava-g { background: var(--green); }
.ava-p { background: var(--purple); }
.ava-a { background: var(--amber); }

/* Public footer */
.pub-footer { background: var(--surface); border-top: 1px solid var(--border); padding: 32px 40px; display: flex; align-items: center; justify-content: space-between; }
.pub-footer img { height: 30px; border-radius: 4px; }
.pub-footer-copy { font-size: 12px; color: var(--text-muted); }
.pub-footer-links { display: flex; gap: 20px; }
.pub-footer-links a { font-size: 13px; color: var(--text-muted); }
.pub-footer-links a:hover { color: var(--text-primary); }

/* ── STATUS BADGE ALIASES (full semantic names) ── */
.b-under-review   { background: var(--accent-light); color: var(--accent); }  .b-under-review::before   { background: var(--accent); }
.b-counter-offer  { background: var(--purple-light); color: var(--purple); }  .b-counter-offer::before  { background: var(--purple); }
.b-negotiated-alt { background: var(--amber-light); color: var(--amber); }    .b-negotiated-alt::before { background: var(--amber); }
/* keep b-review & b-counter as aliases */
.b-review  { background: var(--accent-light); color: var(--accent); }  .b-review::before  { background: var(--accent); }
.b-counter { background: var(--purple-light); color: var(--purple); }  .b-counter::before { background: var(--purple); }

/* ── ERROR STATE ── */
.error-state { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 64px 24px; text-align: center; }
.error-icon  { font-size: 48px; margin-bottom: 16px; }
.error-title { font-size: 17px; font-weight: 700; color: var(--red); margin-bottom: 8px; }
.error-sub   { font-size: 14px; color: var(--text-secondary); max-width: 320px; margin-bottom: 24px; line-height: 1.6; }

/* ── SUCCESS BANNER ── */
.success-banner { display: flex; align-items: center; gap: 14px; background: var(--green-light); border: 1.5px solid var(--green); border-radius: var(--r-md); padding: 16px 20px; margin-bottom: 20px; }
.success-banner-icon { font-size: 24px; flex-shrink: 0; }
.success-banner-text { font-size: 14px; font-weight: 600; color: var(--green); }

/* ── MOBILE MENU TOGGLE ── */
.sb-toggle {
  display: none; width: 36px; height: 36px; border: 1.5px solid var(--border);
  border-radius: var(--r-sm); background: var(--surface); cursor: pointer;
  font-size: 16px; align-items: center; justify-content: center; flex-shrink: 0;
}

/* ── MOBILE BOTTOM NAV ── */
.mob-nav {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 90;
  background: var(--surface); border-top: 1px solid var(--border);
  box-shadow: 0 -2px 16px rgba(15,23,42,.07);
  height: 62px; align-items: stretch; padding: 0 4px;
}
.mob-nav-item {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  justify-content: center; gap: 3px; text-decoration: none;
  color: var(--text-muted); font-size: 10px; font-weight: 600;
  letter-spacing: .02em; padding: 6px 2px; transition: color .15s;
  border: none; background: transparent; cursor: pointer; min-width: 0;
}
.mob-nav-item.on { color: var(--accent); }
.mob-nav-item.on .mob-nav-icon { background: var(--accent-light); border-radius: var(--r-sm); }
.mob-nav-icon { font-size: 20px; line-height: 1; width: 32px; height: 26px; display: flex; align-items: center; justify-content: center; transition: background .15s; }
.mob-nav-label { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 56px; }

/* Pub nav hamburger button (hidden on desktop) */
.pub-nav-ham { display: none; width: 36px; height: 36px; border: 1.5px solid var(--border); border-radius: var(--r-sm); background: transparent; cursor: pointer; font-size: 18px; align-items: center; justify-content: center; }

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
  .kpi-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .pipeline { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  /* Sidebar */
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.28s cubic-bezier(.4,0,.2,1);
    z-index: 60;
  }
  .sidebar.sb-open { transform: translateX(0); }
  .app-main { margin-left: 0; }

  /* Show mobile toggles */
  .sb-toggle { display: flex; }
  .pub-nav-ham { display: flex; }

  /* App layout */
  .app-hdr { padding: 0 16px; gap: 8px; }
  .app-hdr-title { font-size: 14px; }

  /* Page content */
  .page { padding: 16px 16px 80px; } /* bottom pad for mob-nav */

  /* KPI grids */
  .kpi-3, .kpi-4 { grid-template-columns: 1fr 1fr; }
  .kpi-val { font-size: 22px; }

  /* General grids */
  .grid-3, .grid-4 { grid-template-columns: 1fr 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .pipeline { grid-template-columns: 1fr; }

  /* Public nav */
  .pub-nav { padding: 0 16px; height: 56px; }
  .pub-nav-links { display: none; }
  .pub-nav-brand-sub { display: none; }

  /* Typography */
  h1, .t-h1 { font-size: 24px; }
  .t-h2 { font-size: 20px; }

  /* Tables */
  .tbl-wrap { font-size: 13px; }
  thead th { padding: 8px 10px; }
  tbody td { padding: 10px 10px; }

  /* Forms */
  .form-row-2, .form-row-3 { grid-template-columns: 1fr; }
  .filter-bar { gap: 6px; }

  /* Modal */
  .modal { padding: 24px 20px; margin: 16px; max-width: calc(100% - 32px); }

  /* Footer */
  .pub-footer { flex-direction: column; gap: 16px; text-align: center; padding: 24px 20px 80px; }

  /* State demo bar */
  #state-demo-bar { bottom: 72px; font-size: 11px; padding: 6px 12px; }

  /* Mobile bottom nav — show */
  .mob-nav { display: flex; }

  /* Bento hero grid — stack vertically */
  .bento-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
  }
  .b-headline { padding: 28px 24px !important; }
  .b-headline h1 { font-size: 28px !important; }
  .b-dashboard { min-height: 240px !important; }
  .b-stats {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
  }

  /* Spaces-list: hide sidebar on mobile, full width results */
  .page-wrap {
    grid-template-columns: 1fr !important;
    padding: 16px !important;
    gap: 16px !important;
  }
  .filters-aside { display: none !important; }
  #mob-filter-btn { display: flex !important; }
  .cards-grid { grid-template-columns: 1fr 1fr !important; }

  /* Virtual office hero */
  .hero-vo-inner { grid-template-columns: 1fr !important; gap: 32px; }
  .hero-vo { padding: 40px 20px; }

  /* Marketplace + service detail grids */
  .mk-grid { grid-template-columns: 1fr 1fr !important; }
  .detail-grid { grid-template-columns: 1fr !important; }
  .cta-panel { position: static !important; }

  /* Plan grids */
  .plans-grid { grid-template-columns: 1fr !important; }
  .ben-grid { grid-template-columns: 1fr !important; }
  .feat-grid { grid-template-columns: 1fr !important; }
  .test-grid { grid-template-columns: 1fr !important; }

  /* CTA banner */
  .cta-banner { flex-direction: column !important; text-align: center; padding: 32px 24px; }
  .cta-banner-btns { justify-content: center; }

  /* Auth */
  .auth-split { grid-template-columns: 1fr !important; }
  .auth-brand { display: none !important; }
  .auth-form-area { padding: 32px 20px 80px; }
}
@media (max-width: 480px) {
  .kpi-3, .kpi-4 { grid-template-columns: 1fr; }
  .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .cards-grid { grid-template-columns: 1fr !important; }
  .mk-grid { grid-template-columns: 1fr !important; }
}
