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

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.5;
    margin: 0;
    padding: 20px;
    background: #f8f9fa;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

header {
    text-align: center;
    margin-bottom: 30px;
}

header img {
    max-width: 200px;
    height: auto;
}

h1 {
    color: #12649E;
    margin: 20px 0 10px;
}

/* Form sections */
.form-section {
    display: none;
    margin-bottom: 0;
}

.form-section.active {
    display: block;
}

/* Form layout */
.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.form-col {
    flex: 1;
    min-width: 0;
}

.form-group {
    margin-bottom: 20px;
}

/* Name fields */
.name-fields {
    display: flex;
    flex-direction: row;
    gap: 20px;
    margin-bottom: 20px;
}

.name-field {
    flex: 1;
    min-width: 0;
}

/* Form elements */
label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    font-family: inherit;
}

input.compact-input {
    width: 100px;
    margin: 5px 0;
    padding: 5px;
    border-radius: 5px;
}

#cardNumber.compact-input,
#cardholderName.compact-input {
    width: 200px;
}

#paymentForm {
    background-color: lightgray;
    border-radius: 10px;
    padding: 20px;
}

#paymentForm label {
    margin-bottom: 0; /* Removed margin */
}

#expiryMonth,
#expiryYear {
    margin-top: 13px; /* Added margin */
}

#subscribeButton {
    margin-left: auto; /* Move button to the right */
    display: block; /* Make the button a block element */
    margin-left: auto; /* Move button to the right */
}

input.error {
    border-color: #dc3545;
    margin-bottom: 4px;
}

.validation-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 4px;
    min-height: 18px;
}

.form-group {
    position: relative;
}

/* Payment section */
.payment-section {
    margin-top: 20px;
}

.funding-intro {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

/* Payment options */
.payment-options-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.payment-options-list input[type="radio"] {
    display: none;
}

.payment-options-list label {
    display: block;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    margin: 0;
}

.payment-options-list label:hover {
    background: #f8f9fa;
}

/* Pricing blocks */
.pricing-blocks {
    display: flex;
    gap: 20px;
    margin: 20px 0;
}

.pricing-block {
    flex: 1;
    border: 2px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
    background: white;
}

.pricing-block:hover {
    border-color: #12649E;
    box-shadow: 0 2px 8px rgba(18, 100, 158, 0.1);
}

.pricing-block.best-value {
    border-color: #2ecc71;
}

.pricing-block input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.pricing-block:has(input[type="radio"]:checked) {
    background: #f8f9fa;
    border-color: #12649E;
    box-shadow: 0 4px 12px rgba(18, 100, 158, 0.15);
    transform: translateY(-2px);
}

.pricing-block.best-value:has(input[type="radio"]:checked) {
    border-color: #12649E;
}

.pricing-block .pricing-content {
    pointer-events: none;
}

.pricing-block h3 {
    color: #12649E;
    margin-top: 0;
    font-size: 1.25rem;
}

.pricing-block .price {
    font-size: 2.5rem;
    font-weight: 600;
    color: #12649E;
    margin: 15px 0;
}

.pricing-block .benefits {
    list-style: none;
    padding: 0;
    margin: 15px 0;
    text-align: left;
}

.pricing-block .benefits li {
    margin-bottom: 10px;
    padding-left: 25px;
    position: relative;
}

.pricing-block .benefits li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #2ecc71;
    font-weight: bold;
}

.pricing-block .savings {
    background: #2ecc71;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    display: inline-block;
    margin-top: 15px;
    font-weight: 500;
}

.pricing-block .note {
    color: #6c757d;
    font-size: 0.9rem;
    margin-top: 15px;
}

/* Switch for developing nation */
.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
    margin-right: 10px;
    vertical-align: middle;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #2ecc71;
}

input:checked + .slider:before {
    transform: translateX(26px);
}

/* Buttons */
.button-group {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 30px;
}

button {
    background: #12649E;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: background-color 0.2s;
}

button:hover {
    background: #0e4c77;
}

