/* Estilos para Ko-fi Manga Subscription */
/* Compatible con temas claros y oscuros */

/* ============================================
   BOTÓN DE DONACIÓN
   ============================================ */

.kofi-subscription-button-wrapper {
    text-align: center;
    margin: 30px 0;
}

.kofi-subscribe-button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    background: linear-gradient(135deg, #29abe0 0%, #1e88c7 100%);
    color: #ffffff !important;
    text-decoration: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(41, 171, 224, 0.3);
}

.kofi-subscribe-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(41, 171, 224, 0.4);
    color: #ffffff !important;
}

.kofi-icon {
    font-size: 24px;
    line-height: 1;
}

.kofi-subscription-description {
    margin-top: 15px;
    color: #b0b0b0;
    font-size: 14px;
}

.kofi-subscription-note {
    font-size: 12px;
    color: #ff9800 !important;
    margin-top: 5px;
}

/* ============================================
   ESTADO DE SUSCRIPCIÓN
   ============================================ */

.kofi-subscription-status {
    background: rgba(30, 30, 40, 0.95);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    margin: 20px 0;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.subscription-active {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    border-left: 4px solid #4caf50;
    padding-left: 20px;
}

.subscription-inactive {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    border-left: 4px solid #ff9800;
    padding-left: 20px;
}

.status-icon {
    font-size: 48px;
    font-weight: bold;
}

.subscription-active .status-icon {
    color: #4caf50;
}

.subscription-inactive .status-icon {
    color: #ff9800;
}

.status-content h3 {
    margin: 0 0 10px 0;
    font-size: 24px;
    color: #ffffff;
}

.status-content p {
    color: #cccccc;
}

.subscription-benefits {
    margin-top: 15px;
    padding: 10px;
    background: rgba(76, 175, 80, 0.2);
    border-radius: 6px;
    font-weight: 500;
    color: #81c784;
}

/* ============================================
   BENEFICIOS DE SUSCRIPCIÓN
   ============================================ */

.kofi-subscription-benefits {
    background: rgba(30, 30, 40, 0.95);
    border-radius: 12px;
    padding: 40px;
    margin: 30px 0;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.kofi-subscription-benefits h2 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 32px;
    color: #ffffff;
}

.benefits-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.benefit-item {
    display: flex;
    gap: 15px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.benefit-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    background: rgba(255, 255, 255, 0.08);
}

.benefit-icon {
    font-size: 36px;
    flex-shrink: 0;
}

.benefit-content h4 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: #ffffff;
}

.benefit-content p {
    margin: 0;
    color: #b0b0b0;
    font-size: 14px;
    line-height: 1.5;
}

.benefits-cta {
    text-align: center;
    margin-top: 30px;
}

/* ============================================
   AVISO DE CONTENIDO PREMIUM
   ============================================ */

.kofi-premium-notice {
    display: flex;
    align-items: center;
    gap: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #ffffff;
    padding: 30px;
    border-radius: 12px;
    margin: 20px 0;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
}

.notice-icon {
    font-size: 48px;
    flex-shrink: 0;
}

.notice-content {
    flex: 1;
}

.notice-content h3 {
    margin: 0 0 10px 0;
    color: #ffffff;
    font-size: 24px;
}

.notice-content p {
    margin: 0 0 20px 0;
    color: rgba(255, 255, 255, 0.9);
}

