/* Página de inicio · estilos propios */
body {
  min-height: 100%;
}
.fabs {
  position: fixed;
  top: 12px;
  right: 14px;
  z-index: 20;
  display: flex;
  gap: 2px;
  padding: 2px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--bg) 80%, transparent);
  backdrop-filter: blur(8px);
}
.fabs .icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
}
.fabs .icon-btn:hover {
  background: var(--hover);
}
.title {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 18px;
  font-family: var(--brand);
  font-size: 46px;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.1;
}
.title-logo {
  display: inline-grid;
  width: 46px;
  height: 46px;
}
.title-logo svg {
  width: 100%;
  height: 100%;
}
.home {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px 48px;
}

.hero {
  padding: 56px 0 32px;
  text-align: center;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.hero h1 {
  margin: 0;
  font-size: 40px;
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.1;
  text-wrap: balance;
}
.hero p {
  margin: 12px auto 0;
  max-width: 520px;
  color: var(--text-2);
  font-size: 15px;
  line-height: 1.55;
  text-wrap: pretty;
}

.search {
  position: relative;
  max-width: 560px;
  margin: 28px auto 0;
  text-align: left;
}
.search > .ic {
  position: absolute;
  left: 14px;
  top: 13px;
  width: 18px;
  height: 18px;
  color: var(--text-3);
  pointer-events: none;
}
.search > kbd {
  position: absolute;
  right: 12px;
  top: 12px;
  pointer-events: none;
}
.search input {
  width: 100%;
  height: 44px;
  padding: 0 40px 0 42px;
  border: 1px solid var(--border-2);
  border-radius: 12px;
  background: var(--panel);
  font-size: 15px;
  outline: none;
  box-shadow: var(--shadow-sm);
  transition:
    border-color 0.12s,
    box-shadow 0.12s;
}
.search input::-webkit-search-cancel-button {
  display: none;
}
.search input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.search input:focus ~ kbd,
.search input:not(:placeholder-shown) ~ kbd {
  opacity: 0;
}
.results {
  position: absolute;
  left: 0;
  right: 0;
  top: 50px;
  z-index: 10;
  max-height: 360px;
  overflow: auto;
  padding: 6px;
  background: var(--panel);
  border: 1px solid var(--border-2);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  animation: pop 0.14s var(--ease);
}
.res {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: 8px;
  text-decoration: none;
}
.res.active {
  background: var(--accent-soft);
}
.res .app-icon {
  --s: 26px;
}
.res-t {
  font-weight: 500;
}
.res-s {
  color: var(--text-3);
  font-size: 12px;
  margin-left: auto;
  white-space: nowrap;
}
.res-none {
  padding: 18px;
  text-align: center;
  color: var(--text-3);
}

.apps {
  display: grid;
  gap: 30px;
  margin-top: 36px;
}
.group-t {
  margin: 0 0 6px 12px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-3);
}
.group-g {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}
.apps.filtering .group:not(:has(.match)) {
  opacity: 0.35;
}
.tile {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 22px 10px 18px;
  border-radius: 18px;
  text-decoration: none;
  text-align: center;
  transition:
    background-color 0.15s,
    opacity 0.15s;
}
.tile:hover,
.tile:focus-visible {
  background: var(--panel);
  box-shadow: 0 0 0 1px var(--border);
}
.tile .app-icon {
  --s: 76px;
  transition: transform 0.2s var(--ease);
}
.tile:hover .app-icon {
  transform: translateY(-2px);
}
.tile:active .app-icon {
  transform: scale(0.96);
}
.tile-name {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.tile-desc {
  margin-top: -6px;
  font-size: 12px;
  color: var(--text-2);
  line-height: 1.4;
  text-wrap: balance;
}
.tile kbd {
  position: absolute;
  top: 10px;
  right: 10px;
  opacity: 0;
  transition: opacity 0.12s;
}
.tile:hover kbd,
.tile:focus-visible kbd {
  opacity: 1;
}
.tile .recent {
  position: absolute;
  top: 20px;
  left: calc(50% + 40px);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 2px var(--bg);
}
.apps.filtering .tile:not(.match) {
  opacity: 0.28;
}

.section-h {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin: 56px 0 14px;
}
.section-h h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.section-h span {
  color: var(--text-3);
  font-size: 12.5px;
}
.catalog {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.cat {
  display: flex;
  flex-direction: column;
  padding: 16px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
}
.cat-h {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.cat-h .app-icon {
  --s: 30px;
}
.cat-h strong {
  font-size: 14px;
  letter-spacing: -0.01em;
}
.cat-h a.btn {
  margin-left: auto;
}
.cat ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
}
.cat li a,
.cat li span {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  margin: 0 -8px;
  border-radius: 6px;
  font-size: 12.5px;
  color: var(--text-2);
  text-decoration: none;
}
.cat li a:hover {
  background: var(--hover);
  color: var(--text);
}
.cat li a .ic {
  width: 13px;
  height: 13px;
  margin-left: auto;
  opacity: 0;
  color: var(--text-3);
  transition: opacity 0.1s;
}
.cat li a:hover .ic {
  opacity: 1;
}
.cat li i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--border-2);
  flex: none;
}

