/*
Theme Name: Kerifa
Theme URI: https://kerifa.com
Author: Adiel
Author URI: https://kerifa.com
Description: Theme moderno y responsivo para KeRifa, con dashboard de usuario integrado y diseño compatible con el monedero QvaPay Wallet Premium.
Version: 1.0.0
Text Domain: kerifa
*/

/* Reset básico y tipografía */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  color: #111827;
  background-color: #f3f4f6;
}

a {
  color: #4f46e5;
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: #4338ca;
}

/* Enlaces estilizados para el historial de transacciones */
.kerifa-history-link {
  color: #6366f1;
  text-decoration: none;
  font-weight: 500;
  padding: 2px 6px;
  border-radius: 4px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(99, 102, 241, 0.05) 100%);
  transition: all 0.2s ease;
  display: inline-block;
  position: relative;
}

.kerifa-history-link:hover {
  color: #4f46e5;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(99, 102, 241, 0.1) 100%);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(99, 102, 241, 0.2);
}

.kerifa-history-link:active {
  transform: translateY(0);
}

img {
  max-width: 100%;
  height: auto;
}

/* Layout general */

.k-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

.k-site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #ffffff;
  border-bottom: 1px solid #e5e7eb;
  backdrop-filter: blur(8px);
}

/* Asegurar que el header no interfiera con el menú móvil cuando está abierto */
body.menu-open .k-site-header {
  z-index: 1;
}

.k-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0;
  position: relative;
}

/* Layout móvil: hamburger | logo | carrito */
@media (max-width: 900px) {
  .k-header-inner {
    gap: 1rem;
    padding: 1.25rem 0; /* Aumentado de 0.9rem para más altura */
    min-height: 64px; /* Altura mínima para mejor espaciado */
  }
  
  .k-mobile-toggle {
    order: 1;
    flex-shrink: 0;
    padding: 0.75rem; /* Aumentado de 0.5rem para más área de toque */
  }
  
  .k-logo {
    order: 2;
    flex: 1;
    justify-content: center;
  }
  
  .k-header-cta {
    order: 3;
    flex-shrink: 0;
  }
  
  .k-cart-icon {
    padding: 0.75rem; /* Aumentado de 0.5rem para más área de toque */
  }
  
  .k-main-nav {
    display: none;
  }
}

.k-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem; /* Aumentado gap */
  font-weight: 700;
  font-size: 1.25rem;
  color: #111827;
  text-decoration: none;
  transition: opacity 0.2s ease;
  padding: 0.5rem 0; /* Padding vertical para mejor espaciado */
}

.k-logo:hover {
  opacity: 0.8;
}

.k-logo-text {
  display: inline-block;
}

@media (max-width: 900px) {
  .k-logo {
    gap: 0.5rem;
    padding: 0.25rem 0;
  }
}

.k-logo-mark {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 1.1rem;
  font-weight: 700;
  flex-shrink: 0;
}

@media (max-width: 900px) {
  .k-logo-mark {
    width: 44px;
    height: 44px;
    font-size: 1.2rem;
  }
}

.k-main-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-size: 0.95rem;
}

.k-main-nav a {
  color: #4b5563;
  font-weight: 500;
}

.k-main-nav a:hover {
  color: #111827;
}

.k-header-cta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Balance en header */
.k-header-balance {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  text-decoration: none;
}

.k-header-balance::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}

.k-header-balance:hover::before {
  left: 100%;
}

.k-header-balance:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.k-balance-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.k-balance-amount {
  font-size: 1rem;
  font-weight: 700;
  color: #ffffff;
  display: flex;
  align-items: baseline;
  gap: 0.25rem;
}

.k-balance-currency {
  font-size: 0.75rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  opacity: 0.9;
}

.k-btn {
  border-radius: 999px;
  padding: 0.45rem 1.1rem;
  font-size: 0.9rem;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.2s ease;
  text-decoration: none;
}

.k-btn-primary {
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #ffffff;
  box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.3);
}

.k-btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 15px 25px -5px rgba(79, 70, 229, 0.4);
}

.k-btn-outline {
  background: #ffffff;
  border-color: #e5e7eb;
  color: #374151;
}

.k-btn-outline:hover {
  border-color: #4f46e5;
  color: #111827;
}

.k-mobile-toggle {
  display: none;
  background: none;
  border: none;
  padding: 0.5rem;
  cursor: pointer;
  color: #111827;
  transition: opacity 0.2s ease;
  flex-shrink: 0;
}

.k-mobile-toggle:hover {
  opacity: 0.7;
}

.k-mobile-toggle svg {
  display: block;
}

/* Carrito móvil */
.k-cart-icon {
  position: relative;
  display: none;
  padding: 0.5rem;
  color: #111827;
  text-decoration: none;
  transition: opacity 0.2s ease;
  flex-shrink: 0;
}

.k-cart-icon:hover {
  opacity: 0.7;
}

.k-cart-count {
  position: absolute;
  top: 0;
  right: 0;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  box-shadow: 0 2px 4px rgba(99, 102, 241, 0.3);
}

@media (max-width: 900px) {
  .k-cart-icon {
    display: block;
  }
}

/* Footer */

.k-site-footer {
  margin-top: 3rem;
  padding: 2rem 0 1.5rem;
  background: #111827;
  color: #9ca3af;
}

.k-footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  font-size: 0.85rem;
  flex-wrap: wrap;
}

.k-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.k-footer-links a {
  color: #9ca3af;
}

.k-footer-links a:hover {
  color: #e5e7eb;
}

/* Dashboard de cuenta (WooCommerce My Account) */

.k-account-wrapper {
  max-width: 1400px;
  margin: 2rem auto 3rem;
  padding: 0 1.25rem;
}

.k-account-card {
  background: #ffffff;
  border-radius: 1rem;
  border: 1px solid #e5e7eb;
  box-shadow: 0 10px 25px -10px rgba(15, 23, 42, 0.25);
  padding: 2rem 1.75rem;
}

.k-account-title {
  font-size: 2.1rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
  color: #111827;
}

.k-account-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.k-account-subtitle {
  font-size: 0.95rem;
  color: #6b7280;
}

.k-account-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.k-account-nav li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.85rem;
  border-radius: 999px;
  color: #4b5563;
  font-size: 0.92rem;
  font-weight: 500;
  border: 1px solid transparent;
}

.k-account-nav li.is-active a,
.k-account-nav li a:hover {
  background: #eef2ff;
  color: #3730a3;
  border-color: #c7d2fe;
}

.k-account-nav li.is-active a::after {
  content: "•";
  font-size: 1.1rem;
}

.k-account-content {
  background: transparent;
  padding: 0;
}

.k-account-content .woocommerce-MyAccount-content {
  margin: 0;
}

.k-account-full {
  width: 100%;
}

/* Alineación con el diseño QVP wallet */

/* Ocultar el título "My Account" de WordPress (pero NO el banner de bienvenida) */
.woocommerce-account .entry-title,
.woocommerce-account .page-title,
.woocommerce-account h1.page-title,
.woocommerce-account .entry-header h1,
.woocommerce-account .entry-header,
.woocommerce-account .post-title,
.woocommerce-account article h1,
body.woocommerce-account .entry-title,
body.woocommerce-account .page-title,
body.woocommerce-account .entry-header h1,
body.woocommerce-account .entry-header,
body.woocommerce-account article .entry-title,
body.woocommerce-account article h1:not(.kerifa-header-text h1) {
  display: none !important;
}

/* Asegurar que el banner de bienvenida SÍ se muestre */
.woocommerce-account .kerifa-dashboard-header h1,
.woocommerce-account .kerifa-header-text h1,
.woocommerce-account .k-account-top h1,
.woocommerce-account .k-account-header h1 {
  display: block !important;
}

.woocommerce-account .woocommerce {
  margin: 0;
}

/* Formularios genéricos */

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
textarea,
select {
  border-radius: 0.6rem;
  border: 1px solid #d1d5db;
  padding: 0.7rem 0.8rem;
  font-family: inherit;
  font-size: 0.95rem;
  width: 100%;
  background: #fff;
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: #6366f1;
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.25);
}

button,
input[type="submit"] {
  font-family: inherit;
}

.k-form-card {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: 0 10px 25px -15px rgba(15, 23, 42, 0.2);
  margin-bottom: 1.25rem;
}

.k-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

.k-field-label {
  font-weight: 600;
  font-size: 0.93rem;
  color: #111827;
  margin-bottom: 0.35rem;
  display: inline-block;
}

.k-help {
  font-size: 0.85rem;
  color: #6b7280;
  margin-top: 0.15rem;
}

.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
  border-radius: 999px;
  border: none;
  padding: 0.55rem 1.3rem;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #ffffff;
  font-weight: 600;
  font-size: 0.9rem;
}

.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover {
  background: linear-gradient(135deg, #4f46e5, #4338ca);
  color: #fff !important;
}

/* Responsive */

@media (max-width: 900px) {
  .k-header-inner {
    gap: 0.75rem;
    padding: 1.25rem 0; /* Aumentado para más altura en móvil */
  }

  .k-main-nav {
    display: none;
  }

  .k-mobile-toggle {
    display: inline-flex;
  }

  .k-account-top {
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  .k-account-card {
    padding: 1.5rem 1.25rem;
  }

  .k-account-title {
    font-size: 1.7rem;
  }
}

/* ============================================
   DASHBOARD UNIFICADO - Diseño base del monedero
   ============================================ */

:root {
  --kerifa-primary: #6366f1;
  --kerifa-primary-dark: #4f46e5;
  --kerifa-success: #10b981;
  --kerifa-warning: #f59e0b;
  --kerifa-danger: #ef4444;
  --kerifa-info: #3b82f6;
  --kerifa-dark: #1f2937;
  --kerifa-light: #f9fafb;
  --kerifa-border: #e5e7eb;
  --kerifa-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1);
  --kerifa-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
  --kerifa-radius: 12px;
  --kerifa-transition: all 0.3s ease;
}

body.dark-mode {
  --kerifa-dark: #f9fafb;
  --kerifa-light: #1f2937;
  --kerifa-border: #374151;
  background: #111827;
  color: #f9fafb;
}

body.dark-mode .kerifa-balance-card,
body.dark-mode .kerifa-action-card,
body.dark-mode .kerifa-history-table,
body.dark-mode .kerifa-chart-container {
  background: #1f2937;
  color: #f9fafb;
  border-color: #374151;
}

body.dark-mode .kerifa-history-link {
  color: #818cf8;
  background: linear-gradient(135deg, rgba(129, 140, 248, 0.15) 0%, rgba(129, 140, 248, 0.08) 100%);
}

body.dark-mode .kerifa-history-link:hover {
  color: #a5b4fc;
  background: linear-gradient(135deg, rgba(129, 140, 248, 0.25) 0%, rgba(129, 140, 248, 0.15) 100%);
  box-shadow: 0 2px 4px rgba(129, 140, 248, 0.3);
}

body.dark-mode .kerifa-balance-amount,
body.dark-mode .kerifa-action-card h3,
body.dark-mode .kerifa-chart-container h3 {
  color: #f9fafb;
}

body.dark-mode .kerifa-form-group input,
body.dark-mode .kerifa-form-group select,
body.dark-mode .kerifa-form-group textarea {
  background: #111827;
  color: #f9fafb;
  border-color: #374151;
}

body.dark-mode .kerifa-nav-tab {
  color: #9ca3af;
}

body.dark-mode .kerifa-nav-tab.active {
  color: var(--kerifa-primary);
}

body.dark-mode .kerifa-balance-label {
  color: #9ca3af;
}

/* Tablas */
.kerifa-table-container {
  overflow-x: auto;
  margin-top: 20px;
}

.kerifa-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border-radius: var(--kerifa-radius);
  overflow: hidden;
  box-shadow: var(--kerifa-shadow);
}

.kerifa-table thead {
  background: var(--kerifa-light);
}

.kerifa-table th {
  padding: 16px;
  text-align: left;
  font-weight: 600;
  color: var(--kerifa-text);
  border-bottom: 2px solid var(--kerifa-border);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kerifa-table td {
  padding: 16px;
  border-bottom: 1px solid var(--kerifa-border);
  color: var(--kerifa-text);
}

.kerifa-table tbody tr:hover {
  background: rgba(99, 102, 241, 0.05);
}

.kerifa-table tbody tr:last-child td {
  border-bottom: none;
}

body.dark-mode .kerifa-table {
  background: var(--kerifa-dark-bg);
  border-color: var(--kerifa-dark-border);
}

body.dark-mode .kerifa-table thead {
  background: #111827;
}

body.dark-mode .kerifa-table th,
body.dark-mode .kerifa-table td {
  border-color: var(--kerifa-dark-border);
  color: #f9fafb;
}

body.dark-mode .kerifa-table tbody tr:hover {
  background: rgba(99, 102, 241, 0.15);
}

/* Badges de estado de pedidos */
.kerifa-badge-processing {
  background: #dbeafe;
  color: #1e40af;
}

.kerifa-badge-completed {
  background: #d1fae5;
  color: #065f46;
}

.kerifa-badge-cancelled {
  background: #fee2e2;
  color: #991b1b;
}

.kerifa-badge-on-hold {
  background: #fef3c7;
  color: #92400e;
}

.kerifa-badge-refunded {
  background: #f3f4f6;
  color: #374151;
}

/* Wrapper del dashboard */
.kerifa-dashboard-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Header del dashboard */
.kerifa-dashboard-header {
  background: linear-gradient(135deg, var(--kerifa-primary) 0%, var(--kerifa-primary-dark) 100%);
  color: #fff;
  padding: 40px 30px;
  border-radius: var(--kerifa-radius);
  margin-bottom: 30px;
  box-shadow: var(--kerifa-shadow-lg);
  position: relative;
}

.kerifa-header-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  flex-wrap: wrap;
}

.kerifa-header-text {
  flex: 1;
  min-width: 0;
}

.kerifa-dashboard-header h1 {
  margin: 0 0 10px;
  font-size: 32px;
  font-weight: 700;
  color: #fff !important;
}

.kerifa-dashboard-header p {
  margin: 0;
  opacity: 0.9;
  font-size: 16px;
}

.kerifa-dark-mode-toggle {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: #fff;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  transition: var(--kerifa-transition);
  display: flex;
  align-items: center;
  gap: 8px;
}

.kerifa-dark-mode-toggle:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* ============================================
   RIFAS ACTIVAS EN FRONT PAGE
   ============================================ */

.kerifa-raffles-grid-active {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 30px;
  max-width: 100%;
}

/* Cuando hay solo 1 rifa, centrarla en la columna del medio */
.kerifa-raffles-grid-active.single-raffle {
  grid-template-columns: 1fr 1fr 1fr;
}

.kerifa-raffles-grid-active.single-raffle .kerifa-raffle-card-active {
  grid-column: 2;
  max-width: 100%;
}

/* Cuando hay 2 rifas, mantener el espacio de 3 columnas */
.kerifa-raffles-grid-active.two-raffles {
  grid-template-columns: repeat(3, 1fr);
}

.kerifa-raffle-card-active {
  max-width: 100%;
  width: 100%;
  min-width: 0;
}

/* Responsive: en tablets mostrar 2 columnas */
@media (max-width: 1024px) {
  .kerifa-raffles-grid-active {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  
  .kerifa-raffles-grid-active.single-raffle {
    grid-template-columns: 1fr;
  }
  
  .kerifa-raffles-grid-active.single-raffle .kerifa-raffle-card-active {
    grid-column: 1;
  }
}

/* Responsive: en móvil mostrar 1 columna (vertical) */
@media (max-width: 768px) {
  .kerifa-raffles-grid-active {
    grid-template-columns: 1fr !important;
    gap: 20px;
    margin-top: 20px;
  }
  
  .kerifa-raffles-grid-active.single-raffle {
    grid-template-columns: 1fr !important;
  }
  
  .kerifa-raffles-grid-active.single-raffle .kerifa-raffle-card-active {
    grid-column: 1 !important;
  }
  
  .kerifa-raffles-grid-active.two-raffles {
    grid-template-columns: 1fr !important;
  }
}

.kerifa-raffle-card-active {
  background: #ffffff;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  max-width: 100%;
  width: 100%;
  min-width: 0; /* Permite que el contenido se ajuste */
}

.kerifa-raffle-card-placeholder {
  display: none !important;
}

.kerifa-raffle-card-active:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(99, 102, 241, 0.2);
  border-color: #6366f1;
}

.kerifa-raffle-image-active {
  position: relative;
  width: 100%;
  height: 240px;
  overflow: hidden;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
}

.kerifa-raffle-image-active img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.kerifa-raffle-card-active:hover .kerifa-raffle-image-active img {
  transform: scale(1.1);
}

.kerifa-raffle-image-active a {
  display: block;
  width: 100%;
  height: 100%;
}

.kerifa-raffle-placeholder-active {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
}

.kerifa-placeholder-icon-active {
  font-size: 5rem;
  opacity: 0.9;
}

.kerifa-raffle-badge-active {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #10b981;
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
  z-index: 2;
}

.kerifa-raffle-badge-waiting {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #f59e0b;
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
  z-index: 2;
}

.kerifa-raffle-badge-ended {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #ef4444;
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
  z-index: 2;
}

.kerifa-raffle-content-active {
  padding: 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.kerifa-raffle-title-active {
  margin: 0 0 20px;
  font-size: 1.5rem;
  font-weight: 800;
  line-height: 1.3;
  color: #111827;
}

.kerifa-raffle-title-active a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}

