/* /var/www/html/jdserver/2026/modules/climate_pro_ranking/climate_pro_ranking.css
 * JDServer-Webs v6.8 — ranking anual (T° y lluvia)
 */

#climate-pro-ranking{
  max-width: 1120px;
  margin: 18px auto 64px; /* FIX: espacio abajo como los demás */
}

.climatepro-rank{
  border-radius: 18px;
  border: 1px solid var(--border);
  background: var(--card);
  box-shadow: var(--shadow-1);
  padding: 14px 18px 18px;
}

.climatepro-rank-head{
  margin-bottom: 10px;
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:12px;
  flex-wrap: wrap;
}

.climatepro-rank-title{
  margin:0;
  font-size:1.05rem;
  font-weight:600;
}

.climatepro-rank-sub{
  margin:3px 0 0;
  font-size:.88rem;
  color:var(--muted);
}

.climatepro-rank-note{
  margin-top:6px;
  font-size:.82rem;
  color:var(--muted);
}

.climatepro-rank-range{
  font-size:.84rem;
  color:var(--muted);
  white-space:nowrap;
}

.climatepro-rank-loading{
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px dashed var(--border);
  background: color-mix(in oklab, var(--card), var(--brand-50) 8%);
  color: var(--muted);
}

.climatepro-rank-empty{
  margin-top:10px;
  font-size:.9rem;
  color:var(--muted);
}

.climatepro-rank-table-wrap{
  margin-top:10px;
  overflow-x:auto;
}

.climatepro-rank-table{
  width:100%;
  border-collapse:collapse;
  font-size:.88rem;
  min-width:520px;
}

.climatepro-rank-table thead th{
  text-align:left;
  padding:6px 8px;
  border-bottom:1px solid var(--border);
  white-space:nowrap;
}

.climatepro-rank-table tbody td{
  padding:6px 8px;
  border-bottom:1px solid color-mix(in oklab, var(--border) 60%, transparent);
  vertical-align:middle;
}

.climatepro-rank-year{ font-weight:500; }

.cp-rank-chip{
  display:inline-flex;
  align-items:center;
  padding:2px 8px;
  border-radius:999px;
  font-size:.78rem;
  border: 1px solid color-mix(in oklab, var(--border) 70%, transparent);
  background:var(--bg-elevated, var(--card));
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.cp-rank-warm{ background:color-mix(in oklab, #ffb38a 18%, transparent); }
.cp-rank-cold{ background:color-mix(in oklab, #79b7ff 18%, transparent); }
.cp-rank-wet { background:color-mix(in oklab, #7dd3fc 18%, transparent); }
.cp-rank-dry { background:color-mix(in oklab, #ff7b5b 18%, transparent); }

.climatepro-rank-table tbody tr.is-warmest-year{ background:color-mix(in oklab, #ffb38a 10%, transparent); }
.climatepro-rank-table tbody tr.is-coldest-year{ background:color-mix(in oklab, #79b7ff 10%, transparent); }
.climatepro-rank-table tbody tr.is-wettest-year{ background:color-mix(in oklab, #7dd3fc 10%, transparent); }
.climatepro-rank-table tbody tr.is-driest-year{ background:color-mix(in oklab, #ff7b5b 10%, transparent); }

@media (max-width:640px){
  #climate-pro-ranking{ margin-top:16px; margin-bottom:40px; }
  .climatepro-rank{ padding:14px 12px 18px; }

  .climatepro-rank-table{
    min-width:100%;
    font-size:.84rem;
  }
  .climatepro-rank-table thead th{
    white-space:normal;
    line-height:1.15;
    padding:4px 6px;
    font-size:.78rem;
  }
  .climatepro-rank-table tbody td{
    padding:4px 6px;
    font-size:.82rem;
  }
}
