diff --git a/demo/app.js b/demo/app.js new file mode 100644 index 0000000..cfcea35 --- /dev/null +++ b/demo/app.js @@ -0,0 +1,410 @@ +// Mock data matching Pydantic / OpenAPI schema requirements +const SCULPTURES_DATA = [ + { + id: "234e5678-e89b-12d3-a456-426614174001", + name: "La Novia Dulce", + artist: "Lorena Espitia", + year: 2006, + latitude: 3.450143, + longitude: -76.533282, + status: "on-site", + image: "assets/la_novia_dulce.png", + description: "Decorated with sweets and candies representing Cali's culinary traditions. This bride is a homage to the traditional 'Macetas' given to godchildren every June.", + unlocked_content: "Cultural Oracle Insight: Lorena Espitia used bright fiberglass modeling to create a tactile sense of Colombian sugar candies. The sculpture is traditionally positioned near the river to evoke Cali's warm breeze carrying sweet aromas.", + captured: false, + audio_url: "https://cdn.gatos.cali.gov.co/audio/novia_dulce.mp3" + }, + { + id: "234e5678-e89b-12d3-a456-426614174002", + name: "La Gata Ceremonial", + artist: "José Horacio Martínez", + year: 2006, + latitude: 3.451600, + longitude: -76.532600, + status: "moved", + image: "assets/la_gata_ceremonial.png", + description: "A dark sculpture featuring intricate pre-Columbian gold patterns. It represents the ancestral heritage, jaguar spirits, and mythological elements of Southwest Colombia.", + unlocked_content: "Cultural Oracle Insight: The gold motifs are inspired by Calima culture gold artifacts. Its temporary relocation due to civic repairs on the Boulevard has triggered consensus recalculation, verifying its new spot 150m north.", + captured: false, + audio_url: "https://cdn.gatos.cali.gov.co/audio/gata_ceremonial.mp3" + }, + { + id: "234e5678-e89b-12d3-a456-426614174003", + name: "La Gata Ilustrada", + artist: "Lucy Tejada", + year: 2006, + latitude: 3.452600, + longitude: -76.532000, + status: "on-site", + image: "assets/la_gata_ilustrada.png", + description: "A whimsical tribute decorated with open books, flying musical notes, and colorful abstract silhouettes of dancing people. Created by the pioneer female artist Lucy Tejada.", + unlocked_content: "Cultural Oracle Insight: Lucy Tejada painted this cat as a reminder of Cali's literary and artistic renaissance in the mid-20th century. It features references to the Cali Group writers and traditional local salsa music.", + captured: false, + audio_url: "https://cdn.gatos.cali.gov.co/audio/gata_ilustrada.mp3" + } +]; + +let map; +let markers = []; +let selectedSculpture = null; +let currentFilter = 'all'; + +// Initialize Map +function initMap() { + // Center on Cali Gato monument area + map = L.map('map', { + zoomControl: false, + attributionControl: false + }).setView([3.4516, -76.5325], 16); + + // Add zoom control at bottom-right + L.control.zoom({ + position: 'bottomright' + }).addTo(map); + + // CartoDB Dark Matter tiles + L.tileLayer('https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png', { + maxZoom: 20 + }).addTo(map); + + renderMarkers(); +} + +// Render Leaflet Markers +function renderMarkers() { + // Clear existing markers + markers.forEach(marker => map.removeLayer(marker)); + markers = []; + + SCULPTURES_DATA.forEach(sculpture => { + // Skip if doesn't match filter + if (currentFilter !== 'all' && sculpture.status !== currentFilter) { + return; + } + + // Custom glowing icon + const customIcon = L.divIcon({ + html: `
+
+
`, + className: 'leaflet-custom-marker-wrapper', + iconSize: [24, 24], + iconAnchor: [12, 12] + }); + + const marker = L.marker([sculpture.latitude, sculpture.longitude], { icon: customIcon }) + .addTo(map) + .on('click', () => { + selectSculpture(sculpture); + map.setView([sculpture.latitude, sculpture.longitude], 17, { animate: true }); + }); + + markers.push(marker); + }); +} + +// Render Sculpture Cards in List +function renderCards() { + const container = document.getElementById('cards-container'); + container.innerHTML = ''; + + let count = 0; + + SCULPTURES_DATA.forEach(sculpture => { + if (currentFilter !== 'all' && sculpture.status !== currentFilter) { + return; + } + + count++; + + const card = document.createElement('div'); + card.className = `sculpture-card ${selectedSculpture && selectedSculpture.id === sculpture.id ? 'selected' : ''}`; + card.innerHTML = ` + ${sculpture.name} +
+ ${sculpture.name} + ${sculpture.artist} +
+ ${capitalize(sculpture.status)} + ${sculpture.captured ? ' Captured' : ''} +
+
+ `; + + card.addEventListener('click', () => { + selectSculpture(sculpture); + map.setView([sculpture.latitude, sculpture.longitude], 17, { animate: true }); + }); + + container.appendChild(card); + }); + + document.getElementById('list-count').textContent = `${count} matching`; +} + +// Select a sculpture & display detail view +function selectSculpture(sculpture) { + selectedSculpture = sculpture; + + // Toggle sidebar panel views + document.getElementById('sidebar-default').style.display = 'none'; + document.getElementById('sidebar-detail').style.display = 'flex'; + + // Fill in data + document.getElementById('detail-img').src = sculpture.image; + document.getElementById('detail-title').textContent = sculpture.name; + document.getElementById('detail-artist').textContent = sculpture.artist; + document.getElementById('detail-year').textContent = sculpture.year; + document.getElementById('detail-desc').textContent = sculpture.description; + + const statusBadge = document.getElementById('detail-status'); + statusBadge.className = `status-badge status-${sculpture.status}`; + statusBadge.textContent = capitalize(sculpture.status); + + // Render Lock/Unlock Checkin box + renderCheckInArea(sculpture); + + // Update card selected status + renderCards(); +} + +// Render Lock check-in box based on captured state +function renderCheckInArea(sculpture) { + const container = document.getElementById('checkin-container'); + container.innerHTML = ''; + + if (sculpture.captured) { + container.innerHTML = ` +
+
+ Sighting Captured & Unlocked +
+

