/* La página de Neboki. Oscura a propósito, como las apps: coral sobre casi negro y Geist.
   Se adapta al negocio elegido; ver neboki.js y negocios.js. */

@font-face {
  font-family: Geist;
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('./fonts/Geist-Variable.woff2') format('woff2');
}

@font-face {
  font-family: 'Geist Mono';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('./fonts/GeistMono-Variable.woff2') format('woff2');
}

:root {
  color-scheme: dark;
  --bg: #08090c;
  --bg-2: #0d0f14;
  --panel: #12141b;
  --panel-2: #191c25;
  --line: #222632;
  --line-2: #313747;
  --fg: #f4f5f7;
  --muted: #a3a9b5;
  --subtle: #737a88;
  --accent: #ff5a5f;
  --accent-2: #ff8a4c;
  --ok: #34d399;
  --way: #9b8cff;
  --grad: linear-gradient(100deg, #ff5a5f 0%, #ff5a5f 55%, #ff8a4c 100%);
  --sans: Geist, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Geist Mono', ui-monospace, Consolas, monospace;
  --r: 18px;
  --gut: clamp(16px, 4vw, 72px);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizelegibility;
}

body.locked {
  overflow: hidden;
}

a {
  color: inherit;
}

button {
  font-family: inherit;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.skip {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 60;
  background: var(--fg);
  color: var(--bg);
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 600;
}

.skip:focus {
  top: 12px;
}

.wrap {
  max-width: 1760px;
  margin: 0 auto;
  padding-left: max(var(--gut), env(safe-area-inset-left, 0px));
  padding-right: max(var(--gut), env(safe-area-inset-right, 0px));
}

h1,
h2,
h3,
h4 {
  margin: 0;
  text-wrap: balance;
  letter-spacing: -0.028em;
  line-height: 1.05;
}

h2 {
  font-size: clamp(32px, 4.2vw, 58px);
  font-weight: 680;
}

h3 {
  font-size: 19px;
  font-weight: 620;
  letter-spacing: -0.012em;
  line-height: 1.2;
}

p {
  margin: 0;
}

.grad {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.eyebrow {
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

.lead {
  color: var(--muted);
  font-size: clamp(17px, 1.5vw, 20px);
  max-width: 62ch;
}

.lead b {
  color: var(--fg);
  font-weight: 600;
}

section {
  padding-block: clamp(64px, 8vw, 112px);
  border-top: 1px solid var(--line);
}

.head {
  margin-bottom: 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 64px;
  align-items: end;
}

.head > * {
  min-width: 0;
}

/* #region Botones */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font: 600 15.5px var(--sans);
  color: #fff;
  background: var(--grad);
  border: 0;
  border-radius: 99px;
  padding: 13px 22px;
  cursor: pointer;
  box-shadow: 0 10px 30px -12px rgb(255 90 95 / 70%);
}

.btn svg {
  width: 18px;
  height: 18px;
}

.btn--ghost {
  background: transparent;
  color: var(--fg);
  border: 1px solid var(--line-2);
  box-shadow: none;
}

.btn--sm {
  padding: 9px 16px;
  font-size: 14px;
}

/* #endregion */

/* #region Barra superior: el negocio siempre a la vista */

.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  padding-top: env(safe-area-inset-top, 0px);
  background: rgb(8 9 12 / 70%);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, background 0.2s;
}

.nav.is-scrolled {
  background: rgb(8 9 12 / 88%);
  border-bottom-color: var(--line);
}

.nav .wrap {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.nav__links {
  display: flex;
  gap: 24px;
  margin-left: auto;
  font-size: 14.5px;
  color: var(--muted);
}

.nav__links a {
  text-decoration: none;
}

.nav__links a:hover {
  color: var(--fg);
}

.forpill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  background: var(--panel-2);
  border: 1px solid var(--line-2);
  border-radius: 99px;
  color: var(--muted);
  font-size: 14px;
  padding: 7px 8px 7px 14px;
  cursor: pointer;
}

.forpill b {
  color: var(--fg);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 34vw;
}

.forpill i {
  font-style: normal;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--grad);
  color: #fff;
  font-size: 12px;
}

.forpill:hover {
  border-color: var(--accent);
}

/* #endregion */

/* #region Portada */

.hero {
  border-top: 0;
  padding-block: clamp(44px, 6vw, 96px);
  background:
    radial-gradient(1100px 520px at 90% 0%, rgb(255 90 95 / 14%), transparent 70%),
    radial-gradient(800px 420px at 0% 100%, rgb(255 138 76 / 7%), transparent 70%);
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: clamp(36px, 5vw, 96px);
  align-items: center;
}

.hero__grid > * {
  min-width: 0;
}

.hero h1 {
  font-size: clamp(42px, 5.8vw, 96px);
  font-weight: 720;
  letter-spacing: -0.045em;
  line-height: 1.02;
}

.bizbtn {
  font: inherit;
  letter-spacing: inherit;
  color: var(--fg);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: left;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 0.07em;
  text-underline-offset: 0.12em;
}

.bizbtn svg {
  width: 0.5em;
  height: 0.5em;
  vertical-align: 0.12em;
  margin-left: 0.12em;
  color: var(--accent);
}

.bizbtn:hover {
  color: var(--accent);
}

.bizbtn.pulse {
  animation: pulse 2.2s ease-in-out 1s 2;
}

@keyframes pulse {
  50% {
    color: var(--accent);
  }
}

.hero .lead {
  margin-top: 26px;
  font-size: clamp(18px, 1.6vw, 22px);
}

.cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.try {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 30px;
  font-size: 14px;
  color: var(--subtle);
}

.try button {
  font-size: 14px;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--line-2);
  border-radius: 99px;
  padding: 6px 12px;
  cursor: pointer;
}

