/* ============================================================
   TACONES Y MAZMORRAS — Sistema de Diseño FABULOSO 💅✨
   Estética: Neones, Oro, Cristal, RuPaul Realness
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cinzel+Decorative:wght@400;700;900&family=MedievalSharp&family=Outfit:wght@300;400;500;600;700&display=swap');

/* --- Variables de Diseño --- */
:root {
  /* Fondos de la Noche */
  --bg-void: #0a0214;
  --bg-surface: #1a0535;
  --bg-card: rgba(10, 2, 20, 0.45);
  --bg-card-hover: rgba(26, 10, 50, 0.6);

  /* Neones y Purpurina */
  --accent-fucsia: #ff007f;
  --accent-fucsia-glow: rgba(255, 0, 127, 0.6);
  --accent-gold: #ffd700;
  --accent-gold-glow: rgba(255, 215, 0, 0.5);
  --accent-purple: #9d00ff;
  --accent-purple-light: #c4b5fd;

  /* Textos Deslumbrantes */
  --text-primary: #ffffff;
  --text-secondary: #c4b5fd;
  --text-muted: #8e73b0;

  --border-subtle: rgba(255, 0, 127, 0.3);
  --border-glow: rgba(255, 215, 0, 0.5);

  --sidebar-width: 280px;
  --header-height: 72px;

  --font-display: 'Playfair Display', serif;
  --font-technical: 'Space Mono', monospace;
  --font-medieval: 'MedievalSharp', cursive;
  --font-body: 'Outfit', sans-serif;

  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;

  --transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

/* --- Pestaña de Cierre (Móvil) --- */
.sidebar-close-tab {
  display: none;
  /* Oculto en desktop */
  position: absolute;
  top: 120px;
  right: -36px;
  width: 36px;
  height: 70px;
  background: linear-gradient(to bottom, var(--accent-fucsia), #9d00ff);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-left: none;
  border-radius: 0 12px 12px 0;
  color: white;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  box-shadow: 5px 0 15px rgba(255, 0, 127, 0.4);
  z-index: 1001;
  transition: var(--transition);
}

.sidebar-close-tab--right {
  right: auto;
  left: -36px;
  border-radius: 12px 0 0 12px;
  border-left: 1px solid rgba(255, 255, 255, 0.3);
  border-right: none;
  box-shadow: -5px 0 15px rgba(255, 0, 127, 0.4);
}

.sidebar-close-tab:hover {
  width: 42px;
  right: -42px;
  filter: brightness(1.2);
}

.sidebar-close-tab--right:hover {
  width: 42px;
  left: -42px;
  right: auto;
}

@media (max-width: 768px) {
  .sidebar-close-tab {
    display: none;
  }

  .sidebar.open .sidebar-close-tab {
    display: flex;
  }
}

/* --- Reset Base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  background-color: #0d0208;
  color: var(--text-primary);
  font-family: var(--font-body);
  min-height: 100vh;
  overflow-x: hidden;
  background-attachment: fixed;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  opacity: 0.8;
  z-index: -3;
  pointer-events: none;
  mix-blend-mode: soft-light;
}

/* Overlay de Grano de Película */
body::after {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.04;
  background-image: url("/img/noise.svg");
  filter: contrast(150%) brightness(100%);
}

/* ==================== ATMOSPHERE ELEMENTS ==================== */
/* Partículas */
#particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.particle {
  position: absolute;
  border-radius: 50%;
  animation: twinkle var(--dur, 4s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}

@keyframes twinkle {

  0%,
  100% {
    opacity: 0;
    transform: scale(0.5);
  }

  50% {
    opacity: 1;
    transform: scale(1.2);
  }
}

/* Brillos de Fondo */
.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
}

.bg-glow--pink {
  background: rgba(254, 249, 95, 0.08);
  /* Gold soft */
  width: 80vw;
  height: 80vh;
  top: -30vh;
  left: -20vw;
  animation: drift 15s ease-in-out infinite alternate;
}

.bg-glow--purple {
  background: rgba(80, 5, 25, 0.15);
  /* Burgundy */
  width: 60vw;
  height: 60vh;
  bottom: -20vh;
  right: -10vw;
  animation: drift 20s ease-in-out infinite alternate-reverse;
}

@keyframes drift {

  0%,
  100% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(40px, 30px);
  }
}

/* Marco de Tarot */
.tarot-frame {
  position: fixed;
  inset: 0;
  z-index: 2000;
  pointer-events: none;
  box-shadow: inset 0 0 100px rgba(0, 0, 0, 0.8), inset 0 0 30px rgba(255, 0, 127, 0.1);
}