${sculpture.unlocked_content}

+
+ `; + } else { + container.innerHTML = ` +
+

+ + Historical insights & media are locked. Capture this Gata on-site to unlock. +

+ +
+ `; + + document.getElementById('start-checkin-btn').addEventListener('click', () => { + triggerCheckInSimulation(sculpture); + }); + } +} + +// Trigger Checkin Modal simulation +function triggerCheckInSimulation(sculpture) { + const modal = document.getElementById('checkin-modal'); + const viewImg = document.getElementById('viewfinder-img'); + const modalTitle = document.getElementById('modal-sculpture-title'); + const logs = document.getElementById('scan-logs'); + + modalTitle.textContent = `Verifying ${sculpture.name}`; + viewImg.src = sculpture.image; + logs.innerHTML = ''; + + // Show modal + modal.classList.add('active'); + + // Logs sequence simulation + const steps = [ + { text: '[INIT] Contacting Hybrid Recognition Service...', delay: 0 }, + { text: '[GPS] Acquiring coordinates: latitude: ' + sculpture.latitude.toFixed(4) + ', longitude: ' + sculpture.longitude.toFixed(4) + '...', delay: 600 }, + { text: '[GPS] Lock established. Within 2.4 meters threshold.', delay: 1200, success: true }, + { text: '[VISION] Comparing photo vector embeddings with pgvector dataset...', delay: 1800 }, + { text: '[VISION] Match found. Similarity threshold: 0.941 > 0.85.', delay: 2400, success: true }, + { text: '[ORACLE] Consensus engine: Verification success.', delay: 3000 } + ]; + + steps.forEach(step => { + setTimeout(() => { + const entry = document.createElement('div'); + entry.className = 'log-entry'; + + let icon = ''; + if (step.success !== undefined) { + icon = step.success ? '' : ''; + } else { + icon = '
'; + } + + // If it's a loading log, remove spinner from previous logs + const spinners = logs.querySelectorAll('.log-spinner'); + spinners.forEach(s => s.replaceWith(document.createTextNode('✓'))); + + entry.innerHTML = `${icon} ${step.text}`; + logs.appendChild(entry); + + // Auto-scroll logs + logs.scrollTop = logs.scrollHeight; + }, step.delay); + }); + + // End of simulation -> Show Success card + setTimeout(() => { + renderSuccessScreen(sculpture); + }, 3800); +} + +// Render Success screen in modal body +function renderSuccessScreen(sculpture) { + const modalBody = document.getElementById('modal-body-content'); + + // Save original body to restore later + if (!window.originalModalBodyHTML) { + window.originalModalBodyHTML = modalBody.innerHTML; + } + + // Trigger Canvas Confetti + triggerConfetti(); + + modalBody.innerHTML = ` +
+
+ +
+

