:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  --bg: #f4f6f9;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --text: #172033;
  --muted: #64748b;
  --border: #dbe2ea;
  --border-strong: #cbd5e1;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-soft: #eff6ff;
  --danger: #b42318;
  --danger-hover: #912018;
  --danger-soft: #fff1f0;
  --shadow: 0 1px 2px rgb(15 23 42 / 5%), 0 8px 24px rgb(15 23 42 / 5%);
  --radius: 12px;
}

* { box-sizing: border-box; }

body {
  min-height: 100vh;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.55;
}

a {
  color: var(--primary-hover);
  font-weight: 600;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover { color: #1e40af; }

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid rgb(37 99 235 / 24%);
  outline-offset: 2px;
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  margin-bottom: 0.45rem;
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  line-height: 1.18;
  letter-spacing: -0.025em;
}

h2 {
  margin-bottom: 1rem;
  font-size: 1.15rem;
  line-height: 1.3;
}

.site-header {
  position: sticky;
  z-index: 10;
  top: 0;
  border-bottom: 1px solid var(--border);
  background: rgb(255 255 255 / 94%);
  backdrop-filter: blur(10px);
}

.nav-shell {
  display: flex;
  width: min(1120px, calc(100% - 32px));
  min-height: 64px;
  margin: 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-size: 0.98rem;
  font-weight: 750;
  text-decoration: none;
  white-space: nowrap;
}

.brand:hover { color: var(--text); }

.brand-mark {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 9px;
  background: var(--primary);
  color: #fff;
  font-size: 0.84rem;
  font-weight: 800;
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  padding: 8px 12px;
  border-radius: 8px;
  color: #475569;
  font-size: 0.9rem;
  font-weight: 650;
  text-decoration: none;
}

.nav-link:hover {
  background: var(--surface-soft);
  color: var(--text);
}

.nav-link.is-active {
  background: var(--primary-soft);
  color: var(--primary-hover);
}

.page-shell {
  width: min(920px, calc(100% - 32px));
  margin: 0 auto;
  padding: 38px 0 64px;
}

.page-shell-wide { width: min(1120px, calc(100% - 32px)); }

.page-heading {
  display: flex;
  margin-bottom: 24px;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.page-heading p { margin-bottom: 0; color: var(--muted); }

.eyebrow {
  margin-bottom: 7px;
  color: var(--primary-hover);
  font-size: 0.75rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.panel {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.panel + .panel,
.section-gap { margin-top: 20px; }

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.75fr);
  gap: 20px;
  align-items: start;
}

.muted { color: var(--muted); }

.meta-row {
  display: flex;
  margin: 0;
  flex-wrap: wrap;
  gap: 8px 16px;
  color: var(--muted);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: var(--primary-soft);
  color: #1e40af;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.4;
  white-space: nowrap;
}

.integration-summary { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.integration-summary > div:last-child { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.status-success { background: #dcfce7; color: #166534; }
.status-warning { background: #fef3c7; color: #92400e; }
.status-danger { background: #fee2e2; color: #991b1b; }

.item-list,
.host-list {
  display: grid;
  margin: 0;
  padding: 0;
  gap: 10px;
  list-style: none;
}

.item-list li,
.host-list li {
  display: flex;
  min-width: 0;
  padding: 13px 14px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-soft);
}

.item-main { min-width: 0; }
.item-main a, .item-main strong { display: block; overflow-wrap: anywhere; }
.item-meta { color: var(--muted); font-size: 0.86rem; }

.empty-state {
  padding: 24px;
  border: 1px dashed var(--border-strong);
  border-radius: 9px;
  color: var(--muted);
  text-align: center;
}

form { display: grid; gap: 14px; }

label {
  display: grid;
  gap: 6px;
  color: #334155;
  font-size: 0.88rem;
  font-weight: 650;
}

input, button, select { font: inherit; }

input, select {
  width: 100%;
  min-height: 44px;
  padding: 9px 11px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
}

input:hover { border-color: #94a3b8; }
input:focus { border-color: var(--primary); }
input[readonly] { background: var(--surface-soft); color: #475569; }
.confirm-row { display: flex; align-items: flex-start; flex-direction: row; gap: 10px; font-weight: 600; }
.confirm-row input { width: 18px; min-height: 18px; margin-top: 2px; }

.button,
button {
  display: inline-flex;
  min-height: 42px;
  padding: 9px 15px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: #fff;
  color: #334155;
  cursor: pointer;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
}

.button:hover,
button:hover {
  border-color: #94a3b8;
  background: var(--surface-soft);
  color: var(--text);
}

.button-primary,
button.button-primary {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
}

.button-primary:hover,
button.button-primary:hover {
  border-color: var(--primary-hover);
  background: var(--primary-hover);
  color: #fff;
}

.button-danger,
button.button-danger {
  border-color: #fecaca;
  background: var(--danger-soft);
  color: var(--danger);
}

.button-danger:hover,
button.button-danger:hover {
  border-color: #fca5a5;
  background: #ffe4e2;
  color: var(--danger-hover);
}

.button-small,
button.button-small { min-height: 34px; padding: 6px 10px; font-size: 0.82rem; }

.actions,
.action-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.action-grid form, .inline-form { display: inline-flex; width: auto; }

button.is-loading,
button.is-loading:hover {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
  cursor: wait;
  opacity: 0.88;
}

button.is-loading::before,
.operation-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: operation-spin 0.7s linear infinite;
}

button.is-loading::before { margin-right: 8px; content: ""; }

.operation-status {
  display: flex;
  margin-bottom: 18px;
  padding: 18px 20px;
  align-items: flex-start;
  gap: 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.operation-status h2 { margin: 0 0 4px; font-size: 1rem; }
.operation-status p { margin: 0; color: var(--muted); }
.operation-status .button { margin-top: 12px; }
.operation-next-form { display: inline-flex; margin-top: 12px; }
.operation-status-pending { border-color: #bfdbfe; background: #eff6ff; color: #2563eb; }
.operation-status-success { border-color: #bbf7d0; background: #f0fdf4; color: #15803d; }
.operation-status-error { border-color: #fecaca; background: var(--danger-soft); color: var(--danger); }
.operation-status-pending p,
.operation-status-success p,
.operation-status-error p { color: #475569; }

.operation-spinner { flex: 0 0 auto; margin-top: 2px; }
.operation-result-mark {
  display: grid;
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: currentColor;
  color: #fff;
  font-weight: 800;
  place-items: center;
}
.operation-code { margin-top: 6px !important; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.8rem; }

@keyframes operation-spin { to { transform: rotate(360deg); } }

.table-wrap { overflow-x: auto; }

.monitoring-dashboard {
  padding-top: 30px;
}

.monitoring-hero {
  display: flex;
  margin-bottom: 26px;
  padding: 28px 30px;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  border: 1px solid #dce5f0;
  border-radius: 18px;
  background: radial-gradient(circle at 100% 0, #e9f2ff 0, transparent 36%), var(--surface);
  box-shadow: 0 14px 35px rgb(15 23 42 / 6%);
}

.monitoring-hero h1 { margin-bottom: 7px; }
.monitoring-subtitle { margin-bottom: 0; color: var(--muted); }
.monitoring-hero-actions { display: grid; min-width: max-content; justify-items: end; gap: 12px; }

.monitoring-freshness {
  display: inline-flex;
  margin: 0;
  align-items: center;
  gap: 7px;
  color: #166534;
  font-size: 0.82rem;
  font-weight: 700;
}

.monitoring-freshness span,
.monitoring-status i {
  display: inline-block;
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: currentColor;
}

.monitoring-notice { margin: -8px 0 20px; }

.monitoring-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 0 0 30px;
}

.metric-card {
  display: flex;
  min-height: 166px;
  padding: 20px;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 7px 20px rgb(15 23 42 / 4%);
}

.metric-card > p {
  margin-bottom: 13px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 750;
  letter-spacing: .055em;
  text-transform: uppercase;
}

.metric-card > strong {
  margin-bottom: 5px;
  color: #172554;
  font-size: 1.75rem;
  letter-spacing: -.035em;
  line-height: 1;
}

.metric-card > span:not(.monitoring-status) { color: var(--muted); font-size: .82rem; }
.metric-card-summary { background: linear-gradient(145deg, #eff6ff, #fff); }
.metric-card-operations { background: linear-gradient(145deg, #f8fafc, #fff); }

.metric-progress {
  display: block;
  height: 7px;
  margin-top: auto;
  overflow: hidden;
  border-radius: 999px;
  background: #e7edf5;
}

.metric-progress::after {
  display: block;
  width: var(--metric-fill);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #60a5fa, var(--primary));
  content: "";
}

.monitoring-status {
  display: inline-flex;
  width: fit-content;
  margin-top: 10px;
  padding: 4px 8px;
  align-items: center;
  gap: 6px;
  border: 1px solid currentColor;
  border-radius: 999px;
  font-size: .74rem;
  font-weight: 700;
  line-height: 1.25;
  white-space: nowrap;
}

.status-success { border-color: #bbf7d0; background: #f0fdf4; color: #15803d; }
.status-warning { border-color: #fde68a; background: #fffbeb; color: #a16207; }
.status-danger { border-color: #fecaca; background: #fff1f2; color: #b42318; }
.status-neutral { border-color: #dbe2ea; background: #f8fafc; color: #475569; }

.monitoring-section { padding: 24px 0 0; border-top: 1px solid var(--border); }
.monitoring-section-heading { display: flex; margin-bottom: 15px; align-items: end; justify-content: space-between; gap: 16px; }
.monitoring-section-heading .eyebrow { margin-bottom: 3px; }
.monitoring-section-heading h2 { margin-bottom: 0; }
.monitoring-section-heading > p { margin-bottom: 2px; color: var(--muted); font-size: .86rem; }

.monitoring-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 7px 20px rgb(15 23 42 / 4%);
}

.monitoring-table { min-width: 1030px; }
.monitoring-table th { padding: 12px 14px; background: #f8fafc; }
.monitoring-table td { padding: 14px; color: #334155; font-size: .86rem; }
.monitoring-table tbody tr { transition: background .16s ease; }
.monitoring-table tbody tr:hover { background: #f8fbff; }
.monitoring-table td > strong,
.monitoring-table td > small { display: block; }
.monitoring-table td > small { margin-top: 3px; color: var(--muted); font-size: .76rem; }
.monitoring-table .monitoring-status { margin-top: 0; }
table { width: 100%; border-collapse: collapse; }

th, td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: middle;
}

th {
  background: var(--surface-soft);
  color: #475569;
  font-size: 0.75rem;
  font-weight: 750;
  letter-spacing: 0.035em;
  text-transform: uppercase;
}

tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: #fbfdff; }

dl {
  display: grid;
  grid-template-columns: minmax(110px, 0.35fr) minmax(0, 1fr);
  margin: 0;
  gap: 0;
}

dt, dd { margin: 0; padding: 11px 0; border-bottom: 1px solid var(--border); }
dt { color: var(--muted); font-size: 0.86rem; font-weight: 650; }
dd { overflow-wrap: anywhere; font-weight: 600; }

.back-link {
  display: inline-block;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 0.9rem;
  text-decoration: none;
}

.back-link:hover { color: var(--primary-hover); }

.project-overview { padding: 0; overflow: hidden; }
.overview-row {
  display: grid;
  grid-template-columns: minmax(160px, 0.32fr) minmax(0, 1fr);
  gap: 24px;
  padding: 16px 22px;
  border-bottom: 1px solid var(--border);
  align-items: center;
}
.overview-client { padding-block: 22px; background: var(--surface-soft); }
.overview-client h1 { margin: 3px 0 0; font-size: 1.55rem; }
.overview-label { color: var(--muted); font-size: 0.86rem; font-weight: 650; }
.overview-value { min-width: 0; overflow-wrap: anywhere; }
.overview-value > .muted { display: block; margin-bottom: 3px; font-size: 0.78rem; }
.overview-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.webhook-preview {
  max-width: 100%;
  padding: 5px 8px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: #f8fafc;
  color: #334155;
  overflow-wrap: anywhere;
}
.project-controls { padding: 18px 22px 22px; }
.project-controls .action-grid { margin-top: 10px; }
.button-disabled { opacity: 0.48; cursor: not-allowed; pointer-events: none; }
.secret-summary { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; align-items: center; }

.auth-page {
  display: grid;
  min-height: 100vh;
  padding: 24px;
  place-items: center;
}

.auth-card {
  width: min(420px, 100%);
  padding: 30px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.auth-card > p { color: var(--muted); }

@media (max-width: 760px) {
  .nav-shell {
    width: min(100% - 24px, 1120px);
    min-height: auto;
    padding: 10px 0;
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .primary-nav { width: 100%; overflow-x: auto; }
  .nav-link { flex: 1; text-align: center; white-space: nowrap; }

  .page-shell,
  .page-shell-wide {
    width: min(100% - 24px, 1120px);
    padding-top: 24px;
  }

  .page-heading,
  .content-grid { display: grid; grid-template-columns: 1fr; }
  .page-heading .button { width: 100%; }
  .panel { padding: 18px; }

  .monitoring-dashboard { padding-top: 24px; }
  .monitoring-hero { padding: 22px; flex-direction: column; gap: 16px; }
  .monitoring-hero-actions { width: 100%; justify-items: stretch; }
  .monitoring-hero-actions .button { width: 100%; }
  .monitoring-grid { grid-template-columns: 1fr; }
  .metric-card { min-height: 142px; }
  .monitoring-section-heading { align-items: flex-start; flex-direction: column; gap: 5px; }

  .project-overview { padding: 0; }
  .overview-row { grid-template-columns: 1fr; gap: 8px; padding: 15px 18px; }
  .overview-actions .button { width: 100%; text-align: center; }
  .project-controls { padding: 16px 18px 18px; }

  .item-list li,
  .host-list li { align-items: flex-start; flex-direction: column; }

  .action-grid,
  .action-grid form,
  .action-grid button { width: 100%; }

  dl { grid-template-columns: 1fr; }
  dt { padding-bottom: 2px; border-bottom: 0; }
  dd { padding-top: 0; }
}

/* Employee Vibe shell. Admin pages keep the compact header rules above. */
.employee-navigation,
.employee-navigation + .page-shell {
  --bg: #f7f5f8;
  --text: #342e39;
  --muted: #716a76;
  --border: #e6e1e8;
  --border-strong: #d8d1dc;
  --primary: #6e56cf;
  --primary-hover: #5942bc;
  --primary-soft: #eee9ff;
  --shadow: 0 8px 28px rgb(55 39 67 / 6%);
  --radius: 14px;
}

.employee-navigation {
  position: fixed;
  inset: 0 auto 0 0;
  width: 248px;
  border: 0;
  background: #241d2e;
  box-shadow: 10px 0 35px rgb(31 21 40 / 8%);
  backdrop-filter: none;
}

.employee-navigation .nav-shell {
  width: 100%;
  min-height: 100%;
  margin: 0;
  padding: 30px 22px;
  align-items: stretch;
  justify-content: flex-start;
  flex-direction: column;
  gap: 34px;
}

.employee-navigation .brand { color: #fff; font-size: 1.05rem; }
.employee-navigation .brand:hover { color: #fff; }
.employee-navigation .brand strong { color: #a996ff; }
.employee-navigation .brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  background: linear-gradient(145deg, #8b72ed, #654ac8);
  box-shadow: 0 8px 20px rgb(110 86 207 / 30%);
}

.employee-navigation .primary-nav {
  display: grid;
  width: 100%;
  gap: 6px;
}

.employee-navigation .nav-link {
  min-height: 44px;
  padding: 11px 13px;
  border-radius: 10px;
  color: #bdb4c7;
  font-size: 0.9rem;
}

.employee-navigation .nav-link:hover {
  background: rgb(255 255 255 / 7%);
  color: #fff;
}

.employee-navigation .nav-link.is-active {
  background: #6e56cf;
  color: #fff;
  box-shadow: 0 8px 22px rgb(18 12 25 / 22%);
}

.employee-navigation + .page-shell {
  width: calc(100% - 248px);
  max-width: none;
  margin: 0 0 0 248px;
  padding: 46px clamp(28px, 4vw, 64px) 72px;
  background: var(--bg);
}

.employee-page { min-height: 100vh; }
.employee-page > * { width: min(1120px, 100%); margin-right: auto; margin-left: auto; }

.vibe-page-heading {
  display: flex;
  margin-bottom: 38px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.vibe-page-heading h1 { margin-bottom: 8px; font-size: clamp(2rem, 3vw, 2.65rem); }
.vibe-page-heading p:last-child { max-width: 650px; margin: 0; color: var(--muted); }
.employee-page .eyebrow { color: #725bcc; letter-spacing: 0.11em; }

.workspace-section {
  scroll-margin-top: 24px;
  margin-top: 34px;
}

.section-heading {
  display: flex;
  margin-bottom: 16px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
}

.section-heading .eyebrow { margin-bottom: 5px; }
.section-heading h2 { margin: 0; font-size: 1.4rem; }
.section-heading p:last-child { max-width: 720px; margin: 7px 0 0; }

.project-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.project-summary-card {
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: #fff;
  box-shadow: var(--shadow);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.project-summary-card:hover {
  border-color: #d3cae6;
  box-shadow: 0 13px 36px rgb(55 39 67 / 10%);
  transform: translateY(-2px);
}

.project-card-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.project-monogram,
.empty-state-mark,
.client-icon {
  display: grid;
  place-items: center;
  color: #6c54ca;
  background: #eee9ff;
  font-weight: 800;
}

.project-monogram { width: 38px; height: 38px; border-radius: 11px; font-family: ui-monospace, monospace; }
.project-summary-card h3 { margin: 20px 0 6px; font-size: 1.08rem; }
.project-summary-card h3 a { color: var(--text); text-decoration: none; }
.project-summary-card h3 a:hover { color: var(--primary-hover); }
.project-card-meta {
  display: flex;
  min-height: 44px;
  margin: 0;
  flex-wrap: wrap;
  align-content: flex-start;
  gap: 3px 7px;
  color: var(--muted);
  font-size: 0.84rem;
}
.project-card-meta a { color: #655b6b; font-size: inherit; text-decoration: none; }
.project-card-action {
  display: flex;
  margin-top: 17px;
  padding-top: 15px;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #f0edf2;
  color: #654dc2;
  font-size: 0.86rem;
  text-decoration: none;
}

.status-neutral { border-color: #ded9e3; background: #f2eff4; color: #68606e; }

.client-card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.client-summary-card {
  display: grid;
  min-width: 0;
  min-height: 82px;
  padding: 14px 16px;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: #fff;
  color: var(--text);
  box-shadow: 0 4px 18px rgb(55 39 67 / 4%);
  text-decoration: none;
}
.client-summary-card:hover { border-color: #d3cae6; color: var(--text); }
.client-icon { width: 42px; height: 42px; border-radius: 12px; }
.client-summary-card strong,
.client-summary-card small { display: block; overflow-wrap: anywhere; }
.client-summary-card small { margin-top: 3px; color: var(--muted); font-weight: 500; }

.vibe-empty-state {
  padding: 38px 24px;
  border: 1px dashed #d6cfe0;
  border-radius: 15px;
  background: rgb(255 255 255 / 55%);
  text-align: center;
}
.empty-state-mark { width: 48px; height: 48px; margin: 0 auto 14px; border-radius: 14px; }
.vibe-empty-state h3 { margin-bottom: 6px; }
.vibe-empty-state p { max-width: 480px; margin: 0 auto 18px; color: var(--muted); }

.compact-form-card {
  display: grid;
  grid-template-columns: minmax(220px, 0.7fr) minmax(300px, 1fr);
  align-items: end;
  gap: 30px;
}
.compact-form-card h2 { margin-bottom: 7px; }
.compact-form-card p { margin-bottom: 0; }
.compact-form-card form { grid-template-columns: minmax(180px, 1fr) auto; align-items: end; }

.secrets-section { padding: 26px; }
.inline-empty-state {
  display: grid;
  padding: 17px 18px;
  gap: 3px;
  border-radius: 10px;
  color: var(--muted);
  background: #f6f3f8;
}
.inline-empty-state strong { color: var(--text); }
.secret-form { grid-template-columns: repeat(3, minmax(0, 1fr)) auto; align-items: end; }

@media (max-width: 900px) {
  .employee-navigation { width: 210px; }
  .employee-navigation + .page-shell { width: calc(100% - 210px); margin-left: 210px; padding-inline: 26px; }
  .employee-navigation .nav-shell { padding-inline: 16px; }
  .compact-form-card,
  .secret-form { grid-template-columns: 1fr; }
  .compact-form-card form { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .employee-navigation {
    position: sticky;
    inset: auto;
    width: 100%;
    background: #241d2e;
  }
  .employee-navigation .nav-shell {
    width: 100%;
    min-height: auto;
    padding: 12px;
    align-items: center;
    flex-direction: row;
    gap: 12px;
  }
  .employee-navigation .brand span:last-child { display: none; }
  .employee-navigation .brand-mark { width: 34px; height: 34px; }
  .employee-navigation .primary-nav { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); min-width: 0; gap: 4px 6px; }
  .employee-navigation .nav-link { min-height: 36px; padding: 7px 6px; font-size: .82rem; white-space: normal; }
  .employee-navigation + .page-shell { width: 100%; margin-left: 0; padding: 28px 16px 56px; }
  .vibe-page-heading { align-items: stretch; flex-direction: column; }
  .vibe-page-heading .button { width: 100%; }
  .section-heading { align-items: stretch; flex-direction: column; }
  .section-heading .button { width: 100%; }
  .project-card-grid,
  .client-card-grid { grid-template-columns: 1fr; }
  .project-card-meta { min-height: auto; }
  .compact-form-card { padding: 20px; }
  .secrets-section { padding: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .project-summary-card { transition: none; }
}

.storage-filters { display:flex; flex-wrap:wrap; align-items:flex-end; gap:16px; margin:24px 0; }
.storage-filters label { display:grid; gap:7px; min-width:220px; }
.storage-filters input, .storage-filters select { min-height:42px; padding:9px 12px; border:1px solid #dedce8; border-radius:10px; background:#fff; color:#242235; }
.monitoring-table td small { overflow-wrap:anywhere; }
.employee-navigation + .page-shell.employee-files { max-width: none; }
.employee-files { color: #26334a; }
.files-heading, .files-location { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 24px; }
.files-heading h1 { margin: 0 0 8px; font-size: clamp(24px, 3vw, 34px); }
.files-heading p, .files-help, .files-cli p { color: #657188; }
.files-eyebrow { font-size: 12px; font-weight: 700; color: #7461c6; margin: 0 0 8px; }
.files-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; align-items: start; }
.files-projects, .files-content { background: #fff; border: 1px solid #e5e6ed; border-radius: 16px; padding: 20px; min-width: 0; }
.files-projects h2 { font-size: 15px; margin: 0 0 14px; }
.files-project-link { display: block; padding: 12px; border-radius: 9px; overflow-wrap: anywhere; color: #344158; text-decoration: none; }
.files-project-link:hover, .files-project-link.is-selected { background: #f0ecfc; color: #6147ba; }
.files-project-link small { display: block; margin-top: 5px; color: #707b8f; }
.files-location { align-items: start; }
.files-location h2 { font-size: 22px; margin: 0 0 12px; overflow-wrap: anywhere; }
.files-location > div { min-width: 0; }
.files-path { margin: 0; }
.files-path span { display: block; font-size: 12px; color: #768197; margin-bottom: 5px; }
.files-path code, .files-row-path { font-size: 12px; overflow-wrap: anywhere; white-space: normal; }
.files-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); background: #f7f8fb; border: 1px solid #ecedf2; border-radius: 12px; padding: 18px; gap: 16px; margin-bottom: 20px; }
.files-metrics span { display: block; color: #758096; font-size: 12px; margin-bottom: 7px; }
.files-metrics strong { font-size: 23px; color: #27344a; }
.files-metrics small { font-size: 12px; font-weight: 400; }
.files-filters { margin: 20px 0; }
.files-table { min-width: 540px; }
.files-table td:first-child { width: 55%; max-width: 0; overflow-wrap: anywhere; }
.files-table td { vertical-align: top; }
.files-row-path { display: block; margin-top: 6px; color: #6c7890; }
.files-project-context { margin-top: 5px; }
.files-pagination { display: flex; gap: 20px; margin-top: 18px; }
.files-help { font-size: 12px; line-height: 1.7; }
.files-cli { display: flex; justify-content: space-between; gap: 20px; padding: 20px; margin-top: 24px; background: #f6f3ff; border-radius: 12px; }
.files-cli h3 { margin: 0 0 8px; font-size: 15px; }
.files-cli p { margin: 0; font-size: 13px; line-height: 1.6; }
.files-cli-links { display: flex; flex-direction: column; align-items: center; gap: 10px; flex-shrink: 0; }
@media (max-width: 1100px) { .files-layout { grid-template-columns: minmax(0, 1fr); }.files-projects { max-height: 230px; overflow: auto; } }
@media (max-width: 640px) { .files-heading, .files-location, .files-cli { flex-direction: column; align-items: stretch; }.files-metrics { grid-template-columns: minmax(0, 1fr); }.files-content, .files-projects { padding: 16px; }.files-cli-links { align-items: stretch; } }
.files-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 24px; }
.files-tabs a { padding: 10px 15px; border-radius: 9px; text-decoration: none; color: #596780; }
.files-tabs a[aria-current="page"] { color: #6147ba; background: #eae3ff; font-weight: 700; }
.files-tabs a[hidden] { display: none; }
.files-share { display: block; width: 100%; min-width: 80px; height: 8px; margin-top: 8px; accent-color: #8061d5; }
.files-share::-webkit-meter-bar { background: #eeedf7; border: 0; border-radius: 8px; }
.files-share::-webkit-meter-optimum-value { background: #8061d5; border-radius: 8px; }
.files-row-tools { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; font-size: 12px; }
.files-copy { border: 0; background: transparent; color: #6147ba; padding: 0; min-height: 28px; font: inherit; cursor: pointer; text-align: left; }
.files-purpose { color: #6147ba; font-weight: 600; margin-top: 5px; }

.files-delete{color:#b42318;background:none;border:0;text-decoration:underline;cursor:pointer;font:inherit}.files-delete-dialog{max-width:560px;width:calc(100% - 40px);box-sizing:border-box;border:1px solid #e2deeb;border-radius:16px;padding:24px;color:#172b3f}.files-delete-dialog::backdrop{background:#172b3f66}.files-delete-dialog code{display:block;overflow-wrap:anywhere;white-space:pre-wrap;padding:12px;background:#f5f4f8;border-radius:8px}.files-delete-actions{display:flex;gap:12px;flex-wrap:wrap;justify-content:flex-end}.files-delete-dialog [role=alert]{color:#b42318}.files-delete-dialog button:disabled{opacity:.6;cursor:wait}