.tarot-corner {
  position: absolute;
  width: 60px;
  height: 60px;
  z-index: 2001;
  opacity: 0.6;
  filter: drop-shadow(0 0 10px var(--accent-gold-glow));
}

.tarot-corner::before,
.tarot-corner::after {
  content: '';
  position: absolute;
  background: var(--accent-gold);
}

.corner-tl {
  top: 0;
  left: 0;
}

.corner-tl::before {
  width: 100%;
  height: 2px;
  top: 0;
  left: 0;
}

.corner-tl::after {
  width: 2px;
  height: 100%;
  top: 0;
  left: 0;
}

.corner-tr {
  top: 0;
  right: 0;
}

.corner-tr::before {
  width: 100%;
  height: 2px;
  top: 0;
  right: 0;
}

.corner-tr::after {
  width: 2px;
  height: 100%;
  top: 0;
  right: 0;
}

.corner-bl {
  bottom: 0;
  left: 0;
}

.corner-bl::before {
  width: 100%;
  height: 2px;
  bottom: 0;
  left: 0;
}

.corner-bl::after {
  width: 2px;
  height: 100%;
  bottom: 0;
  left: 0;
}

.corner-br {
  bottom: 0;
  right: 0;
}

.corner-br::before {
  width: 100%;
  height: 2px;
  bottom: 0;
  right: 0;
}

.corner-br::after {
  width: 2px;
  height: 100%;
  bottom: 0;
  right: 0;
}

/* Animación de entrada fabulosa */
@keyframes popIn {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }

  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes shimmer {
  0% {
    background-position: -200% center;
  }

  100% {
    background-position: 200% center;
  }
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-5px);
  }

  100% {
    transform: translateY(0px);
  }
}

/* --- Layout App --- */
.app-layout {
  display: flex;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* --- Sidebar --- */
.sidebar {
  width: var(--sidebar-width);
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border-color);
  position: fixed;
  left: 0;
  height: 100vh;
  z-index: 100;
  padding: 0;
  overflow: visible;
  /* Importante para que la pestaña de cierre no se corte */
  transition: var(--transition);
}

.sidebar-content {
  height: 100%;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.sidebar-logo {
  padding: 1rem 0 0;
  /* Eliminamos el padding inferior por completo */
  text-align: center;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.sidebar-logo img {
  width: 90%;
  max-width: 220px;
  height: auto;
  filter: drop-shadow(0 0 15px var(--accent-fucsia-glow));
  border-radius: var(--radius-md);
  margin: 0 auto;
}

.sidebar-logo::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 10%;
  width: 80%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 0, 127, 0.3), transparent);
}

.sidebar-logo img {
  width: 100%;
  max-width: 190px;
  /* Animaciones eliminadas definitivamente */
}

.sidebar-nav {
  padding: 0.5rem 0;
  /* Padding reducido al mínimo */
  flex: 1;
}

.nav-section-title {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 900;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent-gold);
  padding: 0 2rem;
  margin-bottom: 0.8rem;
  margin-top: 2rem;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 0.9rem 2rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  border-left: 4px solid transparent;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.nav-link::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 0, 127, 0.15), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: -1;
}

.nav-link:hover {
  color: #fff;
  border-left-color: var(--accent-fucsia);
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
}

.nav-link:hover::before {
  opacity: 1;
}

.nav-link.active {
  color: var(--accent-gold);
  font-weight: 700;
  border-left-color: var(--accent-gold);
  background: linear-gradient(90deg, rgba(255, 215, 0, 0.05), transparent);
  backdrop-filter: blur(10px);
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

/* Efecto de borde sutil para el activo */
.nav-link.active::after {
  content: '';
  position: absolute;
  left: 0;
  top: 15%;
  height: 70%;
  width: 3px;
  background: var(--accent-gold);
  box-shadow: 0 0 10px var(--accent-gold-glow);
  border-radius: 0 4px 4px 0;
}

.nav-link .nav-icon {
  font-size: 1.3rem;
  width: 24px;
  text-align: center;
  transition: var(--transition);
}

.nav-link:hover .nav-icon {
  transform: scale(1.1);
  filter: drop-shadow(0 0 5px var(--accent-fucsia));
}

.nav-link.active .nav-icon {
  transform: scale(1.15);
  filter: drop-shadow(0 0 8px var(--accent-gold-glow));
}

/* --- Sidebar Credits (Fichas) --- */
.sidebar-credits {
  margin: 1.5rem 2rem 0.5rem;
  padding: 0.8rem 1.2rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 0, 127, 0.05));
  border-radius: 12px;
  border: 1px solid rgba(255, 0, 127, 0.2);
  display: flex;
  align-items: center;
  gap: 0.8rem;
  box-shadow: inset 0 0 15px rgba(0, 0, 0, 0.2);
  transition: var(--transition);
}