.kerifa-raffle-title-active a:hover {
  color: #6366f1;
}

/* Countdown */
.kerifa-countdown-wrapper {
  margin-bottom: 12px;
  padding: 10px 12px;
  background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
  border-radius: 10px;
  border: 2px solid #d1d5db;
}

.kerifa-countdown-label {
  font-size: 0.7rem;
  font-weight: 700;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
  text-align: center;
}

.kerifa-countdown {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.kerifa-countdown-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  min-width: 45px;
}

.kerifa-countdown-value {
  font-size: 1.5rem;
  font-weight: 800;
  color: #6366f1;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  background: #ffffff;
  padding: 6px 10px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  min-width: 45px;
  text-align: center;
}

.kerifa-countdown-label-small {
  font-size: 0.65rem;
  font-weight: 600;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kerifa-countdown-separator {
  font-size: 1.5rem;
  font-weight: 700;
  color: #6366f1;
  margin: 0 -4px;
  padding-top: 12px;
}

.kerifa-countdown-expired {
  text-align: center;
  font-size: 1rem;
  font-weight: 700;
  color: #ef4444;
  padding: 12px;
}

.kerifa-raffle-price-active {
  margin-bottom: 20px;
  padding-top: 20px;
  border-top: 1px solid #e5e7eb;
}

.kerifa-price-label-active {
  display: block;
  font-size: 0.75rem;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  margin-bottom: 8px;
}

.kerifa-price-amount-active {
  font-size: 2rem;
  font-weight: 800;
  color: #6366f1;
  line-height: 1;
}

.kerifa-raffle-date-active {
  margin-bottom: 20px;
  padding-top: 20px;
  border-top: 1px solid #e5e7eb;
  text-align: center;
}

.kerifa-date-label-active {
  display: block;
  font-size: 0.75rem;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  margin-bottom: 8px;
}

.kerifa-date-value-active {
  display: block;
  font-size: 1.125rem;
  font-weight: 700;
  color: #111827;
  line-height: 1.4;
}

.kerifa-raffle-footer-active {
  margin-top: auto;
  padding-top: 20px;
}

.kerifa-raffle-footer-active .kerifa-btn {
  width: 100%;
  justify-content: center;
  padding: 14px 24px;
  font-size: 1rem;
  font-weight: 700;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
  transition: all 0.3s ease;
}

.kerifa-raffle-footer-active .kerifa-btn:hover {
  color: #fff !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

/* Responsive - Móviles */
@media (max-width: 768px) {
  .kerifa-countdown-wrapper {
    padding: 12px;
    margin-bottom: 16px;
  }
  
  .kerifa-countdown-label {
    font-size: 0.7rem;
    margin-bottom: 10px;
  }
  
  .kerifa-countdown {
    gap: 4px;
    flex-wrap: wrap;
  }
  
  .kerifa-countdown-item {
    min-width: 40px;
    gap: 2px;
  }
  
  .kerifa-countdown-value {
    font-size: 1.25rem;
    padding: 6px 8px;
    min-width: 40px;
    font-weight: 700;
  }
  
  .kerifa-countdown-label-small {
    font-size: 0.55rem;
    letter-spacing: 0.3px;
  }
  
  .kerifa-countdown-separator {
    font-size: 1rem;
    margin: 0 -2px;
    padding-top: 8px;
  }
  
  .kerifa-countdown-expired {
    font-size: 0.875rem;
    padding: 10px;
  }
}

@media (max-width: 480px) {
  .kerifa-countdown-wrapper {
    padding: 10px;
    margin-bottom: 12px;
  }
  
  .kerifa-countdown-label {
    font-size: 0.65rem;
    margin-bottom: 8px;
  }
  
  .kerifa-countdown {
    gap: 3px;
  }
  
  .kerifa-countdown-item {
    min-width: 35px;
    gap: 2px;
  }
  
  .kerifa-countdown-value {
    font-size: 1rem;
    padding: 5px 6px;
    min-width: 35px;
    border-radius: 6px;
  }
  
  .kerifa-countdown-label-small {
    font-size: 0.5rem;
    letter-spacing: 0.2px;
  }
  
  .kerifa-countdown-separator {
    font-size: 0.875rem;
    margin: 0 -3px;
    padding-top: 6px;
  }
  
  .kerifa-countdown-expired {
    font-size: 0.8rem;
    padding: 8px;
  }
}

@media (max-width: 360px) {
  .kerifa-countdown-wrapper {
    padding: 8px;
  }
  
  .kerifa-countdown {
    gap: 2px;
  }
  
  .kerifa-countdown-item {
    min-width: 30px;
  }
  
  .kerifa-countdown-value {
    font-size: 0.875rem;
    padding: 4px 5px;
    min-width: 30px;
  }
  
  .kerifa-countdown-label-small {
    font-size: 0.45rem;
  }
  
  .kerifa-countdown-separator {
    font-size: 0.75rem;
    margin: 0 -4px;
    padding-top: 5px;
  }
}

/* Cards de balance */
.kerifa-balance-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.kerifa-balance-card {
  background: #fff;
  padding: 25px;
  border-radius: var(--kerifa-radius);
  box-shadow: var(--kerifa-shadow);
  border: 1px solid var(--kerifa-border);
  transition: var(--kerifa-transition);
  position: relative;
  overflow: hidden;
}

.kerifa-balance-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--kerifa-primary);
}

.kerifa-balance-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--kerifa-shadow-lg);
}

.kerifa-balance-label {
  font-size: 14px;
  color: #6b7280;
  font-weight: 500;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kerifa-balance-amount {
  font-size: 36px;
  font-weight: 700;
  color: var(--kerifa-dark);
  margin: 0;
  line-height: 1;
}

.kerifa-balance-currency {
  font-size: 18px;
  color: #9ca3af;
  font-weight: 500;
  margin-left: 8px;
}

/* Navegación con tabs */
.kerifa-nav-container {
  margin-bottom: 30px;
}

.kerifa-nav-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 25px;
  border-bottom: 2px solid var(--kerifa-border);
  flex-wrap: wrap;
  overflow-x: auto;
}

.kerifa-nav-tab {
  padding: 12px 24px;
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  color: #6b7280;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--kerifa-transition);
  position: relative;
  bottom: -2px;
  text-decoration: none;
  display: inline-block;
}

.kerifa-nav-tab:hover {
  color: var(--kerifa-primary);
}

.kerifa-nav-tab.active {
  color: var(--kerifa-primary);
  border-bottom-color: var(--kerifa-primary);
}

/* Contenedor de gráfico */
.kerifa-chart-container {
  background: #fff;
  padding: 30px;
  border-radius: var(--kerifa-radius);
  box-shadow: var(--kerifa-shadow);
  border: 1px solid var(--kerifa-border);
  margin-bottom: 30px;
}

.kerifa-chart-container h3 {
  margin: 0 0 20px;
  font-size: 20px;
  color: var(--kerifa-dark);
}

/* Cards de acción */
.kerifa-action-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 25px;
  margin-bottom: 30px;
}

.kerifa-action-card {
  background: #fff;
  padding: 30px;
  border-radius: var(--kerifa-radius);
  box-shadow: var(--kerifa-shadow);
  border: 1px solid var(--kerifa-border);
}

.kerifa-action-card h3 {
  margin: 0 0 10px;
  font-size: 20px;
  color: var(--kerifa-dark);
  display: flex;
  align-items: center;
  gap: 10px;
}

.kerifa-action-card h3::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 24px;
  background: var(--kerifa-primary);
  border-radius: 3px;
}

.kerifa-action-card p {
  color: #6b7280;
  margin-bottom: 20px;
  line-height: 1.6;
}

/* Formularios */
.kerifa-form-group {
  margin-bottom: 20px;
}

.kerifa-form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--kerifa-dark);
  margin-bottom: 8px;
}

.kerifa-form-group input[type="text"],
.kerifa-form-group input[type="number"],
.kerifa-form-group input[type="email"],
.kerifa-form-group select,
.kerifa-form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--kerifa-border);
  border-radius: 8px;
  font-size: 15px;
  transition: var(--kerifa-transition);
  background: #fff;
  box-sizing: border-box;
}

.kerifa-form-group input:focus,
.kerifa-form-group select:focus,
.kerifa-form-group textarea:focus {
  outline: 0;
  border-color: var(--kerifa-primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

/* Botones */
.kerifa-btn {
  padding: 12px 28px;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--kerifa-transition);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  line-height: 1.5;
}

.kerifa-btn-primary {
  background: var(--kerifa-primary);
  color: #fff;
}

.kerifa-btn-primary:hover {
  background: var(--kerifa-primary-dark);
  color: #fff !important;
  transform: translateY(-2px);
  box-shadow: var(--kerifa-shadow-lg);
}

.kerifa-btn-success {
  background: var(--kerifa-success);
  color: #fff;
}

.kerifa-btn-success:hover {
  background: #059669;
  color: #fff !important;
}

.kerifa-btn-secondary {
  background: #f3f4f6;
  color: var(--kerifa-dark);
}

.kerifa-btn-secondary:hover {
  background: #e5e7eb;
  color: var(--kerifa-dark) !important;
}

.kerifa-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Tabla de historial */
.kerifa-history-table {
  background: #fff;
  border-radius: var(--kerifa-radius);
  overflow: hidden;
  box-shadow: var(--kerifa-shadow);
  border: 1px solid var(--kerifa-border);
}

.kerifa-history-table table {
  width: 100%;
  border-collapse: collapse;
}

.kerifa-history-table thead {
  background: var(--kerifa-light);
}

.kerifa-history-table th {
  padding: 16px;
  text-align: left;
  font-size: 13px;
  font-weight: 700;
  color: var(--kerifa-dark);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 2px solid var(--kerifa-border);
}

.kerifa-history-table td {
  padding: 16px;
  border-bottom: 1px solid var(--kerifa-border);
  color: #374151;
}

.kerifa-history-table tbody tr:hover {
  background: var(--kerifa-light);
}

.kerifa-history-table tbody tr:last-child td {
  border-bottom: none;
}

/* Badges */
.kerifa-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kerifa-badge-credit {
  background: #d1fae5;
  color: #065f46;
}

.kerifa-badge-debit {
  background: #fee2e2;
  color: #991b1b;
}

.kerifa-badge-pending {
  background: #fef3c7;
  color: #92400e;
}

.kerifa-badge-paid {
  background: #d1fae5;
  color: #065f46;
}

/* Alertas */
.kerifa-alert {
  padding: 16px 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  border-left: 4px solid;
  display: flex;
  align-items: start;
  gap: 12px;
}

.kerifa-alert-info {
  background: #dbeafe;
  border-color: var(--kerifa-info);
  color: #1e40af;
}

.kerifa-alert-success {
  background: #d1fae5;
  border-color: var(--kerifa-success);
  color: #065f46;
}

.kerifa-alert-warning {
  background: #fef3c7;
  border-color: var(--kerifa-warning);
  color: #92400e;
}

/* Loading */
.kerifa-loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(99, 102, 241, 0.2);
  border-top-color: var(--kerifa-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Empty state */
.kerifa-empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #9ca3af;
}

.kerifa-empty-state svg {
  width: 80px;
  height: 80px;
  margin-bottom: 20px;
  opacity: 0.5;
}

/* Navegación principal con menús y submenús (en el header) */
.kerifa-dashboard-header .kerifa-main-nav {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.25);
  width: 100%;
  list-style: none;
  margin-left: 0;
  margin-right: 0;
  padding-left: 0;
  padding-right: 0;
  align-items: flex-start;
}

/* Ocultar tabs duplicados del monedero */
.kerifa-wallet-content .kerifa-nav-tabs,
.kerifa-wallet-content .kerifa-wallet-tabs {
  display: none !important;
}

.kerifa-main-nav-item {
  position: relative;
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
}

.kerifa-main-nav-item.has-submenu {
  display: inline-flex;
  align-items: center;
  gap: 0;
}

.kerifa-main-nav-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  color: #ffffff;
  text-decoration: none;
  border: none;
  background: rgba(255, 255, 255, 0.1);
  border-bottom: 2px solid transparent;
  transition: all 0.3s ease;
  font-weight: 500;
  font-size: 14px;
  white-space: nowrap;
  cursor: pointer;
  font-family: inherit;
  min-height: 42px;
  box-sizing: border-box;
  border-radius: 8px;
  width: 100%;
  text-align: left;
  justify-content: flex-start;
}

.kerifa-dashboard-header .kerifa-main-nav-link {
  color: #ffffff;
  font-weight: 500;
  background: rgba(255, 255, 255, 0.12);
}

.kerifa-dashboard-header .kerifa-main-nav-link:hover {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
  transform: translateY(-1px);
}

/* Botones activos en el header - fondo blanco para contraste */
.kerifa-dashboard-header .kerifa-main-nav-link.active,
.kerifa-dashboard-header .kerifa-main-nav-link:focus,
.kerifa-dashboard-header .kerifa-main-nav-item.active > .kerifa-main-nav-link,
.kerifa-dashboard-header .kerifa-main-nav-item.active > button.kerifa-main-nav-link,
.kerifa-dashboard-header .kerifa-main-nav-item.active button.kerifa-main-nav-link {
  background: #ffffff !important;
  color: #6366f1 !important;
  border-bottom-color: #ffffff !important;
  font-weight: 700 !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25) !important;
  border: 2px solid rgba(255, 255, 255, 0.3) !important;
}

.kerifa-main-nav-link-clickable {
  flex: 1;
}

.kerifa-submenu-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 10px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: #ffffff;
  cursor: pointer;
  transition: all 0.3s ease;
  border-radius: 0 8px 8px 0;
  min-height: 42px;
  font-size: 11px;
  margin-left: 2px;
}

.kerifa-submenu-toggle:hover {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

/* Estilos generales (solo para fuera del header del dashboard) */
.kerifa-main-nav-link.active:not(.kerifa-dashboard-header .kerifa-main-nav-link) {
  color: var(--kerifa-primary);
  border-bottom-color: var(--kerifa-primary);
  background: rgba(99, 102, 241, 0.05);
  border-radius: 8px 8px 0 0;
}

.kerifa-main-nav-link:hover:not(.kerifa-dashboard-header .kerifa-main-nav-link) {
  color: var(--kerifa-primary);
  background: rgba(99, 102, 241, 0.05);
  border-radius: 8px 8px 0 0;
}

.kerifa-main-nav-item.active > .kerifa-main-nav-link:not(.kerifa-dashboard-header .kerifa-main-nav-link) {
  color: var(--kerifa-primary);
  border-bottom-color: var(--kerifa-primary);
  background: rgba(99, 102, 241, 0.05);
  border-radius: 8px 8px 0 0;
}

.kerifa-nav-icon {
  font-size: 18px;
}

.kerifa-nav-label {
  font-size: 15px;
}

.kerifa-nav-arrow {
  font-size: 10px;
  margin-left: 4px;
  transition: transform 0.3s ease;
}

.kerifa-main-nav-item.active .kerifa-nav-arrow {
  transform: rotate(180deg);
}

/* Submenú */
.kerifa-submenu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  background: #ffffff !important;
  border: 1px solid #e5e7eb !important;
  border-radius: 10px;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
  min-width: 240px;
  max-height: 450px;
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 1000;
  display: none;
  padding: 6px 0;
  margin-top: 0;
}

.kerifa-submenu::-webkit-scrollbar {
  width: 6px;
}

.kerifa-submenu::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.kerifa-submenu::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 3px;
}

.kerifa-submenu::-webkit-scrollbar-thumb:hover {
  background: #555;
}

.kerifa-main-nav-item.active .kerifa-submenu {
  display: block;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.kerifa-submenu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  color: #374151 !important;
  text-decoration: none;
  transition: all 0.2s ease;
  font-size: 14px;
  font-weight: 400;
  background: #ffffff !important;
}

.kerifa-submenu-icon {
  font-size: 16px;
  flex-shrink: 0;
}

.kerifa-submenu-label {
  flex: 1;
}

.kerifa-submenu-item:hover {
  background: rgba(99, 102, 241, 0.08) !important;
  color: var(--kerifa-primary) !important;
  padding-left: 24px;
}

.kerifa-submenu-item.active {
  background: rgba(99, 102, 241, 0.12) !important;
  color: var(--kerifa-primary) !important;
  font-weight: 600;
  border-left: 4px solid var(--kerifa-primary);
  padding-left: 20px;
}

/* Dark mode para navegación */
body.dark-mode .kerifa-submenu {
  background: #1f2937 !important;
  border-color: #374151;
}

body.dark-mode .kerifa-main-nav-link:hover,
body.dark-mode .kerifa-main-nav-item.active > .kerifa-main-nav-link {
  background: rgba(255, 255, 255, 0.25);
}

body.dark-mode .kerifa-submenu-item {
  color: #f9fafb !important;
  background: #1f2937 !important;
}

body.dark-mode .kerifa-submenu-item:hover {
  background: rgba(99, 102, 241, 0.2) !important;
  color: #ffffff !important;
}

body.dark-mode .kerifa-submenu-item.active {
  background: rgba(99, 102, 241, 0.25) !important;
  color: #ffffff !important;
}

