/* Market Onboarding Styles */

.mo-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6); /* Darkened backdrop for focus */
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mo-overlay.mo-active {
    opacity: 1;
    visibility: visible;
}

.mo-modal {
    background: #ffffff;
    border-radius: 16px;
    width: 90%;
    max-width: 480px;
    padding: 32px 28px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
    transform: translateY(20px);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    color: #333333;
    position: relative;
    overflow: hidden;
}

.mo-overlay.mo-active .mo-modal {
    transform: translateY(0);
}

.mo-modal-header {
    text-align: center;
    margin-bottom: 24px;
}

.mo-modal-icon {
    font-size: 42px;
    color: #0056b3;
    margin-bottom: 12px;
}

.mo-modal-header h2 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #002a46;
    margin-bottom: 8px;
}

.mo-modal-header p {
    font-size: 0.95rem;
    color: #555555;
    line-height: 1.5;
}

.mo-step {
    display: none;
    animation: moFadeIn 0.3s ease;
}

.mo-step.mo-active {
    display: block;
}

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

/* Form Controls */
.mo-form-group {
    margin-bottom: 20px;
}

.mo-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: #002a46;
}

.mo-select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    color: #333;
    background: #f9f9f9;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.mo-select:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.15);
}

/* Category Pills */
.mo-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.mo-pill {
    background: #f0f4f8;
    border: 1px solid #d9e2ec;
    color: #486581;
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.mo-pill:hover {
    background: #e0e8f0;
}

.mo-pill.mo-selected {
    background: #0056b3;
    border-color: #0056b3;
    color: #ffffff;
    box-shadow: 0 4px 10px rgba(0, 86, 179, 0.2);
}

/* Modal Actions */
.mo-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 32px;
}

.mo-btn {
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
}

.mo-btn-secondary {
    background: transparent;
    color: #555;
}

.mo-btn-secondary:hover {
    background: #f5f5f5;
    color: #333;
}

.mo-btn-primary {
    background: #0056b3;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 86, 179, 0.2);
}

.mo-btn-primary:hover {
    background: #004494;
    transform: translateY(-1px);
}

/* Custom Tooltip Tour Engine */

.mo-tour-overlay {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    background: transparent; /* Darkness handled by highlight shadows */
    z-index: 8000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mo-tour-overlay.mo-active {
    opacity: 1;
    pointer-events: auto;
}

/* Highlight class applied to target elements */
.mo-tour-highlight {
    z-index: 8001 !important;
    background: #ffffff !important;
    border-radius: 8px;
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 1), 0 0 0 2000vw rgba(0, 0, 0, 0.7);
    outline: 2px solid #0056b3;
    pointer-events: auto !important; /* Allow clicking highlighted element (e.g. View Details) */
}

/* The floating tooltip */
.mo-tooltip {
    position: fixed;
    z-index: 8002;
    background: #ffffff;
    border-radius: 12px;
    padding: 20px;
    width: 280px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.mo-tooltip.mo-active {
    opacity: 1;
    visibility: visible;
}

.mo-tooltip::after {
    content: '';
    position: absolute;
    width: 0; height: 0;
    border-style: solid;
}

/* Tooltip placements */
.mo-tooltip[data-placement="top"] { transform: translateY(-10px); }
.mo-tooltip[data-placement="top"].mo-active { transform: translateY(0); }
.mo-tooltip[data-placement="top"]::after {
    bottom: -8px; left: 50%; margin-left: -8px;
    border-width: 8px 8px 0 8px;
    border-color: #ffffff transparent transparent transparent;
}

.mo-tooltip[data-placement="bottom"] { transform: translateY(10px); }
.mo-tooltip[data-placement="bottom"].mo-active { transform: translateY(0); }
.mo-tooltip[data-placement="bottom"]::after {
    top: -8px; left: 50%; margin-left: -8px;
    border-width: 0 8px 8px 8px;
    border-color: transparent transparent #ffffff transparent;
}

/* Tooltip Content */
.mo-tooltip h4 {
    margin: 0 0 8px 0;
    color: #002a46;
    font-size: 1.1rem;
    font-weight: 700;
}

.mo-tooltip p {
    margin: 0 0 16px 0;
    color: #444;
    font-size: 0.9rem;
    line-height: 1.4;
}

.mo-tooltip-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.mo-tour-progress {
    font-size: 0.75rem;
    color: #888;
    font-weight: 600;
}

.mo-tooltip-actions {
    display: flex;
    gap: 8px;
}

.mo-btn-skip {
    background: transparent;
    border: none;
    color: #666;
    font-size: 0.8rem;
    cursor: pointer;
    font-weight: 500;
}

.mo-btn-skip:hover {
    color: #333;
}

.mo-btn-next {
    background: #0056b3;
    color: #fff;
    border: none;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
}

.mo-btn-next:hover {
    background: #004494;
}

.products.explore {
    margin-top: 70px;
}

