/**
 * NGC Gift Card Form Styles (v5.0)
 */

.ngc-gift-card-wrapper {
    max-width: 640px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Error messages */
.ngc-form-errors {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 8px;
    padding: 15px 20px;
    margin-bottom: 20px;
    color: #991b1b;
}
.ngc-form-errors ul {
    margin: 0; padding: 0 0 0 18px;
}
.ngc-form-errors li {
    margin: 4px 0;
    font-size: 14px;
}

/* Amount Section */
.amount-section {
    margin-bottom: 25px;
}
.amount-label {
    display: block;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #1a1a1a;
}
.amount-input-container {
    display: flex;
    align-items: center;
    border: 2px solid #d1d5db;
    border-radius: 8px;
    overflow: hidden;
    transition: border-color 0.2s;
}
.amount-input-container:focus-within {
    border-color: #2271b1;
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.15);
}
.currency-symbol {
    padding: 12px 15px;
    background: #f3f4f6;
    font-size: 18px;
    font-weight: 600;
    color: #4b5563;
    border-right: 2px solid #d1d5db;
}
.amount-input {
    flex: 1;
    border: none !important;
    outline: none !important;
    padding: 12px 15px;
    font-size: 18px;
    box-shadow: none !important;
    -moz-appearance: textfield;
}
.amount-input::-webkit-inner-spin-button,
.amount-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Info Sections */
.info-section {
    margin-bottom: 25px;
}
.section-heading {
    font-size: 16px;
    font-weight: 600;
    color: #374151;
    margin: 0 0 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e5e7eb;
}
.info-container {
    display: grid;
    gap: 15px;
}

/* Form Rows */
.form-row {
    margin-bottom: 15px;
}
.form-row label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 6px;
}
.form-row input[type="text"],
.form-row input[type="email"],
.form-row input[type="number"],
.form-row select,
.form-row textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 15px;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
    border-color: #2271b1;
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.15);
    outline: none;
}
.form-row input.error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}
.form-row input.valid {
    border-color: #22c55e;
}
.field-hint {
    display: block;
    font-size: 12px;
    color: #6b7280;
    margin-top: 4px;
}

/* Delivery Options */
.delivery-options {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 15px 20px;
    margin: 0 0 25px;
}
.delivery-options legend {
    font-size: 14px;
    font-weight: 600;
    color: #374151;
    padding: 0 8px;
}
.delivery-option {
    margin: 10px 0;
}
.delivery-option label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    color: #4b5563;
    cursor: pointer;
    line-height: 1.5;
}
.delivery-option input[type="radio"] {
    margin-top: 4px;
    flex-shrink: 0;
}

/* Design Carousel */
.email-design-section {
    background: #f9fafb;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
}
.design-carousel-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 10px 0;
}
.design-carousel {
    flex: 1;
    overflow: hidden;
}
.design-carousel-track {
    display: flex;
    gap: 12px;
    transition: transform 0.3s ease-in-out;
}
.design-option {
    flex: 0 0 140px;
    text-align: center;
}
.design-option input[type="radio"] {
    display: none;
}
.design-option label {
    display: block;
    cursor: pointer;
    border: 3px solid transparent;
    border-radius: 8px;
    overflow: hidden;
    transition: border-color 0.2s, transform 0.2s;
}
.design-option input:checked + label {
    border-color: #2271b1;
    transform: scale(1.02);
    box-shadow: 0 2px 8px rgba(34, 113, 177, 0.25);
}
.design-option label:hover {
    border-color: #93c5fd;
}
.design-option img {
    width: 100%;
    height: auto;
    display: block;
}
.design-name {
    display: block;
    font-size: 12px;
    padding: 6px 4px;
    color: #4b5563;
    background: #fff;
}
.carousel-nav {
    width: 36px;
    height: 36px;
    border: 1px solid #d1d5db;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s;
}
.carousel-nav:hover {
    background: #f3f4f6;
}

/* Terms */
.terms-checkbox {
    margin: 20px 0;
}
.terms-checkbox label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 13px;
    color: #4b5563;
    cursor: pointer;
    line-height: 1.5;
}
.terms-checkbox input {
    margin-top: 3px;
    flex-shrink: 0;
}

/* Submit Button */
.submit-button {
    display: block;
    width: 100%;
    padding: 14px 30px;
    background: #2271b1;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}
.submit-button:hover {
    background: #1a5a8e;
}
.submit-button:active {
    transform: scale(0.98);
}
.submit-button:disabled {
    background: #9ca3af;
    cursor: not-allowed;
}

/* Payment Step */
.payment-processing {
    text-align: center;
    padding: 30px 0;
}
.ngc-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #e5e7eb;
    border-top-color: #2271b1;
    border-radius: 50%;
    animation: ngc-spin 0.8s linear infinite;
    margin-bottom: 15px;
}
@keyframes ngc-spin {
    to { transform: rotate(360deg); }
}
#ngc-payment-status {
    font-size: 16px;
    color: #4b5563;
}
.paypal-fallback-message {
    text-align: center;
    font-size: 15px;
    color: #6b7280;
    margin-bottom: 15px;
}
#ngc-paypal-buttons {
    max-width: 400px;
    margin: 0 auto;
}

/* Success Step */
.success-message {
    text-align: center;
    padding: 40px 20px;
}
.success-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #22c55e;
    color: #fff;
    font-size: 30px;
    line-height: 60px;
    margin: 0 auto 15px;
}
.success-message h3 {
    color: #166534;
    font-size: 22px;
    margin: 0 0 10px;
}
.success-message p {
    color: #4b5563;
    font-size: 16px;
    margin: 0 0 20px;
}
.download-button {
    display: inline-block;
    padding: 12px 30px;
    background: #2271b1;
    color: #fff !important;
    text-decoration: none !important;
    border-radius: 6px;
    font-weight: 600;
    font-size: 16px;
    transition: background 0.2s;
}
.download-button:hover {
    background: #1a5a8e;
}

/* Required indicator */
.required-indicator {
    color: #ef4444;
    font-weight: 600;
}

/* Mobile responsive */
@media (max-width: 600px) {
    .ngc-gift-card-wrapper {
        padding: 10px;
    }
    .amount-input {
        font-size: 16px;
    }
    .design-option {
        flex: 0 0 110px;
    }
}
