/* Checkout Payment Gateway - Design Premium */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
}

.checkout-pg-container {
    max-width: 750px;
    margin: 2rem auto;
    padding: 0;
    font-family: 'Poppins', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
    overflow: hidden;
}

/* Trust Badges - Premium */
.checkout-pg-trust-badges {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1rem;
    padding: 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin-bottom: 0;
}

.trust-badge {
    padding: 1rem;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    text-align: center;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.trust-badge .icon {
    font-size: 1.75rem;
}

/* Progress Indicator - Premium */
.checkout-pg-progress {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 2rem;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
}

.step-number {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #e9ecef;
    color: #6c757d;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.progress-step.active .step-number {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transform: scale(1.05);
}

.progress-step.completed .step-number {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.step-label {
    font-size: 0.85rem;
    color: #6c757d;
    font-weight: 500;
    text-align: center;
}

.progress-step.active .step-label,
.progress-step.completed .step-label {
    color: #2d9b6d;
}

.progress-line {
    flex: 1;
    height: 3px;
    background: #e9ecef;
    margin: 0 1rem;
    transition: all 0.3s ease;
}

.progress-step.completed ~ .progress-line {
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
}

/* Form Styles */
.checkout-pg-form {
    background: white;
    padding: 2.5rem;
    border-radius: 0;
}

.checkout-pg-step {
    display: none;
    animation: fadeIn 0.3s ease;
}

.checkout-pg-step.active {
    display: block;
}

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

.checkout-pg-step h2 {
    font-size: 1.85rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.75rem;
}

.step-description {
    color: #6c757d;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

/* Form Groups */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.form-group .required {
    color: #dc3545;
}

.form-group input {
    width: 100%;
    padding: 0.875rem;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.2s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #2d9b6d;
    box-shadow: 0 0 0 3px rgba(45, 155, 109, 0.1);
}

.form-group input.error {
    border-color: #dc3545;
}

.error-message {
    display: block;
    color: #dc3545;
    font-size: 0.85rem;
    margin-top: 0.375rem;
}

.loading-indicator {
    display: inline-block;
    color: #2d9b6d;
    font-size: 0.85rem;
    margin-top: 0.375rem;
    font-weight: 500;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.6;
    }
    50% {
        opacity: 1;
    }
}

/* Form Row */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* Payment Methods */
.payment-methods {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin: 2rem 0;
}

.payment-option {
    position: relative;
    cursor: pointer;
}

.payment-option input {
    display: none;
}

.payment-content {
    padding: 1.75rem;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: #f8f9fa;
}

.payment-option input:checked + .payment-content {
    border-color: #667eea;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.15);
    transform: translateY(-2px);
}

.payment-option:hover .payment-content {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.1);
}

.payment-icon {
    font-size: 2rem;
}

.payment-info {
    flex: 1;
}

.payment-name {
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.25rem;
}

.payment-badge {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.35rem 0.85rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Order Summary */
.order-summary {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin: 2rem 0;
}

.order-summary h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #1a1a1a;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e9ecef;
    font-size: 0.95rem;
}

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

.summary-row.total {
    border-top: 2px solid #2d9b6d;
    border-bottom: none;
    padding-top: 1rem;
    font-weight: 700;
    color: #2d9b6d;
    font-size: 1.1rem;
}

/* Form Actions */
.form-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 2rem;
}

.btn {
    padding: 0.875rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: inherit;
}

.btn-next,
.btn-submit {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.btn-next:hover,
.btn-submit:hover {
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
    transform: translateY(-2px);
}

.btn-back {
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
    font-weight: 700;
}

.btn-back:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    border-color: #764ba2;
}

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

/* Footer */
.checkout-pg-footer {
    margin-top: 2rem;
    padding: 1.5rem 2.5rem;
    border-top: 1px solid #e9ecef;
    text-align: center;
    font-size: 0.85rem;
    color: #6c757d;
    background: #f8f9fa;
}

.checkout-pg-footer p {
    margin: 0.5rem 0;
}

/* PIX Modal Popup */
.pix-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.pix-modal-overlay.active {
    display: flex;
}

.pix-modal {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
    animation: slideUp 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: center;
}

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

.pix-modal h2 {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1.5rem;
}