button[type="button"]:not([onclick*="Next"]) {
    background: #E0841F;
}

button[type="button"][onclick*="Next"] {
    background: #12649E;
}

button[type="button"]:not([onclick*="Next"]):hover {
    background: #c47319;
}

button[type="button"][onclick*="Next"]:hover {
    background: #0e4c77;
}

/* Payment content visibility */
.payment-option-content {
    display: none;
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }

    .name-fields {
        flex-direction: column;
        gap: 15px;
    }

    .form-row {
        flex-direction: column;
        gap: 15px;
    }

    .pricing-blocks {
        flex-direction: column;
    }

    .button-group {
        flex-direction: column;
    }

    button {
        width: 100%;
    }
}

/* Promo code section */
.promo-code-section {
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #ddd;
}

.promo-code-section h3 {
    color: #12649E;
    margin-top: 0;
    margin-bottom: 15px;
}

.promo-code-input {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.promo-code-input input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.promo-code-input button {
    padding: 10px 20px;
    white-space: nowrap;
}

#promoMessage {
    margin-top: 10px;
    font-size: 0.9rem;
}

#promoMessage.error-message {
    color: #dc3545;
}

#promoMessage.success-message {
    color: #28a745;
}

#promoMessage.info-message {
    color: #17a2b8;
}

.original-price {
    text-decoration: line-through;
    color: #6c757d;
    margin-right: 10px;
    font-size: 0.8em;
}

/* Payment Cards Styling */
.payment-cards {
    display: flex;
    gap: 15px;
    margin: 20px 0;
    justify-content: space-between;
}

.payment-card {
    padding: 20px 15px;
    border: 3px solid;
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    position: relative;
    display: flex;
    flex-direction: column;
}

/* Specific widths for each card type */
.member-card {
    flex: 0 0 30%;
}

.membership-card {
    flex: 0 0 35%;
}

.no-membership-card {
    flex: 0 0 30%;
}

.payment-card h3 {
    font-size: 18px;
    margin-bottom: auto;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-pricing {
    margin: 20px 0 15px 0;
    min-height: auto;
}

.pricing-item {
    margin: 10px 0;
    font-size: 16px;
}

.pricing-item strong {
    font-size: 20px;
    font-weight: 600;
}

.card-select-btn {
    width: 100%;
    padding: 12px 24px;
    border: none;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
}

/* Member Card - Orange/Brown */
.member-card {
    border-color: #D97706;
}

.member-card h3 {
    color: #92400E;
}

.member-card .card-select-btn {
    background-color: #D97706;
    color: white;
}

.member-card:hover {
    box-shadow: 0 4px 12px rgba(217, 119, 6, 0.3);
    transform: translateY(-2px);
}

.member-card.selected {
    background-color: #FEF3C7;
    border-color: #92400E;
}

/* Membership Card - Blue */
.membership-card {
    border-color: #2563EB;
}

.membership-card h3 {
    color: #1E40AF;
}

.membership-card .card-select-btn {
    background-color: #2563EB;
    color: white;
}

.membership-card:hover {
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
    transform: translateY(-2px);
}

.membership-card.selected {
    background-color: #DBEAFE;
    border-color: #1E40AF;
}

/* No Membership Card - Gray */
.no-membership-card {
    border-color: #6B7280;
}

.no-membership-card h3 {
    color: #374151;
}

.no-membership-card .card-select-btn {
    background-color: #6B7280;
    color: white;
}

.no-membership-card:hover {
    box-shadow: 0 4px 12px rgba(107, 114, 128, 0.3);
    transform: translateY(-2px);
}

.no-membership-card.selected {
    background-color: #F3F4F6;
    border-color: #374151;
}

/* Button hover effects */
.card-select-btn:hover {
    opacity: 0.9;
    transform: scale(1.02);
}

.payment-card.selected .card-select-btn {
    opacity: 0.8;
}

/* Responsive design for cards */
@media (max-width: 768px) {
    .payment-cards {
        flex-direction: column;
    }
    
    .payment-card {
        min-width: 100%;
    }
}