.principles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin-top: 56px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
}
.principles h3 {
  margin: 0 0 4px;
  font-size: 13.5px;
  font-weight: 600;
}
.principles p {
  margin: 0;
  color: var(--text-2);
  font-size: 12.5px;
  line-height: 1.55;
}
.eyebrow {
  margin: 28px auto 4px !important;
  color: var(--text-3) !important;
  font-size: 14px !important;
  font-weight: 500;
}
.tip {
  margin: 14px auto 0;
  max-width: 560px;
  color: var(--text-3);
  font-size: 12.5px;
  min-height: 1.5em;
}
.tip kbd {
  margin: 0 1px;
}
.most {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 6px;
  margin: 18px auto 0;
}
.most-l {
  color: var(--text-3);
  font-size: 12px;
  margin-right: 2px;
}
.most a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 30px;
  padding: 0 11px 0 4px;
  border: 1px solid var(--border);
  border-radius: 99px;
  background: var(--panel);
  font-size: 12.5px;
  font-weight: 500;
  text-decoration: none;
  transition:
    background-color 0.12s,
    border-color 0.12s;
}
.most a:hover {
  background: var(--hover);
  border-color: var(--border-2);
}
/* Redondo, a juego con la píldora que lo rodea */
.most .app-icon {
  border-radius: 50%;
}
.nudge {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
  max-width: 640px;
  margin: 18px auto 0;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(234, 179, 8, 0.1);
  border: 1px solid rgba(234, 179, 8, 0.4);
  font-size: 13px;
  color: var(--text);
}
.tip-next {
  margin-left: 2px;
  padding: 0 2px;
  border: 0;
  background: none;
  color: var(--text-3);
  font-size: 12px;
  opacity: 0.75;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 2px;
  transition:
    opacity 0.12s,
    text-decoration-color 0.12s;
}
.tip-next:hover,
.tip-next:focus-visible {
  opacity: 1;
  text-decoration-color: currentColor;
}
.tile-wrap {
  position: relative;
}
.tile-wrap .tile {
  height: 100%;
}
.heart {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  color: var(--text-3);
  opacity: 0;
  transition:
    opacity 0.12s,
    color 0.12s,
    transform 0.12s;
}
.heart svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linejoin: round;
}
.tile-wrap:hover .heart,
.heart:focus-visible {
  opacity: 1;
}
.heart:hover {
  color: #e5484d;
  background: var(--hover);
}
.heart:active {
  transform: scale(0.9);
}
.heart.on {
  opacity: 1;
  color: #e5484d;
}
.heart.on svg {
  fill: currentColor;
}
.heart.pop svg {
  animation: heartPop 0.35s var(--ease);
}
@keyframes heartPop {
  40% {
    transform: scale(1.35);
  }
}
.group[data-group="fav"] .group-t {
  color: #e5484d;
}
@media (hover: none) {
  .heart {
    opacity: 0.55;
  }
}
.install-line {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 4px 8px;
  margin: 8px auto 0;
  color: var(--text-3);
  font-size: 12.5px;
}
.steps {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: s;
  display: grid;
  gap: 10px;
}
.steps li {
  counter-increment: s;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-2);
}
.steps li::before {
  content: counter(s);
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
  font-size: 12px;
}
.steps b {
  color: var(--text);
  font-weight: 600;
}
.browser-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 14px;
}
.install-why {
  margin: 14px 0 0;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--sunken);
  font-size: 12.5px;
  color: var(--text-2);
  line-height: 1.5;
}
.install-ok {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--ok-soft);
  color: var(--ok);
  font-size: 13px;
  font-weight: 500;
}
.data-block {
  margin-top: 48px;
  padding: 16px 20px 0;
  border-top: 1px solid var(--border);
}
.data-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 4px;
}
.data-actions .muted {
  margin-right: 8px;
}
.dlg-p {
  margin: -6px 0 14px;
  color: var(--text-2);
  font-size: 13px;
  line-height: 1.55;
}
.btn.danger-solid {
  background: var(--danger);
  border-color: var(--danger);
  color: #fff;
}
.btn.danger-solid:hover {
  filter: brightness(1.08);
}
.legal-foot {
  margin-top: 28px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
}
.legal-cols {
  display: grid;
  grid-template-columns: 1fr 1.4fr 1.4fr;
  gap: 28px;
}
.legal-cols h3 {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 600;
}
.legal-cols p {
  margin: 0;
  color: var(--text-2);
  font-size: 12.5px;
  line-height: 1.6;
}
.legal-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 5px;
  font-size: 12.5px;
}
.legal-links a {
  color: var(--text-2);
  text-decoration: none;
}
.legal-links a:hover {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.foot {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 28px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  color: var(--text-3);
  font-size: 12px;
}
.foot span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.foot #footCount {
  display: block;
}
.foot-secret {
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.foot-secret:focus-visible { outline: 1px dashed currentColor; outline-offset: 3px; }

@media (max-width: 900px) {
  .group-g {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .catalog {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 600px) {
  .home {
    padding: 0 16px 32px;
  }
  .hero {
    padding: 44px 0 24px;
  }
  .title {
    font-size: 34px;
  }
  .title-logo {
    width: 36px;
    height: 36px;
  }
  .tile .app-icon {
    --s: 60px;
  }
  .tile-desc,
  .tile kbd {
    display: none;
  }
  .catalog,
  .principles,
  .legal-cols {
    grid-template-columns: minmax(0, 1fr);
  }
  .foot {
    flex-direction: column;
  }
}

/* Catálogo plegable (details) */
.cat-h {
  list-style: none;
  cursor: default;
}
.cat-h::-webkit-details-marker {
  display: none;
}
.cat-n {
  display: none;
}
.cat:not([open]) .cat-h {
  margin-bottom: 0;
}

/* Pantallas táctiles: objetivos de al menos 40 px */
:root[data-input="touch"] .heart {
  top: 4px;
  left: 4px;
  width: 40px;
  height: 40px;
}
:root[data-input="touch"] .heart svg {
  width: 18px;
  height: 18px;
}
:root[data-input="touch"] .tip-next {
  min-height: 32px;
  padding: 0 8px;
}
:root[data-input="touch"] .search input {
  font-size: 16px;
}
:root[data-input="touch"] .search > kbd {
  display: none;
}
:root[data-input="touch"] .cat li a,
:root[data-input="touch"] .cat li span {
  min-height: 42px;
  font-size: 14px;
}

@media (max-width: 600px) {
  /* Los botones flotantes se quedan arriba y no tapan el contenido al bajar */
  .fabs {
    position: absolute;
  }
  .catalog {
    gap: 8px;
  }
  .cat {
    padding: 0;
  }
  .cat-h {
    min-height: 56px;
    margin: 0;
    padding: 8px 12px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  .cat-n {
    display: inline-grid;
    place-items: center;
    min-width: 22px;
    height: 20px;
    margin-left: auto;
    padding: 0 6px;
    border-radius: 10px;
    background: var(--hover);
    color: var(--text-3);
    font-size: 11.5px;
    font-variant-numeric: tabular-nums;
  }
  .cat-h a.btn {
    margin-left: 0;
  }
  .cat-h::after {
    content: "";
    width: 8px;
    height: 8px;
    margin: 0 4px 0 2px;
    border-right: 2px solid var(--text-3);
    border-bottom: 2px solid var(--text-3);
    transform: rotate(45deg) translateY(-2px);
    transition: transform 0.15s var(--ease);
  }
  .cat[open] .cat-h::after {
    transform: rotate(-135deg) translate(-2px, 0);
  }
  .cat ul {
    padding: 0 12px 8px;
  }
  .cat li a,
  .cat li span {
    margin: 0 -4px;
    padding: 6px 4px;
  }
}
:root[data-input="touch"] .legal-links {
  gap: 0;
}
:root[data-input="touch"] .legal-links a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  font-size: 14px;
}
@media (max-width: 600px) {
  .section-h {
    flex-direction: column;
    gap: 2px;
    margin-top: 44px;
  }
}

/* Pantallas táctiles: sin estados «hover» que se quedan pegados al tocar (corazón y tarjetas) */
@media (hover: none) {
  .tile:hover:not(:focus-visible) { background: none; box-shadow: none; }
  .tile:hover .app-icon { transform: none; }
  .heart:hover { background: none; color: var(--text-3); }
  .heart.on:hover { color: #e5484d; }
  .heart:focus:not(:focus-visible) { outline: none; }
}
:root[data-input="touch"] .tile-wrap { -webkit-user-select: none; user-select: none; }

/* Herramientas destacadas */
.featured { margin-top: 40px; }
.feat-h { margin-top: 0; align-items: center; }
.feat-hide { font-size: 12.5px; color: var(--text-3); text-decoration: none; }
.feat-hide:hover { color: var(--text); text-decoration: underline; }
.feat-g { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.feat { position: relative; display: flex; flex-direction: column; gap: 12px; padding: 18px; border: 1px solid var(--border); border-radius: 18px; overflow: hidden;
  background: linear-gradient(160deg, color-mix(in srgb, var(--c) 12%, var(--panel)) 0%, var(--panel) 55%); transition: border-color .15s, transform .2s var(--ease), box-shadow .2s; }
.feat:hover { border-color: color-mix(in srgb, var(--c) 45%, var(--border)); box-shadow: 0 10px 26px -14px color-mix(in srgb, var(--c) 70%, transparent); transform: translateY(-2px); }
.feat-main { display: flex; align-items: center; gap: 14px; text-decoration: none; color: inherit; }
.feat-main .app-icon { flex: none; box-shadow: 0 6px 16px -6px color-mix(in srgb, var(--c) 60%, transparent); }
.feat-txt { display: grid; gap: 3px; min-width: 0; }
.feat-txt strong { font-size: 16px; letter-spacing: -.01em; }
.feat-txt span { font-size: 12.5px; line-height: 1.4; color: var(--text-2); }
.feat-go { align-self: flex-start; margin-top: auto; gap: 6px; }
.feat-go .ic { width: 14px; height: 14px; }
@media (max-width: 900px) { .feat-g { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) {
  .featured { margin-top: 28px; }
  .feat-g { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .feat { padding: 14px; }
  .feat-h { flex-direction: row; }
}
:root[data-input="touch"] .feat-go { min-height: 40px; }

/* Tarjetas destacadas más compactas */
.feat-g { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px; }
.feat { gap: 10px; padding: 12px 14px; border-radius: 14px; }
.feat-main { gap: 11px; }
.feat-txt strong { font-size: 14.5px; }
.feat-txt span { font-size: 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.feat-go { height: 26px; font-size: 12px; }
@media (max-width: 600px) { .feat-g { grid-template-columns: minmax(0, 1fr); gap: 8px; } .feat { padding: 11px 12px; } }

/* «Ver más» dentro de cada app del catálogo */
.cat li.x[hidden] { display: none; }
.cat-more { display: inline-flex; align-items: center; gap: 6px; margin: 4px -8px 0; padding: 6px 8px; border: 0; border-radius: 6px; background: none; color: var(--accent); font: 500 12.5px var(--sans); cursor: pointer; }
.cat-more::after { content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translate(-2px, -2px); transition: transform .15s; }
.cat-more[aria-expanded="true"]::after { transform: rotate(-135deg) translate(-2px, -2px); }
.cat-more:hover { background: var(--hover); }
:root[data-input="touch"] .cat-more { min-height: 40px; font-size: 14px; }
