/* SignTurn — Global Styles */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --blue: #1a56db;
  --blue-dark: #1e429f;
  --blue-light: #ebf0ff;
  --green: #059669;
  --green-light: #ecfdf5;
  --red: #dc2626;
  --red-light: #fef2f2;
  --yellow: #d97706;
  --yellow-light: #fffbeb;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --radius: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,.1), 0 2px 4px -1px rgba(0,0,0,.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,.1), 0 4px 6px -2px rgba(0,0,0,.05);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--gray-50);
  color: var(--gray-800);
  line-height: 1.5;
  min-height: 100vh;
}

/* ── Navbar ── */
.navbar {
  background: white;
  border-bottom: 1px solid var(--gray-200);
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}
.navbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--gray-900);
  font-weight: 700;
  font-size: 18px;
}
.navbar-brand .logo-icon {
  background: var(--blue);
  color: white;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}
.navbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.navbar-user {
  color: var(--gray-600);
  font-size: 14px;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.15s ease;
  white-space: nowrap;
}
.btn:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-primary { background: var(--blue); color: white; }
.btn-primary:hover:not(:disabled) { background: var(--blue-dark); }
.btn-success { background: var(--green); color: white; }
.btn-success:hover:not(:disabled) { background: #047857; }
.btn-danger { background: var(--red); color: white; }
.btn-danger:hover:not(:disabled) { background: #b91c1c; }
.btn-secondary { background: white; color: var(--gray-700); border: 1px solid var(--gray-300); }
.btn-secondary:hover:not(:disabled) { background: var(--gray-50); }
.btn-ghost { background: transparent; color: var(--gray-600); }
.btn-ghost:hover:not(:disabled) { background: var(--gray-100); }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-lg { padding: 12px 24px; font-size: 16px; }

/* ── Forms ── */
.form-group { margin-bottom: 16px; }
.form-label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--gray-700);
  margin-bottom: 6px;
}
.form-control {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  font-size: 14px;
  color: var(--gray-800);
  background: white;
  transition: border-color 0.15s;
}
.form-control:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(26,86,219,0.15);
}
select.form-control { appearance: none; cursor: pointer; }