.try button:hover {
  color: var(--fg);
  border-color: var(--muted);
}

.try button[aria-pressed='true'] {
  background: var(--fg);
  color: var(--bg);
  border-color: var(--fg);
}

/* El kit */
.kit {
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 24px;
  padding: clamp(20px, 2.2vw, 32px);
  box-shadow: 0 50px 100px -50px rgb(0 0 0 / 90%);
}

.kit__label {
  font: 500 12px var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.kit__name {
  font-size: clamp(22px, 2vw, 30px);
  font-weight: 680;
  letter-spacing: -0.025em;
  line-height: 1.12;
  margin-top: 8px;
}

.kit__list {
  display: grid;
  gap: 8px;
  margin-top: 18px;
}

.kit__item {
  display: flex;
  gap: 12px;
  align-items: center;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 12px;
  animation: pop 0.45s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.kit__item > div {
  min-width: 0;
  flex: 1;
}

.kit__item b {
  font-weight: 600;
  font-size: 15px;
}

.kit__item small {
  display: block;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.35;
}

.kit__open {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--fg);
  text-decoration: none;
  border: 1px solid var(--line-2);
  border-radius: 99px;
  padding: 6px 12px;
  white-space: nowrap;
}

.kit__open svg {
  width: 14px;
  height: 14px;
  color: var(--accent);
}

.kit__open:hover {
  border-color: var(--accent);
}

.kit__sub {
  margin-top: 18px;
  font: 500 11.5px var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--subtle);
}

.kit__list {
  margin-top: 10px;
}

.kit__soon {
  margin-top: 4px;
}

.kit__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.kit__chips span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13.5px;
  color: var(--muted);
  border: 1px dashed var(--line-2);
  border-radius: 99px;
  padding: 5px 11px 5px 7px;
}

.kit__chips svg {
  width: 15px;
  height: 15px;
}

.kit__none {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px dashed var(--line-2);
  font-size: 13.5px;
  color: var(--subtle);
}

.kit__none:empty {
  display: none;
}

.lang {
  flex: none;
  width: 40px;
  height: 36px;
  border-radius: 99px;
  border: 1px solid var(--line-2);
  background: transparent;
  color: var(--muted);
  font: 600 13px var(--mono);
  cursor: pointer;
}

