/* Reset and Variables */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #0b5b9e; /* Trust Blue */
    --primary-dark: #074275;
    --success-color: #27ae60;
    --bg-color: #f4f7f6;
    --text-color: #2c3e50;
    --light-text: #7f8c8d;
    --white: #ffffff;
    --border-color: #e0e6ed;
    --shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

body {
    font-family: 'Tajawal', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

/* Main Container */
.quiz-container {
    background: var(--white);
    width: 100%;
    max-width: 600px;
    border-radius: 16px;
    box-shadow: var(--shadow);
    padding: 40px;
    position: relative;
    overflow: hidden;
}

/* Progress Bar */
.progress-container {
    width: 100%;
    background-color: var(--border-color);
    height: 8px;
    border-radius: 4px;
    margin-bottom: 30px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background-color: var(--primary-color);
    width: 0%;
    transition: width 0.4s ease;
}

/* Steps */
.step {
    display: none;
    animation: fadeIn 0.5s;
    text-align: center;
}

.step.active {
    display: block;
}

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

/* Typography */
h1, h2 {
    color: var(--primary-dark);
    margin-bottom: 15px;
    line-height: 1.4;
}

h1 { font-size: 24px; font-weight: 800; }
h2 { font-size: 20px; font-weight: 700; }
p { font-size: 16px; color: var(--light-text); margin-bottom: 25px; line-height: 1.6; }

/* Badges */
.badge {
    display: inline-block;
    background: #e8f4fd;
    color: var(--primary-color);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 20px;
}

.secure-badge {
    margin-top: 25px;
    font-size: 13px;
    color: var(--light-text);
}

/* Buttons */
.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 16px 24px;
    width: 100%;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    font-family: 'Tajawal', sans-serif;
}

.btn-primary:hover {
    background-color: var(--primary-dark);
}

