/* NexusHub Fake News Generator: TV + phone live preview in the middle, simple controls beside (below on phones). */
html { background: #000; color-scheme: dark; }
body.fn { margin: 0; background: #000 !important; color: #f5f5f7; font-family: Inter, system-ui, -apple-system, sans-serif; -webkit-font-smoothing: antialiased; }
.fn { --red: #ef3340; --mut: #a1a1a6; --dim: #6e6e73; --line: rgba(255,255,255,.1); --card: #121214; --card2: #1a1a1d; --ease: cubic-bezier(.22,1,.36,1); }
.fn *, .fn *::before, .fn *::after { box-sizing: border-box; }
.fn svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.fn h1, .fn h2, .fn h3 { margin: 0; font-family: Outfit, Inter, sans-serif; letter-spacing: -.03em; color: #f5f5f7; }
.fn em { font-style: normal; color: var(--red); }
.fn button, .fn input, .fn textarea { font: inherit; color: inherit; }
.fn-main { overflow-x: clip; }
.fn [hidden] { display: none !important; }

/* Heading */
.fn-head { position: relative; width: min(1320px, calc(100% - 32px)); margin: 0 auto; padding: 30px 0 8px; text-align: center; }
.fn-head::before { content: ""; position: absolute; z-index: -1; inset: -80px -20% -200px; pointer-events: none; background: radial-gradient(40% 50% at 50% 40%, rgba(239,51,64,.16), transparent 70%); }
.fn-kick { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 10px; color: var(--red); font-size: 13.5px; font-weight: 700; }
.fn-kick span { width: 8px; height: 8px; border-radius: 50%; background: var(--red); animation: fnLive 1.6s ease-in-out infinite; }
.fn-head h1 { font-size: clamp(38px, 9vw, 68px); font-weight: 800; line-height: 1; }
.fn-lead { max-width: 520px; margin: 12px auto 0; color: var(--mut); font-size: clamp(15.5px, 3.8vw, 18px); line-height: 1.5; }

/* App: stage + panel */
.fn-app { display: grid; gap: 22px; width: min(1320px, calc(100% - 24px)); margin: 18px auto 0; }
.fn-stage { min-width: 0; }
.fn-devices { position: relative; width: min(100%, 860px); margin: 0 auto; padding-right: 13%; }
.fn-imac { position: relative; filter: drop-shadow(0 40px 50px rgba(0,0,0,.55)); }
.fn-imac > img { position: relative; z-index: 2; display: block; width: 100%; height: auto; pointer-events: none; user-select: none; }
.fn-scr { position: absolute; z-index: 3; left: 4.54%; top: 5.816%; width: 91.203%; height: 61.064%; overflow: hidden; background: #111; }
.fn-scr canvas { display: block; width: 100%; height: 100%; touch-action: none; }
.fn-scr.has-photo canvas { cursor: grab; }
.fn-scr.has-photo canvas:active { cursor: grabbing; }
.fn-drop { position: absolute; left: 50%; top: 8%; display: flex; flex-direction: column; align-items: center; gap: 3px; width: 46%; padding: 3.2% 3%; transform: translateX(-50%);
  border-radius: 14px; background: rgba(0,0,0,.42); box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  text-align: center; cursor: pointer; transition: background .25s, transform .25s var(--ease), box-shadow .25s; container-type: inline-size; }
.fn-drop:hover, .fn-drop.over { background: rgba(0,0,0,.6); box-shadow: inset 0 0 0 2px #fff; transform: translateX(-50%) scale(1.02); }
.fn-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.fn-drop-ic { display: grid; place-items: center; width: 13cqw; height: 13cqw; margin-bottom: 2cqw; border-radius: 30%; background: #fff; color: #000; }
.fn-drop-ic svg { width: 58%; height: 58%; }
.fn-drop b { font-size: max(10px, 5.2cqw); font-weight: 700; color: #fff; }
.fn-drop small { font-size: max(8px, 3.6cqw); color: rgba(255,255,255,.75); }
.fn-mob { display: none; }
.fn-scr.has-photo .fn-drop { opacity: 0; pointer-events: none; transform: translateX(-50%) scale(.96); }
.fn-pan { position: absolute; left: 50%; top: 4%; padding: 5px 10px; border-radius: 999px; background: rgba(0,0,0,.6); color: #fff; font-size: 11px; font-weight: 600; white-space: nowrap; transform: translateX(-50%);
  pointer-events: none; animation: fnFadeOut 3s 1.5s forwards; }
.fn-phone { position: absolute; z-index: 4; right: 0; bottom: 4%; width: 23%; filter: drop-shadow(0 24px 30px rgba(0,0,0,.6)); }
.fn-phone > img { position: relative; z-index: 2; display: block; width: 100%; height: auto; pointer-events: none; }
.fn-phone-scr { position: absolute; z-index: 1; left: 4.43%; top: 2.37%; width: 90.61%; height: 95.36%; overflow: hidden; border-radius: 10.2% / 4.97%; background: #000; }
.fn-phone-scr canvas { display: block; width: 100%; height: 100%; }

/* Panel */
.fn-panel { display: grid; gap: 12px; align-content: start; }
.fn-sec { padding: 18px; border-radius: 22px; background: var(--card); box-shadow: inset 0 0 0 1px var(--line); }
.fn-sec h2 { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-size: 16.5px; font-weight: 700; letter-spacing: -.01em; }
.fn-sec h2 span { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: rgba(239,51,64,.16); color: #ff8a92; font: 800 12.5px Inter, sans-serif; }
.fn-hl { position: relative; }
.fn-hl textarea { display: block; width: 100%; min-height: 76px; padding: 13px 54px 13px 14px; border: 0; border-radius: 14px; background: #0a0a0b; box-shadow: inset 0 0 0 1px var(--line);
  font-size: 17px; font-weight: 600; line-height: 1.35; resize: none; outline: none; transition: box-shadow .2s; field-sizing: content; }
.fn-hl textarea:focus, .fn-field input:focus { box-shadow: inset 0 0 0 2px var(--red); }
.fn-dice { position: absolute; top: 9px; right: 9px; display: grid; place-items: center; width: 38px; height: 38px; border: 0; border-radius: 11px; background: rgba(255,255,255,.08); cursor: pointer; transition: background .2s, transform .3s var(--ease); }
.fn-dice:hover { background: rgba(255,255,255,.15); }
.fn-dice:active { transform: rotate(90deg) scale(.92); }
.fn-dice svg { width: 20px; height: 20px; }
.fn-field { display: block; margin-top: 12px; color: var(--mut); font-size: 13px; font-weight: 600; }
.fn-field small { color: var(--dim); font-weight: 500; }
.fn-field input { display: block; width: 100%; margin-top: 6px; padding: 12px 13px; border: 0; border-radius: 12px; background: #0a0a0b; box-shadow: inset 0 0 0 1px var(--line); color: #fff; font-size: 15.5px; font-weight: 500; outline: none; transition: box-shadow .2s; }
.fn-field input[type=time] { color-scheme: dark; }
.fn-two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* Channel cards: real renders of each style */
.fn-tpls { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.fn-tpl { position: relative; padding: 0; border: 0; border-radius: 14px; overflow: hidden; background: #000; cursor: pointer; text-align: left; box-shadow: inset 0 0 0 1px var(--line); transition: transform .25s var(--ease), box-shadow .25s; }
.fn-tpl:hover { transform: translateY(-2px); }
.fn-tpl canvas { display: block; width: 100%; aspect-ratio: 16 / 9; }
.fn-tpl span { display: flex; align-items: center; justify-content: space-between; padding: 8px 10px; background: var(--card2); font-size: 13px; font-weight: 600; }
.fn-tpl span::after { content: ""; width: 16px; height: 16px; border-radius: 50%; box-shadow: inset 0 0 0 2px #52525b; transition: box-shadow .2s; }
.fn-tpl[aria-checked="true"] { box-shadow: 0 0 0 2px var(--red); }
.fn-tpl[aria-checked="true"] span::after { box-shadow: inset 0 0 0 5px var(--red); }

/* Picture */
.fn-pic-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.fn-hint { color: var(--mut); font-size: 13px; }
.fn-swatches { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.fn-swatches[hidden] { display: none; }
.fn-sw { width: 38px; height: 38px; padding: 0; border: 0; border-radius: 50%; cursor: pointer; box-shadow: inset 0 0 0 1px rgba(255,255,255,.2); transition: transform .2s var(--ease), box-shadow .2s; }
.fn-sw:hover { transform: scale(1.08); }
.fn-sw[aria-checked="true"] { box-shadow: 0 0 0 2px #000, 0 0 0 4px #fff; }
.fn-range { display: flex; align-items: center; gap: 12px; margin-top: 14px; color: var(--mut); font-size: 13px; font-weight: 600; }
.fn-range input { flex: 1; accent-color: var(--red); }

/* Chips + toggles */
.fn-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.fn-chips button { padding: 7px 11px; border: 0; border-radius: 999px; background: rgba(255,255,255,.07); color: var(--mut); font-size: 12px; font-weight: 700; letter-spacing: .02em; cursor: pointer; transition: background .2s, color .2s; }
.fn-chips button:hover { background: rgba(255,255,255,.13); color: #fff; }
.fn-chips button[aria-pressed="true"] { background: rgba(239,51,64,.18); color: #ffb3b9; }
.fn-toggles { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 16px; }
.fn-tg { display: inline-flex; align-items: center; gap: 10px; color: #e4e4e7; font-size: 14px; font-weight: 600; cursor: pointer; }
.fn-tg input { position: absolute; opacity: 0; pointer-events: none; }
.fn-tg i { position: relative; width: 42px; height: 26px; border-radius: 999px; background: #3f3f46; transition: background .25s; }
.fn-tg i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .3s var(--ease); }
.fn-tg input:checked + i { background: #34c759; }
.fn-tg input:checked + i::after { transform: translateX(16px); }
.fn-tg input:focus-visible + i { outline: 2px solid #fff; outline-offset: 2px; }

/* Buttons */
.fn-btn { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border: 0; border-radius: 999px; cursor: pointer;
  font-size: 14.5px; font-weight: 700; white-space: nowrap; transition: background .2s, transform .2s var(--ease); }
.fn-btn input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.fn-btn svg { width: 18px; height: 18px; stroke-width: 2.3; }
.fn-btn:active { transform: scale(.97); }
.fn-btn.ghost { background: rgba(255,255,255,.08); color: #fff; }
.fn-btn.ghost:hover { background: rgba(255,255,255,.14); }
.fn-btn.primary { width: 100%; min-height: 52px; background: #fff; color: #000; font-size: 16px; box-shadow: 0 12px 30px -12px rgba(255,255,255,.4); }
.fn-btn.primary:hover { background: #ececee; }
.fn-get-row { display: flex; gap: 8px; margin-top: 10px; }
.fn-get-row .fn-btn { flex: 1; padding: 0 12px; }
.fn-small { margin: 12px 0 0; color: var(--dim); font-size: 12.5px; text-align: center; }

/* Info + SEO */
.fn-info { width: min(980px, calc(100% - 32px)); margin: 80px auto 0; padding-bottom: 90px; }
.fn-steps { display: grid; gap: 12px; }
.fn-steps > div { padding: 22px; border-radius: 22px; background: var(--card); box-shadow: inset 0 0 0 1px var(--line); }
.fn-steps b { display: grid; place-items: center; width: 30px; height: 30px; margin-bottom: 12px; border-radius: 50%; background: var(--red); color: #fff; font-size: 14px; }
.fn-steps h3 { font-size: 18px; }
.fn-steps p { margin: 6px 0 0; color: var(--mut); font-size: 14.5px; line-height: 1.55; }
.fn-info > h2 { margin: 70px 0 0; text-align: center; font-size: clamp(28px, 6vw, 44px); font-weight: 800; }
.fn-copy { max-width: 680px; margin: 14px auto 30px; color: var(--mut); font-size: 16px; line-height: 1.65; text-align: center; }
.fn-faq { border-radius: 22px; background: var(--card); box-shadow: inset 0 0 0 1px var(--line); overflow: hidden; }
.fn-faq details + details { border-top: 1px solid var(--line); }
.fn-faq summary { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 19px 22px; font-size: 16px; font-weight: 600; list-style: none; cursor: pointer; }
.fn-faq summary::-webkit-details-marker { display: none; }
.fn-faq summary em { position: relative; flex: none; width: 14px; height: 14px; }
.fn-faq summary em::before, .fn-faq summary em::after { content: ""; position: absolute; left: 0; top: 6px; width: 14px; height: 2px; border-radius: 2px; background: var(--mut); transition: transform .35s var(--ease), opacity .35s; }
.fn-faq summary em::after { transform: rotate(90deg); }
.fn-faq details[open] summary em::after { transform: none; opacity: 0; }
.fn-faq details > div { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .4s var(--ease); }
.fn-faq details[open] > div { grid-template-rows: 1fr; }
.fn-faq details > div > p { overflow: hidden; margin: 0; padding: 0 22px; color: var(--mut); font-size: 15px; line-height: 1.6; }
.fn-faq details[open] > div > p { padding-bottom: 19px; }
.fn-more { margin: 26px 0 0; color: var(--dim); font-size: 14px; text-align: center; line-height: 1.8; }
.fn-more a { color: #fff; text-decoration: none; font-weight: 600; }
.fn-more a:hover { color: var(--red); }

.fn-toast { position: fixed; z-index: 2147483645; left: 50%; bottom: calc(22px + env(safe-area-inset-bottom)); max-width: calc(100% - 32px); padding: 12px 18px; border-radius: 999px; background: #fff; color: #000;
  font-size: 14px; font-weight: 600; box-shadow: 0 16px 40px rgba(0,0,0,.45); transform: translate(-50%, 160%); transition: transform .5s var(--ease); pointer-events: none; }
.fn-toast.show { transform: translate(-50%, 0); }

/* Phones: preview on top, controls below */
@media (max-width: 760px) {
  .fn-desk { display: none; } .fn-mob { display: inline; }
  .fn-drop { top: 6%; width: 58%; border-radius: 10px; }
  .fn-devices { padding-right: 15%; }
  .fn-phone { width: 26%; bottom: 2%; }
  .fn-sec { padding: 16px; border-radius: 20px; }
}
@media (min-width: 640px) { .fn-steps { grid-template-columns: repeat(3, 1fr); } .fn-tpls { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1080px) {
  .fn-app { grid-template-columns: minmax(0, 1fr) 400px; gap: 30px; align-items: start; }
  .fn-stage { position: sticky; top: calc(84px + var(--nxb-h, 0px)); padding-top: 10px; }
  .fn-tpls { grid-template-columns: repeat(2, 1fr); }
  .fn-panel { max-height: none; }
}
@keyframes fnLive { 50% { opacity: .35; } }
@keyframes fnFadeOut { to { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .fn *, .fn *::before, .fn *::after { animation: none !important; transition: none !important; } }
