/* AgentRoot — Shared Styles */
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@300;400;500;600;700&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --bg: #fafaf9;
  --surface: #ffffff;
  --surface2: #f5f5f4;
  --border: #e7e5e4;
  --border2: #d6d3d1;
  --text: #1c1917;
  --text2: #44403c;
  --muted: #78716c;
  --accent: #c2410c;
  --accent-light: #fff7ed;
  --accent-border: #fed7aa;
  --green: #15803d;
  --green-bg: #f0fdf4;
  --green-border: #bbf7d0;
  --blue: #1d4ed8;
  --blue-bg: #eff6ff;
  --red: #dc2626;
  --red-bg: #fef2f2;
  --mono: 'JetBrains Mono', 'Fira Code', monospace;
  --sans: 'Inter', system-ui, sans-serif;
  --radius: 8px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── NAV ── */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(250,250,249,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0 40px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 15px;
  color: var(--text);
}
.logo-icon {
  width: 28px;
  height: 28px;
  background: var(--text);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bg);
  font-size: 13px;
  font-family: var(--mono);
  font-weight: 700;
}
nav { display: flex; align-items: center; gap: 4px; }
nav a {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 5px;
  transition: all 0.15s;
  white-space: nowrap;
}
nav a:hover { color: var(--text); background: var(--surface2); }
nav a.active { color: var(--accent); }
.nav-submit {
  background: var(--text) !important;
  color: var(--bg) !important;
  padding: 6px 14px !important;
  margin-left: 8px;
}
.nav-submit:hover { background: var(--accent) !important; color: white !important; }
.hamburger {
  display: none;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}
.hamburger span { display: block; width: 20px; height: 2px; background: var(--text); border-radius: 2px; }
.mobile-nav {
  display: none;
  position: fixed;
  top: 56px; left: 0; right: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 16px;
  z-index: 99;
  flex-direction: column;
  gap: 4px;
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text2);
  text-decoration: none;
  padding: 10px 12px;
  border-radius: 6px;
}
.mobile-nav a:hover { background: var(--surface2); }

/* ── PAGE HEADER ── */
.page-hero {
  padding: 60px 40px 48px;
  border-bottom: 1px solid var(--border);
  max-width: 1100px;
  margin: 0 auto;
}
.page-eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--accent);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.page-eyebrow::before {
  content: '';
  display: inline-block;
  width: 6px; height: 6px;
  background: var(--accent);
  border-radius: 50%;
}
.page-title {
  font-family: var(--mono);
  font-size: 36px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
  letter-spacing: -0.5px;
}
.page-subtitle {
  font-size: 16px;
  color: var(--text2);
  max-width: 560px;
  line-height: 1.6;
}

/* ── LAYOUT ── */
.container { max-width: 1100px; margin: 0 auto; padding: 0 40px; }
.content-section { padding: 56px 0; border-bottom: 1px solid var(--border); }
.content-section:last-of-type { border-bottom: none; }
.section-label {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 8px;
}
.section-title {
  font-family: var(--mono);
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 32px;
}

