/* ============================================================================
   PRESENCE GPS SYSTEM - Styling
   ============================================================================ */

/* GPS Location Badge */
.gps-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.9em;
}

.gps-badge.valid {
    background: #f0fdf4;
    color: #059669;
    border: 2px solid #bbf7d0;
}

.gps-badge.invalid {
    background: #fef2f2;
    color: #dc2626;
    border: 2px solid #fecaca;
}

.gps-badge.pending {
    background: #fef3c7;
    color: #d97706;
    border: 2px solid #fde68a;
}

/* Clock Button Animations */
.clock-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.clock-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.clock-btn:active::before {
    width: 300px;
    height: 300px;
}

.clock-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
}

/* Presence Status Card */
.presence-status-card {
    background: white;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.presence-status-card:hover {
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}

/* Location Pulse Animation */
@keyframes pulse-location {
    0% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}

.location-active {
    animation: pulse-location 2s infinite;
}

/* GPS Indicator */
.gps-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 8px;
}

.gps-indicator.active {
    background: #10b981;
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.2);
    animation: pulse-location 2s infinite;
}

.gps-indicator.inactive {
    background: #ef4444;
}

/* Time Display */
.time-display {
    font-family: 'Courier New', monospace;
    font-size: 2em;
    font-weight: 700;
    letter-spacing: 2px;
    color: #1f2937;
}

/* Distance Badge */
.distance-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    background: #eff6ff;
    color: #3b82f6;
    border-radius: 6px;
    font-size: 0.85em;
    font-weight: 500;
}

/* Status Timeline */
.status-timeline {
    position: relative;
    padding-left: 30px;
}

.status-timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #e5e7eb;
}

.status-timeline-item {
    position: relative;
    margin-bottom: 20px;
}

.status-timeline-item::before {
    content: '';
    position: absolute;
    left: -25px;
    top: 5px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: white;
    border: 3px solid #3b82f6;
}

.status-timeline-item.completed::before {
    background: #10b981;
    border-color: #10b981;
}

/* Responsive Design */
@media (max-width: 768px) {
    .presence-status-card {
        padding: 20px;
    }
    
    .time-display {
        font-size: 1.5em;
    }
    
    .clock-btn {
        padding: 15px 30px !important;
        font-size: 1em !important;
    }
}

/* Loading Spinner for GPS */
.gps-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(99, 102, 241, 0.3);
    border-radius: 50%;
    border-top-color: #6366f1;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Map Container (untuk future enhancement) */
.map-container {
    width: 100%;
    height: 300px;
    border-radius: 12px;
    overflow: hidden;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Success Animation */
@keyframes success-bounce {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.success-animation {
    animation: success-bounce 0.5s ease;
}
