:root {
  --bg-app: #0f0e0c;
  --bg-card: #181614;
  --bg-hover: #221f1b;
  --color-texto: #e8e2d5;
  --color-secundario: #9e9589;
  --color-acento: #c4923a;
  --color-borde: #2c2722;
  --color-exito: #4e8752;
  --fuente-editorial: "Georgia", serif;
  --fuente-ui: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body { background: var(--bg-app); color: var(--color-texto); font-family: var(--fuente-ui); min-height: 100vh; }

.cuenta-nav { border-bottom: 1px solid var(--color-borde); background: var(--bg-card); padding: 16px 24px; }
.cuenta-nav-container { max-width: 1100px; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; }
.btn-volver-portal { color: var(--color-secundario); text-decoration: none; font-size: 0.9rem; }
.btn-volver-portal:hover { color: var(--color-acento); }
.marca-header { font-family: var(--fuente-editorial); font-size: 1.1rem; }
.btn-logout { background: none; border: 1px solid var(--color-borde); color: var(--color-secundario); padding: 6px 14px; border-radius: 4px; cursor: pointer; }
.btn-logout:hover { color: #fff; border-color: #555; }

.cuenta-main { max-width: 1100px; margin: 40px auto 80px auto; padding: 0 20px; display: flex; flex-direction: column; gap: 32px; }

/* Perfil Card */
.perfil-card {
  background: var(--bg-card); border: 1px solid var(--color-borde);
  border-radius: 8px; padding: 28px; display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
}
.perfil-avatar-wrapper { width: 72px; height: 72px; border-radius: 50%; overflow: hidden; border: 2px solid var(--color-acento); background: #000; }
.avatar-img { width: 100%; height: 100%; object-fit: cover; }
.perfil-datos { flex: 1 1 300px; }
.perfil-datos h2 { font-family: var(--fuente-editorial); font-size: 1.5rem; margin-bottom: 4px; }
.email-texto { color: var(--color-secundario); font-size: 0.9rem; margin-bottom: 12px; }
.perfil-badges { display: flex; gap: 12px; font-size: 0.85rem; }
.badge-nivel { background: var(--bg-hover); padding: 3px 10px; border-radius: 12px; border: 1px solid var(--color-borde); }
.badge-creditos strong { color: var(--color-acento); }
.btn-comprar-saldo { background: var(--color-acento); color: #000; padding: 10px 18px; border-radius: 6px; font-weight: 700; text-decoration: none; font-size: 0.9rem; }

/* Tabs */
.tabs-botones { display: flex; gap: 8px; border-bottom: 1px solid var(--color-borde); padding-bottom: 8px; flex-wrap: wrap; }
.tab-btn { background: none; border: none; color: var(--color-secundario); padding: 10px 18px; font-size: 0.9rem; font-weight: 600; cursor: pointer; border-radius: 6px; }
.tab-btn.activo { background: var(--bg-card); color: var(--color-acento); }
.tab-panel { display: none; padding-top: 20px; }
.tab-panel.activo { display: block; }

/* Tablas */
.tabla-cuenta { width: 100%; border-collapse: collapse; text-align: left; font-size: 0.85rem; background: var(--bg-card); border-radius: 8px; overflow: hidden; border: 1px solid var(--color-borde); }
.tabla-cuenta th, .tabla-cuenta td { padding: 14px 16px; border-bottom: 1px solid var(--color-borde); }
.tabla-cuenta th { background: #12110f; color: var(--color-secundario); font-weight: 600; text-transform: uppercase; font-size: 0.75rem; }
.fila-vacia { text-align: center; color: var(--color-secundario); padding: 30px !important; }

/* Items Biblioteca */
.grilla-items-desbloqueados { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.card-item-desbloqueado { background: var(--bg-card); border: 1px solid var(--color-borde); border-radius: 6px; padding: 20px; }
.card-item-desbloqueado h4 { font-family: var(--fuente-editorial); font-size: 1.1rem; margin-bottom: 8px; }
.btn-acceder-item { display: inline-block; color: var(--color-acento); text-decoration: none; font-size: 0.85rem; font-weight: 600; margin-top: 12px; }

/* Privacidad */
.privacidad-card { background: var(--bg-card); border: 1px solid var(--color-borde); border-radius: 8px; padding: 24px; max-width: 600px; }
.privacidad-card h3 { font-family: var(--fuente-editorial); font-size: 1.2rem; margin-bottom: 8px; }
.privacidad-card p { color: var(--color-secundario); font-size: 0.9rem; line-height: 1.5; margin-bottom: 20px; }
.btn-secundario-cuenta { background: var(--bg-hover); border: 1px solid var(--color-borde); color: var(--color-texto); padding: 10px 18px; border-radius: 6px; cursor: pointer; font-size: 0.9rem; font-weight: 600; }