/* Responsive para navegación */
@media (max-width: 768px) {
  .kerifa-dashboard-header {
    padding: 20px 15px;
  }
  
  .kerifa-header-content {
    flex-direction: column;
    gap: 15px;
  }
  
  .kerifa-header-text {
    width: 100%;
  }
  
  .kerifa-dashboard-header h1 {
    font-size: 22px;
    margin-bottom: 6px;
    line-height: 1.3;
  }
  
  .kerifa-dashboard-header p {
    font-size: 13px;
    margin-bottom: 12px;
    line-height: 1.4;
  }
  
  .kerifa-dark-mode-toggle {
    align-self: flex-start;
    padding: 8px 14px;
    font-size: 12px;
    margin-top: 5px;
  }
  
  .kerifa-dashboard-header .kerifa-main-nav {
    flex-direction: column;
    gap: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.25);
    margin-top: 12px;
    padding-top: 12px;
    width: 100%;
    max-height: 60vh;
    overflow-y: auto;
    overflow-x: hidden;
  }
  
  .kerifa-dashboard-header .kerifa-main-nav::-webkit-scrollbar {
    width: 4px;
  }
  
  .kerifa-dashboard-header .kerifa-main-nav::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
  }
  
  .kerifa-main-nav-item {
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: stretch;
    flex-wrap: wrap;
  }
  
  .kerifa-main-nav-item:last-child {
    border-bottom: none;
  }
  
  .kerifa-main-nav-link {
    border-bottom: none;
    border-radius: 0;
    padding: 14px 16px;
    flex: 1;
    min-width: 0;
    justify-content: flex-start;
    color: #ffffff !important;
    font-size: 15px;
    min-height: 48px;
    font-weight: 500;
  }
  
  .kerifa-main-nav-item.active > .kerifa-main-nav-link {
    border-bottom: none;
    border-left: 4px solid #ffffff;
    background: rgba(255, 255, 255, 0.2);
    font-weight: 600;
  }
  
  .kerifa-submenu-toggle {
    border-radius: 0;
    padding: 14px 12px;
    min-height: 48px;
    border-left: 1px solid rgba(255, 255, 255, 0.15);
    flex-shrink: 0;
    width: 44px;
  }
  
  .kerifa-submenu {
    position: static;
    box-shadow: none;
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 0;
    margin-top: 0;
    padding: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.1);
    max-height: none;
    overflow: visible;
    order: 10;
  }
  
  .kerifa-submenu-item {
    padding: 12px 16px 12px 48px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #374151 !important;
    font-size: 14px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    font-weight: 400;
    transition: all 0.2s ease;
    background: #ffffff !important;
  }
  
  .kerifa-submenu-item:last-child {
    border-bottom: none;
  }
  
  .kerifa-submenu-item:hover {
    background: rgba(99, 102, 241, 0.08) !important;
    color: var(--kerifa-primary) !important;
    padding-left: 52px;
  }
  
  .kerifa-submenu-item.active {
    background: rgba(99, 102, 241, 0.12) !important;
    color: var(--kerifa-primary) !important;
    border-left: 4px solid var(--kerifa-primary);
    font-weight: 600;
    padding-left: 44px;
  }
}

/* Tabs content */
.kerifa-tab-contents {
  margin-top: 20px;
}

.kerifa-tab-content {
  display: none;
  animation: fadeIn 0.3s ease-in;
}

.kerifa-tab-content.active {
  display: block;
}

/* Tabs para direcciones */
.kerifa-address-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  border-bottom: 2px solid var(--kerifa-border);
}

.kerifa-tab-btn {
  padding: 12px 24px;
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  color: var(--kerifa-text);
  text-decoration: none;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.kerifa-tab-btn:hover {
  color: var(--kerifa-primary);
  background: rgba(99, 102, 241, 0.05);
}

.kerifa-tab-btn.active {
  color: var(--kerifa-primary);
  border-bottom-color: var(--kerifa-primary);
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Modal QR */
.kerifa-qr-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 9999;
  justify-content: center;
  align-items: center;
}

.kerifa-qr-modal.active {
  display: flex;
}

.kerifa-qr-content {
  background: #fff;
  padding: 40px;
  border-radius: var(--kerifa-radius);
  max-width: 400px;
  text-align: center;
}

.kerifa-qr-content h3 {
  margin: 0 0 20px;
}

#kerifa-qrcode {
  margin: 20px auto;
}

/* Modales profesionales */
.kerifa-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: kerifaModalFadeIn 0.2s ease-out;
}

@keyframes kerifaModalFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.kerifa-modal-content {
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  animation: kerifaModalSlideIn 0.3s ease-out;
  position: relative;
}

@keyframes kerifaModalSlideIn {
  from {
    transform: translateY(-20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.kerifa-modal-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 24px 30px 20px;
  border-bottom: 1px solid #e5e7eb;
}

.kerifa-modal-icon {
  font-size: 2rem;
  line-height: 1;
}

.kerifa-modal-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
  color: #111827;
  flex: 1;
}

.kerifa-modal-body {
  padding: 24px 30px;
  color: #374151;
  line-height: 1.6;
}

.kerifa-modal-body p {
  margin: 0;
}

.kerifa-modal-body strong {
  color: #111827;
  font-weight: 600;
}

.kerifa-modal-footer {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  padding: 20px 30px 24px;
  border-top: 1px solid #e5e7eb;
}

.kerifa-modal-btn {
  padding: 10px 24px;
  border: none;
  border-radius: 8px;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 100px;
}

.kerifa-modal-btn-cancel {
  background: #ffffff;
  color: #374151;
  border: 1px solid #d1d5db;
}

.kerifa-modal-btn-cancel:hover {
  background: #f9fafb;
  border-color: #9ca3af;
}

.kerifa-modal-btn-confirm {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #ffffff;
  box-shadow: 0 4px 6px -1px rgba(99, 102, 241, 0.3);
}

.kerifa-modal-btn-confirm:hover {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 12px -1px rgba(99, 102, 241, 0.4);
}

.kerifa-modal-btn-ok {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #ffffff;
  box-shadow: 0 4px 6px -1px rgba(99, 102, 241, 0.3);
}

.kerifa-modal-btn-ok:hover {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 12px -1px rgba(99, 102, 241, 0.4);
}

/* Responsive para modales */
@media (max-width: 640px) {
  .kerifa-modal-content {
    max-width: 100%;
    margin: 0;
    border-radius: 16px 16px 0 0;
    max-height: 80vh;
  }

  .kerifa-modal-header {
    padding: 20px 20px 16px;
  }

  .kerifa-modal-title {
    font-size: 1.25rem;
  }

  .kerifa-modal-body {
    padding: 20px;
  }

  .kerifa-modal-footer {
    padding: 16px 20px 20px;
    flex-direction: column-reverse;
  }

  .kerifa-modal-btn {
    width: 100%;
  }
}

/* Modal de pago rápido */
.kerifa-quick-checkout-content {
  max-width: 600px;
}

.kerifa-quick-checkout-numbers {
  margin: 20px 0;
}

.kerifa-quick-checkout-numbers-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.kerifa-quick-checkout-numbers-table thead {
  background: #f9fafb;
  border-bottom: 2px solid #e5e7eb;
}

.kerifa-quick-checkout-numbers-table th {
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
  font-size: 0.875rem;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kerifa-quick-checkout-numbers-table th.text-right {
  text-align: right;
}

.kerifa-quick-checkout-numbers-table tbody tr {
  border-bottom: 1px solid #e5e7eb;
  transition: background-color 0.2s;
}

.kerifa-quick-checkout-numbers-table tbody tr:last-child {
  border-bottom: none;
}

.kerifa-quick-checkout-numbers-table tbody tr:hover {
  background-color: #f9fafb;
}

.kerifa-quick-checkout-numbers-table td {
  padding: 14px 16px;
  font-size: 1rem;
  color: #111827;
}

.kerifa-quick-checkout-numbers-table td strong {
  font-size: 1.125rem;
  color: #6366f1;
  font-weight: 700;
}

.kerifa-quick-checkout-numbers-table td.text-right {
  text-align: right;
  font-weight: 600;
  color: #059669;
}

.kerifa-quick-checkout-numbers-table tfoot {
  border-top: 2px solid #e5e7eb;
  background: #f9fafb;
}

.kerifa-quick-checkout-total-row td {
  padding: 16px;
  font-size: 1.125rem;
}

.kerifa-quick-checkout-total-row td strong {
  color: #111827;
  font-size: 1.125rem;
}

.kerifa-payment-method-box {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 20px;
}

.kerifa-payment-method-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  margin-bottom: 12px;
  cursor: pointer;
}

.kerifa-payment-method-label input[type="radio"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

.kerifa-payment-balance {
  margin: 12px 0;
  padding: 10px;
  background: #fff;
  border-radius: 6px;
  font-size: 0.9375rem;
}

.kerifa-balance-sufficient {
  color: #059669;
  font-weight: 600;
  margin-left: 10px;
}

.kerifa-balance-insufficient {
  color: #dc2626;
  font-weight: 600;
  margin-left: 10px;
}

.kerifa-payment-description {
  margin: 0;
  font-size: 0.875rem;
  color: #6b7280;
}

.kerifa-checkout-spinner {
  text-align: center;
  padding: 40px 20px;
}

.kerifa-spinner {
  width: 50px;
  height: 50px;
  border: 4px solid #e5e7eb;
  border-top-color: #6366f1;
  border-radius: 50%;
  animation: kerifaSpin 1s linear infinite;
  margin: 0 auto 20px;
}

@keyframes kerifaSpin {
  to {
    transform: rotate(360deg);
  }
}

.kerifa-checkout-spinner p {
  margin: 0;
  color: #6b7280;
  font-weight: 600;
}

.kerifa-checkout-success {
  text-align: center;
  padding: 40px 20px;
}

.kerifa-success-icon {
  font-size: 4rem;
  display: block;
  margin-bottom: 15px;
}

.kerifa-checkout-success p {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
  color: #059669;
}

/* Modo oscuro para modales */
@media (prefers-color-scheme: dark) {
  .kerifa-modal-content {
    background: #1f2937;
    border-color: #374151;
  }

  .kerifa-modal-header {
    border-bottom-color: #374151;
  }

  .kerifa-modal-title {
    color: #f9fafb;
  }

  .kerifa-modal-body {
    color: #d1d5db;
  }

  .kerifa-modal-body strong {
    color: #f9fafb;
  }

  .kerifa-modal-footer {
    border-top-color: #374151;
  }

  .kerifa-modal-btn-cancel {
    background: #374151;
    color: #f9fafb;
    border-color: #4b5563;
  }

  .kerifa-modal-btn-cancel:hover {
    background: #4b5563;
  }
  
  .kerifa-quick-checkout-summary h4,
  .kerifa-quick-checkout-payment h4 {
    color: #f9fafb;
  }
  
  .kerifa-quick-checkout-table td {
    border-bottom-color: #374151;
    color: #d1d5db;
  }
  
  .kerifa-payment-method-box {
    background: #111827;
    border-color: #374151;
  }
  
  .kerifa-payment-balance {
    background: #1f2937;
    color: #d1d5db;
  }
  
  .kerifa-payment-description {
    color: #9ca3af;
  }
  
  .kerifa-spinner {
    border-color: #374151;
    border-top-color: #a78bfa;
  }
  
  .kerifa-checkout-spinner p {
    color: #9ca3af;
  }
}

/* Contenido del wallet */
.kerifa-wallet-content {
  margin-top: 20px;
}

.kerifa-wallet-tabs {
  margin-bottom: 30px;
}

/* Responsive */
@media (max-width: 768px) {
  .kerifa-dashboard-wrapper {
    padding: 15px;
  }

  .kerifa-dashboard-header {
    padding: 30px 20px;
  }

  .kerifa-dashboard-header h1 {
    font-size: 24px;
  }

  .kerifa-balance-cards {
    grid-template-columns: 1fr;
  }

  .kerifa-action-cards {
    grid-template-columns: 1fr;
  }

  .kerifa-nav-tabs {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .kerifa-nav-tab {
    white-space: nowrap;
  }

  .kerifa-history-table {
    overflow-x: auto;
  }

  .kerifa-history-table table {
    min-width: 600px;
  }
}

/* ============================================
   HOME PAGE - Diseño para rifas y sorteos
   ============================================ */

.kerifa-home {
  min-height: 100vh;
}

/* Hero Section */
.kerifa-hero {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #ec4899 100%);
  color: #fff;
  padding: 80px 20px;
  position: relative;
  overflow: hidden;
}

.kerifa-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="2" fill="rgba(255,255,255,0.1)"/></svg>');
  opacity: 0.3;
}

.kerifa-hero-content {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.kerifa-hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.1;
  margin: 0 0 20px;
}

.kerifa-hero-highlight {
  background: rgba(255, 255, 255, 0.2);
  padding: 4px 12px;
  border-radius: 8px;
  display: inline-block;
}

.kerifa-hero-subtitle {
  font-size: 1.25rem;
  opacity: 0.95;
  margin-bottom: 30px;
  line-height: 1.6;
}

.kerifa-hero-cta {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.kerifa-btn-hero {
  padding: 16px 32px;
  font-size: 1.1rem;
  background: #fff;
  color: #6366f1;
  font-weight: 700;
}

.kerifa-btn-hero:hover {
  background: #fff;
  color: #6366f1 !important;
  transform: translateY(-3px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.kerifa-btn-hero-outline {
  padding: 16px 32px;
  font-size: 1.1rem;
  background: transparent;
  color: #fff;
  border: 2px solid #fff;
  font-weight: 700;
}

.kerifa-btn-hero-outline:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff !important;
}

/* Lottery Wheel Visual */
.kerifa-hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.kerifa-lottery-wheel {
  width: 300px;
  height: 300px;
  position: relative;
  animation: rotate 20s linear infinite;
}

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.kerifa-wheel-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  background: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.kerifa-wheel-number {
  font-size: 24px;
  font-weight: 800;
  color: #6366f1;
}

.kerifa-wheel-numbers {
  position: absolute;
  width: 100%;
  height: 100%;
}

.kerifa-wheel-num {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%) rotate(var(--rotation)) translateY(-140px);
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.8);
}

/* Features Section */
.kerifa-features {
  padding: 80px 20px;
  background: #fff;
}

.kerifa-section-title {
  text-align: center;
  font-size: 2.5rem;
  font-weight: 700;
  margin: 0 0 50px;
  color: #111827;
}

.kerifa-features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.kerifa-feature-card {
  text-align: center;
  padding: 40px 30px;
  background: #f9fafb;
  border-radius: 16px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.kerifa-feature-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.kerifa-feature-icon {
  font-size: 3rem;
  margin-bottom: 20px;
}

.kerifa-feature-card h3 {
  font-size: 1.5rem;
  margin: 0 0 15px;
  color: #111827;
}

.kerifa-feature-card p {
  color: #6b7280;
  line-height: 1.6;
  margin: 0;
}

/* Raffles Section */
.kerifa-raffles {
  padding: 80px 20px;
  background: #f9fafb;
}

.kerifa-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 40px;
  flex-wrap: wrap;
  gap: 20px;
}

.kerifa-link-more {
  color: #6366f1;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s ease;
}

.kerifa-link-more:hover {
  color: #4f46e5;
}

.kerifa-raffles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 25px;
  max-width: 1200px;
  margin: 0 auto;
}

.kerifa-raffle-card {
  background: #fff;
  border-radius: 16px;
  padding: 25px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #e5e7eb;
}

.kerifa-raffle-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

.kerifa-raffle-header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  margin-bottom: 20px;
}

.kerifa-raffle-header h3 {
  margin: 0;
  font-size: 1.25rem;
  color: #111827;
  flex: 1;
}

.kerifa-raffle-badge {
  background: #10b981;
  color: #fff;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.kerifa-raffle-price {
  margin-bottom: 15px;
}

.kerifa-price-label {
  display: block;
  font-size: 0.875rem;
  color: #6b7280;
  margin-bottom: 5px;
}

.kerifa-price-amount {
  font-size: 1.75rem;
  font-weight: 700;
  color: #6366f1;
}

.kerifa-raffle-stock {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
  background: #f9fafb;
  border-radius: 8px;
  margin-bottom: 20px;
}

.kerifa-stock-label {
  font-size: 0.875rem;
  color: #6b7280;
}

.kerifa-stock-value {
  font-size: 1.1rem;
  font-weight: 700;
  color: #111827;
}

.kerifa-raffle-footer {
  margin-top: 20px;
}

.kerifa-raffle-footer .kerifa-btn {
  width: 100%;
  justify-content: center;
}

/* Winners Section */
.kerifa-winners {
  padding: 80px 20px;
  background: #fff;
}