.sidebar-credits:hover {
  border-color: var(--accent-fucsia);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 0, 127, 0.1));
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(255, 0, 127, 0.2);
}

.credits-icon {
  font-size: 1.2rem;
  filter: drop-shadow(0 0 5px var(--accent-fucsia-glow));
}

.credits-value {
  font-family: var(--font-technical);
  font-size: 1.3rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 0 10px var(--accent-fucsia-glow);
  line-height: 1;
}

.credits-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  font-weight: 700;
  margin-left: auto;
}

.sidebar-user {
  padding: 1.5rem 2rem 0;
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.sidebar-user::before {
  content: '';
  position: absolute;
  top: 0;
  left: 10%;
  width: 80%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 0, 127, 0.2), transparent);
}

.sidebar-user-avatar {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #ff007f, #9d00ff);
  border: 2px solid var(--accent-gold);
  box-shadow: 0 0 20px rgba(255, 0, 127, 0.5);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 800;
  color: white;
  flex-shrink: 0;
}

.sidebar-user-info {
  flex: 1;
  min-width: 0;
}

.sidebar-user-name {
  font-size: 1rem;
  font-weight: 800;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-family: var(--font-display);
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
}

.sidebar-user-role {
  font-size: 0.75rem;
  color: var(--accent-gold);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
}

/* --- Main Content --- */
.main-content {
  margin-left: var(--sidebar-width);
  flex: 1;
  padding: 3rem;
  min-height: 100vh;
  min-width: 0;
  /* Se elimina la animación de entrada para evitar crear un 'Stacking Context' cerrado 
     que rompe el mix-blend-mode de las imágenes del hero */
}

.page-header {
  margin-bottom: 3rem;
  position: relative;
  text-align: center;
}

.page-title {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--text-primary);
  letter-spacing: 0.05em;
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.2), 0 0 40px var(--accent-purple);
  background: linear-gradient(to right, #ffffff, #e0a3ff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.page-subtitle {
  color: var(--text-secondary);
  font-size: 1rem;
  margin-top: 0.5rem;
  font-family: var(--font-body);
  font-weight: 300;
}

/* --- Cards Ornate Physical UI --- */
.card {
  --border-size: 4px;
  --border-radius: 12px;
  background: rgba(15, 5, 25, 0.75);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border-radius: var(--border-radius);
  padding: 2rem;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  overflow: hidden;
  box-shadow:
    0 15px 40px rgba(0, 0, 0, 0.6),
    inset 0 0 30px rgba(255, 0, 127, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.card::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 150%;
  height: 150%;
  background: conic-gradient(from 0deg,
      transparent 45deg,
      var(--accent-fucsia) 180deg,
      var(--accent-gold) 220deg,
      transparent 315deg);
  transform: translate(-50%, -50%) rotate(0deg);
  animation: rotate-border 6s linear infinite;
  z-index: 0;
  opacity: 0.3;
}

.card::after {
  content: '';
  position: absolute;
  inset: var(--border-size);
  background: linear-gradient(135deg, rgba(25, 5, 35, 0.95), rgba(10, 2, 20, 0.98));
  border-radius: calc(var(--border-radius) - var(--border-size));
  z-index: 1;
}

.card>* {
  position: relative;
  z-index: 2;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 50px rgba(255, 0, 127, 0.15);
}

.card:hover::before {
  opacity: 0.8;
}

/* Eliminamos los viejos estilos glow y card--glow que ya no pegan con este estilo físico */

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.card-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--accent-gold);
  text-transform: uppercase;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.2);
}

/* --- KPI Tarjetas Espectaculares --- */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  /* Optimizado para 4 boxes */
  gap: 1.25rem;
  margin-bottom: 3rem;
}

@media (max-width: 1024px) {
  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
    /* 2x2 elegante en tablet */
    gap: 0.75rem;
  }
}

@media (max-width: 600px) {
  .kpi-grid {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 0.6rem !important;
    padding: 0 0.25rem !important;
    width: 100% !important;
  }

  .kpi-card {
    aspect-ratio: auto !important;
    padding: 1.25rem 1rem !important;
    min-height: 90px !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 0.75rem !important;
    text-align: left;
  }

  .kpi-value {
    font-size: 2.4rem !important;
    line-height: 1;
    font-weight: 900;
  }

  .kpi-label {
    font-size: 0.7rem !important;
    letter-spacing: 0.05em;
    opacity: 0.9;
  }
}