/* ── CODE BLOCKS ── */
.code-block {
  background: #1c1917;
  border-radius: var(--radius);
  padding: 20px;
  font-family: var(--mono);
  font-size: 13px;
  color: #e7e5e4;
  overflow-x: auto;
  line-height: 1.7;
  position: relative;
  white-space: pre-wrap;
}
.code-block .k { color: #86efac; }
.code-block .v { color: #93c5fd; }
.code-block .s { color: #fca5a5; }
.code-block .c { color: #57534e; }
.code-block .p { color: #f59e0b; }
code {
  font-family: var(--mono);
  font-size: 0.875em;
  background: var(--surface2);
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid var(--border);
  color: var(--accent);
}
.copy-btn {
  position: absolute;
  top: 10px; right: 10px;
  font-family: var(--mono);
  font-size: 11px;
  background: #292524;
  color: #a8a29e;
  border: 1px solid #3f3a36;
  padding: 4px 10px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s;
}
.copy-btn:hover { color: #e7e5e4; }

/* ── TERMINAL ── */
.terminal {
  background: #1c1917;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  font-family: var(--mono);
  font-size: 13px;
}
.terminal-bar {
  background: #292524;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.term-dot { width: 11px; height: 11px; border-radius: 50%; }
.term-dot.red { background: #ef4444; }
.term-dot.yellow { background: #f59e0b; }
.term-dot.green { background: #22c55e; }
.term-title { font-family: var(--mono); font-size: 11px; color: #78716c; margin-left: 8px; }
.terminal-body { padding: 20px; line-height: 1.7; }
.t-prompt { color: #f59e0b; }
.t-cmd { color: #e7e5e4; }
.t-comment { color: #57534e; }
.t-key { color: #86efac; }
.t-val { color: #93c5fd; }
.t-str { color: #fca5a5; }
.t-line { display: block; }

/* ── BUTTONS ── */
.btn-primary {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  background: var(--text);
  color: var(--bg);
  padding: 12px 24px;
  border-radius: var(--radius);
  text-decoration: none;
  transition: background 0.15s;
  display: inline-block;
  border: none;
  cursor: pointer;
}
.btn-primary:hover { background: var(--accent); }
.btn-ghost {
  font-family: var(--mono);
  font-size: 13px;
  background: transparent;
  color: var(--text2);
  border: 1px solid var(--border2);
  padding: 12px 24px;
  border-radius: var(--radius);
  text-decoration: none;
  transition: all 0.15s;
  display: inline-block;
  cursor: pointer;
}
.btn-ghost:hover { border-color: var(--text); color: var(--text); }

/* ── BADGES ── */
.badge {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.badge-mcp { background: var(--blue-bg); color: var(--blue); }
.badge-rest { background: #fff7ed; color: #c2410c; }
.badge-openapi { background: var(--green-bg); color: var(--green); }
.badge-graphql { background: #fdf4ff; color: #9333ea; }
.badge-a2a { background: #fefce8; color: #a16207; }
.badge-grpc { background: #f5f3ff; color: #7c3aed; }
.badge-other { background: var(--surface2); color: var(--muted); }
.badge-active { background: var(--green-bg); color: var(--green); border: 1px solid var(--green-border); }
.badge-pending { background: #fefce8; color: #a16207; }
.badge-failed { background: var(--red-bg); color: var(--red); }

/* ── TABLES ── */
table { width: 100%; border-collapse: collapse; font-size: 14px; }
thead th {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  text-align: left;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
tbody td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text2);
  vertical-align: top;
}
tbody td:first-child { font-family: var(--mono); font-size: 13px; color: var(--text); font-weight: 500; }
tbody tr:hover td { background: var(--surface2); }

/* ── FORMS ── */
.form-group { margin-bottom: 24px; }
label {
  display: block;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--text2);
  margin-bottom: 8px;
}
input[type="text"], input[type="url"], textarea {
  width: 100%;
  font-family: var(--mono);
  font-size: 14px;
  padding: 12px 14px;
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  outline: none;
  transition: border-color 0.15s;
}
input[type="text"]:focus, input[type="url"]:focus, textarea:focus { border-color: var(--text); }
input::placeholder, textarea::placeholder { color: var(--muted); }

/* ── ALERTS ── */
.alert {
  padding: 14px 18px;
  border-radius: var(--radius);
  font-size: 14px;
  margin-top: 16px;
  font-family: var(--mono);
}
.alert-success { background: var(--green-bg); color: var(--green); border: 1px solid var(--green-border); }
.alert-error { background: var(--red-bg); color: var(--red); border: 1px solid #fecaca; }
.alert-info { background: var(--blue-bg); color: var(--blue); border: 1px solid #bfdbfe; }
.alert-warning { background: #fefce8; color: #a16207; border: 1px solid #fde68a; }

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--border);
  padding: 28px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-left { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.footer-right { display: flex; gap: 24px; }
footer a { font-family: var(--mono); font-size: 12px; color: var(--muted); text-decoration: none; }
footer a:hover { color: var(--text); }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  header { padding: 0 20px; }
  nav { display: none; }
  .hamburger { display: flex; }
  .page-hero { padding: 40px 20px 32px; }
  .page-title { font-size: 26px; }
  .container { padding: 0 20px; }
  .content-section { padding: 40px 0; }
  footer { padding: 24px 20px; flex-direction: column; align-items: flex-start; }
}
