/* ===== LANGUAGE MATERIAL (2026-10-20) ===== *
 * Selector de idioma del portfolio. Inspector nativo: mismo lenguaje visual
 * que los panes MainLogo (TweakPane) y que el modulo SOCIAL MATERIAL.
 *
 * Archivo propio (no inyectado en el CSS global) para no depender del
 * cache-busting del bundle principal.
 */

/* ---------- panel ---------- */
.LanguageMaterial {
  position: fixed;
  right: 38px;
  top: 104px;
  z-index: 60;
  width: 280px;
  max-width: calc(100vw - 76px);
  padding: 10px 12px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-family: "IBM Plex Mono", monospace;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
}
.LanguageMaterial {
  opacity: 1;
  pointer-events: auto;
}

/* ---------- plegable ---------- */
.LanguageMaterial_toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

/* ---------- cabecera ---------- */
.LanguageMaterial__head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 2px 2px 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
}
.LanguageMaterial_head-caret {
  display: inline-flex;
  width: 10px;
  height: 10px;
  color: rgba(255, 255, 255, 0.45);
  transition: transform 0.25s ease;
}
.LanguageMaterial_head-caret svg {
  width: 10px;
  height: 10px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.LanguageMaterial_toggle:not(:checked) ~ .LanguageMaterial__head .LanguageMaterial_head-caret {
  transform: rotate(-90deg);
}
.LanguageMaterial_toggle:not(:checked) ~ .LanguageMaterial__body,
.LanguageMaterial_toggle:not(:checked) ~ .LanguageMaterial__tech {
  display: none;
}
.LanguageMaterial_head-icon {
  display: inline-flex;
  width: 11px;
  height: 11px;
  color: rgba(255, 255, 255, 0.6);
}
.LanguageMaterial_head-icon svg {
  width: 11px;
  height: 11px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.LanguageMaterial_head-title {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.6);
}
.LanguageMaterial_head-count {
  margin-left: auto;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.2;
  color: rgba(255, 38, 51, 0.95);
  border: 1px solid rgba(255, 38, 51, 0.45);
  border-radius: 2px;
  padding: 2px 6px;
  text-shadow: 0 0 8px rgba(255, 38, 51, 0.45);
}

/* ---------- opciones ---------- */
.LanguageMaterial__body {
  padding-top: 2px;
}
.LanguageMaterial_row {
  display: block;
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  color: inherit;
  font: inherit;
  padding: 7px 2px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: background 0.25s ease;
  cursor: pointer;
}
.LanguageMaterial_row:last-child {
  border-bottom: none;
}
.LanguageMaterial_row:hover {
  background: rgba(255, 38, 51, 0.07);
}
.LanguageMaterial_row:focus-visible {
  outline: 1px solid rgba(255, 38, 51, 0.85);
  outline-offset: -1px;
  background: rgba(255, 38, 51, 0.09);
}
.LanguageMaterial_row-top {
  display: flex;
  align-items: center;
  gap: 8px;
}
.LanguageMaterial_row-icon {
  display: inline-flex;
  width: 14px;
  height: 14px;
  color: rgba(255, 255, 255, 0.55);
  transition: color 0.25s ease;
}
.LanguageMaterial_row-icon svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.LanguageMaterial_row:hover .LanguageMaterial_row-icon {
  color: rgba(255, 255, 255, 0.9);
}
.LanguageMaterial_row-name {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.6);
  transition: color 0.25s ease;
}
.LanguageMaterial_row:hover .LanguageMaterial_row-name {
  color: rgba(255, 255, 255, 0.95);
}
.LanguageMaterial_row-meta {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}
.LanguageMaterial_code {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.45);
  transition: color 0.25s ease;
}
.LanguageMaterial_active {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: transparent;
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

/* ---------- estado activo ---------- */
.LanguageMaterial_option[aria-checked="true"] .LanguageMaterial_active {
  background: rgba(255, 38, 51, 0.95);
  border-color: rgba(255, 38, 51, 0.95);
  box-shadow: 0 0 8px rgba(255, 38, 51, 0.7);
}
.LanguageMaterial_option[aria-checked="true"] .LanguageMaterial_row-name {
  color: rgba(255, 255, 255, 0.95);
}
.LanguageMaterial_option[aria-checked="true"] .LanguageMaterial_code {
  color: rgba(255, 38, 51, 0.95);
}
.LanguageMaterial_option[aria-checked="true"] .LanguageMaterial_row-icon {
  color: rgba(255, 38, 51, 0.9);
}

/* ---------- props de cada fila ---------- */
.LanguageMaterial_row-props {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 5px;
  padding-left: 22px;
  pointer-events: none;
}
.LanguageMaterial_prop {
  display: flex;
  align-items: center;
  gap: 5px;
}
.LanguageMaterial_prop-label {
  font-size: 8.5px;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.4);
}
.LanguageMaterial_prop-val {
  font-size: 9px;
  color: rgba(255, 255, 255, 0.5);
  min-width: 26px;
}

