/* ==========================================
   CHECKOUT PAGE STYLES
   ========================================== */

/* Logo Loading Animation */
.logo-loader-container {
    position: relative;
    width: 250px;
    height: 250px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.loading-text {
    margin-top: 20px;
    color: #4b5563;
    font-size: 1.2rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 600;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

.checkout-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem;
}

.checkout-header {
    text-align: center;
    margin-bottom: 3rem;
}

.checkout-header h1 {
    color: #1a4d6f;
    margin-bottom: 2rem;
}

.checkout-steps {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    opacity: 0.4;
    transition: opacity 0.3s;
}

.step.active {
    opacity: 1;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #666;
}

.step.active .step-number {
    background: #ff6b35;
    color: white;
}

.step-label {
    font-size: 0.9rem;
    color: #666;
}

.checkout-content {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    padding: 2rem;
}

.checkout-step h2 {
    color: #1a4d6f;
    margin-bottom: 1.5rem;
}

/* Subscription Options */
.subscription-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.subscription-card {
    border: 3px solid #dee2e6;
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
}

.subscription-card:hover {
    border-color: #ff6b35;
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.2);
}

.subscription-card.selected {
    border-color: #ff6b35;
    background: #fff5f2;
}

.subscription-card.featured {
    border-color: #ffc107;
}

.badge-popular {
    position: absolute;
    top: -12px;
    right: 10px;
    background: #ffc107;
    color: #333;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
}

.subscription-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.subscription-price {
    font-size: 2rem;
    font-weight: bold;
    color: #ff6b35;
    margin: 1rem 0;
}

.subscription-duration {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.subscription-features {
    list-style: none;
    padding: 0;
    text-align: left;
}

.subscription-features li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
}

/* Form Styles */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #333;
}

.form-group small {
    display: block;
    margin-top: 0.25rem;
    color: #666;
    font-size: 0.85rem;
}

.form-input {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-input:focus {
    outline: none;
    border-color: #ff6b35;
}

/* Payment Options */
.payment-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin: 2rem 0;
}

.payment-card {
    border: 3px solid #dee2e6;
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.payment-card:hover {
    border-color: #ff6b35;
    transform: translateY(-4px);
}

.payment-card.selected {
    border-color: #ff6b35;
    background: #fff5f2;
}

.payment-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Order Summary */
.order-summary, .customer-summary {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid #dee2e6;
}

.summary-item.total {
    border-bottom: none;
    font-size: 1.2rem;
    color: #ff6b35;
}

/* Terms Section */
.terms-section {
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 8px;
    padding: 1.5rem;
    margin: 1.5rem 0;
}

.form-check {
    margin-bottom: 1rem;
}

.form-check label {
    margin-left: 0.5rem;
    line-height: 1.6;
}

.info-box {
    background: #e7f3ff;
    border-left: 4px solid #0066cc;
    padding: 1rem;
    border-radius: 4px;
    margin: 1.5rem 0;
}

/* Checkout Actions */
.checkout-actions {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid #dee2e6;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: bold;
}

/* Auth Tabs */
.auth-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid #dee2e6;
}

.tab-button {
    flex: 1;
    padding: 1rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-weight: 600;
    color: #666;
    transition: all 0.3s;
}

.tab-button:hover {
    color: #ff6b35;
}

.tab-button.active {
    color: #ff6b35;
    border-bottom-color: #ff6b35;
}

.auth-form {
    margin-top: 2rem;
}

.auth-success {
    text-align: center;
    padding: 3rem;
    background: #d4edda;
    border: 2px solid #28a745;
    border-radius: 12px;
}

.auth-success .success-icon {
    font-size: 4rem;
    color: #28a745;
    margin-bottom: 1rem;
}

.auth-success h2 {
    color: #155724;
    margin-bottom: 0.5rem;
}

.auth-success p {
    color: #155724;
}

/* Coupon Section */
.coupon-section {
    background: #f0f8ff;
    border: 2px solid #0066cc;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.coupon-section h3 {
    margin-bottom: 1rem;
    color: #0066cc;
}

.coupon-input-group {
    display: flex;
    gap: 0.5rem;
}

.coupon-applied {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #d4edda;
    border: 2px solid #28a745;
    border-radius: 8px;
    padding: 1rem;
}

.coupon-success {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.coupon-success .success-icon {
    width: 40px;
    height: 40px;
    background: #28a745;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
}

.coupon-success strong {
    color: #155724;
    display: block;
    margin-bottom: 0.25rem;
}

.coupon-success p {
    color: #155724;
    margin: 0;
    font-size: 0.9rem;
}

.btn-link {
    background: none;
    border: none;
    color: #dc3545;
    text-decoration: underline;
    cursor: pointer;
    font-weight: 600;
}

.btn-link:hover {
    color: #c82333;
}

.summary-item.discount {
    color: #28a745;
    font-weight: 600;
}

.summary-item.highlight-free {
    background: #d4edda;
    border: 2px solid #28a745;
    border-radius: 8px;
    padding: 1rem;
    margin: 0.5rem 0;
    font-size: 1.1rem;
}

.summary-item.highlight-free span {
    color: #155724;
}

.summary-item.highlight-free strong {
    color: #0f4c1e;
}

/* Logo Animation Styles */
@keyframes logoSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.logo-loader-container {
    width: 120px;
    height: 120px;
    margin-bottom: 1.5rem;
    animation: logoSpin 2s linear infinite;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.logo-loader-container canvas {
    width: 100%;
    height: 100%;
}

.loading-text {
    font-size: 1.2rem;
    color: #666;
    text-align: center;
    margin-top: 0.5rem;
    animation: fadeIn 1s ease-in-out infinite;
}

@keyframes fadeIn {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

/* Alert Styles */
.alert {
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.alert-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .checkout-steps {
        gap: 0.5rem;
    }

    .step-label {
        display: none;
    }

    .subscription-options,
    .payment-options {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }
}