.kpi-card {
  --border-size: 4px;
  --border-radius: 12px;
  background: rgba(15, 5, 25, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: var(--border-radius);
  padding: 1.8rem 2rem;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  overflow: hidden;
  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.5),
    inset 0 0 20px rgba(255, 0, 127, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* El "Alma" del borde animado */
.kpi-card::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 150%;
  height: 150%;
  background: conic-gradient(from 0deg,
      transparent 0deg,
      var(--accent-fucsia) 90deg,
      var(--accent-gold) 180deg,
      var(--accent-fucsia) 270deg,
      transparent 360deg);
  transform: translate(-50%, -50%) rotate(0deg);
  animation: rotate-border 4s linear infinite;
  z-index: 0;
  opacity: 0.4;
  transition: opacity 0.3s;
}

/* La máscara para que solo se vea el borde */
.kpi-card::after {
  content: '';
  position: absolute;
  inset: var(--border-size);
  background: linear-gradient(135deg, rgba(25, 5, 35, 0.95), rgba(10, 2, 20, 0.98));
  border-radius: calc(var(--border-radius) - var(--border-size));
  z-index: 1;
}

.kpi-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 40px rgba(255, 0, 127, 0.2);
}

.kpi-card:hover::before {
  opacity: 1;
  animation-duration: 2s;
  /* Se acelera el glamour al pasar el ratón */
}

@keyframes rotate-border {
  from {
    transform: translate(-50%, -50%) rotate(0deg);
  }

  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

.kpi-card--fucsia::before {
  background: conic-gradient(from 0deg, transparent 45deg, var(--accent-fucsia) 180deg, transparent 315deg);
}

.kpi-card--gold::before {
  background: conic-gradient(from 0deg, transparent 45deg, var(--accent-gold) 180deg, transparent 315deg);
}

.kpi-label {
  font-size: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  font-family: var(--font-display);
  font-weight: 700;
  z-index: 2;
  position: relative;
  line-height: 1.3;
}

.kpi-value {
  font-size: 3.2rem;
  font-weight: 700;
  line-height: 1;
  font-family: var(--font-technical);
  z-index: 2;
  position: relative;
  text-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
  letter-spacing: -0.05em;
  flex-shrink: 0;
}

.kpi-card--fucsia .kpi-value {
  color: var(--accent-fucsia);
  text-shadow: 0 0 20px rgba(255, 0, 127, 0.4);
}

.kpi-card--gold .kpi-value {
  color: var(--accent-gold);
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.4);
}

.kpi-card--purple .kpi-value {
  color: var(--accent-purple-light);
  text-shadow: 0 0 20px rgba(224, 163, 255, 0.4);
}

/* --- Botones Glamourosos --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  /* Pillow shape for elegance */
  font-size: 0.95rem;
  font-weight: 700;
  font-family: var(--font-body);
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: var(--transition);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
  z-index: 1;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.25), transparent);
  transform: skewX(-20deg);
  transition: 0.5s;
  z-index: -1;
}

.btn:hover::before {
  left: 200%;
}

