/*
 * Nodally web — the same visual language as the app.
 * Palette and type lifted from apps/nodally/constants/theme.ts so the poster,
 * the web page and the app all read as one product.
 */

:root {
    --bg: #19152D;
    --bg-deep: #120F22;
    --magenta: #E86BF0;
    --violet: #8B7CF6;
    --cyan: #4FE3E0;

    --surface: rgba(255, 255, 255, 0.07);
    --surface-strong: rgba(255, 255, 255, 0.12);
    --hairline: rgba(255, 255, 255, 0.14);

    --text: #FFFFFF;
    --text-muted: rgba(255, 255, 255, 0.68);
    --text-faint: rgba(255, 255, 255, 0.45);

    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 22px;
    --radius-pill: 999px;

    --gutter: 22px;
    --measure: 560px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    min-height: 100vh;
    background-color: var(--bg);
    color: var(--text);
    font-family: Sora, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* The app's gradient shell: base sweep, then a magenta and a cyan bloom. */
.shell {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background:
        radial-gradient(120% 90% at 100% 100%, rgba(79, 227, 224, 0.26), rgba(79, 227, 224, 0) 70%),
        radial-gradient(110% 80% at 0% 0%, rgba(232, 107, 240, 0.30), rgba(232, 107, 240, 0) 65%),
        linear-gradient(135deg, #2A1B4E 0%, #1C1838 50%, #132A52 100%);
}

.wrap {
    width: 100%;
    max-width: var(--measure);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

main { flex: 1; display: flex; flex-direction: column; justify-content: center; padding-block: 56px 40px; }

/* ---------------------------------------------------------------- type --- */

h1 {
    font-size: clamp(30px, 8vw, 44px);
    line-height: 1.15;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin: 0;
}

h2 {
    font-size: clamp(19px, 5vw, 23px);
    line-height: 1.3;
    font-weight: 600;
    margin: 0 0 10px;
}

.lede { color: var(--text-muted); font-size: clamp(16px, 4.2vw, 18px); margin: 16px 0 0; }
.muted { color: var(--text-muted); }
.faint { color: var(--text-faint); font-size: 13px; }

.gradient-text {
    background: linear-gradient(120deg, var(--magenta), var(--violet) 55%, var(--cyan));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* -------------------------------------------------------------- pieces --- */

.logo { width: min(40vw, 190px); height: auto; display: block; margin: 0 auto; }
.logo--event { width: min(40vw, 200px); border-radius: var(--radius-lg); margin-bottom: 26px; }

/* Logo and headings centre; body copy stays centred with them on these pages. */
.centred { text-align: center; }
.hero { text-align: center; }
.hero .lede { margin-left: auto; margin-right: auto; max-width: 44ch; }

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 14px;
    border-radius: var(--radius-pill);
    background: var(--surface-strong);
    border: 1px solid var(--hairline);
    font-size: 12.5px;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: var(--text-muted);
}

.code-chip {
    display: inline-block;
    margin-top: 6px;
    padding: 12px 22px;
    border-radius: var(--radius-md);
    background: var(--surface);
    border: 1px solid var(--hairline);
    font-size: clamp(22px, 7vw, 28px);
    font-weight: 700;
    letter-spacing: 6px;
}

/* Gradient-bordered button, the same construction as the app's Continue. */
.btn {
    display: block;
    width: 100%;
    padding: 2px;
    border: 0;
    border-radius: var(--radius-pill);
    background: linear-gradient(120deg, var(--magenta), var(--violet) 55%, var(--cyan));
    text-decoration: none;
    cursor: pointer;
    font: inherit;
}

.btn > span {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px 20px;
    border-radius: var(--radius-pill);
    background: var(--bg-deep);
    color: var(--text);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 1.6px;
    text-transform: uppercase;
}

.btn--solid > span { background: transparent; color: var(--bg-deep); }

/* Store buttons -------------------------------------------------------------
   Two presentations of the same link: an icon plus the store's name, and the
   official badge artwork once those files are dropped into img/. The badge is
   hidden until it actually loads, so a missing file degrades to the label
   rather than to a blank button. */

.store-glyph {
    width: 19px;
    height: 19px;
    flex: none;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.store-badge { display: none; }

.btn--badge {
    padding: 0;
    background: none;
    border-radius: 0;
}
.btn--badge > span { display: none; }
.btn--badge .store-badge {
    display: block;
    width: 100%;
    max-width: 200px;
    height: auto;
    margin: 0 auto;
}

.btn--quiet {
    background: var(--surface);
    border: 1px solid var(--hairline);
    padding: 0;
}
.btn--quiet > span {
    background: transparent;
    color: var(--text-muted);
    font-size: 13.5px;
    letter-spacing: 1.4px;
}

/* A store button with nothing to link to yet. Reads as unavailable rather
   than merely secondary: flat, dimmed, and inert to the pointer. */
.btn--disabled {
    background: var(--surface);
    border: 1px dashed var(--hairline);
    cursor: not-allowed;
    pointer-events: none;
    opacity: 0.55;
    filter: grayscale(1);
}
.btn--disabled > span { color: var(--text-muted); }

.btn:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; }

.buttons { display: grid; gap: 12px; margin-top: 30px; }

.store-row { display: grid; gap: 12px; margin-top: 26px; align-items: center; }
@media (min-width: 520px) { .store-row { grid-template-columns: 1fr 1fr; } }

/* Feature list on the marketing page. */
.features { display: grid; gap: 14px; margin: 40px 0 0; padding: 0; list-style: none; }
.features li {
    padding: 18px 20px;
    border-radius: var(--radius-md);
    background: var(--surface);
    border: 1px solid var(--hairline);
}
.features h2 { font-size: 16.5px; margin-bottom: 4px; }
.features p { margin: 0; color: var(--text-muted); font-size: 14.5px; }

.divider { height: 1px; background: var(--hairline); border: 0; margin: 40px 0 0; }

/* ---------------------------------------------------------------- prose --- */

.prose { max-width: 620px; }
.prose h1 { font-size: clamp(28px, 7vw, 38px); margin-bottom: 4px; }
.prose h2 {
    font-size: 18px;
    margin-top: 34px;
    padding-top: 22px;
    border-top: 1px solid var(--hairline);
}
.prose p { color: var(--text-muted); font-size: 15.5px; line-height: 1.75; }
.prose .lede { color: var(--text); font-size: clamp(16px, 4.2vw, 18px); }
.prose ul { color: var(--text-muted); font-size: 15.5px; line-height: 1.75; padding-left: 20px; }
.prose li { margin-bottom: 6px; }
.prose code {
    font-size: 14px;
    padding: 2px 6px;
    border-radius: 6px;
    background: var(--surface);
    border: 1px solid var(--hairline);
}
.prose .updated { margin-top: 34px; }

.back-link {
    display: inline-block;
    margin-bottom: 26px;
    color: var(--text-faint);
    font-size: 14px;
    text-decoration: none;
}
.back-link:hover { color: var(--text-muted); }

/* -------------------------------------------------------------- footer --- */

.footer { padding: 26px var(--gutter) 34px; text-align: center; }
.footer img { width: 104px; height: auto; opacity: 0.85; }
.footer p { margin: 8px 0 0; }
.footer a { color: var(--text-muted); }

a { color: var(--cyan); }

/* Only shown once JS decides the visitor's platform. */
[hidden] { display: none !important; }

@media (prefers-reduced-motion: no-preference) {
    .fade-in { animation: fade-in 420ms ease-out both; }
    @keyframes fade-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
}
