/*
 * FILE: user-guide.css
 * PURPOSE: Styling for the User Guide Modal component
 *
 * KEY RESPONSIBILITIES:
 *  - Style the guide modal carousel
 *  - Handle responsive design
 *  - Animate card transitions
 *
 * DESIGN PHILOSOPHY:
 *  - Trust-building aesthetic: warm, inviting, not intrusive
 *  - Rich illustrations take center stage
 *  - Clear navigation with progress indication
 *
 * LAST UPDATED: December 24, 2025 by /go Agent
 * CHANGE SUMMARY: Initial creation for User Guiding System
 */

/* ═══════════════════════════════════════════════════════════════════════════
   VARIABLES
   ═══════════════════════════════════════════════════════════════════════════ */
.sp-user-guide {
    --guide-modal-width: 540px;
    --guide-modal-max-height: 85vh;
    --guide-illustration-height: 200px;
    --guide-border-radius: 16px;
    --guide-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    
    /* Colors - Trust-building warm palette */
    --guide-bg: #ffffff;
    --guide-text: #1e293b;
    --guide-text-muted: #64748b;
    --guide-primary: #3b82f6;
    --guide-primary-hover: #2563eb;
    --guide-success: #10b981;
    --guide-success-hover: #059669;
    --guide-backdrop: rgba(15, 23, 42, 0.6);
    --guide-border: #e2e8f0;
    --guide-illustration-bg: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
}

/* Dark theme overrides */
[data-theme="dark"] .sp-user-guide {
    --guide-bg: #1e293b;
    --guide-text: #f1f5f9;
    --guide-text-muted: #94a3b8;
    --guide-border: #334155;
    --guide-backdrop: rgba(0, 0, 0, 0.75);
    --guide-illustration-bg: linear-gradient(135deg, #1e3a5f 0%, #0f172a 100%);
}

/* ═══════════════════════════════════════════════════════════════════════════
   BACKDROP
   ═══════════════════════════════════════════════════════════════════════════ */
.sp-user-guide__backdrop {
    position: fixed;
    inset: 0;
    background: var(--guide-backdrop);
    backdrop-filter: blur(4px);
    z-index: 9998;
}

/* ═══════════════════════════════════════════════════════════════════════════
   CONTAINER
   ═══════════════════════════════════════════════════════════════════════════ */
.sp-user-guide__container {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    z-index: 9999;
}

/* ═══════════════════════════════════════════════════════════════════════════
   MODAL
   ═══════════════════════════════════════════════════════════════════════════ */
.sp-user-guide__modal {
    position: relative;
    width: 100%;
    max-width: var(--guide-modal-width);
    max-height: var(--guide-modal-max-height);
    background: var(--guide-bg);
    border-radius: var(--guide-border-radius);
    box-shadow: var(--guide-shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* Close Button */
.sp-user-guide__close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid var(--guide-border);
    border-radius: 50%;
    color: var(--guide-text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 10;
}

.sp-user-guide__close:hover {
    background: #fff;
    color: var(--guide-text);
    transform: scale(1.05);
}

[data-theme="dark"] .sp-user-guide__close {
    background: rgba(30, 41, 59, 0.9);
}

/* ═══════════════════════════════════════════════════════════════════════════
   CAROUSEL
   ═══════════════════════════════════════════════════════════════════════════ */
.sp-user-guide__carousel {
    position: relative;
    flex: 1;
    overflow: hidden;
}

/* Card */
.sp-user-guide__card {
    display: flex;
    flex-direction: column;
}

/* Illustration - FontAwesome icons with decorative background */
.sp-user-guide__illustration {
    width: 100%;
    height: var(--guide-illustration-height);
    background: var(--guide-illustration-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.sp-user-guide__illustration i {
    font-size: 5rem;
    color: var(--guide-primary);
    opacity: 0.9;
}

.sp-user-guide__illustration img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* Content */
.sp-user-guide__content {
    padding: 1.5rem 2rem;
}

.sp-user-guide__title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--guide-text);
    margin: 0 0 1rem 0;
    line-height: 1.3;
}

.sp-user-guide__body {
    font-size: 1rem;
    color: var(--guide-text-muted);
    line-height: 1.6;
}

.sp-user-guide__body p {
    margin: 0 0 0.75rem 0;
}

.sp-user-guide__body p:last-child {
    margin-bottom: 0;
}

.sp-user-guide__body strong {
    color: var(--guide-text);
    font-weight: 600;
}

.sp-user-guide__body ul {
    margin: 0.75rem 0;
    padding-left: 1.25rem;
}

.sp-user-guide__body li {
    margin-bottom: 0.5rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════════════════ */
.sp-user-guide__footer {
    padding: 1rem 2rem 1.5rem;
    border-top: 1px solid var(--guide-border);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Progress Dots */
.sp-user-guide__progress {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}

.sp-user-guide__dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--guide-border);
    border: none;
    padding: 0;
    cursor: pointer;
    transition: all 0.2s ease;
}

.sp-user-guide__dot:hover {
    background: var(--guide-text-muted);
}

.sp-user-guide__dot--active {
    background: var(--guide-primary);
    transform: scale(1.2);
}

/* Preferences */
.sp-user-guide__preferences {
    display: flex;
    justify-content: center;
}

.sp-user-guide__checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--guide-text-muted);
    cursor: pointer;
}

.sp-user-guide__checkbox input {
    width: 16px;
    height: 16px;
    accent-color: var(--guide-primary);
}

/* Navigation */
.sp-user-guide__nav {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
}

.sp-user-guide__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    font-size: 0.9375rem;
    font-weight: 500;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.sp-user-guide__btn--primary {
    background: var(--guide-primary);
    color: #ffffff;
}

.sp-user-guide__btn--primary:hover {
    background: var(--guide-primary-hover);
    transform: translateY(-1px);
}

.sp-user-guide__btn--secondary {
    background: transparent;
    color: var(--guide-text-muted);
    border: 1px solid var(--guide-border);
}

.sp-user-guide__btn--secondary:hover {
    background: var(--guide-border);
    color: var(--guide-text);
}

.sp-user-guide__btn--success {
    background: var(--guide-success);
    color: #ffffff;
}

.sp-user-guide__btn--success:hover {
    background: var(--guide-success-hover);
    transform: translateY(-1px);
}

/* ═══════════════════════════════════════════════════════════════════════════
   HELP TRIGGER (Floating Button)
   ═══════════════════════════════════════════════════════════════════════════ */
.sp-user-guide__help-trigger {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--guide-primary);
    color: #ffffff;
    border: none;
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 100;
}

