/* Styles pour la classification des polynômes (p1_l2_t2) */
.rpoly-section {
  background: #ffffff;
  border: 1px solid #e2e8f0;
}

.rpoly-container {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 14px;
}

.rpoly-card {
  background: #f0fdfa;
  border: 1px solid #ccfbf1;
  border-radius: 14px;
  padding: 16px 20px;
  transition: all 0.2s ease;
}

.rpoly-card:hover {
  border-color: #99f6e4;
  box-shadow: 0 2px 8px rgba(13, 148, 136, 0.06);
}

.rpoly-card-header {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 12px;
}

.rpoly-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: #0d9488;
  color: #ffffff;
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
}

.rpoly-num-degree {
  background: #0284c7;
}

.rpoly-def {
  font-size: 15.5px;
  color: #1e293b;
  line-height: 1.5;
}

.rpoly-hl-red {
  color: #dc2626;
  font-weight: 700;
}

.rpoly-pill-wrapper {
  display: flex;
  justify-content: center;
}

.rpoly-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  border-radius: 12px;
  padding: 8px 24px;
  font-size: 17px;
  font-family: 'Inter', Georgia, serif;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.rpoly-pill-label {
  font-family: system-ui, -apple-system, sans-serif;
  font-size: 15px;
  color: #334155;
  font-weight: 600;
  margin-left: 6px;
}

.rpoly-term-blue {
  color: #0284c7;
  font-weight: 600;
}

.rpoly-term-green {
  color: #059669;
  font-weight: 600;
}

.rpoly-term-purple {
  color: #7c3aed;
  font-weight: 600;
}

.rpoly-exp-red {
  color: #dc2626;
  font-weight: 700;
}

.rpoly-exp-blue {
  color: #0284c7;
  font-weight: 700;
}

.rpoly-exp-green {
  color: #059669;
  font-weight: 700;
}

/* Carte spéciale pour le degré */
.rpoly-card-degree {
  background: #f8fafc;
  border: 1.5px solid #cbd5e1;
}

.rpoly-pill-highlight {
  border-color: #38bdf8;
  background: #ffffff;
}

.rpoly-inline-poly {
  font-weight: 600;
  color: #0f172a;
  padding: 0 4px;
}

.rpoly-calc-badge {
  background: #e0f2fe;
  color: #0369a1;
  padding: 3px 12px;
  border-radius: 8px;
  font-size: 16px;
  margin-left: 4px;
}

.rpoly-deg-res {
  color: #0284c7;
  font-size: 18px;
  font-weight: 800;
}

.rpoly-detail-box {
  margin-top: 14px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px 16px;
}

.rpoly-detail-title {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 8px;
}

.rpoly-terms-deg {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  font-size: 14px;
  color: #334155;
}

.rpoly-max-tag {
  background: #fef2f2;
  color: #dc2626;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: 4px;
}

@media (min-width: 640px) {
  .rpoly-terms-deg {
    grid-template-columns: repeat(2, 1fr);
  }
}
