/* Linen website. One stylesheet for every page. */

:root {
  color-scheme: dark;
  --bg: #0a0a0c;
  --bg-2: #101013;
  --bg-3: #16161a;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);
  --text: #ededf0;
  --muted: #a1a1aa;
  --faint: #71717a;
  --red: #e3132b;
  --red-2: #ff4157;
  --red-soft: rgba(227, 19, 43, 0.14);
  --green: #3ba55d;
  --amber: #f0b232;
  --blue: #5865f2;
  /* Discord's own colors, for the chat mockups */
  --dc-bg: #313338;
  --dc-embed: #2b2d31;
  --dc-text: #dbdee1;
  --dc-muted: #949ba4;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.8);
  --display: "Bricolage Grotesque", "Inter", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  --max: 1180px;
  --nav-h: 68px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.6 var(--body); -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
code, kbd { font-family: var(--mono); }
::selection { background: rgba(227, 19, 43, 0.4); color: #fff; }
:focus-visible { outline: 2px solid var(--red-2); outline-offset: 3px; border-radius: 6px; }

/* Page background: a red glow at the top, a fading dot grid, and grain */
.backdrop { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.backdrop::before {
  content: ""; position: absolute; left: 50%; top: -420px; width: 1400px; height: 900px; transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(227, 19, 43, 0.22), transparent 70%);
}
.backdrop::after {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 20%, transparent 75%);
}
.grain {
  position: fixed; inset: 0; z-index: 100; pointer-events: none; opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }
@media (max-width: 640px) { .container { padding: 0 16px; } }

/* Navigation */
.nav {
  position: sticky; top: 0; z-index: 50; height: var(--nav-h);
  background: rgba(10, 10, 12, 0.72); backdrop-filter: blur(16px) saturate(160%); -webkit-backdrop-filter: blur(16px) saturate(160%);
  border-bottom: 1px solid transparent; transition: border-color 0.3s, background 0.3s;
}
.nav.scrolled { border-bottom-color: var(--line); }
.nav .container { height: 100%; display: flex; align-items: center; gap: 32px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 700; font-size: 20px; letter-spacing: -0.02em; }
.brand img { width: 32px; height: 32px; border-radius: 9px; }
.nav-links { display: flex; gap: 4px; }
.nav-links a { padding: 8px 14px; border-radius: 10px; color: var(--muted); font-size: 15px; transition: color 0.2s, background 0.2s; }
.nav-links a:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); }
.nav-links a.active { color: var(--text); }
.nav-cta { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.menu-btn { display: none; width: 42px; height: 42px; border-radius: 10px; border: 1px solid var(--line); background: none; cursor: pointer; place-items: center; }
.menu-btn span, .menu-btn span::before, .menu-btn span::after { display: block; width: 18px; height: 2px; background: var(--text); border-radius: 2px; position: relative; transition: 0.25s; }
.menu-btn span::before, .menu-btn span::after { content: ""; position: absolute; left: 0; }
.menu-btn span::before { top: -6px; } .menu-btn span::after { top: 6px; }
.nav.open .menu-btn span { background: transparent; }
.nav.open .menu-btn span::before { top: 0; transform: rotate(45deg); }
.nav.open .menu-btn span::after { top: 0; transform: rotate(-45deg); }
@media (max-width: 860px) {
  .menu-btn { display: grid; }
  .nav-cta .btn { display: none; }
  .nav-links {
    position: fixed; top: var(--nav-h); left: 0; right: 0; flex-direction: column; gap: 0; padding: 12px 16px 20px;
    background: rgba(10, 10, 12, 0.97); border-bottom: 1px solid var(--line);
    transform: translateY(-8px); opacity: 0; visibility: hidden; transition: 0.25s;
  }
  .nav-links a { padding: 14px 12px; font-size: 17px; }
  .nav.open .nav-links { transform: none; opacity: 1; visibility: visible; }
  .nav-links .mobile-only { display: block; }
}
.mobile-only { display: none; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 20px;
  border-radius: 12px; border: 1px solid var(--line-2); background: rgba(255, 255, 255, 0.04);
  font-weight: 600; font-size: 15px; cursor: pointer; white-space: nowrap;
  transition: transform 0.15s, background 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.btn:hover { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.22); }
.btn:active { transform: translateY(1px); }
.btn.primary {
  background: linear-gradient(180deg, #f0283f, var(--red)); border-color: rgba(255, 255, 255, 0.18); color: #fff;
  box-shadow: 0 0 0 1px rgba(227, 19, 43, 0.4), 0 10px 30px -8px rgba(227, 19, 43, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.btn.primary:hover { box-shadow: 0 0 0 1px rgba(227, 19, 43, 0.6), 0 14px 38px -8px rgba(227, 19, 43, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.25); }
.btn.sm { height: 38px; padding: 0 14px; font-size: 14px; border-radius: 10px; }
.btn.lg { height: 52px; padding: 0 26px; font-size: 16px; border-radius: 14px; }
.btn svg { width: 18px; height: 18px; flex: none; }

/* Type */
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 8px; border-radius: 999px;
  border: 1px solid var(--line-2); background: rgba(255, 255, 255, 0.03); color: var(--muted); font-size: 13px; font-weight: 500;
}
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 4px var(--red-soft); }
h1, h2, h3 { font-family: var(--display); letter-spacing: -0.03em; line-height: 1.08; margin: 0; }
h1 { font-size: clamp(42px, 6.4vw, 78px); font-weight: 700; }
h2 { font-size: clamp(32px, 4.2vw, 50px); font-weight: 700; }
h3 { font-size: 21px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.25; }
.lead { font-size: clamp(17px, 1.6vw, 20px); color: var(--muted); line-height: 1.6; }
.accent {
  background: linear-gradient(100deg, #ff6b7d, var(--red) 45%, #ff8a3d);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.muted { color: var(--muted); }
.section { padding: 112px 0; position: relative; }
.section.tight { padding: 80px 0; }
.section-head { max-width: 680px; margin-bottom: 56px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head .kicker { color: var(--red-2); font-weight: 600; font-size: 14px; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 14px; display: block; }
.section-head p { margin: 18px 0 0; }
@media (max-width: 640px) { .section { padding: 80px 0; } .section-head { margin-bottom: 40px; } }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: 0.08s; } .reveal[data-delay="2"] { transition-delay: 0.16s; }
.reveal[data-delay="3"] { transition-delay: 0.24s; } .reveal[data-delay="4"] { transition-delay: 0.32s; }

/* Cards with a light that follows the mouse */
.card {
  position: relative; border-radius: var(--radius-lg); border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.015)); overflow: hidden;
}
.card.glow::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.3s;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(227, 19, 43, 0.12), transparent 40%);
}
.card.glow:hover::before { opacity: 1; }
.card.glow:hover { border-color: var(--line-2); }

