:root {
  --mp-blue: #2563eb;
  --mp-blue-dark: #1d4ed8;
  --mp-green: #16a34a;
  --mp-orange: #f97316;
  --mp-purple: #7c3aed;
  --mp-ink: #1f2937;
  --mp-muted: #64748b;
  --mp-soft: #f8fafc;
  --mp-card: #ffffff;
  --mp-border: #e2e8f0;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body.mp-cp-nombres-page {
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, .14), transparent 28rem),
    radial-gradient(circle at top right, rgba(249, 115, 22, .10), transparent 24rem),
    linear-gradient(180deg, #f8fafc 0%, #eef6ff 100%);
  color: var(--mp-ink);
  overflow-x: hidden;
}

.mp-nav-wrap {
  margin-top: 12px;
}

.mp-nav-wrap .navbar {
  border: 0;
  border-radius: 22px;
  box-shadow: 0 12px 35px rgba(15, 23, 42, .08);
}

.mp-nav-wrap .navbar-brand img {
  max-height: 44px;
  width: auto;
}

.mp-nav-wrap .nav > li > a {
  color: #fff !important;
  border-radius: 999px;
  margin: 8px 4px;
  padding: 10px 14px;
  font-weight: 700;
}

.mp-hero,
.mp-card,
.mp-quick-access {
  border: 1px solid rgba(226, 232, 240, .95);
  border-radius: 28px;
  background: rgba(255, 255, 255, .96);
  box-shadow: 0 18px 45px rgba(15, 23, 42, .08);
}

.mp-hero {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr);
  gap: 22px;
  padding: 30px;
  margin: 22px 0;
  align-items: center;
}

.mp-hero-icon {
  width: 78px;
  height: 78px;
  border-radius: 24px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--mp-blue), #38bdf8);
  color: #fff;
  font-size: 34px;
}

.mp-eyebrow {
  display: inline-block;
  color: var(--mp-blue-dark);
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  font-size: 13px;
  margin-bottom: 6px;
}

.mp-hero h1 {
  margin: 0 0 10px;
  font-size: clamp(30px, 5vw, 48px);
  line-height: 1.06;
  font-weight: 900;
}

.mp-hero p {
  font-size: 18px;
  color: var(--mp-muted);
  margin-bottom: 16px;
  max-width: 820px;
}

.mp-hero-level {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #eff6ff;
  color: #1e40af;
  font-weight: 800;
}

.mp-hero-level img {
  height: 44px;
  width: auto;
  display: block;
}

.mp-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.mp-btn {
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 11px 18px;
  border-radius: 999px;
  font-weight: 800;
  text-decoration: none !important;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
}

.mp-btn:hover {
  transform: translateY(-1px);
}

.mp-btn-primary {
  color: #fff !important;
  background: linear-gradient(135deg, var(--mp-orange), #fb923c);
  box-shadow: 0 10px 22px rgba(249, 115, 22, .25);
}

.mp-btn-secondary {
  color: #1e3a8a !important;
  background: #eff6ff;
}

.mp-quick-access {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 18px 22px;
  margin-bottom: 22px;
}

.mp-quick-access strong,
.mp-quick-access span {
  display: block;
}

.mp-quick-access span {
  color: var(--mp-muted);
}

.mp-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 22px;
  align-items: start;
}

.mp-main-column,
.mp-side-column {
  min-width: 0;
}

.mp-card {
  padding: 24px;
  margin-bottom: 22px;
}

.mp-card h2 {
  margin-top: 0;
  font-size: 28px;
  font-weight: 900;
}

.mp-card h3 {
  font-size: 21px;
  font-weight: 900;
  margin-top: 22px;
}

.mp-objective-box,
.mp-example-card,
.mp-reminder {
  border-radius: 20px;
  padding: 16px 18px;
  background: #f8fafc;
  border: 1px solid var(--mp-border);
}

.mp-example-card {
  border-left: 6px solid var(--mp-blue);
}

.mp-reminder {
  background: #ecfdf5;
  border-color: #bbf7d0;
}

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

.mp-number-grid div {
  border-radius: 20px;
  border: 1px solid #dbeafe;
  background: #eff6ff;
  padding: 14px;
  text-align: center;
}

