:root {
  --lg-ink: #1c2a24;
  --lg-forest: #1f4d3b;
  --lg-forest-light: #2f6f4f;
  --lg-paper: #f7f5ef;
  --lg-line: #dcd6c6;
  --lg-amber: #8a5a12;
  --lg-amber-bg: #fbf0dc;
  --lg-muted: #6b7268;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--lg-ink);
  background: var(--lg-paper);
}

.localgist-popup {
  width: 360px;
  padding: 16px;
}

.localgist-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.localgist-title h1 {
  margin: 0;
  font-size: 17px;
  letter-spacing: -0.01em;
  color: var(--lg-forest);
}

.localgist-title p {
  margin: 2px 0 0;
  font-size: 12px;
  color: var(--lg-muted);
}

.localgist-status-pill {
  flex-shrink: 0;
  font-size: 10.5px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #eee;
  color: #555;
  white-space: nowrap;
}

.localgist-status-ready {
  background: #e3efe7;
  color: var(--lg-forest-light);
}

.localgist-status-unavailable {
  background: var(--lg-amber-bg);
  color: var(--lg-amber);
}

.localgist-status-demo {
  background: #e7e4f3;
  color: #4d3f8f;
}

.localgist-source {
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--lg-muted);
  min-height: 16px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.localgist-brief-btn {
  width: 100%;
  margin-top: 10px;
  padding: 10px;
  border: none;
  border-radius: 8px;
  background: var(--lg-forest);
  color: #fff;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
}

.localgist-brief-btn:disabled {
  background: var(--lg-forest-light);
  cursor: default;
  opacity: 0.85;
}

.localgist-result {
  margin-top: 14px;
  border-top: 1px solid var(--lg-line);
  padding-top: 10px;
}

.localgist-block {
  margin-bottom: 12px;
}

.localgist-block h2 {
  margin: 0 0 4px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--lg-muted);
}

.localgist-block p {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
}

.localgist-block ul {
  margin: 0;
  padding-left: 18px;
  font-size: 12.5px;
  line-height: 1.5;
}

.localgist-watchfor {
  background: var(--lg-amber-bg);
  border-radius: 8px;
  padding: 8px 10px;
}

.localgist-watchfor h2 {
  color: var(--lg-amber);
}

.localgist-recent {
  margin-top: 14px;
  border-top: 1px solid var(--lg-line);
  padding-top: 10px;
}

.localgist-recent h2 {
  margin: 0 0 6px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--lg-muted);
}

.localgist-recent ul {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 12px;
}

.localgist-recent li {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 4px 0;
  color: var(--lg-ink);
}

.localgist-recent-date {
  color: var(--lg-muted);
  flex-shrink: 0;
}

.localgist-recent-empty {
  color: var(--lg-muted);
}

.localgist-footer {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--lg-line);
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 11px;
  color: var(--lg-muted);
}

.localgist-upgrade-btn {
  padding: 8px;
  border: 1px solid var(--lg-forest);
  border-radius: 8px;
  background: #fff;
  color: var(--lg-forest);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