.kerifa-winners-list {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.kerifa-winner-item {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  background: #f9fafb;
  border-radius: 12px;
  border-left: 4px solid #10b981;
}

.kerifa-winner-number {
  font-size: 2.5rem;
  line-height: 1;
}

.kerifa-winner-info h4 {
  margin: 0 0 5px;
  font-size: 1.1rem;
  color: #111827;
}

.kerifa-winner-info p {
  margin: 0 0 5px;
  color: #6b7280;
  font-size: 0.95rem;
}

.kerifa-winner-date {
  font-size: 0.85rem;
  color: #9ca3af;
}

/* CTA Section */
.kerifa-cta {
  padding: 100px 20px;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #fff;
  text-align: center;
}

.kerifa-cta-content h2 {
  font-size: 3rem;
  margin: 0 0 20px;
  font-weight: 800;
}

.kerifa-cta-content p {
  font-size: 1.25rem;
  margin: 0 0 40px;
  opacity: 0.95;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ============================================
   FORMULARIOS MODERNIZADOS
   ============================================ */

/* Login/Registro */
.kerifa-auth-wrapper {
  min-height: calc(100vh - 200px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  background: #f9fafb;
}

.kerifa-auth-container {
  max-width: 500px;
  width: 100%;
  background: #fff;
  border-radius: 16px;
  padding: 40px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.kerifa-auth-header {
  text-align: center;
  margin-bottom: 30px;
}

.kerifa-auth-header h1 {
  font-size: 2rem;
  margin: 0 0 10px;
  color: #111827;
}

.kerifa-auth-header p {
  color: #6b7280;
  margin: 0;
}

.kerifa-auth-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 30px;
  border-bottom: 2px solid #e5e7eb;
}

.kerifa-auth-tab {
  flex: 1;
  padding: 12px;
  text-align: center;
  text-decoration: none;
  color: #6b7280;
  font-weight: 600;
  border-bottom: 3px solid transparent;
  transition: all 0.3s ease;
  position: relative;
  bottom: -2px;
}

.kerifa-auth-tab.active {
  color: #6366f1;
  border-bottom-color: #6366f1;
}

.kerifa-auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.kerifa-password-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.2rem;
  padding: 5px;
}

.kerifa-form-group {
  position: relative;
}

.kerifa-form-checkbox {
  display: flex;
  align-items: center;
}

.kerifa-form-checkbox input[type="checkbox"] {
  width: auto;
  margin-right: 8px;
}

/* Checkout */
.kerifa-checkout-wrapper {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 40px;
  max-width: 1400px;
  margin: 0 auto;
  padding: 40px 20px;
}

.kerifa-checkout-section {
  background: #fff;
  border-radius: 16px;
  padding: 30px;
  margin-bottom: 30px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  border: 1px solid #e5e7eb;
}

.kerifa-checkout-section-title {
  font-size: 1.5rem;
  margin: 0 0 25px;
  color: #111827;
  padding-bottom: 15px;
  border-bottom: 2px solid #e5e7eb;
}

.kerifa-order-summary {
  background: #fff;
  border-radius: 16px;
  padding: 30px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  border: 1px solid #e5e7eb;
  position: sticky;
  top: 100px;
}

.kerifa-order-summary-title {
  font-size: 1.5rem;
  margin: 0 0 25px;
  color: #111827;
  padding-bottom: 15px;
  border-bottom: 2px solid #e5e7eb;
}

.kerifa-order-items {
  margin-bottom: 25px;
}

.kerifa-order-item {
  display: flex;
  justify-content: space-between;
  padding: 15px 0;
  border-bottom: 1px solid #e5e7eb;
}

.kerifa-order-item:last-child {
  border-bottom: none;
}

.kerifa-order-item-info h4 {
  margin: 0 0 5px;
  font-size: 1rem;
  color: #111827;
}

.kerifa-order-item-qty {
  font-size: 0.875rem;
  color: #6b7280;
}

.kerifa-order-item-price {
  font-weight: 700;
  color: #111827;
}

.kerifa-order-totals {
  padding-top: 20px;
  border-top: 2px solid #e5e7eb;
}

.kerifa-order-total-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  color: #6b7280;
}

.kerifa-order-total-final {
  font-size: 1.25rem;
  font-weight: 700;
  color: #111827;
  padding-top: 15px;
  border-top: 2px solid #e5e7eb;
  margin-top: 10px;
}

/* Checkout - Login para usuarios no logueados */
.kerifa-checkout-login-wrapper {
  max-width: 600px;
  margin: 60px auto;
  padding: 0 20px;
}

.kerifa-checkout-login-card {
  background: #ffffff;
  border-radius: 24px;
  padding: 48px 40px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.kerifa-checkout-login-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #6366f1 0%, #8b5cf6 50%, #ec4899 100%);
}

.kerifa-checkout-login-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.1) 100%);
  border-radius: 50%;
  color: #6366f1;
}

.kerifa-checkout-login-icon svg {
  width: 48px;
  height: 48px;
}

.kerifa-checkout-login-title {
  font-size: 1.875rem;
  font-weight: 700;
  color: #111827;
  margin: 0 0 12px;
  line-height: 1.3;
}

.kerifa-checkout-login-description {
  font-size: 1rem;
  color: #6b7280;
  line-height: 1.6;
  margin: 0 0 32px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.kerifa-checkout-login-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.kerifa-checkout-login-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 12px;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  min-width: 180px;
  justify-content: center;
}

.kerifa-checkout-login-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.kerifa-checkout-login-btn-primary {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #ffffff;
  box-shadow: 0 4px 6px -1px rgba(99, 102, 241, 0.3), 0 2px 4px -1px rgba(99, 102, 241, 0.2);
}

.kerifa-checkout-login-btn-primary:hover {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.4), 0 4px 6px -2px rgba(99, 102, 241, 0.3);
  color: #ffffff;
}

.kerifa-checkout-login-btn-secondary {
  background: #ffffff;
  color: #6366f1;
  border-color: #6366f1;
}

.kerifa-checkout-login-btn-secondary:hover {
  background: #f3f4f6;
  border-color: #4f46e5;
  color: #4f46e5;
  transform: translateY(-2px);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.kerifa-checkout-login-footer {
  padding-top: 24px;
  border-top: 1px solid #e5e7eb;
  margin-top: 24px;
}

.kerifa-checkout-login-footer p {
  font-size: 0.875rem;
  color: #9ca3af;
  margin: 0;
  line-height: 1.5;
}

/* Responsive para login checkout */
@media (max-width: 640px) {
  .kerifa-checkout-login-wrapper {
    margin: 40px auto;
    padding: 0 16px;
  }

  .kerifa-checkout-login-card {
    padding: 32px 24px;
    border-radius: 20px;
  }

  .kerifa-checkout-login-icon {
    width: 64px;
    height: 64px;
    margin-bottom: 20px;
  }

  .kerifa-checkout-login-icon svg {
    width: 40px;
    height: 40px;
  }

  .kerifa-checkout-login-title {
    font-size: 1.5rem;
  }

  .kerifa-checkout-login-description {
    font-size: 0.9375rem;
    margin-bottom: 24px;
  }

  .kerifa-checkout-login-actions {
    flex-direction: column;
    gap: 12px;
  }

  .kerifa-checkout-login-btn {
    width: 100%;
    min-width: auto;
  }

  .kerifa-checkout-login-card .kerifa-auth-tabs {
    margin: 24px 0 20px;
  }

  .kerifa-checkout-login-card .kerifa-auth-tab {
    padding: 10px 16px;
    font-size: 0.875rem;
    max-width: none;
  }

  .kerifa-checkout-login-card .kerifa-auth-form {
    gap: 16px;
  }

  .kerifa-checkout-login-card .kerifa-form-group input[type="text"],
  .kerifa-checkout-login-card .kerifa-form-group input[type="email"],
  .kerifa-checkout-login-card .kerifa-form-group input[type="password"] {
    padding: 10px 14px;
    font-size: 0.875rem;
  }
}

/* Tabs y formularios dentro del card de login */
.kerifa-checkout-login-card .kerifa-auth-tabs {
  display: flex;
  gap: 0;
  margin: 32px 0 24px;
  border-bottom: 2px solid #e5e7eb;
  justify-content: center;
}

.kerifa-checkout-login-card .kerifa-auth-tab {
  flex: 1;
  max-width: 200px;
  padding: 12px 20px;
  text-align: center;
  text-decoration: none;
  color: #6b7280;
  font-weight: 600;
  font-size: 0.9375rem;
  border-bottom: 3px solid transparent;
  transition: all 0.3s ease;
  position: relative;
  bottom: -2px;
}

.kerifa-checkout-login-card .kerifa-auth-tab:hover {
  color: #6366f1;
}

.kerifa-checkout-login-card .kerifa-auth-tab.active {
  color: #6366f1;
  border-bottom-color: #6366f1;
}

.kerifa-checkout-login-card .kerifa-auth-forms {
  margin-top: 0;
}

.kerifa-checkout-login-card .kerifa-auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.kerifa-checkout-login-card .kerifa-form-group {
  margin-bottom: 0;
}

.kerifa-checkout-login-card .kerifa-form-group label {
  display: block;
  font-size: 0.9375rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 8px;
}

.kerifa-checkout-login-card .kerifa-form-group input[type="text"],
.kerifa-checkout-login-card .kerifa-form-group input[type="email"],
.kerifa-checkout-login-card .kerifa-form-group input[type="password"] {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 10px;
  font-size: 0.9375rem;
  transition: all 0.3s ease;
  background: #ffffff;
  box-sizing: border-box;
}

.kerifa-checkout-login-card .kerifa-form-group input:focus {
  outline: 0;
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.kerifa-password-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.kerifa-password-wrapper input {
  padding-right: 45px !important;
}

.kerifa-password-toggle {
  position: absolute;
  right: 12px;
  cursor: pointer;
  font-size: 1.125rem;
  user-select: none;
  z-index: 10;
  transition: transform 0.2s ease;
}

.kerifa-password-toggle:hover {
  transform: scale(1.1);
}

.kerifa-checkout-login-card .kerifa-form-checkbox {
  display: flex;
  align-items: center;
  margin: 0;
}

.kerifa-checkout-login-card .kerifa-form-checkbox input[type="checkbox"] {
  width: auto;
  margin-right: 8px;
  cursor: pointer;
}

.kerifa-checkout-login-card .kerifa-form-checkbox label {
  display: flex;
  align-items: center;
  cursor: pointer;
  margin: 0;
  font-weight: 500;
  color: #6b7280;
}

.kerifa-checkout-login-card .form-row {
  margin: 0;
}

.kerifa-checkout-login-card .woocommerce-LostPassword {
  text-align: center;
  margin-top: 16px;
}

.kerifa-checkout-login-card .woocommerce-LostPassword a {
  color: #6366f1;
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.kerifa-checkout-login-card .woocommerce-LostPassword a:hover {
  color: #4f46e5;
  text-decoration: underline;
}

.kerifa-checkout-login-card .required {
  color: #ef4444;
}

/* Modo oscuro para login checkout */
@media (prefers-color-scheme: dark) {
  .kerifa-checkout-login-card {
    background: #1f2937;
    border-color: #374151;
  }

  .kerifa-checkout-login-title {
    color: #f9fafb;
  }

  .kerifa-checkout-login-description {
    color: #d1d5db;
  }

  .kerifa-checkout-login-btn-secondary {
    background: #374151;
    color: #a78bfa;
    border-color: #6366f1;
  }

  .kerifa-checkout-login-btn-secondary:hover {
    background: #4b5563;
    color: #8b5cf6;
  }

  .kerifa-checkout-login-footer {
    border-color: #374151;
  }

  .kerifa-checkout-login-footer p {
    color: #9ca3af;
  }

  .kerifa-checkout-login-card .kerifa-auth-tabs {
    border-bottom-color: #374151;
  }

  .kerifa-checkout-login-card .kerifa-auth-tab {
    color: #9ca3af;
  }

  .kerifa-checkout-login-card .kerifa-auth-tab:hover,
  .kerifa-checkout-login-card .kerifa-auth-tab.active {
    color: #a78bfa;
    border-bottom-color: #a78bfa;
  }

  .kerifa-checkout-login-card .kerifa-form-group label {
    color: #d1d5db;
  }

  .kerifa-checkout-login-card .kerifa-form-group input[type="text"],
  .kerifa-checkout-login-card .kerifa-form-group input[type="email"],
  .kerifa-checkout-login-card .kerifa-form-group input[type="password"] {
    background: #111827;
    color: #f9fafb;
    border-color: #374151;
  }

  .kerifa-checkout-login-card .kerifa-form-group input:focus {
    border-color: #6366f1;
  }

  .kerifa-checkout-login-card .kerifa-form-checkbox label {
    color: #d1d5db;
  }

  .kerifa-checkout-login-card .woocommerce-LostPassword a {
    color: #a78bfa;
  }

  .kerifa-checkout-login-card .woocommerce-LostPassword a:hover {
    color: #8b5cf6;
  }
}

/* ============================================
   MENÚ MÓVIL RESPONSIVE
   ============================================ */

.k-nav-list {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 1.5rem;
  align-items: center;
  position: relative;
}

.k-nav-list li {
  margin: 0;
  position: relative;
}

.k-nav-list > li {
  position: relative;
}

.k-nav-list a {
  color: #4b5563;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.k-nav-list a:hover {
  color: #111827;
}

/* Submenú */
.k-submenu {
  position: absolute;
  top: 100%;
  left: 0;
  background: #ffffff;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  border-radius: 0.5rem;
  padding: 0.5rem 0;
  margin-top: 0.5rem;
  min-width: 200px;
  list-style: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
  z-index: 1000;
}

.k-menu-item-has-children:hover > .k-submenu,
.k-menu-item-has-children.k-submenu-open > .k-submenu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.k-submenu li {
  margin: 0;
}

.k-submenu a {
  display: block;
  padding: 0.5rem 1rem;
  color: #4b5563;
  font-weight: 400;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.k-submenu a:hover {
  background-color: #f3f4f6;
  color: #111827;
}

.k-submenu-arrow {
  font-size: 0.75rem;
  margin-left: 0.25rem;
  transition: transform 0.2s ease;
}

.k-menu-item-has-children:hover > a .k-submenu-arrow {
  transform: rotate(180deg);
}

/* Menú móvil lateral desde la izquierda */
/* CRÍTICO: El menú debe estar fuera del contexto de apilamiento del header */
.k-mobile-menu {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  z-index: 999999 !important; /* Z-index extremadamente alto para estar por encima de TODO */
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  pointer-events: none; /* Deshabilitar interacción cuando está oculto */
  /* Asegurar que esté en el contexto de apilamiento más alto */
  isolation: isolate;
}

.k-mobile-menu.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto; /* Habilitar interacción cuando está activo */
}

.k-mobile-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(2px);
  z-index: 1; /* Por encima del fondo pero debajo del nav */
  z-index: 1 !important;
}

.k-mobile-nav {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 85%;
  max-width: 320px;
  height: 100%;
  background: linear-gradient(180deg, #ffffff 0%, #f9fafb 100%);
  box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
  padding: 0;
  overflow-y: auto;
  overflow-x: hidden;
  transform: translateX(-100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  z-index: 2 !important; /* Por encima del overlay */
  /* Asegurar que esté en el contexto de apilamiento correcto */
  isolation: isolate;
}

.k-mobile-menu.active .k-mobile-nav {
  transform: translateX(0);
}

.k-mobile-nav-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.75rem 1.5rem; /* Aumentado padding */
  border-bottom: 1px solid #e5e7eb;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #ffffff;
  /* Animación de entrada más visible */
  opacity: 0;
  transform: translateY(-30px);
  transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1), 
              transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.k-mobile-menu.active .k-mobile-nav-header {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.05s;
}

.k-mobile-nav-title {
  margin: 0;
  font-size: 1.35rem; /* Aumentado tamaño */
  font-weight: 700;
  color: #ffffff;
}

.k-mobile-nav-user-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.k-mobile-nav-balance {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
  opacity: 0.9;
}

.k-mobile-close {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  border-radius: 8px;
  width: 40px; /* Aumentado */
  height: 40px; /* Aumentado */
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #ffffff;
  transition: background 0.2s ease;
  flex-shrink: 0;
  padding: 0.5rem; /* Padding interno para el icono */
}

.k-mobile-close svg {
  width: 20px; /* Aumentado */
  height: 20px; /* Aumentado */
}

.k-mobile-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

.k-mobile-nav-list {
  list-style: none;
  margin: 0;
  padding: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.k-mobile-nav-list > li {
  margin: 0;
  position: relative;
  display: block;
}

.k-mobile-nav-item {
  display: flex;
  align-items: center;
  gap: 1.25rem; /* Aumentado gap */
  padding: 1.25rem 1.5rem; /* Aumentado padding */
  color: #111827;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem; /* Aumentado tamaño de texto */
  transition: all 0.2s ease;
  position: relative;
  overflow: visible;
  width: 100%;
  box-sizing: border-box;
  /* Animación de entrada: caída + fade + slide desde izquierda */
  opacity: 0;
  transform: translateX(-40px) translateY(-20px);
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), 
              transform 0.6s cubic-bezier(0.4, 0, 0.2, 1), 
              all 0.2s ease;
}

/* Animación escalonada para cada item del menú - efecto cascada visible */
/* Aplicar a enlaces normales Y botones toggle */
.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(1) .k-mobile-nav-item,
.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(1) .k-mobile-nav-toggle {
  opacity: 1;
  transform: translateX(0) translateY(0);
  transition-delay: 0.1s;
}

.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(2) .k-mobile-nav-item,
.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(2) .k-mobile-nav-toggle {
  opacity: 1;
  transform: translateX(0) translateY(0);
  transition-delay: 0.2s;
}

.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(3) .k-mobile-nav-item,
.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(3) .k-mobile-nav-toggle {
  opacity: 1;
  transform: translateX(0) translateY(0);
  transition-delay: 0.3s;
}

.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(4) .k-mobile-nav-item,
.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(4) .k-mobile-nav-toggle {
  opacity: 1;
  transform: translateX(0) translateY(0);
  transition-delay: 0.4s;
}

.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(5) .k-mobile-nav-item,
.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(5) .k-mobile-nav-toggle {
  opacity: 1;
  transform: translateX(0) translateY(0);
  transition-delay: 0.5s;
}

.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(6) .k-mobile-nav-item,
.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(6) .k-mobile-nav-toggle {
  opacity: 1;
  transform: translateX(0) translateY(0);
  transition-delay: 0.6s;
}

.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(n+7) .k-mobile-nav-item,
.k-mobile-menu.active .k-mobile-nav-list > li:nth-child(n+7) .k-mobile-nav-toggle {
  opacity: 1;
  transform: translateX(0) translateY(0);
  transition-delay: 0.7s;
}

.k-mobile-nav-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  transform: scaleY(0);
  transition: transform 0.2s ease;
}

.k-mobile-nav-item:hover {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.1) 0%, transparent 100%);
  padding-left: 1.5rem;
}