.options {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.option-btn {
    background-color: var(--white);
    border: 2px solid var(--border-color);
    color: var(--text-color);
    padding: 16px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Tajawal', sans-serif;
}

.option-btn:hover {
    border-color: var(--primary-color);
    background-color: #f8fbff;
}

.highlight-btn {
    border-color: var(--success-color);
    color: var(--success-color);
    font-weight: 700;
}
.highlight-btn:hover {
    background-color: #f0fdf4;
}

.disqualifier {
    border-color: #ffcccc;
    color: #cc0000;
}
.disqualifier:hover {
    background-color: #fff0f0;
}

/* Loading Screen */
.loading-step {
    padding: 40px 0;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 5px solid var(--border-color);
    border-top: 5px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 30px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Result Screen */
.result-box {
    background: #f8fbff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 25px;
    margin-top: 20px;
    text-align: right;
}

.success-icon {
    background: var(--success-color);
    color: var(--white);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 30px;
    margin: 0 auto 20px auto;
}

.product-highlight {
    background: var(--white);
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    border-right: 4px solid var(--primary-color);
    box-shadow: 0 4px 6px rgba(0,0,0,0.02);
}

.product-highlight h3 {
    color: var(--primary-dark);
    margin-bottom: 10px;
    font-size: 18px;
}

.product-highlight ul {
    list-style: none;
}

.product-highlight ul li {
    margin-bottom: 8px;
    font-size: 15px;
}

.urgency-banner {
    background: #fff3cd;
    color: #856404;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
    font-weight: 700;
    margin-bottom: 20px;
    font-size: 14px;
}

/* Form Elements */
.order-form input {
    width: 100%;
    padding: 15px;
    margin-bottom: 15px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 16px;
    font-family: 'Tajawal', sans-serif;
    outline: none;
    transition: border-color 0.3s;
}

.order-form input:focus {
    border-color: var(--primary-color);
}

.form-footer {
    text-align: center;
    margin-top: 15px;
    color: var(--light-text);
}

/* Responsive */
@media (max-width: 480px) {
    .quiz-container {
        padding: 25px 20px;
    }
    
    h1 { font-size: 22px; }
    h2 { font-size: 18px; }
    
    .btn-primary, .option-btn {
        padding: 14px;
        font-size: 15px;
    }
}

/* Ultimate Conversion Hacks CSS */

/* 1. Pulse Animation */
.pulse-button {
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(11, 91, 158, 0.7); }
    70% { transform: scale(1.02); box-shadow: 0 0 0 15px rgba(11, 91, 158, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(11, 91, 158, 0); }
}

/* 2. Countdown Timer */
.timer-container {
    background: #fff3cd;
    border: 1px solid #ffeeba;
    color: #856404;
    padding: 15px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: center;
    font-weight: bold;
}
.countdown {
    font-size: 28px;
    color: #dc3545;
    margin-top: 5px;
    letter-spacing: 2px;
}

/* 3. Trust Badges */
.trust-badges {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 10px;
    margin: 20px 0;
    padding-top: 15px;
    border-top: 1px dashed var(--border-color);
}
.trust-badges span {
    font-size: 12px;
    color: var(--primary-dark);
    background: #e8f4fd;
    padding: 6px 10px;
    border-radius: 20px;
    font-weight: bold;
}

/* 4. Social Proof Toast */
.social-toast {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background: var(--white);
    border-left: 4px solid var(--success-color);
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    padding: 12px 15px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 15px;
    transform: translateY(150%);
    transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 1000;
    max-width: 300px;
}
.social-toast.show {
    transform: translateY(0);
}
.toast-img {
    font-size: 24px;
    background: #f0fdf4;
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
}
.toast-content p {
    margin: 0 0 2px 0;
    font-size: 14px;
    font-weight: bold;
    color: var(--text-color);
}
.toast-content small {
    color: var(--light-text);
    font-size: 12px;
}
@media (max-width: 480px) {
    .social-toast {
        bottom: 10px;
        left: 10px;
        right: 10px;
        max-width: none;
    }
}

/* Checkout Elements CSS */

/* Phone Input Masking */
.phone-input-group {
    display: flex;
    align-items: center;
    border: 1px solid #ccc;
    border-radius: 8px;
    background-color: #fff;
    overflow: hidden;
    margin-bottom: 5px;
}
.phone-input-group .phone-prefix {
    background-color: #f8f9fa;
    color: #495057;
    padding: 14px 15px;
    font-size: 16px;
    font-weight: bold;
    border-right: 1px solid #ccc;
    direction: ltr;
}
.phone-input-group input[type="tel"] {
    flex: 1;
    border: none;
    padding: 14px;
    font-size: 18px;
    margin-bottom: 0;
    border-radius: 0;
    box-shadow: none;
    outline: none;
}
.phone-input-group input:focus {
    outline: none;
    background: transparent;
}

/* Ultimate CRO Checkout Elements */
.product-visual-container {
    text-align: center;
    margin-bottom: 20px;
    background: #fff;
    padding: 15px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.product-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.star-rating {
    font-size: 20px;
    margin-bottom: 10px;
}

.low-stock-alert {
    color: #d9534f;
    font-weight: bold;
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #fdf2f2;
    padding: 8px;
    border-radius: 6px;
    border: 1px dashed #d9534f;
}

.pulsing-dot {
    width: 10px;
    height: 10px;
    background-color: #d9534f;
    border-radius: 50%;
    animation: pulse-red 1.5s infinite;
}

@keyframes pulse-red {
    0% { box-shadow: 0 0 0 0 rgba(217, 83, 79, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(217, 83, 79, 0); }
    100% { box-shadow: 0 0 0 0 rgba(217, 83, 79, 0); }
}

.guarantee-box {
    background: #e8f5e9;
    border: 1px solid #4caf50;
    color: #2e7d32;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 15px;
    font-size: 15px;
    text-align: right;
    box-shadow: 0 2px 8px rgba(76, 175, 80, 0.1);
}

/* Price Anchoring Checkout Style */
.checkout-style {
    background: #fdfbf7;
    border: 2px solid #e5d7a8;
}
.price-container {
    text-align: center;
    margin: 25px 0;
    padding: 20px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    border: 1px solid #f2e9d2;
}
.price-split {
    display: flex;
    justify-content: space-around;
    align-items: center;
    gap: 15px;
    margin-bottom: 12px;
}
@media (max-width: 480px) {
    .price-split {
        flex-direction: column;
        gap: 10px;
    }
}
.price-tag {
    display: flex;
    flex-direction: column;
    align-items: center;
}
.price-tag .price-label {
    font-size: 13px;
    color: var(--light-text);
    margin-bottom: 4px;
}
.price-tag.original .price-val {
    text-decoration: line-through;
    color: #dc3545;
    font-weight: 700;
    font-size: 18px;
}
.price-tag.promo .price-val {
    color: var(--success-color);
    font-weight: 800;
    font-size: 32px;
    text-shadow: 0 1px 2px rgba(39, 174, 96, 0.1);
}
.save-badge {
    background: #e1f5fe;
    color: #0288d1;
    font-size: 14px;
    font-weight: bold;
    padding: 6px 12px;
    border-radius: 20px;
    display: inline-block;
}
.reassurance-text {
    font-size: 13px;
    line-height: 1.6;
    color: #555;
    text-align: center;
    background: #e9ecef;
    padding: 10px;
    border-radius: 6px;
    font-weight: bold;
}

/* Result Step Custom Layout */
.result-header {
    text-align: center;
    margin-bottom: 25px;
}
.diagnostic-subtitle {
    font-size: 15px;
    color: #5a6b7c;
    margin-top: 8px;
}
.verdict-text {
    font-size: 16px;
    line-height: 1.6;
    color: #2c3e50;
    border-bottom: 1px dashed #e0e6ed;
    padding-bottom: 15px;
    margin-bottom: 15px;
}
.highlight-green {
    color: var(--success-color);
    font-weight: 800;
}
.verdict-desc {
    font-size: 15px;
    line-height: 1.6;
    color: #4f5f6f;
    margin-bottom: 20px;
}

/* Checkmark Animation */
.success-checkmark {
    width: 68px;
    height: 68px;
    margin: 0 auto 15px auto;
}
.checkmark-svg {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    display: block;
    stroke-width: 3;
    stroke: var(--success-color);
    stroke-miterlimit: 10;
    box-shadow: inset 0px 0px 0px var(--success-color);
    animation: fill-green .4s ease-in-out .4s forwards, scale-up .3s ease-in-out .9s both;
}
.checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 3;
    stroke-miterlimit: 10;
    stroke: var(--success-color);
    fill: none;
    animation: stroke-circle .6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}
.checkmark-check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    stroke: #ffffff;
    animation: stroke-check .3s cubic-bezier(0.65, 0, 0.45, 1) .8s forwards;
}
@keyframes stroke-circle {
    100% { stroke-dashoffset: 0; }
}
@keyframes stroke-check {
    100% { stroke-dashoffset: 0; }
}
@keyframes fill-green {
    100% { box-shadow: inset 0px 0px 0px 40px var(--success-color); }
}
@keyframes scale-up {
    0%, 100% { transform: none; }
    50% { transform: scale3d(1.1, 1.1, 1); }
}

/* Timer and Progress bar in Timer */
.timer-title {
    font-size: 14px;
    color: #856404;
    margin-bottom: 8px;
}
.timer-bar-wrapper {
    width: 100%;
    height: 6px;
    background: #f1ebd4;
    border-radius: 3px;
    overflow: hidden;
    margin-top: 10px;
}
.timer-bar {
    width: 100%;
    height: 100%;
    background: #dc3545;
    border-radius: 3px;
    transition: width 1s linear;
}

/* Premium Product Visual Section */
.premium-ribbon {
    background: #ffc107;
    color: #000;
    font-size: 12px;
    font-weight: 800;
    padding: 5px 15px;
    border-radius: 4px;
    display: inline-block;
    margin-bottom: 12px;
    box-shadow: 0 2px 4px rgba(255,193,7,0.2);
}
.rating-count {
    font-size: 12px;
    color: #666;
}
.product-title {
    font-size: 20px;
    font-weight: 800;
    color: var(--primary-dark);
    margin-bottom: 15px;
    text-align: center;
}

/* Product Benefits Clean Grid */
.product-benefits {
    padding: 0;
    margin: 20px 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 15px;
    text-align: right;
}
.product-benefits li {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding-bottom: 12px;
    border-bottom: 1px dashed #f0f3f6;
}
.product-benefits li:last-child {
    border-bottom: none;
    padding-bottom: 0;
}
.benefit-icon {
    font-size: 22px;
    line-height: 1;
    background: #e8f4fd;
    padding: 8px;
    border-radius: 8px;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
}
.product-benefits li div strong {
    font-size: 15px;
    color: #1a252f;
    display: block;
    margin-bottom: 2px;
}
.product-benefits li div p {
    font-size: 13px;
    color: #7f8c8d;
    margin: 0;
}

/* Form Styling Upgrade */
.form-field-wrapper {
    margin-bottom: 18px;
    text-align: right;
}
.field-label {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #34495e;
    margin-bottom: 6px;
}
.required-star {
    color: #dc3545;
}
.field-hint {
    font-size: 12px;
    color: #7f8c8d;
    display: block;
    margin-top: 4px;
    line-height: 1.4;
}

/* Button & Trust Badge Layout */
.btn-text {
    display: inline-block;
}
.badge-item {
    display: flex;
    align-items: center;
    gap: 6px;
}
.badge-icon {
    font-size: 14px;
}