.notice-actions {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.notice-actions .button-primary,
.notice-actions .kofi-subscribe-btn {
    background: #ffffff;
    color: #667eea !important;
    padding: 12px 24px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
}

.notice-actions .button-primary:hover,
.notice-actions .kofi-subscribe-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.notice-actions .button-secondary {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff !important;
    padding: 12px 24px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.notice-subtext {
    width: 100%;
    margin: 10px 0 0 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

/* Badge de suscriptor */
.kofi-subscriber-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: linear-gradient(135deg, #ffd700 0%, #ffed4e 100%);
    color: #333;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(255, 215, 0, 0.3);
}

/* ============================================
   GUÍA PASO A PASO - [kofi_how_to_subscribe]
   ============================================ */

.kofi-how-to-subscribe {
    max-width: 1000px;
    margin: 40px auto;
    padding: 20px;
}

.how-to-title {
    text-align: center;
    font-size: 32px;
    color: #ffffff;
    margin-bottom: 40px;
    position: relative;
}

.how-to-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: linear-gradient(135deg, #ff5e5b 0%, #ff8f8c 100%);
    margin: 15px auto 0;
    border-radius: 2px;
}

/* Ya tiene premium */
.already-premium-notice {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    background: linear-gradient(135deg, #4caf50 0%, #66bb6a 100%);
    color: #fff;
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    font-size: 18px;
}

.already-premium-notice .premium-icon {
    font-size: 48px;
}

/* Contenedor de pasos */
.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

/* Tarjeta de paso */
.step-card {
    background: rgba(30, 30, 40, 0.95);
    border-radius: 16px;
    padding: 30px 25px;
    text-align: center;
    position: relative;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.step-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
    border-color: rgba(255, 255, 255, 0.2);
}

.step-card.step-highlight {
    border-color: #ff5e5b;
    background: linear-gradient(135deg, rgba(255, 94, 91, 0.15) 0%, rgba(30, 30, 40, 0.95) 100%);
}

/* Número de paso */
.step-number {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.step-highlight .step-number {
    background: linear-gradient(135deg, #ff5e5b 0%, #ff8f8c 100%);
    box-shadow: 0 4px 12px rgba(255, 94, 91, 0.4);
}

/* Icono del paso */
.step-icon {
    font-size: 48px;
    margin: 15px 0 20px;
}

/* Título y descripción del paso */
.step-card h3 {
    margin: 0 0 12px;
    font-size: 18px;
    color: #ffffff;
}

.step-card>p {
    margin: 0 0 20px;
    color: #b0b0b0;
    font-size: 14px;
    line-height: 1.6;
}

/* Botón de acción del paso */
.step-action-btn {
    display: inline-block;
    padding: 10px 20px;
    background: #667eea;
    color: #fff !important;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.step-action-btn:hover {
    background: #5a6fd6;
    transform: translateY(-2px);
}

/* Paso completado */
.step-complete {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: rgba(76, 175, 80, 0.2);
    color: #81c784;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
}

.step-complete span {
    font-size: 18px;
}

/* Caja del email */
.user-email-box {
    background: rgba(156, 39, 176, 0.2);
    padding: 12px 15px;
    border-radius: 8px;
    margin-top: 10px;
    border: 1px solid rgba(156, 39, 176, 0.3);
}

.user-email-box strong {
    display: block;
    font-size: 12px;
    color: #ce93d8;
    margin-bottom: 5px;
}

.user-email-box code {
    background: rgba(0, 0, 0, 0.3);
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 14px;
    color: #ffffff;
    display: block;
}

.step-note {
    color: #888 !important;
    font-size: 13px !important;
}

/* Botón de donar Ko-fi */
.kofi-donate-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    background: linear-gradient(135deg, #ff5e5b 0%, #ff8f8c 100%);
    color: #fff !important;
    text-decoration: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 94, 91, 0.3);
}

.kofi-donate-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 25px rgba(255, 94, 91, 0.4);
    color: #fff !important;
}

.kofi-btn-icon {
    font-size: 20px;
}

/* Resultado del paso */
.step-result {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: rgba(33, 150, 243, 0.15);
    padding: 15px;
    border-radius: 8px;
    color: #64b5f6;
    font-weight: 600;
    border: 1px solid rgba(33, 150, 243, 0.3);
}

.result-icon {
    font-size: 24px;
}

/* Nota importante */
.important-note {
    display: flex;
    gap: 20px;
    background: rgba(255, 152, 0, 0.15);
    padding: 25px;
    border-radius: 12px;
    border-left: 4px solid #ff9800;
    margin-bottom: 40px;
}

.note-icon {
    font-size: 32px;
    flex-shrink: 0;
}

.note-content strong {
    color: #ffb74d;
    font-size: 16px;
}

.note-content p {
    margin: 10px 0 0;
    color: #cccccc;
    line-height: 1.6;
}

/* FAQ */
.quick-faq {
    background: rgba(30, 30, 40, 0.95);
    padding: 30px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.quick-faq h3 {
    text-align: center;
    margin: 0 0 25px;
    color: #ffffff;
    font-size: 22px;
}

.faq-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 18px 22px;
    border-radius: 8px;
    margin-bottom: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.faq-item:last-child {
    margin-bottom: 0;
}

.faq-question {
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 8px;
    font-size: 15px;
}

.faq-question::before {
    content: '❓ ';
}

.faq-answer {
    color: #b0b0b0;
    font-size: 14px;
    line-height: 1.5;
    padding-left: 22px;
}

/* ============================================
   PÁGINA PREMIUM COMPLETA - [kofi_premium_page]
   ============================================ */

.kofi-premium-page {
    max-width: 1100px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.premium-header {
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border-radius: 20px;
    margin-bottom: 50px;
    position: relative;
    overflow: hidden;
}

.premium-header::before {
    content: '☕';
    position: absolute;
    font-size: 200px;
    opacity: 0.1;
    right: -20px;
    top: 50%;
    transform: translateY(-50%);
}

.premium-header h1 {
    margin: 0 0 15px;
    font-size: 42px;
    font-weight: 700;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    color: #ffffff !important;
}

.premium-subtitle {
    font-size: 18px;
    opacity: 0.95;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
    color: #ffffff;
}

/* Sección */
.premium-section {
    margin-bottom: 50px;
}

/* Separador */
.premium-divider {
    text-align: center;
    margin: 50px 0;
    position: relative;
}

.premium-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.premium-divider span {
    position: relative;
    background: transparent;
    padding: 0 20px;
    font-size: 32px;
}

/* CTA Final */
.premium-final-cta {
    text-align: center;
    padding: 50px 30px;
    background: rgba(30, 30, 40, 0.95);
    border-radius: 20px;
    border: 2px dashed rgba(255, 255, 255, 0.2);
}

.premium-final-cta h2 {
    margin: 0 0 25px;
    color: #ffffff;
    font-size: 28px;
}

/* ============================================
   ESTILOS PARA CAPÍTULOS BLOQUEADOS
   ============================================ */

body.kofi-premium-subscriber .premium-block {
    pointer-events: auto;
    opacity: 1;
}

body.kofi-premium-subscriber .content-blocked {
    display: none;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .kofi-premium-notice {
        flex-direction: column;
        text-align: center;
    }

    .benefits-list {
        grid-template-columns: 1fr;
    }

    .notice-actions {
        justify-content: center;
    }

    .subscription-active,
    .subscription-inactive {
        flex-direction: column;
        text-align: center;
        border-left: none;
        border-top: 4px solid;
        padding-left: 0;
        padding-top: 20px;
    }

    .steps-container {
        grid-template-columns: 1fr;
    }

    .step-card {
        padding: 35px 20px 25px;
    }

    .important-note {
        flex-direction: column;
        text-align: center;
    }

    .premium-header {
        padding: 40px 20px;
    }

    .premium-header h1 {
        font-size: 28px;
    }

    .premium-subtitle {
        font-size: 16px;
    }

    .how-to-title {
        font-size: 26px;
    }

    .premium-final-cta h2 {
        font-size: 22px;
    }
}

@media (max-width: 480px) {
    .kofi-donate-btn {
        padding: 12px 20px;
        font-size: 14px;
    }

    .step-icon {
        font-size: 36px;
    }

    .step-card h3 {
        font-size: 16px;
    }

    .kofi-subscribe-button {
        padding: 12px 20px;
        font-size: 16px;
    }
}

/* ============================================
   INTEGRACIÓN CON WP-MANGA-CHAPTER-COIN
   Cambia "🪙 10" por "Premium" en los badges
   ============================================ */

/* Estilo base para el badge de monedas premium */
.wp-manga-chapter.premium .coin {
    font-size: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-width: auto !important;
    width: auto !important;
    height: auto !important;
    padding: 6px 12px !important;
    border-radius: 15px !important;
    white-space: nowrap !important;
    line-height: 1 !important;
}

/* Ocultar el icono de monedas */
.wp-manga-chapter.premium .coin i,
.wp-manga-chapter.premium .coin .fas,
.wp-manga-chapter.premium .coin .fa-coins {
    display: none !important;
}

/* Mostrar "Premium" en su lugar */
.wp-manga-chapter.premium .coin::before {
    font-size: 12px !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
    display: inline-block !important;
}

/* Capítulos premium bloqueados (no comprados) */
.wp-manga-chapter.premium-block .coin {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%) !important;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.4) !important;
}

.wp-manga-chapter.premium-block .coin::before {
    content: "🔒 Premium" !important;
    color: #fff !important;
}

/* Capítulos premium desbloqueados (comprados o suscriptor) */
.wp-manga-chapter.premium:not(.premium-block) .coin {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4) !important;
}

.wp-manga-chapter.premium:not(.premium-block) .coin::before {
    content: "⭐ Premium" !important;
    color: #fff !important;
}

/* Badge para capítulos gratuitos */
.wp-manga-chapter.free-chap .coin.free {
    background: linear-gradient(135deg, #4caf50 0%, #66bb6a 100%) !important;
    color: #fff !important;
    padding: 6px 12px !important;
    border-radius: 15px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
}

/* ============================================
   MODAL DE PREMIUM CHAPTER MEJORADO
   ============================================ */

#frm-wp-manga-buy-coin .modal-content {
    background: linear-gradient(145deg, #1a1a2e 0%, #16213e 100%) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 20px !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5) !important;
    overflow: hidden;
}

#frm-wp-manga-buy-coin .modal-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    padding: 20px 25px !important;
}

#frm-wp-manga-buy-coin .modal-header .close {
    color: #fff !important;
    opacity: 0.7;
    font-size: 28px;
    text-shadow: none;
}

#frm-wp-manga-buy-coin .modal-header .close:hover {
    opacity: 1;
}

#frm-wp-manga-buy-coin .modal-body {
    padding: 30px 25px !important;
    text-align: center;
}