.k-mobile-nav-item:hover::before {
  transform: scaleY(1);
}

.k-mobile-nav-icon {
  flex-shrink: 0;
  width: 28px; /* Aumentado de 24px */
  height: 28px; /* Aumentado de 24px */
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6366f1;
  transition: transform 0.2s ease;
}

.k-mobile-nav-icon svg {
  width: 100%;
  height: 100%;
}

.k-mobile-nav-item:hover .k-mobile-nav-icon {
  transform: scale(1.1);
}

.k-mobile-nav-text {
  flex: 1;
}

/* Submenús móviles */
.k-mobile-submenu {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  background-color: #f9fafb;
  position: relative;
  z-index: 1;
  width: 100%;
  box-sizing: border-box;
}

.k-mobile-menu-item-has-children.active > .k-mobile-submenu {
  max-height: 1000px;
  padding: 0.5rem 0;
}

.k-mobile-submenu li {
  margin: 0;
  position: relative;
  display: block;
  width: 100%;
}

.k-mobile-submenu .k-mobile-nav-item {
  padding-left: 3.5rem;
  font-size: 0.9rem;
  color: #6b7280;
}

.k-mobile-submenu .k-mobile-nav-item:hover {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.08) 0%, transparent 100%);
  color: #111827;
}

.k-mobile-submenu .k-mobile-nav-icon {
  width: 20px;
  height: 20px;
}

.k-mobile-submenu-arrow {
  margin-left: auto;
  font-size: 0.75rem;
  transition: transform 0.3s ease;
}

.k-mobile-menu-item-has-children.active > button .k-mobile-submenu-arrow {
  transform: rotate(180deg);
}

.k-mobile-nav-toggle {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  padding: 1.25rem 1.5rem;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  color: #111827;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  transition: all 0.2s ease;
  position: relative;
  overflow: visible;
  box-sizing: border-box;
  font-family: inherit;
  /* Mismas animaciones que los enlaces normales */
  opacity: 0;
  transform: translateX(-40px) translateY(-20px);
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), 
              transform 0.6s cubic-bezier(0.4, 0, 0.2, 1), 
              all 0.2s ease;
}

.k-mobile-nav-toggle:hover {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.1) 0%, transparent 100%);
  padding-left: 1.5rem;
}

.k-mobile-nav-toggle::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  transform: scaleY(0);
  transition: transform 0.2s ease;
}

.k-mobile-nav-toggle:hover::before {
  transform: scaleY(1);
}

.k-mobile-nav-toggle:hover .k-mobile-nav-icon {
  transform: scale(1.1);
}

/* Asegurar que los elementos con submenús no se solapen */
.k-mobile-nav-list > li.k-mobile-menu-item-has-children {
  margin-bottom: 0;
  display: block;
  width: 100%;
  position: relative;
  z-index: auto;
}

.k-mobile-nav-list > li.k-mobile-menu-item-has-children + li {
  margin-top: 0;
  position: relative;
  z-index: auto;
}

/* Asegurar que el submenú no interfiera con elementos siguientes */
.k-mobile-submenu {
  position: relative;
  z-index: 1;
  margin-top: 0;
  margin-bottom: 0;
}

.k-mobile-cta {
  margin-top: auto;
  padding: 1.5rem; /* Aumentado padding */
  border-top: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  background: #ffffff;
  /* Animación de entrada más visible */
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), 
              transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.k-mobile-menu.active .k-mobile-cta {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.75s;
}

.k-mobile-btn {
  width: 100%;
  justify-content: center;
}

.k-btn-desktop {
  display: inline-flex;
}

/* ============================================
   RESPONSIVE - Optimización móvil
   ============================================ */

@media (max-width: 900px) {
  .kerifa-hero-content {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 40px;
  }

  .kerifa-hero-title {
    font-size: 2.5rem;
  }

  .kerifa-hero-visual {
    order: -1;
  }

  .kerifa-lottery-wheel {
    width: 250px;
    height: 250px;
  }

  .kerifa-checkout-wrapper {
    grid-template-columns: 1fr;
  }

  .kerifa-order-summary {
    position: static;
  }

  .k-main-nav {
    display: none;
  }

  .k-mobile-toggle {
    display: inline-flex;
  }

  .k-btn-desktop {
    display: none;
  }
  
  .k-logo-text {
    display: none;
  }
  
  .k-logo {
    justify-content: center;
  }
}

@media (max-width: 640px) {
  .kerifa-hero {
    padding: 60px 20px;
  }

  .kerifa-hero-title {
    font-size: 2rem;
  }

  .kerifa-hero-subtitle {
    font-size: 1rem;
  }

  .kerifa-hero-cta {
    flex-direction: column;
  }

  .kerifa-btn-hero,
  .kerifa-btn-hero-outline {
    width: 100%;
    justify-content: center;
  }

  .kerifa-section-title {
    font-size: 2rem;
  }

  .kerifa-features-grid {
    grid-template-columns: 1fr;
  }

  .kerifa-raffles-grid {
    grid-template-columns: 1fr;
  }

  .kerifa-cta-content h2 {
    font-size: 2rem;
  }

  .kerifa-cta-content p {
    font-size: 1rem;
  }

  .kerifa-auth-container {
    padding: 30px 20px;
  }

  .kerifa-checkout-section {
    padding: 20px;
  }

  .kerifa-order-summary {
    padding: 20px;
  }
}

/* ============================================
   PÁGINA DE RIFAS (SHOP) - Diseño Moderno Tipo Polymarket
   ============================================ */

.kerifa-raffles-page {
  padding: 30px 20px;
  background: #f9fafb;
  min-height: calc(100vh - 200px);
}

.kerifa-raffles-header {
  margin-bottom: 30px;
}

.kerifa-raffles-header-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 20px;
}

.kerifa-raffles-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 0 8px;
  color: #111827;
  line-height: 1.2;
}

.kerifa-raffles-subtitle {
  font-size: 1.1rem;
  color: #6b7280;
  margin: 0;
}

.kerifa-raffles-stats {
  display: flex;
  align-items: center;
  gap: 15px;
}

.kerifa-results-count {
  font-size: 0.95rem;
  color: #6b7280;
}

/* Layout principal con sidebar */
.kerifa-raffles-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 30px;
  align-items: start;
}

/* Botón toggle para filtros en móvil */
.kerifa-filters-toggle-mobile {
  display: none;
  width: 100%;
  padding: 14px 20px;
  background: #6366f1;
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  margin-bottom: 16px;
  justify-content: space-between;
  align-items: center;
  transition: all 0.2s;
}

.kerifa-filters-toggle-mobile:hover {
  background: #4f46e5;
}

.kerifa-filters-toggle-icon {
  font-size: 0.875rem;
  transition: transform 0.3s;
}

/* Sidebar de Filtros */
.kerifa-raffles-sidebar {
  position: sticky;
  top: 20px;
}

.kerifa-filters-panel {
  background: #ffffff;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
}

.kerifa-filters-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 2px solid #f3f4f6;
}

.kerifa-filters-header h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
  color: #111827;
}

.kerifa-filters-clear {
  background: none;
  border: none;
  color: #6366f1;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.2s;
}

.kerifa-filters-clear:hover {
  background: #f3f4f6;
}

.kerifa-filter-group {
  margin-bottom: 24px;
}

.kerifa-filter-group:last-child {
  margin-bottom: 0;
}

.kerifa-filter-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 10px;
}

.kerifa-filter-input,
.kerifa-filter-select {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 0.95rem;
  background: #ffffff;
  color: #111827;
  transition: all 0.2s;
}

.kerifa-filter-input:focus,
.kerifa-filter-select:focus {
  outline: none;
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.kerifa-filter-checkboxes {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.kerifa-checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.95rem;
  color: #374151;
  padding: 8px;
  border-radius: 6px;
  transition: background 0.2s;
}

.kerifa-checkbox-label:hover {
  background: #f9fafb;
}

.kerifa-filter-checkbox {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: #6366f1;
}

/* Contenido Principal */
.kerifa-raffles-main {
  min-width: 0;
}

.kerifa-raffles-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding: 16px 20px;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
}

.kerifa-toolbar-left {
  display: flex;
  gap: 8px;
}

.kerifa-view-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid #d1d5db;
  background: #ffffff;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  color: #6b7280;
}

.kerifa-view-toggle:hover {
  border-color: #6366f1;
  color: #6366f1;
  background: #f3f4f6;
}

.kerifa-view-toggle.active {
  border-color: #6366f1;
  background: #6366f1;
  color: #ffffff;
}

.kerifa-toolbar-right {
  display: flex;
  align-items: center;
}

.kerifa-toolbar-right .kerifa-filter-select {
  min-width: 200px;
  padding: 8px 12px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 0.9rem;
  background: #ffffff;
  color: #111827;
  cursor: pointer;
  transition: all 0.2s;
}

.kerifa-toolbar-right .kerifa-filter-select:focus {
  outline: none;
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

/* Grid de Rifas - Cards Modernas */
.woocommerce ul.products,
.products {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)) !important;
  gap: 24px !important;
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
  width: 100% !important;
  clear: both !important;
}

.woocommerce ul.products::before,
.woocommerce ul.products::after,
.products::before,
.products::after {
  display: none !important;
}

.products.view-list,
.woocommerce ul.products.view-list {
  display: flex !important;
  flex-direction: column !important;
  gap: 20px !important;
  grid-template-columns: none !important;
}

.products.view-list .kerifa-raffle-card,
.products.view-list li.kerifa-raffle-card,
.woocommerce ul.products.view-list li.kerifa-raffle-card,
.woocommerce ul.products.view-list li.product {
  display: flex !important;
  flex-direction: row !important;
  width: 100% !important;
  max-width: 100% !important;
  flex: 0 0 100% !important;
  margin: 0 !important;
}

.products.view-list .kerifa-raffle-card-inner {
  display: flex !important;
  flex-direction: row;
  width: 100%;
  min-height: 250px;
}

.products.view-list .kerifa-raffle-image {
  width: 300px;
  min-width: 300px;
  flex-shrink: 0;
  height: 250px;
  min-height: 250px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.products.view-list .kerifa-raffle-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}

.products.view-list .kerifa-raffle-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.products.view-list .kerifa-countdown-wrapper {
  margin-bottom: 16px;
}

.products.view-list .kerifa-raffle-actions {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.kerifa-raffle-card,
li.kerifa-raffle-card,
.woocommerce ul.products li.kerifa-raffle-card,
.woocommerce ul.products li.product {
  background: #ffffff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  display: block !important;
  float: none !important;
  position: relative !important;
  clear: none !important;
  box-sizing: border-box !important;
}

.kerifa-raffle-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
  border-color: #6366f1;
}

.kerifa-raffle-card-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
  max-width: 100%;
}

.kerifa-raffle-image {
  position: relative;
  width: 100%;
  max-width: 100%;
  height: 200px;
  min-height: 200px;
  overflow: hidden;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0;
  flex-shrink: 0;
  box-sizing: border-box;
}

.kerifa-raffle-image a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0;
  padding: 0;
  z-index: 1;
  text-decoration: none;
}

.kerifa-raffle-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
}

.kerifa-raffle-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
}

.kerifa-placeholder-icon {
  font-size: 4rem;
  opacity: 0.8;
}

.kerifa-raffle-link {
  display: block;
  width: 100%;
  height: 100%;
  flex: 1;
  min-height: 0;
}

.kerifa-raffle-badges {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 2;
}

.kerifa-badge {
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.kerifa-badge-active {
  background: #10b981;
  color: #ffffff;
}

.kerifa-badge-ended {
  background: #ef4444;
  color: #ffffff;
}

.kerifa-badge-waiting {
  background: #f59e0b;
  color: #ffffff;
}

.kerifa-badge-sale {
  background: #f59e0b;
  color: #ffffff;
}

.kerifa-raffle-content {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.kerifa-raffle-title {
  margin: 0 0 16px;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.4;
}

.kerifa-raffle-title a {
  color: #111827;
  text-decoration: none;
  transition: color 0.2s;
}

.kerifa-raffle-title a:hover {
  color: #6366f1;
}

.kerifa-raffle-meta {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
  flex: 1;
}

/* Countdown en tarjetas de productos */
.kerifa-raffle-content .kerifa-countdown-wrapper {
  margin-bottom: 12px;
  margin-top: 0;
}

.kerifa-raffle-stock {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: #6b7280;
}

.kerifa-meta-icon {
  font-size: 1.1rem;
}

.kerifa-meta-text {
  font-weight: 500;
}

.kerifa-raffle-price {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.kerifa-price-label {
  font-size: 0.75rem;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

.kerifa-price-amount {
  font-size: 1.5rem;
  font-weight: 800;
  color: #6366f1;
}

/* Información de Pool y Apuestas */
.kerifa-raffle-stats {
  margin: 8px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 8px 10px;
  background: #f9fafb;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}

.kerifa-stat-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.kerifa-stat-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  padding: 4px;
}

.kerifa-stat-icon-pool {
  background: #d1fae5;
}

.kerifa-stat-icon-wagers {
  background: #e0e7ff;
}

.kerifa-stat-icon svg {
  width: 16px;
  height: 16px;
}

.kerifa-stat-content {
  flex: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 6px;
}

.kerifa-stat-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #6b7280;
  line-height: 1.2;
}

.kerifa-stat-value {
  font-size: 0.8rem;
  font-weight: 700;
  color: #111827;
  line-height: 1.2;
}

.kerifa-raffle-actions {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid #f3f4f6;
}

.kerifa-raffle-actions .button,
.kerifa-raffle-actions .added_to_cart,
.kerifa-raffle-actions .kerifa-btn-participate {
  width: 100%;
  padding: 12px 20px;
  background: #6366f1;
  color: #ffffff;
  border: none;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
  text-decoration: none;
  display: block;
}

.kerifa-raffle-actions .button:hover,
.kerifa-raffle-actions .kerifa-btn-participate:hover {
  background: #4f46e5;
  color: #fff !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

.kerifa-raffle-actions .button:disabled {
  background: #d1d5db;
  cursor: not-allowed;
  transform: none;
}

.kerifa-raffle-actions .added_to_cart {
  background: #10b981;
  color: #fff;
}

.kerifa-raffle-actions .added_to_cart:hover {
  background: #059669;
  color: #fff !important;
}

/* Responsive - Tablets */
@media (max-width: 1024px) {
  .kerifa-raffles-layout {
    grid-template-columns: 1fr;
  }

  .kerifa-raffles-sidebar {
    position: static;
  }

  .kerifa-filters-panel {
    margin-bottom: 30px;
  }
}

/* Responsive - Móviles */
@media (max-width: 768px) {
  .k-container {
    padding: 0 1rem;
  }

  .kerifa-raffles-header {
    padding: 1rem 0;
  }

  .kerifa-raffles-title {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
  }

  .kerifa-raffles-subtitle {
    font-size: 0.875rem;
  }

  .kerifa-filters-toggle-mobile {
    display: flex;
  }

  .kerifa-raffles-layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .kerifa-raffles-sidebar {
    position: static;
    display: none;
  }

  .kerifa-raffles-sidebar.kerifa-filters-mobile-open {
    display: block;
  }

  .kerifa-filters-panel {
    padding: 16px;
    margin-bottom: 20px;
  }

  .kerifa-filters-header h3 {
    font-size: 1.1rem;
  }

  .kerifa-filter-group {
    margin-bottom: 20px;
  }

  .kerifa-raffles-toolbar {
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
    padding: 12px 16px;
  }

  .kerifa-toolbar-left {
    justify-content: center;
  }

  /* Grid de productos - siempre 1 columna en móvil */
  .products,
  .woocommerce ul.products {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }

  /* Tarjetas de productos en móvil */
  .kerifa-raffle-card,
  li.kerifa-raffle-card {
    width: 100% !important;
    margin: 0 !important;
  }

  .kerifa-raffle-image {
    height: 180px;
  }

  .kerifa-raffle-content {
    padding: 16px;
  }

  .kerifa-raffle-title {
    font-size: 1.1rem;
    margin-bottom: 12px;
  }

  /* Countdown en móvil */
  .kerifa-countdown-wrapper {
    padding: 12px;
    margin-bottom: 16px;
  }

  .kerifa-countdown-label {
    font-size: 0.7rem;
    margin-bottom: 8px;
  }

  .kerifa-countdown {
    gap: 4px;
  }

  .kerifa-countdown-item {
    min-width: 40px;
  }

  .kerifa-countdown-value {
    font-size: 1.25rem;
    padding: 6px 8px;
    min-width: 40px;
  }

  .kerifa-countdown-label-small {
    font-size: 0.6rem;
  }

  .kerifa-countdown-separator {
    font-size: 1.2rem;
    margin: 0 -2px;
    padding-top: 8px;
  }

  /* Botones en móvil */
  .kerifa-raffle-actions .kerifa-btn-participate,
  .kerifa-raffle-actions .button {
    padding: 14px 20px;
    font-size: 0.95rem;
  }

  /* Vista lista en móvil - cambiar a vertical */
  .products.view-list .kerifa-raffle-card-inner {
    flex-direction: column !important;
    min-height: auto;
  }

  .products.view-list .kerifa-raffle-image {
    width: 100% !important;
    min-width: 100% !important;
    height: 200px;
  }

  .products.view-list .kerifa-raffle-content {
    width: 100%;
  }
}

/* Responsive - Móviles pequeños */
@media (max-width: 480px) {
  .kerifa-raffles-title {
    font-size: 1.25rem;
  }

  .kerifa-filters-panel {
    padding: 12px;
  }

  .kerifa-filter-group {
    margin-bottom: 16px;
  }

  .kerifa-raffle-image {
    height: 160px;
  }

  .kerifa-raffle-content {
    padding: 12px;
  }

  .kerifa-countdown-wrapper {
    padding: 10px;
  }

  .kerifa-countdown-item {
    min-width: 35px;
  }

  .kerifa-countdown-value {
    font-size: 1.1rem;
    padding: 5px 6px;
    min-width: 35px;
  }

  .kerifa-countdown-label-small {
    font-size: 0.55rem;
  }

  .products.view-list .kerifa-raffle-image {
    height: 180px;
  }
}

/* ============================================
   PÁGINA DE PRODUCTO INDIVIDUAL - RIFAS
   ============================================ */

.kerifa-single-raffle {
  padding: 40px 20px;
  background: #f9fafb;
  min-height: calc(100vh - 200px);
}

/* Hero Section */
.kerifa-raffle-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 30px;
  background: #ffffff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  border: 1px solid #e5e7eb;
}

.kerifa-raffle-hero-image {
  position: relative;
  width: 100%;
  min-height: 280px;
  overflow: hidden;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
}

.kerifa-raffle-hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kerifa-raffle-hero-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
}

.kerifa-hero-icon {
  font-size: 8rem;
  opacity: 0.9;
}

.kerifa-raffle-hero-badge {
  position: absolute;
  top: 24px;
  right: 24px;
  background: #10b981;
  color: #ffffff;
  padding: 12px 24px;
  border-radius: 30px;
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.4);
  z-index: 2;
}

.kerifa-raffle-hero-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.kerifa-raffle-hero-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 12px;
  color: #111827;
  line-height: 1.3;
}