.pix-qr-code {
    margin: 2rem 0;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pix-qr-code img {
    max-width: 280px;
    width: 100%;
    height: auto;
}

.pix-timer {
    font-size: 1.25rem;
    font-weight: 700;
    color: #667eea;
    margin: 1.5rem 0;
    font-family: 'Courier New', monospace;
}

.pix-code-box {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 1rem;
    margin: 1.5rem 0;
    display: flex;
    gap: 0.75rem;
}

.pix-code-box input {
    flex: 1;
    border: none;
    background: transparent;
    font-size: 0.85rem;
    font-family: 'Courier New', monospace;
    color: #333;
    word-break: break-all;
}

.pix-code-box input:focus {
    outline: none;
}

.btn-copy-pix {
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn-copy-pix:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
}

.btn-copy-pix:active {
    transform: scale(0.98);
}

.pix-info {
    color: #6c757d;
    font-size: 0.9rem;
    margin: 1.5rem 0 0 0;
    line-height: 1.5;
}

.pix-warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    margin-top: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
    .checkout-pg-container {
        padding: 1rem;
    }
    
    .checkout-pg-form {
        padding: 1.5rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .payment-methods {
        grid-template-columns: 1fr;
    }
    
    .form-actions {
        grid-template-columns: 1fr;
    }
    
    .checkout-pg-progress {
        gap: 0.5rem;
    }
    
    .progress-line {
        margin: 0 0.5rem;
    }
    
    .step-label {
        font-size: 0.75rem;
    }
    
    .checkout-pg-step h2 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .checkout-pg-container {
        padding: 0.5rem;
    }
    
    .checkout-pg-form {
        padding: 1rem;
    }
    
    .checkout-pg-progress {
        flex-wrap: wrap;
        gap: 0.25rem;
    }
    
    .progress-step {
        flex: 0 0 calc(33.333% - 0.25rem);
    }
    
    .progress-line {
        display: none;
    }
    
    .step-number {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

/* Product Summary */
.product-summary {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.product-item {
    display: flex;
    gap: 1rem;
    align-items: center;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e9ecef;
    margin-bottom: 1.5rem;
}

.product-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.product-details {
    flex: 1;
}

.product-name {
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 0.25rem;
    font-size: 0.95rem;
}

.product-qty {
    font-size: 0.85rem;
    color: #6c757d;
}

.product-price {
    font-weight: 700;
    color: #667eea;
    font-size: 1.1rem;
}

.shipping-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.shipping-label {
    font-weight: 600;
    color: #1a1a1a;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.shipping-label::before {
    content: '🚚';
    font-size: 1.25rem;
}

.shipping-price {
    font-weight: 700;
    color: #28a745;
    font-size: 1rem;
}



.btn-already-paid {
    width: 100%;
    padding: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-already-paid:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
}

.btn-already-paid:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Success Page */
.success-page {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 2rem;
    animation: fadeIn 0.3s ease;
}

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

.success-container {
    background: white;
    border-radius: 20px;
    padding: 3rem 2rem;
    max-width: 600px;
    width: 100%;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    text-align: center;
    animation: slideUp 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.success-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
    margin: 0 auto 1.5rem;
    box-shadow: 0 8px 24px rgba(40, 167, 69, 0.3);
}

.success-container h1 {
    font-size: 2rem;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
    font-weight: 800;
}

.success-subtitle {
    font-size: 1rem;
    color: #6c757d;
    margin-bottom: 2rem;
}

.order-details {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    text-align: left;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e9ecef;
}

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

.detail-label {
    color: #6c757d;
    font-weight: 600;
}

.detail-value {
    color: #1a1a1a;
    font-weight: 700;
    font-family: 'Courier New', monospace;
}

.status-confirmed {
    color: #28a745;
}

.success-message {
    background: #e7f5f0;
    border: 1px solid #b8e6dd;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    text-align: left;
}

.success-message h3 {
    color: #1a1a1a;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.success-message p {
    color: #333;
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.success-message ul {
    margin-left: 1.5rem;
    color: #333;
}

.success-message li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.success-footer {
    color: #6c757d;
    font-size: 0.95rem;
}

.success-footer p {
    margin-bottom: 0.5rem;
}

/* Responsive */
@media (max-width: 768px) {
    .success-container {
        padding: 2rem 1.5rem;
    }
    
    .success-container h1 {
        font-size: 1.5rem;
    }
    
    .pix-benefits {
        flex-direction: column;
    }
}


/* PIX Logo Official */
.pix-logo-official {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #1F71B8 0%, #0D47A1 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 900;
    color: white;
    margin: 0 auto 1.5rem;
    box-shadow: 0 8px 24px rgba(31, 113, 184, 0.3);
    letter-spacing: 2px;
}

.pix-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.pix-header h2 {
    font-size: 1.5rem;
    color: #1a1a1a;
    margin-top: 0.5rem;
    margin-bottom: 0.25rem;
}

.pix-tagline {
    font-size: 0.9rem;
    color: #6c757d;
    margin: 0;
}

.pix-simple-instructions {
    background: #f0f7ff;
    border: 2px solid #1F71B8;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    color: #333;
    line-height: 1.8;
}

.pix-simple-instructions p {
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
}

.pix-simple-instructions p:last-child {
    margin-bottom: 0;
}

.pix-simple-instructions strong {
    color: #1F71B8;
    font-weight: 700;
    margin-right: 0.75rem;
    min-width: 1.5rem;
}

.btn-already-paid {
    width: 100%;
    padding: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-already-paid:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
}

.btn-already-paid:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}