Sighting Validated!

+
+ + Unlocked Badge: ${sculpture.name} Capture +
+
+ Recognition Match Score: 94.1% +
+

+ GPS proximity and vector identity matching completed. Trust score validated. Cultural Oracle content unlocked! +

+ +
+ `; + + document.getElementById('finish-checkin-btn').addEventListener('click', () => { + // Capture state update + sculpture.captured = true; + updateCapturedStats(); + + // Close modal & reset layout + closeCheckInModal(); + + // Refresh detail view + selectSculpture(sculpture); + }); +} + +function closeCheckInModal() { + const modal = document.getElementById('checkin-modal'); + modal.classList.remove('active'); + + // Restore original body structure after transition completes + setTimeout(() => { + const modalBody = document.getElementById('modal-body-content'); + if (window.originalModalBodyHTML) { + modalBody.innerHTML = window.originalModalBodyHTML; + } + }, 300); +} + +function updateCapturedStats() { + const count = SCULPTURES_DATA.filter(s => s.captured).length; + document.getElementById('captured-count').textContent = count; +} + +function triggerConfetti() { + const duration = 2 * 1000; + const end = Date.now() + duration; + + (function frame() { + confetti({ + particleCount: 3, + angle: 60, + spread: 55, + origin: { x: 0 }, + colors: ['#ff5e62', '#ff9966', '#10b981'] + }); + confetti({ + particleCount: 3, + angle: 120, + spread: 55, + origin: { x: 1 }, + colors: ['#ff5e62', '#ff9966', '#10b981'] + }); + + if (Date.now() < end) { + requestAnimationFrame(frame); + } + }()); +} + +// Utility Helper +function capitalize(s) { + if (typeof s !== 'string') return ''; + return s.charAt(0).toUpperCase() + s.slice(1); +} + +// Event Listeners +document.getElementById('detail-back-btn').addEventListener('click', () => { + document.getElementById('sidebar-detail').style.display = 'none'; + document.getElementById('sidebar-default').style.display = 'flex'; + selectedSculpture = null; + renderCards(); +}); + +document.getElementById('close-modal').addEventListener('click', closeCheckInModal); + +// Filter pills interaction +document.querySelectorAll('.filter-pill').forEach(pill => { + pill.addEventListener('click', (e) => { + document.querySelectorAll('.filter-pill').forEach(p => p.classList.remove('active')); + e.target.classList.add('active'); + + currentFilter = e.target.dataset.status; + renderCards(); + renderMarkers(); + }); +}); + +// Audio Player Mock toggle play +let audioPlaying = false; +document.getElementById('audio-play').addEventListener('click', (e) => { + const icon = e.currentTarget.querySelector('i'); + const progressBar = document.querySelector('.audio-progress-bar'); + + if (audioPlaying) { + icon.className = 'fa-solid fa-play'; + audioPlaying = false; + progressBar.style.animation = 'none'; + } else { + icon.className = 'fa-solid fa-pause'; + audioPlaying = true; + // Simulate progression bar movement + progressBar.style.animation = 'audioPlaySim 133s linear infinite'; + } +}); + +// Add dynamic CSS style for simulating audio player progress bar +const audioStyle = document.createElement('style'); +audioStyle.innerHTML = ` + @keyframes audioPlaySim { + 0% { width: 35%; } + 100% { width: 100%; } + } +`; +document.head.appendChild(audioStyle); + +// Load everything on startup +window.addEventListener('DOMContentLoaded', () => { + initMap(); + renderCards(); + updateCapturedStats(); +}); diff --git a/demo/assets/la_gata_ceremonial.png b/demo/assets/la_gata_ceremonial.png new file mode 100644 index 0000000..c9967cc Binary files /dev/null and b/demo/assets/la_gata_ceremonial.png differ diff --git a/demo/assets/la_gata_ilustrada.png b/demo/assets/la_gata_ilustrada.png new file mode 100644 index 0000000..e461575 Binary files /dev/null and b/demo/assets/la_gata_ilustrada.png differ diff --git a/demo/assets/la_novia_dulce.png b/demo/assets/la_novia_dulce.png new file mode 100644 index 0000000..1d2dd49 Binary files /dev/null and b/demo/assets/la_novia_dulce.png differ diff --git a/demo/index.html b/demo/index.html new file mode 100644 index 0000000..21f3312 --- /dev/null +++ b/demo/index.html @@ -0,0 +1,162 @@ + + + + + + Novias del Gato - Cali Map Prototype + + + + + + + + + + + + + +
+
+
+ +
+
+

Novias del Gato

+

Geographic Cultural Oracle

+
+
+
+
+ + Captured: 0/3 +
+
+ + Trust Score: 0.85 +
+
+
+ + +
+ + + + +
+
+
+
+ + + + + + + + + + + + diff --git a/demo/style.css b/demo/style.css new file mode 100644 index 0000000..3515fb8 --- /dev/null +++ b/demo/style.css @@ -0,0 +1,918 @@ +/* Style Sheet for Novias del Gato UI Demo */ +@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap'); + +:root { + --bg-color: #0d0e12; + --surface-color: rgba(20, 22, 31, 0.75); + --surface-border: rgba(255, 255, 255, 0.08); + --text-primary: #f3f4f6; + --text-secondary: #9ca3af; + --primary-gradient: linear-gradient(135deg, #ff5e62 0%, #ff9966 100%); + --accent-color: #ff7e5f; + --success-color: #10b981; + --warning-color: #f59e0b; + --danger-color: #ef4444; + --font-family: 'Outfit', sans-serif; + --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.5); + --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1); + --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1); +} + +* { + box-sizing: border-box; + margin: 0; + padding: 0; +} + +body { + font-family: var(--font-family); + background-color: var(--bg-color); + color: var(--text-primary); + height: 100vh; + overflow: hidden; + display: flex; + flex-direction: column; +} + +/* Header */ +header { + height: 70px; + background: rgba(13, 14, 18, 0.85); + backdrop-filter: blur(12px); + -webkit-backdrop-filter: blur(12px); + border-bottom: 1px solid var(--surface-border); + display: flex; + justify-content: space-between; + align-items: center; + padding: 0 24px; + z-index: 1000; + position: relative; +} + +.logo-container { + display: flex; + align-items: center; + gap: 12px; +} + +.logo-icon { + background: var(--primary-gradient); + width: 40px; + height: 40px; + border-radius: 12px; + display: flex; + justify-content: center; + align-items: center; + color: white; + font-size: 1.25rem; + box-shadow: 0 4px 15px rgba(255, 94, 98, 0.3); + animation: float 3s ease-in-out infinite; +} + +.logo-text h1 { + font-size: 1.25rem; + font-weight: 700; + letter-spacing: 0.5px; + background: var(--primary-gradient); + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; +} + +.logo-text p { + font-size: 0.75rem; + color: var(--text-secondary); + font-weight: 400; + text-transform: uppercase; + letter-spacing: 1px; +} + +.header-stats { + display: flex; + gap: 16px; + align-items: center; +} + +.stat-badge { + background: rgba(255, 255, 255, 0.05); + border: 1px solid var(--surface-border); + padding: 8px 14px; + border-radius: 20px; + font-size: 0.85rem; + display: flex; + align-items: center; + gap: 8px; +} + +.stat-badge i { + color: var(--accent-color); +} + +.stat-badge .val { + font-weight: 600; + color: #fff; +} + +/* Main Container */ +.main-wrapper { + display: flex; + flex: 1; + position: relative; + height: calc(100vh - 70px); +} + +/* Sidebar */ +.sidebar { + width: 400px; + background: var(--surface-color); + backdrop-filter: blur(20px); + -webkit-backdrop-filter: blur(20px); + border-right: 1px solid var(--surface-border); + display: flex; + flex-direction: column; + z-index: 999; + transition: transform var(--transition-normal); + position: relative; + box-shadow: var(--shadow-lg); +} + +.sidebar-content { + flex: 1; + overflow-y: auto; + padding: 24px; + display: flex; + flex-direction: column; + gap: 20px; +} + +.sidebar-content::-webkit-scrollbar { + width: 6px; +} + +.sidebar-content::-webkit-scrollbar-thumb { + background: rgba(255, 255, 255, 0.1); + border-radius: 3px; +} + +/* Filters */ +.filter-section { + display: flex; + flex-direction: column; + gap: 10px; +} + +.filter-title { + font-size: 0.85rem; + font-weight: 600; + text-transform: uppercase; + letter-spacing: 1px; + color: var(--text-secondary); +} + +.filter-pills { + display: flex; + gap: 8px; + flex-wrap: wrap; +} + +.filter-pill { + background: rgba(255, 255, 255, 0.04); + border: 1px solid var(--surface-border); + color: var(--text-primary); + padding: 6px 12px; + border-radius: 16px; + font-size: 0.8rem; + cursor: pointer; + transition: all var(--transition-fast); + display: flex; + align-items: center; + gap: 6px; +} + +.filter-pill:hover { + background: rgba(255, 255, 255, 0.1); +} + +.filter-pill.active { + background: var(--accent-color); + color: white; + border-color: var(--accent-color); + box-shadow: 0 4px 12px rgba(255, 126, 95, 0.25); +} + +/* Sculpture List inside Sidebar */ +.sculptures-list { + display: flex; + flex-direction: column; + gap: 12px; +} + +.list-header { + display: flex; + justify-content: space-between; + align-items: center; + margin-top: 10px; +} + +.list-header h3 { + font-size: 0.95rem; + font-weight: 600; +} + +.sculpture-card { + background: rgba(255, 255, 255, 0.02); + border: 1px solid var(--surface-border); + border-radius: 14px; + padding: 12px; + cursor: pointer; + transition: all var(--transition-fast); + display: flex; + gap: 12px; + align-items: center; +} + +.sculpture-card:hover { + background: rgba(255, 255, 255, 0.06); + transform: translateY(-2px); + border-color: rgba(255, 255, 255, 0.15); +} + +.sculpture-card.selected { + background: rgba(255, 126, 95, 0.08); + border-color: var(--accent-color); +} + +.card-thumb { + width: 50px; + height: 50px; + border-radius: 8px; + object-fit: cover; + background: rgba(255, 255, 255, 0.05); +} + +.card-info { + flex: 1; + display: flex; + flex-direction: column; + gap: 2px; +} + +.card-title { + font-size: 0.9rem; + font-weight: 600; + color: white; +} + +.card-artist { + font-size: 0.75rem; + color: var(--text-secondary); +} + +.status-badge { + font-size: 0.7rem; + padding: 2px 8px; + border-radius: 10px; + font-weight: 500; + width: fit-content; + display: flex; + align-items: center; + gap: 4px; +} + +.status-badge::before { + content: ''; + display: inline-block; + width: 6px; + height: 6px; + border-radius: 50%; +} + +.status-on-site { + background: rgba(16, 185, 129, 0.15); + color: var(--success-color); +} +.status-on-site::before { background: var(--success-color); } + +.status-moved { + background: rgba(245, 158, 11, 0.15); + color: var(--warning-color); +} +.status-moved::before { background: var(--warning-color); } + +.status-missing { + background: rgba(239, 68, 68, 0.15); + color: var(--danger-color); +} +.status-missing::before { background: var(--danger-color); } + +/* Detail Panel Container (replacing list view on selection) */ +.detail-panel { + display: flex; + flex-direction: column; + gap: 20px; + animation: fadeIn 0.3s ease; +} + +.back-btn { + background: none; + border: none; + color: var(--text-secondary); + font-size: 0.85rem; + cursor: pointer; + display: flex; + align-items: center; + gap: 6px; + transition: color var(--transition-fast); + width: fit-content; +} + +.back-btn:hover { + color: white; +} + +.detail-img-container { + position: relative; + width: 100%; + height: 220px; + border-radius: 16px; + overflow: hidden; + box-shadow: var(--shadow-lg); + border: 1px solid var(--surface-border); +} + +.detail-img { + width: 100%; + height: 100%; + object-fit: cover; +} + +.detail-overlay { + position: absolute; + bottom: 0; + left: 0; + right: 0; + background: linear-gradient(to top, rgba(13, 14, 18, 0.95) 0%, rgba(13, 14, 18, 0) 100%); + padding: 16px; + display: flex; + justify-content: space-between; + align-items: flex-end; +} + +.detail-title { + font-size: 1.3rem; + font-weight: 700; + color: white; + margin-bottom: 4px; +} + +.detail-subtitle { + font-size: 0.85rem; + color: var(--text-secondary); +} + +.detail-meta { + display: flex; + flex-direction: column; + gap: 12px; +} + +.meta-row { + display: flex; + justify-content: space-between; + border-bottom: 1px solid rgba(255, 255, 255, 0.05); + padding-bottom: 8px; + font-size: 0.85rem; +} + +.meta-label { + color: var(--text-secondary); +} + +.meta-val { + color: white; + font-weight: 500; +} + +.detail-desc { + font-size: 0.9rem; + color: var(--text-secondary); + line-height: 1.5; +} + +.unlocked-box { + background: rgba(16, 185, 129, 0.06); + border: 1px dashed rgba(16, 185, 129, 0.3); + border-radius: 12px; + padding: 14px; + font-size: 0.85rem; + line-height: 1.5; + color: #a7f3d0; + display: flex; + flex-direction: column; + gap: 8px; + animation: pulseGreen 2s infinite alternate; +} + +.unlocked-header { + font-weight: 600; + display: flex; + align-items: center; + gap: 6px; + color: var(--success-color); +} + +.locked-box { + background: rgba(255, 255, 255, 0.02); + border: 1px dashed rgba(255, 255, 255, 0.1); + border-radius: 12px; + padding: 14px; + text-align: center; + font-size: 0.85rem; + color: var(--text-secondary); +} + +.checkin-btn { + background: var(--primary-gradient); + border: none; + color: white; + font-family: var(--font-family); + font-size: 0.95rem; + font-weight: 600; + padding: 14px; + border-radius: 12px; + cursor: pointer; + display: flex; + justify-content: center; + align-items: center; + gap: 10px; + box-shadow: 0 4px 15px rgba(255, 94, 98, 0.3); + transition: all var(--transition-fast); +} + +.checkin-btn:hover { + transform: translateY(-2px); + box-shadow: 0 6px 20px rgba(255, 94, 98, 0.45); +} + +.checkin-btn:active { + transform: translateY(0); +} + +/* Audio Player Mock */ +.audio-player-mock { + background: rgba(255, 255, 255, 0.03); + border: 1px solid var(--surface-border); + border-radius: 12px; + padding: 12px; + display: flex; + align-items: center; + gap: 12px; +} + +.audio-play-btn { + background: rgba(255, 255, 255, 0.1); + border: none; + width: 36px; + height: 36px; + border-radius: 50%; + display: flex; + justify-content: center; + align-items: center; + color: white; + cursor: pointer; + transition: background var(--transition-fast); +} + +.audio-play-btn:hover { + background: var(--accent-color); +} + +.audio-progress { + flex: 1; + height: 4px; + background: rgba(255, 255, 255, 0.1); + border-radius: 2px; + position: relative; + overflow: hidden; +} + +.audio-progress-bar { + width: 35%; + height: 100%; + background: var(--accent-color); + border-radius: 2px; +} + +.audio-time { + font-size: 0.75rem; + color: var(--text-secondary); +} + +/* Map Area */ +.map-container { + flex: 1; + position: relative; + height: 100%; +} + +#map { + width: 100%; + height: 100%; + background: #090a0f; +} + +/* Custom Map Marker Glow */ +.custom-pin { + display: flex; + justify-content: center; + align-items: center; + position: relative; +} + +.pin-glow { + width: 16px; + height: 16px; + border-radius: 50%; + background: var(--accent-color); + box-shadow: 0 0 10px var(--accent-color), 0 0 20px var(--accent-color); + border: 2px solid white; + animation: glow 1.5s infinite alternate; +} + +.pin-glow.status-on-site { + background: var(--success-color); + box-shadow: 0 0 10px var(--success-color), 0 0 20px var(--success-color); +} + +.pin-glow.status-moved { + background: var(--warning-color); + box-shadow: 0 0 10px var(--warning-color), 0 0 20px var(--warning-color); +} + +.pin-glow.status-missing { + background: var(--danger-color); + box-shadow: 0 0 10px var(--danger-color), 0 0 20px var(--danger-color); +} + +/* Viewfinder Modal (Check-in camera validation UI) */ +.modal-overlay { + position: fixed; + top: 0; + left: 0; + right: 0; + bottom: 0; + background: rgba(9, 10, 15, 0.85); + backdrop-filter: blur(8px); + -webkit-backdrop-filter: blur(8px); + display: flex; + justify-content: center; + align-items: center; + z-index: 2000; + opacity: 0; + pointer-events: none; + transition: opacity 0.3s ease; +} + +.modal-overlay.active { + opacity: 1; + pointer-events: auto; +} + +.modal-card { + width: 90%; + max-width: 440px; + background: #151722; + border: 1px solid var(--surface-border); + border-radius: 24px; + overflow: hidden; + box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7); + display: flex; + flex-direction: column; + transform: scale(0.9); + transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); +} + +.modal-overlay.active .modal-card { + transform: scale(1); +} + +.modal-header { + padding: 16px 20px; + border-bottom: 1px solid var(--surface-border); + display: flex; + justify-content: space-between; + align-items: center; +} + +.modal-header h3 { + font-size: 1.05rem; + font-weight: 600; +} + +.close-modal-btn { + background: none; + border: none; + color: var(--text-secondary); + font-size: 1.2rem; + cursor: pointer; +} + +.close-modal-btn:hover { + color: white; +} + +.modal-body { + padding: 20px; + display: flex; + flex-direction: column; + gap: 20px; + align-items: center; +} + +/* Camera Viewfinder Mock */ +.viewfinder-container { + width: 100%; + height: 280px; + background: #0d0e12; + border-radius: 16px; + position: relative; + overflow: hidden; + border: 2px solid rgba(255, 255, 255, 0.05); +} + +.viewfinder-img { + width: 100%; + height: 100%; + object-fit: cover; + filter: blur(2px) brightness(0.6); + transition: filter 0.5s ease; +} + +.viewfinder-scanlines { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + background: linear-gradient( + rgba(18, 16, 16, 0) 50%, + rgba(0, 0, 0, 0.25) 50% + ); + background-size: 100% 4px; + z-index: 10; + pointer-events: none; +} + +.viewfinder-line { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 4px; + background: rgba(255, 94, 98, 0.7); + box-shadow: 0 0 10px rgba(255, 94, 98, 0.8); + z-index: 11; + animation: scan 2.5s linear infinite; +} + +.viewfinder-corners { + position: absolute; + top: 15px; + left: 15px; + right: 15px; + bottom: 15px; + border: 1px solid rgba(255, 255, 255, 0.15); + pointer-events: none; + z-index: 12; +} + +.viewfinder-corners::before, +.viewfinder-corners::after { + content: ''; + position: absolute; + width: 20px; + height: 20px; + border-color: var(--accent-color); + border-style: solid; +} + +.viewfinder-corners::before { + top: -2px; + left: -2px; + border-width: 2px 0 0 2px; +} + +.viewfinder-corners::after { + bottom: -2px; + right: -2px; + border-width: 0 2px 2px 0; +} + +/* Secondary corners using CSS hacks */ +.viewfinder-corners-2 { + position: absolute; + top: 15px; + left: 15px; + right: 15px; + bottom: 15px; + pointer-events: none; + z-index: 12; +} + +.viewfinder-corners-2::before, +.viewfinder-corners-2::after { + content: ''; + position: absolute; + width: 20px; + height: 20px; + border-color: var(--accent-color); + border-style: solid; +} + +.viewfinder-corners-2::before { + top: -2px; + right: -2px; + border-width: 2px 2px 0 0; +} + +.viewfinder-corners-2::after { + bottom: -2px; + left: -2px; + border-width: 0 0 2px 2px; +} + +.viewfinder-overlay { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + z-index: 15; + background: rgba(13, 14, 18, 0.4); +} + +.gps-lock-status { + position: absolute; + bottom: 25px; + left: 25px; + display: flex; + align-items: center; + gap: 8px; + font-size: 0.75rem; + background: rgba(0, 0, 0, 0.6); + padding: 4px 10px; + border-radius: 10px; + border: 1px solid rgba(255,255,255,0.1); + color: var(--success-color); +} + +.gps-lock-status i { + animation: pulse 1s infinite alternate; +} + +/* Simulated Logs / Processes */ +.scan-logs { + width: 100%; + background: #090a0f; + border: 1px solid var(--surface-border); + border-radius: 12px; + padding: 12px; + font-family: monospace; + font-size: 0.75rem; + color: #10b981; + display: flex; + flex-direction: column; + gap: 6px; + min-height: 80px; +} + +.log-entry { + display: flex; + align-items: center; + gap: 8px; +} + +.log-spinner { + width: 10px; + height: 10px; + border: 2px solid transparent; + border-top-color: #10b981; + border-radius: 50%; + animation: spin 0.8s linear infinite; +} + +/* Success Card Content (replaced inside modal body upon validation success) */ +.success-card { + display: flex; + flex-direction: column; + align-items: center; + text-align: center; + gap: 16px; + animation: scaleUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); + padding: 10px 0; +} + +.success-icon { + width: 72px; + height: 72px; + background: rgba(16, 185, 129, 0.1); + border: 2px solid var(--success-color); + border-radius: 50%; + display: flex; + justify-content: center; + align-items: center; + color: var(--success-color); + font-size: 2.2rem; + box-shadow: 0 0 20px rgba(16, 185, 129, 0.2); +} + +.success-title { + font-size: 1.4rem; + font-weight: 700; + color: white; +} + +.success-badge-reward { + background: var(--primary-gradient); + color: white; + font-size: 0.8rem; + font-weight: 600; + padding: 6px 14px; + border-radius: 20px; + display: flex; + align-items: center; + gap: 6px; + box-shadow: 0 4px 10px rgba(255, 94, 98, 0.2); +} + +.similarity-metric { + font-size: 0.85rem; + color: var(--text-secondary); +} + +.similarity-metric .val { + color: var(--success-color); + font-weight: 600; +} + +.close-success-btn { + width: 100%; + background: rgba(255, 255, 255, 0.05); + border: 1px solid var(--surface-border); + color: white; + padding: 12px; + border-radius: 12px; + font-family: var(--font-family); + font-weight: 600; + cursor: pointer; + transition: all var(--transition-fast); +} + +.close-success-btn:hover { + background: rgba(255, 255, 255, 0.1); +} + +/* Animations */ +@keyframes float { + 0% { transform: translateY(0px); } + 50% { transform: translateY(-5px); } + 100% { transform: translateY(0px); } +} + +@keyframes glow { + from { box-shadow: 0 0 4px var(--accent-color), 0 0 8px var(--accent-color); } + to { box-shadow: 0 0 12px var(--accent-color), 0 0 24px var(--accent-color); } +} + +@keyframes scan { + 0% { top: 0%; } + 50% { top: 100%; } + 100% { top: 0%; } +} + +@keyframes spin { + to { transform: rotate(360deg); } +} + +@keyframes pulse { + from { opacity: 0.4; } + to { opacity: 1; } +} + +@keyframes pulseGreen { + from { border-color: rgba(16, 185, 129, 0.2); } + to { border-color: rgba(16, 185, 129, 0.5); } +} + +@keyframes fadeIn { + from { opacity: 0; transform: translateY(8px); } + to { opacity: 1; transform: translateY(0); } +} + +@keyframes scaleUp { + from { transform: scale(0.85); opacity: 0; } + to { transform: scale(1); opacity: 1; } +}