.kerifa-raffle-hero-description {
  font-size: 0.9375rem;
  color: #6b7280;
  line-height: 1.5;
  margin-bottom: 18px;
}

.kerifa-raffle-hero-info {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 18px;
  padding: 16px;
  background: #f9fafb;
  border-radius: 10px;
  border: 1px solid #e5e7eb;
}

.kerifa-info-item {
  display: flex;
  align-items: center;
  gap: 16px;
}

.kerifa-info-icon {
  font-size: 1.25rem;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  flex-shrink: 0;
}

.kerifa-info-item > div {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.kerifa-info-label {
  font-size: 0.75rem;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

.kerifa-info-value {
  font-size: 1rem;
  font-weight: 600;
  color: #111827;
}

/* Countdown Hero */
.kerifa-raffle-countdown-hero {
  margin-top: 20px;
  padding: 24px;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.3);
}

.kerifa-countdown-hero-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
  text-align: center;
  opacity: 0.95;
}

.kerifa-countdown-hero-timer {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.kerifa-countdown-hero-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 55px;
}

.kerifa-countdown-hero-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  background: rgba(255, 255, 255, 0.2);
  padding: 10px 12px;
  border-radius: 8px;
  backdrop-filter: blur(10px);
  min-width: 55px;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.kerifa-countdown-hero-label-small {
  font-size: 0.75rem;
  font-weight: 600;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.9;
}

.kerifa-countdown-hero-separator {
  font-size: 1.5rem;
  font-weight: 700;
  color: #ffffff;
  margin: 0 -4px;
  padding-top: 12px;
  opacity: 0.8;
}

/* Página del carrito - Diseño moderno */
.kerifa-cart-page {
  padding: 2rem 0;
  min-height: 60vh;
}

/* Ocultar el título "Cart" que viene de WordPress/WooCommerce */
.woocommerce-cart .entry-title,
.woocommerce-cart .page-title,
.woocommerce-cart h1:not(.kerifa-cart-title) {
  display: none !important;
}

.kerifa-cart-title {
  font-size: 2rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 2rem;
  text-align: center;
}

.kerifa-cart-table-wrapper {
  background: #ffffff;
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  overflow-x: auto;
  margin-bottom: 2rem;
}

.kerifa-cart-table-wrapper table {
  width: 100%;
  border-collapse: collapse;
}

.kerifa-cart-table-wrapper thead th {
  padding: 1rem;
  text-align: left;
  font-weight: 600;
  color: #374151;
  border-bottom: 2px solid #e5e7eb;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kerifa-cart-table-wrapper tbody td {
  padding: 1.5rem 1rem;
  border-bottom: 1px solid #f3f4f6;
  vertical-align: middle;
}

.kerifa-cart-table-wrapper tbody tr:last-child td {
  border-bottom: none;
}

.kerifa-cart-table-wrapper .product-thumbnail img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
}

.kerifa-cart-table-wrapper .product-name {
  font-weight: 600;
  color: #111827;
}

.kerifa-cart-table-wrapper .product-name a {
  color: #4f46e5;
  text-decoration: none;
  transition: color 0.2s ease;
}

.kerifa-cart-table-wrapper .product-name a:hover {
  color: #4338ca;
}

.kerifa-cart-table-wrapper .product-remove a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #fee2e2;
  color: #dc2626;
  text-decoration: none;
  font-size: 1.25rem;
  line-height: 1;
  transition: all 0.2s ease;
}

.kerifa-cart-table-wrapper .product-remove a:hover {
  background: #dc2626;
  color: #ffffff;
  transform: scale(1.1);
}

.kerifa-cart-table-wrapper .actions {
  padding: 1.5rem 1rem;
  background: #f9fafb;
  border-radius: 12px;
  border-top: 2px solid #e5e7eb;
}

.kerifa-cart-table-wrapper .cart-actions-row {
  background: #f9fafb;
}

.kerifa-cart-table-wrapper .cart-actions-row td {
  border-top: 2px solid #e5e7eb;
  padding: 1.5rem 1rem;
}

.kerifa-cart-table-wrapper .coupon {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.kerifa-cart-table-wrapper .coupon input {
  flex: 1;
  min-width: 200px;
  padding: 0.75rem 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 0.875rem;
  transition: border-color 0.2s ease;
  background: #ffffff;
}

.kerifa-cart-table-wrapper .coupon input:focus {
  outline: none;
  border-color: #4f46e5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.kerifa-cart-table-wrapper .button {
  padding: 0.75rem 1.5rem;
  background: #4f46e5;
  color: #ffffff;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-block;
  text-decoration: none;
}

.kerifa-cart-table-wrapper .button:hover {
  background: #4338ca;
  color: #fff !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 6px -1px rgba(79, 70, 229, 0.3);
}

.kerifa-cart-table-wrapper .button-update-cart {
  background: #6b7280;
  color: #fff;
  margin-top: 0.5rem;
}

.kerifa-cart-table-wrapper .button-update-cart:hover {
  background: #4b5563;
  color: #fff !important;
}

/* Filas de totales integradas */
.kerifa-cart-table-wrapper .cart-subtotal-row,
.kerifa-cart-table-wrapper .cart-shipping-row,
.kerifa-cart-table-wrapper .cart-discount,
.kerifa-cart-table-wrapper .fee,
.kerifa-cart-table-wrapper .tax-rate,
.kerifa-cart-table-wrapper .tax-total {
  background: #f9fafb;
}

.kerifa-cart-table-wrapper .cart-subtotal-row td,
.kerifa-cart-table-wrapper .cart-shipping-row td,
.kerifa-cart-table-wrapper .cart-discount td,
.kerifa-cart-table-wrapper .fee td,
.kerifa-cart-table-wrapper .tax-rate td,
.kerifa-cart-table-wrapper .tax-total td {
  padding: 1rem;
  border-top: 1px solid #e5e7eb;
  border-bottom: none;
}

.kerifa-cart-table-wrapper .cart-subtotal-label,
.kerifa-cart-table-wrapper .cart-shipping-label,
.kerifa-cart-table-wrapper .cart-discount-label,
.kerifa-cart-table-wrapper .fee-label,
.kerifa-cart-table-wrapper .tax-label {
  text-align: right;
  color: #6b7280;
  font-size: 0.9375rem;
}

.kerifa-cart-table-wrapper .cart-subtotal-value,
.kerifa-cart-table-wrapper .cart-shipping-value,
.kerifa-cart-table-wrapper .cart-discount-value,
.kerifa-cart-table-wrapper .fee-value,
.kerifa-cart-table-wrapper .tax-value {
  text-align: right;
  color: #111827;
  font-size: 0.9375rem;
}

.kerifa-cart-table-wrapper .cart-discount-label {
  color: #059669;
}

.kerifa-cart-table-wrapper .cart-discount-value {
  color: #059669;
  font-weight: 600;
}

.kerifa-cart-table-wrapper .cart-total-row {
  background: #ffffff;
  border-top: 2px solid #e5e7eb;
  border-bottom: 2px solid #e5e7eb;
}

.kerifa-cart-table-wrapper .cart-total-row td {
  padding: 1.25rem 1rem;
  border-bottom: none;
}

.kerifa-cart-table-wrapper .cart-total-label {
  text-align: right;
  color: #111827;
  font-size: 1.125rem;
}

.kerifa-cart-table-wrapper .cart-total-value {
  text-align: right;
  color: #111827;
  font-size: 1.25rem;
  font-weight: 700;
}

.kerifa-cart-table-wrapper .cart-checkout-row {
  background: #ffffff;
}

.kerifa-cart-table-wrapper .cart-checkout-cell {
  padding: 1.5rem 1rem;
  text-align: center;
  border-bottom: none;
}

.kerifa-cart-table-wrapper .button-checkout {
  width: 100%;
  max-width: 400px;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #ffffff;
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 6px -1px rgba(217, 119, 6, 0.3);
}

.kerifa-cart-table-wrapper .button-checkout:hover {
  background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
  color: #fff !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 12px -1px rgba(217, 119, 6, 0.4);
}

.cart-collaterals {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 768px) {
  .cart-collaterals {
    grid-template-columns: 1fr 400px;
  }
}

/* Lista de tickets comprados en el carrito */
.kerifa-cart-tickets-list {
  margin-top: 8px;
  font-size: 14px;
  color: #475569;
  line-height: 1.6;
}

.kerifa-cart-ticket-item {
  display: inline-block;
  margin-right: 12px;
  padding: 4px 8px;
  background-color: #f1f5f9;
  border-radius: 6px;
  font-weight: 500;
}

.kerifa-cart-ticket-item:last-child {
  margin-right: 0;
}

/* Estilos para tickets individuales en el carrito */
.kerifa-cart-lottery-item .product-quantity {
	display: none !important;
}

.kerifa-cart-lottery-quantity {
	display: none !important;
}

#kerifa-quantity-header:has(+ .kerifa-cart-lottery-item) {
	display: none !important;
}

.kerifa-cart-lottery-item {
  background-color: #fafbfc;
}

.kerifa-cart-ticket-row:not(:first-of-type) .product-thumbnail,
.kerifa-cart-ticket-row:not(:first-of-type) .product-name > a {
  display: none;
}