#frm-wp-manga-buy-coin .modal-body h3 {
    color: #fff !important;
    font-size: 28px !important;
    font-weight: 700 !important;
    margin-bottom: 20px !important;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Mensaje principal */
#frm-wp-manga-buy-coin .modal-body p {
    color: #e0e0e0 !important;
    font-size: 16px !important;
    line-height: 1.6 !important;
    margin-bottom: 25px !important;
}

/* Ocultar mensajes originales */
#frm-wp-manga-buy-coin .message-sufficient,
#frm-wp-manga-buy-coin .message-lack-of-coin {
    display: none !important;
}

/* Añadir mensaje personalizado */
#frm-wp-manga-buy-coin .modal-body::after {
    content: "⭐ Este capítulo es exclusivo para miembros Premium. \A Dona $5 en Ko-fi para obtener acceso ilimitado por 1 mes.";
    white-space: pre-line;
    display: block;
    color: #ffffff !important;
    font-size: 16px !important;
    line-height: 1.8 !important;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    margin-bottom: 20px;
}

#frm-wp-manga-buy-coin .modal-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
    padding: 20px 25px !important;
    background: rgba(0, 0, 0, 0.2) !important;
    justify-content: center !important;
}

/* Ocultar botón de comprar con monedas */
#frm-wp-manga-buy-coin .btn-agree {
    display: none !important;
}

/* Estilo del botón Cancel */
#frm-wp-manga-buy-coin .btn-cancel {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #fff !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    padding: 12px 30px !important;
    border-radius: 25px !important;
    font-weight: 600;
    transition: all 0.3s ease;
}

#frm-wp-manga-buy-coin .btn-cancel:hover {
    background: rgba(255, 255, 255, 0.2) !important;
}