/* Base Styles */
:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --accent-color: #f97316;
    --text-color: #1f2937;
    --light-text: #6b7280;
    --background-color: #ffffff;
    --light-background: #f9fafb;
    --border-color: #e5e7eb;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

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

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--light-background);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3, h4, h5, h6 {
    margin-bottom: 1rem;
    line-height: 1.2;
    font-weight: 700;
}

/* Spinner overlay (covers the entire page) */
.loader {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(255,255,255,0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

/* Hide by default */
.loader.hidden {
  display: none;
}

/* The spinning circle */
.spinner {
  border: 8px solid #f3f3f3;
  border-top: 8px solid #444;    /* dark segment */
  border-radius: 50%;
  width: 50px; height: 50px;
  animation: spin 1s linear infinite;
}

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


h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

h2 {
    font-size: 1.5rem;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
}

h3 {
    font-size: 1.25rem;
    margin-top: 1rem;
    margin-bottom: 0.75rem;
}

p {
    margin-bottom: 1rem;
}

ul, ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

li {
    margin-bottom: 0.5rem;
}

a {
    color: var(--primary-color);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Checkout Header */
.checkout-header {
    background-color: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 1rem 0;
}

.checkout-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h2 {
    margin: 0;
    color: var(--primary-color);
    font-weight: 700;
}

.checkout-steps {
    display: flex;
    gap: 1.5rem;
}

.step {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--light-text);
}

.step.active {
    color: var(--primary-color);
    font-weight: 600;
}

.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background-color: var(--light-background);
    border: 1px solid var(--border-color);
    font-size: 0.875rem;
}

.step.active .step-number {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Main Checkout Container */
.checkout-container {
    padding: 2rem 0 4rem;
}

.checkout-grid {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 2rem;
}

.checkout-subtitle {
    color: var(--light-text);
    margin-bottom: 2rem;
}

/* Form Styles */
.checkout-form-container {
    background-color: white;
    border-radius: 0.5rem;
    padding: 2rem;
    box-shadow: var(--box-shadow);
}

.form-section {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.form-section:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

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

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-group small {
    display: block;
    margin-top: 0.5rem;
    color: var(--light-text);
    font-size: 0.875rem;
}

/* Payment Methods */
.payment-methods {
    margin-bottom: 1.5rem;
}

.payment-method {
    position: relative;
    margin-bottom: 1rem;
}

.payment-method input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.payment-method label {
    display: flex;
    align-items: center;
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s;
}

.payment-method input[type="radio"]:checked + label {
    border-color: var(--primary-color);
    background-color: rgba(37, 99, 235, 0.05);
}

.radio-button {
    display: inline-block;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid var(--border-color);
    margin-right: 0.75rem;
    position: relative;
}

.payment-method input[type="radio"]:checked + label .radio-button {
    border-color: var(--primary-color);
}

.payment-method input[type="radio"]:checked + label .radio-button:after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--primary-color);
}

.payment-label {
    flex-grow: 1;
    font-weight: 500;
}

.card-icons {
    display: flex;
    gap: 0.5rem;
}

.card-icon {
    font-size: 0;
    width: 40px;
    height: 25px;
    background-color: #f3f4f6;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: transparent;
}

.hidden {
    display: none;
}

.paypal-info {
    padding: 1rem;
    background-color: #f0f9ff;
    border-radius: 0.375rem;
    border: 1px solid #bfdbfe;
    color: var(--primary-color);
}

/* Form Actions */
.form-actions {
    margin-top: 2rem;
    text-align: center;
}

.checkout-button {
    display: inline-block;
    background-color: var(--accent-color);
    color: white;
    font-weight: 700;
    font-size: 1.125rem;
    padding: 1rem 2rem;
    border-radius: 0.5rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 400px;
}

.checkout-button:hover {
    background-color: #ea580c;
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.secure-checkout {
    margin-top: 1rem;
    color: var(--light-text);
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.lock-icon {
    font-size: 1rem;
}

/* Order Summary */
.order-summary {
    position: sticky;
    top: 2rem;
}

.order-summary-content {
    background-color: white;
    border-radius: 0.5rem;
    padding: 1.5rem;
    box-shadow: var(--box-shadow);
}

.product-details {
    margin-bottom: 1.5rem;
}

.product-description {
    color: var(--light-text);
}

.price-breakdown {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.price-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.price-row.discount {
    color: var(--success-color);
    font-weight: 500;
}

.price-row.total {
    margin-top: 1rem;
    font-weight: 700;
    font-size: 1.125rem;
}

.original-price {
    text-decoration: line-through;
    color: var(--light-text);
}

.final-price {
    color: var(--accent-color);
    font-size: 1.25rem;
}

.guarantee-reminder {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background-color: #f0fdf4;
    border-radius: 0.375rem;
    margin-bottom: 1.5rem;
}

.guarantee-icon {
    width: 24px;
    height: 24px;
    background-color: var(--success-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.guarantee-text p {
    font-size: 0.875rem;
    margin-bottom: 0;
}

.what-you-get {
    margin-bottom: 1.5rem;
}

.benefits-list {
    list-style-type: none;
    padding-left: 0;
}

.benefits-list li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.5rem;
}

.benefits-list li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--success-color);
    font-weight: bold;
}

.testimonial {
    background-color: #f9fafb;
    border-radius: 0.375rem;
    padding: 1rem;
    font-style: italic;
}

.quote {
    margin-bottom: 0.5rem;
}

.author {
    text-align: right;
    font-weight: 500;
    font-style: normal;
}

/* Footer */
.checkout-footer {
    background-color: white;
    border-top: 1px solid var(--border-color);
    padding: 1.5rem 0;
    margin-top: 2rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
    color: var(--light-text);
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

/* Responsive Design */
@media (max-width: 992px) {
    .checkout-grid {
        grid-template-columns: 1fr;
    }
    
    .order-summary {
        position: static;
    }
}

@media (max-width: 768px) {
    .checkout-header .container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .checkout-steps {
        width: 100%;
        justify-content: space-between;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .checkout-form-container,
    .order-summary-content {
        padding: 1.25rem;
    }
    
    .step-name {
        display: none;
    }
}