.kerifa-cart-ticket-item-wrapper {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.kerifa-cart-ticket-number {
  display: inline-block;
  min-width: 48px;
  text-align: center;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #ffffff;
  border-radius: 999px;
  padding: 6px 12px;
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 0.5px;
}

.kerifa-cart-ticket-amount-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.kerifa-ticket-decrease,
.kerifa-ticket-increase {
  width: 32px;
  height: 32px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  border-radius: 6px;
  cursor: pointer;
  font-size: 18px;
  font-weight: 700;
  color: #475569;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.kerifa-ticket-decrease:hover,
.kerifa-ticket-increase:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.kerifa-ticket-amount-display {
  min-width: 80px;
  text-align: center;
  font-weight: 700;
  font-size: 16px;
  color: #0f172a;
  padding: 6px 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
}

.kerifa-ticket-available {
  font-size: 12px;
  color: #64748b;
  margin-left: 4px;
}

.kerifa-ticket-error {
  color: #ef4444;
  font-size: 12px;
  margin-top: 4px;
  font-weight: 600;
}

.kerifa-remove-ticket {
  width: 24px;
  height: 24px;
  border: none;
  background: #fee2e2;
  color: #991b1b;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.kerifa-remove-ticket:hover {
  background: #fecaca;
  color: #7f1d1d;
}

/* Ocultar columna cantidad para productos de lotería */
.kerifa-cart-lottery-item .product-quantity,
.kerifa-cart-lottery-quantity {
  display: none !important;
}

/* Ocultar header de cantidad si solo hay productos de lotería */
table.cart:has(.kerifa-cart-lottery-item) .kerifa-cart-quantity-header {
  display: none !important;
}

/* Responsive para tickets en carrito */
@media (max-width: 768px) {
  .kerifa-cart-ticket-amount-controls {
    flex-direction: column;
    align-items: stretch;
  }
  
  .kerifa-ticket-available {
    margin-left: 0;
    margin-top: 4px;
    text-align: center;
  }
}

/* Countdown en el carrito */
.kerifa-cart-countdown {
  margin-top: 8px;
  padding: 8px 12px;
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  border: 1px solid #fbbf24;
}

.kerifa-cart-countdown-label {
  font-weight: 600;
  color: #92400e;
  font-size: 0.8125rem;
}

.kerifa-cart-countdown-timer {
  font-family: 'Digital-7', monospace;
  font-weight: 700;
  color: #78350f;
  font-size: 1rem;
  letter-spacing: 1px;
}

.kerifa-cart-countdown-minutes,
.kerifa-cart-countdown-seconds {
  display: inline-block;
  min-width: 24px;
  text-align: center;
  background: rgba(120, 53, 15, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
}

.kerifa-cart-countdown-expired {
  margin-top: 8px;
  padding: 8px 12px;
  background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  border: 1px solid #ef4444;
}

.kerifa-cart-countdown-expired-text {
  font-weight: 600;
  color: #991b1b;
  font-size: 0.875rem;
}

/* Responsive para countdown en carrito */
@media (max-width: 768px) {
  .kerifa-cart-page {
    padding: 1rem 0;
  }

  .kerifa-cart-countdown {
    font-size: 0.75rem;
    padding: 6px 10px;
  }
  
  .kerifa-cart-countdown-label {
    font-size: 0.75rem;
  }
  
  .kerifa-cart-countdown-timer {
    font-size: 0.875rem;
  }
  
  .kerifa-cart-countdown-minutes,
  .kerifa-cart-countdown-seconds {
    min-width: 20px;
    padding: 2px 4px;
  }
  
  .kerifa-cart-table-wrapper {
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
  }
  
  .kerifa-cart-table-wrapper table {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  }
  
  .kerifa-cart-table-wrapper thead {
    display: none;
  }
  
  .kerifa-cart-table-wrapper tbody tr {
    display: block;
    margin-bottom: 0;
    padding: 1rem;
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    position: relative;
  }

  .kerifa-cart-table-wrapper tbody tr:first-child {
    border-top: none;
  }

  .kerifa-cart-table-wrapper tbody tr:last-child {
    border-bottom: none;
  }
  
  .kerifa-cart-table-wrapper tbody td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: none;
    text-align: left !important;
  }

  .kerifa-cart-table-wrapper tbody td:before {
    content: attr(data-title);
    font-weight: 600;
    color: #6b7280;
    font-size: 0.875rem;
    flex-shrink: 0;
    margin-right: 1rem;
  }

  .kerifa-cart-table-wrapper .product-remove {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    padding: 0;
  }

  .kerifa-cart-table-wrapper .product-remove:before {
    display: none;
  }

  .kerifa-cart-table-wrapper .product-remove a {
    width: 28px;
    height: 28px;
    font-size: 1rem;
  }
  
  .kerifa-cart-table-wrapper .product-thumbnail {
    width: 100%;
    text-align: center;
    padding: 0.5rem 0;
  }

  .kerifa-cart-table-wrapper .product-thumbnail:before {
    display: none;
  }

  .kerifa-cart-table-wrapper .product-thumbnail img {
    width: 100px;
    height: 100px;
    margin: 0 auto;
  }

  .kerifa-cart-table-wrapper .product-name {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .kerifa-cart-table-wrapper .product-name:before {
    display: none;
  }

  .kerifa-cart-table-wrapper .product-price:before,
  .kerifa-cart-table-wrapper .product-quantity:before,
  .kerifa-cart-table-wrapper .product-subtotal:before {
    content: attr(data-title);
  }

  .kerifa-cart-table-wrapper .product-price,
  .kerifa-cart-table-wrapper .product-quantity,
  .kerifa-cart-table-wrapper .product-subtotal {
    font-weight: 600;
  }

  /* Acciones en móvil */
  .kerifa-cart-table-wrapper .cart-actions-row td {
    display: block;
    padding: 1rem;
  }

  .kerifa-cart-table-wrapper .coupon {
    flex-direction: column;
    gap: 0.5rem;
  }

  .kerifa-cart-table-wrapper .coupon input {
    width: 100%;
    min-width: auto;
  }

  .kerifa-cart-table-wrapper .button-update-cart {
    width: 100%;
  }

  /* Totales en móvil */
  .kerifa-cart-table-wrapper .cart-subtotal-row td,
  .kerifa-cart-table-wrapper .cart-shipping-row td,
  .kerifa-cart-table-wrapper .cart-discount td,
  .kerifa-cart-table-wrapper .fee td,
  .kerifa-cart-table-wrapper .tax-rate td,
  .kerifa-cart-table-wrapper .tax-total td,
  .kerifa-cart-table-wrapper .cart-total-row td {
    display: flex;
    justify-content: space-between;
    padding: 1rem;
  }

  .kerifa-cart-table-wrapper .cart-subtotal-label,
  .kerifa-cart-table-wrapper .cart-shipping-label,
  .kerifa-cart-table-wrapper .cart-discount-label,
  .kerifa-cart-table-wrapper .fee-label,
  .kerifa-cart-table-wrapper .tax-label,
  .kerifa-cart-table-wrapper .cart-total-label {
    text-align: left;
  }

  .kerifa-cart-table-wrapper .cart-subtotal-value,
  .kerifa-cart-table-wrapper .cart-shipping-value,
  .kerifa-cart-table-wrapper .cart-discount-value,
  .kerifa-cart-table-wrapper .fee-value,
  .kerifa-cart-table-wrapper .tax-value,
  .kerifa-cart-table-wrapper .cart-total-value {
    text-align: right;
  }

  .kerifa-cart-table-wrapper .cart-checkout-cell {
    padding: 1rem;
  }

  .kerifa-cart-table-wrapper .button-checkout {
    width: 100%;
    max-width: none;
    padding: 1.125rem 2rem;
    font-size: 0.9375rem;
  }
}

.kerifa-countdown-expired-hero {
  text-align: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: #ffffff;
  padding: 20px;
}

.kerifa-raffle-closed-banner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px;
  background: #fee2e2;
  border: 2px solid #ef4444;
  border-radius: 16px;
  margin-top: 20px;
}

.kerifa-closed-icon {
  font-size: 1.5rem;
}

.kerifa-closed-text {
  font-size: 1.125rem;
  font-weight: 700;
  color: #991b1b;
  text-align: center;
}

.kerifa-waiting-results-text {
  display: block;
  width: 100%;
  font-size: 0.95rem;
  font-weight: 600;
  color: #92400e;
  text-align: center;
  margin-top: 4px;
}

/* Sección de tickets */
.kerifa-raffle-tickets-section {
  background: #ffffff;
  border-radius: 16px;
  padding: 28px;
  margin-bottom: 30px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  border: 1px solid #e5e7eb;
}

.kerifa-tickets-header {
  text-align: center;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 2px solid #f3f4f6;
}

.kerifa-tickets-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 10px;
  color: #111827;
}

.kerifa-tickets-subtitle {
  font-size: 0.9375rem;
  color: #6b7280;
  margin: 0 0 8px;
}

.kerifa-tickets-limits {
  font-size: 0.875rem;
  color: #374151;
  margin: 8px 0 0;
  padding: 8px 12px;
  background: #fef3c7;
  border: 1px solid #fbbf24;
  border-radius: 8px;
  display: inline-block;
}

.kerifa-tickets-limits strong {
  color: #92400e;
  font-weight: 600;
}

.kerifa-tickets-content {
  max-width: 100%;
}

/* Ocultar imagen destacada en la sección de tickets (ya está en el hero) */
.kerifa-tickets-content .woocommerce-product-gallery,
.kerifa-tickets-content .wp-post-image,
.kerifa-tickets-content img.attachment-woocommerce_single,
.kerifa-tickets-content .woocommerce-product-gallery__image {
  display: none !important;
}

/* Ocultar input de cantidad para productos de rifa */
.kerifa-single-raffle .quantity,
.kerifa-single-raffle input[type="number"].qty,
.kerifa-single-raffle .qty {
  display: none !important;
}

/* Ocultar categorías y etiquetas para productos de rifa */
.kerifa-single-raffle .product_meta,
.kerifa-single-raffle .posted_in,
.kerifa-single-raffle .tagged_as,
.kerifa-single-raffle .sku_wrapper {
  display: none !important;
}

/* Mejorar estilos del picker del plugin */
.mll-wrap {
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
  box-shadow: none !important;
}

/* Ocultar contenido duplicado del plugin (título, subtítulo y info del sorteo) */
.kerifa-single-raffle .mll-top,
.kerifa-single-raffle .mll-title,
.kerifa-single-raffle .mll-sub {
  display: none !important;
}

.mll-top {
  margin-bottom: 24px !important;
  padding-bottom: 20px;
  border-bottom: 2px solid #f3f4f6;
}

.mll-title {
  font-size: 1.5rem !important;
  font-weight: 800 !important;
  color: #111827 !important;
  margin-bottom: 8px !important;
}

.mll-sub {
  font-size: 0.95rem !important;
  color: #6b7280 !important;
  opacity: 1 !important;
}

.mll-grid {
  gap: 12px !important;
  margin-bottom: 30px !important;
}

.mll-num {
  padding: 16px 8px !important;
  border-radius: 12px !important;
  border: 2px solid #e5e7eb !important;
  background: #ffffff !important;
  font-weight: 700 !important;
  font-size: 1rem !important;
  color: #374151 !important;
  transition: all 0.2s ease !important;
  cursor: pointer !important;
}

.mll-num:hover {
  border-color: #6366f1 !important;
  background: #f3f4f6 !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2) !important;
}

.mll-num.is-on {
  background: #6366f1 !important;
  border-color: #6366f1 !important;
  color: #ffffff !important;
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.4) !important;
}

.mll-num.is-soldout {
  opacity: 0.4 !important;
  cursor: not-allowed !important;
  background: #f3f4f6 !important;
}

.mll-max-hint {
  font-size: 0.75rem;
  color: #6b7280;
  margin-top: 4px;
  font-weight: 500;
}

.mll-amount-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.mll-amount-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 200px;
}

.mll-btn-increase,
.mll-btn-decrease {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 2px solid #6366f1;
  background: #ffffff;
  color: #6366f1;
  font-size: 1.5rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  line-height: 1;
  padding: 0;
}

.mll-btn-increase:hover,
.mll-btn-decrease:hover {
  background: #6366f1;
  color: #ffffff;
  transform: scale(1.05);
}

.mll-btn-increase:active,
.mll-btn-decrease:active {
  transform: scale(0.95);
}

.mll-amount-display {
  flex: 1;
  min-width: 120px;
  padding: 12px 16px;
  background: #1a1a1a;
  color: #00ff00;
  font-family: 'Courier New', monospace;
  font-size: 1.5rem;
  font-weight: 700;
  text-align: center;
  border-radius: 8px;
  border: 2px solid #333;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3), 0 0 10px rgba(0, 255, 0, 0.2);
  letter-spacing: 2px;
}

.mll-amount-controls.mll-error .mll-amount-display {
  border-color: #ef4444;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3), 0 0 10px rgba(239, 68, 68, 0.3);
}

.mll-available-text {
  font-size: 0.875rem;
  color: #6b7280;
  font-weight: 500;
  white-space: nowrap;
  flex-shrink: 0;
}

.mll-available-text .mll-loading {
  color: #9ca3af;
  font-style: italic;
}

.mll-error-msg {
  font-size: 0.75rem;
  color: #ef4444;
  margin-top: 4px;
  font-weight: 500;
  width: 100%;
}

.mll-amt.mll-error {
  border-color: #ef4444 !important;
  background: #fef2f2 !important;
}

.mll-selected {
  margin-top: 30px !important;
  padding: 24px !important;
  background: #f9fafb !important;
  border-radius: 16px !important;
  border: 2px solid #e5e7eb !important;
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}

.mll-selected-list {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}

.mll-selected-title {
  font-size: 1.25rem !important;
  font-weight: 800 !important;
  color: #111827 !important;
  margin-bottom: 20px !important;
}

.mll-row {
  background: #ffffff !important;
  border: 2px solid #e5e7eb !important;
  border-radius: 12px !important;
  padding: 16px !important;
  margin-bottom: 12px !important;
  transition: all 0.2s ease !important;
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}

.mll-row:hover {
  border-color: #6366f1 !important;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.15) !important;
}

.mll-pill {
  background: #6366f1 !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  font-size: 1rem !important;
  padding: 8px 16px !important;
}

.mll-remove {
  background: #fee2e2 !important;
  color: #991b1b !important;
  transition: all 0.2s ease !important;
}

.mll-remove:hover {
  background: #ef4444 !important;
  color: #ffffff !important;
  transform: scale(1.1);
}

.mll-amt {
  border: 2px solid #e5e7eb !important;
  border-radius: 8px !important;
  padding: 10px 14px !important;
  font-size: 1rem !important;
  transition: all 0.2s ease !important;
}

.mll-amt:focus {
  border-color: #6366f1 !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1) !important;
  outline: none !important;
}

.mll-total {
  margin-top: 20px !important;
  padding-top: 20px !important;
  border-top: 2px solid #e5e7eb !important;
  font-size: 1.5rem !important;
  font-weight: 900 !important;
  color: #6366f1 !important;
}

.mll-limits {
  margin-top: 20px !important;
  padding: 16px !important;
  background: #fef3c7 !important;
  border: 2px solid #fbbf24 !important;
  border-radius: 12px !important;
  color: #92400e !important;
  font-size: 0.95rem !important;
}

.mll-note {
  margin-top: 20px !important;
  padding: 16px !important;
  background: #eff6ff !important;
  border: 2px solid #3b82f6 !important;
  border-radius: 12px !important;
  color: #1e40af !important;
  font-size: 0.95rem !important;
}

.mll-closed {
  padding: 20px !important;
  background: #fee2e2 !important;
  border: 2px solid #ef4444 !important;
  border-radius: 12px !important;
  color: #991b1b !important;
  font-weight: 700 !important;
  text-align: center !important;
}

/* Estilos para el botón Añadir al carrito en rifas */
.kerifa-tickets-content .single_add_to_cart_button,
.kerifa-tickets-content button[type="submit"].single_add_to_cart_button,
.kerifa-tickets-content .button.single_add_to_cart_button {
  width: 100%;
  padding: 18px 32px;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-size: 1.125rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.4);
  margin-top: 30px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kerifa-tickets-content .single_add_to_cart_button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.5);
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  color: #fff !important;
}

.kerifa-tickets-content .single_add_to_cart_button:disabled {
  background: #d1d5db;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Formulario de cantidad (si existe) */
.kerifa-tickets-content .quantity {
  margin-bottom: 20px;
}

.kerifa-tickets-content .quantity input {
  padding: 12px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 1rem;
  width: 100px;
  text-align: center;
}

.kerifa-tickets-content .quantity input:focus {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
  outline: none;
}

/* Descripción del sorteo */
.kerifa-raffle-description-section {
  background: #ffffff;
  border-radius: 24px;
  padding: 40px;
  margin-bottom: 40px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid #e5e7eb;
}

.kerifa-raffle-description-content {
  font-size: 1.125rem;
  line-height: 1.8;
  color: #374151;
}

.kerifa-raffle-description-content p {
  margin-bottom: 16px;
}

/* Información adicional */
.kerifa-raffle-additional-info {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 40px;
}

.kerifa-info-card {
  background: #ffffff;
  border-radius: 16px;
  padding: 32px;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
}

.kerifa-info-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
  border-color: #6366f1;
}

.kerifa-info-card-icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.kerifa-info-card h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 12px;
  color: #111827;
}

.kerifa-info-card p {
  font-size: 0.95rem;
  color: #6b7280;
  line-height: 1.6;
  margin: 0;
}

/* Sección de Resultados */
.kerifa-raffle-results-section {
  background: #ffffff;
  border-radius: 16px;
  padding: 32px;
  margin-bottom: 30px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  border: 1px solid #e5e7eb;
}

.kerifa-results-header {
  text-align: center;
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 2px solid #f3f4f6;
}

.kerifa-results-title {
  font-size: 1.75rem;
  font-weight: 800;
  margin: 0 0 20px;
  color: #111827;
}

.kerifa-winner-number {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 32px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.3);
}

.kerifa-winner-label {
  font-size: 1rem;
  font-weight: 600;
  color: #ffffff;
  opacity: 0.9;
}

.kerifa-winner-value {
  font-size: 2.5rem;
  font-weight: 900;
  color: #ffffff;
  font-variant-numeric: tabular-nums;
  background: rgba(255, 255, 255, 0.2);
  padding: 8px 20px;
  border-radius: 8px;
  min-width: 80px;
  text-align: center;
}

.kerifa-winners-subtitle {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 20px;
  color: #111827;
}

.kerifa-winners-table-wrapper {
  overflow-x: auto;
}

.kerifa-winners-table {
  width: 100%;
  border-collapse: collapse;
  background: #ffffff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.kerifa-winners-table thead {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #ffffff;
}