.btn--primary {
  background: linear-gradient(135deg, #ff007f, #9d00ff);
  color: #fff;
  box-shadow: 0 8px 25px rgba(255, 0, 127, 0.4), inset 0 2px 5px rgba(255, 255, 255, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn--primary:hover {
  box-shadow: 0 12px 35px rgba(255, 0, 127, 0.6), inset 0 2px 5px rgba(255, 255, 255, 0.5);
  transform: translateY(-2px) scale(1.02);
}

.btn--gold {
  background: linear-gradient(135deg, #ffd700, #ff8c00);
  color: #3b2a00;
  box-shadow: 0 8px 25px rgba(255, 215, 0, 0.4), inset 0 2px 5px rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.btn--gold:hover {
  box-shadow: 0 12px 35px rgba(255, 215, 0, 0.6);
  transform: translateY(-2px) scale(1.02);
}

.btn--outline {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(5px);
  color: #d4b5f2;
  border: 1px solid rgba(212, 181, 242, 0.3);
}

.btn--outline:hover {
  background: rgba(255, 0, 127, 0.05);
  border-color: var(--accent-fucsia);
  color: #fff;
  box-shadow: 0 0 15px rgba(255, 0, 127, 0.3);
}

.btn--danger {
  background: linear-gradient(135deg, #ff0f47, #b30026);
  color: #fff;
  box-shadow: 0 5px 15px rgba(255, 15, 71, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn--danger:hover {
  box-shadow: 0 10px 25px rgba(255, 15, 71, 0.5);
  transform: translateY(-2px);
}

.btn--sm {
  padding: 0.4rem 1rem;
  font-size: 0.8rem;
}

.btn--lg {
  padding: 1rem 3rem;
  font-size: 1.1rem;
}

/* --- Tabla Elegante --- */
.table-container {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(10, 2, 20, 0.4);
  backdrop-filter: blur(10px);
}

table {
  width: 100%;
  border-collapse: collapse;
}

thead th {
  padding: 1.2rem 1.5rem;
  font-family: var(--font-display);
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-gold);
  text-align: left;
  background: rgba(0, 0, 0, 0.4);
  border-bottom: 2px solid rgba(255, 215, 0, 0.2);
}

tbody tr {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: var(--transition);
}

tbody tr:last-child {
  border-bottom: none;
}

tbody tr:hover {
  background: rgba(255, 0, 127, 0.05);
  box-shadow: inset 4px 0 0 var(--accent-fucsia);
}

tbody td {
  padding: 1.2rem 1.5rem;
  font-size: 0.95rem;
  color: var(--text-primary);
  font-weight: 300;
}

tbody td strong {
  font-weight: 600;
  color: #fff;
}

.nav-section-title {
  padding: 0.5rem 1.5rem 0.2rem;
  /* Reducción extrema para pegar el título al logo */
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 900;
  color: #ffd700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.4);
  opacity: 1;
  border-bottom: none;
  margin-bottom: 0.1rem;
}

/* --- Badges Joya --- */
.badge {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.badge--active {
  background: linear-gradient(135deg, #00f2fe, #4facfe);
  color: #002233;
}

.badge--inactive {
  background: rgba(255, 255, 255, 0.1);
  color: #ccc;
}

.badge--admin {
  background: linear-gradient(135deg, #ff007f, #9d00ff);
  color: #fff;
  box-shadow: 0 0 10px rgba(255, 0, 127, 0.4);
}

.badge--user {
  background: linear-gradient(135deg, #e0c3fc, #8ec5fc);
  color: #1a0b2e;
}

/* --- Toggle Switch Neon --- */
.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.toggle-label {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-primary);
}

.toggle-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

.toggle-switch {
  position: relative;
  width: 50px;
  height: 28px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  inset: 0;
  background: #1a0a2e;
  border-radius: 999px;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.5);
}

.toggle-slider::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  background: var(--text-muted);
  border-radius: 50%;
  transition: var(--transition);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.toggle-switch input:checked+.toggle-slider {
  background: linear-gradient(135deg, #ff007f, #9d00ff);
  border-color: var(--accent-fucsia);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2), 0 0 15px var(--accent-fucsia-glow);
}

.toggle-switch input:checked+.toggle-slider::before {
  left: calc(100% - 22px);
  background: #fff;
  box-shadow: 0 0 10px #fff;
}

/* --- Textarea Editor de Hechizos --- */
.prompt-editor {
  width: 100%;
  min-height: 320px;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(5px);
  border: 1px solid rgba(255, 0, 127, 0.3);
  border-radius: var(--radius-md);
  color: #ffbdf2;
  font-family: 'Cinzel', serif;
  /* Cambiado a algo más mágico */
  font-size: 1.1rem;
  line-height: 1.8;
  padding: 0.75rem !important;
  resize: vertical;
  outline: none;
  transition: var(--transition);
  box-shadow: inset 0 4px 10px rgba(0, 0, 0, 0.5);
}

.prompt-editor:focus {
  border-color: var(--accent-gold);
  box-shadow: 0 0 25px rgba(255, 215, 0, 0.3), inset 0 4px 10px rgba(0, 0, 0, 0.5);
  background: rgba(15, 0, 30, 0.6);
  color: #fff;
}

/* --- Ilustraciones Héroe con Blending Screen --- */
.hero-illust {
  position: absolute;
  /* ... rest of the styles are inherited from below ... */
}

/* Ilustraciones Héroe con Blending Screen */
.hero-illust {
  position: absolute;
  bottom: 0px;
  height: 125%;
  max-width: 45%;
  object-fit: contain;
  object-position: bottom;
  mix-blend-mode: screen;
  pointer-events: none;
  z-index: 5;
  opacity: 1;
  filter: contrast(1.2) brightness(1) drop-shadow(0 0 10px rgba(255, 0, 127, 0.5));
}

.hero-illust-left {
  left: 2%;
  /* Elevación estática para evitar mareos */
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 15%), linear-gradient(to bottom, black 85%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to right, transparent 0%, black 15%), linear-gradient(to bottom, black 85%, transparent 100%);
  mask-composite: intersect;
}

.hero-illust-right {
  right: 2%;
  height: 109%;
  /* Reducido un ~15% desde el 125% original */
  animation: float-slow 7s ease-in-out infinite reverse;
  -webkit-mask-image: linear-gradient(to left, transparent 0%, black 15%), linear-gradient(to bottom, black 85%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to left, transparent 0%, black 15%), linear-gradient(to bottom, black 85%, transparent 100%);
  mask-composite: intersect;
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), filter 0.3s ease;
  pointer-events: auto;
  /* Permitir interacción */
  cursor: pointer;
}

.hero-illust-right:hover {
  transform: scale(1.1) rotate(5deg) translateY(-10px);
  filter: contrast(1.3) brightness(1.2) drop-shadow(0 0 25px rgba(255, 0, 127, 0.8));
}

.hero-illust-right:active {
  animation: dice-shake 0.4s ease-in-out;
}

@keyframes float-slow {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

@keyframes dice-shake {

  0%,
  100% {
    transform: rotate(0deg) scale(1.1);
  }

  25% {
    transform: rotate(-5deg) scale(1.15);
  }

  50% {
    transform: rotate(5deg) scale(1.05);
  }

  75% {
    transform: rotate(-3deg) scale(1.1);
  }
}



@media (max-width: 768px) {
  .hero-illust {
    opacity: 0.15 !important;
    filter: opacity(1);
    z-index: 0;
    height: 90%;
    max-width: 65%;
    top: -2rem;
    /* Subimos un poco las ilustraciones para equilibrar */
    /* Ancladas arriba para no tapar el botón */
    bottom: auto;
  }

  .hero-illust-left {
    left: -10%;
  }

  .hero-illust-right {
    right: -10%;
  }

  .hero-logo {
    display: none;
  }

  .credit-greeting {
    margin-top: 0.5rem;
  }
}

/* --- Hero Styles Base (Desktop) --- */
.hero-logo {
  position: absolute;
  top: -8rem;
  left: 50%;
  transform: translateX(-50%);
  width: 450px;
  max-width: 90vw;
  filter: drop-shadow(0 0 35px var(--accent-fucsia-glow));
  z-index: 20;
}

.credit-hero {
  text-align: center;
  padding: 8rem 2rem 4rem;
  /* Padding aumentado para que el texto NO quede debajo del logo absoluto */
  background: radial-gradient(ellipse at bottom, rgba(255, 0, 127, 0.1) 0%, transparent 80%);
  border-radius: var(--radius-lg);
  position: relative;
  overflow: visible;
  margin-top: 7rem;
  /* Margen extra para dar sitio al logo absoluto superior */
  margin-bottom: 3rem;
  z-index: 1;
  border: none;
}

.credit-greeting {
  font-family: var(--font-medieval);
  font-size: 1rem;
  color: rgba(255, 215, 0, 0.75);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
  font-weight: 400;
  text-shadow: 0 0 12px rgba(255, 215, 0, 0.4);
}

.credit-name {
  font-family: var(--font-medieval);
  font-size: 3.4rem;
  background: linear-gradient(160deg, #fff5c0 0%, #ff9ed2 40%, #ffd700 70%, #c77dff 100%);
  background-size: 200% auto;
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
  margin-bottom: 1.5rem;
  font-weight: 400;
  line-height: 1.1;
  text-shadow: none;
  filter: drop-shadow(0 4px 18px rgba(255, 0, 127, 0.45));
}

.credit-number {
  font-size: 5rem;
  font-weight: 900;
  color: #fff;
  line-height: 1;
  margin-bottom: 0.5rem;
  text-shadow: 0 0 30px rgba(255, 215, 0, 0.6);
  font-family: var(--font-display);
}

.credit-label {
  font-size: 1rem;
  color: var(--accent-purple-light);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-family: var(--font-display);
  margin-bottom: 2rem;
  font-weight: 700;
}

/* --- Botón Nueva Partida (hero) — estilos base, glitter en dashboard.css --- */
#btn-new-game {
  clip-path: none;
  border-radius: 12px;
  animation: none;
}

@keyframes btn-shimmer {
  0% {
    background-position: 0% center;
  }

  100% {
    background-position: 250% center;
  }
}

/* --- Notificaciones --- */
.alert {
  padding: 1rem 1.5rem;
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  margin-bottom: 1rem;
  border: 1px solid;
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  animation: popIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  font-weight: 500;
}

.alert--success {
  background: rgba(0, 255, 170, 0.15);
  border-color: #00ffaa;
  color: #b3ffe6;
  box-shadow: 0 0 20px rgba(0, 255, 170, 0.2);
}

.alert--error {
  background: rgba(255, 0, 76, 0.15);
  border-color: #ff004c;
  color: #ffcccc;
  box-shadow: 0 0 20px rgba(255, 0, 76, 0.2);
}

.alert--info {
  background: rgba(255, 215, 0, 0.1);
  border-color: var(--accent-gold);
  color: #fff2b3;
  box-shadow: 0 0 20px rgba(255, 215, 0, 0.2);
}

#alert-container {
  position: fixed;
  top: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  min-width: 320px;
}

/* --- Mobile Header --- */
.mobile-header {
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  background: rgba(10, 2, 20, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 2px solid var(--accent-fucsia);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  max-width: 100vw;
  box-sizing: border-box;
  z-index: 2000;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.8);
  pointer-events: auto;
}

.mobile-header-logo {
  height: 85px !important;
  /* Ligeramente más grande como pidió la reina */
  object-fit: contain;
  filter: drop-shadow(0 0 15px rgba(255, 0, 127, 0.6));
}

.menu-toggle-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--accent-gold);
  color: var(--accent-gold);
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: absolute;
  left: 1rem;
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.2);
  transition: all 0.3s;
}

.menu-toggle-btn:active {
  transform: scale(0.9);
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  z-index: 95;
  backdrop-filter: blur(5px);
}

.sidebar-overlay.open {
  display: block;
  animation: popIn 0.3s;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  :root {
    --sidebar-width: 240px;
  }
}

@media (max-width: 768px) {
  .mobile-header {
    display: flex;
  }

  .sidebar {
    transform: translateX(-100%);
    width: 280px;
    background: #0a0214;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-right: 1px solid rgba(255, 0, 127, 0.5);
    z-index: 1000;
    overflow: visible;
  }

  .sidebar-content {
    padding-top: 120px;
    /* Espacio para el mobile-header */
  }

  .sidebar-logo {
    padding: 1.5rem 1rem 0.5rem;
    /* Padding equilibrado para móvil */
  }

  .sidebar-logo img {
    max-width: 180px;
    /* Reducimos ligeramente para que no se corte por los lados */
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .main-content {
    margin-left: 0;
    padding: 0.75rem !important;
    padding-top: 10rem !important;
  }

  .page-title {
    font-size: 1.8rem;
  }

  body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url('../img/draq_master_nobackground.webp');
    background-size: 140%;
    background-position: center 35%;
    /* Subimos un poco para que la cintura no quede tan abajo */
    background-repeat: no-repeat;
    opacity: 0.25;
    /* Un poco más sutil */
    z-index: -1;
    pointer-events: none;
    mix-blend-mode: lighten;
    filter: blur(1px);

    /* Máscara mágica para difuminar bordes y el corte de la cintura */
    -webkit-mask-image: radial-gradient(ellipse at center, black 40%, transparent 95%);
    mask-image: radial-gradient(ellipse at center, black 40%, transparent 95%);
  }

  .credit-hero {
    padding: 2rem 1.5rem;
    margin-top: 1rem;
    position: relative;
    background: transparent !important;
    /* Quitamos fondos locales para ver el general */
    border: none !important;
    box-shadow: none !important;
  }

  .credit-hero::before {
    display: none;
    /* Quitamos el fondo local que pusimos antes */
  }

  /* Cajas con transparencia (Glassmorphism) en móvil - LIMPIEZA TOTAL */
  .stat-card,
  .card-recent,
  .card,
  .kpi-card,
  .kpi-card--neon,
  .kpi-card--fucsia,
  .kpi-card--gold,
  .kpi-card--purple {
    background: rgba(45, 10, 75, 0.35) !important;
    /* Violeta muy transparente */
    background-image: none !important;
    /* ELIMINAMOS cualquier imagen o gradiente previo */
    backdrop-filter: blur(15px) saturate(180%) !important;
    /* Desenfoque potente y saturación para ese toque premium */
    -webkit-backdrop-filter: blur(15px) saturate(180%) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    /* Borde blanquecino sutil tipo cristal */
    border-top: 1px solid rgba(255, 215, 0, 0.4) !important;
    /* Toque de oro arriba */
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.6) !important;
    position: relative;
    overflow: hidden;
  }

  /* Limpiamos fondos de cabeceras de cartas */
  .card-header {
    background: transparent !important;
    border-bottom: 1px solid rgba(255, 215, 0, 0.2) !important;
  }

  /* Aseguramos que el contenido interno brille */
  .stat-card-value {
    color: #fff !important;
    text-shadow: 0 0 15px rgba(255, 215, 0, 0.6) !important;
  }

  /* Aseguramos que el contenido interno se lea bien */
  .stat-card-label,
  .stat-card-value,
  .cr-title,
  .cr-text {
    position: relative;
    z-index: 2;
  }

  .hero-illust-left,
  .hero-illust-right {
    display: none !important;
    /* Quitamos las dos figuras que se solapan */
  }

  .hero-logo {
    display: none !important;
    /* El usuario prefiere que no se vea en móvil */
  }

  .credit-number {
    font-size: 3.5rem;
    position: relative;
    z-index: 10;
  }
}

/* --- Scrollbar Joya --- */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.5);
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #ff007f, #9d00ff);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #ffd700, #ff007f);
}

/* ============================================================
   ESTILOS DE MANUAL DE ROL (MESA DE JUEGO)
   Compartidos entre game.html y el Wizard
   ============================================================ */

.side-section-title {
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.side-section-title::before {
  content: '';
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.25));
}

