:root {
  /* Clean & Modern Palette */
  --primary-color: #000000;       /* azul fuerte */
  --secondary-color: #00a8ff;     /* azul claro */
  --bg-color: #f5f7fa;            /* gris muy claro */
  --card-bg: #ffffff;             /* blanco puro para secciones */
  --text-color: #333333;          /* gris oscuro para texto */
  --border-color: #e1e4ea;        /* gris suave para bordes */
  --error-color: #e12d39;         /* rojo suave */
  --nav-height: 70px;
  --transition-speed: 0.25s;
}


html, body {
  height: 100%;
  margin: 0;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  font-family: 'Inter', sans-serif;
  background: var(--bg-color);
  color: var(--text-color);
  line-height: 1.5;
}

* {
  box-sizing: border-box;
}

.container {
  flex: 1;
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem 1rem 1rem;  /* 👈 antes era 2rem abajo, lo bajamos a 1rem */
}


/* NAVBAR */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--card-bg);
  /* height: var(--nav-height);  🔴 quita esto */
  min-height: var(--nav-height);  /* ✅ altura mínima, puede crecer si hace falta */
  padding: 0 1.5rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  position: sticky;
  top: 0;
  z-index: 10;
}

.navbar-brand a {
  color: var(--primary-color);
  font-size: 1.25rem;
  font-weight: 600;
  text-decoration: none;
}
.navbar-menu {
  list-style: none;
  display: flex;
   margin: 0;    /* 👈 añade esto */
  padding: 0;   /* mejor también resetear el padding */
}
.navbar-menu li {
  margin-left: 1.5rem;
}
.navbar-menu li a {
  color: var(--text-color);
  text-decoration: none;
  font-weight: 500;
  transition: color var(--transition-speed);
}
.navbar-menu li a:hover {
  color: var(--primary-color);
}

/* TOGGLE (mobile) */
.navbar-toggle {
  display: none;
  font-size: 1.5rem;
  color: var(--text-color);
  background: none;
  border: none;
  cursor: pointer;
}

@media (max-width: 768px) {
  .navbar-toggle { display:block; }
  .navbar {
    position: sticky;
    top: 0;
    z-index: 20;      /* asegúrate de que esté por encima del contenido */
    padding: 0.5rem 1.25rem;
  }


   .navbar-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--card-bg);
    flex-direction: column;
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition-speed);
    align-items: center;
    padding: 0;
    border-bottom: 1px solid var(--border-color); /* 👈 ESTA */
  }

  .navbar-menu.active {
    max-height: 300px;
    border-bottom: 1px solid var(--border-color); /* 👈 solo cuando está abierto */
  }

  .navbar-menu li{
    width:100%;
    margin:0;
  }
  .navbar-menu li a{
    display:block;
    width:100%;
    padding:1rem 0;
    text-align:center;
  }
  /* En móvil, que el grid se adapte bien (ya lo hace con auto-fill, pero por si acaso) */

  .dashboard-links {
    margin-top: 1.5rem;
  }
}


.navbar-user-strip {
  background: #111827;       /* un gris más oscuro que el de antes */
  color: #f3f4f6;
  border-bottom: 1px solid #1f2937;
  font-size: 0.9rem;
}


.navbar-user-strip-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0.4rem 1rem;
  display: flex;
  justify-content: center;   /* ✅ centra horizontalmente todo el contenido */
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;           /* para que en móvil se parta si hace falta */
  text-align: center;        /* por si hay varias líneas */
}


.navbar-user-name {
  font-weight: 500;
}

/* Ajuste visual de los badges dentro de la strip */
.navbar-user-strip .user-badge,
.navbar-user-strip .badge-admin {
  margin-left: 4px;
}



/* HEADINGS */
h1, h2 {
  margin-bottom: 1.25rem;
  color: var(--primary-color);
  font-weight: 600;
}

