// Main landing page composition

const { useState, useEffect } = React;

const TWEAK_DEFAULTS = /*EDITMODE-BEGIN*/{
  "variant": "night",
  "mode": "dark"
}/*EDITMODE-END*/;

function App() {
  const [tweaks, setTweak] = useTweaks(TWEAK_DEFAULTS);
  const t = useOneiroTheme(tweaks.variant, tweaks.mode);
  const isEsoteric = tweaks.variant === 'esoteric';
  const isDream    = tweaks.variant === 'dreamlike';

  return (
    <div style={{
      background: `linear-gradient(180deg, ${t.bg} 0%, ${t.bgEnd} 60%, ${t.bg} 100%)`,
      color: t.ink, minHeight: '100vh',
      fontFamily: t.sans,
      overflowX: 'hidden',
      position: 'relative',
    }}>
      <Hero t={t} variant={tweaks.variant} />
      <Manifesto t={t} />
      <Mechanism t={t} />
      <LiveSection t={t} />
      <TriggerMoment t={t} />
      <JournalSection t={t} />
      <Waitlist t={t} />
      <Footer t={t} />

      <TweaksPanel title="Tweaks">
        <TweakSection title="Aesthetic">
          <TweakRadio
            label="Direction"
            value={tweaks.variant}
            onChange={v => setTweak('variant', v)}
            options={[
              { value: 'night', label: 'Night' },
              { value: 'dreamlike', label: 'Dream' },
              { value: 'esoteric', label: 'Rite' },
            ]}
          />
          <TweakRadio
            label="Mode"
            value={tweaks.mode}
            onChange={v => setTweak('mode', v)}
            options={[
              { value: 'dark', label: 'Dark' },
              { value: 'light', label: 'Light' },
            ]}
          />
        </TweakSection>
      </TweaksPanel>
    </div>
  );
}

// ─────────────────────────────────────────────────────────────
// HERO
// ─────────────────────────────────────────────────────────────
function Hero({ t, variant }) {
  return (
    <section style={{
      minHeight: '100vh', position: 'relative',
      display: 'flex', alignItems: 'center', justifyContent: 'center',
      padding: '72px 32px',
    }}>
      <Starfield />
      <FogBlobs t={t} count={variant === 'dreamlike' ? 6 : 3} />

      {/* Top nav */}
      <nav style={{
        position: 'absolute', top: 28, left: 32, right: 32, zIndex: 5,
        display: 'flex', justifyContent: 'space-between', alignItems: 'center',
        fontFamily: t.mono, fontSize: 11, letterSpacing: '0.2em',
        color: t.inkSoft, textTransform: 'uppercase',
      }}>
        <div style={{ display: 'flex', alignItems: 'center', gap: 10 }}>
          <a href="https://øneiro.com" style={{ fontFamily: t.serif, fontSize: 22, color: t.ink, letterSpacing: 0, textTransform: 'none', textDecoration: 'none' }}>Øneiro</a>
          <span style={{ color: t.inkFaint }}>· {t.label}</span>
        </div>
        <div style={{ display: 'flex', gap: 28 }}>
          <a href="#mechanism" style={navLink(t)}>The Mechanism</a>
          <a href="#listener" style={navLink(t)}>The Practice</a>
          <a href="mailto:oneiro.orieno@gmail.com?subject=Field%20Notes" style={navLink(t)}>Field Notes</a>
          <a href="#enter" style={{ ...navLink(t), color: t.ink }}>Enter →</a>
        </div>
      </nav>

      <div style={{ position: 'relative', zIndex: 4, textAlign: 'center', maxWidth: 920 }}>
        {/* Sigil */}
        <div style={{
          display: 'flex', justifyContent: 'center', marginBottom: 28,
          filter: `drop-shadow(0 0 30px ${t.glow})`,
        }}>
          <OneiroSigil size={140} t={t} />
        </div>

        <div style={{
          fontFamily: t.mono, fontSize: 11, letterSpacing: '0.32em',
          color: t.inkSoft, textTransform: 'uppercase', marginBottom: 22,
        }}>
          a lucid dreaming instrument · est. 2026
        </div>

        <h1 style={{
          fontFamily: t.serif, fontWeight: 400,
          fontSize: 'clamp(56px, 9vw, 132px)', lineHeight: 0.95,
          margin: 0, letterSpacing: '-0.02em',
          color: t.ink, textWrap: 'balance',
        }}>
          where one is<br/>
          <span style={{ fontStyle: 'italic', color: t.accent }}>the dream.</span>
        </h1>

        <p style={{
          fontFamily: t.serif, fontStyle: 'italic',
          fontSize: 'clamp(18px, 2.2vw, 24px)', lineHeight: 1.5,
          color: t.inkSoft, maxWidth: 620, margin: '32px auto 0',
          textWrap: 'pretty',
        }}>
          a soft cue, placed at the threshold. you sleep, and we listen for the
          moment your mind begins to dream — then whisper it back to you,
          through the wrist.
        </p>

        <div style={{ display: 'flex', gap: 14, justifyContent: 'center', marginTop: 40, flexWrap: 'wrap' }}>
          <Button t={t} primary href="#enter">Request the rite</Button>
          <Button t={t} href="#mechanism">How it listens</Button>
        </div>

        {/* meta strip */}
        <div style={{
          marginTop: 64, display: 'flex', gap: 36, justifyContent: 'center',
          fontFamily: t.mono, fontSize: 10, letterSpacing: '0.18em',
          color: t.inkFaint, textTransform: 'uppercase', flexWrap: 'wrap',
        }}>
          <span>Muse S Athena · OSC :5000</span>
          <span>θ/α adaptive · Bayesian</span>
          <span>haptic · 3 × 500 ms</span>
          <span>night data · never leaves</span>
        </div>
      </div>
    </section>
  );
}