.mp-number-grid strong {
  display: block;
  font-size: 30px;
  color: var(--mp-blue-dark);
}

.mp-number-grid span {
  display: block;
  color: var(--mp-muted);
  overflow-wrap: anywhere;
}

.mp-big-number {
  font-size: 34px;
  color: var(--mp-purple);
  font-weight: 900;
}

.mp-lesson-list {
  padding-left: 20px;
}

.mp-lesson-list li {
  margin-bottom: 8px;
}

.mp-ex-block {
  border-top: 1px solid var(--mp-border);
  padding-top: 18px;
  margin-top: 18px;
}

.mp-question {
  border: 0;
  padding: 0;
  margin: 12px 0 0;
}

.mp-question legend {
  border: 0;
  font-size: 18px;
  font-weight: 900;
  color: var(--mp-ink);
  margin-bottom: 10px;
}

.mp-question label {
  display: block;
  background: #fff;
  border: 2px solid #e2e8f0;
  border-radius: 18px;
  padding: 12px 14px;
  margin-bottom: 10px;
  cursor: pointer;
  font-weight: 700;
}

.mp-question label:hover {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.mp-question input {
  margin-right: 8px;
}

.mp-question.is-correct {
  border-radius: 18px;
  box-shadow: inset 0 0 0 3px #86efac;
  padding: 8px;
  background: #f0fdf4;
}

.mp-question.is-wrong {
  border-radius: 18px;
  box-shadow: inset 0 0 0 3px #fecaca;
  padding: 8px;
  background: #fef2f2;
}

.mp-quiz-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.mp-result {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 18px;
  display: none;
  font-weight: 900;
}

.mp-result.is-visible {
  display: block;
  background: #eff6ff;
  color: #1e40af;
  border: 1px solid #bfdbfe;
}

.mp-correction-toggle {
  width: 100%;
  border: 0;
  border-radius: 20px;
  padding: 16px;
  background: linear-gradient(135deg, var(--mp-green), #22c55e);
  color: #fff;
  font-size: 20px;
  font-weight: 900;
}

.mp-correction-content {
  margin-top: 18px;
}

.mp-correction-content li {
  margin-bottom: 10px;
}

.mp-related-card {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
}

.mp-related-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.mp-related-grid a {
  display: block;
  border-radius: 18px;
  border: 1px solid #dbeafe;
  background: #eff6ff;
  color: #1e40af;
  padding: 13px 14px;
  font-weight: 900;
  text-decoration: none !important;
  overflow-wrap: anywhere;
}

.mp-related-grid a:hover {
  background: #dbeafe;
}

.mp-side-column {
  position: sticky;
  top: 18px;
}

.mp-tip-card {
  background: linear-gradient(135deg, #fff7ed, #ffffff);
}

.mp-mini-card p {
  margin-bottom: 8px;
}

@media (max-width: 991px) {
  .mp-layout {
    grid-template-columns: 1fr;
  }

  .mp-side-column {
    position: static;
  }
}

@media (max-width: 767px) {
  body.mp-cp-nombres-page {
    font-size: 16px;
  }

  .mp-nav-wrap {
    margin-top: 0;
    padding-left: 8px;
    padding-right: 8px;
  }

  .mp-hero {
    grid-template-columns: 1fr;
    padding: 22px;
    border-radius: 22px;
  }

  .mp-hero-icon {
    width: 64px;
    height: 64px;
    font-size: 28px;
  }

  .mp-hero h1 {
    font-size: 32px;
  }

  .mp-hero p {
    font-size: 16px;
  }

  .mp-quick-access {
    flex-direction: column;
    align-items: stretch;
    border-radius: 22px;
  }

  .mp-card {
    padding: 18px;
    border-radius: 22px;
  }

  .mp-card h2 {
    font-size: 25px;
  }

  .mp-actions,
  .mp-quiz-actions {
    flex-direction: column;
  }

  .mp-btn {
    width: 100%;
  }

  .mp-number-grid,
  .mp-related-grid {
    grid-template-columns: 1fr;
  }

  .mp-question label {
    overflow-wrap: anywhere;
  }
}