
.inner-page {
  background: #f7f4ee;
}

.archive-hero {
  padding: 92px 0 58px;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgb(8 20 29 / 82%), rgb(8 20 29 / 35%)),
    url("../img/hero-cumbres.jpg") center 43% / cover;
  color: white;
}

.archive-hero h1 {
  margin: 0 0 16px;
  font-size: clamp(4.4rem, 9vw, 8rem);
  line-height: .9;
}

.archive-summary {
  margin: 0;
  color: rgb(255 255 255 / 78%);
  font-size: 1.18rem;
}

.archive-section {
  padding: 48px 0 80px;
}

.archive-toolbar {
  display: grid;
  grid-template-columns: minmax(280px, 1.6fr) repeat(3, minmax(155px, 1fr)) auto;
  gap: 12px;
  align-items: end;
}

.archive-toolbar label {
  display: grid;
  gap: 8px;
  color: var(--ink-soft);
  font-weight: 800;
}

.archive-search input {
  min-height: 62px;
  padding: 0 18px;
  border: 1.5px solid var(--line-dark);
  border-radius: 12px;
  background: white;
  font-size: 1.05rem;
}

.archive-results-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin: 28px 0 18px;
}

.archive-results-line p {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
}

.view-switch {
  display: flex;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: white;
}

.view-switch button {
  padding: 8px 12px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  cursor: pointer;
}

.view-switch button.active {
  background: var(--ink);
  color: white;
}

.summit-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.summit-card {
  position: relative;
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 390px;
  padding: 20px;
  overflow: hidden;
  border: 1px solid #dad5cb;
  border-radius: 16px;
  background: rgb(255 255 255 / 52%);
  color: var(--ink);
  text-decoration: none;
  transition: transform .18s ease, box-shadow .18s ease;
}

.summit-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 18px 45px rgb(20 30 40 / 12%);
}

.summit-card-top {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: .75rem;
}

.summit-status,
.summit-type {
  padding: 5px 8px;
  border-radius: 999px;
  font-weight: 850;
}

