/* Aozo Developer Docs — ported from the real v2 Navbar + DocsLayout (aozo.in/docs) */

:root {
  --ink: #202124;
  --ink-muted: #3c4043;
  --ink-faint: #5f6368;
  --line: #e0e0e0;
  --accent: #1a73e8;
  --accent-hover: #1765cc;
  --accent-soft: #e8f0fe;
  --hover-bg: #f1f3f4;
  --sidebar-bg: #f8f9fa;
  --code-bg: #202124;
  --code-ink: #f8f9fa;
  --radius: 8px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: #fff;
  color: var(--ink);
  font-family: 'Google Sans', Arial, Helvetica, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }

/* ─── NAV (ported verbatim from v2 globals.css) ─── */
.nav { display: flex; align-items: center; height: 64px; padding: 0 40px; border-bottom: 1px solid var(--line); background: #fff; position: sticky; top: 0; z-index: 200; gap: 0; }
.logo { display: flex; align-items: center; gap: 8px; margin-right: 32px; text-decoration: none; }
.logo img { height: 32px; width: auto; object-fit: contain; }
.nav-links { display: flex; align-items: center; gap: 2px; flex: 1; }
.nav-item { display: flex; align-items: center; gap: 3px; padding: 6px 12px; border-radius: 4px; font-size: 14px; color: var(--ink-muted); cursor: pointer; white-space: nowrap; transition: background .15s; }
.nav-item:hover { background: var(--hover-bg); }
.nav-item i { font-size: 12px; color: var(--ink-faint); }
.nav-right { display: flex; align-items: center; gap: 12px; margin-left: auto; flex-shrink: 0; }
.nav-contact { font-size: 14px; color: var(--accent); font-weight: 500; cursor: pointer; padding: 6px 12px; border-radius: 4px; transition: background .15s; }
.nav-contact:hover { background: var(--accent-soft); }
.nav-cta { background: var(--accent); color: #fff; border: none; padding: 8px 24px; border-radius: 4px; font-size: 14px; font-weight: 500; cursor: pointer; font-family: inherit; transition: background .15s; }
.nav-cta:hover { background: var(--accent-hover); }

.nav-item-has-mega { position: relative; }
.mega-menu {
  opacity: 0; visibility: hidden;
  position: absolute; top: calc(100% + 10px); left: -20px;
  transform: translateY(10px);
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.08);
  width: 600px; padding: 32px; z-index: 1000;
  display: grid; grid-template-columns: 1fr 1fr; gap: 32px;
  transition: all 0.2s ease-out;
}
.nav-item-has-mega::after { content: ''; position: absolute; bottom: -20px; left: 0; right: 0; height: 20px; }
.nav-item-has-mega:hover .mega-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.mega-group h4 { font-size: 11px; font-weight: 700; color: var(--ink-faint); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 20px; }
.mega-link { display: flex; align-items: flex-start; gap: 16px; padding: 12px; border-radius: 12px; transition: background 0.15s; margin-bottom: 8px; }
.mega-link:hover { background: var(--sidebar-bg); }
.mega-link i { font-size: 24px; color: var(--accent); margin-top: 2px; }
.mega-link-title { font-size: 15px; font-weight: 600; color: var(--ink); margin-bottom: 4px; }
.mega-link-desc { font-size: 13px; color: var(--ink-faint); line-height: 1.5; }

.nav-mobile-toggle { display: none; background: transparent; border: none; font-size: 24px; color: var(--ink); cursor: pointer; width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 8px; }
.nav-mobile-toggle:hover { background: var(--hover-bg); }

.mobile-menu-overlay { position: fixed; top: 64px; left: 0; right: 0; bottom: 0; background: #fff; z-index: 199; overflow-y: auto; display: none; }
.mobile-menu-overlay.open { display: block; }
.mobile-menu-content { padding: 24px 40px; display: flex; flex-direction: column; gap: 16px; }
.mobile-nav-item { font-size: 18px; font-weight: 500; color: var(--ink); padding: 12px 0; border-bottom: 1px solid var(--hover-bg); display: flex; align-items: center; gap: 8px; }
.mobile-menu-actions { margin-top: 24px; display: flex; flex-direction: column; gap: 12px; }
.btn-primary { background: var(--accent); color: #fff; border: none; padding: 12px 28px; border-radius: 4px; font-size: 15px; font-weight: 500; cursor: pointer; font-family: inherit; transition: background .15s; display: block; text-align: center; }
.btn-primary:hover { background: var(--accent-hover); color: #fff; }
.btn-secondary { background: #fff; color: var(--accent); border: 1px solid #dadce0; padding: 12px 28px; border-radius: 4px; font-size: 15px; font-weight: 500; cursor: pointer; font-family: inherit; transition: all .15s; display: block; text-align: center; }
.btn-secondary:hover { background: var(--sidebar-bg); border-color: var(--accent); }

@media (max-width: 900px) {
  .nav-links { display: none !important; }
  .nav-contact, .nav-cta { display: none !important; }
  .nav-mobile-toggle { display: flex !important; }
}

/* ─── DOCS SHELL (ported from v2 DocsLayout) ─── */
.docs-shell { display: flex; flex: 1; border-top: 1px solid var(--line); }

.sidebar { width: 280px; flex-shrink: 0; border-right: 1px solid var(--line); padding: 32px 24px; background: var(--sidebar-bg); overflow-y: auto; }
.sidebar-group { margin-bottom: 24px; }
.sidebar-label { font-size: 12px; text-transform: uppercase; color: var(--ink-faint); font-weight: 600; letter-spacing: 1px; margin-bottom: 12px; }
.sidebar-links { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.sidebar-link { font-size: 14px; color: var(--ink-muted); display: block; }
.sidebar-link:hover { color: var(--ink); }
.sidebar-link.active { color: var(--accent); font-weight: 500; }

.docs-content { flex: 1; min-width: 0; padding: 48px 64px; max-width: 800px; }

/* ─── PAGE TYPOGRAPHY (ported from v2 docs/page.tsx) ─── */
.eyebrow-pill { display: inline-flex; align-items: center; gap: 6px; color: var(--accent); font-size: 13px; font-weight: 600; margin-bottom: 12px; background: var(--accent-soft); padding: 4px 12px; border-radius: 16px; }

.docs-content h1 { font-size: 36px; font-weight: 700; color: var(--ink); margin: 0 0 24px; letter-spacing: -0.5px; line-height: 1.15; }
.docs-content .lead { font-size: 16px; color: var(--ink-muted); line-height: 1.7; margin: 0 0 24px; max-width: 640px; }
.docs-content h2 { font-size: 24px; font-weight: 600; color: var(--ink); margin: 40px 0 16px; }
.docs-content h3 { font-size: 18px; font-weight: 600; color: var(--ink); margin: 28px 0 12px; }
.docs-content h4 { font-size: 14px; font-weight: 600; color: var(--ink); margin: 22px 0 8px; }
.docs-content p { font-size: 16px; color: var(--ink-muted); line-height: 1.7; margin: 0 0 16px; }
.docs-content strong { color: var(--ink); }
.docs-content ul, .docs-content ol { color: var(--ink-muted); padding-left: 22px; margin: 0 0 16px; }
.docs-content li { margin-bottom: 6px; line-height: 1.6; }
.docs-content li code, .docs-content p code { font-size: 0.88em; }

.mono { font-family: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace; }

/* ─── API meta strip ─── */
.api-meta { display: flex; flex-wrap: wrap; gap: 10px 28px; background: var(--sidebar-bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; margin: 0 0 32px; font-size: 13px; }
.api-meta .item { display: flex; flex-direction: column; gap: 2px; }
.api-meta .item .k { color: var(--ink-faint); font-size: 11px; text-transform: uppercase; letter-spacing: .05em; }
.api-meta .item .v { color: var(--ink); font-weight: 600; font-family: "JetBrains Mono", monospace; font-size: 12.5px; }

/* ─── Callout (ported: grey block, blue left border) ─── */
.callout { background: var(--hover-bg); border-left: 4px solid var(--accent); padding: 16px 20px; border-radius: 4px; margin: 0 0 32px; }
.callout h4, .callout .label { font-size: 14px; font-weight: 600; color: var(--ink); margin: 0 0 4px; display: flex; align-items: center; gap: 6px; }
.callout p { font-size: 14px; color: var(--ink-faint); margin: 0; line-height: 1.6; }

/* ─── Code blocks ─── */
pre {
  position: relative;
  background: var(--code-bg);
  color: var(--code-ink);
  padding: 16px 18px;
  border-radius: var(--radius);
  font-size: 13px;
  overflow-x: auto;
  margin: 0 0 24px;
  line-height: 1.6;
}
pre code { background: none; padding: 0; color: inherit; font-size: inherit; }
code { background: var(--hover-bg); color: var(--accent-hover); padding: 2px 6px; border-radius: 4px; font-size: 0.87em; }

.copy-btn {
  position: absolute; top: 9px; right: 10px;
  font-family: 'Google Sans', Arial, sans-serif; font-size: 11px; font-weight: 500;
  color: #9aa0a6; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14);
  border-radius: 6px; padding: 4px 9px; cursor: pointer;
}
.copy-btn:hover { color: var(--code-ink); border-color: rgba(255,255,255,.28); }
.copy-btn.copied { color: #81c995; border-color: #81c995; }

/* ─── Endpoint tables ─── */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); margin: 0 0 24px; }
table.ep { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.ep th, table.ep td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.ep th { font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-faint); font-weight: 700; background: var(--sidebar-bg); }
table.ep tr:last-child td { border-bottom: none; }
table.ep td.mono { color: var(--ink); font-size: 12.5px; }

table.fields { width: 100%; border-collapse: collapse; font-size: 13px; margin: 8px 0 16px; }
table.fields th, table.fields td { text-align: left; padding: 7px 10px; border-bottom: 1px solid var(--line); }
table.fields th { font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-faint); font-weight: 700; }

.method { display: inline-block; font-family: "JetBrains Mono", monospace; font-weight: 700; font-size: 11px; letter-spacing: .02em; padding: 3px 8px; border-radius: 4px; }
.method.get { background: #e6f4ea; color: #137333; }
.method.post { background: var(--accent-soft); color: var(--accent); }
.method.put { background: #fef7e0; color: #b06000; }
.method.patch { background: #f3e8fd; color: #8430ce; }
.method.delete { background: #fce8e6; color: #c5221f; }

/* ─── Product comparison table ─── */
table.compare { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.compare th, table.compare td { text-align: left; padding: 11px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.compare th { font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-faint); font-weight: 700; background: var(--sidebar-bg); }
table.compare tr:last-child td { border-bottom: none; }
table.compare td.prod { font-weight: 700; color: var(--ink); }

/* ─── Next-page nav ─── */
.next-links { display: flex; gap: 16px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); }
.next-card { flex: 1; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; color: var(--ink); }
.next-card:hover { border-color: var(--accent); background: var(--sidebar-bg); }
.next-card .k { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-faint); margin-bottom: 4px; }
.next-card .t { font-weight: 700; font-size: 14.5px; color: var(--ink); }

footer.docs-footer { margin-top: 48px; padding-top: 20px; border-top: 1px solid var(--line); }
footer.docs-footer p { color: var(--ink-faint); font-size: 12.5px; margin: 0; }

@media (max-width: 980px) {
  .docs-shell { flex-direction: column; }
  .sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--line); }
  .docs-content { padding: 32px 24px; max-width: 100%; }
  .docs-content h1 { font-size: 28px; }
  .next-links { flex-direction: column; }
}