.lang:hover {
  color: var(--fg);
  border-color: var(--muted);
}

@keyframes pop {
  from {
    opacity: 0.001;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.ic {
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: var(--panel-2);
  border: 1px solid var(--line-2);
  color: var(--fg);
}

.ic svg {
  width: 20px;
  height: 20px;
}

.ic--hot {
  background: var(--grad);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 6px 16px -6px rgb(255 90 95 / 70%);
}

.stt {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font: 500 11.5px var(--mono);
  color: var(--muted);
  white-space: nowrap;
}

.stt::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--way);
}

.stt--live::before {
  background: var(--ok);
}

/* #endregion */

/* #region Las apps, vistas desde tu negocio */

.apps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.app {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.app__top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.app__top div {
  min-width: 0;
}

.app__top b {
  display: block;
  font-size: 17px;
  font-weight: 620;
}

.app__use {
  font-size: 16.5px;
  line-height: 1.4;
  font-weight: 500;
}

.app__gen {
  color: var(--subtle);
  font-size: 13.5px;
  margin-top: auto;
}

.app__open {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  color: var(--fg);
  border: 1px solid var(--line-2);
  border-radius: 99px;
  padding: 8px 14px;
}

.app__open svg {
  width: 15px;
  height: 15px;
  color: var(--accent);
}

.app__open:hover {
  border-color: var(--accent);
}

.lv {
  align-self: flex-start;
  font: 500 11.5px var(--mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 99px;
  padding: 5px 10px;
}

.app.k2 {
  border-color: rgb(255 90 95 / 50%);
  background: linear-gradient(180deg, rgb(255 90 95 / 8%), var(--panel) 55%);
}

.app.k2 .lv {
  background: var(--accent);
  color: #fff;
}

.app.k2 .app__open {
  background: var(--grad);
  border-color: transparent;
  color: #fff;
}

.app.k2 .app__open svg {
  color: #fff;
}

.app.k1 .lv {
  border: 1px solid var(--line-2);
  color: var(--muted);
}

.app.k0 {
  opacity: 0.5;
  background: transparent;
  border-style: dashed;
}

.app.k0 .lv {
  color: var(--subtle);
  border: 1px dashed var(--line-2);
}

.app.k0 .app__use {
  color: var(--muted);
  font-weight: 400;
}

.note {
  margin-top: 18px;
  color: var(--muted);
  font-size: 15px;
}

.note b {
  color: var(--fg);
}

/* #endregion */


/* #region Cómo funciona, reglas, historia */

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  counter-reset: s;
}

.stp {
  padding: 28px;
  border-radius: var(--r);
  background: var(--panel);
  border: 1px solid var(--line);
}

.stp::before {
  counter-increment: s;
  content: counter(s);
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--grad);
  color: #fff;
  font: 600 15px var(--sans);
  margin-bottom: 18px;
}

.stp p {
  color: var(--muted);
  margin-top: 8px;
  font-size: 15px;
}

.stp p b {
  color: var(--fg);
  font-weight: 600;
}

.rules {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}

.rule {
  border-top: 2px solid var(--accent);
  padding-top: 18px;
}

.rule p {
  color: var(--muted);
  margin-top: 8px;
  font-size: 15px;
}

.story {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: clamp(24px, 4vw, 56px);
  align-items: start;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: clamp(24px, 4vw, 56px);
}

.story__faces {
  display: flex;
}

.story__faces span {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 3px solid var(--panel);
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 20px;
  color: #fff;
  margin-left: -14px;
}

.story__faces span:first-child {
  margin-left: 0;
  background: #ff5a5f;
}

.story__faces span:nth-child(2) {
  background: #ff8a4c;
}

.story__faces span:nth-child(3) {
  background: #9b8cff;
}

.story h2 {
  font-size: clamp(26px, 3vw, 40px);
}

.story p {
  color: var(--muted);
  margin-top: 14px;
  max-width: 72ch;
}

