/* bozcode.com home page since 2026-11-15 (the neon design, from Gordon's
   mockup "BOZCODE Neon Tech Hub.png"; was /prototypes/neon-home/ and
   css/neon-home.css). Template: templates/home.html.
   JS: js/home.js (from frontend/src/home.ts). Rollback: home-v2.css.
   Dark by default like the mockup; <html data-theme="light"> (the moon
   button, remembered in a cookie) swaps the tokens below. Every colour a
   component uses is a token, so the light theme is one block. Classes: nx-. */

/* ---------- tokens ---------- */
:root {
    color-scheme: dark;
    --bg: #060a1c;
    --bg-2: #0a1029;
    --panel: #0e1536;
    --panel-2: #131c46;
    --ink: #f3f5ff;
    --muted: #bcc5e8;
    --faint: #9aa5d3;
    --line: rgb(125 140 255 / .2);
    --line-2: rgb(125 140 255 / .36);
    --cyan: #22d3ee;
    --violet: #a78bfa;
    --link: #38bdf8;
    --focus: #67e8f9;
    --grad-brand: linear-gradient(90deg, #22d3ee, #8b5cf6 55%, #e040fb);
    --grad-h1: linear-gradient(90deg, #22d3ee 0%, #6d8cff 38%, #a855f7 62%, #e040fb 100%);
    --grad-btn: linear-gradient(90deg, #9333ea, #2563eb);
    --grad-line: linear-gradient(90deg, transparent, rgb(139 92 246 / .75) 25%, rgb(34 211 238 / .75) 75%, transparent);
    --header-bg: rgb(6 10 28 / .88);
    --hero-glow: radial-gradient(60% 90% at 78% 0%, rgb(139 92 246 / .32), transparent 70%),
                 radial-gradient(45% 70% at 0% 100%, rgb(34 211 238 / .12), transparent 70%);
    --strip-bg: rgb(10 16 41 / .85);
    --shadow: 0 16px 36px rgb(0 0 0 / .45);
    --glow: 0 0 18px rgb(139 92 246 / .35);
    --glow-cyan: 0 0 16px rgb(34 211 238 / .45);
    --scrim: rgb(6 10 28 / .55);
    --ic-yellow: #facc15; --ic-blue: #60a5fa; --ic-cyan: #22d3ee; --ic-pink: #e879f9; --ic-green: #4ade80;
    --ridge-far: #2a2463; --ridge-mid: #191a48; --ridge-near: #0b0f2b;
    --footer-bg: #070b20;
    --font: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    --mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
    --wrap: 1200px;
    --gutter: clamp(16px, 3vw, 24px);
}
:root[data-theme="light"] {
    color-scheme: light;
    --bg: #eef2fb;
    --bg-2: #e3e9f7;
    --panel: #ffffff;
    --panel-2: #f4f6fd;
    --ink: #0f1b33;
    --muted: #3d4964;
    --faint: #515d79;
    --line: rgb(79 70 229 / .16);
    --line-2: rgb(79 70 229 / .3);
    --cyan: #0e7490;
    --violet: #6d28d9;
    --link: #1d4ed8;
    --focus: #1d4ed8;
    --grad-brand: linear-gradient(90deg, #0e7490, #6d28d9 55%, #a21caf);
    --grad-h1: linear-gradient(90deg, #0e7490 0%, #1d4ed8 38%, #6d28d9 62%, #a21caf 100%);
    --grad-line: linear-gradient(90deg, transparent, rgb(109 40 217 / .45) 25%, rgb(14 116 144 / .45) 75%, transparent);
    --header-bg: rgb(255 255 255 / .9);
    --hero-glow: radial-gradient(60% 90% at 78% 0%, rgb(139 92 246 / .16), transparent 70%),
                 radial-gradient(45% 70% at 0% 100%, rgb(34 211 238 / .12), transparent 70%);
    --strip-bg: rgb(255 255 255 / .8);
    --shadow: 0 14px 30px rgb(15 27 51 / .12);
    --glow: 0 6px 18px rgb(109 40 217 / .14);
    --glow-cyan: 0 6px 16px rgb(14 116 144 / .2);
    --scrim: rgb(238 242 251 / .7);
    --ic-yellow: #a16207; --ic-blue: #1d4ed8; --ic-cyan: #0e7490; --ic-pink: #a21caf; --ic-green: #15803d;
    --ridge-far: #c9d2ee; --ridge-mid: #b3bfe4; --ridge-near: #9cabd8;
    --footer-bg: #dfe6f5;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
body {
    min-height: 100vh;
    background: var(--bg);
    color: var(--ink);
    font: 400 1rem/1.55 var(--font);
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}
img, svg, picture { display: block; max-width: 100%; }
ul { list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
main:focus { outline: none; }
[hidden] { display: none !important; }
.visually-hidden {
    position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.nx-skip {
    position: absolute; left: 12px; top: -60px; z-index: 100;
    padding: 10px 16px; border-radius: 8px; background: var(--panel); color: var(--ink);
    border: 2px solid var(--focus); font-weight: 600;
}
.nx-skip:focus { top: 12px; }
.nx-wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }

/* gradient text (the logo's CODE, the headline's second line) */
.nx-logo-text span {
    background: var(--grad-brand);
    -webkit-background-clip: text; background-clip: text;
    color: transparent;
}

/* ---------- header ---------- */
.nx-header {
    position: sticky; top: 0; z-index: 50;
    background: var(--header-bg);
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.nx-header::after { content: ""; position: absolute; inset: auto 0 0; height: 1px; background: var(--grad-line); }
.nx-header-inner {
    max-width: calc(var(--wrap) + 80px); margin-inline: auto;
    padding: 10px var(--gutter);
    display: flex; align-items: center; gap: clamp(12px, 2vw, 28px);
    min-height: 68px;
}
.nx-logo { display: inline-flex; align-items: center; gap: 14px; flex: none; border-radius: 12px; }
.nx-logo-mark {
    display: grid; place-items: center;
    width: 44px; height: 44px; border-radius: 11px;
    border: 2px solid transparent;
    background: linear-gradient(var(--bg), var(--bg)) padding-box, var(--grad-brand) border-box;
    box-shadow: var(--glow);
    color: var(--cyan); font: 700 1.05rem/1 var(--mono);
}
.nx-logo-text { font: 900 1.75rem/1 var(--font); letter-spacing: .01em; color: var(--ink); }
.nx-nav { margin-left: auto; }
.nx-nav ul { display: flex; align-items: center; gap: clamp(10px, 1.8vw, 30px); }
.nx-nav a {
    position: relative; display: inline-flex; align-items: center; gap: 4px;
    padding: 10px 2px; white-space: nowrap;
    font-weight: 600; font-size: .95rem; color: var(--ink);
}
.nx-nav a::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 3px; height: 2px; border-radius: 2px;
    background: var(--cyan); transform: scaleX(0); transition: transform .2s;
}
.nx-nav a:hover::after { transform: scaleX(1); }
.nx-nav a.is-current { color: var(--cyan); }
.nx-nav a.is-current::after { transform: scaleX(1); box-shadow: var(--glow-cyan); }
.nx-ext { width: 14px; height: 14px; }
.nx-tools { display: flex; align-items: center; gap: 12px; flex: none; }
.nx-icon-btn {
    display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
    border: 1px solid var(--line-2); background: var(--panel); color: var(--ink);
    transition: border-color .2s, box-shadow .2s;
}
.nx-icon-btn:hover { border-color: var(--cyan); box-shadow: var(--glow-cyan); }
.nx-icon-btn svg { width: 21px; height: 21px; }
.nx-theme { border-color: transparent; background: transparent; color: var(--violet); }
.nx-theme .nx-sun { display: none; }
:root[data-theme="light"] .nx-theme .nx-moon { display: none; }
:root[data-theme="light"] .nx-theme .nx-sun { display: block; }
.nx-signform { display: contents; }
.nx-cta {
    display: inline-flex; align-items: center; gap: 8px; min-height: 44px;
    padding: 0 18px; border-radius: 10px; white-space: nowrap;
    border: 2px solid transparent;
    background: linear-gradient(var(--bg), var(--bg)) padding-box, var(--grad-brand) border-box;
    box-shadow: var(--glow), inset 0 0 12px rgb(139 92 246 / .18);
    color: var(--ink); font-weight: 700; font-size: .95rem;
    transition: box-shadow .2s, transform .15s;
}
.nx-cta svg { width: 18px; height: 18px; }
.nx-cta:hover { box-shadow: 0 0 24px rgb(139 92 246 / .55), inset 0 0 14px rgb(34 211 238 / .2); }
.nx-cta:active { transform: translateY(1px); }

/* ---------- hero ---------- */
.nx-hero { position: relative; isolation: isolate; background: var(--hero-glow), var(--bg); overflow: hidden; }
.nx-hero-inner {
    display: grid; grid-template-columns: minmax(0, 480px) 262px; column-gap: 40px; align-items: center;
    min-height: 396px; padding-block: 26px 30px;   /* border-box: fits editor + terminal (~375px at 12.5px type) */
}
/* The hero picture: a drawn synthwave scene (templates/home/hero_scene.html)
   with two HTML windows on it, an editor running a Go program and a terminal.
   Vector, so it stays sharp at any size and needs no cap. On wide screens it
   bleeds to the right edge; its ART fades in on the left, starting ~110px
   into the features column (480 + 40 + 110 from the content edge), so the
   features stand on the dark faded part. The windows don't fade. */
.nx-hero-scene {
    position: absolute; z-index: -1; top: 0; right: 0; bottom: 0;
    width: calc(100% - (100% - min(100%, var(--wrap))) / 2 - var(--gutter) - 630px);
    container-type: inline-size;
}
.nx-scene-art {
    position: absolute; inset: 0; width: 100%; height: 100%;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 32%);
    mask-image: linear-gradient(90deg, transparent 0, #000 32%);
}
/* Sized to the editor; the terminal hangs BELOW its lower-left corner (over
   its bottom padding only, never over code). The -3.4em centres editor +
   terminal together (the terminal sits 4em left of the editor). Window type scales with the scene's width (10-13px), and
   everything inside is em. */
.nx-scene-win {
    position: absolute; top: 50%;
    right: calc((100vw - min(100vw, var(--wrap))) / 2 + var(--gutter));
    transform: translateY(calc(-50% - 3.4em));
    font-size: clamp(10px, 2.5cqi, 12.5px);
}
.nx-code {
    border-radius: 1.05em; overflow: hidden;
    border: 1.5px solid transparent;
    background: linear-gradient(rgb(9 11 32 / .92), rgb(9 11 32 / .92)) padding-box,
                linear-gradient(135deg, #22d3ee, #8b5cf6 50%, #e040fb) border-box;
    box-shadow: 0 0 28px rgb(139 92 246 / .55), 0 0 70px rgb(34 211 238 / .16), 0 24px 50px rgb(0 0 0 / .5);
    color: #e6e9ff;
}
.nx-code-bar {
    display: flex; align-items: center; gap: 1em; padding: .6em .9em;
    background: rgb(255 255 255 / .04); border-bottom: 1px solid rgb(139 92 246 / .35);
}
.nx-code-dots { display: inline-flex; gap: .42em; }
.nx-code-dots i { width: .72em; height: .72em; border-radius: 50%; background: #ff5f57; }
.nx-code-dots i:nth-child(2) { background: #febc2e; }
.nx-code-dots i:nth-child(3) { background: #28c840; }
.nx-code-tab {
    display: inline-flex; align-items: center; gap: .55em; padding: .22em .75em .22em .35em;
    border-radius: .45em; background: rgb(139 92 246 / .2); border: 1px solid rgb(139 92 246 / .45);
    font: 600 .9em/1.3 var(--mono);
}
.nx-code-go { padding: .28em .42em; border-radius: .3em; background: #22d3ee; color: #0b1028; font: 900 .74em/1 var(--font); letter-spacing: .03em; }
.nx-code-src { padding: .85em 1.2em 1.1em .3em; font: 500 1em/1.5 var(--mono); white-space: pre; tab-size: 4; counter-reset: ln; }
/* .ln stays inline: the newlines in the <pre> already break the lines (block
   spans plus those newlines would double-space the code). */
.nx-code-src .ln::before {
    counter-increment: ln; content: counter(ln);
    display: inline-block; width: 2.2em; margin-right: 1em; text-align: right; color: #7c84b5;
}
.nx-code-src .k { color: #f472b6; }   /* keywords */
.nx-code-src .s { color: #86efac; }   /* strings */
.nx-code-src .f { color: #67e8f9; }   /* functions */
.nx-code-src .t { color: #c4b5fd; }   /* types */
.nx-code-src .b { color: #fbbf24; }   /* builtins */
.nx-term {
    position: absolute; left: -4em; top: calc(100% - 1em); width: 17em;
    border-radius: .9em; overflow: hidden;
    background: rgb(6 8 24 / .94); border: 1.5px solid rgb(34 211 238 / .75);
    box-shadow: 0 0 22px rgb(34 211 238 / .35), 0 18px 40px rgb(0 0 0 / .55);
    color: #e6e9ff; font: 500 .86em/1.5 var(--mono);
}
.nx-term-bar {
    display: flex; align-items: center; gap: .8em; padding: .42em .8em;
    border-bottom: 1px solid rgb(34 211 238 / .3); color: #a7b0d8; font-size: .86em;
}
.nx-term-bar .nx-code-dots i { width: .62em; height: .62em; }
.nx-term p { padding-inline: .9em; }
.nx-term p:nth-of-type(1) { padding-top: .5em; }
.nx-term p:last-child { padding-bottom: .6em; }
.nx-term-ps { color: #22d3ee; }
.nx-cursor {
    display: inline-block; width: .55em; height: 1.05em; vertical-align: -.17em;
    background: #22d3ee; box-shadow: 0 0 8px #22d3ee;
}
@media (prefers-reduced-motion: no-preference) { .nx-cursor { animation: nx-blink 1.1s steps(1) infinite; } }
@keyframes nx-blink { 50% { opacity: 0; } }
.nx-eyebrow {
    font: 700 .85rem/1.4 var(--mono); letter-spacing: .28em; text-transform: uppercase; color: var(--ink);
}
.nx-dot { margin-inline: .5em; color: var(--cyan); }
.nx-hero h1 { margin-top: 10px; font: 900 clamp(2.4rem, 4.8vw, 3.55rem)/1.02 var(--font); letter-spacing: -.02em; }
.nx-h1-a, .nx-h1-b { display: block; }
.nx-h1-b { background: var(--grad-h1); -webkit-background-clip: text; background-clip: text; color: transparent; padding-bottom: .06em; }
.nx-lede { margin-top: 14px; max-width: 46ch; font-size: 1.06rem; color: var(--muted); }
.nx-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 22px; }
.nx-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px;
    padding: 0 22px; border-radius: 10px; font-weight: 700; font-size: 1rem; white-space: nowrap;
    transition: box-shadow .2s, transform .15s, border-color .2s, background-color .2s;
}
.nx-btn svg { width: 20px; height: 20px; }
.nx-btn:active { transform: translateY(1px); }
.nx-btn-primary { background: var(--grad-btn); color: #fff; box-shadow: 0 0 22px rgb(147 51 234 / .45); }
.nx-btn-primary:hover { box-shadow: 0 0 30px rgb(99 102 241 / .7); }
.nx-btn-ghost { border: 2px solid var(--cyan); color: var(--ink); background: rgb(34 211 238 / .06); box-shadow: inset 0 0 10px rgb(34 211 238 / .12); }
.nx-btn-ghost:hover { background: rgb(34 211 238 / .14); box-shadow: var(--glow-cyan); }
.nx-btn-ghost svg { color: var(--cyan); }

.nx-hero-feats { display: grid; gap: 18px; }
:root[data-theme="light"] .nx-hero-feats {   /* dark ink can't sit on the scene: a frosted card */
    margin-inline: -16px; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line-2);
    background: rgb(255 255 255 / .8); box-shadow: var(--shadow);
    backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.nx-hero-feats li { display: flex; align-items: center; gap: 14px; }
.nx-hero-feats strong { display: block; font-weight: 700; font-size: 1rem; line-height: 1.25; }
.nx-hero-feats span span { display: block; font-size: .83rem; color: var(--muted); }
.nx-hero-feats li > span:last-child { text-shadow: 0 1px 10px var(--scrim), 0 0 2px var(--scrim); }
.nx-feat-ico {
    flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 10px;
    border: 2px solid transparent;
    background: linear-gradient(var(--panel), var(--panel)) padding-box, linear-gradient(135deg, #a855f7, #22d3ee) border-box;
    box-shadow: var(--glow);
    color: var(--cyan);
}
.nx-feat-ico svg { width: 22px; height: 22px; }
.nx-hero-feats li:nth-child(even) .nx-feat-ico { color: var(--violet); }

/* ---------- highlight strip ---------- */
.nx-strip { position: relative; background: var(--strip-bg); }
.nx-strip::before, .nx-strip::after { content: ""; position: absolute; left: 0; right: 0; height: 1px; background: var(--grad-line); }
.nx-strip::before { top: 0; } .nx-strip::after { bottom: 0; }
.nx-strip-list { max-width: calc(var(--wrap) + 80px); display: flex; justify-content: space-between; padding-block: 16px; }
.nx-hl { flex: 0 1 auto; display: flex; align-items: center; gap: 12px; padding: 4px 16px; }
.nx-hl strong, .nx-hl span span { white-space: nowrap; }
.nx-hl:last-child { flex: 1 1 0; min-width: 200px; max-width: 300px; }   /* the long one may take two lines */
.nx-hl:last-child span span { white-space: normal; }
.nx-hl + .nx-hl { border-left: 1px solid var(--line-2); }
.nx-hl svg { flex: none; width: 30px; height: 30px; }
.nx-hl strong { display: block; font-size: .95rem; font-weight: 700; line-height: 1.25; }
.nx-hl span span { display: block; font-size: .8rem; color: var(--muted); line-height: 1.35; }
.nx-hl--yellow svg { color: var(--ic-yellow); filter: drop-shadow(0 0 6px rgb(250 204 21 / .35)); }
.nx-hl--blue svg { color: var(--ic-blue); }
.nx-hl--cyan svg { color: var(--ic-cyan); }
.nx-hl--pink svg { color: var(--ic-pink); }
.nx-hl--green svg { color: var(--ic-green); }

/* ---------- sections ---------- */
.nx-section { position: relative; padding-block: 24px 30px; }
.nx-section + .nx-section::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px; background: var(--grad-line); }
.nx-examples { padding-top: 28px; }
.nx-sec-head { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.nx-sec-icon {
    flex: none; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 12px;
    border: 2px solid transparent;
    background: linear-gradient(var(--panel), var(--panel)) padding-box, linear-gradient(135deg, #a855f7, #22d3ee) border-box;
    box-shadow: var(--glow); color: var(--ink);
}
.nx-sec-icon svg { width: 26px; height: 26px; }
.nx-sec-title { min-width: 0; }
.nx-sec-title h2 { font: 800 clamp(1.45rem, 2.4vw, 1.75rem)/1.15 var(--font); letter-spacing: -.01em; }
.nx-sec-title p { margin-top: 3px; color: var(--muted); font-size: .98rem; }
.nx-sec-link {
    margin-left: auto; flex: none; display: inline-flex; align-items: center; gap: 6px;
    min-height: 44px; padding: 0 4px; color: var(--link); font-weight: 700; font-size: .95rem;
}
.nx-sec-link svg { width: 18px; height: 18px; transition: transform .2s; }
.nx-sec-link:hover span { text-decoration: underline; text-underline-offset: 4px; }
.nx-sec-link[aria-expanded="true"] svg { transform: rotate(180deg); }

/* ---------- examples: the mockup's colour tiles, our icons ---------- */
.nx-ex-grid { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 14px; }
.nx-tile {
    --t1: #3b82f6; --t2: #1d4ed8;
    position: relative; display: flex; flex-direction: column; height: 100%;
    border-radius: 12px; overflow: hidden;
    border: 1.5px solid color-mix(in srgb, var(--t1) 75%, #fff);
    background: #0a0f2a;
    box-shadow: 0 0 16px color-mix(in srgb, var(--t1) 45%, transparent), inset 0 0 0 1px rgb(255 255 255 / .06);
    transition: transform .2s, box-shadow .2s;
}
.nx-tile:hover { transform: translateY(-3px); box-shadow: 0 0 26px color-mix(in srgb, var(--t1) 70%, transparent), inset 0 0 0 1px rgb(255 255 255 / .1); }
.nx-tile:focus-visible { outline-offset: 4px; border-radius: 12px; }
.nx-tile-top {
    position: relative; display: grid; place-items: center; height: 108px;
    background: linear-gradient(180deg, var(--t1), var(--t2));
}
.nx-tile-top::after {   /* glossy sheen over the top half */
    content: ""; position: absolute; inset: 0 0 50%;
    background: linear-gradient(rgb(255 255 255 / .22), rgb(255 255 255 / 0));
    pointer-events: none;
}
.nx-tile-icon { width: 104px; height: auto; margin-left: -4px; filter: drop-shadow(0 6px 10px rgb(0 0 0 / .35)); }
.nx-tile-label {
    flex: 1; display: flex; flex-direction: column; justify-content: center; align-items: center;
    padding: 8px 6px 10px; text-align: center; color: #fff;
    background: linear-gradient(color-mix(in srgb, var(--t2) 38%, #0a0f2a), #0a0f2a);
    border-top: 1px solid color-mix(in srgb, var(--t1) 60%, #fff);
}
.nx-tile-name { font-weight: 700; font-size: .98rem; line-height: 1.2; }
.nx-tile-sub { margin-top: 2px; font-size: .78rem; line-height: 1.3; color: #e6e9f8; }
.nx-tile--htmlcssjs  { --t1: #f97316; --t2: #c2410c; }
.nx-tile--ansi-c     { --t1: #dc2626; --t2: #991b1b; }
.nx-tile--php        { --t1: #5b5bf0; --t2: #3730a3; }
.nx-tile--go         { --t1: #06b6d4; --t2: #0e7490; }
.nx-tile--python     { --t1: #2563eb; --t2: #1e3a8a; }
.nx-tile--csharp     { --t1: #a855f7; --t2: #6b21a8; }
.nx-tile--database   { --t1: #22a55a; --t2: #166534; }   /* green, like our database icon */
.nx-tile--networking { --t1: #2f7bf5; --t2: #1e3a8a; }

/* ---------- apps carousel ---------- */
.nx-carousel { position: relative; }
.nx-car-track {
    display: grid; grid-auto-flow: column; gap: 14px;
    grid-auto-columns: calc((100% - 5 * 14px) / 6);
    overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory;
    scrollbar-width: none; padding: 4px 2px 8px;
}
.nx-car-track::-webkit-scrollbar { display: none; }
.nx-car-track > li { scroll-snap-align: start; min-width: 0; }
.nx-carousel.is-grid .nx-car-track {
    grid-auto-flow: row; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); overflow: visible;
}
@media (prefers-reduced-motion: no-preference) { .nx-car-track { scroll-behavior: smooth; } }
.nx-app {
    display: flex; flex-direction: column; height: 100%;
    border-radius: 12px; overflow: hidden; background: var(--panel);
    border: 1px solid var(--line-2);
    box-shadow: var(--shadow);
    transition: border-color .2s, box-shadow .2s, transform .2s;
}
.nx-app:hover { border-color: var(--cyan); box-shadow: var(--glow-cyan), var(--shadow); transform: translateY(-2px); }
.nx-app-pic {
    position: relative; display: block; aspect-ratio: 2 / 1; overflow: hidden;
    background: linear-gradient(135deg, #312e81, #0e7490);
    border-bottom: 1px solid var(--line-2);
}
.nx-app-pic img { width: 100%; height: 100%; object-fit: cover; }
.nx-app-pic-ico { display: grid; place-items: center; height: 100%; color: #fff; }
.nx-app-pic-ico svg { width: 46px; height: 46px; filter: drop-shadow(0 0 10px rgb(34 211 238 / .6)); }
.nx-app-body { display: block; padding: 10px 14px 14px; }
.nx-app-name { display: block; font-weight: 700; font-size: 1rem; line-height: 1.3; }
.nx-app-desc { display: block; margin-top: 3px; font-size: .84rem; line-height: 1.4; color: var(--muted); }
.nx-car-btn {
    position: absolute; z-index: 2; top: calc(50% - 26px); display: grid; place-items: center;
    width: 44px; height: 44px; border-radius: 50%;
    background: var(--panel-2); color: var(--ink); border: 1px solid var(--line-2);
    box-shadow: var(--shadow); transition: border-color .2s, box-shadow .2s, opacity .2s;
}
.nx-car-btn svg { width: 20px; height: 20px; }
.nx-car-btn:hover { border-color: var(--cyan); box-shadow: var(--glow-cyan); }
.nx-car-btn[aria-disabled="true"] { opacity: .35; cursor: default; box-shadow: none; }
.nx-car-prev { left: -24px; }
.nx-car-next { right: -24px; }

/* ---------- news ---------- */
.nx-tabs { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }
.nx-tab {
    /* basis 0, not 150px: seven tabs at >=150px came to 1,153px in the 1,152px
       row and Yahoo Tech wrapped alone (2026-11-20). Each still grows to equal
       width, and a long label (TechPlanet Today) keeps its own size. */
    flex: 1 1 0; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    min-height: 44px; padding: 0 14px; border-radius: 9px;
    background: var(--panel); border: 1px solid var(--line-2); color: var(--ink);
    font-weight: 600; font-size: .92rem; white-space: nowrap;
    transition: border-color .2s, box-shadow .2s, background-color .2s;
}
.nx-tab svg { width: 20px; height: 20px; color: var(--violet); }
/* 880-1100px: the seven tabs no longer fit one row, and flex wrapping left
   Yahoo Tech alone on a full-width second row. Four columns give rows of 4
   and 3 (a column stays wider than TechPlanet Today's 193px down to 880px). */
@media (min-width: 880px) and (max-width: 1100px) {
    .nx-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.nx-tab:hover { border-color: var(--cyan); }
.nx-tab[aria-pressed="true"] { background: var(--grad-btn); color: #fff; border-color: transparent; box-shadow: 0 0 18px rgb(147 51 234 / .45); }
.nx-tab[aria-pressed="true"] svg { color: #fff; }
.nx-tab-mark, .nx-src-mark {
    display: inline-grid; place-items: center; flex: none; border-radius: 5px;
    background: var(--src); color: #fff; font: 700 .66rem/1 var(--mono); letter-spacing: .02em;
}
.nx-tab-mark { width: 24px; height: 24px; }
.nx-tab, .nx-card { --src: #2563eb; }
[data-src="techradar"]  { --src: #d31d24; }
[data-src="techplanet"] { --src: #15796f; }
[data-src="macrumors"]  { --src: #a5571e; }
[data-src="techspot"]   { --src: #8a4fc4; }
[data-src="xda"]        { --src: #4d7c0f; }
[data-src="yahoo"]      { --src: #6001d2; }
.nx-tab[aria-pressed="true"] .nx-tab-mark { box-shadow: 0 0 0 2px rgb(255 255 255 / .85); }

.nx-src-banner { margin: 0 auto 18px; max-width: 540px; }
.nx-src-banner img { width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line-2); box-shadow: var(--shadow); }

.nx-cards { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; }
.nx-card {
    position: relative; display: flex; flex-direction: column;
    border-radius: 12px; overflow: hidden; background: var(--panel);
    border: 1px solid var(--line-2); box-shadow: var(--shadow);
    transition: border-color .2s, box-shadow .2s, transform .2s;
}
.nx-card:hover { border-color: var(--cyan); box-shadow: var(--glow-cyan), var(--shadow); transform: translateY(-2px); }
.nx-card:focus-visible { outline-offset: 4px; border-radius: 12px; }
.nx-card-pic {
    position: relative; aspect-ratio: 2 / 1; overflow: hidden;
    background: linear-gradient(135deg, color-mix(in srgb, var(--src) 55%, #0a0f2a), #0a0f2a);
    border-bottom: 1px solid var(--line-2);
}
.nx-card-pic-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; transition: transform .35s; }
@media (prefers-reduced-motion: no-preference) { .nx-card:hover .nx-card-pic-img { transform: scale(1.04); } }
.nx-card-pic--none { display: grid; place-items: center; }
.nx-card-pic-mark {
    display: grid; place-items: center; width: 56px; height: 56px; border-radius: 12px;
    background: var(--src); color: #fff; font: 700 1.05rem/1 var(--mono);
    box-shadow: 0 0 18px color-mix(in srgb, var(--src) 55%, transparent);
}
.nx-card-meta { display: flex; align-items: center; gap: 8px; padding: 10px 14px 0; font-size: .78rem; }
.nx-src-mark { width: 20px; height: 20px; font-size: .58rem; border-radius: 4px; }
.nx-src { font-weight: 700; color: var(--ink); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nx-time { margin-left: auto; flex: none; color: var(--faint); }
.nx-card-title {
    margin: 6px 14px 0; font-size: 1rem; font-weight: 700; line-height: 1.32;
    display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; line-clamp: 4; overflow: hidden;
}
.nx-card-go {
    align-self: flex-end; margin: auto 12px 12px; margin-top: 12px;
    display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%;
    border: 1px solid var(--line-2); background: var(--panel-2); color: var(--ink);
    transition: border-color .2s, background-color .2s;
}
.nx-card-go svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.nx-card:hover .nx-card-go { border-color: var(--cyan); background: rgb(34 211 238 / .12); }
.nx-empty { grid-column: 1 / -1; padding: 28px; text-align: center; color: var(--muted); border: 1px dashed var(--line-2); border-radius: 12px; }
.nx-more { display: flex; justify-content: center; margin-top: 22px; }

/* ---------- footer ---------- */
.nx-footer { position: relative; margin-top: 18px; background: var(--footer-bg); color: var(--ink); }
.nx-footer::before { content: ""; position: absolute; z-index: 1; top: 0; left: 0; right: 0; height: 1px; background: var(--grad-line); }
.nx-ridges { display: block; width: 100%; height: 84px; background: linear-gradient(rgb(76 29 149 / .35), transparent); }
:root[data-theme="light"] .nx-ridges { background: linear-gradient(rgb(167 139 250 / .25), transparent); }
.nx-ridge-far { fill: var(--ridge-far); }
.nx-ridge-mid { fill: var(--ridge-mid); }
.nx-ridge-near { fill: var(--ridge-near); }
.nx-footer-grid {
    display: grid; grid-template-columns: minmax(0, 1.9fr) repeat(3, minmax(0, 1fr)) auto;
    gap: 28px; align-items: start; padding-block: 8px 22px;
}
.nx-foot-quick { display: flex; flex-wrap: wrap; gap: 4px 0; margin-top: 14px; font-size: .95rem; }
.nx-foot-quick li { white-space: nowrap; }
.nx-foot-quick li + li::before { content: "\2022"; margin-inline: 9px; color: var(--faint); }
.nx-foot-quick a, .nx-foot-col a { color: var(--muted); }
.nx-foot-quick a:hover, .nx-foot-col a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.nx-foot-col h2 { font-size: 1rem; font-weight: 700; margin-bottom: 6px; }
.nx-foot-col li { font-size: .93rem; line-height: 1.75; }
.nx-social { display: flex; gap: 14px; align-self: center; }
.nx-social a { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; color: var(--ink); border: 1px solid var(--line-2); background: var(--panel); transition: border-color .2s, box-shadow .2s; }
.nx-social a:hover { border-color: var(--cyan); box-shadow: var(--glow-cyan); }
.nx-social svg { width: 28px; height: 28px; }
.nx-foot-bottom { padding-block: 14px 22px; border-top: 1px solid var(--line); font: 500 .8rem/1.5 var(--mono); color: var(--faint); }

/* ---------- responsive ---------- */
@media (max-width: 1260px) {
    .nx-car-prev { left: -8px; } .nx-car-next { right: -8px; }
}
/* The section links drop to a second header row once they no longer fit. */
@media (max-width: 1240px) {   /* the strip's five items stop fitting on one line */
    .nx-strip-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 14px; }
    .nx-hl:nth-child(4) { border-left: 0; }
    .nx-hl:last-child { max-width: none; }
    .nx-hl span span { white-space: normal; }
}
@media (max-width: 1220px) {
    .nx-has-admin { flex-wrap: wrap; }
    .nx-has-admin .nx-tools { margin-left: auto; }
    .nx-has-admin .nx-nav { order: 3; flex-basis: 100%; margin-left: 0; }
    .nx-has-admin .nx-nav ul { justify-content: center; flex-wrap: wrap; }
}
/* Below 1181px the windows would reach the features: the scene becomes a framed
   picture beside the copy, with the four features in a row below. */
@media (max-width: 1180px) {
    .nx-hero-inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 26px 32px; min-height: 0; }
    .nx-hero-copy { grid-area: 1 / 1; }
    .nx-hero-scene {
        grid-area: 1 / 2; position: relative; z-index: auto; top: auto; right: auto; bottom: auto; width: auto;
        height: 400px;   /* fixed, not aspect-ratio: with a min-height that widened it past a phone */
        border-radius: 14px; overflow: hidden; border: 1px solid var(--line-2); box-shadow: var(--glow);
    }
    .nx-scene-art { -webkit-mask-image: none; mask-image: none; }
    .nx-scene-win { top: 50%; left: 50%; right: auto; transform: translate(-40%, calc(-50% - 3.4em)); }
    .nx-hero-feats { grid-area: 2 / 1 / 3 / 3; grid-template-columns: repeat(4, minmax(0, 1fr)); }
    :root[data-theme="light"] .nx-hero-feats { margin-inline: 0; padding: 0; border: 0; background: none; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
}
@media (max-width: 1120px) {
    .nx-has-nav { flex-wrap: wrap; }
    .nx-has-nav .nx-tools { margin-left: auto; }
    .nx-has-nav .nx-nav { order: 3; flex-basis: 100%; margin-left: 0; }
    .nx-has-nav .nx-nav ul { justify-content: center; flex-wrap: wrap; }
    .nx-ex-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .nx-car-track { grid-auto-columns: calc((100% - 3 * 14px) / 4); }
    .nx-cards { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .nx-footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .nx-foot-brand { grid-column: 1 / -1; }
    .nx-social { grid-column: 1 / -1; align-self: start; }
}
@media (max-width: 960px) {
    .nx-header-inner { flex-wrap: wrap; }
    .nx-tools { margin-left: auto; }
    .nx-nav { order: 3; flex-basis: 100%; margin-left: 0; }
    .nx-nav ul { justify-content: center; flex-wrap: wrap; column-gap: 22px; }
    .nx-hero-feats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .nx-car-track { grid-auto-columns: calc((100% - 2 * 14px) / 3); }
    .nx-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
    .nx-header { position: relative; }   /* two rows is too tall to keep pinned on a phone */
    html { scroll-padding-top: 12px; }
    .nx-hero-inner { grid-template-columns: minmax(0, 1fr); }
    .nx-hero-copy { grid-area: auto; }
    .nx-hero-feats { grid-area: auto; gap: 14px; }
    .nx-hero-scene { grid-area: auto; height: 320px; }
    .nx-strip { display: none; }   /* on a phone it only repeats the hero's features */
    .nx-ex-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
    .nx-car-track { grid-auto-columns: calc((100% - 14px) / 2.2); }
    .nx-car-btn { display: none; }
    .nx-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .nx-sec-head { flex-wrap: wrap; }
    .nx-sec-link { margin-left: 68px; }
}
@media (max-width: 520px) {
    .nx-logo-text { font-size: 1.3rem; }
    .nx-logo { gap: 10px; }
    .nx-logo-mark { width: 40px; height: 40px; }
    .nx-tools { gap: 6px; }
    .nx-icon-btn { width: 40px; height: 40px; }
    .nx-cta { padding: 0 12px; }
    /* features: 2 x 2, titles only (the one-liners cost a screen of scrolling) */
    .nx-hero-feats { gap: 12px; }
    .nx-hero-feats li { gap: 10px; }
    .nx-hero-feats span span { display: none; }
    .nx-hero-feats strong { font-size: .92rem; }
    .nx-feat-ico { width: 38px; height: 38px; }
    .nx-feat-ico svg { width: 19px; height: 19px; }
    .nx-term { left: -3em; }
    .nx-scene-win { transform: translate(-45%, calc(-50% - 3.4em)); }
    .nx-ex-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .nx-car-track { grid-auto-columns: 74%; }
    .nx-cards { grid-template-columns: minmax(0, 1fr); }
    .nx-footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .nx-sec-link { margin-left: 0; }
    .nx-eyebrow { letter-spacing: .18em; }
}
@media (max-width: 400px) {
    .nx-cta svg { display: none; }
    .nx-nav ul { column-gap: 16px; }
}
@media (max-width: 360px) {
    .nx-header .nx-logo-text { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; }
}
