/* Portada comercial. El menú circular sigue en hub.css. */
html:has(body.is-portada) {
  height: auto;
  overflow: auto;
  background: #f4f7fb;
}
body.is-portada {
  height: auto;
  overflow: auto;
  background: #f4f7fb;
  color: #1b2430;
}
html.want-hub,
html.want-hub body {
  height: 100%;
  overflow: hidden;
  background: #05080f;
  color: #fff;
}
html.want-hub #portada-view { display: none !important; }
html.want-hub #hub-view { display: flex !important; }

#portada-view.active {
  display: block;
  min-height: 100dvh;
  max-width: 100%;
  overflow-x: hidden;
  background: #f4f7fb;
  color: #1b2430;
}

.pt-top {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid #e6ebf2;
}
.pt-top-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.pt-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  margin-right: auto;
}
.pt-brand strong { display: block; font-size: 1.05rem; letter-spacing: -0.02em; }
.pt-brand small { display: none; color: #6b7785; }
.pt-nav {
  display: none;
  gap: 18px;
  align-items: center;
}
.pt-nav a {
  color: #243041;
  text-decoration: none;
  font-weight: 650;
  font-size: 0.95rem;
}
.pt-nav a:hover { color: #4293E1; }
.pt-actions { display: flex; gap: 8px; align-items: center; }
.pt-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid #d5deea;
  background: #fff;
  color: #243041;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  font: inherit;
}
.pt-btn-primary {
  background: #4293E1;
  border-color: #4293E1;
  color: #fff;
}

.pt-hero {
  position: relative;
  min-height: 380px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 56px 16px 64px;
  color: #fff;
  background:
    linear-gradient(180deg, rgba(16, 24, 36, 0.28), rgba(16, 24, 36, 0.38)),
    url("/assets/img/portada-hero.jpg?v=20261005home2") center 42% / cover no-repeat;
  overflow: hidden;
}
.pt-hero h1 {
  margin: 0 0 8px;
  font-size: clamp(1.8rem, 4vw, 3rem);
  letter-spacing: -0.03em;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.25);
}
.pt-hero p {
  margin: 0 0 22px;
  font-size: 1.05rem;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.25);
}
.pt-search {
  position: relative;
  z-index: 1;
  width: min(920px, 100%);
  max-width: 100%;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  background: #fff;
  color: #1b2430;
  border-radius: 16px;
  padding: 10px;
  box-shadow: 0 16px 40px rgba(16, 32, 56, 0.18);
}
.pt-search select,
.pt-search input {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  appearance: none;
  -webkit-appearance: none;
  border: none;
  outline: none;
  box-shadow: none;
  background-color: #f4f7fb;
  background-image: none;
  border-radius: 10px;
  min-height: 46px;
  padding: 0 12px;
  font: inherit;
  color: inherit;
}
.pt-search select {
  padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%23627484' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round' d='M1 1.5 6 6.5 11 1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 8px;
}
.pt-search select:focus,
.pt-search input:focus {
  outline: none;
  box-shadow: none;
}
.pt-search button {
  min-height: 46px;
  border: 0;
  border-radius: 10px;
  background: #4293E1;
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.pt-wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 8px 16px 110px;
}
.pt-cats {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 8px 0 16px;
}
.pt-cat-row {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 2px 2px 6px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}
.pt-cat.is-join {
  background: #4293E1;
  color: #fff;
  border-color: #4293E1;
}
.pt-cat.is-join span { color: #fff; }
.pt-cat {
  flex: 0 0 86px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: #243041;
  font-weight: 700;
  font-size: 0.82rem;
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  font-family: inherit;
}
.pt-cat span {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid #e6ebf2;
  box-shadow: 0 8px 18px rgba(28, 45, 72, 0.06);
  display: grid;
  place-items: center;
  color: #4293E1;
}
.pt-cat svg { width: 26px; height: 26px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.pt-ads h2 {
  margin: 8px 0 12px;
  font-size: 1.25rem;
}
.pt-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.pt-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid #e6ebf2;
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 8px 20px rgba(28, 45, 72, 0.05);
}
.pt-cover {
  position: relative;
  aspect-ratio: 16 / 10;
  background: #e8eef5 center / cover no-repeat;
  overflow: hidden;
}
.pt-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.pt-card-body { padding: 12px 14px 14px; }
.pt-kicker {
  margin: 0 0 4px;
  color: #4293E1;
  font-size: 0.78rem;
  font-weight: 700;
}
.pt-card h3 { margin: 0; font-size: 1.05rem; }
.pt-place { margin: 4px 0 0; color: #6b7785; font-size: 0.9rem; }
.pt-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}
.pt-badge {
  flex: 0 0 auto;
  color: #4293E1;
  font-size: 0.78rem;
  font-weight: 800;
}
.pt-empty, .pt-loading { color: #6b7785; padding: 12px 0; }
.pt-foot {
  display: none;
  text-align: center;
  color: #6b7785;
  font-size: 0.82rem;
  padding: 8px 16px 24px;
}
.pt-foot a { color: #4293E1; }

.pt-tab {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: #fff;
  border-top: 1px solid #e6ebf2;
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}
.pt-tab a, .pt-tab button {
  border: 0;
  background: transparent;
  color: #6b7785;
  text-decoration: none;
  font: inherit;
  font-size: 0.68rem;
  font-weight: 700;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: pointer;
  padding: 4px 0;
}
.pt-tab .is-on { color: #4293E1; }
.pt-tab .pt-plus {
  width: 46px;
  height: 46px;
  margin-top: -18px;
  border-radius: 50%;
  background: #4293E1;
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 1.6rem;
  line-height: 1;
  box-shadow: 0 8px 16px rgba(66, 147, 225, 0.35);
}

@media (min-width: 900px) {
  .pt-brand small { display: block; }
  .pt-nav { display: flex; }
  .pt-hero { min-height: 460px; padding: 72px 24px 80px; }
  .pt-search {
    grid-template-columns: 1.15fr 1fr 1.35fr auto;
    align-items: stretch;
    gap: 0;
    border-radius: 14px;
    padding: 6px;
  }
  .pt-search select,
  .pt-search input {
    background-color: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    padding: 0 16px;
  }
  .pt-search select {
    padding-right: 32px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%23627484' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round' d='M1 1.5 6 6.5 11 1.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 12px 8px;
  }
  .pt-search button {
    margin-left: 8px;
    padding: 0 28px;
    border-radius: 10px;
  }
  .pt-cats {
    gap: 14px;
    overflow: visible;
    padding: 18px 0 22px;
  }
  .pt-cat-row {
    display: grid;
    overflow: visible;
    gap: 12px;
  }
  .pt-cat-row { grid-template-columns: repeat(8, minmax(0, 1fr)); }
  .pt-cat {
    flex: none;
    background: #fff;
    border: 1px solid #e7edf4;
    border-radius: 16px;
    box-shadow: 0 8px 18px rgba(28, 45, 72, 0.05);
    min-height: 112px;
    padding: 14px 6px 12px;
    justify-content: center;
    font-size: 0.82rem;
  }
  .pt-cat.is-join {
    background: #4293E1;
    color: #fff;
    border-color: #4293E1;
  }
  .pt-cat span {
    width: auto;
    height: auto;
    background: transparent;
    border: 0;
    box-shadow: none;
    border-radius: 0;
  }
  .pt-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 16px;
  }
  .pt-cover { aspect-ratio: 16 / 10; }
  .pt-tab { display: none; }
  .pt-wrap { padding-bottom: 48px; }
  .pt-foot { display: block; }
}
@media (max-width: 720px) {
  .pt-actions { display: none; }
  .pt-top-inner { padding: 10px 14px; }
  .pt-hero { min-height: 320px; padding: 36px 14px 42px; }
  .pt-hero h1 { font-size: 1.65rem; }
  .pt-wrap { padding: 4px 12px calc(92px + env(safe-area-inset-bottom)); }
  .pt-search { width: 100%; }
}