/* FORMULARIOS */
form {
  background: var(--card-bg);
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  margin-bottom: 2rem;
}
form label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}
form input,
form select,
form textarea {
  width: 100%;
  padding: 0.75rem;
  margin-bottom: 1rem;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  background: var(--bg-color);
  color: var(--text-color);
  transition: border-color var(--transition-speed);
}
form input:focus,
form select:focus,
form textarea:focus {
  border-color: var(--primary-color);
  outline: none;
}
form button {
  background: var(--primary-color);
  color: #fff;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 500;
  transition: background var(--transition-speed);
}
form button:hover {
  background: var(--secondary-color);
}

/* TABLAS */
table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card-bg);
  margin-bottom: 2rem;
}
th, td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-color);
  text-align: left;
}
th {
  background: #f0f2f5;
  font-weight: 600;
}

/* MENSAJES */
.error {
  color: var(--error-color);
  margin-bottom: 1rem;
}
.success {
  color: var(--primary-color);
  margin-bottom: 1rem;
}

form label {
  display: block;
  margin-bottom: 0.75rem;
}
form input, form select {
  width: 100%;
  max-width: 300px;
}


/* ---------- compartir gastos ---------- *//* ---------- compartir gastos ---------- *//* ---------- compartir gastos ---------- *//* ---------- compartir gastos ---------- */

/* ---------- Cards ---------- */
.card {
  background: #fff;
  border: 1px solid #e1e4ea;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,.05);
  margin-bottom: 1.5rem;
  overflow: hidden;
}

/* ---------- Tablas limpias ---------- */
.table-clean {
  width: 100%;
  border-collapse: collapse;
}
.table-clean thead {
  background: #f6f8fa;
  position: sticky;
  top: 0;
  z-index: 5;
}
.table-clean th,
.table-clean td {
  padding: .75rem 1rem;
  border-bottom: 1px solid #e1e4ea;
  text-align: left;
}
.table-clean tbody tr:nth-child(odd) {
  background: #fafbfc;
}
.table-clean tbody tr:hover {
  background: #eef3ff;
}

/* Números alineados a la derecha */
.text-right { text-align: right; }