const navLink = (t) => ({
  color: 'inherit', textDecoration: 'none', cursor: 'pointer',
  transition: 'color 180ms',
});

function Button({ t, primary, children, href, onClick, type }) {
  const [hover, setHover] = useState(false);
  const Tag = href ? 'a' : 'button';
  return (
    <Tag
      href={href}
      onClick={onClick}
      type={type}
      onMouseEnter={() => setHover(true)}
      onMouseLeave={() => setHover(false)}
      style={{
        fontFamily: t.mono, fontSize: 12, letterSpacing: '0.2em',
        textTransform: 'uppercase', textDecoration: 'none',
        display: 'inline-block',
        padding: '14px 28px',
        background: primary ? t.accent : 'transparent',
        color: primary ? '#0a0820' : t.ink,
        border: `1px solid ${primary ? t.accent : t.line}`,
        borderRadius: 999,
        cursor: 'pointer',
        boxShadow: primary && hover ? `0 0 30px ${t.glow}` : 'none',
        transition: 'all 200ms',
        backdropFilter: 'blur(10px)',
      }}>
      {children}
    </Tag>
  );
}

// ─────────────────────────────────────────────────────────────
// MANIFESTO
// ─────────────────────────────────────────────────────────────
function Manifesto({ t }) {
  return (
    <section style={{
      padding: '120px 32px', textAlign: 'center', position: 'relative',
      borderTop: `1px solid ${t.line}`,
    }}>
      <div style={{ maxWidth: 820, margin: '0 auto' }}>
        <SectionLabel t={t}>i. the wager</SectionLabel>
        <p style={{
          fontFamily: t.serif, fontSize: 'clamp(28px, 4vw, 44px)',
          lineHeight: 1.35, fontWeight: 400, margin: 0,
          color: t.ink, textWrap: 'pretty',
          letterSpacing: '-0.01em',
        }}>
          for most of recorded sleep, the dream <em style={{ color: t.accent }}>arrives unannounced</em> —
          a thing that happens to you. Øneiro proposes a different
          arrangement: a quiet sentinel at the temporal lobes, a
          conversation between two heartbeats and one wristband, and a
          door, gently knocked.
        </p>
        <div style={{ height: 1, background: t.line, margin: '60px auto 0', width: 80 }} />
        <p style={{
          fontFamily: t.mono, fontSize: 11, letterSpacing: '0.24em',
          color: t.inkFaint, textTransform: 'uppercase', marginTop: 28,
        }}>
          — CGX / XINGXERX, founding mariners
        </p>
      </div>
    </section>
  );
}

function SectionLabel({ t, children }) {
  return (
    <div style={{
      fontFamily: t.mono, fontSize: 10, letterSpacing: '0.32em',
      color: t.accent, textTransform: 'uppercase', marginBottom: 28,
      display: 'inline-flex', alignItems: 'center', gap: 12,
    }}>
      <span style={{ display: 'inline-block', width: 20, height: 1, background: t.accent }} />
      {children}
      <span style={{ display: 'inline-block', width: 20, height: 1, background: t.accent }} />
    </div>
  );
}

