/* ============================================================
   Guild Save · content pages (docs, guides, security, changelog, legal)
   Loads after /css/home.css. Side nav left, reading column right, no divider lines.
   ============================================================ */

.p-page { min-height: 100vh; display: flex; flex-direction: column; }
.p-page .v3-head { background: rgba(7,8,10,.78); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }

.p-main {
  flex: 1;
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(32px, 6vw, 88px);
  padding-top: clamp(40px, 6vw, 72px);
  padding-bottom: 96px;
}

/* Side nav */
.p-side nav { position: sticky; top: 100px; display: grid; gap: 2px; }
.p-side-label {
  margin: 22px 0 8px;
  font: 600 10.5px/1 var(--f-mono); letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--dim);
}
.p-side-label:first-child { margin-top: 0; }
.p-side a {
  padding: 8px 12px; border-radius: 4px;
  font-size: 14px; color: var(--muted);
  transition: color .15s, background .15s;
}
.p-side a:hover { color: var(--fg); background: rgba(255,255,255,.035); }
.p-side a.is-on { color: var(--fg); background: rgba(255,255,255,.06); }

@media (max-width: 900px) {
  .p-main { grid-template-columns: 1fr; gap: 28px; }
  .p-side nav { position: static; display: flex; flex-wrap: wrap; gap: 4px; }
  .p-side-label { display: none; }
  .p-side a { background: rgba(255,255,255,.03); }
}

/* Reading column */
.p-doc { max-width: 760px; color: var(--fg-2); font-size: 16px; line-height: 1.7; }
.p-doc > div > * + * { margin-top: 16px; }
.p-doc h1 {
  font: 800 clamp(34px, 4.6vw, 56px)/1.02 var(--f-sans);
  letter-spacing: -0.045em;
  color: var(--fg);
  margin-bottom: 18px;
}
.p-doc .p-lead { font-size: 18px; color: var(--fg-2); max-width: 60ch; }
.p-doc .p-meta { font: 500 12.5px/1 var(--f-mono); color: var(--muted); }
.p-doc h2 {
  margin-top: 48px !important;
  font: 700 clamp(22px, 2.4vw, 28px)/1.2 var(--f-sans);
  letter-spacing: -0.025em;
  color: var(--fg);
}
.p-doc h3 { margin-top: 28px !important; font: 700 17px/1.3 var(--f-sans); color: var(--fg); }
.p-doc a:not(.v3-btn) { color: var(--fg); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line-2); }
.p-doc a:not(.v3-btn):hover { text-decoration-color: var(--fg); }
.p-doc strong, .p-doc b { color: var(--fg); font-weight: 600; }
.p-doc ul, .p-doc ol { padding-left: 22px; display: grid; gap: 8px; }
.p-doc ul { list-style: none; padding-left: 0; }
.p-doc ul > li { position: relative; padding-left: 22px; }
.p-doc ul > li::before { content: ""; position: absolute; left: 4px; top: .72em; width: 6px; height: 6px; border-radius: 2px; background: var(--muted); }
.p-doc ol { list-style: decimal; }
.p-doc ol > li::marker { color: var(--muted); font: 600 14px var(--f-mono); }
.p-doc code {
  padding: 2px 7px; border-radius: 3px;
  background: rgba(255,255,255,.06); color: var(--fg);
  font: 500 .88em/1.4 var(--f-mono);
  white-space: nowrap;
}
.p-doc pre {
  padding: 16px 20px; border-radius: 6px;
  background: rgba(255,255,255,.035);
  font: 500 14px/1.6 var(--f-mono); color: var(--fg);
  overflow-x: auto;
}
.p-doc pre code { padding: 0; background: none; white-space: pre; }

/* Callouts: a faint tinted surface, no frame */
.p-note, .p-warn {
  padding: 16px 20px; border-radius: 6px;
  background: rgba(255,255,255,.035);
}
.p-warn { background: linear-gradient(90deg, rgba(232,165,107,.10), rgba(232,165,107,.03)); }
.p-note b:first-child, .p-warn b:first-child { margin-right: 6px; }

/* Tables: rows on faint stripes instead of lines */
.p-doc table { width: 100%; border-collapse: separate; border-spacing: 0 4px; font-size: 14.5px; }
.p-doc th { text-align: left; padding: 0 14px 6px; font: 600 10.5px/1 var(--f-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--dim); }
.p-doc td { padding: 12px 14px; background: rgba(255,255,255,.03); vertical-align: top; }
.p-doc td:first-child { border-radius: 4px 0 0 4px; white-space: nowrap; }
.p-doc td:last-child { border-radius: 0 4px 4px 0; }
@media (max-width: 640px) {
  .p-doc table, .p-doc tbody, .p-doc tr, .p-doc td { display: block; }
  .p-doc thead { display: none; }
  .p-doc tr { margin-bottom: 8px; border-radius: 4px; overflow: hidden; }
  .p-doc td { border-radius: 0 !important; }
  /* Let long inline code (paths, commands) wrap instead of pushing the line off-screen */
  .p-doc code { white-space: normal; overflow-wrap: anywhere; }
  .p-doc td:first-child { white-space: normal; }
}

/* Changelog entries */
.p-release { padding: 22px 24px; border-radius: 8px; background: rgba(255,255,255,.025); }
.p-release h2 { margin-top: 0 !important; }
.p-tag { display: inline-block; margin-left: 10px; padding: 4px 8px; border-radius: 3px; background: rgba(78,201,160,.12); color: var(--ok); font: 700 10.5px/1 var(--f-mono); letter-spacing: .14em; text-transform: uppercase; vertical-align: middle; }

/* Operator details missing in .env */
.p-missing { padding: 2px 8px; border-radius: 3px; background: rgba(232,165,107,.14); color: var(--hit); font: 600 12.5px/1.6 var(--f-mono); }

.p-fallback { margin-bottom: 24px; padding: 12px 16px; border-radius: 6px; background: rgba(255,255,255,.04); font-size: 14px; color: var(--muted); }

/* Footer: one quiet line */
.p-foot { padding-block: 24px 28px; }
.p-foot .v3-wrap { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; font: 500 12px/1.4 var(--f-mono); color: var(--muted); }
.p-foot nav { display: flex; gap: 22px; flex-wrap: wrap; }
.p-foot a:hover { color: var(--fg); }