.kerifa-winners-table th {
  padding: 16px;
  text-align: left;
  font-weight: 700;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kerifa-winners-table tbody tr {
  border-bottom: 1px solid #e5e7eb;
  transition: background-color 0.2s ease;
}

.kerifa-winners-table tbody tr:hover {
  background-color: #f9fafb;
}

.kerifa-winners-table tbody tr:last-child {
  border-bottom: none;
}

.kerifa-winners-table td {
  padding: 16px;
  font-size: 0.9375rem;
}

.kerifa-winners-table .kerifa-rank {
  font-weight: 700;
  color: #6366f1;
  text-align: center;
  width: 60px;
}

.kerifa-winners-table .kerifa-user-name {
  font-weight: 600;
  color: #111827;
}

.kerifa-winners-table .kerifa-invested {
  color: #6b7280;
  font-weight: 500;
}

.kerifa-winners-table .kerifa-payout {
  font-weight: 700;
  color: #10b981;
  font-size: 1.0625rem;
}

.kerifa-no-winners {
  text-align: center;
  padding: 40px;
  color: #6b7280;
  font-size: 1.0625rem;
}

/* Responsive */
@media (max-width: 1024px) {
  .kerifa-raffle-hero {
    grid-template-columns: 1fr;
  }
  
  .kerifa-raffle-hero-image {
    min-height: 240px;
  }
  
  .kerifa-raffle-hero-title {
    font-size: 1.375rem;
  }
  
  .kerifa-raffle-hero-content {
    padding: 20px;
  }
  
  .kerifa-raffle-hero {
    gap: 20px;
    margin-bottom: 24px;
  }
  
  .kerifa-raffle-additional-info {
    grid-template-columns: 1fr;
  }
  
  .kerifa-countdown-hero-item {
    min-width: 70px;
  }
  
  .kerifa-countdown-hero-value {
    font-size: 2rem;
    padding: 12px 16px;
    min-width: 70px;
  }
}

@media (max-width: 768px) {
  .kerifa-raffle-hero-title {
    font-size: 1.25rem;
  }
  
  .kerifa-raffle-hero-content {
    padding: 18px;
  }
  
  .kerifa-raffle-hero-image {
    min-height: 200px;
  }
  
  .kerifa-countdown-hero-timer {
    gap: 6px;
  }
  
  .kerifa-countdown-hero-item {
    min-width: 50px;
  }
  
  .kerifa-countdown-hero-value {
    font-size: 1.25rem;
    padding: 8px 10px;
    min-width: 50px;
  }
  
  .kerifa-countdown-hero-separator {
    font-size: 1.25rem;
  }
  
  .kerifa-countdown-hero-label {
    font-size: 0.75rem;
    margin-bottom: 10px;
  }
  
  .mll-grid {
    grid-template-columns: repeat(7, minmax(0, 1fr)) !important; /* Aumentado de 5 a 7 columnas */
    gap: 6px !important; /* Reducido de 12px a 6px */
  }
  
  .mll-num {
    padding: 10px 4px !important; /* Reducido padding vertical y horizontal */
    font-size: 0.875rem !important; /* Reducido ligeramente el tamaño de fuente */
    border-radius: 8px !important; /* Border más pequeño */
    border-width: 1.5px !important; /* Borde más delgado */
  }
  
  /* Optimización de la sección de tickets seleccionados */
  .mll-selected {
    margin-top: 20px !important; /* Reducido de 30px */
    padding: 16px !important; /* Reducido de 24px */
  }
  
  .mll-selected-title {
    font-size: 1.1rem !important; /* Reducido de 1.25rem */
    margin-bottom: 12px !important; /* Reducido de 20px */
  }
  
  .mll-row {
    padding: 8px 10px !important; /* Muy compacto */
    margin-bottom: 6px !important;
    border-radius: 8px !important;
    border-width: 1.5px !important;
    display: flex !important;
    flex-direction: row !important; /* Forzar horizontal - override del plugin */
    align-items: center !important;
    justify-content: flex-start !important; /* Alinear desde la izquierda */
    gap: 6px !important; /* Reducido gap */
    flex-wrap: nowrap !important; /* No permitir wrap */
    overflow: hidden !important;
    min-height: 40px !important; /* Altura mínima compacta */
    width: 100% !important; /* Asegurar que ocupe todo el ancho */
    max-width: 100% !important; /* No exceder el ancho del contenedor */
    box-sizing: border-box !important; /* Incluir padding en el ancho */
  }
  
  .mll-row-left {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    flex-shrink: 0 !important;
  }
  
  .mll-pill {
    font-size: 0.8rem !important;
    padding: 4px 10px !important; /* Muy compacto */
    min-width: 36px !important;
    border-radius: 12px !important;
    white-space: nowrap !important;
  }
  
  .mll-remove {
    width: 22px !important;
    height: 22px !important;
    font-size: 0.9rem !important;
    padding: 0 !important;
    flex-shrink: 0 !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }
  
  .mll-row-right {
    display: flex !important;
    flex-direction: row !important; /* Forzar horizontal - override del plugin */
    align-items: center !important;
    gap: 4px !important;
    flex: 1 !important;
    min-width: 0 !important; /* Permitir que se comprima */
    max-width: 100% !important; /* No exceder el ancho */
    overflow: hidden !important;
    justify-content: flex-start !important; /* Alinear a la izquierda */
    box-sizing: border-box !important;
  }
  
  .mll-row-right label {
    display: none !important; /* Ocultar label "Monto" */
  }
  
  .mll-amount-wrapper {
    display: flex !important;
    flex-direction: row !important; /* Forzar horizontal */
    align-items: center !important;
    gap: 4px !important;
    flex-wrap: nowrap !important; /* No wrap */
    flex: 1 1 auto !important; /* Crecer y comprimir según espacio disponible */
    min-width: 0 !important; /* Permitir que se comprima */
    max-width: 100% !important; /* No exceder el ancho */
    overflow: hidden !important;
    box-sizing: border-box !important;
    justify-content: flex-start !important; /* Alinear desde la izquierda */
  }
  
  .mll-amount-controls {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 3px !important; /* Gap muy pequeño */
    flex-shrink: 0 !important;
    min-width: 0 !important; /* Permitir compresión si es necesario */
  }
  
  .mll-btn-increase,
  .mll-btn-decrease {
    width: 26px !important; /* Muy compacto */
    height: 26px !important;
    font-size: 1rem !important;
    border-width: 1.5px !important;
    padding: 0 !important;
    flex-shrink: 0 !important;
    line-height: 1 !important;
  }
  
  .mll-amount-display {
    min-width: 45px !important; /* Reducido para más espacio */
    max-width: 65px !important; /* Reducido */
    padding: 4px 5px !important; /* Padding mínimo */
    font-size: 0.85rem !important; /* Fuente más pequeña */
    letter-spacing: 0.5px !important;
    text-align: center !important;
    flex-shrink: 1 !important; /* Permitir compresión si es necesario */
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    box-sizing: border-box !important;
  }
  
  .mll-available-text {
    display: flex !important;
    flex-direction: column !important; /* Apilar verticalmente */
    align-items: center !important;
    justify-content: center !important;
    font-size: 0.7rem !important;
    flex-shrink: 1 !important; /* Permitir que se comprima si es necesario */
    flex-grow: 0 !important; /* No crecer más de lo necesario */
    min-width: 0 !important; /* Permitir compresión completa */
    max-width: 100% !important; /* Respetar el ancho del contenedor */
    width: auto !important; /* Ancho automático basado en contenido */
    text-align: center !important;
    line-height: 1.3 !important;
    padding: 2px 3px !important; /* Padding horizontal mínimo */
    box-sizing: border-box !important;
    overflow: hidden !important; /* Evitar desbordamiento */
    margin-left: auto !important; /* Empujar hacia la derecha pero dentro del contenedor */
    position: relative !important; /* Para posicionamiento relativo */
  }
  
  .mll-available-amount {
    font-weight: 700 !important;
    color: #6366f1 !important;
    font-size: 0.8rem !important; /* Aumentado para mejor visibilidad */
    display: block !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
  }
  
  .mll-available-label {
    font-weight: 500 !important;
    color: #6b7280 !important;
    font-size: 0.65rem !important;
    display: block !important;
    margin-top: 1px !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
  }
  
  .mll-soldout-text {
    font-weight: 700 !important;
    color: #ef4444 !important;
    font-size: 0.75rem !important; /* Aumentado para mejor visibilidad */
    display: block !important;
    text-align: center !important;
    line-height: 1.3 !important;
    white-space: nowrap !important;
  }
  
  .mll-error-msg {
    display: none !important; /* Ocultar en móvil para ahorrar espacio */
  }
  
  .mll-total {
    margin-top: 12px !important; /* Reducido de 20px */
    font-size: 1.1rem !important;
    padding-top: 12px !important;
  }
}

/* Optimización adicional para pantallas muy pequeñas */
@media (max-width: 480px) {
  .mll-grid {
    grid-template-columns: repeat(8, minmax(0, 1fr)) !important; /* 8 columnas en pantallas muy pequeñas */
    gap: 4px !important; /* Gap aún más pequeño */
  }
  
  .mll-num {
    padding: 8px 2px !important; /* Padding aún más compacto */
    font-size: 0.8rem !important; /* Fuente un poco más pequeña */
    border-radius: 6px !important;
  }
  
  /* Optimización extrema para pantallas muy pequeñas */
  .mll-selected {
    padding: 10px !important; /* Aún más compacto */
  }
  
  .mll-row {
    padding: 6px 8px !important; /* Ultra compacto */
    margin-bottom: 4px !important;
    gap: 6px !important;
  }
  
  .mll-pill {
    font-size: 0.75rem !important;
    padding: 3px 8px !important;
    min-width: 32px !important;
  }
  
  .mll-remove {
    width: 20px !important;
    height: 20px !important;
    font-size: 0.85rem !important;
  }
  
  .mll-btn-increase,
  .mll-btn-decrease {
    width: 24px !important;
    height: 24px !important;
    font-size: 0.9rem !important;
  }
  
  .mll-amount-display {
    min-width: 45px !important;
    max-width: 60px !important;
    padding: 3px 5px !important;
    font-size: 0.8rem !important;
  }
  
  .mll-available-text {
    font-size: 0.65rem !important;
  }
}

/* Estilos antiguos mantenidos para compatibilidad */
.kerifa-shop-wrapper {
  padding: 40px 20px;
  background: #f9fafb;
  min-height: calc(100vh - 200px);
}

.kerifa-shop-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 40px;
  flex-wrap: wrap;
  gap: 20px;
}

.kerifa-shop-title-section {
  flex: 1;
}

.kerifa-shop-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 0 10px;
  color: #111827;
}

.kerifa-shop-subtitle {
  font-size: 1.1rem;
  color: #6b7280;
  margin: 0;
}

.kerifa-shop-results {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

/* Grid de productos */
.woocommerce ul.products {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 30px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.kerifa-product-card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #e5e7eb;
  list-style: none;
  margin: 0;
}

.kerifa-product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}

.kerifa-product-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.kerifa-product-image {
  position: relative;
  width: 100%;
  padding-top: 75%;
  overflow: hidden;
  background: #f3f4f6;
}

.kerifa-product-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.kerifa-product-card:hover .kerifa-product-image img {
  transform: scale(1.05);
}

.kerifa-product-link {
  display: block;
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
}

.kerifa-sale-badge {
  position: absolute;
  top: 15px;
  right: 15px;
  background: #ef4444;
  color: #fff;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  z-index: 10;
}

.kerifa-product-info {
  padding: 25px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.kerifa-product-title {
  margin: 0 0 15px;
  font-size: 1.25rem;
  font-weight: 700;
  color: #111827;
}

.kerifa-product-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.kerifa-product-title a:hover {
  color: #6366f1;
}

.kerifa-product-meta {
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid #e5e7eb;
}

.kerifa-product-stock {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 15px;
  padding: 10px;
  background: #f9fafb;
  border-radius: 8px;
}

.kerifa-stock-icon {
  font-size: 1.2rem;
}

.kerifa-stock-text {
  font-size: 0.9rem;
  color: #6b7280;
  font-weight: 500;
}

.kerifa-product-price {
  margin-bottom: 15px;
}

.kerifa-product-price .woocommerce-Price-amount {
  font-size: 1.5rem;
  font-weight: 700;
  color: #6366f1;
}

.kerifa-product-price del {
  color: #9ca3af;
  font-size: 1rem;
  margin-right: 8px;
}

.kerifa-product-actions {
  margin-top: 15px;
}

.kerifa-product-actions .button {
  width: 100%;
  justify-content: center;
  padding: 14px;
  font-size: 1rem;
  font-weight: 600;
}

/* Sin productos */
.woocommerce-info,
.woocommerce-message {
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  border-left: 4px solid #6366f1;
  margin: 40px 0;
}

/* ============================================
   FOOTER MEJORADO
   ============================================ */

.k-site-footer {
  background: #111827;
  color: #9ca3af;
  padding: 60px 20px 30px;
  margin-top: 80px;
}

.k-footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.k-footer-column {
  display: flex;
  flex-direction: column;
}

.k-footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.k-footer-logo-text {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
}

.k-footer-description {
  font-size: 0.95rem;
  line-height: 1.6;
  margin: 0 0 20px;
  color: #9ca3af;
}

.k-footer-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 20px;
}

.k-footer-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.k-footer-menu li {
  margin: 0;
}

.k-footer-menu a {
  color: #9ca3af;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.2s ease;
  display: inline-block;
}

.k-footer-menu a:hover {
  color: #fff;
}

.k-footer-menu li:not(:has(a)) {
  color: #9ca3af;
  font-size: 0.95rem;
}

.k-footer-bottom {
  border-top: 1px solid #374151;
  padding-top: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.k-footer-copyright {
  font-size: 0.9rem;
  color: #6b7280;
}

.k-footer-legal {
  display: flex;
  align-items: center;
  gap: 15px;
  flex-wrap: wrap;
}

.k-footer-legal a {
  color: #9ca3af;
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.k-footer-legal a:hover {
  color: #fff;
}

.k-footer-separator {
  color: #374151;
}

/* Sidebar */
#secondary {
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  border: 1px solid #e5e7eb;
}

.widget {
  margin-bottom: 30px;
}

.widget:last-child {
  margin-bottom: 0;
}

.widget-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 20px;
  color: #111827;
  padding-bottom: 15px;
  border-bottom: 2px solid #e5e7eb;
}

.widget ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.widget ul li {
  margin-bottom: 10px;
  padding-left: 20px;
  position: relative;
}

.widget ul li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: #6366f1;
  font-weight: 700;
}

.widget ul li a {
  color: #4b5563;
  text-decoration: none;
  transition: color 0.2s ease;
}

.widget ul li a:hover {
  color: #6366f1;
}

.widget_search .search-form {
  display: flex;
  gap: 10px;
}

.widget_search input[type="search"] {
  flex: 1;
  padding: 10px 15px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
}

.widget_search input[type="submit"] {
  padding: 10px 20px;
  background: #6366f1;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.2s ease;
}

.widget_search input[type="submit"]:hover {
  background: #4f46e5;
}

/* Responsive para shop y footer */
@media (max-width: 768px) {
  .kerifa-shop-header {
    flex-direction: column;
  }

  .kerifa-shop-title {
    font-size: 2rem;
  }

  .woocommerce ul.products {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
  }

  .k-footer-content {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .k-footer-bottom {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 640px) {
  .woocommerce ul.products {
    grid-template-columns: 1fr;
  }

  .kerifa-product-info {
    padding: 20px;
  }
}

/* ============================================
   POOL DE BANQUEO - Estilos
   ============================================ */

.kerifa-pool-section {
  background: #ffffff;
  border-radius: 24px;
  padding: 40px;
  margin-bottom: 40px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid #e5e7eb;
}

.kerifa-pool-header {
  margin-bottom: 30px;
  text-align: center;
}

.kerifa-pool-title {
  font-size: 2rem;
  font-weight: 800;
  margin: 0 0 12px;
  color: #111827;
}

.kerifa-pool-description {
  font-size: 1rem;
  color: #6b7280;
  margin: 0;
}

.kerifa-pool-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.kerifa-pool-stat-card {
  background: #f9fafb;
  border-radius: 16px;
  padding: 24px;
  text-align: center;
  border: 1px solid #e5e7eb;
}

.kerifa-pool-stat-card.kerifa-pool-user-stat {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #ffffff;
  border: none;
}

.kerifa-pool-stat-label {
  font-size: 0.875rem;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  margin-bottom: 8px;
}

.kerifa-pool-user-stat .kerifa-pool-stat-label {
  color: rgba(255, 255, 255, 0.9);
}

.kerifa-pool-stat-value {
  font-size: 1.75rem;
  font-weight: 800;
  color: #111827;
  margin-bottom: 8px;
}

.kerifa-pool-user-stat .kerifa-pool-stat-value {
  color: #ffffff;
}

.kerifa-pool-stat-sub {
  font-size: 0.875rem;
  color: #9ca3af;
}

.kerifa-pool-user-stat .kerifa-pool-stat-sub {
  color: rgba(255, 255, 255, 0.8);
}

.kerifa-pool-progress-bar {
  width: 100%;
  height: 8px;
  background: #e5e7eb;
  border-radius: 4px;
  overflow: hidden;
  margin: 12px 0 8px;
}

.kerifa-pool-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #6366f1 0%, #8b5cf6 100%);
  border-radius: 4px;
  transition: width 0.3s ease;
}

.kerifa-pool-contribute {
  margin-top: 30px;
  padding-top: 30px;
  border-top: 2px solid #f3f4f6;
}

.kerifa-pool-contribute-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 20px;
  color: #111827;
}

.kerifa-pool-contribute-form {
  max-width: 500px;
  margin: 0 auto;
}

.kerifa-pool-form-group {
  margin-bottom: 24px;
}

.kerifa-pool-form-group label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 8px;
}

.kerifa-pool-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
}

.kerifa-pool-currency {
  font-weight: 700;
  color: #6366f1;
  font-size: 1rem;
  padding: 14px 16px;
  background: #f3f4f6;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  min-width: 60px;
  text-align: center;
  flex-shrink: 0;
}

.kerifa-pool-amount-input {
  flex: 1;
  width: 100%;
  padding: 14px 16px;
  font-size: 1.125rem;
  font-weight: 600;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  background: #ffffff;
  transition: all 0.2s ease;
}

.kerifa-pool-amount-input:focus {
  outline: none;
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.kerifa-pool-balance {
  margin-top: 8px;
  font-size: 0.875rem;
  color: #6b7280;
}

.kerifa-pool-contribute-btn {
  width: 100%;
  padding: 16px;
  font-size: 1.125rem;
  font-weight: 700;
  border-radius: 12px;
  margin-bottom: 16px;
}

.kerifa-pool-contribute-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.kerifa-pool-warning {
  background: #fef3c7;
  border: 1px solid #fbbf24;
  border-radius: 12px;
  padding: 16px;
  font-size: 0.875rem;
  color: #92400e;
}

.kerifa-pool-login-required {
  text-align: center;
  padding: 24px;
  background: #f9fafb;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
}

.kerifa-pool-login-required a {
  color: #6366f1;
  font-weight: 600;
}

/* Inversiones en Pools - Dashboard */
.kerifa-pool-investments {
  padding: 20px 0;
}

.kerifa-section-title {
  font-size: 2rem;
  font-weight: 800;
  margin: 0 0 12px;
  color: #111827;
}

.kerifa-section-description {
  font-size: 1rem;
  color: #6b7280;
  margin: 0 0 30px;
}

.kerifa-investments-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
  margin-top: 30px;
}

.kerifa-investment-card {
  background: #ffffff;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  border: 1px solid #e5e7eb;
  transition: all 0.2s ease;
}

.kerifa-investment-card:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}

.kerifa-investment-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #f3f4f6;
}

.kerifa-investment-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
  flex: 1;
}

.kerifa-investment-title a {
  color: #111827;
  text-decoration: none;
}

.kerifa-investment-title a:hover {
  color: #6366f1;
}

.kerifa-investment-badge {
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kerifa-investment-info {
  margin-bottom: 20px;
}

.kerifa-investment-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid #f9fafb;
}

.kerifa-investment-row:last-child {
  border-bottom: none;
}

.kerifa-investment-label {
  font-size: 0.875rem;
  color: #6b7280;
  font-weight: 500;
}

.kerifa-investment-value {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #111827;
}

.kerifa-investment-amount {
  font-size: 1.125rem;
  font-weight: 700;
  color: #6366f1;
}

.kerifa-investment-profit {
  color: #10b981;
}

.kerifa-investment-loss {
  color: #ef4444;
}

.kerifa-investment-footer {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid #f3f4f6;
}

.kerifa-empty-state {
  text-align: center;
  padding: 60px 20px;
  background: #f9fafb;
  border-radius: 16px;
  border: 2px dashed #e5e7eb;
}

.kerifa-empty-state p {
  font-size: 1.125rem;
  color: #6b7280;
  margin: 0 0 24px;
}

/* Responsive */
@media (max-width: 768px) {
  .kerifa-pool-section {
    padding: 24px;
  }

  .kerifa-pool-stats {
    grid-template-columns: 1fr;
  }

  .kerifa-investments-grid {
    grid-template-columns: 1fr;
  }
}