.stat-card {
  background: linear-gradient(160deg, #22003a 0%, #0d0018 100%);
  border: 1px solid rgba(212, 175, 55, 0.5);
  border-top: 2px solid var(--accent-gold);
  border-radius: 10px;
  padding: 0.75rem 0.6rem 0.6rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  min-height: 90px;
  position: relative;
  overflow: hidden;
  cursor: help;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 215, 0, 0.08);
}

.stat-card:hover {
  border-color: var(--accent-fucsia);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(255, 0, 127, 0.25);
}

.stat-card::before {
  content: '';
  position: absolute;
  top: -20px;
  right: -20px;
  width: 60px;
  height: 60px;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.stat-card-label {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent-gold);
  font-weight: 900;
  opacity: 0.9;
  text-align: center;
}

.stat-card-value {
  font-size: 2.6rem;
  font-weight: 950;
  color: #fff;
  text-shadow: 0 0 15px rgba(255, 215, 0, 0.35), 0 2px 4px rgba(0, 0, 0, 0.8);
  font-family: var(--font-display);
  line-height: 1;
  text-align: center;
}

.stat-card-icon {
  position: absolute;
  bottom: 4px;
  right: 5px;
  width: 22px;
  height: 22px;
  opacity: 0.35;
  pointer-events: none;
}

