/* Homepage + docs (/, /docs, /docs/admin). Uses the colour tokens and light/dark mode from style.css. */
body.site { display: block; place-items: normal; padding: 0; } /* style.css centers the upload card; not here */
/* Readable link/accent text on both themes (the button accent is too dark for text on the dark background). */
:root { --link: #4752c4; }
@media (prefers-color-scheme: dark) { :root { --link: #a5acff; } }
.site a:not(.btn):not(.brand) { color: var(--link); }
.site-nav a, .toc a, .site-foot a { color: var(--muted) !important; }
.site-wrap { max-width: 980px; margin: 0 auto; padding: 0 16px; }

/* ---- Header ---- */
.site-head { border-bottom: 1px solid var(--border); background: var(--card); position: sticky; top: 0; z-index: 5; }
.site-head .site-wrap { display: flex; align-items: center; gap: 14px; min-height: 56px; flex-wrap: wrap; }
.brand { font-weight: 800; font-size: 18px; color: var(--text); text-decoration: none; display: flex; align-items: center; gap: 8px; }
.brand-mark { width: 28px; height: 28px; display: block; }
.site-nav { display: flex; gap: 4px; margin-left: auto; flex-wrap: wrap; }
.site-nav a { color: var(--muted); text-decoration: none; font-size: 14px; padding: 6px 10px; border-radius: 6px; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--text) !important; background: var(--accent-soft); }

/* ---- Buttons ---- */
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }
a.btn { text-decoration: none; display: inline-flex; align-items: center; justify-content: center; }
.btn.big { padding: 12px 20px; font-size: 15px; }

/* ---- Hero ---- */
.hero { padding: 56px 0 36px; display: grid; grid-template-columns: 1.05fr 1fr; gap: 36px; align-items: center; }
.hero h1 { font-size: 40px; line-height: 1.1; margin: 0 0 14px; letter-spacing: -.02em; }
.hero h1 em { font-style: normal; background: linear-gradient(135deg, var(--accent), #eb459e); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 17px; color: var(--muted); margin: 0 0 22px; }
.hero .fine { font-size: 13px; color: var(--muted); margin-top: 12px; }
.counters { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 20px; }
.counters div { display: flex; flex-direction: column; }
.counters strong { font-size: 24px; line-height: 1.1; }
.counters span { font-size: 12px; color: var(--muted); }

/* ---- Sections ---- */
.section { padding: 36px 0; border-top: 1px solid var(--border); }
.section h2 { font-size: 26px; margin: 0 0 6px; letter-spacing: -.01em; }
.section .intro { color: var(--muted); margin: 0 0 22px; max-width: 680px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.tile { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 18px; }
.tile h3 { margin: 0 0 6px; font-size: 16px; }
.tile p { margin: 0; color: var(--muted); font-size: 14px; }
.tile .ico { font-size: 22px; margin-bottom: 8px; display: block; }
.steps { counter-reset: step; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.steps .tile { position: relative; padding-top: 44px; }
.steps .tile::before {
  counter-increment: step; content: counter(step); position: absolute; top: 14px; left: 18px; width: 24px; height: 24px;
  border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 700; color: #fff; background: var(--accent);
}
.soon { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; background: var(--accent-soft); color: var(--link); vertical-align: middle; margin-left: 6px; }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 14px; }
.plan { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 20px; }
.plan.pro { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
.plan h3 { margin: 0 0 4px; font-size: 18px; }
.plan .who { color: var(--muted); font-size: 13px; margin: 0 0 12px; }
.plan ul { margin: 0; padding-left: 18px; font-size: 14px; }
.plan li { margin: 5px 0; }

/* ---- Footer ---- */
.site-foot { border-top: 1px solid var(--border); padding: 22px 0 36px; color: var(--muted); font-size: 13px; }
.site-foot .site-wrap { display: flex; gap: 14px; flex-wrap: wrap; justify-content: space-between; }
.site-foot a { color: var(--muted); }

/* ---- Docs ---- */
.docs { display: grid; grid-template-columns: 210px 1fr; gap: 32px; padding-top: 32px; padding-bottom: 32px; }
.toc { position: sticky; top: 72px; align-self: start; font-size: 14px; }
.toc a { display: block; padding: 5px 8px; color: var(--muted); text-decoration: none; border-radius: 6px; }
.toc a:hover { color: var(--text) !important; background: var(--accent-soft); }
.toc .toc-title { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 0 8px 6px; }
.docbody { min-width: 0; line-height: 1.6; }
.docbody h1 { font-size: 30px; margin: 0 0 6px; }
.docbody > p.lead { color: var(--muted); font-size: 16px; margin: 0 0 18px; }
.docbody h2 { font-size: 21px; margin: 34px 0 8px; padding-top: 8px; scroll-margin-top: 70px; }
.docbody h3 { font-size: 16px; margin: 20px 0 6px; scroll-margin-top: 70px; }
.docbody p, .docbody li { font-size: 15px; }
.docbody ul, .docbody ol { padding-left: 22px; }
.docbody li { margin: 4px 0; }
.docbody a { color: var(--link); }
.docbody code { font-size: 13px; padding: 1px 6px; border-radius: 4px; background: var(--accent-soft); }
.docbody table { width: 100%; border-collapse: collapse; font-size: 14px; margin: 10px 0; display: block; overflow-x: auto; }
.docbody th, .docbody td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.docbody th { color: var(--muted); font-weight: 600; }
.callout { border-left: 3px solid var(--accent); background: var(--accent-soft); border-radius: 6px; padding: 10px 14px; margin: 14px 0; font-size: 14px; }
.figure { margin: 16px 0; }
.figure figcaption { color: var(--muted); font-size: 13px; margin-top: 6px; }

/* ---- Discord mock-ups (drawn with HTML so they stay sharp in light and dark mode) ---- */
.dc { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 16px; font-size: 14px; box-shadow: 0 8px 30px rgba(0, 0, 0, .12); }
.dc-msg { display: grid; grid-template-columns: 40px 1fr; gap: 12px; }
.dc-ava { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; }
.dc-ava.shrinky { overflow: hidden; }
.dc-ava.shrinky img { width: 100%; height: 100%; display: block; }
.dc-ava.user { background: #3ba55c; }
.dc-name { font-weight: 600; }
.dc-tag { font-size: 10px; font-weight: 700; background: var(--accent); color: #fff; border-radius: 3px; padding: 1px 4px; margin-left: 4px; vertical-align: 1px; }
.dc-time { color: var(--muted); font-size: 12px; margin-left: 6px; }
.dc-mention { color: #4752c4; background: rgba(88, 101, 242, .15); border-radius: 3px; padding: 0 2px; font-weight: 500; }
@media (prefers-color-scheme: dark) { .dc-mention { color: #c9cdfb; background: rgba(88, 101, 242, .3); } }
.dc-sub { color: var(--muted); font-size: 12px; margin-top: 2px; }
.dc-pro { font-weight: 700; color: var(--accent); }
.dc-video {
  margin-top: 8px; border-radius: 8px; aspect-ratio: 16 / 9; max-width: 340px; position: relative; overflow: hidden;
  background: linear-gradient(135deg, #2b3a67 0%, #6b3f8f 55%, #e9658b 100%);
}
.dc-video::after { content: "▶"; position: absolute; inset: 0; display: grid; place-items: center; color: #fff; font-size: 30px; text-shadow: 0 2px 10px rgba(0,0,0,.4); }
.dc-video .dc-cap { position: absolute; left: 0; right: 0; top: 10%; text-align: center; color: #fff; font-weight: 800; font-size: 16px; text-shadow: 0 0 3px #000, 0 0 3px #000, 0 0 3px #000; }
.dc-reply { color: var(--muted); font-size: 12px; margin: 0 0 4px 52px; display: flex; gap: 6px; align-items: center; }
.dc-reply::before { content: ""; width: 26px; height: 10px; border-left: 2px solid var(--border); border-top: 2px solid var(--border); border-top-left-radius: 6px; margin-left: -32px; margin-top: 8px; }
.dc-ephemeral { margin-top: 10px; font-size: 12px; color: var(--muted); }
.dc-menu { width: 230px; background: var(--card); border: 1px solid var(--border); border-radius: 8px; padding: 6px; box-shadow: 0 8px 30px rgba(0,0,0,.18); font-size: 14px; }
.dc-menu div { padding: 7px 10px; border-radius: 4px; }
.dc-menu .on { background: var(--accent); color: #fff; }
.dc-menu .sep { height: 1px; padding: 0; margin: 4px 6px; background: var(--border); }
.dc-menu .dim { color: var(--muted); font-size: 12px; }
.dc-row { display: flex; gap: 16px; flex-wrap: wrap; align-items: flex-start; }
.dc-cmd { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; background: var(--accent-soft); border-radius: 6px; padding: 8px 12px; display: inline-block; margin-bottom: 10px; }

@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; padding-top: 32px; }
  .hero h1 { font-size: 32px; }
  .docs { grid-template-columns: 1fr; }
  .toc { position: static; display: flex; flex-wrap: wrap; gap: 2px; }
  .toc .toc-title { width: 100%; }
}