/* ── Cards ── */
.card {
  background: white;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.card-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.card-title { font-weight: 600; font-size: 16px; color: var(--gray-900); }
.card-body { padding: 20px; }

/* ── Badges / Status ── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 500;
}
.badge-pending { background: var(--yellow-light); color: var(--yellow); }
.badge-partially_signed { background: var(--blue-light); color: var(--blue); }
.badge-completed { background: var(--green-light); color: var(--green); }

/* ── Alerts ── */
.alert {
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 14px;
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.alert-error { background: var(--red-light); color: var(--red); border: 1px solid #fca5a5; }
.alert-success { background: var(--green-light); color: var(--green); border: 1px solid #6ee7b7; }
.alert-info { background: var(--blue-light); color: var(--blue); border: 1px solid #a5b4fc; }

/* ── Modals ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}
.modal-overlay.hidden { display: none; }
.modal {
  background: white;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
}
.modal-header {
  padding: 20px 24px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-header h3 { font-size: 18px; font-weight: 600; }
.modal-close {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--gray-400);
  font-size: 20px;
  padding: 4px;
  line-height: 1;
}
.modal-close:hover { color: var(--gray-700); }
.modal-body { padding: 20px 24px; }
.modal-footer {
  padding: 0 24px 20px;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

/* ── Loading spinner ── */
.spinner {
  width: 24px; height: 24px;
  border: 3px solid var(--gray-200);
  border-top-color: var(--blue);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Upload area ── */
.upload-area {
  border: 2px dashed var(--gray-300);
  border-radius: var(--radius);
  padding: 40px 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: white;
}
.upload-area:hover, .upload-area.drag-over {
  border-color: var(--blue);
  background: var(--blue-light);
}
.upload-icon { font-size: 40px; margin-bottom: 12px; }

/* ── Document table ── */
.doc-table { width: 100%; border-collapse: collapse; }
.doc-table th {
  padding: 12px 16px;
  text-align: left;
  font-size: 12px;
  font-weight: 600;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: .05em;
  border-bottom: 1px solid var(--gray-200);
  background: var(--gray-50);
}
.doc-table td {
  padding: 14px 16px;
  font-size: 14px;
  border-bottom: 1px solid var(--gray-100);
  vertical-align: middle;
}
.doc-table tr:hover td { background: var(--gray-50); }
.doc-table .doc-name { font-weight: 500; color: var(--gray-900); }
.doc-table .doc-meta { font-size: 12px; color: var(--gray-500); margin-top: 2px; }

/* ── Field Editor specific ── */
#editor-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 0;
  height: calc(100vh - 60px);
}
#pdf-container {
  position: relative;
  overflow: auto;
  background: #525659;
  padding: 20px;
}
#pdf-canvas-wrapper {
  position: relative;
  display: inline-block;
  margin: 0 auto;
}
#pdf-canvas { display: block; }
#field-overlay {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  cursor: crosshair;
}
.field-box {
  position: absolute;
  border: 2px solid;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
  cursor: default;
  overflow: hidden;
  transition: box-shadow 0.1s;
}
.field-box:hover { box-shadow: 0 0 0 2px rgba(0,0,0,.2); }
.field-box.signature   { background: rgba(26,86,219,.15); border-color: #1a56db; color: #1a56db; }
.field-box.initials    { background: rgba(124,58,237,.15); border-color: #7c3aed; color: #7c3aed; }
.field-box.date        { background: rgba(5,150,105,.15);  border-color: #059669; color: #059669; }
.field-box.text        { background: rgba(217,119,6,.15);  border-color: #d97706; color: #d97706; }
.field-box.signed { opacity: 0.7; }
.field-box .field-label { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 4px; }
.field-box .field-delete {
  position: absolute; top: 2px; right: 2px;
  background: rgba(220,38,38,.8);
  color: white; border: none; border-radius: 3px;
  width: 16px; height: 16px; font-size: 10px;
  cursor: pointer; display: none; align-items: center; justify-content: center;
  line-height: 1;
}
.field-box:hover .field-delete { display: flex; }

#sidebar {
  background: white;
  border-left: 1px solid var(--gray-200);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
#sidebar-header {
  padding: 16px;
  border-bottom: 1px solid var(--gray-200);
}
#sidebar-content { flex: 1; overflow-y: auto; padding: 12px; }
#field-list { list-style: none; }
.field-list-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  margin-bottom: 8px;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.1s;
}
.field-list-item:hover { border-color: var(--blue); background: var(--blue-light); }
.field-list-item .fi-type {
  width: 10px; height: 10px;
  border-radius: 2px;
  flex-shrink: 0;
}
.field-list-item .fi-info { flex: 1; min-width: 0; }
.field-list-item .fi-label { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.field-list-item .fi-meta { font-size: 11px; color: var(--gray-500); }
.field-list-item .fi-del {
  background: none; border: none; cursor: pointer;
  color: var(--gray-400); font-size: 14px; padding: 2px 4px;
}
.field-list-item .fi-del:hover { color: var(--red); }

/* Sign canvas */
#sig-canvas-wrap {
  border: 2px solid var(--gray-300);
  border-radius: var(--radius);
  background: white;
  overflow: hidden;
  touch-action: none;
}
#sig-canvas { display: block; touch-action: none; }

/* Tenant sign page */
#sign-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 0;
  height: calc(100vh - 60px);
}
#sign-sidebar {
  background: white;
  border-left: 1px solid var(--gray-200);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
#sign-sidebar-inner { flex: 1; overflow-y: auto; padding: 16px; }

/* PDF page nav */
.page-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(0,0,0,.6);
  color: white;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 14px;
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
}
.page-nav button {
  background: rgba(255,255,255,.2);
  border: none;
  color: white;
  width: 28px; height: 28px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  display: flex; align-items: center; justify-content: center;
}
.page-nav button:hover { background: rgba(255,255,255,.3); }
.page-nav button:disabled { opacity: 0.4; cursor: default; }

/* Login page */
.auth-container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: linear-gradient(135deg, #1e3a8a 0%, #1a56db 100%);
}
.auth-card {
  background: white;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 420px;
  padding: 40px;
}
.auth-logo {
  text-align: center;
  margin-bottom: 32px;
}
.auth-logo .logo-icon {
  background: var(--blue);
  color: white;
  width: 52px; height: 52px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin-bottom: 12px;
}
.auth-logo h1 { font-size: 24px; font-weight: 700; color: var(--gray-900); }
.auth-logo p { font-size: 14px; color: var(--gray-500); margin-top: 4px; }
.auth-tabs {
  display: flex;
  border-bottom: 1px solid var(--gray-200);
  margin-bottom: 24px;
}
.auth-tab {
  flex: 1; text-align: center;
  padding: 10px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: var(--gray-500);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all 0.15s;
}
.auth-tab.active { color: var(--blue); border-bottom-color: var(--blue); }

/* Signature pad area in sign page */
.sig-tab-buttons {
  display: flex;
  border-bottom: 1px solid var(--gray-200);
  margin-bottom: 16px;
}
.sig-tab-btn {
  flex: 1; padding: 8px;
  background: none; border: none;
  border-bottom: 2px solid transparent;
  font-size: 13px; font-weight: 500;
  cursor: pointer; color: var(--gray-500);
  margin-bottom: -1px;
}
.sig-tab-btn.active { color: var(--blue); border-bottom-color: var(--blue); }

/* Tenant field inputs on sign page */
.tenant-field {
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  background: var(--gray-50);
}
.tenant-field-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--gray-600);
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-bottom: 6px;
}
.tenant-field-type {
  font-size: 11px;
  color: var(--gray-400);
  margin-left: 6px;
}