// ─────────────────────────────────────────────────────────────
// MECHANISM — the chain of devices
// ─────────────────────────────────────────────────────────────
function Mechanism({ t }) {
  const stages = [
    { num: 'i', name: 'the headband', sub: 'Muse S Athena', body: 'four wet electrodes against the temporal bone. it watches the slow shape of your sleep.' },
    { num: 'ii', name: 'the listener', sub: 'Phase Sync, on your machine', body: 'parses θ and α in real time. waits for the ratio to cross threshold and stay crossed for ten seconds.' },
    { num: 'iii', name: 'the cue', sub: 'a wristband that pulses', body: 'three soft strikes against the skin — short enough to weave into the dream, not wake you from it.' },
    { num: 'iv', name: 'the grimoire', sub: 'on waking, you write', body: 'the cue becomes a tag in your memory. you turn over, reach for the phone, and the dream is still there.' },
  ];
  return (
    <section id="mechanism" style={{
      padding: '120px 32px', position: 'relative',
      borderTop: `1px solid ${t.line}`,
    }}>
      <div style={{ maxWidth: 1180, margin: '0 auto' }}>
        <div style={{ textAlign: 'center', marginBottom: 80 }}>
          <SectionLabel t={t}>ii. the mechanism</SectionLabel>
          <h2 style={{
            fontFamily: t.serif, fontSize: 'clamp(36px, 5vw, 60px)',
            fontWeight: 400, margin: 0, letterSpacing: '-0.01em',
          }}>
            four <em style={{ color: t.accent }}>quiet</em> devices, in a chain.
          </h2>
        </div>

        <div style={{
          display: 'grid', gridTemplateColumns: 'repeat(4, 1fr)', gap: 0,
          position: 'relative',
        }}>
          {/* connecting line */}
          <div style={{
            position: 'absolute', top: 32, left: '12.5%', right: '12.5%',
            height: 1, background: `linear-gradient(90deg, ${t.line}, ${t.accent}, ${t.line})`,
            opacity: 0.6,
          }} />
          {stages.map((s, i) => (
            <div key={i} style={{
              padding: '0 18px', textAlign: 'center', position: 'relative',
            }}>
              <div style={{
                width: 64, height: 64, borderRadius: '50%',
                border: `1px solid ${t.accent}`,
                background: t.bg,
                display: 'flex', alignItems: 'center', justifyContent: 'center',
                margin: '0 auto 24px',
                fontFamily: t.serif, fontStyle: 'italic',
                fontSize: 22, color: t.accent,
                boxShadow: `0 0 20px ${t.glow}55`,
              }}>{s.num}</div>
              <div style={{ fontFamily: t.serif, fontSize: 22, color: t.ink, marginBottom: 4 }}>
                {s.name}
              </div>
              <div style={{ fontFamily: t.mono, fontSize: 10, letterSpacing: '0.18em', color: t.accent, textTransform: 'uppercase', marginBottom: 12 }}>
                {s.sub}
              </div>
              <div style={{ fontFamily: t.serif, fontStyle: 'italic', fontSize: 15, color: t.inkSoft, lineHeight: 1.5, textWrap: 'pretty' }}>
                {s.body}
              </div>
            </div>
          ))}
        </div>
      </div>
    </section>
  );
}