.stat-card-icon svg {
  width: 100%;
  height: 100%;
  fill: var(--accent-gold);
}

/* --- Botones de Control Premium --- */
.control-btn-lg {
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 2px solid rgba(255, 255, 255, 0.2);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 900;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  user-select: none;
  line-height: 1;
  flex-shrink: 0;
}

.control-btn-lg:hover {
  background: var(--accent-fucsia);
  border-color: var(--accent-gold);
  color: white;
  transform: scale(1.1);
  box-shadow: 0 0 15px var(--accent-fucsia-glow);
}

.control-btn-lg:active {
  transform: scale(0.9);
}

.control-btn-lg.minus {
  border-color: rgba(255, 0, 127, 0.5);
  background: rgba(255, 0, 127, 0.1);
}

.control-btn-lg.plus {
  border-color: rgba(0, 255, 170, 0.5);
  background: rgba(0, 255, 170, 0.1);
}

.hab-val {
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--accent-gold);
  min-width: 40px;
  text-align: center;
  font-family: var(--font-display);
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

/* --- Ayuda y Tooltips Premium --- */
.help-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(212, 175, 55, 0.1);
  border: 1px solid var(--accent-gold);
  color: var(--accent-gold);
  font-size: 0.8rem;
  font-weight: 800;
  cursor: help;
  margin-left: 8px;
  transition: all 0.3s ease;
  vertical-align: middle;
}

.help-icon:hover {
  background: var(--accent-gold);
  color: black;
  box-shadow: 0 0 10px var(--accent-gold-glow);
}

[data-tooltip] {
  position: relative;
}

[data-tooltip]::before {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 125%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  background: linear-gradient(135deg, #2a0b45 0%, #150525 100%);
  border: 1px solid var(--accent-gold);
  color: white;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  font-size: 0.9rem;
  width: 240px;
  line-height: 1.4;
  text-align: center;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: 1000;
  pointer-events: none;
  font-family: var(--font-body);
  font-weight: 400;
}

[data-tooltip]:hover::before,
[data-tooltip].active::before {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

@media (max-width: 768px) {
  [data-tooltip]::before {
    width: 200px;
    font-size: 0.85rem;
  }
}