.sp-user-guide__help-trigger:hover {
    background: var(--guide-primary-hover);
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.5);
}

.sp-user-guide__help-trigger i {
    font-size: 1.25rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════════════ */
@media (max-width: 640px) {
    .sp-user-guide__modal {
        max-width: 100%;
        max-height: 100vh;
        border-radius: 0;
    }
    
    .sp-user-guide__illustration {
        height: 150px;
    }
    
    .sp-user-guide__content {
        padding: 1rem 1.5rem;
    }
    
    .sp-user-guide__title {
        font-size: 1.25rem;
    }
    
    .sp-user-guide__footer {
        padding: 1rem 1.5rem;
    }
    
    .sp-user-guide__nav {
        flex-direction: column;
    }
    
    .sp-user-guide__btn {
        width: 100%;
    }
    
    .sp-user-guide__help-trigger {
        bottom: 5rem; /* Above mobile nav */
        right: 1rem;
    }
}

/* ═══════════════════════════════════════════════════════════════════════════
   ANIMATIONS
   ═══════════════════════════════════════════════════════════════════════════ */
@keyframes guideSlideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sp-user-guide__card {
    animation: guideSlideIn 0.3s ease-out;
}

/* Pulse animation for help trigger */
@keyframes guidePulse {
    0%, 100% {
        box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
    }
    50% {
        box-shadow: 0 4px 20px rgba(59, 130, 246, 0.6);
    }
}

.sp-user-guide__help-trigger {
    animation: guidePulse 2s ease-in-out infinite;
}

.sp-user-guide__help-trigger:hover {
    animation: none;
}