/* ---------- zona tecnica ---------- */
.LanguageMaterial__tech {
  margin-top: 6px;
  padding-top: 7px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.LanguageMaterial_techRow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 2px 2px;
}
.LanguageMaterial_techLabel {
  font-size: 8.5px;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.4);
}
.LanguageMaterial_techVal {
  font-size: 9px;
  letter-spacing: 0.04em;
  color: rgba(255, 38, 51, 0.95);
}

/* ---------- mobile ---------- */
@media not screen and (min-width: 769px) {
  .LanguageMaterial {
    right: 10px;
    top: 70px;
    width: calc(100vw - 20px);
    max-width: none;
    padding: 8px 10px;
  }
  .LanguageMaterial_row {
    padding: 9px 2px;
  }
  .LanguageMaterial_row-name {
    font-size: 12px;
  }
  .LanguageMaterial_row-icon,
  .LanguageMaterial_row-icon svg {
    width: 16px;
    height: 16px;
  }
}

/* ---------- tema 2 (crema) ---------- */
body[data-moto-theme="2"] .LanguageMaterial {
  background: rgba(0, 0, 0, 0.07);
  border-color: rgba(0, 0, 0, 0.12);
}
body[data-moto-theme="2"] .LanguageMaterial__head {
  border-bottom-color: rgba(0, 0, 0, 0.1);
}
body[data-moto-theme="2"] .LanguageMaterial__tech {
  border-top-color: rgba(0, 0, 0, 0.1);
}
body[data-moto-theme="2"] .LanguageMaterial_row {
  border-bottom-color: rgba(0, 0, 0, 0.08);
}
body[data-moto-theme="2"] .LanguageMaterial_head-caret,
body[data-moto-theme="2"] .LanguageMaterial_head-icon,
body[data-moto-theme="2"] .LanguageMaterial_row-icon {
  color: #fff;
  filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.9));
}
body[data-moto-theme="2"] .LanguageMaterial_head-title,
body[data-moto-theme="2"] .LanguageMaterial_row-name,
body[data-moto-theme="2"] .LanguageMaterial_prop-label,
body[data-moto-theme="2"] .LanguageMaterial_prop-val,
body[data-moto-theme="2"] .LanguageMaterial_code,
body[data-moto-theme="2"] .LanguageMaterial_techLabel {
  color: #fff;
  text-shadow: 0 0 3px rgba(0, 0, 0, 0.85), 0 1px 2px rgba(0, 0, 0, 0.55);
}
body[data-moto-theme="2"] .LanguageMaterial_head-count {
  color: #fff;
  text-shadow: 0 0 3px rgba(0, 0, 0, 0.85), 0 1px 2px rgba(0, 0, 0, 0.55);
  border-color: rgba(0, 0, 0, 0.3);
}
body[data-moto-theme="2"] .LanguageMaterial_techVal {
  color: #fff;
  text-shadow: 0 0 3px rgba(0, 0, 0, 0.85), 0 1px 2px rgba(0, 0, 0, 0.55);
}
body[data-moto-theme="2"] .LanguageMaterial_active {
  border-color: rgba(0, 0, 0, 0.35);
}
body[data-moto-theme="2"] .LanguageMaterial_option[aria-checked="true"] .LanguageMaterial_active {
  background: #fff;
  border-color: #fff;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.5);
}
body[data-moto-theme="2"] .LanguageMaterial_option[aria-checked="true"] .LanguageMaterial_row-name,
body[data-moto-theme="2"] .LanguageMaterial_option[aria-checked="true"] .LanguageMaterial_code,
body[data-moto-theme="2"] .LanguageMaterial_option[aria-checked="true"] .LanguageMaterial_row-icon {
  color: #fff;
}
body[data-moto-theme="2"] .LanguageMaterial_row:hover {
  background: rgba(255, 255, 255, 0.09);
}
body[data-moto-theme="2"] .LanguageMaterial_row:focus-visible {
  outline-color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.09);
}

/* ---------- movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  .LanguageMaterial,
  .LanguageMaterial_row,
  .LanguageMaterial_row-name,
  .LanguageMaterial_row-icon,
  .LanguageMaterial_code,
  .LanguageMaterial_active,
  .LanguageMaterial_head-caret {
    transition: none;
  }
}