// ─────────────────────────────────────────────────────────────
// LIVE SECTION — desktop window
// ─────────────────────────────────────────────────────────────
function LiveSection({ t }) {
  return (
    <section id="listener" style={{
      padding: '120px 32px', position: 'relative',
      borderTop: `1px solid ${t.line}`,
    }}>
      <FogBlobs t={t} count={2} />
      <div style={{ maxWidth: 1180, margin: '0 auto', position: 'relative', zIndex: 2 }}>
        <div style={{ display: 'flex', flexDirection: 'column', gap: 56, alignItems: 'center' }}>
          <div style={{ maxWidth: 760, textAlign: 'center' }}>
            <SectionLabel t={t}>iii. the listener</SectionLabel>
            <h2 style={{
              fontFamily: t.serif, fontSize: 'clamp(36px, 4.5vw, 56px)',
              fontWeight: 400, margin: '0 0 22px', letterSpacing: '-0.01em',
              lineHeight: 1.05,
            }}>
              your dream, <em style={{ color: t.accent }}>graphed</em>.
            </h2>
            <p style={{
              fontFamily: t.serif, fontStyle: 'italic',
              fontSize: 18, color: t.inkSoft, lineHeight: 1.55,
              textWrap: 'pretty',
            }}>
              Phase Sync runs on whatever machine you keep by the bed. it
              reads OSC packets at one-second resolution, averages your
              two temporal channels, and watches for the <span style={{ color: t.ink }}>θ/α inversion</span> that
              accompanies REM.
            </p>
            <p style={{
              fontFamily: t.serif, fontStyle: 'italic',
              fontSize: 18, color: t.inkSoft, lineHeight: 1.55,
              textWrap: 'pretty', marginTop: 18,
            }}>
              the threshold is not fixed. a small Bayesian model learns
              the shape of <em style={{ color: t.accent }}>your</em> REM, night by night.
            </p>
            <div style={{ display: 'flex', gap: 36, marginTop: 32, flexWrap: 'wrap', justifyContent: 'center' }}>
              <KeyVal t={t} k="resolution" v="1 Hz" />
              <KeyVal t={t} k="latency" v="< 80 ms" />
              <KeyVal t={t} k="cooldown" v="5 min" />
              <KeyVal t={t} k="storage" v="local only" />
            </div>
          </div>
          <div style={{ width: '100%', maxWidth: 1100, overflow: 'hidden', borderRadius: 26 }}>
            <MacWindow width="100%" height={520} title="Phase Sync — session 14"
                       sidebar={<LiveSidebar t={t} />}>
              <div style={{ height: '100%', margin: -8, marginTop: -4 }}>
                <LiveSession t={t} label={t.label} />
              </div>
            </MacWindow>
          </div>
        </div>
      </div>
    </section>
  );
}

function LiveSidebar({ t }) {
  return (
    <div style={{ padding: '8px 4px', fontFamily: t.mono, fontSize: 11 }}>
      <MacSidebarHeader>Tonight</MacSidebarHeader>
      <MacSidebarItem icon="●" active>Live session</MacSidebarItem>
      <MacSidebarItem icon="◐">Calibration</MacSidebarItem>
      <MacSidebarItem icon="◇">Devices</MacSidebarItem>
      <MacSidebarHeader>Archive</MacSidebarHeader>
      <MacSidebarItem icon="✦">Session 13</MacSidebarItem>
      <MacSidebarItem icon="✦">Session 12</MacSidebarItem>
      <MacSidebarItem icon="✦">Session 11</MacSidebarItem>
      <MacSidebarItem icon="◯">All nights</MacSidebarItem>
    </div>
  );
}

function KeyVal({ t, k, v }) {
  return (
    <div>
      <div style={{ fontFamily: t.mono, fontSize: 9, letterSpacing: '0.22em', color: t.inkFaint, textTransform: 'uppercase' }}>{k}</div>
      <div style={{ fontFamily: t.serif, fontSize: 22, color: t.ink, marginTop: 2 }}>{v}</div>
    </div>
  );
}

// ─────────────────────────────────────────────────────────────
// TRIGGER MOMENT — full-bleed, slow pulse
// ─────────────────────────────────────────────────────────────
function TriggerMoment({ t }) {
  return (
    <section style={{
      padding: '160px 32px', position: 'relative',
      borderTop: `1px solid ${t.line}`,
      overflow: 'hidden',
    }}>
      {/* radial pulse */}
      <div style={{
        position: 'absolute', inset: 0, display: 'flex',
        alignItems: 'center', justifyContent: 'center',
        zIndex: 1, pointerEvents: 'none',
      }}>
        {[1,2,3].map(i => (
          <div key={i} style={{
            position: 'absolute', width: 240 * i, height: 240 * i,
            borderRadius: '50%', border: `1px solid ${t.rem}`,
            opacity: 0.3 / i,
            animation: `oneiro-trigger-pulse 3s ease-out infinite`,
            animationDelay: `${i * 0.5}s`,
          }} />
        ))}
      </div>

      <div style={{
        maxWidth: 760, margin: '0 auto', textAlign: 'center',
        position: 'relative', zIndex: 2,
      }}>
        <SectionLabel t={t}>iv. the cue</SectionLabel>
        <div style={{
          fontFamily: t.mono, fontSize: 12, letterSpacing: '0.32em',
          color: t.rem, marginBottom: 24, textTransform: 'uppercase',
          textShadow: `0 0 12px ${t.rem}`,
        }}>
          ✦ rem confirmed · 03:42:11
        </div>
        <h2 style={{
          fontFamily: t.serif, fontWeight: 400,
          fontSize: 'clamp(40px, 6vw, 80px)', lineHeight: 1.05,
          margin: 0, letterSpacing: '-0.02em', textWrap: 'balance',
        }}>
          three small <em style={{ color: t.rem }}>knocks</em>,<br/>
          on the inside of your wrist.
        </h2>
        <p style={{
          fontFamily: t.serif, fontStyle: 'italic',
          fontSize: 'clamp(17px, 2vw, 22px)', lineHeight: 1.55,
          color: t.inkSoft, maxWidth: 560, margin: '32px auto 0',
          textWrap: 'pretty',
        }}>
          the haptic is calibrated to enter the dream as a <em style={{ color: t.ink }}>symbol</em>, not a
          waking. a low hum. a third heartbeat. a door opening on the
          left side of the room. with practice, you learn to recognize
          it. and then — <em style={{ color: t.rem }}>oh.</em>
        </p>
      </div>
    </section>
  );
}

