/**
 * UL Dash Onboarding - Complete Styles v4.0
 * Underground Landlord brand colors and styling
 */

/* ── DASH WIDGET (Bottom-Right Corner) ── */
.ul-dash-widget { position: fixed; bottom: 20px; right: 20px; z-index: 999999; font-family: Arial, sans-serif; }

/* Toggle Button */
.ul-dash-toggle { display: flex; align-items: center; gap: 10px; padding: 12px 20px; background: linear-gradient(135deg, #AADDFF, #88ccff); border: 2px solid #77bbee; border-radius: 999px; color: #000; font-weight: 600; font-size: 15px; cursor: pointer; box-shadow: 0 4px 12px rgba(0,0,0,0.2); transition: all 0.3s ease; position: relative; }
.ul-dash-toggle:hover { background: linear-gradient(135deg, #88ccff, #AADDFF); transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,0.3); }
.dash-avatar-mini { width: 32px !important; height: 32px !important; max-width: 32px !important; max-height: 32px !important; min-width: 32px; min-height: 32px; object-fit: contain; display: inline-block; flex-shrink: 0; overflow: hidden; border-radius: 50%; }
.dash-text { white-space: nowrap; }
.dash-badge { position: absolute; top: -8px; right: -8px; background: #CC0000; color: white; width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; border: 2px solid white; }

/* Expanded Panel */
.ul-dash-panel { position: absolute; bottom: 70px; right: 0; width: 400px; max-width: calc(100vw - 40px); background: white; border: 2px solid #AADDFF; border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,0.2); display: none; }
.ul-dash-widget.expanded .ul-dash-panel { display: block; animation: slideUp 0.3s ease-out; }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* Header */
.ul-dash-header { display: flex; justify-content: space-between; align-items: flex-start; padding: 16px; background: #E5F3FF; border-bottom: 2px solid #AADDFF; border-radius: 10px 10px 0 0; }
.dash-header-content { display: flex; gap: 12px; align-items: center; }
.dash-avatar { width: 40px !important; height: 40px !important; max-width: 40px !important; max-height: 40px !important; min-width: 40px; min-height: 40px; object-fit: contain; display: inline-block; flex-shrink: 0; overflow: hidden; border-radius: 50%; }
.dash-title { font-size: 18px; font-weight: 700; color: #0a3d5f; }
.dash-subtitle { font-size: 13px; color: #555; }
.ul-dash-close { background: transparent; border: none; font-size: 28px; color: #0a3d5f; cursor: pointer; line-height: 1; padding: 0; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border-radius: 50%; transition: all 0.2s; }
.ul-dash-close:hover { background: rgba(0,0,0,0.1); }

/* Search Box */
.ul-dash-search { padding: 16px; border-bottom: 1px solid #e5e7eb; display: flex; gap: 8px; }
.ul-dash-search input { flex: 1; padding: 10px 12px; border: 2px solid #e5e7eb; border-radius: 8px; font-size: 14px; transition: border-color 0.2s; }
.ul-dash-search input:focus { outline: none; border-color: #AADDFF; }
.ul-dash-search button { padding: 10px 20px; background: linear-gradient(135deg, #AADDFF, #88ccff); border: 2px solid #77bbee; border-radius: 8px; color: #000; font-weight: 600; font-size: 14px; cursor: pointer; transition: all 0.2s; }
.ul-dash-search button:hover { background: linear-gradient(135deg, #88ccff, #AADDFF); }

/* Content Area */
.ul-dash-content { padding: 16px; max-height: 420px; overflow-y: auto; }
.suggestion-title { font-weight: 600; color: #0a3d5f; font-size: 13px; margin-bottom: 8px; text-transform: uppercase; }
.suggestion-item { padding: 10px 12px; background: #f9f9f9; border: 1px solid #e5e7eb; border-radius: 6px; margin-bottom: 6px; cursor: pointer; font-size: 14px; transition: all 0.2s; }
.suggestion-item:hover { background: #E5F3FF; border-color: #AADDFF; }

/* Footer */
.dash-footer { display: flex; justify-content: space-between; align-items: center; padding: 10px 16px; border-top: 1px solid #e5e7eb; background: #fafafa; border-radius: 0 0 10px 10px; }
.dash-hide-btn { background: transparent; border: none; color: #999; font-size: 12px; cursor: pointer; padding: 4px 0; transition: color 0.2s; }
.dash-hide-btn:hover { color: #CC0000; }
.dash-faq-link { color: #0a3d5f; font-size: 12px; font-weight: 600; text-decoration: none; }
.dash-faq-link:hover { text-decoration: underline; }

/* ── SHARED BUTTONS ── */
.ul-dash-btn-primary { display: inline-block; padding: 10px 20px; background: linear-gradient(135deg, #AADDFF, #88ccff); border: 2px solid #77bbee; border-radius: 999px; color: #000; font-weight: 600; font-size: 14px; cursor: pointer; transition: all 0.2s; text-decoration: none; }
.ul-dash-btn-primary:hover { background: linear-gradient(135deg, #88ccff, #AADDFF); transform: translateY(-1px); }
.ul-dash-btn-primary:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.dash-text-link { background: transparent; border: none; color: #0a3d5f; font-size: 13px; cursor: pointer; text-decoration: underline; padding: 4px 0; }
.dash-text-link:hover { color: #555; }
.dash-back-btn { display: inline-block; padding: 8px 16px; background: transparent; border: 1px solid #e5e7eb; border-radius: 8px; color: #0a3d5f; font-size: 14px; cursor: pointer; margin-bottom: 12px; }
.dash-back-btn:hover { background: #f9f9f9; border-color: #AADDFF; }

/* ── TOUR STYLES ── */

/* Welcome Card */
.tour-welcome-card { background: linear-gradient(135deg, #E5F3FF, #d4edff); border: 2px solid #AADDFF; border-radius: 10px; padding: 18px; margin-bottom: 16px; }
.tour-welcome-title { font-size: 17px; font-weight: 700; color: #0a3d5f; margin-bottom: 8px; }
.tour-welcome-desc { font-size: 13.5px; color: #333; line-height: 1.6; }

/* Progress Bar */
.tour-progress { margin-bottom: 14px; }
.tour-progress-bar { width: 100%; height: 8px; background: #e5e7eb; border-radius: 4px; overflow: hidden; margin-bottom: 4px; }
.tour-progress-fill { height: 100%; background: linear-gradient(90deg, #AADDFF, #55aadd); border-radius: 4px; transition: width 0.4s ease; }
.tour-progress-label { font-size: 12px; color: #888; text-align: right; }

/* Checklist */
.tour-checklist { margin-bottom: 16px; }
.tour-stop-item { display: flex; align-items: center; gap: 8px; padding: 10px 12px; background: #fff; border: 1px solid #e5e7eb; border-radius: 8px; margin-bottom: 5px; cursor: pointer; font-size: 14px; transition: all 0.2s; }
.tour-stop-item:hover { background: #E5F3FF; border-color: #AADDFF; }
.tour-stop-visited { background: #f0fdf4; border-color: #bbf7d0; }
.tour-stop-visited:hover { background: #dcfce7; }
.tour-stop-check { font-size: 16px; flex-shrink: 0; width: 22px; text-align: center; }
.tour-stop-emoji { font-size: 18px; flex-shrink: 0; }
.tour-stop-title { flex: 1; font-weight: 600; color: #0a3d5f; }
.tour-stop-lock { font-size: 14px; flex-shrink: 0; }

/* Stop Detail Card */
.tour-stop-card { background: #fff; border: 2px solid #e5e7eb; border-radius: 10px; padding: 18px; margin-bottom: 12px; }
.tour-stop-card-header { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; padding-bottom: 10px; border-bottom: 2px solid #AADDFF; }
.tour-stop-card-emoji { font-size: 28px; }
.tour-stop-card-title { font-size: 18px; font-weight: 700; color: #0a3d5f; }
.tour-stop-card-desc { font-size: 14px; color: #444; line-height: 1.65; margin-bottom: 14px; }

/* Screenshots in tour */
.tour-screenshots { margin-bottom: 14px; }
.tour-screenshots-label { font-size: 13px; font-weight: 600; color: #0a3d5f; margin-bottom: 8px; }
.tour-screenshot-thumb { width: 100%; max-height: 160px; object-fit: cover; object-position: top; border: 2px solid #e5e7eb; border-radius: 8px; cursor: pointer; margin-bottom: 6px; transition: all 0.2s; }
.tour-screenshot-thumb:hover { border-color: #AADDFF; box-shadow: 0 2px 8px rgba(0,0,0,0.15); }

/* State Picker */
.tour-state-picker-wrap { margin-bottom: 14px; }
.tour-state-picker-wrap label { display: block; font-size: 13px; font-weight: 600; color: #0a3d5f; margin-bottom: 6px; }
.tour-state-select { width: 100%; padding: 10px 12px; border: 2px solid #e5e7eb; border-radius: 8px; font-size: 14px; color: #333; background: #fff; transition: border-color 0.2s; }
.tour-state-select:focus { outline: none; border-color: #AADDFF; }

/* Tour Actions */
.tour-stop-actions { margin-top: 4px; }
.tour-upsell-box { background: #fffbeb; border: 2px solid #fde68a; border-radius: 10px; padding: 14px; text-align: center; }
.tour-upsell-text { font-size: 14px; color: #92400e; margin-bottom: 10px; font-weight: 500; }
.tour-upgrade-link { font-size: 13px; }

/* Tour Bottom Controls */
.tour-bottom-controls { text-align: center; padding-top: 8px; border-top: 1px solid #e5e7eb; margin-top: 4px; padding-bottom: 4px; }

/* Arrival Card (when landing on page mid-tour) */
.tour-arrival-card { background: linear-gradient(135deg, #E5F3FF, #d4edff); border: 2px solid #AADDFF; border-radius: 10px; padding: 20px; text-align: center; margin-bottom: 16px; }
.tour-arrival-emoji { font-size: 40px; margin-bottom: 8px; }
.tour-arrival-title { font-size: 17px; font-weight: 700; color: #0a3d5f; margin-bottom: 10px; }
.tour-arrival-desc { font-size: 13.5px; color: #333; line-height: 1.6; }
.tour-arrival-actions { text-align: center; }
.tour-arrival-actions .ul-dash-btn-primary { margin-bottom: 8px; }
.tour-arrival-actions .dash-text-link { display: block; margin-top: 4px; }

/* Tour Complete */
.tour-complete-card { text-align: center; padding: 24px 16px; }
.tour-complete-emoji { font-size: 48px; margin-bottom: 8px; }
.tour-complete-title { font-size: 20px; font-weight: 700; color: #0a3d5f; margin-bottom: 10px; }
.tour-complete-desc { font-size: 14px; color: #555; line-height: 1.6; }
.tour-complete-actions { text-align: center; margin-top: 16px; }
.tour-complete-actions .ul-dash-btn-primary { margin-bottom: 8px; }
.tour-complete-actions .dash-text-link { display: block; margin-top: 4px; }

/* ── LIGHTBOX ── */
.dash-lightbox { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 9999999; display: flex; align-items: center; justify-content: center; }
.dash-lightbox-backdrop { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.75); cursor: pointer; }
.dash-lightbox-content { position: relative; z-index: 1; max-width: 90vw; max-height: 90vh; background: #fff; border-radius: 12px; overflow: hidden; box-shadow: 0 12px 40px rgba(0,0,0,0.4); }
.dash-lightbox-content img { display: block; max-width: 90vw; max-height: 80vh; object-fit: contain; }
.dash-lightbox-x { position: absolute; top: 10px; right: 14px; background: rgba(0,0,0,0.6); color: #fff; border: none; font-size: 24px; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; z-index: 2; }
.dash-lightbox-x:hover { background: rgba(0,0,0,0.8); }
.dash-lightbox-caption { padding: 10px 16px; font-size: 13px; color: #555; text-align: center; background: #f9f9f9; }

/* ── FAQ RESULTS ── */
.faq-result-item { padding: 14px; background: #f9f9f9; border: 2px solid #e5e7eb; border-radius: 8px; margin-bottom: 10px; cursor: pointer; transition: all 0.2s; }
.faq-result-item:hover { background: #E5F3FF; border-color: #AADDFF; }
.faq-result-question { font-weight: 600; color: #0a3d5f; font-size: 15px; margin-bottom: 6px; }
.faq-result-answer { font-size: 14px; color: #555; line-height: 1.6; }
.faq-result-meta { display: flex; gap: 8px; margin-top: 8px; }
.faq-badge { display: inline-block; padding: 3px 10px; background: #AADDFF; color: #000; border-radius: 999px; font-size: 11px; font-weight: 600; }

/* Loading */
.dash-loading { text-align: center; padding: 20px; color: #555; }
.dash-loading::after { content: '...'; animation: dots 1.5s infinite; }
@keyframes dots { 0%, 20% { content: '.'; } 40% { content: '..'; } 60%, 100% { content: '...'; } }

/* ── WALKTHROUGH STYLES (NEW) ── */
.walkthrough-card { background: white; }
.walkthrough-progress { height: 6px; background: #e5e7eb; border-radius: 3px; margin-bottom: 16px; overflow: hidden; }
.walkthrough-progress-bar { height: 100%; background: linear-gradient(90deg, #AADDFF, #88ccff); transition: width 0.5s ease; }
.walkthrough-header { margin-bottom: 12px; }
.walkthrough-badge { display: inline-block; padding: 4px 12px; background: #E5F3FF; color: #0a3d5f; border-radius: 999px; font-size: 12px; font-weight: 600; margin-bottom: 8px; }
.walkthrough-header h3 { font-size: 18px; color: #0a3d5f; margin: 8px 0 0; }
.walkthrough-content { margin: 16px 0; }
.walkthrough-content p { font-size: 14px; color: #333; line-height: 1.6; margin-bottom: 12px; }
.walkthrough-tip { background: #FFF9E6; border-left: 4px solid #FFD700; padding: 12px; border-radius: 6px; margin: 12px 0; font-size: 13px; color: #555; }
.walkthrough-upsell { background: #FFF0F0; border: 2px solid #FFB8B8; border-radius: 8px; padding: 14px; margin: 12px 0; }
.walkthrough-upsell p { color: #CC0000; font-weight: 600; margin-bottom: 8px; }
.walkthrough-actions { display: flex; gap: 10px; margin-top: 16px; }
.walkthrough-next-btn, .walkthrough-finish-btn { flex: 1; padding: 12px; background: linear-gradient(135deg, #AADDFF, #88ccff); border: 2px solid #77bbee; border-radius: 8px; color: #000; font-weight: 600; cursor: pointer; transition: all 0.2s; }
.walkthrough-next-btn:hover, .walkthrough-finish-btn:hover { background: linear-gradient(135deg, #88ccff, #AADDFF); transform: translateY(-1px); }
.walkthrough-skip-btn { padding: 12px 20px; background: transparent; border: 1px solid #e5e7eb; border-radius: 8px; color: #666; cursor: pointer; transition: all 0.2s; }
.walkthrough-skip-btn:hover { background: #f9f9f9; border-color: #AADDFF; }
.walkthrough-complete { text-align: center; padding: 20px 0; }
.walkthrough-complete h3 { color: #0a3d5f; font-size: 20px; margin: 12px 0 8px; }
.walkthrough-complete p { color: #555; margin-bottom: 20px; }
.walkthrough-cta { background: #E5F3FF; border: 2px solid #AADDFF; border-radius: 8px; padding: 16px; margin: 16px 0; }
.walkthrough-cta h4 { color: #0a3d5f; margin-bottom: 12px; }

/* Highlight effect for page elements */
.ul-dash-highlight { position: relative; animation: pulseHighlight 2s infinite; box-shadow: 0 0 0 4px #AADDFF, 0 0 0 8px rgba(170, 221, 255, 0.4) !important; border-radius: 8px !important; z-index: 9999; }
@keyframes pulseHighlight { 0%, 100% { box-shadow: 0 0 0 4px #AADDFF, 0 0 0 8px rgba(170, 221, 255, 0.4); } 50% { box-shadow: 0 0 0 6px #88ccff, 0 0 0 12px rgba(136, 204, 255, 0.6); } }

/* ── SCROLLBAR ── */
.ul-dash-content::-webkit-scrollbar { width: 8px; }
.ul-dash-content::-webkit-scrollbar-track { background: #f9f9f9; }
.ul-dash-content::-webkit-scrollbar-thumb { background: #AADDFF; border-radius: 4px; }
.ul-dash-content::-webkit-scrollbar-thumb:hover { background: #88ccff; }

/* ── MOBILE ── */
@media (max-width: 768px) {
    .ul-dash-widget { bottom: 10px; right: 10px; }
    .ul-dash-panel { width: calc(100vw - 20px); bottom: 60px; }
    .dash-text { display: none; }
    .ul-dash-toggle { padding: 12px; }
    .dash-lightbox-content { max-width: 95vw; }
    .dash-lightbox-content img { max-width: 95vw; }
}