/* #endregion */

/* #region Cierre y pie */

.final {
  text-align: center;
  background: radial-gradient(900px 320px at 50% 0%, rgb(255 90 95 / 17%), transparent 70%);
}

.final h2 {
  font-size: clamp(34px, 5vw, 72px);
}

.final .lead {
  margin: 18px auto 0;
}

.final .cta {
  justify-content: center;
}

footer {
  border-top: 1px solid var(--line);
  padding-block: 36px calc(36px + env(safe-area-inset-bottom, 0px));
  color: var(--subtle);
  font-size: 14px;
}

footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  justify-content: space-between;
}

footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

footer a {
  text-decoration: none;
}

footer a:hover {
  color: var(--fg);
}

/* #endregion */

/* #region Selector de negocio */

.picker {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgb(4 5 8 / 72%);
  backdrop-filter: blur(6px);
  padding: calc(env(safe-area-inset-top, 0px) + 4vh) max(16px, env(safe-area-inset-right, 0px))
    calc(env(safe-area-inset-bottom, 0px) + 4vh) max(16px, env(safe-area-inset-left, 0px));
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.picker__box {
  width: min(1100px, 100%);
  max-height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 24px;
  box-shadow: 0 40px 120px -30px rgb(0 0 0 / 95%);
  overflow: hidden;
}

.picker__head {
  padding: 22px 24px 18px;
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 14px;
}

.picker__title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.picker__title h3 {
  font-size: clamp(22px, 2.4vw, 28px);
}

.x {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line-2);
  background: transparent;
  color: var(--fg);
  font-size: 20px;
  cursor: pointer;
  flex: none;
}

.search {
  position: relative;
}

.search input {
  width: 100%;
  font: 500 19px var(--sans);
  color: var(--fg);
  background: var(--bg-2);
  border: 1px solid var(--line-2);
  border-radius: 14px;
  padding: 15px 16px 15px 48px;
  outline: none;
}

.search input::placeholder {
  color: var(--subtle);
  font-weight: 400;
}

.search input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgb(255 90 95 / 15%);
}

.search svg {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--subtle);
}

.picker__body {
  overflow-y: auto;
  padding: 8px 24px 24px;
}

.grp {
  padding-top: 18px;
}

.grp h4 {
  margin: 0 0 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  font: 500 12px var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--subtle);
}

.grp h4 svg {
  width: 16px;
  height: 16px;
  color: var(--accent);
}

.opts {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 6px;
}

.opt {
  text-align: left;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 11px;
  color: var(--fg);
  font-size: 14.5px;
  padding: 10px 12px;
  cursor: pointer;
}

.opt small {
  color: var(--subtle);
}

.opt:hover,
.opt.on {
  border-color: var(--accent);
  background: rgb(255 90 95 / 10%);
}

.opt[aria-current='true'] {
  border-color: var(--fg);
}

.none {
  color: var(--muted);
  padding: 24px 0;
}

.picker__foot {
  border-top: 1px solid var(--line);
  padding: 14px 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  align-items: center;
  color: var(--subtle);
  font-size: 13.5px;
}

/* #endregion */

@media (max-width: 1500px) {
  .apps {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 1200px) {
  .apps {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 1100px) {
  .hero__grid,
  .head {
    grid-template-columns: 1fr;
  }

  .apps,
  .rules {
    grid-template-columns: 1fr 1fr;
  }

  .steps {
    grid-template-columns: 1fr;
  }

  .nav__links {
    display: none;
  }

  .forpill {
    margin-left: auto;
  }
}

@media (max-width: 640px) {
  .apps,
  .rules,
  .story {
    grid-template-columns: 1fr;
  }

  .forpill span {
    display: none;
  }

  .kit__item {
    flex-wrap: wrap;
  }

  .picker__head,
  .picker__body,
  .picker__foot {
    padding-left: 16px;
    padding-right: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .kit__item,
  .bizbtn.pulse {
    animation: none;
  }
}