/* ---------- Badges de saldo ---------- */
.badge {
  display: inline-block;
  min-width: 70px;
  padding: .25rem .5rem;
  border-radius: 12px;
  color: #fff;
  font-weight: 600;
  text-align: center;
}
.badge-pos { background: #28a745; }   /* verde */
.badge-neg { background: #d93025; }   /* rojo  */

/* ---------- Expense Card ---------- */
.expense-card{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:1rem;
  padding:.9rem 1.1rem;
  border:1px solid #e1e4ea;
  border-radius:8px;
  background:#fff;
  box-shadow:0 1px 4px rgba(0,0,0,.04);
  margin-bottom:.8rem;
  align-items:flex-start;      /* importante: permite varias líneas */
  max-width:100%;             /* ¡no más ancho que el contenedor! */
  flex-wrap:wrap;             /* en móvil se parte en 2 líneas */
}
.expense-info{
  line-height:1.35;
}
.expense-title{
  font-weight:600;
  font-size:1.05rem;
}
.expense-meta{
  font-size:.8rem;
  color:#666;
}
.expense-amount{
  font-weight:700;
  font-size:1.15rem;
  text-align:right;
  min-width:90px;
}
.expense-amount.positivo{color:#28a745;}
.expense-amount.negativo{color:#d93025;}
/* ---------- Compact saldos ---------- */
.balance-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
  gap:.8rem;
}
.balance-card{
  background:#fff;
  border:1px solid #e1e4ea;
  border-radius:8px;
  padding:.8rem 1rem;
  box-shadow:0 1px 4px rgba(0,0,0,.05);
  text-align:center;
}
.balance-user{font-weight:600;margin-bottom:.3rem;}
.balance-num{font-size:1.1rem;}
.balance-pos{color:#28a745;}
.balance-neg{color:#d93025;}


/* ---------- compartir gastos ---------- *//* ---------- compartir gastos ---------- *//* ---------- compartir gastos ---------- */

/* HEADER: título y controles en línea */
.group-head {
  display: flex;
  align-items: center;
  gap: 1rem;              /* espacio entre título y controles */
  margin-bottom: 1.5rem;
}

/* Título sin márgenes extra */
.group-head h2 {
  margin: 0;
  font-size: 1.75rem;
}

/* CONTROLS: icono + botón */
.group-controls {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  /* Si quieres que los controles se queden a la derecha de todo el header,
     descomenta esta línea: */
  /* margin-left: auto; */
}

/* Ajustes al dropdown de miembros */
.member-drop summary {
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

/* ---------- Mini popup de miembros ---------- */
.member-drop{ position:relative; }
.member-drop summary{
  cursor:pointer;
  font-size:.85rem;
  font-weight:500;
  list-style:none;         /* quitamos triángulo nativo */
  user-select:none;
}
.member-drop ul{
  position:absolute;
  right:0;
  top:calc(100% + 4px);    /* 4px de separación */
  background:#fff;
  border:1px solid #e1e4ea;
  border-radius:6px;
  box-shadow:0 2px 6px rgba(0,0,0,.08);
  padding:.6rem .9rem;
  min-width:140px;
  display:none;
  z-index:50;
  font-size:.85rem;
  list-style:none;
  margin:0;
}
.member-drop[open] ul{ display:block; }
.member-drop li{ margin:0 0 .25rem; }
.member-drop li:last-child{ margin-bottom:0; }

/* ---------- Botón pill pastel ---------- */
.btn-pill{
  display:inline-flex;
  align-items:center;
  gap:.35rem;
  background:var(--pastel-primary);
  color:var(--text-on-pastel);
  padding:.45rem .95rem;
  border-radius:999px;
  font-size:.85rem;
  font-weight:500;
  text-decoration:none;
  transition:background .15s, box-shadow .15s;
  box-shadow:0 1px 3px rgba(0,0,0,.10);
}
.btn-pill:hover{
  background:var(--pastel-primary-h);
  box-shadow:0 2px 6px rgba(0,0,0,.12);
}

/* Botón secundario */
.btn-sec{
  background:var(--pastel-sec);
  color:#333;
}
.btn-sec:hover{
  background:var(--pastel-sec-h);
}



/* ---------- Contenedor de acciones ---------- */
.group-actions{
  margin-left:auto;
  display:flex;
  gap:.6rem;
  flex-wrap:wrap;
}

/* ---------- Encabezado de sección ---------- */
.section-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-top:2rem;
  flex-wrap:wrap;
}
.section-head h3{
  margin:0;
  display:flex;
  align-items:baseline;
  gap:.4rem;
}
.section-head .expense-meta{
  font-size:.9rem;
  color:#666;
}


/* ═════════════════════ Historial dentro de la tarjeta gasto ═════════════════════ */

/* Botón desplegable */
.exp-history summary{
  cursor:pointer;
  font-size:.8rem;
  margin-top:.4rem;
  color:#0052cc;
}

/* Lista de versiones */
.exp-history{
  max-width:100%;              /* nunca más ancha que la tarjeta */
  overflow-wrap:anywhere;      /* rompe cualquier palabra larga */
}
.exp-history ul{
  margin:.4rem 0 0 1rem;
  font-size:.8rem;
  list-style:disc;
  overflow-wrap:anywhere;      /* idem */
  white-space:normal;
}
.exp-history li{
  margin-bottom:.3rem;
}
.exp-history li code{
  background:#eef2ff;
  padding:1px 4px;
  border-radius:4px;
}

/* Parte izquierda: título + meta + historial */
.expense-info{
  flex:1 1 0;                  /* puede crecer y encogerse */
  min-width:0;                 /* fuerza el wrap antes de ensanchar */
}

/* Parte derecha: importe */
.expense-amount{
  flex:0 0 100px;              /* ancho fijo, no cambia */
  text-align:right;
}

.edited-badge{
  display:inline-block;
  margin-left:.35rem;
  padding:0 .35rem;
  font-size:.7rem;
  font-weight:600;
  color:#fff;
  background:#ff9800;    /* naranja suave */
  border-radius:4px;
  vertical-align:middle;
}

/* Historial más compacto */
.history-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.history-list li {
  margin-bottom: 0.6rem;
}
.history-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  margin-bottom: 0.2rem;
}
.history-details {
  gap: 0.5rem;
  font-size: 0.85rem;
  margin-top: 0.3rem;
  display: block;
}
.history-details span + span::before {
  content: "|";
  margin: 0 0.3rem;
  color: #ccc;
}
.history-time {
  color: #6c757d;          /* gris medio */
}
.history-editor {
  color: var(--secondary-color);
  font-weight: 600;
}

.history-amount {
  color: #28a745;          /* verde para positivo */
  font-weight: 600;
}
.history-date {
  color: #007bff;          /* azul para la fecha original */
}
.history-title {
  display: block;
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0.25rem;
}
/* importe y fecha en la segunda línea */
/* Segunda fila: importe y fecha */
.history-meta {
  display: flex;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: #555;
}


/*Listas de grupos */

/* ———————————————————————————————— */
/* Estilos para la lista de grupos */
/* ———————————————————————————————— */

.button {
  display: block;
  margin: 2rem auto; /* arriba/abajo 2rem, y centrado lateralmente */
  background: var(--primary-color);
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 500;
  transition: background var(--transition-speed);
  text-align: center;
}
.button:hover {
  background: var(--secondary-color);
}


.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.group-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
}

.group-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1.25rem;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  transition: transform var(--transition-speed), box-shadow var(--transition-speed);
  color: var(--primary-color);
  text-decoration: none;
}
.group-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}
.group-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
}