/* Responsive */
@media (max-width: 768px) {
  #editor-layout, #sign-layout {
    grid-template-columns: 1fr;
    height: auto;
  }
  #sidebar, #sign-sidebar {
    border-left: none;
    border-top: 1px solid var(--gray-200);
    max-height: 50vh;
  }
  #pdf-container { min-height: 60vh; }
  .navbar { padding: 0 16px; }
  .auth-card { padding: 24px; }
}

/* ───────────────────────────────────────────────────────────────────────────
   Signer page (public/sign.html)

   Mobile-first: the document stacks above the controls on a phone, and goes
   side-by-side from 900px. Most signers are on a phone, so that is the
   layout that gets the default rather than the override.
   ─────────────────────────────────────────────────────────────────────────── */

.sign-body {
  background: var(--gray-50, #f9fafb);
  margin: 0;
}

.sign-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: #1a1a6e;
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 20;
}
.sign-nav-brand { font-weight: 700; letter-spacing: .2px; }
.sign-nav-doc {
  font-size: 13px;
  color: #c7d2fe;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sign-centered {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  text-align: left;
}

.sign-card {
  background: #fff;
  border: 1px solid var(--gray-200, #e5e7eb);
  border-radius: 10px;
  padding: 18px;
  margin-bottom: 14px;
}
.sign-card-narrow { max-width: 460px; width: 100%; }
.muted { color: var(--gray-500, #6b7280); }
.hint { font-size: 12px; color: var(--gray-500, #6b7280); margin: 6px 0 0; }

/* Consent — the ESIGN disclosure. Deliberately plain and readable rather
   than styled down into something skippable. */
.consent-box {
  background: var(--gray-50, #f9fafb);
  border: 1px solid var(--gray-200, #e5e7eb);
  border-radius: 8px;
  padding: 14px 16px;
  margin: 14px 0;
  max-height: 46vh;
  overflow-y: auto;
}
.consent-box h3 { margin: 0 0 10px; font-size: 14px; }
.consent-box ul { margin: 0; padding-left: 18px; }
.consent-box li { font-size: 13px; line-height: 1.55; margin-bottom: 8px; color: #374151; }

.consent-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 13px;
  line-height: 1.45;
  margin: 12px 0;
  cursor: pointer;
}
/* A 16px checkbox is a miss on a phone; this is the minimum comfortable tap. */
.consent-check input { width: 20px; height: 20px; flex: 0 0 auto; margin-top: 1px; }

#sign-layout {
  display: block;
  padding: 14px;
  max-width: 1280px;
  margin: 0 auto;
}
.sign-doc-pane { margin-bottom: 14px; }
.sign-side-pane { min-width: 0; }

@media (min-width: 900px) {
  #sign-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 18px;
    align-items: start;
  }
  .sign-doc-pane { margin-bottom: 0; }
  .sign-side-pane { position: sticky; top: 70px; max-height: calc(100vh - 86px); overflow-y: auto; }
}

.pdf-container {
  background: #fff;
  border: 1px solid var(--gray-200, #e5e7eb);
  border-radius: 10px;
  padding: 16px;
  overflow-x: auto;
  display: flex;
  justify-content: center;
}

.sign-who-name { font-weight: 600; }
.sign-who-meta { font-size: 12px; color: var(--gray-500, #6b7280); margin-top: 2px; }

.signers-list { margin-top: 12px; }
.signer-group { margin-bottom: 10px; }
.signer-group-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: var(--gray-400, #9ca3af);
  margin-bottom: 4px;
}
.signer-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  padding: 3px 0;
}
.signer-row.is-me { font-weight: 600; }
.signer-badge {
  width: 18px; height: 18px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%;
  font-size: 11px;
  flex: 0 0 auto;
}
.signer-badge.ok { background: #d1fae5; color: #065f46; }
.signer-badge.bad { background: #fee2e2; color: #991b1b; }
.signer-badge.mid { background: #e0e7ff; color: #3730a3; }
.signer-badge.muted { background: var(--gray-100, #f3f4f6); color: var(--gray-400, #9ca3af); }

.pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  background: #e0e7ff;
  color: #3730a3;
  margin-left: 6px;
}
.pill-muted { background: var(--gray-100, #f3f4f6); color: var(--gray-500, #6b7280); }

.sig-tabs { display: flex; gap: 6px; margin-bottom: 10px; }
.sig-tab-btn {
  flex: 1;
  padding: 7px 10px;
  font-size: 13px;
  border: 1px solid var(--gray-200, #e5e7eb);
  background: #fff;
  border-radius: 6px;
  cursor: pointer;
}
.sig-tab-btn.active { background: #1a1a6e; color: #fff; border-color: #1a1a6e; }

.sig-canvas {
  width: 100%;
  height: 130px;
  border: 1px dashed var(--gray-300, #d1d5db);
  border-radius: 8px;
  background: #fff;
  /* Without this the browser scrolls the page instead of drawing. */
  touch-action: none;
}

.typed-preview {
  min-height: 52px;
  display: flex;
  align-items: center;
  padding: 8px 10px;
  margin-top: 8px;
  border: 1px solid var(--gray-200, #e5e7eb);
  border-radius: 8px;
  font-size: 22px;
  font-style: italic;
  font-family: "Segoe Script", "Brush Script MT", Georgia, serif;
  color: #1a1a6e;
}

.tenant-field.done { border-color: #6ee7b7; background: #f0fdf9; }
.tenant-field.flash, .field-box.flash {
  animation: flash-ring 1.2s ease-out;
}
@keyframes flash-ring {
  0%   { box-shadow: 0 0 0 0 rgba(26, 86, 219, .55); }
  100% { box-shadow: 0 0 0 10px rgba(26, 86, 219, 0); }
}

/* Other signers' boxes stay visible but inert, so a signer can see the whole
   ceremony without being able to act on someone else's behalf. */
.field-box.theirs {
  opacity: .45;
  pointer-events: none;
  border-style: dotted;
}
.field-box.mine { cursor: pointer; }

.btn-block { display: block; width: 100%; justify-content: center; }
.btn-block + .btn-block { margin-top: 8px; }

.success-tick {
  width: 56px; height: 56px;
  margin: 0 auto 12px;
  border-radius: 50%;
  background: #d1fae5;
  color: #065f46;
  font-size: 30px;
  display: flex; align-items: center; justify-content: center;
}

/* ───────────────────────────────────────────────────────────────────────────
   Editor — recipients panel
   ─────────────────────────────────────────────────────────────────────────── */

.editor-section {
  padding-bottom: 14px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--gray-200, #e5e7eb);
}
.editor-section-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-600, #4b5563);
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-bottom: 10px;
}

.recipient-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 8px;
  border: 1px solid var(--gray-200, #e5e7eb);
  border-radius: 6px;
  margin-bottom: 6px;
  background: #fff;
}
.recipient-row.is-me { border-color: #c7d2fe; background: #f5f7ff; }
.recipient-main { min-width: 0; flex: 1; }
.recipient-name { font-size: 13px; font-weight: 600; }
.recipient-email {
  font-size: 11px;
  color: var(--gray-500, #6b7280);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.recipient-step {
  font-size: 10px;
  font-weight: 700;
  color: var(--gray-400, #9ca3af);
  flex: 0 0 auto;
}
.recipient-del {
  border: none; background: none; cursor: pointer;
  color: var(--gray-400, #9ca3af); font-size: 13px; padding: 2px 4px;
  flex: 0 0 auto;
}
.recipient-del:hover { color: #b91c1c; }

.recipient-add { margin-top: 10px; }
.recipient-add .form-control { margin-bottom: 6px; font-size: 13px; }
.recipient-add-row { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }

.send-link-row {
  font-size: 11px;
  padding: 6px 8px;
  border: 1px solid var(--gray-200, #e5e7eb);
  border-radius: 6px;
  margin-top: 6px;
  background: var(--gray-50, #f9fafb);
  word-break: break-all;
}
.send-link-row strong { display: block; margin-bottom: 2px; font-size: 12px; }

.sign-slot {
  margin-bottom: 8px;
  padding: 10px;
  border: 1px solid var(--gray-200, #e5e7eb);
  border-radius: 6px;
  background: #fff;
}
.sign-slot.done { border-color: #6ee7b7; background: #f0fdf9; }
.sign-slot-label { font-size: 12px; font-weight: 600; margin-bottom: 6px; color: var(--gray-700, #374151); }
.sign-slot-label .hint { display: inline; font-weight: 400; }

/* Activity timeline — the tracking view. */
.activity-row {
  display: flex;
  gap: 8px;
  font-size: 11.5px;
  padding: 3px 0;
  color: var(--gray-600, #4b5563);
}
.activity-when { flex: 0 0 62px; color: var(--gray-400, #9ca3af); }
.activity-what { min-width: 0; }
.activity-who { color: var(--gray-500, #6b7280); }

.recipient-track {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
  font-size: 10.5px;
  color: var(--gray-500, #6b7280);
}
.recipient-track span { white-space: nowrap; }
.recipient-track .on { color: #047857; font-weight: 600; }
.recipient-track .off { color: var(--gray-300, #d1d5db); }

.doc-digest {
  font-size: 10px;
  color: var(--gray-400, #9ca3af);
  word-break: break-all;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--gray-100, #f3f4f6);
}
.tenant-field.auto { opacity: .8; }

/* Google sign-in button. Follows Google's identity guidelines closely
   enough to be recognisable: white surface, their wordmark colours in the
   mark, and never restyled into the app's own palette. */
.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  background: #fff;
  color: #3c4043;
  border: 1px solid #dadce0;
  font-weight: 500;
  text-decoration: none;
}
.btn-google:hover { background: #f8f9fa; border-color: #d2d5d9; }
.btn-google svg { flex: 0 0 auto; }

.auth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0;
  color: var(--gray-400, #9ca3af);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gray-200, #e5e7eb);
}