// ─────────────────────────────────────────────────────────────
// JOURNAL SECTION — phone
// ─────────────────────────────────────────────────────────────
function JournalSection({ t }) {
  const phoneIsDark = true; // journal always reads dark in our system regardless of mode

  return (
    <section style={{
      padding: '120px 32px', position: 'relative',
      borderTop: `1px solid ${t.line}`,
    }}>
      <div style={{ maxWidth: 1180, margin: '0 auto' }}>
        <div style={{ display: 'grid', gridTemplateColumns: 'minmax(320px, 440px) 1fr', gap: 64, alignItems: 'center' }}>
          <div style={{ display: 'flex', justifyContent: 'center' }}>
            <IOSDevice width={380} height={780} dark>
              <div style={{ height: '100%' }}>
                <DreamJournal t={t} />
              </div>
            </IOSDevice>
          </div>
          <div>
            <SectionLabel t={t}>v. the grimoire</SectionLabel>
            <h2 style={{
              fontFamily: t.serif, fontSize: 'clamp(36px, 4.5vw, 56px)',
              fontWeight: 400, margin: '0 0 22px', letterSpacing: '-0.01em',
              lineHeight: 1.05,
            }}>
              the cue, <em style={{ color: t.accent }}>remembered</em>.
            </h2>
            <p style={{
              fontFamily: t.serif, fontStyle: 'italic',
              fontSize: 18, color: t.inkSoft, lineHeight: 1.55,
              textWrap: 'pretty',
            }}>
              when the alarm comes, it comes soft. you reach for the
              phone — already lit, already listening. you speak, or you
              type, and the entry is timestamped against the cue that
              fired forty seconds before you woke.
            </p>
            <p style={{
              fontFamily: t.serif, fontStyle: 'italic',
              fontSize: 18, color: t.inkSoft, lineHeight: 1.55,
              textWrap: 'pretty', marginTop: 18,
            }}>
              over weeks, the grimoire builds its own grammar. recurring
              <em style={{ color: t.accent }}> rooms</em>, recurring <em style={{ color: t.accent }}>strangers</em>, recurring <em style={{ color: t.accent }}>verbs</em>.
              the lucidity score rises. the dreams begin to keep you.
            </p>

            <div style={{
              marginTop: 36, padding: 22, borderRadius: 14,
              border: `1px solid ${t.line}`, background: t.surface,
            }}>
              <div style={{ fontFamily: t.mono, fontSize: 10, letterSpacing: '0.22em', color: t.inkFaint, textTransform: 'uppercase', marginBottom: 10 }}>
                a fragment, recovered
              </div>
              <div style={{ fontFamily: t.serif, fontStyle: 'italic', fontSize: 19, color: t.ink, lineHeight: 1.5, textWrap: 'pretty' }}>
                "I knew I was dreaming when the books rearranged
                themselves to my gaze. I asked the librarian her name.
                She said —"
              </div>
            </div>
          </div>
        </div>
      </div>
    </section>
  );
}

