@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Outfit:wght@600;700;800&display=swap');

:root {
  --bg-dark: #090a0f;
  --card-bg: #12141d;
  --card-border: #1e2230;
  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --accent-blue: #3b82f6;
  --accent-hover: #2563eb;
  --free-tag: #10b981;
  --plus-tag: #f59e0b;
  --admin-tag: #ef4444;
  --danger-bg: #dc2626;
  --danger-hover: #b91c1c;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: 'Inter', sans-serif;
  min-height: 100vh;
}

/* NAVBAR */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 32px;
  background-color: rgba(18, 20, 29, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--card-border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.logo a {
  font-family: 'Outfit', sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  color: #ffffff;
  text-decoration: none;
  letter-spacing: -0.5px;
}

.logo span {
  color: var(--accent-blue);
}

.user-menu {
  display: flex;
  align-items: center;
  gap: 16px;
}

.user-tag {
  font-size: 0.9rem;
  color: var(--text-muted);
  background: #181b26;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid var(--card-border);
}

.user-tag strong {
  color: var(--plus-tag);
}

/* BOTONES NAVBAR */
.btn-discord {
  background-color: #5865f2;
  color: #fff;
  padding: 8px 18px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.85rem;
  transition: background 0.2s ease;
}

.btn-discord:hover {
  background-color: #4752c4;
}

.btn-logout {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--card-border);
  padding: 8px 16px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.85rem;
  transition: all 0.2s ease;
}

.btn-logout:hover {
  background-color: #1e2230;
  color: #fff;
}

.btn-admin-link {
  background-color: #ef4444;
  color: #fff;
  padding: 8px 16px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.85rem;
  transition: background 0.2s ease;
}

.btn-admin-link:hover {
  background-color: #dc2626;
}

.btn-get-plus {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  border: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-get-plus:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(245, 158, 11, 0.4);
}

/* FEED GRID DE 3 COLUMNAS */
.feed {
  max-width: 1300px;
  margin: 35px auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 25px;
}

/* TARJETAS CÚBICAS DE ILUSTRACIÓN */
.card-cube {
  background-color: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
  overflow: hidden;
}

.card-cube:hover {
  transform: translateY(-4px);
  border-color: #2e3548;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}

.card-cube h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 12px;
  padding-right: 70px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-cube h3 a {
  color: var(--text-main);
  text-decoration: none;
}

.card-cube h3 a:hover {
  color: var(--accent-blue);
}

/* BADGES DE TIPO DE CONTENIDO */
.badge {
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  z-index: 2;
}

.badge.FREE {
  background-color: rgba(16, 185, 129, 0.15);
  color: var(--free-tag);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge.PLUS {
  background-color: rgba(245, 158, 11, 0.15);
  color: var(--plus-tag);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

/* CONTENEDOR DE IMAGEN */
.image-container {
  width: 100%;
  height: 280px;
  background-color: #090a0f;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
}

.image-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.card-cube:hover .image-container img {
  transform: scale(1.03);
}

/* BARRA DE ME GUSTA */
.like-bar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-top: 14px;
}

.btn-like {
  background: #191c28;
  border: 1px solid var(--card-border);
  color: #fff;
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-like:hover {
  background-color: #222738;
  border-color: #3b82f6;
  transform: scale(1.05);
}

/* MODALES Y GATEKEEPER (+18 Y PLUS) */
.gatekeeper {
  position: fixed;
  inset: 0;
  background-color: rgba(4, 5, 8, 0.88);
  backdrop-filter: blur(14px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 999;
}

.modal {
  background-color: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 32px;
  max-width: 480px;
  width: 90%;
  text-align: center;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8);
}

.modal h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.6rem;
  margin-bottom: 12px;
  color: #ef4444;
}

.modal p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.5;
  margin-bottom: 24px;
}

.modal-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.btn-age {
  padding: 10px 22px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
}

.btn-yes {
  background-color: var(--accent-blue);
  color: #fff;
}

.btn-yes:hover {
  background-color: var(--accent-hover);
}

.btn-no {
  background-color: #1e2230;
  color: var(--text-muted);
  border: 1px solid var(--card-border);
}

.btn-no:hover {
  background-color: #2a3044;
  color: #fff;
}

/* GRILLA DE PLANES EN MODAL PLUS */
.plans-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 25px;
  text-align: left;
}

.plan-card {
  background-color: #0b0c12;
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  position: relative;
}

.plan-card.recommended {
  border-color: var(--plus-tag);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.15);
}

.plan-badge-top {
  position: absolute;
  top: -11px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--plus-tag);
  color: #000;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 10px;
  border-radius: 12px;
  white-space: nowrap;
}

.plan-card h3 {
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 8px;
}

.plan-price {
  font-size: 1.8rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 14px;
}

.plan-price span {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 400;
}

.plan-features {
  list-style: none;
  margin-top: 15px;
}

.plan-features li {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 8px;
  line-height: 1.4;
}

/* EFECTO DESENFOQUE PARA MENORES DE EDAD */
.blurred {
  filter: blur(18px);
  pointer-events: none;
  user-select: none;
}

/* ADAPTACIÓN RESPONSIVA (TABLETS Y MÓVILES) */
@media (max-width: 1024px) {
  .feed {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 680px) {
  .navbar {
    flex-direction: column;
    gap: 15px;
    padding: 16px;
  }
  
  .feed {
    grid-template-columns: 1fr;
  }

  .plans-grid {
    grid-template-columns: 1fr;
  }
  
  .image-container {
    height: 240px;
  }
}