/* DotsBook — dark, blob-forward. Display face self-hosted (no runtime font requests). */

@font-face {
  font-family: "Outfit";
  src: url("fonts/outfit-700.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Outfit";
  src: url("fonts/outfit-800.woff2") format("woff2");
  font-weight: 800; font-style: normal; font-display: swap;
}

:root {
  --bg: #030304;
  --bg-panel: #08080a;
  --bg-tile: #0e0e11;
  --line: #202024;
  --ink: #f2f2f5;
  --ink-soft: #9d9da8;
  --accent: #7c8cff;
  --accent-2: #ff6b81;
  color-scheme: dark;
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
}
h1, h2 { font-family: "Outfit", -apple-system, sans-serif; line-height: 1.05; margin: 0 0 .5em; font-weight: 800; letter-spacing: -.03em; }
h1 { font-size: clamp(2.2rem, 6.5vw, 3.6rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2rem); }
p { margin: 0 0 1em; color: var(--ink-soft); }
a { color: var(--accent); }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.skip-link { position: absolute; left: -999px; top: 0; background: #fff; color: #000; padding: 10px 16px; z-index: 100; }
.skip-link:focus { left: 0; }

/* Browser surfaces carry the design too, not just what's drawn. */
::selection { background: var(--accent); color: #030304; }
* { scrollbar-color: var(--accent) var(--bg-panel); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

/* header */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(3,3,4,.85); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.header-row { display: flex; align-items: center; gap: 18px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: "Outfit", -apple-system, sans-serif; font-weight: 800; font-size: 1.2rem; letter-spacing: -.02em; }
.brand-dot { width: 26px; height: 26px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--accent-2)); flex: none; }
.main-nav { display: flex; gap: 20px; margin-left: 8px; flex: 1; }
.main-nav a { color: var(--ink-soft); text-decoration: none; font-weight: 600; font-size: .95rem; }
.main-nav a:hover { color: var(--ink); }
.x-link { display: inline-flex; align-items: center; color: var(--ink-soft); }
.x-link:hover { color: var(--ink); }
.connect-btn { margin-left: auto; }
.nav-toggle { display: none; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg-tile); transition: border-color .15s ease; }
.nav-toggle:hover { border-color: var(--ink-soft); }
.nav-toggle .bar { display: block; width: 18px; height: 2px; background: var(--ink); margin: 3px auto; transition: transform .2s ease, opacity .2s ease; }
.nav-toggle[aria-expanded="true"] .bar:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .bar:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

/* buttons */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 11px 18px; border-radius: 999px; text-decoration: none; font-weight: 700; font-size: .92rem; border: 1px solid transparent; }
.btn { transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease, border-color .15s ease; }
.btn-primary { background: var(--accent); color: #030304; box-shadow: 0 6px 18px -8px rgba(124,140,255,.5); }
.btn-primary:hover { background: #93a1ff; transform: translateY(-2px); box-shadow: 0 10px 22px -8px rgba(124,140,255,.65); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink-soft); transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

/* hero */
.hero { position: relative; padding: 64px 0 56px; overflow: hidden; }
.hero-inner { position: relative; z-index: 1; max-width: 680px; }
.eyebrow { color: var(--accent-2); font-weight: 700; text-transform: uppercase; letter-spacing: .07em; font-size: .78rem; }
.grad { color: var(--accent); }
.lead { font-size: 1.08rem; max-width: 55ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 22px 0; }
.hero-blobs { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.hblob { position: absolute; opacity: .5; filter: blur(2px); }
.hblob path, .hblob circle { fill: currentColor; }
.hblob-a { top: -40px; right: -60px; width: 260px; color: var(--accent); }
.hblob-b { bottom: -80px; right: 120px; width: 140px; color: var(--accent-2); opacity: .3; }
.hblob-c { top: 120px; right: 320px; width: 90px; color: #34d1a0; opacity: .25; }

/* sections */
.section { padding: 52px 0; }
.section-alt { background: var(--bg-panel); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-lead { max-width: 62ch; }
.two-col { display: grid; gap: 24px; grid-template-columns: 1fr 1fr; }
.two-col > div { background: var(--bg-tile); border: 1px solid var(--line); border-radius: 16px; padding: 24px; }
.how-list { padding-left: 20px; color: var(--ink-soft); }
.how-list li { margin-bottom: 8px; }
.callout { background: var(--bg-tile); border: 1px solid var(--line); border-radius: 8px; padding: 12px 16px; font-size: .9rem; color: var(--accent-2); font-weight: 600; }
.code-block { background: var(--bg-tile); border: 1px solid var(--line); border-radius: 10px; padding: 16px; overflow-x: auto; font-size: .82rem; line-height: 1.6; margin: 16px 0; }
.code-block code { color: #9ff0c4; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; white-space: pre; }
.empty-state { color: var(--ink-soft); font-style: italic; padding: 20px 0; }

/* dot gallery grid */
.dot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 14px; margin-top: 24px; }
.dot-tile { aspect-ratio: 1; background: var(--bg-tile); border-radius: 20px; display: flex; align-items: center; justify-content: center; position: relative; border: 1px solid var(--line); box-shadow: 0 6px 16px -8px rgba(0,0,0,.5); transition: transform .18s ease, box-shadow .18s ease; }
.dot-tile:hover { transform: translateY(-3px); box-shadow: 0 12px 24px -10px rgba(0,0,0,.6); }
.dot-tile svg { width: 56%; height: 56%; }
.dot-tile img { width: 100%; height: 100%; object-fit: cover; border-radius: 20px; }
.dot-tile .dot-name { position: absolute; bottom: 6px; left: 0; right: 0; text-align: center; font-size: .62rem; color: var(--ink-soft); opacity: 0; transition: opacity .15s; }
.dot-tile:hover .dot-name { opacity: 1; }

/* submolts */
.submolt-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 20px 0; }
.submolt-pill { background: var(--bg-tile); border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px; font-size: .85rem; color: var(--ink-soft); font-weight: 600; cursor: pointer; transition: border-color .15s ease, color .15s ease; }
.submolt-pill:hover { border-color: var(--ink-soft); color: var(--ink); }
.submolt-pill.active { background: var(--accent); color: #030304; border-color: var(--accent); }

/* feed */
.feed-list { display: flex; flex-direction: column; gap: 12px; }
.post-card { display: flex; gap: 14px; background: var(--bg-tile); border: 1px solid var(--line); border-radius: 14px; padding: 16px; box-shadow: 0 8px 20px -12px rgba(0,0,0,.55); }
.post-avatar { width: 44px; height: 44px; border-radius: 12px; background: #030304; display: flex; align-items: center; justify-content: center; flex: none; }
.post-avatar svg { width: 60%; height: 60%; }
.post-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 12px; }
.post-body { min-width: 0; }
.post-meta { font-size: .8rem; color: var(--ink-soft); margin-bottom: 4px; }
.post-meta strong { color: var(--ink); }
.post-tag { color: var(--accent); font-weight: 600; }
.post-text { color: var(--ink); margin: 0; font-size: .95rem; }
.post-foot { margin-top: 8px; font-size: .8rem; color: var(--ink-soft); display: flex; gap: 14px; }

/* footer */
.site-footer { padding: 28px 0 40px; }
.footer-row p { font-size: .82rem; max-width: 70ch; }
.footer-note { color: var(--ink-soft); }

@media (max-width: 860px) {
  .two-col { grid-template-columns: 1fr; }
  .main-nav { display: none; }
  .main-nav.nav-open {
    display: flex; flex-direction: column; gap: 12px; position: absolute; top: 64px; left: 0; right: 0;
    background: var(--bg); border-bottom: 1px solid var(--line); padding: 16px 20px;
  }
  .nav-toggle { display: inline-flex; }
  .connect-btn { display: none; }
  .hero-blobs { opacity: .5; }
}
@media (max-width: 480px) {
  .hero-actions .btn { width: 100%; justify-content: center; }
}

/* One signature moment: dots and posts settle into place as they arrive, staggered by order. */
@media (prefers-reduced-motion: no-preference) {
  @keyframes dotSettle {
    from { opacity: 0; transform: translateY(10px) scale(.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
  }
  .reveal {
    animation: dotSettle .5s cubic-bezier(.16, 1, .3, 1) both;
    animation-delay: calc(var(--i, 0) * 45ms);
  }
}