.summit-status.done { color: #075c36; background: #dcf5e6; }
.summit-status.pending { color: #8f1515; background: #fee3e3; }
.summit-type { color: var(--muted); background: #eceae4; }

.summit-card-mountain {
  height: 112px;
  margin: 18px -5px 2px;
  color: #d7d1c5;
}

.summit-card-mountain svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.summit-card h2 {
  margin: 0 0 4px;
  font-size: 1.48rem;
  line-height: 1.08;
}

.summit-alt {
  min-height: 1.4em;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: .83rem;
}

.summit-meta {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 3px 12px;
  align-items: end;
}

.summit-meta strong {
  grid-row: 1 / 3;
  font-size: 2rem;
}

.summit-meta strong small {
  font-size: .45em;
}

.summit-meta span {
  color: var(--muted);
  font-size: .82rem;
}

.summit-detail {
  margin: 16px 0 10px;
  color: var(--muted);
  font-size: .84rem;
  line-height: 1.45;
}

.summit-open {
  margin-top: auto;
  color: var(--orange);
  font-weight: 850;
}

.summit-grid.list-view {
  grid-template-columns: 1fr;
}

.summit-grid.list-view .summit-card {
  min-height: 0;
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
}

.summit-grid.list-view .summit-card-mountain {
  grid-row: 1 / 7;
  height: 100px;
  margin: 0;
}

.archive-empty {
  grid-column: 1 / -1;
  padding: 60px 20px;
  border: 1px dashed var(--line-dark);
  border-radius: 16px;
  text-align: center;
}

.popup-detail-link {
  display: block;
  margin-top: 13px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  color: var(--orange);
  text-decoration: none;
  font-weight: 850;
}

/* Summit detail */
.summit-detail-hero {
  padding: 80px 0 62px;
  color: white;
  background:
    linear-gradient(90deg, rgb(6 18 27 / 86%), rgb(6 18 27 / 30%)),
    url("../img/hero-cumbres.jpg") center 42% / cover;
}

.back-link {
  color: rgb(255 255 255 / 78%);
  text-decoration: none;
}

.detail-status-line {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 38px 0 14px;
}

.detail-status-line > span:last-child {
  color: rgb(255 255 255 / 68%);
}

.summit-detail-hero h1 {
  max-width: 1100px;
  margin: 0;
  font-size: clamp(4.6rem, 9vw, 9rem);
  line-height: .86;
}

.detail-alt-name {
  margin: 14px 0 24px;
  color: rgb(255 255 255 / 72%);
  font-size: 1.2rem;
}

.detail-hero-facts {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 12px 22px;
}

.detail-hero-facts strong {
  font-size: 3.2rem;
}

.detail-hero-facts strong small {
  font-size: .4em;
}

.detail-hero-facts span {
  color: rgb(255 255 255 / 78%);
  font-weight: 700;
}

.detail-body {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(280px, .75fr);
  gap: 34px;
  padding-top: 56px;
  padding-bottom: 80px;
}

.detail-main {
  display: grid;
  gap: 64px;
}

.detail-main h2,
.detail-sidebar h2 {
  margin: 0 0 20px;
  font-size: 2.3rem;
}

#summit-map {
  height: 480px;
  border-radius: 18px;
  overflow: hidden;
}

.ascent-list {
  display: grid;
  gap: 16px;
}

.ascent-record,
.detail-facts-card,
.related-card {
  padding: 26px;
  border: 1px solid #dcd6cb;
  border-radius: 16px;
  background: rgb(255 255 255 / 48%);
}

.ascent-record h3 {
  margin: 0 0 5px;
  font-size: 1.65rem;
}

.ascent-trip {
  color: var(--muted);
}

.ascent-record dl,
.detail-facts-card dl {
  display: grid;
  gap: 13px;
  margin: 22px 0;
}

.ascent-record dl div,
.detail-facts-card dl div {
  display: grid;
  grid-template-columns: 135px 1fr;
  gap: 16px;
}

dt {
  color: var(--muted);
  font-size: .82rem;
  font-weight: 800;
}

dd {
  margin: 0;
  font-weight: 700;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.detail-action {
  padding: 10px 13px;
  border-radius: 10px;
  background: var(--ink);
  color: white;
  text-decoration: none;
  font-weight: 800;
}

.ascent-notes {
  margin: 20px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.detail-sidebar {
  display: grid;
  align-content: start;
  gap: 18px;
}

.related-summit {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}

.related-summit:last-child {
  border-bottom: 0;
}

.related-summit strong {
  white-space: nowrap;
}

.detail-loading {
  min-height: 60vh;
  display: grid;
  place-content: center;
  text-align: center;
}

@media (max-width: 1100px) {
  .archive-toolbar {
    grid-template-columns: repeat(2, 1fr);
  }

  .archive-search {
    grid-column: 1 / -1;
  }

  .summit-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 820px) {
  .archive-hero {
    padding-top: 72px;
  }

  .archive-toolbar {
    grid-template-columns: 1fr;
  }

  .archive-search {
    grid-column: auto;
  }

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

  .summit-grid.list-view .summit-card {
    display: flex;
  }

  .detail-body {
    grid-template-columns: 1fr;
  }

  .summit-detail-hero h1 {
    font-size: clamp(3.7rem, 16vw, 6rem);
  }

  #summit-map {
    height: 380px;
  }
}


/* v12 · Distinct section identity */
.archive-hero:not(.trip-archive-hero) {
  background:
    linear-gradient(90deg, rgb(10 24 34 / 88%), rgb(10 24 34 / 24%)),
    linear-gradient(0deg, rgb(3 18 10 / 18%), transparent),
    url("../img/hero-cumbres.jpg") center 29% / cover;
}

.summit-detail-hero {
  background:
    linear-gradient(90deg, rgb(8 20 29 / 90%), rgb(8 20 29 / 20%)),
    url("../img/hero-cumbres.jpg") center 35% / cover;
}

/* Sprint 001 · compañeros enlazados desde cada ascensión */
.ascent-people {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.ascent-people a,
.ascent-people span {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 999px;
  background: #ece9e2;
  color: inherit;
  font-size: .82rem;
  font-weight: 800;
  line-height: 1.25;
  text-decoration: none;
}

.ascent-people a {
  transition: background-color .2s ease, color .2s ease, transform .2s ease;
}

.ascent-people a:hover,
.ascent-people a:focus-visible {
  background: var(--green-dark, #075c36);
  color: #fff;
  transform: translateY(-1px);
}
