/* ==========================================================================
   WoWPyPoints Commerce - Modern Dynamic Styles
   ========================================================================== */

.wpcommerce-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px 20px 60px;
}

/* --- Header --- */
.wpcommerce-header {
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

.wpcommerce-header h1 {
    font-size: 2.6em;
    margin: 0 0 8px;
    font-weight: 800;
    letter-spacing: 1px;
}

.wpcommerce-glow {
    background: linear-gradient(135deg, #f0c040, #e67e22, #f0c040);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: wpTextShine 3s ease-in-out infinite;
}

@keyframes wpTextShine {
    0%, 100% { background-position: 0% center; }
    50% { background-position: 100% center; }
}

.wpcommerce-header > p {
    font-size: 1.1em;
    color: #888;
    margin: 0 0 20px;
}

.wpcommerce-balance {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    background: rgba(240, 192, 64, 0.1);
    border: 1px solid rgba(240, 192, 64, 0.25);
    border-radius: 50px;
    font-size: 0.95em;
    animation: wpBalanceFade 0.8s ease-out;
}

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

.wp-balance-icon { font-size: 1.2em; }
.wp-balance-label { color: #aaa; }
.wp-balance-amount { color: #f0c040; font-weight: bold; }

/* --- Plans Grid --- */
.wpcommerce-plans {
    display: flex;
    gap: 30px;
    justify-content: center;
    flex-wrap: wrap;
    perspective: 1200px;
}

/* --- Card --- */
.wpcommerce-card {
    width: 310px;
    background: linear-gradient(160deg, #1a1a2e 0%, #16213e 50%, #0f1629 100%);
    border: 1px solid rgba(42, 42, 74, 0.6);
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    animation: wpCardIn 0.6s ease-out backwards;
    cursor: default;
}

.wpcommerce-card:nth-child(1) { animation-delay: 0.1s; }
.wpcommerce-card:nth-child(2) { animation-delay: 0.2s; }
.wpcommerce-card:nth-child(3) { animation-delay: 0.3s; }

@keyframes wpCardIn {
    from { opacity: 0; transform: translateY(40px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.wpcommerce-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 1px;
    background: linear-gradient(160deg, transparent 40%, rgba(240, 192, 64, 0.15) 100%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.wpcommerce-card:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: rgba(240, 192, 64, 0.3);
}

.wpcommerce-card-featured {
    border-color: rgba(240, 192, 64, 0.4);
    box-shadow: 0 0 30px rgba(240, 192, 64, 0.1), 0 8px 32px rgba(0, 0, 0, 0.3);
    transform: scale(1.06);
    z-index: 2;
}

.wpcommerce-card-featured:hover {
    box-shadow: 0 0 50px rgba(240, 192, 64, 0.2), 0 12px 48px rgba(0, 0, 0, 0.4);
    transform: scale(1.06) translateY(-8px);
}

.wpcommerce-card-glow {
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle at 30% 20%, rgba(240, 192, 64, 0.06), transparent 60%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.6s;
}

.wpcommerce-card:hover .wpcommerce-card-glow { opacity: 1; }

/* --- Badge --- */
.wpcommerce-badge {
    position: absolute;
    top: 18px; right: -32px;
    background: linear-gradient(135deg, #f0c040, #e67e22);
    color: #1a1a2e;
    padding: 4px 36px;
    font-size: 0.7em;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    transform: rotate(45deg);
    z-index: 3;
    box-shadow: 0 2px 10px rgba(240, 192, 64, 0.3);
}

/* --- Card Header --- */
.wpcommerce-card-header {
    text-align: center;
    padding: 30px 20px 15px;
    position: relative;
}

.wpcommerce-card-header h2 {
    font-size: 1em;
    color: #666;
    margin: 0 0 15px;
    text-transform: uppercase;
    letter-spacing: 3px;
    font-weight: 600;
}

.wpcommerce-wp-amount {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 4px;
}

.wpcommerce-number {
    font-size: 3.2em;
    font-weight: 800;
    color: #f0c040;
    line-height: 1;
    letter-spacing: -1px;
}

.wpcommerce-unit {
    font-size: 1.1em;
    color: #f0c040;
    font-weight: 600;
    opacity: 0.7;
}

.wpcommerce-price-label {
    margin-top: 8px;
    font-size: 0.95em;
    color: #888;
}

/* --- Card Body --- */
.wpcommerce-card-body {
    padding: 15px 25px;
}

.wpcommerce-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.wpcommerce-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    color: #bbb;
    font-size: 0.92em;
    border-bottom: 1px solid rgba(42, 42, 74, 0.4);
}

.wpcommerce-features li:last-child { border-bottom: none; }

.wpcommerce-features li i {
    color: #f0c040;
    font-size: 1.1em;
    width: 20px;
    text-align: center;
}

.wpcommerce-features li strong { color: #fff; }

/* --- Card Footer --- */
.wpcommerce-card-footer {
    padding: 15px 20px 25px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* --- Payment Method Buttons --- */
.wpcommerce-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 16px;
    font-weight: 700;
    font-size: 0.9em;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    overflow: hidden;
    color: #fff;
}

.wpcommerce-btn:hover { transform: scale(1.02); }
.wpcommerce-btn:active { transform: scale(0.97); }

.wpcommerce-btn-icon {
    font-size: 1.1em;
    display: flex;
    align-items: center;
}

/* Pagopar */
.wpcommerce-pagopar-btn {
    background: linear-gradient(135deg, #f0c040, #d4a830);
    color: #1a1a2e;
}

.wpcommerce-pagopar-btn:hover {
    background: linear-gradient(135deg, #ffd650, #e0b840);
    box-shadow: 0 4px 20px rgba(240, 192, 64, 0.4);
}

/* Offline */
.wpcommerce-offline-btn {
    background: linear-gradient(135deg, #28a745, #1e7e34);
}

.wpcommerce-offline-btn:hover {
    background: linear-gradient(135deg, #34ce57, #28a745);
    box-shadow: 0 4px 20px rgba(40, 167, 69, 0.4);
}

/* PayPal */
.wpcommerce-paypal-btn {
    background: linear-gradient(135deg, #0070ba, #003087);
}

.wpcommerce-paypal-btn:hover {
    background: linear-gradient(135deg, #0099e8, #0070ba);
    box-shadow: 0 4px 20px rgba(0, 112, 186, 0.4);
}

/* --- Overlay --- */
.wpcommerce-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(10, 11, 16, 0.92);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
    animation: wpOverlayIn 0.3s ease-out;
}

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

.wpcommerce-overlay-content {
    text-align: center;
    animation: wpOverlayContent 0.5s ease-out;
}

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

.wpcommerce-overlay-content h3 { color: #f0c040; font-size: 1.4em; margin: 0 0 8px; }
.wpcommerce-overlay-content p { color: #888; font-size: 0.95em; margin: 0; }

/* Spinner */
.wpcommerce-spinner {
    width: 60px; height: 60px;
    margin: 0 auto 20px;
    animation: wpSpinRotate 2s linear infinite;
}

.wpcommerce-spinner svg { width: 100%; height: 100%; }

.wpcommerce-spinner-path {
    stroke: #f0c040;
    stroke-dasharray: 90 150;
    stroke-linecap: round;
    animation: wpSpinDash 1.5s ease-in-out infinite;
}

@keyframes wpSpinRotate { 100% { transform: rotate(360deg); } }

@keyframes wpSpinDash {
    0% { stroke-dasharray: 1 250; stroke-dashoffset: 0; }
    50% { stroke-dasharray: 120 250; stroke-dashoffset: -35; }
    100% { stroke-dasharray: 120 250; stroke-dashoffset: -250; }
}

/* --- SweetAlert --- */
.wpcommerce-swal-content {
    text-align: center;
    padding: 10px 0;
}

.wpcommerce-swal-icon {
    font-size: 3em;
    margin-bottom: 10px;
    animation: wpSwalBounce 1s ease infinite;
}

@keyframes wpSwalBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

.wpcommerce-swal-amount {
    font-size: 2em;
    font-weight: 800;
    color: #f0c040;
}

.wpcommerce-swal-price {
    font-size: 1.1em;
    color: #aaa;
    margin-top: 4px;
}

.wpcommerce-swal-loading {
    text-align: center;
    padding: 15px 0;
}

.wpcommerce-swal-spinner {
    width: 50px; height: 50px;
    animation: wpSpinRotate 2s linear infinite;
}

.wpcommerce-swal-loading p { color: #aaa; margin-top: 12px; }

/* --- Modal (Offline details) --- */
.wpcommerce-modal {
    display: none;
    position: fixed;
    z-index: 99998;
    left: 0; top: 0;
    width: 100%; height: 100%;
    background: rgba(10, 11, 16, 0.92);
    backdrop-filter: blur(8px);
    overflow: auto;
    animation: wpOverlayIn 0.3s ease-out;
}

.wpcommerce-modal-content {
    background: linear-gradient(160deg, #1a1a2e 0%, #16213e 50%, #0f1629 100%);
    margin: 60px auto;
    padding: 30px;
    border: 1px solid rgba(240, 192, 64, 0.2);
    border-radius: 20px;
    max-width: 520px;
    position: relative;
    animation: wpCardIn 0.4s ease-out;
    color: #f0f0f2;
}

.wpcommerce-modal-close {
    position: absolute;
    top: 15px; right: 20px;
    font-size: 1.8em;
    color: #888;
    cursor: pointer;
    transition: color 0.2s;
}

.wpcommerce-modal-close:hover { color: #fff; }

.wpcommerce-offline-details {
    background: rgba(255,255,255,0.03);
    border-radius: 12px;
    padding: 20px;
}

.wpcommerce-offline-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(42, 42, 74, 0.4);
}

.wpcommerce-offline-row:last-child { border-bottom: none; }

.wpcommerce-offline-label {
    color: #888;
    font-size: 0.9em;
    min-width: 120px;
}

.wpcommerce-offline-value {
    color: #f0f0f2;
    text-align: right;
    word-break: break-all;
}

.wpcommerce-copy-btn {
    background: rgba(240, 192, 64, 0.15);
    color: #f0c040;
    border: 1px solid rgba(240, 192, 64, 0.3);
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 0.8em;
    cursor: pointer;
    transition: all 0.2s;
}

.wpcommerce-copy-btn:hover {
    background: rgba(240, 192, 64, 0.25);
}

/* --- Result pages --- */
.wpcommerce-result {
    text-align: center;
    padding: 80px 20px;
    max-width: 500px;
    margin: 0 auto;
    animation: wpResultIn 0.6s ease-out;
}

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

.wpcommerce-result-icon { font-size: 5em; margin-bottom: 20px; }

.wpcommerce-result-icon.success {
    color: #28a745;
    animation: wpSuccessPulse 2s ease-in-out infinite;
}

@keyframes wpSuccessPulse {
    0%, 100% { transform: scale(1); filter: drop-shadow(0 0 10px rgba(40, 167, 69, 0.3)); }
    50% { transform: scale(1.1); filter: drop-shadow(0 0 25px rgba(40, 167, 69, 0.5)); }
}

.wpcommerce-result-icon.error { color: #dc3545; }

.wpcommerce-result h1 {
    font-size: 2em;
    color: #f0c040;
    margin-bottom: 15px;
}

.wpcommerce-result p {
    color: #888;
    margin-bottom: 30px;
    line-height: 1.7;
    font-size: 1.05em;
}

/* --- Orders Table --- */
.wpcommerce-orders-table-wrap {
    overflow-x: auto;
}

.wpcommerce-orders-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9em;
}

.wpcommerce-orders-table th,
.wpcommerce-orders-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid rgba(42, 42, 74, 0.4);
}

.wpcommerce-orders-table th {
    color: #888;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.8em;
    letter-spacing: 1px;
}

.wpcommerce-orders-table td { color: #ddd; }

.wpcommerce-status {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 600;
}

.wpcommerce-status.pendiente { background: rgba(255, 193, 7, 0.15); color: #ffc107; }
.wpcommerce-status.pagado { background: rgba(40, 167, 69, 0.15); color: #28a745; }
.wpcommerce-status.fallido { background: rgba(220, 53, 69, 0.15); color: #dc3545; }

.wpcommerce-back-link {
    display: inline-block;
    color: #f0c040;
    text-decoration: none;
    margin-top: 10px;
    font-size: 0.95em;
}

.wpcommerce-back-link:hover { text-decoration: underline; }

/* --- Responsive --- */
@media (max-width: 1100px) {
    .wpcommerce-card { width: 280px; }
    .wpcommerce-number { font-size: 2.6em; }
}

@media (max-width: 768px) {
    .wpcommerce-header h1 { font-size: 1.8em; }
    .wpcommerce-card { width: 100%; max-width: 380px; }
    .wpcommerce-card-featured { transform: none; }
    .wpcommerce-card-featured:hover { transform: translateY(-8px); }
    .wpcommerce-plans { gap: 20px; }
}

@media (max-width: 480px) {
    .wpcommerce-container { padding: 20px 15px 40px; }
    .wpcommerce-number { font-size: 2.2em; }
}