/* 1) Card como bloque para apilar contenido */
.expense-card {
  display: block;
  width: 100%;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: var(--card-bg);
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
  margin-bottom: 0.8rem;
  overflow: hidden;
  transition: box-shadow var(--transition-speed) ease;
}
.expense-card:hover {
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* 2) Summary sigue en flex para título ↔ importe */
.expense-card summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 0.9rem 1.1rem;
  cursor: pointer;
  user-select: none;
}
.expense-card summary::-webkit-details-marker {
  display: none;
}

/* 3) Animación slide+fade */
@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 4) Historial oculto inicialmente */
.expense-card .exp-history {
  opacity: 0;
  transform: translateY(-10px);
  padding: 0 1.25rem;
  margin-top: 0;
}

/* 5) Al abrir, “cae” justo debajo */
.expense-card[open] .exp-history {
  margin-top: 0.5rem;
  animation: slideDown 0.35s ease-out forwards;
}

/*saldos */

/* Encabezado de la sección */
.balances-section .section-head h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

/* Grid de balances */
.balance-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

/* Tarjeta individual */
.balance-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1rem;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

/* Cabecera con nombre e icono */
.balance-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.balance-user {
  font-weight: 600;
  font-size: 1.1rem;
}
.balance-status {
  font-size: 1.25rem;
}
.balance-status.positive { color: #28a745; }  /* verde */
.balance-status.negative { color: #d93025; }  /* rojo  */

/* Monto principal */
.balance-amount {
  font-size: 1.5rem;
  font-weight: 700;
}
.balance-amount.positive { color: #28a745; }
.balance-amount.negative { color: #d93025; }

/* Detalles secundarios */
.balance-details {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.9rem;
  color: #555;
}
.balance-details li {
  display: flex;
  justify-content: space-between;
}
.balance-details strong {
  font-weight: 600;
  color: var(--text-color);
}

/* Encabezado flex del resumen */
.debt-summary-header {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Título sin márgenes extra */
.debt-summary h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
}

/* Detalles (⚙️) como botón pequeño */
/* botón ⚙️ junto al resumen */
.share-config {
  position: relative;
  display: inline-block;
  margin-left: 0.5rem;
}
.share-config summary {
  list-style: none;
  cursor: pointer;
  padding: 0.25rem;
  font-size: 1.1rem;
  user-select: none;
}
.share-config summary::-webkit-details-marker {
  display: none;
}
/* popup con el form */
.share-form-container {
  position: absolute;
  top: 100%;
  right: 0;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 1rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  margin-top: 0.5rem;
  z-index: 100;
  width: 220px;
}
/* lista vertical de inputs */
.share-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: 340px;
  overflow-y: auto;
  margin-bottom: 1rem;
}
.share-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.share-item input {
  width: 4rem;
  padding: 0.25rem;
  text-align: right;
  border: 1px solid var(--border-color);
  border-radius: 4px;
}


/* Restablecer estilo visual del Resumen de Deudas */
.debt-summary {
  background: #fffbe6;
  border: 1px solid #ffe58f;
  border-radius: 6px;
  padding: 0.8rem 1rem;
  margin: 1rem 0 1.5rem;
}
.debt-summary ul {
  margin: 0.5rem 0 0 1.2rem;
  padding: 0;
  list-style: disc inside;
}
.debt-summary li {
  margin-bottom: 0.4rem;
  font-size: 0.9rem;
}

.history-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.5rem;
  align-items: center;
}

/* Haz que el form se comporte igual que el <a> */
.history-actions form {
  display: inline-flex;
  align-items: center;
  margin: 0;      /* quita márgenes por defecto */
  padding: 0;     /* quita padding por defecto */
}

/* Ambos controles comparten esta clase: */
.btn-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: none;
  border-radius: 50%;
  font-size: 1.1rem;
  cursor: pointer;
  transition: background var(--transition-speed);
  text-decoration: none;
  vertical-align: middle;  /* refuerza el centrado vertical */
  margin: 0;               /* quita márgenes */
}


/* Editar: azul claro */
.btn-edit {
  background: var(--secondary-color);
  color: #fff;
}
.btn-edit:hover {
  background: #008ad6;     /* un tono 10% más oscuro que #00a8ff */
}

/* Eliminar: rojo y hover más oscuro */
.btn-delete {
  background: var(--error-color);
  color: #fff;
}
.btn-delete:hover {
  background: #c82333;
}

/* ==== Dashboard principal: tarjetas de enlaces ==== */

/* Contenedor de las tarjetas del dashboard */
.dashboard-links {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

/* Tarjeta base */
.group-card {
  border: 2px solid #ddd;
  border-radius: 12px;
  padding: 1rem;
  background: #fff;
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
  display: block;
  color: #222;
}
.group-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* Título dentro de la tarjeta */
.group-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #333;
  margin-bottom: 0.5rem;
}

/* Ajuste del texto dentro de las tarjetas del dashboard */
.dashboard-links .group-card p {
  margin: 0.5rem 0 0;
  font-size: 0.9rem;
  color: #555;
}

/* --- Tarjetas premium (todas) → chapa ⭐ y borde azul resplandeciente --- */
.dashboard-card-premium {
  position: relative;
  overflow: hidden;
  border-color: var(--secondary-color, #00a8ff);
  box-shadow: 0 0 12px rgba(0, 168, 255, 0.25),
              0 0 25px rgba(0, 168, 255, 0.15),
              inset 0 0 6px rgba(0, 168, 255, 0.2);
}

.dashboard-card-premium::after {
  content: "⭐  Premium";
  position: absolute;
  top: 4px;
  right: 6px;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #fff;
  background: var(--secondary-color, #00a8ff);
  padding: 2px 6px;
  border-radius: 999px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
  z-index: 2;
  opacity: 0.95;
}

/* Tarjeta bloqueada (por si decides usarlas luego) */
.dashboard-card-locked {
  opacity: 0.7;
  cursor: not-allowed;
}
.dashboard-card-locked:hover {
  transform: none;
}

/* Responsive */
@media (max-width: 600px) {
  .group-card {
    padding: 0.8rem;
    font-size: 0.9rem;
  }
  .group-title {
    font-size: 1rem;
  }
}
    .user-badge {
      font-size: 0.75rem;
      margin-left: 6px;
      padding: 2px 6px;
      border-radius: 999px;
      font-weight: 600;
    }
    /* Premium (azul brillante con gradiente) */
.badge-premium {
  background: linear-gradient(135deg, #00c6ff, #0072ff);
  color: #fff;
}


/* Estándar (gris neutro, sin cambiar) */
.badge-standard {
  background: #374151;
  color: #d1d5db;
}
    /* --- Admin dorado con brillo y volumen (mismo tamaño que Premium) --- */
.badge-admin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 75px; /* 👈 igual que el premium */
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
  color: #fff8dc; /* marfil suave */
  background: linear-gradient(135deg, #f8d847, #b8860b);
  border: 1px solid rgba(255, 215, 0, 0.4);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
  box-shadow:
    0 2px 5px rgba(0, 0, 0, 0.25),
    inset 0 1px 2px rgba(255, 255, 255, 0.3),
    0 0 8px rgba(255, 223, 0, 0.4);
  transition: all 0.25s ease;
}

/* --- Enlace para el badge admin --- */
.badge-admin-link {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Efecto visual sutil al pasar el ratón */
.badge-admin-link:hover .badge-admin {
  transform: scale(1.05);
  box-shadow:
    0 3px 8px rgba(0, 0, 0, 0.3),
    0 0 12px rgba(255, 223, 0, 0.8);
  transition: all 0.2s ease;
}


/* === Botón del nombre de usuario en la barra (versión más clara) === */
.navbar-user-name-btn {
  display: inline-flex;
align-items: center;
justify-content: center;
min-width: 75px;           /* igual que el premium */
padding: 4px 8px;
border-radius: 999px;
font-size: 0.75rem;
font-weight: 600;
line-height: 1;
color: #f9fafb;            /* texto gris muy claro / casi blanco */
background: rgba(255, 255, 255, 0.25); /* el gris translúcido que estás usando */
border: 1px solid rgba(249, 250, 251, 0.6); /* borde claro suave */
text-shadow: 0 1px 2px rgba(15, 23, 42, 0.5); /* sombra discreta para legibilidad */
box-shadow:
  0 2px 5px rgba(15, 23, 42, 0.35),          /* sombra exterior suave en gris oscuro */
  inset 0 1px 2px rgba(255, 255, 255, 0.25), /* brillo interior */
  0 0 8px rgba(148, 163, 184, 0.45);         /* halo gris-azulado suave */
transition: all 0.25s ease;
text-decoration: none;

}

.navbar-user-name-btn:hover {
  transform: scale(1.05);
  box-shadow:
    0 3px 8px rgba(0, 0, 0, 0.3),
    0 0 12px rgba(255, 223, 0, 0.8);
  transition: all 0.2s ease;
}

.navbar-user-name-btn:active {
  transform: translateY(0);
  background: rgba(255, 255, 255, 0.12);
}















/* === Porcentaje vs ahorro base (sobre fondo verde) === */
.pf-summary-baseline-diff {
  display: inline-block;
  font-weight: 700;
  font-size: 0.9rem;
  color: #b9ffb9; /* verde claro brillante */
  text-shadow:
    0 0 4px rgba(0, 0, 0, 0.8),   /* sombra principal fuerte */
    0 0 8px rgba(0, 0, 0, 0.6),   /* halo oscuro */
    0 0 12px rgba(150, 255, 150, 0.4); /* leve resplandor verde */
  letter-spacing: 0.02em;
  transition: transform 0.15s ease, opacity 0.2s ease;
}

.pf-summary-baseline-diff:hover {
  transform: scale(1.04);
  opacity: 0.95;
}



/* FOOTER “sticky” */
/* FOOTER “sticky” */
/* FOOTER “sticky” */
.footer {
  margin-top: auto;                         /* 👈 lo usamos para pegarlo abajo */
  background: var(--card-bg);               /* misma barra blanca que arriba */
  box-shadow: 0 -2px 4px rgba(0,0,0,0.05);
  border-top: 1px solid var(--border-color);
  padding: 0.75rem 1.5rem;                  /* espacio interno */
  text-align: center;
  font-size: 0.85rem;
  color: #6b7280;
}