/* Hero */
.hero { padding: 72px 0 96px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.hero h1 { margin: 22px 0 22px; }
.hero .lead { max-width: 540px; margin: 0 0 34px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-note { margin-top: 22px; display: flex; gap: 18px; flex-wrap: wrap; color: var(--faint); font-size: 14px; }
.hero-note span { display: inline-flex; align-items: center; gap: 6px; }
.hero-note svg { width: 16px; height: 16px; color: var(--green); }
@media (max-width: 980px) { .hero-grid { grid-template-columns: 1fr; gap: 48px; } .hero { padding-top: 48px; } }

/* Discord window mockup */
.discord {
  border-radius: 18px; background: var(--dc-bg); border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 40px 90px -30px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(0, 0, 0, 0.4), 0 0 120px -40px rgba(227, 19, 43, 0.35);
  overflow: hidden; font-size: 15px; color: var(--dc-text);
}
.discord-top { height: 46px; display: flex; align-items: center; gap: 8px; padding: 0 16px; background: #2b2d31; border-bottom: 1px solid rgba(0, 0, 0, 0.25); }
.discord-top .lights { display: flex; gap: 6px; margin-right: 8px; }
.discord-top .lights i { width: 11px; height: 11px; border-radius: 50%; background: #4e5058; }
.discord-top .channel { font-weight: 600; color: #f2f3f5; display: flex; align-items: center; gap: 6px; }
.discord-top .channel b { color: var(--dc-muted); font-weight: 500; font-size: 20px; line-height: 1; }
.discord-body { height: 440px; padding: 16px 0 8px; display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden; }
.discord-input { margin: 0 16px 16px; height: 44px; border-radius: 10px; background: #383a40; display: flex; align-items: center; padding: 0 16px; color: var(--dc-muted); font-size: 15px; }
.discord-input .typed { color: var(--dc-text); }
.discord-input .caret { display: inline-block; width: 1px; height: 18px; background: var(--dc-text); margin-left: 1px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.msg { display: flex; gap: 14px; padding: 6px 16px; animation: msg-in 0.35s cubic-bezier(0.2, 0.8, 0.2, 1); }
@keyframes msg-in { from { opacity: 0; transform: translateY(8px); } }
.msg .av { width: 40px; height: 40px; border-radius: 50%; flex: none; background: #5865f2; display: grid; place-items: center; font-weight: 700; color: #fff; overflow: hidden; }
.msg .av img { width: 100%; height: 100%; object-fit: cover; }
.msg .meta { display: flex; align-items: center; gap: 6px; line-height: 1.3; }
.msg .name { font-weight: 600; color: #f2f3f5; }
.msg .app { font-size: 10px; font-weight: 600; background: #5865f2; color: #fff; padding: 1px 5px; border-radius: 4px; }
.msg .time { font-size: 12px; color: var(--dc-muted); }
.msg .text { margin-top: 2px; }
.msg .text code { font-size: 13px; background: #2b2d31; padding: 2px 4px; border-radius: 4px; }
.mention { background: rgba(88, 101, 242, 0.3); color: #c9cdfb; border-radius: 3px; padding: 0 2px; font-weight: 500; }

.embed {
  margin-top: 6px; max-width: 440px; border-radius: 6px; background: var(--dc-embed); border-left: 4px solid #4e5058;
  padding: 10px 14px 12px; font-size: 14px; line-height: 1.45;
}
.embed.red { border-left-color: var(--red); } .embed.green { border-left-color: #57a773; } .embed.amber { border-left-color: #d9a548; }
.embed .e-title { font-weight: 700; color: #f2f3f5; margin-bottom: 4px; font-size: 15px; }
.embed .e-fields { display: grid; grid-template-columns: repeat(3, auto); gap: 8px 18px; margin-top: 10px; justify-content: start; }
.embed .e-fields div b { display: block; color: #f2f3f5; font-size: 13px; }
.embed .e-fields div span { color: var(--dc-text); font-size: 13px; }
.embed .e-fine { margin-top: 8px; font-size: 12px; color: var(--dc-muted); }
.embed .e-banner { margin: -10px -14px 10px; height: 64px; background: url("../img/linen-banner.png") center / cover; border-radius: 0 6px 0 0; }
.dc-buttons { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.dc-btn { height: 32px; padding: 0 14px; border-radius: 8px; background: #4e5058; color: #fff; font-size: 14px; font-weight: 500; display: inline-flex; align-items: center; }
.dc-btn.red { background: #da373c; } .dc-btn.green { background: #248046; } .dc-btn.blue { background: #5865f2; }
.dc-select { margin-top: 8px; height: 40px; border-radius: 8px; background: #1e1f22; border: 1px solid rgba(0, 0, 0, 0.3); display: flex; align-items: center; justify-content: space-between; padding: 0 12px; color: var(--dc-muted); font-size: 14px; max-width: 440px; }
.lyric-now { font-size: 18px; font-weight: 700; color: #f2f3f5; margin: 2px 0; }
.lyric-side { font-size: 12px; color: var(--dc-muted); }
.bar { height: 4px; border-radius: 4px; background: #4e5058; margin: 10px 0 4px; overflow: hidden; }
.bar i { display: block; height: 100%; width: 38%; background: var(--red); border-radius: 4px; animation: play 12s linear infinite; }
@keyframes play { from { width: 12%; } to { width: 92%; } }

/* Stats strip */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); border-radius: var(--radius-lg); background: rgba(255, 255, 255, 0.02); }
.stat { padding: 28px 28px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; }
.stat .num { font-family: var(--display); font-size: 44px; font-weight: 700; letter-spacing: -0.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.stat .num small { font-size: 26px; color: var(--red-2); }
.stat .label { color: var(--muted); margin-top: 8px; font-size: 15px; }
@media (max-width: 860px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* Bot family */
.family { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.bot-card { padding: 30px; display: flex; flex-direction: column; }
.bot-card .icon { width: 60px; height: 60px; border-radius: 16px; margin-bottom: 22px; box-shadow: 0 12px 30px -10px rgba(227, 19, 43, 0.7); }
.bot-card h3 { display: flex; align-items: center; gap: 10px; }
.bot-card .tag { font-family: var(--body); font-size: 12px; font-weight: 600; letter-spacing: 0; color: var(--muted); border: 1px solid var(--line-2); border-radius: 999px; padding: 2px 9px; }
.bot-card p { color: var(--muted); margin: 10px 0 20px; }
.ticks { list-style: none; margin: 0 0 28px; padding: 0; display: grid; gap: 10px; font-size: 15px; }
.ticks li { display: flex; gap: 10px; align-items: flex-start; }
.ticks li::before {
  content: ""; flex: none; width: 18px; height: 18px; margin-top: 3px; border-radius: 50%;
  background: var(--red-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ff4157' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 11px no-repeat;
}
.bot-card .actions { margin-top: auto; display: flex; gap: 10px; flex-wrap: wrap; }
@media (max-width: 980px) { .family { grid-template-columns: 1fr; max-width: 560px; margin: 0 auto; } }

/* Feature tabs */
.tabs { display: flex; gap: 6px; padding: 6px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255, 255, 255, 0.02); width: max-content; max-width: 100%; overflow-x: auto; margin: 0 auto 40px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { height: 40px; padding: 0 16px; border-radius: 11px; border: 0; background: none; color: var(--muted); font-weight: 500; cursor: pointer; white-space: nowrap; transition: color 0.2s, background 0.2s; }
.tab:hover { color: var(--text); }
.tab[aria-selected="true"] { background: rgba(255, 255, 255, 0.08); color: var(--text); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06); }
.tab-panel { display: grid; grid-template-columns: 1fr 1.05fr; gap: 48px; align-items: center; padding: 44px; }
.tab-panel[hidden] { display: none; }
.tab-panel.show { animation: fade 0.45s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } }
.tab-panel h3 { font-size: 30px; margin-bottom: 14px; }
.tab-panel > div > p { color: var(--muted); margin: 0 0 24px; }
.tab-panel .chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.chip { font-family: var(--mono); font-size: 13px; padding: 5px 10px; border-radius: 8px; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); color: #d4d4d8; }
.tab-panel .discord-body { height: auto; padding: 16px 0; }
@media (max-width: 900px) { .tab-panel { grid-template-columns: 1fr; padding: 28px 22px; gap: 32px; } }

/* Small feature grid */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature { padding: 28px; }
.feature .ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--red-soft); color: var(--red-2); margin-bottom: 18px; border: 1px solid rgba(227, 19, 43, 0.25); }
.feature .ico svg { width: 22px; height: 22px; }
.feature p { color: var(--muted); margin: 10px 0 0; font-size: 15px; }
.feature code { font-size: 13px; color: #e4e4e7; background: rgba(255, 255, 255, 0.06); padding: 1px 6px; border-radius: 6px; }
@media (max-width: 980px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-3 { grid-template-columns: 1fr; } }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; counter-reset: step; }
.step { padding: 30px; }
.step .n { font-family: var(--display); font-size: 15px; font-weight: 700; width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: #fff; color: var(--bg); margin-bottom: 20px; }
.step p { color: var(--muted); margin: 10px 0 0; font-size: 15px; }
.step code { font-size: 13px; color: #e4e4e7; background: rgba(255, 255, 255, 0.06); padding: 1px 6px; border-radius: 6px; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; } }

/* FAQ */
.faq { max-width: 780px; margin: 0 auto; display: grid; gap: 12px; }
.faq details { border: 1px solid var(--line); border-radius: 16px; background: rgba(255, 255, 255, 0.02); transition: border-color 0.2s, background 0.2s; }
.faq details[open] { border-color: var(--line-2); background: rgba(255, 255, 255, 0.035); }
.faq summary { list-style: none; cursor: pointer; padding: 20px 24px; font-weight: 600; font-size: 17px; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 12px; height: 12px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg) translate(-3px, -3px); transition: transform 0.25s; }
.faq details[open] summary::after { transform: rotate(225deg) translate(-3px, -3px); }
.faq .answer { padding: 0 24px 22px; color: var(--muted); }
.faq .answer code { font-size: 13px; color: #e4e4e7; background: rgba(255, 255, 255, 0.06); padding: 1px 6px; border-radius: 6px; }

/* Call to action band */
.cta {
  position: relative; overflow: hidden; border-radius: 28px; padding: 72px 48px; text-align: center;
  background: radial-gradient(600px 300px at 50% 0%, rgba(255, 255, 255, 0.18), transparent 70%), linear-gradient(160deg, #f0283f, #b80d20 60%, #7d0815);
  box-shadow: 0 40px 100px -40px rgba(227, 19, 43, 0.8);
}
.cta::before {
  content: ""; position: absolute; inset: 0; opacity: 0.25;
  background-image: radial-gradient(rgba(255, 255, 255, 0.5) 1px, transparent 1px); background-size: 22px 22px;
  mask-image: radial-gradient(ellipse at center, #000, transparent 75%); -webkit-mask-image: radial-gradient(ellipse at center, #000, transparent 75%);
}
.cta > * { position: relative; }
.cta h2 { color: #fff; }
.cta p { color: rgba(255, 255, 255, 0.85); font-size: 19px; margin: 16px auto 32px; max-width: 560px; }
.cta .btn { background: #fff; color: #b80d20; border-color: #fff; }
.cta .btn:hover { background: #ffe9ec; }
.cta .btn.ghost { background: rgba(0, 0, 0, 0.18); color: #fff; border-color: rgba(255, 255, 255, 0.35); }
.cta .btn.ghost:hover { background: rgba(0, 0, 0, 0.28); }
.cta .stamp { width: 84px; height: 84px; border-radius: 22px; margin: 0 auto 26px; box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.14), 0 20px 40px -10px rgba(0, 0, 0, 0.5); transform: rotate(-6deg); }
@media (max-width: 640px) { .cta { padding: 56px 22px; border-radius: 22px; } }

/* Footer */
.footer { border-top: 1px solid var(--line); padding: 56px 0 40px; margin-top: 40px; color: var(--muted); font-size: 15px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 32px; }
.footer h4 { color: var(--text); font-size: 14px; margin: 0 0 14px; font-weight: 600; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer a:hover { color: var(--text); }
.footer .tagline { margin: 14px 0 0; max-width: 320px; }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); color: var(--faint); font-size: 14px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-grid > :first-child { grid-column: 1 / -1; } }

/* Invite picker (a small dialog) */
.modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 16px; background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); opacity: 0; visibility: hidden; transition: 0.25s; }
.modal.open { opacity: 1; visibility: visible; }
.modal-box { width: 100%; max-width: 460px; border-radius: 22px; border: 1px solid var(--line-2); background: #121215; box-shadow: var(--shadow); padding: 26px; transform: translateY(10px) scale(0.98); transition: 0.25s; }
.modal.open .modal-box { transform: none; }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.modal-head h3 { font-size: 22px; }
.modal-close { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: none; cursor: pointer; color: var(--muted); font-size: 20px; line-height: 1; }
.modal-close:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); }
.modal p { color: var(--muted); margin: 0 0 18px; font-size: 15px; }
.invite-list { display: grid; gap: 10px; }
.invite-row { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.02); transition: border-color 0.2s, background 0.2s, transform 0.15s; }
.invite-row:hover { border-color: rgba(227, 19, 43, 0.45); background: var(--red-soft); transform: translateX(2px); }
.invite-row img { width: 40px; height: 40px; border-radius: 11px; }
.invite-row b { display: block; font-weight: 600; }
.invite-row small { color: var(--muted); font-size: 13px; }
.invite-row .go { margin-left: auto; color: var(--faint); }

/* Page header for inner pages */
.page-head { padding: 80px 0 48px; text-align: center; }
.page-head h1 { font-size: clamp(40px, 5.5vw, 66px); margin: 20px auto 18px; max-width: 900px; }
.page-head .lead { max-width: 640px; margin: 0 auto; }

/* About page */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split .prose p { color: var(--muted); font-size: 17px; margin: 0 0 18px; }
.split .prose p strong { color: var(--text); font-weight: 600; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; gap: 40px; } }
.orbit { position: relative; aspect-ratio: 1; max-width: 460px; margin: 0 auto; width: 100%; }
.orbit .ring { position: absolute; inset: 0; border-radius: 50%; border: 1px dashed rgba(255, 255, 255, 0.12); animation: spin 60s linear infinite; }
.orbit .ring.r2 { inset: 17%; animation-duration: 40s; animation-direction: reverse; }
.orbit .core { position: absolute; inset: 34%; border-radius: 28%; background: url("../img/linen-icon.png") center / cover; box-shadow: 0 0 0 10px rgba(227, 19, 43, 0.12), 0 30px 80px -10px rgba(227, 19, 43, 0.7); transform: rotate(-6deg); }
.orbit .sat { position: absolute; width: 22%; aspect-ratio: 1; border-radius: 26%; background-size: cover; background-position: center; box-shadow: 0 16px 40px -10px rgba(0, 0, 0, 0.8); border: 3px solid var(--bg); }
.orbit .sat.vc { top: 2%; left: 39%; background-image: url("../img/vc-icon.png"); }
.orbit .sat.music { bottom: 12%; left: 4%; background-image: url("../img/music-icon.png"); }
.orbit .sat.music2 { bottom: 12%; right: 4%; background-image: url("../img/music-icon.png"); }
.orbit .label { position: absolute; font-size: 13px; color: var(--muted); white-space: nowrap; transform: translateX(-50%); }
@keyframes spin { to { transform: rotate(1turn); } }

.timeline { position: relative; max-width: 780px; margin: 0 auto; display: grid; gap: 18px; }
.timeline::before { content: ""; position: absolute; left: 19px; top: 8px; bottom: 8px; width: 2px; background: linear-gradient(var(--red), rgba(227, 19, 43, 0.05)); }
.t-item { position: relative; padding-left: 60px; }
.t-item .mark { position: absolute; left: 6px; top: 22px; width: 28px; height: 28px; border-radius: 50%; background: var(--bg); border: 2px solid var(--red); display: grid; place-items: center; }
.t-item .mark::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--red); }
.t-item.next .mark { border-color: var(--faint); } .t-item.next .mark::after { background: var(--faint); }
.t-item .card { padding: 22px 24px; }
.t-item .phase { font-size: 13px; font-weight: 600; color: var(--red-2); letter-spacing: 0.06em; text-transform: uppercase; }
.t-item.next .phase { color: var(--faint); }
.t-item h3 { margin: 6px 0 8px; }
.t-item p { color: var(--muted); margin: 0; font-size: 15px; }

/* Docs */
.docs { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 48px; padding-top: 32px; padding-bottom: 80px; }
.sidebar { position: sticky; top: calc(var(--nav-h) + 24px); align-self: start; max-height: calc(100vh - var(--nav-h) - 48px); overflow-y: auto; padding-right: 8px; scrollbar-width: thin; scrollbar-color: #2a2a30 transparent; }
.search-btn { width: 100%; height: 42px; display: flex; align-items: center; gap: 10px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.03); color: var(--faint); cursor: pointer; font-size: 14px; margin-bottom: 24px; transition: border-color 0.2s; }
.search-btn:hover { border-color: var(--line-2); color: var(--muted); }
.search-btn svg { width: 16px; height: 16px; }
.search-btn kbd { margin-left: auto; font-size: 11px; padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line-2); color: var(--muted); }
.side-group { margin-bottom: 22px; }
.side-title { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--text); margin: 0 0 8px; }
.side-title img { width: 20px; height: 20px; border-radius: 6px; }
.side-group a { display: block; padding: 6px 12px; margin-left: 2px; border-left: 1px solid var(--line); color: var(--muted); font-size: 14px; transition: color 0.15s, border-color 0.15s; }
.side-group a:hover { color: var(--text); }
.side-group a.active { color: var(--text); border-left-color: var(--red); font-weight: 500; }
.side-toggle { display: none; }
@media (max-width: 960px) {
  .docs { grid-template-columns: 1fr; gap: 0; padding-top: 16px; }
  .side-toggle { display: flex; width: 100%; align-items: center; justify-content: space-between; height: 46px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.03); cursor: pointer; font-weight: 500; margin-bottom: 12px; position: sticky; top: calc(var(--nav-h) + 8px); z-index: 20; backdrop-filter: blur(12px); }
  .sidebar { position: static; max-height: none; display: none; padding: 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--bg-2); margin-bottom: 24px; }
  .sidebar.open { display: block; position: fixed; top: calc(var(--nav-h) + 62px); left: 16px; right: 16px; z-index: 30; max-height: calc(100vh - var(--nav-h) - 80px); max-height: calc(100dvh - var(--nav-h) - 80px); overflow-y: auto; box-shadow: var(--shadow); }
}

.doc { max-width: 820px; }
.doc section { padding-top: 8px; margin-bottom: 72px; }
.doc .doc-hero { display: flex; align-items: center; gap: 18px; margin-bottom: 18px; }
.doc .doc-hero img { width: 56px; height: 56px; border-radius: 15px; box-shadow: 0 10px 30px -10px rgba(227, 19, 43, 0.7); }
.doc h2 { font-size: clamp(30px, 3.6vw, 40px); }
.doc h3 { font-size: 22px; margin: 40px 0 12px; }
.doc p, .doc li { color: #c4c4cc; font-size: 16px; }
.doc p { margin: 0 0 16px; }
.doc ul, .doc ol { padding-left: 22px; margin: 0 0 18px; }
.doc li { margin-bottom: 8px; }
.doc li::marker { color: var(--faint); }
.doc strong { color: var(--text); font-weight: 600; }
.doc a.link { color: var(--red-2); border-bottom: 1px solid rgba(255, 65, 87, 0.35); }
.doc a.link:hover { border-bottom-color: var(--red-2); }
.doc :not(pre) > code { font-size: 0.86em; color: #f4f4f5; background: rgba(255, 255, 255, 0.07); border: 1px solid var(--line); padding: 1px 6px; border-radius: 6px; white-space: nowrap; }
.doc .intro { font-size: 18px; color: var(--muted); }
.callout { display: flex; gap: 14px; padding: 16px 18px; border-radius: 14px; border: 1px solid rgba(227, 19, 43, 0.3); background: rgba(227, 19, 43, 0.07); margin: 0 0 20px; }
.callout.info { border-color: rgba(88, 101, 242, 0.35); background: rgba(88, 101, 242, 0.08); }
.callout svg { width: 20px; height: 20px; flex: none; margin-top: 2px; color: var(--red-2); }
.callout.info svg { color: #8f9bff; }
.callout p { margin: 0; font-size: 15px; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; margin: 0 0 20px; }
.doc table { width: 100%; border-collapse: collapse; font-size: 15px; }
.doc th { text-align: left; font-weight: 600; color: var(--text); background: rgba(255, 255, 255, 0.03); padding: 12px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.doc td { padding: 12px 16px; border-top: 1px solid var(--line); color: #c4c4cc; vertical-align: top; }
.doc tr:first-child td { border-top: 0; }
.doc td:first-child { white-space: nowrap; }
.doc h2 + p { margin-top: 14px; }

.cat-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin: 48px 0 6px; padding-top: 8px; }
.cat-head h3 { margin: 0; font-size: 24px; }
.cat-head .count { font-size: 13px; color: var(--faint); }
.cat-blurb { color: var(--muted) !important; margin: 0 0 18px !important; }
.sub-title { font-size: 13px; font-weight: 600; color: var(--faint); text-transform: uppercase; letter-spacing: 0.08em; margin: 26px 0 10px; }
.group-head { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--faint); margin: 24px 0 10px; }
@media (max-width: 960px) { .doc [id] { scroll-margin-top: 58px; } }
.invite-row code, .t-item code { font-family: var(--mono); font-size: 0.88em; color: var(--text); background: rgba(255, 255, 255, 0.07); padding: 1px 5px; border-radius: 5px; }
.cmd-list { display: grid; gap: 8px; }
.cmd {
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 16px; align-items: start;
  padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.02);
  transition: border-color 0.2s, background 0.2s;
}
.cmd:hover { border-color: var(--line-2); background: rgba(255, 255, 255, 0.035); }
.cmd.flash { animation: flash 1.6s ease; }
@keyframes flash { 0%, 30% { border-color: var(--red); background: var(--red-soft); } }
.cmd .sig { font-family: var(--mono); font-size: 14px; color: var(--text); word-break: break-word; }
.cmd .sig .p { color: var(--red-2); }
.cmd .sig .args { color: var(--faint); }
.cmd .desc { grid-column: 1 / -1; color: var(--muted); font-size: 15px; margin: 0; }
.cmd .aka { grid-column: 1 / -1; display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.cmd .aka span { font-family: var(--mono); font-size: 12px; color: var(--muted); padding: 1px 8px; border-radius: 6px; background: rgba(255, 255, 255, 0.05); }
.copy { height: 28px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--line); background: none; color: var(--faint); font-size: 12px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; opacity: 0; transition: opacity 0.2s, color 0.2s, border-color 0.2s; }
.cmd:hover .copy, .copy:focus-visible { opacity: 1; }
.copy:hover { color: var(--text); border-color: var(--line-2); }
.copy.done { color: var(--green); border-color: rgba(59, 165, 93, 0.4); opacity: 1; }
.copy svg { width: 13px; height: 13px; }
@media (hover: none) { .copy { opacity: 1; } .search-btn kbd { display: none; } }
.legend { display: flex; gap: 18px; flex-wrap: wrap; font-size: 14px; color: var(--muted); margin: 0 0 8px; }
.legend code { font-size: 13px !important; }

/* Search dialog */
.search-modal { position: fixed; inset: 0; z-index: 90; display: flex; justify-content: center; align-items: flex-start; padding: 12vh 16px 16px; background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); opacity: 0; visibility: hidden; transition: 0.2s; }
.search-modal.open { opacity: 1; visibility: visible; }
.search-box { width: 100%; max-width: 640px; border-radius: 18px; border: 1px solid var(--line-2); background: #121215; box-shadow: var(--shadow); overflow: hidden; transform: translateY(-8px); transition: 0.2s; }
.search-modal.open .search-box { transform: none; }
.search-input { display: flex; align-items: center; gap: 12px; padding: 0 18px; border-bottom: 1px solid var(--line); }
.search-input svg { width: 18px; height: 18px; color: var(--faint); flex: none; }
.search-input input { flex: 1; height: 58px; border: 0; outline: 0; background: none; color: var(--text); font: inherit; font-size: 17px; }
.search-input kbd { font-size: 11px; padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line-2); color: var(--muted); }
.results { max-height: 52vh; overflow-y: auto; padding: 8px; }
.result { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; cursor: pointer; }
.result img { width: 26px; height: 26px; border-radius: 8px; flex: none; }
.result .r-main { min-width: 0; flex: 1; }
.result .r-name { font-family: var(--mono); font-size: 14px; color: var(--text); }
.result .r-desc { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.result .r-where { font-size: 12px; color: var(--faint); white-space: nowrap; }
.result.sel, .result:hover { background: rgba(255, 255, 255, 0.06); }
.result.sel .r-where { color: var(--muted); }
.results .none { padding: 32px 16px; text-align: center; color: var(--muted); font-size: 15px; }
.search-foot { display: flex; gap: 16px; padding: 10px 16px; border-top: 1px solid var(--line); font-size: 12px; color: var(--faint); }
.search-foot kbd { font-size: 11px; padding: 1px 5px; border-radius: 5px; border: 1px solid var(--line-2); margin-right: 4px; }
@media (max-width: 640px) { .result .r-where { display: none; } .search-foot { display: none; } }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 28px; z-index: 95; transform: translate(-50%, 16px); opacity: 0; padding: 10px 16px; border-radius: 12px; background: #1c1c21; border: 1px solid var(--line-2); font-size: 14px; transition: 0.25s; pointer-events: none; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