// ─────────────────────────────────────────────────────────────
// WAITLIST / CTA
// ─────────────────────────────────────────────────────────────
function Waitlist({ t }) {
  const [email, setEmail] = useState('');
  const knock = (e) => {
    e.preventDefault();
    const subject = encodeURIComponent('Øneiro — knock at the door');
    const body = encodeURIComponent(
      `My sleeping name: ${email || '(left blank)'}\n\nI'd like to be considered for the next cohort.\n`
    );
    window.location.href = `mailto:oneiro.orieno@gmail.com?subject=${subject}&body=${body}`;
  };
  return (
    <section id="enter" style={{
      padding: '160px 32px', position: 'relative',
      borderTop: `1px solid ${t.line}`,
      textAlign: 'center', overflow: 'hidden',
    }}>
      <FogBlobs t={t} count={3} />
      <div style={{
        position: 'absolute', top: '50%', left: '50%',
        transform: 'translate(-50%, -50%)', opacity: 0.08, zIndex: 0,
      }}>
        <OneiroSigil size={520} t={t} />
      </div>
      <div style={{ maxWidth: 720, margin: '0 auto', position: 'relative', zIndex: 3 }}>
        <SectionLabel t={t}>vi. enter</SectionLabel>
        <h2 style={{
          fontFamily: t.serif, fontWeight: 400,
          fontSize: 'clamp(44px, 6vw, 84px)', lineHeight: 1.0,
          margin: 0, letterSpacing: '-0.02em', textWrap: 'balance',
        }}>
          the rite is <em style={{ color: t.accent }}>private</em>.<br/>
          the waitlist is <em style={{ color: t.accent }}>small</em>.
        </h2>
        <p style={{
          fontFamily: t.serif, fontStyle: 'italic',
          fontSize: 'clamp(17px, 2vw, 21px)', lineHeight: 1.55,
          color: t.inkSoft, maxWidth: 540, margin: '28px auto 0',
          textWrap: 'pretty',
        }}>
          the first cohort receives the wristband, the listener, and
          three nights of guided calibration. an NDA is part of the
          ceremony.
        </p>

        <form onSubmit={knock} style={{
          marginTop: 44, display: 'flex', gap: 0, maxWidth: 520, margin: '44px auto 0',
          border: `1px solid ${t.line}`, borderRadius: 999, overflow: 'hidden',
          background: t.surface, backdropFilter: 'blur(10px)',
        }}>
          <input
            value={email}
            onChange={(e) => setEmail(e.target.value)}
            placeholder="your sleeping name…"
            style={{
              flex: 1, background: 'transparent', border: 'none', outline: 'none',
              padding: '16px 22px', fontFamily: t.serif, fontStyle: 'italic',
              fontSize: 16, color: t.ink,
            }}
          />
          <button type="submit" style={{
            background: t.accent, color: '#0a0820', border: 'none',
            padding: '0 28px', fontFamily: t.mono, fontSize: 11, letterSpacing: '0.22em',
            textTransform: 'uppercase', cursor: 'pointer',
          }}>knock →</button>
        </form>

        <div style={{
          marginTop: 28, fontFamily: t.mono, fontSize: 10,
          letterSpacing: '0.22em', color: t.inkFaint, textTransform: 'uppercase',
        }}>
          247 sleepers ahead of you · cohort 03 · summer solstice
        </div>
      </div>
    </section>
  );
}

// ─────────────────────────────────────────────────────────────
// FOOTER
// ─────────────────────────────────────────────────────────────
function Footer({ t }) {
  return (
    <footer style={{
      padding: '56px 32px 36px',
      borderTop: `1px solid ${t.line}`,
      fontFamily: t.mono, fontSize: 10, letterSpacing: '0.18em',
      color: t.inkFaint, textTransform: 'uppercase',
    }}>
      <div style={{
        maxWidth: 1180, margin: '0 auto',
        display: 'flex', justifyContent: 'space-between', alignItems: 'center', flexWrap: 'wrap', gap: 18,
      }}>
        <div style={{ display: 'flex', alignItems: 'center', gap: 12 }}>
          <a href="https://øneiro.com" style={{ fontFamily: t.serif, fontSize: 18, color: t.ink, letterSpacing: 0, textTransform: 'none', textDecoration: 'none' }}>Øneiro</a>
          <span>· © 2026 CGX · all rites reserved</span>
        </div>
        <div style={{ display: 'flex', gap: 28 }}>
          <a href="mailto:oneiro.orieno@gmail.com?subject=Field%20Notes" style={navLink(t)}>Field Notes</a>
          <a href="mailto:oneiro.orieno@gmail.com?subject=NDA%20request" style={navLink(t)}>NDA</a>
          <a href="mailto:oneiro.orieno@gmail.com?subject=Press%20inquiry" style={navLink(t)}>Press</a>
          <a href="mailto:oneiro.orieno@gmail.com" style={navLink(t)}>Contact</a>
        </div>
        <a href="https://øneiro.com" target="_blank" rel="noreferrer" style={{ ...navLink(t), color: t.ink }}>øneiro.com</a>
      </div>
    </footer>
  );
}

ReactDOM.createRoot(document.getElementById('root')).render(<App />);
